ios - Setting UISwitch state in UIPopoverController -
i reset state of uiswitch in uipopovercontroller mainviewcontroller. assume simple
popoverview.switchname.on = no;
wont job (as doesnt seem working). whats best way this? thank you.
the uipopovercontroller container content view controller shown inside frame. assume @ point calling initwithcontentviewcontroller view controller presents content , view controller has switchname property.
to access view controller can use contentviewcontroller property of uipopovercontroller. imagine like:
// assuming popoverview uipopovercontroller , type of // view contorller pass initwithcontentviewcontroller yourviewcontroller yourviewcontroller * mycontroller = (yourviewcontroller*)popoverview.contentviewcontroller; mycontroller.switchname.on = no;
Comments
Post a Comment