[gnome-builder/wip/gtk4-port: 190/343] libide/greeter: use AdwWindowTitle
- From: Christian Hergert <chergert src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [gnome-builder/wip/gtk4-port: 190/343] libide/greeter: use AdwWindowTitle
- Date: Mon, 4 Apr 2022 20:02:14 +0000 (UTC)
commit 1ef52fd75dc3f2bc8eb0e9b41108d22f0fbedbb0
Author: Christian Hergert <chergert redhat com>
Date: Wed Mar 30 13:58:57 2022 -0700
libide/greeter: use AdwWindowTitle
src/libide/greeter/ide-greeter-workspace.c | 4 ++--
src/libide/greeter/ide-greeter-workspace.ui | 13 ++-----------
2 files changed, 4 insertions(+), 13 deletions(-)
---
diff --git a/src/libide/greeter/ide-greeter-workspace.c b/src/libide/greeter/ide-greeter-workspace.c
index b96257627..3de902ae4 100644
--- a/src/libide/greeter/ide-greeter-workspace.c
+++ b/src/libide/greeter/ide-greeter-workspace.c
@@ -63,7 +63,7 @@ struct _IdeGreeterWorkspace
GtkButton *select_button;
GtkActionBar *action_bar;
GtkActionBar *projects_action_bar;
- GtkLabel *title;
+ AdwWindowTitle *title;
IdeGreeterButtonsSection *buttons_section;
DzlEmptyState *empty_state;
GtkGestureMultiPress *multipress_gesture;
@@ -216,7 +216,7 @@ stack_notify_visible_child_cb (IdeGreeterWorkspace *self,
full_title = g_strdup_printf (_("Builder — %s"), title);
}
- gtk_label_set_label (self->title, title);
+ adw_window_title_set_title (self->title, title);
gtk_window_set_title (GTK_WINDOW (self), full_title);
sections = ide_str_equal0 ("sections", gtk_stack_get_visible_child_name (stack));
diff --git a/src/libide/greeter/ide-greeter-workspace.ui b/src/libide/greeter/ide-greeter-workspace.ui
index f615eec1b..a27540d7b 100644
--- a/src/libide/greeter/ide-greeter-workspace.ui
+++ b/src/libide/greeter/ide-greeter-workspace.ui
@@ -1,21 +1,12 @@
<?xml version="1.0" encoding="UTF-8"?>
<interface>
- <!-- interface-requires gtk+ 3.24 -->
+ <requires lib="gtk" version="4.0"/>
<template class="IdeGreeterWorkspace" parent="IdeWorkspace">
<child type="titlebar">
<object class="IdeHeaderBar" id="header_bar">
<property name="menu-id">ide-greeter-workspace-menu</property>
- <property name="show-fullscreen-button">false</property>
- <property name="show-close-button">true</property>
- <property name="visible">true</property>
<child type="title">
- <object class="GtkLabel" id="title">
- <property name="visible">true</property>
- <property name="hexpand">true</property>
- <style>
- <class name="title"/>
- </style>
- </object>
+ <object class="AdwWindowTitle" id="title"/>
</child>
<child type="left">
<object class="GtkButton" id="back_button">
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]