# HG changeset patch # User oshiro # Date 1548843657 -32400 # Node ID f06b0d50e4e2a37dd9d411ec7734231172b053d6 # Parent 101b8a3ed8e467d3157a638f4fb9760c15c2c915# Parent 59cde26249b190ba407b95b1f9cd6ace563a3df9 merge diff -r 59cde26249b1 -r f06b0d50e4e2 src/main/java/jp/ac/u_ryukyu/treevnc/TreeVncCommand.java --- a/src/main/java/jp/ac/u_ryukyu/treevnc/TreeVncCommand.java Wed Jan 30 18:59:13 2019 +0900 +++ b/src/main/java/jp/ac/u_ryukyu/treevnc/TreeVncCommand.java Wed Jan 30 19:20:57 2019 +0900 @@ -111,10 +111,10 @@ rfb.setId(id); rfb.setMyAddress(myHostName); rfb.setLeader(leader); - if (rfb.isTreeManager()) { + //if (rfb.isTreeManager()) { // markers tree root has a parent on a different network. - rfb.setId((short) -1); - } + // rfb.setId((short) -1); + //} try { rfb.getViewer().connectToParenet(port, hostname); } catch (IOException e) { diff -r 59cde26249b1 -r f06b0d50e4e2 src/viewer_swing/java/com/glavsoft/viewer/Viewer.java --- a/src/viewer_swing/java/com/glavsoft/viewer/Viewer.java Wed Jan 30 18:59:13 2019 +0900 +++ b/src/viewer_swing/java/com/glavsoft/viewer/Viewer.java Wed Jan 30 19:20:57 2019 +0900 @@ -226,6 +226,7 @@ final boolean hasJsch = checkJsch(); final boolean allowInteractive = allowAppletInteractiveConnections || ! isApplet; connectionPresenter = new ConnectionPresenter(hasJsch, allowInteractive); + connectionPresenter.setReconnectingId(myRfb.getId()); connectionPresenter.setNoConnection(noConnection); connectionPresenter.addModel("ConnectionParamsModel", connectionParams); connectionPresenter.startVNCConnection(this, false, null, null); @@ -388,6 +389,10 @@ return; } } + + if (rfb.isTreeManager()) { + rfb.setId((short) rfb.getNewNodeId()); + } cp.sendWhereToConnect(this); isTreeVNC = true; myRfb = rfb;