本页内容

Qt3DInput::QLogicalDevice Class

class Qt3DInput::QLogicalDevice

QLogicalDevice 允许用户定义一组希望在应用程序中使用的操作。更多内容...

标题: #include <qlogicaldevice.h>
CMake: find_package(Qt6 REQUIRED COMPONENTS 3dinput)
target_link_libraries(mytarget PRIVATE Qt6::3dinput)
qmake: QT += 3dinput
在 QML 中: LogicalDevice
继承自: Qt3DCore::QComponent
状态: 已弃用

该类已弃用。我们强烈建议不要在新代码中使用它。

公共函数

QLogicalDevice(Qt3DCore::QNode *parent = nullptr)
QList<Qt3DInput::QAction *> actions() const
void addAction(Qt3DInput::QAction *action)
void addAxis(Qt3DInput::QAxis *axis)
QList<Qt3DInput::QAxis *> axes() const
void removeAction(Qt3DInput::QAction *action)
void removeAxis(Qt3DInput::QAxis *axis)

详细说明

成员函数文档

[explicit] QLogicalDevice::QLogicalDevice(Qt3DCore::QNode *parent = nullptr)

创建一个父设备为parent 的新QLogicalDevice实例。

QList<Qt3DInput::QAction *> QLogicalDevice::actions() const

返回操作列表。

void QLogicalDevice::addAction(Qt3DInput::QAction *action)

将“action ”添加到操作列表中。

void QLogicalDevice::addAxis(Qt3DInput::QAxis *axis)

将一个axis 添加到轴列表中。

QList<Qt3DInput::QAxis *> QLogicalDevice::axes() const

返回轴的列表。

void QLogicalDevice::removeAction(Qt3DInput::QAction *action)

从操作列表中删除“action ”。

void QLogicalDevice::removeAxis(Qt3DInput::QAxis *axis)

从轴列表中移除一个axis 。

© 2026 The Qt Company Ltd. Documentation contributions included herein are the copyrights of their respective owners. The documentation provided herein is licensed under the terms of the GNU Free Documentation License version 1.3 as published by the Free Software Foundation. Qt and respective logos are trademarks of The Qt Company Ltd. in Finland and/or other countries worldwide. All other trademarks are property of their respective owners.