diff options
Diffstat (limited to 'indra/newview/llpanelgrouproles.h')
-rw-r--r-- | indra/newview/llpanelgrouproles.h | 54 |
1 files changed, 19 insertions, 35 deletions
diff --git a/indra/newview/llpanelgrouproles.h b/indra/newview/llpanelgrouproles.h index 95057bbfaf..bd5fc1d235 100644 --- a/indra/newview/llpanelgrouproles.h +++ b/indra/newview/llpanelgrouproles.h @@ -35,6 +35,7 @@ #include "llpanelgroup.h" +class LLFilterEditor; class LLNameListCtrl; class LLPanelGroupSubTab; class LLPanelGroupMembersSubTab; @@ -42,17 +43,17 @@ class LLPanelGroupRolesSubTab; class LLPanelGroupActionsSubTab; class LLScrollListCtrl; class LLScrollListItem; +class LLTextEditor; // Forward declare for friend usage. //virtual BOOL LLPanelGroupSubTab::postBuildSubTab(LLView*); typedef std::map<std::string,std::string> icon_map_t; -class LLPanelGroupRoles : public LLPanelGroupTab, - public LLPanelGroupTabObserver +class LLPanelGroupRoles : public LLPanelGroupTab { public: - LLPanelGroupRoles(const std::string& name, const LLUUID& group_id); + LLPanelGroupRoles(); virtual ~LLPanelGroupRoles(); // Allow sub tabs to ask for sibling controls. @@ -63,8 +64,7 @@ public: virtual BOOL postBuild(); virtual BOOL isVisibleByAgent(LLAgent* agentp); - static void* createTab(void* data); - static void onClickSubTab(void*,bool); + void handleClickSubTab(); // Checks if the current tab needs to be applied, and tries to switch to the requested tab. @@ -87,8 +87,7 @@ public: virtual void cancel(); virtual void update(LLGroupChange gc); - // PanelGroupTab observer trigger - virtual void tabChanged(); + virtual void setGroupID(const LLUUID& id); protected: LLPanelGroupTab* mCurrentTab; @@ -104,7 +103,7 @@ protected: class LLPanelGroupSubTab : public LLPanelGroupTab { public: - LLPanelGroupSubTab(const std::string& name, const LLUUID& group_id); + LLPanelGroupSubTab(); virtual ~LLPanelGroupSubTab(); virtual BOOL postBuild(); @@ -112,14 +111,6 @@ public: // This allows sub-tabs to collect child widgets from a higher level in the view hierarchy. virtual BOOL postBuildSubTab(LLView* root) { return TRUE; } - static void onSearchKeystroke(LLLineEditor* caller, void* user_data); - void handleSearchKeystroke(LLLineEditor* caller); - - static void onClickSearch(void*); - void handleClickSearch(); - static void onClickShowAll(void*); - void handleClickShowAll(); - virtual void setSearchFilter( const std::string& filter ); virtual void activate(); @@ -131,7 +122,7 @@ public: U64 allowed_by_some, U64 allowed_by_all, icon_map_t& icons, - void (*commit_callback)(LLUICtrl*,void*), + LLUICtrl::commit_callback_t commit_callback, BOOL show_all, BOOL filter, BOOL is_owner_role); @@ -140,19 +131,19 @@ public: U64 allowed_by_all, LLRoleActionSet* action_set, icon_map_t& icons, - void (*commit_callback)(LLUICtrl*,void*), + LLUICtrl::commit_callback_t commit_callback, BOOL show_all, BOOL filter, BOOL is_owner_role); void setFooterEnabled(BOOL enable); + + virtual void setGroupID(const LLUUID& id); protected: LLPanel* mHeader; LLPanel* mFooter; - LLLineEditor* mSearchLineEditor; - LLButton* mSearchButton; - LLButton* mShowAllButton; + LLFilterEditor* mSearchEditor; std::string mSearchFilter; @@ -164,13 +155,11 @@ protected: class LLPanelGroupMembersSubTab : public LLPanelGroupSubTab { public: - LLPanelGroupMembersSubTab(const std::string& name, const LLUUID& group_id); + LLPanelGroupMembersSubTab(); virtual ~LLPanelGroupMembersSubTab(); virtual BOOL postBuildSubTab(LLView* root); - static void* createTab(void* data); - static void onMemberSelect(LLUICtrl*, void*); void handleMemberSelect(); @@ -200,6 +189,8 @@ public: virtual void draw(); + virtual void setGroupID(const LLUUID& id); + protected: typedef std::map<LLUUID, LLRoleMemberChangeType> role_change_data_map_t; typedef std::map<LLUUID, role_change_data_map_t*> member_role_changes_map_t; @@ -229,13 +220,11 @@ protected: class LLPanelGroupRolesSubTab : public LLPanelGroupSubTab { public: - LLPanelGroupRolesSubTab(const std::string& name, const LLUUID& group_id); + LLPanelGroupRolesSubTab(); virtual ~LLPanelGroupRolesSubTab(); virtual BOOL postBuildSubTab(LLView* root); - static void* createTab(void* data); - virtual void activate(); virtual void deactivate(); virtual bool needsApply(std::string& mesg); @@ -249,7 +238,6 @@ public: void buildMembersList(); static void onActionCheck(LLUICtrl*, void*); - void handleActionCheck(LLCheckBoxCtrl*, bool force=false); bool addActionCB(const LLSD& notification, const LLSD& response, LLCheckBoxCtrl* check); static void onPropertiesKey(LLLineEditor*, void*); @@ -268,10 +256,8 @@ public: void saveRoleChanges(); protected: - LLSD createRoleItem(const LLUUID& role_id, - std::string name, - std::string title, - S32 members); + void handleActionCheck(LLUICtrl* ctrl, bool force); + LLSD createRoleItem(const LLUUID& role_id, std::string name, std::string title, S32 members); LLScrollListCtrl* mRolesList; LLNameListCtrl* mAssignedMembersList; @@ -293,12 +279,11 @@ protected: class LLPanelGroupActionsSubTab : public LLPanelGroupSubTab { public: - LLPanelGroupActionsSubTab(const std::string& name, const LLUUID& group_id); + LLPanelGroupActionsSubTab(); virtual ~LLPanelGroupActionsSubTab(); virtual BOOL postBuildSubTab(LLView* root); - static void* createTab(void* data); virtual void activate(); virtual void deactivate(); @@ -306,7 +291,6 @@ public: virtual bool apply(std::string& mesg); virtual void update(LLGroupChange gc); - static void onActionSelect(LLUICtrl*, void*); void handleActionSelect(); protected: LLScrollListCtrl* mActionList; |