--- a/Cursor.st Thu Mar 27 17:15:30 1997 +0100
+++ b/Cursor.st Fri Mar 28 13:52:47 1997 +0100
@@ -1863,9 +1863,19 @@
"create a new Cursor representing the same cursor as
myself on aDevice; if one already exists, return the one"
+ self obsoleteMethodWarning:'use #onDevice:'.
+ ^ self onDevice:aDevice
+
+ "Modified: 28.3.1997 / 13:47:02 / cg"
+!
+
+onDevice:aDevice
+ "create a new Cursor representing the same cursor as
+ myself on aDevice; if one already exists, return the one"
+
aDevice isNil ifTrue:[
- "this may not happen"
- self error:'nil device'
+ "this may not happen"
+ self error:'nil device'
].
"if I am already assigned to that device ..."
@@ -1873,27 +1883,28 @@
"first look if not already there"
Lobby do:[:aCursor |
- (aCursor graphicsDevice == aDevice) ifTrue:[
- shape notNil ifTrue:[
- (aCursor shape == shape) ifTrue:[
- ^ aCursor
- ]
- ] ifFalse:[
- (aCursor sourceForm == sourceForm) ifTrue:[
- (aCursor maskForm == maskForm) ifTrue:[
- (aCursor hotX == hotX) ifTrue:[
- (aCursor hotY == hotY) ifTrue:[
- ^ aCursor
- ]
- ]
- ]
- ]
- ]
- ]
+ (aCursor graphicsDevice == aDevice) ifTrue:[
+ shape notNil ifTrue:[
+ (aCursor shape == shape) ifTrue:[
+ ^ aCursor
+ ]
+ ] ifFalse:[
+ (aCursor sourceForm == sourceForm) ifTrue:[
+ (aCursor maskForm == maskForm) ifTrue:[
+ (aCursor hotX == hotX) ifTrue:[
+ (aCursor hotY == hotY) ifTrue:[
+ ^ aCursor
+ ]
+ ]
+ ]
+ ]
+ ]
+ ]
].
^ self newOn:aDevice
"Modified: 5.7.1996 / 17:58:00 / cg"
+ "Created: 28.3.1997 / 13:46:38 / cg"
! !
!Cursor methodsFor:'instance release'!
@@ -2046,6 +2057,6 @@
!Cursor class methodsFor:'documentation'!
version
- ^ '$Header: /cvs/stx/stx/libview/Cursor.st,v 1.46 1997-03-04 13:24:02 cg Exp $'
+ ^ '$Header: /cvs/stx/stx/libview/Cursor.st,v 1.47 1997-03-28 12:51:20 cg Exp $'
! !
Cursor initialize!