summaryrefslogtreecommitdiff
path: root/indra/newview/llnavigationbar.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'indra/newview/llnavigationbar.cpp')
-rw-r--r--indra/newview/llnavigationbar.cpp18
1 files changed, 17 insertions, 1 deletions
diff --git a/indra/newview/llnavigationbar.cpp b/indra/newview/llnavigationbar.cpp
index b4a6e63de8..fbeff2d628 100644
--- a/indra/newview/llnavigationbar.cpp
+++ b/indra/newview/llnavigationbar.cpp
@@ -176,7 +176,8 @@ LLNavigationBar::LLNavigationBar()
mBtnHome(NULL),
mBtnHelp(NULL),
mCmbLocation(NULL),
- mLeSearch(NULL)
+ mLeSearch(NULL),
+ mPurgeTPHistoryItems(false)
{
setIsChrome(TRUE);
@@ -247,6 +248,12 @@ BOOL LLNavigationBar::postBuild()
void LLNavigationBar::draw()
{
+ if(mPurgeTPHistoryItems)
+ {
+ LLTeleportHistory::getInstance()->purgeItems();
+ onTeleportHistoryChanged();
+ mPurgeTPHistoryItems = false;
+ }
LLPanel::draw();
}
@@ -531,3 +538,12 @@ void LLNavigationBar::invokeSearch(std::string search_text)
{
LLFloaterReg::showInstance("search", LLSD().insert("panel", "all").insert("id", LLSD(search_text)));
}
+
+void LLNavigationBar::clearHistoryCache()
+{
+ mCmbLocation->removeall();
+ LLLocationHistory* lh = LLLocationHistory::getInstance();
+ lh->removeItems();
+ lh->save();
+ mPurgeTPHistoryItems= true;
+}