合并UI 1/target/1
authorCaisking <3449750381@qq.com>
Sat, 13 Apr 2024 09:04:26 +0000 (17:04 +0800)
committerCaisking <3449750381@qq.com>
Sat, 13 Apr 2024 09:04:26 +0000 (17:04 +0800)
16 files changed:
code/sdk/application/wearable/fd230app/nativeui/traing/Training_UiConfig.h
code/sdk/application/wearable/fd230app/nativeui/traing/training_card/include/TrainingDataView.h
code/sdk/application/wearable/fd230app/nativeui/traing/training_card/include/TrainingDetailView.h
code/sdk/application/wearable/fd230app/nativeui/traing/training_card/include/TrainingEndNoteView.h [deleted file]
code/sdk/application/wearable/fd230app/nativeui/traing/training_card/include/TrainingEndView.h [deleted file]
code/sdk/application/wearable/fd230app/nativeui/traing/training_card/src/TraingCardPresenter.cpp
code/sdk/application/wearable/fd230app/nativeui/traing/training_card/src/TrainingControlView.cpp
code/sdk/application/wearable/fd230app/nativeui/traing/training_card/src/TrainingDataView.cpp
code/sdk/application/wearable/fd230app/nativeui/traing/training_card/src/TrainingDetailView.cpp
code/sdk/application/wearable/fd230app/nativeui/traing/training_card/src/TrainingEndNoteView.cpp [deleted file]
code/sdk/application/wearable/fd230app/nativeui/traing/training_card/src/TrainingEndView.cpp [deleted file]
code/sdk/build/config/target_config/brandy/mk_fs_image/fd230/fs/user/res/Training/modules/Color_Progress.bin [new file with mode: 0644]
code/sdk/build/config/target_config/brandy/mk_fs_image/fd230/fs/user/res/Training/modules/Sport_continue.bin
code/sdk/build/config/target_config/brandy/mk_fs_image/fd230/fs/user/res/Training/modules/Sport_pause.bin
code/sdk/build/config/target_config/brandy/mk_fs_image/fd230/fs/user/res/Training/modules/Sport_stop.bin
code/sdk/build/config/target_config/brandy/mk_fs_image/fd230/fs/user/res/Training/modules/sport_heartrate.bin [new file with mode: 0644]

index 4bf5d9c..d0bbb42 100644 (file)
@@ -54,6 +54,7 @@ namespace OHOS
     static constexpr const char *BUTTONGROUND2_IMAGE = MODULES "/Buttonground2.bin";
     static constexpr const char *BUBBLE_IMAGE = MODULES "/Bubble.bin";
     static constexpr const char *BUTTONOK_IMAGE = MODULES "/Buttonok.bin";
+    static constexpr const char *COLOR_PROGRESS_IMAGE = MODULES "/Color_Progress.bin";
     static constexpr const char *CALORIES_IMAGE = MODULES "/Calories.bin";
     static constexpr const char *CALORIES_30_IMAGE = MODULES "/Calories_30.bin";
     static constexpr const char *CONTROL_POINT_IMAGE = MODULES "/Control_point.bin";
@@ -92,6 +93,7 @@ namespace OHOS
     static constexpr const char *SPORT_STOP_IMAGE = MODULES "/Sport_stop.bin";
     static constexpr const char *SPORT_STRENGTH_IMAGE = MODULES "/Sport_strength.bin";
     static constexpr const char *STEP_30_IMAGE = MODULES "/Step_30.bin";
+    static constexpr const char *SPORT_HEARTRATE_IMAGE = MODULES "/sport_heartrate.bin";
     static constexpr const char *TIME_IMAGE = MODULES "/Time.bin";
     static constexpr const char *WALKING_54_IMAGE = MODULES "/Walking_54.bin";
     static constexpr const char *WARNING_IMAGE = MODULES "/Warning.bin";
index 7fd16b2..b12fbab 100644 (file)
@@ -42,6 +42,8 @@ namespace OHOS
         void PreLoad(void) override;
         void UnLoad(void) override;
         UILabelExt *GetTimeLabel();
+        UILabelExt *GetHeartLabel();
+
         void UpdataTime();
 
     private:
@@ -51,14 +53,14 @@ namespace OHOS
 
         UIViewGroup *container_ = nullptr;
 
