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
9f666f7c
Commit
9f666f7c
authored
Aug 07, 2007
by
Jean-Baptiste Kempf
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Qt4 - Playlist: scrollTo current-item and view issues...
Patch by Ilkka Ollakka
parent
f0cf58a8
Changes
2
Show whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
14 additions
and
4 deletions
+14
-4
modules/gui/qt4/components/playlist/standardpanel.cpp
modules/gui/qt4/components/playlist/standardpanel.cpp
+1
-1
modules/gui/qt4/playlist_model.cpp
modules/gui/qt4/playlist_model.cpp
+13
-3
No files found.
modules/gui/qt4/components/playlist/standardpanel.cpp
View file @
9f666f7c
...
...
@@ -144,9 +144,9 @@ void StandardPLPanel::toggleRandom()
void
StandardPLPanel
::
handleExpansion
(
const
QModelIndex
&
index
)
{
QModelIndex
parent
;
view
->
scrollTo
(
index
,
QAbstractItemView
::
EnsureVisible
);
if
(
model
->
isCurrent
(
index
)
)
{
view
->
scrollTo
(
index
,
QAbstractItemView
::
EnsureVisible
);
parent
=
index
;
while
(
parent
.
isValid
()
)
{
...
...
modules/gui/qt4/playlist_model.cpp
View file @
9f666f7c
...
...
@@ -79,6 +79,10 @@ void PLItem::init( int _i_id, int _i_input_id, PLItem *parent, PLModel *m)
{
i_showflags
=
config_GetInt
(
model
->
p_intf
,
"qt-pl-showflags"
);
updateview
();
}
else
{
i_showflags
=
parentItem
->
i_showflags
;
//Add empty string and update() handles data appending
strings
.
append
(
qtr
(
""
)
);
}
}
...
...
@@ -86,6 +90,12 @@ void PLItem::updateview( void )
{
strings
.
clear
();
if
(
model
->
i_depth
==
1
)
//left window for playlist etc.
{
strings
.
append
(
qtr
(
""
)
);
return
;
}
for
(
int
i_index
=
1
;
i_index
<=
VLC_META_ENGINE_MB_TRM_ID
;
i_index
=
i_index
*
2
)
{
if
(
i_showflags
&
i_index
)
...
...
@@ -170,7 +180,6 @@ void PLItem::update( playlist_item_t *p_item, bool iscurrent )
{
char
psz_duration
[
MSTRTIME_MAX_SIZE
];
assert
(
p_item
->
p_input
->
i_id
==
i_input_id
);
strings
.
clear
();
type
=
p_item
->
p_input
->
i_type
;
current
=
iscurrent
;
...
...
@@ -182,6 +191,8 @@ void PLItem::update( playlist_item_t *p_item, bool iscurrent )
else
if
(
current
)
model
->
removeArt
();
strings
.
clear
();
if
(
model
->
i_depth
==
1
)
//left window for playlist etc.
{
strings
.
append
(
p_item
->
p_input
->
psz_name
);
...
...
@@ -209,7 +220,7 @@ void PLItem::update( playlist_item_t *p_item, bool iscurrent )
{
ADD_META
(
p_item
->
p_input
->
p_meta
->
psz_title
);
}
else
{
ADD_META
(
p_item
->
p_input
->
psz_name
);
strings
.
append
(
qfu
(
p_item
->
p_input
->
psz_name
)
);
}
break
;
case
VLC_META_ENGINE_DESCRIPTION
:
...
...
@@ -543,7 +554,6 @@ QModelIndex PLModel::parent(const QModelIndex &index) const
int
PLModel
::
columnCount
(
const
QModelIndex
&
i
)
const
{
if
(
i_depth
==
1
)
return
1
;
return
rootItem
->
strings
.
count
();
}
...
...
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