#include "components/icon_adapter.h"
#include "AlipayPresenter.h"
#include "AppViewIDs.h"
+#include "components/ui_label_ext.h"
+#include"language/font/ui_resource_string.h"
#include "UiConfig.h"
#include "AlipayListAdapter.h"
#include "AlipayListItem.h"
#include "components/icon_adapter.h"
#include "AlipayPresenter.h"
#include "AppViewIDs.h"
+#include "components/ui_label_ext.h"
+#include"language/font/ui_resource_string.h"
#include "UiConfig.h"
#include "AlipayTransListAdapter.h"
#include "AlipayTransListItem.h"
#include "bundle_info.h"
#include "AppViewIDs.h"
+#include "components/ui_label_ext.h"
+#include"language/font/ui_resource_string.h"
#include "ohos_types.h"
#define APP_MAX_NUM 50
#include "UiConfig.h"
#include "AppViewIDs.h"
+#include "components/ui_label_ext.h"
+#include"language/font/ui_resource_string.h"
#include "ApplistModel.h"
#include "ApplistPresenter.h"
#include "string"\r
#include "PhoneService.h"\r
#include "AppViewIDs.h"\r
+#include "components/ui_label_ext.h"\r
+#include"language/font/ui_resource_string.h"\r
#include "message.h"\r
#include "msg_center.h"\r
\r
#include "AppViewIDs.h"\r
+#include "components/ui_label_ext.h"\r
+#include"language/font/ui_resource_string.h"\r
#include "NativeAbility.h"\r
#include "graphic_math.h"\r
#include "classicbluetooth/include/ClassicBlueToothPresenter.h"\r
#include "ohos_types.h"
#include "UiConfig.h"
#include "AppViewIDs.h"
+#include "components/ui_label_ext.h"
+#include"language/font/ui_resource_string.h"
#include "CompassView.h"
namespace OHOS {
#include "ohos_types.h"
#include "UiConfig.h"
#include "AppViewIDs.h"
+#include "components/ui_label_ext.h"
+#include"language/font/ui_resource_string.h"
#include "CompassView.h"
#include "CompassPresenter.h"
#include "CompassModel.h"
#include "AppViewIDs.h"
+#include "components/ui_label_ext.h"
+#include"language/font/ui_resource_string.h"
#include "NativeAbility.h"
#include "DialViewGroup.h"
#include "dialupdate/include/DialUpdatePresenter.h"
#include "AppViewIDs.h"\r
+#include "components/ui_label_ext.h"\r
+#include"language/font/ui_resource_string.h"\r
#include "NativeAbility.h"\r
#include "graphic_math.h"\r
#include "string.h"\r
#include "View.h"
#include "components/ui_view_group.h"
#include "components/ui_label_ext.h"
+#include"language/font/ui_resource_string.h"
#include "components/ui_image_animator.h"
#include "components/ui_label_button_ext.h"
#include "components/ui_image_view.h"
* @FilePath: /FD230/code/sdk/application/wearable/fd230app/nativeui/findphone/src/FindPhonePresenter.cpp
*/
#include "AppViewIDs.h"
+#include "components/ui_label_ext.h"
+#include"language/font/ui_resource_string.h"
#include "NativeAbility.h"
#include "findphone/include/FindPhonePresenter.h"
#include "common/key_code.h"
#include "KeyInputListener.h"
#include "common/key_code.h"
#include "AppViewIDs.h"
+#include "components/ui_label_ext.h"
+#include"language/font/ui_resource_string.h"
#include "View.h"
#include "MainViewSample.h"
#include "wearable_log.h"
{"uz", "O‘zbek", "乌兹别克语"},
{"az", "Azərbaycan dili", "阿塞拜疆语"}};
- static const char *en = "user/res/language_config/font/en.lang";
- static const char *zh_CN = "user/res/language_config/font/zh.lang";
+ static const char *en = "user/res/font/en.lang";
+ static const char *zh_CN = "user/res/font/zh.lang";
static const uint8_t langcount = 2;
const char *resFiles[langcount] = {zh_CN, en};
--- /dev/null
+STR_EXERCISE_GENERAL,Exercise general\r
+STR_EXERCISE_FREETRAINING,Free training\r
+STR_EXERCISE_RESISTANCETRAINING,Resistance training\r
+STR_EXERCISE_SPINBIKE,Spin bike\r
+STR_EXERCISE_TREADMILL,Treadmill\r
+STR_EXERCISE_STROLLMACHINE,Stroll machine\r
+STR_EXERCISE_HIIT,High intense interval training\r
+STR_EXERCISE_CROSSFIT,Crossfit\r
+STR_EXERCISE_GROUPCALISTHENICS,Group calisthenics\r
+STR_EXERCISE_YOGA,Yoga\r
+STR_EXERCISE_YOGACAT,Yoga cat\r
+STR_EXERCISE_YOGACOW,Yoga cow\r
+STR_EXERCISE_YOGACOBRA,Yoga cobra\r
+STR_EXERCISE_YOGAHERO1,Yoga hero1\r
+STR_EXERCISE_YOGAHERO2,Yoga hero2\r
+STR_EXERCISE_YOGAHERO3,Yoga hero3\r
+STR_EXERCISE_YOGAROLLING,Yoga rolling\r
+STR_EXERCISE_OUTDOORWALKING,Outdoor walking\r
+STR_EXERCISE_OUTDOORRUNNING,Outdoor running\r
+STR_EXERCISE_INDOORWALKING,Indoor walking\r
+STR_EXERCISE_INDOORRUNNING,Indoor running\r
+STR_EXERCISE_OUTDOORBIKING,Outdoor biking\r
+STR_EXERCISE_JUMPINGROPE,Jumping rope\r
+STR_EXERCISE_PILATES,Pilates\r
+STR_EXERCISE_CROSS_FIT,Cross fit\r
+STR_EXERCISE_FUNCTIONALTRAINING,Functional training\r
+STR_EXERCISE_PHYSICALTRAINING,Physical Training\r
+STR_EXERCISE_TAEKWONDO,Taekwondo\r
+STR_EXERCISE_BOXING,Boxing\r
+STR_EXERCISE_KICKBOXING,Kickboxing\r
+STR_EXERCISE_KARATE,Karate\r
+STR_EXERCISE_FENCING,Fencing\r
+STR_EXERCISE_CORETRAINING,Core training\r
+STR_EXERCISE_BODYCOMBAT,Body Combat\r
+STR_EXERCISE_KENDO,Kendo\r
+STR_EXERCISE_HORIZONTALBAR,Horizontal bar\r
+STR_EXERCISE_PARALLELBARS,Parallel bars\r
+STR_EXERCISE_CROSSFIT,Circuit training\r
+STR_EXERCISE_AEROBICS,Aerobics\r
+STR_EXERCISE_CALISTHENICE,Calisthenice\r
+STR_EXERCISE_P90X,P90X\r
+STR_EXERCISE_KETTLEBELLTRAINING,Kettlebell Training\r
+STR_EXERCISE_MIXEDMARTIALARTS,Mixed martial arts\r
+STR_EXERCISE_STAIRCLIMBINGMACHINE,Stair climbing machine\r
+STR_EXERCISE_WEIGHTLIFTING,Weightlifting\r
+STR_EXERCISE_BARRE,Barre\r
+STR_EXERCISE_HANDCYCLING,Hand cycling\r
+STR_EXERCISE_TRACKFIELD,Track field\r
+STR_EXERCISE_WRESTLING,Wrestling\r
+STR_EXERCISE_MINDBODY,Mind body\r
+STR_EXERCISE_FLEXIBILITY,Flexibility\r
+STR_EXERCISE_MIXEDCARDIO,Mixed cardio\r
+STR_EXERCISE_TRADITIONALSTRENGTHTRAINING,Traditional strength training\r
+STR_EXERCISE_CROSSTRAINING,Cross training\r
+STR_EXERCISE_GYMNASTICS,Gymnastics\r
+STR_EXERCISE_STEPTRAINING,Step training\r
+STR_EXERCISE_ELLIPTICALTRAINER,Elliptical trainer\r
+STR_EXERCISE_ROWINGMACHINE,Rowing machine\r
+STR_DANCING_GENERAL,Dancing general\r
+STR_DANCING_BELLY,Belly dance\r
+STR_DANCING_JAZZ,Jazz dance\r
+STR_DANCING_LATIN,Latin dance\r
+STR_DANCING_BALLET,Ballet dance\r
+STR_DANCING_STREET,Street dance\r
+STR_DANCING_PUBLICSQUARE,Public square dancing\r
+STR_DANCING_ZUMBA,Zumba\r
+STR_DANCING_SOCIALDANCE,Social dance\r
+STR_DANCING_TAPDANCE,Tap dance\r
+STR_RECREATIONAL_SPORTS,Recreational Sports\r
+STR_RECREATIONAL_SKATING,Roller Skating\r
+STR_RECREATIONAL_MARTIALARTS,Martial arts\r
+STR_RECREATIONAL_TAICHI,Tai Chi\r
+STR_RECREATIONAL_HULAHOOP,Hula hoop\r
+STR_RECREATIONAL_DISCSPORT,Disc sport\r
+STR_RECREATIONAL_DARTS,Darts\r
+STR_RECREATIONAL_ARCHERY,Archery\r
+STR_RECREATIONAL_HORSERIDING,Horse riding\r
+STR_RECREATIONAL_BATTLEGAME,Battle game\r
+STR_RECREATIONAL_KITE,Fly a kite\r
+STR_RECREATIONAL_TUGOFWAR,Tug of war\r
+STR_RECREATIONAL_SWING,Swing\r
+STR_RECREATIONAL_STAIRCLIMBING,Stair climbing\r
+STR_RECREATIONAL_OBSTACLERACE,Obstacle race\r
+STR_RECREATIONAL_FISHING,Fishing\r
+STR_RECREATIONAL_HUNTING,Hunting\r
+STR_RECREATIONAL_SCOOTERRIDING,Scooter Riding\r
+STR_RECREATIONAL_PARAGLIDING,Paragliding\r
+STR_RECREATIONAL_TEAMSPORTS,Team sports\r
+STR_RECREATIONAL_FINESSGAMING,Finess gaming\r
+STR_RECREATIONAL_HIKING,Hiking\r
+STR_RECREATIONAL_EQUESTRIANSPORTS,Equestrian sports\r
+STR_RECREATIONAL_PLAY,Play\r
+STR_BALL_GAMES,Ball games\r
+STR_BALL_BADMINTON,Badminton\r
+STR_BALL_TABLETENNIS,Table tennis\r
+STR_BALL_TENNIS,Tennis\r
+STR_BALL_BILLIARDS,Billiards\r
+STR_BALL_BOWLING,Bowling\r
+STR_BALL_VOLLEYBALL,Volleyball\r
+STR_BALL_SHUTTLECOCK,Shuttlecock\r
+STR_BALL_HANDBALL,Handball\r
+STR_BALL_BASEBALL,Baseball\r
+STR_BALL_SOFTBALL,Softball\r
+STR_BALL_CRICKET,Cricket\r
+STR_BALL_FOOTBALL,Football\r
+STR_BALL_BEACHSOCCER,Beach soccer\r
+STR_BALL_BEACHVOLLEYBALL,Beach volleyball\r
+STR_BALL_CROQUET,Croquet\r
+STR_BALL_HOCKEY,Hockey\r
+STR_BALL_SQUASH,Squash\r
+STR_BALL_SEPAKTAKRAW,Sepak takraw\r
+STR_BALL_DODGEBALL,Dodge ball\r
+STR_BALL_BASKETBALL,Basketball\r
+STR_BALL_SOCCER,Soccer\r
+STR_BALL_GOLF,Golf\r
+STR_BALL_POLO,Polo\r
+STR_BALL_RACQUETBALL,Racquetball\r
+STR_BALL_RUGBY,Rugby\r
+STR_BALL_GATEBALL,Gateball\r
+STR_BALL_PICKLEBALL,Pickleball\r
+STR_BALL_LACROSSE,Lacrosse\r
+STR_WATER_ACTIVITIES,Water activities\r
+STR_WATER_SAILING,Sailing\r
+STR_WATER_SURFING,Surfing\r
+STR_WATER_WHITEWATERRAFTING,Whitewater rafting\r
+STR_WATER_CANOEING,Canoeing\r
+STR_WATER_KAYAKING,Kayaking\r
+STR_WATER_ROWING,Rowing\r
+STR_WATER_MOTORBOAT,Motorboat\r
+STR_WATER_SUP,SUP\r
+STR_WATER_SCUBADIVING,Scuba diving\r
+STR_WATER_DIVING,Diving\r
+STR_WATER_KITESURFING,Kitesurfing\r
+STR_WATER_WAKEBOARDING,Wakeboarding\r
+STR_WATER_POLO,Water Polo\r
+STR_WATER_WINDSURFING,Windsurfing\r
+STR_WATER_DRIFTING,Drifting\r
+STR_WATER_FITNESS,Water fitness\r
+STR_WATER_SPORTS,Water sports\r
+STR_WATER_OUTDOORSWIM,Outdoor swim\r
+STR_WATER_INDOORSWIM,Indoor swim\r
+STR_WATER_SWIMFREESTYLE,Swim freestyle\r
+STR_WATER_SWIMBREASTSTROKE,Swim\r
+STR_WATER_SWIMBACKSTROKE,Swim\r
+STR_WATER_SWIMBUTTERFLY,Swim\r
+STR_ICE_SPORTS,Ice sports\r
+STR_ICE_SKATING,Skating\r
+STR_ICE_HOCKEY,Hockey\r
+STR_ICE_CURLING,Curling\r
+STR_ICE_SNOWMOBILING,Snow mobiling\r
+STR_ICE_SLED,Sled\r
+STR_ICE_BIATHLON,Biathlon\r
+STR_ICE_CROSSCOUNTRYSKING,Crosscountry sking\r
+STR_ICE_SKIING,Skiing\r
+STR_ICE_SNOWBOARDING,Snowboarding\r
+STR_ICE_SNOWSHOEING,Snowshoeing\r
+STR_ICE_SNOWSPORTS,Snow sport\r
+STR_EXTREME_SPORTS,Extreme sports\r
+STR_EXTREME_SKATEBOARDING,Skateboarding\r
+STR_EXTREME_ROCKCLIMBING,Rock climbing\r
+STR_EXTREME_BUNGEEJUMPING,Bungee Jumping\r
+STR_EXTREME_PARKOUR,Parkour\r
+STR_EXTREME_BMX,Bike motocross\r
+STR_EXTREME_ORIENTEERING,Orienteering\r
+STR_EXTREME_PARACHUTE,Parachute\r
+STR_EXTREME_RACING,Racing\r
+STR_EXTREME_TRIATHLONS,Triathlons\r
+STR_OTHER_ELEVATOR,Elevator\r
+STR_OTHER_ESCALATOR,Escalator\r
+STR_OTHER_GARDENING,Gardening\r
+STR_OTHER_HORSEWORK,House Work\r
+STR_OTHER_INVEHICLE,In Vehicle\r
+STR_OTHER_MEDITATION,Meditation\r
+STR_OTHER_STILL,Still\r
+STR_OTHER_TILTING,Tilting\r
+STR_OTHER_WHEELCHAIR,Wheelchair\r
--- /dev/null
+STR_EXERCISE_GENERAL,一般锻炼\r
+STR_EXERCISE_FREETRAINING,自由训练\r
+STR_EXERCISE_RESISTANCETRAINING,肌力训练\r
+STR_EXERCISE_SPINBIKE,飞轮车/室内健身车\r
+STR_EXERCISE_TREADMILL,踏步机\r
+STR_EXERCISE_STROLLMACHINE,漫步机\r
+STR_EXERCISE_HIIT,HIIT/高强度间歇训练\r
+STR_EXERCISE_CROSSFIT,健身\r
+STR_EXERCISE_GROUPCALISTHENICS,团体操\r
+STR_EXERCISE_YOGA,瑜珈\r
+STR_EXERCISE_YOGACAT,瑜珈猫式\r
+STR_EXERCISE_YOGACOW,瑜珈牛式\r
+STR_EXERCISE_YOGACOBRA,瑜珈眼镜蛇式\r
+STR_EXERCISE_YOGAHERO1,瑜珈英雄式1\r
+STR_EXERCISE_YOGAHERO2,瑜珈英雄式2\r
+STR_EXERCISE_YOGAHERO3,瑜珈英雄式3\r
+STR_EXERCISE_YOGAROLLING,瑜珈滚轮\r
+STR_EXERCISE_OUTDOORWALKING,室外走路\r
+STR_EXERCISE_OUTDOORRUNNING,室外跑步\r
+STR_EXERCISE_INDOORWALKING,室内走路\r
+STR_EXERCISE_INDOORRUNNING,室内跑步\r
+STR_EXERCISE_OUTDOORBIKING,室外骑行\r
+STR_EXERCISE_JUMPINGROPE,跳绳\r
+STR_EXERCISE_PILATES,皮拉提斯\r
+STR_EXERCISE_CROSS_FIT,混合健身\r
+STR_EXERCISE_FUNCTIONALTRAINING,功能性训练\r
+STR_EXERCISE_PHYSICALTRAINING,体能训练\r
+STR_EXERCISE_TAEKWONDO,跆拳道/踢拳\r
+STR_EXERCISE_BOXING,拳击\r
+STR_EXERCISE_KICKBOXING,自由搏击\r
+STR_EXERCISE_KARATE,空手道\r
+STR_EXERCISE_FENCING,击剑\r
+STR_EXERCISE_CORETRAINING,核心训练\r
+STR_EXERCISE_BODYCOMBAT,拳击有氧\r
+STR_EXERCISE_KENDO,剑道\r
+STR_EXERCISE_HORIZONTALBAR,单杠\r
+STR_EXERCISE_PARALLELBARS,双杠\r
+STR_EXERCISE_CROSSFIT,循环训练\r
+STR_EXERCISE_AEROBICS,有氧运动\r
+STR_EXERCISE_CALISTHENICE,健美操\r
+STR_EXERCISE_P90X,P90X\r
+STR_EXERCISE_KETTLEBELLTRAINING,壶铃训练\r
+STR_EXERCISE_MIXEDMARTIALARTS,综合格斗\r
+STR_EXERCISE_STAIRCLIMBINGMACHINE,爬楼梯机\r
+STR_EXERCISE_WEIGHTLIFTING,举重\r
+STR_EXERCISE_BARRE,Barre\r
+STR_EXERCISE_HANDCYCLING,手轮\r
+STR_EXERCISE_TRACKFIELD,田径\r
+STR_EXERCISE_WRESTLING,角力\r
+STR_EXERCISE_MINDBODY,身心运动\r
+STR_EXERCISE_FLEXIBILITY,柔软操\r
+STR_EXERCISE_MIXEDCARDIO,混和有氧\r
+STR_EXERCISE_TRADITIONALSTRENGTHTRAINING,传统肌力训练\r
+STR_EXERCISE_CROSSTRAINING,交叉训练\r
+STR_EXERCISE_GYMNASTICS,体操\r
+STR_EXERCISE_STEPTRAINING,阶梯训练\r
+STR_EXERCISE_ELLIPTICALTRAINER,椭圆机\r
+STR_EXERCISE_ROWINGMACHINE,划船机\r
+STR_DANCING_GENERAL,一般舞蹈\r
+STR_DANCING_BELLY,肚皮舞\r
+STR_DANCING_JAZZ,爵士舞\r
+STR_DANCING_LATIN,拉丁舞\r
+STR_DANCING_BALLET,芭蕾\r
+STR_DANCING_STREET,街舞\r
+STR_DANCING_PUBLICSQUARE,广场舞\r
+STR_DANCING_ZUMBA,尊巴\r
+STR_DANCING_SOCIALDANCE,社交舞\r
+STR_DANCING_TAPDANCE,踢踏舞\r
+STR_RECREATIONAL_SPORTS,一般休闲运动\r
+STR_RECREATIONAL_SKATING,滑轮溜冰\r
+STR_RECREATIONAL_MARTIALARTS,武术\r
+STR_RECREATIONAL_TAICHI,太极拳\r
+STR_RECREATIONAL_HULAHOOP,呼拉圈\r
+STR_RECREATIONAL_DISCSPORT,飞盘\r
+STR_RECREATIONAL_DARTS,飞镖\r
+STR_RECREATIONAL_ARCHERY,射箭\r
+STR_RECREATIONAL_HORSERIDING,骑马\r
+STR_RECREATIONAL_BATTLEGAME,对战游戏\r
+STR_RECREATIONAL_KITE,放风筝\r
+STR_RECREATIONAL_TUGOFWAR,拔河\r
+STR_RECREATIONAL_SWING,鞦韆\r
+STR_RECREATIONAL_STAIRCLIMBING,爬楼梯\r
+STR_RECREATIONAL_OBSTACLERACE,障碍赛\r
+STR_RECREATIONAL_FISHING,钓鱼\r
+STR_RECREATIONAL_HUNTING,打猎\r
+STR_RECREATIONAL_SCOOTERRIDING,滑板车\r
+STR_RECREATIONAL_PARAGLIDING,滑翔伞\r
+STR_RECREATIONAL_TEAMSPORTS,团队竞技\r
+STR_RECREATIONAL_FINESSGAMING,健身电玩\r
+STR_RECREATIONAL_HIKING,健行\r
+STR_RECREATIONAL_EQUESTRIANSPORTS,马术运动\r
+STR_RECREATIONAL_PLAY,玩乐\r
+STR_BALL_GAMES,一般球类运动\r
+STR_BALL_BADMINTON,羽毛球\r
+STR_BALL_TABLETENNIS,乒乓球\r
+STR_BALL_TENNIS,网球\r
+STR_BALL_BILLIARDS,撞球\r
+STR_BALL_BOWLING,保龄球\r
+STR_BALL_VOLLEYBALL,排球\r
+STR_BALL_SHUTTLECOCK,毽子球\r
+STR_BALL_HANDBALL,手球\r
+STR_BALL_BASEBALL,棒球\r
+STR_BALL_SOFTBALL,垒球\r
+STR_BALL_CRICKET,板球\r
+STR_BALL_FOOTBALL,美式橄榄球\r
+STR_BALL_BEACHSOCCER,沙滩足球\r
+STR_BALL_BEACHVOLLEYBALL,沙滩排球\r
+STR_BALL_CROQUET,槌球\r
+STR_BALL_HOCKEY,曲棍球\r
+STR_BALL_SQUASH,英式壁球\r
+STR_BALL_SEPAKTAKRAW,藤球\r
+STR_BALL_DODGEBALL,躲避球\r
+STR_BALL_BASKETBALL,篮球\r
+STR_BALL_SOCCER,足球\r
+STR_BALL_GOLF,高尔夫球\r
+STR_BALL_POLO,马球\r
+STR_BALL_RACQUETBALL,美式壁球\r
+STR_BALL_RUGBY,英式橄榄球\r
+STR_BALL_GATEBALL,门球\r
+STR_BALL_PICKLEBALL,匹克球\r
+STR_BALL_LACROSSE,袋棍球\r
+STR_WATER_ACTIVITIES,一般水上活动\r
+STR_WATER_SAILING,帆船\r
+STR_WATER_SURFING,冲浪\r
+STR_WATER_WHITEWATERRAFTING,泛舟\r
+STR_WATER_CANOEING,划龙舟\r
+STR_WATER_KAYAKING,轻艇\r
+STR_WATER_ROWING,赛艇\r
+STR_WATER_MOTORBOAT,水上摩托车\r
+STR_WATER_SUP,立桨冲浪\r
+STR_WATER_SCUBADIVING,潜水\r
+STR_WATER_DIVING,跳水\r
+STR_WATER_KITESURFING,滑翔伞冲浪\r
+STR_WATER_WAKEBOARDING,冲浪滑水\r
+STR_WATER_POLO,水球\r
+STR_WATER_WINDSURFING,风帆冲浪\r
+STR_WATER_DRIFTING,漂流活动\r
+STR_WATER_FITNESS,水中健身\r
+STR_WATER_SPORTS,水上运动\r
+STR_WATER_OUTDOORSWIM,户外游泳\r
+STR_WATER_INDOORSWIM,室内游泳\r
+STR_WATER_SWIMFREESTYLE,游泳_自由式\r
+STR_WATER_SWIMBREASTSTROKE,游泳_蛙式\r
+STR_WATER_SWIMBACKSTROKE,游泳_仰式\r
+STR_WATER_SWIMBUTTERFLY,游泳_蝶式\r
+STR_ICE_SPORTS,一般冰上运动\r
+STR_ICE_SKATING,溜冰\r
+STR_ICE_HOCKEY,冰球\r
+STR_ICE_CURLING,冰石壶/冰壶\r
+STR_ICE_SNOWMOBILING,雪上摩托车\r
+STR_ICE_SLED,雪橇\r
+STR_ICE_BIATHLON,冬季两项\r
+STR_ICE_CROSSCOUNTRYSKING,越野滑雪\r
+STR_ICE_SKIING,滑雪\r
+STR_ICE_SNOWBOARDING,单板滑雪/滑雪板\r
+STR_ICE_SNOWSHOEING,雪鞋健行\r
+STR_ICE_SNOWSPORTS,雪地运动\r
+STR_EXTREME_SPORTS,一般极限运动\r
+STR_EXTREME_SKATEBOARDING,滑板\r
+STR_EXTREME_ROCKCLIMBING,攀岩\r
+STR_EXTREME_BUNGEEJUMPING,高空弹跳/蹦极活动\r
+STR_EXTREME_PARKOUR,跑酷\r
+STR_EXTREME_BMX,BMX\r
+STR_EXTREME_ORIENTEERING,定向越野\r
+STR_EXTREME_PARACHUTE,跳伞\r
+STR_EXTREME_RACING,赛车\r
+STR_EXTREME_TRIATHLONS,铁人三项运动\r
+STR_OTHER_ELEVATOR,乘电梯\r
+STR_OTHER_ESCALATOR,乘手扶梯\r
+STR_OTHER_GARDENING,做园艺\r
+STR_OTHER_HORSEWORK,做家务\r
+STR_OTHER_INVEHICLE,在车里\r
+STR_OTHER_MEDITATION,冥想\r
+STR_OTHER_STILL,静止\r
+STR_OTHER_TILTING,倾斜\r
+STR_OTHER_WHEELCHAIR,坐轮椅移动
\ No newline at end of file
--- /dev/null
+<language id="language" direct="ltf" languageinfo="en">\r
+ <lanstr id="STR_EXERCISE_GENERAL" value="Exercise general"/>\r
+ <lanstr id="STR_EXERCISE_FREETRAINING" value="Free training"/>\r
+ <lanstr id="STR_EXERCISE_RESISTANCETRAINING" value="Resistance training"/>\r
+ <lanstr id="STR_EXERCISE_SPINBIKE" value="Spin bike"/>\r
+ <lanstr id="STR_EXERCISE_TREADMILL" value="Treadmill"/>\r
+ <lanstr id="STR_EXERCISE_STROLLMACHINE" value="Stroll machine"/>\r
+ <lanstr id="STR_EXERCISE_HIIT" value="High intense interval training"/>\r
+ <lanstr id="STR_EXERCISE_CROSSFIT" value="Crossfit"/>\r
+ <lanstr id="STR_EXERCISE_GROUPCALISTHENICS" value="Group calisthenics"/>\r
+ <lanstr id="STR_EXERCISE_YOGA" value="Yoga"/>\r
+ <lanstr id="STR_EXERCISE_YOGACAT" value="Yoga cat"/>\r
+ <lanstr id="STR_EXERCISE_YOGACOW" value="Yoga cow"/>\r
+ <lanstr id="STR_EXERCISE_YOGACOBRA" value="Yoga cobra"/>\r
+ <lanstr id="STR_EXERCISE_YOGAHERO1" value="Yoga hero1"/>\r
+ <lanstr id="STR_EXERCISE_YOGAHERO2" value="Yoga hero2"/>\r
+ <lanstr id="STR_EXERCISE_YOGAHERO3" value="Yoga hero3"/>\r
+ <lanstr id="STR_EXERCISE_YOGAROLLING" value="Yoga rolling"/>\r
+ <lanstr id="STR_EXERCISE_OUTDOORWALKING" value="Outdoor walking"/>\r
+ <lanstr id="STR_EXERCISE_OUTDOORRUNNING" value="Outdoor running"/>\r
+ <lanstr id="STR_EXERCISE_INDOORWALKING" value="Indoor walking"/>\r
+ <lanstr id="STR_EXERCISE_INDOORRUNNING" value="Indoor running"/>\r
+ <lanstr id="STR_EXERCISE_OUTDOORBIKING" value="Outdoor biking"/>\r
+ <lanstr id="STR_EXERCISE_JUMPINGROPE" value="Jumping rope"/>\r
+ <lanstr id="STR_EXERCISE_PILATES" value="Pilates"/>\r
+ <lanstr id="STR_EXERCISE_CROSS_FIT" value="Cross fit"/>\r
+ <lanstr id="STR_EXERCISE_FUNCTIONALTRAINING" value="Functional training"/>\r
+ <lanstr id="STR_EXERCISE_PHYSICALTRAINING" value="Physical Training"/>\r
+ <lanstr id="STR_EXERCISE_TAEKWONDO" value="Taekwondo"/>\r
+ <lanstr id="STR_EXERCISE_BOXING" value="Boxing"/>\r
+ <lanstr id="STR_EXERCISE_KICKBOXING" value="Kickboxing"/>\r
+ <lanstr id="STR_EXERCISE_KARATE" value="Karate"/>\r
+ <lanstr id="STR_EXERCISE_FENCING" value="Fencing"/>\r
+ <lanstr id="STR_EXERCISE_CORETRAINING" value="Core training"/>\r
+ <lanstr id="STR_EXERCISE_BODYCOMBAT" value="Body Combat"/>\r
+ <lanstr id="STR_EXERCISE_KENDO" value="Kendo"/>\r
+ <lanstr id="STR_EXERCISE_HORIZONTALBAR" value="Horizontal bar"/>\r
+ <lanstr id="STR_EXERCISE_PARALLELBARS" value="Parallel bars"/>\r
+ <lanstr id="STR_EXERCISE_CROSSFIT" value="Circuit training"/>\r
+ <lanstr id="STR_EXERCISE_AEROBICS" value="Aerobics"/>\r
+ <lanstr id="STR_EXERCISE_CALISTHENICE" value="Calisthenice"/>\r
+ <lanstr id="STR_EXERCISE_P90X" value="P90X"/>\r
+ <lanstr id="STR_EXERCISE_KETTLEBELLTRAINING" value="Kettlebell Training"/>\r
+ <lanstr id="STR_EXERCISE_MIXEDMARTIALARTS" value="Mixed martial arts"/>\r
+ <lanstr id="STR_EXERCISE_STAIRCLIMBINGMACHINE" value="Stair climbing machine"/>\r
+ <lanstr id="STR_EXERCISE_WEIGHTLIFTING" value="Weightlifting"/>\r
+ <lanstr id="STR_EXERCISE_BARRE" value="Barre"/>\r
+ <lanstr id="STR_EXERCISE_HANDCYCLING" value="Hand cycling"/>\r
+ <lanstr id="STR_EXERCISE_TRACKFIELD" value="Track field"/>\r
+ <lanstr id="STR_EXERCISE_WRESTLING" value="Wrestling"/>\r
+ <lanstr id="STR_EXERCISE_MINDBODY" value="Mind body"/>\r
+ <lanstr id="STR_EXERCISE_FLEXIBILITY" value="Flexibility"/>\r
+ <lanstr id="STR_EXERCISE_MIXEDCARDIO" value="Mixed cardio"/>\r
+ <lanstr id="STR_EXERCISE_TRADITIONALSTRENGTHTRAINING" value="Traditional strength training"/>\r
+ <lanstr id="STR_EXERCISE_CROSSTRAINING" value="Cross training"/>\r
+ <lanstr id="STR_EXERCISE_GYMNASTICS" value="Gymnastics"/>\r
+ <lanstr id="STR_EXERCISE_STEPTRAINING" value="Step training"/>\r
+ <lanstr id="STR_EXERCISE_ELLIPTICALTRAINER" value="Elliptical trainer"/>\r
+ <lanstr id="STR_EXERCISE_ROWINGMACHINE" value="Rowing machine"/>\r
+ <lanstr id="STR_DANCING_GENERAL" value="Dancing general"/>\r
+ <lanstr id="STR_DANCING_BELLY" value="Belly dance"/>\r
+ <lanstr id="STR_DANCING_JAZZ" value="Jazz dance"/>\r
+ <lanstr id="STR_DANCING_LATIN" value="Latin dance"/>\r
+ <lanstr id="STR_DANCING_BALLET" value="Ballet dance"/>\r
+ <lanstr id="STR_DANCING_STREET" value="Street dance"/>\r
+ <lanstr id="STR_DANCING_PUBLICSQUARE" value="Public square dancing"/>\r
+ <lanstr id="STR_DANCING_ZUMBA" value="Zumba"/>\r
+ <lanstr id="STR_DANCING_SOCIALDANCE" value="Social dance"/>\r
+ <lanstr id="STR_DANCING_TAPDANCE" value="Tap dance"/>\r
+ <lanstr id="STR_RECREATIONAL_SPORTS" value="Recreational Sports"/>\r
+ <lanstr id="STR_RECREATIONAL_SKATING" value="Roller Skating"/>\r
+ <lanstr id="STR_RECREATIONAL_MARTIALARTS" value="Martial arts"/>\r
+ <lanstr id="STR_RECREATIONAL_TAICHI" value="Tai Chi"/>\r
+ <lanstr id="STR_RECREATIONAL_HULAHOOP" value="Hula hoop"/>\r
+ <lanstr id="STR_RECREATIONAL_DISCSPORT" value="Disc sport"/>\r
+ <lanstr id="STR_RECREATIONAL_DARTS" value="Darts"/>\r
+ <lanstr id="STR_RECREATIONAL_ARCHERY" value="Archery"/>\r
+ <lanstr id="STR_RECREATIONAL_HORSERIDING" value="Horse riding"/>\r
+ <lanstr id="STR_RECREATIONAL_BATTLEGAME" value="Battle game"/>\r
+ <lanstr id="STR_RECREATIONAL_KITE" value="Fly a kite"/>\r
+ <lanstr id="STR_RECREATIONAL_TUGOFWAR" value="Tug of war"/>\r
+ <lanstr id="STR_RECREATIONAL_SWING" value="Swing"/>\r
+ <lanstr id="STR_RECREATIONAL_STAIRCLIMBING" value="Stair climbing"/>\r
+ <lanstr id="STR_RECREATIONAL_OBSTACLERACE" value="Obstacle race"/>\r
+ <lanstr id="STR_RECREATIONAL_FISHING" value="Fishing"/>\r
+ <lanstr id="STR_RECREATIONAL_HUNTING" value="Hunting"/>\r
+ <lanstr id="STR_RECREATIONAL_SCOOTERRIDING" value="Scooter Riding"/>\r
+ <lanstr id="STR_RECREATIONAL_PARAGLIDING" value="Paragliding"/>\r
+ <lanstr id="STR_RECREATIONAL_TEAMSPORTS" value="Team sports"/>\r
+ <lanstr id="STR_RECREATIONAL_FINESSGAMING" value="Finess gaming"/>\r
+ <lanstr id="STR_RECREATIONAL_HIKING" value="Hiking"/>\r
+ <lanstr id="STR_RECREATIONAL_EQUESTRIANSPORTS" value="Equestrian sports"/>\r
+ <lanstr id="STR_RECREATIONAL_PLAY" value="Play"/>\r
+ <lanstr id="STR_BALL_GAMES" value="Ball games"/>\r
+ <lanstr id="STR_BALL_BADMINTON" value="Badminton"/>\r
+ <lanstr id="STR_BALL_TABLETENNIS" value="Table tennis"/>\r
+ <lanstr id="STR_BALL_TENNIS" value="Tennis"/>\r
+ <lanstr id="STR_BALL_BILLIARDS" value="Billiards"/>\r
+ <lanstr id="STR_BALL_BOWLING" value="Bowling"/>\r
+ <lanstr id="STR_BALL_VOLLEYBALL" value="Volleyball"/>\r
+ <lanstr id="STR_BALL_SHUTTLECOCK" value="Shuttlecock"/>\r
+ <lanstr id="STR_BALL_HANDBALL" value="Handball"/>\r
+ <lanstr id="STR_BALL_BASEBALL" value="Baseball"/>\r
+ <lanstr id="STR_BALL_SOFTBALL" value="Softball"/>\r
+ <lanstr id="STR_BALL_CRICKET" value="Cricket"/>\r
+ <lanstr id="STR_BALL_FOOTBALL" value="Football"/>\r
+ <lanstr id="STR_BALL_BEACHSOCCER" value="Beach soccer"/>\r
+ <lanstr id="STR_BALL_BEACHVOLLEYBALL" value="Beach volleyball"/>\r
+ <lanstr id="STR_BALL_CROQUET" value="Croquet"/>\r
+ <lanstr id="STR_BALL_HOCKEY" value="Hockey"/>\r
+ <lanstr id="STR_BALL_SQUASH" value="Squash"/>\r
+ <lanstr id="STR_BALL_SEPAKTAKRAW" value="Sepak takraw"/>\r
+ <lanstr id="STR_BALL_DODGEBALL" value="Dodge ball"/>\r
+ <lanstr id="STR_BALL_BASKETBALL" value="Basketball"/>\r
+ <lanstr id="STR_BALL_SOCCER" value="Soccer"/>\r
+ <lanstr id="STR_BALL_GOLF" value="Golf"/>\r
+ <lanstr id="STR_BALL_POLO" value="Polo"/>\r
+ <lanstr id="STR_BALL_RACQUETBALL" value="Racquetball"/>\r
+ <lanstr id="STR_BALL_RUGBY" value="Rugby"/>\r
+ <lanstr id="STR_BALL_GATEBALL" value="Gateball"/>\r
+ <lanstr id="STR_BALL_PICKLEBALL" value="Pickleball"/>\r
+ <lanstr id="STR_BALL_LACROSSE" value="Lacrosse"/>\r
+ <lanstr id="STR_WATER_ACTIVITIES" value="Water activities"/>\r
+ <lanstr id="STR_WATER_SAILING" value="Sailing"/>\r
+ <lanstr id="STR_WATER_SURFING" value="Surfing"/>\r
+ <lanstr id="STR_WATER_WHITEWATERRAFTING" value="Whitewater rafting"/>\r
+ <lanstr id="STR_WATER_CANOEING" value="Canoeing"/>\r
+ <lanstr id="STR_WATER_KAYAKING" value="Kayaking"/>\r
+ <lanstr id="STR_WATER_ROWING" value="Rowing"/>\r
+ <lanstr id="STR_WATER_MOTORBOAT" value="Motorboat"/>\r
+ <lanstr id="STR_WATER_SUP" value="SUP"/>\r
+ <lanstr id="STR_WATER_SCUBADIVING" value="Scuba diving"/>\r
+ <lanstr id="STR_WATER_DIVING" value="Diving"/>\r
+ <lanstr id="STR_WATER_KITESURFING" value="Kitesurfing"/>\r
+ <lanstr id="STR_WATER_WAKEBOARDING" value="Wakeboarding"/>\r
+ <lanstr id="STR_WATER_POLO" value="Water Polo"/>\r
+ <lanstr id="STR_WATER_WINDSURFING" value="Windsurfing"/>\r
+ <lanstr id="STR_WATER_DRIFTING" value="Drifting"/>\r
+ <lanstr id="STR_WATER_FITNESS" value="Water fitness"/>\r
+ <lanstr id="STR_WATER_SPORTS" value="Water sports"/>\r
+ <lanstr id="STR_WATER_OUTDOORSWIM" value="Outdoor swim"/>\r
+ <lanstr id="STR_WATER_INDOORSWIM" value="Indoor swim"/>\r
+ <lanstr id="STR_WATER_SWIMFREESTYLE" value="Swim freestyle"/>\r
+ <lanstr id="STR_WATER_SWIMBREASTSTROKE" value="Swim"/>\r
+ <lanstr id="STR_WATER_SWIMBACKSTROKE" value="Swim"/>\r
+ <lanstr id="STR_WATER_SWIMBUTTERFLY" value="Swim"/>\r
+ <lanstr id="STR_ICE_SPORTS" value="Ice sports"/>\r
+ <lanstr id="STR_ICE_SKATING" value="Skating"/>\r
+ <lanstr id="STR_ICE_HOCKEY" value="Hockey"/>\r
+ <lanstr id="STR_ICE_CURLING" value="Curling"/>\r
+ <lanstr id="STR_ICE_SNOWMOBILING" value="Snow mobiling"/>\r
+ <lanstr id="STR_ICE_SLED" value="Sled"/>\r
+ <lanstr id="STR_ICE_BIATHLON" value="Biathlon"/>\r
+ <lanstr id="STR_ICE_CROSSCOUNTRYSKING" value="Crosscountry sking"/>\r
+ <lanstr id="STR_ICE_SKIING" value="Skiing"/>\r
+ <lanstr id="STR_ICE_SNOWBOARDING" value="Snowboarding"/>\r
+ <lanstr id="STR_ICE_SNOWSHOEING" value="Snowshoeing"/>\r
+ <lanstr id="STR_ICE_SNOWSPORTS" value="Snow sport"/>\r
+ <lanstr id="STR_EXTREME_SPORTS" value="Extreme sports"/>\r
+ <lanstr id="STR_EXTREME_SKATEBOARDING" value="Skateboarding"/>\r
+ <lanstr id="STR_EXTREME_ROCKCLIMBING" value="Rock climbing"/>\r
+ <lanstr id="STR_EXTREME_BUNGEEJUMPING" value="Bungee Jumping"/>\r
+ <lanstr id="STR_EXTREME_PARKOUR" value="Parkour"/>\r
+ <lanstr id="STR_EXTREME_BMX" value="Bike motocross"/>\r
+ <lanstr id="STR_EXTREME_ORIENTEERING" value="Orienteering"/>\r
+ <lanstr id="STR_EXTREME_PARACHUTE" value="Parachute"/>\r
+ <lanstr id="STR_EXTREME_RACING" value="Racing"/>\r
+ <lanstr id="STR_EXTREME_TRIATHLONS" value="Triathlons"/>\r
+ <lanstr id="STR_OTHER_ELEVATOR" value="Elevator"/>\r
+ <lanstr id="STR_OTHER_ESCALATOR" value="Escalator"/>\r
+ <lanstr id="STR_OTHER_GARDENING" value="Gardening"/>\r
+ <lanstr id="STR_OTHER_HORSEWORK" value="House Work"/>\r
+ <lanstr id="STR_OTHER_INVEHICLE" value="In Vehicle"/>\r
+ <lanstr id="STR_OTHER_MEDITATION" value="Meditation"/>\r
+ <lanstr id="STR_OTHER_STILL" value="Still"/>\r
+ <lanstr id="STR_OTHER_TILTING" value="Tilting"/>\r
+ <lanstr id="STR_OTHER_WHEELCHAIR" value="Wheelchair"/>\r
+</language>\r
--- /dev/null
+<language id="language" direct="ltf" languageinfo="zh">\r
+ <lanstr id="STR_EXERCISE_GENERAL" value="一般锻炼"/>\r
+ <lanstr id="STR_EXERCISE_FREETRAINING" value="自由训练"/>\r
+ <lanstr id="STR_EXERCISE_RESISTANCETRAINING" value="肌力训练"/>\r
+ <lanstr id="STR_EXERCISE_SPINBIKE" value="飞轮车/室内健身车"/>\r
+ <lanstr id="STR_EXERCISE_TREADMILL" value="踏步机"/>\r
+ <lanstr id="STR_EXERCISE_STROLLMACHINE" value="漫步机"/>\r
+ <lanstr id="STR_EXERCISE_HIIT" value="HIIT/高强度间歇训练"/>\r
+ <lanstr id="STR_EXERCISE_CROSSFIT" value="健身"/>\r
+ <lanstr id="STR_EXERCISE_GROUPCALISTHENICS" value="团体操"/>\r
+ <lanstr id="STR_EXERCISE_YOGA" value="瑜珈"/>\r
+ <lanstr id="STR_EXERCISE_YOGACAT" value="瑜珈猫式"/>\r
+ <lanstr id="STR_EXERCISE_YOGACOW" value="瑜珈牛式"/>\r
+ <lanstr id="STR_EXERCISE_YOGACOBRA" value="瑜珈眼镜蛇式"/>\r
+ <lanstr id="STR_EXERCISE_YOGAHERO1" value="瑜珈英雄式1"/>\r
+ <lanstr id="STR_EXERCISE_YOGAHERO2" value="瑜珈英雄式2"/>\r
+ <lanstr id="STR_EXERCISE_YOGAHERO3" value="瑜珈英雄式3"/>\r
+ <lanstr id="STR_EXERCISE_YOGAROLLING" value="瑜珈滚轮"/>\r
+ <lanstr id="STR_EXERCISE_OUTDOORWALKING" value="室外走路"/>\r
+ <lanstr id="STR_EXERCISE_OUTDOORRUNNING" value="室外跑步"/>\r
+ <lanstr id="STR_EXERCISE_INDOORWALKING" value="室内走路"/>\r
+ <lanstr id="STR_EXERCISE_INDOORRUNNING" value="室内跑步"/>\r
+ <lanstr id="STR_EXERCISE_OUTDOORBIKING" value="室外骑行"/>\r
+ <lanstr id="STR_EXERCISE_JUMPINGROPE" value="跳绳"/>\r
+ <lanstr id="STR_EXERCISE_PILATES" value="皮拉提斯"/>\r
+ <lanstr id="STR_EXERCISE_CROSS_FIT" value="混合健身"/>\r
+ <lanstr id="STR_EXERCISE_FUNCTIONALTRAINING" value="功能性训练"/>\r
+ <lanstr id="STR_EXERCISE_PHYSICALTRAINING" value="体能训练"/>\r
+ <lanstr id="STR_EXERCISE_TAEKWONDO" value="跆拳道/踢拳"/>\r
+ <lanstr id="STR_EXERCISE_BOXING" value="拳击"/>\r
+ <lanstr id="STR_EXERCISE_KICKBOXING" value="自由搏击"/>\r
+ <lanstr id="STR_EXERCISE_KARATE" value="空手道"/>\r
+ <lanstr id="STR_EXERCISE_FENCING" value="击剑"/>\r
+ <lanstr id="STR_EXERCISE_CORETRAINING" value="核心训练"/>\r
+ <lanstr id="STR_EXERCISE_BODYCOMBAT" value="拳击有氧"/>\r
+ <lanstr id="STR_EXERCISE_KENDO" value="剑道"/>\r
+ <lanstr id="STR_EXERCISE_HORIZONTALBAR" value="单杠"/>\r
+ <lanstr id="STR_EXERCISE_PARALLELBARS" value="双杠"/>\r
+ <lanstr id="STR_EXERCISE_CROSSFIT" value="循环训练"/>\r
+ <lanstr id="STR_EXERCISE_AEROBICS" value="有氧运动"/>\r
+ <lanstr id="STR_EXERCISE_CALISTHENICE" value="健美操"/>\r
+ <lanstr id="STR_EXERCISE_P90X" value="P90X"/>\r
+ <lanstr id="STR_EXERCISE_KETTLEBELLTRAINING" value="壶铃训练"/>\r
+ <lanstr id="STR_EXERCISE_MIXEDMARTIALARTS" value="综合格斗"/>\r
+ <lanstr id="STR_EXERCISE_STAIRCLIMBINGMACHINE" value="爬楼梯机"/>\r
+ <lanstr id="STR_EXERCISE_WEIGHTLIFTING" value="举重"/>\r
+ <lanstr id="STR_EXERCISE_BARRE" value="Barre"/>\r
+ <lanstr id="STR_EXERCISE_HANDCYCLING" value="手轮"/>\r
+ <lanstr id="STR_EXERCISE_TRACKFIELD" value="田径"/>\r
+ <lanstr id="STR_EXERCISE_WRESTLING" value="角力"/>\r
+ <lanstr id="STR_EXERCISE_MINDBODY" value="身心运动"/>\r
+ <lanstr id="STR_EXERCISE_FLEXIBILITY" value="柔软操"/>\r
+ <lanstr id="STR_EXERCISE_MIXEDCARDIO" value="混和有氧"/>\r
+ <lanstr id="STR_EXERCISE_TRADITIONALSTRENGTHTRAINING" value="传统肌力训练"/>\r
+ <lanstr id="STR_EXERCISE_CROSSTRAINING" value="交叉训练"/>\r
+ <lanstr id="STR_EXERCISE_GYMNASTICS" value="体操"/>\r
+ <lanstr id="STR_EXERCISE_STEPTRAINING" value="阶梯训练"/>\r
+ <lanstr id="STR_EXERCISE_ELLIPTICALTRAINER" value="椭圆机"/>\r
+ <lanstr id="STR_EXERCISE_ROWINGMACHINE" value="划船机"/>\r
+ <lanstr id="STR_DANCING_GENERAL" value="一般舞蹈"/>\r
+ <lanstr id="STR_DANCING_BELLY" value="肚皮舞"/>\r
+ <lanstr id="STR_DANCING_JAZZ" value="爵士舞"/>\r
+ <lanstr id="STR_DANCING_LATIN" value="拉丁舞"/>\r
+ <lanstr id="STR_DANCING_BALLET" value="芭蕾"/>\r
+ <lanstr id="STR_DANCING_STREET" value="街舞"/>\r
+ <lanstr id="STR_DANCING_PUBLICSQUARE" value="广场舞"/>\r
+ <lanstr id="STR_DANCING_ZUMBA" value="尊巴"/>\r
+ <lanstr id="STR_DANCING_SOCIALDANCE" value="社交舞"/>\r
+ <lanstr id="STR_DANCING_TAPDANCE" value="踢踏舞"/>\r
+ <lanstr id="STR_RECREATIONAL_SPORTS" value="一般休闲运动"/>\r
+ <lanstr id="STR_RECREATIONAL_SKATING" value="滑轮溜冰"/>\r
+ <lanstr id="STR_RECREATIONAL_MARTIALARTS" value="武术"/>\r
+ <lanstr id="STR_RECREATIONAL_TAICHI" value="太极拳"/>\r
+ <lanstr id="STR_RECREATIONAL_HULAHOOP" value="呼拉圈"/>\r
+ <lanstr id="STR_RECREATIONAL_DISCSPORT" value="飞盘"/>\r
+ <lanstr id="STR_RECREATIONAL_DARTS" value="飞镖"/>\r
+ <lanstr id="STR_RECREATIONAL_ARCHERY" value="射箭"/>\r
+ <lanstr id="STR_RECREATIONAL_HORSERIDING" value="骑马"/>\r
+ <lanstr id="STR_RECREATIONAL_BATTLEGAME" value="对战游戏"/>\r
+ <lanstr id="STR_RECREATIONAL_KITE" value="放风筝"/>\r
+ <lanstr id="STR_RECREATIONAL_TUGOFWAR" value="拔河"/>\r
+ <lanstr id="STR_RECREATIONAL_SWING" value="鞦韆"/>\r
+ <lanstr id="STR_RECREATIONAL_STAIRCLIMBING" value="爬楼梯"/>\r
+ <lanstr id="STR_RECREATIONAL_OBSTACLERACE" value="障碍赛"/>\r
+ <lanstr id="STR_RECREATIONAL_FISHING" value="钓鱼"/>\r
+ <lanstr id="STR_RECREATIONAL_HUNTING" value="打猎"/>\r
+ <lanstr id="STR_RECREATIONAL_SCOOTERRIDING" value="滑板车"/>\r
+ <lanstr id="STR_RECREATIONAL_PARAGLIDING" value="滑翔伞"/>\r
+ <lanstr id="STR_RECREATIONAL_TEAMSPORTS" value="团队竞技"/>\r
+ <lanstr id="STR_RECREATIONAL_FINESSGAMING" value="健身电玩"/>\r
+ <lanstr id="STR_RECREATIONAL_HIKING" value="健行"/>\r
+ <lanstr id="STR_RECREATIONAL_EQUESTRIANSPORTS" value="马术运动"/>\r
+ <lanstr id="STR_RECREATIONAL_PLAY" value="玩乐"/>\r
+ <lanstr id="STR_BALL_GAMES" value="一般球类运动"/>\r
+ <lanstr id="STR_BALL_BADMINTON" value="羽毛球"/>\r
+ <lanstr id="STR_BALL_TABLETENNIS" value="乒乓球"/>\r
+ <lanstr id="STR_BALL_TENNIS" value="网球"/>\r
+ <lanstr id="STR_BALL_BILLIARDS" value="撞球"/>\r
+ <lanstr id="STR_BALL_BOWLING" value="保龄球"/>\r
+ <lanstr id="STR_BALL_VOLLEYBALL" value="排球"/>\r
+ <lanstr id="STR_BALL_SHUTTLECOCK" value="毽子球"/>\r
+ <lanstr id="STR_BALL_HANDBALL" value="手球"/>\r
+ <lanstr id="STR_BALL_BASEBALL" value="棒球"/>\r
+ <lanstr id="STR_BALL_SOFTBALL" value="垒球"/>\r
+ <lanstr id="STR_BALL_CRICKET" value="板球"/>\r
+ <lanstr id="STR_BALL_FOOTBALL" value="美式橄榄球"/>\r
+ <lanstr id="STR_BALL_BEACHSOCCER" value="沙滩足球"/>\r
+ <lanstr id="STR_BALL_BEACHVOLLEYBALL" value="沙滩排球"/>\r
+ <lanstr id="STR_BALL_CROQUET" value="槌球"/>\r
+ <lanstr id="STR_BALL_HOCKEY" value="曲棍球"/>\r
+ <lanstr id="STR_BALL_SQUASH" value="英式壁球"/>\r
+ <lanstr id="STR_BALL_SEPAKTAKRAW" value="藤球"/>\r
+ <lanstr id="STR_BALL_DODGEBALL" value="躲避球"/>\r
+ <lanstr id="STR_BALL_BASKETBALL" value="篮球"/>\r
+ <lanstr id="STR_BALL_SOCCER" value="足球"/>\r
+ <lanstr id="STR_BALL_GOLF" value="高尔夫球"/>\r
+ <lanstr id="STR_BALL_POLO" value="马球"/>\r
+ <lanstr id="STR_BALL_RACQUETBALL" value="美式壁球"/>\r
+ <lanstr id="STR_BALL_RUGBY" value="英式橄榄球"/>\r
+ <lanstr id="STR_BALL_GATEBALL" value="门球"/>\r
+ <lanstr id="STR_BALL_PICKLEBALL" value="匹克球"/>\r
+ <lanstr id="STR_BALL_LACROSSE" value="袋棍球"/>\r
+ <lanstr id="STR_WATER_ACTIVITIES" value="一般水上活动"/>\r
+ <lanstr id="STR_WATER_SAILING" value="帆船"/>\r
+ <lanstr id="STR_WATER_SURFING" value="冲浪"/>\r
+ <lanstr id="STR_WATER_WHITEWATERRAFTING" value="泛舟"/>\r
+ <lanstr id="STR_WATER_CANOEING" value="划龙舟"/>\r
+ <lanstr id="STR_WATER_KAYAKING" value="轻艇"/>\r
+ <lanstr id="STR_WATER_ROWING" value="赛艇"/>\r
+ <lanstr id="STR_WATER_MOTORBOAT" value="水上摩托车"/>\r
+ <lanstr id="STR_WATER_SUP" value="立桨冲浪"/>\r
+ <lanstr id="STR_WATER_SCUBADIVING" value="潜水"/>\r
+ <lanstr id="STR_WATER_DIVING" value="跳水"/>\r
+ <lanstr id="STR_WATER_KITESURFING" value="滑翔伞冲浪"/>\r
+ <lanstr id="STR_WATER_WAKEBOARDING" value="冲浪滑水"/>\r
+ <lanstr id="STR_WATER_POLO" value="水球"/>\r
+ <lanstr id="STR_WATER_WINDSURFING" value="风帆冲浪"/>\r
+ <lanstr id="STR_WATER_DRIFTING" value="漂流活动"/>\r
+ <lanstr id="STR_WATER_FITNESS" value="水中健身"/>\r
+ <lanstr id="STR_WATER_SPORTS" value="水上运动"/>\r
+ <lanstr id="STR_WATER_OUTDOORSWIM" value="户外游泳"/>\r
+ <lanstr id="STR_WATER_INDOORSWIM" value="室内游泳"/>\r
+ <lanstr id="STR_WATER_SWIMFREESTYLE" value="游泳_自由式"/>\r
+ <lanstr id="STR_WATER_SWIMBREASTSTROKE" value="游泳_蛙式"/>\r
+ <lanstr id="STR_WATER_SWIMBACKSTROKE" value="游泳_仰式"/>\r
+ <lanstr id="STR_WATER_SWIMBUTTERFLY" value="游泳_蝶式"/>\r
+ <lanstr id="STR_ICE_SPORTS" value="一般冰上运动"/>\r
+ <lanstr id="STR_ICE_SKATING" value="溜冰"/>\r
+ <lanstr id="STR_ICE_HOCKEY" value="冰球"/>\r
+ <lanstr id="STR_ICE_CURLING" value="冰石壶/冰壶"/>\r
+ <lanstr id="STR_ICE_SNOWMOBILING" value="雪上摩托车"/>\r
+ <lanstr id="STR_ICE_SLED" value="雪橇"/>\r
+ <lanstr id="STR_ICE_BIATHLON" value="冬季两项"/>\r
+ <lanstr id="STR_ICE_CROSSCOUNTRYSKING" value="越野滑雪"/>\r
+ <lanstr id="STR_ICE_SKIING" value="滑雪"/>\r
+ <lanstr id="STR_ICE_SNOWBOARDING" value="单板滑雪/滑雪板"/>\r
+ <lanstr id="STR_ICE_SNOWSHOEING" value="雪鞋健行"/>\r
+ <lanstr id="STR_ICE_SNOWSPORTS" value="雪地运动"/>\r
+ <lanstr id="STR_EXTREME_SPORTS" value="一般极限运动"/>\r
+ <lanstr id="STR_EXTREME_SKATEBOARDING" value="滑板"/>\r
+ <lanstr id="STR_EXTREME_ROCKCLIMBING" value="攀岩"/>\r
+ <lanstr id="STR_EXTREME_BUNGEEJUMPING" value="高空弹跳/蹦极活动"/>\r
+ <lanstr id="STR_EXTREME_PARKOUR" value="跑酷"/>\r
+ <lanstr id="STR_EXTREME_BMX" value="BMX"/>\r
+ <lanstr id="STR_EXTREME_ORIENTEERING" value="定向越野"/>\r
+ <lanstr id="STR_EXTREME_PARACHUTE" value="跳伞"/>\r
+ <lanstr id="STR_EXTREME_RACING" value="赛车"/>\r
+ <lanstr id="STR_EXTREME_TRIATHLONS" value="铁人三项运动"/>\r
+ <lanstr id="STR_OTHER_ELEVATOR" value="乘电梯"/>\r
+ <lanstr id="STR_OTHER_ESCALATOR" value="乘手扶梯"/>\r
+ <lanstr id="STR_OTHER_GARDENING" value="做园艺"/>\r
+ <lanstr id="STR_OTHER_HORSEWORK" value="做家务"/>\r
+ <lanstr id="STR_OTHER_INVEHICLE" value="在车里"/>\r
+ <lanstr id="STR_OTHER_MEDITATION" value="冥想"/>\r
+ <lanstr id="STR_OTHER_STILL" value="静止"/>\r
+ <lanstr id="STR_OTHER_TILTING" value="倾斜"/>\r
+ <lanstr id="STR_OTHER_WHEELCHAIR" value="坐轮椅移动"/>\r
+</language>\r
--- /dev/null
+
+import xml.dom.minidom
+
+# 从外部文件读取列表数据
+def read_list_from_file(file_path):
+ with open(file_path, "r", encoding="utf-8") as f:
+ lines = f.readlines()
+ input_list = [line.strip().split(",") for line in lines]
+ return input_list
+
+# 生成 XML 文件
+def generate_xml_from_list(input_list, output_file, lang):
+ dom = xml.dom.minidom.getDOMImplementation().createDocument(None, "language", None)
+ root = dom.documentElement
+ root.setAttribute("id", "language")
+ root.setAttribute("direct", "ltr")
+ root.setAttribute("languageinfo", lang)
+
+ for item in input_list:
+ key = item[0]
+ value = item[1]
+
+ lanstr_element = dom.createElement("lanstr")
+ lanstr_element.setAttribute("id", key)
+ lanstr_element.setAttribute("value", value)
+ root.appendChild(lanstr_element)
+
+ with open(output_file, "w", encoding="utf-8") as f:
+ f.write(root.toprettyxml())
+
+
+# 从外部文件读取不同语言的列表数据
+input_list_en = read_list_from_file("./input_list_en.txt")
+input_list_zh = read_list_from_file("./input_list_zh.txt")
+
+# 生成不同语言的 XML 文件
+generate_xml_from_list(input_list_en, "./language_en.xml", "en")
+generate_xml_from_list(input_list_zh, "./language_zh.xml", "zh")
+
+print("XML文件生成完成。")
--- /dev/null
+## 多国语言工具脚本使用方法\r
+\r
+### 1.下载打包工具\r
+\r
+\tools\string_packer 属于DebugKit里面的tool\r
+\r
+同时新建文件夹font\r
+\r
+### 2.下载脚本文件\r
+\r
+将**【Language_xml】**下载到打包工具里面\r
+\r
+【Language_xml】文件夹包含:\r
+\r
+```c\r
+ languagetool.py: 生成xml脚本\r
+\r
+ language_zh.xml: 中文xml(使用脚本可生成)\r
+\r
+ language_eh.xml: 英语xml(使用脚本可生成)\r
+\r
+ input_list_zh.txt: 中文语言列表 \r
+ 里面可以直接输入键和建值:比如:STR_ICE_SPORTS,冰上运动\r
+ input_list_en.txt: 英语语言列表 (同上)\r
+```\r
+\r
+### 3.使用方法\r
+\r
+在\tools\string_packer\Language_xml目录下使用cmd:\r
+\r
+输入以下指令将脚本增加权限:\r
+\r
+```\r
+ icacls languagetool.py /grant Everyone:F\r
+```\r
+\r
+使用指令运行脚本:\r
+\r
+```\r
+ python languagetool.py\r
+```\r
+\r
+文件夹里面生成两个xml文件。\r
+\r
+在**DebugKit**里面\r
+\r
+选择“system”->"string packer"\r
+\r
+```c\r
+python file: /tools/string_packer/language_trans.py\r
+\r
+File path: /tools/string_packer/Language_xml\r
+\r
+Output Path: /tools/string_packer/font\r
+```\r
+\r
+点击Execute生成:生成的font文件夹里面的内容**需要同步到代码以及res资源库**\r
+\r
+代码路径:application/wearable/fd230app/nativeui/language/font\r
+\r
+res路径: \FD230\code\sdk\build\config\target_config\brandy\mk_fs_image\fd230\fs\user\res\font\r
+\r
+\r
+\r
+【完成多国语言文件配置】
\ No newline at end of file
--- /dev/null
+/*
+* Copyright (c) xxxxxxxx Technologies Co., Ltd. 2021-2021. All rights reserved.
+* Description: language
+* Author: Graphic develop team
+* Create: 2021-07-06
+*/
+
+#ifndef UI_RESOURCE_STRING_H
+#define UI_RESOURCE_STRING_H
+#include <cstdint>
+namespace OHOS {
+enum UIResourceTextId : uint16_t {
+ STR_EXERCISE_GENERAL = 0,\r
+ STR_EXERCISE_FREETRAINING = 1,\r
+ STR_EXERCISE_RESISTANCETRAINING = 2,\r
+ STR_EXERCISE_SPINBIKE = 3,\r
+ STR_EXERCISE_TREADMILL = 4,\r
+ STR_EXERCISE_STROLLMACHINE = 5,\r
+ STR_EXERCISE_HIIT = 6,\r
+ STR_EXERCISE_CROSSFIT = 7,\r
+ STR_EXERCISE_GROUPCALISTHENICS = 8,\r
+ STR_EXERCISE_YOGA = 9,\r
+ STR_EXERCISE_YOGACAT = 10,\r
+ STR_EXERCISE_YOGACOW = 11,\r
+ STR_EXERCISE_YOGACOBRA = 12,\r
+ STR_EXERCISE_YOGAHERO1 = 13,\r
+ STR_EXERCISE_YOGAHERO2 = 14,\r
+ STR_EXERCISE_YOGAHERO3 = 15,\r
+ STR_EXERCISE_YOGAROLLING = 16,\r
+ STR_EXERCISE_OUTDOORWALKING = 17,\r
+ STR_EXERCISE_OUTDOORRUNNING = 18,\r
+ STR_EXERCISE_INDOORWALKING = 19,\r
+ STR_EXERCISE_INDOORRUNNING = 20,\r
+ STR_EXERCISE_OUTDOORBIKING = 21,\r
+ STR_EXERCISE_JUMPINGROPE = 22,\r
+ STR_EXERCISE_PILATES = 23,\r
+ STR_EXERCISE_CROSS_FIT = 24,\r
+ STR_EXERCISE_FUNCTIONALTRAINING = 25,\r
+ STR_EXERCISE_PHYSICALTRAINING = 26,\r
+ STR_EXERCISE_TAEKWONDO = 27,\r
+ STR_EXERCISE_BOXING = 28,\r
+ STR_EXERCISE_KICKBOXING = 29,\r
+ STR_EXERCISE_KARATE = 30,\r
+ STR_EXERCISE_FENCING = 31,\r
+ STR_EXERCISE_CORETRAINING = 32,\r
+ STR_EXERCISE_BODYCOMBAT = 33,\r
+ STR_EXERCISE_KENDO = 34,\r
+ STR_EXERCISE_HORIZONTALBAR = 35,\r
+ STR_EXERCISE_PARALLELBARS = 36,\r
+ STR_EXERCISE_AEROBICS = 37,\r
+ STR_EXERCISE_CALISTHENICE = 38,\r
+ STR_EXERCISE_P90X = 39,\r
+ STR_EXERCISE_KETTLEBELLTRAINING = 40,\r
+ STR_EXERCISE_MIXEDMARTIALARTS = 41,\r
+ STR_EXERCISE_STAIRCLIMBINGMACHINE = 42,\r
+ STR_EXERCISE_WEIGHTLIFTING = 43,\r
+ STR_EXERCISE_BARRE = 44,\r
+ STR_EXERCISE_HANDCYCLING = 45,\r
+ STR_EXERCISE_TRACKFIELD = 46,\r
+ STR_EXERCISE_WRESTLING = 47,\r
+ STR_EXERCISE_MINDBODY = 48,\r
+ STR_EXERCISE_FLEXIBILITY = 49,\r
+ STR_EXERCISE_MIXEDCARDIO = 50,\r
+ STR_EXERCISE_TRADITIONALSTRENGTHTRAINING = 51,\r
+ STR_EXERCISE_CROSSTRAINING = 52,\r
+ STR_EXERCISE_GYMNASTICS = 53,\r
+ STR_EXERCISE_STEPTRAINING = 54,\r
+ STR_EXERCISE_ELLIPTICALTRAINER = 55,\r
+ STR_EXERCISE_ROWINGMACHINE = 56,\r
+ STR_DANCING_GENERAL = 57,\r
+ STR_DANCING_BELLY = 58,\r
+ STR_DANCING_JAZZ = 59,\r
+ STR_DANCING_LATIN = 60,\r
+ STR_DANCING_BALLET = 61,\r
+ STR_DANCING_STREET = 62,\r
+ STR_DANCING_PUBLICSQUARE = 63,\r
+ STR_DANCING_ZUMBA = 64,\r
+ STR_DANCING_SOCIALDANCE = 65,\r
+ STR_DANCING_TAPDANCE = 66,\r
+ STR_RECREATIONAL_SPORTS = 67,\r
+ STR_RECREATIONAL_SKATING = 68,\r
+ STR_RECREATIONAL_MARTIALARTS = 69,\r
+ STR_RECREATIONAL_TAICHI = 70,\r
+ STR_RECREATIONAL_HULAHOOP = 71,\r
+ STR_RECREATIONAL_DISCSPORT = 72,\r
+ STR_RECREATIONAL_DARTS = 73,\r
+ STR_RECREATIONAL_ARCHERY = 74,\r
+ STR_RECREATIONAL_HORSERIDING = 75,\r
+ STR_RECREATIONAL_BATTLEGAME = 76,\r
+ STR_RECREATIONAL_KITE = 77,\r
+ STR_RECREATIONAL_TUGOFWAR = 78,\r
+ STR_RECREATIONAL_SWING = 79,\r
+ STR_RECREATIONAL_STAIRCLIMBING = 80,\r
+ STR_RECREATIONAL_OBSTACLERACE = 81,\r
+ STR_RECREATIONAL_FISHING = 82,\r
+ STR_RECREATIONAL_HUNTING = 83,\r
+ STR_RECREATIONAL_SCOOTERRIDING = 84,\r
+ STR_RECREATIONAL_PARAGLIDING = 85,\r
+ STR_RECREATIONAL_TEAMSPORTS = 86,\r
+ STR_RECREATIONAL_FINESSGAMING = 87,\r
+ STR_RECREATIONAL_HIKING = 88,\r
+ STR_RECREATIONAL_EQUESTRIANSPORTS = 89,\r
+ STR_RECREATIONAL_PLAY = 90,\r
+ STR_BALL_GAMES = 91,\r
+ STR_BALL_BADMINTON = 92,\r
+ STR_BALL_TABLETENNIS = 93,\r
+ STR_BALL_TENNIS = 94,\r
+ STR_BALL_BILLIARDS = 95,\r
+ STR_BALL_BOWLING = 96,\r
+ STR_BALL_VOLLEYBALL = 97,\r
+ STR_BALL_SHUTTLECOCK = 98,\r
+ STR_BALL_HANDBALL = 99,\r
+ STR_BALL_BASEBALL = 100,\r
+ STR_BALL_SOFTBALL = 101,\r
+ STR_BALL_CRICKET = 102,\r
+ STR_BALL_FOOTBALL = 103,\r
+ STR_BALL_BEACHSOCCER = 104,\r
+ STR_BALL_BEACHVOLLEYBALL = 105,\r
+ STR_BALL_CROQUET = 106,\r
+ STR_BALL_HOCKEY = 107,\r
+ STR_BALL_SQUASH = 108,\r
+ STR_BALL_SEPAKTAKRAW = 109,\r
+ STR_BALL_DODGEBALL = 110,\r
+ STR_BALL_BASKETBALL = 111,\r
+ STR_BALL_SOCCER = 112,\r
+ STR_BALL_GOLF = 113,\r
+ STR_BALL_POLO = 114,\r
+ STR_BALL_RACQUETBALL = 115,\r
+ STR_BALL_RUGBY = 116,\r
+ STR_BALL_GATEBALL = 117,\r
+ STR_BALL_PICKLEBALL = 118,\r
+ STR_BALL_LACROSSE = 119,\r
+ STR_WATER_ACTIVITIES = 120,\r
+ STR_WATER_SAILING = 121,\r
+ STR_WATER_SURFING = 122,\r
+ STR_WATER_WHITEWATERRAFTING = 123,\r
+ STR_WATER_CANOEING = 124,\r
+ STR_WATER_KAYAKING = 125,\r
+ STR_WATER_ROWING = 126,\r
+ STR_WATER_MOTORBOAT = 127,\r
+ STR_WATER_SUP = 128,\r
+ STR_WATER_SCUBADIVING = 129,\r
+ STR_WATER_DIVING = 130,\r
+ STR_WATER_KITESURFING = 131,\r
+ STR_WATER_WAKEBOARDING = 132,\r
+ STR_WATER_POLO = 133,\r
+ STR_WATER_WINDSURFING = 134,\r
+ STR_WATER_DRIFTING = 135,\r
+ STR_WATER_FITNESS = 136,\r
+ STR_WATER_SPORTS = 137,\r
+ STR_WATER_OUTDOORSWIM = 138,\r
+ STR_WATER_INDOORSWIM = 139,\r
+ STR_WATER_SWIMFREESTYLE = 140,\r
+ STR_WATER_SWIMBREASTSTROKE = 141,\r
+ STR_WATER_SWIMBACKSTROKE = 142,\r
+ STR_WATER_SWIMBUTTERFLY = 143,\r
+ STR_ICE_SPORTS = 144,\r
+ STR_ICE_SKATING = 145,\r
+ STR_ICE_HOCKEY = 146,\r
+ STR_ICE_CURLING = 147,\r
+ STR_ICE_SNOWMOBILING = 148,\r
+ STR_ICE_SLED = 149,\r
+ STR_ICE_BIATHLON = 150,\r
+ STR_ICE_CROSSCOUNTRYSKING = 151,\r
+ STR_ICE_SKIING = 152,\r
+ STR_ICE_SNOWBOARDING = 153,\r
+ STR_ICE_SNOWSHOEING = 154,\r
+ STR_ICE_SNOWSPORTS = 155,\r
+ STR_EXTREME_SPORTS = 156,\r
+ STR_EXTREME_SKATEBOARDING = 157,\r
+ STR_EXTREME_ROCKCLIMBING = 158,\r
+ STR_EXTREME_BUNGEEJUMPING = 159,\r
+ STR_EXTREME_PARKOUR = 160,\r
+ STR_EXTREME_BMX = 161,\r
+ STR_EXTREME_ORIENTEERING = 162,\r
+ STR_EXTREME_PARACHUTE = 163,\r
+ STR_EXTREME_RACING = 164,\r
+ STR_EXTREME_TRIATHLONS = 165,\r
+ STR_OTHER_ELEVATOR = 166,\r
+ STR_OTHER_ESCALATOR = 167,\r
+ STR_OTHER_GARDENING = 168,\r
+ STR_OTHER_HORSEWORK = 169,\r
+ STR_OTHER_INVEHICLE = 170,\r
+ STR_OTHER_MEDITATION = 171,\r
+ STR_OTHER_STILL = 172,\r
+ STR_OTHER_TILTING = 173,\r
+ STR_OTHER_WHEELCHAIR = 174,\r
+ STR_MAX_ID = 175,\r
+}; // UIResourceTextId\r
+
+enum FontLanguageId : uint8_t {
+ LANGUAGE_ID_EN,\r
+ LANGUAGE_ID_ZH,\r
+ LANGUAGE_ID_MAX\r
+}; // UITextLanguageTextId\r
+}\r
+#endif /* UI_RESOURCE_STRING_H */\r
+++ /dev/null
-{
- "languages": {
- "zh": {
- "path": "user/res/language_config/font/zh.lang"
- },
- "en": {
- "path": "user/res/language_config/font/en.lang"
- }
- },
- "languages_satuas": 0
-}
\ No newline at end of file
+++ /dev/null
-/*
-* Copyright (c) xxxxxxxx Technologies Co., Ltd. 2021-2021. All rights reserved.
-* Description: language
-* Author: Graphic develop team
-* Create: 2021-07-06
-*/
-
-#ifndef UI_RESOURCE_STRING_H
-#define UI_RESOURCE_STRING_H
-#include <cstdint>
-namespace OHOS {
-enum UIResourceTextId : uint16_t {
- STR_IMAGE = 0,\r
- STR_PROGRESSBAR = 1,\r
- STR_SLIDEUNLOCK = 2,\r
- STR_LISTBOX = 3,\r
- STR_BUTTON = 4,\r
- STR_SCROLLVIEW = 5,\r
- STR_SCROLLGRID = 6,\r
- STR_CLOCK = 7,\r
- STR_DISTURBANCE = 8,\r
- STR_BRIGHT = 9,\r
- STR_PHONE = 10,\r
- STR_LANGAGE = 11,\r
- STR_ALARM = 12,\r
- STR_SYSTEM = 13,\r
- STR_SPO2 = 14,\r
- STR_COMPASS = 15,\r
- STR_INDOORWALK = 16,\r
- STR_WEATHER = 17,\r
- STR_SYSTEMSETTING = 18,\r
- STR_MAX_ID = 19,\r
-}; // UIResourceTextId\r
-
-enum FontLanguageId : uint8_t {
- LANGUAGE_ID_ZH,\r
- LANGUAGE_ID_EN,\r
- LANGUAGE_ID_MAX\r
-}; // UITextLanguageTextId\r
-}\r
-#endif /* UI_RESOURCE_STRING_H */\r
+++ /dev/null
-<language id="language" languageinfo="en" fontName="DroidSansFallback.ttf" direct="ltf">
-
- <lanstr id="STR_IMAGE" value="Image" size="21" direct="rtl" />
- <lanstr id="STR_PROGRESSBAR" value="ProgressBar" direct="mixed" />
- <lanstr id="STR_SLIDEUNLOCK" value="SlideUnlock" />
- <lanstr id="STR_LISTBOX" value="ListBox" />
- <lanstr id="STR_BUTTON" value="Button" />
- <lanstr id="STR_SCROLLVIEW" value="ScrollView" />
- <lanstr id="STR_SCROLLGRID" value="ScrollGrid" />
- <lanstr id="STR_CLOCK" value="Clock" />
- <lanstr id="STR_DISTURBANCE" value="Disturbance" />
- <lanstr id="STR_BRIGHT" value="Bright" />
- <lanstr id="STR_PHONE" value="Phone" />
- <lanstr id="STR_ALARM" value="Alarm" />
- <lanstr id="STR_SYSTEMSETTING" value="Setting" />
- <lanstr id="STR_LANGAGE" size="26" value="Language" />
- <lanstr id="STR_SPO2" value="SPO2" />
- <lanstr id="STR_COMPASS" value="Compass" />
- <lanstr id="STR_INDOORWALK" value="IndoorWalk" />
- <lanstr id="STR_WEATHER" value="Weathher" />
-
-</language>
\ No newline at end of file
+++ /dev/null
-<language id="language" direct="ltf" languageinfo="zh">
-
- <lanstr id="STR_IMAGE" value="图片" size="32" direct="rtl" />
- <lanstr id="STR_PROGRESSBAR" value="进度条" direct="mixed" />
- <lanstr id="STR_SLIDEUNLOCK" value="滑动解锁" />
- <lanstr id="STR_LISTBOX" value="列表" />
- <lanstr id="STR_BUTTON" value="按钮" />
- <lanstr id="STR_SCROLLVIEW" value="滚动视图" />
- <lanstr id="STR_SCROLLGRID" value="滚动网格" />
- <lanstr id="STR_CLOCK" value="时钟" />
- <lanstr id="STR_DISTURBANCE" value="勿扰" />
- <lanstr id="STR_BRIGHT" value="亮屏" />
- <lanstr id="STR_PHONE" value="找手机" />
- <lanstr id="STR_LANGAGE" size="30" value="语言" />
- <lanstr id="STR_ALARM" value="闹钟" />
- <lanstr id="STR_SYSTEM" value="设置" />
- <lanstr id="STR_SPO2" value="血氧饱和度" />
- <lanstr id="STR_COMPASS" value="指南针" />
- <lanstr id="STR_INDOORWALK" value="室内步行" />
- <lanstr id="STR_WEATHER" value="天气" />
-
-</language>
\ No newline at end of file
#include <cstdint>
#include <map>
#include "AppViewIDs.h"
+#include "components/ui_label_ext.h"
+#include"language/font/ui_resource_string.h"
#include "UiConfig.h"
#include "MessagePresenter.h"
#include "message/include/MessageAdapter.h"
#include "AppViewIDs.h"
+#include "components/ui_label_ext.h"
+#include"language/font/ui_resource_string.h"
#include "NativeAbility.h"
#include "message/include/MessagePresenter.h"
#include "message/include/MessageAdapter.h"
#include "VocassistView.h"
#include "VocassistModel.h"
#include "AppViewIDs.h"
+#include "components/ui_label_ext.h"
+#include"language/font/ui_resource_string.h"
#include "NativeAbility.h"
#include "graphic_service.h"
* Create: 2022-01-18
*/
#include "AppViewIDs.h"
+#include "components/ui_label_ext.h"
+#include"language/font/ui_resource_string.h"
#include "VocassistPresenter.h"
#include "PlayersModel.h"
#include "ui_service.h"
#include <limits>\r
#include "cmsis_os.h"\r
#include "AppViewIDs.h"\r
+#include "components/ui_label_ext.h"\r
+#include"language/font/ui_resource_string.h"\r
#include "PlayersModel.h"\r
#include "CallerLogModel.h"\r
#include "VocassistModel.h"\r
#include "AppViewIDs.h"\r
+#include "components/ui_label_ext.h"\r
+#include"language/font/ui_resource_string.h"\r
#include "NativeAbility.h"\r
#include "string"\r
#include "phone/include/PhoneCallPresenter.h"\r
#include "AppViewIDs.h"\r
+#include "components/ui_label_ext.h"\r
+#include"language/font/ui_resource_string.h"\r
#include "NativeAbility.h"\r
\r
#include "phone/include/PhoneCallingPresenter.h"\r
#include "AppViewIDs.h"\r
+#include "components/ui_label_ext.h"\r
+#include"language/font/ui_resource_string.h"\r
#include "NativeAbility.h"\r
\r
#include "phone/include/PhoneCallupPresenter.h"\r
#include "AppViewIDs.h"\r
+#include "components/ui_label_ext.h"\r
+#include"language/font/ui_resource_string.h"\r
#include "NativeAbility.h"\r
\r
#include "phone/include/PhoneDirPresenter.h"\r
#include "AppViewIDs.h"\r
+#include "components/ui_label_ext.h"\r
+#include"language/font/ui_resource_string.h"\r
#include "NativeAbility.h"\r
\r
#include "phone/include/PhonePresenter.h"\r
#include "AppViewIDs.h"\r
+#include "components/ui_label_ext.h"\r
+#include"language/font/ui_resource_string.h"\r
#include "NativeAbility.h"\r
\r
#include "phone/include/PhoneRingPresenter.h"\r
#include "AppViewIDs.h"\r
+#include "components/ui_label_ext.h"\r
+#include"language/font/ui_resource_string.h"\r
#include "NativeAbility.h"\r
#include "graphic_math.h"\r
#include "string.h"\r
#include "components/ui_image_view.h"\r
#include "components/ui_button.h"\r
#include "components/ui_label_ext.h"\r
+#include"language/font/ui_resource_string.h"\r
namespace OHOS\r
{\r
\r
#include "components/ui_circle_progress.h"\r
#include "components/ui_checkbox.h"\r
#include "components/ui_label_ext.h"\r
+#include"language/font/ui_resource_string.h"\r
#include "components/ui_button.h"\r
#define APP_RES_PATH "/user/res"\r
namespace OHOS\r
#include "AppViewIDs.h"\r
+#include "components/ui_label_ext.h"\r
+#include"language/font/ui_resource_string.h"\r
#include "NativeAbility.h"\r
#include "graphic_math.h"\r
#include "string.h"\r
#include "AppViewIDs.h"
+#include "components/ui_label_ext.h"
+#include"language/font/ui_resource_string.h"
#include "NativeAbility.h"
#include "rotate/include/RotatePresenter.h"
\r
#include "AppViewIDs.h"\r
+#include "components/ui_label_ext.h"\r
+#include"language/font/ui_resource_string.h"\r
#include "NativeAbility.h"\r
\r
#include "saveele/include/SaveBatPresenter.h"\r
#include "AppViewIDs.h"\r
+#include "components/ui_label_ext.h"\r
+#include"language/font/ui_resource_string.h"\r
#include "NativeAbility.h"\r
\r
#include "saveele/include/SaveElePresenter.h"\r
#include "power_display_service.h"
#include "NativeAbility.h"
#include "AppViewIDs.h"
+#include "components/ui_label_ext.h"
+#include"language/font/ui_resource_string.h"
#include "MainViewSample.h"
#include "ui_screennotify.h"
#include "AppViewIDs.h"\r
+#include "components/ui_label_ext.h"\r
+#include"language/font/ui_resource_string.h"\r
#include "NativeAbility.h"\r
\r
#include "secondaryfunction/include/FastTrainingAttentionPresenter.h"\r
#include "AppViewIDs.h"\r
+#include "components/ui_label_ext.h"\r
+#include"language/font/ui_resource_string.h"\r
#include "NativeAbility.h"\r
#include "graphic_math.h"\r
#include "string.h"\r
\r
#include "AppViewIDs.h"\r
+#include "components/ui_label_ext.h"\r
+#include"language/font/ui_resource_string.h"\r
#include "NativeAbility.h"\r
#include "secondaryfunction/include/SecondaryFunctionPresenter.h"\r
#include "secondaryfunction/include/SecondaryFunctionModel.h"\r
#include <cstdint>
#include <map>
#include "AppViewIDs.h"
+#include "components/ui_label_ext.h"
+#include"language/font/ui_resource_string.h"
#include "UiConfig.h"
#include "SettingItem.h"
#include "SettingPresenter.h"
#include "AppViewIDs.h"\r
+#include "components/ui_label_ext.h"\r
+#include"language/font/ui_resource_string.h"\r
#include "NativeAbility.h"\r
#include "graphic_math.h"\r
#include "string.h"\r
#include "AppViewIDs.h"\r
+#include "components/ui_label_ext.h"\r
+#include"language/font/ui_resource_string.h"\r
#include "NativeAbility.h"\r
#include "graphic_math.h"\r
#include "string.h"\r
*/\r
\r
#include "AppViewIDs.h"\r
+#include "components/ui_label_ext.h"\r
+#include"language/font/ui_resource_string.h"\r
#include "NativeAbility.h"\r
#include "graphic_math.h"\r
#include "string.h"\r
#include "AppViewIDs.h"\r
+#include "components/ui_label_ext.h"\r
+#include"language/font/ui_resource_string.h"\r
#include "NativeAbility.h"\r
#include "graphic_math.h"\r
#include "string.h"\r
#include "components/ui_radio_button.h"\r
#include "components/ui_image_view.h"\r
#include "components/ui_label_ext.h"\r
+#include"language/font/ui_resource_string.h"\r
namespace OHOS\r
{\r
class SystemLanguageView\r
return nullptr;\r
}\r
Title->SetPosition(203, 52, 200, 35);\r
- Title->SetTextId(11);\r
- //Title->SetFont(DEFAULT_VECTOR_FONT_FILENAME, 30);\r
+ Title->SetTextId(0);\r
+ // Title->SetFont(DEFAULT_VECTOR_FONT_FILENAME, 30);\r
scrollView->Add(Title);\r
/* ------------------------------- Background ------------------------------- */\r
ImageConfig imageconfig = {\r
return nullptr;\r
}\r
SetRadioButtonSelectStatus(*SimplifiedChineseRadioButton, true);\r
- UICheckBox::OnChangeListener *SimplifiedChineseRadioButtonChange = static_cast<UICheckBox::OnChangeListener *>(new RadiobuttonOnChangeListener(SimplifiedChineseRadioButton,Title));\r
+ UICheckBox::OnChangeListener *SimplifiedChineseRadioButtonChange = static_cast<UICheckBox::OnChangeListener *>(new RadiobuttonOnChangeListener(SimplifiedChineseRadioButton, Title));\r
SimplifiedChineseRadioButton->SetOnChangeListener(SimplifiedChineseRadioButtonChange);\r
scrollView->Add(SimplifiedChineseRadioButton);\r
/* --------------------------- EnglishRadioButton --------------------------- */\r
WEARABLE_LOGE(WEARABLE_LOG_MODULE_APP, "SystemLanguageView::EnglishRadioButton new fail!");\r
return nullptr;\r
}\r
- UICheckBox::OnChangeListener *EnglishRadioButtonChange = static_cast<UICheckBox::OnChangeListener *>(new RadiobuttonOnChangeListener(EnglishRadioButton,Title));\r
+ UICheckBox::OnChangeListener *EnglishRadioButtonChange = static_cast<UICheckBox::OnChangeListener *>(new RadiobuttonOnChangeListener(EnglishRadioButton, Title));\r
EnglishRadioButton->SetOnChangeListener(EnglishRadioButtonChange);\r
scrollView->Add(EnglishRadioButton);\r
initViewStatus = true;\r
#include "AppViewIDs.h"\r
+#include "components/ui_label_ext.h"\r
+#include"language/font/ui_resource_string.h"\r
#include "NativeAbility.h"\r
#include "graphic_math.h"\r
#include "string.h"\r
#include "common/key_code.h"\r
#include "custom_utils.h"\r
#include "language/LanguageInit.h"\r
-\r
+#include "language/font/ui_resource_string.h"\r
namespace OHOS\r
{\r
\r
bool RadiobuttonOnChangeListener::OnChange(UICheckBox::UICheckBoxState state)\r
{\r
language *g_planguage;\r
- // static const char *en = "user/res/language_config/font/en.lang";\r
- // static const char *zh_CN = "user/res/language_config/font/zh.lang";\r
+ // static const char *en = "user/res/font/en.lang";\r
+ // static const char *zh_CN = "user/res/font/zh.lang";\r
switch (state)\r
{\r
case UICheckBox::SELECTED:\r
// 英语文本\r
g_planguage->ChangeLanguage(LanguageId::EN);\r
}\r
- m_label->SetTextId(11);\r
+ m_label->SetTextId(0);\r
// 强制刷新\r
m_label->ForceResetText();\r
RootView::GetInstance()->Invalidate();\r
#include "traing/include/TraingModel.h"
#include "traing/Training_UiConfig.h"
#include "components/ui_label_ext.h"
+#include"language/font/ui_resource_string.h"
#include "traing/include/TraingModel.h"
#include "traing/Training_UiConfig.h"
#include "AppViewIDs.h"\r
+#include "components/ui_label_ext.h"\r
+#include"language/font/ui_resource_string.h"\r
#include "NativeAbility.h"\r
\r
#include <iostream>\r
#include "traing/include/TraingControlView.h"\r
\r
#include "common/image_cache_manager.h"\r
+#include "components/ui_label_ext.h"\r
+#include"language/font/ui_resource_string.h"\r
#include "UiConfig.h"\r
#include "ui_resource_image.h"\r
#include <ui_scroll_view.h>\r
\r
#include "AppViewIDs.h"\r
+#include "components/ui_label_ext.h"\r
+#include"language/font/ui_resource_string.h"\r
#include "NativeAbility.h"\r
\r
#include <iostream>\r
#include "traing/include/TraingDataView.h"\r
\r
#include "common/image_cache_manager.h"\r
+#include "components/ui_label_ext.h"\r
+#include"language/font/ui_resource_string.h"\r
#include "UiConfig.h"\r
#include "ui_resource_image.h"\r
#include <ui_scroll_view.h>\r
\r
\r
#include "AppViewIDs.h"\r
+#include "components/ui_label_ext.h"\r
+#include"language/font/ui_resource_string.h"\r
#include "NativeAbility.h"\r
\r
#include <iostream>\r
#include "traing/include/TraingDetailView.h"\r
\r
#include "common/image_cache_manager.h"\r
+#include "components/ui_label_ext.h"\r
+#include"language/font/ui_resource_string.h"\r
#include "UiConfig.h"\r
#include "ui_resource_image.h"\r
#include <ui_scroll_view.h>\r
#include "AppViewIDs.h"
+#include "components/ui_label_ext.h"
+#include"language/font/ui_resource_string.h"
#include "NativeAbility.h"
#include <iostream>
#include "traing/include/TraingEnddataView.h"
#include "common/image_cache_manager.h"
+#include "components/ui_label_ext.h"
+#include"language/font/ui_resource_string.h"
#include "UiConfig.h"
#include "ui_resource_image.h"
#include <ui_scroll_view.h>
#include "AppViewIDs.h"
+#include "components/ui_label_ext.h"
+#include"language/font/ui_resource_string.h"
#include "NativeAbility.h"
#include <iostream>
#include "traing/include/TraingEndnote2View.h"
#include "common/image_cache_manager.h"
+#include "components/ui_label_ext.h"
+#include"language/font/ui_resource_string.h"
#include "UiConfig.h"
#include "ui_resource_image.h"
#include <ui_scroll_view.h>
#include "AppViewIDs.h"
+#include "components/ui_label_ext.h"
+#include"language/font/ui_resource_string.h"
#include "NativeAbility.h"
#include <iostream>
#include "traing/include/TraingEndnoteView.h"
#include "common/image_cache_manager.h"
+#include "components/ui_label_ext.h"
+#include"language/font/ui_resource_string.h"
#include "UiConfig.h"
#include "ui_resource_image.h"
#include <ui_scroll_view.h>
#include "AppViewIDs.h"
+#include "components/ui_label_ext.h"
+#include"language/font/ui_resource_string.h"
#include "NativeAbility.h"
#include <iostream>
#include "traing/include/TraingMusicView.h"
#include <ui_scroll_view.h>
#include "common/image_cache_manager.h"
+#include "components/ui_label_ext.h"
+#include"language/font/ui_resource_string.h"
#include "UiConfig.h"
#include "ui_resource_image.h"
#include <ui_scroll_view.h>
\r
#include "AppViewIDs.h"\r
+#include "components/ui_label_ext.h"\r
+#include"language/font/ui_resource_string.h"\r
#include "NativeAbility.h"\r
\r
#include <iostream>\r
#include "traing/include/TraingNomalView.h"
#include "common/image_cache_manager.h"
+#include "components/ui_label_ext.h"
+#include"language/font/ui_resource_string.h"
#include "UiConfig.h"
#include "ui_resource_image.h"
#include <ui_scroll_view.h>
#include "AppViewIDs.h"
+#include "components/ui_label_ext.h"
+#include"language/font/ui_resource_string.h"
#include "NativeAbility.h"
#include <iostream>
#include "AppViewIDs.h"\r
+#include "components/ui_label_ext.h"\r
+#include"language/font/ui_resource_string.h"\r
#include "NativeAbility.h"\r
\r
#include <iostream>\r
#include "traing/include/TraingSetCaluliView.h"\r
\r
#include "common/image_cache_manager.h"\r
+#include "components/ui_label_ext.h"\r
+#include"language/font/ui_resource_string.h"\r
#include "UiConfig.h"\r
#include "ui_resource_image.h"\r
#include <ui_scroll_view.h>\r
#include "AppViewIDs.h"
+#include "components/ui_label_ext.h"
+#include"language/font/ui_resource_string.h"
#include "NativeAbility.h"
#include <iostream>
#include "traing/include/TraingSetDistView.h"
#include "common/image_cache_manager.h"
+#include "components/ui_label_ext.h"
+#include"language/font/ui_resource_string.h"
#include "UiConfig.h"
#include "ui_resource_image.h"
#include <ui_scroll_view.h>
#include "AppViewIDs.h"\r
+#include "components/ui_label_ext.h"\r
+#include"language/font/ui_resource_string.h"\r
#include "NativeAbility.h"\r
\r
#include <iostream>\r
#include "AppViewIDs.h"
+#include "components/ui_label_ext.h"
+#include"language/font/ui_resource_string.h"
#include "NativeAbility.h"
#include <iostream>
#include "traing/include/TraingSetSeptView.h"
#include "common/image_cache_manager.h"
+#include "components/ui_label_ext.h"
+#include"language/font/ui_resource_string.h"
#include "UiConfig.h"
#include "ui_resource_image.h"
#include <ui_scroll_view.h>
#include "AppViewIDs.h"\r
+#include "components/ui_label_ext.h"\r
+#include"language/font/ui_resource_string.h"\r
#include "NativeAbility.h"\r
\r
#include <iostream>\r
#include "traing/include/TraingSetTimeView.h"\r
\r
#include "common/image_cache_manager.h"\r
+#include "components/ui_label_ext.h"\r
+#include"language/font/ui_resource_string.h"\r
#include "UiConfig.h"\r
#include "ui_resource_image.h"\r
#include <ui_scroll_view.h>\r
#include "traing/include/TraingSetView.h"\r
\r
#include "common/image_cache_manager.h"\r
+#include "components/ui_label_ext.h"\r
+#include"language/font/ui_resource_string.h"\r
#include "UiConfig.h"\r
#include "ui_resource_image.h"\r
#include <ui_scroll_view.h>\r
#include "AppViewIDs.h"
+#include "components/ui_label_ext.h"
+#include"language/font/ui_resource_string.h"
#include "NativeAbility.h"
#include <iostream>
#include "traing/include/TraingStrongView.h"
#include "common/image_cache_manager.h"
+#include "components/ui_label_ext.h"
+#include"language/font/ui_resource_string.h"
#include "UiConfig.h"
#include "ui_resource_image.h"
#include <ui_scroll_view.h>
#include "AppViewIDs.h"
+#include "components/ui_label_ext.h"
+#include"language/font/ui_resource_string.h"
#include "NativeAbility.h"
#include <iostream>
#include "traing/include/TraingWinView.h"
#include "common/image_cache_manager.h"
+#include "components/ui_label_ext.h"
+#include"language/font/ui_resource_string.h"
#include "UiConfig.h"
#include "ui_resource_image.h"
#include <ui_scroll_view.h>
#include "AppViewIDs.h"
+#include "components/ui_label_ext.h"
+#include"language/font/ui_resource_string.h"
#include "NativeAbility.h"
#include <iostream>
#include "traing/training_GPS/include/TraingGPSView.h"
#include "common/image_cache_manager.h"
+#include "components/ui_label_ext.h"
+#include"language/font/ui_resource_string.h"
#include "UiConfig.h"
#include "ui_resource_image.h"
#include <ui_scroll_view.h>
#include "AppViewIDs.h"
+#include "components/ui_label_ext.h"
+#include"language/font/ui_resource_string.h"
#include "NativeAbility.h"
#include <iostream>
#include "traing/training_GPS/include/TraingGPSbackView.h"
#include "common/image_cache_manager.h"
+#include "components/ui_label_ext.h"
+#include"language/font/ui_resource_string.h"
#include "UiConfig.h"
#include "ui_resource_image.h"
#include <ui_scroll_view.h>
#include "AppViewIDs.h"
+#include "components/ui_label_ext.h"
+#include"language/font/ui_resource_string.h"
#include "NativeAbility.h"
#include <iostream>
#include "traing/training_GPS/include/TraingGPSlackView.h"
#include "common/image_cache_manager.h"
+#include "components/ui_label_ext.h"
+#include"language/font/ui_resource_string.h"
#include "UiConfig.h"
#include "ui_resource_image.h"
#include <ui_scroll_view.h>
#include "AppViewIDs.h"
+#include "components/ui_label_ext.h"
+#include"language/font/ui_resource_string.h"
#include "NativeAbility.h"
#include <iostream>
#include "traing/training_GPS/include/TraingGPSlostView.h"
#include "common/image_cache_manager.h"
+#include "components/ui_label_ext.h"
+#include"language/font/ui_resource_string.h"
#include "UiConfig.h"
#include "ui_resource_image.h"
#include <ui_scroll_view.h>
#include "AppViewIDs.h"
+#include "components/ui_label_ext.h"
+#include"language/font/ui_resource_string.h"
#include "NativeAbility.h"
#include <iostream>
#include "traing/training_GPS/include/TraingGPSnoteView.h"
#include "common/image_cache_manager.h"
+#include "components/ui_label_ext.h"
+#include"language/font/ui_resource_string.h"
#include "UiConfig.h"
#include "ui_resource_image.h"
#include <ui_scroll_view.h>
#include "AppViewIDs.h"
+#include "components/ui_label_ext.h"
+#include"language/font/ui_resource_string.h"
#include "NativeAbility.h"
#include <iostream>
#include "traing/training_GPS/include/TraingGPSsetView.h"
#include "common/image_cache_manager.h"
+#include "components/ui_label_ext.h"
+#include"language/font/ui_resource_string.h"
#include "UiConfig.h"
#include "ui_resource_image.h"
#include <ui_scroll_view.h>
\r
\r
#include "AppViewIDs.h"\r
+#include "components/ui_label_ext.h"\r
+#include"language/font/ui_resource_string.h"\r
#include "NativeAbility.h"\r
\r
#include <iostream>\r
\r
#include "traing/training_card/include/TraingCardView.h"\r
#include "common/image_cache_manager.h"\r
+#include "components/ui_label_ext.h"\r
+#include"language/font/ui_resource_string.h"\r
#include "UiConfig.h"\r
#include "ui_resource_image.h"\r
#include <ui_scroll_view.h>\r
#include "traing/training_card/include/Training_CardView.h"
#include "AppViewIDs.h"
+#include "components/ui_label_ext.h"
+#include"language/font/ui_resource_string.h"
#include "NativeAbility.h"
+#include "components/ui_label_ext.h"
+#include"language/font/ui_resource_string.h"
#include "UiConfig.h"
#include "wearable_log.h"
namespace OHOS
#include "traing/training_card/include/Training_CardView.h"\r
\r
#include "common/image_cache_manager.h"\r
+#include "components/ui_label_ext.h"\r
+#include"language/font/ui_resource_string.h"\r
#include "UiConfig.h"\r
#include "ui_resource_image.h"\r
#include <ui_scroll_view.h>\r
-/***
+/***
* @Author: Caisking 3449750381@qq.com
* @Date: 2024-03-27 11:09:52
* @LastEditors: Caisking 3449750381@qq.com
#include "components/ui_label.h"
#include "components/ui_checkbox.h"
#include "AppViewIDs.h"
-
+#include "components/ui_label_ext.h"
+#include"language/font/ui_resource_string.h"
+#include "language/font/ui_resource_string.h"
// 列表的适配器
namespace OHOS
{
typedef struct
{
AppViewId id;
- const char *label; // 标签
+ UIResourceTextId labelid; // 标签
} TraingDanceItem;
class TraingDanceAdapter : public AbstractAdapter
-
+/***
+ * @Author: Caisking 3449750381@qq.com
+ * @Date: 2024-03-27 15:24:12
+ * @LastEditors: Caisking 3449750381@qq.com
+ * @LastEditTime: 2024-03-28 16:46:53
+ * @FilePath: /sdk/application/wearable/fd230app/nativeui/traing/training_list_dance/include/TraingDanceItemView.h
+ * @Description: 这是默认设置,请设置`customMade`, 打开koroFileHeader查看配置 进行设置: https://github.com/OBKoro1/koro1FileHeader/wiki/%E9%85%8D%E7%BD%AE
+ */
+/***
+ * @Author: Caisking 3449750381@qq.com
+ * @Date: 2024-03-27 15:24:12
+ * @LastEditors: Caisking 3449750381@qq.com
+ * @LastEditTime: 2024-03-28 16:42:47
+ * @FilePath: /sdk/application/wearable/fd230app/nativeui/traing/training_list_dance/include/TraingDanceItemView.h
+ * @Description: 这是默认设置,请设置`customMade`, 打开koroFileHeader查看配置 进行设置: https://github.com/OBKoro1/koro1FileHeader/wiki/%E9%85%8D%E7%BD%AE
+ */
#ifndef TraingDance_ITEM_VIEW_H
#define TraingDance_ITEM_VIEW_H
#include "traing/training_list_dance/include/TraingDanceAdapter.h"
#include "components/ui_label_button.h"
#include "AppViewIDs.h"
+#include "components/ui_label_ext.h"
+#include"language/font/ui_resource_string.h"
+#include "components/ui_label_ext.h"
+#include"language/font/ui_resource_string.h"
#include "ohos_types.h"
namespace OHOS
private:
TraingDanceItemView(const TraingDanceItemView &);
UIImageView sbackground; // 背景
- UIImageView sicon; // 箭头
- UILabel sLabel; // 标签
- TraingDanceItem sItemInfo = {VIEW_INVALID, nullptr};
+ UIImageView sicon; // 箭头
+ UILabelExt sLabel; // 标签
+ TraingDanceItem sItemInfo = {VIEW_INVALID, STR_DANCING_GENERAL};
};
}
#include <cstdint>
#include <map>
#include "AppViewIDs.h"
+#include "components/ui_label_ext.h"
+#include"language/font/ui_resource_string.h"
+#include "components/ui_label_ext.h"
+#include"language/font/ui_resource_string.h"
#include "UiConfig.h"
#include "TraingDancePresenter.h"
#include "traing/training_list_dance/include/TraingDanceAdapter.h"
TraingDanceModel &operator=(const TraingDanceModel &);
virtual ~TraingDanceModel();
static const uint16_t TraingDanceListMaxNum = 10;
- TraingDanceItem TraingDances[TraingDanceListMaxNum] = {VIEW_INVALID, nullptr};
+ TraingDanceItem TraingDances[TraingDanceListMaxNum] = {VIEW_INVALID, STR_DANCING_GENERAL};
// std::map<int, AppViewId> TraingDanceIdToViewId;
bool btConnectStatus{false};
};
#include "traing/training_list_dance/include/TraingDanceModel.h"
#include "components/ui_label_button_ext.h"
#include "components/ui_label_ext.h"
+#include"language/font/ui_resource_string.h"
namespace OHOS
{
#include "traing/training_list_dance/include/TraingDanceItemView.h"
#include "traing/include/TraingModel.h"
#include "traing/Training_UiConfig.h"
+#include "components/ui_label_ext.h"
+#include"language/font/ui_resource_string.h"
#include "UiConfig.h"
namespace OHOS
{
void TraingDanceItemView::SetItemInfo(const TraingDanceItem itemInfo)
{
sItemInfo = itemInfo;
- sLabel.SetText(itemInfo.label);
+ sLabel.SetTextId(itemInfo.labelid);
}
/// @brief 设置每一个itemview上的组件
#include "traing/training_list_dance/include/TraingDanceModel.h"
#include "common/image_cache_manager.h"
+#include "components/ui_label_ext.h"
+#include"language/font/ui_resource_string.h"
#include "UiConfig.h"
#include "ui_resource_image.h"
#include "AppViewIDs.h"
+#include "components/ui_label_ext.h"
+#include"language/font/ui_resource_string.h"
namespace OHOS
{
return instance;
}
- static char *text[] = {"一般舞蹈", "肚皮舞", "爵士舞", "拉丁舞", "芭蕾", "街舞", "广场舞", "尊巴", "社交舞", "踢踏舞"};
+ // static char *text[] = {"一般舞蹈", "肚皮舞", "爵士舞", "拉丁舞", "芭蕾", "街舞", "广场舞", "尊巴", "社交舞", "踢踏舞"};
void TraingDanceModel::InitTraingDanceListItem()
{
- TraingDances[0] = {VIEW_TRAININGNOMAL, "一般舞蹈"};
- TraingDances[1] = {VIEW_TRAININGNOMAL, "肚皮舞"};
- TraingDances[2] = {VIEW_TRAININGNOMAL, "爵士舞"};
- TraingDances[3] = {VIEW_TRAININGNOMAL, "拉丁舞"};
- TraingDances[4] = {VIEW_TRAININGNOMAL, "芭蕾"};
- TraingDances[5] = {VIEW_TRAININGNOMAL, "街舞"};
- TraingDances[6] = {VIEW_TRAININGNOMAL, "广场舞"};
- TraingDances[7] = {VIEW_TRAININGNOMAL, "尊巴"};
- TraingDances[8] = {VIEW_TRAININGNOMAL, "社交舞"};
- TraingDances[9] = {VIEW_TRAININGNOMAL, "踢踏舞"};
+ TraingDances[0] = {VIEW_TRAININGNOMAL, STR_DANCING_GENERAL};
+ TraingDances[1] = {VIEW_TRAININGNOMAL, STR_DANCING_BELLY};
+ TraingDances[2] = {VIEW_TRAININGNOMAL, STR_DANCING_JAZZ};
+ TraingDances[3] = {VIEW_TRAININGNOMAL, STR_DANCING_LATIN};
+ TraingDances[4] = {VIEW_TRAININGNOMAL, STR_DANCING_BALLET};
+ TraingDances[5] = {VIEW_TRAININGNOMAL, STR_DANCING_STREET};
+ TraingDances[6] = {VIEW_TRAININGNOMAL, STR_DANCING_PUBLICSQUARE};
+ TraingDances[7] = {VIEW_TRAININGNOMAL, STR_DANCING_ZUMBA};
+ TraingDances[8] = {VIEW_TRAININGNOMAL, STR_DANCING_SOCIALDANCE};
+ TraingDances[9] = {VIEW_TRAININGNOMAL, STR_DANCING_TAPDANCE};
}
const TraingDanceItem *TraingDanceModel::GetTraingDancelistItems() const
*/
#include "AppViewIDs.h"
+#include "components/ui_label_ext.h"
+#include"language/font/ui_resource_string.h"
#include "NativeAbility.h"
#include <iostream>
#include "traing/include/TraingModel.h"
#include "traing/Training_UiConfig.h"
+#include "components/ui_label_ext.h"
+#include"language/font/ui_resource_string.h"
#include "UiConfig.h"
#include "wearable_log.h"
TraingDanceList->SetMaxScrollDistance(MAX_SCR_DIS);
// 增加表冠控制
- TraingDanceList->SetRotateFactor(2);
- TraingDanceList->RequestFocus();
+ scrollView->SetRotateFactor(2);
+ scrollView->RequestFocus();
}
UIList *TraingDanceView::GetList()
{
#include "traing/training_list_fitness/include/TraingFitnessModel.h"
#include "components/ui_label_button_ext.h"
#include "components/ui_label_ext.h"
+#include"language/font/ui_resource_string.h"
namespace OHOS
{
-/***
+/***
* @Author: Caisking 3449750381@qq.com
* @Date: 2024-03-27 11:09:52
* @LastEditors: Caisking 3449750381@qq.com
- * @LastEditTime: 2024-03-27 15:25:46
+ * @LastEditTime: 2024-03-28 19:54:05
* @FilePath: /sdk/application/wearable/fd230app/nativeui/traing/training_list_ice/include/TraingIceAdapter.h
* @Description: 这是默认设置,请设置`customMade`, 打开koroFileHeader查看配置 进行设置: https://github.com/OBKoro1/koro1FileHeader/wiki/%E9%85%8D%E7%BD%AE
*/
#include "components/ui_label.h"
#include "components/ui_checkbox.h"
#include "AppViewIDs.h"
+#include "components/ui_label_ext.h"
+#include"language/font/ui_resource_string.h"
// 列表的适配器
namespace OHOS
typedef struct
{
AppViewId id;
- const char *label; // 标签
+ UIResourceTextId labelid; // 标签
} TraingIceItem;
class TraingIceAdapter : public AbstractAdapter
#include "traing/training_list_ice/include/TraingIceAdapter.h"
#include "components/ui_label_button.h"
#include "AppViewIDs.h"
+#include "components/ui_label_ext.h"
+#include"language/font/ui_resource_string.h"
#include "ohos_types.h"
namespace OHOS
TraingIceItemView(const TraingIceItemView &);
UIImageView sbackground; // 背景
UIImageView sicon; // 箭头
- UILabel sLabel; // 标签
- TraingIceItem sItemInfo = {VIEW_INVALID, nullptr};
+ UILabelExt sLabel; // 标签
+ TraingIceItem sItemInfo = {VIEW_INVALID, STR_ICE_SPORTS};
};
}
#include <cstdint>
#include <map>
#include "AppViewIDs.h"
+#include "components/ui_label_ext.h"
+#include"language/font/ui_resource_string.h"
+#include "components/ui_label_ext.h"
+#include"language/font/ui_resource_string.h"
#include "UiConfig.h"
#include "TraingIcePresenter.h"
#include "traing/training_list_ice/include/TraingIceAdapter.h"
TraingIceModel &operator=(const TraingIceModel &);
virtual ~TraingIceModel();
static const uint16_t TraingIceListMaxNum = 12;
- TraingIceItem TraingIces[TraingIceListMaxNum] = {VIEW_INVALID, nullptr};
+ TraingIceItem TraingIces[TraingIceListMaxNum] = {VIEW_INVALID, STR_ICE_SPORTS};
// std::map<int, AppViewId> TraingIceIdToViewId;
bool btConnectStatus{false};
};
#include "traing/training_list_ice/include/TraingIceModel.h"
#include "components/ui_label_button_ext.h"
#include "components/ui_label_ext.h"
+#include"language/font/ui_resource_string.h"
namespace OHOS
{
#include "traing/training_list_ice/include/TraingIceItemView.h"
#include "traing/include/TraingModel.h"
#include "traing/Training_UiConfig.h"
+#include "components/ui_label_ext.h"
+#include"language/font/ui_resource_string.h"
#include "UiConfig.h"
namespace OHOS
{
void TraingIceItemView::SetItemInfo(const TraingIceItem itemInfo)
{
sItemInfo = itemInfo;
- sLabel.SetText(itemInfo.label);
+ sLabel.SetTextId(itemInfo.labelid);
}
/// @brief 设置每一个itemview上的组件
#include "traing/training_list_ice/include/TraingIceModel.h"
#include "common/image_cache_manager.h"
+#include "components/ui_label_ext.h"
+#include "language/font/ui_resource_string.h"
#include "UiConfig.h"
#include "ui_resource_image.h"
#include "AppViewIDs.h"
+#include "components/ui_label_ext.h"
+#include "language/font/ui_resource_string.h"
namespace OHOS
{
void TraingIceModel::InitTraingIceListItem()
{
- TraingIces[0] = {VIEW_TRAININGNOMAL, "一般冰上运动"};
- TraingIces[1] = {VIEW_TRAININGNOMAL, "溜冰"};
- TraingIces[2] = {VIEW_TRAININGNOMAL, "冰球"};
- TraingIces[3] = {VIEW_TRAININGNOMAL, "冰石壶/冰壶"};
- TraingIces[4] = {VIEW_TRAININGNOMAL, "雪上摩托车"};
- TraingIces[5] = {VIEW_TRAININGNOMAL, "雪橇"};
- TraingIces[6] = {VIEW_TRAININGNOMAL, "冬季两项"};
- TraingIces[7] = {VIEW_TRAININGNOMAL, "越野滑雪"};
- TraingIces[8] = {VIEW_TRAININGNOMAL, "滑雪"};
- TraingIces[9] = {VIEW_TRAININGNOMAL, "单板滑雪/滑雪板"};
- TraingIces[10] = {VIEW_TRAININGNOMAL, "雪鞋健行"};
- TraingIces[11] = {VIEW_TRAININGNOMAL, "雪地运动"};
+ TraingIces[0] = {VIEW_TRAININGNOMAL, STR_ICE_SPORTS};
+ TraingIces[1] = {VIEW_TRAININGNOMAL, STR_ICE_SKATING};
+ TraingIces[2] = {VIEW_TRAININGNOMAL, STR_ICE_HOCKEY};
+ TraingIces[3] = {VIEW_TRAININGNOMAL, STR_ICE_CURLING};
+ TraingIces[4] = {VIEW_TRAININGNOMAL, STR_ICE_SNOWMOBILING};
+ TraingIces[5] = {VIEW_TRAININGNOMAL, STR_ICE_SLED};
+ TraingIces[6] = {VIEW_TRAININGNOMAL, STR_ICE_BIATHLON};
+ TraingIces[7] = {VIEW_TRAININGNOMAL, STR_ICE_CROSSCOUNTRYSKING};
+ TraingIces[8] = {VIEW_TRAININGNOMAL, STR_ICE_SKIING};
+ TraingIces[9] = {VIEW_TRAININGNOMAL, STR_ICE_SNOWBOARDING};
+ TraingIces[10] = {VIEW_TRAININGNOMAL, STR_ICE_SNOWSHOEING};
+ TraingIces[11] = {VIEW_TRAININGNOMAL, STR_ICE_SNOW_SPORTS};
}
-
const TraingIceItem *TraingIceModel::GetTraingIcelistItems() const
{
return TraingIces;
*/
#include "AppViewIDs.h"
+#include "components/ui_label_ext.h"
+#include"language/font/ui_resource_string.h"
#include "NativeAbility.h"
#include <iostream>
+/***
+ * @Author: Caisking 3449750381@qq.com
+ * @Date: 2024-03-26 09:46:17
+ * @LastEditors: Caisking 3449750381@qq.com
+ * @LastEditTime: 2024-03-28 19:59:38
+ * @FilePath: /sdk/application/wearable/fd230app/nativeui/traing/training_list_ice/src/TraingIceView.cpp
+ * @Description: 这是默认设置,请设置`customMade`, 打开koroFileHeader查看配置 进行设置: https://github.com/OBKoro1/koro1FileHeader/wiki/%E9%85%8D%E7%BD%AE
+ */
#include "traing/training_list_ice/include/TraingIceView.h"
#include "traing/training_list_ice/include/TraingIcePresenter.h"
#include "traing/include/TraingModel.h"
#include "traing/Training_UiConfig.h"
+#include "components/ui_label_ext.h"
+#include"language/font/ui_resource_string.h"
#include "UiConfig.h"
#include "wearable_log.h"
TraingIceList->SetMaxScrollDistance(MAX_SCR_DIS);
// 增加表冠控制
- TraingIceList->SetRotateFactor(2);
- TraingIceList->RequestFocus();
+ scrollView->SetRotateFactor(2);
+ scrollView->RequestFocus();
}
UIList *TraingIceView::GetList()
{
#include "components/ui_label.h"
#include "components/ui_checkbox.h"
#include "AppViewIDs.h"
+#include "components/ui_label_ext.h"
+#include"language/font/ui_resource_string.h"
// 列表的适配器
namespace OHOS
#include "traing/training_list_limit/include/TraingLimitAdapter.h"
#include "components/ui_label_button.h"
#include "AppViewIDs.h"
+#include "components/ui_label_ext.h"
+#include"language/font/ui_resource_string.h"
#include "ohos_types.h"
namespace OHOS
#include <cstdint>
#include <map>
#include "AppViewIDs.h"
+#include "components/ui_label_ext.h"
+#include"language/font/ui_resource_string.h"
+#include "components/ui_label_ext.h"
+#include"language/font/ui_resource_string.h"
#include "UiConfig.h"
#include "TraingLimitPresenter.h"
#include "traing/training_list_limit/include/TraingLimitAdapter.h"
#include "traing/training_list_limit/include/TraingLimitModel.h"
#include "components/ui_label_button_ext.h"
#include "components/ui_label_ext.h"
+#include"language/font/ui_resource_string.h"
namespace OHOS
{
#include "traing/training_list_limit/include/TraingLimitItemView.h"
#include "traing/include/TraingModel.h"
#include "traing/Training_UiConfig.h"
+#include "components/ui_label_ext.h"
+#include"language/font/ui_resource_string.h"
#include "UiConfig.h"
namespace OHOS
{
#include "traing/training_list_limit/include/TraingLimitModel.h"
#include "common/image_cache_manager.h"
+#include "components/ui_label_ext.h"
+#include"language/font/ui_resource_string.h"
#include "UiConfig.h"
#include "ui_resource_image.h"
#include "AppViewIDs.h"
+#include "components/ui_label_ext.h"
+#include"language/font/ui_resource_string.h"
namespace OHOS
{
*/\r
\r
#include "AppViewIDs.h"\r
+#include "components/ui_label_ext.h"\r
+#include"language/font/ui_resource_string.h"\r
#include "NativeAbility.h"\r
\r
#include <iostream>\r
#include "traing/include/TraingModel.h"\r
#include "traing/Training_UiConfig.h"\r
\r
+#include "components/ui_label_ext.h"\r
+#include"language/font/ui_resource_string.h"\r
#include "UiConfig.h"\r
#include "wearable_log.h"\r
\r
#include "AppViewIDs.h"\r
+#include "components/ui_label_ext.h"\r
+#include"language/font/ui_resource_string.h"\r
#include "NativeAbility.h"\r
\r
#include <iostream>\r
#include "traing/Training_UiConfig.h"\r
\r
#include "common/image_cache_manager.h"\r
+#include "components/ui_label_ext.h"\r
+#include"language/font/ui_resource_string.h"\r
#include "UiConfig.h"\r
#include "ui_resource_image.h"\r
#include <ui_scroll_view.h>\r
#include "AppViewIDs.h"
+#include "components/ui_label_ext.h"
+#include"language/font/ui_resource_string.h"
#include "NativeAbility.h"
#include <iostream>
#include <cstdint>
#include <map>
#include "AppViewIDs.h"
+#include "components/ui_label_ext.h"
+#include"language/font/ui_resource_string.h"
#include "UiConfig.h"
#include "UISamplePresenter.h"
#include "components/ui_view_group.h"\r
#include "components/ui_scroll_view.h"\r
#include "components/ui_label_ext.h"\r
+#include"language/font/ui_resource_string.h"\r
#include "components/ui_image_animator.h"\r
#include "config/include/ConfigModel.h"\r
namespace OHOS\r
#include "AppViewIDs.h"\r
+#include "components/ui_label_ext.h"\r
+#include"language/font/ui_resource_string.h"\r
#include "NativeAbility.h"\r
\r
#include "weather/include/FutureWeatherPresenter.h"\r
#include "AppViewIDs.h"\r
+#include "components/ui_label_ext.h"\r
+#include"language/font/ui_resource_string.h"\r
#include "NativeAbility.h"\r
#include "weather/include/GetWeatherDataErrorPresenter.h"\r
\r
#include "AppViewIDs.h"\r
+#include "components/ui_label_ext.h"\r
+#include"language/font/ui_resource_string.h"\r
#include "NativeAbility.h"\r
#include "weather/include/MainWeatherPresenter.h"\r
#include "common/key_code.h"\r
#include <cstdint>
#include "AppViewIDs.h"
+#include "components/ui_label_ext.h"
#include "components/ui_view.h"
#include "NativeAbility.h"
#ifndef NATIVE_LAUNCHER_H
#define NATIVE_LAUNCHER_H
#include "AppViewIDs.h"
+#include "components/ui_label_ext.h"
namespace OHOS {
class NativeLauncher {
#include "MainView.h"
#include "AppViewIDs.h"
+#include "components/ui_label_ext.h"
#include "wearable_log.h"
#include "components/icon_adapter.h"
#include "AlipayPresenter.h"
#include "AppViewIDs.h"
+#include "components/ui_label_ext.h"
#include "UiConfig.h"
#include "AlipayListAdapter.h"
#include "AlipayListItem.h"
#include "components/icon_adapter.h"
#include "AlipayPresenter.h"
#include "AppViewIDs.h"
+#include "components/ui_label_ext.h"
#include "UiConfig.h"
#include "AlipayTransListAdapter.h"
#include "AlipayTransListItem.h"
#include "bundle_info.h"
#include "AppViewIDs.h"
+#include "components/ui_label_ext.h"
#include "ohos_types.h"
#define APP_MAX_NUM 50
#include "string"\r
#include "PhoneService.h"\r
#include "AppViewIDs.h"\r
+#include "components/ui_label_ext.h"\r
#include "message.h"\r
#include "msg_center.h"\r
\r
#include "ohos_types.h"\r
#include "UiConfig.h"\r
#include "AppViewIDs.h"\r
+#include "components/ui_label_ext.h"\r
#include "CompassView.h"\r
\r
namespace OHOS {\r
#include "ohos_types.h"\r
#include "UiConfig.h"\r
#include "AppViewIDs.h"\r
+#include "components/ui_label_ext.h"\r
#include "CompassView.h"\r
#include "CompassPresenter.h"\r
#include "CompassModel.h"\r
#include "KeyInputListener.h"
#include "common/key_code.h"
#include "AppViewIDs.h"
+#include "components/ui_label_ext.h"
#include "View.h"
#include "MainViewSample.h"
#include "wearable_log.h"
#include "VocassistView.h"
#include "VocassistModel.h"
#include "AppViewIDs.h"
+#include "components/ui_label_ext.h"
#include "NativeAbility.h"
#include "graphic_service.h"
* Create: 2022-01-18
*/
#include "AppViewIDs.h"
+#include "components/ui_label_ext.h"
#include "VocassistPresenter.h"
#include "PlayersModel.h"
#include "ui_service.h"
#include <limits>\r
#include "cmsis_os.h"\r
#include "AppViewIDs.h"\r
+#include "components/ui_label_ext.h"\r
#include "PlayersModel.h"\r
#include "CallerLogModel.h"\r
#include "VocassistModel.h"\r
#include "power_display_service.h"
#include "NativeAbility.h"
#include "AppViewIDs.h"
+#include "components/ui_label_ext.h"
#include "MainViewSample.h"
#include "ui_screennotify.h"
#include <cstdint>
#include <map>
#include "AppViewIDs.h"
+#include "components/ui_label_ext.h"
#include "UiConfig.h"
#include "SettingItem.h"
#include "SettingPresenter.h"
#include <cstdint>
#include <map>
#include "AppViewIDs.h"
+#include "components/ui_label_ext.h"
#include "UiConfig.h"
#include "UISamplePresenter.h"
#ifdef SUPPORT_CHARGER_PLUG_DETECTION_NOTIFICATION
TOPIC_EVENT_CHARGE_PLUG,
TOPIC_EVENT_CHARGE_UNPLUG,
+ TOPIC_EVENT_LOWPOWER_ALARM,
#endif
#ifdef SUPPORT_SPO2_NOTIFICATION
TOPIC_EVENT_SPO2_UPDATE,
#ifdef SUPPORT_CHARGER_PLUG_DETECTION_NOTIFICATION
{TOPIC_EVENT_CHARGE_PLUG, A_CORE_MASK, 1},
{TOPIC_EVENT_CHARGE_UNPLUG, A_CORE_MASK, 1},
+ {TOPIC_EVENT_LOWPOWER_ALARM, A_CORE_MASK, 1},
#endif
#ifdef SUPPORT_DEVICE_PAIRING_NOTIFICATION
{TOPIC_EVENT_DEVICE_BIND,A_CORE_MASK, 1},
)
set(SOURCES
${CMAKE_CURRENT_SOURCE_DIR}/factorytestService.c
+ ${CMAKE_CURRENT_SOURCE_DIR}/factorytest_protocol.c
)
set(COMPONENT_PUBLIC_CCFLAGS
uint32_t g_factory_ota_report_hdl = 0;\r
uint32_t factory_ota_write_handl = 0;\r
\r
-uint16_t modbus_crc16(uint8_t *data, uint16_t length) { \r
- uint8_t crc_hi = 0xFF; \r
- uint8_t crc_lo = 0xFF; \r
- int i; \r
- \r
- while (length--) { \r
- crc_hi ^= *data++;\r
- for (i = 0; i < 8; i++) { \r
- if (crc_hi & 0x80) { \r
- crc_hi = (crc_hi << 1) ^ 0x8005; \r
- } else { \r
- crc_hi <<= 1; \r
- } \r
- } \r
- } \r
- \r
- return (crc_hi << 8) | crc_lo; \r
-} \r
- \r
-\r
/* 创建服务 */\r
static void ble_factorytest_add_service(void)\r
{\r
ble_factorytest_add_service();\r
}\r
\r
+extern void factorytest_protocol_decode(uint8_t *buf, uint16_t event_size);\r
//协议接收client下发的数据接口\r
void factory_recv_cmd_data(uint8_t *buf, uint16_t event_size,uint16_t handle)\r
{\r
- printf("factory_recv_cmd_data len %d , handle 0x%X\r\n",event_size,handle);\r
+ if(buf != NULL)\r
+ printf("factory_recv_cmd_data len %d , handle 0x%X ,*buf 0x%02X\r\n",event_size,handle,*buf);\r
/****此处为接收指令,处理后反馈结果的参考**/\r
- uint8_t buff[128]={0};\r
- sprintf((char*)buff,"%X",event_size);\r
- ble_factorytest_server_send_input_report((uint8_t*)buff,strlen((char*)buff));\r
+ factorytest_protocol_decode(buf,event_size);\r
/*****参考结束****/\r
}\r
\r
/* write */
#define BLE_UUID_ATE_TX 0x1004
-// 主模式ID 公共接口 0x01
-#define BLE_TEST_CMD_MODE_COMMON 0x01
-// 主模式ID 生产软件 0x02
-#define BLE_TEST_CMD_MODE_SOFT_TEST 0x02
-// 主模式ID 硬测接口 0x03
-#define BLE_TEST_CMD_MODE_HW_TEST 0x03
-// 主模式ID 串口接口 0x04
-#define BLE_TEST_CMD_MODE_SERIAL_PORT 0x04
-
-
-// 协议定义:
-// 发送:协议头(0xFD) + 长度(2bytes) +模块ID(1bytes)+子模块ID(1bytes)+测试项ID(1bytes)+可变字节+CRC(2bytes)
-// 接收:协议头(0xFD) + 长度(2bytes) +模块ID(1bytes)+子模块ID(1bytes)+测试项ID(1bytes)+执行状态(1bytes)+可变字节+CRC(2bytes)
-// 备注:
-// 1、状态返回00表示成功,01表示开始执行,其他表示各种错误。
-// 2、命令响应超时为:3秒,超时重发2次。
-// 3、大端模式。
-// 4、长耗时命令,先确认收到,执行完再返回结果。
-#define BLE_TEST_PROTOCOL_HEADER 0xFD
-
-
-//公共模式 子模式ID 模式切换
-#define BLE_TEST_CMD_COMMON_SUB_MODE_SWITCH_MODE 0x01
-//公共模式 子模式ID 系统版本
-#define BLE_TEST_CMD_COMMON_SUB_MODE_SYSTEM_VERSION 0x02
-//公共模式 子模式ID 开关机
-#define BLE_TEST_CMD_COMMON_SUB_MODE_POWER_ON_OFF_DEVICE 0x03
-//公共模式 子模式ID 功耗
-#define BLE_TEST_CMD_COMMON_SUB_MODE_POWERCONSUMPTION 0x04
-//公共模式 子模式ID OTA
-#define BLE_TEST_CMD_COMMON_SUB_MODE_OTA 0x05
-
-//软件测试 子模式ID 蓝牙
-#define BLE_TEST_CMD_SOFT_TEST_SUB_MODE_BLE 0x01
-//软件测试 子模式ID 马达
-#define BLE_TEST_CMD_SOFT_TEST_SUB_MODE_VIBRATOR 0x02
-//软件测试 子模式ID 按键
-#define BLE_TEST_CMD_SOFT_TEST_SUB_MODE_KEY 0x03
-//软件测试 子模式ID RTC
-#define BLE_TEST_CMD_SOFT_TEST_SUB_MODE_RTC 0x04
-//软件测试 子模式ID 温度
-#define BLE_TEST_CMD_SOFT_TEST_SUB_MODE_TEMPERATURE 0x05
-
-//软件测试 子模式ID 老化测试
-#define BLE_TEST_CMD_SOFT_TEST_SUB_MODE_AGING_TEST 0x06
-
-//软件测试 子模式ID 定制测试 读写SN等 读CHIPID
-#define BLE_TEST_CMD_SOFT_TEST_SUB_MODE_CUSTOM_CMD 0x07
-
-//软件测试 子模式ID 屏幕
-#define BLE_TEST_CMD_SOFT_TEST_SUB_MODE_LCD 0x11
-//软件测试 子模式ID TP
-#define BLE_TEST_CMD_SOFT_TEST_SUB_MODE_TP 0x12
-//软件测试 子模式ID ACC
-#define BLE_TEST_CMD_SOFT_TEST_SUB_MODE_ACC 0x13
-//软件测试 子模式ID 心率
-#define BLE_TEST_CMD_SOFT_TEST_SUB_MODE_HRS 0x14
-//软件测试 子模式ID 地磁
-#define BLE_TEST_CMD_SOFT_TEST_SUB_MODE_COMPASS 0x16
-//软件测试 子模式ID 电源管理
-#define BLE_TEST_CMD_SOFT_TEST_SUB_MODE_PM 0x17
-//软件测试 子模式ID 扩展FLASH
-#define BLE_TEST_CMD_SOFT_TEST_SUB_MODE_EXTFLASH 0x18
-//软件测试 子模式ID 扩展RAM
-#define BLE_TEST_CMD_SOFT_TEST_SUB_MODE_EXTRAM 0x19
-//软件测试 子模式ID CAT1
-#define BLE_TEST_CMD_SOFT_TEST_SUB_MODE_CAT1 0x1A
-
/**
* @if Eng
--- /dev/null
+/*\r
+ * Copyright (c) @CompanyNameMagicTag 2022. All rights reserved.\r
+ * Description: BT HID Service Server Module.\r
+ */\r
+#include "factorytest_protocol.h"\r
+#include "factorytestService.h"\r
+#include "wearable_log.h"\r
+#include "custom_utils.h"\r
+\r
+#pragma pack(1)\r
+typedef struct factorytest_cmd_header_t\r
+{\r
+ uint8_t header;\r
+ uint16_t len;\r
+ uint8_t mode;\r
+ uint8_t submod;\r
+ uint8_t testitem;\r
+}factorytest_cmd_header_t;\r
+#pragma pack()\r
+\r
+static int CRC16_XMODEM(uint8_t *bytes,uint16_t length) {\r
+ int crc = 0x0000; // initial value\r
+ int polynomial = 0x1021;\r
+ for (int index = 0; index < length; index++) {\r
+ uint8_t b = bytes[index];\r
+ for (int i = 0; i < 8; i++) {\r
+ uint8_t bit = ((b >> (7 - i) & 1) == 1);\r
+ uint8_t c15 = ((crc >> 15 & 1) == 1);\r
+ crc <<= 1;\r
+ if (c15 ^ bit) crc ^= polynomial;\r
+ }\r
+ }\r
+ crc &= 0xffff;\r
+ return crc;\r
+}\r
+errcode_t factorytest_protocol_replymsg(uint8_t mode, uint8_t submode,uint8_t testitem,\r
+ uint8_t *input_data,uint16_t input_len)\r
+{\r
+\r
+ uint8_t * replybuf=NULL;\r
+ errcode_t ret;\r
+ uint16_t total_len = input_len +1+2+1+1+1+2;//头+长度+mode+submod+testitem+crc\r
+ replybuf = malloc(total_len);\r
+ printf("input_len 0x%02X, total_len 0x%02X\n",input_len,total_len);\r
+ if(replybuf == NULL) \r
+ {\r
+ printf("malloc buf failed!\r\n");\r
+ return ERRCODE_MALLOC;\r
+ }\r
+ factorytest_cmd_header_t pcmdheader ={0};\r
+ pcmdheader.header = BLE_TEST_PROTOCOL_HEADER;\r
+ pcmdheader.len = total_len - 2 -1 - 2; //去掉头,长度,crc\r
+ pcmdheader.mode = mode;\r
+ pcmdheader.submod = submode;\r
+ pcmdheader.testitem = testitem;\r
+ replybuf[0] = pcmdheader.header;\r
+ replybuf[1] = ((uint8_t*)&pcmdheader.len)[1];\r
+ replybuf[2] = ((uint8_t*)&pcmdheader.len)[0];\r
+ replybuf[3] = pcmdheader.mode;\r
+ replybuf[4] = pcmdheader.submod;\r
+ replybuf[5] = pcmdheader.testitem;\r
+ if (input_len>0)\r
+ memcpy_s(replybuf+1+2+1+1+1/*header+len+mode+submod+testitem*/,input_len,input_data,input_len);\r
+ //计算除了crc外的所有数据\r
+ uint16_t crc16 = CRC16_XMODEM(replybuf,total_len - 2);\r
+ \r
+ replybuf[total_len-1] = ((uint8_t *) &crc16 )[0];\r
+ replybuf[total_len-2] = ((uint8_t *) &crc16 )[1];\r
+ for ( int i = 0; i<total_len;i++){\r
+ printf("%02X ",replybuf[i]);\r
+ }\r
+ printf("\r\n");\r
+ ret = ble_factorytest_server_send_input_report(replybuf,total_len);\r
+ free(replybuf);\r
+ return ret;\r
+}\r
+/**\r
+ * BLE_TEST_CMD_MODE_COMMON\r
+ * factorytest_protocol_common_decode\r
+*/\r
+void factorytest_protocol_common_decode(uint8_t submode,uint8_t testitem,uint8_t* data,uint16_t len)\r
+{\r
+ errcode_t ret;\r
+ printf("submode 0x%02X testitem 0x%02X\r\n",submode,testitem);\r
+ switch(submode)\r
+ {\r
+ case BLE_TEST_CMD_COMMON_SUB_MODE_SYSTEM_VERSION:\r
+ if (testitem == 0x02)\r
+ {\r
+\r
+ uint8_t buildversion[128]={0};\r
+ uint16_t versionlen = 128;\r
+ ret = uapi_get_buildversion(buildversion,versionlen);\r
+ factorytest_protocol_replymsg(BLE_TEST_CMD_MODE_COMMON,\r
+ BLE_TEST_CMD_COMMON_SUB_MODE_SYSTEM_VERSION,\r
+ 0x02,\r
+ buildversion,\r
+ strlen((char*)buildversion));\r
+ }\r
+ break;\r
+\r
+ default:\r
+ printf("");\r
+ break;\r
+\r
+ }\r
+}\r
+errcode_t factorytest_protocol_decode(uint8_t *buf, uint16_t event_size)\r
+{\r
+ if(buf != NULL && event_size>=(1+2+1+1+1+2/*header+len+mod+submod+item+crc*/))\r
+ {\r
+ factorytest_cmd_header_t header ={0};\r
+ header.header = buf[0];\r
+ ((uint8_t *)&header.len)[1] = buf[1];\r
+ ((uint8_t *)&header.len)[0] = buf[2];\r
+ header.mode = buf[3];\r
+ header.submod = buf[4];\r
+ header.testitem = buf[5];\r
+ printf("header 0x%02X vs 0x%02X\n",header.header, buf[0]);\r
+ if (header.header == BLE_TEST_PROTOCOL_HEADER )\r
+ { \r
+ //消息长度大于event_size证明解析错误. \r
+ printf("(header->len 0x%04X\n",header.len);\r
+ if ((header.len + 1+2+2) > event_size) \r
+ {\r
+ printf("Error 数据长度大于eventsize\r\n");\r
+ return ERRCODE_FAIL;\r
+ }\r
+ uint16_t crc16 = CRC16_XMODEM(buf,header.len+1+2);\r
+ uint16_t crc16_2 = 0;\r
+ ((uint8_t *)&crc16_2)[1] = buf[event_size-2];\r
+ ((uint8_t *)&crc16_2)[0] = buf[event_size-1];\r
+ \r
+ printf("crc16 0x%04X vs 0x%04X\n",crc16,crc16_2);\r
+\r
+ if( crc16 == crc16_2) //校验通过,开始正式解析\r
+ {\r
+ printf("mode %d\n",header.mode);\r
+ switch(header.mode)\r
+ {\r
+ // 主模式ID 公共接口 0x01\r
+ case BLE_TEST_CMD_MODE_COMMON:\r
+ factorytest_protocol_common_decode(header.submod,header.testitem,\r
+ buf+1+2+1+1+1,\r
+ header.len);\r
+ break;\r
+ \r
+ // 主模式ID 生产软件 0x02\r
+ case BLE_TEST_CMD_MODE_SOFT_TEST:\r
+ break;\r
+ \r
+ // 主模式ID 硬测接口 0x03\r
+ case BLE_TEST_CMD_MODE_HW_TEST:\r
+ break;\r
+\r
+ // 主模式ID 串口接口 0x04\r
+ case BLE_TEST_CMD_MODE_SERIAL_PORT:\r
+ break;\r
+ }\r
+\r
+ }\r
+ \r
+ }else{\r
+ printf("crc error!\r\n");\r
+ return ERRCODE_FAIL;\r
+ }\r
+\r
+ }else{\r
+ printf("error format!\r\n");\r
+ return ERRCODE_FAIL;\r
+ }\r
+ return ERRCODE_SUCC;\r
+}\r
+\r
+\r
+errcode_t factorytest_ota_recv(const uint8_t *data, uint8_t len)\r
+{\r
+\r
+ return ERRCODE_SUCC;\r
+}\r
+\r
+errcode_t factorytest_ota_report(uint8_t mode, uint8_t submode,uint8_t testitem,\r
+ uint8_t *input_data,uint16_t input_len)\r
+{\r
+\r
+ return ERRCODE_SUCC;\r
+}\r
+\r
--- /dev/null
+/*
+ * Copyright (c) @CompanyNameMagicTag 2022. All rights reserved.
+ * Description: BT HID Service Server module.
+ */
+
+/**
+ * @defgroup bluetooth_bts_hid_server HID SERVER API
+ * @ingroup bluetooth
+ * @{
+ */
+#ifndef BLE_FACTORY_TEST_PROTOCOL_H
+#define BLE_FACTORY_TEST_PROTOCOL_H
+
+#include "errcode.h"
+
+#ifdef __cplusplus
+extern "C" {
+#endif
+// ATE工厂模式服务UUID: 00002760-08c2-11e1-9073-0e8afefd1000
+// OTA RX characteristic UUID: 00002760-08c2-11e1-9073-0e8afefd1001
+// OTA TX characteristic UUID: 00002760-08c2-11e1-9073-0e8afefd1002
+// ATE RX characteristic UUID: 00002760-08c2-11e1-9073-0e8afefd1003
+// ATE TX characteristic UUID: 00002760-08c2-11e1-9073-0e8afefd1004
+
+// 主模式ID 公共接口 0x01
+#define BLE_TEST_CMD_MODE_COMMON 0x01
+// 主模式ID 生产软件 0x02
+#define BLE_TEST_CMD_MODE_SOFT_TEST 0x02
+// 主模式ID 硬测接口 0x03
+#define BLE_TEST_CMD_MODE_HW_TEST 0x03
+// 主模式ID 串口接口 0x04
+#define BLE_TEST_CMD_MODE_SERIAL_PORT 0x04
+
+
+// 协议定义:
+// CRC 计算的所有数据的校驗值
+// 长度是从模块ID开始到CRC结束的长度
+// 发送:协议头(0xFD) + 长度(2bytes) +模块ID(1bytes)+子模块ID(1bytes)+测试项ID(1bytes)+可变字节+CRC(2bytes)
+// 接收:协议头(0xFD) + 长度(2bytes) +模块ID(1bytes)+子模块ID(1bytes)+测试项ID(1bytes)+执行状态(1bytes)+可变字节+CRC(2bytes)
+// 备注:
+// 1、状态返回00表示成功,01表示开始执行,其他表示各种错误。
+// 2、命令响应超时为:3秒,超时重发2次。
+// 3、大端模式。
+// 4、长耗时命令,先确认收到,执行完再返回结果。
+#define BLE_TEST_PROTOCOL_HEADER 0xFD
+
+
+//公共模式 子模式ID 模式切换
+#define BLE_TEST_CMD_COMMON_SUB_MODE_SWITCH_MODE 0x01
+//公共模式 子模式ID 系统版本
+#define BLE_TEST_CMD_COMMON_SUB_MODE_SYSTEM_VERSION 0x02
+//公共模式 子模式ID 开关机
+#define BLE_TEST_CMD_COMMON_SUB_MODE_POWER_ON_OFF_DEVICE 0x03
+//公共模式 子模式ID 功耗
+#define BLE_TEST_CMD_COMMON_SUB_MODE_POWERCONSUMPTION 0x04
+//公共模式 子模式ID OTA
+#define BLE_TEST_CMD_COMMON_SUB_MODE_OTA 0x05
+
+//软件测试 子模式ID 蓝牙
+#define BLE_TEST_CMD_SOFT_TEST_SUB_MODE_BLE 0x01
+//软件测试 子模式ID 马达
+#define BLE_TEST_CMD_SOFT_TEST_SUB_MODE_VIBRATOR 0x02
+//软件测试 子模式ID 按键
+#define BLE_TEST_CMD_SOFT_TEST_SUB_MODE_KEY 0x03
+//软件测试 子模式ID RTC
+#define BLE_TEST_CMD_SOFT_TEST_SUB_MODE_RTC 0x04
+//软件测试 子模式ID 温度
+#define BLE_TEST_CMD_SOFT_TEST_SUB_MODE_TEMPERATURE 0x05
+
+//软件测试 子模式ID 老化测试
+#define BLE_TEST_CMD_SOFT_TEST_SUB_MODE_AGING_TEST 0x06
+
+//软件测试 子模式ID 定制测试 读写SN等 读CHIPID
+#define BLE_TEST_CMD_SOFT_TEST_SUB_MODE_CUSTOM_CMD 0x07
+
+//软件测试 子模式ID 屏幕
+#define BLE_TEST_CMD_SOFT_TEST_SUB_MODE_LCD 0x11
+//软件测试 子模式ID TP
+#define BLE_TEST_CMD_SOFT_TEST_SUB_MODE_TP 0x12
+//软件测试 子模式ID ACC
+#define BLE_TEST_CMD_SOFT_TEST_SUB_MODE_ACC 0x13
+//软件测试 子模式ID 心率
+#define BLE_TEST_CMD_SOFT_TEST_SUB_MODE_HRS 0x14
+//软件测试 子模式ID 地磁
+#define BLE_TEST_CMD_SOFT_TEST_SUB_MODE_COMPASS 0x16
+//软件测试 子模式ID 电源管理
+#define BLE_TEST_CMD_SOFT_TEST_SUB_MODE_PM 0x17
+//软件测试 子模式ID 扩展FLASH
+#define BLE_TEST_CMD_SOFT_TEST_SUB_MODE_EXTFLASH 0x18
+//软件测试 子模式ID 扩展RAM
+#define BLE_TEST_CMD_SOFT_TEST_SUB_MODE_EXTRAM 0x19
+//软件测试 子模式ID CAT1
+#define BLE_TEST_CMD_SOFT_TEST_SUB_MODE_CAT1 0x1A
+/**
+ *
+ * encode cmd msg string and send to ble
+ * input: mod,submod,data,len
+ * output: output_data
+ * return:0 success other failed
+ * 请注意:output内存是函数内部创建,用后需要执行 factorytest_cmd_msg_free .
+*/
+errcode_t factorytest_protocol_replymsg(uint8_t mode, uint8_t submode,uint8_t testitem,
+ uint8_t *input_data,uint16_t input_len);
+/***
+ * decode protocol data
+*/
+errcode_t factorytest_protocol_decode(uint8_t *buf, uint16_t event_size);
+
+errcode_t factorytest_ota_recv(const uint8_t *data, uint8_t len);
+errcode_t factorytest_ota_report(uint8_t mode, uint8_t submode,uint8_t testitem,
+ uint8_t *input_data,uint16_t input_len);
+
+/**
+ * @}
+ */
+#ifdef __cplusplus
+}
+#endif
+
+
+#endif//BLE_FACTORY_TEST_PROTOCOL_H
#ifdef SUPPORT_CHARGER_PLUG_DETECTION_NOTIFICATION
{TOPIC_EVENT_CHARGE_PLUG, PRIORITY_TWO},
{TOPIC_EVENT_CHARGE_UNPLUG, PRIORITY_TWO},
+ {TOPIC_EVENT_LOWPOWER_ALARM,PRIORITY_TWO},
#endif
{TOPIC_EVENT_HFP_INCOMMING, PRIORITY_ONE},
{TOPIC_EVENT_HFP_FINISHED, PRIORITY_ONE},
{TOPIC_EVENT_HFP_WATCH_ACTIVE, PRIORITY_ONE},
{TOPIC_EVENT_HFP_WATCH_TO_PHONE, PRIORITY_ONE},
{TOPIC_EVENT_HFP_PHONE_TO_WATCH, PRIORITY_ONE},
+
#ifdef SUPPORT_CAT1_MODEM
{TOPIC_EVENT_CAT1_INCOMMING, PRIORITY_ONE},
{TOPIC_EVENT_CAT1_CALLCONNTED, PRIORITY_ONE},
#ifdef SUPPORT_CHARGER_PLUG_DETECTION_NOTIFICATION
MsgCenterSubscribeTopic(TOPIC_EVENT_CHARGE_PLUG);
MsgCenterSubscribeTopic(TOPIC_EVENT_CHARGE_UNPLUG);
+ MsgCenterSubscribeTopic(TOPIC_EVENT_LOWPOWER_ALARM);
#endif
#ifdef SUPPORT_SPO2_NOTIFICATION_TEST
MsgCenterSubscribeTopic(TOPIC_EVENT_SPO2_UPDATE);
t->ChangeViewcolor(false);
}
}
+
+void MsgCenterNotifyLowPowerAlarmProc(const Topic topic, Request* req)
+{
+ unused(req);
+ unused(topic);
+ WEARABLE_LOGI(WEARABLE_LOG_MODULE_APP, "MsgCenterNotifyProc:: LowPower Alarm !");
+ //TODO: 亮屏弹窗倒计时5秒关机(不需要取消,强制关机)
+ // DialModelCharge::GetInstance()->UpdateChargeStuaut(0);
+ // SaveEleModel::GetInstance()->SetChargeStuaut(0);
+
+ // testCHANINGView *t=testCHANINGView::GetInstance();
+ // if(t!=NULL)
+ // {
+ // t->ChangeViewcolor(false);
+ // }
+}
+
#endif
void MsgCenterNotifyNextDayProc(const Topic topic, Request* req)
{
#ifdef SUPPORT_CHARGER_PLUG_DETECTION_NOTIFICATION
{TOPIC_EVENT_CHARGE_PLUG, MsgCenterNotifyChargePlugProc},
{TOPIC_EVENT_CHARGE_UNPLUG, MsgCenterNotifyChargeUnPlugProc},
+ {TOPIC_EVENT_LOWPOWER_ALARM, MsgCenterNotifyLowPowerAlarmProc},
#endif
#ifdef SUPPORT_SPO2_NOTIFICATION_TEST
{TOPIC_EVENT_SPO2_UPDATE, MsgCenterNotifySPO2hProc},
--- /dev/null
+/*
+* Copyright (c) xxxxxxxx Technologies Co., Ltd. 2021-2021. All rights reserved.
+* Description: language
+* Author: Graphic develop team
+* Create: 2021-07-06
+*/
+
+#ifndef UI_RESOURCE_STRING_H
+#define UI_RESOURCE_STRING_H
+#include <cstdint>
+namespace OHOS {
+enum UIResourceTextId : uint16_t {
+ STR_EXERCISE_GENERAL = 0,\r
+ STR_EXERCISE_FREETRAINING = 1,\r
+ STR_EXERCISE_RESISTANCETRAINING = 2,\r
+ STR_EXERCISE_SPINBIKE = 3,\r
+ STR_EXERCISE_TREADMILL = 4,\r
+ STR_EXERCISE_STROLLMACHINE = 5,\r
+ STR_EXERCISE_HIIT = 6,\r
+ STR_EXERCISE_CROSSFIT = 7,\r
+ STR_EXERCISE_GROUPCALISTHENICS = 8,\r
+ STR_EXERCISE_YOGA = 9,\r
+ STR_EXERCISE_YOGACAT = 10,\r
+ STR_EXERCISE_YOGACOW = 11,\r
+ STR_EXERCISE_YOGACOBRA = 12,\r
+ STR_EXERCISE_YOGAHERO1 = 13,\r
+ STR_EXERCISE_YOGAHERO2 = 14,\r
+ STR_EXERCISE_YOGAHERO3 = 15,\r
+ STR_EXERCISE_YOGAROLLING = 16,\r
+ STR_EXERCISE_OUTDOORWALKING = 17,\r
+ STR_EXERCISE_OUTDOORRUNNING = 18,\r
+ STR_EXERCISE_INDOORWALKING = 19,\r
+ STR_EXERCISE_INDOORRUNNING = 20,\r
+ STR_EXERCISE_OUTDOORBIKING = 21,\r
+ STR_EXERCISE_JUMPINGROPE = 22,\r
+ STR_EXERCISE_PILATES = 23,\r
+ STR_EXERCISE_CROSS_FIT = 24,\r
+ STR_EXERCISE_FUNCTIONALTRAINING = 25,\r
+ STR_EXERCISE_PHYSICALTRAINING = 26,\r
+ STR_EXERCISE_TAEKWONDO = 27,\r
+ STR_EXERCISE_BOXING = 28,\r
+ STR_EXERCISE_KICKBOXING = 29,\r
+ STR_EXERCISE_KARATE = 30,\r
+ STR_EXERCISE_FENCING = 31,\r
+ STR_EXERCISE_CORETRAINING = 32,\r
+ STR_EXERCISE_BODYCOMBAT = 33,\r
+ STR_EXERCISE_KENDO = 34,\r
+ STR_EXERCISE_HORIZONTALBAR = 35,\r
+ STR_EXERCISE_PARALLELBARS = 36,\r
+ STR_EXERCISE_AEROBICS = 37,\r
+ STR_EXERCISE_CALISTHENICE = 38,\r
+ STR_EXERCISE_P90X = 39,\r
+ STR_EXERCISE_KETTLEBELLTRAINING = 40,\r
+ STR_EXERCISE_MIXEDMARTIALARTS = 41,\r
+ STR_EXERCISE_STAIRCLIMBINGMACHINE = 42,\r
+ STR_EXERCISE_WEIGHTLIFTING = 43,\r
+ STR_EXERCISE_BARRE = 44,\r
+ STR_EXERCISE_HANDCYCLING = 45,\r
+ STR_EXERCISE_TRACKFIELD = 46,\r
+ STR_EXERCISE_WRESTLING = 47,\r
+ STR_EXERCISE_MINDBODY = 48,\r
+ STR_EXERCISE_FLEXIBILITY = 49,\r
+ STR_EXERCISE_MIXEDCARDIO = 50,\r
+ STR_EXERCISE_TRADITIONALSTRENGTHTRAINING = 51,\r
+ STR_EXERCISE_CROSSTRAINING = 52,\r
+ STR_EXERCISE_GYMNASTICS = 53,\r
+ STR_EXERCISE_STEPTRAINING = 54,\r
+ STR_EXERCISE_ELLIPTICALTRAINER = 55,\r
+ STR_EXERCISE_ROWINGMACHINE = 56,\r
+ STR_DANCING_GENERAL = 57,\r
+ STR_DANCING_BELLY = 58,\r
+ STR_DANCING_JAZZ = 59,\r
+ STR_DANCING_LATIN = 60,\r
+ STR_DANCING_BALLET = 61,\r
+ STR_DANCING_STREET = 62,\r
+ STR_DANCING_PUBLICSQUARE = 63,\r
+ STR_DANCING_ZUMBA = 64,\r
+ STR_DANCING_SOCIALDANCE = 65,\r
+ STR_DANCING_TAPDANCE = 66,\r
+ STR_RECREATIONAL_SPORTS = 67,\r
+ STR_RECREATIONAL_SKATING = 68,\r
+ STR_RECREATIONAL_MARTIALARTS = 69,\r
+ STR_RECREATIONAL_TAICHI = 70,\r
+ STR_RECREATIONAL_HULAHOOP = 71,\r
+ STR_RECREATIONAL_DISCSPORT = 72,\r
+ STR_RECREATIONAL_DARTS = 73,\r
+ STR_RECREATIONAL_ARCHERY = 74,\r
+ STR_RECREATIONAL_HORSERIDING = 75,\r
+ STR_RECREATIONAL_BATTLEGAME = 76,\r
+ STR_RECREATIONAL_KITE = 77,\r
+ STR_RECREATIONAL_TUGOFWAR = 78,\r
+ STR_RECREATIONAL_SWING = 79,\r
+ STR_RECREATIONAL_STAIRCLIMBING = 80,\r
+ STR_RECREATIONAL_OBSTACLERACE = 81,\r
+ STR_RECREATIONAL_FISHING = 82,\r
+ STR_RECREATIONAL_HUNTING = 83,\r
+ STR_RECREATIONAL_SCOOTERRIDING = 84,\r
+ STR_RECREATIONAL_PARAGLIDING = 85,\r
+ STR_RECREATIONAL_TEAMSPORTS = 86,\r
+ STR_RECREATIONAL_FINESSGAMING = 87,\r
+ STR_RECREATIONAL_HIKING = 88,\r
+ STR_RECREATIONAL_EQUESTRIANSPORTS = 89,\r
+ STR_RECREATIONAL_PLAY = 90,\r
+ STR_BALL_GAMES = 91,\r
+ STR_BALL_BADMINTON = 92,\r
+ STR_BALL_TABLETENNIS = 93,\r
+ STR_BALL_TENNIS = 94,\r
+ STR_BALL_BILLIARDS = 95,\r
+ STR_BALL_BOWLING = 96,\r
+ STR_BALL_VOLLEYBALL = 97,\r
+ STR_BALL_SHUTTLECOCK = 98,\r
+ STR_BALL_HANDBALL = 99,\r
+ STR_BALL_BASEBALL = 100,\r
+ STR_BALL_SOFTBALL = 101,\r
+ STR_BALL_CRICKET = 102,\r
+ STR_BALL_FOOTBALL = 103,\r
+ STR_BALL_BEACHSOCCER = 104,\r
+ STR_BALL_BEACHVOLLEYBALL = 105,\r
+ STR_BALL_CROQUET = 106,\r
+ STR_BALL_HOCKEY = 107,\r
+ STR_BALL_SQUASH = 108,\r
+ STR_BALL_SEPAKTAKRAW = 109,\r
+ STR_BALL_DODGEBALL = 110,\r
+ STR_BALL_BASKETBALL = 111,\r
+ STR_BALL_SOCCER = 112,\r
+ STR_BALL_GOLF = 113,\r
+ STR_BALL_POLO = 114,\r
+ STR_BALL_RACQUETBALL = 115,\r
+ STR_BALL_RUGBY = 116,\r
+ STR_BALL_GATEBALL = 117,\r
+ STR_BALL_PICKLEBALL = 118,\r
+ STR_BALL_LACROSSE = 119,\r
+ STR_WATER_ACTIVITIES = 120,\r
+ STR_WATER_SAILING = 121,\r
+ STR_WATER_SURFING = 122,\r
+ STR_WATER_WHITEWATERRAFTING = 123,\r
+ STR_WATER_CANOEING = 124,\r
+ STR_WATER_KAYAKING = 125,\r
+ STR_WATER_ROWING = 126,\r
+ STR_WATER_MOTORBOAT = 127,\r
+ STR_WATER_SUP = 128,\r
+ STR_WATER_SCUBADIVING = 129,\r
+ STR_WATER_DIVING = 130,\r
+ STR_WATER_KITESURFING = 131,\r
+ STR_WATER_WAKEBOARDING = 132,\r
+ STR_WATER_POLO = 133,\r
+ STR_WATER_WINDSURFING = 134,\r
+ STR_WATER_DRIFTING = 135,\r
+ STR_WATER_FITNESS = 136,\r
+ STR_WATER_SPORTS = 137,\r
+ STR_WATER_OUTDOORSWIM = 138,\r
+ STR_WATER_INDOORSWIM = 139,\r
+ STR_WATER_SWIMFREESTYLE = 140,\r
+ STR_WATER_SWIMBREASTSTROKE = 141,\r
+ STR_WATER_SWIMBACKSTROKE = 142,\r
+ STR_WATER_SWIMBUTTERFLY = 143,\r
+ STR_ICE_SPORTS = 144,\r
+ STR_ICE_SKATING = 145,\r
+ STR_ICE_HOCKEY = 146,\r
+ STR_ICE_CURLING = 147,\r
+ STR_ICE_SNOWMOBILING = 148,\r
+ STR_ICE_SLED = 149,\r
+ STR_ICE_BIATHLON = 150,\r
+ STR_ICE_CROSSCOUNTRYSKING = 151,\r
+ STR_ICE_SKIING = 152,\r
+ STR_ICE_SNOWBOARDING = 153,\r
+ STR_ICE_SNOWSHOEING = 154,\r
+ STR_ICE_SNOWSPORTS = 155,\r
+ STR_EXTREME_SPORTS = 156,\r
+ STR_EXTREME_SKATEBOARDING = 157,\r
+ STR_EXTREME_ROCKCLIMBING = 158,\r
+ STR_EXTREME_BUNGEEJUMPING = 159,\r
+ STR_EXTREME_PARKOUR = 160,\r
+ STR_EXTREME_BMX = 161,\r
+ STR_EXTREME_ORIENTEERING = 162,\r
+ STR_EXTREME_PARACHUTE = 163,\r
+ STR_EXTREME_RACING = 164,\r
+ STR_EXTREME_TRIATHLONS = 165,\r
+ STR_OTHER_ELEVATOR = 166,\r
+ STR_OTHER_ESCALATOR = 167,\r
+ STR_OTHER_GARDENING = 168,\r
+ STR_OTHER_HORSEWORK = 169,\r
+ STR_OTHER_INVEHICLE = 170,\r
+ STR_OTHER_MEDITATION = 171,\r
+ STR_OTHER_STILL = 172,\r
+ STR_OTHER_TILTING = 173,\r
+ STR_OTHER_WHEELCHAIR = 174,\r
+ STR_MAX_ID = 175,\r
+}; // UIResourceTextId\r
+
+enum FontLanguageId : uint8_t {
+ LANGUAGE_ID_EN,\r
+ LANGUAGE_ID_ZH,\r
+ LANGUAGE_ID_MAX\r
+}; // UITextLanguageTextId\r
+}\r
+#endif /* UI_RESOURCE_STRING_H */\r
+++ /dev/null
-{
- "languages": {
- "zh": {
- "path": "user/res/language_config/font/zh.lang"
- },
- "en": {
- "path": "user/res/language_config/font/en.lang"
- }
- },
- "languages_satuas": 0
-}
\ No newline at end of file
+++ /dev/null
-/*
-* Copyright (c) xxxxxxxx Technologies Co., Ltd. 2021-2021. All rights reserved.
-* Description: language
-* Author: Graphic develop team
-* Create: 2021-07-06
-*/
-
-#ifndef UI_RESOURCE_STRING_H
-#define UI_RESOURCE_STRING_H
-#include <cstdint>
-namespace OHOS {
-enum UIResourceTextId : uint16_t {
- STR_IMAGE = 0,\r
- STR_PROGRESSBAR = 1,\r
- STR_SLIDEUNLOCK = 2,\r
- STR_LISTBOX = 3,\r
- STR_BUTTON = 4,\r
- STR_SCROLLVIEW = 5,\r
- STR_SCROLLGRID = 6,\r
- STR_CLOCK = 7,\r
- STR_DISTURBANCE = 8,\r
- STR_BRIGHT = 9,\r
- STR_PHONE = 10,\r
- STR_LANGAGE = 11,\r
- STR_ALARM = 12,\r
- STR_SYSTEM = 13,\r
- STR_SPO2 = 14,\r
- STR_COMPASS = 15,\r
- STR_INDOORWALK = 16,\r
- STR_WEATHER = 17,\r
- STR_SYSTEMSETTING = 18,\r
- STR_MAX_ID = 19,\r
-}; // UIResourceTextId\r
-
-enum FontLanguageId : uint8_t {
- LANGUAGE_ID_ZH,\r
- LANGUAGE_ID_EN,\r
- LANGUAGE_ID_MAX\r
-}; // UITextLanguageTextId\r
-}\r
-#endif /* UI_RESOURCE_STRING_H */\r
extern void get_gsonsen_xyz(gsenson_t *t);
+extern void gsensor_get_n_data(uint8_t cnt);
+
#pragma pack()
int cywee_main_dml(void);
void cywee_int_handler(void);
+
+
#ifdef __cplusplus
#if __cplusplus
}
#define GSENSON_MSG_COUNT 16
osal_mutex mutex_gsenson_queue;
+osal_mutex mutex_gsensor_queue_ext;
static unsigned long gsenson_queue;
+
void uapi_GSENSON_create_queue(void)
{
- if (osal_msg_queue_create("battery_queue", GSENSON_MSG_COUNT, &gsenson_queue,
- 0, sizeof(gsenson_t)) != ERRCODE_SUCC) {
- //PRINT("[battery][service] app create mail fail\n");
+ if ( (osal_msg_queue_create("gsensor_queue", GSENSON_MSG_COUNT, &gsenson_queue,0, sizeof(gsenson_t)) )!= ERRCODE_SUCC)
+ {
+ CWM_OS_dbgPrintf("gsensor_queue create fail\r\n");
}
osal_mutex_init(&mutex_gsenson_queue);
static gsenson_t gxyz_t;
static uint8_t gsenson_falg=0;
+
+static uint16 num_falg=0;
+static gsenson_t gxyz_t_queue[16]={0};
+static int16 left_falg=0;
+static int16 right_falg=-1;
+
+
void get_gsonsen_xyz(gsenson_t *t)
{
- if(osal_mutex_trylock(&mutex_gsenson_queue)==0)
+ if(osal_mutex_trylock(&mutex_gsenson_queue)==0)
+ {
+ CWM_OS_dbgPrintf("get_gsonsen_xyz_fail\n");
+ return;
+ }
+ t->x = gxyz_t_queue[left_falg].x;
+ t->y = gxyz_t_queue[left_falg].y;
+ t->z = gxyz_t_queue[left_falg].z;
+ osal_mutex_unlock(&mutex_gsenson_queue);
+}
+
+void gsensor_get_n_data(uint8_t cnt)
+{
+ for(int i=0;i<cnt;i++)
{
- CWM_OS_dbgPrintf("get_gsonsen_xyz_fail\n");
- return;
+ if(osal_mutex_trylock(&mutex_gsenson_queue)==0)
+ {
+ CWM_OS_dbgPrintf("get_gsonsen_xyz_fail\n");
+ return;
+ }
+ CWM_OS_dbgPrintf("x : %d , y : %d , z : %d\n", gxyz_t_queue[left_falg].x, gxyz_t_queue[left_falg].y, gxyz_t_queue[left_falg].z);
+ if(num_falg==0)
+ {
+ break;
+ }
+ left_falg++;
+ left_falg=left_falg%16;
+ num_falg--;
+ osal_mutex_unlock(&mutex_gsenson_queue);
}
- t->x=gxyz_t.x;
- t->y=gxyz_t.y;
- t->z=gxyz_t.z;
- CWM_OS_dbgPrintf("get_gsonsen_%d,%d,%d\n",t->x, t->y,t->z);
- osal_mutex_unlock(&mutex_gsenson_queue);
-}
+}
+//static int flag=32;
void CWM_AP_SensorListen(pSensorEVT_t sensorEVT) {
switch (sensorEVT->sensorType) {
case IDX_ACCEL:
- #if 1
- // CWM_OS_dbgPrintf("acc: x=%.3f, y=%.3f, z=%.3f\n",
- // sensorEVT->fData[0],
- // sensorEVT->fData[1],
- // sensorEVT->fData[2]
- // );
- if(osal_msg_queue_is_full(gsenson_queue))
- {
-
- gsenson_t t;
- int ret=osal_msg_queue_read_copy(gsenson_queue, &t, sizeof(gsenson_t),OSAL_MSGQ_NO_WAIT);
- if(osal_mutex_trylock(&mutex_gsenson_queue)==0)
- {
- CWM_OS_dbgPrintf("get_gsonsen_xxxxxxxx_fail\n");
- break;
- }
- gxyz_t.x=t.x;
- gxyz_t.y=t.y;
- gxyz_t.z=t.z;
- osal_mutex_unlock(&mutex_gsenson_queue);
-
- if(ret!=0)
- {
- CWM_OS_dbgPrintf("osal_msg_queue_read_copyz_fail\n");
- }
- t.x=sensorEVT->fData[0]*1024;
- t.y=sensorEVT->fData[1]*1024;
- t.z=sensorEVT->fData[2]*1024;
- ret=osal_msg_queue_write_copy(gsenson_queue, &t, sizeof(gsenson_t),OSAL_MSGQ_NO_WAIT);
- if(ret!=0)
- {
- CWM_OS_dbgPrintf("osal_msg_queue_write_copy_fail\n");
- }
-
-
- }
- else
- {
- gsenson_t t;
- t.x=sensorEVT->fData[0];
- t.y=sensorEVT->fData[1];
- t.z=sensorEVT->fData[2];
- int ret= osal_msg_queue_write_copy(gsenson_queue, &t, sizeof(gsenson_t),OSAL_MSGQ_NO_WAIT);
- if(ret!=0)
- {
- CWM_OS_dbgPrintf("osal_msg_queue_write_copy_fail\n");
- }
-
- }
-
+ #if 1
+ if(osal_mutex_trylock(&mutex_gsenson_queue)==0)
+ {
+ CWM_OS_dbgPrintf("get_gsonsen_xxxxxxxx_fail\n");
+ break;
+ }
+ if(num_falg==16)
+ {
+ left_falg++;
+ right_falg++;
+ right_falg=right_falg%16;
+ left_falg=left_falg%16;
+ gxyz_t_queue[right_falg].x= sensorEVT->fData[0];
+ gxyz_t_queue[right_falg].y= sensorEVT->fData[1];
+ gxyz_t_queue[right_falg].z= sensorEVT->fData[2];
+
+ }
+ else
+ {
+ //left_falg++;
+ right_falg++;
+ right_falg=right_falg%16;
+ //left_falg=left_falg%16;
+ num_falg++;
+ gxyz_t_queue[right_falg].x= sensorEVT->fData[0];
+ gxyz_t_queue[right_falg].y= sensorEVT->fData[1];
+ gxyz_t_queue[right_falg].z= sensorEVT->fData[2];
+ CWM_OS_dbgPrintf("write: x=%d, y=%d, z=%d\n", gxyz_t_queue[right_falg].x ,gxyz_t_queue[right_falg].y ,gxyz_t_queue[right_falg].z);
+
+ }
+ osal_mutex_unlock(&mutex_gsenson_queue);
#endif
break;
CWM_SettingControl(SCL_CHIP_VENDOR_CONFIG, &scl);
//CWM_OS_dbgPrintf("[DBG] %s %d\n", __func__,__LINE__);
+ uapi_GSENSON_create_queue();
CWM_LibPostInit(CWM_AP_SensorListen);
//CWM_OS_dbgPrintf("[DBG] %s %d\n", __func__,__LINE__);
{
//默认是:WatchSoar
printf("是默认值,修改名称\n");
- sprintf_s((char*)(name),sizeof(name),"WatchSoar_%02X%02X",bd_addr[1],bd_addr[0]);
+ sprintf_s((char*)(name),sizeof(name),"WatchSoar%02X%02X",bd_addr[1],bd_addr[0]);
printf("uapi_set_nv_btname %s , namelen %d\n",name,namelen);
ret = uapi_set_nv_btname(name,strlen((char*)name));
if (ret != ERRCODE_SUCC) {