|
@@ -11,22 +11,22 @@
|
|
|
|
|
|
//多玩客户端不支持window.open,在这里做统一兼容处理
|
|
|
var dwClientIncompatible = {
|
|
|
- isClient(){
|
|
|
+ isClient: function() {
|
|
|
return !!(window.external && window.external.OpenThirdLogin)
|
|
|
},
|
|
|
- open(url,target){
|
|
|
+ open: function(url,target) {
|
|
|
if(dwClientIncompatible.isClient()){
|
|
|
window.external.OpenThirdLogin(url)
|
|
|
} else {
|
|
|
return window.open(url,target)
|
|
|
}
|
|
|
},
|
|
|
- focus(context){
|
|
|
+ focus: function(context) {
|
|
|
if(!dwClientIncompatible.isClient()){
|
|
|
context && context.focus()
|
|
|
}
|
|
|
},
|
|
|
- close(context){
|
|
|
+ close: function(context) {
|
|
|
if(dwClientIncompatible.isClient()){
|
|
|
window.external.CloseThirdLogin()
|
|
|
} else {
|