Gestures: flick, long-press alternates, trackpad, layer slide, rollover
- PointerTracker: per-finger gesture state machine (pure, unit-tested) - AlternatesPicker + AlternatesPopup.qml: long-press choices, finger selects - Space long-press trackpad moves the cursor with arrow keysyms - Slide from .?123 onto a symbol types it and switches back - New finger commits pending taps (iOS rollover) - Flick animation: secondary symbol slides down as the finger moves - Transparent popup margin with an input region that passes clicks through - tst_keyboardsurface: end-to-end gesture tests on the real QML Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This commit is contained in:
@@ -1,6 +1,5 @@
|
||||
#include "engine/InputEngine.h"
|
||||
#include "input/KeyboardController.h"
|
||||
#include "layout/LayoutLoader.h"
|
||||
#include "layout/LayoutModel.h"
|
||||
#include "layout/LayoutRepository.h"
|
||||
|
||||
@@ -106,6 +105,22 @@ private Q_SLOTS:
|
||||
QCOMPARE(model.layerName(), u"numbers");
|
||||
}
|
||||
|
||||
void slideTypesSymbolAndSwitchesBack()
|
||||
{
|
||||
KeyDef layer = makeKey(KeyType::LayerSwitch);
|
||||
layer.target = u"numbers"_s;
|
||||
controller->keyDown(layer, 0);
|
||||
controller->slideReleased(makeKey(KeyType::Character, u"5"_s), 100);
|
||||
QCOMPARE(engine.output, u"5");
|
||||
QCOMPARE(model.layerName(), u"letters");
|
||||
}
|
||||
|
||||
void trackpadMovesCursor()
|
||||
{
|
||||
controller->moveCursor({2, -1});
|
||||
QCOMPARE(engine.keysyms, (QList<quint32>{XKB_KEY_Right, XKB_KEY_Right, XKB_KEY_Up}));
|
||||
}
|
||||
|
||||
void globeCyclesLayouts()
|
||||
{
|
||||
QCOMPARE(model.layoutName(), u"English (US)");
|
||||
|
||||
Reference in New Issue
Block a user