mirror of
https://github.com/zen-browser/desktop.git
synced 2025-09-06 03:18:19 +00:00
FIxed mica window control buttons
This commit is contained in:
@@ -110,10 +110,3 @@
|
|||||||
margin-inline-end: 8px;
|
margin-inline-end: 8px;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
@media (-moz-windows-mica) {
|
|
||||||
:root[should-hide='true'] .titlebar-buttonbox {
|
|
||||||
/* We need to add a background so windows doesnt generate a default one */
|
|
||||||
background: var(--zen-branding-bg);
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
19
src/widget/windows/nsWindow-cpp.patch
Normal file
19
src/widget/windows/nsWindow-cpp.patch
Normal file
@@ -0,0 +1,19 @@
|
|||||||
|
diff --git a/widget/windows/nsWindow.cpp b/widget/windows/nsWindow.cpp
|
||||||
|
index 00681c216c838efedbbcded9d6b843dbd8b5b0b6..e40203bc4557acbf014e7a5d16ca35fad7b57ca0 100644
|
||||||
|
--- a/widget/windows/nsWindow.cpp
|
||||||
|
+++ b/widget/windows/nsWindow.cpp
|
||||||
|
@@ -1078,6 +1078,14 @@ nsresult nsWindow::Create(nsIWidget* aParent, const LayoutDeviceIntRect& aRect,
|
||||||
|
const DWM_SYSTEMBACKDROP_TYPE tabbedWindow = DWMSBT_TABBEDWINDOW;
|
||||||
|
DwmSetWindowAttribute(mWnd, DWMWA_SYSTEMBACKDROP_TYPE, &tabbedWindow,
|
||||||
|
sizeof tabbedWindow);
|
||||||
|
+
|
||||||
|
+ // If someone wants to make a patch to firefox, im fine with it. Im tired, boss.
|
||||||
|
+ // Windows creates some sort of control buttons under the titlebar, which is
|
||||||
|
+ // annoying for us because it wont allow us to have those hiding animations.
|
||||||
|
+ // Let's just... remove them... and hope for the best.
|
||||||
|
+ LONG_PTR style = ::GetWindowLongPtr(hwnd, GWL_STYLE);
|
||||||
|
+ style &= ~(kTitlebarItemsWindowStyles);
|
||||||
|
+ ::SetWindowLongPtr(hwnd, GWL_STYLE, style);
|
||||||
|
}
|
||||||
|
|
||||||
|
if (mOpeningAnimationSuppressed) {
|
Reference in New Issue
Block a user