Skip to content
GitLab
Projects
Groups
Snippets
/
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Sign in
Toggle navigation
Menu
Open sidebar
Gautam Chitnis
web-ui-redesign
Commits
ca797b13
Commit
ca797b13
authored
Jun 01, 2008
by
Rémi Denis-Courmont
Browse files
Use pl_Yield instead of vlc_object_find
parent
ddfce772
Changes
1
Hide whitespace changes
Inline
Side-by-side
modules/gui/qt4/main_interface.cpp
View file @
ca797b13
...
...
@@ -223,14 +223,10 @@ MainInterface::MainInterface( intf_thread_t *_p_intf ) : QVLCMW( _p_intf )
p_intf
->
b_interaction
=
true
;
/* Register callback for the intf-popupmenu variable */
playlist_t
*
p_playlist
=
(
playlist_t
*
)
vlc_object_find
(
p_intf
,
VLC_OBJECT_PLAYLIST
,
FIND_ANYWHERE
);
if
(
p_playlist
!=
NULL
)
{
var_AddCallback
(
p_playlist
,
"intf-popupmenu"
,
PopupMenuCB
,
p_intf
);
var_AddCallback
(
p_playlist
,
"intf-show"
,
IntfShowCB
,
p_intf
);
vlc_object_release
(
p_playlist
);
}
playlist_t
*
p_playlist
=
pl_Yield
(
p_intf
);
var_AddCallback
(
p_playlist
,
"intf-popupmenu"
,
PopupMenuCB
,
p_intf
);
var_AddCallback
(
p_playlist
,
"intf-show"
,
IntfShowCB
,
p_intf
);
pl_Release
(
p_intf
);
/* VideoWidget connect mess to avoid different threads speaking to each other */
CONNECT
(
this
,
askReleaseVideo
(
void
*
),
...
...
@@ -289,14 +285,10 @@ MainInterface::~MainInterface()
delete
settings
;
/* Unregister callback for the intf-popupmenu variable */
playlist_t
*
p_playlist
=
(
playlist_t
*
)
vlc_object_find
(
p_intf
,
VLC_OBJECT_PLAYLIST
,
FIND_ANYWHERE
);
if
(
p_playlist
!=
NULL
)
{
var_DelCallback
(
p_playlist
,
"intf-popupmenu"
,
PopupMenuCB
,
p_intf
);
var_DelCallback
(
p_playlist
,
"intf-show"
,
IntfShowCB
,
p_intf
);
vlc_object_release
(
p_playlist
);
}
playlist_t
*
p_playlist
=
pl_Yield
(
p_intf
);
var_DelCallback
(
p_playlist
,
"intf-popupmenu"
,
PopupMenuCB
,
p_intf
);
var_DelCallback
(
p_playlist
,
"intf-show"
,
IntfShowCB
,
p_intf
);
pl_Release
(
p_intf
);
p_intf
->
b_interaction
=
false
;
var_DelCallback
(
p_intf
,
"interaction"
,
InteractCallback
,
this
);
...
...
Write
Preview
Supports
Markdown
0%
Try again
or
attach a new 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