Skip to content
Commit 6515aa66 authored by Noah Davis's avatar Noah Davis 🌵
Browse files

kstyle: Add QFocusFrame to non-view/delegate interactive widget

There are 2 parts that contain the bulk of the code in this patch.

Style::event() is used to apply the QFocusFrame to a widget when it gets
focus with a keyboard input related focus reason. If the focused widget
has a focusProxy, this makes sure the QFocusFrame is applied to the
focusProxy instead.

Style::drawFocusFrame() is mostly what you'd expect. It draws a focus
frame based on the type of widget the QFocusFrame was applied to. I had
to do a workaround for QFocusFrame not fully repainting ouside the
bounds of QSliders and QDials when the handle moves though. What I do is
check if `_focusFrame` is defined and then `_focusFrame->update()`.

BUG: 443469


(cherry picked from commit 586e7462)
parent 8f2d1e7b
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment