diff options
| author | Steven Bennetts <steve@lindenlab.com> | 2009-10-01 17:44:44 +0000 |
|---|---|---|
| committer | Steven Bennetts <steve@lindenlab.com> | 2009-10-01 17:44:44 +0000 |
| commit | f05df68656d2abdc38d86cd6746398fa90eb8614 (patch) | |
| tree | 95f389551a7132b86dd96ff7c55b92674ee16756 /indra/newview/llchatitemscontainerctrl.h | |
| parent | 090977608d3d4e1d6d26689064910221c66f6084 (diff) | |
merge https://svn.aws.productengine.com/secondlife/export-from-ll/viewer-2-0@1868 https://svn.aws.productengine.com/secondlife/pe/stable-2@1876 -> viewer-2.0.0-3
* Bugs: EXT-1111 EXT-915 EXT-1131 EXT-1200 EXT-1202 EXT-1201 EXT-1205 EXT-1212 EXT-1173 EXT-1229 EXT-1218 EXT-1164 EXT-996 EXT-821 EXT-1030 EXT-1031 EXT-816
* Major Bugs: EXT-1142 (timeout during login due to processing group IMs)
* Changes: EXT-1216 (minimize message well)
Diffstat (limited to 'indra/newview/llchatitemscontainerctrl.h')
| -rw-r--r-- | indra/newview/llchatitemscontainerctrl.h | 86 |
1 files changed, 17 insertions, 69 deletions
diff --git a/indra/newview/llchatitemscontainerctrl.h b/indra/newview/llchatitemscontainerctrl.h index de16cf9505..8fb045b6d9 100644 --- a/indra/newview/llchatitemscontainerctrl.h +++ b/indra/newview/llchatitemscontainerctrl.h @@ -37,6 +37,7 @@ #include "llscrollbar.h" #include "string" #include "llchat.h" +#include "lltoastpanel.h" typedef enum e_show_item_header { @@ -45,20 +46,18 @@ typedef enum e_show_item_header CHATITEMHEADER_SHOW_BOTH } EShowItemHeader; -class LLChatItemCtrl: public LLPanel +class LLNearbyChatToastPanel: public LLToastPanelBase { protected: - LLChatItemCtrl(){}; + LLNearbyChatToastPanel():mIsDirty(false){}; public: - ~LLChatItemCtrl(){} + ~LLNearbyChatToastPanel(){} - static LLChatItemCtrl* createInstance(); + static LLNearbyChatToastPanel* createInstance(); - void draw(); - - const LLChat& getMessage() const { return mOriginalMessage;} + const LLUUID& getFromID() const { return mFromID;} void addText (const std::string& message); void setMessage (const LLChat& msg); @@ -77,78 +76,27 @@ public: void setHeaderVisibility(EShowItemHeader e); BOOL handleRightMouseDown(S32 x, S32 y, MASK mask); -private: - - std::string appendTime (); - -private: - LLChat mOriginalMessage; - - std::vector<std::string> mMessages; -}; - -class LLChatItemsContainerCtrl: public LLPanel -{ -public: - struct Params - : public LLInitParam::Block<Params, LLPanel::Params> - { - Params(){}; - }; - - LLChatItemsContainerCtrl(const Params& params); - - - ~LLChatItemsContainerCtrl(){} - - void addMessage (const LLChat& msg); - - void draw(); - - void reshape (S32 width, S32 height, BOOL called_from_parent = TRUE); - - void onScrollPosChangeCallback(S32, LLScrollbar*); - - virtual BOOL postBuild(); - - BOOL handleMouseDown (S32 x, S32 y, MASK mask); - BOOL handleKeyHere (KEY key, MASK mask); - BOOL handleScrollWheel( S32 x, S32 y, S32 clicks ); - - void scrollToBottom (); - - void setHeaderVisibility(EShowItemHeader e); - EShowItemHeader getHeaderVisibility() const { return mEShowItemHeader;}; + virtual void init(LLSD& data); + virtual void draw(); private: - void reformatHistoryScrollItems(S32 width); - void arrange (S32 width, S32 height); - - S32 calcRecuiredHeight (); - S32 getRecuiredHeight () const { return mInnerRect.getHeight(); } - - void updateLayout (S32 width, S32 height); - - void show_hide_scrollbar (S32 width, S32 height); - - void showScrollbar (S32 width, S32 height); - void hideScrollbar (S32 width, S32 height); - - void panelSetLeftTopAndSize (LLView* panel, S32 left, S32 top, S32 width, S32 height); - void panelShiftVertical (LLView* panel,S32 delta); - void shiftPanels (S32 delta); + + std::string appendTime (); private: - std::vector<LLChatItemCtrl*> mItems; + std::string mText; // UTF-8 line of text + std::string mFromName; // agent or object name + LLUUID mFromID; // agent id or object id + EChatSourceType mSourceType; - EShowItemHeader mEShowItemHeader; - LLRect mInnerRect; - LLScrollbar* mScrollbar; + std::vector<std::string> mMessages; + bool mIsDirty; }; + #endif |
