Prepares release 1.6.0-beta-2

This commit is contained in:
stom79 2017-11-15 14:14:41 +01:00
parent 1e240ecd42
commit bff2af7bd9
3 changed files with 13 additions and 10 deletions

1
.gitignore vendored
View File

@ -6,3 +6,4 @@
/build
/captures
.externalNativeBuild
/crowdin.properties

View File

@ -7,8 +7,8 @@ android {
applicationId "fr.gouv.etalab.mastodon"
minSdkVersion 15
targetSdkVersion 27
versionCode 70
versionName "1.6.0-beta-1"
versionCode 71
versionName "1.6.0-beta-2"
}
flavorDimensions "default"
buildTypes {

View File

@ -930,7 +930,7 @@ public class TootActivity extends AppCompatActivity implements OnRetrieveSearcAc
}
return true;
case R.id.action_store:
storeToot(true);
storeToot(true, true);
return true;
case R.id.action_restore:
try{
@ -1061,7 +1061,7 @@ public class TootActivity extends AppCompatActivity implements OnRetrieveSearcAc
Toast.makeText(getApplicationContext(), R.string.toot_scheduled_date, Toast.LENGTH_LONG).show();
}else {
//Store the toot as draft first
storeToot(false);
storeToot(false, false);
//Schedules the toot
ScheduledTootsSyncJob.schedule(getApplicationContext(), currentToId, time);
//Clear content
@ -1408,7 +1408,7 @@ public class TootActivity extends AppCompatActivity implements OnRetrieveSearcAc
final SharedPreferences sharedpreferences = getSharedPreferences(Helper.APP_PREFS, Context.MODE_PRIVATE);
boolean storeToot = sharedpreferences.getBoolean(Helper.SET_AUTO_STORE, true);
if( storeToot && accountReply == null)
storeToot(true);
storeToot(true, false);
}
@ -1817,12 +1817,14 @@ public class TootActivity extends AppCompatActivity implements OnRetrieveSearcAc
private void storeToot(boolean message){
private void storeToot(boolean message, boolean forced){
//Nothing to store here....
if(toot_content.getText().toString().trim().length() == 0 && (attachments == null || attachments.size() <1) && toot_cw_content.getText().toString().trim().length() == 0)
return;
if( initialContent.trim().equals(toot_content.getText().toString().trim()))
return;
if( !forced) {
if (toot_content.getText().toString().trim().length() == 0 && (attachments == null || attachments.size() < 1) && toot_cw_content.getText().toString().trim().length() == 0)
return;
if (initialContent.trim().equals(toot_content.getText().toString().trim()))
return;
}
Status toot = new Status();
toot.setSensitive(isSensitive);
toot.setMedia_attachments(attachments);