Ignore failure when un/registering listener for invalid display
- In the wm tests, the virtual display can be removed by the time we go to update the back gesture handler, which can result in an exception that (unnecessarily) crashes SysUI. Bug: 154041177 Test: Manual, not actually able to repro Change-Id: Iec2a0aaeed43254693a6d2ef01205641189a5648
This commit is contained in:
@@ -312,7 +312,7 @@ public class EdgeBackGestureHandler implements DisplayListener,
|
||||
WindowManagerGlobal.getWindowManagerService()
|
||||
.unregisterSystemGestureExclusionListener(
|
||||
mGestureExclusionListener, mDisplayId);
|
||||
} catch (RemoteException e) {
|
||||
} catch (RemoteException | IllegalArgumentException e) {
|
||||
Log.e(TAG, "Failed to unregister window manager callbacks", e);
|
||||
}
|
||||
|
||||
@@ -326,7 +326,7 @@ public class EdgeBackGestureHandler implements DisplayListener,
|
||||
WindowManagerGlobal.getWindowManagerService()
|
||||
.registerSystemGestureExclusionListener(
|
||||
mGestureExclusionListener, mDisplayId);
|
||||
} catch (RemoteException e) {
|
||||
} catch (RemoteException | IllegalArgumentException e) {
|
||||
Log.e(TAG, "Failed to register window manager callbacks", e);
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user