From 2a93f64f37291ad0b3bf6029dd6fe11d3f7b50ef Mon Sep 17 00:00:00 2001 From: "thomasvl@chromium.org" Date: Mon, 12 Oct 2009 12:13:49 +0000 Subject: Add a learn more hyper link button to the privacy settings area of under the hood prefs. BUG=24424 TEST=under the hood has a working learn more button in the privacy section. Review URL: http://codereview.chromium.org/268028 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@28699 0039d316-1c4b-4281-b951-d872f2087c98 --- chrome/browser/cocoa/preferences_window_controller.h | 1 + chrome/browser/cocoa/preferences_window_controller.mm | 8 ++++++++ 2 files changed, 9 insertions(+) (limited to 'chrome/browser/cocoa') diff --git a/chrome/browser/cocoa/preferences_window_controller.h b/chrome/browser/cocoa/preferences_window_controller.h index f358cb9..a69591c 100644 --- a/chrome/browser/cocoa/preferences_window_controller.h +++ b/chrome/browser/cocoa/preferences_window_controller.h @@ -97,6 +97,7 @@ class Profile; // Under the hood - (IBAction)browseDownloadLocation:(id)sender; +- (IBAction)privacyLearnMore:(id)sender; // When a toolbar button is clicked - (IBAction)toolbarButtonSelected:(id)sender; diff --git a/chrome/browser/cocoa/preferences_window_controller.mm b/chrome/browser/cocoa/preferences_window_controller.mm index ac0a88f..11aa419 100644 --- a/chrome/browser/cocoa/preferences_window_controller.mm +++ b/chrome/browser/cocoa/preferences_window_controller.mm @@ -806,6 +806,14 @@ const int kDisabledIndex = 1; contextInfo:NULL]; } +- (IBAction)privacyLearnMore:(id)sender { + // We open a new browser window so the Options dialog doesn't get lost + // behind other windows. + Browser* browser = Browser::Create(profile_); + browser->OpenURL(GURL(l10n_util::GetStringUTF16(IDS_LEARN_MORE_PRIVACY_URL)), + GURL(), NEW_WINDOW, PageTransition::LINK); +} + - (IBAction)toolbarButtonSelected:(id)sender { DCHECK([sender isKindOfClass:[NSToolbarItem class]]); [self displayPreferenceViewForToolbarItem:sender -- cgit v1.1