Consolidate group playback checks with `hasGroupPlayback` method.

Have a single method that checks whether there is an active group
playback performed i.e. more than one output device connected. This
check should be done on the output device list before appending the
input devices to it, therefore it's better to do in in the
MediaSwitchingController.

Bug: 422288043
Bug: 432107581
Test: atest MediaOutputAdapterTest, MediaOutputAdapterLegacyTest,
MediaSwitchingControllerTest, MediaOutputAdapterScreenshotTest
Flag: EXEMPT refactor

Change-Id: I6eae42ddaa8a0c436390a3e8e692c74f125d9d97
6 files changed