comparison src/viewer_swing/java/com/glavsoft/viewer/Viewer.java @ 174:2e1530139169

reorganization
author Shinji KONO <kono@ie.u-ryukyu.ac.jp>
date Sun, 22 Jun 2014 11:22:52 +0900
parents 1c9f6acdfeb2
children e1aa06b0d2ff
comparison
equal deleted inserted replaced
173:70068c2642de 174:2e1530139169
46 import java.util.logging.*; 46 import java.util.logging.*;
47 47
48 import jp.ac.u_ryukyu.treevnc.CreateConnectionParam; 48 import jp.ac.u_ryukyu.treevnc.CreateConnectionParam;
49 import jp.ac.u_ryukyu.treevnc.MyRfbProto; 49 import jp.ac.u_ryukyu.treevnc.MyRfbProto;
50 import jp.ac.u_ryukyu.treevnc.client.MyRfbProtoClient; 50 import jp.ac.u_ryukyu.treevnc.client.MyRfbProtoClient;
51 import jp.ac.u_ryukyu.treevnc.server.TreeManagement;
51 52
52 @SuppressWarnings("serial") 53 @SuppressWarnings("serial")
53 public class Viewer extends JApplet implements Runnable, WindowListener , ViewerInterface{ 54 public class Viewer extends JApplet implements Runnable, WindowListener , ViewerInterface{
54 55
55 private Logger logger; 56 private Logger logger;
318 myRfb = rfb; 319 myRfb = rfb;
319 settings.setViewOnly(true); // too avoid unnecessary upward traffic 320 settings.setViewOnly(true); // too avoid unnecessary upward traffic
320 cp.getAcceptThread().waitForShutdown(); 321 cp.getAcceptThread().waitForShutdown();
321 } 322 }
322 323
323 324
324 325 /**
326 * Start client with new parent (including reconnection)
327 * @param port
328 * @param hostname
329 * @throws IOException
330 */
331 @Override
332 public void connectToParenet(int port, String hostname) throws IOException {
333 setTeminationType(false);
334 closeApp();
335 setConnectionParam(hostname, port);
336 run();
337 }
325 338
326 public void setConnectionParam(String hostName, int port) { 339 public void setConnectionParam(String hostName, int port) {
327 connectionParams.setHostName(hostName); 340 connectionParams.setHostName(hostName);
328 connectionParams.setPortNumber(port); 341 connectionParams.setPortNumber(port);
329 } 342 }
344 } 357 }
345 358
346 @Override 359 @Override
347 public void createRootSelectionPanel() { 360 public void createRootSelectionPanel() {
348 } 361 }
362
363 @Override
364 public void changeVNCServer(String newHostName, int i, int j, short id) {
365
366 }
367
368 @Override
369 public void initRoot(String hostName, MyRfbProto myRfb) {
370 isApplet = false;
371 setIsTreeVNC(true);
372 setConnectionParam(hostName,ConnectionParams.DEFAULT_RFB_PORT);
373 isApplet = true;
374 run();
375 }
376
377 @Override
378 public void inhelitClients(ViewerInterface vncProxyService, String hostName) {
379 // TODO Auto-generated method stub
380
381 }
382
383 @Override
384 public void setTreeManager(TreeManagement treeManager) {
385 // TODO Auto-generated method stub
386
387 }
388
389 @Override
390 public void initRootViewer(String hostName) {
391 // TODO Auto-generated method stub
392
393 }
394
349 } 395 }