Skip to content

Commit

Permalink
Blender LDraw Render - remove mAddonUpdate #416
Browse files Browse the repository at this point in the history
  • Loading branch information
trevorsandy committed May 28, 2023
1 parent d787e6e commit fd54270
Show file tree
Hide file tree
Showing 15 changed files with 31 additions and 36 deletions.
2 changes: 1 addition & 1 deletion builds/linux/obs/PKGBUILD
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
# Last Update: July 19, 2020
# Copyright (C) 2017 - 2023 by Trevor SANDY
pkgname=lpub3d
pkgver=2.4.6.3384
pkgver=2.4.6.3385
pkgrel=1
pkgdesc="An LDraw Building Instruction Editor"
url="https://github.com/trevorsandy/lpub3d.git"
Expand Down
2 changes: 1 addition & 1 deletion builds/linux/obs/alldeps/PKGBUILD
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
# Last Update: July 19, 2020
# Copyright (C) 2017 - 2023 by Trevor SANDY
pkgname=lpub3d
pkgver=2.4.6.3384
pkgver=2.4.6.3385
pkgrel=1
pkgdesc="An LDraw Building Instruction Editor"
url="https://github.com/trevorsandy/lpub3d.git"
Expand Down
6 changes: 3 additions & 3 deletions builds/linux/obs/alldeps/debian/changelog
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
lpub3d (2.4.6.3384) debian; urgency=medium
lpub3d (2.4.6.3385) debian; urgency=medium

* LPub3D version 2.4.6.273.3384_20230528 for Linux
* LPub3D version 2.4.6.274.3385_20230528 for Linux

-- Trevor SANDY <trevor.sandy@gmail.com> Sun, 28 May 2023 18:29:02 +0200
-- Trevor SANDY <trevor.sandy@gmail.com> Sun, 28 May 2023 18:31:04 +0200
2 changes: 1 addition & 1 deletion builds/linux/obs/alldeps/debian/lpub3d.dsc
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@ Format: 1.0
Source: lpub3d
Binary: lpub3d
Architecture: any
Version: 2.4.6.3384
Version: 2.4.6.3385
Maintainer: Trevor SANDY <trevor.sandy@gmail.com>
Homepage: https://trevorsandy.github.io/lpub3d/
Standards-Version: 3.9.7
Expand Down
4 changes: 2 additions & 2 deletions builds/linux/obs/alldeps/lpub3d.spec
Original file line number Diff line number Diff line change
Expand Up @@ -120,7 +120,7 @@ BuildRequires: fdupes
Summary: An LDraw Building Instruction Editor
Name: lpub3d
Icon: lpub3d.xpm
Version: 2.4.6.3384
Version: 2.4.6.3385
Release: <B_CNT>%{?dist}
URL: https://trevorsandy.github.io/lpub3d
Vendor: Trevor SANDY
Expand Down Expand Up @@ -797,7 +797,7 @@ update-desktop-database || true
%endif

%changelog
* Sun May 28 2023 - trevor.dot.sandy.at.gmail.dot.com 2.4.6.3384
* Sun May 28 2023 - trevor.dot.sandy.at.gmail.dot.com 2.4.6.3385
- LPub3D 2.4.4 enhancements and fixes - see RELEASE_NOTES for details

* Tue May 31 2022 - trevor dot sandy at gmail dot com 2.4.4.2670
Expand Down
6 changes: 3 additions & 3 deletions builds/linux/obs/debian/changelog
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
lpub3d (2.4.6.3384) debian; urgency=medium
lpub3d (2.4.6.3385) debian; urgency=medium

* LPub3D version 2.4.6.273.3384_20230528 for Linux
* LPub3D version 2.4.6.274.3385_20230528 for Linux

-- Trevor SANDY <trevor.sandy@gmail.com> Sun, 28 May 2023 18:29:04 +0200
-- Trevor SANDY <trevor.sandy@gmail.com> Sun, 28 May 2023 18:31:05 +0200
2 changes: 1 addition & 1 deletion builds/linux/obs/debian/lpub3d.dsc
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@ Format: 1.0
Source: lpub3d
Binary: lpub3d
Architecture: any
Version: 2.4.6.3384
Version: 2.4.6.3385
Maintainer: Trevor SANDY <trevor.sandy@gmail.com>
Homepage: https://trevorsandy.github.io/lpub3d/
Standards-Version: 3.9.7
Expand Down
4 changes: 2 additions & 2 deletions builds/linux/obs/lpub3d.spec
Original file line number Diff line number Diff line change
Expand Up @@ -82,7 +82,7 @@ BuildRequires: fdupes
Summary: An LDraw Building Instruction Editor
Name: lpub3d
Icon: lpub3d.xpm
Version: 2.4.6.3384
Version: 2.4.6.3385
Release: 1%{?dist}
URL: https://trevorsandy.github.io/lpub3d
Vendor: Trevor SANDY
Expand Down Expand Up @@ -313,7 +313,7 @@ update-desktop-database || true
%endif

