follow code in popup keys

code will always be preferred over a|b style labels
add some tests for adjusted KeySpecParser
fixes #466
This commit is contained in:
Helium314 2024-02-01 07:22:41 +01:00
parent f19ffa54c9
commit d5c97a9697
8 changed files with 23 additions and 17 deletions

View file

@ -148,6 +148,7 @@ fun editCustomLayout(layoutName: String, context: Context, startContent: String?
val isJson = checkLayout(content, context)
if (isJson == null) {
editCustomLayout(layoutName, context, content)
// todo: this actually always returns the "simple layout" error, even on a json layout with a single small error
infoDialog(context, context.getString(R.string.layout_error, Log.getLog(10).lastOrNull { it.tag == TAG }?.message))
} else {
val wasJson = file.name.substringAfterLast(".") == "json"