Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
V
vlc-gpu
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-gpu
Commits
f4f58eb9
Commit
f4f58eb9
authored
Aug 10, 2011
by
Felix Paul Kühne
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
vout_macosx: factorize objc selectors
no functional change
parent
32272ce5
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
18 additions
and
11 deletions
+18
-11
modules/video_output/macosx.m
modules/video_output/macosx.m
+18
-11
No files found.
modules/video_output/macosx.m
View file @
f4f58eb9
/*****************************************************************************
/*****************************************************************************
* voutgl.m: MacOS X OpenGL provider
* voutgl.m: MacOS X OpenGL provider
*****************************************************************************
*****************************************************************************
* Copyright (C) 2001-20
09
the VideoLAN team
* Copyright (C) 2001-20
11
the VideoLAN team
* $Id$
* $Id$
*
*
* Authors: Colin Delacroix <colin@zoy.org>
* Authors: Colin Delacroix <colin@zoy.org>
...
@@ -12,6 +12,7 @@
...
@@ -12,6 +12,7 @@
* Benjamin Pracht <bigben at videolan dot org>
* Benjamin Pracht <bigben at videolan dot org>
* Damien Fouilleul <damienf at videolan dot org>
* Damien Fouilleul <damienf at videolan dot org>
* Pierre d'Herbemont <pdherbemont at videolan dot org>
* Pierre d'Herbemont <pdherbemont at videolan dot org>
* Felix Paul Kühne <fkuehne at videolan dot org>
*
*
* This program is free software; you can redistribute it and/or modify
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* it under the terms of the GNU General Public License as published by
...
@@ -311,28 +312,34 @@ static int Control (vout_display_t *vd, int query, va_list ap)
...
@@ -311,28 +312,34 @@ static int Control (vout_display_t *vd, int query, va_list ap)
NSPoint
topleftscreen
;
NSPoint
topleftscreen
;
NSRect
new_frame
;
NSRect
new_frame
;
const
vout_display_cfg_t
*
cfg
;
const
vout_display_cfg_t
*
cfg
;
id
o_window
=
[
sys
->
glView
window
];
NSRect
windowFrame
=
[
o_window
frame
];
NSRect
glViewFrame
=
[
sys
->
glView
frame
];
NSSize
windowMinSize
=
[
o_window
minSize
];
topleftbase
.
x
=
0
;
topleftbase
.
x
=
0
;
topleftbase
.
y
=
[[
sys
->
glView
window
]
frame
]
.
size
.
height
;
topleftbase
.
y
=
windowFrame
.
size
.
height
;
topleftscreen
=
[
[
sys
->
glView
window
]
convertBaseToScreen
:
topleftbase
];
topleftscreen
=
[
o_window
convertBaseToScreen
:
topleftbase
];
cfg
=
(
const
vout_display_cfg_t
*
)
va_arg
(
ap
,
const
vout_display_cfg_t
*
);
cfg
=
(
const
vout_display_cfg_t
*
)
va_arg
(
ap
,
const
vout_display_cfg_t
*
);
int
i_width
=
cfg
->
display
.
width
;
int
i_width
=
cfg
->
display
.
width
;
int
i_height
=
cfg
->
display
.
height
;
int
i_height
=
cfg
->
display
.
height
;
/* Calculate the window's new size, if it is larger than our minimal size */
/* Calculate the window's new size, if it is larger than our minimal size */
if
(
i_width
<
[[
sys
->
glView
window
]
minSize
]
.
width
)
if
(
i_width
<
windowMinSize
.
width
)
i_width
=
[[
sys
->
glView
window
]
minSize
]
.
width
;
i_width
=
windowMinSize
.
width
;
if
(
i_height
<
[[
sys
->
glView
window
]
minSize
]
.
height
)
if
(
i_height
<
windowMinSize
.
height
)
i_height
=
[[
sys
->
glView
window
]
minSize
]
.
height
;
i_height
=
windowMinSize
.
height
;
if
(
i_height
!=
[
sys
->
glView
frame
].
size
.
height
||
i_width
!=
[
sys
->
glView
frame
]
.
size
.
width
)
if
(
i_height
!=
glViewFrame
.
size
.
height
||
i_width
!=
glViewFrame
.
size
.
width
)
{
{
new_frame
.
size
.
width
=
[[
sys
->
glView
window
]
frame
].
size
.
width
-
[
sys
->
glView
frame
]
.
size
.
width
+
i_width
;
new_frame
.
size
.
width
=
windowFrame
.
size
.
width
-
glViewFrame
.
size
.
width
+
i_width
;
new_frame
.
size
.
height
=
[[
sys
->
glView
window
]
frame
].
size
.
height
-
[
sys
->
glView
frame
]
.
size
.
height
+
i_height
;
new_frame
.
size
.
height
=
windowFrame
.
size
.
height
-
glViewFrame
.
size
.
height
+
i_height
;
new_frame
.
origin
.
x
=
topleftscreen
.
x
;
new_frame
.
origin
.
x
=
topleftscreen
.
x
;
new_frame
.
origin
.
y
=
topleftscreen
.
y
-
new_frame
.
size
.
height
;
new_frame
.
origin
.
y
=
topleftscreen
.
y
-
new_frame
.
size
.
height
;
[
[
sys
->
glView
window
]
setFrame
:
new_frame
display
:
YES
animate
:
YES
];
[
o_window
setFrame
:
new_frame
display
:
YES
animate
:
YES
];
}
}
return
VLC_SUCCESS
;
return
VLC_SUCCESS
;
}
}
...
...
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