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

Unified Diff: ui/views/controls/message_box_view.cc

Issue 10911074: Change how ui::Clipboard is accessed so there's only one per thread. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Fixes for kaiwang 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
« no previous file with comments | « ui/base/clipboard/clipboard_unittest.cc ('k') | ui/views/controls/textfield/native_textfield_views.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: ui/views/controls/message_box_view.cc
diff --git a/ui/views/controls/message_box_view.cc b/ui/views/controls/message_box_view.cc
index 960b3161b8a09d0e1b4068725635a66df7fb099d..5d5e909f4fe7c42d874b22fd80017be691e0f766 100644
--- a/ui/views/controls/message_box_view.cc
+++ b/ui/views/controls/message_box_view.cc
@@ -17,7 +17,6 @@
#include "ui/views/controls/textfield/textfield.h"
#include "ui/views/layout/grid_layout.h"
#include "ui/views/layout/layout_constants.h"
-#include "ui/views/views_delegate.h"
#include "ui/views/widget/widget.h"
#include "ui/views/window/client_view.h"
@@ -140,10 +139,7 @@ bool MessageBoxView::AcceleratorPressed(const ui::Accelerator& accelerator) {
if (prompt_field_ && prompt_field_->HasFocus())
return false;
- if (!ViewsDelegate::views_delegate)
- return false;
-
- ui::Clipboard* clipboard = ViewsDelegate::views_delegate->GetClipboard();
+ ui::Clipboard* clipboard = ui::Clipboard::GetForCurrentThread();
if (!clipboard)
return false;
« no previous file with comments | « ui/base/clipboard/clipboard_unittest.cc ('k') | ui/views/controls/textfield/native_textfield_views.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698