lost of Control-y

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

lost of Control-y

Jim Harsh

I seem to have lost the ability to interrupt a process using
Control-y in the user version of my application. I'm running VW7.7.1
In our application there are various sections code that can run for a
long time. To give the user the ability to interrupt the process for
what ever reason we have sections of code wrapped as follows:

        (Core.Object userInterruptSignal)
                handle:
                        [:ex| self restoreParametersAfterUserInterrupt.
                        self setToNilAndGarbageCollect.
                        self propagateClearingOfStatusFlags.
                        self propagateClearingOfAdjointStatusFlags.
                        messages value: 'I halted because you interrupted me...'.
                        Dialog warn: 'User Interruption of Optimization'.
                        ex return]
                do:
                        [self optimizeBegin]



In the developer version this works find, hitting Control-y
interrupts the process, pops the Dialog and every thing is fine.

However after I Runtimepackage the application, control-y doesn't
cause the userInteruptSignal to be raised on Windows. (XP and Windows
7), Linux 32 nor Linux 64. However on my Linux 32 (debian) and Linux
64 (Redhat) control-` raises the signal. control-` does not raise the
signal on Windows.

During the Runtime packaging, I tested the application figuring if I
missed something that should be kept, I would get a dynamic reference
so I could go back and add it but Control-y raised the signal with no
dynamic references posted.

What am I missing during the packaging procedure to keep the
control-y functionality?

Thanks

_______________________________________________
vwnc mailing list
[hidden email]
http://lists.cs.uiuc.edu/mailman/listinfo/vwnc
Reply | Threaded
Open this post in threaded view
|

Re: lost of Control-y

Boris Popov, DeepCove Labs (SNN)
Jim,

