Open ofTheo opened 12 months ago
what about simulator support? it would facilitate a refactor of the examples.
in https://github.com/openframeworks/openFrameworks/issues/6966#issuecomment-1324265560 @danoli3 says "Designed for iPad works" but on M1 (13.4) I get this error (both with 0.12 and git-master):
[edit to change image // copy-paste mistake sorry -- previously pasted the simulator error]
Oh yes - @artificiel that's a separate known issue. I think will get fixed with @danoli3's changes. I think currently the only way to use the simulator is launching Xcode in Rosetta mode.
This issue was just for updating the examples.
ah yes sorry for not being clearer — I meant that having the simulator working would facilite this task, suggesting a form of priority, and reported that the work-around does not seem to be working.
NB I get the same error with a simulator build through rosetta on M1, launched with:
arch -x86_64 /Applications/Xcode.app/Contents/MacOS/Xcode
Make sure on latest Xcode for Rosetta stuff: it should look like this
hmmm a bit more digging and I realize starting in x64 gives the "double amount" of entries for simulators... but no mention of rosetta. however trying the "the other one" for a given pair does compile and run!
I don't know if I missed did some extra step but I don't see the same things as you do:
@artificiel Rosetta would just mean x86_64 which you can see at the top in the menu bar, so I think that is what he meant.
@ofTheo yes, I just wanted to state the Xcode GUI behaviour I have is not the same — in @danoli3 's screenshot the entries are marked Rosetta, which makes them clear to choose from. Here my entries are not marked, which makes it a trial-and-error thing to somehow "discover" there are rosetta ones.
so someone trying to use the simulator might not get @danoli3's described behaviour, and I wonder why the behaviour is different. but maybe it's moot as the proper simulator will soon be fixed?
@artificiel
@ofTheo yes, I just wanted to state the Xcode GUI behaviour I have is not the same — in @danoli3 's screenshot the entries are marked Rosetta, which makes them clear to choose from. Here my entries are not marked, which makes it a trial-and-error thing to somehow "discover" there are rosetta ones.
You can find rosetta from Product > Destination > Destination Architectures > Show Rosetta Destinations
@ofTheo I try to update iPhoneGuiExample using storyboard not nib.
UIStoryboard *storyboard = [UIStoryboard storyboardWithName:@"MyGuiView" bundle:nil]; myGuiViewController = [storyboard instantiateViewControllerWithIdentifier:@"MyGuiView"];
I'm currently trying to use iOS examples, but some of them are not working. UIActionSheet does not work in iosOrientationExample. So, I modified the example and used UIAlertController instead of UIActionSheet. This means we no longer use the UIActionSheet delegate. How about changing the file name? Naturally, we should update the interface name as well.
I will also make modifications to other iOS examples as much as I can.
Amazing @azuremous !!
I would say all the iOS examples are completely open to being changed / rewritten to be brought up to date. So definitely do what makes the most sense to you.
Happy if you want to do per example Pull Requests or larger PRs for multiple examples, whatever works best for you.
Thanks so much! Great to get some energy on this!!
Some of the old native UI examples didn't work anymore so they were removed for 0.12.0 It would be great to do an audit of current examples and see what works, what doesn't and what is missing.
Needed: