forked from guodong/cloudwarehub-client
-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathcip_protocol.h
More file actions
81 lines (68 loc) · 1.3 KB
/
cip_protocol.h
File metadata and controls
81 lines (68 loc) · 1.3 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
//
// cip_protocol.h
// cip-server
//
// Created by gd on 16/1/11.
// Copyright © 2016年 CloudwareHub. All rights reserved.
//
#ifndef cip_protocol_h
#define cip_protocol_h
#include "cip_defs.h"
enum CIP_CHANNEL {
CIP_CHANNEL_MASTER,
CIP_CHANNEL_EVENT,
CIP_CHANNEL_DISPLAY,
CIP_CHANNEL_DATA,
};
typedef struct {
u8 version;
u8 channel_type;
u16 session_length; /* also used for session_length */
/* token/session */
} cip_message_connect_t;
typedef struct {
u8 success;
u8 _pad[3];
//u16 session_length;
/* session */
} cip_message_connect_reply_t;
enum CIP_EVENT {
CIP_EVENT_WINDOW_CREATE,
CIP_EVENT_WINDOW_DESTROY,
CIP_EVENT_WINDOW_SHOW,
CIP_EVENT_WINDOW_HIDE,
};
typedef struct {
u8 type;
u8 bare;
u8 _pad[2];
u32 wid;
i16 x;
i16 y;
u16 width;
u16 height;
} cip_event_window_create_t;
typedef struct {
u8 type;
u8 _pad[3];
u32 wid;
u8 _pad1[8];
} cip_event_window_destroy_t;
typedef struct {
u8 type;
u8 _pad[3];
u32 wid;
u8 _pad1[8];
} cip_event_window_hide_t;
typedef struct {
u8 type;
u8 bare;
u8 _pad[2];
u32 wid;
u8 _pad1[8];
} cip_event_window_show_t;
typedef struct {
u32 wid;
u32 length;
} cip_event_window_frame_t;
#endif /* cip_protocol_h */