|
|
@ -24,7 +24,7 @@ private tailrec fun getCompatActivity(context: Context?): AppCompatActivity? { |
|
|
|
val View.activity: AppCompatActivity? |
|
|
|
val View.activity: AppCompatActivity? |
|
|
|
get() = getCompatActivity(context) |
|
|
|
get() = getCompatActivity(context) |
|
|
|
|
|
|
|
|
|
|
|
inline fun View.hideSoftInput() = run { |
|
|
|
fun View.hideSoftInput() = run { |
|
|
|
val imm = App.INSTANCE.getSystemService(Context.INPUT_METHOD_SERVICE) as? InputMethodManager |
|
|
|
val imm = App.INSTANCE.getSystemService(Context.INPUT_METHOD_SERVICE) as? InputMethodManager |
|
|
|
imm?.let { |
|
|
|
imm?.let { |
|
|
|
imm.hideSoftInputFromWindow(this.windowToken, 0) |
|
|
|
imm.hideSoftInputFromWindow(this.windowToken, 0) |
|
|
|