diff --git a/res/layout/calc_editor.xml b/res/layout/calc_editor.xml index af5992f6..909ba4f7 100644 --- a/res/layout/calc_editor.xml +++ b/res/layout/calc_editor.xml @@ -14,7 +14,8 @@ diff --git a/src/main/java/org/solovyev/android/calculator/CalculatorEditor.java b/src/main/java/org/solovyev/android/calculator/CalculatorEditor.java index c38946f0..9ff1466b 100644 --- a/src/main/java/org/solovyev/android/calculator/CalculatorEditor.java +++ b/src/main/java/org/solovyev/android/calculator/CalculatorEditor.java @@ -19,7 +19,6 @@ import org.solovyev.android.calculator.model.CalculatorEngine; import org.solovyev.android.calculator.model.CalculatorParseException; import org.solovyev.android.calculator.model.TextProcessor; import org.solovyev.android.calculator.view.TextHighlighter; -import org.solovyev.common.utils.CollectionsUtils; /** * User: serso @@ -52,17 +51,9 @@ public class CalculatorEditor extends EditText implements SharedPreferences.OnSh public boolean onCheckIsTextEditor() { // Main goal of this implementation is to hide android soft keyboard from appearing when working with text input - // todo serso: refactor - // NOTE: do not copy or reuse code below, it's completely SHIT!!! - if ( Build.VERSION.SDK_INT >= 11 ) { // fix for missing cursor in android 3 and higher - for (StackTraceElement stackTraceElement : CollectionsUtils.asList(Thread.currentThread().getStackTrace())) { - if ( "isCursorVisible".equals(stackTraceElement.getMethodName()) ) { - return true; - } - } - return false; + return true; } else { return false; }