Skip to content
体验新版
项目
组织
正在加载...
登录
切换导航
打开侧边栏
OpenHarmony
Graphic Ui
提交
4cb6bedd
G
Graphic Ui
项目概览
OpenHarmony
/
Graphic Ui
大约 1 年 前同步成功
通知
13
Star
2
Fork
0
代码
文件
提交
分支
Tags
贡献者
分支图
Diff
Issue
0
列表
看板
标记
里程碑
合并请求
0
DevOps
流水线
流水线任务
计划
Wiki
0
Wiki
分析
仓库
DevOps
项目成员
Pages
G
Graphic Ui
项目概览
项目概览
详情
发布
仓库
仓库
文件
提交
分支
标签
贡献者
分支图
比较
Issue
0
Issue
0
列表
看板
标记
里程碑
合并请求
0
合并请求
0
Pages
DevOps
DevOps
流水线
流水线任务
计划
分析
分析
仓库分析
DevOps
Wiki
0
Wiki
成员
成员
收起侧边栏
关闭侧边栏
动态
分支图
创建新Issue
流水线任务
提交
Issue看板
体验新版 GitCode,发现更多精彩内容 >>
未验证
提交
4cb6bedd
编写于
2月 28, 2022
作者:
O
openharmony_ci
提交者:
Gitee
2月 28, 2022
浏览文件
操作
浏览文件
下载
差异文件
!610 修改拼写错误
Merge pull request !610 from 郝烁/master
上级
2fbff43b
92cb745b
变更
5
隐藏空白更改
内联
并排
Showing
5 changed file
with
7 addition
and
7 deletion
+7
-7
interfaces/kits/components/ui_button.h
interfaces/kits/components/ui_button.h
+2
-2
interfaces/kits/components/ui_label_button.h
interfaces/kits/components/ui_label_button.h
+1
-1
test/framework/src/test_case_list_adapter.cpp
test/framework/src/test_case_list_adapter.cpp
+1
-1
test/framework/src/ui_test_app.cpp
test/framework/src/ui_test_app.cpp
+1
-1
test/unittest/components/ui_label_button_unit_test.cpp
test/unittest/components/ui_label_button_unit_test.cpp
+2
-2
未找到文件。
interfaces/kits/components/ui_button.h
浏览文件 @
4cb6bedd
...
...
@@ -267,7 +267,7 @@ public:
}
/**
* @brief Obtains the height of this
image
.
* @brief Obtains the height of this
button
.
*
* @return Returns the image height.
* @since 1.0
...
...
@@ -281,7 +281,7 @@ public:
}
/**
* @brief Sets the width for this
image
.
* @brief Sets the width for this
button
.
*
* @param width Indicates the width to set.
* @since 1.0
...
...
interfaces/kits/components/ui_label_button.h
浏览文件 @
4cb6bedd
...
...
@@ -117,7 +117,7 @@ public:
* @since 1.0
* @version 1.0
*/
void
SetLab
le
Position
(
int16_t
x
,
int16_t
y
)
void
SetLab
el
Position
(
int16_t
x
,
int16_t
y
)
{
offset_
.
x
=
x
;
offset_
.
y
=
y
;
...
...
test/framework/src/test_case_list_adapter.cpp
浏览文件 @
4cb6bedd
...
...
@@ -175,7 +175,7 @@ UIView* TestCaseListAdapter::GetView(UIView* inView, int16_t index)
item
->
SetFont
(
DEFAULT_VECTOR_FONT_FILENAME
,
24
);
// 24: means font size
item
->
SetViewIndex
(
index
);
item
->
SetAlign
(
TEXT_ALIGNMENT_LEFT
);
item
->
SetLab
le
Position
(
24
,
0
);
// 24: lable x-coordinate
item
->
SetLab
el
Position
(
24
,
0
);
// 24: lable x-coordinate
item
->
SetImageSrc
(
TEST_RIGHT_ARROW
,
TEST_RIGHT_ARROW
);
// 2: half of button height; 18: half px of image height
item
->
SetImagePosition
(
item
->
GetWidth
()
-
TEXT_DISTANCE_TO_LEFT_SIDE
,
TESTCASE_BUTTON_HEIGHT
/
2
-
18
);
...
...
test/framework/src/ui_test_app.cpp
浏览文件 @
4cb6bedd
...
...
@@ -144,7 +144,7 @@ void UITestApp::InitBackBtn()
backBtn_
->
Resize
(
163
,
64
);
// 163: button width; 64: button height
backBtn_
->
SetText
(
"Back"
);
backBtn_
->
SetViewId
(
UI_TEST_BACK_BUTTON_ID
);
backBtn_
->
SetLab
le
Position
(
72
,
0
);
// 72: button label x-coordinate
backBtn_
->
SetLab
el
Position
(
72
,
0
);
// 72: button label x-coordinate
backBtn_
->
SetFont
(
DEFAULT_VECTOR_FONT_FILENAME
,
24
);
// 24: means font size
backBtn_
->
SetImageSrc
(
TEST_BACK_LEFT_ARROW
,
TEST_BACK_LEFT_ARROW
);
// 27: button Image x-coordinate; 18: half px of image height
...
...
test/unittest/components/ui_label_button_unit_test.cpp
浏览文件 @
4cb6bedd
...
...
@@ -83,7 +83,7 @@ HWTEST_F(UILabelButtonTest, UILabelButtonSetText_001, TestSize.Level1)
}
/**
* @tc.name: UILabelButtonSetLablePosition_001
* @tc.desc: Verify SetLab
le
Position function.
* @tc.desc: Verify SetLab
el
Position function.
* @tc.type: FUNC
* @tc.require: AR000EEMQ5
*/
...
...
@@ -96,7 +96,7 @@ HWTEST_F(UILabelButtonTest, UILabelButtonSetLablePosition_001, TestSize.Level1)
const
int16_t
posX
=
10
;
const
int16_t
posY
=
20
;
labelBtn_
->
SetLab
le
Position
(
posX
,
posY
);
labelBtn_
->
SetLab
el
Position
(
posX
,
posY
);
EXPECT_EQ
(
labelBtn_
->
GetLabelPosition
().
x
,
posX
);
EXPECT_EQ
(
labelBtn_
->
GetLabelPosition
().
y
,
posY
);
}
...
...
编辑
预览
Markdown
is supported
0%
请重试
或
添加新附件
.
添加附件
取消
You are about to add
0
people
to the discussion. Proceed with caution.
先完成此消息的编辑!
取消
想要评论请
注册
或
登录