2
0
mirror of https://github.com/KDE/kdeconnect-android synced 2025-08-29 13:17:43 +00:00

Assume computer by default from the phone for device with no type

This commit is contained in:
Albert Vaca 2015-09-09 01:11:46 -07:00
parent f56fc9ceb8
commit 1fe01db26e

View File

@ -51,7 +51,6 @@ import java.security.spec.X509EncodedKeySpec;
import java.util.ArrayList; import java.util.ArrayList;
import java.util.HashMap; import java.util.HashMap;
import java.util.HashSet; import java.util.HashSet;
import java.util.Objects;
import java.util.Set; import java.util.Set;
import java.util.Timer; import java.util.Timer;
import java.util.TimerTask; import java.util.TimerTask;
@ -105,14 +104,14 @@ public class Device implements BaseLink.PackageReceiver {
public static DeviceType FromString(String s) { public static DeviceType FromString(String s) {
if ("tablet".equals(s)) return Tablet; if ("tablet".equals(s)) return Tablet;
if ("desktop".equals(s)) return Computer; if ("phone".equals(s)) return Phone;
return Phone; //Default return Computer; //Default
} }
public String toString() { public String toString() {
switch (this) { switch (this) {
case Tablet: return "tablet"; case Tablet: return "tablet";
case Computer: return "desktop"; case Phone: return "phone";
default: return "phone"; default: return "desktop";
} }
} }
} }