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

Unified Diff: ios/chrome/app/spotlight/actions_spotlight_manager.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/spotlight/actions_spotlight_manager.h
diff --git a/ios/chrome/app/spotlight/actions_spotlight_manager.h b/ios/chrome/app/spotlight/actions_spotlight_manager.h
new file mode 100644
index 0000000000000000000000000000000000000000..67f0acb09665afffbc42f85718f0011f9d722765
--- /dev/null
+++ b/ios/chrome/app/spotlight/actions_spotlight_manager.h
@@ -0,0 +1,42 @@
+// 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_SPOTLIGHT_ACTIONS_SPOTLIGHT_MANAGER_H_
+#define IOS_CHROME_APP_SPOTLIGHT_ACTIONS_SPOTLIGHT_MANAGER_H_
+
+#import "ios/chrome/app/spotlight/base_spotlight_manager.h"
+
+@class AppStartupParameters;
+
+namespace spotlight {
+
+// Keys for Spotlight actions.
+extern const char kSpotlightActionNewTab[];
+extern const char kSpotlightActionNewIncognitoTab[];
+extern const char kSpotlightActionVoiceSearch[];
+extern const char kSpotlightActionQRScanner[];
+
+// Sets the correct properties for startup parameters according to the action
+// specified by the |query|. Returns YES if the properties were successfully
+// set. The query must represent an action and |startupParams| must not be nil.
+BOOL SetStartupParametersForSpotlightAction(
+ NSString* query,
+ AppStartupParameters* startupParams);
+
+} // namespace spotlight
+
+// Allows Chrome to add links to actions to the systemwide Spotlight search
+// index.
+@interface ActionsSpotlightManager : BaseSpotlightManager
+
+// Creates an ActionsSpotlightManager.
++ (ActionsSpotlightManager*)actionsSpotlightManager;
+
+// Updates the index with the Spotlight actions if the EnableSpotlightActions
+// experimental flag is set. Otherwise the index is only cleared.
+- (void)indexActions;
+
+@end
+
+#endif // IOS_CHROME_APP_SPOTLIGHT_ACTIONS_SPOTLIGHT_MANAGER_H_
« no previous file with comments | « ios/chrome/app/safe_mode/safe_mode_view_controller_unittest.mm ('k') | ios/chrome/app/spotlight/actions_spotlight_manager.mm » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698