[ 
https://issues.apache.org/jira/browse/WEEX-556?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=16576064#comment-16576064
 ] 

ASF GitHub Bot commented on WEEX-556:
-------------------------------------

cxfeng1 closed pull request #1418: [WEEX-556][iOS] Fix video play state is not 
'play' while set autoplay…
URL: https://github.com/apache/incubator-weex/pull/1418
 
 
   

This is a PR merged from a forked repository.
As GitHub hides the original diff on merge, it is displayed below for
the sake of provenance:

As this is a foreign pull request (from a fork), the diff is supplied
below (as it won't show otherwise due to GitHub magic):

diff --git a/ios/sdk/WeexSDK/Sources/Component/WXVideoComponent.m 
b/ios/sdk/WeexSDK/Sources/Component/WXVideoComponent.m
index cf3a5fc681..c6b955e0bf 100644
--- a/ios/sdk/WeexSDK/Sources/Component/WXVideoComponent.m
+++ b/ios/sdk/WeexSDK/Sources/Component/WXVideoComponent.m
@@ -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];
@@ -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


 

----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on GitHub and use the
URL above to go to the specific comment.
 
For queries about this service, please contact Infrastructure at:
us...@infra.apache.org


> Video play state is not 'play' while set autoplay to true
> ---------------------------------------------------------
>
>                 Key: WEEX-556
>                 URL: https://issues.apache.org/jira/browse/WEEX-556
>             Project: Weex
>          Issue Type: Bug
>          Components: iOS
>            Reporter: Xiaomin Cai
>            Assignee: XuYouyang
>            Priority: Minor
>
> http://dotwe.org/vue/af01551f3368a00a58bec35e22fec65a



--
This message was sent by Atlassian JIRA
(v7.6.3#76005)

Reply via email to