diff options
author | estade@chromium.org <estade@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98> | 2009-02-25 00:22:27 +0000 |
---|---|---|
committer | estade@chromium.org <estade@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98> | 2009-02-25 00:22:27 +0000 |
commit | 40bdb6d952d8b20846cdf0c7ee7a4cd4a930898d (patch) | |
tree | 064b6b849ecad44cf99764aeaffc28644148b9da /chrome/browser/browser.cc | |
parent | e2f86d9313ffcdd815e2828f9c0cbf16728d74be (diff) | |
download | chromium_src-40bdb6d952d8b20846cdf0c7ee7a4cd4a930898d.zip chromium_src-40bdb6d952d8b20846cdf0c7ee7a4cd4a930898d.tar.gz chromium_src-40bdb6d952d8b20846cdf0c7ee7a4cd4a930898d.tar.bz2 |
Get save page working on posix.
* rearrange some IFDEFs
* trim whitespace on suggest name
Also fix a relatively new bug in DomSerializer.
Review URL: http://codereview.chromium.org/27106
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@10314 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'chrome/browser/browser.cc')
-rw-r--r-- | chrome/browser/browser.cc | 12 |
1 files changed, 6 insertions, 6 deletions
diff --git a/chrome/browser/browser.cc b/chrome/browser/browser.cc index 9c479a6..5af7a2b 100644 --- a/chrome/browser/browser.cc +++ b/chrome/browser/browser.cc @@ -743,6 +743,11 @@ void Browser::BookmarkCurrentPage() { window_->ShowBookmarkBubble(url, model->IsBookmarked(url)); } +void Browser::SavePage() { + UserMetrics::RecordAction(L"SavePage", profile_); + GetSelectedTabContents()->AsWebContents()->OnSavePage(); +} + void Browser::ViewSource() { UserMetrics::RecordAction(L"ViewSource", profile_); @@ -766,11 +771,6 @@ void Browser::Print() { GetSelectedTabContents()->AsWebContents()->PrintPreview(); } -void Browser::SavePage() { - UserMetrics::RecordAction(L"SavePage", profile_); - GetSelectedTabContents()->AsWebContents()->OnSavePage(); -} - void Browser::ToggleEncodingAutoDetect() { UserMetrics::RecordAction(L"AutoDetectChange", profile_); encoding_auto_detect_.SetValue(!encoding_auto_detect_.GetValue()); @@ -1113,12 +1113,12 @@ void Browser::ExecuteCommand(int id) { case IDC_EXIT: Exit(); break; // Page-related commands + case IDC_SAVE_PAGE: SavePage(); break; case IDC_STAR: BookmarkCurrentPage(); break; case IDC_VIEW_SOURCE: ViewSource(); break; #if defined(OS_WIN) case IDC_CLOSE_POPUPS: ClosePopups(); break; case IDC_PRINT: Print(); break; - case IDC_SAVE_PAGE: SavePage(); break; case IDC_ENCODING_AUTO_DETECT: ToggleEncodingAutoDetect(); break; case IDC_ENCODING_UTF8: case IDC_ENCODING_UTF16LE: |