Question
Native Extension iOS UIButton, A way to attach to the screen
Native Extension iOS UIButton, A way to attach to the screen
Crash is on the iPhone.
FREObject AddButton (FREContext ctx, void * funcData, uint32_t argc, FREObject argv [])
{
UIWindow *window = [[UIApplication sharedApplication] keyWindow];
button = [UIButton buttonWithType:UIButtonTypeRoundedRect];
[button setTitle:@"iOS TestButton" forState:UIControlStateNormal];
button.frame = CGRectMake(150, 150, 106, 53);
[window addSubview:button];
return NULL;
}
