Skip to content

Commit b0917df

Browse files
デバイス確認画面で認証ダイアログ後に強制終了する件の修正。
1 parent d9b5671 commit b0917df

3 files changed

Lines changed: 11 additions & 5 deletions

File tree

dConnectDevicePlugin/dConnectDeviceLinking/dConnectDeviceLinking/Classes/beacon/DPLinkingBeaconManager.m

Lines changed: 6 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -293,12 +293,16 @@ - (void) removeRawDataDelegate:(id<DPLinkingBeaconRawDataDelegate>)delegate {
293293

294294
- (void) startBeaconScanInternal {
295295
DCLogInfo(@"startBeaconScanInternal");
296-
[[BLEConnecter sharedInstance] startPartialScanDevice];
296+
dispatch_async(dispatch_get_main_queue(), ^{
297+
[[BLEConnecter sharedInstance] startPartialScanDevice];
298+
});
297299
}
298300

299301
- (void) stopBeaconScanInternal {
300302
DCLogInfo(@"stopBeaconScanInternal");
301-
[[BLEConnecter sharedInstance] stopPartialScanDevice];
303+
dispatch_async(dispatch_get_main_queue(), ^{
304+
[[BLEConnecter sharedInstance] stopPartialScanDevice];
305+
});
302306
}
303307

304308
- (void) startCheckConnectionOfBeacon {

dConnectDevicePlugin/dConnectDeviceSphero/dConnectDeviceSphero/Classes/DPSpheroManager.m

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -60,7 +60,7 @@ - (instancetype)init
6060
// アプリがバックグラウンドに入った
6161
- (void)applicationDidEnterBackground
6262
{
63-
// // センサーのマスクを保持
63+
// センサーのマスクを保持
6464
_streamingMask = [RKSetDataStreamingCommand currentMask];
6565
[RKRobotDiscoveryAgent stopDiscovery];
6666
[RKRobotDiscoveryAgent disconnectAll];
@@ -210,7 +210,9 @@ - (void)handleRobotStateChangeNotification:(RKRobotChangedStateNotification*)n {
210210
}
211211
case RKRobotDisconnected: {
212212
[self updateManageServices];
213-
[RKRobotDiscoveryAgent startDiscovery];
213+
dispatch_async(dispatch_get_main_queue(), ^{
214+
[RKRobotDiscoveryAgent startDiscovery];
215+
});
214216
break;
215217
}
216218
default:

dConnectSDK/dConnectSDKForIOS/DConnectSDK/Classes/http/DConnectServerManager.m

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -104,7 +104,7 @@ + (void) convertUriOfMessage:(DConnectMessage *) response
104104
NSArray *keys = [response allKeys];
105105
for (NSString *key in keys) {
106106
NSObject *obj = [response objectForKey:key];
107-
if ([key isEqualToString:@"uri"]) {
107+
if ([obj isKindOfClass:[NSString class]] && [key isEqualToString:@"uri"]) {
108108
NSString *uri = (NSString *)obj;
109109

110110
// http, httpsで指定されているURLは直接アクセスできるのでFilesAPIを利用しない

0 commit comments

Comments
 (0)