public PrimitivePopup() { attach(); }
public PrimitivePopup hide() { reset(); this.getElement().getStyle().setDisplay(Style.Display.NONE); return this; }
protected void doShow(final IPrimitive<?> _primitive, final double width, final double height, final double x, final double y) { reset(); lienzoPanel = new LienzoPanel((int) width, (int) height); this.add(lienzoPanel); lienzoPanel.getScene().add(canvasLayer); if (null != _primitive) { canvasLayer.add(_primitive); } this.getElement().getStyle().setLeft(x, Style.Unit.PX); this.getElement().getStyle().setTop(y, Style.Unit.PX); this.getElement().getStyle().setZIndex(zIndex); this.getElement().getStyle().setDisplay(Style.Display.INLINE); }
public PrimitivePopup show(final double width, final double height, final double x, final double y) { doShow(null, width, height, x, y); lienzoPanel.draw(); return this; }
@Override public PrimitivePopup hide() { clearTimers(); return super.hide(); }
@Override public PrimitivePopup remove() { clearTimers(); return super.remove(); }
protected void reset() { this.clear(); canvasLayer = new Layer(); lienzoPanel = null; } }
protected void attach() { RootPanel.get().add(this); this.getElement().getStyle().setPosition(Style.Position.FIXED); this.getElement().getStyle().setZIndex(zIndex); this.getElement().getStyle().setDisplay(Style.Display.NONE); }
public PrimitivePopup show(final IPrimitive<?> _primitive, final double width, final double height, final double x, final double y) { doShow(_primitive, width, height, x, y); lienzoPanel.draw(); return this; }