Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
V
vlc-2-2
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-2-2
Commits
47801e51
Commit
47801e51
authored
Feb 18, 2009
by
Felix Paul Kühne
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
macosx-port: removed compatibility code for outdated versions of OS X
parent
a8038909
Changes
5
Hide whitespace changes
Inline
Side-by-side
Showing
5 changed files
with
18 additions
and
77 deletions
+18
-77
modules/codec/quicktime.c
modules/codec/quicktime.c
+7
-16
modules/gui/macosx/embeddedwindow.m
modules/gui/macosx/embeddedwindow.m
+5
-15
modules/misc/quartztext.c
modules/misc/quartztext.c
+1
-9
projects/macosx/vlc_app/Sources/VLCBrowsableVideoView.m
projects/macosx/vlc_app/Sources/VLCBrowsableVideoView.m
+3
-5
src/misc/darwin_specific.c
src/misc/darwin_specific.c
+2
-32
No files found.
modules/codec/quicktime.c
View file @
47801e51
/*****************************************************************************
* quicktime.c: a quicktime decoder that uses the QT library/dll
*****************************************************************************
* Copyright (C) 2003 the VideoLAN team
* Copyright (C) 2003
, 2008 - 2009
the VideoLAN team
* $Id$
*
* Authors: Laurent Aimar <fenrir at via.ecp.fr>
...
...
@@ -234,9 +234,13 @@ static int Open( vlc_object_t *p_this )
err
=
Gestalt
(
gestaltQuickTimeVersion
,
&
qtVersion
);
err
=
Gestalt
(
gestaltSystemVersion
,
&
macosversion
);
#ifndef NDEBUG
msg_Dbg
(
p_this
,
"
mac os
version is %#lx"
,
macosversion
);
msg_Dbg
(
p_this
,
"
q
uicktime version is %#lx"
,
qtVersion
);
msg_Dbg
(
p_this
,
"
Mac OS
version is %#lx"
,
macosversion
);
msg_Dbg
(
p_this
,
"
Q
uicktime version is %#lx"
,
qtVersion
);
#endif
/* bail out. This plugin is soo Carbon, that it can't be used on 10.5 at all */
msg_Info
(
p_dec
,
"Your Mac OS version is to new to use this plugin for anything."
);
return
VLC_EGENERIC
;
#endif
switch
(
p_dec
->
fmt_in
.
i_codec
)
...
...
@@ -307,19 +311,6 @@ static int Open( vlc_object_t *p_this )
p_dec
->
fmt_out
.
i_cat
=
AUDIO_ES
;
return
VLC_SUCCESS
;
#else
#ifdef __APPLE__
/* FIXME: right now, we don't support audio decoding on 10.5 and later
because we are still using the hardcore-outdated SoundManager API,
which was removed after 10.4 */
if
(
macosversion
>=
0x1050
||
err
!=
noErr
)
{
msg_Warn
(
p_dec
,
"Your Mac OS version doesn't have SoundManager anymore. "
"You can't use this plugin for audio."
);
return
VLC_EGENERIC
;
}
#endif
return
OpenAudio
(
p_dec
);
#endif
...
...
modules/gui/macosx/embeddedwindow.m
View file @
47801e51
/*****************************************************************************
* embeddedwindow.m: MacOS X interface module
*****************************************************************************
* Copyright (C) 2005-200
8
the VideoLAN team
* Copyright (C) 2005-200
9
the VideoLAN team
* $Id$
*
* Authors: Benjamin Pracht <bigben at videolan dot org>
...
...
@@ -261,10 +261,9 @@
[
o_fullscreen_window
setBackgroundColor
:
[
NSColor
blackColor
]];
[
o_fullscreen_window
setCanBecomeKeyWindow
:
YES
];
if
(
!
[
self
isVisible
]
||
[
self
alphaValue
]
==
0
.
0
||
MACOS_VERSION
<
10
.
4
f
)
if
(
!
[
self
isVisible
]
||
[
self
alphaValue
]
==
0
.
0
)
{
/* We don't animate if we are not visible or if we are running on
* Mac OS X <10.4 which doesn't support NSAnimation, instead we
/* We don't animate if we are not visible, instead we
* simply fade the display */
CGDisplayFadeReservationToken
token
;
...
...
@@ -301,14 +300,6 @@
EnableScreenUpdates
();
}
if
(
MACOS_VERSION
<
10
.
4
f
)
{
/* We were already fullscreen nothing to do when NSAnimation
* is not supported */
[
self
unlockFullscreenAnimation
];
return
;
}
/* We are in fullscreen (and no animation is running) */
if
(
b_fullscreen
)
{
...
...
@@ -410,10 +401,9 @@
return
;
}
if
(
fadeout
||
MACOS_VERSION
<
10
.
4
f
)
if
(
fadeout
)
{
/* We don't animate if we are not visible or if we are running on
* Mac OS X <10.4 which doesn't support NSAnimation, instead we
/* We don't animate if we are not visible, instead we
* simply fade the display */
CGDisplayFadeReservationToken
token
;
...
...
modules/misc/quartztext.c
View file @
47801e51
/*****************************************************************************
* quartztext.c : Put text on the video, using Mac OS X Quartz Engine
*****************************************************************************
* Copyright (C) 2007 the VideoLAN team
* Copyright (C) 2007
, 2009
the VideoLAN team
* $Id$
*
* Authors: Bernie Purcell <bitmap@videolan.org>
...
...
@@ -667,11 +667,7 @@ static CGContextRef CreateOffScreenContext( int i_width, int i_height,
p_bitmap
->
p_data
=
calloc
(
i_height
,
p_bitmap
->
i_bytesPerRow
);
#if MAC_OS_X_VERSION_MIN_REQUIRED >= MAC_OS_X_VERSION_10_4
*
pp_colorSpace
=
CGColorSpaceCreateWithName
(
kCGColorSpaceGenericRGB
);
#else
*
pp_colorSpace
=
CreateGenericRGBColorSpace
();
#endif
if
(
p_bitmap
->
p_data
&&
*
pp_colorSpace
)
{
...
...
@@ -681,14 +677,10 @@ static CGContextRef CreateOffScreenContext( int i_width, int i_height,
}
if
(
p_context
)
{
#if MAC_OS_X_VERSION_MIN_REQUIRED > MAC_OS_X_VERSION_10_1
// OS X 10.1 doesn't support weak linking of this call which is only available
// int 10.4 and later
if
(
CGContextSetAllowsAntialiasing
!=
NULL
)
{
CGContextSetAllowsAntialiasing
(
p_context
,
true
);
}
#endif
}
*
pp_memory
=
p_bitmap
;
}
...
...
projects/macosx/vlc_app/Sources/VLCBrowsableVideoView.m
View file @
47801e51
...
...
@@ -3,7 +3,7 @@
* browsing
*****************************************************************************
* Copyright (C) 2007 Pierre d'Herbemont
* Copyright (C) 2007 the VideoLAN team
* Copyright (C) 2007
, 2009
the VideoLAN team
* $Id$
*
* Authors: Pierre d'Herbemont <pdherbemont # videolan.org>
...
...
@@ -683,8 +683,7 @@
if
(
!
[[
self
window
]
isVisible
]
||
[[
self
window
]
alphaValue
]
==
0
.
0
||
[
self
isHiddenOrHasHiddenAncestor
]
)
{
/* We don't animate if we are not visible or if we are running on
* Mac OS X <10.4 which doesn't support NSAnimation, instead we
/* We don't animate if we are not visible, instead we
* simply fade the display */
CGDisplayFadeReservationToken
token
;
...
...
@@ -817,8 +816,7 @@
if
(
fadeout
||
[
tempFullScreenView
isHiddenOrHasHiddenAncestor
])
{
/* We don't animate if we are not visible or if we are running on
* Mac OS X <10.4 which doesn't support NSAnimation, instead we
/* We don't animate if we are not visible, instead we
* simply fade the display */
CGDisplayFadeReservationToken
token
;
...
...
src/misc/darwin_specific.c
View file @
47801e51
/*****************************************************************************
* darwin_specific.m: Darwin specific features
*****************************************************************************
* Copyright (C) 2001-200
7
the VideoLAN team
* Copyright (C) 2001-200
9
the VideoLAN team
* $Id$
*
* Authors: Sam Hocevar <sam@zoy.org>
...
...
@@ -44,33 +44,6 @@
# define MAXPATHLEN 1024
#endif
/* CFLocaleCopyAvailableLocaleIdentifiers is present only on post-10.4 */
extern
CFArrayRef
CFLocaleCopyAvailableLocaleIdentifiers
(
void
)
__attribute__
((
weak_import
));
/* emulate CFLocaleCopyAvailableLocaleIdentifiers on pre-10.4 */
static
CFArrayRef
copy_all_locale_indentifiers
(
void
)
{
CFMutableArrayRef
available_locales
;
DIR
*
dir
;
struct
dirent
*
file
;
dir
=
opendir
(
"/usr/share/locale"
);
available_locales
=
CFArrayCreateMutable
(
kCFAllocatorDefault
,
0
,
&
kCFTypeArrayCallBacks
);
while
(
(
file
=
readdir
(
dir
))
)
{
/* we should probably filter out garbage */
/* we can't use CFStringCreateWithFileSystemRepresentation as it is
* supported only on post-10.4 (and this function is only for pre-10.4) */
CFStringRef
locale
=
CFStringCreateWithCString
(
kCFAllocatorDefault
,
file
->
d_name
,
kCFStringEncodingUTF8
);
CFArrayAppendValue
(
available_locales
,
(
void
*
)
locale
);
CFRelease
(
locale
);
}
closedir
(
dir
);
return
available_locales
;
}
/*****************************************************************************
* system_Init: fill in program path & retrieve language
*****************************************************************************/
...
...
@@ -149,10 +122,7 @@ void system_Init( libvlc_int_t *p_this, int *pi_argc, const char *ppsz_argv[] )
CFArrayRef
all_locales
,
preferred_locales
;
char
psz_locale
[
50
];
if
(
CFLocaleCopyAvailableLocaleIdentifiers
)
all_locales
=
CFLocaleCopyAvailableLocaleIdentifiers
();
else
all_locales
=
copy_all_locale_indentifiers
();
all_locales
=
CFLocaleCopyAvailableLocaleIdentifiers
();
preferred_locales
=
CFBundleCopyLocalizationsForPreferences
(
all_locales
,
NULL
);
...
...
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