Have a look at InputState class>>allProcessInterruptKey (and friends:
#interruptKeyValue,  #warpToLauncherKeyCode) which return nil when the
system is built for runtime. There was a common complaint in the past
that these development shortcuts were available in runtime-built images,
so I believe this was a low enough level where it could be addressed.
There doesn't seem to be a clean hook to re-enable this functionality,
so you may need an override or two in this area to achieve the desired
result.

Hope this helps,

-Boris

-----Original Message-----
From: [hidden email] [mailto:[hidden email]] On
Behalf Of Jim Harsh
Sent: 04 May 2011 13:06
To: [hidden email]
Subject: [vwnc] lost of Control-y


I seem to have lost the ability to interrupt a process using Control-y
in the user version of my application. I'm running VW7.7.1 In our
application there are various sections code that can run for a long
time. To give the user the ability to interrupt the process for what
ever reason we have sections of code wrapped as follows:

        (Core.Object userInterruptSignal)
                handle:
                        [:ex| self restoreParametersAfterUserInterrupt.
                        self setToNilAndGarbageCollect.
                        self propagateClearingOfStatusFlags.
                        self propagateClearingOfAdjointStatusFlags.
                        messages value: 'I halted because you
interrupted me...'.
                        Dialog warn: 'User Interruption of
Optimization'.
                        ex return]
                do:
                        [self optimizeBegin]



In the developer version this works find, hitting Control-y interrupts
the process, pops the Dialog and every thing is fine.

However after I Runtimepackage the application, control-y doesn't cause
the userInteruptSignal to be raised on Windows. (XP and Windows 7),
Linux 32 nor Linux 64. However on my Linux 32 (debian) and Linux
64 (Redhat) control-` raises the signal. control-` does not raise the
signal on Windows.

During the Runtime packaging, I tested the application figuring if I
missed something that should be kept, I would get a dynamic reference so
I could go back and add it but Control-y raised the signal with no
dynamic references posted.

What am I missing during the packaging procedure to keep the control-y
functionality?

Thanks

_______________________________________________
vwnc mailing list
[hidden email]
http://lists.cs.uiuc.edu/mailman/listinfo/vwnc

_______________________________________________
vwnc mailing list
[hidden email]
http://lists.cs.uiuc.edu/mailman/listinfo/vwnc
Reply | Threaded
Open this post in threaded view
|

Re: lost of Control-y

jarober
Alternatively, package without RuntimePackager and trap those keyboard entries any way you want.  That's how I package

On May 4, 2011, at 1:18 PM, Boris Popov, DeepCove Labs wrote:

> Jim,
>
> Have a look at InputState class>>allProcessInterruptKey (and friends:
> #interruptKeyValue,  #warpToLauncherKeyCode) which return nil when the
> system is built for runtime. There was a common complaint in the past
> that these development shortcuts were available in runtime-built images,
> so I believe this was a low enough level where it could be addressed.
> There doesn't seem to be a clean hook to re-enable this functionality,
> so you may need an override or two in this area to achieve the desired
> result.
>
> Hope this helps,
>
> -Boris
>
> -----Original Message-----
> From: [hidden email] [mailto:[hidden email]] On
> Behalf Of Jim Harsh
> Sent: 04 May 2011 13:06
> To: [hidden email]
> Subject: [vwnc] lost of Control-y
>
>
> I seem to have lost the ability to interrupt a process using Control-y
> in the user version of my application. I'm running VW7.7.1 In our
> application there are various sections code that can run for a long
> time. To give the user the ability to interrupt the process for what
> ever reason we have sections of code wrapped as follows:
>
> (Core.Object userInterruptSignal)
> handle:
> [:ex| self restoreParametersAfterUserInterrupt.
> self setToNilAndGarbageCollect.
> self propagateClearingOfStatusFlags.
> self propagateClearingOfAdjointStatusFlags.
> messages value: 'I halted because you
> interrupted me...'.
> Dialog warn: 'User Interruption of
> Optimization'.
> ex return]
> do:
> [self optimizeBegin]
>
>
>
> In the developer version this works find, hitting Control-y interrupts
> the process, pops the Dialog and every thing is fine.
>
> However after I Runtimepackage the application, control-y doesn't cause
> the userInteruptSignal to be raised on Windows. (XP and Windows 7),
> Linux 32 nor Linux 64. However on my Linux 32 (debian) and Linux
> 64 (Redhat) control-` raises the signal. control-` does not raise the
> signal on Windows.
>
> During the Runtime packaging, I tested the application figuring if I
> missed something that should be kept, I would get a dynamic reference so
> I could go back and add it but Control-y raised the signal with no
> dynamic references posted.
>
> What am I missing during the packaging procedure to keep the control-y
> functionality?
>
> Thanks
>
> _______________________________________________
> vwnc mailing list
> [hidden email]
> http://lists.cs.uiuc.edu/mailman/listinfo/vwnc
>
> _______________________________________________
> vwnc mailing list
> [hidden email]
> http://lists.cs.uiuc.edu/mailman/listinfo/vwnc

James Robertson
http://www.jarober.com
[hidden email]




_______________________________________________
vwnc mailing list
[hidden email]
http://lists.cs.uiuc.edu/mailman/listinfo/vwnc
Reply | Threaded
Open this post in threaded view
|

Re: lost of Control-y

Mark Pirogovsky-3
In reply to this post by Jim Harsh
Jim
In the development environment "InputState interruptKeyValue" return 25
- which is CTRL-Y.
However  the Runtime packager sets that value to 0 as follows:

InputState interruptKeyValue:(Character value:0 ).

If you can somehow set this value back to 25, while stripping an Image,  
you should be OK.

My 2C.

--Mark Pirogovsky

Jim Harsh wrote:

> I seem to have lost the ability to interrupt a process using
> Control-y in the user version of my application. I'm running VW7.7.1
> In our application there are various sections code that can run for a
> long time. To give the user the ability to interrupt the process for
> what ever reason we have sections of code wrapped as follows:
>
> (Core.Object userInterruptSignal)
> handle:
> [:ex| self restoreParametersAfterUserInterrupt.
> self setToNilAndGarbageCollect.
> self propagateClearingOfStatusFlags.
> self propagateClearingOfAdjointStatusFlags.
> messages value: 'I halted because you interrupted me...'.
> Dialog warn: 'User Interruption of Optimization'.
> ex return]
> do:
> [self optimizeBegin]
>
>
>
>
>    

_______________________________________________
vwnc mailing list
[hidden email]
http://lists.cs.uiuc.edu/mailman/listinfo/vwnc
Reply | Threaded
Open this post in threaded view
|

Re: lost of Control-y

Boris Popov, DeepCove Labs (SNN)
Mark,

Please note the first line in the below method,

interruptKeyValue
        "Answer the code for the key that causes an interrupt.  The
interrupt key may be a Character,
        a Symbol naming a function key, or an Integer, representing a
keyboard event that is not
        explicitly recognized by the event machinery"

        RuntimeSystem isRuntime ifTrue: [^nil].
        ^InterruptKey < 0
                ifTrue: [InterruptKey negated]
                ifFalse:
                        [InterruptKey < 16r20000
                                ifTrue: [Character value: InterruptKey]
                                ifFalse: [InterruptKey]].

-Boris

-----Original Message-----
From: [hidden email] [mailto:[hidden email]] On
Behalf Of Mark Pirogovsky
Sent: 04 May 2011 13:52
To: Jim Harsh
Cc: [hidden email]
Subject: Re: [vwnc] lost of Control-y

Jim
In the development environment "InputState interruptKeyValue" return 25
- which is CTRL-Y.
However  the Runtime packager sets that value to 0 as follows:

InputState interruptKeyValue:(Character value:0 ).

If you can somehow set this value back to 25, while stripping an Image,
you should be OK.

My 2C.

--Mark Pirogovsky

Jim Harsh wrote:
> I seem to have lost the ability to interrupt a process using Control-y

> in the user version of my application. I'm running VW7.7.1 In our
> application there are various sections code that can run for a long
> time. To give the user the ability to interrupt the process for what
> ever reason we have sections of code wrapped as follows:
>
> (Core.Object userInterruptSignal)
> handle:
> [:ex| self restoreParametersAfterUserInterrupt.
> self setToNilAndGarbageCollect.
> self propagateClearingOfStatusFlags.
> self propagateClearingOfAdjointStatusFlags.
> messages value: 'I halted because you
interrupted me...'.
> Dialog warn: 'User Interruption of
Optimization'.
> ex return]
> do:
> [self optimizeBegin]
>
>
>
>
>    

_______________________________________________
vwnc mailing list
[hidden email]
http://lists.cs.uiuc.edu/mailman/listinfo/vwnc

_______________________________________________
vwnc mailing list
[hidden email]
http://lists.cs.uiuc.edu/mailman/listinfo/vwnc
Reply | Threaded
Open this post in threaded view
|

Re: lost of Control-y

Boris Popov, DeepCove Labs (SNN)
In reply to this post by Mark Pirogovsky-3
Bah, never mind, that's my own override, oof ;)

-Boris

-----Original Message-----
From: Boris Popov, DeepCove Labs
Sent: 04 May 2011 13:54
To: 'Mark Pirogovsky'; Jim Harsh
Cc: [hidden email]
Subject: RE: [vwnc] lost of Control-y

Mark,

Please note the first line in the below method,

interruptKeyValue
        "Answer the code for the key that causes an interrupt.  The
interrupt key may be a Character,
        a Symbol naming a function key, or an Integer, representing a
keyboard event that is not
        explicitly recognized by the event machinery"

        RuntimeSystem isRuntime ifTrue: [^nil].
        ^InterruptKey < 0
                ifTrue: [InterruptKey negated]
                ifFalse:
                        [InterruptKey < 16r20000
                                ifTrue: [Character value: InterruptKey]
                                ifFalse: [InterruptKey]].

-Boris

-----Original Message-----
From: [hidden email] [mailto:[hidden email]] On
Behalf Of Mark Pirogovsky
Sent: 04 May 2011 13:52
To: Jim Harsh
Cc: [hidden email]
Subject: Re: [vwnc] lost of Control-y

Jim
In the development environment "InputState interruptKeyValue" return 25
- which is CTRL-Y.
However  the Runtime packager sets that value to 0 as follows:

InputState interruptKeyValue:(Character value:0 ).

If you can somehow set this value back to 25, while stripping an Image,
you should be OK.

My 2C.

--Mark Pirogovsky

Jim Harsh wrote:
> I seem to have lost the ability to interrupt a process using Control-y

> in the user version of my application. I'm running VW7.7.1 In our
> application there are various sections code that can run for a long
> time. To give the user the ability to interrupt the process for what
> ever reason we have sections of code wrapped as follows:
>
> (Core.Object userInterruptSignal)
> handle:
> [:ex| self restoreParametersAfterUserInterrupt.
> self setToNilAndGarbageCollect.
> self propagateClearingOfStatusFlags.
> self propagateClearingOfAdjointStatusFlags.
> messages value: 'I halted because you
interrupted me...'.
> Dialog warn: 'User Interruption of
Optimization'.
> ex return]
> do:
> [self optimizeBegin]
>
>
>
>
>    

_______________________________________________
vwnc mailing list
[hidden email]
http://lists.cs.uiuc.edu/mailman/listinfo/vwnc

_______________________________________________
vwnc mailing list
[hidden email]
http://lists.cs.uiuc.edu/mailman/listinfo/vwnc
Reply | Threaded
Open this post in threaded view
|

Re: lost of Control-y

Jim Harsh
In reply to this post by Mark Pirogovsky-3

Thanks All, it's amazing what a couple of quote marks will do in the
"right" spot.


At 11:51 AM 5/4/2011, Mark Pirogovsky wrote:

>Jim
>In the development environment "InputState interruptKeyValue" return
>25 - which is CTRL-Y.
>However  the Runtime packager sets that value to 0 as follows:
>
>InputState interruptKeyValue:(Character value:0 ).
>
>If you can somehow set this value back to 25, while stripping an Image,
>you should be OK.
>
>My 2C.
>
>--Mark Pirogovsky
>
>Jim Harsh wrote:
>>I seem to have lost the ability to interrupt a process using
>>Control-y in the user version of my application. I'm running VW7.7.1
>>In our application there are various sections code that can run for a
>>long time. To give the user the ability to interrupt the process for
>>what ever reason we have sections of code wrapped as follows:
>>
>>         (Core.Object userInterruptSignal)
>>                 handle:
>>                         [:ex| self restoreParametersAfterUserInterrupt.
>>                         self setToNilAndGarbageCollect.
>>                         self propagateClearingOfStatusFlags.
>>                         self propagateClearingOfAdjointStatusFlags.
>>                         messages value: 'I halted because you
>> interrupted me...'.
>>                         Dialog warn: 'User Interruption of Optimization'.
>>                         ex return]
>>                 do:
>>                         [self optimizeBegin]
>>
>>
>>
>>
>>

_______________________________________________
vwnc mailing list
[hidden email]
http://lists.cs.uiuc.edu/mailman/listinfo/vwnc