import com.google.gwt.user.client.DOM;
import com.google.gwt.user.client.Element;
-import com.google.gwt.user.client.Event;
import com.google.gwt.user.client.ui.ComplexPanel;
import com.google.gwt.user.client.ui.Widget;
import com.vaadin.terminal.gwt.client.Util;
private Widget visibleWidget;
- private TouchScrollHandler touchScrollHandler;
+ private final TouchScrollHandler touchScrollHandler;
/**
* Creates an empty tabsheet panel.
*/
public VTabsheetPanel() {
setElement(DOM.createDiv());
- sinkEvents(Event.TOUCHEVENTS);
-
touchScrollHandler = TouchScrollDelegate.enableTouchScrolling(this);
}
Element el = DOM.createDiv();
DOM.setStyleAttribute(el, "position", "absolute");
hide(el);
+ touchScrollHandler.addElement(el);
return el;
}
if (parent != null) {
DOM.removeChild(getElement(), parent);
}
+ touchScrollHandler.removeElement(parent);
}
return removed;
}
}
visibleWidget = newVisible;
unHide(DOM.getParent(visibleWidget.getElement()));
- touchScrollHandler.setElements(visibleWidget.getElement()
- .getParentElement());
}
}