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
04806c15
Commit
04806c15
authored
Jul 18, 2012
by
Francois Cartegnie
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Qt: MLModel: Move Popup() creation out of the MLModel
parent
4e7f747f
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
0 additions
and
54 deletions
+0
-54
modules/gui/qt4/components/playlist/ml_model.cpp
modules/gui/qt4/components/playlist/ml_model.cpp
+0
-53
modules/gui/qt4/components/playlist/ml_model.hpp
modules/gui/qt4/components/playlist/ml_model.hpp
+0
-1
No files found.
modules/gui/qt4/components/playlist/ml_model.cpp
View file @
04806c15
...
...
@@ -593,59 +593,6 @@ bool MLModel::isCurrentItem( const QModelIndex &index, playLocation where ) cons
return
false
;
}
bool
MLModel
::
popup
(
const
QModelIndex
&
index
,
const
QPoint
&
point
,
const
QModelIndexList
&
selectionlist
)
{
QModelIndexList
callerAsList
;
callerAsList
<<
(
index
.
isValid
()
?
index
:
QModelIndex
()
);
#define ADD_MENU_ENTRY( icon, title, act, data ) \
action = menu.addAction( icon, title ); \
container.action = act; \
container.indexes = data; \
action->setData( QVariant::fromValue( container ) )
/* */
QMenu
menu
;
QAction
*
action
;
VLCModel
::
actionsContainerType
container
;
if
(
index
.
isValid
()
)
{
ADD_MENU_ENTRY
(
QIcon
(
":/menu/play"
),
qtr
(
I_POP_PLAY
),
container
.
ACTION_PLAY
,
callerAsList
);
ADD_MENU_ENTRY
(
QIcon
(
":/menu/stream"
),
qtr
(
I_POP_STREAM
),
container
.
ACTION_STREAM
,
selectionlist
);
ADD_MENU_ENTRY
(
QIcon
(),
qtr
(
I_POP_SAVE
),
container
.
ACTION_SAVE
,
selectionlist
);
ADD_MENU_ENTRY
(
QIcon
(
":/menu/info"
),
qtr
(
I_POP_INFO
),
container
.
ACTION_INFO
,
callerAsList
);
menu
.
addSeparator
();
}
QIcon
addIcon
(
":/buttons/playlist/playlist_add"
);
menu
.
addSeparator
();
//menu.addAction( addIcon, qtr(I_PL_ADDF), THEDP, SLOT( simpleMLAppendDialog()) );
//menu.addAction( addIcon, qtr(I_PL_ADDDIR), THEDP, SLOT( MLAppendDir() ) );
//menu.addAction( addIcon, qtr(I_OP_ADVOP), THEDP, SLOT( MLAppendDialog() ) );
if
(
index
.
isValid
()
)
{
ADD_MENU_ENTRY
(
QIcon
(
":/buttons/playlist/playlist_remove"
),
qtr
(
I_POP_DEL
),
container
.
ACTION_REMOVE
,
selectionlist
);
menu
.
addSeparator
();
}
if
(
!
menu
.
isEmpty
()
)
{
menu
.
exec
(
point
);
return
true
;
}
else
return
false
;
}
QStringList
MLModel
::
selectedURIs
(
QModelIndexList
*
current_selection
)
{
QStringList
list
;
...
...
modules/gui/qt4/components/playlist/ml_model.hpp
View file @
04806c15
...
...
@@ -93,7 +93,6 @@ public:
void
remove
(
QModelIndex
idx
);
void
clear
();
virtual
bool
popup
(
const
QModelIndex
&
index
,
const
QPoint
&
point
,
const
QModelIndexList
&
list
);
void
play
(
const
QModelIndex
&
idx
);
QStringList
selectedURIs
(
QModelIndexList
*
);
virtual
QString
getURI
(
const
QModelIndex
&
index
)
const
;
...
...
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