summaryrefslogtreecommitdiffstats
path: root/chrome/browser/autofill
diff options
context:
space:
mode:
Diffstat (limited to 'chrome/browser/autofill')
-rw-r--r--chrome/browser/autofill/autofill_dialog_controller_mac.h6
-rw-r--r--chrome/browser/autofill/autofill_dialog_controller_mac.mm11
2 files changed, 16 insertions, 1 deletions
diff --git a/chrome/browser/autofill/autofill_dialog_controller_mac.h b/chrome/browser/autofill/autofill_dialog_controller_mac.h
index d7b50c3..34e40fa 100644
--- a/chrome/browser/autofill/autofill_dialog_controller_mac.h
+++ b/chrome/browser/autofill/autofill_dialog_controller_mac.h
@@ -119,11 +119,15 @@ class Profile;
// credit card list.
- (IBAction)deleteSelection:(id)sender;
-// IBActions for editing an item. |sender| is expected to be the "Edit..."
+// IBAction for editing an item. |sender| is expected to be the "Edit..."
// button. The editing acts on the selected item in either the address or
// credit card list.
- (IBAction)editSelection:(id)sender;
+// IBAction for opening the help link. |sender| is expected to be the
+// "About AutoFill" link.
+- (IBAction)openHelp:(id)sender;
+
// NSTableView data source methods.
- (id)tableView:(NSTableView *)tableView
objectValueForTableColumn:(NSTableColumn *)tableColumn
diff --git a/chrome/browser/autofill/autofill_dialog_controller_mac.mm b/chrome/browser/autofill/autofill_dialog_controller_mac.mm
index d39c456..72c301b 100644
--- a/chrome/browser/autofill/autofill_dialog_controller_mac.mm
+++ b/chrome/browser/autofill/autofill_dialog_controller_mac.mm
@@ -7,6 +7,8 @@
#include "app/resource_bundle.h"
#include "base/mac_util.h"
#include "base/sys_string_conversions.h"
+#include "chrome/browser/browser.h"
+#include "chrome/browser/browser_list.h"
#import "chrome/browser/autofill/autofill_address_model_mac.h"
#import "chrome/browser/autofill/autofill_address_sheet_controller_mac.h"
#import "chrome/browser/autofill/autofill_credit_card_model_mac.h"
@@ -412,6 +414,15 @@ void PersonalDataManagerObserver::OnPersonalDataLoaded() {
}
}
+// Navigates to the AutoFill help url.
+- (IBAction)openHelp:(id)sender {
+ Browser* browser = BrowserList::GetLastActive();
+
+ if (!browser || !browser->GetSelectedTabContents())
+ browser = Browser::Create(profile_);
+ browser->OpenAutoFillHelpTabAndActivate();
+}
+
// Edit address sheet was dismissed. Non-zero |returnCode| indicates a save.
- (void)addressEditDidEnd:(NSWindow *)sheet
returnCode:(int)returnCode