aboutsummaryrefslogtreecommitdiffstats
path: root/e-util/gal-view-factory.c
diff options
context:
space:
mode:
authorMatthew Barnes <mbarnes@redhat.com>2013-07-03 05:36:01 +0800
committerMatthew Barnes <mbarnes@redhat.com>2013-07-06 04:40:50 +0800
commita2e20af49304296b3c2b10305cb1312031107d55 (patch)
treefef2296790edf090261bd529c6fbfb5ee988c9f3 /e-util/gal-view-factory.c
parentbb5f5ad90beabd459e27d7aaac44d92c9b106c00 (diff)
downloadgsoc2013-evolution-a2e20af49304296b3c2b10305cb1312031107d55.tar
gsoc2013-evolution-a2e20af49304296b3c2b10305cb1312031107d55.tar.gz
gsoc2013-evolution-a2e20af49304296b3c2b10305cb1312031107d55.tar.bz2
gsoc2013-evolution-a2e20af49304296b3c2b10305cb1312031107d55.tar.lz
gsoc2013-evolution-a2e20af49304296b3c2b10305cb1312031107d55.tar.xz
gsoc2013-evolution-a2e20af49304296b3c2b10305cb1312031107d55.tar.zst
gsoc2013-evolution-a2e20af49304296b3c2b10305cb1312031107d55.zip
GalViewFactoryClass: Remove the new_view() method.
GalViewFactory can now use its "gal_view_type" class member to instantiate an appropriate GalView without help from subclasses.
Diffstat (limited to 'e-util/gal-view-factory.c')
-rw-r--r--e-util/gal-view-factory.c7
1 files changed, 3 insertions, 4 deletions
diff --git a/e-util/gal-view-factory.c b/e-util/gal-view-factory.c
index d235a63d86..9d0ef7596f 100644
--- a/e-util/gal-view-factory.c
+++ b/e-util/gal-view-factory.c
@@ -68,21 +68,20 @@ gal_view_factory_get_type_code (GalViewFactory *factory)
/**
* gal_view_factory_new_view:
* @factory: a #GalViewFactory
- * @name: the name for the view
+ * @title: the title for the view
*
* Returns: The new view
*/
GalView *
gal_view_factory_new_view (GalViewFactory *factory,
- const gchar *name)
+ const gchar *title)
{
GalViewFactoryClass *class;
g_return_val_if_fail (GAL_IS_VIEW_FACTORY (factory), NULL);
class = GAL_VIEW_FACTORY_GET_CLASS (factory);
- g_return_val_if_fail (class->new_view != NULL, NULL);
- return class->new_view (factory, name);
+ return g_object_new (class->gal_view_type, "title", title, NULL);
}