mirror of
https://github.com/KDE/kdeconnect-android
synced 2025-08-31 06:05:12 +00:00
Don't convert shuffle value to String when sending the command
This commit is contained in:
committed by
Nicolas Fella
parent
8da49741f2
commit
843d25d112
@@ -200,7 +200,7 @@ public class MprisPlugin extends Plugin {
|
||||
}
|
||||
|
||||
public void setShuffle(boolean shuffle) {
|
||||
MprisPlugin.this.sendCommand(getPlayer(), "setShuffle", String.valueOf(shuffle));
|
||||
MprisPlugin.this.sendCommand(getPlayer(), "setShuffle", shuffle);
|
||||
}
|
||||
|
||||
public void setVolume(int volume) {
|
||||
@@ -281,6 +281,13 @@ public class MprisPlugin extends Plugin {
|
||||
device.sendPacket(np);
|
||||
}
|
||||
|
||||
private void sendCommand(String player, String method, boolean value) {
|
||||
NetworkPacket np = new NetworkPacket(PACKET_TYPE_MPRIS_REQUEST);
|
||||
np.set("player", player);
|
||||
np.set(method, value);
|
||||
device.sendPacket(np);
|
||||
}
|
||||
|
||||
private void sendCommand(String player, String method, int value) {
|
||||
NetworkPacket np = new NetworkPacket(PACKET_TYPE_MPRIS_REQUEST);
|
||||
np.set("player", player);
|
||||
|
Reference in New Issue
Block a user