Open GoogleCodeExporter opened 9 years ago
Julien, Thanks for submitting this. Can you clarify what the problem is. I
looked at r819 but I don't see any changes to a listenForCanvas method.
Original comment by atdi...@gmail.com
on 23 Apr 2012 at 3:37
Hi,
if i look at PSwingNode r819 lines 610 to 615 are a test to see if the
PSwingNode is directly added to the camera.
In the latter revisions the test is gone, and so PSwingNode added to a PCamera
doesn't work anymore. If you copy the code from 610 to 615 in the latest
PSwingNode revision it works again.
Original comment by julien.b...@gmail.com
on 23 Apr 2012 at 6:54
Is this on svn trunk or branches/release-1.3?
Original comment by heue...@gmail.com
on 31 Aug 2012 at 4:35
Original comment by heue...@gmail.com
on 31 Aug 2012 at 8:29
Hi,
i checked and the part is missing in trunk latest version and in 1.3.1 branch
(the java part).
You can find the code i am talking about (r819 line 610-615) in the trunk
revision.
I copy the code here if you can't find it.
this is the part in the if(parent instanceof PCamera).
private void listenForCanvas(final PNode node) {
// need to get the full tree for this node
PNode p = node;
while (p != null) {
listenToNode(p);
final PNode parent = p;
if (parent instanceof PCamera) {
final PCamera cam = (PCamera) parent;
if (cam.getComponent() instanceof PSwingCanvas) {
updateCanvas((PSwingCanvas) cam.getComponent());
}
}
else if (parent instanceof PLayer) {
final PLayer player = (PLayer) parent;
for (int i = 0; i < player.getCameraCount(); i++) {
final PCamera cam = player.getCamera(i);
if (cam.getComponent() instanceof PSwingCanvas) {
updateCanvas((PSwingCanvas) cam.getComponent());
break;
}
}
}
p = p.getParent();
}
}
Original comment by julien.b...@gmail.com
on 3 Sep 2012 at 8:00
Original issue reported on code.google.com by
julien.b...@gmail.com
on 11 Apr 2012 at 7:43