Use ConstraintLayout for BadgedImageView
App icon badge size is based on the view size, as a ratio. Use ConstraintLayout to define the app icon size based on constraints. This way we do not have to recalculate the app icon size manually. If the BadgedImageView size changes, app icon will be resized automatically. App icon badge position is fixed to the right. If it needs to be shown on the left, due to bubble position, we update the location using translationX. Bug: 162857077 Test: verified visually that bubble with app icon looks the same Test: verified visually that when display size changes, app icon changes together with bubble size Test: ran WMShellUnitTests unit tests Change-Id: I63a6cadfc7847dd0c0d9dca6bb6efd11f5b9958e
Loading
Please register or sign in to comment