[Kst] extragear/graphics/kst/kst

George Staikos staikos at kde.org
Sat Nov 12 02:16:23 CET 2005


SVN commit 479875 by staikos:

- fix memory leak in mouse mode menu
- fix memory leak in plot labels
- make plot labels faster


 M  +1 -1      kst.cpp  
 M  +3 -0      kst2dplot.cpp  
 M  +3 -0      kstplotlabel.cpp  


--- trunk/extragear/graphics/kst/kst/kst.cpp #479874:479875
@@ -797,7 +797,7 @@
   LayoutAction->setWhatsThis(i18n("Use this mode to move, resize, and group plots."));
 
   // this is the mouse mode menu
-  QPopupMenu* mouseModeMenu = new QPopupMenu();
+  QPopupMenu* mouseModeMenu = new QPopupMenu(this);
 
   XYZoomAction->plug(mouseModeMenu);
   XZoomAction->plug(mouseModeMenu);
--- trunk/extragear/graphics/kst/kst/kst2dplot.cpp #479874:479875
@@ -511,6 +511,9 @@
   _xTickLabel = new KstPlotLabel;
   _yTickLabel = new KstPlotLabel;
   _fullTickLabel = new KstPlotLabel;
+  _fullTickLabel->setInterpreted(false); // much faster
+  _xTickLabel->setInterpreted(false); // much faster
+  _yTickLabel->setInterpreted(false); // much faster
   _zoomPaused = false;
   setDirty(true);
   _oldSize.setWidth(0);
--- trunk/extragear/graphics/kst/kst/kstplotlabel.cpp #479874:479875
@@ -63,10 +63,13 @@
 
 
 KstPlotLabel::~KstPlotLabel() {
+  delete _parsed;
+  _parsed = 0L;
 }
 
 
 void KstPlotLabel::reparse() {
+  delete _parsed;
    _parsed = Label::parse(_txt, _interpret);
 }
 


More information about the Kst mailing list