All Downloads are FREE. Search and download functionalities are using the official Maven repository.

io.qt.gui.QPointerEvent Maven / Gradle / Ivy

There is a newer version: 6.8.0
Show newest version
package io.qt.gui;

import io.qt.*;


/**
 * 

A base class for pointer events

*

Java wrapper for Qt class QPointerEvent

*/ public class QPointerEvent extends io.qt.gui.QInputEvent { @QtPropertyMember(enabled=false) private Object __rcExclusiveGrabber = null; @QtPropertyMember(enabled=false) private java.util.Collection __rcPassiveGrabber; /** *

See QPointerEvent::QPointerEvent(QEvent::Type,const QPointingDevice*,Qt::KeyboardModifiers,QList<QEventPoint>)

*/ public QPointerEvent(io.qt.core.QEvent.@NonNull Type type, io.qt.gui.@Nullable QPointingDevice dev, io.qt.core.Qt.@NonNull KeyboardModifiers modifiers, java.util.@NonNull Collection points){ super((QPrivateConstructor)null); initialize_native(this, type, dev, modifiers, points); } private native static void initialize_native(QPointerEvent instance, io.qt.core.QEvent.Type type, io.qt.gui.QPointingDevice dev, io.qt.core.Qt.KeyboardModifiers modifiers, java.util.Collection points); /** *

See QPointerEvent::QPointerEvent(QPointerEvent)

*/ protected QPointerEvent(io.qt.gui.@StrictNonNull QPointerEvent arg__1){ super((QPrivateConstructor)null); java.util.Objects.requireNonNull(arg__1, "Argument 'arg__1': null not expected."); initialize_native(this, arg__1); } private native static void initialize_native(QPointerEvent instance, io.qt.gui.QPointerEvent arg__1); /** *

See QPointerEvent::addPassiveGrabber(QEventPoint,QObject*)

*/ @QtUninvokable public final boolean addPassiveGrabber(io.qt.gui.@NonNull QEventPoint point, io.qt.core.@Nullable QObject grabber){ boolean __qt_return_value = addPassiveGrabber_native_cref_QEventPoint_QObject_ptr(QtJambi_LibraryUtilities.internal.nativeId(this), QtJambi_LibraryUtilities.internal.checkedNativeId(point), QtJambi_LibraryUtilities.internal.checkedNativeId(grabber)); if (grabber != null) { if(__rcPassiveGrabber==null) __rcPassiveGrabber = QtJambi_LibraryUtilities.internal.newRCList(); __rcPassiveGrabber.add(grabber); } return __qt_return_value; } @QtUninvokable private native boolean addPassiveGrabber_native_cref_QEventPoint_QObject_ptr(long __this__nativeId, long point, long grabber); /** *

See QPointerEvent::allPointsAccepted()const

*/ @QtUninvokable public final boolean allPointsAccepted(){ return allPointsAccepted_native_constfct(QtJambi_LibraryUtilities.internal.nativeId(this)); } @QtUninvokable private native boolean allPointsAccepted_native_constfct(long __this__nativeId); /** *

See QPointerEvent::allPointsGrabbed()const

*/ @QtUninvokable public final boolean allPointsGrabbed(){ return allPointsGrabbed_native_constfct(QtJambi_LibraryUtilities.internal.nativeId(this)); } @QtUninvokable private native boolean allPointsGrabbed_native_constfct(long __this__nativeId); /** *

See QPointerEvent::clearPassiveGrabbers(QEventPoint)

*/ @QtUninvokable public final void clearPassiveGrabbers(io.qt.gui.@NonNull QEventPoint point){ clearPassiveGrabbers_native_cref_QEventPoint(QtJambi_LibraryUtilities.internal.nativeId(this), QtJambi_LibraryUtilities.internal.checkedNativeId(point)); } @QtUninvokable private native void clearPassiveGrabbers_native_cref_QEventPoint(long __this__nativeId, long point); /** *

See QPointerEvent::exclusiveGrabber(QEventPoint)const

*/ @QtUninvokable public final io.qt.core.@Nullable QObject exclusiveGrabber(io.qt.gui.@NonNull QEventPoint point){ return exclusiveGrabber_native_cref_QEventPoint_constfct(QtJambi_LibraryUtilities.internal.nativeId(this), QtJambi_LibraryUtilities.internal.checkedNativeId(point)); } @QtUninvokable private native io.qt.core.QObject exclusiveGrabber_native_cref_QEventPoint_constfct(long __this__nativeId, long point); /** *

See QPointerEvent::operator=(QPointerEvent)

*/ @QtUninvokable protected final void assign(io.qt.gui.@StrictNonNull QPointerEvent other){ java.util.Objects.requireNonNull(other, "Argument 'other': null not expected."); assign_native_cref_QPointerEvent(QtJambi_LibraryUtilities.internal.nativeId(this), QtJambi_LibraryUtilities.internal.checkedNativeId(other)); } @QtUninvokable private native void assign_native_cref_QPointerEvent(long __this__nativeId, long other); /** *

See QPointerEvent::passiveGrabbers(QEventPoint)const

*/ @QtUninvokable public final io.qt.core.@NonNull QList passiveGrabbers(io.qt.gui.@NonNull QEventPoint point){ return passiveGrabbers_native_cref_QEventPoint_constfct(QtJambi_LibraryUtilities.internal.nativeId(this), QtJambi_LibraryUtilities.internal.checkedNativeId(point)); } @QtUninvokable private native io.qt.core.QList passiveGrabbers_native_cref_QEventPoint_constfct(long __this__nativeId, long point); /** *

See QPointerEvent::point(qsizetype)

*/ @QtUninvokable public final io.qt.gui.@NonNull QEventPoint point(long i){ if(pointCount() <= i) throw new IndexOutOfBoundsException("Index out of range: "+i); return point_native_qsizetype(QtJambi_LibraryUtilities.internal.nativeId(this), i); } @QtUninvokable private native io.qt.gui.QEventPoint point_native_qsizetype(long __this__nativeId, long i); /** *

See QPointerEvent::pointById(int)

*/ @QtUninvokable public final io.qt.gui.@Nullable QEventPoint pointById(int id){ return pointById_native_int(QtJambi_LibraryUtilities.internal.nativeId(this), id); } @QtUninvokable private native io.qt.gui.QEventPoint pointById_native_int(long __this__nativeId, int id); /** *

See QPointerEvent::pointCount()const

*/ @QtUninvokable public final long pointCount(){ return pointCount_native_constfct(QtJambi_LibraryUtilities.internal.nativeId(this)); } @QtUninvokable private native long pointCount_native_constfct(long __this__nativeId); /** *

See QPointerEvent::pointerType()const

*/ @QtUninvokable public final io.qt.gui.QPointingDevice.@NonNull PointerType pointerType(){ return io.qt.gui.QPointingDevice.PointerType.resolve(pointerType_native_constfct(QtJambi_LibraryUtilities.internal.nativeId(this))); } @QtUninvokable private native int pointerType_native_constfct(long __this__nativeId); /** *

See QPointerEvent::pointingDevice()const

*/ @QtUninvokable public final io.qt.gui.@Nullable QPointingDevice pointingDevice(){ return pointingDevice_native_constfct(QtJambi_LibraryUtilities.internal.nativeId(this)); } @QtUninvokable private native io.qt.gui.QPointingDevice pointingDevice_native_constfct(long __this__nativeId); /** *

See QPointerEvent::points()const

*/ @QtUninvokable public final io.qt.core.@NonNull QList points(){ return points_native_constfct(QtJambi_LibraryUtilities.internal.nativeId(this)); } @QtUninvokable private native io.qt.core.QList points_native_constfct(long __this__nativeId); /** *

See QPointerEvent::removePassiveGrabber(QEventPoint,QObject*)

*/ @QtUninvokable public final boolean removePassiveGrabber(io.qt.gui.@NonNull QEventPoint point, io.qt.core.@Nullable QObject grabber){ boolean __qt_return_value = removePassiveGrabber_native_cref_QEventPoint_QObject_ptr(QtJambi_LibraryUtilities.internal.nativeId(this), QtJambi_LibraryUtilities.internal.checkedNativeId(point), QtJambi_LibraryUtilities.internal.checkedNativeId(grabber)); if (grabber != null) { while (__rcPassiveGrabber != null && __rcPassiveGrabber.remove(grabber)) ; } return __qt_return_value; } @QtUninvokable private native boolean removePassiveGrabber_native_cref_QEventPoint_QObject_ptr(long __this__nativeId, long point, long grabber); /** *

See QPointerEvent::setExclusiveGrabber(QEventPoint,QObject*)

*/ @QtUninvokable public final void setExclusiveGrabber(io.qt.gui.@NonNull QEventPoint point, io.qt.core.@Nullable QObject exclusiveGrabber){ setExclusiveGrabber_native_cref_QEventPoint_QObject_ptr(QtJambi_LibraryUtilities.internal.nativeId(this), QtJambi_LibraryUtilities.internal.checkedNativeId(point), QtJambi_LibraryUtilities.internal.checkedNativeId(exclusiveGrabber)); __rcExclusiveGrabber = exclusiveGrabber; } @QtUninvokable private native void setExclusiveGrabber_native_cref_QEventPoint_QObject_ptr(long __this__nativeId, long point, long exclusiveGrabber); /** *

See QEvent::clone()const

*/ @QtUninvokable @Override public io.qt.gui.@Nullable QPointerEvent clone(){ return clone_native_constfct(QtJambi_LibraryUtilities.internal.nativeId(this)); } @QtUninvokable private native io.qt.gui.QPointerEvent clone_native_constfct(long __this__nativeId); /** *

See QPointerEvent::isBeginEvent()const

*/ @QtUninvokable public boolean isBeginEvent(){ return isBeginEvent_native_constfct(QtJambi_LibraryUtilities.internal.nativeId(this)); } @QtUninvokable private native boolean isBeginEvent_native_constfct(long __this__nativeId); /** *

See QPointerEvent::isEndEvent()const

*/ @QtUninvokable public boolean isEndEvent(){ return isEndEvent_native_constfct(QtJambi_LibraryUtilities.internal.nativeId(this)); } @QtUninvokable private native boolean isEndEvent_native_constfct(long __this__nativeId); /** *

See QPointerEvent::isUpdateEvent()const

*/ @QtUninvokable public boolean isUpdateEvent(){ return isUpdateEvent_native_constfct(QtJambi_LibraryUtilities.internal.nativeId(this)); } @QtUninvokable private native boolean isUpdateEvent_native_constfct(long __this__nativeId); /** *

See QEvent::setAccepted(bool)

*/ @QtUninvokable public void setAccepted(boolean accepted){ setAccepted_native_bool(QtJambi_LibraryUtilities.internal.nativeId(this), accepted); } @QtUninvokable private native void setAccepted_native_bool(long __this__nativeId, boolean accepted); /** *

See QInputEvent::setTimestamp(quint64)

*/ @QtUninvokable @Override public void setTimestamp(long timestamp){ setTimestamp_native_quint64(QtJambi_LibraryUtilities.internal.nativeId(this), timestamp); } @QtUninvokable private native void setTimestamp_native_quint64(long __this__nativeId, long timestamp); /** * Constructor for internal use only. * @param p expected to be null. * @hidden */ @NativeAccess protected QPointerEvent(QPrivateConstructor p) { super(p); } @QtUninvokable public final native void setPoint(long i, QEventPoint point); /** *

Overloaded constructor for {@link #QPointerEvent(io.qt.core.QEvent.Type, io.qt.gui.QPointingDevice, io.qt.core.Qt.KeyboardModifiers, java.util.Collection)} * with points = java.util.Collections.emptyList().

*/ public QPointerEvent(io.qt.core.QEvent.@NonNull Type type, io.qt.gui.@Nullable QPointingDevice dev, io.qt.core.Qt.@NonNull KeyboardModifiers modifiers) { this(type, dev, modifiers, java.util.Collections.emptyList()); } /** *

Overloaded constructor for {@link #QPointerEvent(io.qt.core.QEvent.Type, io.qt.gui.QPointingDevice, io.qt.core.Qt.KeyboardModifiers, java.util.Collection)}

*

with:

    *
  • modifiers = new io.qt.core.Qt.KeyboardModifiers(0)
  • *
  • points = java.util.Collections.emptyList()
  • *
*/ public QPointerEvent(io.qt.core.QEvent.@NonNull Type type, io.qt.gui.@Nullable QPointingDevice dev) { this(type, dev, new io.qt.core.Qt.KeyboardModifiers(0), java.util.Collections.emptyList()); } /** * @deprecated Use {@link #assign(io.qt.gui.QPointerEvent)} instead. */ @Deprecated @QtUninvokable protected final void set(io.qt.gui.@StrictNonNull QPointerEvent other) { assign(other); } }