Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
V
vlc-gpu
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Redmine
Redmine
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Operations
Operations
Metrics
Environments
Analytics
Analytics
CI / CD
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
videolan
vlc-gpu
Commits
e866693d
Commit
e866693d
authored
Aug 10, 2010
by
Erwan Tulou
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
skins2: playlist make sure deletion works for both nodes and leaves
parent
cf79a31c
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
6 additions
and
6 deletions
+6
-6
modules/gui/skins2/vars/playtree.cpp
modules/gui/skins2/vars/playtree.cpp
+6
-6
No files found.
modules/gui/skins2/vars/playtree.cpp
View file @
e866693d
...
@@ -51,12 +51,11 @@ void Playtree::delSelected()
...
@@ -51,12 +51,11 @@ void Playtree::delSelected()
{
{
Iterator
it
=
begin
();
Iterator
it
=
begin
();
playlist_Lock
(
getIntf
()
->
p_sys
->
p_playlist
);
playlist_Lock
(
getIntf
()
->
p_sys
->
p_playlist
);
for
(
it
=
begin
();
it
!=
end
();
it
=
getNext
Visible
Item
(
it
)
)
for
(
it
=
begin
();
it
!=
end
();
it
=
getNextItem
(
it
)
)
{
{
if
(
(
*
it
).
m_selected
&&
!
(
*
it
).
isReadonly
()
)
if
(
it
->
m_selected
&&
!
it
->
isReadonly
()
)
{
{
(
*
it
).
m_deleted
=
true
;
it
->
cascadeDelete
();
(
*
it
).
m_expanded
=
false
;
}
}
}
}
/// \todo Do this better (handle item-deleted)
/// \todo Do this better (handle item-deleted)
...
@@ -66,7 +65,7 @@ void Playtree::delSelected()
...
@@ -66,7 +65,7 @@ void Playtree::delSelected()
it
=
begin
();
it
=
begin
();
while
(
it
!=
end
()
)
while
(
it
!=
end
()
)
{
{
if
(
(
*
it
).
m_deleted
)
if
(
it
->
m_deleted
)
{
{
VarTree
::
Iterator
it2
;
VarTree
::
Iterator
it2
;
playlist_item_t
*
p_item
=
(
playlist_item_t
*
)(
it
->
m_pData
);
playlist_item_t
*
p_item
=
(
playlist_item_t
*
)(
it
->
m_pData
);
...
@@ -74,13 +73,14 @@ void Playtree::delSelected()
...
@@ -74,13 +73,14 @@ void Playtree::delSelected()
{
{
playlist_DeleteFromInput
(
getIntf
()
->
p_sys
->
p_playlist
,
playlist_DeleteFromInput
(
getIntf
()
->
p_sys
->
p_playlist
,
p_item
->
p_input
,
pl_Locked
);
p_item
->
p_input
,
pl_Locked
);
it2
=
getNextItem
(
it
)
;
}
}
else
else
{
{
playlist_NodeDelete
(
getIntf
()
->
p_sys
->
p_playlist
,
p_item
,
playlist_NodeDelete
(
getIntf
()
->
p_sys
->
p_playlist
,
p_item
,
true
,
false
);
true
,
false
);
it2
=
it
->
getNextSiblingOrUncle
();
}
}
it2
=
getNextItem
(
it
)
;
it
->
parent
()
->
removeChild
(
it
);
it
->
parent
()
->
removeChild
(
it
);
it
=
it2
;
it
=
it2
;
}
}
...
...
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