mirror of
https://github.com/overte-org/overte.git
synced 2025-07-04 02:09:30 +02:00
reset tablet contextual mode back to false when toggling tablet show/hide
This commit is contained in:
parent
80dc98b2c2
commit
08a6eb4dd3
2 changed files with 11 additions and 2 deletions
|
@ -108,6 +108,15 @@ void HMDScriptingInterface::openTablet(bool contextualMode) {
|
||||||
_tabletContextualMode = contextualMode;
|
_tabletContextualMode = contextualMode;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
void HMDScriptingInterface::toggleShouldShowTablet() {
|
||||||
|
setShouldShowTablet(!getShouldShowTablet());
|
||||||
|
}
|
||||||
|
|
||||||
|
void HMDScriptingInterface::setShouldShowTablet(bool value) {
|
||||||
|
_showTablet = value;
|
||||||
|
_tabletContextualMode = false;
|
||||||
|
}
|
||||||
|
|
||||||
QScriptValue HMDScriptingInterface::getHUDLookAtPosition2D(QScriptContext* context, QScriptEngine* engine) {
|
QScriptValue HMDScriptingInterface::getHUDLookAtPosition2D(QScriptContext* context, QScriptEngine* engine) {
|
||||||
glm::vec3 hudIntersection;
|
glm::vec3 hudIntersection;
|
||||||
auto instance = DependencyManager::get<HMDScriptingInterface>();
|
auto instance = DependencyManager::get<HMDScriptingInterface>();
|
||||||
|
|
|
@ -89,8 +89,8 @@ public:
|
||||||
|
|
||||||
bool isMounted() const;
|
bool isMounted() const;
|
||||||
|
|
||||||
void toggleShouldShowTablet() { _showTablet = !_showTablet; }
|
void toggleShouldShowTablet();
|
||||||
void setShouldShowTablet(bool value) { _showTablet = value; }
|
void setShouldShowTablet(bool value);
|
||||||
bool getShouldShowTablet() const { return _showTablet; }
|
bool getShouldShowTablet() const { return _showTablet; }
|
||||||
bool getTabletContextualMode() const { return _tabletContextualMode; }
|
bool getTabletContextualMode() const { return _tabletContextualMode; }
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue