We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent 27729cf commit 91afd4bCopy full SHA for 91afd4b
druid/src/widget/textbox.rs
@@ -269,9 +269,8 @@ impl<T: TextStorage + EditableText> Widget<T> for TextBox<T> {
269
self.editor.set_text(data.to_owned());
270
self.editor.rebuild_if_needed(ctx.text(), env);
271
}
272
- LifeCycle::FocusChanged(_is_focused) => {
273
- #[cfg(target_os = "macos")]
274
- if *_is_focused && !self.was_focused_from_click {
+ LifeCycle::FocusChanged(is_focused) => {
+ if cfg!(target_os = "macos") && *is_focused && !self.was_focused_from_click {
275
self.editor.select_all(data);
276
277
self.was_focused_from_click = false;
0 commit comments