/[gtktalog]/gtktalog/src/config_parse.y
ViewVC logotype

Diff of /gtktalog/src/config_parse.y

Parent Directory Parent Directory | Revision Log Revision Log | View Patch Patch

revision 1.1 by ymettier, Sun Oct 13 17:14:59 2002 UTC revision 1.2 by chevdor, Mon Feb 10 23:12:02 2003 UTC
# Line 30  Line 30 
30  #include "addisk.h"  #include "addisk.h"
31  #include "io.h"  #include "io.h"
32  #include "setup.h"  #include "setup.h"
33    #include "setup_trees.h"
34    
35  #if (defined(OS_LINUX) || defined(__APPLE__) || defined(OS_FREEBSD) || defined(OS_NETBSD) || defined(OS_OPENBSD))  #if (defined(OS_LINUX) || defined(__APPLE__) || defined(OS_FREEBSD) || defined(OS_NETBSD) || defined(OS_OPENBSD))
36  #if defined(HAVE_GETFSENT)  #if defined(HAVE_GETFSENT)
37  #include <fstab.h>  #include <fstab.h>
# Line 1260  init_config (GtkWidget * w) Line 1262  init_config (GtkWidget * w)
1262    gchar *path;    gchar *path;
1263    GString *tmpstr;    GString *tmpstr;
1264    
1265      struct_mime_type_to_skip* mime_type_to_skip;
1266      
1267    conf_file = g_string_new (g_get_home_dir ());    conf_file = g_string_new (g_get_home_dir ());
1268    conf_file =    conf_file =
1269      g_string_append (conf_file, USER_CONFIG_DIR "/" USER_CONFIG_FILE);      g_string_append (conf_file, USER_CONFIG_DIR "/" USER_CONFIG_FILE);
# Line 1295  init_config (GtkWidget * w) Line 1299  init_config (GtkWidget * w)
1299        my_config->mount_retry = 0;        my_config->mount_retry = 0;
1300        my_config->mime_extensions = g_tree_new ((GCompareFunc) strcmp);        my_config->mime_extensions = g_tree_new ((GCompareFunc) strcmp);
1301        my_config->mime_vfs_extensions = g_tree_new ((GCompareFunc) strcmp);        my_config->mime_vfs_extensions = g_tree_new ((GCompareFunc) strcmp);
1302        my_config->mime_to_skip_during_a_scan =        my_config->mime_to_skip_during_a_scan = NULL;
         g_tree_new ((GCompareFunc) strcmp);  
1303        my_config->use_du_s = TRUE;        my_config->use_du_s = TRUE;
1304        my_config->warn_mount = FALSE;        my_config->warn_mount = FALSE;
1305        my_config->eject_disk = TRUE;        my_config->eject_disk = TRUE;
# Line 1684  init_config (GtkWidget * w) Line 1687  init_config (GtkWidget * w)
1687                /* Icon */                /* Icon */
1688                gl1 = GET_TOKEN;                gl1 = GET_TOKEN;
1689                gl2 = g_list_next (gl1);                gl2 = g_list_next (gl1);
1690                g_tree_insert (my_config->mime_to_skip_during_a_scan,                
1691                               (mime = g_strdup (((GString                g_print ("load %s | state=%i\n",mime = g_strdup (((GString*) (gl1->data))->str),gl2->data);
                                                  *) (gl1->data))->str)),  
                              gl2->data);  
1692    
1693                  mime_type_to_skip=(struct_mime_type_to_skip*)malloc(sizeof(struct_mime_type_to_skip));
1694                  
1695                  mime_type_to_skip->state     = gl2->data;
1696                  mime_type_to_skip->mime_type = g_strdup (((GString*) (gl1->data))->str);
1697    
1698                  g_slist_prepend(my_config->mime_to_skip_during_a_scan,
1699                                  mime_type_to_skip);
1700                  
1701                g_string_free (gl1->data, TRUE);                g_string_free (gl1->data, TRUE);
   
1702                g_list_free (gl1);                g_list_free (gl1);
1703    
   
1704                NEXT_TOKEN;                NEXT_TOKEN;
1705    
1706              }              }
1707            else if (IS_TOKEN ("ReadInformation"))            else if (IS_TOKEN ("ReadInformation"))
1708              {              {

Legend:
Removed from v.1.1  
changed lines
  Added in v.1.2

savannah-hackers-public@gnu.org
ViewVC Help
Powered by ViewVC 1.1.26