2
0
mirror of https://github.com/KDE/kdeconnect-android synced 2025-09-05 16:45:08 +00:00

Added support for Ctrl, Alt, Shift combinations and F keys to keyboard.

To use with keyboards like Hacker's Keyboard (tested with it).
This commit is contained in:
Albert Vaca
2015-01-06 00:05:44 -08:00
parent 96e8610363
commit 332c2d4856
2 changed files with 90 additions and 42 deletions

View File

@@ -22,7 +22,6 @@ package org.kde.kdeconnect.Plugins.MousePadPlugin;
import android.app.Activity;
import android.app.AlertDialog;
import android.content.Context;
import android.content.Intent;
import android.graphics.drawable.Drawable;
import android.view.View;
@@ -142,15 +141,7 @@ public class MousePadPlugin extends Plugin {
device.sendPackage(np);
}
public void sendKey(String utfChar) {
NetworkPackage np = new NetworkPackage(NetworkPackage.PACKAGE_TYPE_MOUSEPAD);
np.set("key", utfChar);
device.sendPackage(np);
}
public void sendSpecialKey(int specialKey) {
NetworkPackage np = new NetworkPackage(NetworkPackage.PACKAGE_TYPE_MOUSEPAD);
np.set("specialKey", specialKey);
public void sendKeyboardPacket(NetworkPackage np) {
device.sendPackage(np);
}