Commit 5a99750b authored by 王雅楠's avatar 王雅楠

🦄 refactor:将同步联系人的显示方式由字库显示修改为数字显示

parent 04acf3aa
......@@ -671,7 +671,11 @@ static uint16_t Bluetooth_num_night[] = {
void AMT630H_GUI_Bluetooth_Information( uint8_t Connect_ON)
{
uint8_t Contect_totalnumber;
DISPLAY_NUM_ST DisplayNumPara;
uint16_t connect_personnumber;
connect_personnumber = BlueToothPhoneData.PhoneBookTotalCount;
Contect_totalnumber = 0;
if(g_u8Display_Mode == ModeDAY)
{
if(g_u8Language == CH)
......@@ -762,67 +766,68 @@ void AMT630H_GUI_Bluetooth_Information( uint8_t Connect_ON)
PackedTransfer_LabelsList( 0x5022,(uint8_t *)BlueToothName, 40);
SetPageText(GRAPHICS_PAGE_0, 0x5022, 570 , 165 , 200, ALIGN_LEFT, 0, TEXT_COLOR(0XFF,0XFF,0XFF,0XFF),TEXT_LINE_OFFSET(1,1));
}
/*遍历同步联系人数组*/
if(PhoneNumberTotal[0] == 0)
{
Contect_totalnumber = 1;
}
else
{
for(int i=0 ; i<20 ; i++ )
{
if(PhoneNumberTotal[i] != 0)
{
Contect_totalnumber++;
}
else
{
break;
}
}
}
/*同步联系人数字显示(字库版)*/
/*同步联系人数字显示*/
if(g_u8Display_Mode == ModeDAY)
{
if(Contect_totalnumber == 1)
if((connect_personnumber >= 0)&&(connect_personnumber < 10))
{
SetPagePic(GRAPHICS_PAGE_0, Pic_0038_590_287); /*【括号】 一位数 */
PackedTransfer_LabelsList( 0x7000,(uint8_t *)PhoneNumberTotal, 20);
SetPageText(GRAPHICS_PAGE_0, 0x7000, 605 , 289 , 200, ALIGN_LEFT, 0, TEXT_COLOR(0,0,0,0XFF),TEXT_LINE_OFFSET(1,1));
DisplayNumPara.x = 605;
DisplayNumPara.MinDigits = 1;
}
else if(Contect_totalnumber == 2)
else if((connect_personnumber >= 10)&&(connect_personnumber < 100))
{
SetPagePic(GRAPHICS_PAGE_0, Pic_0039_583_287); /*【括号】 两位数 */
PackedTransfer_LabelsList( 0x7000,(uint8_t *)PhoneNumberTotal, 20);
SetPageText(GRAPHICS_PAGE_0, 0x7000, 590 , 285 , 200, ALIGN_LEFT, 0, TEXT_COLOR(0,0,0,0XFF),TEXT_LINE_OFFSET(1,1));
DisplayNumPara.x = 612;
DisplayNumPara.MinDigits = 2;
}
else
{
;
}
// else if(Contect_totalnumber == 3)
// {
// SetPagePic(GRAPHICS_PAGE_0, ); /*【括号】 三位数 */
// PackedTransfer_LabelsList( 0x4022,(uint8_t *)PhoneNumberTotal, 40);
// SetPageText(GRAPHICS_PAGE_0, 0x4022, 570 , 165 , 200, ALIGN_LEFT, 0, TEXT_COLOR(0XFF,0XFF,0XFF,0XFF),TEXT_LINE_OFFSET(1,1));
//
// }
DisplayNumPara.NumList = Bluetooth_num_day;
DisplayNumPara.NumInterval = GROUP_PIC_DIR_LEFT | 14;
DisplayNumPara.y = GROUP_PIC_USE_PSD_Y_POS;
DisplayNumPara.DecimalNum = 0;
DisplayNum(GRAPHICS_PAGE_0, &DisplayNumPara, connect_personnumber);
}
else if(g_u8Display_Mode == ModeNIGHT)
{
if(Contect_totalnumber == 1)
if((connect_personnumber >= 0)&&(connect_personnumber < 10))
{
SetPagePic(GRAPHICS_PAGE_0, Pic_0223_590_287); /*【括号】 一位数 */
PackedTransfer_LabelsList( 0x7000,(uint8_t *)PhoneNumberTotal, 20);
SetPageText(GRAPHICS_PAGE_0, 0x7000, 605 , 289 , 200, ALIGN_LEFT, 0, TEXT_COLOR(0XFF,0XFF,0XFF,0XFF),TEXT_LINE_OFFSET(1,1));
DisplayNumPara.x = 605;
DisplayNumPara.MinDigits = 1;
}
else if(Contect_totalnumber == 2)
else if((connect_personnumber >= 10)&&(connect_personnumber < 100))
{
SetPagePic(GRAPHICS_PAGE_0, Pic_0224_583_287); /*【括号】 两位数 */
PackedTransfer_LabelsList( 0x7000,(uint8_t *)PhoneNumberTotal, 20);
SetPageText(GRAPHICS_PAGE_0, 0x7000, 590 , 285 , 200, ALIGN_LEFT, 0, TEXT_COLOR(0XFF,0XFF,0XFF,0XFF),TEXT_LINE_OFFSET(1,1));
DisplayNumPara.x = 612;
DisplayNumPara.MinDigits = 2;
}
else
{
;
}
// else if(Contect_totalnumber == 3)
// {
// SetPagePic(GRAPHICS_PAGE_0, ); /*【括号】 三位数 */
// PackedTransfer_LabelsList( 0x4022,(uint8_t *)PhoneNumberTotal, 40);
// SetPageText(GRAPHICS_PAGE_0, 0x4022, 570 , 165 , 200, ALIGN_LEFT, 0, TEXT_COLOR(0,0,0,0XFF),TEXT_LINE_OFFSET(1,1));
//
// }
DisplayNumPara.NumList = Bluetooth_num_night;
DisplayNumPara.NumInterval = GROUP_PIC_DIR_LEFT | 14;
DisplayNumPara.y = GROUP_PIC_USE_PSD_Y_POS;
DisplayNumPara.DecimalNum = 0;
DisplayNum(GRAPHICS_PAGE_0, &DisplayNumPara, connect_personnumber);
}
}
......@@ -2113,6 +2118,9 @@ static uint16_t Bluetooth_Connect_num_night[] = {
*/
void AMT630H_GUI_Bluetooth_Connect_Setting(Menu_Item_en_t select, uint8_t Connect_ON)
{
DISPLAY_NUM_ST DisplayNumPara;
uint16_t connect_personnumber;
connect_personnumber = BlueToothPhoneData.PhoneBookTotalCount;
uint8_t Contect_totalnumber;
Contect_totalnumber = 0;
if(g_u8Display_Mode == ModeDAY)
......@@ -2263,67 +2271,64 @@ void AMT630H_GUI_Bluetooth_Connect_Setting(Menu_Item_en_t select, uint8_t Connec
PackedTransfer_LabelsList( 0x5022,(uint8_t *)BlueToothName, 40);
SetPageText(GRAPHICS_PAGE_0, 0x5022, 570 , 165 , 200, ALIGN_LEFT, 0, TEXT_COLOR(0XFF,0XFF,0XFF,0XFF),TEXT_LINE_OFFSET(1,1));
}
/*遍历同步联系人数组*/
if(PhoneNumberTotal[0] == 0)
{
Contect_totalnumber = 1;
}
else
{
for(int i=0 ; i<20 ; i++ )
{
if(PhoneNumberTotal[i] != 0)
{
Contect_totalnumber++;
}
else
{
break;
}
}
}
/*同步联系人数字显示(字库版)*/
/*同步联系人数字显示*/
if(g_u8Display_Mode == ModeDAY)
{
if(Contect_totalnumber == 1)
if((connect_personnumber >= 0)&&(connect_personnumber < 10))
{
SetPagePic(GRAPHICS_PAGE_0, Pic_0038_590_287); /*【括号】 一位数 */
PackedTransfer_LabelsList( 0x7000,(uint8_t *)PhoneNumberTotal, 20);
SetPageText(GRAPHICS_PAGE_0, 0x7000, 605 , 289 , 200, ALIGN_LEFT, 0, TEXT_COLOR(0,0,0,0XFF),TEXT_LINE_OFFSET(1,1));
DisplayNumPara.x = 605;
DisplayNumPara.MinDigits = 1;
}
else if(Contect_totalnumber == 2)
else if((connect_personnumber >= 10)&&(connect_personnumber < 100))
{
SetPagePic(GRAPHICS_PAGE_0, Pic_0039_583_287); /*【括号】 两位数 */
PackedTransfer_LabelsList( 0x7000,(uint8_t *)PhoneNumberTotal, 20);
SetPageText(GRAPHICS_PAGE_0, 0x7000, 590 , 285 , 200, ALIGN_LEFT, 0, TEXT_COLOR(0,0,0,0XFF),TEXT_LINE_OFFSET(1,1));
DisplayNumPara.x = 612;
DisplayNumPara.MinDigits = 2;
}
// else if(Contect_totalnumber == 3)
// {
// SetPagePic(GRAPHICS_PAGE_0, ); /*【括号】 三位数 */
// PackedTransfer_LabelsList( 0x4022,(uint8_t *)PhoneNumberTotal, 40);
// SetPageText(GRAPHICS_PAGE_0, 0x4022, 570 , 165 , 200, ALIGN_LEFT, 0, TEXT_COLOR(0XFF,0XFF,0XFF,0XFF),TEXT_LINE_OFFSET(1,1));
//
// }
DisplayNumPara.NumList = Bluetooth_num_day;
DisplayNumPara.NumInterval = GROUP_PIC_DIR_LEFT | 14;
DisplayNumPara.y = GROUP_PIC_USE_PSD_Y_POS;
DisplayNumPara.DecimalNum = 0;
DisplayNum(GRAPHICS_PAGE_0, &DisplayNumPara, connect_personnumber);
}
else if(g_u8Display_Mode == ModeNIGHT)
{
if(Contect_totalnumber == 1)
if((connect_personnumber >= 0)&&(connect_personnumber < 10))
{
SetPagePic(GRAPHICS_PAGE_0, Pic_0223_590_287); /*【括号】 一位数 */
PackedTransfer_LabelsList( 0x7000,(uint8_t *)PhoneNumberTotal, 20);
SetPageText(GRAPHICS_PAGE_0, 0x7000, 605 , 289 , 200, ALIGN_LEFT, 0, TEXT_COLOR(0XFF,0XFF,0XFF,0XFF),TEXT_LINE_OFFSET(1,1));
DisplayNumPara.x = 605;
DisplayNumPara.MinDigits = 1;
}
else if(Contect_totalnumber == 2)
else if((connect_personnumber >= 10)&&(connect_personnumber < 100))
{
SetPagePic(GRAPHICS_PAGE_0, Pic_0224_583_287); /*【括号】 两位数 */
PackedTransfer_LabelsList( 0x7000,(uint8_t *)PhoneNumberTotal, 20);
SetPageText(GRAPHICS_PAGE_0, 0x7000, 590 , 285 , 200, ALIGN_LEFT, 0, TEXT_COLOR(0XFF,0XFF,0XFF,0XFF),TEXT_LINE_OFFSET(1,1));
DisplayNumPara.x = 612;
DisplayNumPara.MinDigits = 2;
}
else
{
;
}
// else if(Contect_totalnumber == 3)
// {
// SetPagePic(GRAPHICS_PAGE_0, ); /*【括号】 三位数 */
// PackedTransfer_LabelsList( 0x4022,(uint8_t *)PhoneNumberTotal, 40);
// SetPageText(GRAPHICS_PAGE_0, 0x4022, 570 , 165 , 200, ALIGN_LEFT, 0, TEXT_COLOR(0,0,0,0XFF),TEXT_LINE_OFFSET(1,1));
//
// }
DisplayNumPara.NumList = Bluetooth_num_night;
DisplayNumPara.NumInterval = GROUP_PIC_DIR_LEFT | 14;
DisplayNumPara.y = GROUP_PIC_USE_PSD_Y_POS;
DisplayNumPara.DecimalNum = 0;
DisplayNum(GRAPHICS_PAGE_0, &DisplayNumPara, connect_personnumber);
}
}
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment