From 596522c7e5a9bff53a56db90597c7bcbcdbf1537 Mon Sep 17 00:00:00 2001 From: dolphin Date: Tue, 29 Jan 2013 13:58:13 -0800 Subject: Added a combox to the script editor to select an experience. Selected experience is sent with the script when saved. The list of experiences is currently populated with the avatar's current experience, if any. --- indra/newview/llpreviewscript.h | 13 ++++++++----- 1 file changed, 8 insertions(+), 5 deletions(-) (limited to 'indra/newview/llpreviewscript.h') diff --git a/indra/newview/llpreviewscript.h b/indra/newview/llpreviewscript.h index 7563cecd9d..27252d17a1 100644 --- a/indra/newview/llpreviewscript.h +++ b/indra/newview/llpreviewscript.h @@ -106,6 +106,9 @@ public: static bool enableLoadFromFileMenu(void* userdata); virtual bool hasAccelerators() const { return true; } + void addExperienceInfo( const LLSD& experience ); + void clearExperiences(); + LLUUID getSelectedExperience()const; private: void onBtnHelp(); @@ -120,6 +123,9 @@ private: void enableSave(BOOL b) {mEnableSave = b;} + void requestExperiences(); + void experienceChanged(); + protected: void deleteBridges(); void setHelpPage(const std::string& help_string); @@ -135,6 +141,7 @@ private: void (*mSearchReplaceCallback) (void* userdata); void* mUserdata; LLComboBox *mFunctions; + LLComboBox *mExperiences; BOOL mForceClose; LLPanel* mCodePanel; LLScrollListCtrl* mErrorList; @@ -237,11 +244,7 @@ private: virtual void loadAsset(); void loadAsset(BOOL is_new); /*virtual*/ void saveIfNeeded(bool sync = true); - void uploadAssetViaCaps(const std::string& url, - const std::string& filename, - const LLUUID& task_id, - const LLUUID& item_id, - BOOL is_running); + void uploadAssetViaCaps(const std::string& url, const std::string& filename, const LLUUID& task_id, const LLUUID& item_id, BOOL is_running, const LLUUID& experience_public_id); void uploadAssetLegacy(const std::string& filename, LLViewerObject* object, const LLTransactionID& tid, -- cgit v1.2.3 From 6308f93c6adddc9d396e8d2527e97e0d02c4aa52 Mon Sep 17 00:00:00 2001 From: dolphin Date: Mon, 20 May 2013 10:04:29 -0700 Subject: WIP check in, testing GetMeta --- indra/newview/llpreviewscript.h | 11 +++++++---- 1 file changed, 7 insertions(+), 4 deletions(-) (limited to 'indra/newview/llpreviewscript.h') diff --git a/indra/newview/llpreviewscript.h b/indra/newview/llpreviewscript.h index 27252d17a1..b29d16c58d 100644 --- a/indra/newview/llpreviewscript.h +++ b/indra/newview/llpreviewscript.h @@ -108,7 +108,8 @@ public: virtual bool hasAccelerators() const { return true; } void addExperienceInfo( const LLSD& experience ); void clearExperiences(); - LLUUID getSelectedExperience()const; + LLUUID getSelectedExperience()const; + void setAssociatedExperience( const LLUUID& experience_id ); private: void onBtnHelp(); @@ -139,7 +140,7 @@ private: void (*mLoadCallback)(void* userdata); void (*mSaveCallback)(void* userdata, BOOL close_after_save); void (*mSearchReplaceCallback) (void* userdata); - void* mUserdata; + void* mUserdata; LLComboBox *mFunctions; LLComboBox *mExperiences; BOOL mForceClose; @@ -153,6 +154,7 @@ private: BOOL mEnableSave; BOOL mHasScriptData; LLLiveLSLFile* mLiveFile; + LLUUID mAssociatedExperience; LLScriptEdContainer* mContainer; // parent view }; @@ -234,7 +236,8 @@ public: /*virtual*/ BOOL postBuild(); - void setIsNew() { mIsNew = TRUE; } + void setIsNew() { mIsNew = TRUE; } + void setAssociatedExperience( const LLUUID& experience_id ); private: virtual BOOL canClose(); @@ -285,7 +288,7 @@ private: S32 mPendingUploads; BOOL getIsModifiable() const { return mIsModifiable; } // Evaluated on load assert - + LLCheckBoxCtrl* mMonoCheckbox; BOOL mIsModifiable; }; -- cgit v1.2.3 From 37bd01152ac278e3401a96b12baf5505c5c1f789 Mon Sep 17 00:00:00 2001 From: dolphin Date: Tue, 21 May 2013 22:57:15 -0700 Subject: Update experience request to use the new post service. --- indra/newview/llpreviewscript.h | 1 + 1 file changed, 1 insertion(+) (limited to 'indra/newview/llpreviewscript.h') diff --git a/indra/newview/llpreviewscript.h b/indra/newview/llpreviewscript.h index b29d16c58d..28e71b111a 100755 --- a/indra/newview/llpreviewscript.h +++ b/indra/newview/llpreviewscript.h @@ -238,6 +238,7 @@ public: void setIsNew() { mIsNew = TRUE; } void setAssociatedExperience( const LLUUID& experience_id ); + void fetchAssociatedExperience(const LLUUID& asset_id); private: virtual BOOL canClose(); -- cgit v1.2.3 From 08a1ae6839f07aeadb58326208c2c01b2ef667c3 Mon Sep 17 00:00:00 2001 From: dolphin Date: Tue, 6 Aug 2013 16:05:09 -0700 Subject: Checkpoint script editor --- indra/newview/llpreviewscript.h | 15 +++++++++++---- 1 file changed, 11 insertions(+), 4 deletions(-) (limited to 'indra/newview/llpreviewscript.h') diff --git a/indra/newview/llpreviewscript.h b/indra/newview/llpreviewscript.h index 28e71b111a..043bf9c0b7 100755 --- a/indra/newview/llpreviewscript.h +++ b/indra/newview/llpreviewscript.h @@ -100,7 +100,9 @@ public: static void onBtnInsertSample(void*); static void onBtnInsertFunction(LLUICtrl*, void*); static void onBtnLoadFromFile(void*); - static void onBtnSaveToFile(void*); + static void onBtnSaveToFile(void*); + static void onToggleExperience(LLUICtrl *ui, void* userdata); + static void onToggleExperienceDetails(void* userdata); static bool enableSaveToFileMenu(void* userdata); static bool enableLoadFromFileMenu(void* userdata); @@ -108,7 +110,8 @@ public: virtual bool hasAccelerators() const { return true; } void addExperienceInfo( const LLSD& experience ); void clearExperiences(); - LLUUID getSelectedExperience()const; + LLUUID getAssociatedExperience()const; + void setAssociatedExperience( const LLUUID& experience_id ); private: @@ -125,7 +128,8 @@ private: void enableSave(BOOL b) {mEnableSave = b;} void requestExperiences(); - void experienceChanged(); + void experienceChanged(); + void addAssociatedExperience(const LLSD& experience); protected: void deleteBridges(); @@ -142,7 +146,10 @@ private: void (*mSearchReplaceCallback) (void* userdata); void* mUserdata; LLComboBox *mFunctions; - LLComboBox *mExperiences; + LLComboBox *mExperiences; + LLCheckBoxCtrl *mExperienceEnabled; + LLUICtrl *mExperienceDetails; + LLButton *mExpandExperience; BOOL mForceClose; LLPanel* mCodePanel; LLScrollListCtrl* mErrorList; -- cgit v1.2.3 From 6354ad379d0850b4cc3969130fb1b30b0e2c0ee9 Mon Sep 17 00:00:00 2001 From: dolphin Date: Thu, 8 Aug 2013 09:26:09 -0700 Subject: Simplified the experience panel to only the required elements --- indra/newview/llpreviewscript.h | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) (limited to 'indra/newview/llpreviewscript.h') diff --git a/indra/newview/llpreviewscript.h b/indra/newview/llpreviewscript.h index 043bf9c0b7..9578396f91 100755 --- a/indra/newview/llpreviewscript.h +++ b/indra/newview/llpreviewscript.h @@ -102,17 +102,18 @@ public: static void onBtnLoadFromFile(void*); static void onBtnSaveToFile(void*); static void onToggleExperience(LLUICtrl *ui, void* userdata); - static void onToggleExperienceDetails(void* userdata); static bool enableSaveToFileMenu(void* userdata); static bool enableLoadFromFileMenu(void* userdata); virtual bool hasAccelerators() const { return true; } - void addExperienceInfo( const LLSD& experience ); - void clearExperiences(); + void addExperienceInfo( const LLSD& experience, BOOL enabled ); + void setExperienceIds(const LLSD& experience_ids); + void buildExperienceList(); LLUUID getAssociatedExperience()const; void setAssociatedExperience( const LLUUID& experience_id ); + void updateExperiencePanel(); private: void onBtnHelp(); @@ -148,8 +149,6 @@ private: LLComboBox *mFunctions; LLComboBox *mExperiences; LLCheckBoxCtrl *mExperienceEnabled; - LLUICtrl *mExperienceDetails; - LLButton *mExpandExperience; BOOL mForceClose; LLPanel* mCodePanel; LLScrollListCtrl* mErrorList; @@ -162,6 +161,7 @@ private: BOOL mHasScriptData; LLLiveLSLFile* mLiveFile; LLUUID mAssociatedExperience; + LLSD mExperienceIds; LLScriptEdContainer* mContainer; // parent view }; -- cgit v1.2.3 From 02b501e4dc9a389878cd323e4f781bc752fec737 Mon Sep 17 00:00:00 2001 From: dolphin Date: Thu, 15 Aug 2013 09:32:12 -0700 Subject: Move the experience panel to the bottom of the editor floater --- indra/newview/llpreviewscript.h | 35 +++++++++++++++++++---------------- 1 file changed, 19 insertions(+), 16 deletions(-) (limited to 'indra/newview/llpreviewscript.h') diff --git a/indra/newview/llpreviewscript.h b/indra/newview/llpreviewscript.h index 9578396f91..bd594cdb9d 100755 --- a/indra/newview/llpreviewscript.h +++ b/indra/newview/llpreviewscript.h @@ -101,19 +101,13 @@ public: static void onBtnInsertFunction(LLUICtrl*, void*); static void onBtnLoadFromFile(void*); static void onBtnSaveToFile(void*); - static void onToggleExperience(LLUICtrl *ui, void* userdata); static bool enableSaveToFileMenu(void* userdata); static bool enableLoadFromFileMenu(void* userdata); - virtual bool hasAccelerators() const { return true; } - void addExperienceInfo( const LLSD& experience, BOOL enabled ); - void setExperienceIds(const LLSD& experience_ids); - void buildExperienceList(); + virtual bool hasAccelerators() const { return true; } LLUUID getAssociatedExperience()const; - void setAssociatedExperience( const LLUUID& experience_id ); - void updateExperiencePanel(); private: void onBtnHelp(); @@ -128,10 +122,6 @@ private: void enableSave(BOOL b) {mEnableSave = b;} - void requestExperiences(); - void experienceChanged(); - void addAssociatedExperience(const LLSD& experience); - protected: void deleteBridges(); void setHelpPage(const std::string& help_string); @@ -146,9 +136,7 @@ private: void (*mSaveCallback)(void* userdata, BOOL close_after_save); void (*mSearchReplaceCallback) (void* userdata); void* mUserdata; - LLComboBox *mFunctions; - LLComboBox *mExperiences; - LLCheckBoxCtrl *mExperienceEnabled; + LLComboBox *mFunctions; BOOL mForceClose; LLPanel* mCodePanel; LLScrollListCtrl* mErrorList; @@ -161,7 +149,6 @@ private: BOOL mHasScriptData; LLLiveLSLFile* mLiveFile; LLUUID mAssociatedExperience; - LLSD mExperienceIds; LLScriptEdContainer* mContainer; // parent view }; @@ -244,8 +231,19 @@ public: /*virtual*/ BOOL postBuild(); void setIsNew() { mIsNew = TRUE; } - void setAssociatedExperience( const LLUUID& experience_id ); + + static void setAssociatedExperience( LLHandle editor, const LLSD& experience ); + static void onToggleExperience(LLUICtrl *ui, void* userdata); + void fetchAssociatedExperience(const LLUUID& asset_id); + + void addExperienceInfo( const LLSD& experience, BOOL enabled ); + void setExperienceIds(const LLSD& experience_ids); + void buildExperienceList(); + void updateExperiencePanel(); + void requestExperiences(); + void experienceChanged(); + void addAssociatedExperience(const LLSD& experience); private: virtual BOOL canClose(); @@ -299,6 +297,11 @@ private: LLCheckBoxCtrl* mMonoCheckbox; BOOL mIsModifiable; + + + LLComboBox *mExperiences; + LLCheckBoxCtrl *mExperienceEnabled; + LLSD mExperienceIds; }; #endif // LL_LLPREVIEWSCRIPT_H -- cgit v1.2.3 From b980efd014ddb56650fffeb7968901b8e6bc2837 Mon Sep 17 00:00:00 2001 From: dolphin Date: Mon, 19 Aug 2013 09:24:04 -0700 Subject: Added experience association info llsidepaneliteminfo for scripts. Changed the cap which looks up a script association to take a object/item id pair instead of a asset id. Updated llpreviewscript to use the new cap (which also improves loading time since it can be done in parallel with the lsltext retrieval). --- indra/newview/llpreviewscript.h | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) (limited to 'indra/newview/llpreviewscript.h') diff --git a/indra/newview/llpreviewscript.h b/indra/newview/llpreviewscript.h index bd594cdb9d..faeb4a5b8a 100755 --- a/indra/newview/llpreviewscript.h +++ b/indra/newview/llpreviewscript.h @@ -234,9 +234,7 @@ public: static void setAssociatedExperience( LLHandle editor, const LLSD& experience ); static void onToggleExperience(LLUICtrl *ui, void* userdata); - - void fetchAssociatedExperience(const LLUUID& asset_id); - + void addExperienceInfo( const LLSD& experience, BOOL enabled ); void setExperienceIds(const LLSD& experience_ids); void buildExperienceList(); -- cgit v1.2.3 From 257110c11e5546f0a5a07b087694cfc9059367b4 Mon Sep 17 00:00:00 2001 From: dolphin Date: Wed, 21 Aug 2013 15:43:09 -0700 Subject: Added new fields to the experience cache. Experience profile moved to it's own floater, will probalby be moving again. XP profile displays most data, though the presentation is not final Fixed a bug with the XP selection combobox in the script editor --- indra/newview/llpreviewscript.h | 4 ++++ 1 file changed, 4 insertions(+) (limited to 'indra/newview/llpreviewscript.h') diff --git a/indra/newview/llpreviewscript.h b/indra/newview/llpreviewscript.h index faeb4a5b8a..4e76238c71 100755 --- a/indra/newview/llpreviewscript.h +++ b/indra/newview/llpreviewscript.h @@ -49,6 +49,7 @@ class LLKeywordToken; class LLVFS; class LLViewerInventoryItem; class LLScriptEdContainer; +class LLFloaterExperienceProfile; // Inner, implementation class. LLPreviewScript and LLLiveLSLEditor each own one of these. class LLScriptEdCore : public LLPanel @@ -234,6 +235,7 @@ public: static void setAssociatedExperience( LLHandle editor, const LLSD& experience ); static void onToggleExperience(LLUICtrl *ui, void* userdata); + static void onViewProfile(LLUICtrl *ui, void* userdata); void addExperienceInfo( const LLSD& experience, BOOL enabled ); void setExperienceIds(const LLSD& experience_ids); @@ -300,6 +302,8 @@ private: LLComboBox *mExperiences; LLCheckBoxCtrl *mExperienceEnabled; LLSD mExperienceIds; + + LLHandle mExperienceProfile; }; #endif // LL_LLPREVIEWSCRIPT_H -- cgit v1.2.3 From 7b9817cbcc5acab58d9d4355984b429850bd3ef8 Mon Sep 17 00:00:00 2001 From: dolphin Date: Mon, 10 Mar 2014 10:15:19 -0700 Subject: Fixed a bug that lost callbacks if > 10 experiences were looked up at a time. --- indra/newview/llpreviewscript.h | 1 - 1 file changed, 1 deletion(-) (limited to 'indra/newview/llpreviewscript.h') diff --git a/indra/newview/llpreviewscript.h b/indra/newview/llpreviewscript.h index 29d1443d6c..0264601d83 100755 --- a/indra/newview/llpreviewscript.h +++ b/indra/newview/llpreviewscript.h @@ -240,7 +240,6 @@ public: static void onToggleExperience(LLUICtrl *ui, void* userdata); static void onViewProfile(LLUICtrl *ui, void* userdata); - void addExperienceInfo( const LLSD& experience, BOOL enabled ); void setExperienceIds(const LLSD& experience_ids); void buildExperienceList(); void updateExperiencePanel(); -- cgit v1.2.3