-        UILabelExt *curtimelabel = nullptr;  // 当前时间
-        UILabelExt *sportlabel = nullptr;    // 运动项目名称
-        UILabelExt *timerlabel = nullptr;    // 计时
-        UILabelExt *heartlabel = nullptr;    // 运动实时心率
-        UILabelExt *strengthlabel = nullptr; // 运动强度
+        UILabelExt *curtimelabel = nullptr; // 当前时间
+        UILabelExt *sportlabel = nullptr;   // 运动项目名称
+        UILabelExt *timerlabel = nullptr;   // 计时
+        UILabelExt *heartlabel = nullptr;   // 运动实时心率
+        UILabelExt *ubpmlabel = nullptr;    // 运动强度
 
         UIImageView *image_progress = nullptr;
-        UIImageView *image_arrows = nullptr;
+        UIImageView *image_heart = nullptr;
         UIImageView *image_lowIntensity = nullptr;       // 低等强度
         UIImageView *image_mediumIntensity = nullptr;    // 中等强度
         UIImageView *image_highIntensity = nullptr;      // 高等强度
index 97459ab..34ab3e1 100644 (file)
@@ -41,7 +41,7 @@ namespace OHOS
         void PreLoad(void) override;
         void UnLoad(void) override;
 
-        UILabelExt *GetHeartLabel();
+ 
         UILabelExt *GetMileLabel();
         UILabelExt *GetStepLabel();
         UILabelExt *GetCalorieLabel();
@@ -53,22 +53,17 @@ namespace OHOS
 
         UIViewGroup *container_ = nullptr;
 
-        UILabelExt *u_heartlabel = nullptr;
+        UILabelButtonExt *intensity_button{nullptr};
+
         UILabelExt *u_milelabel = nullptr;
         UILabelExt *u_stepslabel = nullptr;
         UILabelExt *u_calorielabel = nullptr;
-        UILabelExt *heartlabel = nullptr;
         UILabelExt *milelabel = nullptr;
         UILabelExt *steplabel = nullptr;
         UILabelExt *calorielabel = nullptr;
 
-        UIImageView *heartimage = nullptr;
-        UIImageView *mileimage = nullptr;
-        UIImageView *stepimage = nullptr;
-        UIImageView *calorieimage = nullptr;
-        UIImageView *lineimage1_ = nullptr;
+        UIImageView *progress_image = nullptr;
         UIImageView *lineimage2_ = nullptr;
-        UIImageView *lineimage3_ = nullptr;
 
         bool viewiInitStatus{false};
     };
diff --git a/code/sdk/application/wearable/fd230app/nativeui/traing/training_card/include/TrainingEndNoteView.h b/code/sdk/application/wearable/fd230app/nativeui/traing/training_card/include/TrainingEndNoteView.h
deleted file mode 100644 (file)
index e69de29..0000000
diff --git a/code/sdk/application/wearable/fd230app/nativeui/traing/training_card/include/TrainingEndView.h b/code/sdk/application/wearable/fd230app/nativeui/traing/training_card/include/TrainingEndView.h
deleted file mode 100644 (file)
index e69de29..0000000
index aac7c21..87be72b 100644 (file)
@@ -106,6 +106,7 @@ namespace OHOS
     }\r
 \r
     /* --------------------------------- cywee库操作 -------------------------------- */\r
