diff options
author | daniel oeh <daniel.oeh@gmail.com> | 2013-04-20 16:38:03 +0200 |
---|---|---|
committer | daniel oeh <daniel.oeh@gmail.com> | 2013-04-20 16:38:03 +0200 |
commit | 1c139616ba2011655dedcef064a0df81a4afed33 (patch) | |
tree | 1b34d8132158d7a8db70e61e3313ef36302ff26c /src/de/danoeh/antennapod/fragment | |
parent | f781bba3f3085ab766e0a4f80421343161728d2e (diff) | |
download | AntennaPod-1c139616ba2011655dedcef064a0df81a4afed33.zip |
Made sure links are opened in external application
Diffstat (limited to 'src/de/danoeh/antennapod/fragment')
-rw-r--r-- | src/de/danoeh/antennapod/fragment/ItemDescriptionFragment.java | 12 |
1 files changed, 8 insertions, 4 deletions
diff --git a/src/de/danoeh/antennapod/fragment/ItemDescriptionFragment.java b/src/de/danoeh/antennapod/fragment/ItemDescriptionFragment.java index fd5a3b7e4..160784a90 100644 --- a/src/de/danoeh/antennapod/fragment/ItemDescriptionFragment.java +++ b/src/de/danoeh/antennapod/fragment/ItemDescriptionFragment.java @@ -9,7 +9,6 @@ import android.content.Context; import android.content.Intent; import android.content.SharedPreferences; import android.content.res.TypedArray; -import android.graphics.Picture; import android.net.Uri; import android.os.AsyncTask; import android.os.Build; @@ -23,11 +22,8 @@ import android.view.Menu; import android.view.MenuItem; import android.view.View; import android.view.ViewGroup; -import android.webkit.WebBackForwardList; -import android.webkit.WebChromeClient; import android.webkit.WebSettings.LayoutAlgorithm; import android.webkit.WebView; -import android.webkit.WebView.PictureListener; import android.webkit.WebViewClient; import android.widget.Toast; @@ -119,7 +115,15 @@ public class ItemDescriptionFragment extends SherlockFragment { webvDescription.setWebViewClient(new WebViewClient() { @Override + public boolean shouldOverrideUrlLoading(WebView view, String url) { + Intent intent = new Intent(Intent.ACTION_VIEW, Uri.parse(url)); + startActivity(intent); + return true; + } + + @Override public void onPageFinished(WebView view, String url) { + super.onPageFinished(view, url); if (AppConfig.DEBUG) Log.d(TAG, "Page finished"); // Restoring the scroll position might not always work |