STR_SCHEDULE_TIME = 534,\r
STR_SCHEDULE_NOTES = 535,\r
STR_SCHEDULE_DELETE_PROMPT = 536,\r
- STR_MAX_ID = 537,\r
+ STR_HANG_UP_OR_ANSWER = 537,\r
+ STR_WATCH_CALL = 538,\r
+ STR_PHONE_CALL = 539,\r
+ STR_MAX_ID = 540,\r
}; // UIResourceTextId\r
enum FontLanguageId : uint8_t {
- LANGUAGE_ID_ZH,\r
LANGUAGE_ID_EN,\r
+ LANGUAGE_ID_ZH,\r
LANGUAGE_ID_MAX\r
}; // UITextLanguageTextId\r
}\r
UIImageView *imageDissgree{nullptr};
UIImageView *imageperson{nullptr};
- UILabel *callerDisplay{nullptr};
- UILabel *currentTimes{nullptr};
+ UILabelExt *callerDisplay{nullptr};
+ UILabelExt *currentTimes{nullptr};
- UILabel *label_call_source{nullptr};
- UILabel *label_call_hint{nullptr};
+ UILabelExt *label_call_source{nullptr};
+ UILabelExt *label_call_hint{nullptr};
};
}
#include "ChangeSliceListener.h"
#include "components/ui_label_button.h"
+
namespace OHOS {
class CallingView {
public:
UIImageView *imageperson{nullptr};
UILabel *callerDisplay{nullptr};
- UILabel *currentTimes{nullptr};
+ UILabelExt *currentTimes{nullptr};
UILabel *callDuration{nullptr};
UIViewGroup *dial_group{nullptr};
#include "MainCallingPresenter.h"
#include "UiConfig.h"
#include "phoneaddressmodel.h"
+#include "ui_resource_string.h"
namespace OHOS {
static constexpr uint16 MATH_ZERO = 0;
bool CallerDisplayView::InitUILabelDisplay()
{
- callerDisplay = new UILabel();
+ callerDisplay = new UILabelExt();
if (callerDisplay == nullptr) {
return false;
}
group->Add(callerDisplay);
if (label_call_hint == nullptr) {
- label_call_hint = new UILabel();
+ label_call_hint = new UILabelExt();
}
- label_call_hint->SetPosition(163, 353); // widget's left position and top position
- label_call_hint->Resize(140, 35); // widget's width and height
+ label_call_hint->SetPosition(133, 353); // widget's left position and top position
+ label_call_hint->Resize(200, 35); // widget's width and height
label_call_hint->SetViewId("label3");// Set style
label_call_hint->SetStyle(STYLE_TEXT_FONT, 30);
// Set additional property
label_call_hint->SetText("挂断/接听");
- label_call_hint->SetLineBreakMode(UILabel::LINE_BREAK_ELLIPSIS);
+ label_call_hint->SetTextId(STR_HANG_UP_OR_ANSWER);
+
+ label_call_hint->SetLineBreakMode(UILabel::LINE_BREAK_MARQUEE);
label_call_hint->SetTextColor(Color::GetColorFromRGBA(0xAA, 0xAA, 0xAA, 0xff));
label_call_hint->SetAlign(TEXT_ALIGNMENT_CENTER, TEXT_ALIGNMENT_CENTER);
label_call_hint->SetRollSpeed(0);
if (label_call_source == nullptr) {
- label_call_source = new UILabel();
+ label_call_source = new UILabelExt();
}
label_call_source->SetPosition(133, 34); // widget's left position and top position
label_call_source->Resize(200, 60); // widget's width and height
label_call_source->SetStyle(STYLE_TEXT_FONT, 30);
// Set additional property
- if (CallerLogModel::GetInstance()->GetCallSource() == CallerLogModel::CallSourceCat1)
- label_call_source->SetText("手表来电");
+ if (CallerLogModel::GetInstance()->GetCallSource() == CallerLogModel::CallSourceCat1)
+ {
+ label_call_source->SetText("手表来电");
+ label_call_source->SetTextId(STR_WATCH_CALL);
+ }
else
- label_call_source->SetText("手机来电");
+ {
+ label_call_source->SetText("手机来电");
+ label_call_source->SetTextId(STR_PHONE_CALL);
+ }
+
label_call_source->SetLineBreakMode(UILabel::LINE_BREAK_MARQUEE);
label_call_source->SetTextColor(Color::GetColorFromRGBA(0xAA, 0xAA, 0xAA, 0xff));
#include "custom_utils.h"
#include "phoneaddressmodel.h"
#include "bletest.h"
+#include "ui_resource_string.h"
namespace OHOS {
static constexpr uint16 MATH_ZERO = 0;
// group->Add(callDuration);
- currentTimes = new UILabel();
+ currentTimes = new UILabelExt();
if (currentTimes == nullptr) {
return false;
}
- currentTimes->SetPosition(194, 38,
- 79, 35);
+ currentTimes->SetPosition(184, 38,
+ 89, 35);
currentTimes->SetStyle(STYLE_BACKGROUND_COLOR, OPA_TRANSPARENT);
currentTimes->SetAlign(TEXT_ALIGNMENT_CENTER);
-
+ currentTimes->SetLineBreakMode(UILabel::LINE_BREAK_WRAP);
currentTimes->SetText(CallerLogModel::GetInstance()->InitDateHourTime().c_str());
WEARABLE_LOGE(WEARABLE_LOG_MODULE_APP, "CallingView::InitUILabelDisplay error");
return nullptr;
}
- currentTimes->SetText("拨号中..."); /* code */
+ currentTimes->SetTextId(STR_CALLING); /* code */
if(!Initshowdial())
{
delete screenView;
screenView = nullptr;
+ delete waitingView;
+ waitingView = nullptr;
+
+
g_pMainView = nullptr;
}
WaitingHintsView::~WaitingHintsView()
{
g_pMainView = nullptr;
+
+ group->RemoveAll();
+ delete imageDissgree;
+ imageDissgree = nullptr;
+
+ delete callerDisplay;
+ callerDisplay = nullptr;
+
+ delete newcallHints;
+ newcallHints = nullptr;
+
+
+ delete group;
+ group = nullptr;
+
}
UIViewGroup *WaitingHintsView::CreateUIViewGroup()
STR_SCHEDULE_TIME = 534,\r
STR_SCHEDULE_NOTES = 535,\r
STR_SCHEDULE_DELETE_PROMPT = 536,\r
- STR_MAX_ID = 537,\r
+ STR_HANG_UP_OR_ANSWER = 537,\r
+ STR_WATCH_CALL = 538,\r
+ STR_PHONE_CALL = 539,\r
+ STR_MAX_ID = 540,\r
}; // UIResourceTextId\r
enum FontLanguageId : uint8_t {
- LANGUAGE_ID_ZH,\r
LANGUAGE_ID_EN,\r
+ LANGUAGE_ID_ZH,\r
LANGUAGE_ID_MAX\r
}; // UITextLanguageTextId\r
}\r
STR_DIAL_VIA_WATCH_SIM$Dial via Watch SIM\r
STR_DIAL_VIA_PHONE$Dial via Phone\r
STR_KUMI_TECHNOLOGY$KUMI Technology\r
-STR_CALLING$Calling\r
+STR_CALLING$Calling...\r
STR_NOT_PAIRED$Not Paired\r
STR_PAIRED$Paired\r
STR_UNPAIR$Unpair\r
STR_SCHEDULE_TOPIC$Topic:\r
STR_SCHEDULE_TIME$Time:\r
STR_SCHEDULE_NOTES$Notes:\r
-STR_SCHEDULE_DELETE_PROMPT$Delete this schedule
\ No newline at end of file
+STR_SCHEDULE_DELETE_PROMPT$Delete this schedule\r
+STR_HANG_UP_OR_ANSWER$HangUp/Answer\r
+STR_WATCH_CALL$Watch Call\r
+STR_PHONE_CALL$Phone Call
\ No newline at end of file
STR_DIAL_VIA_WATCH_SIM$通过手表SIM卡拨号\r
STR_DIAL_VIA_PHONE$通过手机拨号\r
STR_KUMI_TECHNOLOGY$库密科技\r
-STR_CALLING$拨号中\r
+STR_CALLING$拨号中...\r
STR_NOT_PAIRED$未配对\r
STR_PAIRED$已配对\r
STR_UNPAIR$取消配对\r
STR_SCHEDULE_TOPIC$主题:\r
STR_SCHEDULE_TIME$时间:\r
STR_SCHEDULE_NOTES$备注:\r
-STR_SCHEDULE_DELETE_PROMPT$是否确认删除该日程
\ No newline at end of file
+STR_SCHEDULE_DELETE_PROMPT$是否确认删除该日程\r
+STR_HANG_UP_OR_ANSWER$挂断/接听\r
+STR_WATCH_CALL$手表来电\r
+STR_PHONE_CALL$手机来电
\ No newline at end of file
<lanstr id="STR_DIAL_VIA_WATCH_SIM" value="Dial via Watch SIM"/>
<lanstr id="STR_DIAL_VIA_PHONE" value="Dial via Phone"/>
<lanstr id="STR_KUMI_TECHNOLOGY" value="KUMI Technology"/>
- <lanstr id="STR_CALLING" value="Calling"/>
+ <lanstr id="STR_CALLING" value="Calling..."/>
<lanstr id="STR_NOT_PAIRED" value="Not Paired"/>
<lanstr id="STR_PAIRED" value="Paired"/>
<lanstr id="STR_UNPAIR" value="Unpair"/>
<lanstr id="STR_SCHEDULE_TIME" value="Time:"/>
<lanstr id="STR_SCHEDULE_NOTES" value="Notes:"/>
<lanstr id="STR_SCHEDULE_DELETE_PROMPT" value="Delete this schedule"/>
+ <lanstr id="STR_HANG_UP_OR_ANSWER" value="HangUp/Answer"/>
+ <lanstr id="STR_WATCH_CALL" value="Watch Call"/>
+ <lanstr id="STR_PHONE_CALL" value="Phone Call"/>
</language>
<lanstr id="STR_DIAL_VIA_WATCH_SIM" value="通过手表SIM卡拨号"/>
<lanstr id="STR_DIAL_VIA_PHONE" value="通过手机拨号"/>
<lanstr id="STR_KUMI_TECHNOLOGY" value="库密科技"/>
- <lanstr id="STR_CALLING" value="拨号中"/>
+ <lanstr id="STR_CALLING" value="拨号中..."/>
<lanstr id="STR_NOT_PAIRED" value="未配对"/>
<lanstr id="STR_PAIRED" value="已配对"/>
<lanstr id="STR_UNPAIR" value="取消配对"/>
<lanstr id="STR_SCHEDULE_TIME" value="时间:"/>
<lanstr id="STR_SCHEDULE_NOTES" value="备注:"/>
<lanstr id="STR_SCHEDULE_DELETE_PROMPT" value="是否确认删除该日程"/>
+ <lanstr id="STR_HANG_UP_OR_ANSWER" value="挂断/接听"/>
+ <lanstr id="STR_WATCH_CALL" value="手表来电"/>
+ <lanstr id="STR_PHONE_CALL" value="手机来电"/>
</language>
STR_SCHEDULE_TIME = 534,\r
STR_SCHEDULE_NOTES = 535,\r
STR_SCHEDULE_DELETE_PROMPT = 536,\r
- STR_MAX_ID = 537,\r
+ STR_HANG_UP_OR_ANSWER = 537,\r
+ STR_WATCH_CALL = 538,\r
+ STR_PHONE_CALL = 539,\r
+ STR_MAX_ID = 540,\r
}; // UIResourceTextId\r
enum FontLanguageId : uint8_t {
- LANGUAGE_ID_ZH,\r
LANGUAGE_ID_EN,\r
+ LANGUAGE_ID_ZH,\r
LANGUAGE_ID_MAX\r
}; // UITextLanguageTextId\r
}\r