From 40ed94f7fbce33f375121d3145c12506a6a8098a Mon Sep 17 00:00:00 2001 From: csoler Date: Fri, 27 Sep 2013 21:40:51 +0000 Subject: [PATCH] removed copy/paste of links of type PERSON in friendlist. This caused confusion and did not provide anything useful since the creation of the full certificate links git-svn-id: http://svn.code.sf.net/p/retroshare/code/trunk@6771 b45a01b8-16f6-495d-af2f-9b41ad6348cc --- retroshare-gui/src/gui/common/FriendList.cpp | 50 ++++++++++---------- retroshare-gui/src/gui/common/FriendList.h | 2 +- 2 files changed, 26 insertions(+), 26 deletions(-) diff --git a/retroshare-gui/src/gui/common/FriendList.cpp b/retroshare-gui/src/gui/common/FriendList.cpp index 2d733799b..7e0918534 100644 --- a/retroshare-gui/src/gui/common/FriendList.cpp +++ b/retroshare-gui/src/gui/common/FriendList.cpp @@ -403,14 +403,14 @@ void FriendList::peerTreeWidgetCostumPopupMenu() if (type == TYPE_SSL) { contextMnu.addAction(QIcon(IMAGE_COPYLINK), tr("Copy certificate link"), this, SLOT(copyFullCertificate())); } - if (type == TYPE_GPG) { - contextMnu.addAction(QIcon(IMAGE_COPYLINK), tr("Copy RetroShare Link"), this, SLOT(copyLink())); - } + //if (type == TYPE_GPG) { + // contextMnu.addAction(QIcon(IMAGE_COPYLINK), tr("Copy RetroShare Link"), this, SLOT(copyLink())); + //} - QAction *action = contextMnu.addAction(QIcon(IMAGE_PASTELINK), tr("Paste Friend Link"), this, SLOT(pastePerson())); - if (RSLinkClipboard::empty(RetroShareLink::TYPE_PERSON) && RSLinkClipboard::empty(RetroShareLink::TYPE_CERTIFICATE)) { + QAction *action = contextMnu.addAction(QIcon(IMAGE_PASTELINK), tr("Paste certificate link"), this, SLOT(pastePerson())); + + if (/*RSLinkClipboard::empty(RetroShareLink::TYPE_PERSON) &&*/ RSLinkClipboard::empty(RetroShareLink::TYPE_CERTIFICATE)) action->setDisabled(true); - } if (type == TYPE_GPG) { contextMnu.addAction(QIcon(IMAGE_DENYFRIEND), tr("Deny Friend"), this, SLOT(removefriend())); @@ -519,8 +519,8 @@ void FriendList::peerTreeWidgetCostumPopupMenu() // } // } } else { - QAction *action = contextMnu.addAction(QIcon(IMAGE_PASTELINK), tr("Paste Friend Link"), this, SLOT(pastePerson())); - if (RSLinkClipboard::empty(RetroShareLink::TYPE_PERSON) && RSLinkClipboard::empty(RetroShareLink::TYPE_CERTIFICATE)) { + QAction *action = contextMnu.addAction(QIcon(IMAGE_PASTELINK), tr("Paste certificate link"), this, SLOT(pastePerson())); + if (/*RSLinkClipboard::empty(RetroShareLink::TYPE_PERSON) &&*/ RSLinkClipboard::empty(RetroShareLink::TYPE_CERTIFICATE)) { action->setDisabled(true); } } @@ -1338,7 +1338,7 @@ void FriendList::recommendfriend() void FriendList::pastePerson() { - RSLinkClipboard::process(RetroShareLink::TYPE_PERSON); + //RSLinkClipboard::process(RetroShareLink::TYPE_PERSON); RSLinkClipboard::process(RetroShareLink::TYPE_CERTIFICATE); } @@ -1356,22 +1356,22 @@ void FriendList::copyFullCertificate() RSLinkClipboard::copyLinks(urls); } -void FriendList::copyLink() -{ - QTreeWidgetItem *c = getCurrentPeer(); - - if (c == NULL) { - return; - } - - QList urls; - RetroShareLink link; - if (link.createPerson(getRsId(c))) { - urls.push_back(link); - } - - RSLinkClipboard::copyLinks(urls); -} +// void FriendList::copyLink() +// { +// QTreeWidgetItem *c = getCurrentPeer(); +// +// if (c == NULL) { +// return; +// } +// +// QList urls; +// RetroShareLink link; +// if (link.createPerson(getRsId(c))) { +// urls.push_back(link); +// } +// +// RSLinkClipboard::copyLinks(urls); +// } /** * Find out which group is selected diff --git a/retroshare-gui/src/gui/common/FriendList.h b/retroshare-gui/src/gui/common/FriendList.h index c477e02ef..637b741d0 100644 --- a/retroshare-gui/src/gui/common/FriendList.h +++ b/retroshare-gui/src/gui/common/FriendList.h @@ -140,7 +140,7 @@ private slots: void configurefriend(); void chatfriend(QTreeWidgetItem *); void chatfriendproxy(); - void copyLink(); + //void copyLink(); void copyFullCertificate(); // void exportfriend(); void addFriend();