From 718314af75783595e227c1289813667282d08ec3 Mon Sep 17 00:00:00 2001 From: csoler Date: Sat, 23 Feb 2013 13:24:16 +0000 Subject: [PATCH] removed debug info, added missing error message git-svn-id: http://svn.code.sf.net/p/retroshare/code/trunk@6140 b45a01b8-16f6-495d-af2f-9b41ad6348cc --- retroshare-gui/src/gui/ChatLobbyWidget.cpp | 2 - retroshare-gui/src/gui/MainWindow.cpp | 49 ++++++++++++---------- retroshare-gui/src/gui/RetroShareLink.cpp | 4 +- retroshare-gui/src/gui/TransfersDialog.cpp | 6 +-- 4 files changed, 31 insertions(+), 30 deletions(-) diff --git a/retroshare-gui/src/gui/ChatLobbyWidget.cpp b/retroshare-gui/src/gui/ChatLobbyWidget.cpp index 85037a8bf..43c4b9c5f 100644 --- a/retroshare-gui/src/gui/ChatLobbyWidget.cpp +++ b/retroshare-gui/src/gui/ChatLobbyWidget.cpp @@ -365,8 +365,6 @@ ChatTabWidget *ChatLobbyWidget::getTabWidget() void ChatLobbyWidget::displayChatLobbyEvent(qulonglong lobby_id, int event_type, const QString& nickname, const QString& str) { - std::cerr << "Received displayChatLobbyEvent()!" << std::endl; - std::string vpid; if (rsMsgs->getVirtualPeerId(lobby_id, vpid)) { if (ChatLobbyDialog *cld = dynamic_cast(ChatDialog::getExistingChat(vpid))) { diff --git a/retroshare-gui/src/gui/MainWindow.cpp b/retroshare-gui/src/gui/MainWindow.cpp index 15f81ba47..84f2ea5cd 100644 --- a/retroshare-gui/src/gui/MainWindow.cpp +++ b/retroshare-gui/src/gui/MainWindow.cpp @@ -43,7 +43,7 @@ #include "SearchDialog.h" #include "TransfersDialog.h" #include "MessagesDialog.h" -//#include "SharedFilesDialog.h" +#include "SharedFilesDialog.h" #include "PluginsPage.h" #include "NewsFeed.h" #include "ShareManager.h" @@ -885,32 +885,35 @@ void SetForegroundWindowInternal(HWND hWnd) return NULL; } - switch (page) { -// case Network: -// return _instance->networkDialog; - case Friends: - return _instance->friendsDialog; - case ChatLobby: - return _instance->chatLobbyDialog; - case Transfers: - return _instance->transfersDialog; -// case SharedDirectories: -// return _instance->sharedfilesDialog; - case Messages: - return _instance->messagesDialog; + switch (page) + { + case Network: + return _instance->friendsDialog->networkDialog; + case Friends: + return _instance->friendsDialog; + case ChatLobby: + return _instance->chatLobbyDialog; + case Transfers: + return _instance->transfersDialog; + case SharedDirectories: + return _instance->transfersDialog->localSharedFiles; + case Search: + return _instance->transfersDialog->searchDialog; + case Messages: + return _instance->messagesDialog; #ifdef RS_USE_LINKS - case Links: - return _instance->linksDialog; + case Links: + return _instance->linksDialog; #endif - case Channels: - return _instance->channelFeed; - case Forums: - return _instance->forumsDialog; + case Channels: + return _instance->channelFeed; + case Forums: + return _instance->forumsDialog; #ifdef BLOGS - case Blogs: - return _instance->blogsFeed; + case Blogs: + return _instance->blogsFeed; #endif - } + } return NULL; } diff --git a/retroshare-gui/src/gui/RetroShareLink.cpp b/retroshare-gui/src/gui/RetroShareLink.cpp index 238ec48e4..89ce80325 100644 --- a/retroshare-gui/src/gui/RetroShareLink.cpp +++ b/retroshare-gui/src/gui/RetroShareLink.cpp @@ -1215,7 +1215,9 @@ static void processList(const QStringList &list, const QString &textSingular, co MainWindow::showWindow(MainWindow::Search); SearchDialog *searchDialog = dynamic_cast(MainWindow::getPage(MainWindow::Search)); - if (!searchDialog) { + if (!searchDialog) + { + std::cerr << "Retrieve of search dialog failed. Please debug!" << std::endl; break; } diff --git a/retroshare-gui/src/gui/TransfersDialog.cpp b/retroshare-gui/src/gui/TransfersDialog.cpp index e3f150c41..890536201 100644 --- a/retroshare-gui/src/gui/TransfersDialog.cpp +++ b/retroshare-gui/src/gui/TransfersDialog.cpp @@ -1490,7 +1490,7 @@ void TransfersDialog::changeSpeed(int speed) void TransfersDialog::changeQueuePosition(QueueMove mv) { - std::cerr << "In changeQueuePosition (gui)"<< std::endl ; +// std::cerr << "In changeQueuePosition (gui)"<< std::endl ; std::set items; std::set::iterator it; getSelectedItems(&items, NULL); @@ -1503,7 +1503,7 @@ void TransfersDialog::changeQueuePosition(QueueMove mv) void TransfersDialog::clearcompleted() { - std::cerr << "TransfersDialog::clearcompleted()" << std::endl; +// std::cerr << "TransfersDialog::clearcompleted()" << std::endl; rsFiles->FileClearCompleted(); } @@ -1512,8 +1512,6 @@ void TransfersDialog::showFileDetails() std::string file_hash ; int nb_select = 0 ; - std::cout << "new selection " << std::endl ; - for(int i = 0; i <= DLListModel->rowCount(); i++) if(selection->isRowSelected(i, QModelIndex())) {