mirror of
https://github.com/lwch/natpass.git
synced 2026-10-21 05:22:00 +00:00
修改msg数据结构定义
This commit is contained in:
@@ -12,7 +12,7 @@ func (conn *Conn) SendVNCImage(to string, toIdx uint32, id string, screen, rect
|
||||
var msg network.Msg
|
||||
msg.To = to
|
||||
msg.ToIdx = toIdx
|
||||
msg.XType = network.Msg_shell_resize
|
||||
msg.XType = network.Msg_vnc_image
|
||||
msg.LinkId = id
|
||||
msg.Payload = &network.Msg_Vimg{
|
||||
Vimg: &network.VncImage{
|
||||
|
||||
+20
-16
@@ -35,9 +35,10 @@ const (
|
||||
Msg_shell_data MsgType = 11
|
||||
// vnc
|
||||
Msg_vnc_ctrl MsgType = 20
|
||||
Msg_vnc_mouse MsgType = 21
|
||||
Msg_vnc_keyboard MsgType = 22
|
||||
Msg_vnc_cad MsgType = 23 // ctrl+alt+del
|
||||
Msg_vnc_image MsgType = 21
|
||||
Msg_vnc_mouse MsgType = 22
|
||||
Msg_vnc_keyboard MsgType = 23
|
||||
Msg_vnc_cad MsgType = 24 // ctrl+alt+del
|
||||
)
|
||||
|
||||
// Enum value maps for MsgType.
|
||||
@@ -53,9 +54,10 @@ var (
|
||||
10: "shell_resize",
|
||||
11: "shell_data",
|
||||
20: "vnc_ctrl",
|
||||
21: "vnc_mouse",
|
||||
22: "vnc_keyboard",
|
||||
23: "vnc_cad",
|
||||
21: "vnc_image",
|
||||
22: "vnc_mouse",
|
||||
23: "vnc_keyboard",
|
||||
24: "vnc_cad",
|
||||
}
|
||||
MsgType_value = map[string]int32{
|
||||
"unknown": 0,
|
||||
@@ -68,9 +70,10 @@ var (
|
||||
"shell_resize": 10,
|
||||
"shell_data": 11,
|
||||
"vnc_ctrl": 20,
|
||||
"vnc_mouse": 21,
|
||||
"vnc_keyboard": 22,
|
||||
"vnc_cad": 23,
|
||||
"vnc_image": 21,
|
||||
"vnc_mouse": 22,
|
||||
"vnc_keyboard": 23,
|
||||
"vnc_cad": 24,
|
||||
}
|
||||
)
|
||||
|
||||
@@ -400,7 +403,7 @@ var file_msg_proto_rawDesc = []byte{
|
||||
0x09, 0x76, 0x6e, 0x63, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x22, 0x25, 0x0a, 0x11, 0x68, 0x61,
|
||||
0x6e, 0x64, 0x73, 0x68, 0x61, 0x6b, 0x65, 0x5f, 0x70, 0x61, 0x79, 0x6c, 0x6f, 0x61, 0x64, 0x12,
|
||||
0x10, 0x0a, 0x03, 0x65, 0x6e, 0x63, 0x18, 0x01, 0x20, 0x01, 0x28, 0x0c, 0x52, 0x03, 0x65, 0x6e,
|
||||
0x63, 0x22, 0xc2, 0x06, 0x0a, 0x03, 0x6d, 0x73, 0x67, 0x12, 0x26, 0x0a, 0x05, 0x5f, 0x74, 0x79,
|
||||
0x63, 0x22, 0xd1, 0x06, 0x0a, 0x03, 0x6d, 0x73, 0x67, 0x12, 0x26, 0x0a, 0x05, 0x5f, 0x74, 0x79,
|
||||
0x70, 0x65, 0x18, 0x01, 0x20, 0x01, 0x28, 0x0e, 0x32, 0x11, 0x2e, 0x6e, 0x65, 0x74, 0x77, 0x6f,
|
||||
0x72, 0x6b, 0x2e, 0x6d, 0x73, 0x67, 0x2e, 0x74, 0x79, 0x70, 0x65, 0x52, 0x04, 0x54, 0x79, 0x70,
|
||||
0x65, 0x12, 0x12, 0x0a, 0x04, 0x66, 0x72, 0x6f, 0x6d, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52,
|
||||
@@ -438,7 +441,7 @@ var file_msg_proto_rawDesc = []byte{
|
||||
0x75, 0x73, 0x65, 0x48, 0x00, 0x52, 0x06, 0x76, 0x6d, 0x6f, 0x75, 0x73, 0x65, 0x12, 0x2b, 0x0a,
|
||||
0x04, 0x76, 0x6b, 0x62, 0x64, 0x18, 0x21, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x15, 0x2e, 0x6e, 0x65,
|
||||
0x74, 0x77, 0x6f, 0x72, 0x6b, 0x2e, 0x76, 0x6e, 0x63, 0x5f, 0x6b, 0x65, 0x79, 0x62, 0x6f, 0x61,
|
||||
0x72, 0x64, 0x48, 0x00, 0x52, 0x04, 0x76, 0x6b, 0x62, 0x64, 0x22, 0xce, 0x01, 0x0a, 0x04, 0x74,
|
||||
0x72, 0x64, 0x48, 0x00, 0x52, 0x04, 0x76, 0x6b, 0x62, 0x64, 0x22, 0xdd, 0x01, 0x0a, 0x04, 0x74,
|
||||
0x79, 0x70, 0x65, 0x12, 0x0b, 0x0a, 0x07, 0x75, 0x6e, 0x6b, 0x6e, 0x6f, 0x77, 0x6e, 0x10, 0x00,
|
||||
0x12, 0x0d, 0x0a, 0x09, 0x68, 0x61, 0x6e, 0x64, 0x73, 0x68, 0x61, 0x6b, 0x65, 0x10, 0x01, 0x12,
|
||||
0x0d, 0x0a, 0x09, 0x6b, 0x65, 0x65, 0x70, 0x61, 0x6c, 0x69, 0x76, 0x65, 0x10, 0x02, 0x12, 0x0f,
|
||||
@@ -449,11 +452,12 @@ var file_msg_proto_rawDesc = []byte{
|
||||
0x0c, 0x73, 0x68, 0x65, 0x6c, 0x6c, 0x5f, 0x72, 0x65, 0x73, 0x69, 0x7a, 0x65, 0x10, 0x0a, 0x12,
|
||||
0x0e, 0x0a, 0x0a, 0x73, 0x68, 0x65, 0x6c, 0x6c, 0x5f, 0x64, 0x61, 0x74, 0x61, 0x10, 0x0b, 0x12,
|
||||
0x0c, 0x0a, 0x08, 0x76, 0x6e, 0x63, 0x5f, 0x63, 0x74, 0x72, 0x6c, 0x10, 0x14, 0x12, 0x0d, 0x0a,
|
||||
0x09, 0x76, 0x6e, 0x63, 0x5f, 0x6d, 0x6f, 0x75, 0x73, 0x65, 0x10, 0x15, 0x12, 0x10, 0x0a, 0x0c,
|
||||
0x76, 0x6e, 0x63, 0x5f, 0x6b, 0x65, 0x79, 0x62, 0x6f, 0x61, 0x72, 0x64, 0x10, 0x16, 0x12, 0x0b,
|
||||
0x0a, 0x07, 0x76, 0x6e, 0x63, 0x5f, 0x63, 0x61, 0x64, 0x10, 0x17, 0x42, 0x09, 0x0a, 0x07, 0x70,
|
||||
0x61, 0x79, 0x6c, 0x6f, 0x61, 0x64, 0x42, 0x0c, 0x5a, 0x0a, 0x2e, 0x2f, 0x3b, 0x6e, 0x65, 0x74,
|
||||
0x77, 0x6f, 0x72, 0x6b, 0x62, 0x06, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x33,
|
||||
0x09, 0x76, 0x6e, 0x63, 0x5f, 0x69, 0x6d, 0x61, 0x67, 0x65, 0x10, 0x15, 0x12, 0x0d, 0x0a, 0x09,
|
||||
0x76, 0x6e, 0x63, 0x5f, 0x6d, 0x6f, 0x75, 0x73, 0x65, 0x10, 0x16, 0x12, 0x10, 0x0a, 0x0c, 0x76,
|
||||
0x6e, 0x63, 0x5f, 0x6b, 0x65, 0x79, 0x62, 0x6f, 0x61, 0x72, 0x64, 0x10, 0x17, 0x12, 0x0b, 0x0a,
|
||||
0x07, 0x76, 0x6e, 0x63, 0x5f, 0x63, 0x61, 0x64, 0x10, 0x18, 0x42, 0x09, 0x0a, 0x07, 0x70, 0x61,
|
||||
0x79, 0x6c, 0x6f, 0x61, 0x64, 0x42, 0x0c, 0x5a, 0x0a, 0x2e, 0x2f, 0x3b, 0x6e, 0x65, 0x74, 0x77,
|
||||
0x6f, 0x72, 0x6b, 0x62, 0x06, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x33,
|
||||
}
|
||||
|
||||
var (
|
||||
|
||||
@@ -26,9 +26,10 @@ message msg {
|
||||
shell_data = 11;
|
||||
// vnc
|
||||
vnc_ctrl = 20;
|
||||
vnc_mouse = 21;
|
||||
vnc_keyboard = 22;
|
||||
vnc_cad = 23; // ctrl+alt+del
|
||||
vnc_image = 21;
|
||||
vnc_mouse = 22;
|
||||
vnc_keyboard = 23;
|
||||
vnc_cad = 24; // ctrl+alt+del
|
||||
}
|
||||
type _type = 1;
|
||||
string from = 2;
|
||||
|
||||
Reference in New Issue
Block a user