%changelog
* Sun May 28 2023 - trevor.dot.sandy.at.gmail.dot.com 2.4.6.3384
* Sun May 28 2023 - trevor.dot.sandy.at.gmail.dot.com 2.4.6.3385
- LPub3D 2.4.4 enhancements and fixes - see RELEASE_NOTES for details

* Tue May 31 2022 - trevor dot sandy at gmail dot com 2.4.4.2670
Expand Down
2 changes: 1 addition & 1 deletion builds/utilities/version.info
Original file line number Diff line number Diff line change
@@ -1 +1 @@
2 4 6 273 3384 ce0d63675
2 4 6 274 3385 d787e6efb
6 changes: 3 additions & 3 deletions gitversion.pri
Original file line number Diff line number Diff line change
Expand Up @@ -41,7 +41,7 @@ equals(GIT_DIR, undefined) {

# Check if we do not have a valid version number (i.e. no version tag found)
isEmpty(GIT_VERSION) {
GIT_REVISION = 273
GIT_REVISION = 274
GIT_SHA = $$system($$GIT_BASE_COMMAND rev-parse --short HEAD 2> $$NULL_DEVICE)
GIT_COMMIT = $$system($$GIT_BASE_COMMAND rev-list --count HEAD 2> $$NULL_DEVICE)
GIT_VERSION = v$${VERSION}-$${GIT_REVISION}-$${GIT_SHA}
Expand Down Expand Up @@ -69,7 +69,7 @@ equals(GIT_DIR, undefined) {
# Get commit count
GIT_COMMIT = $$system($$GIT_BASE_COMMAND rev-list --count HEAD 2> $$NULL_DEVICE)
isEmpty(GIT_COMMIT) {
GIT_COMMIT = 3384
GIT_COMMIT = 3385
message("~~~ ERROR! GIT_COMMIT NOT DEFINED, USING $$GIT_COMMIT ~~~")
}

Expand Down Expand Up @@ -117,7 +117,7 @@ if (equals(USE_GIT_VER_FILE, true)|equals(USE_VERSION_INFO_VAR, true)) {
GIT_VERSION = $$cat($$GIT_VER_FILE, lines)
} else {
message("~~~ ERROR! $$GIT_DIR_ENV VERSION_INFO FILE $$GIT_VER_FILE NOT FOUND ~~~")
GIT_VERSION = $${VERSION}.273.3384.ce0d63675
GIT_VERSION = $${VERSION}.274.3385.d787e6efb
message("~~~ GIT_DIR [$$GIT_DIR_ENV, USING VERSION] $$GIT_VERSION ~~~")
GIT_VERSION ~= s/\./" "
}
Expand Down
20 changes: 8 additions & 12 deletions mainApp/blenderpreferences.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -490,7 +490,6 @@ BlenderPreferences::BlenderPreferences(
versionText = tr("Blender not configured");
}

mAddonUpdate = false;
mAddonVersionEdit->setVisible(!mAddonVersion.isEmpty());
mBlenderVersionLabel->setStyleSheet(QString("QLabel { color : %1; }").arg(textColour));
mAddonVersionLabel->setStyleSheet(QString("QLabel { color : %1; }").arg(textColour));
Expand Down Expand Up @@ -845,18 +844,17 @@ void BlenderPreferences::updateBlenderAddon()
{
mAddonUpdateButton->setEnabled(false);

QObject::disconnect(mPathLineEditList[LBL_BLENDER_PATH], SIGNAL(editingFinished()),
this, SLOT (configureBlenderAddon()));
disconnect(mPathLineEditList[LBL_BLENDER_PATH], SIGNAL(editingFinished()),
this, SLOT (configureBlenderAddon()));

mAddonUpdate = !mAddonVersion.isEmpty();

configureBlenderAddon(sender() == mPathBrowseButtonList[LBL_BLENDER_PATH]);
configureBlenderAddon(sender() == mPathBrowseButtonList[LBL_BLENDER_PATH],
sender() == mAddonUpdateButton);

connect(mPathLineEditList[LBL_BLENDER_PATH], SIGNAL(editingFinished()),
this, SLOT (configureBlenderAddon()));
}

void BlenderPreferences::configureBlenderAddon(bool testBlender)
void BlenderPreferences::configureBlenderAddon(bool testBlender, bool addonUpdate)
{
mProgressBar = nullptr;

Expand Down Expand Up @@ -892,7 +890,7 @@ void BlenderPreferences::configureBlenderAddon(bool testBlender)

bool newBlenderExe = blenderExeCompare != blenderExe.toLower();

if (mConfigured && !mAddonUpdate && !newBlenderExe)
if (mConfigured && !addonUpdate && !newBlenderExe)
return;

// Process command
Expand Down Expand Up @@ -1112,7 +1110,7 @@ void BlenderPreferences::configureBlenderAddon(bool testBlender)
: QString(); // disable all import modules
Preferences::setBlenderImportModule(preferredImportModule);
} else {
mBlenderVersionEdit->setVisible(mAddonUpdate); // was false
mBlenderVersionEdit->setVisible(addonUpdate);
}

if (mProgressBar) {
Expand All @@ -1122,10 +1120,9 @@ void BlenderPreferences::configureBlenderAddon(bool testBlender)

// Download and extract blender addon
if (!extractBlenderAddon(blenderDir)) {
if (mAddonUpdate) {
if (addonUpdate) {
mExeGridLayout->replaceWidget(mProgressBar, mBlenderVersionEdit);
mConfigured = true;
mAddonUpdate = !mConfigured;
mBlenderVersionLabel->setText(tr("Blender"));
mBlenderVersionLabel->setStyleSheet(QString("QLabel { color : %1; }").arg(QApplication::palette().text().color().name()));
mBlenderVersionEdit->setText(mBlenderVersion);
Expand Down Expand Up @@ -1533,7 +1530,6 @@ void BlenderPreferences::showResult()
QString const textColour = QString("QLabel { color : %1; }").arg(QApplication::palette().text().color().name());
mAddonGridLayout->replaceWidget(mProgressBar, mAddonVersionEdit);
mConfigured = true;
mAddonUpdate = !mConfigured;
mBlenderVersionLabel->setText(tr("Blender"));
mBlenderVersionLabel->setStyleSheet(textColour);
mBlenderVersionEdit->setText(mBlenderVersion);
Expand Down
3 changes: 1 addition & 2 deletions mainApp/blenderpreferences.h
Original file line number Diff line number Diff line change
Expand Up @@ -127,7 +127,7 @@ public slots:

private slots:
void browseBlender(bool);
void configureBlenderAddon(bool = false);
void configureBlenderAddon(bool = false, bool = false);
void updateBlenderAddon();
void enableImportModule();
void sizeChanged(const QString &);
Expand Down Expand Up @@ -464,7 +464,6 @@ private slots:
QString mBlenderVersion;
QString mAddonVersion;
bool mConfigured;
bool mAddonUpdate;
bool mDocumentRender;
bool mDialogCancelled;
};
Expand Down
2 changes: 1 addition & 1 deletion mainApp/docs/README.txt
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
LPub3D 2.4.6.273.3384 (28 05 2023 18:29:04)
LPub3D 2.4.6.274.3385 (28 05 2023 18:31:05)

Features, enhancements, fixes and changes
------------
Expand Down
2 changes: 1 addition & 1 deletion mainApp/docs/RELEASE_NOTES.html
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@
<table class="tg">
<tr>
<th class="tg-0pky">
<h4><a id="LPub3D_0"></a>LPub3D 2.4.6.273.3384 (28 05 2023 18:29:04)</h4>
<h4><a id="LPub3D_0"></a>LPub3D 2.4.6.274.3385 (28 05 2023 18:31:05)</h4>
<hr>
<p>
<span class="tg-1pky">LPub3D Official release.</span><br>
Expand Down
4 changes: 2 additions & 2 deletions mainApp/extras/LPub3D_Npp_UDL.xml
Original file line number Diff line number Diff line change
Expand Up @@ -14,8 +14,8 @@
;;
;; Author......: Trevor SANDY
;; Name........: LPub3D_Npp_UDL.xml
;; Version.....: 2.4.6.273.3384
;; Last Update.: Sun, 28 May 2023 18:29:04 +0200
;; Version.....: 2.4.6.274.3385
;; Last Update.: Sun, 28 May 2023 18:31:05 +0200
;; License.....: GPLv3
;; Homepage....: https://trevorsandy.github.io/lpub3d
;; Copyright (C) 2021 - 2023 by Trevor SANDY
Expand Down

0 comments on commit fd54270

Please sign in to comment.