1 /* -*- Mode: C; indent-tabs-mode: t; c-basic-offset: 8; tab-width: 8 -*- */
2 
3 /*
4    caja-open-with-dialog.c: an open-with dialog
5 
6    Copyright (C) 2004 Novell, Inc.
7 
8    The Mate Library is free software; you can redistribute it and/or
9    modify it under the terms of the GNU Library General Public License as
10    published by the Free Software Foundation; either version 2 of the
11    License, or (at your option) any later version.
12 
13    The Mate Library is distributed in the hope that it will be useful,
14    but WITHOUT ANY WARRANTY; without even the implied warranty of
15    MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
16    Library General Public License for more details.
17 
18    You should have received a copy of the GNU Library General Public
19    License along with the Mate Library; see the file COPYING.LIB.  If not,
20    write to the Free Software Foundation, Inc., 51 Franklin St, Fifth Floor,
21    Boston, MA 02110-1301, USA.
22 
23    Authors: Dave Camp <dave@novell.com>
24 */
25 
26 #ifndef CAJA_OPEN_WITH_DIALOG_H
27 #define CAJA_OPEN_WITH_DIALOG_H
28 
29 #include <gtk/gtk.h>
30 #include <gio/gio.h>
31 
32 #define CAJA_TYPE_OPEN_WITH_DIALOG         (caja_open_with_dialog_get_type ())
33 #define CAJA_OPEN_WITH_DIALOG(obj)         (G_TYPE_CHECK_INSTANCE_CAST ((obj), CAJA_TYPE_OPEN_WITH_DIALOG, CajaOpenWithDialog))
34 #define CAJA_OPEN_WITH_DIALOG_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST ((klass), CAJA_TYPE_OPEN_WITH_DIALOG, CajaOpenWithDialogClass))
35 #define CAJA_IS_OPEN_WITH_DIALOG(obj)      (G_TYPE_INSTANCE_CHECK_TYPE ((obj), CAJA_TYPE_OPEN_WITH_DIALOG)
36 
37 typedef struct _CajaOpenWithDialog        CajaOpenWithDialog;
38 typedef struct _CajaOpenWithDialogClass   CajaOpenWithDialogClass;
39 typedef struct _CajaOpenWithDialogDetails CajaOpenWithDialogDetails;
40 
41 struct _CajaOpenWithDialog
42 {
43     GtkDialog parent;
44     CajaOpenWithDialogDetails *details;
45 };
46 
47 struct _CajaOpenWithDialogClass
48 {
49     GtkDialogClass parent_class;
50 
51     void (*application_selected) (CajaOpenWithDialog *dialog,
52                                   GAppInfo *application);
53 };
54 
55 GType      caja_open_with_dialog_get_type (void);
56 GtkWidget* caja_open_with_dialog_new      (const char *uri,
57         const char *mime_type,
58         const char *extension);
59 GtkWidget* caja_add_application_dialog_new (const char *uri,
60         const char *mime_type);
61 GtkWidget* caja_add_application_dialog_new_for_multiple_files (const char *extension,
62         const char *mime_type);
63 
64 
65 
66 #endif /* CAJA_OPEN_WITH_DIALOG_H */
67