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

Side by Side Diff: chrome/browser/views/new_profile_dialog.cc

Issue 21439: Fix for focus traversal issue in Gears dialogs (Closed) Base URL: svn://chrome-svn/chrome/trunk/src/
Patch Set: '' Created 11 years, 10 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 unified diff | Download patch | Annotate | Revision Log
« no previous file with comments | « chrome/browser/views/new_profile_dialog.h ('k') | chrome/browser/views/options/cookies_view.h » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright (c) 2006-2008 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2006-2008 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #include "chrome/browser/views/new_profile_dialog.h" 5 #include "chrome/browser/views/new_profile_dialog.h"
6 6
7 #include <string> 7 #include <string>
8 8
9 #include "base/logging.h" 9 #include "base/logging.h"
10 #include "base/file_util.h" 10 #include "base/file_util.h"
(...skipping 32 matching lines...) Expand 10 before | Expand all | Expand 10 after
43 message_box_view_->text_box()->SetController(this); 43 message_box_view_->text_box()->SetController(this);
44 } 44 }
45 45
46 NewProfileDialog::~NewProfileDialog() { 46 NewProfileDialog::~NewProfileDialog() {
47 } 47 }
48 48
49 int NewProfileDialog::GetDialogButtons() const { 49 int NewProfileDialog::GetDialogButtons() const {
50 return DIALOGBUTTON_OK | DIALOGBUTTON_CANCEL; 50 return DIALOGBUTTON_OK | DIALOGBUTTON_CANCEL;
51 } 51 }
52 52
53 views::View* NewProfileDialog::GetInitiallyFocusedView() const { 53 views::View* NewProfileDialog::GetInitiallyFocusedView() {
54 views::TextField* text_box = message_box_view_->text_box(); 54 views::TextField* text_box = message_box_view_->text_box();
55 DCHECK(text_box); 55 DCHECK(text_box);
56 return text_box; 56 return text_box;
57 } 57 }
58 58
59 bool NewProfileDialog::IsDialogButtonEnabled( 59 bool NewProfileDialog::IsDialogButtonEnabled(
60 DialogButton button) const { 60 DialogButton button) const {
61 if (button == DIALOGBUTTON_OK) { 61 if (button == DIALOGBUTTON_OK) {
62 std::wstring profile_name = message_box_view_->GetInputText(); 62 std::wstring profile_name = message_box_view_->GetInputText();
63 // TODO(munjal): Refactor the function ReplaceIllegalCharacters in 63 // TODO(munjal): Refactor the function ReplaceIllegalCharacters in
(...skipping 32 matching lines...) Expand 10 before | Expand all | Expand 10 after
96 UserDataManager::Get()->CreateDesktopShortcutForProfile( 96 UserDataManager::Get()->CreateDesktopShortcutForProfile(
97 profile_name); 97 profile_name);
98 98
99 UserDataManager::Get()->LaunchChromeForProfile(profile_name); 99 UserDataManager::Get()->LaunchChromeForProfile(profile_name);
100 return true; 100 return true;
101 } 101 }
102 102
103 views::View* NewProfileDialog::GetContentsView() { 103 views::View* NewProfileDialog::GetContentsView() {
104 return message_box_view_; 104 return message_box_view_;
105 } 105 }
OLDNEW
« no previous file with comments | « chrome/browser/views/new_profile_dialog.h ('k') | chrome/browser/views/options/cookies_view.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698