Skip to content

Commit 3341084

Browse files
committed
Fix: #24
1 parent 4b5a0a6 commit 3341084

File tree

1 file changed

+6
-9
lines changed

1 file changed

+6
-9
lines changed

app/src/main/java/io/neoterm/setup/SetupThread.java

Lines changed: 6 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -65,15 +65,12 @@ public void run() {
6565
final int totalReadBytesFinal = totalReadBytes;
6666
final int totalBytesFinal = totalBytes;
6767

68-
activity.runOnUiThread(new Runnable() {
69-
@Override
70-
public void run() {
71-
try {
72-
double progressFloat = ((double) totalReadBytesFinal) / ((double) totalBytesFinal) * 100.0;
73-
progressDialog.setProgress((int) progressFloat);
74-
} catch (RuntimeException ignore) {
75-
// activity dismissed
76-
}
68+
activity.runOnUiThread(() -> {
69+
try {
70+
double progressFloat = ((double) totalReadBytesFinal) / ((double) totalBytesFinal) * 100.0;
71+
progressDialog.setProgress((int) progressFloat);
72+
} catch (RuntimeException ignore) {
73+
// activity dismissed
7774
}
7875
});
7976

0 commit comments

Comments
 (0)