UIHelper

object UIHelper

Properties

Link copied to clipboard
Link copied to clipboard

Functions

Link copied to clipboard
fun adjustAlpha(@ColorInt color: Int, factor: Float): Int
Link copied to clipboard
Link copied to clipboard
Link copied to clipboard
Link copied to clipboard
Link copied to clipboard
fun createPaletteAsync(url: String, bitmap: Bitmap, callback: (Palette) -> Unit)
Link copied to clipboard
Link copied to clipboard
Link copied to clipboard
Link copied to clipboard
Link copied to clipboard
Link copied to clipboard
fun Context.getResourceColor(@AttrRes resource: Int, alphaFactor: Float = 1.0f): Int
Link copied to clipboard
Link copied to clipboard
Link copied to clipboard
Link copied to clipboard
fun hideKeyboard(view: View?)
Link copied to clipboard
Link copied to clipboard
Link copied to clipboard
Link copied to clipboard
fun Activity?.navigate(@IdRes navigation: Int, arguments: Bundle? = null)
Link copied to clipboard
Link copied to clipboard
fun populateChips(view: ChipGroup?, tags: List<String>, @StyleRes style: Int = R.style.ChipFilled)
Link copied to clipboard
fun View.popupMenuNoIcons(items: List<Pair<Int, Int>>, onMenuItemClick: MenuItem.() -> Unit): PopupMenu

id, stringRes

Link copied to clipboard
fun View.popupMenuNoIconsAndNoStringRes(items: List<Pair<Int, String>>, onMenuItemClick: MenuItem.() -> Unit): PopupMenu

id, string

Link copied to clipboard
Link copied to clipboard
fun ImageView?.setImage(uiImage: UiImage?, @DrawableRes errorImageDrawable: Int? = null, fadeIn: Boolean = true, radius: Int = 0, sample: Int = 3, colorCallback: (Palette) -> Unit? = null): Boolean
fun ImageView?.setImage(url: String?, headers: Map<String, String>? = null, @DrawableRes errorImageDrawable: Int? = null, fadeIn: Boolean = true, radius: Int = 0, sample: Int = 3, colorCallback: (Palette) -> Unit? = null): Boolean
Link copied to clipboard
fun ImageView?.setImageBlur(url: String?, radius: Int, sample: Int = 3, headers: Map<String, String>? = null)
Link copied to clipboard

Sets ListView height dynamically based on the height of the items.

Link copied to clipboard
Link copied to clipboard
fun showInputMethod(view: View?)
Link copied to clipboard