From f8528374885ee968dc69c404d6c5507ceb456314 Mon Sep 17 00:00:00 2001 From: hyb1996 <946994919@qq.com> Date: Thu, 22 Feb 2018 10:38:00 +0800 Subject: [PATCH] fix: console input box not showing on some devices --- .../assets/editor/theme/dark_default.json | 14 - app/src/main/assets/editor/theme/dark_vs.json | 364 ------------------ .../autojs/core/console/ConsoleView.java | 2 +- autojs/src/main/res/layout/console_view.xml | 2 +- 4 files changed, 2 insertions(+), 380 deletions(-) delete mode 100644 app/src/main/assets/editor/theme/dark_default.json delete mode 100644 app/src/main/assets/editor/theme/dark_vs.json diff --git a/app/src/main/assets/editor/theme/dark_default.json b/app/src/main/assets/editor/theme/dark_default.json deleted file mode 100644 index 4823a374..00000000 --- a/app/src/main/assets/editor/theme/dark_default.json +++ /dev/null @@ -1,14 +0,0 @@ -{ - "$schema": "vscode://schemas/color-theme", - "name": "Dark Default Colors", - "colors": { - "editor.background": "#1E1E1E", - "editor.foreground": "#D4D4D4", - "editor.inactiveSelectionBackground": "#3A3D41", - "editorIndentGuide.background": "#404040", - "editor.selectionHighlightBackground": "#ADD6FF26", - "list.dropBackground": "#383B3D", - "activityBarBadge.background": "#007ACC", - "sideBarTitle.foreground": "#BBBBBB" - } -} \ No newline at end of file diff --git a/app/src/main/assets/editor/theme/dark_vs.json b/app/src/main/assets/editor/theme/dark_vs.json deleted file mode 100644 index cfd99150..00000000 --- a/app/src/main/assets/editor/theme/dark_vs.json +++ /dev/null @@ -1,364 +0,0 @@ -{ - "$schema": "vscode://schemas/color-theme", - "name": "Dark (Visual Studio)", - "colors": { - "editor.background": "#1E1E1E", - "editor.foreground": "#D4D4D4", - "editor.inactiveSelectionBackground": "#3A3D41", - "editorIndentGuide.background": "#404040", - "editor.selectionHighlightBackground": "#ADD6FF26", - "list.dropBackground": "#383B3D", - "activityBarBadge.background": "#007ACC", - "sideBarTitle.foreground": "#BBBBBB" - }, - "tokenColors": [ - { - "scope": [ - "meta.embedded", - "source.groovy.embedded" - ], - "settings": { - "foreground": "#D4D4D4" - } - }, - { - "scope": "emphasis", - "settings": { - "fontStyle": "italic" - } - }, - { - "scope": "strong", - "settings": { - "fontStyle": "bold" - } - }, - { - "scope": "header", - "settings": { - "foreground": "#000080" - } - }, - { - "scope": "comment", - "settings": { - "foreground": "#608b4e" - } - }, - { - "scope": "constant.language", - "settings": { - "foreground": "#569cd6" - } - }, - { - "scope": [ - "constant.numeric" - ], - "settings": { - "foreground": "#b5cea8" - } - }, - { - "scope": "constant.regexp", - "settings": { - "foreground": "#646695" - } - }, - { - "scope": "entity.name.tag", - "settings": { - "foreground": "#569cd6" - } - }, - { - "scope": "entity.name.tag.css", - "settings": { - "foreground": "#d7ba7d" - } - }, - { - "scope": "entity.other.attribute-name", - "settings": { - "foreground": "#9cdcfe" - } - }, - { - "scope": [ - "entity.other.attribute-name.class.css", - "entity.other.attribute-name.class.mixin.css", - "entity.other.attribute-name.id.css", - "entity.other.attribute-name.parent-selector.css", - "entity.other.attribute-name.pseudo-class.css", - "entity.other.attribute-name.pseudo-element.css", - "source.css.less entity.other.attribute-name.id", - "entity.other.attribute-name.attribute.scss", - "entity.other.attribute-name.scss" - ], - "settings": { - "foreground": "#d7ba7d" - } - }, - { - "scope": "invalid", - "settings": { - "foreground": "#f44747" - } - }, - { - "scope": "markup.underline", - "settings": { - "fontStyle": "underline" - } - }, - { - "scope": "markup.bold", - "settings": { - "fontStyle": "bold", - "foreground": "#569cd6" - } - }, - { - "scope": "markup.heading", - "settings": { - "fontStyle": "bold", - "foreground": "#569cd6" - } - }, - { - "scope": "markup.italic", - "settings": { - "fontStyle": "italic" - } - }, - { - "scope": "markup.inserted", - "settings": { - "foreground": "#b5cea8" - } - }, - { - "scope": "markup.deleted", - "settings": { - "foreground": "#ce9178" - } - }, - { - "scope": "markup.changed", - "settings": { - "foreground": "#569cd6" - } - }, - { - "scope": "beginning.punctuation.definition.quote.markdown", - "settings": { - "foreground": "#608b4e" - } - }, - { - "scope": "beginning.punctuation.definition.list.markdown", - "settings": { - "foreground": "#6796e6" - } - }, - { - "scope": "markup.inline.raw", - "settings": { - "foreground": "#ce9178" - } - }, - { - "scope": "meta.selector", - "settings": { - "foreground": "#d7ba7d" - } - }, - { - "name": "brackets of XML/HTML tags", - "scope": "punctuation.definition.tag", - "settings": { - "foreground": "#808080" - } - }, - { - "scope": "meta.preprocessor", - "settings": { - "foreground": "#569cd6" - } - }, - { - "scope": "meta.preprocessor.string", - "settings": { - "foreground": "#ce9178" - } - }, - { - "scope": "meta.preprocessor.numeric", - "settings": { - "foreground": "#b5cea8" - } - }, - { - "scope": "meta.structure.dictionary.key.python", - "settings": { - "foreground": "#9cdcfe" - } - }, - { - "scope": "meta.diff.header", - "settings": { - "foreground": "#569cd6" - } - }, - { - "scope": "storage", - "settings": { - "foreground": "#569cd6" - } - }, - { - "scope": "storage.type", - "settings": { - "foreground": "#569cd6" - } - }, - { - "scope": "storage.modifier", - "settings": { - "foreground": "#569cd6" - } - }, - { - "scope": "string", - "settings": { - "foreground": "#ce9178" - } - }, - { - "scope": "string.tag", - "settings": { - "foreground": "#ce9178" - } - }, - { - "scope": "string.value", - "settings": { - "foreground": "#ce9178" - } - }, - { - "scope": "string.regexp", - "settings": { - "foreground": "#d16969" - } - }, - { - "name": "String interpolation", - "scope": [ - "punctuation.definition.template-expression.begin", - "punctuation.definition.template-expression.end", - "punctuation.section.embedded" - ], - "settings": { - "foreground": "#569cd6" - } - }, - { - "name": "Reset JavaScript string interpolation expression", - "scope": [ - "meta.template.expression" - ], - "settings": { - "foreground": "#d4d4d4" - } - }, - { - "scope": [ - "support.type.vendored.property-name", - "support.type.property-name", - "variable.css", - "variable.scss", - "variable.other.less", - "source.coffee.embedded" - ], - "settings": { - "foreground": "#9cdcfe" - } - }, - { - "scope": "keyword", - "settings": { - "foreground": "#569cd6" - } - }, - { - "scope": "keyword.control", - "settings": { - "foreground": "#569cd6" - } - }, - { - "scope": "keyword.operator", - "settings": { - "foreground": "#d4d4d4" - } - }, - { - "scope": [ - "keyword.operator.new", - "keyword.operator.expression", - "keyword.operator.cast", - "keyword.operator.sizeof", - "keyword.operator.logical.python" - ], - "settings": { - "foreground": "#569cd6" - } - }, - { - "scope": "keyword.other.unit", - "settings": { - "foreground": "#b5cea8" - } - }, - { - "scope": [ - "punctuation.section.embedded.begin.php", - "punctuation.section.embedded.end.php" - ], - "settings": { - "foreground": "#569cd6" - } - }, - { - "scope": "support.function.git-rebase", - "settings": { - "foreground": "#9cdcfe" - } - }, - { - "scope": "constant.sha.git-rebase", - "settings": { - "foreground": "#b5cea8" - } - }, - { - "name": "coloring of the Java import and package identifiers", - "scope": [ - "storage.modifier.import.java", - "variable.language.wildcard.java", - "storage.modifier.package.java" - ], - "settings": { - "foreground": "#d4d4d4" - } - }, - { - "name": "this.self", - "scope": "variable.language", - "settings": { - "foreground": "#569cd6" - } - } - ] -} \ No newline at end of file diff --git a/autojs/src/main/java/com/stardust/autojs/core/console/ConsoleView.java b/autojs/src/main/java/com/stardust/autojs/core/console/ConsoleView.java index 3d85d047..e5081812 100644 --- a/autojs/src/main/java/com/stardust/autojs/core/console/ConsoleView.java +++ b/autojs/src/main/java/com/stardust/autojs/core/console/ConsoleView.java @@ -181,7 +181,7 @@ public class ConsoleView extends FrameLayout implements StardustConsole.LogListe public void showEditText() { post(() -> { mWindow.requestWindowFocus(); - mInputContainer.setVisibility(VISIBLE); + //mInputContainer.setVisibility(VISIBLE); mEditText.requestFocus(); }); } diff --git a/autojs/src/main/res/layout/console_view.xml b/autojs/src/main/res/layout/console_view.xml index c2dd5579..1b497f74 100644 --- a/autojs/src/main/res/layout/console_view.xml +++ b/autojs/src/main/res/layout/console_view.xml @@ -18,7 +18,7 @@ android:layout_height="wrap_content" android:layout_marginLeft="8dp" android:orientation="horizontal" - android:visibility="gone" + android:visibility="visible" tools:visibility="visible">