Pulled apart LLInventoryPanel and LLInventoryView. TODO: LLInventoryView needs to be chopped apart into a floater (LLFloaterInventory) and a panel (LLPanelMainInventory).

This commit is contained in:
Shyotl
2012-01-29 17:10:04 -06:00
parent 9453c2c2e9
commit a0c549534f
46 changed files with 1514 additions and 1332 deletions

View File

@@ -2381,6 +2381,25 @@ void LLView::registerEventListener(std::string name, LLSimpleListener* function)
}
struct LLSignalListener : LLSimpleListener
{
LLSignalListener(LLView::event_signal_t::slot_type &cb)
{
mSignal.connect(cb);
}
/*virtual*/ bool handleEvent(LLPointer<LLEvent> event, const LLSD& userdata)
{
mSignal(event, userdata);
return true;
}
LLView::event_signal_t mSignal;
};
void LLView::registerEventListener(std::string name, event_signal_t::slot_type &cb)
{
registerEventListener(name, new LLSignalListener(cb));
}
void LLView::deregisterEventListener(std::string name)
{
dispatch_list_t::iterator itor = mDispatchList.find(name);