PostGIS  2.2.8dev-r@@SVN_REVISION@@

◆ table_chooser_visibility_func()

static gboolean table_chooser_visibility_func ( GtkTreeModel *  model,
GtkTreeIter *  iter,
gpointer  data 
)
static

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

References checkbutton_chooser_geoonly, FALSE, TABLECHOOSER_HASGEO_COLUMN, and TRUE.

Referenced by pgui_create_tablechooser_dialog().

767 {
768  /* First determine whether the hasgeo tickbox is selected or not */
769  gboolean geoonly = gtk_toggle_button_get_active(GTK_TOGGLE_BUTTON(checkbutton_chooser_geoonly));
770  int hasgeo;
771 
772  /* If unticked then we show all tables */
773  if (!geoonly)
774  return TRUE;
775  else
776  {
777  /* Otherwise we only show the tables with geo columns */
778  gtk_tree_model_get(GTK_TREE_MODEL(model), iter, TABLECHOOSER_HASGEO_COLUMN, &hasgeo, -1);
779  if (hasgeo)
780  return TRUE;
781  else
782  return FALSE;
783  }
784 
785  return FALSE;
786 }
static GtkWidget * checkbutton_chooser_geoonly
#define FALSE
Definition: dbfopen.c:168
#define TRUE
Definition: dbfopen.c:169
Here is the caller graph for this function: