0

How could i inflate my custom view using the main.xml file? I thought it carried the format of

<com.blah.project.MainClass.innerClass /> 

but I cant seem to get the fully qualified name of my inner class right. My customView is inside of my Main.java file, anyone know how I could properly reference it? Thank you.

Quintin Robinson
  • 81,193
  • 14
  • 123
  • 132
jfisk
  • 6,125
  • 20
  • 77
  • 113

2 Answers2

0

try <view class="com.blah.project.MainClass$innerClass" ... /> or separate the view class.

Andy Lin
  • 545
  • 2
  • 4
0

it is , but what i was missing is that in order for it to be inflated, the view must be declared static.

jfisk
  • 6,125
  • 20
  • 77
  • 113