Mercurial > hg > Members > riono > TreeVNC_ja_comment
comparison src/main/java/jp/ac/u_ryukyu/treevnc/TreeRootFinderListener.java @ 514:887ebd993b3d
separate rfb broadcast
author | mir3636 |
---|---|
date | Thu, 21 Feb 2019 16:52:21 +0900 |
parents | b97fdcd337fe |
children |
comparison
equal
deleted
inserted
replaced
513:b97fdcd337fe | 514:887ebd993b3d |
---|---|
16 public static final String Ipv4McastAddr = "224.0.0.1"; | 16 public static final String Ipv4McastAddr = "224.0.0.1"; |
17 public static final String Ipv6McastAddr = "ff02::1"; | 17 public static final String Ipv6McastAddr = "ff02::1"; |
18 public static String McastAddr = Ipv4McastAddr; | 18 public static String McastAddr = Ipv4McastAddr; |
19 | 19 |
20 static final int BufSize = 1024; | 20 static final int BufSize = 1024; |
21 private ReceiverTask receiverTask; | |
22 private boolean stopFlag = false; | 21 private boolean stopFlag = false; |
23 private ViewerInterface vps; | 22 private ViewerInterface vps; |
24 private MulticastSocket soc; | 23 private MulticastSocket soc; |
25 private SecurityManager securityManager; | 24 private SecurityManager securityManager; |
26 | 25 |
70 port = port * 256 + reply[10]; | 69 port = port * 256 + reply[10]; |
71 port = port * 256 + reply[11]; | 70 port = port * 256 + reply[11]; |
72 | 71 |
73 TreeVncProtocol t = new TreeVncProtocol(hostname, port); | 72 TreeVncProtocol t = new TreeVncProtocol(hostname, port); |
74 t.findRootReply(vps.getRfb().getAcceptPort()); | 73 t.findRootReply(vps.getRfb().getAcceptPort()); |
75 } else if (receiverTask != null && !vps.getRfb().isTreeManager()) { | |
76 receiverTask.setReader(new Reader(new ByteArrayInputStream(reply))); | |
77 if (receiverTask.getMessageId() == FRAMEBUFFER_UPDATE) { | |
78 receiverTask.framebufferUpdateMessage(); | |
79 } | |
80 } | 74 } |
81 } | 75 } |
82 } catch (Exception e) { | 76 } catch (Exception e) { |
83 System.out.println("tree-root-find-listener :" + e.getMessage()); | 77 System.out.println("tree-root-find-listener :" + e.getMessage()); |
84 } | 78 } |