mirror of
https://github.com/antos-rde/antosdk-apps.git
synced 2024-12-26 12:18:21 +01:00
improve UI handling
This commit is contained in:
parent
55787b135b
commit
03f48f3211
@ -7,6 +7,7 @@ Further information on **wvnc**: [https://blog.lxsang.me/post/id/23](https://blo
|
|||||||
|
|
||||||
|
|
||||||
## Change logs
|
## Change logs
|
||||||
|
* v0.1.12 - improve UI handling
|
||||||
* v0.1.11 - Support 16 bits per pixel
|
* v0.1.11 - Support 16 bits per pixel
|
||||||
* v0.1.10 - Allow to sync clipboard between local and remote machine, CTRL+SHIF+V to paste text from local to remote machine
|
* v0.1.10 - Allow to sync clipboard between local and remote machine, CTRL+SHIF+V to paste text from local to remote machine
|
||||||
* v0.1.9 - improve stability
|
* v0.1.9 - improve stability
|
||||||
|
@ -5,6 +5,6 @@ afx-app-window[data-id="RemoteDesktop"] div[data-id="container"]
|
|||||||
afx-app-window[data-id="RemoteDesktop"] canvas[data-id="screen"]
|
afx-app-window[data-id="RemoteDesktop"] canvas[data-id="screen"]
|
||||||
{
|
{
|
||||||
border:0;
|
border:0;
|
||||||
margin: auto;
|
/*margin: auto;*/
|
||||||
display: block;
|
display: block;
|
||||||
}
|
}
|
@ -7,6 +7,7 @@ Further information on **wvnc**: [https://blog.lxsang.me/post/id/23](https://blo
|
|||||||
|
|
||||||
|
|
||||||
## Change logs
|
## Change logs
|
||||||
|
* v0.1.12 - improve UI handling
|
||||||
* v0.1.11 - Support 16 bits per pixel
|
* v0.1.11 - Support 16 bits per pixel
|
||||||
* v0.1.10 - Allow to sync clipboard between local and remote machine, CTRL+SHIF+V to paste text from local to remote machine
|
* v0.1.10 - Allow to sync clipboard between local and remote machine, CTRL+SHIF+V to paste text from local to remote machine
|
||||||
* v0.1.9 - improve stability
|
* v0.1.9 - improve stability
|
||||||
|
@ -5,6 +5,6 @@ afx-app-window[data-id="RemoteDesktop"] div[data-id="container"]
|
|||||||
afx-app-window[data-id="RemoteDesktop"] canvas[data-id="screen"]
|
afx-app-window[data-id="RemoteDesktop"] canvas[data-id="screen"]
|
||||||
{
|
{
|
||||||
border:0;
|
border:0;
|
||||||
margin: auto;
|
/*margin: auto;*/
|
||||||
display: block;
|
display: block;
|
||||||
}
|
}
|
File diff suppressed because one or more lines are too long
@ -7,7 +7,7 @@
|
|||||||
"author": "Dany LE",
|
"author": "Dany LE",
|
||||||
"email": "contact@iohub.dev"
|
"email": "contact@iohub.dev"
|
||||||
},
|
},
|
||||||
"version":"0.1.11-b",
|
"version":"0.1.12-b",
|
||||||
"dependencies": [],
|
"dependencies": [],
|
||||||
"category":"Internet",
|
"category":"Internet",
|
||||||
"icon": "icon.png",
|
"icon": "icon.png",
|
||||||
|
Binary file not shown.
@ -175,12 +175,16 @@ class WVNC
|
|||||||
|
|
||||||
@socket.onmessage = (e) ->
|
@socket.onmessage = (e) ->
|
||||||
me.consume e
|
me.consume e
|
||||||
|
@socket.onerror = (e) =>
|
||||||
|
me.onerror("Websocket error")
|
||||||
|
|
||||||
@socket.onclose = () ->
|
@socket.onclose = () ->
|
||||||
me.socket = null
|
me.socket = null
|
||||||
me.canvas.style.cursor = "auto"
|
me.canvas.style.cursor = "auto"
|
||||||
me.canvas.getContext('2d').clearRect 0,0, me.resolution.w, me.resolution.h if me.canvas and me.resolution
|
me.canvas.getContext('2d').clearRect 0,0, me.resolution.w, me.resolution.h if me.canvas and me.resolution
|
||||||
clearTimeout(me.pingto) if me.pingto
|
clearTimeout(me.pingto) if me.pingto
|
||||||
me.pingto = undefined
|
me.pingto = undefined
|
||||||
|
me.ondisconnect()
|
||||||
console.log "socket closed"
|
console.log "socket closed"
|
||||||
|
|
||||||
disconnect: (close_worker) ->
|
disconnect: (close_worker) ->
|
||||||
@ -280,6 +284,9 @@ class WVNC
|
|||||||
onresize: () ->
|
onresize: () ->
|
||||||
console.log "resize"
|
console.log "resize"
|
||||||
|
|
||||||
|
ondisconnect: () ->
|
||||||
|
console.log "disconnect"
|
||||||
|
|
||||||
consume: (e) ->
|
consume: (e) ->
|
||||||
data = new Uint8Array e.data
|
data = new Uint8Array e.data
|
||||||
cmd = data[0]
|
cmd = data[0]
|
||||||
|
@ -98,8 +98,10 @@ class RemoteDesktop extends this.OS.application.BaseApplication
|
|||||||
}
|
}
|
||||||
@bindKey "CTRL-SHIFT-V", (e) =>
|
@bindKey "CTRL-SHIFT-V", (e) =>
|
||||||
@pasteText()
|
@pasteText()
|
||||||
@client.onerror = (m) =>
|
#@client.onerror = (m) =>
|
||||||
@error m
|
# @error m.toString()
|
||||||
|
# @showConnectionDialog()
|
||||||
|
@client.ondisconnect = () =>
|
||||||
@showConnectionDialog()
|
@showConnectionDialog()
|
||||||
@client.onresize = ()=>
|
@client.onresize = ()=>
|
||||||
@setScale()
|
@setScale()
|
||||||
@ -160,16 +162,13 @@ class RemoteDesktop extends this.OS.application.BaseApplication
|
|||||||
{ text: "__(New Connection)", dataid: "#{@name}-new", },
|
{ text: "__(New Connection)", dataid: "#{@name}-new", },
|
||||||
{ text: "__(Disconnect)", dataid: "#{@name}-close" }
|
{ text: "__(Disconnect)", dataid: "#{@name}-close" }
|
||||||
],
|
],
|
||||||
onchildselect: (e) => @actionConnection()
|
onchildselect: (e) =>
|
||||||
|
@client.disconnect(false) if @client
|
||||||
}
|
}
|
||||||
]
|
]
|
||||||
|
|
||||||
actionConnection: (e) ->
|
|
||||||
@client.disconnect(false) if @client
|
|
||||||
@showConnectionDialog()
|
|
||||||
|
|
||||||
showConnectionDialog: () ->
|
showConnectionDialog: () ->
|
||||||
|
return unless @client
|
||||||
@openDialog new ConnectionDialog, { title: __("Connection")}
|
@openDialog new ConnectionDialog, { title: __("Connection")}
|
||||||
.then (d) =>
|
.then (d) =>
|
||||||
@client.ws = d.wvnc
|
@client.ws = d.wvnc
|
||||||
@ -177,5 +176,6 @@ class RemoteDesktop extends this.OS.application.BaseApplication
|
|||||||
|
|
||||||
cleanup: () ->
|
cleanup: () ->
|
||||||
@client.disconnect(true) if @client
|
@client.disconnect(true) if @client
|
||||||
|
@client = undefined
|
||||||
|
|
||||||
this.OS.register "RemoteDesktop", RemoteDesktop
|
this.OS.register "RemoteDesktop", RemoteDesktop
|
@ -7,7 +7,7 @@
|
|||||||
"author": "Dany LE",
|
"author": "Dany LE",
|
||||||
"email": "contact@iohub.dev"
|
"email": "contact@iohub.dev"
|
||||||
},
|
},
|
||||||
"version":"0.1.11-b",
|
"version":"0.1.12-b",
|
||||||
"dependencies": [],
|
"dependencies": [],
|
||||||
"category":"Internet",
|
"category":"Internet",
|
||||||
"icon": "icon.png",
|
"icon": "icon.png",
|
||||||
|
@ -69,16 +69,6 @@
|
|||||||
"dependencies": ["Antunnel@0.2.0-b"],
|
"dependencies": ["Antunnel@0.2.0-b"],
|
||||||
"download": "https://raw.githubusercontent.com/lxsang/antosdk-apps/master/AntunnelPlugins/build/release/AntunnelPlugins.zip"
|
"download": "https://raw.githubusercontent.com/lxsang/antosdk-apps/master/AntunnelPlugins/build/release/AntunnelPlugins.zip"
|
||||||
},
|
},
|
||||||
{
|
|
||||||
"pkgname": "AntunnelTestClient",
|
|
||||||
"name": "AntunnelTestClient",
|
|
||||||
"description": "https://raw.githubusercontent.com/lxsang/antosdk-apps/master/AntunnelTestClient/README.md",
|
|
||||||
"category": "Development",
|
|
||||||
"author": "Dany LE",
|
|
||||||
"version": "0.1.0-a",
|
|
||||||
"dependencies": ["Antunnel@0.2.1-b"],
|
|
||||||
"download": "https://raw.githubusercontent.com/lxsang/antosdk-apps/master/AntunnelTestClient/build/release/AntunnelTestClient.zip"
|
|
||||||
},
|
|
||||||
{
|
{
|
||||||
"pkgname": "Archive",
|
"pkgname": "Archive",
|
||||||
"name": "Archive",
|
"name": "Archive",
|
||||||
@ -365,7 +355,7 @@
|
|||||||
"description": "https://raw.githubusercontent.com/lxsang/antosdk-apps/master/RemoteDesktop/README.md",
|
"description": "https://raw.githubusercontent.com/lxsang/antosdk-apps/master/RemoteDesktop/README.md",
|
||||||
"category": "Internet",
|
"category": "Internet",
|
||||||
"author": "Dany LE",
|
"author": "Dany LE",
|
||||||
"version": "0.1.11-b",
|
"version": "0.1.12-b",
|
||||||
"dependencies": [],"category":"Internet","icon":"icon.png","mimes":["none"],
|
"dependencies": [],"category":"Internet","icon":"icon.png","mimes":["none"],
|
||||||
"download": "https://raw.githubusercontent.com/lxsang/antosdk-apps/master/RemoteDesktop/build/release/RemoteDesktop.zip"
|
"download": "https://raw.githubusercontent.com/lxsang/antosdk-apps/master/RemoteDesktop/build/release/RemoteDesktop.zip"
|
||||||
},
|
},
|
||||||
|
Loading…
Reference in New Issue
Block a user