repositories / dotfiles

dotfiles

bugabingas dorkfiles

owned by bugabinga

caldav: auto-focus the setup form's first field on open

f67418dbf2887eeb80b25aee006ff620805e1e08

Oliver Jan Krylow <oliver@bugabinga.net> ·

unsigned

Browse filesCompare with HEAD

Grab keyboard focus into the URL field via Qt.callLater (fires after the
card claims the surface focus) on both completion and visibility change,
so a first-run user can type immediately. The popout surface already holds
WlrKeyboardFocus.Exclusive while visible.

Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>

Changed files (1)

quickshell/nuguland/PopoutHost.qml

Modified
522 522 width: parent ? parent.width : 0
523 523 spacing: 8
525 + // grab keyboard focus into the first field once the card has
526 + // finished claiming the surface focus (callLater wins the race)
527 + onVisibleChanged: if (visible) Qt.callLater(urlField.field.forceActiveFocus)
528 + Component.onCompleted: if (visible) Qt.callLater(urlField.field.forceActiveFocus)
525 530 component Field: Rectangle {
526 531 property alias field: ti
527 532 property string placeholder: ""