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
138da191
Commit
138da191
authored
Jun 20, 2008
by
Rémi Denis-Courmont
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Remove the broken window embedding core code
parent
a735127f
Changes
5
Hide whitespace changes
Inline
Side-by-side
Showing
5 changed files
with
3 additions
and
140 deletions
+3
-140
include/vlc_interface.h
include/vlc_interface.h
+0
-7
modules/gui/qt4/components/interface_widgets.cpp
modules/gui/qt4/components/interface_widgets.cpp
+0
-4
modules/gui/qt4/main_interface.cpp
modules/gui/qt4/main_interface.cpp
+1
-31
src/interface/interface.c
src/interface/interface.c
+0
-3
src/video_output/vout_intf.c
src/video_output/vout_intf.c
+2
-95
No files found.
include/vlc_interface.h
View file @
138da191
...
...
@@ -68,13 +68,6 @@ struct intf_thread_t
/** Interaction stuff */
bool
b_interaction
;
/** Video window callbacks */
void
*
(
*
pf_request_window
)
(
intf_thread_t
*
,
vout_thread_t
*
,
int
*
,
int
*
,
unsigned
int
*
,
unsigned
int
*
);
void
(
*
pf_release_window
)
(
intf_thread_t
*
,
void
*
);
int
(
*
pf_control_window
)
(
intf_thread_t
*
,
void
*
,
int
,
va_list
);
/* XXX: new message passing stuff will go here */
vlc_mutex_t
change_lock
;
bool
b_menu_change
;
...
...
modules/gui/qt4/components/interface_widgets.cpp
View file @
138da191
...
...
@@ -52,10 +52,6 @@
* Video Widget. A simple frame on which video is drawn
* This class handles resize issues
**********************************************************************/
static
void
*
DoRequest
(
intf_thread_t
*
,
vout_thread_t
*
,
int
*
,
int
*
,
unsigned
int
*
,
unsigned
int
*
);
static
void
DoRelease
(
intf_thread_t
*
,
void
*
);
static
int
DoControl
(
intf_thread_t
*
,
void
*
,
int
,
va_list
);
VideoWidget
::
VideoWidget
(
intf_thread_t
*
_p_i
)
:
QFrame
(
NULL
),
p_intf
(
_p_i
)
{
...
...
modules/gui/qt4/main_interface.cpp
View file @
138da191
...
...
@@ -76,29 +76,6 @@ static int IntfShowCB( vlc_object_t *p_this, const char *psz_variable,
vlc_value_t
old_val
,
vlc_value_t
new_val
,
void
*
param
);
static
int
InteractCallback
(
vlc_object_t
*
,
const
char
*
,
vlc_value_t
,
vlc_value_t
,
void
*
);
/* Video handling */
static
void
*
DoRequest
(
intf_thread_t
*
p_intf
,
vout_thread_t
*
p_vout
,
int
*
pi1
,
int
*
pi2
,
unsigned
int
*
pi3
,
unsigned
int
*
pi4
)
{
return
p_intf
->
p_sys
->
p_mi
->
requestVideo
(
p_vout
,
pi1
,
pi2
,
pi3
,
pi4
);
}
static
void
*
DoNotEmbeddedRequest
(
intf_thread_t
*
p_intf
,
vout_thread_t
*
p_vout
,
int
*
pi1
,
int
*
pi2
,
unsigned
int
*
pi3
,
unsigned
int
*
pi4
)
{
p_intf
->
p_sys
->
p_mi
->
requestNotEmbeddedVideo
(
p_vout
);
return
NULL
;
}
static
void
DoRelease
(
intf_thread_t
*
p_intf
,
void
*
p_win
)
{
return
p_intf
->
p_sys
->
p_mi
->
releaseVideo
(
p_win
);
}
static
int
DoControl
(
intf_thread_t
*
p_intf
,
void
*
p_win
,
int
i_q
,
va_list
a
)
{
return
p_intf
->
p_sys
->
p_mi
->
controlVideo
(
p_win
,
i_q
,
a
);
}
MainInterface
::
MainInterface
(
intf_thread_t
*
_p_intf
)
:
QVLCMW
(
_p_intf
)
{
...
...
@@ -311,9 +288,6 @@ MainInterface::~MainInterface()
p_intf
->
b_interaction
=
false
;
var_DelCallback
(
p_intf
,
"interaction"
,
InteractCallback
,
this
);
p_intf
->
pf_request_window
=
NULL
;
p_intf
->
pf_release_window
=
NULL
;
p_intf
->
pf_control_window
=
NULL
;
p_intf
->
p_sys
->
p_mi
=
NULL
;
}
...
...
@@ -463,13 +437,9 @@ void MainInterface::handleMainUi( QSettings *settings )
videoWidget
=
new
VideoWidget
(
p_intf
);
mainLayout
->
insertWidget
(
0
,
videoWidget
);
p_intf
->
pf_request_window
=
::
DoRequest
;
p_intf
->
pf_release_window
=
::
DoRelease
;
p_intf
->
pf_control_window
=
::
DoControl
;
}
else
{
p_intf
->
pf_request_window
=
::
DoNotEmbeddedRequest
;
}
/* Finish the sizing */
...
...
@@ -745,7 +715,7 @@ void MainInterface::releaseVideoSlot( void *p_win )
videoWidget
->
release
(
p_win
);
videoWidget
->
hide
();
if
(
bgWidget
)
// W
O
RONG
if
(
bgWidget
)
// WRONG
bgWidget
->
show
();
adjustSize
();
...
...
src/interface/interface.c
View file @
138da191
...
...
@@ -93,9 +93,6 @@ intf_thread_t* __intf_Create( vlc_object_t *p_this, const char *psz_module )
p_intf
=
vlc_object_create
(
p_this
,
VLC_OBJECT_INTF
);
if
(
!
p_intf
)
return
NULL
;
p_intf
->
pf_request_window
=
NULL
;
p_intf
->
pf_release_window
=
NULL
;
p_intf
->
pf_control_window
=
NULL
;
p_intf
->
b_interaction
=
false
;
p_intf
->
b_should_run_on_first_thread
=
false
;
...
...
src/video_output/vout_intf.c
View file @
138da191
...
...
@@ -2,7 +2,6 @@
* vout_intf.c : video output interface
*****************************************************************************
* Copyright (C) 2000-2007 the VideoLAN team
* $Id$
*
* Authors: Gildas Bazin <gbazin@videolan.org>
*
...
...
@@ -87,12 +86,6 @@ void *vout_RequestWindow( vout_thread_t *p_vout,
unsigned
int
*
pi_width_hint
,
unsigned
int
*
pi_height_hint
)
{
intf_thread_t
*
p_intf
=
NULL
;
vlc_list_t
*
p_list
;
void
*
p_window
;
vlc_value_t
val
;
int
i
;
/* Small kludge */
if
(
!
var_Type
(
p_vout
,
"aspect-ratio"
)
)
vout_IntfInit
(
p_vout
);
...
...
@@ -107,104 +100,18 @@ void *vout_RequestWindow( vout_thread_t *p_vout,
int
drawable
=
var_CreateGetInteger
(
p_vout
,
"drawable"
);
if
(
drawable
)
return
(
void
*
)(
intptr_t
)
drawable
;
#if 0
/* FIXME:
* This code is utter crap w.r.t. threading. And it has always been.
* First, one cannot invoke callbacks from another thread's object.
* Not without a well-defined locking convention.
*
* Second, this would need to "wait" for the interface to be ready.
* Otherwise, the availability of the embded window would become
* time-dependent.
*
* In the past, this kind of things worked by accident. This time is over.
* -- Courmisch, 12 Jun 2008
*/
/* Find if the main interface supports embedding */
p_list = vlc_list_find( p_vout, VLC_OBJECT_INTF, FIND_ANYWHERE );
if( !p_list ) return NULL;
for( i = 0; i < p_list->i_count; i++ )
{
p_intf = (intf_thread_t *)p_list->p_values[i].p_object;
if( p_intf->pf_request_window ) break;
p_intf = NULL;
}
if( !p_intf )
{
vlc_list_release( p_list );
return NULL;
}
vlc_object_yield( p_intf );
vlc_list_release( p_list );
p_window = p_intf->pf_request_window( p_intf, p_vout, pi_x_hint, pi_y_hint,
pi_width_hint, pi_height_hint );
if( !p_window ) vlc_object_release( p_intf );
else p_vout->p_parent_intf = p_intf;
return p_window;
#else
return
NULL
;
#endif
}
void
vout_ReleaseWindow
(
vout_thread_t
*
p_vout
,
void
*
p_window
)
{
intf_thread_t
*
p_intf
=
p_vout
->
p_parent_intf
;
if
(
!
p_intf
)
return
;
vlc_object_lock
(
p_intf
);
if
(
p_intf
->
b_dead
)
{
vlc_object_unlock
(
p_intf
);
return
;
}
if
(
!
p_intf
->
pf_release_window
)
{
msg_Err
(
p_vout
,
"no pf_release_window"
);
vlc_object_unlock
(
p_intf
);
vlc_object_release
(
p_intf
);
return
;
}
p_intf
->
pf_release_window
(
p_intf
,
p_window
);
p_vout
->
p_parent_intf
=
NULL
;
vlc_object_unlock
(
p_intf
);
vlc_object_release
(
p_intf
);
(
void
)
p_vout
;
(
void
)
p_window
;
}
int
vout_ControlWindow
(
vout_thread_t
*
p_vout
,
void
*
p_window
,
int
i_query
,
va_list
args
)
{
intf_thread_t
*
p_intf
=
p_vout
->
p_parent_intf
;
int
i_ret
;
if
(
!
p_intf
)
return
VLC_EGENERIC
;
vlc_object_lock
(
p_intf
);
if
(
p_intf
->
b_dead
)
{
vlc_object_unlock
(
p_intf
);
return
VLC_EGENERIC
;
}
if
(
!
p_intf
->
pf_control_window
)
{
msg_Err
(
p_vout
,
"no pf_control_window"
);
vlc_object_unlock
(
p_intf
);
return
VLC_EGENERIC
;
}
i_ret
=
p_intf
->
pf_control_window
(
p_intf
,
p_window
,
i_query
,
args
);
vlc_object_unlock
(
p_intf
);
return
i_ret
;
(
void
)
p_vout
;
(
void
)
p_window
;
(
void
)
i_query
;
(
void
)
args
;
}
/*****************************************************************************
...
...
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