[plt-scheme] Distinguishing between pressing Run or Debug button in a tool

From: Gregory Cooper (greg at cs.brown.edu)
Date: Wed Jul 9 08:04:13 EDT 2008

I'm not sure I understand.  The debug button is itself part of a tool,
not part of the standard DrScheme interface, so writing another tool
that assumes it's there seems problematic.  Am I missing something?

Robby, your change certainly simplifies things, but it looks to me
like the execute-callback will still be invoked along the main path
through debug-callback.  Again, maybe I'm misunderstanding what the
problem is.

In general, my impression was "debugging = extra setup + execution",
so I don't see how to avoid making the debug button do everything the
execute button does (and then some).

Greg

On Wed, Jul 9, 2008 at 7:31 AM, Robby Findler <robby at cs.uchicago.edu> wrote:
> Looking over the code debugger's code, I don't see why it is written
> like that. I have changed it to something that doesn't make the docs
> lie, but if one of the maintainers of the debugger were to check it
> over, that would be a good thing. (This is revision 10695.)
>
> Thanks,
> Robby
>
> On Wed, Jul 9, 2008 at 2:12 AM, Robert Matovinovic
> <robert.matovinovic at web.de> wrote:
>> Hi,
>> In creating a language tool so far I found no way to distinguish if the
>> debug or the run button was pressed. My tool overrides the execute-callback
>> function of drscheme:unit:frame% and is called whenever Run or Debug is
>> pressed. However the documentation says only it is called, when the Run
>> button is pressed. This is just for information no complaint about the
>> behaviour, because I want to do different things before debugging or run.
>> Only that I can't do it the way I thought because I don't find a method like
>> is-clicked? or on-click for a switchable-button which would give me the
>> opportunity to know which one invoked the callback functions. Did I miss
>> something?
>> Thanks for your suggestions.
>>
>> Robert
>>
>> _________________________________________
>> Robert Matovinovic
>> Wintererstr. 61
>> 79104 Freiburg
>> Germany
>>
>> Tel:    +49 (0)761 51 93 544
>> Cell:   +49 (0)171 56 32 330
>> email: robert.matovinovic at web.de
>>
>> _________________________________________________
>>  For list-related administrative tasks:
>>  http://list.cs.brown.edu/mailman/listinfo/plt-scheme
>>
>>
> _________________________________________________
>  For list-related administrative tasks:
>  http://list.cs.brown.edu/mailman/listinfo/plt-scheme
>


Posted on the users mailing list.