|
|
|
|
@ -68,6 +68,8 @@ class EditorFragment : RealmFragment(), RowRepresentableDelegate, KeyboardListen |
|
|
|
|
return this.model.isEdited |
|
|
|
|
} |
|
|
|
|
|
|
|
|
|
private var isKeyboardShown: Boolean = false |
|
|
|
|
|
|
|
|
|
private var _binding: FragmentHandHistoryBinding? = null |
|
|
|
|
private val binding get() = _binding!! |
|
|
|
|
|
|
|
|
|
@ -467,7 +469,7 @@ class EditorFragment : RealmFragment(), RowRepresentableDelegate, KeyboardListen |
|
|
|
|
} |
|
|
|
|
HandRowType.PLAYER_POSITION -> { |
|
|
|
|
this.model.createPlayerSetupForPosition(value as Position) |
|
|
|
|
this.editorAdapter.notifyDataSetChanged() |
|
|
|
|
// this.editorAdapter.notifyDataSetChanged() |
|
|
|
|
} |
|
|
|
|
is ComputedAction -> { |
|
|
|
|
this.model.amountChanged(value as String) |
|
|
|
|
@ -638,6 +640,10 @@ class EditorFragment : RealmFragment(), RowRepresentableDelegate, KeyboardListen |
|
|
|
|
*/ |
|
|
|
|
private fun animateKeyboard(show: Boolean, endHandler: (() -> (Unit))? = null) { |
|
|
|
|
|
|
|
|
|
if (show == this.isKeyboardShown) { |
|
|
|
|
return |
|
|
|
|
} |
|
|
|
|
|
|
|
|
|
val height = 310.0f.px |
|
|
|
|
val start = if (show) 0.0f else height |
|
|
|
|
val end = if (show) height else 0.0f |
|
|
|
|
@ -656,6 +662,7 @@ class EditorFragment : RealmFragment(), RowRepresentableDelegate, KeyboardListen |
|
|
|
|
this.binding.kbTopGuideline.layoutParams = lp |
|
|
|
|
|
|
|
|
|
if (lp.guideEnd == end.toInt()) { |
|
|
|
|
this.isKeyboardShown = show |
|
|
|
|
endHandler?.invoke() |
|
|
|
|
} |
|
|
|
|
|
|
|
|
|
|