mirror of
https://git.planet-casio.com/Lephenixnoir/gint.git
synced 2024-12-28 04:23:36 +01:00
gdb: add icons on mono (bypassing video intf for now)
This commit is contained in:
parent
0afd05848a
commit
d065a17063
1 changed files with 11 additions and 1 deletions
|
@ -5,6 +5,8 @@
|
||||||
#include <gint/usb-ff-bulk.h>
|
#include <gint/usb-ff-bulk.h>
|
||||||
#include <gint/usb.h>
|
#include <gint/usb.h>
|
||||||
#include <gint/video.h>
|
#include <gint/video.h>
|
||||||
|
#include <gint/display.h>
|
||||||
|
#include <gint/config.h>
|
||||||
|
|
||||||
#include <ctype.h>
|
#include <ctype.h>
|
||||||
#include <stdio.h>
|
#include <stdio.h>
|
||||||
|
@ -19,11 +21,16 @@ enum { ICON_WORKING, ICON_ERROR, ICON_COMM, ICON_IDLE };
|
||||||
|
|
||||||
static void gdb_show_stub_status(int icon)
|
static void gdb_show_stub_status(int icon)
|
||||||
{
|
{
|
||||||
|
// TODO[3]: Use normal way for both fx and cg (and remove display.h include)
|
||||||
|
#if GINT_RENDER_MONO
|
||||||
|
extern bopti_image_t gint_gdb_icons_i1msb;
|
||||||
|
dsubimage(120, 0, &gint_gdb_icons_i1msb, 8*icon, 0, 8, 5, DIMAGE_NONE);
|
||||||
|
dupdate();
|
||||||
|
#else
|
||||||
video_mode_t const *M = video_get_current_mode();
|
video_mode_t const *M = video_get_current_mode();
|
||||||
if(!M)
|
if(!M)
|
||||||
return;
|
return;
|
||||||
|
|
||||||
// extern image_t gint_gdb_icons_i1msb;
|
|
||||||
extern image_t gint_gdb_icons_rgb565;
|
extern image_t gint_gdb_icons_rgb565;
|
||||||
|
|
||||||
if(M->format == IMAGE_RGB565) {
|
if(M->format == IMAGE_RGB565) {
|
||||||
|
@ -32,6 +39,7 @@ static void gdb_show_stub_status(int icon)
|
||||||
if(!video_update(M->width-7, 0, &sub, 0))
|
if(!video_update(M->width-7, 0, &sub, 0))
|
||||||
abort();
|
abort();
|
||||||
}
|
}
|
||||||
|
#endif
|
||||||
}
|
}
|
||||||
|
|
||||||
#else
|
#else
|
||||||
|
@ -722,6 +730,8 @@ int gdb_start(void)
|
||||||
if (gdb_started)
|
if (gdb_started)
|
||||||
return 0;
|
return 0;
|
||||||
|
|
||||||
|
gdb_show_stub_status(ICON_WORKING);
|
||||||
|
|
||||||
if(usb_is_open() && !usb_is_open_interface(&usb_ff_bulk))
|
if(usb_is_open() && !usb_is_open_interface(&usb_ff_bulk))
|
||||||
usb_close();
|
usb_close();
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue