标签:port hang post ring apply logs timeout log 事件
window.addEventListener(‘message‘, function (event) { if (event.data.type === "changeMainSrc") { changeMainSrcByUrl(event.data.body.url, event.data.body.queryString); } else if (event.data.type === "screenshot") { if (!contains($scope.latestlist, event.data.body)) { $scope.latestlist.push(event.data.body); } } else if (event.data.type === "closeFrame") { $scope.$apply($scope.toMain(event.data.body.url, event.data.body.backUrl)); } else if (event.data.type === "changeFuncName") { $timeout(function () { $scope.currentFuc.funcName = event.data.body.name }); } else if (event.data.type === "changeMainSrcNotInFrame") { $scope.changeMainSrc(event.data.body.submenu, null, event.data.body.queryString); $scope.$apply(); } else if(event.data.type === "report") { handleReportMessage(event); } else if(event.data.type === HrUtils.postMessageType.MESSAGE) { messageService.sendRequest(event.data.body); } }, true);
标签:port hang post ring apply logs timeout log 事件
原文地址:http://www.cnblogs.com/ms-grf/p/7634877.html