Skip to content

Commit

Permalink
progress dialog fixed
Browse files Browse the repository at this point in the history
unconditional list refresh on properties change added
  • Loading branch information
eprst committed Aug 23, 2015
1 parent 98244dc commit 784fb92
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 10 deletions.
16 changes: 6 additions & 10 deletions app/src/main/java/com/kos/ktodo/KTodo.java
Original file line number Diff line number Diff line change
Expand Up @@ -655,7 +655,6 @@ protected void onStart() {
listView.setSlideLeftInfo(null, null);
}

Float prevListFontSize = listFontSize;
final String _default = "default";
final String fontSize = prefs.getString(Preferences.MAIN_LIST_FONT_SIZE, _default);
if (!fontSize.equals(_default)) {
Expand All @@ -673,9 +672,7 @@ protected void onStart() {
setupVoiceRecognition();
setupAddButtonIcon();

// !Objects.equals(prevListFontSize, listFontSize)
if (!(prevListFontSize == null ? listFontSize == null : prevListFontSize.equals(listFontSize)))
reloadTodoItemsFromUIThread(); // for font size changes to kick in
reloadTodoItemsFromUIThread(); // for font size changes or 'show as days left' to kick in
}

private void startEditingItem(final long id) {
Expand Down Expand Up @@ -1300,16 +1297,15 @@ public void onClick(final DialogInterface dialog, final int which) {
}

private void runAsynchronously(final int title, final int message, final Runnable r) {
final ProgressDialog pg = ProgressDialog.show(this, getString(title), getString(message), true);
final Handler h = new DialogDismissingHandler(pg);
final ProgressDialog pg = ProgressDialog.show(this, getString(title), getString(message), true, false);

final Runnable r2 = new Runnable() {
new Thread() {
@Override
public void run() {
r.run();
h.sendEmptyMessage(0);
pg.dismiss();
}
};
new Thread(r2).start();
}.start();
}

/* private void startSubActivity(final Class subActivityClass, final SubActivityCallback callback, final Bundle params) {
Expand Down
Binary file added mappings/mapping_2_0.7z
Binary file not shown.

0 comments on commit 784fb92

Please sign in to comment.