ZYShareView icon indicating copy to clipboard operation
ZYShareView copied to clipboard

iOS13下会出现第一次无法点击按钮问题

Open kangyeting opened this issue 5 years ago • 0 comments

  • (void)addToKeyWindow { if (!self.superview) { UIWindow *keyWindow = [UIApplication sharedApplication].keyWindow; [keyWindow addSubview:self];

    } }

  • (void)commonInit { [self addSubview:self.dimBackgroundView]; [self addSubview:self.shareSheetView];

    self.frame = CGRectMake(0, 0, ZY_ScreenWidth, ZY_ScreenHeight);

    [[NSNotificationCenter defaultCenter] addObserver:self selector:@selector(hide) name:ZY_HideNotification object:nil]; }

是把 [self addSubview:self.dimBackgroundView]; [self addSubview:self.shareSheetView]; 俩行代码 , 挪到了 commonInit 里面就可以了

kangyeting avatar Feb 19 '20 04:02 kangyeting