Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
V
vlc
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
Commits
cf79a31c
Commit
cf79a31c
authored
Aug 10, 2010
by
Erwan Tulou
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
skins2: transform getNextSibling into getNextSiblingOrUncle
parent
98c1ff6e
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
18 additions
and
10 deletions
+18
-10
modules/gui/skins2/utils/var_tree.cpp
modules/gui/skins2/utils/var_tree.cpp
+17
-9
modules/gui/skins2/utils/var_tree.hpp
modules/gui/skins2/utils/var_tree.hpp
+1
-1
No files found.
modules/gui/skins2/utils/var_tree.cpp
View file @
cf79a31c
...
...
@@ -111,21 +111,29 @@ VarTree::ConstIterator VarTree::operator[]( int n ) const
return
it
;
}
VarTree
::
Iterator
VarTree
::
getNextSibling
(
VarTree
::
Iterator
current
)
VarTree
::
Iterator
VarTree
::
getNextSibling
OrUncle
(
)
{
VarTree
*
p_parent
=
current
->
parent
();
if
(
p_parent
&&
current
!=
p_parent
->
end
()
)
VarTree
*
p_parent
=
parent
();
if
(
p_parent
)
{
Iterator
it
=
current
->
parent
()
->
begin
();
while
(
it
!=
p_parent
->
end
()
&&
it
!=
current
)
it
++
;
Iterator
it
=
p_parent
->
begin
();
while
(
it
!=
p_parent
->
end
()
&&
&
(
*
it
)
!=
this
)
++
it
;
if
(
it
!=
p_parent
->
end
()
)
{
it
++
;
return
it
;
Iterator
current
=
it
;
++
it
;
if
(
it
!=
p_parent
->
end
()
)
return
it
;
else
return
current
->
next_uncle
();
}
else
{
msg_Err
(
getIntf
(),
"should never occur"
);
return
end
();
}
return
root
()
->
end
();
}
return
root
()
->
end
();
return
end
();
}
/* find iterator to next ancestor
...
...
modules/gui/skins2/utils/var_tree.hpp
View file @
cf79a31c
...
...
@@ -105,7 +105,7 @@ public:
VarTree
*
parent
()
{
return
m_pParent
;
}
/// Get next sibling
Iterator
getNextSibling
(
Iterator
);
Iterator
getNextSibling
OrUncle
(
);
Iterator
next_uncle
();
Iterator
prev_uncle
();
...
...
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