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

Issue 1078563002: [Webapp Refactor] Clean up remoting.Clipboard. (Closed)

Created:
5 years, 8 months ago by kelvinp
Modified:
5 years, 8 months ago
Reviewers:
Jamie
CC:
chromium-reviews, dcheng, 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

[Webapp Refactor] Clean up remoting.Clipboard. Currently, remoting.Clipboard is exposed as a global, such that it can hook events across different files, e.g. remoting.js, client_plugin_impl.js, application.js This CL moves clean up the file by: 1. Only create an instance of the clipboard when a session is connected. This removes the startSession() method on the clipboard. 2. Hook all events (copy/paste/focus changes) from within remoting.clipboard, which eliminates the need to have a global and effectively makes all its methods private. 3. Style cleanups, use single quotes for strings, make sure private variables are post-fixed with underscores. BUG=475317 Committed: https://crrev.com/be79f477e4d1e66e2d80e7bcd5f9689f3fbbcefc Cr-Commit-Position: refs/heads/master@{#324354}

Patch Set 1 #

Total comments: 6

Patch Set 2 : Remove remoting.ClientSession.sendClipboardItem for real #

Unified diffs Side-by-side diffs Delta from patch set Stats (+114 lines, -135 lines) Patch
M remoting/webapp/base/js/application.js View 1 chunk +0 lines, -1 line 0 comments Download
M remoting/webapp/crd/js/client_plugin.js View 1 chunk +8 lines, -2 lines 0 comments Download
M remoting/webapp/crd/js/client_plugin_impl.js View 3 chunks +14 lines, -20 lines 0 comments Download
M remoting/webapp/crd/js/client_session.js View 1 1 chunk +0 lines, -12 lines 0 comments Download
M remoting/webapp/crd/js/clipboard.js View 1 8 chunks +90 lines, -56 lines 0 comments Download
M remoting/webapp/crd/js/connected_view.js View 2 chunks +2 lines, -11 lines 0 comments Download
M remoting/webapp/crd/js/remoting.js View 2 chunks +0 lines, -33 lines 0 comments Download

Messages

Total messages: 9 (3 generated)
kelvinp
PTAL https://codereview.chromium.org/1078563002/diff/1/remoting/webapp/base/js/application.js File remoting/webapp/base/js/application.js (left): https://codereview.chromium.org/1078563002/diff/1/remoting/webapp/base/js/application.js#oldcode162 remoting/webapp/base/js/application.js:162: remoting.clipboard.startSession(); The clipboard is now created in remoting.ConnectedView. ...
5 years, 8 months ago (2015-04-09 00:28:26 UTC) #2
Jamie
Nice cleanup! LGTM
5 years, 8 months ago (2015-04-09 00:35:20 UTC) #3
kelvinp
You are welcome. Thank you for the quick turn around. FYI
5 years, 8 months ago (2015-04-09 01:09:32 UTC) #4
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/patch-status/1078563002/20001
5 years, 8 months ago (2015-04-09 01:11:00 UTC) #7
commit-bot: I haz the power
Committed patchset #2 (id:20001)
5 years, 8 months ago (2015-04-09 03:47:06 UTC) #8
commit-bot: I haz the power
5 years, 8 months ago (2015-04-09 03:48:04 UTC) #9
Message was sent while issue was closed.
Patchset 2 (id:??) landed as
https://crrev.com/be79f477e4d1e66e2d80e7bcd5f9689f3fbbcefc
Cr-Commit-Position: refs/heads/master@{#324354}

Powered by Google App Engine
This is Rietveld 408576698