java - Add button to actionbar in android activity -
i add share button in action bar of current activity.
i don't know how it.
is possible in activity ?
here code of activity :
package com.rss.utils;  import com.rss.r;  import android.app.activity; import android.content.intent; import android.os.bundle; import android.util.log; import android.webkit.webchromeclient; import android.webkit.webview; import android.webkit.webviewclient; import android.widget.progressbar;  public class webbrowserviewactivity extends activity {      webview webview;     progressbar progressb = null;      @override     public void oncreate(bundle savedinstancestate) {         super.oncreate(savedinstancestate);         setcontentview(r.layout.web_browser_view);          intent intent = getintent();          string url = intent.getstringextra("url");          log.d("webbrowserviewactivity", "url load : " +url);          progressb = (progressbar) findviewbyid(r.id.progressbar1);         webview = (webview) findviewbyid(r.id.webviewarticle);             webview.setscrollbarstyle(webview.scrollbars_outside_overlay);          // webview.getsettings().setloadwithoverviewmode(true);         webview.getsettings().setusewideviewport(true);         webview.getsettings().setsupportzoom(true);         webview.getsettings().setbuiltinzoomcontrols(true);         webview.setwebviewclient(new webviewclient());          webview.setwebchromeclient(new webchromeclient() {             public void onprogresschanged(webview view, int progress) {                 if(progress < 100 && progressb.getvisibility() == progressbar.gone){                     progressb.setvisibility(progressbar.visible);                 }                 progressb.setprogress(progress);                 if(progress == 100) {                     progressb.setvisibility(progressbar.gone);                 }             }         });          webview.loadurl(url);        }   }   thanks lot help.
++
i've never done before did research , i'm pretty sure this you're looking for.
this article tell :)
Comments
Post a Comment