Showing the changes to interface/src/Application.cpp (1 of 2 files). Show all
Unified · Split
| @@ -2342,6 +2342,8 @@ Application::Application(int& argc, char** argv, QElapsedTimer& startupTimer, bo · 2341 unmodified lines | |||
| 2342 | } else { | 2342 | } else { |
| 2343 | QObject::connect(webSurface.data(), &hifi::qml::OffscreenSurface::rootContextCreated, rootItemLoadedFunctor); | 2343 | QObject::connect(webSurface.data(), &hifi::qml::OffscreenSurface::rootContextCreated, rootItemLoadedFunctor); |
| 2344 | } | 2344 | } |
| 2345 | auto surfaceContext = webSurface->getSurfaceContext(); | ||
| 2346 | surfaceContext->setContextProperty("KeyboardScriptingInterface", DependencyManager::get<KeyboardScriptingInterface>().data()); | ||
| 2345 | } else { | 2347 | } else { |
| 2346 | // FIXME: the tablet should use the OffscreenQmlSurfaceCache | 2348 | // FIXME: the tablet should use the OffscreenQmlSurfaceCache |
| 2347 | webSurface = QSharedPointer<OffscreenQmlSurface>(new OffscreenQmlSurface(), [](OffscreenQmlSurface* webSurface) { | 2349 | webSurface = QSharedPointer<OffscreenQmlSurface>(new OffscreenQmlSurface(), [](OffscreenQmlSurface* webSurface) { |
| @@ -3278,6 +3280,7 @@ void Application::setupQmlSurface(QQmlContext* surfaceContext, bool setAdditiona · 930 unmodified lines | |||
| 3278 | surfaceContext->setContextProperty("MyAvatar", DependencyManager::get<AvatarManager>()->getMyAvatar().get()); | 3280 | surfaceContext->setContextProperty("MyAvatar", DependencyManager::get<AvatarManager>()->getMyAvatar().get()); |
| 3279 | surfaceContext->setContextProperty("Entities", DependencyManager::get<EntityScriptingInterface>().data()); | 3281 | surfaceContext->setContextProperty("Entities", DependencyManager::get<EntityScriptingInterface>().data()); |
| 3280 | surfaceContext->setContextProperty("Snapshot", DependencyManager::get<Snapshot>().data()); | 3282 | surfaceContext->setContextProperty("Snapshot", DependencyManager::get<Snapshot>().data()); |
| 3283 | surfaceContext->setContextProperty("KeyboardScriptingInterface", DependencyManager::get<KeyboardScriptingInterface>().data()); | ||
| 3281 | 3284 | ||
| 3282 | if (setAdditionalContextProperties) { | 3285 | if (setAdditionalContextProperties) { |
| 3283 | auto tabletScriptingInterface = DependencyManager::get<TabletScriptingInterface>(); | 3286 | auto tabletScriptingInterface = DependencyManager::get<TabletScriptingInterface>(); |
| @@ -3288,7 +3291,6 @@ void Application::setupQmlSurface(QQmlContext* surfaceContext, bool setAdditiona · 4 unmodified lines | |||
| 3288 | 3291 | ||
| 3289 | surfaceContext->setContextProperty("Settings", SettingsScriptingInterface::getInstance()); | 3292 | surfaceContext->setContextProperty("Settings", SettingsScriptingInterface::getInstance()); |
| 3290 | surfaceContext->setContextProperty("MenuInterface", MenuScriptingInterface::getInstance()); | 3293 | surfaceContext->setContextProperty("MenuInterface", MenuScriptingInterface::getInstance()); |
| 3291 | surfaceContext->setContextProperty("KeyboardScriptingInterface", DependencyManager::get<KeyboardScriptingInterface>().data()); | ||
| 3292 | 3294 | ||
| 3293 | surfaceContext->setContextProperty("Account", AccountServicesScriptingInterface::getInstance()); // DEPRECATED - TO BE REMOVED | 3295 | surfaceContext->setContextProperty("Account", AccountServicesScriptingInterface::getInstance()); // DEPRECATED - TO BE REMOVED |
| 3294 | surfaceContext->setContextProperty("GlobalServices", AccountServicesScriptingInterface::getInstance()); // DEPRECATED - TO BE REMOVED | 3296 | surfaceContext->setContextProperty("GlobalServices", AccountServicesScriptingInterface::getInstance()); // DEPRECATED - TO BE REMOVED |