Skip to content

Commit

Permalink
cleaned up
Browse files Browse the repository at this point in the history
  • Loading branch information
fmerzadyan committed Oct 19, 2016
1 parent 02905b9 commit fc5363e
Showing 1 changed file with 6 additions and 4 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -260,6 +260,7 @@ public boolean onTouchEvent(MotionEvent ev)
// Don't return here -- must call super.onTouchEvent()

boolean superHandled = super.onTouchEvent(ev);

return (superHandled || handled || swipeHandled);
}

Expand All @@ -283,7 +284,8 @@ public NonHTCWebView(Context context)
public boolean onCheckIsTextEditor()
{
if (proxy.hasProperty(TiC.PROPERTY_SOFT_KEYBOARD_ON_FOCUS)) {
int value = TiConvert.toInt(proxy.getProperty(TiC.PROPERTY_SOFT_KEYBOARD_ON_FOCUS), TiUIView.SOFT_KEYBOARD_DEFAULT_ON_FOCUS);
int value = TiConvert.toInt(proxy.getProperty(TiC.PROPERTY_SOFT_KEYBOARD_ON_FOCUS), TiUIView.SOFT_KEYBOARD_DEFAULT_ON_FOCUS);

if (value == TiUIView.SOFT_KEYBOARD_HIDE_ON_FOCUS) {
return false;
} else if (value == TiUIView.SOFT_KEYBOARD_SHOW_ON_FOCUS) {
Expand Down Expand Up @@ -319,7 +321,7 @@ private boolean isHTCSenseDevice()
public TiUIWebView(TiViewProxy proxy)
{
super(proxy);

// We can only support debugging in API 19 and higher
if (Build.VERSION.SDK_INT >= Build.VERSION_CODES.KITKAT) {
// Only enable webview debugging, when app is debuggable
Expand All @@ -330,7 +332,7 @@ public TiUIWebView(TiViewProxy proxy)

TiWebView webView = isHTCSenseDevice() ? new TiWebView(proxy.getActivity()) : new NonHTCWebView(proxy.getActivity());
webView.setVerticalScrollbarOverlay(true);

WebSettings settings = webView.getSettings();
settings.setUseWideViewPort(true);
settings.setJavaScriptEnabled(true);
Expand Down Expand Up @@ -922,7 +924,7 @@ public void reload()
getWebView().reload();
}
break;

case URL:
if (reloadData != null && reloadData instanceof String) {
setUrl((String) reloadData);
Expand Down

0 comments on commit fc5363e

Please sign in to comment.