Beispiel #1
0
 @Override
 protected void onCancelled(DBResult dbResult) {
   super.onCancelled(dbResult);
   if (progressFragment != null) {
     progressFragment.dismissAllowingStateLoss();
   }
   if (e != null) Toast.makeText(OAuthActivity.this, e.getError(), Toast.LENGTH_SHORT).show();
   webView.loadUrl(getWeiboOAuthUrl());
 }
Beispiel #2
0
 @Override
 protected void onPostExecute(DBResult dbResult) {
   if (progressFragment.isVisible()) {
     progressFragment.dismissAllowingStateLoss();
   }
   switch (dbResult) {
     case add_successfuly:
       Toast.makeText(OAuthActivity.this, getString(R.string.login_success), Toast.LENGTH_SHORT)
           .show();
       break;
     case update_successfully:
       Toast.makeText(
               OAuthActivity.this,
               getString(R.string.update_account_success),
               Toast.LENGTH_SHORT)
           .show();
       break;
   }
   finish();
 }