skip to Main Content

Ios swift – Enable/Disable Screen Capture in iOS

I am able to disable screen capture in iOS using this code Objective- C - (void)makeSecure { dispatch_async(dispatch_get_main_queue(), ^{ UITextField *field = [[UITextField alloc] init]; field.secureTextEntry = true; [self addSubview:field]; [[field.centerYAnchor constraintEqualToAnchor:self.centerYAnchor] setActive:YES]; [[field.centerXAnchor constraintEqualToAnchor:self.centerXAnchor] setActive:YES]; [self.layer.superlayer addSublayer:field.layer]; [field.layer.sublayers.firstObject addSublayer:self.layer];…

VIEW QUESTION
Back To Top
Search