예제 #1
0
CMDERR debug_console_execute_command(running_machine &machine, const char *command, int echo)
{
	CMDERR result;

	/* echo if requested */
	if (echo)
		debug_console_printf(machine, ">%s\n", command);

	/* parse and execute */
	result = internal_parse_command(machine, command, TRUE);

	/* display errors */
	if (result != CMDERR_NONE)
	{
		if (!echo)
			debug_console_printf(machine, ">%s\n", command);
		debug_console_printf(machine, " %*s^\n", CMDERR_ERROR_OFFSET(result), "");
		debug_console_printf(machine, "%s\n", debug_cmderr_to_string(result));
	}

	/* update all views */
	if (echo)
	{
		machine.debug_view().update_all();
		debugger_refresh_display(machine);
	}
	return result;
}
예제 #2
0
파일: debugint.c 프로젝트: h0tw1r3/mewui
	DView(render_target *target, running_machine &machine, debug_view_type type, int flags)
		: next(NULL),
			type(0),
			state(0),
			ofs_x(0),
			ofs_y(0)
		{
		this->target = target;
		//dv->container = render_target_get_component_container(target, name, &pos);
		this->container = target->debug_alloc();
		this->view = machine.debug_view().alloc_view(type, dview_update, this);
		this->type = type;
		this->m_machine = &machine;
		this->state = flags | VIEW_STATE_NEEDS_UPDATE;

		// initial size
		this->bounds.set(0, 300, 0, 300);

		/* specials */
		switch (type)
		{
		case DVT_DISASSEMBLY:
			/* set up disasm view */
			downcast<debug_view_disasm *>(this->view)->set_expression("curpc");
			//debug_view_  property_UINT32(dv->view, DVP_DASM_TRACK_LIVE, 1);
			break;
		default:
			break;
		}
		}
예제 #3
0
	debug_area(running_machine &machine, debug_view_type type)
		: next(nullptr),
			type(0),
			ofs_x(0),
			ofs_y(0),
			is_collapsed(false),
			exec_cmd(false),
			scroll_end(false),
			scroll_follow(false)
		{
		this->view = machine.debug_view().alloc_view(type, nullptr, this);
		this->type = type;
		this->m_machine = &machine;
		this->width = 300;
		this->height = 300;
		this->console_prev.clear();

		/* specials */
		switch (type)
		{
		case DVT_DISASSEMBLY:
			/* set up disasm view */
			downcast<debug_view_disasm *>(this->view)->set_expression("curpc");
			break;
		default:
			break;
		}
		}
예제 #4
0
void debug_errorlog_write_line(running_machine &machine, const char *line)
{
	if (errorlog_textbuf)
		text_buffer_print(errorlog_textbuf, line);

	/* force an update of any log views */
	machine.debug_view().update_all(DVT_LOG);
}
예제 #5
0
void CLIB_DECL debug_console_vprintf(running_machine &machine, const char *format, va_list args)
{
	astring buffer;

	buffer.vprintf(format, args);
	text_buffer_print(console_textbuf, buffer);

	/* force an update of any console views */
	machine.debug_view().update_all(DVT_CONSOLE);
}
예제 #6
0
void CLIB_DECL debug_console_printf_wrap(running_machine &machine, int wrapcol, const char *format, ...)
{
	astring buffer;
	va_list arg;

	va_start(arg, format);
	buffer.vprintf(format, arg);
	va_end(arg);

	text_buffer_print_wrap(console_textbuf, buffer, wrapcol);

	/* force an update of any console views */
	machine.debug_view().update_all(DVT_CONSOLE);
}