apprt/gtk: comments

pull/9756/head
Mitchell Hashimoto 2025-11-30 07:04:08 -08:00
parent e18a7d9501
commit b8393fd4aa
No known key found for this signature in database
GPG Key ID: 523D5DC389D273BC
1 changed files with 3 additions and 0 deletions

View File

@ -185,6 +185,9 @@ pub const SearchOverlay = extern struct {
pub fn grabFocus(self: *Self) void {
const priv = self.private();
_ = priv.search_entry.as(gtk.Widget).grabFocus();
// Select all text in the search entry field. -1 is distance from
// the end, causing the entire text to be selected.
priv.search_entry.as(gtk.Editable).selectRegion(0, -1);
}