Author: mlytwyn Date: Sun Mar 12 01:15:14 2017 New Revision: 40383 URL: http://svn.gna.org/viewcvs/gnustep?rev=40383&view=rev Log: Fix for bug 12810 - Script/Images name disappearing when clicked on it
Modified: libs/gui/branches/gnustep_testplant_branch/Source/NSOutlineView.m Modified: libs/gui/branches/gnustep_testplant_branch/Source/NSOutlineView.m URL: http://svn.gna.org/viewcvs/gnustep/libs/gui/branches/gnustep_testplant_branch/Source/NSOutlineView.m?rev=40383&r1=40382&r2=40383&view=diff ============================================================================== --- libs/gui/branches/gnustep_testplant_branch/Source/NSOutlineView.m (original) +++ libs/gui/branches/gnustep_testplant_branch/Source/NSOutlineView.m Sun Mar 12 01:15:14 2017 @@ -89,6 +89,10 @@ static NSImage *collapsed = nil; static NSImage *expanded = nil; static NSImage *unexpandable = nil; + +@interface NSTableView (GNUstepPrivate) +- (NSArray*) _visibleColumns; +@end @interface NSOutlineView (NotificationRequestMethods) - (void) _postSelectionIsChangingNotification; @@ -948,28 +952,9 @@ } /* Determine starting column as fast as possible */ - x_pos = NSMinX (aRect); - i = 0; - while ((i < _numberOfColumns) && (x_pos > _columnOrigins[i])) - { - i++; - } - startingColumn = (i - 1); - - if (startingColumn == -1) - startingColumn = 0; - - /* Determine ending column as fast as possible */ - x_pos = NSMaxX (aRect); - // Nota Bene: we do *not* reset i - while ((i < _numberOfColumns) && (x_pos > _columnOrigins[i])) - { - i++; - } - endingColumn = (i - 1); - - if (endingColumn == -1) - endingColumn = _numberOfColumns - 1; + NSArray *columns = [self _visibleColumns]; + startingColumn = [_tableColumns indexOfObject: [columns firstObject]]; + endingColumn = [_tableColumns indexOfObject: [columns lastObject]]; /* Draw the row between startingColumn and endingColumn */ for (i = startingColumn; i <= endingColumn; i++) _______________________________________________ Gnustep-cvs mailing list Gnustep-cvs@gna.org https://mail.gna.org/listinfo/gnustep-cvs