Commit ca256da8 by Takatoshi Miura

Merge branch 'communication/#42975_ios-host-request' into 'develop'

#42975 iOSのホスト変更ロジック適用

See merge request !154
parents 95e6d2e1 479b028e
......@@ -365,3 +365,10 @@ CHAT_DB.getJoinCollaborationType = function() {
return parseInt(callNativeApp("getJoinCollaborationType", {}), 10);
}
};
CHAT_DB.getHostRequestFlg = function() {
// Androidは実装不要
if (CHAT_UTIL.isIOS()) {
return parseInt(callNativeApp("getHostRequestFlg", {}), 10);
}
};
......@@ -186,14 +186,14 @@ $(function () {
if (CHAT_UTIL.isAndroid()) {
android.setHostRequestFlg(HOST_REQUEST_FLG.DOING);
} else {
//TODO ホストリクエスト中フラグを設定
webkit.messageHandlers.setHostRequestFlg.postMessage(HOST_REQUEST_FLG.DOING);
}
if(g_isMainMan && confirm(getLocalizedString('norify_request_host_change', data.payload.hostId))) {
Coview_changeHost(getFermiLoginId(data.payload.hostId));
if (CHAT_UTIL.isAndroid()) {
android.setHostRequestFlg(HOST_REQUEST_FLG.DONE);
} else {
//TODO ホストリクエスト中フラグを設定
webkit.messageHandlers.setHostRequestFlg.postMessage(HOST_REQUEST_FLG.DONE);
}
fw.sendToMsg('others', 'HOST_REQUEST_DONE', {"hostId": data.payload.hostId});
}
......@@ -201,7 +201,7 @@ $(function () {
if (CHAT_UTIL.isAndroid()) {
android.setHostRequestFlg(HOST_REQUEST_FLG.DONE);
} else {
//TODO ホストリクエスト中フラグを設定
webkit.messageHandlers.setHostRequestFlg.postMessage(HOST_REQUEST_FLG.DONE);
}
}
});
......@@ -590,7 +590,7 @@ function applyForHostChange() {
if (CHAT_UTIL.isAndroid()) {
hostRequestFlg = android.getHostRequestFlg();
} else {
//TODO ホストリクエスト中フラグを取得
hostRequestFlg = CHAT_DB.getHostRequestFlg();
}
if (hostRequestFlg == HOST_REQUEST_FLG.DOING) {
alert(getLocalizedString('already_processing_host_request'));
......@@ -599,7 +599,7 @@ function applyForHostChange() {
if (CHAT_UTIL.isAndroid()) {
android.setHostRequestFlg(HOST_REQUEST_FLG.DOING);
} else {
//TODO ホストリクエスト中フラグを設定
webkit.messageHandlers.setHostRequestFlg.postMessage(HOST_REQUEST_FLG.DOING);
}
fw.sendToMsg('others', 'CHANGE_HOST_APPLY', {"hostId": CHAT.globalLoginParameter.loginId});
};
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment