From 8f4fa005746deb8dd7e34cd07acaa55d50d59fe9 Mon Sep 17 00:00:00 2001 From: Michael R Sweet Date: Fri, 23 Jul 2004 21:12:24 +0000 Subject: Fl_Counter didn't use a thin down box for the text field if the box type was set to FL_THIN_UP_BOX (STR #467) Fl_Help_View now resets the scrollbars if they go outside the current view (STR #464) fl_dir_chooser() did not show the previous selection as documented (STR #443) Fl_Text_Display used delete[] instead of free() in some places (STR #466) git-svn-id: file:///fltk/svn/fltk/branches/branch-1.1@3691 ea41ed52-d2ee-0310-a9c1-e6b18d33e121 --- src/Fl_Text_Display.cxx | 9 +++++---- 1 file changed, 5 insertions(+), 4 deletions(-) (limited to 'src/Fl_Text_Display.cxx') diff --git a/src/Fl_Text_Display.cxx b/src/Fl_Text_Display.cxx index e5b2b1d49..43559cfd3 100644 --- a/src/Fl_Text_Display.cxx +++ b/src/Fl_Text_Display.cxx @@ -1,5 +1,5 @@ // -// "$Id: Fl_Text_Display.cxx,v 1.12.2.54 2004/05/26 02:42:10 easysw Exp $" +// "$Id: Fl_Text_Display.cxx,v 1.12.2.55 2004/07/23 21:12:24 easysw Exp $" // // Copyright 2001-2004 by Bill Spitzak and others. // Original code Copyright Mark Edel. Permission to distribute under @@ -793,7 +793,7 @@ int Fl_Text_Display::position_to_xy( int pos, int* X, int* Y ) { outIndex += charLen; } *X = xStep; - delete [] (char *)lineStr; + free((char *)lineStr); return 1; } @@ -1851,9 +1851,10 @@ int Fl_Text_Display::xy_to_position( int X, int Y, int posType ) { outIndex += charLen; } + free((char *)lineStr); + /* If the X position was beyond the end of the line, return the position of the newline at the end of the line */ - delete [] (char *)lineStr; return lineStart + lineLen; } @@ -3087,5 +3088,5 @@ int Fl_Text_Display::handle(int event) { // -// End of "$Id: Fl_Text_Display.cxx,v 1.12.2.54 2004/05/26 02:42:10 easysw Exp $". +// End of "$Id: Fl_Text_Display.cxx,v 1.12.2.55 2004/07/23 21:12:24 easysw Exp $". // -- cgit v1.2.3