This commit is contained in:
parent
3f1ed3ba70
commit
3457a239fe
@ -1966,7 +1966,7 @@ final public class InAppWebView extends InputAwareWebView {
|
|||||||
@Override
|
@Override
|
||||||
public void onReceiveValue(String value) {
|
public void onReceiveValue(String value) {
|
||||||
if (floatingContextMenu != null) {
|
if (floatingContextMenu != null) {
|
||||||
if (value != null && !value.equals("null")) {
|
if (value != null && !value.equalsIgnoreCase("null")) {
|
||||||
int x = contextMenuPoint.x;
|
int x = contextMenuPoint.x;
|
||||||
int y = (int) ((Float.parseFloat(value) * scale) + (floatingContextMenu.getHeight() / 3.5));
|
int y = (int) ((Float.parseFloat(value) * scale) + (floatingContextMenu.getHeight() / 3.5));
|
||||||
contextMenuPoint.y = y;
|
contextMenuPoint.y = y;
|
||||||
@ -1986,7 +1986,7 @@ final public class InAppWebView extends InputAwareWebView {
|
|||||||
evaluateJavascript(getSelectedTextJS, new ValueCallback<String>() {
|
evaluateJavascript(getSelectedTextJS, new ValueCallback<String>() {
|
||||||
@Override
|
@Override
|
||||||
public void onReceiveValue(String value) {
|
public void onReceiveValue(String value) {
|
||||||
value = (value != null) ? value.substring(1, value.length() - 1) : null;
|
value = (value != null && !value.equalsIgnoreCase("null")) ? value.substring(1, value.length() - 1) : null;
|
||||||
resultCallback.onReceiveValue(value);
|
resultCallback.onReceiveValue(value);
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
|
Loading…
x
Reference in New Issue
Block a user