summaryrefslogtreecommitdiffstats
path: root/chrome/browser/cocoa/hyperlink_button_cell.h
diff options
context:
space:
mode:
authorrsesek@chromium.org <rsesek@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2009-09-29 15:34:32 +0000
committerrsesek@chromium.org <rsesek@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2009-09-29 15:34:32 +0000
commitc1275b92a99f3e4163c3cc133132e983a424cc90 (patch)
treef271e81aa7f157d7328f30d8fd97c738e7cb22cc /chrome/browser/cocoa/hyperlink_button_cell.h
parenta5f44c93e83cb964fa4c0529d6333f50ee5e73cf (diff)
downloadchromium_src-c1275b92a99f3e4163c3cc133132e983a424cc90.zip
chromium_src-c1275b92a99f3e4163c3cc133132e983a424cc90.tar.gz
chromium_src-c1275b92a99f3e4163c3cc133132e983a424cc90.tar.bz2
[Mac] Create HyperlinkButtonCell and make the "Get themes" button an instance
* Creates a HyperlinkButtonCell that can be used in conjuction with a NSButton to display the control as a hyperlink (blue underliend text), rather than a normal Cocoa control. * Switch the "Get themes..." button in Preferences to be one. BUG=17989,21414 TEST=Preferences-->Personal Stuff, "Get themes..." is a hyperlink. Review URL: http://codereview.chromium.org/248019 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@27479 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'chrome/browser/cocoa/hyperlink_button_cell.h')
-rw-r--r--chrome/browser/cocoa/hyperlink_button_cell.h21
1 files changed, 21 insertions, 0 deletions
diff --git a/chrome/browser/cocoa/hyperlink_button_cell.h b/chrome/browser/cocoa/hyperlink_button_cell.h
new file mode 100644
index 0000000..67b5c20
--- /dev/null
+++ b/chrome/browser/cocoa/hyperlink_button_cell.h
@@ -0,0 +1,21 @@
+// Copyright (c) 2009 The Chromium Authors. All rights reserved.
+// Use of this source code is governed by a BSD-style license that can be
+// found in the LICENSE file.
+
+#import <Cocoa/Cocoa.h>
+#include "base/scoped_nsobject.h"
+
+// A HyperlinkButtonCell is used to create an NSButton that looks and acts
+// like a hyperlink. The default styling is to look like blue, underlined text
+// and to have the pointingHand cursor on mouse over.
+//
+// To use in Interface Builder:
+// 1. Drag out an NSButton.
+// 2. Double click on the button so you have the cell component selected.
+// 3. In the Identity panel of the inspector, set the custom class to this.
+@interface HyperlinkButtonCell : NSButtonCell {
+ scoped_nsobject<NSColor> textColor_;
+}
+@property (retain) NSColor* textColor;
+
+@end