mirror of
https://github.com/RetroShare/RetroShare.git
synced 2025-05-13 03:22:34 -04:00
redesign MessengerWindow
git-svn-id: http://svn.code.sf.net/p/retroshare/code/trunk@2175 b45a01b8-16f6-495d-af2f-9b41ad6348cc
This commit is contained in:
parent
e08d13397a
commit
8d74bb0e6b
12 changed files with 809 additions and 392 deletions
|
@ -25,13 +25,14 @@
|
|||
|
||||
#include "mainpage.h"
|
||||
#include "ui_MessengerWindow.h"
|
||||
#include "NetworkDialog.h"
|
||||
|
||||
#include <gui/settings/rsharesettings.h>
|
||||
#include <gui/common/rwindow.h>
|
||||
#include "chat/PopupChatDialog.h"
|
||||
|
||||
|
||||
class LogoBar;
|
||||
class PeersDialog;
|
||||
//class MainWindow;
|
||||
|
||||
class MessengerWindow : public RWindow
|
||||
{
|
||||
|
@ -39,21 +40,22 @@ class MessengerWindow : public RWindow
|
|||
|
||||
public:
|
||||
|
||||
void setChatDialog(PeersDialog *cd);
|
||||
|
||||
|
||||
NetworkDialog *networkDialog2;
|
||||
PopupChatDialog *getPrivateChat(std::string id, std::string name, uint chatflags);
|
||||
|
||||
QPixmap picture;
|
||||
|
||||
static MessengerWindow* getInstance();
|
||||
static void releaseInstance();
|
||||
|
||||
virtual void updateMessengerDisplay() ; // overloaded from RsAutoUpdatePage
|
||||
|
||||
public slots:
|
||||
void insertPeers();
|
||||
/** Called when this dialog is to be displayed */
|
||||
void show();
|
||||
|
||||
void updatePeersAvatar(const QString& peer_id);
|
||||
|
||||
LogoBar & getLogoBar() const;
|
||||
|
||||
protected:
|
||||
|
@ -68,37 +70,42 @@ private slots:
|
|||
/** Create the context popup menu and it's submenus */
|
||||
void messengertreeWidgetCostumPopupMenu( QPoint point );
|
||||
|
||||
/** Export friend in Friends Dialog */
|
||||
void exportfriend2();
|
||||
/** Add a new friend */
|
||||
void addFriend();
|
||||
/** Export friend */
|
||||
void exportfriend();
|
||||
/** Remove friend */
|
||||
void removefriend2();
|
||||
void removefriend();
|
||||
/** start a chat with a friend **/
|
||||
void chatfriend2();
|
||||
|
||||
void sendMessage();
|
||||
|
||||
void configurefriend2();
|
||||
|
||||
void addFriend2();
|
||||
|
||||
void getAvatar();
|
||||
void chatfriend();
|
||||
/** start Messages Composer **/
|
||||
void sendMessage();
|
||||
/** start to connect to a friend **/
|
||||
void connectfriend();
|
||||
/** show peers details for each friend **/
|
||||
void configurefriend();
|
||||
|
||||
/** Open Shared Manager **/
|
||||
void openShareManager();
|
||||
|
||||
void showMessagesPopup();
|
||||
|
||||
//void showMessages(MainWindow::Page page = MainWindow::Messages);
|
||||
|
||||
/** RsServer Friend Calls */
|
||||
void allowfriend2();
|
||||
void connectfriend2();
|
||||
void setaddressfriend2();
|
||||
void trustfriend2();
|
||||
|
||||
/** get own last stored Avatar**/
|
||||
void getAvatar();
|
||||
|
||||
void changeAvatarClicked();
|
||||
void updateAvatar();
|
||||
|
||||
void loadmystatus();
|
||||
void loadmystatus();
|
||||
void loadstatus();
|
||||
|
||||
void on_actionSort_Peers_Descending_Order_activated();
|
||||
void on_actionSort_Peers_Ascending_Order_activated();
|
||||
void on_actionRoot_is_decorated_activated();
|
||||
void on_actionRoot_isnot_decorated_activated();
|
||||
|
||||
void displayMenu();
|
||||
|
||||
signals:
|
||||
void friendsUpdated() ;
|
||||
|
||||
private:
|
||||
|
||||
|
@ -107,12 +114,14 @@ private:
|
|||
/* (1) Update Display */
|
||||
|
||||
/* (2) Utility Fns */
|
||||
QTreeWidgetItem *getCurrentPeer(bool &isOnline);
|
||||
QTreeWidgetItem *getCurrentPeer();
|
||||
|
||||
PeersDialog *chatDialog;
|
||||
|
||||
//MainWindow* mainWindow;
|
||||
std::map<std::string, PopupChatDialog *> chatDialogs;
|
||||
|
||||
class QLabel *iconLabel, *textLabel;
|
||||
class QWidget *widget;
|
||||
class QWidgetAction *widgetAction;
|
||||
class QSpacerItem *spacerItem;
|
||||
|
||||
/** Define the popup menus for the Context menu */
|
||||
QMenu* contextMnu;
|
||||
|
@ -122,7 +131,7 @@ private:
|
|||
QAction* connectfriendAct;
|
||||
QAction* configurefriendAct;
|
||||
QAction* exportfriendAct;
|
||||
QAction* removefriend2Act;
|
||||
QAction* removefriendAct;
|
||||
|
||||
QTreeView *messengertreeWidget;
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue