@Test public void testDestroy() throws Exception { Callback callback = mock(Callback.class); tested.show(glyphDragItem, 11, 33, callback); tested.destroy(); verify(proxyPanel, times(1)).destroy(); verify(proxyPanel, never()).clear(); verify(moveHandlerReg, times(1)).removeHandler(); verify(upHandlerReg, times(1)).removeHandler(); verify(rootPanel, times(1)).remove(eq(proxyPanel)); assertTrue(handlerRegistrations.isEmpty()); }
public void destroy() { clearState(() -> dragProxyPanel.destroy()); }
ShapeGlyphDragHandler { public void destroy() { clearState(() -> dragProxyPanel.destroy()); } }
ShapeGlyphDragHandler { public void destroy() { clearState(() -> dragProxyPanel.destroy()); } @Inject  ShapeGlyphDragHandler(final LienzoGlyphRenderers glyphLienzoGlyphRenderer);   ShapeGlyphDragHandler(final LienzoGlyphRenderer<Glyph> glyphLienzoGlyphRenderer,
                          final List<HandlerRegistration> handlerRegistrations,
                          final Supplier<AbsolutePanel> rootPanelSupplier,
                          final Function<ShapeGlyphDragHandler.Item, LienzoPanel> lienzoPanelBuilder,
                          final BiConsumer<Command, Integer> timer); }
ShapeGlyphDragHandler { public void destroy() { clearState(() -> dragProxyPanel.destroy()); } @Inject  ShapeGlyphDragHandler(final LienzoGlyphRenderers glyphLienzoGlyphRenderer);   ShapeGlyphDragHandler(final LienzoGlyphRenderer<Glyph> glyphLienzoGlyphRenderer,
                          final List<HandlerRegistration> handlerRegistrations,
                          final Supplier<AbsolutePanel> rootPanelSupplier,
                          final Function<ShapeGlyphDragHandler.Item, LienzoPanel> lienzoPanelBuilder,
                          final BiConsumer<Command, Integer> timer); ShapeGlyphDragHandler show(final ShapeGlyphDragHandler.Item item,
                                      final int x,
                                      final int y,
                                      final ShapeGlyphDragHandler.Callback Callback); void clear(); void destroy(); }
ShapeGlyphDragHandler { public void destroy() { clearState(() -> dragProxyPanel.destroy()); } @Inject  ShapeGlyphDragHandler(final LienzoGlyphRenderers glyphLienzoGlyphRenderer);   ShapeGlyphDragHandler(final LienzoGlyphRenderer<Glyph> glyphLienzoGlyphRenderer,
                          final List<HandlerRegistration> handlerRegistrations,
                          final Supplier<AbsolutePanel> rootPanelSupplier,
                          final Function<ShapeGlyphDragHandler.Item, LienzoPanel> lienzoPanelBuilder,
                          final BiConsumer<Command, Integer> timer); ShapeGlyphDragHandler show(final ShapeGlyphDragHandler.Item item,
                                      final int x,
                                      final int y,
                                      final ShapeGlyphDragHandler.Callback Callback); void clear(); void destroy();  }