00001 /* 00002 Situare - A location system for Facebook 00003 Copyright (C) 2010 Ixonos Plc. Authors: 00004 00005 Kaj Wallin - kaj.wallin@ixonos.com 00006 00007 Situare is free software; you can redistribute it and/or 00008 modify it under the terms of the GNU General Public License 00009 version 2 as published by the Free Software Foundation. 00010 00011 Situare is distributed in the hope that it will be useful, 00012 but WITHOUT ANY WARRANTY; without even the implied warranty of 00013 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 00014 GNU General Public License for more details. 00015 00016 You should have received a copy of the GNU General Public License 00017 along with Situare; if not, write to the Free Software 00018 Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, 00019 USA. 00020 */ 00021 00022 00023 #ifndef USERPANEL_H 00024 #define USERPANEL_H 00025 00026 #include <QtGui> 00027 #include "../user/user.h" 00028 00029 class PanelSliderBar; 00030 class UserInfo; 00031 00038 class UserInfoPanel : public QWidget 00039 { 00040 Q_OBJECT 00041 00042 public: 00048 UserInfoPanel(QWidget *parent = 0); 00049 00050 /******************************************************************************* 00051 * MEMBER FUNCTIONS AND SLOTS 00052 ******************************************************************************/ 00053 public slots: 00054 00061 void reDrawUserPanel(int width, int height); 00062 00068 void userDataReceived(User *user); 00069 00070 signals: 00075 void refreshUserData(); 00076 00081 void requestReverseGeo(); 00082 00088 void reverseGeoReady(const QString &address); 00089 00096 void statusUpdate(const QString &status, const bool &publish); 00097 00098 00099 /******************************************************************************* 00100 * DATA MEMBERS 00101 ******************************************************************************/ 00102 private: 00103 QWidget *m_panelBase; 00104 PanelSliderBar *m_userPanelSlidingBar; 00105 QState *m_userPanelStateClosed; 00106 QStateMachine *m_userPanelStateMachine; 00107 QState *m_userPanelStateOpened; 00108 QSignalTransition *m_userPanelTransitionClose; 00109 QSignalTransition *m_userPanelTransitionOpen; 00110 UserInfo *m_userInfo; 00111 QVBoxLayout *m_userPanelVBox; 00112 }; 00113 #endif // USERPANEL_H