From 176565d78cac21ddc64ca95edb0b3b97ce7b7210 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Luis=20=C3=81ngel=20San=20Mart=C3=ADn?= Date: Mon, 10 Sep 2018 20:49:14 +0200 Subject: [PATCH] Use the native macos toolbar depending on the theme. --- YACReaderLibrary/library_window.cpp | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/YACReaderLibrary/library_window.cpp b/YACReaderLibrary/library_window.cpp index 4d30a896..8283af13 100644 --- a/YACReaderLibrary/library_window.cpp +++ b/YACReaderLibrary/library_window.cpp @@ -179,11 +179,11 @@ void LibraryWindow::doLayout() editInfoToolBar = new QToolBar(); editInfoToolBar->setStyleSheet("QToolBar {border: none;}"); -#ifdef Q_OS_MAC - libraryToolBar = new YACReaderMacOSXToolbar(this); -#else - libraryToolBar = new YACReaderMainToolBar(this); -#endif + if (theme.isMacosNative) { + libraryToolBar = new YACReaderMacOSXToolbar(this); + } else { + libraryToolBar = new YACReaderMainToolBar(this); + } #ifndef NO_OPENGL //FLOW-----------------------------------------------------------------------