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

Unified Diff: ios/chrome/app/application_delegate/tab_opening.h

Issue 2580363002: Upstream Chrome on iOS source code [1/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
Index: ios/chrome/app/application_delegate/tab_opening.h
diff --git a/ios/chrome/app/application_delegate/tab_opening.h b/ios/chrome/app/application_delegate/tab_opening.h
new file mode 100644
index 0000000000000000000000000000000000000000..93bf7450dd18f584901a0c70cc52bf5526004275
--- /dev/null
+++ b/ios/chrome/app/application_delegate/tab_opening.h
@@ -0,0 +1,38 @@
+// Copyright 2016 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_APP_APPLICATION_DELEGATE_TAB_OPENING_H_
+#define IOS_CHROME_APP_APPLICATION_DELEGATE_TAB_OPENING_H_
+
+#include "base/ios/block_types.h"
+#include "ios/chrome/app/application_mode.h"
+#include "ui/base/page_transition_types.h"
+
+@class AppState;
+@class TabModel;
+@protocol StartupInformation;
+class GURL;
+
+// Protocol for object that can open new tabs during application launch.
+@protocol TabOpening<NSObject>
+
+// Dismisses any modal view then opens either a normal or incognito tab with
+// |url|. After opening |url|, run completion |handler| if it is not nil.
+- (void)dismissModalsAndOpenSelectedTabInMode:(ApplicationMode)targetMode
+ withURL:(const GURL&)url
+ transition:(ui::PageTransition)transition
+ completion:(ProceduralBlock)handler;
+
+// Creates a new tab if the launch options are not null.
+- (void)openTabFromLaunchOptions:(NSDictionary*)launchOptions
+ startupInformation:(id<StartupInformation>)startupInformation
+ appState:(AppState*)appState;
+
+// Returns whether an NTP tab should be opened when the specified tabModel is
+// made current.
+- (BOOL)shouldOpenNTPTabOnActivationOfTabModel:(TabModel*)tabModel;
+
+@end
+
+#endif // IOS_CHROME_APP_APPLICATION_DELEGATE_TAB_OPENING_H_
« no previous file with comments | « ios/chrome/app/application_delegate/startup_information.h ('k') | ios/chrome/app/application_delegate/tab_switching.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698