|
|
|
|
@ -87,6 +87,14 @@ class KeyboardActionView(context: Context) : AbstractKeyboardView(context), |
|
|
|
|
} |
|
|
|
|
|
|
|
|
|
fun setAvailableActions(availableActions: Set<Action.Type>) { |
|
|
|
|
|
|
|
|
|
val displayedTypes = Action.Type.defaultTypes |
|
|
|
|
availableActions.forEach { |
|
|
|
|
if (!displayedTypes.contains(it)) { |
|
|
|
|
throw PAIllegalStateException("Displayed actions does not contain $it, can't be shown") |
|
|
|
|
} |
|
|
|
|
} |
|
|
|
|
|
|
|
|
|
this.availableActions = availableActions |
|
|
|
|
this.dataAdapter.notifyDataSetChanged() |
|
|
|
|
} |
|
|
|
|
|