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
e0a92345
Commit
e0a92345
authored
Jan 28, 2010
by
Jakob Leben
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Qt iconView: browse into node when it spawns subitems
parent
03fef5e5
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
34 additions
and
3 deletions
+34
-3
modules/gui/qt4/components/playlist/standardpanel.cpp
modules/gui/qt4/components/playlist/standardpanel.cpp
+31
-3
modules/gui/qt4/components/playlist/standardpanel.hpp
modules/gui/qt4/components/playlist/standardpanel.hpp
+3
-0
No files found.
modules/gui/qt4/components/playlist/standardpanel.cpp
View file @
e0a92345
...
...
@@ -113,6 +113,10 @@ StandardPLPanel::StandardPLPanel( PlaylistWidget *_parent,
}
getSettings
()
->
endGroup
();
last_activated_id
=
-
1
;
CONNECT
(
THEMIM
,
inputChanged
(
input_thread_t
*
),
this
,
handleInputChange
(
input_thread_t
*
)
);
}
StandardPLPanel
::~
StandardPLPanel
()
...
...
@@ -363,13 +367,37 @@ void StandardPLPanel::wheelEvent( QWheelEvent *e )
void
StandardPLPanel
::
activate
(
const
QModelIndex
&
index
)
{
if
(
model
->
hasChildren
(
index
)
&&
currentView
==
iconView
)
last_activated_id
=
model
->
itemId
(
index
);
if
(
model
->
hasChildren
(
index
)
)
{
iconView
->
setRootIndex
(
index
);
title
->
setText
(
index
.
data
().
toString
()
);
if
(
currentView
==
iconView
)
{
iconView
->
setRootIndex
(
index
);
title
->
setText
(
index
.
data
().
toString
()
);
}
}
else
{
model
->
activateItem
(
index
);
}
}
void
StandardPLPanel
::
handleInputChange
(
input_thread_t
*
p_input_thread
)
{
input_item_t
*
p_input_item
=
input_GetItem
(
p_input_thread
);
if
(
!
p_input_item
)
return
;
playlist_Lock
(
THEPL
);
playlist_item_t
*
p_item
=
playlist_ItemGetByInput
(
THEPL
,
p_input_item
);
if
(
p_item
&&
p_item
->
p_parent
&&
p_item
->
p_parent
->
i_id
==
last_activated_id
)
{
QModelIndex
index
=
model
->
index
(
p_item
->
p_parent
->
i_id
,
0
);
iconView
->
setRootIndex
(
index
);
title
->
setText
(
index
.
data
().
toString
()
);
last_activated_id
=
p_item
->
i_id
;
}
playlist_Unlock
(
THEPL
);
}
modules/gui/qt4/components/playlist/standardpanel.hpp
View file @
e0a92345
...
...
@@ -76,6 +76,8 @@ private:
int
currentRootId
;
QSignalMapper
*
selectColumnsSigMapper
;
int
last_activated_id
;
enum
{
TREE_VIEW
=
0
,
ICON_VIEW
,
...
...
@@ -99,6 +101,7 @@ private slots:
void
toggleColumnShown
(
int
);
void
toggleView
();
void
activate
(
const
QModelIndex
&
);
void
handleInputChange
(
input_thread_t
*
);
};
#endif
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