Skip to content

Commit

Permalink
API version check for AccessibilityNodeInfo.setEditable call (flutter…
Browse files Browse the repository at this point in the history
  • Loading branch information
jason-simmons authored Jan 5, 2018
1 parent 6a724f0 commit e1b01d7
Showing 1 changed file with 3 additions and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,7 @@

import android.graphics.Rect;
import android.opengl.Matrix;
import android.os.Build;
import android.os.Bundle;
import android.util.Log;
import android.view.View;
Expand Down Expand Up @@ -121,7 +122,8 @@ public AccessibilityNodeInfo createAccessibilityNodeInfo(int virtualViewId) {

if (object.hasFlag(Flag.IS_TEXT_FIELD)) {
result.setClassName("android.widget.EditText");
result.setEditable(true);
if (Build.VERSION.SDK_INT >= Build.VERSION_CODES.JELLY_BEAN_MR2)
result.setEditable(true);

// Cursor movements
int granularities = 0;
Expand Down

0 comments on commit e1b01d7

Please sign in to comment.