On Tue, Apr 6, 2010 at 10:40 AM, Xavi <jara...@gmail.com> wrote:
> El 06/04/2010 9:33, Viktor Szakáts escribió:
>>
>> False. In GTWVT it will only do it if callback says to do so,
>> and it instantly exists the application (that's why it modifies
>> this flag internally - I guess).
>
> GTWVT do this without callback, you need to program a express callback to
> not do so return 1 i.e.
> if not exist NotifierBlock "callback" hb_gt_wvt_FireEvent return 0 and do
> so.
>
> static int hb_gt_wvt_FireEvent( PHB_GTWVT pWVT, int nEvent )
> {
>   int nResult = 0; /* Unhandled */
>
>   if( pWVT->pGT->pNotifierBlock )
>   {
>        ...
>   }
>
>   return nResult;
> }
> ...
>      case WM_CLOSE:  /* Clicked 'X' on system menu */
>         if( hb_gt_wvt_FireEvent( pWVT, HB_GTE_CLOSE ) == 0 )
>         {
>            PHB_ITEM pItem = hb_itemPutL( NULL, HB_TRUE );
>            hb_setSetItem( HB_SET_CANCEL, pItem );...
> ...
>
>> In GTWIN, it just sets the SETCANCEL flag and lets the
>> app continue to run.

This is wrong solution. SETCANCEL is not something
the app sets. SETCANCEL is a way to let app developers
_control_ the behavior of Ctrl+C. Nothing more. What you
committed just creates a hidden extension plus incompatible
to Clipper behavior (since in Clipper SETCANCEL flag was
never modified by window closure).

Brgds,
Viktor
_______________________________________________
Harbour mailing list (attachment size limit: 40KB)
Harbour@harbour-project.org
http://lists.harbour-project.org/mailman/listinfo/harbour

Reply via email to