Fwd: Linux desktop manager Close Window is dangerous.

Previous Topic Next Topic
 
classic Classic list List threaded Threaded
7 messages Options
Reply | Threaded
Open this post in threaded view
|

Fwd: Linux desktop manager Close Window is dangerous.

Ian Piumarta
 


Begin forwarded message:

> From: [hidden email]
> Date: August 29, 2007 7:42:47 AM PDT
> To: [hidden email]
> Subject: Re: Linux desktop manager Close Window is dangerous.
>
> You are not allowed to post to this mailing list, and your message has
> been automatically rejected.  If you think that your messages are
> being rejected in error, contact the mailing list owner at
> [hidden email].
>
>
> From: Ian Piumarta <[hidden email]>
> Date: August 29, 2007 7:50:53 AM PDT
> To: The general-purpose Squeak developers list <squeak-
> [hidden email]>
> Cc: Squeak Virtual Machine Development Discussion <vm-
> [hidden email]>
> Subject: Re: Linux desktop manager Close Window is dangerous.
>
>
> This patch disables the title bar quit button (iff your window  
> manager participates in the WM_DELETE_WINDOW protocol) and causes  
> an event of type 6 to be sent to the image (in response to which it  
> should pop open the 'save changes before quit' dialogue -- an SEP).
>
> If (1) several people report that this adequately addresses the  
> issue and (2) nobody else has claimed event type 6, then I'll  
> commit the changes and move the event type definition into sq.h  
> next to the others.
>
>



quit.diff.gz (1K) Download Attachment
Reply | Threaded
Open this post in threaded view
|

Re: Fwd: Linux desktop manager Close Window is dangerous.

johnmci
 
How is this different than sending an event type 5 (window event)
with a subtype of 2 (WindowEventClose)

Well unless the idea is that you can close the main squeak window and  
squeak will keep running.


On Aug 29, 2007, at 8:20 AM, Ian Piumarta wrote:

>
>
> Begin forwarded message:
>
>> From: [hidden email]
>> Date: August 29, 2007 7:42:47 AM PDT
>> To: [hidden email]
>> Subject: Re: Linux desktop manager Close Window is dangerous.
>>
>> You are not allowed to post to this mailing list, and your message  
>> has
>> been automatically rejected.  If you think that your messages are
>> being rejected in error, contact the mailing list owner at
>> [hidden email].
>>
>>
>> From: Ian Piumarta <[hidden email]>
>> Date: August 29, 2007 7:50:53 AM PDT
>> To: The general-purpose Squeak developers list <squeak-
>> [hidden email]>
>> Cc: Squeak Virtual Machine Development Discussion <vm-
>> [hidden email]>
>> Subject: Re: Linux desktop manager Close Window is dangerous.
>>
>>
>> This patch disables the title bar quit button (iff your window  
>> manager participates in the WM_DELETE_WINDOW protocol) and causes  
>> an event of type 6 to be sent to the image (in response to which  
>> it should pop open the 'save changes before quit' dialogue -- an  
>> SEP).
>>
>> If (1) several people report that this adequately addresses the  
>> issue and (2) nobody else has claimed event type 6, then I'll  
>> commit the changes and move the event type definition into sq.h  
>> next to the others.
>>
>>
>> <quit.diff.gz>
>

--
========================================================================
===
John M. McIntosh <[hidden email]>
Corporate Smalltalk Consulting Ltd.  http://www.smalltalkconsulting.com
========================================================================
===


Reply | Threaded
Open this post in threaded view
|

Re: Fwd: Linux desktop manager Close Window is dangerous.

Andreas.Raab
 
Yeah, it should use a window event with the close window subtype unless
there is something about X that I don't know (is this possibly a
post-close event, e.g., the window manager destroyed the window already?)

Cheers,
   - Andreas

John M McIntosh wrote:

