gengxin
authorCCC <2393524978@qq.com>
Tue, 15 Aug 2023 10:07:20 +0000 (18:07 +0800)
committerCCC <2393524978@qq.com>
Tue, 15 Aug 2023 10:07:20 +0000 (18:07 +0800)
2.sdk/sdk/gui/lv_watch/lv_apps/health_measure/health_measure.c
2.sdk/sdk/gui/lv_watch/lv_apps/lowbattery/lowbattery.c
2.sdk/sdk/gui/lv_watch/lv_apps/mmi_video_call/mmi_video_call.c
2.sdk/sdk/gui/lv_watch/lv_apps/mmi_video_call/mmi_video_call_fzd.c
2.sdk/sdk/gui/lv_watch/lv_apps/mmi_wechat/wechat.h
2.sdk/sdk/gui/lv_watch/lv_apps/mmi_wechat/wechat_ui.c
2.sdk/sdk/gui/lv_watch/lv_apps/phonebook/phonebook.c
2.sdk/sdk/gui/lv_watch/lv_watch.c
2.sdk/sdk/gui/lv_watch/lv_watch_common.c
2.sdk/sdk/gui/lv_watch/mmi_default.h

index 995185f..a739c3c 100644 (file)
@@ -116,15 +116,15 @@ bool mmi_health_measure_heart_data_process(uint16_t * heart_value)
        srand(Hal_Timer_Get_Counter());
        t_value = 50 + rand() % 150;
 
+#else
+       mmi_hsensor_heart_value_get(&t_value);
+#endif
+
        if(220 < t_value)
                t_value = 220;
        else if(50 > t_value)
                t_value = 50;
 
-#else
-       mmi_hsensor_heart_value_get(&t_value);
-#endif
-
        HEALTH_MEASURE_DEBUG_PRINTF("[@CHENG_DEBUG][%s][%d]: %d\n", __FUNCTION__, __LINE__, t_value);
        * heart_value = t_value;
 
@@ -279,16 +279,26 @@ void mmi_health_measure_timed_list_node_add(MMI_HEALTH_MEASURE_TYPE_E measure_ty
        * new_node = measure_type;
 }
 
-void mmi_health_measure_timed_list_trigger(void)
+static bool mmi_health_measure_timed_list_trigger(MMI_HEALTH_MEASURE_TYPE_E measure_type)
 {
        if(true == _lv_ll_is_empty(&s_health_measure_timed_ll))
-               return;
+               return false;
 
     MMI_HEALTH_MEASURE_TYPE_E * node = _lv_ll_get_tail(&s_health_measure_timed_ll);
        if(NULL == node)
-               return;
+               return false;
+
+       lv_obj_t * activity_obj = lv_watch_get_activity_obj(ACT_ID_FACTORY_MODE_TEST);
+       if(NULL != activity_obj)
+               return false;
 
+       HEALTH_MEASURE_DEBUG_PRINTF("[@CHENG_DEBUG][%s][%d]: %d,%d\n", __FUNCTION__, __LINE__, measure_type, * node);
+
+       if(measure_type != * node)
+               return false;
+       
        mmi_health_measure_timed_measure_start(* node);
+       return true;
 }
 
 void mmi_health_measure_timed_time_stamp_set(MMI_HEALTH_MEASURE_TYPE_E measure_type, uint32_t time_stamp)
