diff options
author | jamiewalch@google.com <jamiewalch@google.com@0039d316-1c4b-4281-b951-d872f2087c98> | 2012-12-14 21:40:36 +0000 |
---|---|---|
committer | jamiewalch@google.com <jamiewalch@google.com@0039d316-1c4b-4281-b951-d872f2087c98> | 2012-12-14 21:40:36 +0000 |
commit | 5948872244a0d95a1e0d3d4ab7dd2209d018648a (patch) | |
tree | b54b9ea32f4334bfdd378e973c8f7c3237481a2a /remoting | |
parent | 36f659637c64042672f48f39b040991a145b4d7b (diff) | |
download | chromium_src-5948872244a0d95a1e0d3d4ab7dd2209d018648a.zip chromium_src-5948872244a0d95a1e0d3d4ab7dd2209d018648a.tar.gz chromium_src-5948872244a0d95a1e0d3d4ab7dd2209d018648a.tar.bz2 |
Increase default maximum desktop size and make it configurable.
BUG=166099
Review URL: https://codereview.chromium.org/11566037
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@173214 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'remoting')
-rwxr-xr-x | remoting/tools/me2me_virtual_host.py | 23 |
1 files changed, 17 insertions, 6 deletions
diff --git a/remoting/tools/me2me_virtual_host.py b/remoting/tools/me2me_virtual_host.py index 57688f2..da9bbf5 100755 --- a/remoting/tools/me2me_virtual_host.py +++ b/remoting/tools/me2me_virtual_host.py @@ -35,6 +35,16 @@ XSESSION_COMMAND = None LOG_FILE_ENV_VAR = "CHROME_REMOTE_DESKTOP_LOG_FILE" +# This script has a sensible default for the initial and maximum desktop size, +# which can be overridden either on the command-line, or via a comma-separated +# list of sizes in this environment variable. +DEFAULT_SIZES_ENV_VAR = "CHROME_REMOTE_DESKTOP_DEFAULT_DESKTOP_SIZES" + +# By default, provide a relatively small size to handle the case where resize- +# to-client is disabled, and a much larger size to support clients with large +# or mulitple monitors. These defaults can be overridden in ~/.profile. +DEFAULT_SIZES = "1600x1200,3840x1600" + SCRIPT_PATH = sys.path[0] DEFAULT_INSTALL_PATH = "/opt/google/chrome-remote-desktop" @@ -748,7 +758,6 @@ def waitpid_handle_exceptions(pid, deadline): def main(): - 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""" @@ -756,10 +765,9 @@ Web Store: https://chrome.google.com/remotedesktop""" usage="Usage: %prog [options] [ -- [ X server options ] ]", epilog=EPILOG) parser.add_option("-s", "--size", dest="size", action="append", - help="Dimensions of virtual desktop (default: %s). " - "This can be specified multiple times to make multiple " - "screen resolutions available (if the Xvfb server " - "supports this)" % DEFAULT_SIZE) + help="Dimensions of virtual desktop. This can be specified " + "multiple times to make multiple screen resolutions " + "available (if the Xvfb server supports this).") parser.add_option("-f", "--foreground", dest="foreground", default=False, action="store_true", help="Don't run as a background daemon.") @@ -833,7 +841,10 @@ Web Store: https://chrome.google.com/remotedesktop""" # Collate the list of sizes that XRANDR should support. if not options.size: - options.size = [DEFAULT_SIZE] + default_sizes = DEFAULT_SIZES + if os.environ.has_key(DEFAULT_SIZES_ENV_VAR): + default_sizes = os.environ[DEFAULT_SIZES_ENV_VAR] + options.size = default_sizes.split(","); sizes = [] for size in options.size: |