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

Side by Side Diff: remoting/client/ios/session/remoting_client.h

Issue 2871993003: Moving the iOS directory to be remoting top level. (Closed)
Patch Set: //remoting/ios was the old landing target for the internal iOS application. Fix. Created 3 years, 7 months 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 unified diff | Download patch
« no previous file with comments | « remoting/client/ios/session/BUILD.gn ('k') | remoting/client/ios/session/remoting_client.mm » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
(Empty)
1 // Copyright 2017 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.
4
5 #ifndef REMOTING_CLIENT_IOS_SESSION_REMOTING_CLIENT_H_
6 #define REMOTING_CLIENT_IOS_SESSION_REMOTING_CLIENT_H_
7
8 #import <Foundation/Foundation.h>
9
10 #import "remoting/client/ios/display/gl_display_handler.h"
11
12 #include "remoting/protocol/connection_to_host.h"
13
14 namespace remoting {
15
16 class GestureInterpreter;
17
18 } // namespace remoting
19
20 @class HostInfo;
21 @class GlDisplayHandler;
22
23 // A list of notifications that will be sent out for different types of Remoting
24 // Client events.
25 //
26 extern NSString* const kHostSessionStatusChanged;
27 extern NSString* const kHostSessionPinProvided;
28
29 // List of keys in user info from events.
30 extern NSString* const kSessionDetails;
31 extern NSString* const kSessonStateErrorCode;
32 extern NSString* const kHostSessionPin;
33
34 // Remoting Client is the entry point for starting a session with a remote
35 // host. This object should not be reused. Remoting Client will use the default
36 // NSNotificationCenter to signal session state changes using the key
37 // |kHostSessionStatusChanged|. It expects to receive an event back on
38 // |kHostSessionPinProvided| when the session is asking for a PIN authenication.
39 @interface RemotingClient : NSObject<GlDisplayHandlerDelegate>
40
41 // Connect to a given host.
42 // |hostInfo| is all the details around a host.
43 // |username| is the username to be used when connecting.
44 // |accessToken| is the oAuth access token to provided to create the session.
45 - (void)connectToHost:(HostInfo*)hostInfo
46 username:(NSString*)username
47 accessToken:(NSString*)accessToken;
48
49 // Disconnect the current host connection.
50 - (void)disconnectFromHost;
51
52 // Mirrors the native client session delegate interface:
53
54 - (void)onConnectionState:(remoting::protocol::ConnectionToHost::State)state
55 error:(remoting::protocol::ErrorCode)error;
56
57 - (void)commitPairingCredentialsForHost:(NSString*)host
58 id:(NSString*)id
59 secret:(NSString*)secret;
60
61 - (void)fetchThirdPartyTokenForUrl:(NSString*)tokenUrl
62 clientId:(NSString*)clinetId
63 scope:(NSString*)scope;
64
65 - (void)setCapabilities:(NSString*)capabilities;
66
67 - (void)handleExtensionMessageOfType:(NSString*)type message:(NSString*)message;
68
69 // Notifies all components that the frame of the surface has changed.
70 - (void)surfaceChanged:(const CGRect&)frame;
71
72 // The display handler tied to the remoting client used to display the host.
73 @property(nonatomic, strong) GlDisplayHandler* displayHandler;
74 // The host info used to make the remoting client connection.
75 @property(nonatomic, readonly) HostInfo* hostInfo;
76 // The gesture interpreter used to handle gestures.
77 // This is valid only after the client has connected to the host. Always use
78 // RemotingClient.gestureInterpreter instead of storing the pointer separately.
79 @property(nonatomic, readonly) remoting::GestureInterpreter* gestureInterpreter;
80
81 @end
82
83 #endif // REMOTING_CLIENT_IOS_SESSION_REMOTING_CLIENT_H_
OLDNEW
« no previous file with comments | « remoting/client/ios/session/BUILD.gn ('k') | remoting/client/ios/session/remoting_client.mm » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698