[Pkg] The Trunk: Graphics-tfel.355.mcz

commits at source.squeak.org commits at source.squeak.org
Wed Jul 27 16:03:34 UTC 2016


Tim Felgentreff uploaded a new version of Graphics to project The Trunk:
http://source.squeak.org/trunk/Graphics-tfel.355.mcz

==================== Summary ====================

Name: Graphics-tfel.355
Author: tfel
Time: 27 July 2016, 6:02:58.629152 pm
UUID: 004f1a41-9be9-c443-9853-26c892c7a2ae
Ancestors: Graphics-tpr.354

small fix to allow creating Forms from hibernated bitmaps, like the Sugar icon library does

=============== Diff against Graphics-tpr.354 ===============

Item was changed:
  ----- Method: Form>>setExtent:depth:bits: (in category 'private') -----
  setExtent: extent depth: bitsPerPixel bits: bitmap
  	"Create a virtual bit map with the given extent and bitsPerPixel."
  
  	width := extent x asInteger.
  	width < 0 ifTrue: [width := 0].
  	height := extent y asInteger.
  	height < 0 ifTrue: [height := 0].
  	depth := bitsPerPixel.
  	depth := bitsPerPixel.
+ 	(bits isNil
- 	(bitmap isNil
  		or:[(bitmap class isWords and: [self bitsSize = bitmap size])
  		or: [bitmap class isBytes and: [self bitsSize * 4 = bitmap size]]])
  			ifFalse:[^self error:'Bad dimensions'].
  	bits := bitmap!



More information about the Packages mailing list