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
c81187a1
Commit
c81187a1
authored
May 26, 2013
by
Gleb Pinigin
Browse files
About code simplification: create view controller if needed
parent
6f066a02
Changes
4
Hide whitespace changes
Inline
Side-by-side
AspenProject/VLCAboutViewController.m
View file @
c81187a1
...
...
@@ -35,15 +35,12 @@
-
(
void
)
viewWillAppear
:(
BOOL
)
animated
{
[
self
.
navigationController
setNavigationBarHidden
:
YES
animated
:
NO
];
if
(
UI_USER_INTERFACE_IDIOM
()
==
UIUserInterfaceIdiomPhone
)
[
UIApplication
sharedApplication
].
statusBarStyle
=
UIStatusBarStyleBlackTranslucent
;
[
super
viewWillAppear
:
animated
];
}
-
(
void
)
viewWillDisappear
:(
BOOL
)
animated
{
[
self
.
navigationController
setNavigationBarHidden
:
NO
animated
:
YES
];
[
UIApplication
sharedApplication
].
statusBarStyle
=
UIStatusBarStyleBlackOpaque
;
[
super
viewWillDisappear
:
animated
];
}
...
...
AspenProject/VLCAddMediaViewController.m
View file @
c81187a1
...
...
@@ -102,10 +102,8 @@
-
(
IBAction
)
openAboutPanel
:(
id
)
sender
{
VLCAppDelegate
*
appDelegate
=
[
UIApplication
sharedApplication
].
delegate
;
if
(
!
appDelegate
.
playlistViewController
.
aboutViewController
)
appDelegate
.
playlistViewController
.
aboutViewController
=
[[
VLCAboutViewController
alloc
]
initWithNibName
:
@"VLCAboutViewController"
bundle
:
nil
];
[
appDelegate
.
playlistViewController
.
navigationController
pushViewController
:
appDelegate
.
playlistViewController
.
aboutViewController
animated
:
YES
];
UIViewController
*
aboutController
=
[[
VLCAboutViewController
alloc
]
initWithNibName
:
@"VLCAboutViewController"
bundle
:
nil
];
[
appDelegate
.
playlistViewController
.
navigationController
pushViewController
:
aboutController
animated
:
YES
];
[
self
_hideAnimated
:
NO
];
}
...
...
AspenProject/VLCPlaylistViewController.h
View file @
c81187a1
...
...
@@ -10,7 +10,6 @@
#import "AQGridView.h"
@class
VLCMovieViewController
;
@class
VLCAboutViewController
;
@class
VLCAddMediaViewController
;
@interface
VLCPlaylistViewController
:
UIViewController
<
AQGridViewDataSource
,
AQGridViewDelegate
,
UITableViewDataSource
,
UITableViewDelegate
,
UITabBarDelegate
,
UIPopoverControllerDelegate
>
...
...
@@ -19,9 +18,7 @@
}
@property
(
nonatomic
,
strong
)
VLCMovieViewController
*
movieViewController
;
@property
(
nonatomic
,
strong
)
VLCAboutViewController
*
aboutViewController
;
@property
(
nonatomic
,
strong
)
VLCAddMediaViewController
*
addMediaViewController
;
@property
(
nonatomic
,
strong
)
UIPopoverController
*
addMediaPopoverController
;
@property
(
nonatomic
,
strong
)
IBOutlet
UITableView
*
tableView
;
...
...
AspenProject/VLCPlaylistViewController.m
View file @
c81187a1
...
...
@@ -10,7 +10,6 @@
#import "VLCMovieViewController.h"
#import "VLCPlaylistTableViewCell.h"
#import "VLCPlaylistGridView.h"
#import "VLCAboutViewController.h"
#import "VLCAddMediaViewController.h"
@interface
VLCPlaylistViewController
()
{
...
...
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