io.qt.gui.QInputEvent Maven / Gradle / Ivy
Show all versions of qtjambi Show documentation
package io.qt.gui;
import io.qt.*;
/**
* The base class for events that describe user input
* Java wrapper for Qt class QInputEvent
*/
public class QInputEvent extends io.qt.core.QEvent
{
static {
QtJambi_LibraryUtilities.initialize();
}
@QtPropertyMember(enabled=false)
private Object __rcDevice = null;
/**
* See QInputEvent:: QInputEvent(QEvent::Type, const QInputDevice*, Qt::KeyboardModifiers)
*/
public QInputEvent(io.qt.core.QEvent.@NonNull Type type, io.qt.gui.@Nullable QInputDevice m_dev, io.qt.core.Qt.@NonNull KeyboardModifiers modifiers){
super((QPrivateConstructor)null);
initialize_native(this, type, m_dev, modifiers);
}
private native static void initialize_native(QInputEvent instance, io.qt.core.QEvent.Type type, io.qt.gui.QInputDevice m_dev, io.qt.core.Qt.KeyboardModifiers modifiers);
/**
* See QInputEvent:: QInputEvent(QInputEvent)
*/
protected QInputEvent(io.qt.gui.@StrictNonNull QInputEvent 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(QInputEvent instance, io.qt.gui.QInputEvent arg__1);
/**
* See QInputEvent:: device()const
*/
@QtUninvokable
public final io.qt.gui.@Nullable QInputDevice device(){
return device_native_constfct(QtJambi_LibraryUtilities.internal.nativeId(this));
}
@QtUninvokable
private native io.qt.gui.QInputDevice device_native_constfct(long __this__nativeId);
/**
* See QInputEvent:: deviceType()const
*/
@QtUninvokable
public final io.qt.gui.QInputDevice.@NonNull DeviceType deviceType(){
return io.qt.gui.QInputDevice.DeviceType.resolve(deviceType_native_constfct(QtJambi_LibraryUtilities.internal.nativeId(this)));
}
@QtUninvokable
private native int deviceType_native_constfct(long __this__nativeId);
/**
* See QInputEvent:: modifiers()const
*/
@QtDeclaredFinal
@QtUninvokable
public io.qt.core.Qt.@NonNull KeyboardModifiers modifiers(){
return new io.qt.core.Qt.KeyboardModifiers(modifiers_native_constfct(QtJambi_LibraryUtilities.internal.nativeId(this)));
}
@QtUninvokable
private native int modifiers_native_constfct(long __this__nativeId);
/**
* See QInputEvent:: operator=(QInputEvent)
*/
@QtUninvokable
protected final void assign(io.qt.gui.@StrictNonNull QInputEvent other){
java.util.Objects.requireNonNull(other, "Argument 'other': null not expected.");
assign_native_cref_QInputEvent(QtJambi_LibraryUtilities.internal.nativeId(this), QtJambi_LibraryUtilities.internal.checkedNativeId(other));
}
@QtUninvokable
private native void assign_native_cref_QInputEvent(long __this__nativeId, long other);
/**
* See QInputEvent:: setModifiers(Qt::KeyboardModifiers)
*/
@QtUninvokable
public final void setModifiers(io.qt.core.Qt.@NonNull KeyboardModifiers modifiers){
setModifiers_native_Qt_KeyboardModifiers(QtJambi_LibraryUtilities.internal.nativeId(this), modifiers.value());
}
@QtUninvokable
private native void setModifiers_native_Qt_KeyboardModifiers(long __this__nativeId, int modifiers);
/**
* See QInputEvent:: timestamp()const
*/
@QtUninvokable
public final long timestamp(){
return timestamp_native_constfct(QtJambi_LibraryUtilities.internal.nativeId(this));
}
@QtUninvokable
private native long timestamp_native_constfct(long __this__nativeId);
/**
*
*/
@QtUninvokable
@Override
public io.qt.gui.@Nullable QInputEvent clone(){
return clone_native_constfct(QtJambi_LibraryUtilities.internal.nativeId(this));
}
@QtUninvokable
private native io.qt.gui.QInputEvent clone_native_constfct(long __this__nativeId);
/**
* See QInputEvent:: setTimestamp(quint64)
*/
@QtUninvokable
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);
/**
* See QInputEvent:: m_dev
*/
@QtUninvokable
protected final void setDevice(io.qt.gui.@Nullable QInputDevice device){
setDevice_native_const_QInputDevice_ptr(QtJambi_LibraryUtilities.internal.nativeId(this), QtJambi_LibraryUtilities.internal.checkedNativeId(device));
__rcDevice = device;
}
@QtUninvokable
private native void setDevice_native_const_QInputDevice_ptr(long __this__nativeId, long device);
/**
* Constructor for internal use only.
* @param p expected to be null
.
* @hidden
*/
@NativeAccess
protected QInputEvent(QPrivateConstructor p) { super(p); }
/**
* Overloaded constructor for {@link #QInputEvent(io.qt.core.QEvent.Type, io.qt.gui.QInputDevice, io.qt.core.Qt.KeyboardModifiers)}
* with modifiers = new io.qt.core.Qt.KeyboardModifiers(0)
.
*/
public QInputEvent(io.qt.core.QEvent.@NonNull Type type, io.qt.gui.@Nullable QInputDevice m_dev) {
this(type, m_dev, new io.qt.core.Qt.KeyboardModifiers(0));
}
/**
* Overloaded constructor for {@link #QInputEvent(io.qt.core.QEvent.Type, io.qt.gui.QInputDevice, io.qt.core.Qt.KeyboardModifiers)}.
*/
public QInputEvent(io.qt.core.QEvent.@NonNull Type type, io.qt.gui.@Nullable QInputDevice m_dev, io.qt.core.Qt.@NonNull KeyboardModifier @NonNull... modifiers) {
this(type, m_dev, new io.qt.core.Qt.KeyboardModifiers(modifiers));
}
/**
* @deprecated Use {@link #assign(io.qt.gui.QInputEvent)} instead.
*/
@Deprecated
@QtUninvokable
protected final void set(io.qt.gui.@StrictNonNull QInputEvent other) {
assign(other);
}
/**
* Overloaded function for {@link #setModifiers(io.qt.core.Qt.KeyboardModifiers)}.
*/
@QtUninvokable
public final void setModifiers(io.qt.core.Qt.@NonNull KeyboardModifier @NonNull... modifiers) {
setModifiers(new io.qt.core.Qt.KeyboardModifiers(modifiers));
}
}