Skip to content
GitLab
Projects
Groups
Snippets
Help
Loading...
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
VLC-iOS
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
311
Issues
311
List
Boards
Labels
Service Desk
Milestones
Merge Requests
6
Merge Requests
6
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Operations
Operations
Incidents
Environments
Analytics
Analytics
CI / CD
Repository
Value Stream
Wiki
Wiki
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
VideoLAN
VLC-iOS
Commits
26bdb0ca
Commit
26bdb0ca
authored
Oct 22, 2015
by
Felix Paul Kühne
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
ATV: add OneDrive support
parent
040be9d5
Changes
7
Hide whitespace changes
Inline
Side-by-side
Showing
7 changed files
with
33 additions
and
15 deletions
+33
-15
Sources/VLCCloudStorageTableViewCell.h
Sources/VLCCloudStorageTableViewCell.h
+2
-2
Sources/VLCCloudStorageTableViewCell.m
Sources/VLCCloudStorageTableViewCell.m
+4
-3
Sources/VLCOneDriveTableViewController.m
Sources/VLCOneDriveTableViewController.m
+10
-8
VLC for Apple TV/VLCCloudServicesTVViewController.h
VLC for Apple TV/VLCCloudServicesTVViewController.h
+1
-0
VLC for Apple TV/VLCCloudServicesTVViewController.m
VLC for Apple TV/VLCCloudServicesTVViewController.m
+9
-0
VLC for Apple TV/VLCCloudServicesTVViewController.xib
VLC for Apple TV/VLCCloudServicesTVViewController.xib
+5
-2
VLC for iOS.xcodeproj/project.pbxproj
VLC for iOS.xcodeproj/project.pbxproj
+2
-0
No files found.
Sources/VLCCloudStorageTableViewCell.h
View file @
26bdb0ca
...
...
@@ -12,10 +12,10 @@
*****************************************************************************/
#import "VLCDropboxController.h"
#import "VLCOneDriveObject.h"
#if TARGET_OS_IOS
#import "GTLDrive.h"
#import <BoxSDK/BoxSDK.h>
#import "VLCOneDriveObject.h"
#endif
@interface
VLCCloudStorageTableViewCell
:
UITableViewCell
...
...
@@ -29,10 +29,10 @@
@property
(
nonatomic
,
strong
)
IBOutlet
UIButton
*
downloadButton
;
@property
(
nonatomic
,
retain
)
DBMetadata
*
dropboxFile
;
@property
(
nonatomic
,
retain
)
VLCOneDriveObject
*
oneDriveFile
;
#if TARGET_OS_IOS
@property
(
nonatomic
,
retain
)
GTLDriveFile
*
driveFile
;
@property
(
nonatomic
,
retain
)
BoxItem
*
boxFile
;
@property
(
nonatomic
,
retain
)
VLCOneDriveObject
*
oneDriveFile
;
#endif
@property
(
nonatomic
,
readwrite
)
BOOL
isDownloadable
;
...
...
Sources/VLCCloudStorageTableViewCell.m
View file @
26bdb0ca
...
...
@@ -57,6 +57,7 @@
[
self
performSelectorOnMainThread
:
@selector
(
_updatedDisplayedInformation
)
withObject:
nil
waitUntilDone
:
NO
];
}
#endif
-
(
void
)
setOneDriveFile
:(
VLCOneDriveObject
*
)
oneDriveFile
{
...
...
@@ -66,7 +67,6 @@
[
self
performSelectorOnMainThread
:
@selector
(
_updatedDisplayedInformation
)
withObject:
nil
waitUntilDone
:
NO
];
}
#endif
-
(
void
)
_updatedDisplayedInformation
{
...
...
@@ -152,7 +152,9 @@
self
.
thumbnailView
.
image
=
[
UIImage
imageNamed
:
@"blank"
];
APLog
(
@"missing icon for type '%@'"
,
self
.
boxFile
);
}
}
else
if
(
_oneDriveFile
!=
nil
)
{
}
#endif
else
if
(
_oneDriveFile
!=
nil
)
{
if
(
_oneDriveFile
.
isFolder
)
{
self
.
downloadButton
.
hidden
=
YES
;
self
.
folderTitleLabel
.
text
=
self
.
oneDriveFile
.
name
;
...
...
@@ -191,7 +193,6 @@
self
.
thumbnailView
.
image
=
[
UIImage
imageNamed
:
@"blank"
];
}
}
#endif
[
self
setNeedsDisplay
];
}
...
...
Sources/VLCOneDriveTableViewController.m
View file @
26bdb0ca
...
...
@@ -119,14 +119,6 @@
[
self
.
tableView
deselectRowAtIndexPath
:
indexPath
animated
:
NO
];
}
-
(
void
)
alertView
:(
UIAlertView
*
)
alertView
clickedButtonAtIndex
:(
NSInteger
)
buttonIndex
{
if
(
buttonIndex
==
1
)
[
_oneDriveController
downloadObject
:
_selectedFile
];
_selectedFile
=
nil
;
}
#pragma mark - login dialog
-
(
void
)
loginAction
:(
id
)
sender
...
...
@@ -147,6 +139,7 @@
#pragma mark - cell delegation
#if TARGET_OS_IOS
-
(
void
)
triggerDownloadForCell
:(
VLCCloudStorageTableViewCell
*
)
cell
{
NSIndexPath
*
indexPath
=
[
self
.
tableView
indexPathForCell
:
cell
];
...
...
@@ -170,4 +163,13 @@
}
}
-
(
void
)
alertView
:(
UIAlertView
*
)
alertView
clickedButtonAtIndex
:(
NSInteger
)
buttonIndex
{
if
(
buttonIndex
==
1
)
[
_oneDriveController
downloadObject
:
_selectedFile
];
_selectedFile
=
nil
;
}
#endif
@end
VLC for Apple TV/VLCCloudServicesTVViewController.h
View file @
26bdb0ca
...
...
@@ -14,5 +14,6 @@
@interface
VLCCloudServicesTVViewController
:
UIViewController
-
(
IBAction
)
dropbox
:(
id
)
sender
;
-
(
IBAction
)
onedrive
:(
id
)
sender
;
@end
VLC for Apple TV/VLCCloudServicesTVViewController.m
View file @
26bdb0ca
...
...
@@ -15,10 +15,13 @@
#import "VLCDropboxTableViewController.h"
#import "SSKeychain.h"
#import "VLCPlayerDisplayController.h"
#import "VLCOneDriveTableViewController.h"
@interface
VLCCloudServicesTVViewController
()
@property
(
nonatomic
)
VLCDropboxTableViewController
*
dropboxTableViewController
;
@property
(
nonatomic
)
VLCOneDriveTableViewController
*
oneDriveTableViewController
;
@end
@implementation
VLCCloudServicesTVViewController
...
...
@@ -27,6 +30,7 @@
[
super
viewDidLoad
];
self
.
dropboxTableViewController
=
[[
VLCDropboxTableViewController
alloc
]
initWithNibName
:
@"VLCCloudStorageTableViewController"
bundle
:
nil
];
self
.
oneDriveTableViewController
=
[[
VLCOneDriveTableViewController
alloc
]
initWithNibName
:
@"VLCCloudStorageTableViewController"
bundle
:
nil
];
}
-
(
NSString
*
)
title
...
...
@@ -60,4 +64,9 @@
[
self
presentViewController
:
alert
animated
:
YES
completion
:
nil
];
}
-
(
void
)
onedrive
:(
id
)
sender
{
[
self
showDetailViewController
:
self
.
oneDriveTableViewController
sender
:
self
];
}
@end
VLC for Apple TV/VLCCloudServicesTVViewController.xib
View file @
26bdb0ca
<?xml version="1.0" encoding="UTF-8" standalone="no"?>
<document
type=
"com.apple.InterfaceBuilder.AppleTV.XIB"
version=
"3.0"
toolsVersion=
"905
8"
systemVersion=
"15A284
"
targetRuntime=
"AppleTV"
propertyAccessControl=
"none"
useAutolayout=
"YES"
>
<document
type=
"com.apple.InterfaceBuilder.AppleTV.XIB"
version=
"3.0"
toolsVersion=
"905
9"
systemVersion=
"15B42
"
targetRuntime=
"AppleTV"
propertyAccessControl=
"none"
useAutolayout=
"YES"
>
<dependencies>
<plugIn
identifier=
"com.apple.InterfaceBuilder.IBCocoaTouchPlugin"
version=
"904
8
"
/>
<plugIn
identifier=
"com.apple.InterfaceBuilder.IBCocoaTouchPlugin"
version=
"904
9
"
/>
</dependencies>
<objects>
<placeholder
placeholderIdentifier=
"IBFilesOwner"
id=
"-1"
userLabel=
"File's Owner"
customClass=
"VLCCloudServicesTVViewController"
>
...
...
@@ -47,6 +47,9 @@
<animations/>
<inset
key=
"contentEdgeInsets"
minX=
"40"
minY=
"20"
maxX=
"40"
maxY=
"20"
/>
<state
key=
"normal"
title=
"OneDrive"
/>
<connections>
<action
selector=
"onedrive:"
destination=
"-1"
eventType=
"primaryActionTriggered"
id=
"FXo-bT-UMk"
/>
</connections>
</button>
</subviews>
<animations/>
...
...
VLC for iOS.xcodeproj/project.pbxproj
View file @
26bdb0ca
...
...
@@ -71,6 +71,7 @@
7D0C352F1BD97BC50058CD19
/* libLiveTVSDK.a in Frameworks */
=
{
isa
=
PBXBuildFile
;
fileRef
=
7D0C352E1BD97BC50058CD19
/* libLiveTVSDK.a */
;
};
7D0C35331BD97C100058CD19
/* VLCOneDriveController.m in Sources */
=
{
isa
=
PBXBuildFile
;
fileRef
=
7D1052ED1A4DCD1E00295F08
/* VLCOneDriveController.m */
;
};
7D0C35341BD97C7B0058CD19
/* VLCOneDriveObject.m in Sources */
=
{
isa
=
PBXBuildFile
;
fileRef
=
7DB847D61A5871570002DC30
/* VLCOneDriveObject.m */
;
};
7D0C35371BD97E870058CD19
/* VLCOneDriveTableViewController.m in Sources */
=
{
isa
=
PBXBuildFile
;
fileRef
=
7D1052E81A4DCC1100295F08
/* VLCOneDriveTableViewController.m */
;
};
7D1052E91A4DCC1100295F08
/* VLCOneDriveTableViewController.m in Sources */
=
{
isa
=
PBXBuildFile
;
fileRef
=
7D1052E81A4DCC1100295F08
/* VLCOneDriveTableViewController.m */
;
};
7D1052EE1A4DCD1E00295F08
/* VLCOneDriveController.m in Sources */
=
{
isa
=
PBXBuildFile
;
fileRef
=
7D1052ED1A4DCD1E00295F08
/* VLCOneDriveController.m */
;
};
7D1276621AADA0E600F0260C
/* VLCMultiSelectionMenuView.m in Sources */
=
{
isa
=
PBXBuildFile
;
fileRef
=
7D1276611AADA0E600F0260C
/* VLCMultiSelectionMenuView.m */
;
};
...
...
@@ -2492,6 +2493,7 @@
isa
=
PBXSourcesBuildPhase
;
buildActionMask
=
2147483647
;
files
=
(
7D0C35371BD97E870058CD19
/* VLCOneDriveTableViewController.m in Sources */
,
7DEC8C1F1BD6A113006E1093
/* UIDevice+VLC.m in Sources */
,
7D0C34E71BD951080058CD19
/* NSString+SupportedMedia.m in Sources */
,
7DC71D211BC83058001FACAA
/* VLCAppSharesTVViewController.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