Thu Nov 12 15:20:15 1998 Jim Ingham <jingham@cygnus.com>
* console.tcl (complete): I added the ability to pass from_tty from gdb_cmd to the underlying commands. Pass 1 when the command is invoked from the console. * interface.tcl (gdbtk_tcl_tstart, gdbtk_tcl_tstop): Run the src window's do_tstop method rather than manipulating the widgets by hand. * src.tcl (build_win): Redo the packing so that the function combobox doesn't push all the other combo-boxes off the screen if it has a very long function name in it. * srcbar.tcl (do_tstop): Added a mode that just changes the GUI, which can be called from console hooks. * srctextwin.tcl: Fixed some bugs I introduced in setting breakpoints in the assembly & mixed mode windows. Dropped the notion of joint breakpoint images for lines that have breakpoints of two separate types. Too fragile. Also added the "dont_change_appearance" flag, used in the continue_to_here method to tell the GUI not to reflect the temporary disabling of all the breakpoints. * toolbar.tcl (insert_buttons): Added a little more error-checking. Thu Nov 12 15:20:15 1998 Jim Ingham <jingham@cygnus.com> * gdbtk-cmds.c (gdb_cmd): Added an optional second argument to the gdb_cmd, which is from_tty. This is passed to the gdb command parser. It is 0 by default, and the console window passes 1. * gdbtk-cmds.c: moved disassemble_from_exec from gdbtk.c to gdbtk-cmds.c with all the other link-var'ed variables * gdbtk-hooks.c (gdbtk_trace_find): Only run the hook functions if we are called from_tty. * gdbtk-hooks.c (gdbtk_trace_start_stop): Set the trace buttons from a trace_start_command callback rather than doing it as a special case in gdb_cmd. * tracepoint.c (tstart_command, tstop_command): Add call to trace_start_stop_hook here.
This commit is contained in:
parent
e9928289d3
commit
2aae63977c
6 changed files with 97 additions and 46 deletions
|
@ -152,6 +152,11 @@ extern struct breakpoint *set_raw_breakpoint (struct symtab_and_line sal);
|
|||
extern void set_breakpoint_count (int);
|
||||
extern int breakpoint_count;
|
||||
|
||||
/* This variable determines where memory used for disassembly is read from.
|
||||
* See note in gdbtk.h for details.
|
||||
*/
|
||||
int disassemble_from_exec = -1;
|
||||
|
||||
|
||||
/*
|
||||
* Declarations for routines exported from this file
|
||||
|
@ -330,6 +335,10 @@ Gdbtk_Init (interp)
|
|||
Tcl_LinkVar (interp, "gdb_context_id",
|
||||
(char *) &gdb_context,
|
||||
TCL_LINK_INT | TCL_LINK_READ_ONLY);
|
||||
|
||||
/* Determine where to disassemble from */
|
||||
Tcl_LinkVar (gdbtk_interp, "disassemble-from-exec", (char *) &disassemble_from_exec,
|
||||
TCL_LINK_INT);
|
||||
|
||||
Tcl_PkgProvide(interp, "Gdbtk", GDBTK_VERSION);
|
||||
return TCL_OK;
|
||||
|
@ -666,13 +675,23 @@ gdb_cmd (clientData, interp, objc, objv)
|
|||
int objc;
|
||||
Tcl_Obj *CONST objv[];
|
||||
{
|
||||
|
||||
int from_tty = 0;
|
||||
|
||||
if (objc < 2)
|
||||
{
|
||||
Tcl_SetStringObj (result_ptr->obj_ptr, "wrong # args", -1);
|
||||
return TCL_ERROR;
|
||||
}
|
||||
|
||||
if (objc == 3)
|
||||
{
|
||||
if (Tcl_GetBooleanFromObj (NULL, objv[2], &from_tty) != TCL_OK) {
|
||||
Tcl_SetStringObj (result_ptr->obj_ptr, "from_tty must be a boolean.",
|
||||
-1);
|
||||
return TCL_ERROR;
|
||||
}
|
||||
}
|
||||
|
||||
if (running_now || load_in_progress)
|
||||
return TCL_OK;
|
||||
|
||||
|
@ -688,7 +707,7 @@ gdb_cmd (clientData, interp, objc, objv)
|
|||
load_in_progress = 1;
|
||||
}
|
||||
|
||||
execute_command (Tcl_GetStringFromObj (objv[1], NULL), 1);
|
||||
execute_command (Tcl_GetStringFromObj (objv[1], NULL), from_tty);
|
||||
|
||||
if (load_in_progress)
|
||||
{
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue