Skip to content
GitLab
Projects
Groups
Snippets
Help
Loading...
Help
What's new
7
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Sign in / Register
Toggle navigation
Open sidebar
VideoLAN
VLC-iOS
Commits
7e7d9c57
Commit
7e7d9c57
authored
Oct 29, 2015
by
Tobias
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
don't use VLCPlayerDisplayController on TV
parent
6d1280b1
Changes
10
Hide whitespace changes
Inline
Side-by-side
Showing
10 changed files
with
38 additions
and
34 deletions
+38
-34
SharedSources/ServerBrowsing/VLCServerBrowsingController.m
SharedSources/ServerBrowsing/VLCServerBrowsingController.m
+15
-0
Sources/VLCDropboxController.m
Sources/VLCDropboxController.m
+2
-4
Sources/VLCOneDriveTableViewController.m
Sources/VLCOneDriveTableViewController.m
+6
-0
Sources/VLCPlaybackController.m
Sources/VLCPlaybackController.m
+1
-1
VLC for Apple TV/AppleTVAppDelegate.m
VLC for Apple TV/AppleTVAppDelegate.m
+1
-4
VLC for Apple TV/TVPrefixHeader.pch
VLC for Apple TV/TVPrefixHeader.pch
+1
-0
VLC for Apple TV/VLCFullscreenMovieTVViewController.h
VLC for Apple TV/VLCFullscreenMovieTVViewController.h
+2
-0
VLC for Apple TV/VLCFullscreenMovieTVViewController.m
VLC for Apple TV/VLCFullscreenMovieTVViewController.m
+6
-19
VLC for Apple TV/VLCOpenNetworkStreamTVViewController.m
VLC for Apple TV/VLCOpenNetworkStreamTVViewController.m
+4
-2
VLC for iOS.xcodeproj/project.pbxproj
VLC for iOS.xcodeproj/project.pbxproj
+0
-4
No files found.
SharedSources/ServerBrowsing/VLCServerBrowsingController.m
View file @
7e7d9c57
...
...
@@ -16,6 +16,9 @@
#import "VLCPlaybackController.h"
#if TARGET_OS_TV
#import "VLCFullscreenMovieTVViewController.h"
#endif
#if DOWNLOAD_SUPPORTED
#import "VLCDownloadViewController.h"
...
...
@@ -179,11 +182,22 @@
#pragma mark - File Streaming
-
(
void
)
showMovieViewController
{
#if TARGET_OS_TV
VLCFullscreenMovieTVViewController
*
moviewVC
=
[
VLCFullscreenMovieTVViewController
fullscreenMovieTVViewController
];
[
self
.
viewController
presentViewController
:
moviewVC
animated:
YES
completion:
nil
];
#endif
}
-
(
void
)
streamMediaList
:(
VLCMediaList
*
)
mediaList
startingAtIndex
:(
NSInteger
)
startIndex
{
VLCPlaybackController
*
vpc
=
[
VLCPlaybackController
sharedInstance
];
[
vpc
playMediaList
:
mediaList
firstIndex
:
startIndex
];
[
self
showMovieViewController
];
}
-
(
void
)
streamFileForItem
:(
id
<
VLCNetworkServerBrowserItem
>
)
item
...
...
@@ -205,6 +219,7 @@
VLCPlaybackController
*
vpc
=
[
VLCPlaybackController
sharedInstance
];
[
vpc
playURL
:
URLToPlay
subtitlesFilePath
:
URLofSubtitle
];
[
self
showMovieViewController
];
}
...
...
Sources/VLCDropboxController.m
View file @
7e7d9c57
...
...
@@ -14,9 +14,7 @@
#import "VLCDropboxController.h"
#import "NSString+SupportedMedia.h"
#import "VLCPlaybackController.h"
#if TARGET_OS_TV
#import "VLCPlayerDisplayController.h"
#else
#if !TARGET_OS_TV
#import "VLCActivityManager.h"
#import "VLCMediaFileDiscoverer.h"
#endif
...
...
@@ -326,7 +324,7 @@
[
alert
addAction
:
defaultAction
];
[[
[
VLCPlayerDisplayController
sharedInstance
]
child
ViewController
]
presentViewController
:
alert
animated
:
YES
completion
:
nil
];
[[
UIApplication
sharedApplication
].
keyWindow
.
root
ViewController
presentViewController
:
alert
animated
:
YES
completion
:
nil
];
#endif
}
...
...
Sources/VLCOneDriveTableViewController.m
View file @
7e7d9c57
...
...
@@ -116,6 +116,12 @@
NSURL
*
url
=
[
NSURL
URLWithString
:
selectedObject
.
downloadPath
];
VLCPlaybackController
*
vpc
=
[
VLCPlaybackController
sharedInstance
];
[
vpc
playURL
:
url
successCallback
:
nil
errorCallback
:
nil
];
#if TARGET_OS_TV
VLCFullscreenMovieTVViewController
*
movieVC
=
[
VLCFullscreenMovieTVViewController
fullscreenMovieTVViewController
];
[
self
presentViewController
:
movieVC
animated:
YES
completion:
nil
];
#endif
}
[
self
.
tableView
deselectRowAtIndexPath
:
indexPath
animated
:
NO
];
...
...
Sources/VLCPlaybackController.m
View file @
7e7d9c57
...
...
@@ -280,7 +280,7 @@ NSString *const VLCPlaybackControllerPlaybackDidFail = @"VLCPlaybackControllerPl
}];
[
alert
addAction
:
defaultAction
];
[
alert
addAction
:
cancelAction
];
[[
[
VLCPlayerDisplayController
sharedInstance
]
child
ViewController
]
presentViewController
:
alert
animated
:
YES
completion
:
nil
];
[[
UIApplication
sharedApplication
].
keyWindow
.
root
ViewController
presentViewController
:
alert
animated
:
YES
completion
:
nil
];
#endif
}
else
[
self
_playNewMedia
];
...
...
VLC for Apple TV/AppleTVAppDelegate.m
View file @
7e7d9c57
...
...
@@ -13,7 +13,6 @@
#import "VLCAppSharesTVViewController.h"
#import "VLCLocalNetworkTVViewController.h"
#import "VLCOpenNetworkStreamTVViewController.h"
#import "VLCPlayerDisplayController.h"
#import "VLCSettingsAboutTableViewController.h"
#import "VLCCloudServicesTVViewController.h"
...
...
@@ -73,9 +72,7 @@
[[
UINavigationController
alloc
]
initWithRootViewController
:
_localNetworkVC
],
_cloudServicesVC
,
_openNetworkVC
,
_aboutSettingsVC
];
VLCPlayerDisplayController
*
playerDisplayController
=
[
VLCPlayerDisplayController
sharedInstance
];
playerDisplayController
.
childViewController
=
_mainViewController
;
self
.
window
.
rootViewController
=
playerDisplayController
;
self
.
window
.
rootViewController
=
_mainViewController
;
[
self
.
window
makeKeyAndVisible
];
return
YES
;
...
...
VLC for Apple TV/TVPrefixHeader.pch
View file @
7e7d9c57
...
...
@@ -23,6 +23,7 @@
#import "UIColor+Presets.h"
#import "VLCTVConstants.h"
#import "UIViewController+VLCAlert.h"
#import "VLCFullscreenMovieTVViewController.h"
#define SYSTEM_VERSION_GREATER_THAN_OR_EQUAL_TO(v) ([[UIDevice currentDevice] systemVersion].floatValue >= [v floatValue])
...
...
VLC for Apple TV/VLCFullscreenMovieTVViewController.h
View file @
7e7d9c57
...
...
@@ -24,4 +24,6 @@
@property
(
readwrite
,
nonatomic
,
weak
)
IBOutlet
UILabel
*
titleLabel
;
@property
(
readwrite
,
nonatomic
,
weak
)
IBOutlet
UILabel
*
bufferingLabel
;
+
(
instancetype
)
fullscreenMovieTVViewController
;
@end
VLC for Apple TV/VLCFullscreenMovieTVViewController.m
View file @
7e7d9c57
...
...
@@ -10,7 +10,6 @@
*****************************************************************************/
#import "VLCFullscreenMovieTVViewController.h"
#import "VLCPlayerDisplayController.h"
@interface
VLCFullscreenMovieTVViewController
()
{
...
...
@@ -21,6 +20,11 @@
@implementation
VLCFullscreenMovieTVViewController
+
(
instancetype
)
fullscreenMovieTVViewController
{
return
[[
self
alloc
]
initWithNibName
:
nil
bundle
:
nil
];
}
-
(
void
)
viewDidLoad
{
[
super
viewDidLoad
];
...
...
@@ -28,10 +32,6 @@
self
.
edgesForExtendedLayout
=
UIRectEdgeAll
;
NSNotificationCenter
*
center
=
[
NSNotificationCenter
defaultCenter
];
[
center
addObserver
:
self
selector:
@selector
(
appBecameActive
:)
name:
UIApplicationDidBecomeActiveNotification
object:
nil
];
[
center
addObserver
:
self
selector:
@selector
(
playbackDidStop
:)
name:
VLCPlaybackControllerPlaybackDidStop
...
...
@@ -109,22 +109,9 @@
APLog
(
@"%s"
,
__PRETTY_FUNCTION__
);
}
-
(
void
)
appBecameActive
:(
NSNotification
*
)
aNotification
{
VLCPlayerDisplayController
*
pdc
=
[
VLCPlayerDisplayController
sharedInstance
];
if
(
pdc
.
displayMode
==
VLCPlayerDisplayControllerDisplayModeFullscreen
)
{
VLCPlaybackController
*
vpc
=
[
VLCPlaybackController
sharedInstance
];
[
vpc
recoverDisplayedMetadata
];
if
(
vpc
.
videoOutputView
!=
self
.
movieView
)
{
vpc
.
videoOutputView
=
nil
;
vpc
.
videoOutputView
=
self
.
movieView
;
}
}
}
-
(
void
)
playbackDidStop
:(
NSNotification
*
)
aNotification
{
[
[
UIApplication
sharedApplication
]
sendAction
:
@selector
(
closeFullscreenPlayback
)
to
:
nil
from
:
self
forEvent
:
nil
];
[
self
dismissViewControllerAnimated
:
YES
completion
:
nil
];
}
-
(
void
)
mediaPlayerStateChanged
:(
VLCMediaPlayerState
)
currentState
...
...
VLC for Apple TV/VLCOpenNetworkStreamTVViewController.m
View file @
7e7d9c57
...
...
@@ -12,6 +12,7 @@
#import "VLCOpenNetworkStreamTVViewController.h"
#import "VLCPlaybackController.h"
#import "VLCPlayerDisplayController.h"
#import "VLCFullscreenMovieTVViewController.h"
@interface
VLCOpenNetworkStreamTVViewController
()
{
...
...
@@ -103,10 +104,11 @@
-
(
void
)
_openURLStringAndDismiss
:(
NSString
*
)
url
{
[
VLCPlayerDisplayController
sharedInstance
].
displayMode
=
VLCPlayerDisplayControllerDisplayModeFullscreen
;
VLCPlaybackController
*
vpc
=
[
VLCPlaybackController
sharedInstance
];
[
vpc
playURL
:[
NSURL
URLWithString
:
url
]
subtitlesFilePath
:
nil
];
[
self
presentViewController
:[
VLCFullscreenMovieTVViewController
fullscreenMovieTVViewController
]
animated:
YES
completion:
nil
];
}
@end
VLC for iOS.xcodeproj/project.pbxproj
View file @
7e7d9c57
...
...
@@ -206,8 +206,6 @@
7DDD0429172D98E5005A7B10
/* CFNetwork.framework in Frameworks */
=
{
isa
=
PBXBuildFile
;
fileRef
=
7DDD0428172D98E5005A7B10
/* CFNetwork.framework */
;
};
7DDFF4251BDFD23300913BD1
/* VLCCone512x512.png in Resources */
=
{
isa
=
PBXBuildFile
;
fileRef
=
7DDFF4241BDFD23300913BD1
/* VLCCone512x512.png */
;
};
7DE56C1A1AD93F9100E8CA00
/* VLCPlaybackController.m in Sources */
=
{
isa
=
PBXBuildFile
;
fileRef
=
7DE56C191AD93F9100E8CA00
/* VLCPlaybackController.m */
;
};
7DEC8BD71BD658E6006E1093
/* VLCPlayerDisplayController.m in Sources */
=
{
isa
=
PBXBuildFile
;
fileRef
=
DD510B6F1B14E564003BA71C
/* VLCPlayerDisplayController.m */
;
};
7DEC8BD81BD66DA8006E1093
/* VLCMiniPlaybackView.m in Sources */
=
{
isa
=
PBXBuildFile
;
fileRef
=
7D95610A1AF3E9E800779745
/* VLCMiniPlaybackView.m */
;
};
7DEC8BD91BD670EB006E1093
/* VLCPlaybackNavigationController.m in Sources */
=
{
isa
=
PBXBuildFile
;
fileRef
=
7D9CB9DB1A4C55EF00BB74B4
/* VLCPlaybackNavigationController.m */
;
};
7DEC8BDA1BD67112006E1093
/* VLCFrostedGlasView.m in Sources */
=
{
isa
=
PBXBuildFile
;
fileRef
=
9BADAF44185FBD9D00108BD8
/* VLCFrostedGlasView.m */
;
};
7DEC8BDE1BD67899006E1093
/* VLCFullscreenMovieTVViewController.m in Sources */
=
{
isa
=
PBXBuildFile
;
fileRef
=
7DEC8BDC1BD67899006E1093
/* VLCFullscreenMovieTVViewController.m */
;
};
...
...
@@ -2677,7 +2675,6 @@
DD3EFF4A1BDEBCE500B68579
/* VLCLocalNetworkServiceBrowserPlex.m in Sources */
,
DD3EABEF1BE14720003668DA
/* VLCPlaybackControlsFocusView.m in Sources */
,
7DEC8BED1BD68D6A006E1093
/* VLCAboutTVViewController.m in Sources */
,
7DEC8BD81BD66DA8006E1093
/* VLCMiniPlaybackView.m in Sources */
,
DD3EFF3A1BDEBCE500B68579
/* VLCLocalNetworkServiceVLCMedia.m in Sources */
,
7D7EF3DA1BD56B5900CD4CEE
/* VLCOpenNetworkStreamTVViewController.m in Sources */
,
DD3EFF521BDEBCE500B68579
/* VLCPlexWebAPI.m in Sources */
,
...
...
@@ -2690,7 +2687,6 @@
7D13347C1BE132EA0012E919
/* VLCLocalNetworkServiceBrowserUPnP.m in Sources */
,
DDEAECF11BDFE9E800756C83
/* VLCServerListTVTableViewController.m in Sources */
,
7DEC8BDE1BD67899006E1093
/* VLCFullscreenMovieTVViewController.m in Sources */
,
7DEC8BD71BD658E6006E1093
/* VLCPlayerDisplayController.m in Sources */
,
DD3EFF501BDEBCE500B68579
/* VLCPlexParser.m in Sources */
,
7D44085A1BDA8DCE0080FB42
/* VLCBoxTableViewController.m in Sources */
,
DD3EFF4E1BDEBCE500B68579
/* VLCNetworkServerBrowserPlex.m in Sources */
,
...
...
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