>
> How is this different than sending an event type 5 (window event)
> with a subtype of 2 (WindowEventClose)
>
> Well unless the idea is that you can close the main squeak window and
> squeak will keep running.
>
>
> On Aug 29, 2007, at 8:20 AM, Ian Piumarta wrote:
>
>>
>>
>> Begin forwarded message:
>>
>>> From: [hidden email]
>>> Date: August 29, 2007 7:42:47 AM PDT
>>> To: [hidden email]
>>> Subject: Re: Linux desktop manager Close Window is dangerous.
>>>
>>> You are not allowed to post to this mailing list, and your message has
>>> been automatically rejected.  If you think that your messages are
>>> being rejected in error, contact the mailing list owner at
>>> [hidden email].
>>>
>>>
>>> From: Ian Piumarta <[hidden email]>
>>> Date: August 29, 2007 7:50:53 AM PDT
>>> To: The general-purpose Squeak developers list
>>> <[hidden email]>
>>> Cc: Squeak Virtual Machine Development Discussion
>>> <[hidden email]>
>>> Subject: Re: Linux desktop manager Close Window is dangerous.
>>>
>>>
>>> This patch disables the title bar quit button (iff your window
>>> manager participates in the WM_DELETE_WINDOW protocol) and causes an
>>> event of type 6 to be sent to the image (in response to which it
>>> should pop open the 'save changes before quit' dialogue -- an SEP).
>>>
>>> If (1) several people report that this adequately addresses the issue
>>> and (2) nobody else has claimed event type 6, then I'll commit the
>>> changes and move the event type definition into sq.h next to the others.
>>>
>>>
>>> <quit.diff.gz>
>>
>
> --
> ===========================================================================
> John M. McIntosh <[hidden email]>
> Corporate Smalltalk Consulting Ltd.  http://www.smalltalkconsulting.com
> ===========================================================================
>
>
Reply | Threaded
Open this post in threaded view
|

Re: Fwd: Linux desktop manager Close Window is dangerous.

Bert Freudenberg
 
No, it's just a notification that the window should be closed if  
possible:

        http://tronche.com/gui/x/icccm/sec-4.html#s-4.2.8.1

Btw, how do we allocate window event subtypes? We need a "window  
completely obscured" visibility event for OLPC.

- Bert -

On Aug 29, 2007, at 10:03 , Andreas Raab wrote:

> Yeah, it should use a window event with the close window subtype  
> unless there is something about X that I don't know (is this  
> possibly a post-close event, e.g., the window manager destroyed the  
> window already?)
>
> Cheers,
>   - Andreas
>
> John M McIntosh wrote:
>> How is this different than sending an event type 5 (window event)
>> with a subtype of 2 (WindowEventClose)
>> Well unless the idea is that you can close the main squeak window  
>> and squeak will keep running.
>> On Aug 29, 2007, at 8:20 AM, Ian Piumarta wrote:
>>>
>>>
>>> Begin forwarded message:
>>>
>>>> From: [hidden email]
>>>> Date: August 29, 2007 7:42:47 AM PDT
>>>> To: [hidden email]
>>>> Subject: Re: Linux desktop manager Close Window is dangerous.
>>>>
>>>> You are not allowed to post to this mailing list, and your  
>>>> message has
>>>> been automatically rejected.  If you think that your messages are
>>>> being rejected in error, contact the mailing list owner at
>>>> [hidden email].
>>>>
>>>>
>>>> From: Ian Piumarta <[hidden email]>
>>>> Date: August 29, 2007 7:50:53 AM PDT
>>>> To: The general-purpose Squeak developers list <squeak-
>>>> [hidden email]>
>>>> Cc: Squeak Virtual Machine Development Discussion <vm-
>>>> [hidden email]>
>>>> Subject: Re: Linux desktop manager Close Window is dangerous.
>>>>
>>>>
>>>> This patch disables the title bar quit button (iff your window  
>>>> manager participates in the WM_DELETE_WINDOW protocol) and  
>>>> causes an event of type 6 to be sent to the image (in response  
>>>> to which it should pop open the 'save changes before quit'  
>>>> dialogue -- an SEP).
>>>>
>>>> If (1) several people report that this adequately addresses the  
>>>> issue and (2) nobody else has claimed event type 6, then I'll  
>>>> commit the changes and move the event type definition into sq.h  
>>>> next to the others.
>>>>
>>>>
>>>> <quit.diff.gz>
>>>
>> --
>> =====================================================================
>> ======
>> John M. McIntosh <[hidden email]>
>> Corporate Smalltalk Consulting Ltd.  http://
>> www.smalltalkconsulting.com
>> =====================================================================
>> ======


