diff options
Diffstat (limited to 'src/application.cpp')
-rw-r--r-- | src/application.cpp | 15 |
1 files changed, 15 insertions, 0 deletions
diff --git a/src/application.cpp b/src/application.cpp index 8a24014d..231b45b7 100644 --- a/src/application.cpp +++ b/src/application.cpp @@ -42,6 +42,7 @@ #include "urlbar.h" #include "sessionmanager.h" #include "adblockmanager.h" +#include "search/opensearchmanager.h" #include "webview.h" #include "filterurljob.h" #include "tabbar.h" @@ -64,6 +65,7 @@ QWeakPointer<HistoryManager> Application::s_historyManager; QWeakPointer<BookmarkProvider> Application::s_bookmarkProvider; QWeakPointer<SessionManager> Application::s_sessionManager; QWeakPointer<AdBlockManager> Application::s_adblockManager; +QWeakPointer<OpenSearchManager> Application::s_opensearchManager; Application::Application() @@ -98,6 +100,9 @@ Application::~Application() delete s_adblockManager.data(); s_adblockManager.clear(); + + delete s_opensearchManager.data(); + s_opensearchManager.clear(); } @@ -315,6 +320,16 @@ SessionManager *Application::sessionManager() } +OpenSearchManager *Application::opensearchManager() +{ + if (s_opensearchManager.isNull()) + { + s_opensearchManager = new OpenSearchManager(instance()); + } + return s_opensearchManager.data(); +} + + KIcon Application::icon(const KUrl &url) { // avoid infinite loop at startup |