windowTitle: Add custom window title widget

Fixes #202
This commit is contained in:
Sophie Herold 2023-12-20 20:26:32 +01:00
parent d39bd774d5
commit d185973815
4 changed files with 107 additions and 1 deletions

View file

@ -52,6 +52,7 @@ 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
@ -78,6 +79,8 @@ 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>,