|
GnuCash 2.4.99
|
00001 /********************************************************************\ 00002 * This program is free software; you can redistribute it and/or * 00003 * modify it under the terms of the GNU General Public License as * 00004 * published by the Free Software Foundation; either version 2 of * 00005 * the License, or (at your option) any later version. * 00006 * * 00007 * This program is distributed in the hope that it will be useful, * 00008 * but WITHOUT ANY WARRANTY; without even the implied warranty of * 00009 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * 00010 * GNU General Public License for more details. * 00011 * * 00012 * You should have received a copy of the GNU General Public License* 00013 * along with this program; if not, contact: * 00014 * * 00015 * Free Software Foundation Voice: +1-617-542-5942 * 00016 * 51 Franklin Street, Fifth Floor Fax: +1-617-542-2652 * 00017 * Boston, MA 02110-1301, USA gnu@gnu.org * 00018 \********************************************************************/ 00026 #include "config.h" 00027 00028 #include <gmodule.h> 00029 00030 #include "gnc-module.h" 00031 #include "gnc-module-api.h" 00032 #include "gnc-plugin-csv-import.h" 00033 00034 GNC_MODULE_API_DECL(libgncmod_csv_import) 00035 00036 /* version of the gnc module system interface we require */ 00037 int libgncmod_csv_import_gnc_module_system_interface = 0; 00038 00039 /* module versioning uses libtool semantics. */ 00040 int libgncmod_csv_import_gnc_module_current = 0; 00041 int libgncmod_csv_import_gnc_module_revision = 0; 00042 int libgncmod_csv_import_gnc_module_age = 0; 00043 00044 //static GNCModule bus_core; 00045 //static GNCModule file; 00046 00047 char * 00048 libgncmod_csv_import_gnc_module_path(void) 00049 { 00050 return g_strdup("gnucash/import-export/csv-import"); 00051 } 00052 00053 char * 00054 libgncmod_csv_import_gnc_module_description(void) 00055 { 00056 return g_strdup("Gnome GUI and C code for CSV importer."); 00057 } 00058 00059 int 00060 libgncmod_csv_import_gnc_module_init(int refcount) 00061 { 00062 if (!gnc_module_load("gnucash/engine", 0)) 00063 { 00064 return FALSE; 00065 } 00066 if (!gnc_module_load("gnucash/app-utils", 0)) 00067 { 00068 return FALSE; 00069 } 00070 if (!gnc_module_load("gnucash/gnome-utils", 0)) 00071 { 00072 return FALSE; 00073 } 00074 if (!gnc_module_load("gnucash/import-export", 0)) 00075 { 00076 return FALSE; 00077 } 00078 00079 /* Add menu items with C callbacks */ 00080 gnc_plugin_csv_import_create_plugin(); 00081 00082 return TRUE; 00083 } 00084 00085 int 00086 libgncmod_csv_import_gnc_module_end(int refcount) 00087 { 00088 return TRUE; 00089 }
1.7.4