title: Why I Cannot Access to this function?
body: <p>I've been past this example of watchface from java to kotlin, but I suddenly notice that I can not access three functions. (I only mention one because the error is the same "unresolved reference")</p>
  
  <p>I do not understand why I can not access them, I have changed the access modifiers I have extended one class to another but I can not access those functions</p>
  
  <p>I will appreciate your valuable comments</p>
  
  <p>class ComplicationConfigActivity : WearableActivity(), View.OnClickListener {</p>
  
  <pre><code>private val TAG = "Configuration Activity"
  
  internal val COMPLICATION_CONFIG_REQUEST_CODE = 1001 // internal val COMPLICATION_CONFIG_REQUEST_CODE = 1001
  
  
  enum class ComplicationLocation {
      LEFT,
      RIGHT,
      TOP,
      BOTTOM
  }//---
  
  private var mLeftComplicationId: Int = 0
  private var mRightComplicationId: Int = 0
  //---
  private var mTopComplicationId: Int = 0
  private var mBottomComplicationId: Int = 0
  //---
  
  
  
  override fun onCreate(savedInstanceState: Bundle?) {
      super.onCreate(savedInstanceState)
      setContentView(R.layout.activity_complication_config)
  
      setContentView(R.layout.activity_complication_config)
      mDefaultAddComplicationDrawable = getDrawable(R.drawable.add_complication)
  
      mSelectedComplicationId = -1
  
      mLeftComplicationId = MyWatchFace.getComplicationId(ComplicationLocation.LEFT) // unresolved reference
      mRightComplicationId = MyWatchFace.getComplicationId(ComplicationLocation.RIGHT) // getComplicationId
      mTopComplicationId = MyWatchFace.getComplicationId(ComplicationLocation.TOP)
      mBottomComplicationId = MyWatchFace.getComplicationId(ComplicationLocation.BOTTOM)
  </code></pre>
  
  <p>class MyWatchFace : CanvasWatchFaceService() {</p>
  
  <pre><code>private val TAG = "ComplicationConfigActivity"
  // TODO: Step 2, intro 1
  private val LEFT_COMPLICATION_ID = 0
  private val RIGHT_COMPLICATION_ID = 1
  private val TOP_COMPLICATION_ID = 2
  private val BOTTOM_COMPLICATION_ID = 3
  
  private val COMPLICATION_IDS =
      intArrayOf(LEFT_COMPLICATION_ID, RIGHT_COMPLICATION_ID, TOP_COMPLICATION_ID, BOTTOM_COMPLICATION_ID)
  
  // Left and right dial supported types.
  private val COMPLICATION_SUPPORTED_TYPES = arrayOf(
      intArrayOf(
          ComplicationData.TYPE_RANGED_VALUE, ComplicationData.TYPE_ICON, ComplicationData.TYPE_SHORT_TEXT,
          //ComplicationData.IMAGE_STYLE_PHOTO,//
          ComplicationData.TYPE_SMALL_IMAGE
      ), intArrayOf(
          ComplicationData.TYPE_RANGED_VALUE, ComplicationData.TYPE_ICON, ComplicationData.TYPE_SHORT_TEXT,
          //ComplicationData.IMAGE_STYLE_PHOTO,//
          ComplicationData.TYPE_SMALL_IMAGE
      ), intArrayOf(
          ComplicationData.TYPE_RANGED_VALUE, ComplicationData.TYPE_ICON, ComplicationData.TYPE_SHORT_TEXT,
          //ComplicationData.IMAGE_STYLE_PHOTO,//
          ComplicationData.TYPE_SMALL_IMAGE
      ), intArrayOf(
          ComplicationData.TYPE_RANGED_VALUE, ComplicationData.TYPE_ICON, ComplicationData.TYPE_SHORT_TEXT,
          //ComplicationData.IMAGE_STYLE_PHOTO, //
          ComplicationData.TYPE_SMALL_IMAGE
      )
  )
  
  // Used by {@link ComplicationConfigActivity} to retrieve id for complication locations and
  // to check if complication location is supported.
  // TODO: Step 3, expose complication information, part 1
  //---
  internal fun getComplicationId( // CAN´T ACCESS THIS FUNCTION
      complicationLocation: ComplicationLocation
  ): Int {
      when (complicationLocation) {
          LEFT -&gt; return LEFT_COMPLICATION_ID
          RIGHT -&gt; return RIGHT_COMPLICATION_ID
          TOP -&gt; return TOP_COMPLICATION_ID
          BOTTOM -&gt; return BOTTOM_COMPLICATION_ID
          else -&gt; return -1
      }
  }
  //----
  // Used by {@link ComplicationConfigActivity} to retrieve all complication ids.
  // TODO: Step 3, expose complication information, part 2
  //---
  internal fun getComplicationIds(): IntArray { // CAN´T ACCESS THIS FUNCTION
  
      return COMPLICATION_IDS
  }
  //---
  
  // Used by {@link ComplicationConfigActivity} to retrieve complication types supported by
  // location.
  // TODO: Step 3, expose complication information, part 3
  //---
  internal fun getSupportedComplicationTypes( // CAN´T ACCESS THIS FUNCTION
      complicationLocation: ComplicationLocation
  ): IntArray {
      when (complicationLocation) {
          LEFT -&gt; return COMPLICATION_SUPPORTED_TYPES[0]
          RIGHT -&gt; return COMPLICATION_SUPPORTED_TYPES[1]
          TOP -&gt; return COMPLICATION_SUPPORTED_TYPES[2]
          BOTTOM -&gt; return COMPLICATION_SUPPORTED_TYPES[3]
          else -&gt; return intArrayOf()
      }
  }
  //---
  
  /*
   * Update rate in milliseconds for interactive mode. We update once a second to advance the
   * second hand.
   */
  private val INTERACTIVE_UPDATE_RATE_MS = TimeUnit.SECONDS.toMillis(1)
  
  
  override fun onCreateEngine(): Engine {
      return Engine()
  }
  
  private class EngineHandler(reference: Engine) : Handler() { // 
      private val mWeakReference: WeakReference&lt;Engine&gt; = WeakReference(reference)
  
      override fun handleMessage(msg: Message) {
          val engine = mWeakReference.get()
          if (engine != null) {
              when (msg.what) {
                  MSG_UPDATE_TIME -&gt; engine.handleUpdateTimeMessage()
              }
          }
      }
  }
  
  inner class Engine : CanvasWatchFaceService.Engine() {}
  </code></pre>