/indra/newview/lltoastimpanel.h
C++ Header | 80 lines | 41 code | 14 blank | 25 comment | 0 complexity | 154edc7d653aa5e28bc3da38e089f0a4 MD5 | raw file
Possible License(s): LGPL-2.1
1/** 2 * @file lltoastimpanel.h 3 * @brief Panel for IM toasts. 4 * 5 * $LicenseInfo:firstyear=2001&license=viewerlgpl$ 6 * Second Life Viewer Source Code 7 * Copyright (C) 2010, Linden Research, Inc. 8 * 9 * This library is free software; you can redistribute it and/or 10 * modify it under the terms of the GNU Lesser General Public 11 * License as published by the Free Software Foundation; 12 * version 2.1 of the License only. 13 * 14 * This library is distributed in the hope that it will be useful, 15 * but WITHOUT ANY WARRANTY; without even the implied warranty of 16 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU 17 * Lesser General Public License for more details. 18 * 19 * You should have received a copy of the GNU Lesser General Public 20 * License along with this library; if not, write to the Free Software 21 * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA 22 * 23 * Linden Research, Inc., 945 Battery Street, San Francisco, CA 94111 USA 24 * $/LicenseInfo$ 25 */ 26 27#ifndef LLTOASTIMPANEL_H_ 28#define LLTOASTIMPANEL_H_ 29 30 31#include "lltoastpanel.h" 32#include "lltextbox.h" 33#include "llbutton.h" 34#include "llavatariconctrl.h" 35 36class LLGroupIconCtrl; 37 38class LLToastIMPanel: public LLToastPanel 39{ 40public: 41 struct Params 42 { 43 LLNotificationPtr notification; 44 LLUUID avatar_id; 45 LLUUID session_id; 46 std::string from; 47 std::string time; 48 std::string message; 49 50 Params() {} 51 }; 52 53 LLToastIMPanel(LLToastIMPanel::Params &p); 54 virtual ~LLToastIMPanel(); 55 /*virtual*/ BOOL handleMouseDown(S32 x, S32 y, MASK mask); 56 /*virtual*/ BOOL handleToolTip(S32 x, S32 y, MASK mask); 57private: 58 void showInspector(); 59 60 void spawnNameToolTip(); 61 void spawnGroupIconToolTip(); 62 63 void initIcon(); 64 65 static const S32 DEFAULT_MESSAGE_MAX_LINE_COUNT; 66 67 LLNotificationPtr mNotification; 68 LLUUID mSessionID; 69 LLUUID mAvatarID; 70 LLAvatarIconCtrl* mAvatarIcon; 71 LLGroupIconCtrl* mGroupIcon; 72 LLAvatarIconCtrl* mAdhocIcon; 73 LLTextBox* mAvatarName; 74 LLTextBox* mTime; 75 LLTextBox* mMessage; 76}; 77 78#endif // LLTOASTIMPANEL_H_ 79 80