/***** * * Copyright (C) 2002, 2003 Pablo Belin * All Rights Reserved * * This file is part of the gprelude program. * * 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, 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; see the file COPYING. If not, write to * the Free Software Foundation, 675 Mass Ave, Cambridge, MA 02139, USA. * *****/ #include #include #include #include #include #include #include #include #include #include #include #include "list.h" #include "gprelude-mem.h" #include "gprelude-sys.h" #include "db-interface.h" #include "db-interface-sax.h" #include "gprelude-config.h" #include "gprelude-window.h" int main ( int argc, char **argv ) { int ret; gprelude_config_t *cfg; gprelude_window_t *win; gtk_init ( &argc, &argv ); cfg = gprelude_init ( argc, argv ); if ( !cfg ) exit ( EXIT_FAILURE ); ret = prelude_db_init (); if ( ret < 0 ) { log ( LOG_ERR, "could not initialize DB subsystem.\n" ); gprelude_exit ( cfg ); exit ( EXIT_FAILURE ); } win = create_gprelude_window ( cfg ); if ( win ) init_gprelude_window ( win ); else { gprelude_exit ( cfg ); exit ( EXIT_FAILURE ); } gtk_main (); return 0; }