mirror of
https://github.com/YGGverse/Yoda.git
synced 2026-03-31 16:45:27 +00:00
simplify construction
This commit is contained in:
parent
58394f84ca
commit
ffca1d3d60
1 changed files with 1 additions and 3 deletions
|
|
@ -169,14 +169,12 @@ impl Request {
|
|||
// Note:
|
||||
// * Custom GestureClick is not an option here, as GTK Entry has default controller
|
||||
// * This is experimental feature does not follow native GTK behavior @TODO make optional
|
||||
if !has_focus.take()
|
||||
if !has_focus.replace(state.contains(StateFlags::FOCUS_WITHIN))
|
||||
&& state.contains(StateFlags::ACTIVE | StateFlags::FOCUS_WITHIN)
|
||||
&& this.selection_bounds().is_none()
|
||||
{
|
||||
this.select_region(0, -1)
|
||||
}
|
||||
// Update last focus state
|
||||
has_focus.replace(state.contains(StateFlags::FOCUS_WITHIN));
|
||||
}
|
||||
});
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue