summaryrefslogtreecommitdiff
path: root/indra/newview/llviewermenu.cpp
diff options
context:
space:
mode:
authorandreykproductengine <andreykproductengine@lindenlab.com>2018-04-20 20:21:20 +0300
committerandreykproductengine <andreykproductengine@lindenlab.com>2018-04-20 20:21:20 +0300
commit66502df0502f1c2aa6aa9fda0a2a61921535a645 (patch)
treed37316b63ed6175158fddd10195f9a9d7a8f0d0f /indra/newview/llviewermenu.cpp
parent449a4f9b0653dc74133fbb18502c00a9398bfebb (diff)
MAINT-8540 Eliminated a lot of xui related log warnings on startup and opening preferences
Diffstat (limited to 'indra/newview/llviewermenu.cpp')
-rw-r--r--indra/newview/llviewermenu.cpp19
1 files changed, 19 insertions, 0 deletions
diff --git a/indra/newview/llviewermenu.cpp b/indra/newview/llviewermenu.cpp
index e973363e0f..0eebf2051c 100644
--- a/indra/newview/llviewermenu.cpp
+++ b/indra/newview/llviewermenu.cpp
@@ -7976,6 +7976,23 @@ void handle_web_browser_test(const LLSD& param)
LLWeb::loadURLInternal(url);
}
+bool callback_clear_cache_immediately(const LLSD& notification, const LLSD& response)
+{
+ S32 option = LLNotificationsUtil::getSelectedOption(notification, response);
+ if ( option == 0 ) // YES
+ {
+ //clear cache
+ LLAppViewer::instance()->purgeCacheImmediate();
+ }
+
+ return false;
+}
+
+void handle_cache_clear_immediately()
+{
+ LLNotificationsUtil::add("ConfirmClearCache", LLSD(), LLSD(), callback_clear_cache_immediately);
+}
+
void handle_web_content_test(const LLSD& param)
{
std::string url = param.asString();
@@ -9026,6 +9043,8 @@ void initialize_menus()
//Develop (Texture Fetch Debug Console)
view_listener_t::addMenu(new LLDevelopTextureFetchDebugger(), "Develop.SetTexFetchDebugger");
+ //Develop (clear cache immediately)
+ commit.add("Develop.ClearCache", boost::bind(&handle_cache_clear_immediately) );
// Admin >Object
view_listener_t::addMenu(new LLAdminForceTakeCopy(), "Admin.ForceTakeCopy");