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
12ae705d
Commit
12ae705d
authored
Mar 19, 2013
by
Erwan Tulou
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
skins2: use the "mute" variable
parent
e2382750
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
12 additions
and
4 deletions
+12
-4
modules/gui/skins2/src/vlcproc.cpp
modules/gui/skins2/src/vlcproc.cpp
+11
-4
modules/gui/skins2/src/vlcproc.hpp
modules/gui/skins2/src/vlcproc.hpp
+1
-0
No files found.
modules/gui/skins2/src/vlcproc.cpp
View file @
12ae705d
...
...
@@ -155,6 +155,7 @@ VlcProc::VlcProc( intf_thread_t *pIntf ): SkinObject( pIntf ),
var_AddCallback( p_object, var, onGenericCallback, this );
ADD_CALLBACK
(
pIntf
->
p_sys
->
p_playlist
,
"volume"
)
ADD_CALLBACK
(
pIntf
->
p_sys
->
p_playlist
,
"mute"
)
ADD_CALLBACK
(
pIntf
->
p_libvlc
,
"intf-toggle-fscontrol"
)
ADD_CALLBACK
(
pIntf
->
p_sys
->
p_playlist
,
"random"
)
...
...
@@ -201,6 +202,8 @@ VlcProc::~VlcProc()
var_DelCallback
(
getIntf
()
->
p_sys
->
p_playlist
,
"volume"
,
onGenericCallback
,
this
);
var_DelCallback
(
getIntf
()
->
p_sys
->
p_playlist
,
"mute"
,
onGenericCallback
,
this
);
var_DelCallback
(
getIntf
()
->
p_libvlc
,
"intf-toggle-fscontrol"
,
onGenericCallback
,
this
);
...
...
@@ -365,6 +368,7 @@ int VlcProc::onGenericCallback( vlc_object_t *pObj, const char *pVariable,
}
ADD_CALLBACK_ENTRY
(
"volume"
,
on_volume_changed
,
true
)
ADD_CALLBACK_ENTRY
(
"mute"
,
on_mute_changed
,
true
)
ADD_CALLBACK_ENTRY
(
"bit-rate"
,
on_bit_rate_changed
,
false
)
ADD_CALLBACK_ENTRY
(
"sample-rate"
,
on_sample_rate_changed
,
false
)
...
...
@@ -669,8 +673,12 @@ void VlcProc::on_volume_changed( vlc_object_t* p_obj, vlc_value_t newVal )
playlist_t
*
pPlaylist
=
getIntf
()
->
p_sys
->
p_playlist
;
SET_VOLUME
(
m_cVarVolume
,
var_GetFloat
(
pPlaylist
,
"volume"
),
false
);
bool
b_is_muted
=
playlist_MuteGet
(
pPlaylist
)
>
0
;
SET_BOOL
(
m_cVarMute
,
b_is_muted
);
}
void
VlcProc
::
on_mute_changed
(
vlc_object_t
*
p_obj
,
vlc_value_t
newVal
)
{
(
void
)
p_obj
;
SET_BOOL
(
m_cVarMute
,
newVal
.
b_bool
);
}
void
VlcProc
::
on_audio_filter_changed
(
vlc_object_t
*
p_obj
,
vlc_value_t
newVal
)
...
...
@@ -773,8 +781,7 @@ void VlcProc::init_variables()
SET_BOOL
(
m_cVarRepeat
,
var_GetBool
(
pPlaylist
,
"repeat"
)
);
SET_VOLUME
(
m_cVarVolume
,
var_GetFloat
(
pPlaylist
,
"volume"
),
false
);
bool
b_is_muted
=
playlist_MuteGet
(
pPlaylist
)
>
0
;
SET_BOOL
(
m_cVarMute
,
b_is_muted
);
SET_BOOL
(
m_cVarMute
,
var_GetBool
(
pPlaylist
,
"mute"
)
);
update_equalizer
();
}
...
...
modules/gui/skins2/src/vlcproc.hpp
View file @
12ae705d
...
...
@@ -111,6 +111,7 @@ public:
void
on_repeat_changed
(
vlc_object_t
*
p_obj
,
vlc_value_t
newVal
);
void
on_volume_changed
(
vlc_object_t
*
p_obj
,
vlc_value_t
newVal
);
void
on_mute_changed
(
vlc_object_t
*
p_obj
,
vlc_value_t
newVal
);
void
on_audio_filter_changed
(
vlc_object_t
*
p_obj
,
vlc_value_t
newVal
);
void
on_intf_show_changed
(
vlc_object_t
*
p_obj
,
vlc_value_t
newVal
);
...
...
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