BigW Consortium Gitlab
Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
L
lvgl
Project
Overview
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
Registry
Registry
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Commits
Issue Boards
Open sidebar
Forest Godfrey
lvgl
Commits
4138785a
Commit
4138785a
authored
Dec 08, 2017
by
Gabor Kiss-Vamosi
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
lv_tanview: minor renames
parent
91b788dc
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
9 additions
and
9 deletions
+9
-9
lv_tabview.c
lv_objx/lv_tabview.c
+7
-7
lv_tabview.h
lv_objx/lv_tabview.h
+2
-2
No files found.
lv_objx/lv_tabview.c
View file @
4138785a
...
...
@@ -218,7 +218,7 @@ lv_obj_t * lv_tabview_add_tab(lv_obj_t * tabview, const char * name)
/*Set the first btn as active*/
if
(
ext
->
tab_cnt
==
1
)
{
ext
->
tab_cur
=
0
;
lv_tabview_set_
current_tab
(
tabview
,
0
,
false
);
lv_tabview_set_
tab_act
(
tabview
,
0
,
false
);
tabview_realign
(
tabview
);
/*To set the proper btns height*/
}
...
...
@@ -235,7 +235,7 @@ lv_obj_t * lv_tabview_add_tab(lv_obj_t * tabview, const char * name)
* @param id index of a tab to load
* @param anim_en true: set with sliding animation; false: set immediately
*/
void
lv_tabview_set_
current_tab
(
lv_obj_t
*
tabview
,
uint16_t
id
,
bool
anim_en
)
void
lv_tabview_set_
tab_act
(
lv_obj_t
*
tabview
,
uint16_t
id
,
bool
anim_en
)
{
lv_tabview_ext_t
*
ext
=
lv_obj_get_ext_attr
(
tabview
);
lv_style_t
*
style
=
lv_obj_get_style
(
ext
->
content
);
...
...
@@ -377,11 +377,11 @@ void lv_tabview_set_style(lv_obj_t *tabview, lv_tabview_style_t type, lv_style_t
*====================*/
/**
* Get the index of the currently active
btn
* Get the index of the currently active
tab
* @param tabview pointer to Tab view object
* @return the active btn index
*/
uint16_t
lv_tabview_get_
current_tab
(
lv_obj_t
*
tabview
)
uint16_t
lv_tabview_get_
tab_act
(
lv_obj_t
*
tabview
)
{
lv_tabview_ext_t
*
ext
=
lv_obj_get_ext_attr
(
tabview
);
return
ext
->
tab_cur
;
...
...
@@ -680,7 +680,7 @@ static void tabpage_press_lost_hadler(lv_obj_t * tabview, lv_obj_t * tabpage)
if
(
tab_cur
<
ext
->
tab_cnt
-
1
)
tab_cur
++
;
}
lv_tabview_set_
current_tab
(
tabview
,
tab_cur
,
true
);
lv_tabview_set_
tab_act
(
tabview
,
tab_cur
,
true
);
}
/**
...
...
@@ -701,7 +701,7 @@ static lv_res_t tab_btnm_action(lv_obj_t * tab_btnm, const char * tab_name)
i
++
;
}
lv_tabview_set_
current_tab
(
tab
,
i
,
true
);
lv_tabview_set_
tab_act
(
tab
,
i
,
true
);
return
LV_RES_OK
;
}
...
...
@@ -746,6 +746,6 @@ static void tabview_realign(lv_obj_t * tabview)
lv_obj_align
(
ext
->
indic
,
ext
->
btns
,
LV_ALIGN_IN_BOTTOM_LEFT
,
0
,
0
);
lv_tabview_set_
current_tab
(
tabview
,
ext
->
tab_cur
,
false
);
lv_tabview_set_
tab_act
(
tabview
,
ext
->
tab_cur
,
false
);
}
#endif
lv_objx/lv_tabview.h
View file @
4138785a
...
...
@@ -106,7 +106,7 @@ lv_obj_t * lv_tabview_add_tab(lv_obj_t * tabview, const char * name);
* @param id index of a tab to load
* @param anim_en true: set with sliding animation; false: set immediately
*/
void
lv_tabview_set_
current_tab
(
lv_obj_t
*
tabview
,
uint16_t
id
,
bool
anim_en
);
void
lv_tabview_set_
tab_act
(
lv_obj_t
*
tabview
,
uint16_t
id
,
bool
anim_en
);
/**
* Set an action to call when a tab is loaded (Good to create content only if required)
...
...
@@ -147,7 +147,7 @@ void lv_tabview_set_style(lv_obj_t *tabview, lv_tabview_style_t type, lv_style_t
* @param tabview pointer to Tab view object
* @return the active tab index
*/
uint16_t
lv_tabview_get_
current_tab
(
lv_obj_t
*
tabview
);
uint16_t
lv_tabview_get_
tab_act
(
lv_obj_t
*
tabview
);
/**
* Get the number of tabs
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment