3 #import <Foundation/Foundation.h>
4 #import <UIKit/UIKit.h>
8 extern bool IsWildcat_;
10 @implementation UIViewController (Cydia)
18 @implementation CYViewController
20 - (void) setDelegate:(id)delegate {
28 - (void) viewWillAppear:(BOOL)animated {
29 [super viewWillAppear:animated];
31 // Load on first appearance. We don't need to set the loaded flag here
32 // because it is set for us the first time -reloadData is called.
33 if (![self hasLoaded])
41 - (void) releaseSubviews {
45 - (void) setView:(UIView *)view {
46 // Nasty hack for 2.x-compatibility. In 3.0+, we can and
47 // should just override -viewDidUnload instead.
49 [self releaseSubviews];
55 // This is called automatically on the first appearance of a controller,
56 // or any other time it needs to reload the information shown. However (!),
57 // this is not called by any tab bar or navigation controller's -reloadData
58 // method unless this controller returns YES from -hadLoaded.
62 - (NSURL *) navigationURL {
66 - (BOOL) shouldAutorotateToInterfaceOrientation:(UIInterfaceOrientation)orientation {
67 return IsWildcat_ || orientation == UIInterfaceOrientationPortrait;