diff options
author | Damiano Galassi <[email protected]> | 2015-08-29 17:32:50 +0200 |
---|---|---|
committer | Damiano Galassi <[email protected]> | 2015-08-29 17:32:50 +0200 |
commit | 2d847fea38299aa444bd27b1d9133f10eb9043a5 (patch) | |
tree | 57f9a5911fbbc876eb55f5c7ce4676ec32b9f48e /macosx/HBPicture.m | |
parent | 32f442e8da91b8766333abc9ba6b69946701d8db (diff) |
MacGui: added a new sourceInfo property to retrieve a string with the picture size info of the source
Diffstat (limited to 'macosx/HBPicture.m')
-rw-r--r-- | macosx/HBPicture.m | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/macosx/HBPicture.m b/macosx/HBPicture.m index 43c1d7979..099a4c77a 100644 --- a/macosx/HBPicture.m +++ b/macosx/HBPicture.m @@ -345,6 +345,11 @@ NSString * const HBPictureChangedNotification = @"HBPictureChangedNotification"; return self.sourceWidth / 2 - 2; } +- (int)sourceDisplayWidth +{ + return (int) (self.sourceWidth * self.sourceParNum / (double)self.sourceParDen); +} + + (NSSet *)keyPathsForValuesAffectingValueForKey:(NSString *)key { NSSet *retval = nil; |