mirror of
https://git.sr.ht/~eliasnaur/gio
synced 2026-07-04 08:55:35 +00:00
app: [Windows] use SWP_NOZORDER instead of SWP_NOOWNERZORDER
As I read the SetWindowPos documentation, SWP_NOZORDER is the correct flag for keeping the z-order of the window. Signed-off-by: Elias Naur <mail@eliasnaur.com>
This commit is contained in:
+3
-3
@@ -624,7 +624,7 @@ func (w *window) Configure(options []Option) {
|
|||||||
y := wr.Top
|
y := wr.Top
|
||||||
dx := r.Right - r.Left
|
dx := r.Right - r.Left
|
||||||
dy := r.Bottom - r.Top
|
dy := r.Bottom - r.Top
|
||||||
windows.SetWindowPos(w.hwnd, 0, x, y, dx, dy, windows.SWP_NOOWNERZORDER|windows.SWP_FRAMECHANGED)
|
windows.SetWindowPos(w.hwnd, 0, x, y, dx, dy, windows.SWP_NOZORDER|windows.SWP_FRAMECHANGED)
|
||||||
windows.ShowWindow(w.hwnd, windows.SW_SHOWNORMAL)
|
windows.ShowWindow(w.hwnd, windows.SW_SHOWNORMAL)
|
||||||
|
|
||||||
case Fullscreen:
|
case Fullscreen:
|
||||||
@@ -636,7 +636,7 @@ func (w *window) Configure(options []Option) {
|
|||||||
mi.Monitor.Left, mi.Monitor.Top,
|
mi.Monitor.Left, mi.Monitor.Top,
|
||||||
mi.Monitor.Right-mi.Monitor.Left,
|
mi.Monitor.Right-mi.Monitor.Left,
|
||||||
mi.Monitor.Bottom-mi.Monitor.Top,
|
mi.Monitor.Bottom-mi.Monitor.Top,
|
||||||
windows.SWP_NOOWNERZORDER|windows.SWP_FRAMECHANGED,
|
windows.SWP_NOZORDER|windows.SWP_FRAMECHANGED,
|
||||||
)
|
)
|
||||||
windows.ShowWindow(w.hwnd, windows.SW_SHOW)
|
windows.ShowWindow(w.hwnd, windows.SW_SHOW)
|
||||||
}
|
}
|
||||||
@@ -760,7 +760,7 @@ func (w *window) Perform(acts system.Action) {
|
|||||||
mi := windows.GetMonitorInfo(w.hwnd).Monitor
|
mi := windows.GetMonitorInfo(w.hwnd).Monitor
|
||||||
x := (mi.Right - mi.Left - dx) / 2
|
x := (mi.Right - mi.Left - dx) / 2
|
||||||
y := (mi.Bottom - mi.Top - dy) / 2
|
y := (mi.Bottom - mi.Top - dy) / 2
|
||||||
windows.SetWindowPos(w.hwnd, 0, x, y, dx, dy, windows.SWP_NOOWNERZORDER|windows.SWP_FRAMECHANGED)
|
windows.SetWindowPos(w.hwnd, 0, x, y, dx, dy, windows.SWP_NOZORDER|windows.SWP_FRAMECHANGED)
|
||||||
case system.ActionRaise:
|
case system.ActionRaise:
|
||||||
w.raise()
|
w.raise()
|
||||||
case system.ActionClose:
|
case system.ActionClose:
|
||||||
|
|||||||
Reference in New Issue
Block a user