1 /* -*- Mode: C; tab-width: 8; indent-tabs-mode: nil; c-basic-offset: 8 -*- */ 2 /* 3 * Copyright (C) 2002 CodeFactory AB 4 * Copyright (C) 2002 Mikael Hallendal <micke@imendio.com> 5 * Copyright (C) 2005-2008 Imendio AB 6 * 7 * This program is free software; you can redistribute it and/or 8 * modify it under the terms of the GNU General Public License as 9 * published by the Free Software Foundation; either version 2 of the 10 * License, or (at your option) any later version. 11 * 12 * This program is distributed in the hope that it will be useful, 13 * but WITHOUT ANY WARRANTY; without even the implied warranty of 14 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU 15 * General Public License for more details. 16 * 17 * You should have received a copy of the GNU General Public 18 * License along with this program; if not, write to the 19 * Free Software Foundation, Inc., 59 Temple Place - Suite 330, 20 * Boston, MA 02111-1307, USA. 21 */ 22 23 #ifndef __DH_BASE_H__ 24 #define __DH_BASE_H__ 25 26 #include <gtk/gtk.h> 27 28 #include "dh-book-manager.h" 29 30 G_BEGIN_DECLS 31 32 typedef struct _DhBase DhBase; 33 typedef struct _DhBaseClass DhBaseClass; 34 35 #define DH_TYPE_BASE (dh_base_get_type ()) 36 #define DH_BASE(o) (G_TYPE_CHECK_INSTANCE_CAST ((o), DH_TYPE_BASE, DhBase)) 37 #define DH_BASE_CLASS(k) (G_TYPE_CHECK_CLASS_CAST ((k), DH_TYPE_BASE, DhBaseClass)) 38 #define DH_IS_BASE(o) (G_TYPE_CHECK_INSTANCE_TYPE ((o), DH_TYPE_BASE)) 39 #define DH_IS_BASE_CLASS(k) (G_TYPE_CHECK_CLASS_TYPE ((k), DH_TYPE_BASE)) 40 #define DH_BASE_GET_CLASS(o) (G_TYPE_INSTANCE_GET_CLASS ((o), DH_TYPE_BASE, DhBaseClass)) 41 42 struct _DhBase { 43 GObject parent_instance; 44 }; 45 46 struct _DhBaseClass { 47 GObjectClass parent_class; 48 }; 49 50 GType dh_base_get_type (void) G_GNUC_CONST; 51 DhBase * dh_base_get (void); 52 DhBase * dh_base_new (void); 53 GtkWidget * dh_base_new_window (DhBase *base); 54 GtkWidget * dh_base_new_assistant (DhBase *base); 55 GtkWidget * dh_base_get_window (DhBase *base); 56 GtkWidget * dh_base_get_window_on_current_workspace (DhBase *base); 57 DhBookManager *dh_base_get_book_manager (DhBase *base); 58 void dh_base_quit (DhBase *base); 59 60 G_END_DECLS 61 62 #endif /* __DH_BASE_H__ */ 63