diff --git a/AppKit/CPImageView.j b/AppKit/CPImageView.j index ed6eeea42..817ffbd0b 100644 --- a/AppKit/CPImageView.j +++ b/AppKit/CPImageView.j @@ -31,24 +31,10 @@ #include "CoreGraphics/CGGeometry.h" - -/* - @global - @group CPImageScaling -*/ CPScaleProportionally = 0; -/* - @global - @group CPImageScaling -*/ CPScaleToFit = 1; -/* - @global - @group CPImageScaling -*/ CPScaleNone = 2; - var CPImageViewShadowBackgroundColor = nil; var LEFT_SHADOW_INSET = 3.0, @@ -225,6 +211,11 @@ var LEFT_SHADOW_INSET = 3.0, [self setNeedsDisplay:YES]; } +- (unsigned)imageScaling +{ + return [self currentValueForThemeAttribute:@"image-scaling"]; +} + /*! Toggles the display of the image view. */ diff --git a/AppKit/CPTheme.j b/AppKit/CPTheme.j index 499aaa8f7..77bac886d 100644 --- a/AppKit/CPTheme.j +++ b/AppKit/CPTheme.j @@ -22,7 +22,7 @@ @import @import - +@import var CPThemesByName = { }, CPThemeDefaultTheme = nil; diff --git a/Objective-J/Preprocessor.js b/Objective-J/Preprocessor.js index e07ccf75a..51bcd4bae 100644 --- a/Objective-J/Preprocessor.js +++ b/Objective-J/Preprocessor.js @@ -855,7 +855,7 @@ Preprocessor.prototype.preprocess = function(tokens, /*StringBuffer*/ aStringBuf // If we get this far and we're parsing an objj_msgSend (or array), then we have a problem. if (tuple) - new SyntaxError(this.error_message("*** Expected ']' - Unterminated message send or array.")); + throw new SyntaxError(this.error_message("*** Expected ']' - Unterminated message send or array.")); if (!aStringBuffer) return buffer; diff --git a/Tools/nib2cib/NSImageView.j b/Tools/nib2cib/NSImageView.j index 62eb55fe0..2624c2582 100644 --- a/Tools/nib2cib/NSImageView.j +++ b/Tools/nib2cib/NSImageView.j @@ -33,7 +33,7 @@ { var cell = [aCoder decodeObjectForKey:@"NSCell"]; - _imageScaling = [cell imageScaling]; + [self setImageScaling:[cell imageScaling]]; _isEditable = [cell isEditable]; }