/** Notifies all views of layout changes. */ public void layout() { for (final View v : view) { v.refreshLayout(); final ViewPanel vp = (ViewPanel) v.getParent(); final ViewMover vm = (ViewMover) vp.getComponent(0); vm.refreshLayout(); } }
public void setGridBagLayout() { operationPanel.setSize(175, 590); operationPanel.setLocation(0, 0); add(operationPanel); viewPanel.setSize(530, 550); viewPanel.setLocation(180, 0); add(viewPanel); }
@Override public void paintComponent(Graphics g) { super.paintComponent(g); checkTitle(); Graphics2D g2 = (Graphics2D) g; render(g2); }
public void release3(ViewPanel v, int mod, int jpx, int jpy, MouseEvent e) { application.cam.setXspeed(0); application.cam.setYspeed(0); application.cam.setZspeed(0); v.setDrawDrag(false); application.vsm.getActiveView().mouse.setSensitivity(true); /*Camera c=v.cams[0]; application.cam.createCameraAnimation(500,2,new LongPoint(lastX-application.vsm.mouse.vx,lastY-application.vsm.mouse.vy),c.getID());*/ }
public void press3(ViewPanel v, int mod, int jpx, int jpy, MouseEvent e) { // application.vsm.setSync(false); lastJPX = jpx; lastJPY = jpy; // application.vsm.animator.setActiveCam(v.cams[0]); v.setDrawDrag(true); application.vsm.getActiveView().mouse.setSensitivity(false); // because we would not be consistent (when dragging the mouse, we computeMouseOverList, but // if there is an anim triggered by {X,Y,A}speed, and if the mouse is not moving, this list is // not computed - so here we choose to disable this computation when dragging the mouse with // button 3 pressed) }