@Test public void testDeleteChild() { Shape shape = mock(Shape.class); ShapeView shapeView = mock(ShapeView.class); when(shape.getShapeView()).thenReturn(shapeView); tested.deleteChild(shape); verify(view, times(1)).deleteRoot(eq(shapeView)); }
@Override protected void deleteChild(final Shape shape) { getView().deleteRoot(shape.getShapeView()); }
WiresCanvas extends LienzoCanvas<WiresCanvasView> { @Override protected void deleteChild(final Shape shape) { getView().deleteRoot(shape.getShapeView()); } }
WiresCanvas extends LienzoCanvas<WiresCanvasView> { @Override protected void deleteChild(final Shape shape) { getView().deleteRoot(shape.getShapeView()); } @Inject  WiresCanvas(final Event<CanvasClearEvent> canvasClearEvent,
                       final Event<CanvasShapeAddedEvent> canvasShapeAddedEvent,
                       final Event<CanvasShapeRemovedEvent> canvasShapeRemovedEvent,
                       final Event<CanvasDrawnEvent> canvasDrawnEvent,
                       final Event<CanvasFocusedEvent> canvasFocusedEvent,
                       final @Default WiresManagerFactory wiresManagerFactory,
                       final WiresCanvasView view); }
WiresCanvas extends LienzoCanvas<WiresCanvasView> { @Override protected void deleteChild(final Shape shape) { getView().deleteRoot(shape.getShapeView()); } @Inject  WiresCanvas(final Event<CanvasClearEvent> canvasClearEvent,
                       final Event<CanvasShapeAddedEvent> canvasShapeAddedEvent,
                       final Event<CanvasShapeRemovedEvent> canvasShapeRemovedEvent,
                       final Event<CanvasDrawnEvent> canvasDrawnEvent,
                       final Event<CanvasFocusedEvent> canvasFocusedEvent,
                       final @Default WiresManagerFactory wiresManagerFactory,
                       final WiresCanvasView view); @Override AbstractCanvas<WiresCanvasView> initialize(final CanvasPanel panel,
                                                      final CanvasSettings settings); @Override WiresCanvasView getView(); WiresManager getWiresManager(); }
WiresCanvas extends LienzoCanvas<WiresCanvasView> { @Override protected void deleteChild(final Shape shape) { getView().deleteRoot(shape.getShapeView()); } @Inject  WiresCanvas(final Event<CanvasClearEvent> canvasClearEvent,
                       final Event<CanvasShapeAddedEvent> canvasShapeAddedEvent,
                       final Event<CanvasShapeRemovedEvent> canvasShapeRemovedEvent,
                       final Event<CanvasDrawnEvent> canvasDrawnEvent,
                       final Event<CanvasFocusedEvent> canvasFocusedEvent,
                       final @Default WiresManagerFactory wiresManagerFactory,
                       final WiresCanvasView view); @Override AbstractCanvas<WiresCanvasView> initialize(final CanvasPanel panel,
                                                      final CanvasSettings settings); @Override WiresCanvasView getView(); WiresManager getWiresManager(); static final String WIRES_CANVAS_GROUP_ID; }