XWorkstation.st
changeset 8761 b8c491882560
parent 8760 177561518e39
child 8800 03cc2eb3c798
--- a/XWorkstation.st	Tue Aug 06 11:34:14 2019 +0200
+++ b/XWorkstation.st	Tue Aug 06 11:38:22 2019 +0200
@@ -3790,21 +3790,21 @@
 
      xDndAware := self atomIDOf:#XdndAware create:false.
      xDndAware notNil ifTrue:[
-         xDndSelection := self atomIDOf:#XdndSelection create:false.
-         xDndEnter := self atomIDOf:#XdndEnter create:false.
-         xDndLeave := self atomIDOf:#XdndLeave create:false.
-         xDndPosition := self atomIDOf:#XdndPosition create:false.
-         xDndDrop := self atomIDOf:#XdndDrop create:false.
-         xDndFinished := self atomIDOf:#XdndFinished create:false.
-         xDndStatus := self atomIDOf:#XdndStatus create:false.
-         xDndActionCopy := self atomIDOf:#XdndActionCopy create:false.
-         xDndActionMove := self atomIDOf:#XdndActionMove create:false.
-         xDndActionLink := self atomIDOf:#XdndActionLink create:false.
-         xDndActionAsk := self atomIDOf:#XdndActionAsk create:false.
-         xDndActionPrivate := self atomIDOf:#XdndActionPrivate create:false.
-         xDndTypeList := self atomIDOf:#XdndTypeList create:false.
-         xDndTextUriList := self atomIDOf:'test/uri-list' create:false.
-         xDndSelectionAtom := self atomIDOf:'XdndSTXSelection' create:true.
+	 xDndSelection := self atomIDOf:#XdndSelection create:false.
+	 xDndEnter := self atomIDOf:#XdndEnter create:false.
+	 xDndLeave := self atomIDOf:#XdndLeave create:false.
+	 xDndPosition := self atomIDOf:#XdndPosition create:false.
+	 xDndDrop := self atomIDOf:#XdndDrop create:false.
+	 xDndFinished := self atomIDOf:#XdndFinished create:false.
+	 xDndStatus := self atomIDOf:#XdndStatus create:false.
+	 xDndActionCopy := self atomIDOf:#XdndActionCopy create:false.
+	 xDndActionMove := self atomIDOf:#XdndActionMove create:false.
+	 xDndActionLink := self atomIDOf:#XdndActionLink create:false.
+	 xDndActionAsk := self atomIDOf:#XdndActionAsk create:false.
+	 xDndActionPrivate := self atomIDOf:#XdndActionPrivate create:false.
+	 xDndTypeList := self atomIDOf:#XdndTypeList create:false.
+	 xDndTextUriList := self atomIDOf:'test/uri-list' create:false.
+	 xDndSelectionAtom := self atomIDOf:'XdndSTXSelection' create:true.
     ].
 
     "
@@ -3871,11 +3871,11 @@
 
     "data.l[0] contains the XID of the source window.
      data.l[1]:
-        Bit 0 is set if the source supports more than three data types.
-        The high byte contains the protocol version to use (minimum of the source's and target's highest supported versions).
-        The rest of the bits are reserved for future use.
-     data.l[2,3,4] contain the first three types that the source supports. Unused slots are set to None. 
-         The ordering is arbitrary since, in general, the source cannot know what the target prefers."
+	Bit 0 is set if the source supports more than three data types.
+	The high byte contains the protocol version to use (minimum of the source's and target's highest supported versions).
+	The rest of the bits are reserved for future use.
+     data.l[2,3,4] contain the first three types that the source supports. Unused slots are set to None.
+	 The ordering is arbitrary since, in general, the source cannot know what the target prefers."
 
     sourceXid := data unsignedInt32At:1.
     protocolVersion := data unsignedInt32At:5.
@@ -3883,13 +3883,13 @@
     protocolVersion := protocolVersion byteAt:4.
 
     supportedTypes := (1 to:3) collect:[:eachIdx|
-                                    data unsignedInt32At:eachIdx*4+5
-                                ] thenSelect:[:eachType|
-                                    eachType ~~ 0
-                                ].
-
-    Logger info:'xdnd enter:%1 xid:%2 version:%3 types:%4 hasExtensions:%5' 
-           withArguments:{ targetView. sourceXid. protocolVersion. supportedTypes. hasExtensionTypes}.
+				    data unsignedInt32At:eachIdx*4+5
+				] thenSelect:[:eachType|
+				    eachType ~~ 0
+				].
+
+    Logger info:'xdnd enter:%1 xid:%2 version:%3 types:%4 hasExtensions:%5'
+	   withArguments:{ targetView. sourceXid. protocolVersion. supportedTypes. hasExtensionTypes}.
 
     "Created: / 05-08-2019 / 19:44:28 / Stefan Vogel"
     "Modified (format): / 06-08-2019 / 11:31:53 / Stefan Vogel"
