title: Kotlin unresolved reference : inflate
body: <p>i was learning how to make recycler view in kotlin, and given code like this for my adapter</p>
  <pre><code>override fun onCreateViewHolder(parent: ViewGroup, viewType: Int): RecyclerView.ViewHolder {
          return when (viewType) {
              ITEM_HEADER -&gt; MenuHeaderHolder(parent.inflate(R.layout.item_header))
              ITEM_MENU -&gt; MenuItemHolder(parent.inflate(R.layout.item_menu))
              else -&gt; throw throw IllegalArgumentException(&quot;Undefined view type&quot;)
          }
      }
  </code></pre>
  <p>and my Class MenuHeaderHolder</p>
  <pre><code>class MenuHeaderHolder(itemView: View) : RecyclerView.ViewHolder(itemView) {
      private val itemHeader = itemView.findViewById(R.id.tvHeaderItem) as TextView
  
      fun bindContent(text: String){
          itemHeader.text = text
      }
  }
  </code></pre>
  <p>but i get error unresolved reference : inflate, how fox this ?</p>