Reputation: 6200
I would like to create sub-folders in the layout folder for organization purpose. I know this was no possible in Eclipse but according to this issue is now possible with gradle build system in Android Studio:
Marking this as released. This is largely possible in the Gradle build system as it exists today, and we won't be implementing this for other build systems.
Status: Released
Cc: [email protected]
But I couldn't find anything searching on Google. I tried creating a sub-folder but I can't access it using R.layout.subfolder.my_layout.xml
. How is the way to do it?
Upvotes: 0
Views: 5895
Reputation: 80010
My answer in that bug was a little misleading. In Gradle you can't have subfolders within, say, a layout folder, but you can have multiple top-level resource folders, each of which can have layouts. It's maybe not what you really want (and not what the original bug was asking for), but it's as close as you'll be able to get for the foreseeable future, I think.
Upvotes: 3