mirror of
https://github.com/kavishdevar/librepods.git
synced 2026-02-13 21:16:18 +00:00
[Linux] Don't use playerctl for current media state
This commit is contained in:
committed by
Tim Gromeyer
parent
aaf82c9738
commit
48ae249405
@@ -44,12 +44,7 @@ void MediaController::handleEarDetection(EarDetection *earDetection)
|
||||
|
||||
if (shouldPause && isActiveOutputDeviceAirPods())
|
||||
{
|
||||
QProcess process;
|
||||
process.start("playerctl", QStringList() << "status");
|
||||
process.waitForFinished();
|
||||
QString playbackStatus = process.readAllStandardOutput().trimmed();
|
||||
LOG_DEBUG("Playback status: " << playbackStatus);
|
||||
if (playbackStatus == "Playing")
|
||||
if (m_mediaState == Playing)
|
||||
{
|
||||
pause();
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user