/** * Override this for methods which invoke a cancel action. * * @param e takes a com.google.gwt.dom.client.Element. * */ public void cancel(com.google.gwt.dom.client.Element e) { setElement(e); // This has to be the order of calls cancel(e.<com.google.gwt.user.client.Element> cast()); }
private void stop(Element elem, String name, boolean clear, boolean jumpToEnd) { @SuppressWarnings("rawtypes") Queue q = queue(elem, name, null); if (q != null) { Object f = q.peek(); if (clear) { q.clear(); } if (f != null) { if (f instanceof Function) { // pass jumpToEnd to Animation.onCancel() via the element's data object $(elem).data(JUMP_TO_END, Boolean.valueOf(jumpToEnd)); ((Function) f).cancel(elem); $(elem).removeData(JUMP_TO_END); } dequeueIfNotDoneYet(elem, name, f); } } } }