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

Commit

Permalink
[WEEX-629][iOS] fix report firstScreenRenderTime failed (#1567)
Browse files Browse the repository at this point in the history
  • Loading branch information
lucky-chen authored and cxfeng1 committed Sep 24, 2018
1 parent d069b12 commit 7f1bba7
Showing 1 changed file with 3 additions and 5 deletions.
8 changes: 3 additions & 5 deletions ios/sdk/WeexSDK/Sources/Monitor/WXMonitor.m
Original file line number Diff line number Diff line change
Expand Up @@ -67,6 +67,9 @@ + (void)performancePoint:(WXPerformanceTag)tag didEndWithInstance:(WXSDKInstance
}

dict[kEndKey] = @(CACurrentMediaTime() * 1000);
if (tag == WXPTFirstScreenRender) {
[instance.apmInstance onStage:KEY_PAGE_STAGES_FSRENDER];
}

// if (tag == WXPTAllRender) {
// [self performanceFinish:instance];
Expand Down Expand Up @@ -236,11 +239,6 @@ + (void)commitPerformanceWithDict:(NSMutableDictionary *)commitDict instance:(WX
if (appMonitor && [appMonitor respondsToSelector:@selector(commitAppMonitorArgs:)]){
[appMonitor commitAppMonitorArgs:commitDict];
}
long oldFSRenderCostTime = [commitDict[FSRENDERTIME] longValue];
if (oldFSRenderCostTime > 0) {
long oldFSRenderTime = instance.performance.renderUnixTimeOrigin + oldFSRenderCostTime;
[instance.apmInstance onStageWithTime:KEY_PAGE_STAGES_FSRENDER time:oldFSRenderTime];
}

[self printPerformance:commitDict];
[WXTracingManager commitTracingSummaryInfo:commitDict withInstanceId:instance.instanceId];
Expand Down

0 comments on commit 7f1bba7

Please sign in to comment.