Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(458)

Unified Diff: remoting/tools/me2me_virtual_host.py

Issue 10918224: Cross-platform plumbing for resize-to-client (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Reviewer comments. Created 8 years, 3 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« remoting/host/host_status_observer.h ('K') | « remoting/remoting.gyp ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: remoting/tools/me2me_virtual_host.py
diff --git a/remoting/tools/me2me_virtual_host.py b/remoting/tools/me2me_virtual_host.py
index 1438bf472f38bd86cd3853da1e0c906613f8dbd2..d2da3ab0f1e1a4e2cd1e2bd103d30a030ebb2b36 100755
--- a/remoting/tools/me2me_virtual_host.py
+++ b/remoting/tools/me2me_virtual_host.py
@@ -168,6 +168,7 @@ class Desktop:
self.child_env = None
self.sizes = sizes
self.pulseaudio_pipe = None
+ self.server_supports_exact_resize = False
g_desktops.append(self)
@staticmethod
@@ -253,9 +254,16 @@ class Desktop:
max_height = max([height for width, height in self.sizes])
try:
- xvfb = locate_executable("Xvfb-randr")
+ # TODO(jamiewalch): This script expects to be installed alongside
+ # Xvfb-randr, but that's no longer the case. Fix this once we have
+ # a Xvfb-randr package that installs somewhere sensible.
+ xvfb = "/usr/bin/Xvfb-randr"
+ if not os.path.exists(xvfb):
+ xvfb = locate_executable("Xvfb-randr")
+ self.server_supports_exact_resize = True
except Exception:
xvfb = "Xvfb"
+ self.server_supports_exact_resize = False
logging.info("Starting %s on display :%d" % (xvfb, display))
screen_option = "%dx%dx24" % (max_width, max_height)
@@ -347,6 +355,8 @@ class Desktop:
args = [locate_executable(HOST_BINARY_NAME), "--host-config=/dev/stdin"]
if self.pulseaudio_pipe:
args.append("--audio-pipe-name=%s" % self.pulseaudio_pipe)
+ if self.server_supports_exact_resize:
+ args.append("--server-supports-exact-resize")
self.host_proc = subprocess.Popen(args, env=self.child_env,
stdin=subprocess.PIPE)
logging.info(args)
@@ -601,7 +611,7 @@ def relaunch_self():
def main():
- DEFAULT_SIZE = "1280x800"
+ DEFAULT_SIZE = "2560x1600"
EPILOG = """This script is not intended for use by end-users. To configure
Chrome Remote Desktop, please install the app from the Chrome
Web Store: https://chrome.google.com/remotedesktop"""
« remoting/host/host_status_observer.h ('K') | « remoting/remoting.gyp ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698