From b31631934a7caa0fe331cd25e745e8b9c9485798 Mon Sep 17 00:00:00 2001 From: pavelk_productengine Date: Tue, 3 Feb 2015 19:44:25 +0200 Subject: MAINT-4734 (Separate transaction notices from group notice/invites) - added code to sort notifications between tabs: Invites, Transactions, System messages - made cosmetic changes according to comment from 27/Jan/15 in Jira - added code to show correct number of notifications on each tab - added code to close all notifications on current tab via "Delete all" button --- indra/newview/llnotificationlistitem.h | 136 +++++++++++++++++++++++++++++++++ 1 file changed, 136 insertions(+) create mode 100644 indra/newview/llnotificationlistitem.h (limited to 'indra/newview/llnotificationlistitem.h') diff --git a/indra/newview/llnotificationlistitem.h b/indra/newview/llnotificationlistitem.h new file mode 100644 index 0000000000..bc77d873a4 --- /dev/null +++ b/indra/newview/llnotificationlistitem.h @@ -0,0 +1,136 @@ +/** + * @file llnotificationlistitem.h + * @brief // TODO + * + * $LicenseInfo:firstyear=2003&license=viewerlgpl$ + * Second Life Viewer Source Code + * Copyright (C) 2015, Linden Research, Inc. + * + * This library is free software; you can redistribute it and/or + * modify it under the terms of the GNU Lesser General Public + * License as published by the Free Software Foundation; + * version 2.1 of the License only. + * + * This library is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + * Lesser General Public License for more details. + * + * You should have received a copy of the GNU Lesser General Public + * License along with this library; if not, write to the Free Software + * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA + * + * Linden Research, Inc., 945 Battery Street, San Francisco, CA 94111 USA + * $/LicenseInfo$ + */ + +#ifndef LL_LLNOTIFICATIONLISTITEM_H +#define LL_LLNOTIFICATIONLISTITEM_H + +#include "llpanel.h" +#include "lltextbox.h" +#include "llbutton.h" +#include "lliconctrl.h" + +#include "llgroupmgr.h" + +#include + +class LLNotificationListItem : public LLPanel +{ +public: + struct Params : public LLInitParam::Block + { + LLUUID notification_id; + LLUUID group_id; + std::string notification_name; + std::string title; + std::string sender; + LLDate time_stamp; + Params() {}; + }; + + static LLNotificationListItem* create(const Params& p); + + static std::set getInviteTypes(); + static std::set getTransactionTypes(); + + // title + void setTitle( std::string title ); + + // get item's ID + LLUUID getID() { return mID; } + std::string getTitle() { return mTitle; } + std::string getNotificationName() { return mNotificationName; } + + // handlers + virtual BOOL handleMouseDown(S32 x, S32 y, MASK mask); + virtual void onMouseEnter(S32 x, S32 y, MASK mask); + virtual void onMouseLeave(S32 x, S32 y, MASK mask); + + //callbacks + typedef boost::function item_callback_t; + typedef boost::signals2::signal item_signal_t; + item_signal_t mOnItemClose; + item_signal_t mOnItemClick; + boost::signals2::connection setOnItemCloseCallback(item_callback_t cb) { return mOnItemClose.connect(cb); } + boost::signals2::connection setOnItemClickCallback(item_callback_t cb) { return mOnItemClick.connect(cb); } + +protected: + LLNotificationListItem(const Params& p); + virtual ~LLNotificationListItem(); + + static std::string buildNotificationDate(const LLDate&); + void onClickCloseBtn(); + + LLTextBox* mTitleBox; + LLTextBox* mTimeBox; + LLButton* mCloseBtn; + LLUUID mID; + std::string mTitle; + std::string mNotificationName; + LLTextBox* mSenderBox; +}; + +class LLInviteNotificationListItem : public LLNotificationListItem +{ +public: + //void setGroupID(const LLUUID& group_id); + //void setGroupIconID(const LLUUID& group_icon_id); + //void setGroupName(const std::string& group_name); + static std::set getTypes(); +private: + friend class LLNotificationListItem; + LLInviteNotificationListItem(const Params& p); + LLInviteNotificationListItem(const LLInviteNotificationListItem &); + LLInviteNotificationListItem & operator=(LLInviteNotificationListItem &); + + LLIconCtrl* mGroupIcon; + LLUUID mGroupID; +}; + +class LLTransactionNotificationListItem : public LLNotificationListItem +{ +public: + static std::set getTypes(); +private: + friend class LLNotificationListItem; + LLTransactionNotificationListItem(const Params& p); + LLTransactionNotificationListItem(const LLTransactionNotificationListItem &); + LLTransactionNotificationListItem & operator=(LLTransactionNotificationListItem &); +}; + +class LLSystemNotificationListItem : public LLNotificationListItem +{ +public: + static std::set getTypes(); +private: + friend class LLNotificationListItem; + LLSystemNotificationListItem(const Params& p); + LLSystemNotificationListItem(const LLSystemNotificationListItem &); + LLSystemNotificationListItem & operator=(LLSystemNotificationListItem &); +}; + +#endif // LL_LLNOTIFICATIONLISTITEM_H + + -- cgit v1.2.3 From 5f96f3bba20fcacbe7115b7d27bc50cad56850d4 Mon Sep 17 00:00:00 2001 From: pavelkproductengine Date: Wed, 4 Feb 2015 15:48:22 +0200 Subject: MAINT-4734 (Separate transaction notices from group notice/invites) - fixed Mac build --- indra/newview/llnotificationlistitem.h | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'indra/newview/llnotificationlistitem.h') diff --git a/indra/newview/llnotificationlistitem.h b/indra/newview/llnotificationlistitem.h index bc77d873a4..89de0487be 100644 --- a/indra/newview/llnotificationlistitem.h +++ b/indra/newview/llnotificationlistitem.h @@ -60,8 +60,8 @@ public: // get item's ID LLUUID getID() { return mID; } - std::string getTitle() { return mTitle; } - std::string getNotificationName() { return mNotificationName; } + std::string& getTitle() { return mTitle; } + std::string& getNotificationName() { return mNotificationName; } // handlers virtual BOOL handleMouseDown(S32 x, S32 y, MASK mask); -- cgit v1.2.3 From 9d8bbe16007ef9292a04856f55f71016cf1220bf Mon Sep 17 00:00:00 2001 From: pavelk_productengine Date: Tue, 10 Feb 2015 19:56:32 +0200 Subject: MAINT-4734 (Separate transaction notices from group notice/invites) - introduced different design for System, Incoming/Outcoming Transactions, Invites --- indra/newview/llnotificationlistitem.h | 14 +++++++++++--- 1 file changed, 11 insertions(+), 3 deletions(-) (limited to 'indra/newview/llnotificationlistitem.h') diff --git a/indra/newview/llnotificationlistitem.h b/indra/newview/llnotificationlistitem.h index 89de0487be..da6d792fb8 100644 --- a/indra/newview/llnotificationlistitem.h +++ b/indra/newview/llnotificationlistitem.h @@ -30,7 +30,7 @@ #include "llpanel.h" #include "lltextbox.h" #include "llbutton.h" -#include "lliconctrl.h" +#include "llgroupiconctrl.h" #include "llgroupmgr.h" @@ -76,6 +76,7 @@ public: boost::signals2::connection setOnItemCloseCallback(item_callback_t cb) { return mOnItemClose.connect(cb); } boost::signals2::connection setOnItemClickCallback(item_callback_t cb) { return mOnItemClick.connect(cb); } + virtual BOOL postBuild(); protected: LLNotificationListItem(const Params& p); virtual ~LLNotificationListItem(); @@ -83,13 +84,13 @@ protected: static std::string buildNotificationDate(const LLDate&); void onClickCloseBtn(); + Params mParams; LLTextBox* mTitleBox; LLTextBox* mTimeBox; LLButton* mCloseBtn; LLUUID mID; std::string mTitle; std::string mNotificationName; - LLTextBox* mSenderBox; }; class LLInviteNotificationListItem : public LLNotificationListItem @@ -99,36 +100,43 @@ public: //void setGroupIconID(const LLUUID& group_icon_id); //void setGroupName(const std::string& group_name); static std::set getTypes(); + + virtual BOOL postBuild(); private: friend class LLNotificationListItem; LLInviteNotificationListItem(const Params& p); LLInviteNotificationListItem(const LLInviteNotificationListItem &); LLInviteNotificationListItem & operator=(LLInviteNotificationListItem &); - LLIconCtrl* mGroupIcon; + LLGroupIconCtrl* mGroupIcon; LLUUID mGroupID; + LLTextBox* mSenderBox; }; class LLTransactionNotificationListItem : public LLNotificationListItem { public: static std::set getTypes(); + virtual BOOL postBuild(); private: friend class LLNotificationListItem; LLTransactionNotificationListItem(const Params& p); LLTransactionNotificationListItem(const LLTransactionNotificationListItem &); LLTransactionNotificationListItem & operator=(LLTransactionNotificationListItem &); + LLIconCtrl* mTransactionIcon; }; class LLSystemNotificationListItem : public LLNotificationListItem { public: static std::set getTypes(); + virtual BOOL postBuild(); private: friend class LLNotificationListItem; LLSystemNotificationListItem(const Params& p); LLSystemNotificationListItem(const LLSystemNotificationListItem &); LLSystemNotificationListItem & operator=(LLSystemNotificationListItem &); + LLIconCtrl* mSystemNotificationIcon; }; #endif // LL_LLNOTIFICATIONLISTITEM_H -- cgit v1.2.3 From 575b750d1c1d3de2c86ad80759a2ba51d671344a Mon Sep 17 00:00:00 2001 From: pavelk_productengine Date: Tue, 24 Feb 2015 17:27:00 +0200 Subject: MAINT-4734 (Separate transaction notices from group notice/invites) - introduced expanded notification view and general condense/expand behaviour for all types of notifications --- indra/newview/llnotificationlistitem.h | 36 ++++++++++++++++++++++++++++++---- 1 file changed, 32 insertions(+), 4 deletions(-) (limited to 'indra/newview/llnotificationlistitem.h') diff --git a/indra/newview/llnotificationlistitem.h b/indra/newview/llnotificationlistitem.h index da6d792fb8..f5cd9422b5 100644 --- a/indra/newview/llnotificationlistitem.h +++ b/indra/newview/llnotificationlistitem.h @@ -28,6 +28,7 @@ #define LL_LLNOTIFICATIONLISTITEM_H #include "llpanel.h" +#include "lllayoutstack.h" #include "lltextbox.h" #include "llbutton.h" #include "llgroupiconctrl.h" @@ -59,7 +60,7 @@ public: void setTitle( std::string title ); // get item's ID - LLUUID getID() { return mID; } + LLUUID getID() { return mParams.notification_id; } std::string& getTitle() { return mTitle; } std::string& getNotificationName() { return mNotificationName; } @@ -82,18 +83,34 @@ protected: virtual ~LLNotificationListItem(); static std::string buildNotificationDate(const LLDate&); + void setExpanded(BOOL value); + void onClickExpandBtn(); + void onClickCondenseBtn(); void onClickCloseBtn(); Params mParams; LLTextBox* mTitleBox; + LLTextBox* mTitleBoxExp; + LLTextBox* mNoticeTextExp; LLTextBox* mTimeBox; + LLTextBox* mTimeBoxExp; + LLButton* mExpandBtn; + LLButton* mCondenseBtn; LLButton* mCloseBtn; - LLUUID mID; + LLButton* mCloseBtnExp; + LLLayoutStack* mVerticalStack; + LLPanel* mCondensedViewPanel; + LLPanel* mExpandedViewPanel; + LLPanel* mMainPanel; + //LLUUID mID; std::string mTitle; std::string mNotificationName; + S32 mCondensedHeight; + S32 mExpandedHeight; }; -class LLInviteNotificationListItem : public LLNotificationListItem +class LLInviteNotificationListItem + : public LLNotificationListItem, public LLGroupMgrObserver { public: //void setGroupID(const LLUUID& group_id); @@ -102,15 +119,24 @@ public: static std::set getTypes(); virtual BOOL postBuild(); + + void setGroupId(const LLUUID& value); + // LLGroupMgrObserver observer trigger + virtual void changed(LLGroupChange gc); private: friend class LLNotificationListItem; LLInviteNotificationListItem(const Params& p); LLInviteNotificationListItem(const LLInviteNotificationListItem &); LLInviteNotificationListItem & operator=(LLInviteNotificationListItem &); + bool updateFromCache(); + LLGroupIconCtrl* mGroupIcon; - LLUUID mGroupID; + LLGroupIconCtrl* mGroupIconExp; + LLUUID mGroupId; LLTextBox* mSenderBox; + LLTextBox* mSenderBoxExp; + LLTextBox* mGroupNameBoxExp; }; class LLTransactionNotificationListItem : public LLNotificationListItem @@ -124,6 +150,7 @@ private: LLTransactionNotificationListItem(const LLTransactionNotificationListItem &); LLTransactionNotificationListItem & operator=(LLTransactionNotificationListItem &); LLIconCtrl* mTransactionIcon; + LLIconCtrl* mTransactionIconExp; }; class LLSystemNotificationListItem : public LLNotificationListItem @@ -137,6 +164,7 @@ private: LLSystemNotificationListItem(const LLSystemNotificationListItem &); LLSystemNotificationListItem & operator=(LLSystemNotificationListItem &); LLIconCtrl* mSystemNotificationIcon; + LLIconCtrl* mSystemNotificationIconExp; }; #endif // LL_LLNOTIFICATIONLISTITEM_H -- cgit v1.2.3 From b147d659dc0c94a972f1c82f16536b374ee10c19 Mon Sep 17 00:00:00 2001 From: pavelk_productengine Date: Tue, 17 Mar 2015 18:26:28 +0200 Subject: MAINT-4734 (Separate transaction notices from group notice/invites) 1) stripped off attachment field; 2) made logos (group's, sender's, etc) in expanded view the same size as in condensed view; 3) turned on notification showing upon click; 4) fixed cropped right border of Invite and Transactions notifications; 5) enabled "Collapse All" button; 6) stripped off unnecessary icons. --- indra/newview/llnotificationlistitem.h | 78 +++++++++++++++++----------------- 1 file changed, 38 insertions(+), 40 deletions(-) (limited to 'indra/newview/llnotificationlistitem.h') diff --git a/indra/newview/llnotificationlistitem.h b/indra/newview/llnotificationlistitem.h index f5cd9422b5..22003a3a6a 100644 --- a/indra/newview/llnotificationlistitem.h +++ b/indra/newview/llnotificationlistitem.h @@ -1,8 +1,8 @@ /** * @file llnotificationlistitem.h - * @brief // TODO + * @brief * - * $LicenseInfo:firstyear=2003&license=viewerlgpl$ + * $LicenseInfo:firstyear=2015&license=viewerlgpl$ * Second Life Viewer Source Code * Copyright (C) 2015, Linden Research, Inc. * @@ -32,6 +32,7 @@ #include "lltextbox.h" #include "llbutton.h" #include "llgroupiconctrl.h" +#include "llavatariconctrl.h" #include "llgroupmgr.h" @@ -40,13 +41,15 @@ class LLNotificationListItem : public LLPanel { public: - struct Params : public LLInitParam::Block + struct Params : public LLInitParam::Block { - LLUUID notification_id; + LLUUID notification_id; LLUUID group_id; - std::string notification_name; - std::string title; - std::string sender; + LLUUID paid_from_id; + LLUUID paid_to_id; + std::string notification_name; + std::string title; + std::string sender; LLDate time_stamp; Params() {}; }; @@ -65,44 +68,41 @@ public: std::string& getNotificationName() { return mNotificationName; } // handlers - virtual BOOL handleMouseDown(S32 x, S32 y, MASK mask); - virtual void onMouseEnter(S32 x, S32 y, MASK mask); - virtual void onMouseLeave(S32 x, S32 y, MASK mask); + virtual BOOL handleMouseUp(S32 x, S32 y, MASK mask); //callbacks typedef boost::function item_callback_t; typedef boost::signals2::signal item_signal_t; - item_signal_t mOnItemClose; - item_signal_t mOnItemClick; + item_signal_t mOnItemClose; + item_signal_t mOnItemClick; boost::signals2::connection setOnItemCloseCallback(item_callback_t cb) { return mOnItemClose.connect(cb); } boost::signals2::connection setOnItemClickCallback(item_callback_t cb) { return mOnItemClick.connect(cb); } - + + void setExpanded(BOOL value); virtual BOOL postBuild(); protected: LLNotificationListItem(const Params& p); - virtual ~LLNotificationListItem(); + virtual ~LLNotificationListItem(); static std::string buildNotificationDate(const LLDate&); - void setExpanded(BOOL value); - void onClickExpandBtn(); - void onClickCondenseBtn(); + void onClickExpandBtn(); + void onClickCondenseBtn(); void onClickCloseBtn(); Params mParams; - LLTextBox* mTitleBox; - LLTextBox* mTitleBoxExp; - LLTextBox* mNoticeTextExp; + LLTextBox* mTitleBox; + LLTextBox* mTitleBoxExp; + LLTextBox* mNoticeTextExp; LLTextBox* mTimeBox; LLTextBox* mTimeBoxExp; - LLButton* mExpandBtn; - LLButton* mCondenseBtn; - LLButton* mCloseBtn; - LLButton* mCloseBtnExp; + LLButton* mExpandBtn; + LLButton* mCondenseBtn; + LLButton* mCloseBtn; + LLButton* mCloseBtnExp; LLLayoutStack* mVerticalStack; LLPanel* mCondensedViewPanel; - LLPanel* mExpandedViewPanel; + LLPanel* mExpandedViewPanel; LLPanel* mMainPanel; - //LLUUID mID; std::string mTitle; std::string mNotificationName; S32 mCondensedHeight; @@ -113,11 +113,7 @@ class LLInviteNotificationListItem : public LLNotificationListItem, public LLGroupMgrObserver { public: - //void setGroupID(const LLUUID& group_id); - //void setGroupIconID(const LLUUID& group_icon_id); - //void setGroupName(const std::string& group_name); static std::set getTypes(); - virtual BOOL postBuild(); void setGroupId(const LLUUID& value); @@ -129,41 +125,43 @@ private: LLInviteNotificationListItem(const LLInviteNotificationListItem &); LLInviteNotificationListItem & operator=(LLInviteNotificationListItem &); + void setSender(std::string sender); + void setGroupName(std::string name); + bool updateFromCache(); LLGroupIconCtrl* mGroupIcon; LLGroupIconCtrl* mGroupIconExp; - LLUUID mGroupId; - LLTextBox* mSenderBox; - LLTextBox* mSenderBoxExp; - LLTextBox* mGroupNameBoxExp; + LLUUID mGroupId; + LLTextBox* mSenderBox; + LLTextBox* mSenderBoxExp; + LLTextBox* mGroupNameBoxExp; }; class LLTransactionNotificationListItem : public LLNotificationListItem { public: static std::set getTypes(); - virtual BOOL postBuild(); + virtual BOOL postBuild(); private: friend class LLNotificationListItem; LLTransactionNotificationListItem(const Params& p); LLTransactionNotificationListItem(const LLTransactionNotificationListItem &); LLTransactionNotificationListItem & operator=(LLTransactionNotificationListItem &); - LLIconCtrl* mTransactionIcon; - LLIconCtrl* mTransactionIconExp; + LLAvatarIconCtrl* mAvatarIcon; + LLAvatarIconCtrl* mAvatarIconExp; }; class LLSystemNotificationListItem : public LLNotificationListItem { public: - static std::set getTypes(); - virtual BOOL postBuild(); + virtual BOOL postBuild(); private: friend class LLNotificationListItem; LLSystemNotificationListItem(const Params& p); LLSystemNotificationListItem(const LLSystemNotificationListItem &); LLSystemNotificationListItem & operator=(LLSystemNotificationListItem &); - LLIconCtrl* mSystemNotificationIcon; + LLIconCtrl* mSystemNotificationIcon; LLIconCtrl* mSystemNotificationIconExp; }; -- cgit v1.2.3 From 60d28437e616a6afda51a368ea40ad49a707d16c Mon Sep 17 00:00:00 2001 From: pavelk_productengine Date: Wed, 8 Apr 2015 19:51:39 +0300 Subject: MAINT-4734 (Separate transaction notices from group notice/invites) 1) added GroupNotice notification type and tab "Group" for it; 2) added Attachment field to group notice notifications which may contain inventory offers, notecards, etc; 3) added Fee field to Group Invite notifications; 4) added notification resize depending on attachment field. --- indra/newview/llnotificationlistitem.h | 82 ++++++++++++++++++++++++++-------- 1 file changed, 63 insertions(+), 19 deletions(-) (limited to 'indra/newview/llnotificationlistitem.h') diff --git a/indra/newview/llnotificationlistitem.h b/indra/newview/llnotificationlistitem.h index 22003a3a6a..bd76d17fe8 100644 --- a/indra/newview/llnotificationlistitem.h +++ b/indra/newview/llnotificationlistitem.h @@ -35,6 +35,7 @@ #include "llavatariconctrl.h" #include "llgroupmgr.h" +#include "llviewermessage.h" #include @@ -49,15 +50,21 @@ public: LLUUID paid_to_id; std::string notification_name; std::string title; + std::string subject; + std::string message; std::string sender; - LLDate time_stamp; + S32 fee; + LLDate time_stamp; + LLDate received_time; + LLSD inventory_offer; Params() {}; }; static LLNotificationListItem* create(const Params& p); - static std::set getInviteTypes(); static std::set getTransactionTypes(); + static std::set getGroupInviteTypes(); + static std::set getGroupNoticeTypes(); // title void setTitle( std::string title ); @@ -99,43 +106,80 @@ protected: LLButton* mCondenseBtn; LLButton* mCloseBtn; LLButton* mCloseBtnExp; - LLLayoutStack* mVerticalStack; LLPanel* mCondensedViewPanel; LLPanel* mExpandedViewPanel; - LLPanel* mMainPanel; std::string mTitle; std::string mNotificationName; - S32 mCondensedHeight; - S32 mExpandedHeight; + S32 mCondensedHeight; + S32 mExpandedHeight; + S32 mExpandedHeightResize; }; -class LLInviteNotificationListItem +class LLGroupNotificationListItem : public LLNotificationListItem, public LLGroupMgrObserver { public: - static std::set getTypes(); virtual BOOL postBuild(); void setGroupId(const LLUUID& value); // LLGroupMgrObserver observer trigger virtual void changed(LLGroupChange gc); -private: - friend class LLNotificationListItem; - LLInviteNotificationListItem(const Params& p); - LLInviteNotificationListItem(const LLInviteNotificationListItem &); - LLInviteNotificationListItem & operator=(LLInviteNotificationListItem &); - void setSender(std::string sender); - void setGroupName(std::string name); - - bool updateFromCache(); + friend class LLNotificationListItem; +protected: + LLGroupNotificationListItem(const Params& p); LLGroupIconCtrl* mGroupIcon; LLGroupIconCtrl* mGroupIconExp; LLUUID mGroupId; - LLTextBox* mSenderBox; - LLTextBox* mSenderBoxExp; + LLTextBox* mSenderOrFeeBox; + LLTextBox* mSenderOrFeeBoxExp; LLTextBox* mGroupNameBoxExp; + +private: + LLGroupNotificationListItem(const LLGroupNotificationListItem &); + LLGroupNotificationListItem & operator=(LLGroupNotificationListItem &); + + void setGroupName(std::string name); + bool updateFromCache(); +}; + +class LLGroupInviteNotificationListItem + : public LLGroupNotificationListItem +{ +public: + static std::set getTypes(); + virtual BOOL postBuild(); + +private: + friend class LLNotificationListItem; + LLGroupInviteNotificationListItem(const Params& p); + LLGroupInviteNotificationListItem(const LLGroupInviteNotificationListItem &); + LLGroupInviteNotificationListItem & operator=(LLGroupInviteNotificationListItem &); + + void setFee(S32 fee); +}; + +class LLGroupNoticeNotificationListItem + : public LLGroupNotificationListItem +{ +public: + static std::set getTypes(); + virtual BOOL postBuild(); + +private: + friend class LLNotificationListItem; + LLGroupNoticeNotificationListItem(const Params& p); + LLGroupNoticeNotificationListItem(const LLGroupNoticeNotificationListItem &); + LLGroupNoticeNotificationListItem & operator=(LLGroupNoticeNotificationListItem &); + + void setSender(std::string sender); + + LLPanel* mAttachmentPanel; + LLTextBox* mAttachmentTextBox; + LLIconCtrl* mAttachmentIcon; + LLIconCtrl* mAttachmentIconExp; + LLOfferInfo* mInventoryOffer; }; class LLTransactionNotificationListItem : public LLNotificationListItem -- cgit v1.2.3 From f479235aaa94555ee0ea7a663187ae9930d7d5f4 Mon Sep 17 00:00:00 2001 From: pavelkproductengine Date: Tue, 19 May 2015 13:20:46 +0300 Subject: MAINT-4734 (Separate transaction notices from group notice/invites) 1) disabled popup show (toast) when clicking on notification in expanded view; 2) made attachment in Group Notice notification clickable (copied logic from LLToastGroupNotifyPanel); 3) removed border around notification text in expanded view and made lighter background; 4) removed border around attachment field in expanded notification view. --- indra/newview/llnotificationlistitem.h | 52 +++++++++++++++++++--------------- 1 file changed, 29 insertions(+), 23 deletions(-) (limited to 'indra/newview/llnotificationlistitem.h') diff --git a/indra/newview/llnotificationlistitem.h b/indra/newview/llnotificationlistitem.h index bd76d17fe8..f8d9fc0330 100644 --- a/indra/newview/llnotificationlistitem.h +++ b/indra/newview/llnotificationlistitem.h @@ -30,6 +30,7 @@ #include "llpanel.h" #include "lllayoutstack.h" #include "lltextbox.h" +#include "llviewertexteditor.h" #include "llbutton.h" #include "llgroupiconctrl.h" #include "llavatariconctrl.h" @@ -95,24 +96,25 @@ protected: void onClickExpandBtn(); void onClickCondenseBtn(); void onClickCloseBtn(); - - Params mParams; - LLTextBox* mTitleBox; - LLTextBox* mTitleBoxExp; - LLTextBox* mNoticeTextExp; - LLTextBox* mTimeBox; - LLTextBox* mTimeBoxExp; - LLButton* mExpandBtn; - LLButton* mCondenseBtn; - LLButton* mCloseBtn; - LLButton* mCloseBtnExp; - LLPanel* mCondensedViewPanel; - LLPanel* mExpandedViewPanel; - std::string mTitle; - std::string mNotificationName; - S32 mCondensedHeight; - S32 mExpandedHeight; - S32 mExpandedHeightResize; + virtual void close() {}; + + Params mParams; + LLTextBox* mTitleBox; + LLTextBox* mTitleBoxExp; + LLViewerTextEditor* mNoticeTextExp; + LLTextBox* mTimeBox; + LLTextBox* mTimeBoxExp; + LLButton* mExpandBtn; + LLButton* mCondenseBtn; + LLButton* mCloseBtn; + LLButton* mCloseBtnExp; + LLPanel* mCondensedViewPanel; + LLPanel* mExpandedViewPanel; + std::string mTitle; + std::string mNotificationName; + S32 mCondensedHeight; + S32 mExpandedHeight; + S32 mExpandedHeightResize; }; class LLGroupNotificationListItem @@ -174,12 +176,16 @@ private: LLGroupNoticeNotificationListItem & operator=(LLGroupNoticeNotificationListItem &); void setSender(std::string sender); + void onClickAttachment(); + /*virtual*/ void close(); + + static bool isAttachmentOpenable(LLAssetType::EType); - LLPanel* mAttachmentPanel; - LLTextBox* mAttachmentTextBox; - LLIconCtrl* mAttachmentIcon; - LLIconCtrl* mAttachmentIconExp; - LLOfferInfo* mInventoryOffer; + LLPanel* mAttachmentPanel; + LLTextBox* mAttachmentTextBox; + LLIconCtrl* mAttachmentIcon; + LLIconCtrl* mAttachmentIconExp; + LLOfferInfo* mInventoryOffer; }; class LLTransactionNotificationListItem : public LLNotificationListItem -- cgit v1.2.3 From 33c5a3974c210af259d3572193bcdcd65137d888 Mon Sep 17 00:00:00 2001 From: Mnikolenko ProductEngine Date: Mon, 13 Jul 2015 17:52:42 +0300 Subject: MAINT-5369 FIXED Unable to accept group invite using Notification floater --- indra/newview/llnotificationlistitem.h | 10 ++++++++++ 1 file changed, 10 insertions(+) (limited to 'indra/newview/llnotificationlistitem.h') diff --git a/indra/newview/llnotificationlistitem.h b/indra/newview/llnotificationlistitem.h index f8d9fc0330..6801e77342 100644 --- a/indra/newview/llnotificationlistitem.h +++ b/indra/newview/llnotificationlistitem.h @@ -46,6 +46,7 @@ public: struct Params : public LLInitParam::Block { LLUUID notification_id; + LLUUID transaction_id; LLUUID group_id; LLUUID paid_from_id; LLUUID paid_to_id; @@ -160,6 +161,15 @@ private: LLGroupInviteNotificationListItem & operator=(LLGroupInviteNotificationListItem &); void setFee(S32 fee); + + void onClickJoinBtn(); + void onClickDeclineBtn(); + void onClickInfoBtn(); + + LLPanel* mInviteButtonPanel; + LLButton* mJoinBtn; + LLButton* mDeclineBtn; + LLButton* mInfoBtn; }; class LLGroupNoticeNotificationListItem -- cgit v1.2.3 From 8b498ab961f14cfb03834422c4b2b33a91f91f6e Mon Sep 17 00:00:00 2001 From: Mnikolenko ProductEngine Date: Thu, 16 Jul 2015 13:19:14 +0300 Subject: MAINT-5396 FIXED Group notice timestamps are no longer GMT --- indra/newview/llnotificationlistitem.h | 10 +++++++++- 1 file changed, 9 insertions(+), 1 deletion(-) (limited to 'indra/newview/llnotificationlistitem.h') diff --git a/indra/newview/llnotificationlistitem.h b/indra/newview/llnotificationlistitem.h index 6801e77342..d00016fc15 100644 --- a/indra/newview/llnotificationlistitem.h +++ b/indra/newview/llnotificationlistitem.h @@ -89,11 +89,19 @@ public: void setExpanded(BOOL value); virtual BOOL postBuild(); + + typedef enum e_time_type + { + SLT = 1, + Local = 2, + UTC = 3, + }ETimeType; + protected: LLNotificationListItem(const Params& p); virtual ~LLNotificationListItem(); - static std::string buildNotificationDate(const LLDate&); + static std::string buildNotificationDate(const LLDate& time_stamp, ETimeType time_type = SLT); void onClickExpandBtn(); void onClickCondenseBtn(); void onClickCloseBtn(); -- cgit v1.2.3 From da0f280ec3989789db4d502f4b34797c03dea9fa Mon Sep 17 00:00:00 2001 From: Mnikolenko ProductEngine Date: Mon, 20 Jul 2015 16:38:57 +0300 Subject: MAINT-5414 FIXED Viewer crashes after opening Group info panel --- indra/newview/llnotificationlistitem.h | 1 + 1 file changed, 1 insertion(+) (limited to 'indra/newview/llnotificationlistitem.h') diff --git a/indra/newview/llnotificationlistitem.h b/indra/newview/llnotificationlistitem.h index d00016fc15..86b1128de0 100644 --- a/indra/newview/llnotificationlistitem.h +++ b/indra/newview/llnotificationlistitem.h @@ -184,6 +184,7 @@ class LLGroupNoticeNotificationListItem : public LLGroupNotificationListItem { public: + ~LLGroupNoticeNotificationListItem(); static std::set getTypes(); virtual BOOL postBuild(); -- cgit v1.2.3 From 5665c5320c50180e69e3616613b7796da919a721 Mon Sep 17 00:00:00 2001 From: pavelkproductengine Date: Fri, 31 Jul 2015 17:49:45 +0300 Subject: MAINT-5394 [Project Notice] The PERMISSION_DEBIT notification is not distinct enough on the Project Notice viewer. --- indra/newview/llnotificationlistitem.h | 7 +++++++ 1 file changed, 7 insertions(+) (limited to 'indra/newview/llnotificationlistitem.h') diff --git a/indra/newview/llnotificationlistitem.h b/indra/newview/llnotificationlistitem.h index 86b1128de0..4df21951a1 100644 --- a/indra/newview/llnotificationlistitem.h +++ b/indra/newview/llnotificationlistitem.h @@ -59,6 +59,7 @@ public: LLDate time_stamp; LLDate received_time; LLSD inventory_offer; + e_notification_priority notification_priority; Params() {}; }; @@ -87,6 +88,7 @@ public: boost::signals2::connection setOnItemCloseCallback(item_callback_t cb) { return mOnItemClose.connect(cb); } boost::signals2::connection setOnItemClickCallback(item_callback_t cb) { return mOnItemClick.connect(cb); } + virtual bool showPopup() { return true; } void setExpanded(BOOL value); virtual BOOL postBuild(); @@ -162,6 +164,8 @@ public: static std::set getTypes(); virtual BOOL postBuild(); + /*virtual*/ bool showPopup() { return false; } + private: friend class LLNotificationListItem; LLGroupInviteNotificationListItem(const Params& p); @@ -188,6 +192,8 @@ public: static std::set getTypes(); virtual BOOL postBuild(); + /*virtual*/ bool showPopup() { return false; } + private: friend class LLNotificationListItem; LLGroupNoticeNotificationListItem(const Params& p); @@ -232,6 +238,7 @@ private: LLSystemNotificationListItem & operator=(LLSystemNotificationListItem &); LLIconCtrl* mSystemNotificationIcon; LLIconCtrl* mSystemNotificationIconExp; + bool mIsCaution; }; #endif // LL_LLNOTIFICATIONLISTITEM_H -- cgit v1.2.3 From 374a5b7dbe248eb62ab0fd919c13dd4fe41de3a2 Mon Sep 17 00:00:00 2001 From: Mnikolenko ProductEngine Date: Tue, 4 Aug 2015 16:46:50 +0300 Subject: MAINT-5427 FIXED Highlight notifications when hovering mouse. --- indra/newview/llnotificationlistitem.h | 2 ++ 1 file changed, 2 insertions(+) (limited to 'indra/newview/llnotificationlistitem.h') diff --git a/indra/newview/llnotificationlistitem.h b/indra/newview/llnotificationlistitem.h index 4df21951a1..950b75c39a 100644 --- a/indra/newview/llnotificationlistitem.h +++ b/indra/newview/llnotificationlistitem.h @@ -79,6 +79,8 @@ public: // handlers virtual BOOL handleMouseUp(S32 x, S32 y, MASK mask); + virtual void onMouseEnter(S32 x, S32 y, MASK mask); + virtual void onMouseLeave(S32 x, S32 y, MASK mask); //callbacks typedef boost::function item_callback_t; -- cgit v1.2.3 From 1dd2a17f6876fdb2f8856a2f2fb2b69d2bb4b265 Mon Sep 17 00:00:00 2001 From: Mnikolenko ProductEngine Date: Fri, 18 Sep 2015 15:59:53 +0300 Subject: MAINT-5427 Expand notifications according to message length --- indra/newview/llnotificationlistitem.h | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) (limited to 'indra/newview/llnotificationlistitem.h') diff --git a/indra/newview/llnotificationlistitem.h b/indra/newview/llnotificationlistitem.h index 950b75c39a..9a4ce2be4b 100644 --- a/indra/newview/llnotificationlistitem.h +++ b/indra/newview/llnotificationlistitem.h @@ -34,7 +34,7 @@ #include "llbutton.h" #include "llgroupiconctrl.h" #include "llavatariconctrl.h" - +#include "llchatentry.h" #include "llgroupmgr.h" #include "llviewermessage.h" @@ -93,6 +93,7 @@ public: virtual bool showPopup() { return true; } void setExpanded(BOOL value); virtual BOOL postBuild(); + void reshapeNotification(); typedef enum e_time_type { @@ -114,7 +115,7 @@ protected: Params mParams; LLTextBox* mTitleBox; LLTextBox* mTitleBoxExp; - LLViewerTextEditor* mNoticeTextExp; + LLChatEntry* mNoticeTextExp; LLTextBox* mTimeBox; LLTextBox* mTimeBoxExp; LLButton* mExpandBtn; @@ -128,6 +129,7 @@ protected: S32 mCondensedHeight; S32 mExpandedHeight; S32 mExpandedHeightResize; + bool mExpanded; }; class LLGroupNotificationListItem -- cgit v1.2.3