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

Unified Diff: chrome/browser/views/first_run_bubble.cc

Issue 55019: Fix for focus issue in first run bubble (Closed) Base URL: svn://chrome-svn/chrome/trunk/src/
Patch Set: Created 11 years, 9 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 | « no previous file | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: chrome/browser/views/first_run_bubble.cc
===================================================================
--- chrome/browser/views/first_run_bubble.cc (revision 12500)
+++ chrome/browser/views/first_run_bubble.cc (working copy)
@@ -99,6 +99,10 @@
AddChildView(change_button_);
}
+ void BubbleShown() {
+ keep_button_->RequestFocus();
+ }
+
// Overridden from ButtonListener.
virtual void ButtonPressed(views::Button* sender) {
bubble_window_->Close();
@@ -153,11 +157,6 @@
pref_size.width(), pref_size.height());
}
- virtual void ViewHierarchyChanged(bool is_add, View* parent, View* child) {
- if (keep_button_)
- keep_button_->RequestFocus();
- }
-
// Overridden from views::View.
virtual gfx::Size GetPreferredSize() {
return gfx::Size(views::Window::GetLocalizedContentsSize(
@@ -237,6 +236,7 @@
views::FocusManager* focus_manager =
views::FocusManager::GetFocusManager(window->GetNativeView());
focus_manager->AddFocusChangeListener(view);
+ view->BubbleShown();
return window;
}
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698