Use scroll in folder window
[modest] / src / hildon2 / modest-hildon2-window-mgr.c
index 36f7b3c..1d2d114 100644 (file)
@@ -72,7 +72,6 @@ static void modest_hildon2_window_mgr_show_toolbars (ModestWindowMgr *self,
                                                     GType window_type,
                                                     gboolean show_toolbars,
                                                     gboolean fullscreen);
-static ModestWindow* modest_hildon2_window_mgr_get_main_window (ModestWindowMgr *self, gboolean show);
 static GtkWindow *modest_hildon2_window_mgr_get_modal (ModestWindowMgr *self);
 static void modest_hildon2_window_mgr_set_modal (ModestWindowMgr *self, 
                                                 GtkWindow *window,
@@ -164,7 +163,6 @@ modest_hildon2_window_mgr_class_init (ModestHildon2WindowMgrClass *klass)
        mgr_class->set_fullscreen_mode = modest_hildon2_window_mgr_set_fullscreen_mode;
        mgr_class->get_fullscreen_mode = modest_hildon2_window_mgr_get_fullscreen_mode;
        mgr_class->show_toolbars = modest_hildon2_window_mgr_show_toolbars;
-       mgr_class->get_main_window = modest_hildon2_window_mgr_get_main_window;
        mgr_class->get_modal = modest_hildon2_window_mgr_get_modal;
        mgr_class->set_modal = modest_hildon2_window_mgr_set_modal;
        mgr_class->find_registered_header = modest_hildon2_window_mgr_find_registered_header;
@@ -261,9 +259,6 @@ modest_hildon2_window_mgr_finalize (GObject *obj)
        }
        g_mutex_free (priv->queue_lock);
 
-       /* Do not unref priv->main_window because it does not hold a
-          new reference */
-
        G_OBJECT_CLASS(parent_class)->finalize (obj);
 }
 
@@ -823,43 +818,6 @@ modest_hildon2_window_mgr_show_toolbars (ModestWindowMgr *self,
        return;
 }
 
-static ModestWindow*  
-modest_hildon2_window_mgr_get_main_window (ModestWindowMgr *self, gboolean show)
-{
-       ModestHildon2WindowMgrPrivate *priv;
-       ModestWindow *result;
-
-       g_return_val_if_fail (MODEST_IS_HILDON2_WINDOW_MGR (self), NULL);
-       priv = MODEST_HILDON2_WINDOW_MGR_GET_PRIVATE (self);
-
-       /* TODO: make this return NULL always */
-
-       result = MODEST_WINDOW_MGR_CLASS (parent_class)->get_main_window (self, FALSE);
-       /* create the main window, if it hasn't been created yet */
-       if (!result && show) {
-               /* modest_window_mgr_register_window will set priv->main_window */
-               result = modest_main_window_new ();
-               /* We have to remove all other windows */
-               if (!modest_window_mgr_close_all_windows (self)) {
-                       gtk_widget_destroy (GTK_WIDGET (result));
-                       return NULL;
-               }
-               if (!modest_window_mgr_register_window (self, result, NULL)) {
-                       gtk_widget_destroy (GTK_WIDGET (result));
-                       return NULL;
-               }
-               MODEST_DEBUG_BLOCK(
-                       g_debug ("%s: created main window: %p\n", __FUNCTION__, result);
-               );
-       }
-       if (show) {
-               gtk_widget_show_all (GTK_WIDGET (result));
-               gtk_window_present (GTK_WINDOW (result));
-       }
-
-       return result;
-}
-
 static gint
 look_for_transient (gconstpointer a,
                    gconstpointer b)