Back to project page Langleo.
The source code is released under:
Apache License
If you think the Android project Langleo listed in this page is inappropriate, such as containing malicious code/tools or violating the copyright, please email info at java2s dot com, thanks.
package com.atteo.langleo_trial.activities; //from w ww . j a v a2 s . co m import android.app.Activity; import android.content.Intent; import android.os.Bundle; import android.webkit.WebView; import com.atteo.langleo_trial.R; public class Help extends Activity { private final String prefix = "file:///android_asset/help/"; @Override public void onCreate(Bundle savedInstanceState) { super.onCreate(savedInstanceState); setContentView(R.layout.help); WebView wv = (WebView) this.findViewById(R.id.help_webview); Intent intent = getIntent(); if (savedInstanceState != null) wv.loadUrl(savedInstanceState.getString("url")); else wv.loadUrl(prefix + intent.getStringExtra("part") + ".html"); } @Override public void onSaveInstanceState(Bundle b) { WebView wv = (WebView) this.findViewById(R.id.help_webview); b.putString("url", wv.getUrl()); } }