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

Issue 804783002: Improve DPI matching & scaling logic. (Closed)

Created:
6 years ago by Wez
Modified:
5 years, 10 months ago
CC:
chromium-reviews, chromoting-reviews_chromium.org
Base URL:
https://chromium.googlesource.com/chromium/src.git@master
Target Ref:
refs/pending/heads/master
Project:
chromium
Visibility:
Public.

Description

Improve DPI matching & scaling logic. Previously the client would attempt to scale the host desktop to account for the difference between client & host DPI. This could produce poor results in situations in which the client could not control the host dimensions, e.g. if the host was fixed at a very low resolution, but being displayed on a high-resolution display with the same notional DPI then lots of space would be wasted. This CL implements a new scheme, described in the comment block in remoting.ClientSession.updateDimensions(), that allows for more flexible up-scaling of very small hosts, and better handling of close-to-integer scale factors. BUG=135089, 366359 Committed: https://crrev.com/301d65d865ed85c01f8243565f3f76b232f3953f Cr-Commit-Position: refs/heads/master@{#316353}

Patch Set 1 #

Patch Set 2 : Rebase #

Patch Set 3 : Reinstate basic DPI matching and snap-to-integer-scale #

Patch Set 4 : Improve comments #

Total comments: 4

Patch Set 5 : Unit-tests! #

Total comments: 18

Patch Set 6 : Address review comments #

Patch Set 7 : Update non-shrink-to-fit tests #

Total comments: 17

Patch Set 8 : Address review comments #

Patch Set 9 : Fix multi-monitor specialization & update tests #

Total comments: 8

Patch Set 10 : Address review comments #

Patch Set 11 : Rebase #

Unified diffs Side-by-side diffs Delta from patch set Stats (+445 lines, -51 lines) Patch
M remoting/remoting_webapp_files.gypi View 1 2 3 4 5 6 7 8 9 10 1 chunk +1 line, -0 lines 0 comments Download
M remoting/webapp/crd/js/desktop_connected_view.js View 1 2 3 4 5 6 7 8 9 10 2 chunks +125 lines, -51 lines 0 comments Download
A remoting/webapp/unittests/desktop_connected_view_unittest.js View 1 2 3 4 5 6 7 8 9 10 1 chunk +319 lines, -0 lines 0 comments Download

Messages

