diff --git a/AppKit/CPLevelIndicator.j b/AppKit/CPLevelIndicator.j index 6eb42ed44..6a9812c12 100644 --- a/AppKit/CPLevelIndicator.j +++ b/AppKit/CPLevelIndicator.j @@ -370,7 +370,11 @@ var CPLevelIndicatorStyleKey = "CPLevelIndicatorStyleKey", - (void)encodeWithCoder:(CPCoder)aCoder { + // There's no reason to encode the background. + var background = [self backgroundColor]; + [self setBackgroundColor:nil]; [super encodeWithCoder:aCoder]; + [self setBackgroundColor:background]; [aCoder encodeInt:_levelIndicatorStyle forKey:CPLevelIndicatorStyleKey]; [aCoder encodeDouble:_minValue forKey:CPLevelIndicatorMinValueKey];