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
8bc5770c
Commit
8bc5770c
authored
Apr 14, 2018
by
Gabor Kiss-Vamosi
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
lv_del_obj: fix if delted while pressed
parent
913517f1
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
16 additions
and
11 deletions
+16
-11
lv_obj.c
lv_core/lv_obj.c
+12
-10
lv_ta.c
lv_objx/lv_ta.c
+4
-1
No files found.
lv_core/lv_obj.c
View file @
8bc5770c
...
...
@@ -292,17 +292,9 @@ lv_res_t lv_obj_del(lv_obj_t * obj)
/* Reset all input devices if
* the currently pressed object is deleted*/
lv_indev_t
*
indev
=
lv_indev_next
(
NULL
);
lv_obj_t
*
dpar
;
while
(
indev
)
{
dpar
=
obj
;
while
(
dpar
!=
NULL
)
{
if
(
indev
->
proc
.
act_obj
==
dpar
||
indev
->
proc
.
last_obj
==
dpar
)
{
lv_indev_reset
(
indev
);
break
;
}
else
{
dpar
=
lv_obj_get_parent
(
dpar
);
}
if
(
indev
->
proc
.
act_obj
==
obj
||
indev
->
proc
.
last_obj
==
obj
)
{
lv_indev_reset
(
indev
);
}
indev
=
lv_indev_next
(
indev
);
}
...
...
@@ -1591,6 +1583,16 @@ static void delete_children(lv_obj_t * obj)
if
(
obj
->
group_p
!=
NULL
)
lv_group_remove_obj
(
obj
);
#endif
/* Reset the input devices if
* the currently pressed object is deleted*/
lv_indev_t
*
indev
=
lv_indev_next
(
NULL
);
while
(
indev
)
{
if
(
indev
->
proc
.
act_obj
==
obj
||
indev
->
proc
.
last_obj
==
obj
)
{
lv_indev_reset
(
indev
);
}
indev
=
lv_indev_next
(
indev
);
}
/*Remove the object from parent's children list*/
lv_obj_t
*
par
=
lv_obj_get_parent
(
obj
);
lv_ll_rem
(
&
(
par
->
child_ll
),
obj
);
...
...
lv_objx/lv_ta.c
View file @
8bc5770c
...
...
@@ -1044,7 +1044,10 @@ static void pwd_char_hider(lv_obj_t * ta)
int16_t
len
=
lv_txt_get_length
(
txt
);
bool
refr
=
false
;
uint16_t
i
;
for
(
i
=
0
;
i
<
len
;
i
++
)
txt
[
i
]
=
'*'
;
for
(
i
=
0
;
i
<
len
;
i
++
)
{
txt
[
i
]
=
'*'
;
refr
=
true
;
}
txt
[
i
]
=
'\0'
;
...
...
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