Revision: 12406 http://sourceforge.net/p/skim-app/code/12406 Author: hofman Date: 2021-09-17 20:12:02 +0000 (Fri, 17 Sep 2021) Log Message: ----------- Never allow removing the last color from a color swatch
Modified Paths: -------------- trunk/SKColorSwatch.m Modified: trunk/SKColorSwatch.m =================================================================== --- trunk/SKColorSwatch.m 2021-09-14 14:38:58 UTC (rev 12405) +++ trunk/SKColorSwatch.m 2021-09-17 20:12:02 UTC (rev 12406) @@ -633,7 +633,7 @@ } - (void)removeColorAtIndex:(NSInteger)i { - if (i >= 0 && i < (NSInteger)[colors count]) { + if (i >= 0 && i < (NSInteger)[colors count] && [colors count] > 1) { [self deactivate]; NSSize size = [self sizeForNumberOfColors:[colors count] - 1]; [self noteFocusRingMaskChanged]; This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. _______________________________________________ Skim-app-commit mailing list Skim-app-commit@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/skim-app-commit