Fix NoteOpEvent to return the last entry with max duration

We should consider duration as well when reading
the last entry at the same time

Change-Id: Ie94e552e065de0142927a08a144bb16220481c8b
Fix: 357150294
Test: manual
Test: atest CtsAppOpsTestCases
FLAG: EXEMPT bugfix
1 file changed