Skip to content

Commit

Permalink
Revert "Start using DcJsonrpcInstance"
Browse files Browse the repository at this point in the history
This reverts commit 91ba9ae.
  • Loading branch information
link2xt committed Apr 22, 2023
1 parent 91ba9ae commit cff98f6
Showing 1 changed file with 4 additions and 6 deletions.
10 changes: 4 additions & 6 deletions src/org/thoughtcrime/securesms/ApplicationContext.java
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,6 @@
import com.b44t.messenger.DcContext;
import com.b44t.messenger.DcEvent;
import com.b44t.messenger.DcEventEmitter;
import com.b44t.messenger.DcJsonrpcInstance;

import org.thoughtcrime.securesms.components.emoji.EmojiProvider;
import org.thoughtcrime.securesms.connect.AccountManager;
Expand Down Expand Up @@ -112,14 +111,13 @@ public void onCreate() {
notificationCenter = new NotificationCenter(this);
eventCenter = new DcEventCenter(this);
new Thread(() -> {
DcJsonrpcInstance emitter = dcAccounts.getJsonrpcInstance();
DcEventEmitter emitter = dcAccounts.getEventEmitter();
while (true) {
String response = emitter.getNextResponse();
if (response==null) {
DcEvent event = emitter.getNextEvent();
if (event==null) {
break;
}
// TODO convert notification to event
//eventCenter.handleEvent(event);
eventCenter.handleEvent(event);
}
Log.i("DeltaChat", "shutting down event handler");
}, "eventThread").start();
Expand Down

0 comments on commit cff98f6

Please sign in to comment.