@@ -3921,7 +3921,7 @@
     "data.l[0] contains the XID of the source window.
      data.l[1] is reserved for future use (flags).
      data.l[2] contains the coordinates of the mouse position relative to the root window.
-         data.l[2] = (x << 16) | y
+	 data.l[2] = (x << 16) | y
      data.l[3] contains the time stamp for retrieving the data. (new in version 1)
      data.l[4] contains the action requested by the user. (new in version 2)"
 
@@ -3931,8 +3931,8 @@
     timestamp := data unsignedInt32At:13.
     userAction := data unsignedInt32At:17.
 
-    Logger info:'xdnd position:%1 xid:%2 x:%3 y:%4 time:%5 uaction:%6' 
-           withArguments:{targetView. sourceXid. sourceXPosition. sourceYPosition. timestamp. userAction}.
+    Logger info:'xdnd position:%1 xid:%2 x:%3 y:%4 time:%5 uaction:%6'
+	   withArguments:{targetView. sourceXid. sourceXPosition. sourceYPosition. timestamp. userAction}.
 
     "Created: / 05-08-2019 / 19:44:46 / Stefan Vogel"
     "Modified: / 05-08-2019 / 21:11:53 / Stefan Vogel"
@@ -5718,51 +5718,51 @@
     |sensor dndProtocolAtom xdndEnterAtom xdndPositionAtom xdndLeaveAtom xdndDropAtom|
 
     targetView isNil ifTrue:[
-        "targetView is gone? Anyway, cannot do anything with this event..."
-        ^ self.
-    ].
-
-    (xdndEnterAtom := Display atomIDOf:#XdndEnter create:false) notNil ifTrue:[
-        "DND drag&drop protocol"
-        (typeAtom == xdndEnterAtom) ifTrue:[
-            self xdndEnter:data view:targetView.
-            ^ self.
-        ].
-    ].
-    (xdndPositionAtom := Display atomIDOf:#XdndPosition create:false) notNil ifTrue:[
-        "DND drag&drop protocol"
-        (typeAtom == xdndPositionAtom) ifTrue:[
-            self xdndPosition:data view:targetView.
-            ^ self.
-        ].
-    ].
-    (xdndLeaveAtom := Display atomIDOf:#XdndLeave create:false) notNil ifTrue:[
-        "DND drag&drop protocol"
-        (typeAtom == xdndLeaveAtom) ifTrue:[
-            self xdndLeave:data view:targetView.
-            ^ self.
-        ].
-    ].
-    (xdndDropAtom := Display atomIDOf:#XdndDrop create:false) notNil ifTrue:[
-        "DND drag&drop protocol"
-        (typeAtom == xdndDropAtom) ifTrue:[
-            self xdndDrop:data view:targetView.
-            ^ self.
-        ].
+	"targetView is gone? Anyway, cannot do anything with this event..."
+	^ self.
+    ].
+
+    (xdndEnterAtom := self atomIDOf:#XdndEnter create:false) notNil ifTrue:[
+	"DND drag&drop protocol"
+	(typeAtom == xdndEnterAtom) ifTrue:[
+	    self xdndEnter:data view:targetView.
+	    ^ self.
+	].
+    ].
+    (xdndPositionAtom := self atomIDOf:#XdndPosition create:false) notNil ifTrue:[
+	"DND drag&drop protocol"
+	(typeAtom == xdndPositionAtom) ifTrue:[
+	    self xdndPosition:data view:targetView.
+	    ^ self.
+	].
+    ].
+    (xdndLeaveAtom := self atomIDOf:#XdndLeave create:false) notNil ifTrue:[
+	"DND drag&drop protocol"
+	(typeAtom == xdndLeaveAtom) ifTrue:[
+	    self xdndLeave:data view:targetView.
+	    ^ self.
+	].
+    ].
+    (xdndDropAtom := self atomIDOf:#XdndDrop create:false) notNil ifTrue:[
+	"DND drag&drop protocol"
+	(typeAtom == xdndDropAtom) ifTrue:[
+	    self xdndDrop:data view:targetView.
+	    ^ self.
+	].
     ].
 
     (dndProtocolAtom := self atomIDOf:#DndProtocol create:false) notNil ifTrue:[
-        "DND drag&drop protocol"
-        (format == 32 and:[typeAtom == dndProtocolAtom]) ifTrue:[
-            self dndMessage:nil data:data view:targetView.
-            ^ self.
-        ].
+	"DND drag&drop protocol"
+	(format == 32 and:[typeAtom == dndProtocolAtom]) ifTrue:[
+	    self dndMessage:nil data:data view:targetView.
+	    ^ self.
+	].
     ].
 
     sensor := targetView sensor.
     "not posted, if there is no sensor ..."
     sensor notNil ifTrue:[
-        sensor clientMessage:typeAtom format:format eventData:data view:targetView
+	sensor clientMessage:typeAtom format:format eventData:data view:targetView
     ].
 
     "Created: / 04-04-1997 / 17:49:26 / cg"