summaryrefslogtreecommitdiff
path: root/indra/newview/lllocationhistory.h
diff options
context:
space:
mode:
Diffstat (limited to 'indra/newview/lllocationhistory.h')
-rw-r--r--indra/newview/lllocationhistory.h17
1 files changed, 12 insertions, 5 deletions
diff --git a/indra/newview/lllocationhistory.h b/indra/newview/lllocationhistory.h
index 65f0dd2e1b..fb71fbaa0f 100644
--- a/indra/newview/lllocationhistory.h
+++ b/indra/newview/lllocationhistory.h
@@ -111,9 +111,16 @@ class LLLocationHistory: public LLSingleton<LLLocationHistory>
LOG_CLASS(LLLocationHistory);
public:
+ enum EChangeType
+ {
+ ADD
+ ,CLEAR
+ ,LOAD
+ };
+
typedef std::vector<LLLocationHistoryItem> location_list_t;
- typedef boost::function<void()> loaded_callback_t;
- typedef boost::signals2::signal<void()> loaded_signal_t;
+ typedef boost::function<void(EChangeType event)> history_changed_callback_t;
+ typedef boost::signals2::signal<void(EChangeType event)> history_changed_signal_t;
LLLocationHistory();
@@ -122,8 +129,8 @@ public:
void removeItems();
size_t getItemCount() const { return mItems.size(); }
const location_list_t& getItems() const { return mItems; }
- bool getMatchingItems(std::string substring, location_list_t& result) const;
- boost::signals2::connection setLoadedCallback(loaded_callback_t cb) { return mLoadedSignal.connect(cb); }
+ bool getMatchingItems(const std::string& substring, location_list_t& result) const;
+ boost::signals2::connection setChangedCallback(history_changed_callback_t cb) { return mChangedSignal.connect(cb); }
void save() const;
void load();
@@ -133,7 +140,7 @@ private:
location_list_t mItems;
std::string mFilename; /// File to store the history to.
- loaded_signal_t mLoadedSignal;
+ history_changed_signal_t mChangedSignal;
};
#endif