+    /*开启cywee*/\r
     bool TraingCardPresenter::OpenSensor(ExerciseClass type)\r
     {\r
         // 根据不同的运动项目进行不同的运动\r
@@ -114,22 +115,22 @@ namespace OHOS
         switch (type)\r
         {\r
         case ExerciseClass::NORMAL:\r
-            do_cywee_service_check_msg(SPORT_ACTIVE_MODE_NORMAL);\r
+            do_cywee_service_check_msg(CYWEE_SERVICE_CMD_NORMAL_MODE);\r
             break;\r
         case ExerciseClass::TREADMILL:\r
-            do_cywee_service_check_msg(SPORT_ACTIVE_MODE_TREADMILL);\r
+            do_cywee_service_check_msg(CYWEE_SERVICE_CMD_TREADMILL_MODE);\r
             break;\r
         case ExerciseClass::OUTDOOR:\r
-            do_cywee_service_check_msg(SPORT_ACTIVE_MODE_OUTDOOR_RUNNING);\r
+            do_cywee_service_check_msg(CYWEE_SERVICE_CMD_OUTDOOR_RUNNING_MODE);\r
             break;\r
         case ExerciseClass::INDOOR:\r
-            do_cywee_service_check_msg(SPORT_ACTIVE_MODE_INDOOR_RUNNING);\r
+            do_cywee_service_check_msg(CYWEE_SERVICE_CMD_INDOOR_RUNNING_MODE);\r
             break;\r
         case ExerciseClass::FITNESS_PEDOMETER:\r
-            do_cywee_service_check_msg(SPORT_ACTIVE_MODE_FITNESS_PEDOMETERR);\r
+            do_cywee_service_check_msg(CYWEE_SERVICE_CMD_FITNESS_PEDOMETER_MODE);\r
             break;\r
         case ExerciseClass::FREE_TRAINING:\r
-            do_cywee_service_check_msg(SPORT_ACTIVE_MODE_FREE_TRAINING);\r
+            do_cywee_service_check_msg(CYWEE_SERVICE_CMD_FREE_TRAINING_MODE);\r
             break;\r
         default:\r
             break;\r
@@ -138,6 +139,7 @@ namespace OHOS
         return true;\r
     }\r
 \r
+    /*控制cywee*/\r
     bool TraingCardPresenter::ControlSensor(ExerciseState state)\r
     {\r
         switch (state)\r
@@ -169,23 +171,26 @@ namespace OHOS
             return;\r
         }\r
 \r
-        double distance_km = sportdata->distance / 1000.0; // 转换为公里\r
-        std::stringstream stream;\r
-        stream << std::fixed << std::setprecision(2) << distance_km;\r
-        std::string distanceStr = stream.str();\r
+        double distance_km = sportdata->distance / 1000.0; // 转换为公里并保留两位小数\r
+        std::stringstream ss;\r
+        ss << std::fixed << std::setprecision(2) << distance_km;\r
+        std::string distanceStr = ss.str();\r
 \r
-        std::string calorieStr = (sportdata->calories != 0) ? std::to_string(sportdata->calories) : "--";\r
         std::string durationStr = std::to_string(sportdata->duration);\r
         std::string stepsStr = (sportdata->steps != 0) ? std::to_string(sportdata->steps) : "--";\r
+        std::string calorieStr = (sportdata->calories != 0) ? std::to_string(sportdata->calories) : "--";\r
+\r
+        TrainingDataView::GetInstance()->GetHeartLabel()->SetText("--");\r
 \r
-        TrainingDetailView::GetInstance()->GetHeartLabel()->SetText("0");\r
         TrainingDetailView::GetInstance()->GetCalorieLabel()->SetText(calorieStr.c_str());\r
         TrainingDetailView::GetInstance()->GetMileLabel()->SetText(distanceStr.c_str());\r
         TrainingDetailView::GetInstance()->GetStepLabel()->SetText(stepsStr.c_str());\r
 \r
-        WEARABLE_LOGE(WEARABLE_LOG_MODULE_APP, "ControlSensor--%s %s %s!!", calorieStr.c_str(), distanceStr.c_str(), stepsStr.c_str());\r
-    }\r
+        WEARABLE_LOGE(WEARABLE_LOG_MODULE_APP, "ControlSensor--Calories: %s, Distance: %s, Steps: %s", calorieStr.c_str(), distanceStr.c_str(), stepsStr.c_str());\r
 \r
+        // 释放sportdata内存\r
+    }\r
+    /*刷新time和data*/\r
     void TraingCardPresenter::Notify(void)\r
     {\r
         TrainingDataView::GetInstance()->UpdataTime();\r
@@ -225,7 +230,7 @@ namespace OHOS
                 return true;\r
             }\r
         }\r
