1.首页敬请期待弹窗修改完成
Showing
12 changed files
with
121 additions
and
16 deletions
... | @@ -192,7 +192,7 @@ | ... | @@ -192,7 +192,7 @@ |
192 | "array": [ | 192 | "array": [ |
193 | 0, | 193 | 0, |
194 | 0, | 194 | 0, |
195 | 250.28134155273438, | 195 | 271.060302734375, |
196 | 0, | 196 | 0, |
197 | 0, | 197 | 0, |
198 | 0, | 198 | 0, |
... | @@ -5460,7 +5460,7 @@ | ... | @@ -5460,7 +5460,7 @@ |
5460 | "_oFocusScaleFactorInfo": null, | 5460 | "_oFocusScaleFactorInfo": null, |
5461 | "_bShowExitBox": false, | 5461 | "_bShowExitBox": false, |
5462 | "test_json": { | 5462 | "test_json": { |
5463 | "__uuid__": "d797e6d8-b99b-4992-be3f-35357c9dcd65" | 5463 | "__uuid__": "2f979325-7c8b-45cc-99a5-30cc9c056bb1" |
5464 | }, | 5464 | }, |
5465 | "PFB_COMMON_WIDGET": { | 5465 | "PFB_COMMON_WIDGET": { |
5466 | "__uuid__": "57787725-2430-4ac3-b324-c22c08c3f074" | 5466 | "__uuid__": "57787725-2430-4ac3-b324-c22c08c3f074" | ... | ... |
This diff is collapsed.
Click to expand it.
... | @@ -240,10 +240,10 @@ cc.Class({ | ... | @@ -240,10 +240,10 @@ cc.Class({ |
240 | cc.log("向下滑动:" + fiFocusTarget.node.name); | 240 | cc.log("向下滑动:" + fiFocusTarget.node.name); |
241 | this._cFocus.flyFocus(this._fiCurrentFocus, fiFocusTarget, Common.MOVE_DIRECTION_DOWN, 1.0, oScrollParameter); | 241 | this._cFocus.flyFocus(this._fiCurrentFocus, fiFocusTarget, Common.MOVE_DIRECTION_DOWN, 1.0, oScrollParameter); |
242 | } | 242 | } |
243 | // if (this._fiCurrentFocus.node.name == "Play" && this._bShowProgress) { //暂时隐藏选集框,否则点击单曲循环会出现问题 | 243 | if (this._fiCurrentFocus.node.name == "Play" && this._bShowProgress) { //暂时隐藏选集框,否则点击单曲循环会出现问题 |
244 | // this.showSelectGatherArea(); | 244 | this.showSelectGatherArea(); |
245 | // return; | 245 | return; |
246 | // } | 246 | } |
247 | } | 247 | } |
248 | if (event.keyCode == cc.macro.KEY.left || event.keyCode == Common.ANDROID_KEY.left) { | 248 | if (event.keyCode == cc.macro.KEY.left || event.keyCode == Common.ANDROID_KEY.left) { |
249 | if (this._fiCurrentFocus.node.name == "Nothing") { | 249 | if (this._fiCurrentFocus.node.name == "Nothing") { | ... | ... |
... | @@ -403,6 +403,11 @@ cc.Topdraw.TVCanvas = | ... | @@ -403,6 +403,11 @@ cc.Topdraw.TVCanvas = |
403 | this.hideDetainBox(); | 403 | this.hideDetainBox(); |
404 | return; | 404 | return; |
405 | break; | 405 | break; |
406 | case "onComingSoonConfirmClick": | ||
407 | case "onComingSoonCancelClick": | ||
408 | this.hideComingSoonBox(); | ||
409 | return; | ||
410 | break; | ||
406 | case "exit": | 411 | case "exit": |
407 | cc.game.end(); | 412 | cc.game.end(); |
408 | break; | 413 | break; |
... | @@ -1035,6 +1040,82 @@ cc.Topdraw.TVCanvas = | ... | @@ -1035,6 +1040,82 @@ cc.Topdraw.TVCanvas = |
1035 | } | 1040 | } |
1036 | 1041 | ||
1037 | }, | 1042 | }, |
1043 | /** | ||
1044 | * 敬请期待提示框 | ||
1045 | */ | ||
1046 | showComingSoonBox: function (fiBackend, bHideBg) { | ||
1047 | try { | ||
1048 | this._bShowExitBox = true; | ||
1049 | if (this._nodeSystemPrompt) { | ||
1050 | try { | ||
1051 | this._nodeSystemPrompt.opacity = 255; | ||
1052 | if (null == this._aFocusTargets[1]) { //focus放到第二层级,避免冲突 | ||
1053 | this._aFocusTargets[1] = []; | ||
1054 | } | ||
1055 | this._aFocusTargets[1]['coming_soon_confirm_btn'] = cc.find("PromptBox/ComingSoonConfirm", this._nodeSystemPrompt); | ||
1056 | this._aFocusTargets[1]['coming_soon_cancel_btn'] = cc.find("PromptBox/ComingSoonCancel", this._nodeSystemPrompt); | ||
1057 | this._fiBeforeDetainBox = this._fiCurrentFocus; | ||
1058 | this._fiBackend = fiBackend; | ||
1059 | this._iSceneStatus = 1; | ||
1060 | this._cFocus.flyFocus(this._fiCurrentFocus, this._aFocusTargets[1]['coming_soon_confirm_btn'].getComponent(FocusInfo), Common.MOVE_DIRECTION_UP, this._fFocusScaleFactor, null); | ||
1061 | this._bIsLoadingPfbSystemPrompt = false; | ||
1062 | } catch (error) { | ||
1063 | cc.log("Business Exception:Get showComingSoonBox..." + error); | ||
1064 | } | ||
1065 | } else { | ||
1066 | this._bIsLoadingPfbSystemPrompt = true; | ||
1067 | //初始弹框 | ||
1068 | Common.loadRes('Prefab/pfbComingSoonPrompt',//提示预制 | ||
1069 | function (loadedResource) { | ||
1070 | this._nodeSystemPrompt = cc.instantiate(loadedResource); | ||
1071 | this._nodeSystemPrompt.parent = this.node; | ||
1072 | if (bHideBg) { | ||
1073 | this._nodeSystemPrompt.getChildByName("Background").opacity = 0; | ||
1074 | } | ||
1075 | let nodeConfirm = cc.find("PromptBox/ComingSoonConfirm", this._nodeSystemPrompt); | ||
1076 | let nodeCancel = cc.find("PromptBox/ComingSoonCancel", this._nodeSystemPrompt); | ||
1077 | nodeConfirm.getComponent(cc.Sprite).spriteFrame.setRect(cc.rect(0, 0, nodeConfirm.width, nodeConfirm.height)); | ||
1078 | nodeCancel.getComponent(cc.Sprite).spriteFrame.setRect(cc.rect(0, 0, nodeCancel.width, nodeCancel.height)); | ||
1079 | let fiConfirm = nodeConfirm.addComponent(FocusInfo); | ||
1080 | let fiCancel = nodeCancel.addComponent(FocusInfo); | ||
1081 | fiConfirm.init('{"click": [{"action": "onComingSoonConfirmClick"}]}', true); | ||
1082 | fiCancel.init('{"click": [{"action": "onComingSoonCancelClick"}]}', true); | ||
1083 | this.showComingSoonBox(fiBackend); | ||
1084 | }, | ||
1085 | function (error) { | ||
1086 | cc.log("Error When Loading Prefab pfbSystemPrompt ..."); | ||
1087 | }, this | ||
1088 | ); | ||
1089 | } | ||
1090 | } catch (error) { | ||
1091 | if (cc.sys.isNative) { | ||
1092 | jsb.reflection.callStaticMethod("org/cocos2dx/javascript/AppActivity", "logInSceneI", "(Ljava/lang/String;)V", "showComingSoonBox Error in TVCanvas==>" + error); | ||
1093 | } | ||
1094 | } | ||
1095 | |||
1096 | }, | ||
1097 | hideComingSoonBox: function () { | ||
1098 | try { | ||
1099 | this._nodeSystemPrompt.opacity = 0; | ||
1100 | delete this._aFocusTargets[1]['system_confirm_btn']; | ||
1101 | delete this._aFocusTargets[1]['system_cancel_btn']; | ||
1102 | this._iSceneStatus = 0; | ||
1103 | let iX = Common.SCREEN_WIDTH / 2 + Common.getX(this._fiBeforeDetainBox.node) - this._fiBeforeDetainBox.node.width / 2; | ||
1104 | let iY = Common.SCREEN_HEIGHT / 2 - Common.getY(this._fiBeforeDetainBox.node) + this._fiBeforeDetainBox.node.height / 2; | ||
1105 | cc.log("记忆焦点:" + this._fiBeforeDetainBox.node.name); | ||
1106 | if (this._fiBeforeDetainBox.getEnable() && iX >= 0 && iX <= Common.SCREEN_WIDTH && iY >= 0 && iY <= Common.SCREEN_HEIGHT + 50) {//这里是考虑给播放元素设置了虚拟位置 | ||
1107 | this._cFocus.flyFocus(this._fiCurrentFocus, this._fiBeforeDetainBox, Common.MOVE_DIRECTION_UP, this._fFocusScaleFactor, null); | ||
1108 | } else { | ||
1109 | this._cFocus.flyFocus(this._fiCurrentFocus, this._fiBackend, Common.MOVE_DIRECTION_UP, this._fFocusScaleFactor, null); | ||
1110 | } | ||
1111 | this._bShowExitBox = false; | ||
1112 | } catch (error) { | ||
1113 | if (cc.sys.isNative) { | ||
1114 | jsb.reflection.callStaticMethod("org/cocos2dx/javascript/AppActivity", "logInSceneI", "(Ljava/lang/String;)V", "hideComingSoonBox Error in TVCanvas==>" + error); | ||
1115 | } | ||
1116 | } | ||
1117 | |||
1118 | }, | ||
1038 | getImageByTag: (val, strTag, index) => { | 1119 | getImageByTag: (val, strTag, index) => { |
1039 | try { | 1120 | try { |
1040 | strTag = strTag || "normal"; | 1121 | strTag = strTag || "normal"; | ... | ... |
... | @@ -233,7 +233,7 @@ cc.Class({ | ... | @@ -233,7 +233,7 @@ cc.Class({ |
233 | compMarquee.setUIWithFocus(); | 233 | compMarquee.setUIWithFocus(); |
234 | }, | 234 | }, |
235 | 235 | ||
236 | //请求顶部个人中心和订购按钮 | 236 | //请求顶部个人中心和订购按钮(这里先将图片资源缩小了0.8,否则查找资源有些问题) |
237 | getTopNaviRequest: function (strCellName) { | 237 | getTopNaviRequest: function (strCellName) { |
238 | // Network.ajax("GET", Common.TOPDRAW_API_SERVER + "main/main_layout.json", null, null, | 238 | // Network.ajax("GET", Common.TOPDRAW_API_SERVER + "main/main_layout.json", null, null, |
239 | // function (strResponse) { | 239 | // function (strResponse) { |
... | @@ -261,6 +261,7 @@ cc.Class({ | ... | @@ -261,6 +261,7 @@ cc.Class({ |
261 | if (i > 0 && strCellName == "topNavi" || strCellName == "topCell") { //刨掉第一个logo图片 | 261 | if (i > 0 && strCellName == "topNavi" || strCellName == "topCell") { //刨掉第一个logo图片 |
262 | // cc.log("头部图片:"+aTopNaviJson[i].imageURL); | 262 | // cc.log("头部图片:"+aTopNaviJson[i].imageURL); |
263 | if (strCellName == "topCell") { | 263 | if (strCellName == "topCell") { |
264 | // nodeNav.scale = 0.5; | ||
264 | this._oInit.aTopCellImg.push(Common.TOPDRAW_IMAGE_SERVER + aTopNaviJson[i].imageURL); | 265 | this._oInit.aTopCellImg.push(Common.TOPDRAW_IMAGE_SERVER + aTopNaviJson[i].imageURL); |
265 | } else { | 266 | } else { |
266 | this._oInit.aTopNaviImg.push(Common.TOPDRAW_IMAGE_SERVER + aTopNaviJson[i].imageURL); | 267 | this._oInit.aTopNaviImg.push(Common.TOPDRAW_IMAGE_SERVER + aTopNaviJson[i].imageURL); |
... | @@ -691,7 +692,7 @@ cc.Class({ | ... | @@ -691,7 +692,7 @@ cc.Class({ |
691 | this._iCellCountEachRow = 4; | 692 | this._iCellCountEachRow = 4; |
692 | this._fCellMarginTop = 0; | 693 | this._fCellMarginTop = 0; |
693 | this._fCellMarginRight = 24; | 694 | this._fCellMarginRight = 24; |
694 | this._fCellMarginBottom = 16; | 695 | this._fCellMarginBottom = 24; |
695 | this._fCellMarginLeft = 0; | 696 | this._fCellMarginLeft = 0; |
696 | // break; | 697 | // break; |
697 | // default: | 698 | // default: |
... | @@ -921,8 +922,8 @@ cc.Class({ | ... | @@ -921,8 +922,8 @@ cc.Class({ |
921 | // return [null, oScrollParameter]; | 922 | // return [null, oScrollParameter]; |
922 | // } | 923 | // } |
923 | 924 | ||
924 | if (fiFocusTarget && 0 == fiFocusTarget.node.name.indexOf("topNavi") || 0 == fiFocusTarget.node.name.indexOf("topCell")) { | 925 | if (fiFocusTarget && 0 == fiFocusTarget.node.name.indexOf("topNavi")) { |
925 | if (0 != this._fiCurrentFocus.node.name.indexOf("topNavi") && 0 != this._fiCurrentFocus.node.name.indexOf("topCell")) {//如果不是TypeList之间跳转,则哪里来回哪里去 | 926 | if (0 != this._fiCurrentFocus.node.name.indexOf("topNavi")) {//如果不是TypeList之间跳转,则哪里来回哪里去 |
926 | fiFocusTarget = cc.find("topNavi" + this._oSceneContext._iCurrentLeftIndex, leftNavLayout).getComponent(FocusInfo); | 927 | fiFocusTarget = cc.find("topNavi" + this._oSceneContext._iCurrentLeftIndex, leftNavLayout).getComponent(FocusInfo); |
927 | } | 928 | } |
928 | } | 929 | } |
... | @@ -1132,7 +1133,8 @@ cc.Class({ | ... | @@ -1132,7 +1133,8 @@ cc.Class({ |
1132 | this.backToTop(); | 1133 | this.backToTop(); |
1133 | return; | 1134 | return; |
1134 | } else if (0 == fiCurrentFocus.node.getName().indexOf('topCell')) { | 1135 | } else if (0 == fiCurrentFocus.node.getName().indexOf('topCell')) { |
1135 | this.commonSimpleTip("敬请期待!", 3); | 1136 | // this.commonSimpleTip("敬请期待!", 3); |
1137 | this.showComingSoonBox(); | ||
1136 | return; | 1138 | return; |
1137 | } | 1139 | } |
1138 | else { | 1140 | else { |
... | @@ -1271,6 +1273,16 @@ cc.Class({ | ... | @@ -1271,6 +1273,16 @@ cc.Class({ |
1271 | fiFrom.node.getComponent(cc.Sprite).spriteFrame = new cc.SpriteFrame(texture, cc.rect(0, 0, fiFrom.node.width, fiFrom.node.height)); | 1273 | fiFrom.node.getComponent(cc.Sprite).spriteFrame = new cc.SpriteFrame(texture, cc.rect(0, 0, fiFrom.node.width, fiFrom.node.height)); |
1272 | }); | 1274 | }); |
1273 | } | 1275 | } |
1276 | if (0 == fiFrom.node.getName().indexOf('ComingSoonConfirm')) { | ||
1277 | cc.loader.loadRes("SystemExit/btn_confirm_comming_soon", cc.Texture2D, function (err, texture) { | ||
1278 | fiFrom.node.getComponent(cc.Sprite).spriteFrame = new cc.SpriteFrame(texture, cc.rect(0, 0, fiFrom.node.width, fiFrom.node.height)); | ||
1279 | }); | ||
1280 | } | ||
1281 | if (0 == fiFrom.node.getName().indexOf('ComingSoonCancel')) { | ||
1282 | cc.loader.loadRes("SystemExit/btn_cancel_comming_soon", cc.Texture2D, function (err, texture) { | ||
1283 | fiFrom.node.getComponent(cc.Sprite).spriteFrame = new cc.SpriteFrame(texture, cc.rect(0, 0, fiFrom.node.width, fiFrom.node.height)); | ||
1284 | }); | ||
1285 | } | ||
1274 | }, | 1286 | }, |
1275 | 1287 | ||
1276 | onAfterFocusChange: function (event) { | 1288 | onAfterFocusChange: function (event) { |
... | @@ -1383,7 +1395,8 @@ cc.Class({ | ... | @@ -1383,7 +1395,8 @@ cc.Class({ |
1383 | if (0 == fiTo.node.getName().indexOf('view_pager_label') || 0 == fiTo.node.getName().indexOf('topNavi') | 1395 | if (0 == fiTo.node.getName().indexOf('view_pager_label') || 0 == fiTo.node.getName().indexOf('topNavi') |
1384 | || 0 == fiTo.node.getName().indexOf('topCell') || 0 == fiTo.node.getName().indexOf('backToTop') | 1396 | || 0 == fiTo.node.getName().indexOf('topCell') || 0 == fiTo.node.getName().indexOf('backToTop') |
1385 | || 0 == fiTo.node.getName().indexOf('update_btn') || 0 == fiTo.node.getName().indexOf('close_btn') | 1397 | || 0 == fiTo.node.getName().indexOf('update_btn') || 0 == fiTo.node.getName().indexOf('close_btn') |
1386 | || 0 == fiTo.node.getName().indexOf('Confirm') || 0 == fiTo.node.getName().indexOf('Cancel')) { | 1398 | || 0 == fiTo.node.getName().indexOf('Confirm') || 0 == fiTo.node.getName().indexOf('Cancel') |
1399 | || 0 == fiTo.node.getName().indexOf('ComingSoonConfirm') || 0 == fiTo.node.getName().indexOf('ComingSoonCancel')) { | ||
1387 | this._cFocus.hide(); | 1400 | this._cFocus.hide(); |
1388 | } else { | 1401 | } else { |
1389 | if (!this._bIsScrollViewMoving) | 1402 | if (!this._bIsScrollViewMoving) |
... | @@ -1411,6 +1424,17 @@ cc.Class({ | ... | @@ -1411,6 +1424,17 @@ cc.Class({ |
1411 | fiTo.node.getComponent(cc.Sprite).spriteFrame = new cc.SpriteFrame(texture, cc.rect(0, fiTo.node.height, fiTo.node.width, fiTo.node.height)); | 1424 | fiTo.node.getComponent(cc.Sprite).spriteFrame = new cc.SpriteFrame(texture, cc.rect(0, fiTo.node.height, fiTo.node.width, fiTo.node.height)); |
1412 | }); | 1425 | }); |
1413 | } | 1426 | } |
1427 | |||
1428 | if (0 == fiTo.node.getName().indexOf('ComingSoonConfirm')) { | ||
1429 | cc.loader.loadRes("SystemExit/btn_confirm_comming_soon", cc.Texture2D, function (err, texture) { | ||
1430 | fiTo.node.getComponent(cc.Sprite).spriteFrame = new cc.SpriteFrame(texture, cc.rect(0, fiTo.node.height, fiTo.node.width, fiTo.node.height)); | ||
1431 | }); | ||
1432 | } | ||
1433 | if (0 == fiTo.node.getName().indexOf('ComingSoonCancel')) { | ||
1434 | cc.loader.loadRes("SystemExit/btn_cancel_comming_soon", cc.Texture2D, function (err, texture) { | ||
1435 | fiTo.node.getComponent(cc.Sprite).spriteFrame = new cc.SpriteFrame(texture, cc.rect(0, fiTo.node.height, fiTo.node.width, fiTo.node.height)); | ||
1436 | }); | ||
1437 | } | ||
1414 | }, | 1438 | }, |
1415 | 1439 | ||
1416 | doCurrentFocusTVLinkAction: function (strAction) { | 1440 | doCurrentFocusTVLinkAction: function (strAction) { | ... | ... |
This diff is collapsed.
Click to expand it.

5.61 KB

10.2 KB

9.93 KB

13.2 KB
assets/resources/VideoPlayer/video_bg.png
0 → 100644

18.4 KB
... | @@ -164,9 +164,9 @@ | ... | @@ -164,9 +164,9 @@ |
164 | "name": "个人中心", | 164 | "name": "个人中心", |
165 | "left": 1150, | 165 | "left": 1150, |
166 | "top": 8, | 166 | "top": 8, |
167 | "width": 80, | 167 | "width": 60, |
168 | "code": "eb954b1e-712e-415c-ba27-wergherg", | 168 | "code": "eb954b1e-712e-415c-ba27-wergherg", |
169 | "height": 80, | 169 | "height": 60, |
170 | "tvlink": { | 170 | "tvlink": { |
171 | "click": [ | 171 | "click": [ |
172 | { | 172 | { |
... | @@ -184,8 +184,8 @@ | ... | @@ -184,8 +184,8 @@ |
184 | "name": "订购", | 184 | "name": "订购", |
185 | "left": 1060, | 185 | "left": 1060, |
186 | "top": 8, | 186 | "top": 8, |
187 | "width": 80, | 187 | "width": 60, |
188 | "height": 80, | 188 | "height": 60, |
189 | "code": "eb954b1e-712e-415c-ba27-asgerg", | 189 | "code": "eb954b1e-712e-415c-ba27-asgerg", |
190 | "tvlink": { | 190 | "tvlink": { |
191 | "click": [ | 191 | "click": [ | ... | ... |
-
Please register or sign in to post a comment