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

Issue 10916214: Try 2 - Change how ui::Clipboard is accessed so there's only one per thread. (Closed)

Created:
8 years, 3 months ago by Elliot Glaysher
Modified:
8 years, 3 months ago
Reviewers:
tony, jam, dcheng, tc, Ben, kaiwang
CC:
chromium-reviews, sadrul, yusukes+watch_chromium.org, amit, browser-components-watch_chromium.org, dcheng, dmazzoni+watch_chromium.org, ajwong+watch_chromium.org, ben+watch_chromium.org, aboxhall+watch_chromium.org, grt+watch_chromium.org, joi+watch-content_chromium.org, darin-cc_chromium.org, Avi (use Gerrit), creis+watch_chromium.org, yoshiki+watch_chromium.org, penghuang+watch_chromium.org, yuzo+watch_chromium.org, pam+watch_chromium.org, ctguil+watch_chromium.org, zork+watch_chromium.org, hashimoto+watch_chromium.org, tfarina, davidbarr+watch_chromium.org, robertshield, dtseng+watch_chromium.org, James Su
Visibility:
Public.

Description

Try 2 - Change how ui::Clipboard is accessed so there's only one per thread. Currently, there can be any number of Clipboard objects, which can be massively simplified. This removes interfaces for fetching the Clipboard and makes everyone go through a single static ui::Clipboard::GetForCurrentThread() access point. [Differences from the first patch: this may fix the pdf tests, but since I have no way to run them locally or on a trybot, this is going in blind.] BUG=130805 R=jam@chromium.org TBR=tc,ben,dcheng,kaiwang First Review URL: https://chromiumcodereview.appspot.com/10911074 Committed: https://src.chromium.org/viewvc/chrome?view=rev&revision=156027

Patch Set 1 #

Total comments: 6

Patch Set 2 : Rebase to ToT #

Patch Set 3 : Make Clipboard aware of which threads it can run on. #

Patch Set 4 : Add header. #

Patch Set 5 : Fix compile on windows like platforms. #

Patch Set 6 : Windows STL requires <iterator> #

Total comments: 1

Patch Set 7 : Moved to BrowserThreadsStarted #

Unified diffs Side-by-side diffs Delta from patch set Stats (+274 lines, -300 lines) Patch
M ash/drag_drop/drag_drop_controller_unittest.cc View 1 chunk +1 line, -1 line 0 comments Download
M chrome/browser/bookmarks/bookmark_node_data.cc View 4 chunks +3 lines, -5 lines 0 comments Download
M chrome/browser/bookmarks/bookmark_utils_unittest.cc View 2 chunks +3 lines, -6 lines 0 comments Download
M chrome/browser/browser_process.h View 2 chunks +0 lines, -5 lines 0 comments Download
M chrome/browser/browser_process_impl.h View 2 chunks +0 lines, -3 lines 0 comments Download
M chrome/browser/browser_process_impl.cc View 3 chunks +0 lines, -7 lines 0 comments Download
M chrome/browser/tab_contents/render_view_context_menu.cc View 2 chunks +2 lines, -1 line 0 comments Download
M chrome/browser/ui/omnibox/omnibox_view.cc View 2 chunks +1 line, -2 lines 0 comments Download
M chrome/browser/ui/omnibox/omnibox_view_unittest.cc View 7 chunks +9 lines, -9 lines 0 comments Download
M chrome/browser/ui/pdf/pdf_browsertest.cc View 1 chunk +3 lines, -4 lines 0 comments Download
M chrome/browser/ui/views/accessibility/accessibility_event_router_views_unittest.cc View 1 chunk +0 lines, -1 line 0 comments Download
M chrome/browser/ui/views/bookmarks/bookmark_bar_view_test.cc View 1 chunk +0 lines, -1 line 0 comments Download
M chrome/browser/ui/views/chrome_views_delegate.h View 1 chunk +0 lines, -1 line 0 comments Download
M chrome/browser/ui/views/chrome_views_delegate.cc View 2 chunks +0 lines, -5 lines 0 comments Download
M chrome/browser/ui/views/find_bar_host_interactive_uitest.cc View 1 chunk +1 line, -1 line 0 comments Download
M chrome/browser/ui/views/menu_model_adapter_test.cc View 1 chunk +0 lines, -4 lines 0 comments Download
M chrome/browser/ui/views/omnibox/omnibox_view_views.cc View 1 chunk +1 line, -1 line 0 comments Download
M chrome/browser/ui/views/omnibox/omnibox_view_win.cc View 2 chunks +1 line, -2 lines 0 comments Download
M chrome/test/base/testing_browser_process.h View 3 chunks +0 lines, -6 lines 0 comments Download
M chrome/test/base/testing_browser_process.cc View 2 chunks +0 lines, -9 lines 0 comments Download
M chrome_frame/test/chrome_frame_test_utils.cc View 1 chunk +6 lines, -8 lines 0 comments Download
M content/browser/browser_main_loop.cc View 1 2 3 4 5 6 3 chunks +14 lines, -0 lines 0 comments Download
M content/browser/renderer_host/clipboard_message_filter.cc View 1 2 3 4 2 chunks +2 lines, -3 lines 0 comments Download
M content/shell/shell_aura.cc View 2 chunks +0 lines, -8 lines 0 comments Download
M ui/base/clipboard/clipboard.h View 1 2 3 4 chunks +22 lines, -2 lines 0 comments Download
M ui/base/clipboard/clipboard.cc View 1 2 3 4 5 3 chunks +72 lines, -0 lines 0 comments Download
M ui/base/clipboard/clipboard_unittest.cc View 24 chunks +111 lines, -152 lines 0 comments Download
M ui/views/controls/message_box_view.cc View 2 chunks +1 line, -5 lines 0 comments Download
M ui/views/controls/textfield/native_textfield_views.cc View 2 chunks +2 lines, -3 lines 0 comments Download
M ui/views/controls/textfield/native_textfield_views_unittest.cc View 3 chunks +3 lines, -4 lines 0 comments Download
M ui/views/controls/textfield/native_textfield_win.cc View 3 chunks +4 lines, -5 lines 0 comments Download
M ui/views/controls/textfield/textfield_views_model.cc View 4 chunks +3 lines, -4 lines 0 comments Download
M ui/views/controls/textfield/textfield_views_model_unittest.cc View 2 chunks +1 line, -2 lines 0 comments Download
M ui/views/test/test_views_delegate.h View 2 chunks +0 lines, -2 lines 0 comments Download
M ui/views/test/test_views_delegate.cc View 2 chunks +0 lines, -9 lines 0 comments Download
M ui/views/view_unittest.cc View 6 chunks +7 lines, -9 lines 0 comments Download
M ui/views/views_delegate.h View 2 chunks +0 lines, -7 lines 0 comments Download
M webkit/tools/test_shell/simple_clipboard_impl.cc View 2 chunks +1 line, -3 lines 0 comments Download

