FreeRDP
MRDPView.h
1 #ifndef FREERDP_CLIENT_MAC_MRDPVIEW_H
2 #define FREERDP_CLIENT_MAC_MRDPVIEW_H
3 
23 #import <Cocoa/Cocoa.h>
24 
25 #import "mfreerdp.h"
26 #import "mf_client.h"
27 #import "Keyboard.h"
28 
29 #import <CoreGraphics/CoreGraphics.h>
30 
31 @interface MRDPView : NSView
32 {
33  mfContext *mfc;
34  NSBitmapImageRep *bmiRep;
35  NSMutableArray *cursors;
36  NSMutableArray *windows;
37  NSTimer *pasteboard_timer;
38  NSCursor *currentCursor;
39  NSRect prevWinPosition;
40  freerdp *instance;
41  rdpContext *context;
42  CGContextRef bitmap_context;
43  char *pixel_data;
44  int argc;
45  char **argv;
46  DWORD kbdModFlags;
47  BOOL initialized;
48  NSPoint savedDragLocation;
49  BOOL firstCreateWindow;
50  BOOL isMoveSizeInProgress;
51  BOOL skipResizeOnce;
52  BOOL saveInitialDragLoc;
53  BOOL skipMoveWindowOnce;
54  @public
55  NSPasteboard *pasteboard_rd;
56  NSPasteboard *pasteboard_wr;
57  int pasteboard_changecount;
58  int pasteboard_format;
59  int is_connected;
60 }
61 
62 - (int)rdpStart:(rdpContext *)rdp_context;
63 - (void)setCursor:(NSCursor *)cursor;
64 - (void)setScrollOffset:(int)xOffset y:(int)yOffset w:(int)width h:(int)height;
65 
66 - (void)onPasteboardTimerFired:(NSTimer *)timer;
67 - (void)pause;
68 - (void)resume;
69 - (void)releaseResources;
70 
71 @property(assign) int is_connected;
72 
73 @end
74 
75 BOOL mac_pre_connect(freerdp *instance);
76 BOOL mac_post_connect(freerdp *instance);
77 void mac_post_disconnect(freerdp *instance);
78 BOOL mac_authenticate_ex(freerdp *instance, char **username, char **password, char **domain,
79  rdp_auth_reason reason);
80 
81 DWORD mac_verify_certificate_ex(freerdp *instance, const char *host, UINT16 port,
82  const char *common_name, const char *subject, const char *issuer,
83  const char *fingerprint, DWORD flags);
84 DWORD mac_verify_changed_certificate_ex(freerdp *instance, const char *host, UINT16 port,
85  const char *common_name, const char *subject,
86  const char *issuer, const char *fingerprint,
87  const char *old_subject, const char *old_issuer,
88  const char *old_fingerprint, DWORD flags);
89 
90 int mac_logon_error_info(freerdp *instance, UINT32 data, UINT32 type);
91 #endif /* FREERDP_CLIENT_MAC_MRDPVIEW_H */