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BAAkB,CAAC,IAAmB;YAClC,IAAI,OAAO,GAAW,EAAE,CAAC;YACzB,IAAI,IAAI,IAAI,4BAAa,CAAC,EAAE,EAAE;gBAC1B,OAAO,GAAG,mCAAgB,CAAC,cAAc,CAAC,2BAAY,CAAC,kCAAkC,CAAC,CAAC;aAC9F;iBAAM;gBACH,OAAO,GAAG,mCAAgB,CAAC,cAAc,CAAC,2BAAY,CAAC,qCAAqC,CAAC,CAAC;aACjG;YACD,qBAAS,CAAC,SAAS,CAAC,OAAO,CAAC,CAAC;YAC7B,IAAI,CAAC,IAAI,CAAC,SAAS,EAAE,CAAC;QAC1B,CAAC;KAcJ,CAAA;IAhFU,0BAAI,GAAG,uBAAuB,CAAC;IADrB,qBAAqB;QADzC,qCAAY,CAAC,+BAAgB,CAAC;OACV,qBAAqB,CAiFzC;IAAD,4BAAC;KAAA;kBAjFoB,qBAAqB","file":"","sourceRoot":"/","sourcesContent":["\n// import { DailyQuestType } from \"../../../avg/EditorEnums\";\nimport { Presenter } from \"../../../common/classbase/PresenterBase\";\nimport { GetRewardType } from \"../../../common/gameplay/gamedata/GameEnumData\";\nimport { GameTextData } from \"../../../common/gameplay/gamedata/GameTextData\";\nimport { UIManager } from \"../../../common/gameplay/managers/UIManager\";\nimport { CommonLocation, ShowLocationType, ShowType } from \"../../Enums\";\nimport GameDotMgr from \"../../GameDotMgr\";\nimport { GameModelManager } from \"../../model/GameModelManager\";\nimport { RegPresenter } from \"../PresenterCCViewFactory\";\nimport { PlotStopView, PlotStopViewProps, PlotStopViewType } from \"../view/type/PlotStopView\";\n@RegPresenter(PlotStopViewType)\nexport default class PlotStopViewPresenter extends Presenter<undefined, PlotStopView>{\n static uuid = \"PlotStopViewPresenter\";\n private _viewProps: PlotStopViewProps;\n constructor() {\n super();\n }\n initViewProps() {\n this._viewProps = {\n unlockPlotCallbackFunc: this.unlockPlotCallbackFunc,\n onAdBtnOption: this.onAdBtnOption,\n onAddRes: this.onAddRes,\n onCancelAdCallback: this.onCancelAdCallback,\n }\n }\n onOpen() {\n super.onOpen(undefined);\n this.onShow();\n }\n onShow() {\n super.onShow();\n this.initViewProps();\n this._view.setProps(this._viewProps);\n this.view.adButton.loadSVConfig();\n\n let t = this.view.getSvBtnType();\n if (t && t === \"share\" || t === \"video\") {\n this.onAdBtnOption(ShowType.SHOW, t);\n }\n }\n onClose() {\n super.onClose();\n }\n onEnterForeground() {\n super.onEnterForeground();\n }\n onEnterBackground() {\n super.onEnterBackground();\n }\n onHide() {\n }\n\n unlockPlotCallbackFunc = () => {\n\n }\n\n onAdBtnOption = (optionType: ShowType, adType: \"share\" | \"video\", ret?: boolean) => {\n let location = CommonLocation.Nextplot;\n if (adType === \"share\") {\n GameDotMgr.getInstance().dotShare(optionType, ShowLocationType.Share + location);\n }\n if (adType === \"video\") {\n GameDotMgr.getInstance().dotVideo(optionType, ShowLocationType.Video + location);\n }\n if (optionType === ShowType.FINISH && ret && adType === \"video\") {\n // GameModelManager.addDailyTasks(DailyQuestType.Dq_AdsWatch, 1);\n }\n }\n\n onCancelAdCallback(type: GetRewardType) {\n let content: string = \"\";\n if (type == GetRewardType.Ad) {\n content = GameModelManager.getLanguageTxt(GameTextData.GAME_TEXT_MALL_GIFT_ADFAILED_VALUE);\n } else {\n content = GameModelManager.getLanguageTxt(GameTextData.GAME_TEXT_MALL_GIFT_SHAREFAILED_VALUE);\n }\n UIManager.showToast(content);\n this.view.closeView();\n }\n\n onAddRes = (type: string) => {\n if (type === \"video\") {\n GameModelManager.dealBlockedPlot(true);\n } else {\n if (cc.sys.browserType == cc.sys.BROWSER_TYPE_CHROME) {\n GameModelManager.dealBlockedPlot(true);\n } else {\n UIManager.showToast(GameModelManager.getLanguageTxt(GameTextData.GAME_TEXT_DEAL_BLOCKED_PLOT_FAIL));\n }\n }\n this.view.closeView();\n }\n}"]}