mirror of
https://github.com/tateisu/SubwayTooter
synced 2024-12-25 00:21:26 +01:00
バグ修正
This commit is contained in:
parent
0ac0f90d54
commit
fb12ffd81f
@ -9,8 +9,8 @@ android {
|
||||
applicationId "jp.juggler.subwaytooter"
|
||||
minSdkVersion 21
|
||||
targetSdkVersion 25
|
||||
versionCode 28
|
||||
versionName "0.2.8"
|
||||
versionCode 29
|
||||
versionName "0.2.9"
|
||||
testInstrumentationRunner "android.support.test.runner.AndroidJUnitRunner"
|
||||
}
|
||||
|
||||
|
@ -381,16 +381,14 @@ public class ActMain extends AppCompatActivity
|
||||
// floating action button
|
||||
FloatingActionButton fabToot = (FloatingActionButton) findViewById( R.id.fabToot );
|
||||
fabToot.setOnClickListener( new View.OnClickListener() {
|
||||
@Override
|
||||
public void onClick( View view ){
|
||||
@Override public void onClick( View view ){
|
||||
performTootButton();
|
||||
}
|
||||
} );
|
||||
// floating action button
|
||||
FloatingActionButton fabMenu = (FloatingActionButton) findViewById( R.id.fabMenu );
|
||||
fabMenu.setOnClickListener( new View.OnClickListener() {
|
||||
@Override
|
||||
public void onClick( View view ){
|
||||
@Override public void onClick( View view ){
|
||||
if( ! drawer.isDrawerOpen( Gravity.START ) ){
|
||||
drawer.openDrawer( Gravity.START );
|
||||
}
|
||||
@ -405,8 +403,7 @@ public class ActMain extends AppCompatActivity
|
||||
|
||||
public void performAccountAdd(){
|
||||
LoginForm.showLoginForm( this, null, new LoginForm.LoginFormCallback() {
|
||||
@Override
|
||||
public void startLogin( final Dialog dialog, final String instance, final boolean bPseudoAccount ){
|
||||
@Override public void startLogin( final Dialog dialog, final String instance, final boolean bPseudoAccount ){
|
||||
|
||||
final ProgressDialog progress = new ProgressDialog( ActMain.this );
|
||||
|
||||
@ -968,7 +965,11 @@ public class ActMain extends AppCompatActivity
|
||||
private void performTootButton(){
|
||||
Column c = pager_adapter.getColumn( pager.getCurrentItem() );
|
||||
if( c != null ){
|
||||
ActPost.open( this, c.access_info.db_id, "" );
|
||||
if( c.access_info.isPseudo() ){
|
||||
Utils.showToast( this,false,R.string.not_available_for_pseudo_account );
|
||||
}else{
|
||||
ActPost.open( this, c.access_info.db_id, "" );
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -982,14 +982,14 @@ public class ActPost extends AppCompatActivity implements View.OnClickListener {
|
||||
@Override
|
||||
protected void onPostExecute( TootApiResult result ){
|
||||
progress.dismiss();
|
||||
|
||||
if( status != null ){
|
||||
if( result == null ){
|
||||
// cancelled.
|
||||
}else if( status != null ){
|
||||
// 連投してIdempotency が同じだった場合もエラーにはならず、ここを通る
|
||||
ActMain.update_at_resume = true;
|
||||
//DEBUG ActPost.this.finish();
|
||||
ActPost.this.finish();
|
||||
}else{
|
||||
if( result != null ){
|
||||
Utils.showToast( ActPost.this, true, result.error );
|
||||
}
|
||||
Utils.showToast( ActPost.this, true, result.error );
|
||||
}
|
||||
}
|
||||
};
|
||||
|
@ -1136,13 +1136,25 @@ class ColumnViewHolder implements View.OnClickListener, Column.VisualCallback, S
|
||||
activity.performConversation( access_info, status );
|
||||
break;
|
||||
case R.id.btnReply:
|
||||
activity.performReply( access_info, status );
|
||||
if(access_info.isPseudo() ){
|
||||
Utils.showToast( activity,false,R.string.not_available_for_pseudo_account );
|
||||
}else{
|
||||
activity.performReply( access_info, status );
|
||||
}
|
||||
break;
|
||||
case R.id.btnBoost:
|
||||
activity.performBoost( access_info, status, false, bSimpleList ? boost_complete_callback : null );
|
||||
if(access_info.isPseudo() ){
|
||||
Utils.showToast( activity,false,R.string.not_available_for_pseudo_account );
|
||||
}else{
|
||||
activity.performBoost( access_info, status, false, bSimpleList ? boost_complete_callback : null );
|
||||
}
|
||||
break;
|
||||
case R.id.btnFavourite:
|
||||
activity.performFavourite( access_info, status, bSimpleList ? favourite_complete_callback : null );
|
||||
if(access_info.isPseudo() ){
|
||||
Utils.showToast( activity,false,R.string.not_available_for_pseudo_account );
|
||||
}else{
|
||||
activity.performFavourite( access_info, status, bSimpleList ? favourite_complete_callback : null );
|
||||
}
|
||||
break;
|
||||
case R.id.btnMore:
|
||||
activity.openStatusMoreMenu( access_info, status, column.type );
|
||||
|
Loading…
Reference in New Issue
Block a user