1
0
mirror of https://github.com/lvgl/lvgl.git synced 2025-01-21 06:53:01 +08:00

Merge branch 'dev-7.0' of https://github.com/littlevgl/lvgl into dev-7.0

This commit is contained in:
Gabor Kiss-Vamosi 2019-11-06 12:43:52 +01:00
commit c1aae99208
5 changed files with 13 additions and 3 deletions

View File

@ -1474,8 +1474,6 @@ lv_res_t lv_event_send(lv_obj_t * obj, lv_event_t event, const void * data)
*/ */
lv_res_t lv_event_send_func(lv_event_cb_t event_xcb, lv_obj_t * obj, lv_event_t event, const void * data) lv_res_t lv_event_send_func(lv_event_cb_t event_xcb, lv_obj_t * obj, lv_event_t event, const void * data)
{ {
LV_ASSERT_OBJ(obj, LV_OBJX_NAME);
/* Build a simple linked list from the objects used in the events /* Build a simple linked list from the objects used in the events
* It's important to know if an this object was deleted by a nested event * It's important to know if an this object was deleted by a nested event
* called from this `even_cb`. */ * called from this `even_cb`. */

View File

@ -378,7 +378,7 @@ static void lv_draw_map(const lv_area_t * map_area, const lv_area_t * clip_area,
lv_img_rotate_dsc_t rotate_dsc; lv_img_rotate_dsc_t rotate_dsc;
memset(&rotate_dsc, 0, sizeof(lv_img_rotate_dsc_t)); memset(&rotate_dsc, 0, sizeof(lv_img_rotate_dsc_t));
if(angle) { if(angle) {
lv_img_cf_t cf = LV_IMG_CF_TRUE_COLOR; lv_img_cf_t cf = LV_IMG_CF_TRUE_COLOR;
if(alpha_byte) cf = LV_IMG_CF_TRUE_COLOR_ALPHA; if(alpha_byte) cf = LV_IMG_CF_TRUE_COLOR_ALPHA;

View File

@ -337,6 +337,7 @@ static void lv_draw_letter(const lv_point_t * pos_p, const lv_area_t * clip_area
static void draw_letter_normal(lv_coord_t pos_x, lv_coord_t pos_y, lv_font_glyph_dsc_t * g, const lv_area_t * clip_area, const uint8_t * map_p, lv_color_t color, lv_opa_t opa) static void draw_letter_normal(lv_coord_t pos_x, lv_coord_t pos_y, lv_font_glyph_dsc_t * g, const lv_area_t * clip_area, const uint8_t * map_p, lv_color_t color, lv_opa_t opa)
{ {
const uint8_t * bpp_opa_table; const uint8_t * bpp_opa_table;
uint8_t bitmask_init; uint8_t bitmask_init;
uint8_t bitmask; uint8_t bitmask;

View File

@ -353,6 +353,11 @@ lv_res_t lv_img_decoder_built_in_open(lv_img_decoder_t * decoder, lv_img_decoder
LV_LOG_WARN("Image built-in decoder cannot read file because LV_USE_FILESYSTEM = 0"); LV_LOG_WARN("Image built-in decoder cannot read file because LV_USE_FILESYSTEM = 0");
return LV_RES_INV; return LV_RES_INV;
#endif #endif
} else if(dsc->src_type == LV_IMG_SRC_VARIABLE) {
/*The variables should have valid data*/
if(((lv_img_dsc_t *)dsc->src)->data == NULL) {
return LV_RES_INV;
}
} }
lv_img_cf_t cf = dsc->header.cf; lv_img_cf_t cf = dsc->header.cf;
@ -416,6 +421,7 @@ lv_res_t lv_img_decoder_built_in_open(lv_img_decoder_t * decoder, lv_img_decoder
/*The palette begins in the beginning of the image data. Just point to it.*/ /*The palette begins in the beginning of the image data. Just point to it.*/
lv_color32_t * palette_p = (lv_color32_t *)((lv_img_dsc_t *)dsc->src)->data; lv_color32_t * palette_p = (lv_color32_t *)((lv_img_dsc_t *)dsc->src)->data;
uint32_t i; uint32_t i;
for(i = 0; i < palette_size; i++) { for(i = 0; i < palette_size; i++) {
user_data->palette[i] = lv_color_make(palette_p[i].ch.red, palette_p[i].ch.green, palette_p[i].ch.blue); user_data->palette[i] = lv_color_make(palette_p[i].ch.red, palette_p[i].ch.green, palette_p[i].ch.blue);

View File

@ -1788,6 +1788,11 @@ static void refr_cursor_area(lv_obj_t * ta)
cur_area.x2 = letter_pos.x + cur_style.body.padding.right + letter_w; cur_area.x2 = letter_pos.x + cur_style.body.padding.right + letter_w;
cur_area.y2 = letter_pos.y + cur_style.body.padding.bottom + letter_h + (cur_style.line.width >> 1) + cur_area.y2 = letter_pos.y + cur_style.body.padding.bottom + letter_h + (cur_style.line.width >> 1) +
(cur_style.line.width & 0x1); (cur_style.line.width & 0x1);
} else if(ext->cursor.type == LV_CURSOR_NONE) {
cur_area.x1 = letter_pos.x;
cur_area.y1 = letter_pos.y;
lv_area_set_width(&cur_area, 0);
lv_area_set_height(&cur_area, 0);
} }
/*Save the new area*/ /*Save the new area*/