Messages

Total messages: 11 (0 generated)
Elliot Glaysher
John, since you have access to the pdf renderer, could you please test this? I ...
8 years, 3 months ago (2012-09-10 17:52:41 UTC) #1
tony
It seems like it will now be easy to accidentally call ui::Clipboard::GetForCurrentThread() on the wrong ...
8 years, 3 months ago (2012-09-10 18:15:14 UTC) #2
Elliot Glaysher
Part of the motivation here was also simplifying the views interface; any user could subvert ...
8 years, 3 months ago (2012-09-10 18:29:31 UTC) #3
tony
On 2012/09/10 18:29:31, Elliot Glaysher wrote: > Part of the motivation here was also simplifying ...
8 years, 3 months ago (2012-09-10 18:44:40 UTC) #4
jam
i'll verify the pdf code after commit
8 years, 3 months ago (2012-09-10 19:09:37 UTC) #5
Elliot Glaysher
I disagree that having a virtual method hanging off the BrowserProcess global interface, which only ...
8 years, 3 months ago (2012-09-10 20:10:21 UTC) #6
tony
On 2012/09/10 20:10:21, Elliot Glaysher wrote: > How about this instead? I've modified Clipboard so ...
8 years, 3 months ago (2012-09-10 20:20:06 UTC) #7
jam
lgtm
8 years, 3 months ago (2012-09-10 22:41:56 UTC) #8
jam
https://codereview.chromium.org/10916214/diff/12005/content/browser/browser_main_loop.cc File content/browser/browser_main_loop.cc (right): https://codereview.chromium.org/10916214/diff/12005/content/browser/browser_main_loop.cc#newcode478 content/browser/browser_main_loop.cc:478: // Alert the clipboard class to which threads are ...
8 years, 3 months ago (2012-09-10 22:44:18 UTC) #9
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-status.appspot.com/cq/erg@chromium.org/10916214/15001
8 years, 3 months ago (2012-09-10 23:11:22 UTC) #10
commit-bot: I haz the power
8 years, 3 months ago (2012-09-11 01:10:24 UTC) #11
Try job failure for 10916214-15001 (retry) (retry) on win for step "compile"
(clobber build).
It's a second try, previously, step "compile" failed.
http://build.chromium.org/p/tryserver.chromium/buildstatus?builder=win&number...

Powered by Google App Engine
This is Rietveld 408576698