java - Android WebView, how to code for device back button? -


i developing 1 app, has 2 activities. second activity has button using web view. when clicking on button going on web view when pressing on button of device app going first activity, want go again on second activity. how can implement tried many techniques. here code.

public void onbackpressed (){  if (webview.isfocused() && webview.cangoback()) {         webview.goback();        } else {         super.onbackpressed();  } } 


Comments

Popular posts from this blog

python 2.7 - Chat Solution for Mobile App -

jquery - Detect current Section with javascript -