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
45da7268
Commit
45da7268
authored
Aug 07, 2018
by
Soomin Lee
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
VideoModel: Format getter: Remove unnecessary parameter
parent
3f7a8e08
Changes
3
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
8 additions
and
8 deletions
+8
-8
SharedSources/MediaLibraryModel/VideoModel.swift
SharedSources/MediaLibraryModel/VideoModel.swift
+4
-4
Sources/VLCEditController.swift
Sources/VLCEditController.swift
+2
-2
Sources/VLCPlaylistCollectionViewCell.m
Sources/VLCPlaylistCollectionViewCell.m
+2
-2
No files found.
SharedSources/MediaLibraryModel/VideoModel.swift
View file @
45da7268
...
...
@@ -54,12 +54,12 @@ extension VideoModel: MediaLibraryObserver {
}
extension
VLCMLMedia
{
@objc
func
formatDuration
(
ofMedia
media
:
VLCMLMedia
)
->
String
{
return
String
(
format
:
"%@"
,
VLCTime
(
int
:
Int32
(
media
.
duration
())))
@objc
func
formatDuration
()
->
String
{
return
String
(
format
:
"%@"
,
VLCTime
(
int
:
Int32
(
duration
())))
}
@objc
func
formatSize
(
ofMedia
media
:
VLCMLMedia
)
->
String
{
return
ByteCountFormatter
.
string
(
fromByteCount
:
Int64
(
media
.
mainFile
()
.
size
()),
@objc
func
formatSize
()
->
String
{
return
ByteCountFormatter
.
string
(
fromByteCount
:
Int64
(
mainFile
()
.
size
()),
countStyle
:
.
file
)
}
}
Sources/VLCEditController.swift
View file @
45da7268
...
...
@@ -65,8 +65,8 @@ extension VLCEditController: UICollectionViewDataSource {
for
:
indexPath
)
as?
VLCMediaViewEditCell
{
if
let
media
=
category
.
anyfiles
[
indexPath
.
row
]
as?
VLCMLMedia
{
cell
.
titleLabel
.
text
=
media
.
title
cell
.
subInfoLabel
.
text
=
media
.
formatDuration
(
ofMedia
:
media
)
cell
.
sizeLabel
.
text
=
media
.
formatSize
(
ofMedia
:
media
)
cell
.
subInfoLabel
.
text
=
media
.
formatDuration
()
cell
.
sizeLabel
.
text
=
media
.
formatSize
()
}
return
cell
}
...
...
Sources/VLCPlaylistCollectionViewCell.m
View file @
45da7268
...
...
@@ -211,8 +211,8 @@
{
_titleLabel
.
text
=
_media
.
title
;
_subtitleLabel
.
text
=
[
NSString
stringWithFormat
:
@"%@ - %@"
,
[
_media
formatDuration
OfMedia
:
_media
],
[
_media
formatSize
OfMedia
:
_media
]];
[
_media
formatDuration
],
[
_media
formatSize
]];
}
-
(
void
)
_updatedDisplayedInformationForKeyPath
:(
NSString
*
)
keyPath
...
...
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