* minor changes required to get the gui working with PGP,

* improved NetworkView to show signatures, and friends.

I expect these will be cleaned up later - these were purely functional so i could test pgp.

Enable using RS_USE_PGPSSL in rsiface/rsinit.h
   


git-svn-id: http://svn.code.sf.net/p/retroshare/code/trunk@1266 b45a01b8-16f6-495d-af2f-9b41ad6348cc
This commit is contained in:
drbob 2009-05-23 15:13:01 +00:00
parent 5f28f76b07
commit 100cf75439
19 changed files with 695 additions and 208 deletions

View file

@ -36,6 +36,7 @@
#include "graphwidget.h"
#include "edge.h"
#include "arrow.h"
#include "node.h"
#include <QDebug>
@ -96,26 +97,10 @@ bool GraphWidget::clearGraph()
delete oldscene;
}
if (oldcenterNode)
{
//delete oldcenterNode;
}
nodeMap.clear();
edgeList.clear();
std::list<Edge *>::iterator eit;
std::map<std::string, Node *>::iterator it;
for(eit = edgeList.begin(); eit != edgeList.end(); eit++)
{
//delete(*eit);
}
for(it = nodeMap.begin(); it != nodeMap.end(); it++)
{
//delete(it->second);
}
nodeMap.clear();
edgeList.clear();
return true;
return true;
}
void GraphWidget::addNode(uint32_t type, std::string id, std::string name)
@ -161,10 +146,43 @@ void GraphWidget::addEdge(std::string id1, std::string id2)
}
}
void GraphWidget::addArrow(std::string id1, std::string id2)
{
std::map<std::string, Node *>::iterator it;
Node *n1 = NULL;
Node *n2 = NULL;
if (id1 == "")
{
n1 = centerNode;
}
else
{
it = nodeMap.find(id1);
if (it != nodeMap.end())
{
n1 = it->second;
}
}
it = nodeMap.find(id2);
if (it != nodeMap.end())
{
n2 = it->second;
}
if ((n1) && (n2))
{
Arrow *arrow = new Arrow(n1, n2);
scene()->addItem(arrow);
arrowList.push_back(arrow);
}
}
void GraphWidget::itemMoved()
{
if (!timerId)
timerId = startTimer(1000 / 25);
timerId = startTimer(1000 / 10);
}
void GraphWidget::keyPressEvent(QKeyEvent *event)