zoukankan      html  css  js  c++  java
  • 在iOS上present一个半透明的viewController

    UIViewController *viewController = [[UIViewController alloc]init];
    UIViewController* controller = self.view.window.rootViewController;
    viewController.view.backgroundColor
    = [UIColor blackColor]; viewController.view.alpha = 0.5f; controller.modalPresentationStyle = UIModalPresentationCurrentContext; [controller presentViewController:viewController animated:NO completion:nil];

    UIViewController 页面

    UITapGestureRecognizer *tapGesture = [[UITapGestureRecognizer alloc]initWithTarget:self action:@selector(tapGesture:)];

    [self.view addGestureRecognizer:tapGesture];

     

    - (void)tapGesture:(UITapGestureRecognizer *)gesture

    {

        [self dismissViewControllerAnimated:YES completion:nil];

    }

     
  • 相关阅读:
    监控Nginx
    监控Tomcat
    监控memcache
    监控Redis
    14-SpringCloud Bus
    13-SpringCloud Config
    12-SpringCloud GateWay
    11-SpringCloud Hystrix
    10-SpringCloud OpenFeign
    09-SpringCloud Ribbon
  • 原文地址:https://www.cnblogs.com/joesen/p/4062533.html
Copyright © 2011-2022 走看看