Total messages: 29 (4 generated)
Wez
Rebase
5 years, 11 months ago (2015-01-08 22:02:51 UTC) #1
Wez
Reinstate basic DPI matching and snap-to-integer-scale
5 years, 11 months ago (2015-01-09 02:33:14 UTC) #2
Wez
Improve comments
5 years, 11 months ago (2015-01-09 20:18:59 UTC) #3
Wez
PTAL For unit-testing purposes I think it'd be best to pull this logic out into ...
5 years, 11 months ago (2015-01-09 20:25:04 UTC) #5
Jamie
I would either create a new file containing just the function you want to test, ...
5 years, 11 months ago (2015-01-09 22:23:47 UTC) #6
Wez
PTAL; this patch-set adds some unit-tests. It's currently missing some tests for the close-to-integer-scale-factor case ...
5 years, 10 months ago (2015-02-04 01:55:14 UTC) #7
Sergey Ulanov
This doesn't solve the problem for the scenario I described in crbug.com/454618
5 years, 10 months ago (2015-02-04 20:43:06 UTC) #9
Jamie
https://codereview.chromium.org/804783002/diff/80001/remoting/webapp/crd/js/client_session.js File remoting/webapp/crd/js/client_session.js (right): https://codereview.chromium.org/804783002/diff/80001/remoting/webapp/crd/js/client_session.js#newcode1295 remoting/webapp/crd/js/client_session.js:1295: isFullscreen, shrinkToFit) { Maybe assert that any value used ...
5 years, 10 months ago (2015-02-04 23:18:30 UTC) #10
Sergey Ulanov
https://codereview.chromium.org/804783002/diff/80001/remoting/webapp/crd/js/client_session.js File remoting/webapp/crd/js/client_session.js (right): https://codereview.chromium.org/804783002/diff/80001/remoting/webapp/crd/js/client_session.js#newcode1301 remoting/webapp/crd/js/client_session.js:1301: // small. I think another goal here should also ...
5 years, 10 months ago (2015-02-04 23:57:41 UTC) #11
Wez
PTAL Sergey, the 150% DPI host to high-DPI client case you described in crbug.com/454618 is ...
5 years, 10 months ago (2015-02-06 01:29:43 UTC) #12
Sergey Ulanov
On 2015/02/06 01:29:43, Wez wrote: > PTAL > > Sergey, the 150% DPI host to ...
5 years, 10 months ago (2015-02-06 01:56:55 UTC) #13
Sergey Ulanov
On 2015/02/06 01:56:55, Sergey Ulanov wrote: > On 2015/02/06 01:29:43, Wez wrote: > > PTAL ...
5 years, 10 months ago (2015-02-06 02:55:19 UTC) #14
Wez
On 2015/02/06 02:55:19, Sergey Ulanov wrote: > On 2015/02/06 01:56:55, Sergey Ulanov wrote: > > ...
5 years, 10 months ago (2015-02-06 20:06:06 UTC) #15
Jamie
I'd like clarification on what the output of the function represents before reviewing the rest ...
5 years, 10 months ago (2015-02-06 23:06:02 UTC) #16
Wez
PTAL https://codereview.chromium.org/804783002/diff/120001/remoting/webapp/crd/js/client_session.js File remoting/webapp/crd/js/client_session.js (right): https://codereview.chromium.org/804783002/diff/120001/remoting/webapp/crd/js/client_session.js#newcode1261 remoting/webapp/crd/js/client_session.js:1261: // Position the container. On 2015/02/06 23:06:02, Jamie ...
5 years, 10 months ago (2015-02-09 21:32:28 UTC) #17
Wez
https://codereview.chromium.org/804783002/diff/120001/remoting/webapp/crd/js/client_session.js File remoting/webapp/crd/js/client_session.js (right): https://codereview.chromium.org/804783002/diff/120001/remoting/webapp/crd/js/client_session.js#newcode1371 remoting/webapp/crd/js/client_session.js:1371: // multi-monitor combinations more intelligently. On 2015/02/09 21:32:28, Wez ...
5 years, 10 months ago (2015-02-09 21:51:45 UTC) #18
Jamie
https://codereview.chromium.org/804783002/diff/120001/remoting/webapp/crd/js/client_session.js File remoting/webapp/crd/js/client_session.js (right): https://codereview.chromium.org/804783002/diff/120001/remoting/webapp/crd/js/client_session.js#newcode1367 remoting/webapp/crd/js/client_session.js:1367: scale = Math.min(scaleFitHeight, scaleFitWidth); On 2015/02/09 21:32:28, Wez wrote: ...
5 years, 10 months ago (2015-02-09 23:52:35 UTC) #19
kelvinp
https://codereview.chromium.org/804783002/diff/160001/remoting/remoting_webapp_files.gypi File remoting/remoting_webapp_files.gypi (right): https://codereview.chromium.org/804783002/diff/160001/remoting/remoting_webapp_files.gypi#newcode181 remoting/remoting_webapp_files.gypi:181: 'webapp/unittests/client_session_unittest.js', FYI that gary and I are working on ...
5 years, 10 months ago (2015-02-12 22:47:04 UTC) #21
Wez
On 2015/02/12 22:47:04, kelvinp wrote: > https://codereview.chromium.org/804783002/diff/160001/remoting/remoting_webapp_files.gypi > File remoting/remoting_webapp_files.gypi (right): > > https://codereview.chromium.org/804783002/diff/160001/remoting/remoting_webapp_files.gypi#newcode181 > ...
5 years, 10 months ago (2015-02-13 03:48:53 UTC) #22
Wez
Sorry; had to rebase this... https://codereview.chromium.org/804783002/diff/120001/remoting/webapp/crd/js/client_session.js File remoting/webapp/crd/js/client_session.js (right): https://codereview.chromium.org/804783002/diff/120001/remoting/webapp/crd/js/client_session.js#newcode1367 remoting/webapp/crd/js/client_session.js:1367: scale = Math.min(scaleFitHeight, scaleFitWidth); ...
5 years, 10 months ago (2015-02-13 18:59:08 UTC) #23
Wez
On 2015/02/13 18:59:08, Wez wrote: > Sorry; had to rebase this... > > https://codereview.chromium.org/804783002/diff/120001/remoting/webapp/crd/js/client_session.js > ...
5 years, 10 months ago (2015-02-14 00:49:37 UTC) #24
Jamie
lgtm
5 years, 10 months ago (2015-02-14 01:12:11 UTC) #25
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/patch-status/804783002/200001
5 years, 10 months ago (2015-02-14 01:31:26 UTC) #27
commit-bot: I haz the power
Committed patchset #11 (id:200001)
5 years, 10 months ago (2015-02-14 01:39:15 UTC) #28
commit-bot: I haz the power
5 years, 10 months ago (2015-02-14 01:40:00 UTC) #29
Message was sent while issue was closed.
Patchset 11 (id:??) landed as
https://crrev.com/301d65d865ed85c01f8243565f3f76b232f3953f
Cr-Commit-Position: refs/heads/master@{#316353}

Powered by Google App Engine
This is Rietveld 408576698