--- a/WindowGroup.st Wed Jun 10 15:30:54 2009 +0200
+++ b/WindowGroup.st Wed Jun 10 17:22:00 2009 +0200
@@ -16,7 +16,8 @@
previousGroup focusView focusSequence preEventHook postEventHook
pointerView isForModalSubview focusByTab groupHasFocus busyHook
busyHookTimeout inModalLoop preEventHooks postEventHooks
- creatingProcess traceEvents processPriority inWithCursorDoBlock'
+ creatingProcess traceEvents processPriority inWithCursorDoBlock
+ doNotCloseOnAbortSignal'
classVariableNames:'LastActiveGroup LastActiveProcess LeaveSignal
WindowGroupQuerySignal LastEventQuerySignal BusyHookTime'
poolDictionaries:''
@@ -466,6 +467,16 @@
"Modified: 5.7.1996 / 17:53:58 / cg"
!
+doNotCloseOnAbortSignal:something
+ "normally, an abortSignal closes a modal dialog, which is different from a non-modal
+ one, where only the current action (event handling) is aborted.
+
+ This can be disabled, if you want to avoid closing a modal application,
+ but instead have the same non-modal behavior for modal app vies"
+
+ doNotCloseOnAbortSignal := something.
+!
+
graphicsDevice
"return the device, we receive our events from"
@@ -1249,7 +1260,7 @@
thisProcess := Processor activeProcess.
- sigs := SignalSet
+ sigs := SignalSet
"/ with:AbortAllOperationRequest
with:LeaveSignal
with:(self class activityNotificationSignal).
@@ -1257,6 +1268,10 @@
(isModal not or:[AbortAllOperationRequest isHandled not]) ifTrue:[
sigs add:AbortAllOperationRequest
].
+ doNotCloseOnAbortSignal == true ifTrue:[
+ sigs add:AbortOperationRequest
+ ].
+
[
|p g s mainGroup mySema waitSema groupForSema|
@@ -1317,6 +1332,12 @@
|theSig|
theSig := ex signal.
+ (AbortOperationRequest accepts:theSig) ifTrue:[
+ "/
+ "/ on abort, stay in loop
+ "/
+ ex return
+ ].
(AbortAllOperationRequest accepts:theSig) ifTrue:[
"/
"/ on abort, stay in loop
@@ -2692,7 +2713,7 @@
!WindowGroup class methodsFor:'documentation'!
version
- ^ '$Header: /cvs/stx/stx/libview/WindowGroup.st,v 1.300 2009-06-10 13:27:40 ca Exp $'
+ ^ '$Header: /cvs/stx/stx/libview/WindowGroup.st,v 1.301 2009-06-10 15:22:00 ca Exp $'
! !
WindowGroup initialize!