Dialog notifying user of failure when media upload fails (#3135)
* First attempt at user notifications of failure when media upload fails * Drafts alert displays alert * ktLint * Fix defaced 46.json, add 47.json * Mock draftsNeedUserAlert in MainActivityTest to prevent spurious failure * Friendlier posts-failed message * Create DraftsAlert object * DraftsAlert works * Not the cleanest, but DraftsAlert works with multiple accounts * Use plural strings * KtLint * Clean up debug prints * Simplify DraftsAlert per Conny suggestions * Text change suggested by Conny * ktLint again * Back out test changes * Fix MainActivityTest for new approach * Tweak debug log * Do not use GlobalScope for coroutines
This commit is contained in:
parent
47b1299ff2
commit
b2511d782d
13 changed files with 1138 additions and 2 deletions
|
|
@ -31,7 +31,7 @@ import java.io.File;
|
|||
*/
|
||||
@Database(entities = { DraftEntity.class, AccountEntity.class, InstanceEntity.class, TimelineStatusEntity.class,
|
||||
TimelineAccountEntity.class, ConversationEntity.class
|
||||
}, version = 46)
|
||||
}, version = 47)
|
||||
public abstract class AppDatabase extends RoomDatabase {
|
||||
|
||||
public abstract AccountDao accountDao();
|
||||
|
|
@ -639,4 +639,11 @@ public abstract class AppDatabase extends RoomDatabase {
|
|||
database.execSQL("ALTER TABLE `DraftEntity` ADD COLUMN `statusId` TEXT");
|
||||
}
|
||||
};
|
||||
|
||||
public static final Migration MIGRATION_46_47 = new Migration(46, 47) {
|
||||
@Override
|
||||
public void migrate(@NonNull SupportSQLiteDatabase database) {
|
||||
database.execSQL("ALTER TABLE `DraftEntity` ADD COLUMN `failedToSendNew` INTEGER NOT NULL DEFAULT 0");
|
||||
}
|
||||
};
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue