mirror of
https://github.com/Droid-Deck/DroidDeck.git
synced 2026-11-21 13:55:58 +00:00
refactor(input): name the scene input types and wheel scale (#2524)
nativeSendSceneInput took bare integers (3, 4, 6, 11, 12) and the wheel step (120) and pointer fixed-point scale (256) were repeated inline. BottomDesktopPanel kept its own private copies of three of them. Move them to WaylandCompositor next to the native method and use them at every call site. No behavior change. Co-authored-by: Dennis Zabolotny <15849186+zdennisz@users.noreply.github.com>
This commit is contained in:
1 parent
76aa3771b7
commit
e3d86c4b17
4 files changed
+21
-20
No files matched your search
@@ -194,7 +194,7 @@ object BottomDesktop {
|
||||
send(target, Message.obtain(null, Comp.MSG_POINTER, x, y))
|
||||
}
|
||||
|
||||
/** Button (3), wheel (4) and smooth-scroll (12) input, as `WaylandCompositor.nativeSendSceneInput` takes it. */
|
||||
/** Button, wheel and finger-scroll input, using the `WaylandCompositor.SCENE_*` types `nativeSendSceneInput` takes. */
|
||||
fun sendScene(type: Int, a: Int, b: Int = 0) {
|
||||
val target = service ?: return
|
||||
send(target, Message.obtain(null, Comp.MSG_SCENE, type, a).apply {
|
||||
|
||||
Reference in new issue
Block a user