Reply | Threaded
Open this post in threaded view
|

Re: Fwd: Linux desktop manager Close Window is dangerous.

Andreas.Raab
 
Bert Freudenberg wrote:
>
> No, it's just a notification that the window should be closed if possible:
>
>     http://tronche.com/gui/x/icccm/sec-4.html#s-4.2.8.1
>
> Btw, how do we allocate window event subtypes?  

svn co sq.h ;-)

> We need a "window completely obscured" visibility event for OLPC.

Use the iconize event. Unless I'm completely mistaken about OLPC (which
doesn't do overlapping windows, right?) we're talking about users
switching between apps which would best be represented by an iconize
event. Also, depending on what you are planning to do in response I'd
think that this maps more into "iconize actions" on other platforms.

Cheers,
   - Andreas

>
> - Bert -
>
> On Aug 29, 2007, at 10:03 , Andreas Raab wrote:
>
>> Yeah, it should use a window event with the close window subtype
>> unless there is something about X that I don't know (is this possibly
>> a post-close event, e.g., the window manager destroyed the window
>> already?)
>>
>> Cheers,
>>   - Andreas
>>
>> John M McIntosh wrote:
>>> How is this different than sending an event type 5 (window event)
>>> with a subtype of 2 (WindowEventClose)
>>> Well unless the idea is that you can close the main squeak window and
>>> squeak will keep running.
>>> On Aug 29, 2007, at 8:20 AM, Ian Piumarta wrote:
>>>>
>>>>
>>>> Begin forwarded message:
>>>>
>>>>> From: [hidden email]
>>>>> Date: August 29, 2007 7:42:47 AM PDT
>>>>> To: [hidden email]
>>>>> Subject: Re: Linux desktop manager Close Window is dangerous.
>>>>>
>>>>> You are not allowed to post to this mailing list, and your message has
>>>>> been automatically rejected.  If you think that your messages are
>>>>> being rejected in error, contact the mailing list owner at
>>>>> [hidden email].
>>>>>
>>>>>
>>>>> From: Ian Piumarta <[hidden email]>
>>>>> Date: August 29, 2007 7:50:53 AM PDT
>>>>> To: The general-purpose Squeak developers list
>>>>> <[hidden email]>
>>>>> Cc: Squeak Virtual Machine Development Discussion
>>>>> <[hidden email]>
>>>>> Subject: Re: Linux desktop manager Close Window is dangerous.
>>>>>
>>>>>
>>>>> This patch disables the title bar quit button (iff your window
>>>>> manager participates in the WM_DELETE_WINDOW protocol) and causes
>>>>> an event of type 6 to be sent to the image (in response to which it
>>>>> should pop open the 'save changes before quit' dialogue -- an SEP).
>>>>>
>>>>> If (1) several people report that this adequately addresses the
>>>>> issue and (2) nobody else has claimed event type 6, then I'll
>>>>> commit the changes and move the event type definition into sq.h
>>>>> next to the others.
>>>>>
>>>>>
>>>>> <quit.diff.gz>
>>>>
>>> --
>>> ===========================================================================
>>>
>>> John M. McIntosh <[hidden email]>
>>> Corporate Smalltalk Consulting Ltd.  http://www.smalltalkconsulting.com
>>> ===========================================================================
>>>
>
>
Reply | Threaded
Open this post in threaded view
|

