History

change ScriptCache and SoundCache to derive from Dependency

ZappoMan committed 11 years ago

Commit 1fc02251 parent 5c048db11 files · +56 −63Browse files

Showing the changes to interface/src/Application.cpp (1 of 11 files). Show all

Unified · Split

interface/src/Application.cpp+6−1
@@ -211,6 +211,8 @@ bool setupEssentials(int& argc, char** argv) { · 210 unmodified lines
211 auto addressManager = DependencyManager::set<AddressManager>();211 auto addressManager = DependencyManager::set<AddressManager>();
212 auto nodeList = DependencyManager::set<NodeList>(NodeType::Agent, listenPort);212 auto nodeList = DependencyManager::set<NodeList>(NodeType::Agent, listenPort);
213 auto geometryCache = DependencyManager::set<GeometryCache>();213 auto geometryCache = DependencyManager::set<GeometryCache>();
214 auto scriptCache = DependencyManager::set<ScriptCache>();
215 auto soundCache = DependencyManager::set<SoundCache>();
214 auto glowEffect = DependencyManager::set<GlowEffect>();216 auto glowEffect = DependencyManager::set<GlowEffect>();
215 auto faceshift = DependencyManager::set<Faceshift>();217 auto faceshift = DependencyManager::set<Faceshift>();
216 auto audio = DependencyManager::set<AudioClient>();218 auto audio = DependencyManager::set<AudioClient>();
@@ -563,11 +565,14 @@ Application::~Application() { · 346 unmodified lines
563 _myAvatar = NULL;565 _myAvatar = NULL;
564 566
565 DependencyManager::destroy<GLCanvas>();567 DependencyManager::destroy<GLCanvas>();
568
569 qDebug() << "start destroying ResourceCaches Application::~Application() line:" << __LINE__;
566 DependencyManager::destroy<AnimationCache>();570 DependencyManager::destroy<AnimationCache>();
567 DependencyManager::destroy<TextureCache>();571 DependencyManager::destroy<TextureCache>();
568 DependencyManager::destroy<GeometryCache>();572 DependencyManager::destroy<GeometryCache>();
569 DependencyManager::destroy<ScriptCache>();573 DependencyManager::destroy<ScriptCache>();
570 DependencyManager::destroy<SoundCache>();574 DependencyManager::destroy<SoundCache>();
575 qDebug() << "done destroying ResourceCaches Application::~Application() line:" << __LINE__;
571}576}
572 577
573void Application::initializeGL() {578void Application::initializeGL() {
@@ -3466,7 +3471,7 @@ void Application::registerScriptEngineWithApplicationServices(ScriptEngine* scri · 2892 unmodified lines
3466 scriptEngine->registerGlobalObject("Settings", SettingsScriptingInterface::getInstance());3471 scriptEngine->registerGlobalObject("Settings", SettingsScriptingInterface::getInstance());
3467 scriptEngine->registerGlobalObject("AudioDevice", AudioDeviceScriptingInterface::getInstance());3472 scriptEngine->registerGlobalObject("AudioDevice", AudioDeviceScriptingInterface::getInstance());
3468 scriptEngine->registerGlobalObject("AnimationCache", DependencyManager::get<AnimationCache>().data());3473 scriptEngine->registerGlobalObject("AnimationCache", DependencyManager::get<AnimationCache>().data());
3469 scriptEngine->registerGlobalObject("SoundCache", &SoundCache::getInstance());3474 scriptEngine->registerGlobalObject("SoundCache", DependencyManager::get<SoundCache>().data());
3470 scriptEngine->registerGlobalObject("Account", AccountScriptingInterface::getInstance());3475 scriptEngine->registerGlobalObject("Account", AccountScriptingInterface::getInstance());
3471 scriptEngine->registerGlobalObject("Metavoxels", &_metavoxels);3476 scriptEngine->registerGlobalObject("Metavoxels", &_metavoxels);
3472 3477

Keyboard shortcuts

General

Show keyboard shortcuts
?
Focus the current search
/

Issues and pull requests

Open filters
f

Issues, pull requests and Inbox

Select next item
j↓
Select previous item
k↑
Open selected item
Enter
Dismiss filters or clear selection
Esc

Repository code

Go to file
t