Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
V
vlc-1.1
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-1.1
Commits
9cbb99e3
Commit
9cbb99e3
authored
Sep 08, 2007
by
Jean-Baptiste Kempf
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Qt4 - MainInterface and InputManager: setRate actually shows something in the interface.
parent
4c48570a
Changes
4
Hide whitespace changes
Inline
Side-by-side
Showing
4 changed files
with
22 additions
and
5 deletions
+22
-5
modules/gui/qt4/input_manager.cpp
modules/gui/qt4/input_manager.cpp
+4
-1
modules/gui/qt4/input_manager.hpp
modules/gui/qt4/input_manager.hpp
+1
-0
modules/gui/qt4/main_interface.cpp
modules/gui/qt4/main_interface.cpp
+14
-3
modules/gui/qt4/main_interface.hpp
modules/gui/qt4/main_interface.hpp
+3
-1
No files found.
modules/gui/qt4/input_manager.cpp
View file @
9cbb99e3
...
...
@@ -100,8 +100,11 @@ void InputManager::update()
i_time
=
var_GetTime
(
p_input
,
"time"
)
/
1000000
;
f_pos
=
var_GetFloat
(
p_input
,
"position"
);
emit
positionUpdated
(
f_pos
,
i_time
,
i_length
);
/* Update rate */
emit
rateChanged
(
var_GetInteger
(
p_input
,
"rate"
)
);
/* Update
disc
status */
/* Update
navigation
status */
vlc_value_t
val
;
val
.
i_int
=
0
;
var_Change
(
p_input
,
"title"
,
VLC_VAR_CHOICESCOUNT
,
&
val
,
NULL
);
if
(
val
.
i_int
>
0
)
...
...
modules/gui/qt4/input_manager.hpp
View file @
9cbb99e3
...
...
@@ -60,6 +60,7 @@ public slots:
signals:
/// Send new position, new time and new length
void
positionUpdated
(
float
,
int
,
int
);
void
rateChanged
(
int
);
void
nameChanged
(
QString
);
/// Used to signal whether we should show navigation buttons
void
navigationChanged
(
int
);
...
...
modules/gui/qt4/main_interface.cpp
View file @
9cbb99e3
...
...
@@ -183,8 +183,10 @@ MainInterface::MainInterface( intf_thread_t *_p_intf ) : QVLCMW( _p_intf )
/* Connect the input manager to the GUI elements it manages */
/* It is also connected to the control->slider, see the ControlsWidget */
CONNECT
(
THEMIM
->
getIM
(),
positionUpdated
(
float
,
int
,
int
),
this
,
setDisplay
(
float
,
int
,
int
)
);
this
,
setDisplayPosition
(
float
,
int
,
int
)
);
CONNECT
(
THEMIM
->
getIM
(),
rateChanged
(
int
),
this
,
setRate
(
int
)
);
/** Connects on nameChanged() */
/* Naming in the controller statusbar */
CONNECT
(
THEMIM
->
getIM
(),
nameChanged
(
QString
),
this
,
...
...
@@ -655,7 +657,7 @@ bool MainInterface::isAdvancedVisible()
/************************************************************************
* Other stuff
************************************************************************/
void
MainInterface
::
setDisplay
(
float
pos
,
int
time
,
int
length
)
void
MainInterface
::
setDisplay
Position
(
float
pos
,
int
time
,
int
length
)
{
char
psz_length
[
MSTRTIME_MAX_SIZE
],
psz_time
[
MSTRTIME_MAX_SIZE
];
secstotimestr
(
psz_length
,
length
);
...
...
@@ -686,6 +688,15 @@ void MainInterface::setStatus( int status )
updateSystrayMenu
(
status
);
}
void
MainInterface
::
setRate
(
int
rate
)
{
msg_Dbg
(
p_intf
,
"raaahhh %i"
,
rate
);
QString
str
;
str
.
setNum
(
(
1000
/
(
double
)
rate
),
'f'
,
2
);
str
.
append
(
"x"
);
speedLabel
->
setText
(
str
);
}
void
MainInterface
::
updateOnTimer
()
{
/* \todo Make this event-driven */
...
...
modules/gui/qt4/main_interface.hpp
View file @
9cbb99e3
...
...
@@ -128,10 +128,12 @@ public slots:
void
toggleAdvanced
();
private
slots
:
void
updateOnTimer
();
void
setStatus
(
int
);
void
setRate
(
int
);
void
setName
(
QString
);
void
setVLCWindowsTitle
(
QString
title
=
""
);
void
setDisplay
(
float
,
int
,
int
);
void
setDisplay
Position
(
float
,
int
,
int
);
void
toggleTimeDisplay
();
void
setElapsedTime
();
void
setRemainTime
();
...
...
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