Вы не можете выбрать более 25 тем Темы должны начинаться с буквы или цифры, могут содержать дефисы(-) и должны содержать не более 35 символов.

PointerCancelEvent.java 1.8KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162
  1. /*
  2. * Copyright 2000-2016 Vaadin Ltd.
  3. *
  4. * Licensed under the Apache License, Version 2.0 (the "License"); you may not
  5. * use this file except in compliance with the License. You may obtain a copy of
  6. * the License at
  7. *
  8. * http://www.apache.org/licenses/LICENSE-2.0
  9. *
  10. * Unless required by applicable law or agreed to in writing, software
  11. * distributed under the License is distributed on an "AS IS" BASIS, WITHOUT
  12. * WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the
  13. * License for the specific language governing permissions and limitations under
  14. * the License.
  15. */
  16. package com.vaadin.client.event;
  17. import com.google.gwt.event.dom.client.DomEvent;
  18. /**
  19. * Represents a native PointerCancelEvent.
  20. *
  21. * @since 7.2
  22. */
  23. public class PointerCancelEvent extends PointerEvent<PointerCancelHandler> {
  24. /**
  25. * Event type for PointerCancelEvent. Represents the meta-data associated
  26. * with this event.
  27. */
  28. private static final Type<PointerCancelHandler> TYPE = new Type<>(
  29. EventType.PointerCancel.getNativeEventName(),
  30. new PointerCancelEvent());
  31. /**
  32. * Gets the event type associated with pointer cancel events.
  33. *
  34. * @return the handler type
  35. */
  36. public static Type<PointerCancelHandler> getType() {
  37. return TYPE;
  38. }
  39. /**
  40. * Protected constructor, use
  41. * {@link DomEvent#fireNativeEvent(com.google.gwt.dom.client.NativeEvent, com.google.gwt.event.shared.HasHandlers)}
  42. * to fire pointer up events.
  43. */
  44. protected PointerCancelEvent() {
  45. }
  46. @Override
  47. public final Type<PointerCancelHandler> getAssociatedType() {
  48. return TYPE;
  49. }
  50. @Override
  51. protected void dispatch(PointerCancelHandler handler) {
  52. handler.onPointerCancel(this);
  53. }
  54. }