Skip to content

Commit

Permalink
Merge pull request #59767 from ConteZero/window_unmaximize
Browse files Browse the repository at this point in the history
  • Loading branch information
akien-mga authored Mar 31, 2022
2 parents bac58e8 + 59fb6c9 commit 4feee76
Showing 1 changed file with 9 additions and 2 deletions.
11 changes: 9 additions & 2 deletions platform/x11/os_x11.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -1774,8 +1774,15 @@ bool OS_X11::window_maximize_check(const char *p_atom_name) const {

if (result == Success) {
Atom *atoms = (Atom *)data;
Atom wm_act_max_horz = XInternAtom(x11_display, "_NET_WM_ACTION_MAXIMIZE_HORZ", False);
Atom wm_act_max_vert = XInternAtom(x11_display, "_NET_WM_ACTION_MAXIMIZE_VERT", False);
Atom wm_act_max_horz;
Atom wm_act_max_vert;
if (strcmp(p_atom_name, "_NET_WM_STATE") == 0) {
wm_act_max_horz = XInternAtom(x11_display, "_NET_WM_STATE_MAXIMIZED_HORZ", False);
wm_act_max_vert = XInternAtom(x11_display, "_NET_WM_STATE_MAXIMIZED_VERT", False);
} else {
wm_act_max_horz = XInternAtom(x11_display, "_NET_WM_ACTION_MAXIMIZE_HORZ", False);
wm_act_max_vert = XInternAtom(x11_display, "_NET_WM_ACTION_MAXIMIZE_VERT", False);
}
bool found_wm_act_max_horz = false;
bool found_wm_act_max_vert = false;

Expand Down

0 comments on commit 4feee76

Please sign in to comment.