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
3b5bfc6e
Commit
3b5bfc6e
authored
Feb 20, 2012
by
Francois Cartegnie
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Qt: plugins: activate buttons contextually
parent
02affbfe
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
14 additions
and
11 deletions
+14
-11
modules/gui/qt4/dialogs/plugins.cpp
modules/gui/qt4/dialogs/plugins.cpp
+13
-11
modules/gui/qt4/dialogs/plugins.hpp
modules/gui/qt4/dialogs/plugins.hpp
+1
-0
No files found.
modules/gui/qt4/dialogs/plugins.cpp
View file @
3b5bfc6e
...
...
@@ -227,8 +227,7 @@ ExtensionTab::ExtensionTab( intf_thread_t *p_intf )
butMoreInfo
=
new
QPushButton
(
QIcon
(
":/menu/info"
),
qtr
(
"More information..."
),
this
);
CONNECT
(
butMoreInfo
,
clicked
(),
this
,
moreInformation
()
);
CONNECT
(
butMoreInfo
,
clicked
(),
this
,
moreInformation
()
);
hbox
->
addWidget
(
butMoreInfo
);
// Reload button
...
...
@@ -236,18 +235,28 @@ ExtensionTab::ExtensionTab( intf_thread_t *p_intf )
QPushButton
*
reload
=
new
QPushButton
(
QIcon
(
":/update"
),
qtr
(
"Reload extensions"
),
this
);
CONNECT
(
reload
,
clicked
(),
EM
,
reloadExtensions
()
);
CONNECT
(
reload
,
clicked
(),
EM
,
reloadExtensions
()
);
CONNECT
(
reload
,
clicked
(),
this
,
updateButtons
()
);
CONNECT
(
extList
->
selectionModel
(),
selectionChanged
(
const
QItemSelection
&
,
const
QItemSelection
&
),
this
,
updateButtons
()
);
hbox
->
addWidget
(
reload
);
// Add buttons hbox
layout
->
addItem
(
hbox
);
updateButtons
();
}
ExtensionTab
::~
ExtensionTab
()
{
}
void
ExtensionTab
::
updateButtons
()
{
butMoreInfo
->
setEnabled
(
extList
->
selectionModel
()
->
hasSelection
()
);
}
// Do not close on ESC or ENTER
void
ExtensionTab
::
keyPressEvent
(
QKeyEvent
*
keyEvent
)
{
...
...
@@ -261,13 +270,6 @@ void ExtensionTab::keyPressEvent( QKeyEvent *keyEvent )
// Show more information
void
ExtensionTab
::
moreInformation
()
{
if
(
!
extList
->
selectionModel
()
||
extList
->
selectionModel
()
->
selectedIndexes
().
isEmpty
()
)
{
return
;
}
QModelIndex
index
=
extList
->
selectionModel
()
->
selectedIndexes
().
first
();
ExtensionCopy
*
ext
=
(
ExtensionCopy
*
)
index
.
internalPointer
();
if
(
!
ext
)
...
...
modules/gui/qt4/dialogs/plugins.hpp
View file @
3b5bfc6e
...
...
@@ -100,6 +100,7 @@ private:
private
slots
:
void
moreInformation
();
void
updateButtons
();
private:
QListView
*
extList
;
...
...
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