Make sure to handle skipForNow when the user does not sign in.
[chromium-blink-merge.git] / components / handoff / handoff_utility.h
blob551dabcafcff33756fdcf3e2cdf885b70fd4e2fd
1 // Copyright 2014 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file.
5 #ifndef COMPONENTS_HANDOFF_HANDOFF_UTILITY_H_
6 #define COMPONENTS_HANDOFF_HANDOFF_UTILITY_H_
8 #import <Foundation/Foundation.h>
10 namespace handoff {
12 // The value of this key in the userInfo dictionary of an NSUserActivity
13 // indicates the origin. The value should not be used for any privacy or
14 // security sensitive operations, since any application can set the key/value
15 // pair.
16 extern NSString* const kOriginKey;
18 // This value indicates that an NSUserActivity originated from Chrome on iOS.
19 extern NSString* const kOriginiOS;
21 // This value indicates that an NSUserActivity originated from Chrome on Mac.
22 extern NSString* const kOriginMac;
24 // Used for UMA metrics.
25 enum Origin {
26 ORIGIN_UNKNOWN = 0,
27 ORIGIN_IOS = 1,
28 ORIGIN_MAC = 2,
29 ORIGIN_COUNT
32 // Returns ORIGIN_UNKNOWN if |string| is nil or unrecognized.
33 Origin OriginFromString(NSString* string);
35 } // namespace handoff
37 #endif // COMPONENTS_HANDOFF_HANDOFF_UTILITY_H_