Remove builtin qtwin and use WinExtras, replace some macros
This commit is contained in:
@@ -74,11 +74,6 @@ include_directories(${CMAKE_SOURCE_DIR}/ext/libstrawberry-common)
|
||||
include_directories(${CMAKE_SOURCE_DIR}/ext/libstrawberry-tagreader)
|
||||
include_directories(${CMAKE_BINARY_DIR}/ext/libstrawberry-tagreader)
|
||||
|
||||
# Windows
|
||||
if (WIN32)
|
||||
include_directories(../3rdparty/qtwin)
|
||||
endif (WIN32)
|
||||
|
||||
set(SOURCES
|
||||
core/mainwindow.cpp
|
||||
core/application.cpp
|
||||
@@ -965,7 +960,6 @@ endif (APPLE)
|
||||
if (WIN32)
|
||||
target_link_libraries(strawberry_lib
|
||||
${ZLIB_LIBRARIES}
|
||||
qtwin
|
||||
dsound
|
||||
${QT_QTGUI_LIBRARY}
|
||||
)
|
||||
|
||||
@@ -217,7 +217,7 @@ void QtSystemTrayIcon::SetVisible(bool visible) {
|
||||
|
||||
void QtSystemTrayIcon::SetNowPlaying(const Song &song, const QString &image_path) {
|
||||
|
||||
#ifdef Q_WS_WIN
|
||||
#ifdef Q_OS_WIN
|
||||
// Windows doesn't support HTML in tooltips, so just show something basic
|
||||
tray_->setToolTip(song.PrettyTitleWithArtist());
|
||||
return;
|
||||
|
||||
@@ -49,15 +49,17 @@
|
||||
#include <QSettings>
|
||||
#include <QFlags>
|
||||
#include <QtEvents>
|
||||
#ifdef Q_WS_X11
|
||||
#ifdef HAVE_X11
|
||||
# include <QX11Info>
|
||||
#endif
|
||||
#ifdef Q_OS_WIN
|
||||
# include <QtWin>
|
||||
#endif
|
||||
|
||||
#include "osdpretty.h"
|
||||
#include "ui_osdpretty.h"
|
||||
|
||||
#ifdef Q_OS_WIN32
|
||||
# include "qtwin.h"
|
||||
#ifdef Q_OS_WIN
|
||||
# include <windows.h>
|
||||
#endif
|
||||
|
||||
@@ -160,7 +162,7 @@ OSDPretty::~OSDPretty() {
|
||||
}
|
||||
|
||||
bool OSDPretty::IsTransparencyAvailable() {
|
||||
#ifdef Q_WS_X11
|
||||
#ifdef HAVE_X11
|
||||
return QX11Info::isCompositingManagerRunning();
|
||||
#endif
|
||||
return true;
|
||||
@@ -366,7 +368,7 @@ void OSDPretty::Reposition() {
|
||||
|
||||
#ifdef Q_OS_WIN32
|
||||
// On windows, enable blurbehind on the masked area
|
||||
QtWin::enableBlurBehindWindow(this, true, QRegion(mask));
|
||||
QtWin::enableBlurBehindWindow(this, QRegion(mask));
|
||||
#endif
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user