[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Adding functionality to user defined buttons
From: |
Anand Vaddiraju |
Subject: |
Adding functionality to user defined buttons |
Date: |
Mon, 8 Jul 2002 13:20:09 -0700 (PDT) |
Hi,
I added a button to DDD (with GDB) using the Commands->Define Command menu,
and assigned the following command set to the button:
break $arg0
commands
set variable a=17
end
I am having problems getting this to work because there are nested 'end's when
DDD tries to register the user command with GDB. Therefore I want to hardcode
the functionality attached to this button by changing the source code. What
I want to do is:
1. Define a user-command (and button) that just sets the breakpoint.
2. Whenever the user hits this button, enqueue an additional command that
does:
commands
set variable a=17
end
I tried kludging this in do_gdb_command() (Command.C), by enqueueing
"commands\nset variable a=17\nend" after the user command is enqueued, but I
am running into problems with the queueing mechanism -- the commands being
sent to gdb are not in the same order as the enqueued command.
I now want to do this at a much higher level, at the function which is
called when the user hits a user-defined button. I have had no luck so far
in locating this function. If anyone can point me to it, or can suggest an
alternate strategy, I will greatly appreciate it.
Thanks in advance,
Anand
---------------
Anand Vaddiraju
[Prev in Thread] |
Current Thread |
[Next in Thread] |
- Adding functionality to user defined buttons,
Anand Vaddiraju <=