Skip to content

Commit b84cd92

Browse files
committed
update icon
1 parent 87aa560 commit b84cd92

14 files changed

+49
-41
lines changed

fw/application/src/app/desktop/view/app_list_view.c

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -50,9 +50,9 @@ static void app_list_view_on_draw(mui_view_t *p_view, mui_canvas_t *p_canvas) {
5050
// icon_x = LV_MAX(icon_x, 0);
5151
// if( i == focus){
5252
// uint8_t icon_w = LV_MIN(ICON_WIDTH, canvas_width - icon_x);
53-
// mui_canvas_draw_box(p_canvas, icon_x, ICON_TOP_MARGIN, 32, 32);
53+
// mui_canvas_draw_box(p_canvas, icon_x, ICON_TOP_MARGIN, ICON_WIDTH, ICON_WIDTH);
5454
// mui_canvas_set_draw_color(p_canvas, 0);
55-
// mui_canvas_draw_xbm(p_canvas, icon_x, ICON_TOP_MARGIN, ICON_WIDTH, ICON_HEIGHT, img);
55+
// mui_canvas_draw_xbm(p_canvas, icon_x, ICON_TOP_MARGIN, ICON_WIDTH, ICON_HEIGHT, app->icon_32x32->data);
5656
// mui_canvas_set_draw_color(p_canvas, 1);
5757
//}else{
5858
if(app->icon_32x32){
@@ -64,7 +64,7 @@ static void app_list_view_on_draw(mui_view_t *p_view, mui_canvas_t *p_canvas) {
6464

6565
// focus
6666
mui_canvas_set_draw_color(p_canvas, 2);
67-
mui_canvas_draw_box(p_canvas, first_offset, ICON_TOP_MARGIN, 32, 32);
67+
mui_canvas_draw_rbox(p_canvas, first_offset, ICON_TOP_MARGIN, 32, 32, 1);
6868
mui_canvas_set_draw_color(p_canvas, 1);
6969

7070
// left selection

fw/application/src/mui/mui_canvas.c

Lines changed: 9 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -44,7 +44,7 @@ int32_t mui_canvas_draw_utf8_clip(mui_canvas_t *p_canvas, int32_t x, int32_t y,
4444
w += utf8_w;
4545
} else {
4646
uint8_t utf8_x = mui_canvas_get_utf8_width(p_canvas, utf8);
47-
xi += utf8_x + 1; //1 pix for margin
47+
xi += utf8_x + 1; // 1 pix for margin
4848
w += utf8_x + 1;
4949
}
5050
p += utf8_size;
@@ -89,6 +89,12 @@ void mui_canvas_draw_box(mui_canvas_t *p_canvas, uint8_t x, uint8_t y, uint8_t w
8989
u8g2_DrawBox(p_canvas->fb, x, y, w, h);
9090
}
9191

92+
void mui_canvas_draw_rbox(mui_canvas_t *p_canvas, uint8_t x, uint8_t y, uint8_t w, uint8_t h, uint8_t radius) {
93+
x += p_canvas->offset_x;
94+
y += p_canvas->offset_y;
95+
u8g2_DrawRBox(p_canvas->fb, x, y, w, h, radius);
96+
}
97+
9298
void mui_canvas_draw_dot(mui_canvas_t *p_canvas, uint8_t x, uint8_t y) {
9399
x += p_canvas->offset_x;
94100
y += p_canvas->offset_y;
@@ -108,7 +114,8 @@ void mui_canvas_draw_xbm(mui_canvas_t *p_canvas, uint8_t x, uint8_t y, uint8_t w
108114
u8g2_DrawXBM(p_canvas->fb, x, y, width, height, bitmap);
109115
}
110116

111-
void mui_canvas_draw_bitmap(mui_canvas_t *p_canvas, uint8_t x, uint8_t y, uint8_t width, uint8_t height, uint8_t *bitmap){
117+
void mui_canvas_draw_bitmap(mui_canvas_t *p_canvas, uint8_t x, uint8_t y, uint8_t width, uint8_t height,
118+
uint8_t *bitmap) {
112119
x += p_canvas->offset_x;
113120
y += p_canvas->offset_y;
114121
u8g2_DrawBitmap(p_canvas->fb, x, y, width, height, bitmap);

fw/application/src/mui/mui_canvas.h

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -36,6 +36,7 @@ void mui_canvas_set_clip_window(mui_canvas_t *p_canvas, mui_rect_t* p_rect);
3636
uint8_t mui_canvas_get_draw_color(mui_canvas_t *p_canvas);
3737
void mui_canvas_set_draw_color(mui_canvas_t *p_canvas, uint8_t color);
3838
void mui_canvas_draw_box(mui_canvas_t *p_canvas, uint8_t x, uint8_t y, uint8_t w, uint8_t h);
39+
void mui_canvas_draw_rbox(mui_canvas_t *p_canvas, uint8_t x, uint8_t y, uint8_t w, uint8_t h, uint8_t radius);
3940
void mui_canvas_draw_dot(mui_canvas_t *p_canvas, uint8_t x, uint8_t y);
4041
void mui_canvas_draw_rframe(mui_canvas_t *p_canvas, uint8_t x, uint8_t y, uint8_t width, uint8_t height,
4142
uint8_t radius);

fw/application/src/mui/mui_resource.c

Lines changed: 36 additions & 36 deletions
Original file line numberDiff line numberDiff line change
@@ -4,15 +4,15 @@
44
//** /resources/bmp/app_amiibo_database_32x32.bmp
55
//************************************************************************
66
const uint8_t app_amiibo_database_32x32_data[] = {
7-
0x00,0x00,0x00,0x00,0x00,0xf0,0x0f,0x00,0x00,0xff,0xff,0x00,0xc0,0x03,0xe0,
8-
0x03,0x70,0x00,0x00,0x07,0x30,0x00,0x00,0x0e,0x18,0x00,0x00,0x0c,0x18,0x00,
9-
0x00,0x0c,0x38,0x00,0x00,0x0c,0x78,0x00,0x00,0x0f,0xf8,0x07,0xf0,0x0f,0x18,
10-
0x1e,0x3e,0x0c,0x18,0xf0,0x01,0x0c,0x18,0x00,0x80,0x0d,0x18,0x00,0x80,0x0d,
11-
0x78,0x00,0x00,0x0e,0xd8,0x01,0xe0,0x0d,0x18,0x7f,0x38,0x0c,0x18,0xc0,0x8f,
12-
0x0d,0x18,0x00,0x80,0x0d,0x38,0x00,0x00,0x0c,0x78,0x00,0x00,0x0f,0xd8,0x03,
13-
0xe0,0x0d,0x18,0x3f,0x3e,0x0c,0x18,0xe0,0x83,0x0d,0x18,0x00,0x80,0x0d,0x30,
14-
0x00,0x00,0x06,0xe0,0x00,0x80,0x03,0x80,0x07,0xf8,0x01,0x00,0x3c,0x3f,0x00,
15-
0x00,0xf0,0x03,0x00,0x00,0x00,0x00,0x00
7+
0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0xf8,0x1f,0x00,0x80,0xff,0xff,
8+
0x01,0xc0,0x0f,0xf0,0x03,0xf0,0x00,0x00,0x0f,0x78,0x00,0x00,0x1e,0x18,0x00,
9+
0x38,0x18,0x18,0x00,0x38,0x18,0x18,0x00,0x38,0x18,0x78,0x00,0x00,0x1e,0xf8,
10+
0x00,0x00,0x1f,0xd8,0x0f,0xf0,0x1b,0x98,0xff,0xff,0x19,0x18,0xf8,0x1f,0x18,
11+
0x18,0x00,0x00,0x18,0x18,0x00,0x00,0x18,0x78,0x00,0x00,0x1e,0xf8,0x00,0x00,
12+
0x1f,0xd8,0x0f,0xf0,0x1b,0x98,0xff,0xff,0x19,0x18,0xf8,0x1f,0x18,0x18,0x00,
13+
0x00,0x18,0x18,0x00,0x00,0x18,0x18,0x00,0x00,0x18,0x78,0x00,0x00,0x1e,0xf0,
14+
0x00,0x00,0x0f,0xc0,0x0f,0xf0,0x03,0x80,0xff,0xff,0x01,0x00,0xf8,0x1f,0x00,
15+
0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00
1616
};
1717
const xbm_t app_amiibo_database_32x32 = {.width = 32, .height = 32, .data = app_amiibo_database_32x32_data};
1818

@@ -38,14 +38,14 @@ const xbm_t app_amiibo_emulator_32x32 = {.width = 32, .height = 32, .data = app_
3838
//** /resources/bmp/app_amiibo_link_32x32.bmp
3939
//************************************************************************
4040
const uint8_t app_amiibo_link_32x32_data[] = {
41-
0x00,0x00,0x00,0x00,0x00,0xc0,0x01,0x00,0x00,0xe0,0x03,0x00,0x00,0xf0,0x0f,
42-
0x00,0x00,0x38,0x1e,0x00,0x00,0x1c,0x38,0x00,0x00,0x0e,0x70,0x00,0x00,0x86,
43-
0x61,0x00,0x00,0x43,0xc2,0x00,0x00,0x23,0xc4,0x00,0x00,0x23,0xc4,0x00,0x00,
44-
0x46,0x62,0x00,0x00,0x86,0x61,0x00,0x00,0x06,0x70,0x00,0x00,0x0e,0x38,0x00,
45-
0x00,0x3c,0x3e,0x00,0x00,0xfc,0x1f,0x00,0x00,0xcc,0x19,0x00,0x00,0x08,0x08,
46-
0x00,0x00,0x18,0x0c,0x00,0x00,0x10,0x04,0x00,0x00,0x30,0x06,0x00,0x00,0xf0,
47-
0x07,0x00,0x00,0xf0,0x07,0x00,0x00,0x70,0x07,0x00,0x00,0x30,0x06,0x00,0x00,
48-
0x70,0x07,0x00,0x00,0xe0,0x03,0x00,0x00,0xc0,0x01,0x00,0x00,0x00,0x00,0x00,
41+
0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0xe0,0x0f,0x00,0x00,0xf8,0x3f,
42+
0x00,0x00,0x3c,0x78,0x00,0x00,0x0e,0xe0,0x00,0x00,0x07,0xc0,0x01,0x80,0x03,
43+
0x80,0x03,0x80,0xc1,0x07,0x03,0xc0,0xe1,0x0f,0x07,0xc0,0x70,0x1c,0x06,0xc0,
44+
0x30,0x18,0x06,0xc0,0x30,0x18,0x06,0xc0,0x70,0x1c,0x06,0xc0,0xe1,0x0f,0x07,
45+
0x80,0xc1,0x07,0x03,0x80,0x03,0x80,0x03,0x00,0x07,0xc0,0x01,0x00,0x0e,0xe0,
46+
0x00,0x00,0x3c,0xf8,0x00,0x00,0xfc,0xff,0x00,0x00,0xfc,0x7f,0x00,0x00,0xd8,
47+
0x77,0x00,0x00,0xf8,0x3f,0x00,0x00,0x70,0x3c,0x00,0x00,0x30,0x18,0x00,0x00,
48+
0x30,0x18,0x00,0x00,0x70,0x1c,0x00,0x00,0xe0,0x0f,0x00,0x00,0xc0,0x07,0x00,
4949
0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00
5050
};
5151
const xbm_t app_amiibo_link_32x32 = {.width = 32, .height = 32, .data = app_amiibo_link_32x32_data};
@@ -57,11 +57,11 @@ const xbm_t app_amiibo_link_32x32 = {.width = 32, .height = 32, .data = app_amii
5757
const uint8_t app_ble_transfer_32x32_data[] = {
5858
0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x80,0x01,0x00,0x00,0x80,0x03,
5959
0x00,0x00,0x80,0x07,0x00,0x00,0x80,0x0f,0x00,0x00,0x80,0x1d,0x00,0x00,0x80,
60-
0x39,0x00,0x00,0x83,0x71,0x00,0x00,0x87,0xe1,0x00,0x00,0x8e,0xe1,0x00,0x00,
61-
0x9c,0x71,0x00,0x00,0xb8,0x39,0x00,0x00,0xf0,0x1d,0x00,0x00,0xe0,0x0f,0x00,
62-
0x00,0xc0,0x07,0x00,0x00,0xc0,0x07,0x00,0x00,0xe0,0x0f,0x00,0x00,0xf0,0x1d,
63-
0x00,0x00,0xb8,0x39,0x00,0x00,0x9c,0x71,0x00,0x00,0x8e,0xe1,0x00,0x00,0x87,
64-
0xe1,0x00,0x00,0x83,0x71,0x00,0x00,0x80,0x39,0x00,0x00,0x80,0x1d,0x00,0x00,
60+
0x39,0x00,0x80,0x81,0x71,0x00,0x80,0x83,0xe1,0x00,0x00,0x87,0xe1,0x00,0x00,
61+
0x8e,0x71,0x00,0x00,0x9c,0x39,0x00,0x00,0xb8,0x1d,0x00,0x00,0xf0,0x0f,0x00,
62+
0x00,0xe0,0x07,0x00,0x00,0xe0,0x07,0x00,0x00,0xf0,0x0f,0x00,0x00,0xb8,0x1d,
63+
0x00,0x00,0x9c,0x39,0x00,0x00,0x8e,0x71,0x00,0x00,0x87,0xe1,0x00,0x80,0x83,
64+
0xe1,0x00,0x80,0x81,0x71,0x00,0x00,0x80,0x39,0x00,0x00,0x80,0x1d,0x00,0x00,
6565
0x80,0x0f,0x00,0x00,0x80,0x07,0x00,0x00,0x80,0x03,0x00,0x00,0x80,0x01,0x00,
6666
0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00
6767
};
@@ -72,14 +72,14 @@ const xbm_t app_ble_transfer_32x32 = {.width = 32, .height = 32, .data = app_ble
7272
//** /resources/bmp/app_card_emulator_32x32.bmp
7373
//************************************************************************
7474
const uint8_t app_card_emulator_32x32_data[] = {
75-
0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0xfc,0xff,0xff,
76-
0x07,0x06,0x00,0x00,0x0c,0x06,0x00,0x00,0x18,0x06,0x00,0x00,0x18,0x06,0x00,
77-
0x00,0x18,0xfe,0xff,0xff,0x1f,0xfe,0xff,0xff,0x1f,0xfe,0xff,0xff,0x1f,0x06,
78-
0x00,0x00,0x18,0x06,0x00,0x00,0x18,0xc6,0xff,0x00,0x18,0x06,0x00,0x00,0x18,
79-
0x06,0x00,0x00,0x18,0x06,0x00,0x00,0x18,0x06,0x00,0x00,0x38,0x06,0x00,0x00,
80-
0x38,0x06,0x00,0x00,0x38,0x0e,0x00,0x00,0x6c,0xfc,0xff,0xff,0x67,0x18,0x00,
81-
0x00,0x60,0x18,0x00,0x00,0x60,0x10,0x00,0x00,0x3e,0x10,0x00,0xf0,0x07,0x10,
82-
0x00,0x3f,0x00,0x30,0xf8,0x03,0x00,0x60,0x1f,0x00,0x00,0xc0,0x01,0x00,0x00,
75+
0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,
76+
0x00,0x00,0x00,0x00,0x00,0xc0,0xff,0xff,0x0f,0xe0,0xff,0xff,0x1f,0x70,0x00,
77+
0x00,0x38,0x30,0x00,0x00,0x30,0xf0,0xff,0xff,0x30,0xf8,0xff,0xff,0x31,0x1c,
78+
0x00,0x80,0x33,0x0c,0x00,0x00,0x33,0x0c,0x00,0x00,0x33,0xec,0xff,0x7f,0x33,
79+
0xec,0xff,0x7f,0x33,0x0c,0x00,0x00,0x33,0x0c,0x00,0x00,0x33,0xcc,0xff,0x00,
80+
0x33,0x0c,0x00,0x3c,0x33,0x0c,0x00,0x7e,0x33,0x0c,0x00,0x7e,0x33,0x0c,0x00,
81+
0x3c,0x3b,0x0c,0x00,0x00,0x1f,0x1c,0x00,0x80,0x0f,0xf8,0xff,0xff,0x01,0xf0,
82+
0xff,0x7f,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,
8383
0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00
8484
};
8585
const xbm_t app_card_emulator_32x32 = {.width = 32, .height = 32, .data = app_card_emulator_32x32_data};
@@ -90,12 +90,12 @@ const xbm_t app_card_emulator_32x32 = {.width = 32, .height = 32, .data = app_ca
9090
//************************************************************************
9191
const uint8_t app_settings_32x32_data[] = {
9292
0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,
93-
0x00,0x00,0xc0,0x03,0x00,0x00,0xe0,0x07,0x00,0x00,0xe0,0x07,0x00,0x00,0xe0,
94-
0x07,0x00,0x80,0xf3,0xcf,0x01,0xc0,0xff,0xff,0x03,0xe0,0xff,0xff,0x07,0xe0,
95-
0xff,0xff,0x07,0xe0,0xff,0xff,0x07,0xe0,0x3f,0xfc,0x07,0xc0,0x1f,0xf8,0x03,
96-
0x80,0x1f,0xf8,0x01,0x80,0x1f,0xf8,0x01,0xc0,0x1f,0xf8,0x03,0xe0,0x3f,0xfc,
97-
0x07,0xe0,0xff,0xff,0x07,0xe0,0xff,0xff,0x07,0xe0,0xff,0xff,0x07,0xc0,0xff,
98-
0xff,0x03,0x80,0xf1,0xcf,0x01,0x00,0xe0,0x07,0x00,0x00,0xe0,0x07,0x00,0x00,
93+
0x00,0x00,0xc0,0x03,0x00,0x00,0xe0,0x07,0x00,0x00,0xf0,0x0f,0x00,0x80,0xf3,
94+
0xcf,0x01,0xc0,0xf7,0xef,0x03,0xe0,0xff,0xff,0x07,0xf0,0xff,0xff,0x0f,0xf0,
95+
0xff,0xff,0x0f,0xf0,0x3f,0xfc,0x0f,0xe0,0x1f,0xf8,0x07,0xc0,0x0f,0xf8,0x03,
96+
0x00,0x0f,0xf0,0x00,0x80,0x0f,0xf0,0x01,0xc0,0x1f,0xf8,0x03,0xe0,0x1f,0xf8,
97+
0x07,0xf0,0x7f,0xfc,0x0f,0xf0,0xff,0xff,0x0f,0xe0,0xff,0xff,0x0f,0xc0,0xff,
98+
0xff,0x07,0xc0,0xf7,0xcf,0x03,0x80,0xf1,0x8f,0x01,0x00,0xf0,0x0f,0x00,0x00,
9999
0xe0,0x07,0x00,0x00,0xc0,0x03,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,
100100
0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00
101101
};
1023 Bytes
Binary file not shown.
716 Bytes
Binary file not shown.
713 Bytes
Binary file not shown.
810 Bytes
Binary file not shown.
1.22 KB
Binary file not shown.
-2 Bytes
Binary file not shown.

0 commit comments

Comments
 (0)