summaryrefslogtreecommitdiff
path: root/indra/newview/llfloatergesture.h
diff options
context:
space:
mode:
authorDmitry Zaporozhan <dzaporozhan@productengine.com>2009-11-20 19:24:07 +0200
committerDmitry Zaporozhan <dzaporozhan@productengine.com>2009-11-20 19:24:07 +0200
commitd0c1593d85cd26ad822d31e21df7a1864d66541c (patch)
tree30ceb3cfc19ccb36b7bcc7f0e5a2ad3efdd38747 /indra/newview/llfloatergesture.h
parent9d64bf132e27739dedeca17a1d952655c6b52ac3 (diff)
parent0c468557b9e38ec4be201fa991499ed095a4d8c3 (diff)
Merge
--HG-- branch : product-engine
Diffstat (limited to 'indra/newview/llfloatergesture.h')
-rw-r--r--indra/newview/llfloatergesture.h42
1 files changed, 31 insertions, 11 deletions
diff --git a/indra/newview/llfloatergesture.h b/indra/newview/llfloatergesture.h
index 50bef818da..14e132900d 100644
--- a/indra/newview/llfloatergesture.h
+++ b/indra/newview/llfloatergesture.h
@@ -36,11 +36,10 @@
#ifndef LL_LLFLOATERGESTURE_H
#define LL_LLFLOATERGESTURE_H
+#include <vector>
#include "llfloater.h"
-#include "llinventorymodel.h"
#include "llinventoryobserver.h"
-#include "lldarray.h"
class LLScrollContainer;
class LLView;
@@ -53,6 +52,7 @@ class LLScrollListCtrl;
class LLFloaterGestureObserver;
class LLFloaterGestureInventoryObserver;
class LLMultiGesture;
+class LLMenuGL;
class LLFloaterGesture
: public LLFloater, LLInventoryFetchDescendentsObserver
@@ -65,26 +65,46 @@ public:
virtual BOOL postBuild();
virtual void done ();
void refreshAll();
+ /**
+ * @brief Add new scrolllistitem into gesture_list.
+ * @param item_id inventory id of gesture
+ * @param gesture can be NULL , if item was not loaded yet
+ */
+ void addGesture(const LLUUID& item_id, LLMultiGesture* gesture, LLCtrlListInterface * list);
protected:
// Reads from the gesture manager's list of active gestures
// and puts them in this list.
void buildGestureList();
- void addGesture(const LLUUID& item_id, LLMultiGesture* gesture, LLCtrlListInterface * list);
- void onClickInventory();
+ void playGesture(LLUUID item_id);
+private:
+ void addToCurrentOutFit();
+ /**
+ * @brief This method is using to collect selected items.
+ * In some places gesture_list can be rebuilt by gestureObservers during iterating data from LLScrollListCtrl::getAllSelected().
+ * Therefore we have to copy these items to avoid viewer crash.
+ * @see LLFloaterGesture::onActivateBtnClick
+ */
+ void getSelectedIds(std::vector<LLUUID>& ids);
+ bool isActionEnabled(const LLSD& command);
+ /**
+ * @brief Activation rules:
+ * According to Gesture Spec:
+ * 1. If all selected gestures are active: set to inactive
+ * 2. If all selected gestures are inactive: set to active
+ * 3. If selected gestures are in a mixed state: set all to active
+ */
+ void onActivateBtnClick();
void onClickEdit();
void onClickPlay();
void onClickNew();
void onCommitList();
- void playGesture(LLUUID item_id);
- LLCtrlListInterface* getGestureList() const
- {
- return childGetListInterface("gesture_list");
- }
- void onActivateBtnClick();
-protected:
+ void onCopyPastAction(const LLSD& command);
+ void onDeleteSelected();
+
LLUUID mSelectedID;
LLUUID mGestureFolderID;
+ LLScrollListCtrl* mGestureList;
LLFloaterGestureObserver* mObserver;
};