-        // 点击结束按键\r
+        // 点击结束按键,弹窗显示\r
         if (strcmp(view.GetViewId(), BUTTONEND) == 0)\r
         {\r
             ControlSensor(ExerciseState::Pause);\r
index c916ea0..233c1dc 100644 (file)
@@ -41,23 +41,23 @@ namespace OHOS
     void TrainingControlView ::InitView()
     {
         //  初始化Button
-        TraingModel::GetInstance()->InitButton(buttonEnd, 100, 202, 100, 100, BUTTONEND);
+        TraingModel::GetInstance()->InitButton(buttonEnd, 91, 205, 110, 110, BUTTONEND);
         // Set additional property
         buttonEnd->SetImageSrc(SPORT_STOP_IMAGE, SPORT_STOP_IMAGE);
         // 设置按钮的点击事件监听器为 TraingGPSPresenter 的实例
         buttonEnd->SetOnClickListener(static_cast<UIView::OnClickListener *>(TraingCardPresenter::GetInstance()));
         Add(buttonEnd);
-        TraingModel::GetInstance()->InitButton(buttonStop, 255, 202, 100, 100, BUTTONSTOP);
+        TraingModel::GetInstance()->InitButton(buttonStop, 261, 205, 110, 110, BUTTONSTOP);
         // Set additional property
         buttonStop->SetImageSrc(SPORT_PAUSE_IMAGE, SPORT_PAUSE_IMAGE);
         buttonStop->SetOnClickListener(static_cast<UIView::OnClickListener *>(TraingCardPresenter::GetInstance()));
         Add(buttonStop);
 
         // 初始化Lable
-        TraingModel::GetInstance()->InitLabel(labeltitle, 188, 52, 90, 35, "label1", "训练中", DEFAULT_VECTOR_FONT_FILENAME, 30);
-        TraingModel::GetInstance()->InitLabel(labeltimer, 98, 110, 60, 35, "label2", "00:00:00", DEFAULT_VECTOR_FONT_FILENAME, 65);
-        TraingModel::GetInstance()->InitLabel(labelend, 125, 324, 60, 40, "label3", "结束", DEFAULT_VECTOR_FONT_FILENAME, 20);
-        TraingModel::GetInstance()->InitLabel(labelstop, 280, 324, 60, 40, "label4", "暂停", DEFAULT_VECTOR_FONT_FILENAME, 20);
+        TraingModel::GetInstance()->InitLabel(labeltitle, 83, 50, 300, 35, "label1", "训练中", DEFAULT_VECTOR_FONT_FILENAME, 30);
+        TraingModel::GetInstance()->InitLabel(labeltimer, 78, 110, 290, 80, "label2", "00:00:00", DEFAULT_VECTOR_FONT_FILENAME, 65);
+        TraingModel::GetInstance()->InitLabel(labelend, 81, 330, 130, 35, "label3", "结束", DEFAULT_VECTOR_FONT_FILENAME, 30);
+        TraingModel::GetInstance()->InitLabel(labelstop, 251, 330, 130, 35, "label4", "暂停", DEFAULT_VECTOR_FONT_FILENAME, 30);
         Add(labeltitle);
         Add(labeltimer);
         Add(labelend);
index b61bf67..451ced1 100644 (file)
@@ -40,34 +40,38 @@ namespace OHOS
     {
         // 初始化Image
         TraingModel::GetInstance()->InitImageView(image_progress, 13, 13, 440, 386, "image1", PROGRESS_IMAGE);
-        TraingModel::GetInstance()->InitImageView(image_arrows, 208, 297, 20, 20, "image2", ARROWS_IMAGE);
-        TraingModel::GetInstance()->InitImageView(image_lowIntensity, 98, 314, 270, 20, "image3", SPORT_STRENGTH_IMAGE);
+        TraingModel::GetInstance()->InitImageView(image_heart, 88, 295, 50, 50, "image2", SPORT_HEARTRATE_IMAGE);
         TraingModel::GetInstance()->InitImageView(image_iconup, 225, 396, 16, 10, "image4", INCO_UP_IMAGE);
         TraingModel::GetInstance()->InitImageView(image_iconpoint, 193, 421, 80, 20, "image5", DATA_POINT_IMAGE);
         Add(image_progress);
-        Add(image_arrows);
-        Add(image_lowIntensity);
+        Add(image_heart);
         Add(image_iconup);
         Add(image_iconpoint);
         // 初始化Lable
-        TraingModel::GetInstance()->InitLabel(curtimelabel, 185, 60, 90, 35, "label1", "23:54", DEFAULT_VECTOR_FONT_FILENAME, 40);
-        TraingModel::GetInstance()->InitLabel(sportlabel, 158, 120, 150, 35, "label2", "跳绳运动中", DEFAULT_VECTOR_FONT_FILENAME, 30);
-        TraingModel::GetInstance()->InitLabel(timerlabel, 90, 175, 60, 40, "label3", "00:00:00", DEFAULT_VECTOR_FONT_FILENAME, 80);
-        TraingModel::GetInstance()->InitLabel(heartlabel, 150, 276, 60, 40, "label4", "144", DEFAULT_VECTOR_FONT_FILENAME, 23);
-        TraingModel::GetInstance()->InitLabel(strengthlabel, 167, 350, 60, 40, "label4", "中等强度", DEFAULT_VECTOR_FONT_FILENAME, 26);
+        UIResourceTextId sport_id = TraingModel::GetInstance()->GetSportEvent();
+        TraingModel::GetInstance()->InitLabelExt(sportlabel, 83, 120, 300, 35, "label2", sport_id, DEFAULT_VECTOR_FONT_FILENAME, 30);
+        sportlabel->SetTextColor(Color::Gray());
+
+        TraingModel::GetInstance()->InitLabel(curtimelabel, 155, 60, 150, 50, "label1", "23:54", DEFAULT_VECTOR_FONT_FILENAME, 40);
+
+        TraingModel::GetInstance()->InitLabel(timerlabel, 40, 163, 400, 140, "label3", "00:00:00", DEFAULT_VECTOR_FONT_FILENAME, 90);
+        TraingModel::GetInstance()->InitLabel(heartlabel, 85, 284, 230, 80, "label4", "144", DEFAULT_VECTOR_FONT_FILENAME, 60);
+        TraingModel::GetInstance()->InitLabel(ubpmlabel, 218, 284, 230, 80, "label5", "bpm", DEFAULT_VECTOR_FONT_FILENAME, 60);
+        ubpmlabel->SetTextColor(Color::Gray());
         Add(curtimelabel);
         Add(sportlabel);
         Add(timerlabel);
         Add(heartlabel);
-        Add(strengthlabel);
+        Add(ubpmlabel);
+#if 0
         //  初始化Button
         TraingModel::GetInstance()->InitButton(buttonNote, 275, 350, 26, 26, BUTTONNOTE);
         // Set additional property
         buttonNote->SetImageSrc(NOTE_IMAGE, NOTE_IMAGE);
         buttonNote->SetOnClickListener(static_cast<UIView::OnClickListener *>(TraingCardPresenter::GetInstance()));
         Add(buttonNote);
-
-        //增加上拉卡片
+#endif
+        // 增加上拉卡片
         SetCoverable(true);
     }
 
@@ -94,10 +98,10 @@ namespace OHOS
             delete heartlabel;
             heartlabel = nullptr;
         }
-        if (strengthlabel != nullptr)
+        if (ubpmlabel != nullptr)
         {
-            delete strengthlabel;
-            strengthlabel = nullptr;
+            delete ubpmlabel;
+            ubpmlabel = nullptr;
         }
         // 删除button
         if (buttonNote != nullptr)
@@ -139,6 +143,10 @@ namespace OHOS
     {
         return timerlabel;
     }
+    UILabelExt *TrainingDataView::GetHeartLabel()
+    {
+        return heartlabel;
+    }
     /*更新当前时间*/
     void TrainingDataView::UpdataTime()
     {
index 08fe4be..f607d46 100644 (file)
@@ -38,38 +38,33 @@ namespace OHOS
     void TrainingDetailView ::InitView()
     {
         // 初始化Image
-        TraingModel::GetInstance()->InitImageView(heartimage, 134, 58, 30, 30, "image1", HEARTRATE_30_IMAGE);
-        TraingModel::GetInstance()->InitImageView(mileimage, 44, 189, 30, 30, "image2", MILEAGE_30_IMAGE);
-        TraingModel::GetInstance()->InitImageView(stepimage, 297, 189, 30, 30, "image3", STEP_30_IMAGE);
-        TraingModel::GetInstance()->InitImageView(calorieimage, 129, 335, 30, 30, "image4", CALORIES_30_IMAGE);
-        TraingModel::GetInstance()->InitImageView(lineimage1_, 0, 160, 10, 466, "image5", LINE_1_IMAGE);
-        TraingModel::GetInstance()->InitImageView(lineimage2_, 233, 193, 80, 20, "image5", LINE_2_IMAGE);
-        TraingModel::GetInstance()->InitImageView(lineimage3_, 0, 306, 10, 466, "image5", LINE_1_IMAGE);
-        Add(heartimage);
-        Add(mileimage);
-        Add(stepimage);
-        Add(calorieimage);
-        Add(lineimage1_);
+
+        TraingModel::GetInstance()->InitImageView(progress_image, 0, 0, 100, 100, "image5", COLOR_PROGRESS_IMAGE);
+        TraingModel::GetInstance()->InitImageView(lineimage2_, 225, 190, 80, 1, "image", LINE_2_IMAGE);
+        Add(progress_image);
         Add(lineimage2_);
-        Add(lineimage3_);
+
         // 初始化Lable
-        TraingModel::GetInstance()->InitLabel(u_heartlabel, 174, 60, 90, 35, "label1", "心率(次/分)", DEFAULT_VECTOR_FONT_FILENAME, 26);
-        TraingModel::GetInstance()->InitLabel(u_milelabel, 80, 190, 60, 40, "label2", "距离(公里)", DEFAULT_VECTOR_FONT_FILENAME, 26);
-        TraingModel::GetInstance()->InitLabel(u_stepslabel, 332, 189, 60, 40, "label3", "步数", DEFAULT_VECTOR_FONT_FILENAME, 26);
-        TraingModel::GetInstance()->InitLabel(u_calorielabel, 167, 336, 60, 40, "label4", "卡路里(千卡)", DEFAULT_VECTOR_FONT_FILENAME, 26);
-        TraingModel::GetInstance()->InitLabel(heartlabel, 202, 94, 60, 40, "label5", "144", DEFAULT_VECTOR_FONT_FILENAME, 40);
-        TraingModel::GetInstance()->InitLabel(milelabel, 76, 233, 60, 40, "label6", "13.21", DEFAULT_VECTOR_FONT_FILENAME, 40);
-        TraingModel::GetInstance()->InitLabel(steplabel, 300, 233, 60, 40, "label7", "28312", DEFAULT_VECTOR_FONT_FILENAME, 40);
-        TraingModel::GetInstance()->InitLabel(calorielabel, 175, 376, 60, 40, "label8", "210.03", DEFAULT_VECTOR_FONT_FILENAME, 40);
-        Add(u_heartlabel);
+        TraingModel::GetInstance()->InitLabel(u_milelabel, 16, 234, 220, 35, "label2", "距离(公里)", DEFAULT_VECTOR_FONT_FILENAME, 30);
+        TraingModel::GetInstance()->InitLabel(u_stepslabel, 73, 362, 320, 35, "label3", "步数", DEFAULT_VECTOR_FONT_FILENAME, 30);
+        TraingModel::GetInstance()->InitLabel(u_calorielabel, 225, 235, 230, 35, "label4", "卡路里(千卡)", DEFAULT_VECTOR_FONT_FILENAME, 30);
+        u_milelabel->SetTextColor(Color::Gray());
+        u_stepslabel->SetTextColor(Color::Gray());
+        u_calorielabel->SetTextColor(Color::Gray());
+
+        TraingModel::GetInstance()->InitLabel(milelabel, 17, 170, 200, 60, "label6", "13.21", DEFAULT_VECTOR_FONT_FILENAME, 60);
+        TraingModel::GetInstance()->InitLabel(calorielabel, 230, 170, 200, 60, "label7", "28312", DEFAULT_VECTOR_FONT_FILENAME, 60);
+        TraingModel::GetInstance()->InitLabel(steplabel, 133, 296, 200, 60, "label8", "210.03", DEFAULT_VECTOR_FONT_FILENAME, 60);
         Add(u_milelabel);
         Add(u_stepslabel);
         Add(u_calorielabel);
-        Add(heartlabel);
         Add(milelabel);
         Add(steplabel);
         Add(calorielabel);
 
+        TraingModel::GetInstance()->InitButtonExt(intensity_button, 103, 70, 260, 80, "button", STR_MEDIUM_STRENGTH, 30);
+        Add(intensity_button);
+
         SetTouchable(true);
         // SetIntercept(true);
     }
@@ -77,11 +72,6 @@ namespace OHOS
     void TrainingDetailView::DeInit()
     {
         RemoveAll();
-        if (u_heartlabel != nullptr)
-        {
-            delete u_heartlabel;
-            u_heartlabel = nullptr;
-        }
         if (u_milelabel != nullptr)
         {
             delete u_milelabel;
@@ -97,11 +87,6 @@ namespace OHOS
             delete u_calorielabel;
             u_calorielabel = nullptr;
         }
-        if (heartlabel != nullptr)
-        {
-            delete heartlabel;
-            heartlabel = nullptr;
-        }
         if (milelabel != nullptr)
         {
             delete milelabel;
@@ -118,41 +103,20 @@ namespace OHOS
             calorielabel = nullptr;
         }
 
-        // 删除Image
-        if (heartimage != nullptr)
-        {
-            delete heartimage;
-            heartimage = nullptr;
-        }
-        if (mileimage != nullptr)
-        {
-            delete mileimage;
-            mileimage = nullptr;
-        }
-        if (stepimage != nullptr)
-        {
-            delete stepimage;
-            stepimage = nullptr;
-        }
-        if (calorieimage != nullptr)
+        if (progress_image != nullptr)
         {
-            delete calorieimage;
-            calorieimage = nullptr;
-        }
-        if (lineimage1_ != nullptr)
-        {
-            delete lineimage1_;
-            lineimage1_ = nullptr;
+            delete progress_image;
+            progress_image = nullptr;
         }
         if (lineimage2_ != nullptr)
         {
             delete lineimage2_;
             lineimage2_ = nullptr;
         }
-        if (lineimage3_ != nullptr)
+        if (intensity_button != nullptr)
         {
-            delete lineimage3_;
-            lineimage3_ = nullptr;
+            delete intensity_button;
+            intensity_button = nullptr;
         }
     }
 
@@ -168,10 +132,6 @@ namespace OHOS
 
     void TrainingDetailView::UnLoad(void) {}
 
-    UILabelExt *TrainingDetailView::GetHeartLabel()
-    {
-        return heartlabel;
-    }
     UILabelExt *TrainingDetailView::GetMileLabel()
     {
         return milelabel;
diff --git a/code/sdk/application/wearable/fd230app/nativeui/traing/training_card/src/TrainingEndNoteView.cpp b/code/sdk/application/wearable/fd230app/nativeui/traing/training_card/src/TrainingEndNoteView.cpp
deleted file mode 100644 (file)
index e69de29..0000000
diff --git a/code/sdk/application/wearable/fd230app/nativeui/traing/training_card/src/TrainingEndView.cpp b/code/sdk/application/wearable/fd230app/nativeui/traing/training_card/src/TrainingEndView.cpp
deleted file mode 100644 (file)
index e69de29..0000000
diff --git a/code/sdk/build/config/target_config/brandy/mk_fs_image/fd230/fs/user/res/Training/modules/Color_Progress.bin b/code/sdk/build/config/target_config/brandy/mk_fs_image/fd230/fs/user/res/Training/modules/Color_Progress.bin
new file mode 100644 (file)
index 0000000..da0c829
Binary files /dev/null and b/code/sdk/build/config/target_config/brandy/mk_fs_image/fd230/fs/user/res/Training/modules/Color_Progress.bin differ
index dfa9eaf..29fa070 100644 (file)
Binary files a/code/sdk/build/config/target_config/brandy/mk_fs_image/fd230/fs/user/res/Training/modules/Sport_continue.bin and b/code/sdk/build/config/target_config/brandy/mk_fs_image/fd230/fs/user/res/Training/modules/Sport_continue.bin differ
index 80a752d..09cfcda 100644 (file)
Binary files a/code/sdk/build/config/target_config/brandy/mk_fs_image/fd230/fs/user/res/Training/modules/Sport_pause.bin and b/code/sdk/build/config/target_config/brandy/mk_fs_image/fd230/fs/user/res/Training/modules/Sport_pause.bin differ
index 2e12055..7b5a977 100644 (file)
Binary files a/code/sdk/build/config/target_config/brandy/mk_fs_image/fd230/fs/user/res/Training/modules/Sport_stop.bin and b/code/sdk/build/config/target_config/brandy/mk_fs_image/fd230/fs/user/res/Training/modules/Sport_stop.bin differ
diff --git a/code/sdk/build/config/target_config/brandy/mk_fs_image/fd230/fs/user/res/Training/modules/sport_heartrate.bin b/code/sdk/build/config/target_config/brandy/mk_fs_image/fd230/fs/user/res/Training/modules/sport_heartrate.bin
new file mode 100644 (file)
index 0000000..9b6dd78
Binary files /dev/null and b/code/sdk/build/config/target_config/brandy/mk_fs_image/fd230/fs/user/res/Training/modules/sport_heartrate.bin differ