[go: nahoru, domu]

Skip to content
This repository has been archived by the owner on Jun 3, 2021. It is now read-only.

Commit

Permalink
[WEEX-556][iOS] Fix video play state is not 'play' while set autoplay…
Browse files Browse the repository at this point in the history
… to true (#1418)
  • Loading branch information
caixiaomin authored and cxfeng1 committed Aug 10, 2018
1 parent 6f16af7 commit 0fa0610
Showing 1 changed file with 8 additions and 8 deletions.
16 changes: 8 additions & 8 deletions ios/sdk/WeexSDK/Sources/Component/WXVideoComponent.m
Original file line number Diff line number Diff line change
Expand Up @@ -333,14 +333,6 @@ -(void)viewDidLoad
_videoView = (WXVideoView *)self.view;
[_videoView setURL:_videoURL];
[_videoView setPosterURL:_posterURL];
if (_playStatus) {
[_videoView play];
} else {
[_videoView pause];
}
if (_autoPlay) {
[_videoView play];
}
__weak __typeof__(self) weakSelf = self;
_videoView.posterClickHandle = ^{
[weakSelf.videoView play];
Expand All @@ -367,6 +359,14 @@ -(void)viewDidLoad
}
[weakSelf fireEvent:eventType params:nil];
};
if (_playStatus) {
[_videoView play];
} else {
[_videoView pause];
}
if (_autoPlay) {
[_videoView play];
}
}

-(void)updateAttributes:(NSDictionary *)attributes
Expand Down

0 comments on commit 0fa0610

Please sign in to comment.