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

Side by Side Diff: chrome/browser/ui/views/options/options_window_view.cc

Issue 6192007: Remove wstring from views. Part 3: Switch accessibility strings to string16.... (Closed) Base URL: svn://chrome-svn/chrome/trunk/src/
Patch Set: '' Created 9 years, 11 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
OLDNEW
1 // Copyright (c) 2010 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2010 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 "app/l10n_util.h" 5 #include "app/l10n_util.h"
6 #include "base/utf_string_conversions.h" 6 #include "base/utf_string_conversions.h"
7 #include "chrome/browser/browser_process.h" 7 #include "chrome/browser/browser_process.h"
8 #include "chrome/browser/prefs/pref_service.h" 8 #include "chrome/browser/prefs/pref_service.h"
9 #include "chrome/browser/profiles/profile.h" 9 #include "chrome/browser/profiles/profile.h"
10 #include "chrome/browser/ui/browser_list.h" 10 #include "chrome/browser/ui/browser_list.h"
(...skipping 179 matching lines...) Expand 10 before | Expand all | Expand 10 after
190 // HWND to parent native child controls to. 190 // HWND to parent native child controls to.
191 if (is_add && child == this) 191 if (is_add && child == this)
192 Init(); 192 Init();
193 } 193 }
194 194
195 /////////////////////////////////////////////////////////////////////////////// 195 ///////////////////////////////////////////////////////////////////////////////
196 // OptionsWindowView, private: 196 // OptionsWindowView, private:
197 197
198 void OptionsWindowView::Init() { 198 void OptionsWindowView::Init() {
199 tabs_ = new views::TabbedPane; 199 tabs_ = new views::TabbedPane;
200 tabs_->SetAccessibleName(UTF16ToWide( 200 tabs_->SetAccessibleName(l10n_util::GetStringFUTF16(
201 l10n_util::GetStringFUTF16(IDS_OPTIONS_DIALOG_TITLE, 201 IDS_OPTIONS_DIALOG_TITLE,
202 l10n_util::GetStringUTF16(IDS_PRODUCT_NAME)))); 202 l10n_util::GetStringUTF16(IDS_PRODUCT_NAME)));
203 tabs_->SetListener(this); 203 tabs_->SetListener(this);
204 AddChildView(tabs_); 204 AddChildView(tabs_);
205 205
206 int tab_index = 0; 206 int tab_index = 0;
207 GeneralPageView* general_page = new GeneralPageView(profile_); 207 GeneralPageView* general_page = new GeneralPageView(profile_);
208 tabs_->AddTabAtIndex( 208 tabs_->AddTabAtIndex(
209 tab_index++, 209 tab_index++,
210 UTF16ToWide(l10n_util::GetStringUTF16(IDS_OPTIONS_GENERAL_TAB_LABEL)), 210 UTF16ToWide(l10n_util::GetStringUTF16(IDS_OPTIONS_GENERAL_TAB_LABEL)),
211 general_page, false); 211 general_page, false);
212 212
(...skipping 26 matching lines...) Expand all
239 // If there's already an existing options window, activate it and switch to 239 // If there's already an existing options window, activate it and switch to
240 // the specified page. 240 // the specified page.
241 // TODO(beng): note this is not multi-simultaneous-profile-safe. When we care 241 // TODO(beng): note this is not multi-simultaneous-profile-safe. When we care
242 // about this case this will have to be fixed. 242 // about this case this will have to be fixed.
243 if (!instance_) { 243 if (!instance_) {
244 instance_ = new OptionsWindowView(profile); 244 instance_ = new OptionsWindowView(profile);
245 views::Window::CreateChromeWindow(NULL, gfx::Rect(), instance_); 245 views::Window::CreateChromeWindow(NULL, gfx::Rect(), instance_);
246 } 246 }
247 instance_->ShowOptionsPage(page, highlight_group); 247 instance_->ShowOptionsPage(page, highlight_group);
248 } 248 }
OLDNEW
« no previous file with comments | « chrome/browser/ui/views/options/options_group_view.cc ('k') | chrome/browser/ui/views/tabs/base_tab.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698