Update paths for homebrew on Apple Silicon Macs and use Qt Fusion theme on MacOS

This commit is contained in:
Adam Honse 2021-03-03 17:14:45 -06:00
parent 7c272a909d
commit 2915133d96
2 changed files with 14 additions and 2 deletions

View file

@ -816,9 +816,13 @@ unix:macx {
INCLUDEPATH += \
/usr/local/include \
/opt/homebrew/include \
LIBS += \
-L/usr/local/lib -lusb-1.0 -lhidapi \
-L/usr/local/lib \
-L/opt/homebrew/lib \
-lusb-1.0 \
-lhidapi \
CONFIG += \
c++14 \

View file

@ -9,6 +9,7 @@
#include <QTabBar>
#include <QMessageBox>
#include <QCloseEvent>
#include <QStyleFactory>
#ifdef _WIN32
#include <QSettings>
@ -259,7 +260,6 @@ OpenRGBDialog2::OpenRGBDialog2(QWidget *parent) : QMainWindow(parent), ui(new Op
/*-------------------------------------------------*\
| Apply dark theme on Windows if configured |
\*-------------------------------------------------*/
if(IsDarkTheme())
{
QPalette pal = palette();
@ -271,6 +271,14 @@ OpenRGBDialog2::OpenRGBDialog2(QWidget *parent) : QMainWindow(parent), ui(new Op
}
#endif
#ifdef __APPLE__
/*-------------------------------------------------*\
| Apply Qt Fusion theme on MacOS, as the MacOS |
| default theme does not handle vertical tabs well |
\*-------------------------------------------------*/
QApplication::setStyle(QStyleFactory::create("Fusion"));
#endif
/*-----------------------------------------------------*\
| Update the profile list |
\*-----------------------------------------------------*/