android (android)

Contains common Android functions

Constants

Intent : map =

14 elements
{
  ACTION_BOOT_COMPLETED=android.intent.action.BOOT_COMPLETED,
  ACTION_DEFAULT=android.intent.action.VIEW,
  ACTION_DELETE=android.intent.action.DELETE,
  ACTION_EDIT=android.intent.action.EDIT,
  ACTION_INSTALL_PACKAGE=android.intent.action.INSTALL_PACKAGE,
  ACTION_LOCATION_SOURCE_SETTINGS=android.settings.LOCATION_SOURCE_SETTINGS,
  ACTION_MAIN=android.intent.action.MAIN,
  ACTION_MEDIA_MOUNTED=android.intent.action.MEDIA_MOUNTED,
  ACTION_REBOOT=android.intent.action.REBOOT,
  ACTION_RUN=android.intent.action.RUN,
  ACTION_SEARCH=android.intent.action.SEARCH,
  ACTION_SEND=android.intent.action.SEND,
  ACTION_VIEW=android.intent.action.VIEW,
  ACTION_WEB_SEARCH=android.intent.action.WEB_SEARCH
}

R : map =

8 elements
{
  array={},
  attr={},
  color={},
  drawable={},
  id={},
  integer={},
  layout={},
  string={}
}

Resource constants from android.R.xxx class

SDK_INT : number = Android version SDK

Android version SDK

Span : map =

8 elements
{
  COLOR=0,
  ABSOLUTE_SIZE=1,
  RELATIVE_SIZE=2,
  URL=3,
  STYLE=4,
  CLICKABLE=5,
  TYPEFACE=6,
  HTML=7
}

Functions

assetBitmap(path) — loads bitmap from the file in apk's assets folder

assetBytes(path) — reads bytes of the file in apk's assets folder

assetText(path) — reads text content of the file in apk's assets folder

chooser()

listAssets(path) — returns list of files in apk's assets folder

spannable(type, text, ...)

startActivity(intent, uri = "", bundle = []) — starts an activity

toast(text, duration = 0) — shows toast notification

uithread(function, ...) — runs function in main UI-thread