Fixed timeline for uploaded trace + dump files.
Now when uploading and opening trace and dump files at the same time, the timeline should be fully interactive in Global, Focused and Targeted modes. Timestamps should appear and change as you click along the timeline. Test: Start a trace. Run a dump on another Winscope instance. End the first trace. Download the files from both instances, upload and open them on a separate instance. Check that the timestamp changes when selecting different parts of the timeline in different modes. bottom of Winscope. Bug: b/163105631 Change-Id: I979dfe5eea9937b64f17ab62b2c068fac507ec87
This commit is contained in:
@@ -91,7 +91,8 @@
|
||||
name="navigationStyle"
|
||||
md-dense
|
||||
>
|
||||
<md-icon-option :value="NAVIGATION_STYLE.GLOBAL"
|
||||
<md-icon-option
|
||||
:value="NAVIGATION_STYLE.GLOBAL"
|
||||
icon="public"
|
||||
desc="Consider all timelines for navigation"
|
||||
/>
|
||||
@@ -412,7 +413,11 @@ export default {
|
||||
}
|
||||
|
||||
if (this.navigationStyle === NAVIGATION_STYLE.FOCUSED) {
|
||||
return this.focusedFile;
|
||||
//dumps do not have a timeline, so if scrolling over a dump, show merged timeline
|
||||
if (this.focusedFile.timeline) {
|
||||
return this.focusedFile;
|
||||
}
|
||||
return this.mergedTimeline;
|
||||
}
|
||||
|
||||
if (this.navigationStyle === NAVIGATION_STYLE.CUSTOM) {
|
||||
|
||||
@@ -320,7 +320,7 @@ const FILE_DECODERS = {
|
||||
mime: 'application/octet-stream',
|
||||
protoType: SfDumpMessage,
|
||||
transform: SurfaceFlingerDump.fromProto,
|
||||
timeline: false,
|
||||
timeline: true,
|
||||
},
|
||||
},
|
||||
[FILE_TYPES.WINDOW_MANAGER_DUMP]: {
|
||||
@@ -331,7 +331,7 @@ const FILE_DECODERS = {
|
||||
mime: 'application/octet-stream',
|
||||
protoType: WmDumpMessage,
|
||||
transform: WindowManagerDump.fromProto,
|
||||
timeline: false,
|
||||
timeline: true,
|
||||
},
|
||||
},
|
||||
[FILE_TYPES.WAYLAND_DUMP]: {
|
||||
@@ -342,7 +342,7 @@ const FILE_DECODERS = {
|
||||
mime: 'application/octet-stream',
|
||||
protoType: WaylandDumpMessage,
|
||||
transform: transform_wl_outputstate,
|
||||
timeline: false,
|
||||
timeline: true,
|
||||
},
|
||||
},
|
||||
[FILE_TYPES.SCREEN_RECORDING]: {
|
||||
|
||||
@@ -252,6 +252,9 @@ const store = new Vuex.Store({
|
||||
},
|
||||
updateTimelineTime(context, timestamp) {
|
||||
for (const file of context.getters.files) {
|
||||
//dumps do not have a timeline, so only look at files with timelines to update the timestamp
|
||||
if (!file.timeline) continue;
|
||||
|
||||
const type = file.type;
|
||||
const entryIndex = findLastMatchingSorted(
|
||||
file.timeline,
|
||||
|
||||
Reference in New Issue
Block a user