@@ -323,9 +333,13 @@ bool mmi_health_measure_heart_timed_action(bool direct_trigger, uint32_t cur_tim
                if(true == direct_trigger 
                        || s_health_measure_timed_data.heart_timed_interval <= (cur_time_stamp - s_health_measure_heart_timed_time_stamp))
                {
+                       HEALTH_MEASURE_DEBUG_PRINTF("[@CHENG_DEBUG][%s][%d]: \n", __FUNCTION__, __LINE__);
+                       
                        mmi_health_measure_timed_list_node_add(MMI_HEALTH_MEASURE_HEART);
-                       mmi_health_measure_timed_list_trigger();
-                       mmi_health_measure_timed_time_stamp_set(MMI_HEALTH_MEASURE_HEART, cur_time_stamp);
+                       if(true == mmi_health_measure_timed_list_trigger(MMI_HEALTH_MEASURE_HEART))
+                       {
+                               mmi_health_measure_timed_time_stamp_set(MMI_HEALTH_MEASURE_HEART, cur_time_stamp);
+                       }
 
                        return true;
                }
@@ -341,9 +355,13 @@ bool mmi_health_measure_temperature_timed_action(bool direct_trigger, uint32_t c
                if(true == direct_trigger 
                        || s_health_measure_timed_data.temperature_timed_interval <= (cur_time_stamp - s_health_measure_temperature_timed_time_stamp))
                {
+                       HEALTH_MEASURE_DEBUG_PRINTF("[@CHENG_DEBUG][%s][%d]: \n", __FUNCTION__, __LINE__);
+                       
                        mmi_health_measure_timed_list_node_add(MMI_HEALTH_MEASURE_TEMPERATURE);
-                       mmi_health_measure_timed_list_trigger();
-                       mmi_health_measure_timed_time_stamp_set(MMI_HEALTH_MEASURE_TEMPERATURE, cur_time_stamp);
+                       if(true == mmi_health_measure_timed_list_trigger(MMI_HEALTH_MEASURE_TEMPERATURE))
+                       {
+                               mmi_health_measure_timed_time_stamp_set(MMI_HEALTH_MEASURE_TEMPERATURE, cur_time_stamp);
+                       }
 
                        return true;
                }
@@ -360,8 +378,10 @@ bool mmi_health_measure_blood_timed_action(bool direct_trigger, uint32_t cur_tim
                        || s_health_measure_timed_data.blood_timed_interval <= (cur_time_stamp - s_health_measure_blood_timed_time_stamp))
                {
                        mmi_health_measure_timed_list_node_add(MMI_HEALTH_MEASURE_BLOOD);
-                       mmi_health_measure_timed_list_trigger();
-                       mmi_health_measure_timed_time_stamp_set(MMI_HEALTH_MEASURE_BLOOD, cur_time_stamp);
+                       if(true == mmi_health_measure_timed_list_trigger(MMI_HEALTH_MEASURE_BLOOD))
+                       {
+                               mmi_health_measure_timed_time_stamp_set(MMI_HEALTH_MEASURE_BLOOD, cur_time_stamp);
+                       }
 
                        return true;
                }
@@ -379,8 +399,10 @@ bool mmi_health_measure_spo2_timed_action(bool direct_trigger, uint32_t cur_time
                        )
                {
                        mmi_health_measure_timed_list_node_add(MMI_HEALTH_MEASURE_SPO2);
-                       mmi_health_measure_timed_list_trigger();
-                       mmi_health_measure_timed_time_stamp_set(MMI_HEALTH_MEASURE_SPO2, cur_time_stamp);
+                       if(true == mmi_health_measure_timed_list_trigger(MMI_HEALTH_MEASURE_SPO2))
+                       {
+                               mmi_health_measure_timed_time_stamp_set(MMI_HEALTH_MEASURE_SPO2, cur_time_stamp);
+                       }
 
                        return true;
                }
@@ -503,7 +525,10 @@ void mmi_health_measure_send_heart(void)
        uint16_t heart_value = s_health_measure_run_data.heart_value;
 
        if(0 == heart_value)
+       {
+               HEALTH_MEASURE_DEBUG_PRINTF("[@CHENG_DEBUG][%s][%d]: \n", __FUNCTION__, __LINE__);
                return;
+       }
        
        mmi_protocol_action_send_heart(heart_value);
 
@@ -518,7 +543,10 @@ void mmi_health_measure_send_temperature(void)
        float body_value = s_health_measure_run_data.body_value;
 
        if(0.0 == body_value)
+       {
+               HEALTH_MEASURE_DEBUG_PRINTF("[@CHENG_DEBUG][%s][%d]: \n", __FUNCTION__, __LINE__);
                return;
+       }
        
        mmi_protocol_action_send_temperature(body_value);
 
@@ -534,7 +562,10 @@ void mmi_health_measure_send_blood(void)
        uint16_t blood_low_value = s_health_measure_run_data.blood_low_value;
 
        if(0 == blood_high_value || 0 == blood_low_value)
+       {
+               HEALTH_MEASURE_DEBUG_PRINTF("[@CHENG_DEBUG][%s][%d]: \n", __FUNCTION__, __LINE__);
                return;
+       }
        
        mmi_protocol_action_send_blood(blood_high_value, blood_low_value);
 
@@ -550,7 +581,10 @@ void mmi_health_measure_send_spo2(void)
        uint16_t spo2_value = s_health_measure_run_data.spo2_value;
 
        if(0 == spo2_value)
+       {
+               HEALTH_MEASURE_DEBUG_PRINTF("[@CHENG_DEBUG][%s][%d]: \n", __FUNCTION__, __LINE__);
                return;
+       }
        
        mmi_protocol_action_send_spo2(spo2_value);
 
@@ -572,6 +606,8 @@ void mmi_health_measure_process_timer_stop(void)
 
 void mmi_health_measure_process_finish(void)
 {
+       HEALTH_MEASURE_DEBUG_PRINTF("[@CHENG_DEBUG][%s][%d]: \n", __FUNCTION__, __LINE__);
+       
        s_health_measure_run_data.measure_state = MMI_HEALTH_MEASURE_STATE_FINISH;
        s_measure_time_count = 0;
        s_measure_time_total = 0;
@@ -681,7 +717,7 @@ void mmi_health_measure_interrupt(void)
        s_health_measure_run_data.measure_type = MMI_HEALTH_MEASURE_NONE;
 }
 
-void mmi_health_measure_start(MMI_HEALTH_MEASURE_TYPE_E measure_type, uint32_t time_duration)
+static void mmi_health_measure_start(MMI_HEALTH_MEASURE_TYPE_E measure_type, uint32_t time_duration)
 {
        HEALTH_MEASURE_DEBUG_PRINTF("[@CHENG_DEBUG][%s][%d]: \n", __FUNCTION__, __LINE__);
        
@@ -721,6 +757,7 @@ void mmi_health_measure_start(MMI_HEALTH_MEASURE_TYPE_E measure_type, uint32_t t
        s_health_measure_run_data.measure_type = measure_type;
        s_measure_time_count = 0;
 
+       mmi_health_measure_process_timer_stop();
        uos_timer_create(&s_health_measure_process_timer_id);
        uos_timer_start(s_health_measure_process_timer_id, MS_TO_TICKS(MMI_HEALTH_MEASURE_CYCLE_DURATION), 0, mmi_health_measure_process_timer_handle, NULL);
 }
@@ -737,6 +774,8 @@ void mmi_health_measure_timed_measure_start(MMI_HEALTH_MEASURE_TYPE_E measure_ty
                        mmi_health_measure_timed_list_node_remove(measure_type);
                }
 
+               HEALTH_MEASURE_DEBUG_PRINTF("[@CHENG_DEBUG][%s][%d]: type=%d\n", __FUNCTION__, __LINE__, measure_type);
+               
                return;
        }
 
@@ -749,6 +788,10 @@ void mmi_health_measure_app_measure_start(MMI_HEALTH_MEASURE_TYPE_E measure_type
 {
        HEALTH_MEASURE_DEBUG_PRINTF("[@CHENG_DEBUG][%s][%d]: \n", __FUNCTION__, __LINE__);
        
+       lv_obj_t * activity_obj = lv_watch_get_activity_obj(ACT_ID_FACTORY_MODE_TEST);
+       if(NULL != activity_obj)
+               return;
+       
        if(MMI_HEALTH_MEASURE_STATE_UI == s_health_measure_run_data.measure_state)
        {
                return;
index 530b682..6d707b2 100644 (file)
@@ -57,7 +57,7 @@ void lowbattery_task(lv_task_t * task)
     if(HAL_CHG_CONNECTED == Hal_Charger_Get_Status()) {
         if(NULL != lv_watch_get_activity_obj(ACT_ID_LOWBATTERY)) {
             // exit low battery mode
-            printf("power charging start and exit low battery mode\n");
+            printf("[@CHENG_DEBUG][%s][%d]: power charging start and exit low battery mode\n", __FUNCTION__, __LINE__);
             lowbattery_destory();
         }
     } else {
@@ -90,6 +90,7 @@ void lowbattery_task(lv_task_t * task)
         } else {
             // exit low battery mode
             if(NULL != lv_watch_get_activity_obj(ACT_ID_LOWBATTERY)) {
+                printf("[@CHENG_DEBUG][%s][%d]: exit low battery mode\n", __FUNCTION__, __LINE__);
                 lowbattery_destory();
             }
         }
@@ -162,13 +163,19 @@ static lv_obj_t * lowbattery_create(lv_obj_t * activity_obj)
 static void lowbattery_prepare_destory(lv_obj_t * activity_obj)
 {
     lv_watch_png_cache_all_free();
-    lv_lowbattery_ext_t * ext = lv_obj_get_ext_attr(lv_watch_get_activity_obj(ACT_ID_LOWBATTERY));
-    ext->timelabel = NULL;
+    //lv_lowbattery_ext_t * ext = lv_obj_get_ext_attr(lv_watch_get_activity_obj(ACT_ID_LOWBATTERY));
+       //if(NULL != ext)
+       //    ext->timelabel = NULL;
 }
 
 static void lowbattery_destory(void)
 {
     lowbattery_prepare_destory(NULL);
-    lv_obj_del(lv_watch_get_activity_obj(ACT_ID_LOWBATTERY));
+    //lv_obj_del(lv_watch_get_activity_obj(ACT_ID_LOWBATTERY));
+       lv_obj_t * activity_obj = lv_watch_get_activity_obj(ACT_ID_LOWBATTERY);
+       if(NULL != activity_obj)
+       {
+               lv_obj_del(activity_obj);
+       }
 }
 #endif /*USE_LV_WATCH_LOWBATTERY*/
index 1f3bba4..199825e 100644 (file)
@@ -1442,7 +1442,12 @@ void mmi_ui_msg_update_vc_call_incoming(void)
 
 void mmi_vc_call_action_incoming(char * number, MODEM_VIDEO_CALL_TYPE type)
 {
-       if(true == mmi_active_screen_is_prohibit_interrupted() || true == is_rat_gsm())
+       if(true == mmi_active_screen_is_prohibit_interrupted()
+               || true == is_rat_gsm()
+               #ifdef __MMI_ZHSX_SUPPORT_DO_NOT_DISTURB__
+               || true == mmi_watch_is_in_do_not_disturb_time()
+               #endif
+               )
        {
                VIDEO_CALL_DEBUG_PRINTF("[@CHENG_DEBUG][%s][%d]: \n", __FUNCTION__, __LINE__);
                
@@ -1458,6 +1463,15 @@ void mmi_vc_call_action_incoming(char * number, MODEM_VIDEO_CALL_TYPE type)
                s_video_call_params.call_type = type;
                s_video_call_params.state = MMI_VIDEO_CALL_STATE_INCOMING;
                strncpy(s_video_call_params.number, number, NV_WATCH_VC_CONTACT_NUMBER_LEN - 1);
+               uint8_t i = 0;
+               for(i = 0; i < s_vc_contact.total; i++) 
+               {
+                       if(0 == strncmp(s_video_call_params.number, s_vc_contact.number[i], strlen(s_video_call_params.number)))
+                       {
+                               strncpy(s_video_call_params.name, s_vc_contact.name[i], NV_WATCH_VC_CONTACT_NAME_LEN - 1);
+                               break;
+                       }
+               }
                
                HAL_SPEAKER_GAIN volume = query_current_volume();
                if(!Hal_Set_BT_Audio_Path(volume))
@@ -1587,6 +1601,15 @@ void mmi_vc_call_action_dialing(char * number, MODEM_VIDEO_CALL_TYPE type)
     s_video_call_params.state = MMI_VIDEO_CALL_STATE_DIALING;
     s_video_call_params.call_type = type;
     strcpy(s_video_call_params.number, number);
+       uint8_t i = 0;
+       for(i = 0; i < s_vc_contact.total; i++) 
+       {
+               if(0 == strncmp(s_video_call_params.number, s_vc_contact.number[i], strlen(s_video_call_params.number)))
+               {
+                       strncpy(s_video_call_params.name, s_vc_contact.name[i], NV_WATCH_VC_CONTACT_NAME_LEN - 1);
+                       break;
+               }
+       }
        
     int8_t ret = mmi_video_call_dial_req(type, s_video_call_params.number);
     if(NULL == s_video_call_params.dialing_timer_id) 
index 60da4ba..f848d89 100644 (file)
@@ -1445,7 +1445,12 @@ void mmi_ui_msg_update_vc_call_incoming(void)
 
 void mmi_vc_call_action_incoming(char * number, MODEM_VIDEO_CALL_TYPE type, char * t_ticket, char * t_tokens)
 {
-       if(true == mmi_active_screen_is_prohibit_interrupted() || true == is_rat_gsm())
+       if(true == mmi_active_screen_is_prohibit_interrupted()
+               || true == is_rat_gsm()
+               #ifdef __MMI_ZHSX_SUPPORT_DO_NOT_DISTURB__
+               || true == mmi_watch_is_in_do_not_disturb_time()
+               #endif
+               )
        {
                VIDEO_CALL_DEBUG_PRINTF("[@CHENG_DEBUG][%s][%d]: \n", __FUNCTION__, __LINE__);
                
@@ -1461,6 +1466,15 @@ void mmi_vc_call_action_incoming(char * number, MODEM_VIDEO_CALL_TYPE type, char
                s_video_call_params.call_type = type;
                s_video_call_params.state = MMI_VIDEO_CALL_STATE_INCOMING;
                strncpy(s_video_call_params.number, number, NV_WATCH_VC_CONTACT_NUMBER_LEN - 1);
+               uint8_t i = 0;
+               for(i = 0; i < s_vc_contact.total; i++) 
+               {
+                       if(0 == strncmp(s_video_call_params.number, s_vc_contact.number[i], strlen(s_video_call_params.number)))
+                       {
+                               strncpy(s_video_call_params.name, s_vc_contact.name[i], NV_WATCH_VC_CONTACT_NAME_LEN - 1);
+                               break;
+                       }
+               }
 
                memset(s_video_call_ticket, 0x0, MMI_WATCH_VC_TICKET_LEN);
                strncpy(s_video_call_ticket, t_ticket, MMI_WATCH_VC_TICKET_LEN - 1);
@@ -1617,6 +1631,15 @@ void mmi_vc_call_action_dialing(char * number, MODEM_VIDEO_CALL_TYPE type)
     s_video_call_params.state = MMI_VIDEO_CALL_STATE_DIALING;
     s_video_call_params.call_type = type;
     strcpy(s_video_call_params.number, number);
+       uint8_t i = 0;
+       for(i = 0; i < s_vc_contact.total; i++) 
+       {
+               if(0 == strncmp(s_video_call_params.number, s_vc_contact.number[i], strlen(s_video_call_params.number)))
+               {
+                       strncpy(s_video_call_params.name, s_vc_contact.name[i], NV_WATCH_VC_CONTACT_NAME_LEN - 1);
+                       break;
+               }
+       }
        
        mmi_protocol_fzd_action_VC_CALL_REQUEST(s_video_call_params.number, s_video_call_params.call_type);
     s_video_call_params.dialing_timer_id = Hal_Timer_Start(MMI_VC_DIALING_TIMEOUT, mmi_vc_call_dialing_timeout_cb, NULL, 0);
index 742d354..9a35085 100644 (file)
@@ -101,7 +101,7 @@ typedef struct
 
 
 
-void wechat_chat_list_set_slide_enable(lv_watch_obj_ext_t * ext, bool enable);
+//void wechat_chat_list_set_slide_enable(lv_watch_obj_ext_t * ext, bool enable);
 void mmi_wechat_msg_info_init(void);
 void wechat_msg_info_nv_write(void);
 
index 8d2f221..fa85ccf 100644 (file)
@@ -191,7 +191,7 @@ void wechat_prepare_destory(lv_obj_t * activity_obj)
        WECHAT_DEBUG_PRINTF("[@CHENG_DEBUG][%s][%d]: \n", __FUNCTION__, __LINE__);
 }
 
-void wechat_chat_list_set_slide_enable(lv_watch_obj_ext_t * ext, bool enable)
+static void wechat_chat_list_set_slide_enable(lv_watch_obj_ext_t * ext, bool enable)
 {
     if(enable) 
        {
@@ -356,6 +356,9 @@ bool wechat_msg_receive_from_server(char * data_buff, int data_buff_len, nv_wech
                && false == wechat_msg_voice_is_playing() 
                && false == wechat_msg_voice_is_recording()
                && false == wechat_msg_item_is_sending()
+               #ifdef __MMI_ZHSX_SUPPORT_DO_NOT_DISTURB__
+               && false == mmi_watch_is_in_do_not_disturb_time()
+               #endif
                )
        {
                WECHAT_DEBUG_PRINTF("[@CHENG_DEBUG][%s][%d]: \n", __FUNCTION__, __LINE__);
@@ -855,11 +858,11 @@ void wechat_msg_recording_audio_ctrl_callback(AUDIO_CTRL_PRIORITY priority)
                        lv_obj_del(activity_obj);
                }
                
-               lv_wechat_ext_t * ext = wechat_actId_ext_get(ACT_ID_WECHAT_MAIN);
-               if(NULL != ext)
-               {
-                       wechat_chat_list_set_slide_enable(&ext->old_ext, false); /*prevent to slide out while recording*/
-               }
+               //lv_wechat_ext_t * ext = wechat_actId_ext_get(ACT_ID_WECHAT_MAIN);
+               //if(NULL != ext)
+               //{
+               //      wechat_chat_list_set_slide_enable(&ext->old_ext, false); /*prevent to slide out while recording*/
+               //}
     }
 }
 
@@ -1352,7 +1355,7 @@ void wechat_chat_list_voice_item_playing_audio_ctrl_callback(AUDIO_CTRL_PRIORITY
                lv_wechat_ext_t * ext = wechat_actId_ext_get(ACT_ID_WECHAT_MAIN);
                if(NULL != ext)
                {
-                       wechat_chat_list_set_slide_enable(&ext->old_ext, false); /*prevent to slide out while recording*/
+                       //wechat_chat_list_set_slide_enable(&ext->old_ext, false); /*prevent to slide out while recording*/
                        wechat_msg_voice_item_playing_stop(ext);
                }
     }
index 43d4ef3..3292ead 100644 (file)
@@ -695,6 +695,30 @@ static lv_obj_t * phonebook_add(lv_obj_t * page)
 
 static void phonebook_btn_event_cb(lv_obj_t * btn, lv_event_t e)
 {
+#ifdef __MMI_ZHSX_SUPPORT__
+       //printf("[@CHENG_DEBUG][%s][%d]: %d\n", __FUNCTION__, __LINE__, e);
+       
+       static uint8_t s_phonebook_item_click_flag = 0;
+    if(LV_EVENT_CLICKED == e) 
+       {
+               if(s_phonebook_item_click_flag)
+               {
+               lv_phonebook_obj_ext_t * ext = phonebook_get_ext();
+               uint8_t length = strlen(ext->cur_contact->number) + 1;
+               char * number = (char *)lv_mem_alloc(length);
+               memcpy(number, ext->cur_contact->number, length);
+               phone_voice_call_req(number);
+       }
+    }
+       else if(LV_EVENT_PRESSED == e)
+       {
+               s_phonebook_item_click_flag = 1;
+       }
+       else if(LV_EVENT_LONG_PRESSED == e)
+       {
+               s_phonebook_item_click_flag = 0;
+       }
+#else
     lv_phonebook_obj_ext_t * ext = NULL;
     uint8_t length = 0;
     char * number = NULL;
@@ -705,6 +729,7 @@ static void phonebook_btn_event_cb(lv_obj_t * btn, lv_event_t e)
         memcpy(number, ext->cur_contact->number, length);
         phone_voice_call_req(number);
     }
+#endif
 }
 
 static void phonebook_add_btn(lv_obj_t * obj, char * phone_name, char * phone_number, lv_event_cb_t event_cb)
index 5c5b7a6..c90edaf 100644 (file)
@@ -183,7 +183,9 @@ void watch_power_on_req(void)
 #ifdef __MMI_ZHSX_SUPPORT_VIDEO_CALL__
        mmi_video_call_jrtc_config_init_00();
        mmi_video_call_contact_nv_read();
-
+#endif
+#ifdef __MMI_ZHSX_SUPPORT_DO_NOT_DISTURB__
+       mmi_watch_do_not_disturb_nv_read();
 #endif
 
 #endif
@@ -501,8 +503,8 @@ static lv_obj_t * watch_create(bool silentReset)
     voice_wakeup_init();
 #endif
 
-    app_adaptor_pedometer_record_t record;
-    app_adaptor_get_pedometer_info_req(&record);
+    //app_adaptor_pedometer_record_t record;
+    //app_adaptor_get_pedometer_info_req(&record);
 
     app_adaptor_timing_control_init();
 #ifdef __MMI_ZHSX_SUPPORT_NO_SIM_POWER_OFF__
index 67c84d8..22df509 100644 (file)
@@ -471,6 +471,13 @@ void lv_watch_go_home(void)
         return;
     }
 
+#ifdef __MMI_ZHSX_SUPPORT__
+       if(NULL != lv_watch_get_activity_obj(ACT_ID_WATCH_SEARCHING))
+       {
+               mmi_watch_search_screen_destroy();
+       }
+#endif
+
 #if USE_LV_WATCH_EXERCISE != 0
     if(exercise_sport_home_key_handle()) {
         return;
@@ -509,6 +516,8 @@ void lv_watch_go_home(void)
             return;
         }
 
+       printf("[@CHENG_DEBUG][%s][%d]: \n", __FUNCTION__, __LINE__);
+
         if(ext->actId > ACT_ID_ONE_LEVEL_MAX) {
             if(ext->actId == ACT_ID_ALBUM) {
                 album_destory(false);
@@ -551,6 +560,20 @@ void lv_watch_go_back(void)
         return;
     }
 
+#ifdef __MMI_ZHSX_SUPPORT__
+       if(NULL != lv_watch_get_activity_obj(ACT_ID_WATCH_SEARCHING))
+       {
+               mmi_watch_search_screen_destroy();
+       }
+#endif
+
+#ifdef __MMI_ZHSX_SUPPORT_DO_NOT_DISTURB__
+       if(true == mmi_watch_is_in_do_not_disturb_time())
+       {
+        return;
+       }
+#endif
+
 #if USE_LV_WATCH_EXERCISE != 0
     if(exercise_sport_back_key_handle()) {
         return;
@@ -589,6 +612,9 @@ void lv_watch_go_back(void)
             launcher_power_key_event();
             return;
         }
+
+       printf("[@CHENG_DEBUG][%s][%d]: \n", __FUNCTION__, __LINE__);
+       
         if(ext->actId > ACT_ID_ONE_LEVEL_MAX) {
             if(NULL != ext->prepare_destory) {
                 ext->prepare_destory(obj);
index 88c7dbf..d549e4c 100644 (file)
@@ -21,20 +21,20 @@ extern "C"
 
 #include "mmi_default_CUSTOM.h"
 
-//server ip
+// protocol server ip
 #ifdef MMI_CUSTOMER_IP_ADDRESS
 #define MMI_PROTOCOL_IP_ADDRESS_DEFAULT                MMI_CUSTOMER_IP_ADDRESS
 #else
 #define MMI_PROTOCOL_IP_ADDRESS_DEFAULT                "api.xcloudtech.com" // fzd
 #endif
 
+// protocol server port
 #ifdef MMI_CUSTOMER_IP_PORT
 #define MMI_PROTOCOL_IP_PORT_DEFAULT           MMI_CUSTOMER_IP_PORT
 #else
 #define MMI_PROTOCOL_IP_PORT_DEFAULT           (9000) // fzd
 #endif
 
-
 // protocol md5 key
 #ifdef MMI_CUSTOMER_PROTOCOL_MD5_KEY
 #define MMI_PROTOCOL_MD5_KEY_DEFAULT           MMI_CUSTOMER_PROTOCOL_MD5_KEY