Author: clopes
Date: 2011-09-27 14:17:39 -0700 (Tue, 27 Sep 2011)
New Revision: 26992

Modified:
   cytoscapeweb/trunk/cytoscapeweb/src/org/cytoscapeweb/view/GraphMediator.as
Log:
Removed the rescaleNodeLabel method.

Modified: 
cytoscapeweb/trunk/cytoscapeweb/src/org/cytoscapeweb/view/GraphMediator.as
===================================================================
--- cytoscapeweb/trunk/cytoscapeweb/src/org/cytoscapeweb/view/GraphMediator.as  
2011-09-27 21:14:11 UTC (rev 26991)
+++ cytoscapeweb/trunk/cytoscapeweb/src/org/cytoscapeweb/view/GraphMediator.as  
2011-09-27 21:17:39 UTC (rev 26992)
@@ -316,21 +316,11 @@
         
         public function zoomGraphTo(scale:Number):void {
             graphView.zoomTo(scale);
-            if (graphProxy.rolledOverNode != null) {
-                // If zooming while mouse still over a node (e.g. using the 
keyboard to zoom),
-                // its label size may be wrong, so let's reset it:
-                rescaleNodeLabel(graphProxy.rolledOverNode, true);
-            }
         }
         
         public function zoomGraphToFit():void {
             graphView.zoomToFit();
             graphView.centerGraph();
-            if (graphProxy.rolledOverNode != null) {
-                // If zooming while mouse still over a node (e.g. using the 
keyboard to zoom),
-                // its label size may be wrong, so let's reset it:
-                rescaleNodeLabel(graphProxy.rolledOverNode, true);
-            }
         }
         
         public function getViewCenter():Point {
@@ -544,9 +534,6 @@
             
             sendNotification(ApplicationFacade.ROLLOVER_EVENT, n);
             updateCursor();
-            
-            // When zoom < 100%, increase the label size to make it readable:
-            if (_graphScale < 1) rescaleNodeLabel(n);
         }
         
         private function onRollOutNode(evt:MouseEvent):void {
@@ -558,8 +545,6 @@
             n.removeEventListener(MouseEvent.ROLL_OUT, onRollOutNode);
             updateCursor();
             evt.stopImmediatePropagation();
-
-            rescaleNodeLabel(n, true);
         }
         
         private function onMouseDownNode(evt:MouseEvent):void { trace("** 
Mouse DOWN [node]");
@@ -785,21 +770,6 @@
             graphView.stage.addEventListener(MouseEvent.MOUSE_UP, 
onMouseUpToStopPanning, false, 0, true);
         }
         
-        private function rescaleNodeLabel(n:NodeSprite, 
reset:Boolean=false):void {
-            if (n != null && configProxy.config.nodeLabelsVisible) {
-                var label:TextSprite = n.props.label as TextSprite;
-                if (label != null) {
-                    var fsize:Number = 
configProxy.visualStyle.getValue(VisualProperties.NODE_LABEL_FONT_SIZE, n.data) 
as Number;
-                    if (reset)
-                        label.size = fsize;
-                    else if (_graphScale < 1)
-                        label.size = fsize / _graphScale;
-                    
-                    vis.nodeLabeler.operate();
-                }
-            }
-        }
-        
         private function setStyleToSelectionControl(style:VisualStyleVO):void {
                if (_selectionControl == null) return;
                

-- 
You received this message because you are subscribed to the Google Groups 
"cytoscape-cvs" group.
To post to this group, send email to [email protected].
To unsubscribe from this group, send email to 
[email protected].
For more options, visit this group at 
http://groups.google.com/group/cytoscape-cvs?hl=en.

Reply via email to