Status Update
Comments
uc...@google.com <uc...@google.com>
xa...@google.com <xa...@google.com> #2
I'm guessing the light classes created for data-binding don't go look into these folders.
ma...@thisisaim.com <ma...@thisisaim.com> #4
Awesome. Thanks for addressing this, looking forward to the patch.
da...@google.com <da...@google.com> #5
Thanks for being so understanding. I've added this bug to a list of bugs I'll try to ping when 3.6.2 goes out.
da...@google.com <da...@google.com> #6
3.6.2 patch is out. Hopefully you'll find with latest that your issue is fixed. Please let me know if you're still seeing this problem. Thanks!
ma...@thisisaim.com <ma...@thisisaim.com> #7
Looks to have done the trick. Many thanks
Description
sourceSets {
main {
res.srcDirs += [
'src/main/res/layout/activity',
'src/main/res/layout/fragment',
'src/main/res/layout/adapter',
'src/main/res/layout/view'
]
}
}
When the layout files are moved outside of these directories and into the root "res/layout" directory the binding classes are resolved again.
Studio Build: 3.6
Version of Gradle Plugin: 3.6.0
Version of Gradle: 5.6.4
Version of Java: 1.8
OS: Windows 10
Steps to Reproduce:
1. Specify custom resource directories i.e src/main/res/layout/activity as shown above
2. Add data binding layout "foo_bar.xml" to resource directory "src/main/res/layout/activity/layout/"
3. Rebuild project
4. Note FooBarBinding cannot be resolved within IDE, however the app will build successfully and run.