--- a/ObjectView.st Tue May 28 19:08:55 1996 +0200
+++ b/ObjectView.st Tue May 28 19:21:01 1996 +0200
@@ -526,25 +526,19 @@
"
get device coordinates
"
-"/ 'logical ' print. rootPoint printNL.
transformation notNil ifTrue:[
rootPoint := transformation applyTo:rootPoint.
-"/ 'device ' print. rootPoint printNL.
].
+ viewId := rootView id.
+
"
translate to screen
"
- offs := device translatePoint:0@0 from:(self id) to:(rootView id).
-"/ 'offs' print. offs printNL.
+ offs := device translatePoint:0@0 from:(self id) to:viewId.
rootPoint := rootPoint + offs.
-"/ 'screen ' print. rootPoint printNL.
-
-"/ rootPoint := device translatePoint:lastButt
-"/ from:(self id)
-"/ to:(rootView id).
+
"search view the drop is in"
- viewId := rootView id.
[viewId notNil] whileTrue:[
destinationId := device viewIdFromPoint:rootPoint in:viewId.
lastViewId := viewId.
@@ -601,20 +595,16 @@
"
get device coordinates
"
-"/ 'logical ' print. p1 print. ' ' print. p2 printNL.
transformation notNil ifTrue:[
p1 := transformation applyTo:p1.
p2 := transformation applyTo:p2.
-"/ 'device ' print. p1 print. ' ' print. p2 printNL.
].
"
translate to screen
"
offs := device translatePoint:0@0 from:(self id) to:(rootView id).
-"/ 'offs' print. offs printNL.
p1 := p1 + offs.
p2 := p2 + offs.
-"/ 'screen ' print. p1 print. ' ' print. p2 printNL.
] ifFalse:[
dragger := self.
].
@@ -747,13 +737,13 @@
transformation notNil ifTrue:[
p := transformation applyTo:p.
].
+ viewId := rootView id.
"
translate to screen
"
- rootPoint := p + (device translatePoint:0@0 from:(self id) to:(rootView id)).
+ rootPoint := p + (device translatePoint:0@0 from:(self id) to:viewId).
"search view the drop is in"
- viewId := rootView id.
[viewId notNil] whileTrue:[
destinationId := device viewIdFromPoint:rootPoint in:viewId.
lastViewId := viewId.
@@ -2798,5 +2788,5 @@
!ObjectView class methodsFor:'documentation'!
version
- ^ '$Header: /cvs/stx/stx/libwidg/ObjectView.st,v 1.37 1996-05-18 15:41:12 cg Exp $'
+ ^ '$Header: /cvs/stx/stx/libwidg/ObjectView.st,v 1.38 1996-05-28 17:21:01 cg Exp $'
! !