[ekiga/ds-gsettings2: 14/33] GmDialog: Removed antic and unused functions.



commit 3620355684f0ba98b84167d50f10e2e3b6a0d8e5
Author: Damien Sandras <dsandras beip be>
Date:   Sun Apr 7 17:59:14 2013 +0200

    GmDialog: Removed antic and unused functions.
    
    Those date back from the good old GnomeMeeting days!

 lib/Makefile.am                             |    2 -
 lib/engine/gui/gtk-frontend/main_window.cpp |    1 -
 lib/gui/gmwindow.c                          |  143 ---------------------------
 3 files changed, 0 insertions(+), 146 deletions(-)
---
diff --git a/lib/Makefile.am b/lib/Makefile.am
index a5f3a72..8ae687c 100644
--- a/lib/Makefile.am
+++ b/lib/Makefile.am
@@ -132,8 +132,6 @@ libekiga_la_SOURCES += \
        gui/gmcallbacks.h \
        gui/gmconfwidgets.c \
        gui/gmconfwidgets.h \
-       gui/gmdialog.c \
-       gui/gmdialog.h \
        gui/gmentrydialog.c \
        gui/gmentrydialog.h \
        gui/gmmenuaddon.c \
diff --git a/lib/engine/gui/gtk-frontend/main_window.cpp b/lib/engine/gui/gtk-frontend/main_window.cpp
index d0c6343..0bf5fb3 100644
--- a/lib/engine/gui/gtk-frontend/main_window.cpp
+++ b/lib/engine/gui/gtk-frontend/main_window.cpp
@@ -45,7 +45,6 @@
 #include "statusmenu.h"
 
 #include "gmcallbacks.h"
-#include "gmdialog.h"
 #include "gmentrydialog.h"
 #include "gmstatusbar.h"
 #include "gmmenuaddon.h"
diff --git a/lib/gui/gmwindow.c b/lib/gui/gmwindow.c
index ec08049..9611944 100644
--- a/lib/gui/gmwindow.c
+++ b/lib/gui/gmwindow.c
@@ -238,16 +238,6 @@ gm_window_init (GmWindow* self)
 /*
  * Our own stuff
  */
-// FIXME drop this when removing old GMWindows
-static gboolean
-old_style_gm_window_delete_event_cb (GtkWidget* window,
-                                     G_GNUC_UNUSED gpointer data)
-{
-  gm_window_hide (window);
-  return TRUE;
-}
-
-
 static gboolean
 gm_window_delete_event_cb (GtkWidget *w,
                            G_GNUC_UNUSED gpointer data)
@@ -462,136 +452,3 @@ gm_window_is_visible (GtkWidget* w)
 {
   return (gtk_widget_get_visible (w) && !(gdk_window_get_state (gtk_widget_get_window (w)) & 
GDK_WINDOW_STATE_ICONIFIED));
 }
-
-
-void
-gm_window_show (GtkWidget* w)
-{
-  int x = 0;
-  int y = 0;
-
-  gchar* window_name = NULL;
-  gchar* conf_key_size = NULL;
-  gchar* conf_key_position = NULL;
-  gchar* size = NULL;
-  gchar* position = NULL;
-  gchar** couple = NULL;
-
-  g_return_if_fail (GTK_IS_WINDOW (w));
-
-  if (gm_window_is_visible (w)) {
-
-    gtk_window_present (GTK_WINDOW (w));
-    return;
-  } // else we do the show :
-
-  window_name = (char *) g_object_get_data (G_OBJECT (w), "window_name");
-
-  if (window_name) {
-
-    conf_key_position = g_strdup_printf ("%s%s/position", USER_INTERFACE_KEY, window_name);
-    conf_key_size = g_strdup_printf ("%s%s/size", USER_INTERFACE_KEY, window_name);
-
-    if (!gm_window_is_visible (w)) {
-
-      position = gm_conf_get_string (conf_key_position);
-      if (position)
-       couple = g_strsplit (position, ",", 0);
-
-      if (couple && couple [0])
-       x = atoi (couple [0]);
-      if (couple && couple [1])
-       y = atoi (couple [1]);
-
-
-      if (x != 0 && y != 0)
-       gtk_window_move (GTK_WINDOW (w), x, y);
-
-      g_strfreev (couple);
-      couple = NULL;
-      g_free (position);
-
-      if (gtk_window_get_resizable (GTK_WINDOW (w))) {
-
-       size = gm_conf_get_string (conf_key_size);
-       if (size)
-         couple = g_strsplit (size, ",", 0);
-
-       if (couple && couple [0])
-         x = atoi (couple [0]);
-       if (couple && couple [1])
-         y = atoi (couple [1]);
-
-       if (x > 0 && y > 0)
-         gtk_window_resize (GTK_WINDOW (w), x, y);
-
-       g_strfreev (couple);
-       g_free (size);
-      }
-    }
-
-    gtk_window_present (GTK_WINDOW (w));
-    gtk_widget_show_all (w);
-  }
-
-  g_free (conf_key_position);
-  g_free (conf_key_size);
-}
-
-
-void
-gm_window_hide (GtkWidget* w)
-{
-  int x = 0;
-  int y = 0;
-
-  gchar* window_name = NULL;
-  gchar* conf_key_size = NULL;
-  gchar* conf_key_position = NULL;
-  gchar* size = NULL;
-  gchar* position = NULL;
-
-  g_return_if_fail (GTK_IS_WINDOW (w));
-
-  window_name = (char *) g_object_get_data (G_OBJECT (w), "window_name");
-
-  g_return_if_fail (window_name != NULL);
-
-  conf_key_position =
-    g_strdup_printf ("%s%s/position", USER_INTERFACE_KEY, window_name);
-  conf_key_size =
-    g_strdup_printf ("%s%s/size", USER_INTERFACE_KEY, window_name);
-
-
-  /* If the window is visible, save its position and hide the window */
-  if (gm_window_is_visible (w)) {
-
-    gtk_window_get_position (GTK_WINDOW (w), &x, &y);
-    position = g_strdup_printf ("%d,%d", x, y);
-    gm_conf_set_string (conf_key_position, position);
-    g_free (position);
-
-    if (gtk_window_get_resizable (GTK_WINDOW (w))) {
-
-      gtk_window_get_size (GTK_WINDOW (w), &x, &y);
-      size = g_strdup_printf ("%d,%d", x, y);
-      gm_conf_set_string (conf_key_size, size);
-      g_free (size);
-    }
-
-    gtk_widget_hide (w);
-  }
-
-  g_free (conf_key_position);
-  g_free (conf_key_size);
-}
-
-
-void
-gm_window_hide_on_delete (GtkWidget* window)
-{
-  g_return_if_fail (GTK_IS_WIDGET (window));
-
-  g_signal_connect (window, "delete-event",
-                    G_CALLBACK (old_style_gm_window_delete_event_cb), NULL);
-}


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