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
50dcfe2a
Commit
50dcfe2a
authored
Oct 10, 2015
by
David Fuhrmann
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
macosx: Introduce OSX_EL_CAPITAN runtime check
parent
ffa25eff
Changes
6
Show whitespace changes
Inline
Side-by-side
Showing
6 changed files
with
11 additions
and
10 deletions
+11
-10
modules/gui/macosx/CompatibilityFixes.h
modules/gui/macosx/CompatibilityFixes.h
+2
-1
modules/gui/macosx/InputManager.m
modules/gui/macosx/InputManager.m
+1
-1
modules/gui/macosx/MainWindowTitle.m
modules/gui/macosx/MainWindowTitle.m
+5
-5
modules/gui/macosx/StringUtility.m
modules/gui/macosx/StringUtility.m
+1
-1
modules/gui/macosx/about.m
modules/gui/macosx/about.m
+1
-1
modules/gui/macosx/misc.m
modules/gui/macosx/misc.m
+1
-1
No files found.
modules/gui/macosx/CompatibilityFixes.h
View file @
50dcfe2a
...
...
@@ -28,4 +28,5 @@
#define OSX_LION (NSAppKitVersionNumber < 1162 && NSAppKitVersionNumber >= 1115.2)
#define OSX_MOUNTAIN_LION (NSAppKitVersionNumber < 1244 && NSAppKitVersionNumber >= 1162)
#define OSX_MAVERICKS (NSAppKitVersionNumber < 1334 && NSAppKitVersionNumber >= 1244)
#define OSX_YOSEMITE (NSAppKitVersionNumber >= 1334)
#define OSX_YOSEMITE (NSAppKitVersionNumber < 1404 && NSAppKitVersionNumber >= 1334)
#define OSX_EL_CAPITAN (NSAppKitVersionNumber >= 1404)
modules/gui/macosx/InputManager.m
View file @
50dcfe2a
...
...
@@ -304,7 +304,7 @@ static int InputEvent(vlc_object_t *p_this, const char *psz_var,
IOReturn
success
;
/* work-around a bug in 10.7.4 and 10.7.5, so check for 10.7.x < 10.7.4 and 10.8 */
if
((
NSAppKitVersionNumber
>=
1115
.
2
&&
NSAppKitVersionNumber
<
1138
.
45
)
||
OSX_MOUNTAIN_LION
||
OSX_MAVERICKS
||
OSX_YOSEMITE
)
{
if
((
NSAppKitVersionNumber
>=
1115
.
2
&&
NSAppKitVersionNumber
<
1138
.
45
)
||
OSX_MOUNTAIN_LION
||
OSX_MAVERICKS
||
OSX_YOSEMITE
||
OSX_EL_CAPITAN
)
{
CFStringRef
reasonForActivity
=
CFStringCreateWithCString
(
kCFAllocatorDefault
,
_
(
"VLC media playback"
),
kCFStringEncodingUTF8
);
if
([
o_main
activeVideoPlayback
])
success
=
IOPMAssertionCreateWithName
(
kIOPMAssertionTypeNoDisplaySleep
,
kIOPMAssertionLevelOn
,
reasonForActivity
,
&
systemSleepAssertionID
);
...
...
modules/gui/macosx/MainWindowTitle.m
View file @
50dcfe2a
...
...
@@ -84,7 +84,7 @@
{
b_nativeFullscreenMode
=
var_InheritBool
(
VLCIntf
,
"macosx-nativefullscreenmode"
);
if
(
!
b_nativeFullscreenMode
||
OSX_YOSEMITE
)
{
if
(
!
b_nativeFullscreenMode
||
OSX_YOSEMITE
||
OSX_EL_CAPITAN
)
{
[
o_fullscreen_btn
setHidden
:
YES
];
}
...
...
@@ -118,7 +118,7 @@
-
(
NSImage
*
)
getButtonImage
:(
NSString
*
)
o_id
{
NSString
*
o_name
=
@""
;
if
(
OSX_YOSEMITE
)
{
if
(
OSX_YOSEMITE
||
OSX_EL_CAPITAN
)
{
o_name
=
@"yosemite-"
;
}
else
{
// OSX_LION, OSX_MOUNTAIN_LION, OSX_MAVERICKS
o_name
=
@"lion-"
;
...
...
@@ -146,7 +146,7 @@
o_green_on_img
=
[
self
getButtonImage
:
@"window-zoom-on"
];
// these files are only available in the yosemite variant
if
(
OSX_YOSEMITE
)
{
if
(
OSX_YOSEMITE
||
OSX_EL_CAPITAN
)
{
o_fullscreen_img
=
[
self
getButtonImage
:
@"window-fullscreen"
];
o_fullscreen_over_img
=
[
self
getButtonImage
:
@"window-fullscreen-over"
];
o_fullscreen_on_img
=
[
self
getButtonImage
:
@"window-fullscreen-on"
];
...
...
@@ -181,7 +181,7 @@
{
// default image for old version, or if native fullscreen is
// disabled on yosemite, or if alt key is pressed
if
(
!
OSX_YOSEMITE
||
!
b_nativeFullscreenMode
||
b_alt_pressed
)
{
if
(
!
(
OSX_YOSEMITE
||
OSX_EL_CAPITAN
)
||
!
b_nativeFullscreenMode
||
b_alt_pressed
)
{
if
(
b_mouse_over
)
{
[
o_green_btn
setImage
:
o_green_over_img
];
...
...
@@ -214,7 +214,7 @@
else
if
(
sender
==
o_yellow_btn
)
[[
self
window
]
miniaturize
:
sender
];
else
if
(
sender
==
o_green_btn
)
{
if
(
OSX_YOSEMITE
&&
b_nativeFullscreenMode
&&
!
b_alt_pressed
)
{
if
(
(
OSX_YOSEMITE
||
OSX_EL_CAPITAN
)
&&
b_nativeFullscreenMode
&&
!
b_alt_pressed
)
{
[[
self
window
]
toggleFullScreen
:
self
];
}
else
{
[[
self
window
]
performZoom
:
sender
];
...
...
modules/gui/macosx/StringUtility.m
View file @
50dcfe2a
...
...
@@ -532,7 +532,7 @@ NSString *toNSStr(const char *str) {
NSImage
*
imageFromRes
(
NSString
*
o_id
)
{
NSString
*
result
=
@""
;
if
(
OSX_YOSEMITE
)
{
if
(
OSX_YOSEMITE
||
OSX_EL_CAPITAN
)
{
result
=
[
result
stringByAppendingString
:
@"ys-"
];
}
...
...
modules/gui/macosx/about.m
View file @
50dcfe2a
...
...
@@ -139,7 +139,7 @@
"
\"
http://www.videolan.org/contribute/
\"
><span style=
\"
text-decoration: "
"underline; color:#0057ae;
\"
>Help and join us!</span></a>"
));
NSString
*
fontfamily
;
if
(
OSX_YOSEMITE
)
if
(
OSX_YOSEMITE
||
OSX_EL_CAPITAN
)
fontfamily
=
@"Helvetica Neue"
;
else
fontfamily
=
@"Lucida Grande"
;
...
...
modules/gui/macosx/misc.m
View file @
50dcfe2a
...
...
@@ -173,7 +173,7 @@ static bool b_old_spaces_style = YES;
/* init our fake object attribute */
blackoutWindows
=
[[
NSMutableArray
alloc
]
initWithCapacity
:
1
];
if
(
OSX_MAVERICKS
||
OSX_YOSEMITE
)
{
if
(
OSX_MAVERICKS
||
OSX_YOSEMITE
||
OSX_EL_CAPITAN
)
{
NSUserDefaults
*
userDefaults
=
[[
NSUserDefaults
alloc
]
init
];
[
userDefaults
addSuiteNamed
:
@"com.apple.spaces"
];
/* this is system settings -> mission control -> monitors using different spaces */
...
...
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