Fixed bug number 10297.
This commit is contained in:
parent
8d1e130df8
commit
61ccc09bee
|
@ -298,6 +298,7 @@ static void init_Matrix_style(void)
|
|||
}
|
||||
|
||||
|
||||
static lv_obj_t* SelectedImage = NULL;
|
||||
// --------------------------------------------------------------------------
|
||||
// MaxNum
|
||||
// --------------------------------------------------------------------------
|
||||
|
@ -324,10 +325,17 @@ void show_MaxNum_page(lv_obj_t* obj)
|
|||
sprintf(result, "%02d", puiPara->SendMaxNum);
|
||||
MaxNumValueLabel = lv_label_create(obj, NULL);
|
||||
lv_obj_set_pos(MaxNumValueLabel, 145, 93);
|
||||
lv_obj_set_size(MaxNumValueLabel, 30, 24);
|
||||
lv_obj_set_size(MaxNumValueLabel, 32, 24);
|
||||
lv_obj_add_style(MaxNumValueLabel, 0, &gMatrixStylebtn);
|
||||
lv_obj_set_state(MaxNumValueLabel, LV_STATE_DEFAULT);
|
||||
lv_obj_set_state(MaxNumValueLabel, LV_STATE_FOCUSED);
|
||||
lv_label_set_text(MaxNumValueLabel, result);
|
||||
SelectedImage = lv_img_create(obj, NULL);
|
||||
lv_obj_set_hidden(SelectedImage, false);
|
||||
lv_obj_set_click(SelectedImage, false);
|
||||
lv_obj_set_drag(SelectedImage, false);
|
||||
lv_obj_set_size(SelectedImage, 32, 88);
|
||||
lv_img_set_src(SelectedImage, &sf_pwd_down_up);
|
||||
lv_obj_set_pos(SelectedImage, 145, 62);
|
||||
}
|
||||
|
||||
void hidde_MaxNum_page(void)
|
||||
|
@ -342,6 +350,11 @@ void hidde_MaxNum_page(void)
|
|||
lv_obj_del(MaxNumValueLabel);
|
||||
MaxNumValueLabel = NULL;
|
||||
}
|
||||
if(SelectedImage)
|
||||
{
|
||||
lv_obj_del(SelectedImage);
|
||||
SelectedImage = NULL;
|
||||
}
|
||||
}
|
||||
|
||||
void Option_MaxNum_Key(lv_obj_t* obj, uint32_t key)
|
||||
|
@ -364,7 +377,7 @@ void Option_MaxNum_Key(lv_obj_t* obj, uint32_t key)
|
|||
puiPara->SendMaxNum--;
|
||||
else
|
||||
puiPara->SendMaxNum = 99;
|
||||
sprintf(result, "%d", puiPara->SendMaxNum);
|
||||
sprintf(result, "%02d", puiPara->SendMaxNum);
|
||||
lv_label_set_text(MaxNumValueLabel, result);
|
||||
break;
|
||||
case LV_USER_KEY_PREV:
|
||||
|
@ -373,7 +386,7 @@ void Option_MaxNum_Key(lv_obj_t* obj, uint32_t key)
|
|||
puiPara->SendMaxNum++;
|
||||
else
|
||||
puiPara->SendMaxNum = 1;
|
||||
sprintf(result, "%d", puiPara->SendMaxNum);
|
||||
sprintf(result, "%02d", puiPara->SendMaxNum);
|
||||
lv_label_set_text(MaxNumValueLabel, result);
|
||||
break;
|
||||
case LV_USER_KEY_LEFT:
|
||||
|
@ -438,7 +451,6 @@ static const char* SendTimeMap_1[BUTTON_NUM_4] =
|
|||
// static int CameraInfoIndex = 0;
|
||||
// static lv_obj_t *CameraInfolabel = NULL;
|
||||
static lv_obj_t *SendTypeImage = NULL;
|
||||
static lv_obj_t* SelectedImage = NULL;
|
||||
static lv_obj_t * btnm = NULL;
|
||||
static const char * map[] = {"1", "2", ""};
|
||||
|
||||
|
@ -493,7 +505,6 @@ void show_send_time_page(lv_obj_t* obj, const int sendType)
|
|||
SendTimeMatrixObj_1 = NULL;
|
||||
SendTimeMatrixObj_0 = NULL;
|
||||
btnm = NULL;
|
||||
SelectedImage = NULL;
|
||||
|
||||
init_Matrix_style();
|
||||
|
||||
|
|
Loading…
Reference in New Issue
Block a user