Skip to content

Commit

Permalink
#3592 assume randr_notify is available
Browse files Browse the repository at this point in the history
  • Loading branch information
totaam committed Jul 26, 2023
1 parent 5cfc9c2 commit 2707043
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 7 deletions.
1 change: 0 additions & 1 deletion xpra/client/mixins/display.py
Original file line number Diff line number Diff line change
Expand Up @@ -108,7 +108,6 @@ def get_info(self):
# hello:
def get_caps(self) -> Dict[str,Any]:
caps = {
"randr_notify" : True,
"show-desktop" : True,
"vrefresh" : self.get_vrefresh(),
}
Expand Down
8 changes: 2 additions & 6 deletions xpra/server/source/display.py
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,6 @@ def init_state(self) -> None:
self.vrefresh : int = -1
self.icc : Dict = {}
self.display_icc : Dict = {}
self.randr_notify : bool = False
self.desktop_size : Optional[Tuple[int, int]] = None
self.desktop_mode_size : Optional[Tuple[int, int]] = None
self.desktop_size_unscaled : Optional[Tuple[int, int]] = None
Expand All @@ -47,7 +46,6 @@ def get_info(self) -> Dict[str,Any]:
"desktop_size" : self.desktop_size or "",
"desktops" : self.desktops,
"desktop_names" : self.desktop_names,
"randr_notify" : self.randr_notify,
"opengl" : self.opengl_props,
"monitors" : self.monitors,
"screens" : len(self.screen_sizes),
Expand All @@ -61,7 +59,6 @@ def get_info(self) -> Dict[str,Any]:

def parse_client_caps(self, c : typedict) -> None:
self.vrefresh = c.intget("vrefresh", -1)
self.randr_notify = c.boolget("randr_notify")
self.desktop_size = c.intpair("desktop_size")
if self.desktop_size is not None:
w, h = self.desktop_size
Expand Down Expand Up @@ -165,11 +162,10 @@ def set_desktops(self, desktops:int, desktop_names) -> None:
self.desktop_names = tuple(net_utf8(d) for d in (desktop_names or ()))

def updated_desktop_size(self, root_w:int, root_h:int, max_w:int, max_h:int) -> bool:
log("updated_desktop_size%s randr_notify=%s, desktop_size=%s",
(root_w, root_h, max_w, max_h), self.randr_notify, self.desktop_size)
log("updated_desktop_size%s desktop_size=%s", (root_w, root_h, max_w, max_h), self.desktop_size)
if not self.hello_sent:
return False
if self.randr_notify and (not self.desktop_size_server or tuple(self.desktop_size_server)!=(root_w, root_h)):
if not self.desktop_size_server or tuple(self.desktop_size_server)!=(root_w, root_h):
self.desktop_size_server = root_w, root_h
self.send("desktop_size", root_w, root_h, max_w, max_h)
return True
Expand Down

0 comments on commit 2707043

Please sign in to comment.