2002-01-08 21:25:33 +00:00
|
|
|
/* -*- mode: c; style: linux -*- */
|
|
|
|
|
|
|
|
/* service-info.h
|
|
|
|
*
|
|
|
|
* Copyright (C) 2002 Ximian, Inc.
|
|
|
|
*
|
|
|
|
* Written by Bradford Hovinen <hovinen@ximian.com>
|
|
|
|
*
|
|
|
|
* This program is free software; you can redistribute it and/or
|
|
|
|
* modify it under the terms of the GNU General Public License as
|
|
|
|
* published by the Free Software Foundation; either version 2 of the
|
|
|
|
* License, or (at your option) any later version.
|
|
|
|
*
|
|
|
|
* This program is distributed in the hope that it will be useful,
|
|
|
|
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
|
|
|
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
|
|
|
|
* General Public License for more details.
|
|
|
|
*
|
|
|
|
* You should have received a copy of the GNU General Public
|
|
|
|
* License along with this program; if not, write to the
|
|
|
|
* Free Software Foundation, Inc., 59 Temple Place - Suite 330,
|
|
|
|
* Boston, MA 02111-1307, USA.
|
|
|
|
*/
|
|
|
|
|
|
|
|
#ifndef __SERVICE_INFO_H
|
|
|
|
#define __SERVICE_INFO_H
|
|
|
|
|
|
|
|
#include <gnome.h>
|
|
|
|
#include <bonobo.h>
|
|
|
|
#include <libgnomevfs/gnome-vfs-mime-handlers.h>
|
|
|
|
|
2002-01-25 16:12:01 +00:00
|
|
|
#include "model-entry.h"
|
|
|
|
|
2002-01-08 21:25:33 +00:00
|
|
|
G_BEGIN_DECLS
|
|
|
|
|
2002-01-25 16:12:01 +00:00
|
|
|
#define SERVICE_INFO(obj) ((ServiceInfo *) obj)
|
|
|
|
|
2002-01-08 21:25:33 +00:00
|
|
|
typedef struct _ServiceInfo ServiceInfo;
|
|
|
|
|
|
|
|
struct _ServiceInfo {
|
2002-01-25 16:12:01 +00:00
|
|
|
ModelEntry entry;
|
2002-01-11 15:32:10 +00:00
|
|
|
|
2002-01-08 21:25:33 +00:00
|
|
|
gchar *protocol;
|
|
|
|
gchar *description;
|
2002-01-11 14:17:40 +00:00
|
|
|
gboolean run_program;
|
2002-01-08 21:25:33 +00:00
|
|
|
|
|
|
|
GnomeVFSMimeApplication *app;
|
|
|
|
gchar *custom_line;
|
|
|
|
gboolean need_terminal;
|
|
|
|
};
|
|
|
|
|
2002-01-25 16:12:01 +00:00
|
|
|
void load_all_services (void);
|
|
|
|
|
2002-01-26 16:24:45 +00:00
|
|
|
ServiceInfo *service_info_new (const gchar *protocol);
|
2002-01-25 16:12:01 +00:00
|
|
|
void service_info_load_all (ServiceInfo *info);
|
|
|
|
const gchar *service_info_get_description (ServiceInfo *info);
|
|
|
|
void service_info_save (const ServiceInfo *info);
|
2002-01-26 18:30:32 +00:00
|
|
|
void service_info_delete (const ServiceInfo *info);
|
2002-01-25 16:12:01 +00:00
|
|
|
void service_info_free (ServiceInfo *info);
|
2002-01-08 21:25:33 +00:00
|
|
|
|
2002-01-25 16:12:01 +00:00
|
|
|
const GList *get_apps_for_service_type (gchar *protocol);
|
2002-01-26 18:30:32 +00:00
|
|
|
ModelEntry *get_services_category_entry (void);
|
2002-01-11 17:47:31 +00:00
|
|
|
|
2002-01-08 21:25:33 +00:00
|
|
|
G_END_DECLS
|
|
|
|
|
|
|
|
#endif /* __SERVICE_INFO_H */
|