History

some what working d-pad

Dante Ruiz committed 9 years ago

Commit d3fa7651 parent 865a78a8 files · +76 −8Browse files

Showing the changes to libraries/script-engine/src/TabletScriptingInterface.cpp (1 of 8 files). Show all

Unified · Split

libraries/script-engine/src/TabletScriptingInterface.cpp+5−0
@@ -51,6 +51,10 @@ QQuickWindow* TabletScriptingInterface::getTabletWindow() { · 50 unmodified lines
51 TabletProxy* tablet = qobject_cast<TabletProxy*>(getTablet("com.highfidelity.interface.tablet.system"));51 TabletProxy* tablet = qobject_cast<TabletProxy*>(getTablet("com.highfidelity.interface.tablet.system"));
52 QObject* qmlSurface = tablet->getTabletSurface();52 QObject* qmlSurface = tablet->getTabletSurface();
53 OffscreenQmlSurface* surface = dynamic_cast<OffscreenQmlSurface*>(qmlSurface);53 OffscreenQmlSurface* surface = dynamic_cast<OffscreenQmlSurface*>(qmlSurface);
54
55 if (!surface) {
56 return nullptr;
57 }
54 QQuickWindow* window = surface->getWindow();58 QQuickWindow* window = surface->getWindow();
55 return window;59 return window;
56}60}
@@ -212,6 +216,7 @@ void TabletProxy::addButtonsToHomeScreen() { · 155 unmodified lines
212 }216 }
213 auto loader = _qmlTabletRoot->findChild<QQuickItem*>("loader");217 auto loader = _qmlTabletRoot->findChild<QQuickItem*>("loader");
214 QObject::disconnect(loader, SIGNAL(loaded()), this, SLOT(addButtonsToHomeScreen()));218 QObject::disconnect(loader, SIGNAL(loaded()), this, SLOT(addButtonsToHomeScreen()));
219 QMetaObject::invokeMethod(_qmlTabletRoot, "forceFocus");
215}220}
216 221
217QObject* TabletProxy::getTabletSurface() {222QObject* TabletProxy::getTabletSurface() {