this repo has no description
13
fork

Configure Feed

Select the types of activity you want to include in your feed.

vxfw: remove assert

We asserted before adding the root. This meant we could panic in
situations where the root was intended to be the focused widget

+1 -4
+1 -4
src/vxfw/App.zig
··· 530 530 // Find the path to the focused widget. This builds a list that has the first element as the 531 531 // focused widget, and walks backward to the root. It's possible our focused widget is *not* 532 532 // in this tree. If this is the case, we refocus to the root widget 533 - const has_focus = try self.childHasFocus(allocator, surface); 533 + _ = try self.childHasFocus(allocator, surface); 534 534 535 - // We assert that the focused widget *must* be in the widget tree. There is certianly a 536 - // logic bug in the code somewhere if this is not the case 537 - assert(has_focus); // Focused widget not found in Surface tree 538 535 if (!self.root.eql(surface.widget)) { 539 536 // If the root of surface is not the initial widget, we append the initial widget 540 537 try self.path_to_focused.append(allocator, self.root);