Skip to content
GitLab
Menu
Projects
Groups
Snippets
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Sign in / Register
Toggle navigation
Menu
Open sidebar
VideoLAN
VLC-iOS
Commits
244ac26b
Commit
244ac26b
authored
Dec 09, 2015
by
Felix Paul Kühne
Browse files
iOS ONS: micro-optimization
parent
2d782c46
Changes
1
Hide whitespace changes
Inline
Side-by-side
Sources/VLCOpenNetworkStreamViewController.m
View file @
244ac26b
...
...
@@ -169,12 +169,13 @@
{
if
([
self
.
urlField
.
text
length
]
>
0
)
{
if
(
!
self
.
privateToggleSwitch
.
on
)
{
if
([
_recentURLs
indexOfObject
:
self
.
urlField
.
text
]
!=
NSNotFound
)
[
_recentURLs
removeObject
:
self
.
urlField
.
text
];
NSString
*
urlString
=
self
.
urlField
.
text
;
if
([
_recentURLs
indexOfObject
:
urlString
]
!=
NSNotFound
)
[
_recentURLs
removeObject
:
urlString
];
if
(
_recentURLs
.
count
>=
100
)
[
_recentURLs
removeLastObject
];
[
_recentURLs
addObject
:
self
.
urlField
.
text
];
[
_recentURLs
addObject
:
urlString
];
[[
NSUbiquitousKeyValueStore
defaultStore
]
setArray
:
_recentURLs
forKey
:
kVLCRecentURLs
];
[
self
.
historyTableView
reloadData
];
...
...
Write
Preview
Supports
Markdown
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