diff --git a/common/lc_library.cpp b/common/lc_library.cpp index bcd834cc..2c943091 100644 --- a/common/lc_library.cpp +++ b/common/lc_library.cpp @@ -1537,6 +1537,11 @@ void lcPiecesLibrary::UploadTextures(lcContext* Context) mTextureUploads.clear(); } +bool lcPiecesLibrary::SupportsStudLogo() const +{ + return mZipFiles[LC_ZIPFILE_UNOFFICIAL] || mHasUnofficial; +} + void lcPiecesLibrary::SetStudLogo(int StudLogo, bool Reload) { mStudLogo = StudLogo; diff --git a/common/lc_library.h b/common/lc_library.h index deb95c85..0c8e197c 100644 --- a/common/lc_library.h +++ b/common/lc_library.h @@ -127,6 +127,7 @@ public: bool LoadPrimitive(lcLibraryPrimitive* Primitive); + bool SupportsStudLogo() const; void SetStudLogo(int StudLogo, bool Reload); int GetStudLogo() const diff --git a/qt/lc_qpreferencesdialog.cpp b/qt/lc_qpreferencesdialog.cpp index 3e107f99..c3d4f3f2 100644 --- a/qt/lc_qpreferencesdialog.cpp +++ b/qt/lc_qpreferencesdialog.cpp @@ -182,6 +182,12 @@ lcQPreferencesDialog::lcQPreferencesDialog(QWidget* Parent, lcPreferencesDialogO else ui->PreviewViewSphereSizeCombo->setCurrentIndex(0); + if (!lcGetPiecesLibrary()->SupportsStudLogo()) + { + ui->studLogo->setEnabled(false); + ui->studLogoCombo->setEnabled(false); + } + ui->studLogo->setChecked(mOptions->StudLogo); if (ui->studLogo->isChecked()) ui->studLogoCombo->setCurrentIndex(mOptions->StudLogo - 1); @@ -556,7 +562,8 @@ void lcQPreferencesDialog::ColorButtonClicked() void lcQPreferencesDialog::on_studLogo_toggled() { - ui->studLogoCombo->setEnabled(ui->studLogo->isChecked()); + if (lcGetPiecesLibrary()->SupportsStudLogo()) + ui->studLogoCombo->setEnabled(ui->studLogo->isChecked()); } void lcQPreferencesDialog::on_antiAliasing_toggled()