"use strict"; cc._RF.push(module, 'b3237jh22lP85w794nIihoG', 'cmp.pvprank.records'); // Scripts/mod/pvp/rank/cmp/cmp.pvprank.records.js "use strict"; var BridgeWindow = require("bridge.window"); var ElitematchEvent = require("elitematch_event"); var FxSVC = require("nx.fx.sv.expand"); var FxTogs = require("nx.fx.togs"); cc.Class({ "extends": BridgeWindow, properties: { nodRecords: { "default": null, type: FxSVC }, nodEmpty: { "default": null, type: cc.Node }, nodToggle: { "default": null, type: FxTogs } }, // 重载:关闭前 onPreClosed: function onPreClosed() { this.nodRecords.rebuild([]); }, onOpenConfigs: function onOpenConfigs(params) { this.mod = params.mod; if (!this.mod) { this.delayClose(); return; } this.bindGEvent(ElitematchEvent.Elite_Challenge_Record_Event, this.freshChallengeLog.bind(this)); // this.bindGEvent( ArenaEvent.UpdateLoopChallengeTimesList, this.freshSelf.bind(this) ); // this.bindGEvent( ArenaEvent.UpdateLoopChallengeTimesList, this.showNode.bind(this)); // this.bindGEvent( ArenaEvent.UpdateArena_Number, this.updateRankListInfo.bind(this)); this.nodToggle.posTog = this.onTogMenu.bind(this); this.nodToggle.togTo(0); this.onTogMenu(0); }, freshChallengeLog: function freshChallengeLog(_cdata) { var _this = this; var records = _cdata.arena_elite_log; records.forEach(function (_item) { _item.type = _this.type; }); this.nodRecords.rebuild(records); nx.gui.setActive(this.nodEmpty, "", nx.dt.arrEmpty(records)); }, onTogMenu: function onTogMenu(_idx) { var type = _idx + 1; this.type = type; if (this.mod) { this.mod.sender24930(type); } } }); cc._RF.pop();