Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 0e55469d authored by Hao Chen's avatar Hao Chen
Browse files

Add Display ID when Getting Display State

Multiple displays can be opened concurrently, so display ID
is needed when getting status of active displays.

Test: build
Bug: 262779341

Change-Id: I12af698be85ba72f0fb81f143441956dd0bfe1d2
parent 36f26f1a
Loading
Loading
Loading
Loading
+1 −0
Original line number Original line Diff line number Diff line
@@ -47,4 +47,5 @@ interface IEvsEnumerator {
  android.hardware.automotive.evs.IEvsDisplay openDisplay(in int id);
  android.hardware.automotive.evs.IEvsDisplay openDisplay(in int id);
  android.hardware.automotive.evs.IEvsUltrasonicsArray openUltrasonicsArray(in String ultrasonicsArrayId);
  android.hardware.automotive.evs.IEvsUltrasonicsArray openUltrasonicsArray(in String ultrasonicsArrayId);
  void registerStatusCallback(in android.hardware.automotive.evs.IEvsEnumeratorStatusCallback callback);
  void registerStatusCallback(in android.hardware.automotive.evs.IEvsEnumeratorStatusCallback callback);
  android.hardware.automotive.evs.DisplayState getDisplayStateById(in int id);
}
}
+19 −4
Original line number Original line Diff line number Diff line
@@ -78,12 +78,12 @@ interface IEvsEnumerator {
    byte[] getDisplayIdList();
    byte[] getDisplayIdList();


    /**
    /**
     * This call requests the current state of the display
     * This call requests the current state of the primary display
     *
     *
     * If there is no open display, this returns DisplayState::NOT_OPEN. otherwise, it returns
     * If there is no open display, this returns DisplayState::NOT_OPEN. otherwise, it returns
     * the actual state of the active display.  This call is replicated on the IEvsEnumerator
     * the actual state of the active primary display.  This call is replicated on the
     * interface in order to allow secondary clients to monitor the state of the EVS display
     * IEvsEnumerator interface in order to allow secondary clients to monitor the state of the EVS
     * without acquiring exclusive ownership of the display.
     * display without acquiring exclusive ownership of the display.
     *
     *
     * @return Current DisplayState of this Display.
     * @return Current DisplayState of this Display.
     * @throws EvsResult::OWNERSHIP_LOST if current display is inactive
     * @throws EvsResult::OWNERSHIP_LOST if current display is inactive
@@ -163,4 +163,19 @@ interface IEvsEnumerator {
     * @param in callback IEvsEnumeratorStatusCallback implementation
     * @param in callback IEvsEnumeratorStatusCallback implementation
     */
     */
    void registerStatusCallback(in IEvsEnumeratorStatusCallback callback);
    void registerStatusCallback(in IEvsEnumeratorStatusCallback callback);

    /**
     * This call requests the current state of the display
     *
     * If the requested display is not active, this returns DisplayState::NOT_OPEN. otherwise, it
     * returns the actual state of the active display.  This call is replicated on the
     * IEvsEnumerator interface in order to allow secondary clients to monitor the state of the EVS
     * display without acquiring exclusive ownership of the display.
     *
     * @param in id ID of the requested display.
     * @return Current DisplayState of this Display.
     * @throws EvsResult::OWNERSHIP_LOST if current display is inactive
     *        EvsResult::PERMISSION_DENIED if the process is not permitted to do this operation.
     */
    DisplayState getDisplayStateById(in int id);
}
}