Skip to content

Commit

Permalink
Merge branch 'Mudlet:development' into ircServerPassword
Browse files Browse the repository at this point in the history
  • Loading branch information
atari2600tim committed Dec 3, 2021
2 parents da19e36 + 0e25764 commit 94a1804
Show file tree
Hide file tree
Showing 3 changed files with 657 additions and 596 deletions.
2 changes: 1 addition & 1 deletion src/main.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -487,7 +487,7 @@ int main(int argc, char* argv[])
QFile::link(homeDirectory, homeLink);
}
#endif
app->setStyle(new AltFocusMenuBarDisable);

mudlet::start();

if (first_launch) {
Expand Down
6 changes: 4 additions & 2 deletions src/mudlet.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -267,14 +267,16 @@ mudlet::mudlet()
}

qApp->setAttribute(Qt::AA_UseHighDpiPixmaps);
setAppearance(mAppearance, true);
// We need to record this before we clobber it with our own substitute...
mDefaultStyle = qApp->style()->objectName();
// ... which is applied here:
setAppearance(mAppearance, true);

scanForMudletTranslations(QStringLiteral(":/lang"));
scanForQtTranslations(getMudletPath(qtTranslationsPath));
loadTranslators(mInterfaceLanguage);

if (QStringList{"windowsvista", "macintosh"}.contains(mDefaultStyle, Qt::CaseInsensitive)) {
if (QStringList{"windowsvista", "macintosh"}.contains(mDefaultStyle, Qt::CaseInsensitive)) {
qDebug().nospace().noquote() << "mudlet::mudlet() INFO - '" << mDefaultStyle << "' has been detected as the style factory in use - QPushButton styling fix applied!";
mBG_ONLY_STYLESHEET = QStringLiteral("QPushButton {background-color: %1; border: 1px solid #8f8f91;}");
mTEXT_ON_BG_STYLESHEET = QStringLiteral("QPushButton {color: %1; background-color: %2; border: 1px solid #8f8f91;}");
Expand Down
Loading

0 comments on commit 94a1804

Please sign in to comment.