*** empty log message ***
authorClaus Gittinger <cg@exept.de>
Fri, 11 Apr 1997 00:53:07 +0200
changeset 518 c9d492fbb1b6
parent 517 6658791e40d0
child 519 1ee56341ef50
*** empty log message ***
WinIconRdr.st
WindowsIconReader.st
--- a/WinIconRdr.st	Fri Apr 11 00:42:53 1997 +0200
+++ b/WinIconRdr.st	Fri Apr 11 00:53:07 1997 +0200
@@ -391,7 +391,7 @@
 fromWindowsBMPStream:aStream 
     "read an image from a windows BMP stream"
 
-    | fileSize header inDepth inPlanes compression
+    | fileSize header iSize inDepth inPlanes compression
       imgSize resH resV numColor numImportantColor
       dataStart
       rawMap rMap gMap bMap srcIndex dstIndex inBytesPerRow
@@ -406,7 +406,9 @@
     header := ByteArray uninitializedNew:16r54.
     aStream nextBytes:18 into:header.
 
-    ((header at:(16r0E + 1)) == 40) ifTrue:[    "header-size"
+    iSize := header at:(16r0E + 1).
+
+    (iSize == 40) ifTrue:[    "header-size"
         "
          its an Windows3.x BMP file
          or OS/2 vsn 2 BMP file
@@ -443,7 +445,7 @@
         ].
         dataStart := header wordAt:(16r0A + 1) MSB:false
     ] ifFalse:[
-        ((header at:(16r0E + 1)) == 12) ifTrue:[     "core-info header size"
+        (iSize == 12) ifTrue:[     "core-info header size"
             "
              its an OS/2 (vsn1.2) BMP file
             "
@@ -539,7 +541,7 @@
     colorMap := Colormap redVector:rMap greenVector:gMap blueVector:bMap.
 
     "Modified: 17.9.1995 / 18:48:46 / claus"
-    "Modified: 28.1.1997 / 01:47:18 / cg"
+    "Modified: 11.4.1997 / 00:49:38 / cg"
 !
 
 fromWindowsICOFile:aFilename 
@@ -660,6 +662,6 @@
 !WindowsIconReader class methodsFor:'documentation'!
 
 version
-    ^ '$Header: /cvs/stx/stx/libview2/Attic/WinIconRdr.st,v 1.30 1997-02-24 11:12:59 cg Exp $'
+    ^ '$Header: /cvs/stx/stx/libview2/Attic/WinIconRdr.st,v 1.31 1997-04-10 22:53:07 cg Exp $'
 ! !
 WindowsIconReader initialize!
--- a/WindowsIconReader.st	Fri Apr 11 00:42:53 1997 +0200
+++ b/WindowsIconReader.st	Fri Apr 11 00:53:07 1997 +0200
@@ -391,7 +391,7 @@
 fromWindowsBMPStream:aStream 
     "read an image from a windows BMP stream"
 
-    | fileSize header inDepth inPlanes compression
+    | fileSize header iSize inDepth inPlanes compression
       imgSize resH resV numColor numImportantColor
       dataStart
       rawMap rMap gMap bMap srcIndex dstIndex inBytesPerRow
@@ -406,7 +406,9 @@
     header := ByteArray uninitializedNew:16r54.
     aStream nextBytes:18 into:header.
 
-    ((header at:(16r0E + 1)) == 40) ifTrue:[    "header-size"
+    iSize := header at:(16r0E + 1).
+
+    (iSize == 40) ifTrue:[    "header-size"
         "
          its an Windows3.x BMP file
          or OS/2 vsn 2 BMP file
@@ -443,7 +445,7 @@
         ].
         dataStart := header wordAt:(16r0A + 1) MSB:false
     ] ifFalse:[
-        ((header at:(16r0E + 1)) == 12) ifTrue:[     "core-info header size"
+        (iSize == 12) ifTrue:[     "core-info header size"
             "
              its an OS/2 (vsn1.2) BMP file
             "
@@ -539,7 +541,7 @@
     colorMap := Colormap redVector:rMap greenVector:gMap blueVector:bMap.
 
     "Modified: 17.9.1995 / 18:48:46 / claus"
-    "Modified: 28.1.1997 / 01:47:18 / cg"
+    "Modified: 11.4.1997 / 00:49:38 / cg"
 !
 
 fromWindowsICOFile:aFilename 
@@ -660,6 +662,6 @@
 !WindowsIconReader class methodsFor:'documentation'!
 
 version
-    ^ '$Header: /cvs/stx/stx/libview2/WindowsIconReader.st,v 1.30 1997-02-24 11:12:59 cg Exp $'
+    ^ '$Header: /cvs/stx/stx/libview2/WindowsIconReader.st,v 1.31 1997-04-10 22:53:07 cg Exp $'
 ! !
 WindowsIconReader initialize!