Android facebook api authorization
<p>Im trying to use official facebook api for android and I found a strange thing in the auth process.
The code was cut from the official example.</p>

<pre><code>@Override
public void onCreate(Bundle savedInstanceState) { 
   mFacebook = new Facebook(APP_ID); 
}

@Override
protected void onActivityResult(int requestCode, int resultCode,
                                Intent data) {
    mFacebook.authorizeCallback(requestCode, resultCode, data);
}

 private final class ButtonOnClickListener implements OnClickListener {

    public void onClick(View arg0) {
       mFacebook.authorize(mActivity, mPermissions, new LoginDialogListener());
    }
} 


private class SessionListener implements AuthListener, LogoutListener {
   public void onAuthSucceed() {
       setImageResource(R.drawable.logout_button);
       SessionStore.save(mFb, getContext());
   }
} 
</code></pre>

<p>So in the onClick you give a reference to your activity, because you'll get the result of the login process in the onActivityResult.</p>

<p>The strange thing that if your activity is killed while youre on the login screen your facebook object will be reinstantiated in onCreate and after the authorizeCallback call none of your SessionListener's method is getting invoked.</p>

<p>The problem is that I have an upload method which would be called in onAuthSucceed().</p>

<p>Does anyone have a solution for this?</p>
