1
0
mirror of https://github.com/lxsang/antd-web-apps synced 2025-07-27 02:59:47 +02:00

add demo page

This commit is contained in:
lxsang
2018-09-23 14:08:19 +02:00
parent 1a78d814eb
commit efe2061289
5 changed files with 73 additions and 21 deletions

View File

@ -188,12 +188,12 @@
me = this;
this.client.onpassword = function() {
return new Promise(function(r, e) {
return r('lxsan9');
return r('demopass');
});
};
this.client.oncredential = function() {
return new Promise(function(r, e) {
return r('mrsang', '!x$@n9');
return r('demo', 'demo');
});
};
this.client.oncopy = function(text) {
@ -201,17 +201,20 @@
};
return this.client.init().then(function() {
$("#connect").click(function(e) {
return me.client.connect("192.168.1.20:5901", {
return me.client.connect("/Users/mrsang/Documents/build/www/vnc.conf", {
bbp: 32,
flag: 3,
quality: 30
quality: 10
});
});
$("#tbstatus").html("32bbp, compress JPEG & ZLib, JPEG quality 10%");
$("#stop").click(function(e) {
return me.client.disconnect();
});
return $("#btclipboard").click(function(e) {
return me.client.sendTextAsClipboard(($("#clipboard"))[0].value);
return $("#selscale").on('change', function(e) {
var value;
value = Number(this.value) / 100;
return me.client.setScale(value);
});
})["catch"](function(m, s) {
return console.error(m, s);

File diff suppressed because one or more lines are too long