[Author Prev][Author Next][Thread Prev][Thread Next][Author Index][Thread Index]

[vidalia-svn] r2011: I changed my mind on r2010: if the router is already on the (in trunk: . src/gui/network)



Author: edmanm
Date: 2007-10-12 03:49:28 -0400 (Fri, 12 Oct 2007)
New Revision: 2011

Modified:
   trunk/
   trunk/src/gui/network/tormapwidget.cpp
Log:
 r2086@lysithea:  edmanm | 2007-10-12 03:49:24 -0400
 I changed my mind on r2010: if the router is already on the map, just update
 the coordinates, instead of completely removing and readding the router.



Property changes on: trunk
___________________________________________________________________
 svk:merge ticket from /local/vidalia/trunk [r2086] on dc66be73-d13e-47ba-a267-8dc7cda68c65

Modified: trunk/src/gui/network/tormapwidget.cpp
===================================================================
--- trunk/src/gui/network/tormapwidget.cpp	2007-10-12 07:34:20 UTC (rev 2010)
+++ trunk/src/gui/network/tormapwidget.cpp	2007-10-12 07:49:28 UTC (rev 2011)
@@ -95,8 +95,9 @@
   
   /* Add data the hash of known routers, and plot the point on the map */
   if (_routers.contains(id))
-    delete _routers.take(id);
-  _routers.insert(id, new QPair<QPointF,bool>(routerCoord, false));
+    _routers.value(id)->first = routerCoord;
+  else
+    _routers.insert(id, new QPair<QPointF,bool>(routerCoord, false));
 }
 
 /** Adds a circuit to the map using the given ordered list of router IDs. */