Skip to content

general: Use new libadwaita widgets and utilities

Christopher Davis requested to merge wip/cdavis/dual-pane-adaptive-states into main

AdwLeaflet and friends cause undefined behavior by making changes to widget size while the widget is in the process of being resized. This causes applications to emit warnings and criticals in the process of resizing, and in order to not exacerbate the issue we end up limited in what we can do at different sizes.

AdwBreakpoint is a new utility that developers attach to their top-level windows. The object has set horizontal and vertical breakpoints, and can set properties on other objects when a breakpoint is reached. You can also listen to the enter and exit breakpoints to make arbitrary changes in code.

AdwNavigationSplitView is a replacement for Leaflet that expects developers to use adaptive states to manage whether or not it is folded. AdwNavigationSplitView makes use of another new widget, AdwNavigationPage, that also manages titles on headers and tooltips for navigating back and forward in the NavigationView and NavigationSplitView widgets.

Widgets like Leaflet are deprecated, and apps are expected to move to breakpoints, navigation pages, and navigation split views. This commit does exactly that for Contacts.

We also now use AdwToolbarView, which provides consistent styling for toolbars - especially within AdwNavigationSplitView.

Edited by Christopher Davis

Merge request reports