zoukankan      html  css  js  c++  java
  • OC--初始化UINavigationController

    - (BOOL)application:(UIApplication *)application didFinishLaunchingWithOptions:(NSDictionary *)launchOptions

    {

      // create a navigation controller and perform some simple styling

      self.navigationController = [UINavigationController new];

      self.navigationController.navigationBar.barTintColor = [UIColor darkGrayColor];

      [self.navigationController.navigationBar setTitleTextAttributes:@{NSForegroundColorAttributeName : [UIColor whiteColor]}];

      

      // create and navigate to a view controller

      UIViewController *viewController = [self createInitialViewController];

      [self.navigationController pushViewController:viewController animated:NO];

      // show the navigation controller

      self.window = [[UIWindow alloc] initWithFrame:[[UIScreen mainScreen] bounds]];

      self.window.rootViewController = self.navigationController;

      [self.window makeKeyAndVisible];

      return YES;

    }

    - (UIViewController *)createInitialViewController {

      self.viewModelServices = [[RWTViewModelServicesImpl alloc] initWithNavigationController:self.navigationController];

      self.viewModel = [[RWTFlickrSearchViewModel alloc]

                        initWithServices:self.viewModelServices];

      return [[RWTFlickrSearchViewController alloc]

              initWithViewModel:self.viewModel];

    }

  • 相关阅读:
    selenium-java,定位并操作frame和iframe内的元素
    多线程-java
    Mysql基础
    webpack文件处理
    webpack调试必备配置之SourceMap介绍
    webpack提取分离css单独打包
    webpack编译less和sass
    webpack中loader在处理HTML中引入图片
    webpack用loader加载css
    使用配置文件webpack.config.js打包文件
  • 原文地址:https://www.cnblogs.com/SimonGao/p/4882192.html
Copyright © 2011-2022 走看看