window: Limit HeaderBar to min width as nat width

Before we were doing the same with just the title in the HeaderBar. This
gave problems with correctly measuring for ADW_CENTERING_POLICY_LOOSE.
This commit is contained in:
Sophie Herold 2024-01-09 15:56:23 +01:00
parent 7ebc902838
commit 446ae5063a
7 changed files with 93 additions and 109 deletions

View file

@ -53,7 +53,6 @@ const HIDE_CONTROLS_IDLE_TIMEOUT: u64 = 3000;
mod imp {
use super::*;
use crate::widgets::LpWindowTitle;
// To use composite templates, you need
// to use derive macro. Derive macros generate
@ -80,8 +79,6 @@ mod imp {
#[template_child]
pub(super) headerbar: TemplateChild<adw::HeaderBar>,
#[template_child]
pub(super) title: TemplateChild<LpWindowTitle>,
#[template_child]
pub(super) headerbar_events: TemplateChild<gtk::EventControllerMotion>,
#[template_child]
pub(super) properties_button: TemplateChild<gtk::ToggleButton>,