diff options
25 files changed, 305 insertions, 307 deletions
diff --git a/chrome/app/chrome_dll.rc b/chrome/app/chrome_dll.rc index 0c0a564..da31f89 100644 --- a/chrome/app/chrome_dll.rc +++ b/chrome/app/chrome_dll.rc @@ -34,15 +34,15 @@ IDR_MAINFRAME ACCELERATORS BEGIN VK_LEFT, IDC_BACK, VIRTKEY, ALT VK_BACK, IDC_BACK, VIRTKEY - VK_F4, IDC_CLOSETAB, VIRTKEY, CONTROL - "W", IDC_CLOSETAB, VIRTKEY, CONTROL - "W", IDC_CLOSEPOPUPS, VIRTKEY, SHIFT, ALT - "L", IDC_DEBUGGER, VIRTKEY, SHIFT, CONTROL - "J", IDC_SHOW_JS_CONSOLE,VIRTKEY, SHIFT, CONTROL + VK_F4, IDC_CLOSE_TAB, VIRTKEY, CONTROL + "W", IDC_CLOSE_TAB, VIRTKEY, CONTROL + "W", IDC_CLOSE_POPUPS, VIRTKEY, SHIFT, ALT + "L", IDC_DEBUGGER, VIRTKEY, CONTROL, SHIFT + "J", IDC_JS_CONSOLE, VIRTKEY, CONTROL, SHIFT "F", IDC_FIND, VIRTKEY, CONTROL "G", IDC_FIND_NEXT, VIRTKEY, CONTROL VK_F3, IDC_FIND_NEXT, VIRTKEY - "G", IDC_FIND_PREVIOUS, VIRTKEY, SHIFT, CONTROL + "G", IDC_FIND_PREVIOUS, VIRTKEY, CONTROL, SHIFT VK_F3, IDC_FIND_PREVIOUS, VIRTKEY, SHIFT VK_F6, IDC_FOCUS_LOCATION, VIRTKEY "D", IDC_FOCUS_LOCATION, VIRTKEY, ALT @@ -52,34 +52,34 @@ BEGIN "T", IDC_FOCUS_TOOLBAR, VIRTKEY, SHIFT, ALT VK_RIGHT, IDC_FORWARD, VIRTKEY, ALT VK_BACK, IDC_FORWARD, VIRTKEY, SHIFT - VK_F1, IDC_HELPMENU, VIRTKEY - "T", IDC_NEWTAB, VIRTKEY, CONTROL - "N", IDC_NEWWINDOW, VIRTKEY, CONTROL + VK_F1, IDC_HELP_PAGE, VIRTKEY + "T", IDC_NEW_TAB, VIRTKEY, CONTROL + "N", IDC_NEW_WINDOW, VIRTKEY, CONTROL // CTRL + M is used for opening the dialog to let the user select // a profile to open a new window. // CTRL + SHIFT + N (N = 1 to 9) is used to let the user open a new // window in profile 1 to profile 9 directly. - "M", IDC_NEWPROFILEWINDOW, VIRTKEY, CONTROL - "1", IDC_NEWPROFILEWINDOW_PROFILE1, VIRTKEY, CONTROL, SHIFT - VK_NUMPAD1, IDC_NEWPROFILEWINDOW_PROFILE1, VIRTKEY, CONTROL, SHIFT - "2", IDC_NEWPROFILEWINDOW_PROFILE2, VIRTKEY, CONTROL, SHIFT - VK_NUMPAD2, IDC_NEWPROFILEWINDOW_PROFILE2, VIRTKEY, CONTROL, SHIFT - "3", IDC_NEWPROFILEWINDOW_PROFILE3, VIRTKEY, CONTROL, SHIFT - VK_NUMPAD3, IDC_NEWPROFILEWINDOW_PROFILE3, VIRTKEY, CONTROL, SHIFT - "4", IDC_NEWPROFILEWINDOW_PROFILE4, VIRTKEY, CONTROL, SHIFT - VK_NUMPAD4, IDC_NEWPROFILEWINDOW_PROFILE4, VIRTKEY, CONTROL, SHIFT - "5", IDC_NEWPROFILEWINDOW_PROFILE5, VIRTKEY, CONTROL, SHIFT - VK_NUMPAD5, IDC_NEWPROFILEWINDOW_PROFILE5, VIRTKEY, CONTROL, SHIFT - "6", IDC_NEWPROFILEWINDOW_PROFILE6, VIRTKEY, CONTROL, SHIFT - VK_NUMPAD6, IDC_NEWPROFILEWINDOW_PROFILE6, VIRTKEY, CONTROL, SHIFT - "7", IDC_NEWPROFILEWINDOW_PROFILE7, VIRTKEY, CONTROL, SHIFT - VK_NUMPAD7, IDC_NEWPROFILEWINDOW_PROFILE7, VIRTKEY, CONTROL, SHIFT - "8", IDC_NEWPROFILEWINDOW_PROFILE8, VIRTKEY, CONTROL, SHIFT - VK_NUMPAD8, IDC_NEWPROFILEWINDOW_PROFILE8, VIRTKEY, CONTROL, SHIFT - "9", IDC_NEWPROFILEWINDOW_PROFILE9, VIRTKEY, CONTROL, SHIFT - VK_NUMPAD9, IDC_NEWPROFILEWINDOW_PROFILE9, VIRTKEY, CONTROL, SHIFT - "N", IDC_GOOFFTHERECORD, VIRTKEY, CONTROL, SHIFT - "O", IDC_OPENFILE, VIRTKEY, CONTROL + "M", IDC_SELECT_PROFILE, VIRTKEY, CONTROL + "1", IDC_NEW_WINDOW_PROFILE_0, VIRTKEY, CONTROL, SHIFT + VK_NUMPAD1, IDC_NEW_WINDOW_PROFILE_0, VIRTKEY, CONTROL, SHIFT + "2", IDC_NEW_WINDOW_PROFILE_1, VIRTKEY, CONTROL, SHIFT + VK_NUMPAD2, IDC_NEW_WINDOW_PROFILE_1, VIRTKEY, CONTROL, SHIFT + "3", IDC_NEW_WINDOW_PROFILE_2, VIRTKEY, CONTROL, SHIFT + VK_NUMPAD3, IDC_NEW_WINDOW_PROFILE_2, VIRTKEY, CONTROL, SHIFT + "4", IDC_NEW_WINDOW_PROFILE_3, VIRTKEY, CONTROL, SHIFT + VK_NUMPAD4, IDC_NEW_WINDOW_PROFILE_3, VIRTKEY, CONTROL, SHIFT + "5", IDC_NEW_WINDOW_PROFILE_4, VIRTKEY, CONTROL, SHIFT + VK_NUMPAD5, IDC_NEW_WINDOW_PROFILE_4, VIRTKEY, CONTROL, SHIFT + "6", IDC_NEW_WINDOW_PROFILE_5, VIRTKEY, CONTROL, SHIFT + VK_NUMPAD6, IDC_NEW_WINDOW_PROFILE_5, VIRTKEY, CONTROL, SHIFT + "7", IDC_NEW_WINDOW_PROFILE_6, VIRTKEY, CONTROL, SHIFT + VK_NUMPAD7, IDC_NEW_WINDOW_PROFILE_6, VIRTKEY, CONTROL, SHIFT + "8", IDC_NEW_WINDOW_PROFILE_7, VIRTKEY, CONTROL, SHIFT + VK_NUMPAD8, IDC_NEW_WINDOW_PROFILE_7, VIRTKEY, CONTROL, SHIFT + "9", IDC_NEW_WINDOW_PROFILE_8, VIRTKEY, CONTROL, SHIFT + VK_NUMPAD9, IDC_NEW_WINDOW_PROFILE_8, VIRTKEY, CONTROL, SHIFT + "N", IDC_NEW_INCOGNITO_WINDOW, VIRTKEY, CONTROL, SHIFT + "O", IDC_OPEN_FILE, VIRTKEY, CONTROL "P", IDC_PRINT, VIRTKEY, CONTROL "R", IDC_RELOAD, VIRTKEY, CONTROL VK_F5, IDC_RELOAD, VIRTKEY @@ -87,13 +87,13 @@ BEGIN VK_F5, IDC_RELOAD, VIRTKEY, SHIFT VK_HOME, IDC_HOME, VIRTKEY, ALT "T", IDC_RESTORE_TAB, VIRTKEY, CONTROL, SHIFT - "S", IDC_SAVEPAGE, VIRTKEY, CONTROL + "S", IDC_SAVE_PAGE, VIRTKEY, CONTROL "9", IDC_SELECT_LAST_TAB,VIRTKEY, CONTROL VK_NUMPAD9, IDC_SELECT_LAST_TAB,VIRTKEY, CONTROL VK_TAB, IDC_SELECT_NEXT_TAB,VIRTKEY, CONTROL VK_NEXT, IDC_SELECT_NEXT_TAB,VIRTKEY, CONTROL - VK_TAB, IDC_SELECT_PREV_TAB,VIRTKEY, SHIFT, CONTROL - VK_PRIOR, IDC_SELECT_PREV_TAB,VIRTKEY, CONTROL + VK_TAB, IDC_SELECT_PREVIOUS_TAB, VIRTKEY, CONTROL, SHIFT + VK_PRIOR, IDC_SELECT_PREVIOUS_TAB, VIRTKEY, CONTROL // NOTE: IDC_SELECT_TAB_N is bound to the key N+1, and selects the tab at // index N. For example, IDC_SELECT_TAB_0 is bound to control 1, and selects // the tab at index 0. @@ -113,14 +113,14 @@ BEGIN VK_NUMPAD7, IDC_SELECT_TAB_6, VIRTKEY, CONTROL "8", IDC_SELECT_TAB_7, VIRTKEY, CONTROL VK_NUMPAD8, IDC_SELECT_TAB_7, VIRTKEY, CONTROL - "B", IDC_SHOW_BOOKMARKS_BAR, VIRTKEY, CONTROL + "B", IDC_SHOW_BOOKMARK_BAR, VIRTKEY, CONTROL "B", IDC_SHOW_BOOKMARK_MANAGER, VIRTKEY, CONTROL, SHIFT "J", IDC_SHOW_DOWNLOADS, VIRTKEY, CONTROL "H", IDC_SHOW_HISTORY, VIRTKEY, CONTROL "D", IDC_STAR, VIRTKEY, CONTROL VK_ESCAPE, IDC_STOP, VIRTKEY - VK_ESCAPE, IDC_TASKMANAGER, VIRTKEY, SHIFT - "U", IDC_VIEWSOURCE, VIRTKEY, CONTROL + VK_ESCAPE, IDC_TASK_MANAGER, VIRTKEY, SHIFT + "U", IDC_VIEW_SOURCE, VIRTKEY, CONTROL VK_OEM_MINUS, IDC_ZOOM_MINUS, VIRTKEY, CONTROL VK_OEM_MINUS, IDC_ZOOM_MINUS, VIRTKEY, CONTROL, SHIFT VK_SUBTRACT, IDC_ZOOM_MINUS, VIRTKEY, CONTROL @@ -180,7 +180,7 @@ IDR_MAINFRAME ICON "theme\chromium\chromium.ico" // Bitmap // -IDR_CRASHED_PLUGIN BINDATA "resources\\sadplugin.png" +IDR_SAD_PLUGIN BINDATA "resources\\sadplugin.png" ///////////////////////////////////////////////////////////////////////////// // diff --git a/chrome/app/chrome_dll_resource.h b/chrome/app/chrome_dll_resource.h index 7b57ade..d040e6d 100644 --- a/chrome/app/chrome_dll_resource.h +++ b/chrome/app/chrome_dll_resource.h @@ -33,25 +33,25 @@ #define IDC_STOP 32770 #define IDC_RELOAD 32771 #define IDC_GO 32772 -#define IDC_NEWTAB 32773 -#define IDC_CLOSETAB 32774 -#define IDC_NEWWINDOW 32775 -#define IDC_CLOSEWINDOW 32776 +#define IDC_NEW_TAB 32773 +#define IDC_CLOSE_TAB 32774 +#define IDC_NEW_WINDOW 32775 +#define IDC_CLOSE_WINDOW 32776 #define IDC_FOCUS_LOCATION 32777 #define IDC_FOCUS_SEARCH 32778 #define IDC_STAR 32779 -#define IDC_OPENURL 32780 +#define IDC_OPEN_CURRENT_URL 32780 #define IDC_FIND 32781 #define IDC_FIND_NEXT 32782 #define IDC_FIND_PREVIOUS 32783 #define IDC_CUT 32784 #define IDC_COPY 32785 #define IDC_PASTE 32786 -#define IDC_SAVEPAGE 32787 +#define IDC_SAVE_PAGE 32787 #define IDC_PRINT 32788 -#define IDC_VIEWSOURCE 32789 +#define IDC_VIEW_SOURCE 32789 #define IDC_SELECT_NEXT_TAB 32790 -#define IDC_SELECT_PREV_TAB 32791 +#define IDC_SELECT_PREVIOUS_TAB 32791 #define IDC_SELECT_TAB_0 32792 #define IDC_SELECT_TAB_1 32793 #define IDC_SELECT_TAB_2 32794 @@ -61,7 +61,7 @@ #define IDC_SELECT_TAB_6 32798 #define IDC_SELECT_TAB_7 32799 #define IDC_SELECT_LAST_TAB 32800 -#define IDC_CREATE_SHORTCUT 32801 +#define IDC_CREATE_SHORTCUTS 32801 #define IDC_SHOWALLTABS_NEXT 32802 #define IDC_SHOWALLTABS_PREV 32803 #define IDC_SHOWALLTABS 32804 @@ -69,15 +69,15 @@ #define IDC_ZOOM_PLUS 32806 #define IDC_ZOOM_MINUS 32807 #define IDC_ZOOM_NORMAL 32808 -#define IDC_OPENFILE 32809 -#define IDC_ZOOM 32810 -#define IDC_TASKMANAGER 32812 -#define IDC_CLOSEPOPUPS 32813 +#define IDC_OPEN_FILE 32809 +#define IDC_ZOOM_MENU 32810 +#define IDC_TASK_MANAGER 32812 +#define IDC_CLOSE_POPUPS 32813 #define IDC_ALWAYS_ON_TOP 32814 #define IDC_COPY_URL 32815 -#define IDC_SHOW_JS_CONSOLE 32816 -#define IDC_DUPLICATE 32817 -#define IDC_GOOFFTHERECORD 32818 +#define IDC_JS_CONSOLE 32816 +#define IDC_DUPLICATE_TAB 32817 +#define IDC_NEW_INCOGNITO_WINDOW 32818 #define IDC_VIEW_PASSWORDS 32819 #define IDC_SHOW_APPLICATIONS 32820 #define IDC_SHOW_DOWNLOADS 32821 @@ -90,8 +90,9 @@ #define IDC_ABOUT 32829 #define IDC_IMPORT_SETTINGS 32830 #define IDC_OPTIONS 32831 -// Free space 32832 - 32890 -#define IDC_ENCODING 32891 +#define IDC_REPORT_BUG 32832 +// Free space 32833 - 32890 +#define IDC_ENCODING_MENU 32891 #define IDC_ENCODING_AUTO_DETECT 32892 #define IDC_ENCODING_UTF8 32893 #define IDC_ENCODING_UTF16LE 32894 @@ -133,48 +134,47 @@ // Spell-check suggestions. // If more suggestions have to be inserted, insert them before the _LAST // These have to be consecutive. -#define IDC_USESPELLCHECKSUGGESTION_0 32930 -#define IDC_USESPELLCHECKSUGGESTION_1 32931 -#define IDC_USESPELLCHECKSUGGESTION_2 32932 -#define IDC_USESPELLCHECKSUGGESTION_3 32933 -#define IDC_USESPELLCHECKSUGGESTION_4 32934 +#define IDC_SPELLCHECK_SUGGESTION_0 32930 +#define IDC_SPELLCHECK_SUGGESTION_1 32931 +#define IDC_SPELLCHECK_SUGGESTION_2 32932 +#define IDC_SPELLCHECK_SUGGESTION_3 32933 +#define IDC_SPELLCHECK_SUGGESTION_4 32934 // We leave some empty room here (35-39) in case we need to grow. -#define IDC_USESPELLCHECKSUGGESTION_LAST IDC_USESPELLCHECKSUGGESTION_4 +#define IDC_SPELLCHECK_SUGGESTION_LAST IDC_SPELLCHECK_SUGGESTION_4 #define IDC_RESTORE_TAB 32940 #define IDC_SHOW_AS_TAB 32941 #define IDC_EXIT 32942 #define IDC_DEBUGGER 32943 -#define IDC_DEVELOPER 32944 -#define IDC_HELPMENU 32945 -#define IDC_SHOW_BOOKMARKS_BAR 32946 +#define IDC_DEVELOPER_MENU 32944 +#define IDC_HELP_PAGE 32945 +#define IDC_SHOW_BOOKMARK_BAR 32946 // Free space 32947 - 32950 -#define IDR_CRASHED_PLUGIN 32951 +#define IDR_SAD_PLUGIN 32951 #define IDC_SHOW_BOOKMARK_MANAGER 32952 -#define IDC_SHOW_SPELLCHECKER_SUBMENU 32953 +#define IDC_SPELLCHECK_MENU 32953 // Reserve space for 100 Spell Check languages - currently we have 30. -#define IDC_SPELLCHECKER_LANGUAGE_FIRST 32954 -#define IDC_SPELLCHECKER_LANGUAGE_LAST 33054 +#define IDC_SPELLCHECK_LANGUAGES_FIRST 32954 +#define IDC_SPELLCHECK_LANGUAGES_LAST 33054 // We have a menu item for opening a new window in a specific profile, and it // has dynamic number of sub menu items. The number of sub menu items depends on // the number of existing profiles. But we only show menu items for nine // different profiles, plus a menu item for other than the nine profiles (if // there are more than nine profiles), plus a menu item for new profile. -#define IDC_NEWPROFILEWINDOW 33055 +#define IDC_PROFILE_MENU 33055 #define IDC_SELECT_PROFILE 33056 #define IDC_NEW_PROFILE 33057 // Define menu IDs for nine profiles to provide accelarators like CTRL + // SHIFT + 1, CTRL + SHIFT + 2, etc. for them. -#define IDC_NEWPROFILEWINDOW_PROFILE1 33058 -#define IDC_NEWPROFILEWINDOW_PROFILE2 33059 -#define IDC_NEWPROFILEWINDOW_PROFILE3 33060 -#define IDC_NEWPROFILEWINDOW_PROFILE4 33061 -#define IDC_NEWPROFILEWINDOW_PROFILE5 33062 -#define IDC_NEWPROFILEWINDOW_PROFILE6 33063 -#define IDC_NEWPROFILEWINDOW_PROFILE7 33064 -#define IDC_NEWPROFILEWINDOW_PROFILE8 33065 -#define IDC_NEWPROFILEWINDOW_PROFILE9 33066 -#define IDC_NEWPROFILEWINDOW_MIN_ID IDC_NEWPROFILEWINDOW_PROFILE1 -#define IDC_NEWPROFILEWINDOW_MAX_ID IDC_NEWPROFILEWINDOW_PROFILE9 +#define IDC_NEW_WINDOW_PROFILE_0 33058 +#define IDC_NEW_WINDOW_PROFILE_1 33059 +#define IDC_NEW_WINDOW_PROFILE_2 33060 +#define IDC_NEW_WINDOW_PROFILE_3 33061 +#define IDC_NEW_WINDOW_PROFILE_4 33062 +#define IDC_NEW_WINDOW_PROFILE_5 33063 +#define IDC_NEW_WINDOW_PROFILE_6 33064 +#define IDC_NEW_WINDOW_PROFILE_7 33065 +#define IDC_NEW_WINDOW_PROFILE_8 33066 +#define IDC_NEW_WINDOW_PROFILE_LAST IDC_NEW_WINDOW_PROFILE_8 // Next default values for new objects // diff --git a/chrome/app/generated_resources.grd b/chrome/app/generated_resources.grd index 492ecea..24d568d 100644 --- a/chrome/app/generated_resources.grd +++ b/chrome/app/generated_resources.grd @@ -360,7 +360,7 @@ each locale. --> <message name="IDS_CONTENT_CONTEXT_NO_SPELLING_SUGGESTIONS" desc="The name of the No Spelling Suggestions display in the content area context menu"> &No spelling suggestions </message> - <message name="IDS_CONTENT_CONTEXT_SPELLCHECK_OPTIONS" desc="The name of the Spellcheck Options display in the content area context menu"> + <message name="IDS_CONTENT_CONTEXT_SPELLCHECK_MENU" desc="The name of the Spellcheck Options submenu in the content area context menu"> &Spell-checker options </message> <message name="IDS_CONTENT_CONTEXT_LANGUAGE_SETTINGS" desc="The name of the Language Settings command in the content area context menu"> @@ -383,22 +383,22 @@ each locale. --> </message> <!-- Page menu --> - <message name="IDS_NEWTAB" desc="The text label of the New Tab menu item"> + <message name="IDS_NEW_TAB" desc="The text label of the New Tab menu item"> New &tab </message> <message name="IDS_SHOW_AS_TAB" desc="The text label for the Show As tab menu item"> &Show as tab </message> - <message name="IDS_NEWWINDOW" desc="The text label of the New Window menu item" > + <message name="IDS_NEW_WINDOW" desc="The text label of the New Window menu item" > &New window </message> - <message name="IDS_NEWPROFILEWINDOW" desc="The text label of the New profile Window menu item" > + <message name="IDS_PROFILE_MENU" desc="The text label of the New profile Window menu item" > New window in &profile </message> - <message name="IDS_NEWPROFILEWINDOW_OTHERPROFILE" desc="The text label of the sub menu item of New profile Window menu item to select a profile other than the ones displayed in the sub-menu items." > + <message name="IDS_SELECT_PROFILE" desc="The text label of the menu item to select a profile other than the ones displayed directly in the Profile submenu." > Other... </message> - <message name="IDS_GOOFFTHERECORD" desc="The text label of the New incognito window menu item"> + <message name="IDS_NEW_INCOGNITO_WINDOW" desc="The text label of the New incognito window menu item"> New &incognito window </message> <message name="IDS_UNDO" desc="The text label of the Undo menu item" > @@ -413,19 +413,19 @@ each locale. --> <message name="IDS_PASTE" desc="The text label of the Paste menu item" > &Paste </message> - <message name="IDS_SELECTALL" desc="The text label of the Select All menu item" > + <message name="IDS_SELECT_ALL" desc="The text label of the Select All menu item" > Select &all </message> - <message name="IDS_FIND_IN_PAGE" desc="The text label of the Find in Page menu item" > + <message name="IDS_FIND" desc="The text label of the Find in Page menu item" > &Find in page </message> - <message name="IDS_SAVEPAGEAS" desc="The text label of the Save Page As menu item" > + <message name="IDS_SAVE_PAGE" desc="The text label of the Save Page As menu item" > Save page &as... </message> <message name="IDS_PRINT" desc="The text label of the Print... menu item. Opens a dialog box to select print settings" > &Print... </message> - <message name="IDS_ZOOM" desc="The text label of the Zoom submenu" > + <message name="IDS_ZOOM_MENU" desc="The text label of the Zoom submenu" > &Zoom </message> <message name="IDS_ZOOM_PLUS" desc="The text label of the Make Text Larger menu item" > @@ -437,7 +437,7 @@ each locale. --> <message name="IDS_ZOOM_MINUS" desc="The text label of the Make Text Smaller menu item" > &Smaller </message> - <message name="IDS_ENCODING" desc="The text label of the Encoding submenu" > + <message name="IDS_ENCODING_MENU" desc="The text label of the Encoding submenu" > &Encoding </message> <message name="IDS_ENCODING_AUTO_DETECT" desc="The text label of the Auto Dectect submenu" > @@ -503,10 +503,10 @@ each locale. --> <message name="IDS_ENCODING_VIETNAMESE" desc="The text label of Vietnamese encoding" > Vietnamese </message> - <message name="IDS_DEVELOPER" desc="The text label of the Developer submenu"> + <message name="IDS_DEVELOPER_MENU" desc="The text label of the Developer submenu"> Developer </message> - <message name="IDS_VIEWPAGESOURCE" desc="The text label of the View Page Source menu item" > + <message name="IDS_VIEW_SOURCE" desc="The text label of the View Page Source menu item" > View s&ource </message> <message name="IDS_VIEWPAGEINFO" desc="The text label of the View Page Info menu item" > @@ -515,13 +515,13 @@ each locale. --> <message name="IDS_DEBUGGER" desc="The text label of the JavaScript debugger menu item"> Debug JavaScript </message> - <message name="IDS_COMMANDS_REPORTBUG" desc="The text label of the Report Bug menu item"> + <message name="IDS_REPORT_BUG" desc="The text label of the Report Bug menu item"> &Report bug or broken website... </message> - <message name="IDS_VIEWJSCONSOLE" desc="The text the menu to show the JS console"> + <message name="IDS_JS_CONSOLE" desc="The text the menu to show the JS console"> &JavaScript console </message> - <message name="IDS_TASKMANAGER" desc="The text label of the Task Manager menu item" > + <message name="IDS_TASK_MANAGER" desc="The text label of the Task Manager menu item" > &Task manager </message> <message name="IDS_CLOSE" desc="The close menu"> @@ -561,7 +561,7 @@ each locale. --> <message name="IDS_OPTIONS" desc="The text label of the Options menu item"> &Options </message> - <message name="IDS_HELP" desc="The text label of the Help menu item"> + <message name="IDS_HELP_PAGE" desc="The text label of the Help menu item"> Help </message> <message name="IDS_ABOUT" desc="The text label of the About Chrome menu item"> @@ -1283,7 +1283,7 @@ each locale. --> </message> <!-- Gears shortcut strings --> - <message name="IDS_DEFAULT_INSTALL_SITE_LABEL" desc="Default installation menu label"> + <message name="IDS_CREATE_SHORTCUTS" desc="Default installation menu label"> Create application &shortcuts... </message> @@ -2158,7 +2158,7 @@ each locale. --> <message name="IDS_APP_MENU_RELOAD" desc="The reload menu in application windows"> Reload </message> - <message name="IDS_APP_MENU_DUPLICATE" meaning="Duplicate application window" desc="The duplicate / start new instance menu"> + <message name="IDS_APP_MENU_DUPLICATE_APP_WINDOW" meaning="Duplicate application window" desc="The duplicate / start new instance menu"> Duplicate </message> <message name="IDS_APP_MENU_COPY_URL" desc="The copy url menu in application windows"> diff --git a/chrome/browser/autocomplete/autocomplete_edit.cc b/chrome/browser/autocomplete/autocomplete_edit.cc index 60f1387..357fbd9 100644 --- a/chrome/browser/autocomplete/autocomplete_edit.cc +++ b/chrome/browser/autocomplete/autocomplete_edit.cc @@ -756,8 +756,8 @@ AutocompleteEditView::AutocompleteEditView( context_menu_->AppendMenuItemWithLabel( IDS_PASTE_AND_GO, l10n_util::GetString(IDS_PASTE_AND_GO)); context_menu_->AppendSeparator(); - context_menu_->AppendMenuItemWithLabel(IDS_SELECTALL, - l10n_util::GetString(IDS_SELECTALL)); + context_menu_->AppendMenuItemWithLabel( + IDS_SELECT_ALL, l10n_util::GetString(IDS_SELECT_ALL)); context_menu_->AppendSeparator(); context_menu_->AppendMenuItemWithLabel( IDS_EDIT_SEARCH_ENGINES, l10n_util::GetString(IDS_EDIT_SEARCH_ENGINES)); @@ -1174,7 +1174,7 @@ bool AutocompleteEditView::IsCommandEnabled(int id) const { case IDS_COPY: return !!CanCopy(); case IDS_PASTE: return !!CanPaste(); case IDS_PASTE_AND_GO: return CanPasteAndGo(GetClipboardText()); - case IDS_SELECTALL: return !!CanSelectAll(); + case IDS_SELECT_ALL: return !!CanSelectAll(); case IDS_EDIT_SEARCH_ENGINES: return command_controller_->IsCommandEnabled(IDC_EDIT_SEARCH_ENGINES); default: NOTREACHED(); return false; @@ -1219,7 +1219,7 @@ void AutocompleteEditView::ExecuteCommand(int id) { Paste(); break; - case IDS_SELECTALL: + case IDS_SELECT_ALL: SelectAll(false); break; diff --git a/chrome/browser/automation/automation_provider.cc b/chrome/browser/automation/automation_provider.cc index c1d4a15..2f2b6b5 100644 --- a/chrome/browser/automation/automation_provider.cc +++ b/chrome/browser/automation/automation_provider.cc @@ -2238,7 +2238,7 @@ void AutomationProvider::SavePage(const IPC::Message& message, NavigationController* nav = tab_tracker_->GetResource(tab_handle); Browser* browser = FindAndActivateTab(nav); DCHECK(browser); - if (!browser->IsCommandEnabled(IDC_SAVEPAGE)) { + if (!browser->IsCommandEnabled(IDC_SAVE_PAGE)) { Send(new AutomationMsg_SavePageResponse(message.routing_id(), false)); return; } diff --git a/chrome/browser/browser.cc b/chrome/browser/browser.cc index 4d96433..dba2bc0 100644 --- a/chrome/browser/browser.cc +++ b/chrome/browser/browser.cc @@ -1036,12 +1036,12 @@ void Browser::ShowDownloadsTab() { ShowNativeUITab(DownloadTabUI::GetURL()); } -void Browser::OpenBookmarksManager() { +void Browser::OpenBookmarkManager() { UserMetrics::RecordAction(L"ShowBookmarkManager", profile_); window_->ShowBookmarkManager(); } -void Browser::ToggleBookmarksBar() { +void Browser::ToggleBookmarkBar() { UserMetrics::RecordAction(L"ShowBookmarksBar", profile_); window_->ToggleBookmarkBar(); } @@ -1105,16 +1105,16 @@ void Browser::ExecuteCommand(int id) { case IDC_STOP: Stop(); break; case IDC_HOME: Home(); break; case IDC_GO: Go(); break; - case IDC_OPENURL: OpenCurrentURL(); break; + case IDC_OPEN_CURRENT_URL: OpenCurrentURL(); break; - case IDC_NEWTAB: NewTab(); break; - case IDC_CLOSETAB: CloseTab(); break; + case IDC_NEW_TAB: NewTab(); break; + case IDC_CLOSE_TAB: CloseTab(); break; case IDC_CLOSE_WEB_APP: CloseApp(); break; - case IDC_NEWWINDOW: NewWindow(); break; - case IDC_GOOFFTHERECORD: NewIncognitoWindow(); break; - case IDC_CLOSEWINDOW: CloseWindow(); break; + case IDC_NEW_WINDOW: NewWindow(); break; + case IDC_NEW_INCOGNITO_WINDOW: NewIncognitoWindow(); break; + case IDC_CLOSE_WINDOW: CloseWindow(); break; case IDC_SELECT_NEXT_TAB: SelectNextTab(); break; - case IDC_SELECT_PREV_TAB: SelectPreviousTab(); break; + case IDC_SELECT_PREVIOUS_TAB: SelectPreviousTab(); break; case IDC_SELECT_TAB_0: case IDC_SELECT_TAB_1: case IDC_SELECT_TAB_2: @@ -1124,7 +1124,7 @@ void Browser::ExecuteCommand(int id) { case IDC_SELECT_TAB_6: case IDC_SELECT_TAB_7: SelectNumberedTab(id - IDC_SELECT_TAB_0); break; case IDC_SELECT_LAST_TAB: SelectLastTab(); break; - case IDC_DUPLICATE: DuplicateTab(); break; + case IDC_DUPLICATE_TAB: DuplicateTab(); break; case IDC_RESTORE_TAB: RestoreTab(); break; case IDC_SHOW_AS_TAB: ConvertPopupToTabbedBrowser(); break; case IDC_EXIT: Exit(); break; @@ -1147,10 +1147,10 @@ void Browser::ExecuteCommand(int id) { case IDC_FOCUS_TOOLBAR: FocusToolbar(); break; case IDC_STAR: BookmarkCurrentPage(); break; - case IDC_VIEWSOURCE: ViewSource(); break; - case IDC_CLOSEPOPUPS: ClosePopups(); break; + case IDC_VIEW_SOURCE: ViewSource(); break; + case IDC_CLOSE_POPUPS: ClosePopups(); break; case IDC_PRINT: Print(); break; - case IDC_SAVEPAGE: SavePage(); break; + case IDC_SAVE_PAGE: SavePage(); break; case IDC_ENCODING_AUTO_DETECT: ToggleEncodingAutoDetect(); break; case IDC_ENCODING_UTF8: case IDC_ENCODING_UTF16LE: @@ -1192,21 +1192,21 @@ void Browser::ExecuteCommand(int id) { case IDC_EDIT_SEARCH_ENGINES: OpenKeywordEditor(); break; case IDC_CLEAR_BROWSING_DATA: OpenClearBrowsingDataDialog(); break; case IDC_IMPORT_SETTINGS: OpenImportSettingsDialog(); break; - case IDS_COMMANDS_REPORTBUG: OpenBugReportDialog(); break; + case IDC_REPORT_BUG: OpenBugReportDialog(); break; case IDC_DEBUGGER: OpenDebuggerWindow(); break; - case IDC_SHOW_JS_CONSOLE: OpenJavaScriptConsole(); break; - case IDC_CREATE_SHORTCUT: OpenCreateShortcutsDialog(); break; + case IDC_JS_CONSOLE: OpenJavaScriptConsole(); break; + case IDC_CREATE_SHORTCUTS: OpenCreateShortcutsDialog(); break; case IDC_VIEW_PASSWORDS: OpenPasswordManager(); break; case IDC_ABOUT: OpenAboutChromeDialog(); break; - case IDC_OPENFILE: OpenFile(); break; - case IDC_TASKMANAGER: OpenTaskManager(); break; + case IDC_OPEN_FILE: OpenFile(); break; + case IDC_TASK_MANAGER: OpenTaskManager(); break; case IDC_OPTIONS: OpenOptionsDialog(); break; - case IDC_HELPMENU: OpenHelpTab(); break; + case IDC_HELP_PAGE: OpenHelpTab(); break; case IDC_SHOW_HISTORY: ShowHistoryTab(); break; case IDC_SHOW_DOWNLOADS: ShowDownloadsTab(); break; - case IDC_SHOW_BOOKMARK_MANAGER: OpenBookmarksManager(); break; - case IDC_SHOW_BOOKMARKS_BAR: ToggleBookmarksBar(); break; - case IDC_NEWPROFILEWINDOW: + case IDC_SHOW_BOOKMARK_MANAGER: OpenBookmarkManager(); break; + case IDC_SHOW_BOOKMARK_BAR: ToggleBookmarkBar(); break; + case IDC_PROFILE_MENU: case IDC_SELECT_PROFILE: OpenSelectProfileDialog(); break; @@ -1214,9 +1214,9 @@ void Browser::ExecuteCommand(int id) { default: // Handle the user action for creating a new window in a specific profile. - if (id >= IDC_NEWPROFILEWINDOW_MIN_ID && - id <= IDC_NEWPROFILEWINDOW_MAX_ID) { - int index = id - IDC_NEWPROFILEWINDOW_MIN_ID; + if (id >= IDC_NEW_WINDOW_PROFILE_0 && + id <= IDC_NEW_WINDOW_PROFILE_LAST) { + int index = id - IDC_NEW_WINDOW_PROFILE_0; NewProfileWindowByIndex(index); } else { LOG(WARNING) << "Received Unimplemented Command: " << id; @@ -1881,15 +1881,15 @@ void Browser::InitCommandState() { controller_.UpdateCommandEnabled(IDC_RELOAD, true); controller_.UpdateCommandEnabled(IDC_HOME, type() == TYPE_NORMAL); controller_.UpdateCommandEnabled(IDC_GO, true); - controller_.UpdateCommandEnabled(IDC_NEWTAB, true); - controller_.UpdateCommandEnabled(IDC_CLOSETAB, true); - controller_.UpdateCommandEnabled(IDC_NEWWINDOW, true); - controller_.UpdateCommandEnabled(IDC_CLOSEWINDOW, true); + controller_.UpdateCommandEnabled(IDC_NEW_TAB, true); + controller_.UpdateCommandEnabled(IDC_CLOSE_TAB, true); + controller_.UpdateCommandEnabled(IDC_NEW_WINDOW, true); + controller_.UpdateCommandEnabled(IDC_CLOSE_WINDOW, true); controller_.UpdateCommandEnabled(IDC_FOCUS_LOCATION, true); controller_.UpdateCommandEnabled(IDC_FOCUS_SEARCH, true); controller_.UpdateCommandEnabled(IDC_FOCUS_TOOLBAR, true); controller_.UpdateCommandEnabled(IDC_STAR, true); - controller_.UpdateCommandEnabled(IDC_OPENURL, true); + controller_.UpdateCommandEnabled(IDC_OPEN_CURRENT_URL, true); controller_.UpdateCommandEnabled(IDC_SHOWALLTABS_NEXT, true); controller_.UpdateCommandEnabled(IDC_SHOWALLTABS_PREV, true); controller_.UpdateCommandEnabled(IDC_SHOWALLTABS, true); @@ -1899,10 +1899,10 @@ void Browser::InitCommandState() { controller_.UpdateCommandEnabled(IDC_FIND, true); controller_.UpdateCommandEnabled(IDC_FIND_NEXT, true); controller_.UpdateCommandEnabled(IDC_FIND_PREVIOUS, true); - controller_.UpdateCommandEnabled(IDS_COMMANDS_REPORTBUG, true); - controller_.UpdateCommandEnabled(IDC_SHOW_JS_CONSOLE, true); + controller_.UpdateCommandEnabled(IDC_REPORT_BUG, true); + controller_.UpdateCommandEnabled(IDC_JS_CONSOLE, true); controller_.UpdateCommandEnabled(IDC_SELECT_NEXT_TAB, true); - controller_.UpdateCommandEnabled(IDC_SELECT_PREV_TAB, true); + controller_.UpdateCommandEnabled(IDC_SELECT_PREVIOUS_TAB, true); controller_.UpdateCommandEnabled(IDC_SELECT_TAB_0, true); controller_.UpdateCommandEnabled(IDC_SELECT_TAB_1, true); controller_.UpdateCommandEnabled(IDC_SELECT_TAB_2, true); @@ -1912,28 +1912,28 @@ void Browser::InitCommandState() { controller_.UpdateCommandEnabled(IDC_SELECT_TAB_6, true); controller_.UpdateCommandEnabled(IDC_SELECT_TAB_7, true); controller_.UpdateCommandEnabled(IDC_SELECT_LAST_TAB, true); - controller_.UpdateCommandEnabled(IDC_VIEWSOURCE, true); - controller_.UpdateCommandEnabled(IDC_CREATE_SHORTCUT, false); + controller_.UpdateCommandEnabled(IDC_VIEW_SOURCE, true); + controller_.UpdateCommandEnabled(IDC_CREATE_SHORTCUTS, false); controller_.UpdateCommandEnabled(IDC_EDIT_SEARCH_ENGINES, true); controller_.UpdateCommandEnabled(IDC_ZOOM_PLUS, true); controller_.UpdateCommandEnabled(IDC_ZOOM_MINUS, true); controller_.UpdateCommandEnabled(IDC_ZOOM_NORMAL, true); - controller_.UpdateCommandEnabled(IDC_OPENFILE, true); - controller_.UpdateCommandEnabled(IDC_TASKMANAGER, true); - controller_.UpdateCommandEnabled(IDC_CLOSEPOPUPS, true); + controller_.UpdateCommandEnabled(IDC_OPEN_FILE, true); + controller_.UpdateCommandEnabled(IDC_TASK_MANAGER, true); + controller_.UpdateCommandEnabled(IDC_CLOSE_POPUPS, true); controller_.UpdateCommandEnabled(IDC_PRINT, true); controller_.UpdateCommandEnabled(IDC_COPY_URL, true); - controller_.UpdateCommandEnabled(IDC_DUPLICATE, true); - controller_.UpdateCommandEnabled(IDC_GOOFFTHERECORD, true); + controller_.UpdateCommandEnabled(IDC_DUPLICATE_TAB, true); + controller_.UpdateCommandEnabled(IDC_NEW_INCOGNITO_WINDOW, true); controller_.UpdateCommandEnabled(IDC_VIEW_PASSWORDS, true); controller_.UpdateCommandEnabled(IDC_IMPORT_SETTINGS, true); controller_.UpdateCommandEnabled(IDC_CLEAR_BROWSING_DATA, true); controller_.UpdateCommandEnabled(IDC_ABOUT, true); controller_.UpdateCommandEnabled(IDC_SHOW_HISTORY, true); - controller_.UpdateCommandEnabled(IDC_SHOW_BOOKMARKS_BAR, true); + controller_.UpdateCommandEnabled(IDC_SHOW_BOOKMARK_BAR, true); controller_.UpdateCommandEnabled(IDC_SHOW_BOOKMARK_MANAGER, true); controller_.UpdateCommandEnabled(IDC_SHOW_DOWNLOADS, true); - controller_.UpdateCommandEnabled(IDC_ENCODING, true); + controller_.UpdateCommandEnabled(IDC_ENCODING_MENU, true); controller_.UpdateCommandEnabled(IDC_ENCODING_AUTO_DETECT, true); controller_.UpdateCommandEnabled(IDC_ENCODING_UTF8, true); controller_.UpdateCommandEnabled(IDC_ENCODING_UTF16LE, true); @@ -1981,8 +1981,8 @@ void Browser::InitCommandState() { // the debugger doesn't work in single process mode controller_.UpdateCommandEnabled(IDC_DEBUGGER, !RenderProcessHost::run_renderer_in_process()); - controller_.UpdateCommandEnabled(IDC_DEVELOPER, true); - controller_.UpdateCommandEnabled(IDC_HELPMENU, true); + controller_.UpdateCommandEnabled(IDC_DEVELOPER_MENU, true); + controller_.UpdateCommandEnabled(IDC_HELP_PAGE, true); } void Browser::UpdateNavigationCommands() { @@ -2003,19 +2003,19 @@ void Browser::UpdateNavigationCommands() { SetStarredButtonToggled(web_contents->is_starred()); // View-source should not be enabled if already in view-source mode. - controller_.UpdateCommandEnabled(IDC_VIEWSOURCE, + controller_.UpdateCommandEnabled(IDC_VIEW_SOURCE, current_tab->type() != TAB_CONTENTS_VIEW_SOURCE && current_tab->controller()->GetActiveEntry()); - controller_.UpdateCommandEnabled(IDC_ZOOM, true); + controller_.UpdateCommandEnabled(IDC_ZOOM_MENU, true); bool enable_encoding = SavePackage::IsSavableContents(web_contents->contents_mime_type()) && SavePackage::IsSavableURL(current_tab->GetURL()); - controller_.UpdateCommandEnabled(IDC_ENCODING, enable_encoding); + controller_.UpdateCommandEnabled(IDC_ENCODING_MENU, enable_encoding); - controller_.UpdateCommandEnabled(IDC_SAVEPAGE, + controller_.UpdateCommandEnabled(IDC_SAVE_PAGE, SavePackage::IsSavableURL(current_tab->GetURL())); - controller_.UpdateCommandEnabled(IDC_SHOW_JS_CONSOLE, true); + controller_.UpdateCommandEnabled(IDC_JS_CONSOLE, true); controller_.UpdateCommandEnabled(IDC_FIND, true); controller_.UpdateCommandEnabled(IDC_FIND_NEXT, true); controller_.UpdateCommandEnabled(IDC_FIND_PREVIOUS, true); @@ -2023,19 +2023,19 @@ void Browser::UpdateNavigationCommands() { controller_.UpdateCommandEnabled(IDC_ZOOM_MINUS, true); controller_.UpdateCommandEnabled(IDC_ZOOM_NORMAL, true); controller_.UpdateCommandEnabled(IDC_STOP, true); - controller_.UpdateCommandEnabled(IDC_SHOW_JS_CONSOLE, true); + controller_.UpdateCommandEnabled(IDC_JS_CONSOLE, true); controller_.UpdateCommandEnabled(IDC_PRINT, true); } else { - controller_.UpdateCommandEnabled(IDC_VIEWSOURCE, false); - controller_.UpdateCommandEnabled(IDC_SHOW_JS_CONSOLE, false); + controller_.UpdateCommandEnabled(IDC_VIEW_SOURCE, false); + controller_.UpdateCommandEnabled(IDC_JS_CONSOLE, false); // Both disable the starring button and ensure it doesn't show a star. controller_.UpdateCommandEnabled(IDC_STAR, false); SetStarredButtonToggled(false); - controller_.UpdateCommandEnabled(IDC_ZOOM, false); - controller_.UpdateCommandEnabled(IDC_ENCODING, false); + controller_.UpdateCommandEnabled(IDC_ZOOM_MENU, false); + controller_.UpdateCommandEnabled(IDC_ENCODING_MENU, false); - controller_.UpdateCommandEnabled(IDC_SAVEPAGE, false); + controller_.UpdateCommandEnabled(IDC_SAVE_PAGE, false); controller_.UpdateCommandEnabled(IDC_FIND, false); controller_.UpdateCommandEnabled(IDC_FIND_NEXT, false); controller_.UpdateCommandEnabled(IDC_FIND_PREVIOUS, false); @@ -2043,22 +2043,22 @@ void Browser::UpdateNavigationCommands() { controller_.UpdateCommandEnabled(IDC_ZOOM_MINUS, false); controller_.UpdateCommandEnabled(IDC_ZOOM_NORMAL, false); controller_.UpdateCommandEnabled(IDC_STOP, false); - controller_.UpdateCommandEnabled(IDC_SHOW_JS_CONSOLE, false); + controller_.UpdateCommandEnabled(IDC_JS_CONSOLE, false); controller_.UpdateCommandEnabled(IDC_PRINT, false); } - controller_.UpdateCommandEnabled(IDC_CREATE_SHORTCUT, + controller_.UpdateCommandEnabled(IDC_CREATE_SHORTCUTS, current_tab->type() == TAB_CONTENTS_WEB && !current_tab->GetFavIcon().isNull()); - controller_.UpdateCommandEnabled(IDC_DUPLICATE, + controller_.UpdateCommandEnabled(IDC_DUPLICATE_TAB, CanDuplicateContentsAt(selected_index())); // Enable various IDC_NEWPROFILEWINDOW* commands. - controller_.UpdateCommandEnabled(IDC_NEWPROFILEWINDOW, true); + controller_.UpdateCommandEnabled(IDC_PROFILE_MENU, true); controller_.UpdateCommandEnabled(IDC_SELECT_PROFILE, true); controller_.UpdateCommandEnabled(IDC_NEW_PROFILE, true); - for (int i = IDC_NEWPROFILEWINDOW_MIN_ID; - i <= IDC_NEWPROFILEWINDOW_MAX_ID; + for (int i = IDC_NEW_WINDOW_PROFILE_0; + i <= IDC_NEW_WINDOW_PROFILE_LAST; ++i) { controller_.UpdateCommandEnabled(i, true); } @@ -2169,7 +2169,7 @@ void Browser::ProcessPendingUIUpdates() { if (contents == GetSelectedTabContents()) { TabContents* current_tab = GetSelectedTabContents(); - controller_.UpdateCommandEnabled(IDC_CREATE_SHORTCUT, + controller_.UpdateCommandEnabled(IDC_CREATE_SHORTCUTS, current_tab->type() == TAB_CONTENTS_WEB && !current_tab->GetFavIcon().isNull()); } diff --git a/chrome/browser/browser.h b/chrome/browser/browser.h index a704199..648a04a 100644 --- a/chrome/browser/browser.h +++ b/chrome/browser/browser.h @@ -290,8 +290,8 @@ class Browser : public TabStripModelDelegate, void OpenHelpTab(); void ShowHistoryTab(); void ShowDownloadsTab(); - void OpenBookmarksManager(); - void ToggleBookmarksBar(); + void OpenBookmarkManager(); + void ToggleBookmarkBar(); void OpenSelectProfileDialog(); void OpenNewProfileDialog(); diff --git a/chrome/browser/browser_uitest.cc b/chrome/browser/browser_uitest.cc index f3e42e3..d849860 100644 --- a/chrome/browser/browser_uitest.cc +++ b/chrome/browser/browser_uitest.cc @@ -180,11 +180,11 @@ TEST_F(BrowserTest, TabNavigationAccelerators) { // to. int old_tab_count = -1; ASSERT_TRUE(window->GetTabCount(&old_tab_count)); - ASSERT_TRUE(window->ApplyAccelerator(IDC_NEWTAB)); + ASSERT_TRUE(window->ApplyAccelerator(IDC_NEW_TAB)); int new_tab_count; ASSERT_TRUE(window->WaitForTabCountToChange(old_tab_count, &new_tab_count, 5000)); - ASSERT_TRUE(window->ApplyAccelerator(IDC_NEWTAB)); + ASSERT_TRUE(window->ApplyAccelerator(IDC_NEW_TAB)); old_tab_count = new_tab_count; ASSERT_TRUE(window->WaitForTabCountToChange(old_tab_count, &new_tab_count, 5000)); @@ -202,7 +202,7 @@ TEST_F(BrowserTest, TabNavigationAccelerators) { ASSERT_TRUE(window->WaitForTabToBecomeActive(1, 5000)); // Navigate back to the first tab using the previous accelerators. - ASSERT_TRUE(window->ApplyAccelerator(IDC_SELECT_PREV_TAB)); + ASSERT_TRUE(window->ApplyAccelerator(IDC_SELECT_PREVIOUS_TAB)); ASSERT_TRUE(window->WaitForTabToBecomeActive(0, 5000)); // Navigate to the last tab using the select last accelerator. @@ -248,7 +248,7 @@ TEST_F(BrowserTest, DuplicateTab) { ASSERT_TRUE(automation()->GetBrowserWindowCount(&initial_window_count)); // Duplicate the tab. - ASSERT_TRUE(browser_proxy->ApplyAccelerator(IDC_DUPLICATE)); + ASSERT_TRUE(browser_proxy->ApplyAccelerator(IDC_DUPLICATE_TAB)); // The duplicated tab should not end up in a new window. int window_count; diff --git a/chrome/browser/render_view_context_menu.cc b/chrome/browser/render_view_context_menu.cc index db7dc47..5806eb8 100644 --- a/chrome/browser/render_view_context_menu.cc +++ b/chrome/browser/render_view_context_menu.cc @@ -119,9 +119,9 @@ void RenderViewContextMenu::AppendSelectionItems() { void RenderViewContextMenu::AppendEditableItems() { // Append Dictionary spell check suggestions. for (size_t i = 0; i < misspelled_word_suggestions_.size() && - IDC_USESPELLCHECKSUGGESTION_0 + i <= IDC_USESPELLCHECKSUGGESTION_LAST; + IDC_SPELLCHECK_SUGGESTION_0 + i <= IDC_SPELLCHECK_SUGGESTION_LAST; i ++) { - AppendMenuItemWithLabel(IDC_USESPELLCHECKSUGGESTION_0 + static_cast<int>(i), + AppendMenuItemWithLabel(IDC_SPELLCHECK_SUGGESTION_0 + static_cast<int>(i), misspelled_word_suggestions_[i]); } if (misspelled_word_suggestions_.size() > 0) @@ -147,22 +147,22 @@ void RenderViewContextMenu::AppendEditableItems() { AppendSeparator(); // Add Spell Check options sub menu. - spellchecker_sub_menu_ = AppendSubMenu(IDC_SHOW_SPELLCHECKER_SUBMENU, - l10n_util::GetString(IDS_CONTENT_CONTEXT_SPELLCHECK_OPTIONS)); + spellchecker_sub_menu_ = AppendSubMenu(IDC_SPELLCHECK_MENU, + l10n_util::GetString(IDS_CONTENT_CONTEXT_SPELLCHECK_MENU)); // Add Spell Check languages to sub menu. std::vector<std::wstring> language_vector; int current_language_index = SpellChecker:: GetSpellCheckLanguagesToDisplayInContextMenu(profile_, &language_vector); // Add the spell check languages. - DCHECK(language_vector.size() <= - IDC_SPELLCHECKER_LANGUAGE_LAST - IDC_SPELLCHECKER_LANGUAGE_FIRST); + DCHECK(language_vector.size() < + IDC_SPELLCHECK_LANGUAGES_LAST - IDC_SPELLCHECK_LANGUAGES_FIRST); const std::wstring app_locale = g_browser_process->GetApplicationLocale(); for (size_t i = 0; i < language_vector.size(); ++i) { std::wstring local_language(l10n_util::GetLocalName( language_vector.at(i), app_locale, true)); spellchecker_sub_menu_->AppendMenuItem( - IDC_SPELLCHECKER_LANGUAGE_FIRST + i, local_language, RADIO); + IDC_SPELLCHECK_LANGUAGES_FIRST + i, local_language, RADIO); } // Add item in the sub menu to pop up the fonts and languages options menu. diff --git a/chrome/browser/render_view_context_menu_controller.cc b/chrome/browser/render_view_context_menu_controller.cc index e54868c..f8c77cb 100644 --- a/chrome/browser/render_view_context_menu_controller.cc +++ b/chrome/browser/render_view_context_menu_controller.cc @@ -104,8 +104,8 @@ std::wstring RenderViewContextMenuController::GetLabel(int id) const { bool RenderViewContextMenuController::IsCommandEnabled(int id) const { // Allow Spell Check language items on sub menu for text area context menu. - if (id >= IDC_SPELLCHECKER_LANGUAGE_FIRST - && id <= IDC_SPELLCHECKER_LANGUAGE_LAST) { + if ((id >= IDC_SPELLCHECK_LANGUAGES_FIRST) && + (id < IDC_SPELLCHECK_LANGUAGES_LAST)) { return true; } @@ -175,13 +175,13 @@ bool RenderViewContextMenuController::IsCommandEnabled(int id) const { case IDS_CONTENT_CONTEXT_COPYIMAGE: case IDS_CONTENT_CONTEXT_PRINT: case IDS_CONTENT_CONTEXT_SEARCHWEBFOR: - case IDC_USESPELLCHECKSUGGESTION_0: - case IDC_USESPELLCHECKSUGGESTION_1: - case IDC_USESPELLCHECKSUGGESTION_2: - case IDC_USESPELLCHECKSUGGESTION_3: - case IDC_USESPELLCHECKSUGGESTION_4: + case IDC_SPELLCHECK_SUGGESTION_0: + case IDC_SPELLCHECK_SUGGESTION_1: + case IDC_SPELLCHECK_SUGGESTION_2: + case IDC_SPELLCHECK_SUGGESTION_3: + case IDC_SPELLCHECK_SUGGESTION_4: return true; - case IDC_SHOW_SPELLCHECKER_SUBMENU: + case IDC_SPELLCHECK_MENU: return true; case IDS_CONTENT_CONTEXT_ADD_TO_DICTIONARY: return !params_.misspelled_word.empty(); @@ -204,7 +204,7 @@ bool RenderViewContextMenuController::IsItemChecked(int id) const { int spellcheck_language_index = SpellChecker:: GetSpellCheckLanguagesToDisplayInContextMenu( source_web_contents_->profile(), &display_language_vector); - if (id - IDC_SPELLCHECKER_LANGUAGE_FIRST == spellcheck_language_index) + if (id - IDC_SPELLCHECK_LANGUAGES_FIRST == spellcheck_language_index) return true; return false; @@ -246,19 +246,19 @@ bool RenderViewContextMenuController::GetAcceleratorInfo( void RenderViewContextMenuController::ExecuteCommand(int id) { // Check to see if one of the spell check language ids have been clicked. - if (id >= IDC_SPELLCHECKER_LANGUAGE_FIRST && - id <= IDC_SPELLCHECKER_LANGUAGE_LAST) { + if (id >= IDC_SPELLCHECK_LANGUAGES_FIRST && + id < IDC_SPELLCHECK_LANGUAGES_LAST) { std::vector<std::wstring> display_language_vector; int current_language = SpellChecker:: GetSpellCheckLanguagesToDisplayInContextMenu( source_web_contents_->profile(), &display_language_vector); - if (id - IDC_SPELLCHECKER_LANGUAGE_FIRST < + if (id - IDC_SPELLCHECK_LANGUAGES_FIRST < static_cast<int>(display_language_vector.size())) { StringPrefMember dictionary_language; dictionary_language.Init(prefs::kSpellCheckDictionary, source_web_contents_->profile()->GetPrefs(), NULL); dictionary_language.SetValue(display_language_vector.at( - id - IDC_SPELLCHECKER_LANGUAGE_FIRST)); + id - IDC_SPELLCHECK_LANGUAGES_FIRST)); } return; @@ -433,13 +433,13 @@ void RenderViewContextMenuController::ExecuteCommand(int id) { break; } - case IDC_USESPELLCHECKSUGGESTION_0: - case IDC_USESPELLCHECKSUGGESTION_1: - case IDC_USESPELLCHECKSUGGESTION_2: - case IDC_USESPELLCHECKSUGGESTION_3: - case IDC_USESPELLCHECKSUGGESTION_4: + case IDC_SPELLCHECK_SUGGESTION_0: + case IDC_SPELLCHECK_SUGGESTION_1: + case IDC_SPELLCHECK_SUGGESTION_2: + case IDC_SPELLCHECK_SUGGESTION_3: + case IDC_SPELLCHECK_SUGGESTION_4: source_web_contents_->render_view_host()->Replace( - params_.dictionary_suggestions[id - IDC_USESPELLCHECKSUGGESTION_0]); + params_.dictionary_suggestions[id - IDC_SPELLCHECK_SUGGESTION_0]); break; case IDS_CONTENT_CONTEXT_ADD_TO_DICTIONARY: diff --git a/chrome/browser/sessions/session_restore_uitest.cc b/chrome/browser/sessions/session_restore_uitest.cc index f93098a..8843567 100644 --- a/chrome/browser/sessions/session_restore_uitest.cc +++ b/chrome/browser/sessions/session_restore_uitest.cc @@ -47,7 +47,7 @@ class SessionRestoreUITest : public UITest { scoped_ptr<BrowserProxy> browser_proxy( automation()->GetBrowserWindow(window_index)); ASSERT_TRUE(browser_proxy.get()); - ASSERT_TRUE(browser_proxy->ApplyAccelerator(IDC_CLOSEWINDOW)); + ASSERT_TRUE(browser_proxy->ApplyAccelerator(IDC_CLOSE_WINDOW)); browser_proxy.reset(); int window_count; ASSERT_TRUE(automation()->WaitForWindowCountToChange(initial_count, @@ -266,7 +266,7 @@ TEST_F(SessionRestoreUITest, DISABLED_DontRestoreWhileIncognito) { scoped_ptr<BrowserProxy> browser_proxy(automation()->GetBrowserWindow(0)); // Create an off the record window and wait for it to appear. - ASSERT_TRUE(browser_proxy->ApplyAccelerator(IDC_GOOFFTHERECORD)); + ASSERT_TRUE(browser_proxy->ApplyAccelerator(IDC_NEW_INCOGNITO_WINDOW)); int window_count; ASSERT_TRUE(automation()->WaitForWindowCountToChange(1, &window_count, kWaitForActionMsec) && @@ -389,7 +389,7 @@ TEST_F(SessionRestoreUITest, DISABLED_ShareProcessesOnRestore) { // Create two new tabs. int new_tab_count; - ASSERT_TRUE(browser_proxy->ApplyAccelerator(IDC_NEWTAB)); + ASSERT_TRUE(browser_proxy->ApplyAccelerator(IDC_NEW_TAB)); ASSERT_TRUE(browser_proxy->WaitForTabCountToChange(tab_count, &new_tab_count, kWaitForActionMsec)); scoped_ptr<TabProxy> last_tab(browser_proxy->GetTab(new_tab_count - 1)); @@ -397,7 +397,7 @@ TEST_F(SessionRestoreUITest, DISABLED_ShareProcessesOnRestore) { // Do a reload to ensure new tab page has loaded. ASSERT_TRUE(last_tab->Reload()); tab_count = new_tab_count; - ASSERT_TRUE(browser_proxy->ApplyAccelerator(IDC_NEWTAB)); + ASSERT_TRUE(browser_proxy->ApplyAccelerator(IDC_NEW_TAB)); ASSERT_TRUE(browser_proxy->WaitForTabCountToChange(tab_count, &new_tab_count, kWaitForActionMsec)); last_tab.reset(browser_proxy->GetTab(new_tab_count - 1)); diff --git a/chrome/browser/tab_restore_uitest.cc b/chrome/browser/tab_restore_uitest.cc index 6e813e8..73327ac 100644 --- a/chrome/browser/tab_restore_uitest.cc +++ b/chrome/browser/tab_restore_uitest.cc @@ -245,7 +245,7 @@ TEST_F(TabRestoreUITest, RestoreWindow) { new_tab->NavigateToURL(url2_); // Close the window. - ASSERT_TRUE(browser_proxy->ApplyAccelerator(IDC_CLOSEWINDOW)); + ASSERT_TRUE(browser_proxy->ApplyAccelerator(IDC_CLOSE_WINDOW)); browser_proxy.reset(); new_tab.reset(); ASSERT_TRUE(automation()->WaitForWindowCountToBecome(window_count - 1, diff --git a/chrome/browser/view_source_uitest.cc b/chrome/browser/view_source_uitest.cc index c943480..1aad505 100644 --- a/chrome/browser/view_source_uitest.cc +++ b/chrome/browser/view_source_uitest.cc @@ -84,7 +84,7 @@ TEST_F(ViewSourceTest, ViewSourceInPageMenuEnabledOnANormalPage) { GURL url = server.TestServerPageW(test_html_); NavigateToURL(url); - EXPECT_TRUE(IsPageMenuCommandEnabled(IDC_VIEWSOURCE)); + EXPECT_TRUE(IsPageMenuCommandEnabled(IDC_VIEW_SOURCE)); } // Make sure that when looking at the page source, we can't select @@ -97,6 +97,6 @@ TEST_F(ViewSourceTest, ViewSourceInPageMenuDisabledWhileViewingSource) { GURL url_viewsource = GURL("view-source:" + url.spec()); NavigateToURL(url_viewsource); - EXPECT_FALSE(IsPageMenuCommandEnabled(IDC_VIEWSOURCE)); + EXPECT_FALSE(IsPageMenuCommandEnabled(IDC_VIEW_SOURCE)); } diff --git a/chrome/browser/views/find_bar_win_uitest.cc b/chrome/browser/views/find_bar_win_uitest.cc index 7350779..2354d72a 100644 --- a/chrome/browser/views/find_bar_win_uitest.cc +++ b/chrome/browser/views/find_bar_win_uitest.cc @@ -255,7 +255,7 @@ TEST_F(FindInPageControllerTest, FindMovesOnTabClose_Issue1343052) { ASSERT_TRUE(browser.get() != NULL); // Toggle the bookmark bar state. - browser->ApplyAccelerator(IDC_SHOW_BOOKMARKS_BAR); + browser->ApplyAccelerator(IDC_SHOW_BOOKMARK_BAR); EXPECT_TRUE(WaitForBookmarkBarVisibilityChange(browser.get(), true)); // Open the Find window and wait for it to animate. @@ -280,8 +280,8 @@ TEST_F(FindInPageControllerTest, FindMovesOnTabClose_Issue1343052) { EXPECT_EQ(x, new_x); EXPECT_EQ(y, new_y); - // Now reset the bookmarks bar state and try the same again. - browser->ApplyAccelerator(IDC_SHOW_BOOKMARKS_BAR); + // Now reset the bookmark bar state and try the same again. + browser->ApplyAccelerator(IDC_SHOW_BOOKMARK_BAR); EXPECT_TRUE(WaitForBookmarkBarVisibilityChange(browser.get(), false)); // Bookmark bar has moved, reset our coordinates. diff --git a/chrome/browser/views/frame/browser_view.cc b/chrome/browser/views/frame/browser_view.cc index ccbb950..7c84c6d 100644 --- a/chrome/browser/views/frame/browser_view.cc +++ b/chrome/browser/views/frame/browser_view.cc @@ -82,22 +82,22 @@ static const int kLoadingAnimationFrameTimeMs = 30; static const struct { bool separator; int command; int label; } kMenuLayout[] = { { true, 0, 0 }, - { false, IDC_TASKMANAGER, IDS_TASKMANAGER }, + { false, IDC_TASK_MANAGER, IDS_TASK_MANAGER }, { true, 0, 0 }, - { false, IDC_ENCODING, IDS_ENCODING }, - { false, IDC_ZOOM, IDS_ZOOM }, + { false, IDC_ENCODING_MENU, IDS_ENCODING_MENU }, + { false, IDC_ZOOM_MENU, IDS_ZOOM_MENU }, { false, IDC_PRINT, IDS_PRINT }, - { false, IDC_SAVEPAGE, IDS_SAVEPAGEAS }, - { false, IDC_FIND, IDS_FIND_IN_PAGE }, + { false, IDC_SAVE_PAGE, IDS_SAVE_PAGE }, + { false, IDC_FIND, IDS_FIND }, { true, 0, 0 }, { false, IDC_PASTE, IDS_PASTE }, { false, IDC_COPY, IDS_COPY }, { false, IDC_CUT, IDS_CUT }, { true, 0, 0 }, - { false, IDC_NEWTAB, IDS_APP_MENU_NEW_WEB_PAGE }, + { false, IDC_NEW_TAB, IDS_APP_MENU_NEW_WEB_PAGE }, { false, IDC_SHOW_AS_TAB, IDS_SHOW_AS_TAB }, { false, IDC_COPY_URL, IDS_APP_MENU_COPY_URL }, - { false, IDC_DUPLICATE, IDS_APP_MENU_DUPLICATE }, + { false, IDC_DUPLICATE_TAB, IDS_APP_MENU_DUPLICATE_APP_WINDOW }, { true, 0, 0 }, { false, IDC_RELOAD, IDS_APP_MENU_RELOAD }, { false, IDC_FORWARD, IDS_CONTENT_CONTEXT_FORWARD }, @@ -991,8 +991,8 @@ void BrowserView::InitSystemMenu() { // to change. if (browser_->type() == Browser::TYPE_NORMAL) { system_menu_->AddSeparator(insertion_index); - system_menu_->AddMenuItemWithLabel(insertion_index, IDC_TASKMANAGER, - l10n_util::GetString(IDS_TASKMANAGER)); + system_menu_->AddMenuItemWithLabel(insertion_index, IDC_TASK_MANAGER, + l10n_util::GetString(IDS_TASK_MANAGER)); // If it's a regular browser window with tabs, we don't add any more items, // since it already has menus (Page, Chrome). } else { @@ -1250,17 +1250,17 @@ void BrowserView::BuildMenuForTabStriplessWindow(Menu* menu, menu->AddSeparator(insertion_index); } else { int command = kMenuLayout[i].command; - if (command == IDC_ENCODING) { + if (command == IDC_ENCODING_MENU) { Menu* encoding_menu = menu->AddSubMenu( insertion_index, - IDC_ENCODING, - l10n_util::GetString(IDS_ENCODING)); + IDC_ENCODING_MENU, + l10n_util::GetString(IDS_ENCODING_MENU)); encoding_menu->set_delegate(encoding_menu_delegate_.get()); EncodingMenuControllerDelegate::BuildEncodingMenu(browser_->profile(), encoding_menu); - } else if (command == IDC_ZOOM) { - Menu* zoom_menu = menu->AddSubMenu(insertion_index, IDC_ZOOM, - l10n_util::GetString(IDS_ZOOM)); + } else if (command == IDC_ZOOM_MENU) { + Menu* zoom_menu = menu->AddSubMenu(insertion_index, IDC_ZOOM_MENU, + l10n_util::GetString(IDS_ZOOM_MENU)); zoom_menu->AppendMenuItemWithLabel( IDC_ZOOM_PLUS, l10n_util::GetString(IDS_ZOOM_PLUS)); @@ -1293,11 +1293,11 @@ int BrowserView::GetCommandIDForAppCommandID(int app_command_id) const { case APPCOMMAND_BROWSER_SEARCH: return IDC_FOCUS_SEARCH; case APPCOMMAND_CLOSE: - return IDC_CLOSETAB; + return IDC_CLOSE_TAB; case APPCOMMAND_NEW: - return IDC_NEWTAB; + return IDC_NEW_TAB; case APPCOMMAND_OPEN: - return IDC_OPENFILE; + return IDC_OPEN_FILE; case APPCOMMAND_PRINT: return IDC_PRINT; diff --git a/chrome/browser/views/location_bar_view.cc b/chrome/browser/views/location_bar_view.cc index c8a4ebc..30a8a8c 100644 --- a/chrome/browser/views/location_bar_view.cc +++ b/chrome/browser/views/location_bar_view.cc @@ -321,7 +321,7 @@ void LocationBarView::OnAutocompleteAccept( if (controller_) { if (alternate_nav_url.empty()) { - controller_->ExecuteCommand(IDC_OPENURL); + controller_->ExecuteCommand(IDC_OPEN_CURRENT_URL); return; } @@ -330,7 +330,7 @@ void LocationBarView::OnAutocompleteAccept( // The AlternateNavURLFetcher will listen for the pending navigation // notification that will be issued as a result of the "open URL." It // will automatically install itself into that navigation controller. - controller_->ExecuteCommand(IDC_OPENURL); + controller_->ExecuteCommand(IDC_OPEN_CURRENT_URL); if (fetcher->state() == AlternateNavURLFetcher::NOT_STARTED) { // I'm not sure this should be reachable, but I'm not also sure enough // that it shouldn't to stick in a NOTREACHED(). In any case, this is diff --git a/chrome/browser/views/toolbar_view.cc b/chrome/browser/views/toolbar_view.cc index 246f1c7..e46ca09 100644 --- a/chrome/browser/views/toolbar_view.cc +++ b/chrome/browser/views/toolbar_view.cc @@ -470,8 +470,8 @@ void BrowserToolbarView::RunPageMenu(const CPoint& pt, HWND hwnd) { Menu menu(this, anchor, hwnd); // The install menu may be dynamically generated with a contextual label. // See browser_commands.cc. - menu.AppendMenuItemWithLabel(IDC_CREATE_SHORTCUT, - l10n_util::GetString(IDS_DEFAULT_INSTALL_SITE_LABEL)); + menu.AppendMenuItemWithLabel(IDC_CREATE_SHORTCUTS, + l10n_util::GetString(IDS_CREATE_SHORTCUTS)); menu.AppendSeparator(); menu.AppendMenuItemWithLabel(IDC_CUT, l10n_util::GetString(IDS_CUT)); menu.AppendMenuItemWithLabel(IDC_COPY, l10n_util::GetString(IDS_COPY)); @@ -479,14 +479,14 @@ void BrowserToolbarView::RunPageMenu(const CPoint& pt, HWND hwnd) { menu.AppendSeparator(); menu.AppendMenuItemWithLabel(IDC_FIND, - l10n_util::GetString(IDS_FIND_IN_PAGE)); - menu.AppendMenuItemWithLabel(IDC_SAVEPAGE, - l10n_util::GetString(IDS_SAVEPAGEAS)); + l10n_util::GetString(IDS_FIND)); + menu.AppendMenuItemWithLabel(IDC_SAVE_PAGE, + l10n_util::GetString(IDS_SAVE_PAGE)); menu.AppendMenuItemWithLabel(IDC_PRINT, l10n_util::GetString(IDS_PRINT)); menu.AppendSeparator(); - Menu* zoom_menu = menu.AppendSubMenu(IDC_ZOOM, - l10n_util::GetString(IDS_ZOOM)); + Menu* zoom_menu = menu.AppendSubMenu(IDC_ZOOM_MENU, + l10n_util::GetString(IDS_ZOOM_MENU)); zoom_menu->AppendMenuItemWithLabel(IDC_ZOOM_PLUS, l10n_util::GetString(IDS_ZOOM_PLUS)); zoom_menu->AppendMenuItemWithLabel(IDC_ZOOM_NORMAL, @@ -495,8 +495,8 @@ void BrowserToolbarView::RunPageMenu(const CPoint& pt, HWND hwnd) { l10n_util::GetString(IDS_ZOOM_MINUS)); // Create encoding menu. - Menu* encoding_menu = menu.AppendSubMenu(IDC_ENCODING, - l10n_util::GetString(IDS_ENCODING)); + Menu* encoding_menu = menu.AppendSubMenu( + IDC_ENCODING_MENU, l10n_util::GetString(IDS_ENCODING_MENU)); EncodingMenuControllerDelegate::BuildEncodingMenu(profile_, encoding_menu); @@ -505,15 +505,15 @@ void BrowserToolbarView::RunPageMenu(const CPoint& pt, HWND hwnd) { unsigned int menu_label_id; }; struct MenuCreateMaterial developer_menu_materials[] = { - { IDC_VIEWSOURCE, IDS_VIEWPAGESOURCE }, + { IDC_VIEW_SOURCE, IDS_VIEW_SOURCE }, { IDC_DEBUGGER, IDS_DEBUGGER }, - { IDC_SHOW_JS_CONSOLE, IDS_VIEWJSCONSOLE }, - { IDC_TASKMANAGER, IDS_TASKMANAGER } + { IDC_JS_CONSOLE, IDS_JS_CONSOLE }, + { IDC_TASK_MANAGER, IDS_TASK_MANAGER } }; // Append developer menu. menu.AppendSeparator(); - Menu* developer_menu = - menu.AppendSubMenu(IDC_DEVELOPER, l10n_util::GetString(IDS_DEVELOPER)); + Menu* developer_menu = menu.AppendSubMenu(IDC_DEVELOPER_MENU, + l10n_util::GetString(IDS_DEVELOPER_MENU)); for (int i = 0; i < arraysize(developer_menu_materials); ++i) { if (developer_menu_materials[i].menu_id) { developer_menu->AppendMenuItemWithLabel( @@ -526,8 +526,8 @@ void BrowserToolbarView::RunPageMenu(const CPoint& pt, HWND hwnd) { menu.AppendSeparator(); - menu.AppendMenuItemWithLabel(IDS_COMMANDS_REPORTBUG, - l10n_util::GetString(IDS_COMMANDS_REPORTBUG)); + menu.AppendMenuItemWithLabel(IDC_REPORT_BUG, + l10n_util::GetString(IDS_REPORT_BUG)); menu.RunMenuAt(pt.x, pt.y); } @@ -537,23 +537,23 @@ void BrowserToolbarView::RunAppMenu(const CPoint& pt, HWND hwnd) { anchor = Menu::TOPLEFT; Menu menu(this, anchor, hwnd); - menu.AppendMenuItemWithLabel(IDC_NEWTAB, l10n_util::GetString(IDS_NEWTAB)); - menu.AppendMenuItemWithLabel(IDC_NEWWINDOW, - l10n_util::GetString(IDS_NEWWINDOW)); - menu.AppendMenuItemWithLabel(IDC_GOOFFTHERECORD, - l10n_util::GetString(IDS_GOOFFTHERECORD)); + menu.AppendMenuItemWithLabel(IDC_NEW_TAB, l10n_util::GetString(IDS_NEW_TAB)); + menu.AppendMenuItemWithLabel(IDC_NEW_WINDOW, + l10n_util::GetString(IDS_NEW_WINDOW)); + menu.AppendMenuItemWithLabel(IDC_NEW_INCOGNITO_WINDOW, + l10n_util::GetString(IDS_NEW_INCOGNITO_WINDOW)); // Enumerate profiles asynchronously and then create the parent menu item // "Open new window in profile...". We will create the child menu items for // this once the asynchronous call is done. See OnGetProfilesDone. profiles_helper_->GetProfiles(NULL); Menu* profiles_menu = menu.AppendSubMenu( - IDC_NEWPROFILEWINDOW, - l10n_util::GetString(IDS_NEWPROFILEWINDOW)); + IDC_PROFILE_MENU, + l10n_util::GetString(IDS_PROFILE_MENU)); profiles_menu_ = profiles_menu; menu.AppendSeparator(); - menu.AppendMenuItemWithLabel(IDC_SHOW_BOOKMARKS_BAR, + menu.AppendMenuItemWithLabel(IDC_SHOW_BOOKMARK_BAR, l10n_util::GetString(IDS_SHOW_BOOKMARK_BAR)); menu.AppendSeparator(); menu.AppendMenuItemWithLabel(IDC_SHOW_HISTORY, @@ -568,13 +568,12 @@ void BrowserToolbarView::RunAppMenu(const CPoint& pt, HWND hwnd) { menu.AppendMenuItemWithLabel(IDC_IMPORT_SETTINGS, l10n_util::GetString(IDS_IMPORT_SETTINGS)); menu.AppendSeparator(); - menu.AppendMenuItemWithLabel(IDC_OPTIONS, - l10n_util::GetStringF(IDS_OPTIONS, - l10n_util::GetString(IDS_PRODUCT_NAME))); - menu.AppendMenuItemWithLabel(IDC_ABOUT, - l10n_util::GetStringF(IDS_ABOUT, - l10n_util::GetString(IDS_PRODUCT_NAME))); - menu.AppendMenuItemWithLabel(IDC_HELPMENU, l10n_util::GetString(IDS_HELP)); + menu.AppendMenuItemWithLabel(IDC_OPTIONS, l10n_util::GetStringF(IDS_OPTIONS, + l10n_util::GetString(IDS_PRODUCT_NAME))); + menu.AppendMenuItemWithLabel(IDC_ABOUT, l10n_util::GetStringF(IDS_ABOUT, + l10n_util::GetString(IDS_PRODUCT_NAME))); + menu.AppendMenuItemWithLabel(IDC_HELP_PAGE, + l10n_util::GetString(IDS_HELP_PAGE)); menu.AppendSeparator(); menu.AppendMenuItemWithLabel(IDC_EXIT, l10n_util::GetString(IDS_EXIT)); @@ -587,7 +586,7 @@ void BrowserToolbarView::RunAppMenu(const CPoint& pt, HWND hwnd) { bool BrowserToolbarView::IsItemChecked(int id) const { if (!profile_) return false; - if (id == IDC_SHOW_BOOKMARKS_BAR) + if (id == IDC_SHOW_BOOKMARK_BAR) return profile_->GetPrefs()->GetBoolean(prefs::kShowBookmarkBar); else return EncodingMenuControllerDelegate::IsItemChecked(id); @@ -617,12 +616,12 @@ void BrowserToolbarView::OnGetProfilesDone( browser_->set_user_data_dir_profiles(profiles); // Number of sub menu items that we can show directly. - const int sub_items_count = IDC_NEWPROFILEWINDOW_MAX_ID - - IDC_NEWPROFILEWINDOW_MIN_ID + 1; + const int sub_items_count = IDC_NEW_WINDOW_PROFILE_0 - + IDC_NEW_WINDOW_PROFILE_LAST + 1; std::vector<std::wstring>::const_iterator iter = profiles.begin(); // Add direct sub menu items for profiles. - for (int i = IDC_NEWPROFILEWINDOW_MIN_ID; - i <= IDC_NEWPROFILEWINDOW_MAX_ID && iter != profiles.end(); + for (int i = IDC_NEW_WINDOW_PROFILE_0; + i <= IDC_NEW_WINDOW_PROFILE_LAST && iter != profiles.end(); ++i, ++iter) { profiles_menu_->AppendMenuItemWithLabel(i, *iter); } @@ -630,8 +629,7 @@ void BrowserToolbarView::OnGetProfilesDone( if (iter != profiles.end()) { profiles_menu_->AppendSeparator(); profiles_menu_->AppendMenuItemWithLabel( - IDC_SELECT_PROFILE, - l10n_util::GetString(IDS_NEWPROFILEWINDOW_OTHERPROFILE)); + IDC_SELECT_PROFILE, l10n_util::GetString(IDS_SELECT_PROFILE)); } // Always show a link to select a new profile. profiles_menu_->AppendSeparator(); @@ -752,8 +750,8 @@ void BrowserToolbarView::ExecuteCommand(int id) { // If the command id is for one of the sub-menu-items of the new profile // window menu then we need to get the name of the profile from the menu // item id and then pass on that to the browser to take action. - if (id >= IDC_NEWPROFILEWINDOW_MIN_ID && id <= IDC_NEWPROFILEWINDOW_MAX_ID) { - browser_->NewProfileWindowByIndex(id - IDC_NEWPROFILEWINDOW_MIN_ID); + if (id >= IDC_NEW_WINDOW_PROFILE_0 && id <= IDC_NEW_WINDOW_PROFILE_LAST) { + browser_->NewProfileWindowByIndex(id - IDC_NEW_WINDOW_PROFILE_0); return; } diff --git a/chrome/renderer/webplugin_delegate_proxy.cc b/chrome/renderer/webplugin_delegate_proxy.cc index c688817..3525a1f 100644 --- a/chrome/renderer/webplugin_delegate_proxy.cc +++ b/chrome/renderer/webplugin_delegate_proxy.cc @@ -675,7 +675,7 @@ void WebPluginDelegateProxy::PaintSadPlugin(HDC hdc, const gfx::Rect& rect) { if (!sad_plugin_) { sad_plugin_ = ResourceBundle::LoadBitmap( - _AtlBaseModule.GetResourceInstance(), IDR_CRASHED_PLUGIN); + _AtlBaseModule.GetResourceInstance(), IDR_SAD_PLUGIN); } if (sad_plugin_) { diff --git a/chrome/test/accessibility/accessibility_tests.cc b/chrome/test/accessibility/accessibility_tests.cc index 42c087a..1eacede 100644 --- a/chrome/test/accessibility/accessibility_tests.cc +++ b/chrome/test/accessibility/accessibility_tests.cc @@ -210,7 +210,7 @@ TEST_F(AccessibilityTest, TestStarBtnStatusOnNewTab) { // Add empty new tab and check status. int old_tab_count = -1; ASSERT_TRUE(window->GetTabCount(&old_tab_count)); - ASSERT_TRUE(window->ApplyAccelerator(IDC_NEWTAB)); + ASSERT_TRUE(window->ApplyAccelerator(IDC_NEW_TAB)); int new_tab_count; ASSERT_TRUE(window->WaitForTabCountToChange(old_tab_count, &new_tab_count, 5000)); @@ -335,7 +335,7 @@ TEST_F(AccessibilityTest, DISABLED_TestBackBtnStatusOnNewTab) { // Add empty new tab and check status. ASSERT_TRUE(window->GetTabCount(&old_tab_count)); - ASSERT_TRUE(window->ApplyAccelerator(IDC_NEWTAB)); + ASSERT_TRUE(window->ApplyAccelerator(IDC_NEW_TAB)); ASSERT_TRUE(window->WaitForTabCountToChange(old_tab_count, &new_tab_count, 5000)); // Check tab count. Also, check accessibility object's children. @@ -484,7 +484,7 @@ TEST_F(AccessibilityTest, DISABLED_TestForwardBtnStatusOnNewTab) { // Add empty new tab and check status. ASSERT_TRUE(window->GetTabCount(&old_tab_count)); - ASSERT_TRUE(window->ApplyAccelerator(IDC_NEWTAB)); + ASSERT_TRUE(window->ApplyAccelerator(IDC_NEW_TAB)); ASSERT_TRUE(window->WaitForTabCountToChange(old_tab_count, &new_tab_count, 5000)); // Check tab count. diff --git a/chrome/test/automated_ui_tests/automated_ui_tests.cc b/chrome/test/automated_ui_tests/automated_ui_tests.cc index f96a261..3f1f317 100644 --- a/chrome/test/automated_ui_tests/automated_ui_tests.cc +++ b/chrome/test/automated_ui_tests/automated_ui_tests.cc @@ -328,7 +328,7 @@ bool AutomatedUITest::DoAction(const std::string & action) { } else if (LowerCaseEqualsASCII(action, "selectprevtab")) { did_complete_action = SelectPreviousTab(); } else if (LowerCaseEqualsASCII(action, "showbookmarks")) { - did_complete_action = ShowBookmarksBar(); + did_complete_action = ShowBookmarkBar(); } else if (LowerCaseEqualsASCII(action, "setup")) { LaunchBrowserAndServer(); did_complete_action = true; @@ -445,7 +445,7 @@ bool AutomatedUITest::CloseActiveTab() { // Avoid quitting the application by not closing the last window. if (tab_count > 1) { int new_tab_count; - return_value = browser->RunCommand(IDC_CLOSETAB); + return_value = browser->RunCommand(IDC_CLOSE_TAB); // Wait for the tab to close before we continue. if (!browser->WaitForTabCountToChange( tab_count, &new_tab_count, kWaitForActionMaxMsec)) { @@ -454,7 +454,7 @@ bool AutomatedUITest::CloseActiveTab() { } } else if (tab_count == 1 && browser_windows_count > 1) { int new_window_count; - return_value = browser->RunCommand(IDC_CLOSETAB); + return_value = browser->RunCommand(IDC_CLOSE_TAB); // Wait for the window to close before we continue. if (!automation()->WaitForWindowCountToChange( browser_windows_count, &new_window_count, kWaitForActionMaxMsec)) { @@ -469,7 +469,7 @@ bool AutomatedUITest::CloseActiveTab() { } bool AutomatedUITest::DuplicateTab() { - return RunCommand(IDC_DUPLICATE); + return RunCommand(IDC_DUPLICATE_TAB); } bool AutomatedUITest::FindInPage() { @@ -481,7 +481,7 @@ bool AutomatedUITest::ForwardButton() { } bool AutomatedUITest::GoOffTheRecord() { - return RunCommand(IDC_GOOFFTHERECORD); + return RunCommand(IDC_NEW_INCOGNITO_WINDOW); } bool AutomatedUITest::Home() { @@ -489,7 +489,7 @@ bool AutomatedUITest::Home() { } bool AutomatedUITest::JavaScriptConsole() { - return RunCommand(IDC_SHOW_JS_CONSOLE); + return RunCommand(IDC_JS_CONSOLE); } bool AutomatedUITest::JavaScriptDebugger() { @@ -541,7 +541,7 @@ bool AutomatedUITest::NewTab() { &is_timeout); // Apply accelerator and wait for a new tab to open, if either // fails, return false. Apply Accelerator takes care of logging its failure. - bool return_value = RunCommand(IDC_NEWTAB); + bool return_value = RunCommand(IDC_NEW_TAB); if (!browser->WaitForTabCountToChange( old_tab_count, &new_tab_count, kWaitForActionMaxMsec)) { AddWarningAttribute("tab_count_failed_to_change"); @@ -567,7 +567,7 @@ bool AutomatedUITest::OpenImportSettingsDialog() { } bool AutomatedUITest::OpenTaskManagerDialog() { - return RunCommand(IDC_TASKMANAGER); + return RunCommand(IDC_TASK_MANAGER); } bool AutomatedUITest::OpenViewPasswordsDialog() { @@ -623,11 +623,11 @@ bool AutomatedUITest::SelectNextTab() { } bool AutomatedUITest::SelectPreviousTab() { - return RunCommand(IDC_SELECT_PREV_TAB); + return RunCommand(IDC_SELECT_PREVIOUS_TAB); } -bool AutomatedUITest::ShowBookmarksBar() { - return RunCommand(IDC_SHOW_BOOKMARKS_BAR); +bool AutomatedUITest::ShowBookmarkBar() { + return RunCommand(IDC_SHOW_BOOKMARK_BAR); } bool AutomatedUITest::ShowDownloads() { @@ -643,7 +643,7 @@ bool AutomatedUITest::StarPage() { } bool AutomatedUITest::ViewSource() { - return RunCommand(IDC_VIEWSOURCE); + return RunCommand(IDC_VIEW_SOURCE); } bool AutomatedUITest::ZoomMinus() { diff --git a/chrome/test/automated_ui_tests/automated_ui_tests.h b/chrome/test/automated_ui_tests/automated_ui_tests.h index 1e2656c..b747d34 100644 --- a/chrome/test/automated_ui_tests/automated_ui_tests.h +++ b/chrome/test/automated_ui_tests/automated_ui_tests.h @@ -286,7 +286,7 @@ class AutomatedUITest : public UITest { // Displays the bookmark bar. // Returns true if call to activate the accelerator is successful. // XML element: <ShowBookmarks/> - bool ShowBookmarksBar(); + bool ShowBookmarkBar(); // Opens the Downloads page in the current active browser window. // XML element: <Downloads/> diff --git a/chrome/test/automation/automation_proxy_uitest.cc b/chrome/test/automation/automation_proxy_uitest.cc index ece5fd8..4a0cd90 100644 --- a/chrome/test/automation/automation_proxy_uitest.cc +++ b/chrome/test/automation/automation_proxy_uitest.cc @@ -476,7 +476,7 @@ TEST_F(AutomationProxyTest, AcceleratorNewTab) { int old_tab_count = -1; ASSERT_TRUE(window->GetTabCount(&old_tab_count)); - ASSERT_TRUE(window->ApplyAccelerator(IDC_NEWTAB)); + ASSERT_TRUE(window->ApplyAccelerator(IDC_NEW_TAB)); int new_tab_count; ASSERT_TRUE(window->WaitForTabCountToChange(old_tab_count, &new_tab_count, 5000)); @@ -785,7 +785,7 @@ TEST_F(AutomationProxyTest, AutocompleteParallelProxy) { scoped_ptr<AutocompleteEditProxy> edit1( automation()->GetAutocompleteEditForBrowser(browser1.get())); ASSERT_TRUE(edit1.get()); - EXPECT_TRUE(browser1->ApplyAccelerator(IDC_NEWWINDOW)); + EXPECT_TRUE(browser1->ApplyAccelerator(IDC_NEW_WINDOW)); scoped_ptr<BrowserProxy> browser2(automation()->GetBrowserWindow(1)); ASSERT_TRUE(browser2.get()); scoped_ptr<AutocompleteEditProxy> edit2( diff --git a/chrome/test/startup/feature_startup_test.cc b/chrome/test/startup/feature_startup_test.cc index 59fdfa1..28d16e8 100644 --- a/chrome/test/startup/feature_startup_test.cc +++ b/chrome/test/startup/feature_startup_test.cc @@ -69,7 +69,7 @@ class NewTabUIStartupTest : public UITest { ASSERT_EQ(1, old_tab_count); // Hit ctl-t and wait for the tab to load. - window->ApplyAccelerator(IDC_NEWTAB); + window->ApplyAccelerator(IDC_NEW_TAB); int new_tab_count = -1; ASSERT_TRUE(window->WaitForTabCountToChange(old_tab_count, &new_tab_count, 5000)); @@ -82,9 +82,9 @@ class NewTabUIStartupTest : public UITest { // Bring up a second tab, now that we've already shown one tab. old_tab_count = new_tab_count; new_tab_count = -1; - window->ApplyAccelerator(IDC_NEWTAB); - ASSERT_TRUE(window->WaitForTabCountToChange(old_tab_count, &new_tab_count, - 5000)); + window->ApplyAccelerator(IDC_NEW_TAB); + ASSERT_TRUE(window->WaitForTabCountToChange(old_tab_count, + &new_tab_count, 5000)); ASSERT_EQ(3, new_tab_count); ASSERT_TRUE(automation()->WaitForInitialNewTabUILoad(&load_time)); timings[i] = TimeDelta::FromMilliseconds(load_time); diff --git a/chrome/test/ui/ui_test.cc b/chrome/test/ui/ui_test.cc index 5b549a0..35f09cf 100644 --- a/chrome/test/ui/ui_test.cc +++ b/chrome/test/ui/ui_test.cc @@ -292,7 +292,7 @@ void UITest::QuitBrowser() { for (BrowserVector::iterator iter = browsers.begin(); iter != browsers.end(); ++iter) { // Use ApplyAccelerator since it doesn't wait - (*iter)->ApplyAccelerator(IDC_CLOSEWINDOW); + (*iter)->ApplyAccelerator(IDC_CLOSE_WINDOW); delete (*iter); } diff --git a/chrome/views/text_field.cc b/chrome/views/text_field.cc index 7bc4859..14a9305 100644 --- a/chrome/views/text_field.cc +++ b/chrome/views/text_field.cc @@ -290,8 +290,8 @@ TextField::Edit::Edit(TextField* parent, bool draw_border) context_menu_->AppendMenuItemWithLabel(IDS_PASTE, l10n_util::GetString(IDS_PASTE)); context_menu_->AppendSeparator(); - context_menu_->AppendMenuItemWithLabel(IDS_SELECTALL, - l10n_util::GetString(IDS_SELECTALL)); + context_menu_->AppendMenuItemWithLabel(IDS_SELECT_ALL, + l10n_util::GetString(IDS_SELECT_ALL)); } TextField::Edit::~Edit() { @@ -360,13 +360,13 @@ void TextField::Edit::SetBackgroundColor(COLORREF bg_color) { bool TextField::Edit::IsCommandEnabled(int id) const { switch (id) { - case IDS_UNDO: return !parent_->IsReadOnly() && !!CanUndo(); - case IDS_CUT: return !parent_->IsReadOnly() && !!CanCut(); - case IDS_COPY: return !!CanCopy(); - case IDS_PASTE: return !parent_->IsReadOnly() && !!CanPaste(); - case IDS_SELECTALL: return !!CanSelectAll(); - default: NOTREACHED(); - return false; + case IDS_UNDO: return !parent_->IsReadOnly() && !!CanUndo(); + case IDS_CUT: return !parent_->IsReadOnly() && !!CanCut(); + case IDS_COPY: return !!CanCopy(); + case IDS_PASTE: return !parent_->IsReadOnly() && !!CanPaste(); + case IDS_SELECT_ALL: return !!CanSelectAll(); + default: NOTREACHED(); + return false; } } @@ -374,12 +374,12 @@ void TextField::Edit::ExecuteCommand(int id) { ScopedFreeze freeze(this, GetTextObjectModel()); OnBeforePossibleChange(); switch (id) { - case IDS_UNDO: Undo(); break; - case IDS_CUT: Cut(); break; - case IDS_COPY: Copy(); break; - case IDS_PASTE: Paste(); break; - case IDS_SELECTALL: SelectAll(); break; - default: NOTREACHED(); break; + case IDS_UNDO: Undo(); break; + case IDS_CUT: Cut(); break; + case IDS_COPY: Copy(); break; + case IDS_PASTE: Paste(); break; + case IDS_SELECT_ALL: SelectAll(); break; + default: NOTREACHED(); break; } OnAfterPossibleChange(); } |