class: ExternalTopView
changed:
#checkWindowStillAlive
#destroyView
#setWindowID:
access device via message send
--- a/ExternalTopView.st Tue Feb 18 15:21:54 2014 +0100
+++ b/ExternalTopView.st Tue Feb 18 15:38:31 2014 +0100
@@ -89,19 +89,20 @@
"check for a destroyed topView
(must poll, since we do not get any events from X for the alien topView)"
- |stillAlive prevErrorPrintingFlag|
+ |stillAlive prevErrorPrintingFlag graphicsDevice|
- prevErrorPrintingFlag := device class errorPrinting.
- device class errorPrinting:(ErrorPrinting ? true).
+ graphicsDevice := self graphicsDevice.
+ prevErrorPrintingFlag := graphicsDevice class errorPrinting.
+ graphicsDevice class errorPrinting:(ErrorPrinting ? true).
- drawableId notNil ifTrue:[
- stillAlive := device isValidWindowId:drawableId.
+ self drawableId notNil ifTrue:[
+ stillAlive := graphicsDevice isValidWindowId:self drawableId.
] ifFalse:[
stillAlive := false
].
- device flush.
+ graphicsDevice flush.
- device class errorPrinting:prevErrorPrintingFlag.
+ graphicsDevice class errorPrinting:prevErrorPrintingFlag.
^ stillAlive.
!
@@ -137,7 +138,7 @@
!ExternalTopView methodsFor:'private accessing'!
setWindowID:aWindowID
- drawableId := aWindowID.
+ self setId:aWindowID.
realized := shown := true.
! !
@@ -157,8 +158,7 @@
self stopWindowClosedPollProcess.
realized := false.
- drawableId := nil.
-
+ self setId:nil.
!
open
@@ -317,6 +317,6 @@
!ExternalTopView class methodsFor:'documentation'!
version
- ^ '$Header: /cvs/stx/stx/libview2/ExternalTopView.st,v 1.20 2013-06-26 08:01:39 stefan Exp $'
+ ^ '$Header: /cvs/stx/stx/libview2/ExternalTopView.st,v 1.21 2014-02-18 14:38:31 stefan Exp $'
! !