Re: Fwd: Linux desktop manager Close Window is dangerous.

johnmci
In reply to this post by Andreas.Raab
 
Ok, well the other option is this more of a application event, where  
this close window event really means quit the application.

On the macintosh we get a quit application event which we ignore, or  
optionally for the Scratch people we have a VM setting were the VM  
actually terminates. This is used to terminate the Scratch VM without  
intervention if the macintosh user logs off or shutdowns the machine.

We could of course flow the event 6 when we receive the "quit  
application" event from the operating system.


On Aug 29, 2007, at 10:03 AM, Andreas Raab wrote:

> Yeah, it should use a window event with the close window subtype  
> unless there is something about X that I don't know (is this  
> possibly a post-close event, e.g., the window manager destroyed the  
> window already?)
>
> Cheers,
>   - Andreas
>
> John M McIntosh wrote:
>> How is this different than sending an event type 5 (window event)
>> with a subtype of 2 (WindowEventClose)
>> Well unless the idea is that you can close the main squeak window  
>> and squeak will keep running.
>> On Aug 29, 2007, at 8:20 AM, Ian Piumarta wrote:
>>>
>>>
>>> Begin forwarded message:
>>>
>>>> From: [hidden email]
>>>> Date: August 29, 2007 7:42:47 AM PDT
>>>> To: [hidden email]
>>>> Subject: Re: Linux desktop manager Close Window is dangerous.
>>>>
>>>> You are not allowed to post to this mailing list, and your  
>>>> message has
>>>> been automatically rejected.  If you think that your messages are
>>>> being rejected in error, contact the mailing list owner at
>>>> [hidden email].
>>>>
>>>>
>>>> From: Ian Piumarta <[hidden email]>
>>>> Date: August 29, 2007 7:50:53 AM PDT
>>>> To: The general-purpose Squeak developers list <squeak-
>>>> [hidden email]>
>>>> Cc: Squeak Virtual Machine Development Discussion <vm-
>>>> [hidden email]>
>>>> Subject: Re: Linux desktop manager Close Window is dangerous.
>>>>
>>>>
>>>> This patch disables the title bar quit button (iff your window  
>>>> manager participates in the WM_DELETE_WINDOW protocol) and  
>>>> causes an event of type 6 to be sent to the image (in response  
>>>> to which it should pop open the 'save changes before quit'  
>>>> dialogue -- an SEP).
>>>>
>>>> If (1) several people report that this adequately addresses the  
>>>> issue and (2) nobody else has claimed event type 6, then I'll  
>>>> commit the changes and move the event type definition into sq.h  
>>>> next to the others.
>>>>
>>>>
>>>> <quit.diff.gz>
>>>
>> --
>> =====================================================================
>> ======
>> John M. McIntosh <[hidden email]>
>> Corporate Smalltalk Consulting Ltd.  http://
>> www.smalltalkconsulting.com
>> =====================================================================
>> ======

--
========================================================================
===
John M. McIntosh <[hidden email]>
Corporate Smalltalk Consulting Ltd.  http://www.smalltalkconsulting.com
========================================================================
===


Reply | Threaded
Open this post in threaded view
|

Re: Fwd: Linux desktop manager Close Window is dangerous.

Ian Piumarta
In reply to this post by Ian Piumarta
 
On Aug 29, 2007, at 8:20 AM, Ian Piumarta wrote:

>> This patch disables the title bar quit button (iff your window  
>> manager participates in the WM_DELETE_WINDOW protocol) and causes  
>> an event of type 6 to be sent to the image (in response to which  
>> it should pop open the 'save changes before quit' dialogue -- an  
>> SEP).

Changed to use WindowEvent(action=Close) and committed.

Ciao,
Ian