feat:stop debugging when devkit is disconnected from server
This commit is contained in:
parent
2e678b1231
commit
a40ec58fca
@ -183,6 +183,7 @@ public class DoricDev {
|
||||
|
||||
public void onClose() {
|
||||
devKitConnected = false;
|
||||
stopDebugging(true);
|
||||
uiHandler.post(new Runnable() {
|
||||
@Override
|
||||
public void run() {
|
||||
@ -195,6 +196,7 @@ public class DoricDev {
|
||||
|
||||
public void onFailure(final Throwable t) {
|
||||
devKitConnected = false;
|
||||
stopDebugging(true);
|
||||
uiHandler.post(new Runnable() {
|
||||
@Override
|
||||
public void run() {
|
||||
|
@ -132,6 +132,7 @@ - (void)onOpen {
|
||||
|
||||
- (void)onClose {
|
||||
self.devKitConnected = NO;
|
||||
[self stopDebugging:YES];
|
||||
dispatch_async(dispatch_get_main_queue(), ^{
|
||||
for (id <DoricDevStatusCallback> callback in self.callbacks) {
|
||||
[callback onClose:self.url];
|
||||
@ -141,6 +142,7 @@ - (void)onClose {
|
||||
|
||||
- (void)onFailure:(NSError *)error {
|
||||
self.devKitConnected = NO;
|
||||
[self stopDebugging:YES];
|
||||
dispatch_async(dispatch_get_main_queue(), ^{
|
||||
for (id <DoricDevStatusCallback> callback in self.callbacks) {
|
||||
[callback onFailure:error];
|
||||
|
Reference in New Issue
Block a user