mirror of
https://github.com/ONLYOFFICE/desktop-apps.git
synced 2026-04-07 14:09:22 +08:00
Adaptation for WinXP
This commit is contained in:
@ -269,12 +269,13 @@ core_windows {
|
|||||||
-lcredui \
|
-lcredui \
|
||||||
-lnetapi32 \
|
-lnetapi32 \
|
||||||
-lcomctl32 \
|
-lcomctl32 \
|
||||||
-lrpcrt4 \
|
-lrpcrt4
|
||||||
-ldwmapi
|
|
||||||
# -lOpenGL32
|
# -lOpenGL32
|
||||||
|
|
||||||
build_xp {
|
build_xp {
|
||||||
DEFINES += __OS_WIN_XP
|
DEFINES += __OS_WIN_XP
|
||||||
|
} else {
|
||||||
|
LIBS += -ldwmapi
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@ -58,8 +58,10 @@ CWindowPlatform::CWindowPlatform(const QRect &rect) :
|
|||||||
m_hWnd = (HWND)winId();
|
m_hWnd = (HWND)winId();
|
||||||
DWORD style = ::GetWindowLong(m_hWnd, GWL_STYLE);
|
DWORD style = ::GetWindowLong(m_hWnd, GWL_STYLE);
|
||||||
::SetWindowLong(m_hWnd, GWL_STYLE, style | WS_MAXIMIZEBOX | WS_THICKFRAME | WS_CAPTION);
|
::SetWindowLong(m_hWnd, GWL_STYLE, style | WS_MAXIMIZEBOX | WS_THICKFRAME | WS_CAPTION);
|
||||||
|
#ifndef __OS_WIN_XP
|
||||||
const MARGINS shadow = {1, 1, 1, 1};
|
const MARGINS shadow = {1, 1, 1, 1};
|
||||||
DwmExtendFrameIntoClientArea(m_hWnd, &shadow);
|
DwmExtendFrameIntoClientArea(m_hWnd, &shadow);
|
||||||
|
#endif
|
||||||
connect(this->window()->windowHandle(), &QWindow::screenChanged, this, [=]() {
|
connect(this->window()->windowHandle(), &QWindow::screenChanged, this, [=]() {
|
||||||
QTimer::singleShot(50, this, [=]() {
|
QTimer::singleShot(50, this, [=]() {
|
||||||
resize(size() + QSize(1,1));
|
resize(size() + QSize(1,1));
|
||||||
|
|||||||
Reference in New Issue
Block a user