PostGIS 3.0.6dev-r@@SVN_REVISION@@
Loading...
Searching...
No Matches

◆ pgui_action_open_file_dialog()

static void pgui_action_open_file_dialog ( GtkWidget *  widget,
gpointer  data 
)
static

Definition at line 1298 of file shp2pgsql-gui.c.

1299{
1300 SHPLOADERCONFIG *loader_file_config;
1301 GSList *filename_list, *filename_item;
1302 gchar *filename;
1303
1304 /* Make sure we deselect any files from the last time */
1305 gtk_file_chooser_unselect_all(GTK_FILE_CHOOSER(dialog_filechooser));
1306
1307 /* Run the dialog */
1308 if (gtk_dialog_run(GTK_DIALOG(dialog_filechooser)) == GTK_RESPONSE_ACCEPT)
1309 {
1310 /* Create the new file configuration based upon the each filename and add it to the listview */
1311 filename_list = gtk_file_chooser_get_filenames(GTK_FILE_CHOOSER(dialog_filechooser));
1312
1313 filename_item = g_slist_nth(filename_list, 0);
1314 while (filename_item)
1315 {
1316 /* Add the configuration */
1317 filename = g_slist_nth_data(filename_item, 0);
1318
1319 loader_file_config = create_new_file_config(filename);
1320 add_loader_file_config_to_list(loader_file_config);
1321
1322 /* Grab the next filename */
1323 filename_item = g_slist_next(filename_item);
1324 }
1325
1326 /* Free the list */
1327 g_slist_free(filename_list);
1328 }
1329
1330 gtk_widget_hide(dialog_filechooser);
1331}
static SHPLOADERCONFIG * create_new_file_config(const char *filename)
static GtkWidget * dialog_filechooser
static void add_loader_file_config_to_list(SHPLOADERCONFIG *loader_file_config)

References add_loader_file_config_to_list(), create_new_file_config(), and dialog_filechooser.

Referenced by pgui_create_import_file_table().

Here is the call graph for this function:
Here is the caller graph for this function: