Toggle navigation
Toggle navigation
This project
Loading...
Sign in
developOne
/
harmonyPool
Go to a project
Toggle navigation
Projects
Groups
Snippets
Help
Toggle navigation pinning
Project
Activity
Repository
Pipelines
Graphs
Issues
0
Merge Requests
0
Wiki
Network
Create a new issue
Builds
Commits
Authored by
wangliang_wd
2024-06-12 14:18:26 +0800
Browse Files
Options
Browse Files
Download
Email Patches
Plain Diff
Commit
017b348a7f151b7101b9c2eb0ed1423556abbda9
017b348a
1 parent
9e04f345
feat:增加启动广告视频播放
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
10 additions
and
1 deletions
sight_harmony/products/phone/src/main/ets/pages/launchPage/LaunchAdvertisingPage.ets
sight_harmony/products/phone/src/main/ets/pages/launchPage/LaunchAdvertisingPage.ets
View file @
017b348
...
...
@@ -7,7 +7,6 @@ import LaunchDataModel, { defaultLaunchModel } from '../viewModel/LaunchDataMode
import { ParamType, TrackConstants, TrackingButton, TrackingContent } from 'wdTracking/Index';
import { ContentDTO } from 'wdBean/Index';
import { Core } from '@ohos/hypium';
@Entry
...
...
@@ -19,6 +18,8 @@ struct LaunchAdvertisingPage {
@State defaultModel:defaultLaunchModel = new defaultLaunchModel()
private controller:VideoController | undefined;
enter() {
WDRouterRule.jumpWithReplacePage(WDRouterPage.mainPage)
clearInterval(this.timer)
...
...
@@ -60,6 +61,14 @@ struct LaunchAdvertisingPage {
Column(){
if(this.defaultModel.showType === '1'){
//显示视频播放
Video({
src: this.defaultModel.bootVideoUrl,
previewUri: this.defaultModel.bootVideoScreenUrl,
controller: this.controller
})
.objectFit(ImageFit.Contain) //设置视频适配模式
.width('100%')
.height('100%')
}else {
//显示图片
Image(this.defaultModel.bootScreenUrl)
...
...
Please
register
or
login
to post a comment