diff --git a/retroshare-gui/src/gui/FriendsDialog.cpp b/retroshare-gui/src/gui/FriendsDialog.cpp index 61a367782..bf6091adb 100644 --- a/retroshare-gui/src/gui/FriendsDialog.cpp +++ b/retroshare-gui/src/gui/FriendsDialog.cpp @@ -82,19 +82,6 @@ FriendsDialog::FriendsDialog(QWidget *parent) connect( ui.addfileButton, SIGNAL(clicked() ), this , SLOT(addExtraFile())); connect(ui.actionAdd_Friend, SIGNAL(triggered()), this, SLOT(addFriend())); - connect(ui.action_Hide_Offline_Friends, SIGNAL(toggled(bool)), ui.friendList, SLOT(setHideUnconnected(bool))); - connect(ui.action_Hide_Status_Column, SIGNAL(toggled(bool)), ui.friendList, SLOT(setHideStatusColumn(bool))); - connect(ui.action_Hide_Status_Column, SIGNAL(toggled(bool)), ui.friendList, SLOT(setHideHeader(bool))); - connect(ui.action_Hide_Status_Column, SIGNAL(toggled(bool)), ui.action_Hide_State, SLOT(setEnabled(bool))); - connect(ui.action_Hide_Avatar_Column, SIGNAL(toggled(bool)), ui.friendList, SLOT(setHideAvatarColumn(bool))); - connect(ui.action_Hide_State, SIGNAL(toggled(bool)), ui.friendList, SLOT(setHideState(bool))); - - connect(ui.action_Sort_by_State, SIGNAL(toggled(bool)), ui.friendList, SLOT(setSortByState(bool))); - connect(ui.actionSort_Peers_Ascending_Order, SIGNAL(triggered()), ui.friendList, SLOT(sortPeersAscendingOrder())); - connect(ui.actionSort_Peers_Descending_Order, SIGNAL(triggered()), ui.friendList, SLOT(sortPeersDescendingOrder())); - - connect(ui.friendList, SIGNAL(peerSortColumnChanged(bool)), this, SLOT(peerSortColumnChanged(bool))); - ui.avatar->setFrameType(AvatarWidget::STATUS_FRAME); ui.avatar->setOwnId(); @@ -177,10 +164,15 @@ FriendsDialog::FriendsDialog(QWidget *parent) ui.splitter_2->setSizes(sizes); loadmypersonalstatus(); - displayMenu(); + ui.displayButton->setMenu(ui.friendList->createDisplayMenu()); // load settings RsAutoUpdatePage::lockAllEvents(); + ui.friendList->setShowStatusColumn(true); + ui.friendList->setShowLastContactColumn(false); + ui.friendList->setShowAvatarColumn(false); + ui.friendList->setRootIsDecorated(true); + ui.friendList->setShowGroups(true); processSettings(true); RsAutoUpdatePage::unlockAllEvents(); @@ -213,66 +205,19 @@ void FriendsDialog::processSettings(bool bLoad) if (bLoad) { // load settings - // state of peer tree - ui.friendList->restoreHeaderState(Settings->value("PeerTree").toByteArray()); - - // state of hideUnconnected - ui.action_Hide_Offline_Friends->setChecked(Settings->value("hideUnconnected", false).toBool()); - - // state of the status - ui.action_Hide_State->setChecked(Settings->value("hideState", false).toBool()); - - // state of hideStatusColumn - ui.action_Hide_Status_Column->setChecked(Settings->value("hideStatusColumn", false).toBool()); - - // state of hideAvatar - ui.action_Hide_Avatar_Column->setChecked(Settings->value("hideAvatar", true).toBool()); - // state of splitter ui.splitter->restoreState(Settings->value("Splitter").toByteArray()); ui.splitter_2->restoreState(Settings->value("GroupChatSplitter").toByteArray()); - - // open groups - int arrayIndex = Settings->beginReadArray("Groups"); - for (int index = 0; index < arrayIndex; index++) { - Settings->setArrayIndex(index); - ui.friendList->addGroupToExpand(Settings->value("open").toString().toStdString()); - } - Settings->endArray(); } else { // save settings - // state of peer tree - Settings->setValue("PeerTree", ui.friendList->saveHeaderState()); - - // state of hideUnconnected - Settings->setValue("hideUnconnected", ui.action_Hide_Offline_Friends->isChecked()); - - // state of the status - Settings->setValue("hideState", ui.action_Hide_State->isChecked()); - - // state of hideStatusColumn - Settings->setValue("hideStatusColumn", ui.action_Hide_Status_Column->isChecked()); - - // state of hideAvatar - Settings->setValue("hideAvatar", ui.action_Hide_Avatar_Column->isChecked()); - // state of splitter Settings->setValue("Splitter", ui.splitter->saveState()); Settings->setValue("GroupChatSplitter", ui.splitter_2->saveState()); - - // open groups - Settings->beginWriteArray("Groups"); - int arrayIndex = 0; - std::set expandedPeers; - ui.friendList->getExpandedGroups(expandedPeers); - foreach (std::string groupId, expandedPeers) { - Settings->setArrayIndex(arrayIndex++); - Settings->setValue("open", QString::fromStdString(groupId)); - } - Settings->endArray(); } + ui.friendList->processSettings(bLoad); + Settings->endGroup(); } @@ -945,21 +890,6 @@ void FriendsDialog::playsound(){ QSound::play(OnlineSound); } -void FriendsDialog::displayMenu() -{ - QMenu *displaymenu = new QMenu(); - - displaymenu->addAction(ui.actionSort_Peers_Descending_Order); - displaymenu->addAction(ui.actionSort_Peers_Ascending_Order); - displaymenu->addAction(ui.action_Hide_Offline_Friends); - displaymenu->addAction(ui.action_Sort_by_State); - displaymenu->addAction(ui.action_Hide_Avatar_Column); - displaymenu->addAction(ui.action_Hide_Status_Column); - displaymenu->addAction(ui.action_Hide_State); - - ui.displayButton->setMenu(displaymenu); -} - void FriendsDialog::on_actionMessageHistory_triggered() { ImHistoryBrowser imBrowser("", ui.lineEdit, this); @@ -984,8 +914,3 @@ void FriendsDialog::newsFeedChanged(int count) ui.peertabWidget->tabBar()->setTabIcon(newsFeedTabIndex, QIcon(IMAGE_NEWSFEED)); } } - -void FriendsDialog::peerSortColumnChanged(bool sortedByState) -{ - ui.action_Sort_by_State->setChecked(sortedByState); -} diff --git a/retroshare-gui/src/gui/FriendsDialog.h b/retroshare-gui/src/gui/FriendsDialog.h index 0d1d8a03c..e63ef5db9 100644 --- a/retroshare-gui/src/gui/FriendsDialog.h +++ b/retroshare-gui/src/gui/FriendsDialog.h @@ -115,8 +115,6 @@ private slots: void newsFeedChanged(int count); - void peerSortColumnChanged(bool sortedByState); - signals: void notifyGroupChat(const QString&,const QString&) ; @@ -127,7 +125,6 @@ private: void colorChanged(const QColor &c); void fontChanged(const QFont &font); - void displayMenu(); ///play the sound when recv a message void playsound(); diff --git a/retroshare-gui/src/gui/FriendsDialog.ui b/retroshare-gui/src/gui/FriendsDialog.ui index 1024325f6..39cf5b972 100644 --- a/retroshare-gui/src/gui/FriendsDialog.ui +++ b/retroshare-gui/src/gui/FriendsDialog.ui @@ -653,10 +653,7 @@ p, li { white-space: pre-wrap; } - - - b{} - + 0 @@ -669,6 +666,9 @@ p, li { white-space: pre-wrap; } 0 + + b{} + @@ -1423,79 +1423,6 @@ background: white;} Deletes all stored and displayed chat history - - - true - - - Hide Offline Friends - - - - - true - - - Hide Status Column - - - - - true - - - Sort by State - - - Sort by State - - - - - true - - - false - - - Hide State - - - - - - :/images/sort_decrease.png:/images/sort_decrease.png - - - Sort Descending Order - - - Sort Descending Order - - - - - - :/images/sort_incr.png:/images/sort_incr.png - - - Sort Ascending Order - - - Sort Ascending Order - - - - - true - - - Hide Avatar Column - - - Hide Avatar Column - - @@ -1516,7 +1443,6 @@ background: white;}
gui/common/FriendList.h
1
-
diff --git a/retroshare-gui/src/gui/MessengerWindow.cpp b/retroshare-gui/src/gui/MessengerWindow.cpp index 0c8761d66..918e30b05 100644 --- a/retroshare-gui/src/gui/MessengerWindow.cpp +++ b/retroshare-gui/src/gui/MessengerWindow.cpp @@ -60,6 +60,7 @@ MessengerWindow* MessengerWindow::_instance = NULL; static std::set *expandedPeers = NULL; +static std::set *expandedGroups = NULL; /*static*/ void MessengerWindow::showYourself () { @@ -86,6 +87,11 @@ void MessengerWindow::releaseInstance() delete(expandedPeers); expandedPeers = NULL; } + if (expandedGroups) { + /* delete saved expanded groups */ + delete(expandedGroups); + expandedGroups = NULL; + } } /** Constructor */ @@ -107,9 +113,6 @@ MessengerWindow::MessengerWindow(QWidget* parent, Qt::WFlags flags) connect( ui.shareButton, SIGNAL(clicked()), SLOT(openShareManager())); connect( ui.addIMAccountButton, SIGNAL(clicked( bool ) ), this , SLOT( addFriend() ) ); #endif // MINIMAL_RSGUI - connect(ui.actionHide_Offline_Friends, SIGNAL(toggled(bool)), ui.friendList, SLOT(setHideUnconnected(bool))); - connect(ui.actionSort_by_State, SIGNAL(toggled(bool)), ui.friendList, SLOT(setSortByState(bool))); - connect(ui.actionRoot_is_decorated, SIGNAL(toggled(bool)), ui.friendList, SLOT(setRootIsDecorated(bool))); connect(ui.clearButton, SIGNAL(clicked()), this, SLOT(clearFilter())); connect(ui.messagelineEdit, SIGNAL(textChanged(const QString &)), this, SLOT(savestatusmessage())); @@ -129,20 +132,30 @@ MessengerWindow::MessengerWindow(QWidget* parent, Qt::WFlags flags) expandedPeers = NULL; } + if (expandedGroups != NULL) { + for (std::set::iterator groupIt = expandedGroups->begin(); groupIt != expandedGroups->end(); groupIt++) { + ui.friendList->addGroupToExpand(*groupIt); + } + delete expandedGroups; + expandedGroups = NULL; + } + //LogoBar _rsLogoBarmessenger = new LogoBar(ui.logoframe); Widget::createLayout(ui.logoframe)->addWidget(_rsLogoBarmessenger); ui.messagelineEdit->setMinimumWidth(20); - displayMenu(); + ui.displaypushButton->setMenu(ui.friendList->createDisplayMenu()); // load settings RsAutoUpdatePage::lockAllEvents(); + ui.friendList->setShowStatusColumn(false); + ui.friendList->setShowLastContactColumn(false); + ui.friendList->setShowAvatarColumn(true); + ui.friendList->setRootIsDecorated(true); + ui.friendList->setShowGroups(false); processSettings(true); - ui.friendList->setHideHeader(true); - ui.friendList->setHideStatusColumn(true); - ui.friendList->setHideGroups(true); ui.friendList->setBigName(true); RsAutoUpdatePage::unlockAllEvents(); @@ -198,39 +211,7 @@ MessengerWindow::~MessengerWindow () void MessengerWindow::processSettings(bool bLoad) { Settings->beginGroup(_name); - - if (bLoad) { - // load settings - - // state of messenger tree - ui.friendList->restoreHeaderState(Settings->value("MessengerTree").toByteArray()); - - // state of actionHide_Offline_Friends - ui.actionHide_Offline_Friends->setChecked(Settings->value("hideOfflineFriends", false).toBool()); - - // state of actionSort_by_State - ui.actionSort_by_State->setChecked(Settings->value("sortByState", false).toBool()); - - // state of actionRoot_is_decorated - bool decorated = Settings->value("rootIsDecorated", true).toBool(); - ui.actionRoot_is_decorated->setChecked(decorated); - ui.friendList->setRootIsDecorated(decorated); - } else { - // save settings - - // state of messenger tree - Settings->setValue("MessengerTree", ui.friendList->saveHeaderState()); - - // state of actionSort_by_State - Settings->setValue("sortByState", ui.actionSort_by_State->isChecked()); - - // state of actionHide_Offline_Friends - Settings->setValue("hideOfflineFriends", ui.actionHide_Offline_Friends->isChecked()); - - // state of actionRoot_is_decorated - Settings->setValue("rootIsDecorated", ui.actionRoot_is_decorated->isChecked()); - } - + ui.friendList->processSettings(bLoad); Settings->endGroup(); } @@ -256,6 +237,15 @@ void MessengerWindow::closeEvent (QCloseEvent * /*event*/) } ui.friendList->getExpandedPeers(*expandedPeers); + + /* save the expanded groups */ + if (expandedGroups == NULL) { + expandedGroups = new std::set; + } else { + expandedGroups->clear(); + } + + ui.friendList->getExpandedGroups(*expandedGroups); } LogoBar & MessengerWindow::getLogoBar() const { @@ -296,18 +286,6 @@ void MessengerWindow::updateOwnStatus(const QString &peer_id, int status) #endif // MINIMAL_RSGUI -void MessengerWindow::displayMenu() -{ - QMenu *lookmenu = new QMenu(); - lookmenu->addAction(ui.actionSort_Peers_Descending_Order); - lookmenu->addAction(ui.actionSort_Peers_Ascending_Order); - lookmenu->addAction(ui.actionSort_by_State); - lookmenu->addAction(ui.actionHide_Offline_Friends); - lookmenu->addAction(ui.actionRoot_is_decorated); - - ui.displaypushButton->setMenu(lookmenu); -} - /* clear Filter */ void MessengerWindow::clearFilter() { diff --git a/retroshare-gui/src/gui/MessengerWindow.h b/retroshare-gui/src/gui/MessengerWindow.h index 3823d7b32..34916bc40 100644 --- a/retroshare-gui/src/gui/MessengerWindow.h +++ b/retroshare-gui/src/gui/MessengerWindow.h @@ -75,9 +75,6 @@ private: void processSettings(bool bLoad); - void displayMenu(); - - LogoBar * _rsLogoBarmessenger; QString m_nickName; diff --git a/retroshare-gui/src/gui/MessengerWindow.ui b/retroshare-gui/src/gui/MessengerWindow.ui index 196d65f02..343bd915d 100644 --- a/retroshare-gui/src/gui/MessengerWindow.ui +++ b/retroshare-gui/src/gui/MessengerWindow.ui @@ -379,57 +379,6 @@ stop:0 #FEFEFE, stop:1 #E8E8E8); - - - - :/images/sort_decrease.png:/images/sort_decrease.png - - - Sort Descending Order - - - Sort Descending Order - - - - - - :/images/sort_incr.png:/images/sort_incr.png - - - Sort Ascending Order - - - Sort Ascending Order - - - - - true - - - Set root is Decorated - - - Set Root Decorated - - - - - true - - - Hide Offline Friends - - - - - true - - - Sort by State - - diff --git a/retroshare-gui/src/gui/common/FriendList.cpp b/retroshare-gui/src/gui/common/FriendList.cpp index fe4840dd0..81c0b380d 100644 --- a/retroshare-gui/src/gui/common/FriendList.cpp +++ b/retroshare-gui/src/gui/common/FriendList.cpp @@ -71,10 +71,11 @@ #define IMAGE_PASTELINK ":/images/pasterslink.png" #define IMAGE_GROUP24 ":/images/user/group24.png" -#define COLUMN_COUNT 3 -#define COLUMN_NAME 0 -#define COLUMN_STATE 1 -#define COLUMN_AVATAR 2 +#define COLUMN_COUNT 4 +#define COLUMN_NAME 0 +#define COLUMN_STATE 1 +#define COLUMN_LAST_CONTACT 2 +#define COLUMN_AVATAR 3 #define COLUMN_DATA 0 // column for storing the userdata id @@ -109,36 +110,47 @@ FriendList::FriendList(QWidget *parent) : ui(new Ui::FriendList), m_compareRole(new RSTreeWidgetItemCompareRole), mBigName(false), - mHideAvatarColumn(false), - mHideGroups(false), + mShowGroups(true), mHideState(false), - mHideStatusColumn(false), mHideUnconnected(false), groupsHasChanged(false), openGroups(NULL), - openPeers(NULL), - correctColumnStatusSize(false), - firstTimeShown(true) + openPeers(NULL) { ui->setupUi(this); m_compareRole->setRole(COLUMN_NAME, ROLE_SORT); m_compareRole->setRole(COLUMN_STATE, ROLE_SORT); + m_compareRole->setRole(COLUMN_LAST_CONTACT, ROLE_SORT); m_compareRole->setRole(COLUMN_AVATAR, ROLE_STANDARD); connect(ui->peerTreeWidget, SIGNAL(customContextMenuRequested(QPoint)), this, SLOT(peerTreeWidgetCostumPopupMenu())); connect(ui->peerTreeWidget, SIGNAL(itemDoubleClicked(QTreeWidgetItem *, int)), this, SLOT(chatfriend(QTreeWidgetItem *))); - connect(ui->peerTreeWidget->header(), SIGNAL(sortIndicatorChanged(int, Qt::SortOrder)), this, SLOT(peerSortIndicatorChanged(int, Qt::SortOrder))); connect(NotifyQt::getInstance(), SIGNAL(groupsChanged(int)), this, SLOT(groupsChanged())); connect(NotifyQt::getInstance(), SIGNAL(friendsChanged()), this, SLOT(insertPeers())); connect(NotifyQt::getInstance(), SIGNAL(peerHasNewAvatar(const QString&)), this, SLOT(updateAvatar(const QString&))); - ui->peerTreeWidget->setColumnWidth(COLUMN_NAME, 150); + connect(ui->actionHideOfflineFriends, SIGNAL(triggered(bool)), this, SLOT(setHideUnconnected(bool))); + connect(ui->actionShowStatusColumn, SIGNAL(triggered(bool)), this, SLOT(setShowStatusColumn(bool))); + connect(ui->actionShowAvatarColumn, SIGNAL(triggered(bool)), this, SLOT(setShowAvatarColumn(bool))); + connect(ui->actionShowLastContactColumn, SIGNAL(triggered(bool)), this, SLOT(setShowLastContactColumn(bool))); + connect(ui->actionHideState, SIGNAL(triggered(bool)), this, SLOT(setHideState(bool))); + connect(ui->actionRootIsDecorated, SIGNAL(triggered(bool)), this, SLOT(setRootIsDecorated(bool))); + connect(ui->actionShowGroups, SIGNAL(triggered(bool)), this, SLOT(setShowGroups(bool))); + + connect(ui->actionSortByName, SIGNAL(triggered()), this, SLOT(setSortByName())); + connect(ui->actionSortByState, SIGNAL(triggered()), this, SLOT(setSortByState())); + connect(ui->actionSortByLastContact, SIGNAL(triggered()), this, SLOT(setSortByLastContact())); + connect(ui->actionSortPeersAscendingOrder, SIGNAL(triggered()), this, SLOT(sortPeersAscendingOrder())); + connect(ui->actionSortPeersDescendingOrder, SIGNAL(triggered()), this, SLOT(sortPeersDescendingOrder())); + + initializeHeader(false); + ui->peerTreeWidget->sortItems(COLUMN_NAME, Qt::AscendingOrder); // set header text aligment - QTreeWidgetItem * headerItem = ui->peerTreeWidget->headerItem(); + QTreeWidgetItem *headerItem = ui->peerTreeWidget->headerItem(); headerItem->setTextAlignment(COLUMN_NAME, Qt::AlignHCenter | Qt::AlignVCenter); headerItem->setTextAlignment(COLUMN_STATE, Qt::AlignLeft | Qt::AlignVCenter); headerItem->setTextAlignment(COLUMN_AVATAR, Qt::AlignLeft | Qt::AlignVCenter); @@ -155,6 +167,89 @@ FriendList::~FriendList() delete(m_compareRole); } +void FriendList::processSettings(bool bLoad) +{ + int peerTreeVersion = 2; // version number for the settings to solve problems when modifying the column count + + if (bLoad) { + // load settings + + // state of peer tree + if (Settings->value("peerTreeVersion").toInt() == peerTreeVersion) { + ui->peerTreeWidget->header()->restoreState(Settings->value("peerTree").toByteArray()); + } +// ui->peerTreeWidget->header()->doItemsLayout(); // is needed because I added a third column + // restoreState would corrupt the internal sectionCount + + // state of the columns + setShowStatusColumn(Settings->value("showStatusColumn", !ui->peerTreeWidget->isColumnHidden(COLUMN_STATE)).toBool()); + setShowLastContactColumn(Settings->value("showLastContactColumn", !ui->peerTreeWidget->isColumnHidden(COLUMN_LAST_CONTACT)).toBool()); + setShowAvatarColumn(Settings->value("showAvatarColumn", !ui->peerTreeWidget->isColumnHidden(COLUMN_AVATAR)).toBool()); + + // states + setHideUnconnected(Settings->value("hideUnconnected", mHideUnconnected).toBool()); + setHideState(Settings->value("hideState", mHideState).toBool()); + setRootIsDecorated(Settings->value("rootIsDecorated", ui->peerTreeWidget->rootIsDecorated()).toBool()); + setShowGroups(Settings->value("showGroups", mShowGroups).toBool()); + + // open groups + int arrayIndex = Settings->beginReadArray("Groups"); + for (int index = 0; index < arrayIndex; index++) { + Settings->setArrayIndex(index); + addGroupToExpand(Settings->value("open").toString().toStdString()); + } + Settings->endArray(); + + initializeHeader(true); + updateHeader(); + } else { + // save settings + + // state of peer tree + Settings->setValue("peerTree", ui->peerTreeWidget->header()->saveState()); + Settings->setValue("peerTreeVersion", peerTreeVersion); + + // state of the columns + Settings->setValue("showStatusColumn", !ui->peerTreeWidget->isColumnHidden(COLUMN_STATE)); + Settings->setValue("showLastContactColumn", !ui->peerTreeWidget->isColumnHidden(COLUMN_LAST_CONTACT)); + Settings->setValue("showAvatarColumn", !ui->peerTreeWidget->isColumnHidden(COLUMN_AVATAR)); + + // states + Settings->setValue("hideUnconnected", mHideUnconnected); + Settings->setValue("hideState", mHideState); + Settings->setValue("rootIsDecorated", ui->peerTreeWidget->rootIsDecorated()); + Settings->setValue("showGroups", mShowGroups); + + // open groups + Settings->beginWriteArray("Groups"); + int arrayIndex = 0; + std::set expandedPeers; + getExpandedGroups(expandedPeers); + foreach (std::string groupId, expandedPeers) { + Settings->setArrayIndex(arrayIndex++); + Settings->setValue("open", QString::fromStdString(groupId)); + } + Settings->endArray(); + } +} + +void FriendList::initializeHeader(bool afterLoadSettings) +{ + // set column size + QHeaderView *header = ui->peerTreeWidget->header(); + header->setMovable(false); + header->setResizeMode(COLUMN_NAME, QHeaderView::Stretch); + header->setResizeMode(COLUMN_STATE, QHeaderView::Interactive); + header->setResizeMode(COLUMN_LAST_CONTACT, QHeaderView::Interactive); + header->setResizeMode(COLUMN_AVATAR, QHeaderView::Fixed); + + if (!afterLoadSettings) { + header->resizeSection(COLUMN_NAME, 150); + header->resizeSection(COLUMN_LAST_CONTACT, 120); + } + header->resizeSection(COLUMN_AVATAR, COLUMN_AVATAR_WIDTH); +} + /* Utility Fns */ inline std::string getRsId(QTreeWidgetItem *item) { @@ -267,7 +362,7 @@ void FriendList::peerTreeWidgetCostumPopupMenu() contextMnu.addAction(QIcon(IMAGE_REMOVEFRIEND), tr("Remove Friend Location"), this, SLOT(removefriend())); } - if (mHideGroups == false && type == TYPE_GPG) { + if (mShowGroups && type == TYPE_GPG) { QMenu* addToGroupMenu = NULL; QMenu* moveToGroupMenu = NULL; @@ -361,7 +456,7 @@ void FriendList::groupsChanged() void FriendList::updateAvatar(const QString& id) { - if (mHideAvatarColumn) + if (ui->peerTreeWidget->isColumnHidden(COLUMN_AVATAR)) return; QTreeWidgetItemIterator it(ui->peerTreeWidget); @@ -378,16 +473,6 @@ void FriendList::updateAvatar(const QString& id) } } -void FriendList::showEvent(QShowEvent *event) -{ - if (firstTimeShown) { - firstTimeShown = false; - updateHeaderSizes(); - } - - RsAutoUpdatePage::showEvent(event); -} - /** * Get the list of peers from the RsIface. * Adds all friend gpg ids, with their locations as children to the peerTreeWidget. @@ -403,6 +488,9 @@ void FriendList::insertPeers() std::cerr << "FriendList::insertPeers() called." << std::endl; #endif + bool isStatusColumnHidden = ui->peerTreeWidget->isColumnHidden(COLUMN_STATE); + bool isAvatarColumnHidden = ui->peerTreeWidget->isColumnHidden(COLUMN_AVATAR); + std::list statusInfo; rsStatus->getStatusList(statusInfo); @@ -457,7 +545,7 @@ void FriendList::insertPeers() break; } - if (mHideGroups == false && groupsHasChanged) { + if (mShowGroups && groupsHasChanged) { if (parent) { if (parent->type() == TYPE_GROUP) { std::string groupId = getRsId(parent); @@ -486,7 +574,7 @@ void FriendList::insertPeers() break; case TYPE_GROUP: { - if (mHideGroups) { + if (!mShowGroups) { if (item->parent()) { delete(item->parent()->takeChild(item->parent()->indexOfChild(item))); } else { @@ -522,7 +610,7 @@ void FriendList::insertPeers() RsGroupInfo *groupInfo = NULL; int onlineCount = 0; int availableCount = 0; - if (!mHideGroups && groupIt != groupInfoList.end()) { + if (mShowGroups && groupIt != groupInfoList.end()) { groupInfo = &(*groupIt); if ((groupInfo->flag & RS_GROUP_FLAG_STANDARD) && groupInfo->peerIds.size() == 0) { @@ -586,7 +674,7 @@ void FriendList::insertPeers() for (gpgIt = gpgFriends.begin(); gpgIt != gpgFriends.end(); gpgIt++) { std::string gpgId = *gpgIt; - if (!mHideGroups) { + if (mShowGroups) { if (groupInfo) { // we fill a group, check if gpg id is assigned if (std::find(groupInfo->peerIds.begin(), groupInfo->peerIds.end(), gpgId) == groupInfo->peerIds.end()) { @@ -647,17 +735,18 @@ void FriendList::insertPeers() } gpgItem->setChildIndicatorPolicy(QTreeWidgetItem::DontShowIndicatorWhenChildless); - if (!mBigName) { - gpgItem->setSizeHint(COLUMN_NAME, QSize(26, 26)); - } else { - gpgItem->setSizeHint(COLUMN_NAME, QSize(40, 40)); - } gpgItem->setTextAlignment(COLUMN_NAME, Qt::AlignLeft | Qt::AlignVCenter); /* not displayed, used to find back the item */ gpgItem->setData(COLUMN_DATA, ROLE_ID, QString::fromStdString(detail.id)); } + if (mBigName && !mHideState && isStatusColumnHidden) { + gpgItem->setSizeHint(COLUMN_NAME, QSize(40, 40)); + } else { + gpgItem->setSizeHint(COLUMN_NAME, QSize(26, 26)); + } + availableCount++; QString gpgItemText = QString::fromUtf8(detail.name.c_str()); @@ -685,6 +774,7 @@ void FriendList::insertPeers() std::string bestSslId; // for gpg item QString bestCustomStateString;// for gpg item std::list sslContacts; + QDateTime lastContact; rsPeers->getAssociatedSSLIds(detail.gpg_id, sslContacts); for (std::list::iterator sslIt = sslContacts.begin(); sslIt != sslContacts.end(); sslIt++) { @@ -740,14 +830,14 @@ void FriendList::insertPeers() } QString connectStateString = StatusDefs::connectStateString(sslDetail); - if (!mHideStatusColumn) { + if (!isStatusColumnHidden) { sslItem->setText(COLUMN_STATE, connectStateString); } else if (!mHideState && connectStateString.isEmpty() == false) { sText += " [" + StatusDefs::connectStateString(sslDetail) + "]"; } sslItem->setText( COLUMN_NAME, sText); - if (mHideStatusColumn == true && mHideState == true) { + if (isStatusColumnHidden == true && mHideState == true) { /* Show the state as tooltip */ sslItem->setToolTip(COLUMN_NAME, connectStateString); } else { @@ -757,6 +847,14 @@ void FriendList::insertPeers() // sort location sslItem->setData(COLUMN_STATE, ROLE_SORT, sText); + /* last contact */ + QDateTime sslLastContact = QDateTime::fromTime_t(sslDetail.lastConnect); + sslItem->setData(COLUMN_LAST_CONTACT, Qt::DisplayRole, QVariant(sslLastContact)); + sslItem->setData(COLUMN_LAST_CONTACT, ROLE_SORT, sslLastContact); + if (sslLastContact > lastContact) { + lastContact = sslLastContact; + } + /* change color and icon */ QIcon sslIcon; QFont sslFont; @@ -879,21 +977,21 @@ void FriendList::insertPeers() gpgIcon = QIcon(StatusDefs::imageUser(bestRSState)); - if (!mHideStatusColumn) { + if (!isStatusColumnHidden) { gpgItem->setText(COLUMN_STATE, StatusDefs::name(bestRSState)); } - if (mBigName) { + if (isStatusColumnHidden && mBigName && !mHideState) { if (bestCustomStateString.isEmpty()) { gpgItemText += "\n" + StatusDefs::name(bestRSState); } else { gpgItemText += "\n" + bestCustomStateString; } - } else if (mHideStatusColumn && !mHideState){ + } else if (isStatusColumnHidden && !mHideState){ gpgItemText += " [" + StatusDefs::name(bestRSState) + "]"; } } else if (gpg_online) { - if (!mHideStatusColumn) { + if (!isStatusColumnHidden) { gpgItem->setText(COLUMN_STATE, tr("Available")); } else if (!mHideState && !mBigName) { gpgItemText += " [" + tr("Available") + "]"; @@ -911,7 +1009,7 @@ void FriendList::insertPeers() gpgItem->setFont(i,font); } } else { - if (!mHideStatusColumn) { + if (!isStatusColumnHidden) { gpgItem->setText(COLUMN_STATE, StatusDefs::name(RS_STATUS_OFFLINE)); } else if (!mHideState && !mBigName) { gpgItemText += " [" + StatusDefs::name(RS_STATUS_OFFLINE) + "]"; @@ -933,7 +1031,7 @@ void FriendList::insertPeers() gpgIcon = QIcon(":/images/chat.png"); } - if (!mHideAvatarColumn && gpgItem->icon(COLUMN_AVATAR).isNull()) { + if (!isAvatarColumnHidden && gpgItem->icon(COLUMN_AVATAR).isNull()) { // only set the avatar image the first time, or when it changed // otherwise getAvatarFromSslId sends request packages to peers. QPixmap avatar; @@ -946,6 +1044,8 @@ void FriendList::insertPeers() gpgItem->setData(COLUMN_NAME, ROLE_SORT, "2 " + gpgItemText); gpgItem->setData(COLUMN_STATE, ROLE_SORT, "2 " + BuildStateSortString(true, gpgItemText, bestPeerState)); gpgItem->setIcon(COLUMN_NAME, gpgIcon); + gpgItem->setData(COLUMN_LAST_CONTACT, Qt::DisplayRole, QVariant(lastContact)); + gpgItem->setData(COLUMN_LAST_CONTACT, ROLE_SORT, "2 " + lastContact.toString("yyyyMMdd_hhmmss")); if (openPeers != NULL && openPeers->find(gpgId) != openPeers->end()) { gpgItem->setExpanded(true); @@ -965,7 +1065,7 @@ void FriendList::insertPeers() } } - if (!mHideGroups && groupIt != groupInfoList.end()) { + if (mShowGroups && groupIt != groupInfoList.end()) { groupIt++; } else { // all done @@ -1392,60 +1492,48 @@ void FriendList::removeGroup() rsPeers->removeGroup(groupId); } -void FriendList::setHideUnconnected(bool hidden) { +void FriendList::setHideUnconnected(bool hidden) +{ if (mHideUnconnected != hidden) { mHideUnconnected = hidden; insertPeers(); } } -void FriendList::setHideStatusColumn(bool hidden) +void FriendList::setShowStatusColumn(bool show) { - if (mHideStatusColumn != hidden) { - ui->peerTreeWidget->setColumnHidden(COLUMN_STATE, hidden); + ui->actionHideState->setEnabled(!show); + bool isColumnVisible = !ui->peerTreeWidget->isColumnHidden(COLUMN_STATE); - QHeaderView *header = ui->peerTreeWidget->header(); - if (mHideStatusColumn) { // if column was hidden - if (correctColumnStatusSize) { - correctColumnStatusSize = false; - header->resizeSection(COLUMN_STATE, 100); - } + if (isColumnVisible != show) { + ui->peerTreeWidget->setColumnHidden(COLUMN_STATE, !show); - if (header->sectionSize(COLUMN_STATE) < header->sectionSize(COLUMN_NAME)) { - // resize name column to make room for status column, but only if it doesn't result in negative width - header->resizeSection(COLUMN_NAME, header->sectionSize(COLUMN_NAME) - header->sectionSize(COLUMN_STATE)); - } - } - - mHideStatusColumn = hidden; - updateHeaderSizes(); + updateHeader(); insertPeers(); } } -void FriendList::setHideAvatarColumn(bool hidden) +void FriendList::setShowLastContactColumn(bool show) { - if (mHideAvatarColumn == hidden) - return; + bool isColumnVisible = !ui->peerTreeWidget->isColumnHidden(COLUMN_LAST_CONTACT); - bool columnWasHidden = mHideAvatarColumn; - mHideAvatarColumn = hidden; - ui->peerTreeWidget->setColumnHidden(COLUMN_AVATAR, hidden); + if (isColumnVisible != show) { + ui->peerTreeWidget->setColumnHidden(COLUMN_LAST_CONTACT, !show); - if (RsAutoUpdatePage::eventsLocked()) // don't change header sizes - return; - - QHeaderView *header = ui->peerTreeWidget->header(); - if (columnWasHidden) { - if (header->sectionSize(COLUMN_NAME) > COLUMN_AVATAR_WIDTH) { - // resize name column to make room for avatar column, but only if it doesn't result in negative width - header->resizeSection(COLUMN_NAME, header->sectionSize(COLUMN_NAME) - COLUMN_AVATAR_WIDTH); - } - } else { - header->resizeSection(COLUMN_NAME, header->sectionSize(COLUMN_NAME) + COLUMN_AVATAR_WIDTH); + updateHeader(); + insertPeers(); } +} - updateHeaderSizes(); +void FriendList::setShowAvatarColumn(bool show) +{ + bool isColumnVisible = !ui->peerTreeWidget->isColumnHidden(COLUMN_AVATAR); + if (isColumnVisible == show) + return; + + ui->peerTreeWidget->setColumnHidden(COLUMN_AVATAR, !show); + + updateHeader(); insertPeers(); } @@ -1458,43 +1546,33 @@ void FriendList::setHideState(bool hidden) } /** - * Set the correct header resize modes. + * Set the header visible. */ -void FriendList::updateHeaderSizes() +void FriendList::updateHeader() { - if (RsAutoUpdatePage::eventsLocked()) - return; - - QHeaderView *header = ui->peerTreeWidget->header(); - if (mHideAvatarColumn) { - /* Set header sizes for the fixed columns and resize modes, must be set after processSettings */ - if (!this->isVisible() && ui->peerTreeWidget->isColumnHidden(COLUMN_STATE)) { - // Workaround - correctColumnStatusSize = true; - } - header->setStretchLastSection(true); - header->setResizeMode(COLUMN_NAME, QHeaderView::Interactive); - header->setResizeMode(COLUMN_STATE, QHeaderView::Interactive); + if (ui->peerTreeWidget->isColumnHidden(COLUMN_STATE) && ui->peerTreeWidget->isColumnHidden(COLUMN_LAST_CONTACT)) { + ui->peerTreeWidget->setHeaderHidden(true); } else { - header->setStretchLastSection(false); - if (mHideStatusColumn) { - header->setResizeMode(COLUMN_NAME, QHeaderView::Stretch); - } else { - header->setResizeMode(COLUMN_NAME, QHeaderView::Interactive); - } - header->setResizeMode(COLUMN_AVATAR, QHeaderView::Fixed); - - header->resizeSection(COLUMN_AVATAR, COLUMN_AVATAR_WIDTH); + ui->peerTreeWidget->setHeaderHidden(false); } } -void FriendList::setSortByState(bool sortByState) +void FriendList::setSortByName() { - if (sortByState) { - ui->peerTreeWidget->sortByColumn(COLUMN_STATE); - } else { - ui->peerTreeWidget->sortByColumn(COLUMN_NAME); - } + ui->peerTreeWidget->sortByColumn(COLUMN_NAME); + sortPeersAscendingOrder(); +} + +void FriendList::setSortByState() +{ + ui->peerTreeWidget->sortByColumn(COLUMN_STATE); + sortPeersAscendingOrder(); +} + +void FriendList::setSortByLastContact() +{ + ui->peerTreeWidget->sortByColumn(COLUMN_LAST_CONTACT); + sortPeersDescendingOrder(); } void FriendList::sortPeersAscendingOrder() @@ -1507,25 +1585,29 @@ void FriendList::sortPeersDescendingOrder() ui->peerTreeWidget->sortByColumn(ui->peerTreeWidget->sortColumn(), Qt::DescendingOrder); } -void FriendList::peerSortIndicatorChanged(int column, Qt::SortOrder) -{ - emit peerSortColumnChanged(column == COLUMN_STATE); -} - void FriendList::setRootIsDecorated(bool show) { ui->peerTreeWidget->setRootIsDecorated(show); } -void FriendList::setHideHeader(bool hidden) +void FriendList::setShowGroups(bool show) { - ui->peerTreeWidget->setHeaderHidden(hidden); -} - -void FriendList::setHideGroups(bool hidden) -{ - if (mHideGroups != hidden) { - mHideGroups = hidden; + if (mShowGroups != show) { + mShowGroups = show; + if (mShowGroups) { + // remove all not assigned gpg ids + int childCount = ui->peerTreeWidget->topLevelItemCount(); + int childIndex = 0; + while (childIndex < childCount) { + QTreeWidgetItem *item = ui->peerTreeWidget->topLevelItem(childIndex); + if (item->type() == TYPE_GPG) { + delete(ui->peerTreeWidget->takeTopLevelItem(childIndex)); + childCount = ui->peerTreeWidget->topLevelItemCount(); + continue; + } + childIndex++; + } + } insertPeers(); } } @@ -1559,20 +1641,6 @@ void FriendList::setBigName(bool bigName) } } -void FriendList::restoreHeaderState(const QByteArray &state) -{ - ui->peerTreeWidget->header()->restoreState(state); - ui->peerTreeWidget->header()->doItemsLayout(); // is needed because I added a third column - // restoreState would corrupt the internal sectionCount - ui->peerTreeWidget->setColumnHidden(COLUMN_STATE, mHideStatusColumn); - ui->peerTreeWidget->setColumnHidden(COLUMN_AVATAR, mHideAvatarColumn); -} - -QByteArray FriendList::saveHeaderState() const -{ - return ui->peerTreeWidget->header()->saveState(); -} - /** * Hides all items that don't contain sPattern in the name column. */ @@ -1641,3 +1709,55 @@ void FriendList::addPeerToExpand(const std::string &gpgId) } openPeers->insert(gpgId); } + +QMenu *FriendList::createDisplayMenu() +{ + QMenu *displayMenu = new QMenu(this); + connect(displayMenu, SIGNAL(aboutToShow()), this, SLOT(updateMenu())); + + displayMenu->addAction(ui->actionSortPeersDescendingOrder); + displayMenu->addAction(ui->actionSortPeersAscendingOrder); + QMenu *menu = displayMenu->addMenu(tr("Columns")); + menu->addAction(ui->actionShowAvatarColumn); + menu->addAction(ui->actionShowLastContactColumn); + menu->addAction(ui->actionShowStatusColumn); + menu = displayMenu->addMenu(tr("Sort by")); + menu->addAction(ui->actionSortByName); + menu->addAction(ui->actionSortByState); + menu->addAction(ui->actionSortByLastContact); + displayMenu->addAction(ui->actionHideOfflineFriends); + displayMenu->addAction(ui->actionHideState); + displayMenu->addAction(ui->actionRootIsDecorated); + displayMenu->addAction(ui->actionShowGroups); + + QActionGroup *group = new QActionGroup(this); + group->addAction(ui->actionSortByName); + group->addAction(ui->actionSortByState); + group->addAction(ui->actionSortByLastContact); + + return displayMenu; +} + +void FriendList::updateMenu() +{ + switch (ui->peerTreeWidget->sortColumn()) { + case COLUMN_NAME: + ui->actionSortByName->setChecked(true); + break; + case COLUMN_STATE: + ui->actionSortByState->setChecked(true); + break; + case COLUMN_LAST_CONTACT: + ui->actionSortByLastContact->setChecked(true); + break; + case COLUMN_AVATAR: + break; + } + ui->actionShowStatusColumn->setChecked(!ui->peerTreeWidget->isColumnHidden(COLUMN_STATE)); + ui->actionShowLastContactColumn->setChecked(!ui->peerTreeWidget->isColumnHidden(COLUMN_LAST_CONTACT)); + ui->actionShowAvatarColumn->setChecked(!ui->peerTreeWidget->isColumnHidden(COLUMN_AVATAR)); + ui->actionHideOfflineFriends->setChecked(mHideUnconnected); + ui->actionHideState->setChecked(mHideState); + ui->actionRootIsDecorated->setChecked(ui->peerTreeWidget->rootIsDecorated()); + ui->actionShowGroups->setChecked(mShowGroups); +} diff --git a/retroshare-gui/src/gui/common/FriendList.h b/retroshare-gui/src/gui/common/FriendList.h index c61f22d2a..db633cf3c 100644 --- a/retroshare-gui/src/gui/common/FriendList.h +++ b/retroshare-gui/src/gui/common/FriendList.h @@ -34,6 +34,7 @@ namespace Ui { class RSTreeWidgetItemCompareRole; class QTreeWidgetItem; +class QMenu; class FriendList : public RsAutoUpdatePage { @@ -43,6 +44,8 @@ public: explicit FriendList(QWidget *parent = 0); ~FriendList(); + QMenu *createDisplayMenu(); + void processSettings(bool bLoad); void addGroupToExpand(const std::string &groupId); bool getExpandedGroups(std::set &groups) const; void addPeerToExpand(const std::string &gpgId); @@ -50,42 +53,33 @@ public: std::string getSelectedGroupId() const; - void restoreHeaderState(const QByteArray &state); - QByteArray saveHeaderState() const; - virtual void updateDisplay(); -signals: - void peerSortColumnChanged(bool sortedByState); - public slots: void filterItems(const QString &sPattern); void setBigName(bool bigName); // show customStateString in second line of the name cell - void setHideAvatarColumn(bool hidden); - void setHideGroups(bool hidden); + void setShowGroups(bool show); void setHideUnconnected(bool hidden); void setHideState(bool hidden); - void setHideStatusColumn(bool hidden); - void setHideHeader(bool hidden); + void setShowStatusColumn(bool show); + void setShowLastContactColumn(bool show); + void setShowAvatarColumn(bool show); void setRootIsDecorated(bool show); - void setSortByState(bool sortByState); + void setSortByName(); + void setSortByState(); + void setSortByLastContact(); void sortPeersAscendingOrder(); void sortPeersDescendingOrder(); -protected: - void showEvent(QShowEvent *event); - private: Ui::FriendList *ui; RSTreeWidgetItemCompareRole *m_compareRole; // Settings for peer list display bool mBigName; - bool mHideAvatarColumn; - bool mHideGroups; + bool mShowGroups; bool mHideState; - bool mHideStatusColumn; bool mHideUnconnected; QString filterText; @@ -96,20 +90,15 @@ private: QTreeWidgetItem *getCurrentPeer() const; static bool filterItem(QTreeWidgetItem *pItem, const QString &sPattern); - void updateHeaderSizes(); - - bool correctColumnStatusSize; - bool firstTimeShown; - - -// QString fileName; + void updateHeader(); + void initializeHeader(bool afterLoadSettings); private slots: void groupsChanged(); void insertPeers(); - void peerSortIndicatorChanged(int,Qt::SortOrder); void peerTreeWidgetCostumPopupMenu(); void updateAvatar(const QString &); + void updateMenu(); void pastePerson(); diff --git a/retroshare-gui/src/gui/common/FriendList.ui b/retroshare-gui/src/gui/common/FriendList.ui index 8843503b7..f5ab5aa8c 100644 --- a/retroshare-gui/src/gui/common/FriendList.ui +++ b/retroshare-gui/src/gui/common/FriendList.ui @@ -1,90 +1,216 @@ - - - FriendList - - - - 0 - 0 - 337 - 229 - - - - - 0 - - - - - - Arial - 9 - PreferAntialias - true - - - - Qt::CustomContextMenu - - - false - - - false - - - - 38 - 38 - - - - 1 - - - 20 - - - true - - - true - - - true - - - false - - - false - - - 3 - - - 200 - - - - Friends - - - - - Status - - - - - Avatar - - - - - - - - - + + + FriendList + + + + 0 + 0 + 337 + 229 + + + + + 0 + + + + + + Arial + 9 + PreferAntialias + true + + + + Qt::CustomContextMenu + + + + 38 + 38 + + + + 1 + + + 20 + + + true + + + true + + + true + + + false + + + 4 + + + false + + + + Friends + + + + + Status + + + + + Last Contact + + + + + Avatar + + + + + + + + true + + + Hide Offline Friends + + + + + true + + + Status + + + + + true + + + State + + + Sort by State + + + + + true + + + false + + + Hide State + + + + + + :/images/sort_decrease.png:/images/sort_decrease.png + + + Sort Descending Order + + + Sort Descending Order + + + + + + :/images/sort_incr.png:/images/sort_incr.png + + + Sort Ascending Order + + + Sort Ascending Order + + + + + true + + + Avatar + + + Show Avatar Column + + + + + true + + + Name + + + Sort by Name + + + + + true + + + Last Contact + + + Sort by last contact + + + + + true + + + Last Contact + + + Show Last Contact Column + + + + + true + + + Set root is Decorated + + + Set Root Decorated + + + + + true + + + Show Groups + + + Show Groups + + + + + + + + diff --git a/retroshare-gui/src/lang/retroshare_de.qm b/retroshare-gui/src/lang/retroshare_de.qm index 07a819b82..538b8d2b6 100644 Binary files a/retroshare-gui/src/lang/retroshare_de.qm and b/retroshare-gui/src/lang/retroshare_de.qm differ diff --git a/retroshare-gui/src/lang/retroshare_de.ts b/retroshare-gui/src/lang/retroshare_de.ts index ecc7e3345..691949ca1 100644 --- a/retroshare-gui/src/lang/retroshare_de.ts +++ b/retroshare-gui/src/lang/retroshare_de.ts @@ -3524,7 +3524,7 @@ p, li { white-space: pre-wrap; } FlatStyle_RDM - + Friends Directories Dateien von Freunden @@ -4033,7 +4033,7 @@ p, li { white-space: pre-wrap; } Next unread - + Nächste ungelesene @@ -4136,22 +4136,112 @@ p, li { white-space: pre-wrap; } FriendList - + Friends Freunde - + + Hide Offline Friends + Verstecke offline Freunde + + + + Status Status - + + State + Status + + + + Sort by State + Sortiere nach Status + + + + Hide State + Status ausblenden + + + + + Sort Descending Order + Absteigend sortieren + + + + + Sort Ascending Order + Aufsteigend sortieren + + + + Show Last Contact Column + Zeige die Spalte letzer Kontakt + + + + Avatar Avatar - + Hide Avatar Column + Avatar ausblenden + + + + Name + Name + + + + Sort by Name + Sortiere nach Name + + + + + + Last Contact + Letzter Kontakt + + + + Show Avatar Column + Zeige Avatar Spalte + + + + Sort by last contact + Sortiere nach letztem Kontakt + + + Hide Last Contact Column + Verstecke + + + + Set root is Decorated + Zeige Baumstruktur + + + + Set Root Decorated + Zeige Baumstruktur + + + + + Show Groups + Zeige Gruppen + + + Group Gruppe @@ -4267,16 +4357,26 @@ p, li { white-space: pre-wrap; } Alle reduzieren - + Available Verfügbar - + Do you want to remove this Friend? Möchtest du diesen Freund entfernen? + + + Sort by + Sortiere nach + + + + Columns + Spalten + FriendsDialog @@ -4439,56 +4539,45 @@ p, li { white-space: pre-wrap; } Nachrichtenverlauf speichern - Hide Offline Friends - Verstecke offline Freunde + Verstecke offline Freunde - Hide Status Column - Status Spalte ausblenden + Status Spalte ausblenden - - Sort by State - Sortiere nach Status + Sortiere nach Status - - Hide Avatar Column - Avatar ausblenden + Avatar ausblenden Hide State Status ausblenden - + Add a new Group Neue Gruppe hinzufügen - Hide State - Status ausblenden + Status ausblenden - - Sort Descending Order - Absteigend sortieren + Absteigend sortieren + + + Sort Ascending Order + Aufsteigend sortieren - - Sort Ascending Order - Aufsteigend sortieren - - - Delete Chat History Nachrichtenverlauf löschen @@ -4498,7 +4587,7 @@ p, li { white-space: pre-wrap; } Löscht den gespeicherten und angezeigten Chat Verlauf - + Profile Profil @@ -4513,12 +4602,12 @@ p, li { white-space: pre-wrap; } Willkommen bei RetroShare's Gruppenchat. - + me ich - + Paste RetroShare Link RetroShare Link einfügen @@ -7617,48 +7706,40 @@ p, li { white-space: pre-wrap; } Suche Freunde - - Sort Descending Order - Absteigend sortieren + Absteigend sortieren - - Sort Ascending Order - Aufsteigend sortieren + Aufsteigend sortieren - Set root is Decorated - Zeige Baumstruktur + Zeige Baumstruktur - Set Root Decorated - Zeige Baumstruktur + Zeige Baumstruktur - Hide Offline Friends - Verstecke offline Freunde + Verstecke offline Freunde - + Reset Zurücksetzen - Sort by State - Sortiere nach Status + Sortiere nach Status Recomend this Friend to... Freund weiterempfehlen... - + RetroShare Messenger @@ -9964,6 +10045,31 @@ Lockdatei: Round Trip Time: + + + Unable to make path + + + + + Unable to make path: + + + + + Treatment of collection file has failed. + + + + + The collection file + + + + + could not be openned. Reported error is: + + QuickStartWizard @@ -10341,7 +10447,7 @@ p, li { white-space: pre-wrap; } RetroshareDirModel - + Anonymous Anonym @@ -10360,6 +10466,34 @@ p, li { white-space: pre-wrap; } NEW NEU + + + Create selection file + + + + + Collection files + + + + + RsCollectionDialog + + + File + Datei + + + + Size + Grösse + + + + Hash + Prüfsumme + Rshare @@ -10494,7 +10628,7 @@ p, li { white-space: pre-wrap; } - + Download Herunterladen @@ -10531,7 +10665,7 @@ p, li { white-space: pre-wrap; } Ordner - + New RetroShare Link(s) Neu(e) RetroShare Link(s) @@ -10586,7 +10720,7 @@ p, li { white-space: pre-wrap; } Such ID - + Download Notice Download @@ -11040,7 +11174,7 @@ Es hilft auch, wenn Sie sich hinter einer Firewall/VPN befinden. Plugins - + Plugins @@ -11397,7 +11531,7 @@ p, li { white-space: pre-wrap; } SharedFilesDialog - + Download Herunterladen @@ -11481,22 +11615,22 @@ p, li { white-space: pre-wrap; } - + Open File Datei öffnen - + Open Folder Ordner öffnen - + Set command for opening this file Setze eine Regel zum Öffnen dieser Datei - + Copy retroshare Link Kopiere RetroShare Link @@ -11516,7 +11650,7 @@ p, li { white-space: pre-wrap; } Sende RetroShare Link - + Copy retroshare Links to Clipboard Kopiere RetroShare Links in die Zwischenablage @@ -11546,13 +11680,18 @@ p, li { white-space: pre-wrap; } Füge die Links zur Verknüpfungs-Wolke hinzu - - + + Create collection file + + + + + Recommend in a message to Empfehle in einer Nachricht an - + RetroShare Link @@ -11567,7 +11706,7 @@ p, li { white-space: pre-wrap; } Empfehlung(en) - + <strong>My Shared Files</strong> <strong>Meine Dateien</strong> @@ -12545,7 +12684,7 @@ p, li { white-space: pre-wrap; } TransfersDialog - + Cancel Abbrechen @@ -12738,7 +12877,7 @@ p, li { white-space: pre-wrap; } Blockstrategie - + Queued In Warteschleife @@ -12788,7 +12927,7 @@ p, li { white-space: pre-wrap; } Soll dieser Download wirklich abgebrochen und gelöscht werden? - + Speed / Queue position Geschwindigkeits- / Warteschlangenposition @@ -12841,30 +12980,30 @@ p, li { white-space: pre-wrap; } - + Slower Langsamer - - + + Average Durchschnitt - - + + Faster Schneller - + Move in Queue... Verschiebe in Warteschlange... - + Failed @@ -12917,7 +13056,7 @@ p, li { white-space: pre-wrap; } Überprüfe... - + Force Check Erzwinge Überprüfung @@ -12925,7 +13064,7 @@ p, li { white-space: pre-wrap; } TreeStyle_RDM - + My files Meine Dateien @@ -13338,4 +13477,54 @@ p, li { white-space: pre-wrap; } Bilder (*.png *.xpm *.jpg *.tiff *.gif) + + rsCollectionDialog + + + Dialog + + + + + File name : + + + + + Total size : + + + + + Selected files: + + + + + + + TextLabel + + + + + Select all + + + + + Deselect all + + + + + Cancel + Abbrechen + + + + Download! + + +