Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(99)

Unified Diff: ios/chrome/browser/ui/toolbar/new_tab_button.h

Issue 2588733002: Upstream Chrome on iOS source code [9/11]. (Closed)
Patch Set: Created 4 years ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « ios/chrome/browser/ui/toolbar/README.md ('k') | ios/chrome/browser/ui/toolbar/new_tab_button.mm » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: ios/chrome/browser/ui/toolbar/new_tab_button.h
diff --git a/ios/chrome/browser/ui/toolbar/new_tab_button.h b/ios/chrome/browser/ui/toolbar/new_tab_button.h
new file mode 100644
index 0000000000000000000000000000000000000000..7e26ea257bd3b119b4e7e72bc243c7e097823e3a
--- /dev/null
+++ b/ios/chrome/browser/ui/toolbar/new_tab_button.h
@@ -0,0 +1,26 @@
+// Copyright 2012 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.
+
+#ifndef IOS_CHROME_BROWSER_UI_TOOLBAR_NEW_TAB_BUTTON_H_
+#define IOS_CHROME_BROWSER_UI_TOOLBAR_NEW_TAB_BUTTON_H_
+
+#import <UIKit/UIKit.h>
+
+// UIButton subclass used for the New Tab button in the phone switcher toolbar
+// and the tablet no-tabs toolbar. A NewTabButton has a custom background rect
+// and by default will call it's own (derived) -chromeExecuteCommand method
+// on |TouchUpInside|, and has a tag of |IDC_NEW_TAB|. Instances can add further
+// targets.
+@interface NewTabButton : UIButton
+// Whether the button opens incognito tabs or not; setting this property changes
+// the button's behavior, updating its tag to
+// IDS_IOS_TOOLS_MENU_NEW_INCOGNITO_TAB, and updates its appearance.
+@property(nonatomic, assign, getter=isIncognito) BOOL incognito;
+
+// If |animated|, animates the transition of the foreground image of the button.
+- (void)setIncognito:(BOOL)incognito animated:(BOOL)animated;
+
+@end
+
+#endif // IOS_CHROME_BROWSER_UI_TOOLBAR_NEW_TAB_BUTTON_H_
« no previous file with comments | « ios/chrome/browser/ui/toolbar/README.md ('k') | ios/chrome/browser/ui/toolbar/new_tab_button.mm » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698