5

I'm using the Facebook SDK 3.0 for Android with the uiHelper and the loginButton. When I press the login button a progress dialog is displayed. Is it possible to custom it or replace it with another dialog ? How ? I'm pretty sure that's possible, Candy crush do it ... Moreover, I try to log user without the uiHelper but with the traditionnal method : session.openForRead(new Session.OpenRequest(this).setCallback(statusCallback)); I've the same issue, I don't understand how this progress dialog is displayed.

Thank you all !

vokvince
  • 61
  • 1
  • 5
  • The FB SDK sources are available on github. You can change there whatever you want – Eugen Martynov Nov 11 '13 at 19:48
  • Do you know the class which is concerned by the progress dialog ? – vokvince Nov 11 '13 at 19:56
  • 3
    The class com.facebook.LoginActivity has an authorizationClient field and the method setBackgroundProcessingListener with 2 callbacks(line 75 SDK 3.0) display this spinner. Unfortunately, there isn't callback for your activity. – vokvince Nov 11 '13 at 21:13

3 Answers3

0

you can go directly to the Facebook Library project added to your Project , Go inside the code and change it .

this is an example from WebDialog Class , i simply removed the show method of the ProgressDialog:

    @Override
    public void onPageStarted(WebView view, String url, Bitmap favicon) {
        Utility.logd(LOG_TAG, "Webview loading URL: " + url);
        super.onPageStarted(view, url, favicon);
        if (!isDetached) {
            //spinner.show();
        }
    }
Gal Rom
  • 6,221
  • 3
  • 41
  • 33
0

For facebook-android-sdk-4.4.1

It can be changed in com/facebook/login/loginFragment look for com_facebook_login_activity_progress_bar and set the visibility to GONE like this

R.id.com_facebook_login_activity_progress_bar).setVisibility(View.GONE);
0

You can use this answer to hide the Facebook process dialog, and then implement your own when the Facebook login is pressed.

Community
  • 1
  • 1
JuiCe
  • 4,132
  • 16
  • 68
  • 119