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
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
rev   line source
206
2b3eb4a9492f MyRfbProto reorganization
oc
parents: 98
diff changeset
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
e654b2e4de64 add TreeTask.java
one
parents: 14
diff changeset
3 import com.glavsoft.rfb.protocol.Protocol;
e654b2e4de64 add TreeTask.java
one
parents: 14
diff changeset
4
11
57ae9fbb1245 add files
Taninari YU <you@cr.ie.u-ryukyu.ac.jp>
parents:
diff changeset
5 public class RequestScreenThread implements Runnable {
207
b31903e5b02d rename myRFBProto
oc
parents: 206
diff changeset
6 public TreeRFBProto rfb;
16
e654b2e4de64 add TreeTask.java
one
parents: 14
diff changeset
7 Protocol protocol;
11
57ae9fbb1245 add files
Taninari YU <you@cr.ie.u-ryukyu.ac.jp>
parents:
diff changeset
8
207
b31903e5b02d rename myRFBProto
oc
parents: 206
diff changeset
9 public RequestScreenThread(TreeRFBProto _rfb) {
11
57ae9fbb1245 add files
Taninari YU <you@cr.ie.u-ryukyu.ac.jp>
parents:
diff changeset
10 rfb = _rfb;
57ae9fbb1245 add files
Taninari YU <you@cr.ie.u-ryukyu.ac.jp>
parents:
diff changeset
11 }
57ae9fbb1245 add files
Taninari YU <you@cr.ie.u-ryukyu.ac.jp>
parents:
diff changeset
12
88
a719aa609e14 add name valuer threads.
oc
parents: 33
diff changeset
13
a719aa609e14 add name valuer threads.
oc
parents: 33
diff changeset
14
a719aa609e14 add name valuer threads.
oc
parents: 33
diff changeset
15 /* (non-Javadoc)
a719aa609e14 add name valuer threads.
oc
parents: 33
diff changeset
16 * @see java.lang.Runnable#run()
a719aa609e14 add name valuer threads.
oc
parents: 33
diff changeset
17 *
a719aa609e14 add name valuer threads.
oc
parents: 33
diff changeset
18 * request full screen update every 3 second.
a719aa609e14 add name valuer threads.
oc
parents: 33
diff changeset
19 * restart send this immediately.
a719aa609e14 add name valuer threads.
oc
parents: 33
diff changeset
20 * nobody call this.
a719aa609e14 add name valuer threads.
oc
parents: 33
diff changeset
21 *
a719aa609e14 add name valuer threads.
oc
parents: 33
diff changeset
22 */
11
57ae9fbb1245 add files
Taninari YU <you@cr.ie.u-ryukyu.ac.jp>
parents:
diff changeset
23 public void run() {
57ae9fbb1245 add files
Taninari YU <you@cr.ie.u-ryukyu.ac.jp>
parents:
diff changeset
24 while (true) {
57ae9fbb1245 add files
Taninari YU <you@cr.ie.u-ryukyu.ac.jp>
parents:
diff changeset
25 try {
88
a719aa609e14 add name valuer threads.
oc
parents: 33
diff changeset
26 synchronized(this) {
a719aa609e14 add name valuer threads.
oc
parents: 33
diff changeset
27 wait();
a719aa609e14 add name valuer threads.
oc
parents: 33
diff changeset
28 }
11
57ae9fbb1245 add files
Taninari YU <you@cr.ie.u-ryukyu.ac.jp>
parents:
diff changeset
29 Thread.sleep(3000);
16
e654b2e4de64 add TreeTask.java
one
parents: 14
diff changeset
30 rfb.writeFramebufferUpdateRequest(0, 0, protocol.getFbWidth(),
e654b2e4de64 add TreeTask.java
one
parents: 14
diff changeset
31 protocol.getFbHeight(), false);
11
57ae9fbb1245 add files
Taninari YU <you@cr.ie.u-ryukyu.ac.jp>
parents:
diff changeset
32
57ae9fbb1245 add files
Taninari YU <you@cr.ie.u-ryukyu.ac.jp>
parents:
diff changeset
33 } catch (Exception e) {
57ae9fbb1245 add files
Taninari YU <you@cr.ie.u-ryukyu.ac.jp>
parents:
diff changeset
34 e.printStackTrace();
57ae9fbb1245 add files
Taninari YU <you@cr.ie.u-ryukyu.ac.jp>
parents:
diff changeset
35 break;
57ae9fbb1245 add files
Taninari YU <you@cr.ie.u-ryukyu.ac.jp>
parents:
diff changeset
36 }
57ae9fbb1245 add files
Taninari YU <you@cr.ie.u-ryukyu.ac.jp>
parents:
diff changeset
37 }
57ae9fbb1245 add files
Taninari YU <you@cr.ie.u-ryukyu.ac.jp>
parents:
diff changeset
38 }
57ae9fbb1245 add files
Taninari YU <you@cr.ie.u-ryukyu.ac.jp>
parents:
diff changeset
39
57ae9fbb1245 add files
Taninari YU <you@cr.ie.u-ryukyu.ac.jp>
parents:
diff changeset
40
88
a719aa609e14 add name valuer threads.
oc
parents: 33
diff changeset
41 /**
a719aa609e14 add name valuer threads.
oc
parents: 33
diff changeset
42 * do nothing.
a719aa609e14 add name valuer threads.
oc
parents: 33
diff changeset
43 */
11
57ae9fbb1245 add files
Taninari YU <you@cr.ie.u-ryukyu.ac.jp>
parents:
diff changeset
44 public synchronized void reStart() {
57ae9fbb1245 add files
Taninari YU <you@cr.ie.u-ryukyu.ac.jp>
parents:
diff changeset
45 notify();
57ae9fbb1245 add files
Taninari YU <you@cr.ie.u-ryukyu.ac.jp>
parents:
diff changeset
46 }
57ae9fbb1245 add files
Taninari YU <you@cr.ie.u-ryukyu.ac.jp>
parents:
diff changeset
47
57ae9fbb1245 add files
Taninari YU <you@cr.ie.u-ryukyu.ac.jp>
parents:
diff changeset
48 }