ui: Refactor

This commit is contained in:
Matt Borgerson
2020-05-04 07:24:05 -07:00
parent b4f2267101
commit c02c245e0f
5 changed files with 148 additions and 155 deletions
-1
View File
@@ -26,7 +26,6 @@ endif
# Override with xemu UI
sdl.mo-objs := \
imgui/imgui.o \
imgui/imgui_demo.o \
imgui/imgui_draw.o \
imgui/imgui_widgets.o \
imgui/examples/imgui_impl_opengl3.o \
+139 -148
View File
File diff suppressed because it is too large Load Diff
+2 -2
View File
@@ -102,9 +102,9 @@ void xemu_run_monitor_command(const char *cmd)
int len = strlen(cmd)+1;
/* FIXME: qemu_chr_be_write needs to be fixed to declare inbuf as const. It
* does not modify the data. Accept the warning for now as a reminder.
* does not modify the data. Cast for now.
*/
qemu_chr_be_write(mon_chr, cmd, len);
qemu_chr_be_write(mon_chr, (unsigned char*)cmd, len);
}
static const TypeInfo char_xemu_type_info = {
+5 -1
View File
@@ -69,6 +69,10 @@ const char *xemu_get_os_info(void)
void xemu_open_web_browser(const char *url)
{
char *cmd = g_strdup_printf("xdg-open %s", url);
system(cmd);
int status = system(cmd);
if (status < 0) {
fprintf(stderr, "Failed to run: %s\n", cmd);
}
free(cmd);
}
+2 -3
View File
@@ -1420,9 +1420,8 @@ static void post_swap(void)
}
}
// #undef main
int main(int argc, char **argv) {
int main(int argc, char **argv)
{
QemuThread thread;
DPRINTF("Entered main()\n");