public override bool FinishedLaunching(UIApplication application, NSDictionary launchOptions) { // create a new window instance based on the screen size Window = new UIWindow(UIScreen.MainScreen.Bounds); var searchController = new SearchController(); var searchNavController = new UINavigationController(searchController); var topRatedController = new TopRatedListController(); var topNavController = new UINavigationController(topRatedController); var tabBarController = new TabBarController() { ViewControllers = new UIViewController[] { searchNavController, topNavController } }; Window.RootViewController = tabBarController; // make the window visible Window.MakeKeyAndVisible(); return(true); }
public override bool FinishedLaunching(UIApplication application, NSDictionary launchOptions) { // Override point for customization after application launch. // If not required for your application you can safely delete this method this.Window = new UIWindow(UIScreen.MainScreen.Bounds); var movieapi = new MovieApi(); var imageDownloader = new ImageDownloader(new StorageClient()); var searchController = new MovieSearchController(movieapi, imageDownloader); var topRatedController = new TopRatedController(movieapi, imageDownloader); var searchControllerNavigation = new UINavigationController(searchController); var topRatedControllerNavigation = new UINavigationController(topRatedController); var taBar = new TabBarController() { ViewControllers = new UIViewController[] { searchControllerNavigation, topRatedControllerNavigation } }; this.Window.RootViewController = taBar; this.Window.MakeKeyAndVisible(); return(true); }
public override bool FinishedLaunching(UIApplication application, NSDictionary launchOptions) { this.Window = new UIWindow(UIScreen.MainScreen.Bounds); var movies = new FilmCollection(); MovieDbFactory.RegisterSettings(movies); var movieController = new ViewController(movies._movies); var movieNavigationController = new UINavigationController(movieController); var topRatedController = new TopRatedMovieController(movies._movies); var topRatedNavigationController = new UINavigationController(topRatedController); var tabBarController = new TabBarController() { ViewControllers = new UINavigationController[] { movieNavigationController, topRatedNavigationController } }; this.Window.RootViewController = tabBarController; this.Window.MakeKeyAndVisible(); return(true); }
public override bool FinishedLaunching(UIApplication application, NSDictionary launchOptions) { // Override point for customization after application launch. // If not required for your application you can safely delete this method this.Window = new UIWindow(UIScreen.MainScreen.Bounds); var storageClient = new StorageClient(); var imageDownloader = new ImageDownloader(storageClient); var movieSearchController = new MovieSearchController(new MovieService(), imageDownloader); var movieTopListController = new MovieTopListController(new MovieService(), imageDownloader); var navSearchController = new UINavigationController(movieSearchController); var navTopListController = new UINavigationController(movieTopListController); var tabBarController = new TabBarController() { ViewControllers = new UIViewController[] { navSearchController, navTopListController } }; this.Window.RootViewController = tabBarController; //this.Window.RootViewController = new UINavigationController(movieSearchController); this.Window.MakeKeyAndVisible(); return(true); }
public override bool FinishedLaunching(UIApplication application, NSDictionary launchOptions) { this._searchMoviesHelper = new MovieHelper(); this._topRatedMoviesHelper = new MovieHelper(); // Override point for customization after application launch. // If not required for your application you can safely delete this method this.Window = new UIWindow(UIScreen.MainScreen.Bounds); var movieController = new MovieController(this._searchMoviesHelper); var movieNavigationController = new UINavigationController(movieController); var topRatedMovieController = new TopRatedMovieController(this._topRatedMoviesHelper); var topRatedMovieNavigationController = new UINavigationController(topRatedMovieController); var tabBarController = new TabBarController() { ViewControllers = new UIViewController[] { movieNavigationController, topRatedMovieNavigationController } }; this.Window.RootViewController = tabBarController; this.Window.MakeKeyAndVisible(); return(true); }