summaryrefslogtreecommitdiff
path: root/indra/newview/llrootview.h
diff options
context:
space:
mode:
Diffstat (limited to 'indra/newview/llrootview.h')
-rw-r--r--indra/newview/llrootview.h22
1 files changed, 22 insertions, 0 deletions
diff --git a/indra/newview/llrootview.h b/indra/newview/llrootview.h
index f704fecddd..760b1a7a4c 100644
--- a/indra/newview/llrootview.h
+++ b/indra/newview/llrootview.h
@@ -47,5 +47,27 @@ public:
LLRootView(const Params& p)
: LLView(p)
{}
+
+ // added to provide possibility to handle mouse click event inside all application
+ // window without creating any floater
+ typedef boost::signals2::signal<void(S32 x, S32 y, MASK mask)>
+ mouse_signal_t;
+
+ private:
+ mouse_signal_t mMouseDownSignal;
+
+ public:
+ /*virtual*/
+ BOOL handleMouseDown(S32 x, S32 y, MASK mask)
+ {
+ mMouseDownSignal(x, y, mask);
+ return LLView::handleMouseDown(x, y, mask);
+ }
+
+ boost::signals2::connection addMouseDownCallback(
+ const mouse_signal_t::slot_type& cb)
+ {
+ return mMouseDownSignal.connect(cb);
+ }
};
#endif //LL_LLROOTVIEW_H