brackeen / glfm

OpenGL ES and input for iOS, tvOS, Android, and WebGL
zlib License
570 stars 77 forks source link

Feature request: split up glfm_platform_ios.c #1

Open alexhunsley opened 7 years ago

alexhunsley commented 7 years ago

This file contains GLFMAppDelegate and GLFMViewController, amongst other things. Having this all in one files makes it harder to navigate to one of these things (e.g. in AppCode "quick open" then typing GLFMAppDelegate doesn't work).

It also makes tracking source control changes to one of these classes more tricky (e.g. I can't easily just see changes to GLFMViewController).

brackeen commented 7 years ago

The file will get split up at some point (trying to be more like GLFW) but not anytime soon. It's not too complicated of a file at the moment (less than 900 lines). I'll leave the issue open, but it's not a high priority.

Which IDE are you using? Quick open works in Xcode. Does your IDE pick up the #pragma mark lines?

alexhunsley commented 7 years ago

I'm mainly using AppCode, where the quick open shortcut doesn't pick up on a class inside a file with a non-matching name. AppCode does parse #pragma marks though.

willbamford commented 6 years ago

I'm also interested in getting this to work with React Native. So, use RN for the general UI but GLFM for OpenGL visualisations. In this case I wouldn't want GLFM to create and manage AppDelegate but would instead want to use GLFMViewController. It feels like splitting out the functionality into different files would be a step towards allowing this perhaps?

brackeen commented 6 years ago

@WebSeed - That's doable, I created issue #11 for that. I believe this is currently possible in the Android version (starting a GLFM-based Activity from another Activity) but have not tested.