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
06ee1e11
Commit
06ee1e11
authored
Apr 03, 2014
by
Francois Cartegnie
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Qt: implement teletext buttons (fix #11132)
parent
39ba1dfa
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
35 additions
and
0 deletions
+35
-0
NEWS
NEWS
+1
-0
modules/gui/qt4/components/controller.cpp
modules/gui/qt4/components/controller.cpp
+34
-0
No files found.
NEWS
View file @
06ee1e11
...
...
@@ -107,6 +107,7 @@ Interfaces:
Misc:
* New module for TLS on OS X and iOS
* Windows installer will kill running instance before installing
* Teletext navigation buttons support in Qt4 gui
Removed modules:
* ios video output: use ios2
...
...
modules/gui/qt4/components/controller.cpp
View file @
06ee1e11
...
...
@@ -616,6 +616,40 @@ QFrame *AbstractController::telexFrame()
telexPage
->
setEnabled
(
false
);
telexLayout
->
addWidget
(
telexPage
);
/* Contextual & Index Buttons */
QSignalMapper
*
contextButtonMapper
=
new
QSignalMapper
(
this
);
QToolButton
*
contextButton
=
NULL
;
QPixmap
iconPixmap
(
telexOn
->
minimumHeight
(),
telexOn
->
minimumHeight
()
);
iconPixmap
.
fill
(
Qt
::
transparent
);
QPainter
iconPixmapPainter
(
&
iconPixmap
);
QRadialGradient
iconPixmapPainterGradient
(
iconPixmap
.
rect
().
center
(),
iconPixmap
.
rect
().
width
()
/
2
,
iconPixmap
.
rect
().
center
()
/
2
);
#define CREATE_CONTEXT_BUTTON(color, key) \
iconPixmapPainterGradient.setColorAt( 0, QColor( color ).lighter(150) );\
iconPixmapPainterGradient.setColorAt( 1.0, QColor( color ) );\
iconPixmapPainter.setBrush( iconPixmapPainterGradient );\
iconPixmapPainter.drawEllipse( iconPixmap.rect().adjusted( 0, 0, -1, -1 ) );\
contextButton = new QToolButton();\
setupButton( contextButton );\
contextButton->setIcon( iconPixmap );\
contextButton->setEnabled( false );\
contextButtonMapper->setMapping( contextButton, key << 16 );\
CONNECT( contextButton, clicked(), contextButtonMapper, map() );\
CONNECT( contextButtonMapper, mapped( int ),\
THEMIM->getIM(), telexSetPage( int ) );\
CONNECT( THEMIM->getIM(), teletextActivated( bool ), contextButton, setEnabled( bool ) );\
telexLayout->addWidget( contextButton )
CREATE_CONTEXT_BUTTON
(
"grey"
,
'i'
);
/* index */
CREATE_CONTEXT_BUTTON
(
"red"
,
'r'
);
CREATE_CONTEXT_BUTTON
(
"green"
,
'g'
);
CREATE_CONTEXT_BUTTON
(
"yellow"
,
'y'
);
CREATE_CONTEXT_BUTTON
(
"blue"
,
'b'
);
#undef CREATE_CONTEXT_BUTTON
/* Page change and set */
CONNECT
(
telexPage
,
valueChanged
(
int
),
THEMIM
->
getIM
(),
telexSetPage
(
int
)
);
...
...
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