[libadwaita/wip/exalm/demo] demo: Remove app-notification style demo




commit 8ccfbb669afc9d6c335ce6db44a5b20c8c6159ad
Author: Alexander Mikhaylenko <alexm gnome org>
Date:   Mon Dec 27 17:03:20 2021 +0500

    demo: Remove app-notification style demo
    
    We have toasts now and the style is marked as deprecated in docs.

 demo/pages/styles/adw-style-demo-window.c  | 14 -------
 demo/pages/styles/adw-style-demo-window.ui | 62 ------------------------------
 2 files changed, 76 deletions(-)
---
diff --git a/demo/pages/styles/adw-style-demo-window.c b/demo/pages/styles/adw-style-demo-window.c
index 2d7c26d4..477cc95c 100644
--- a/demo/pages/styles/adw-style-demo-window.c
+++ b/demo/pages/styles/adw-style-demo-window.c
@@ -11,7 +11,6 @@ struct _AdwStyleDemoWindow
   GtkWindow *header_bar_window;
   GtkWindow *status_page_window;
   GtkWindow *sidebar_window;
-  GtkRevealer *app_notification_revealer;
   AdwLeaflet *sidebar_leaflet;
 };
 
@@ -56,17 +55,6 @@ sidebar_cb (GtkWidget  *sender,
   gtk_window_present (self->sidebar_window);
 }
 
-static void
-app_notification_cb (GtkWidget  *sender,
-                     const char *name,
-                     GVariant   *param)
-{
-  AdwStyleDemoWindow *self = ADW_STYLE_DEMO_WINDOW (sender);
-  gboolean show = g_variant_get_boolean (param);
-
-  gtk_revealer_set_reveal_child (self->app_notification_revealer, show);
-}
-
 static void
 dummy_cb (GtkWidget  *sender,
           const char *name,
@@ -195,7 +183,6 @@ adw_style_demo_window_class_init (AdwStyleDemoWindowClass *klass)
   gtk_widget_class_bind_template_child (widget_class, AdwStyleDemoWindow, header_bar_window);
   gtk_widget_class_bind_template_child (widget_class, AdwStyleDemoWindow, status_page_window);
   gtk_widget_class_bind_template_child (widget_class, AdwStyleDemoWindow, sidebar_window);
-  gtk_widget_class_bind_template_child (widget_class, AdwStyleDemoWindow, app_notification_revealer);
   gtk_widget_class_bind_template_child (widget_class, AdwStyleDemoWindow, sidebar_leaflet);
   gtk_widget_class_bind_template_callback (widget_class, selection_mode_for_folded);
   gtk_widget_class_bind_template_callback (widget_class, sidebar_back_cb);
@@ -206,7 +193,6 @@ adw_style_demo_window_class_init (AdwStyleDemoWindowClass *klass)
   gtk_widget_class_install_action (widget_class, "style.header-bar", NULL, header_bar_cb);
   gtk_widget_class_install_action (widget_class, "style.status-page", NULL, status_page_cb);
   gtk_widget_class_install_action (widget_class, "style.sidebar", NULL, sidebar_cb);
-  gtk_widget_class_install_action (widget_class, "style.app-notification", "b", app_notification_cb);
   gtk_widget_class_install_action (widget_class, "style.dummy", NULL, dummy_cb);
 }
 
diff --git a/demo/pages/styles/adw-style-demo-window.ui b/demo/pages/styles/adw-style-demo-window.ui
index 04473155..9d9520f1 100644
--- a/demo/pages/styles/adw-style-demo-window.ui
+++ b/demo/pages/styles/adw-style-demo-window.ui
@@ -15,54 +15,6 @@
         </child>
         <child>
           <object class="GtkOverlay">
-            <child type="overlay">
-              <object class="GtkRevealer" id="app_notification_revealer">
-                <property name="valign">start</property>
-                <property name="halign">center</property>
-                <property name="can-focus">False</property>
-                <property name="child">
-                  <object class="GtkFrame">
-                    <property name="tooltip-text">app-notification</property>
-                    <style>
-                      <class name="app-notification"/>
-                    </style>
-                    <property name="child">
-                      <object class="GtkBox">
-                        <property name="spacing">12</property>
-                        <property name="margin-start">12</property>
-                        <property name="width-request">300</property>
-                        <child>
-                          <object class="GtkLabel">
-                            <property name="label" translatable="yes">In-App Notification</property>
-                            <property name="ellipsize">end</property>
-                            <property name="xalign">0</property>
-                            <property name="hexpand">True</property>
-                          </object>
-                        </child>
-                        <child>
-                          <object class="GtkButton">
-                            <property name="label" translatable="yes">Action</property>
-                            <property name="action-name">style.app-notification</property>
-                            <property name="action-target">false</property>
-                          </object>
-                        </child>
-                        <child>
-                          <object class="GtkButton">
-                            <property name="icon-name">window-close-symbolic</property>
-                            <property name="action-name">style.app-notification</property>
-                            <property name="action-target">false</property>
-                            <style>
-                              <class name="flat"/>
-                              <class name="circular"/>
-                            </style>
-                          </object>
-                        </child>
-                      </object>
-                    </property>
-                  </object>
-                </property>
-              </object>
-            </child>
             <child type="overlay">
               <object class="GtkProgressBar">
                 <property name="valign">start</property>
@@ -1185,20 +1137,6 @@ The "raised" style class can be used to make a button inside a toolbar use defau
                         </child>
                       </object>
                     </child>
-                    <child>
-                      <object class="AdwActionRow">
-                        <property name="title" translatable="yes">In-App Notification</property>
-                        <property name="subtitle" translatable="yes">"app-notification" style class on 
GtkFrame</property>
-                        <child>
-                          <object class="GtkButton">
-                            <property name="label" translatable="yes">Show</property>
-                            <property name="action-name">style.app-notification</property>
-                            <property name="action-target">true</property>
-                            <property name="valign">center</property>
-                          </object>
-                        </child>
-                      </object>
-                    </child>
                   </object>
                 </child>
               </object>


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]