[nautilus/wip/oholy/gtk4-modal-dialogs: 2/2] eel-stock-dialogs: Remove unused functionality




commit cb0019c74b1088366388d324314107055a27d32c
Author: Ondrej Holy <oholy redhat com>
Date:   Wed Jan 26 12:26:03 2022 +0100

    eel-stock-dialogs: Remove unused functionality
    
    Some functions are no more used. Let's remove them instead of fixing
    GTK 4 regressions in them.
    
    Related: https://gitlab.gnome.org/GNOME/nautilus/-/issues/2117

 eel/eel-stock-dialogs.c | 65 -------------------------------------------------
 eel/eel-stock-dialogs.h |  9 -------
 2 files changed, 74 deletions(-)
---
diff --git a/eel/eel-stock-dialogs.c b/eel/eel-stock-dialogs.c
index 4bfde1b95..dbc3ddb53 100644
--- a/eel/eel-stock-dialogs.c
+++ b/eel/eel-stock-dialogs.c
@@ -400,71 +400,6 @@ create_message_dialog (const char     *primary_text,
     return GTK_DIALOG (dialog);
 }
 
-static GtkDialog *
-show_message_dialog (const char     *primary_text,
-                     const char     *secondary_text,
-                     GtkMessageType  type,
-                     GtkButtonsType  buttons_type,
-                     GtkWindow      *parent)
-{
-    GtkDialog *dialog;
-
-    dialog = create_message_dialog (primary_text, secondary_text, type,
-                                    buttons_type, parent);
-    gtk_widget_show (GTK_WIDGET (dialog));
-
-    g_signal_connect (dialog, "response",
-                      G_CALLBACK (gtk_window_destroy), NULL);
-
-    return dialog;
-}
-
-static GtkDialog *
-show_ok_dialog (const char     *primary_text,
-                const char     *secondary_text,
-                GtkMessageType  type,
-                GtkWindow      *parent)
-{
-    GtkDialog *dialog;
-
-    dialog = show_message_dialog (primary_text, secondary_text, type,
-                                  GTK_BUTTONS_OK, parent);
-    gtk_dialog_set_default_response (GTK_DIALOG (dialog), GTK_RESPONSE_OK);
-
-    return dialog;
-}
-
-GtkDialog *
-eel_show_info_dialog (const char *primary_text,
-                      const char *secondary_text,
-                      GtkWindow  *parent)
-{
-    return show_ok_dialog (primary_text,
-                           secondary_text,
-                           GTK_MESSAGE_INFO, parent);
-}
-
-GtkDialog *
-eel_show_warning_dialog (const char *primary_text,
-                         const char *secondary_text,
-                         GtkWindow  *parent)
-{
-    return show_ok_dialog (primary_text,
-                           secondary_text,
-                           GTK_MESSAGE_WARNING, parent);
-}
-
-
-GtkDialog *
-eel_show_error_dialog (const char *primary_text,
-                       const char *secondary_text,
-                       GtkWindow  *parent)
-{
-    return show_ok_dialog (primary_text,
-                           secondary_text,
-                           GTK_MESSAGE_ERROR, parent);
-}
-
 /**
  * eel_show_yes_no_dialog:
  *
diff --git a/eel/eel-stock-dialogs.h b/eel/eel-stock-dialogs.h
index cb1bb09c2..064afb490 100644
--- a/eel/eel-stock-dialogs.h
+++ b/eel/eel-stock-dialogs.h
@@ -51,15 +51,6 @@ GtkDialog *eel_show_simple_dialog             (GtkWidget         *parent,
  * primary, and secondary messages, and we return GtkDialog pointers 
  * instead of GtkWidget pointers.
  */
-GtkDialog *eel_show_info_dialog               (const char        *primary_text,
-                                              const char        *secondary_text,
-                                              GtkWindow         *parent);
-GtkDialog *eel_show_warning_dialog            (const char        *primary_text,
-                                              const char        *secondary_text,
-                                              GtkWindow         *parent);
-GtkDialog *eel_show_error_dialog              (const char        *primary_text,
-                                              const char        *secondary_text,
-                                              GtkWindow         *parent);
 GtkDialog *eel_show_yes_no_dialog             (const char        *primary_text,
                                               const char        *secondary_text,
                                               const char        *yes_label,


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