Mercurial > hg > Applications > TreeVNC
annotate src/main/java/jp/ac/u_ryukyu/treevnc/RequestScreenThread.java @ 232:6ee4cdca104c
send value of port and localhost in checkdelay framebufferupdate, and get this.
author | oc |
---|---|
date | Fri, 10 Oct 2014 23:39:44 +0900 |
parents | b31903e5b02d |
children | 42fcc9419498 |
rev | line source |
---|---|
206 | 1 package jp.ac.u_ryukyu.treevnc; |
33
9d3478d11d3b
Add the processing of client
Taninari YU <you@cr.ie.u-ryukyu.ac.jp>
parents:
28
diff
changeset
|
2 |
16 | 3 import com.glavsoft.rfb.protocol.Protocol; |
4 | |
11 | 5 public class RequestScreenThread implements Runnable { |
207 | 6 public TreeRFBProto rfb; |
16 | 7 Protocol protocol; |
11 | 8 |
207 | 9 public RequestScreenThread(TreeRFBProto _rfb) { |
11 | 10 rfb = _rfb; |
11 } | |
12 | |
88 | 13 |
14 | |
15 /* (non-Javadoc) | |
16 * @see java.lang.Runnable#run() | |
17 * | |
18 * request full screen update every 3 second. | |
19 * restart send this immediately. | |
20 * nobody call this. | |
21 * | |
22 */ | |
11 | 23 public void run() { |
24 while (true) { | |
25 try { | |
88 | 26 synchronized(this) { |
27 wait(); | |
28 } | |
11 | 29 Thread.sleep(3000); |
16 | 30 rfb.writeFramebufferUpdateRequest(0, 0, protocol.getFbWidth(), |
31 protocol.getFbHeight(), false); | |
11 | 32 |
33 } catch (Exception e) { | |
34 e.printStackTrace(); | |
35 break; | |
36 } | |
37 } | |
38 } | |
39 | |
40 | |
88 | 41 /** |
42 * do nothing. | |
43 */ | |
11 | 44 public synchronized void reStart() { |
45 notify(); | |
46 } | |
47 | |
48 } |