*** empty log message ***
authorclaus
Mon, 20 Dec 1993 00:42:23 +0100
changeset 20 ab35d92b9a4b
parent 19 74683e998f36
child 21 7b3da079729d
*** empty log message ***
DevWorkst.st
DeviceWorkstation.st
GLXWorkstat.st
GLXWorkstation.st
View.st
--- a/DevWorkst.st	Sun Dec 19 01:46:41 1993 +0100
+++ b/DevWorkst.st	Mon Dec 20 00:42:23 1993 +0100
@@ -34,7 +34,7 @@
 COPYRIGHT (c) 1993 by Claus Gittinger
               All Rights Reserved
 
-$Header: /cvs/stx/stx/libview/Attic/DevWorkst.st,v 1.6 1993-12-11 01:27:42 claus Exp $
+$Header: /cvs/stx/stx/libview/Attic/DevWorkst.st,v 1.7 1993-12-19 23:42:15 claus Exp $
 written jan 93 by claus
 '!
 
@@ -838,7 +838,7 @@
                     sema := nil
                 ]
             ]
-        ] forkAt:(Processor userSchedulingPriority).
+        ] forkAt:(Processor userSchedulingPriority + 1).
         p name:'event dispatcher'
     ]
 !
--- a/DeviceWorkstation.st	Sun Dec 19 01:46:41 1993 +0100
+++ b/DeviceWorkstation.st	Mon Dec 20 00:42:23 1993 +0100
@@ -34,7 +34,7 @@
 COPYRIGHT (c) 1993 by Claus Gittinger
               All Rights Reserved
 
-$Header: /cvs/stx/stx/libview/DeviceWorkstation.st,v 1.6 1993-12-11 01:27:42 claus Exp $
+$Header: /cvs/stx/stx/libview/DeviceWorkstation.st,v 1.7 1993-12-19 23:42:15 claus Exp $
 written jan 93 by claus
 '!
 
@@ -838,7 +838,7 @@
                     sema := nil
                 ]
             ]
-        ] forkAt:(Processor userSchedulingPriority).
+        ] forkAt:(Processor userSchedulingPriority + 1).
         p name:'event dispatcher'
     ]
 !
--- a/GLXWorkstat.st	Sun Dec 19 01:46:41 1993 +0100
+++ b/GLXWorkstat.st	Mon Dec 20 00:42:23 1993 +0100
@@ -24,7 +24,7 @@
 
 this class just to give a hint of what could be ...
 
-$Header: /cvs/stx/stx/libview/Attic/GLXWorkstat.st,v 1.4 1993-12-19 00:46:02 claus Exp $
+$Header: /cvs/stx/stx/libview/Attic/GLXWorkstat.st,v 1.5 1993-12-19 23:42:20 claus Exp $
 written june 93 by claus
 '!
 
@@ -306,6 +306,14 @@
         self addKnownView:aView withId:windowId.
     ].
     ^ windowId
+!
+
+unlinkGLXView:aGLXWindowId
+    "remove X/GLX link"
+%{
+    if (_isSmallInteger(aGLXWindowId))
+        GLXUnlinkWindow(myDpy, MKWIN(aGLXWindowId));
+%}
 ! !
 
 !GLXWorkstation methodsFor:'queries'!
--- a/GLXWorkstation.st	Sun Dec 19 01:46:41 1993 +0100
+++ b/GLXWorkstation.st	Mon Dec 20 00:42:23 1993 +0100
@@ -24,7 +24,7 @@
 
 this class just to give a hint of what could be ...
 
-$Header: /cvs/stx/stx/libview/GLXWorkstation.st,v 1.4 1993-12-19 00:46:02 claus Exp $
+$Header: /cvs/stx/stx/libview/GLXWorkstation.st,v 1.5 1993-12-19 23:42:20 claus Exp $
 written june 93 by claus
 '!
 
@@ -306,6 +306,14 @@
         self addKnownView:aView withId:windowId.
     ].
     ^ windowId
+!
+
+unlinkGLXView:aGLXWindowId
+    "remove X/GLX link"
+%{
+    if (_isSmallInteger(aGLXWindowId))
+        GLXUnlinkWindow(myDpy, MKWIN(aGLXWindowId));
+%}
 ! !
 
 !GLXWorkstation methodsFor:'queries'!
--- a/View.st	Sun Dec 19 01:46:41 1993 +0100
+++ b/View.st	Mon Dec 20 00:42:23 1993 +0100
@@ -42,7 +42,7 @@
 COPYRIGHT (c) 1989 by Claus Gittinger
               All Rights Reserved
 
-$Header: /cvs/stx/stx/libview/View.st,v 1.6 1993-12-12 21:34:05 claus Exp $
+$Header: /cvs/stx/stx/libview/View.st,v 1.7 1993-12-19 23:42:23 claus Exp $
 
 written spring/summer 89 by claus
 3D effects summer 90 by claus
@@ -1469,23 +1469,14 @@
 !
 
 sensor
+    "return the views sensor"
+
     windowGroup notNil ifTrue:[
         ^ windowGroup sensor.
     ].
     ^ nil
 !
 
-open
-    ProcessorScheduler isPureEventDriven ifFalse:[
-        windowGroup isNil ifTrue:[
-            windowGroup := WindowGroup new.
-            windowGroup addTopView:self.
-        ].
-        windowGroup startup.
-    ].
-    ^ self realize
-!
-
 update
     ^ self redraw
 !
@@ -1546,7 +1537,7 @@
 !View methodsFor:'scrolling'!
 
 widthForScrollBetween:firstLine and:lastLine
-    "answer the width in pixels for a scroll between firstLine and lastLine
+    "return the width in pixels for a scroll between firstLine and lastLine
      - return full width here since we do not know how wide contents is"
 
     ^ (width - margin - margin)
@@ -2462,6 +2453,35 @@
         realized := false.
         shown := false
     ]
+!
+
+open
+    "create and schedule a new windowgroup for me and open the view"
+
+    ProcessorScheduler isPureEventDriven ifFalse:[
+        windowGroup isNil ifTrue:[
+            windowGroup := WindowGroup new.
+            windowGroup addTopView:self.
+        ].
+        windowGroup startup.
+    ].
+    ^ self realize
+!
+
+openModal
+    "create a new windowgroup, but start processing in the current process
+     actually suspending event processing for the currently active group"
+
+    ProcessorScheduler isPureEventDriven ifFalse:[
+        windowGroup isNil ifTrue:[
+            windowGroup := WindowGroup new.
+            windowGroup addTopView:self.
+        ].
+	self realize.
+	self windowGroup eventLoop
+    ] ifFalse:[
+	self realize
+    ]
 ! !
 
 !View methodsFor:'drawing'!