diff options
Diffstat (limited to 'src')
| -rw-r--r-- | src/generators.c | 4 | ||||
| -rw-r--r-- | src/setup.c | 3 | ||||
| -rw-r--r-- | src/setup.h | 1 |
3 files changed, 6 insertions, 2 deletions
diff --git a/src/generators.c b/src/generators.c index a755a45..48f7c0b 100644 --- a/src/generators.c +++ b/src/generators.c @@ -427,7 +427,7 @@ write_html_album (TGallerySetup *setup, } if (in_go_up_string && strstr (buffer, "<!-- $(END_GO_UP) -->")) { in_go_up_string = FALSE; - if (! items->parent_index) + if (! items->parent_index || ! setup->show_go_up) continue; } if (in_go_up_string) { @@ -520,7 +520,7 @@ write_html_album (TGallerySetup *setup, } /* Select apropriate line buffer */ - if (strstr (buffer, "<!-- $(END_GO_UP) -->") && items->parent_index) { + if (strstr (buffer, "<!-- $(END_GO_UP) -->") && items->parent_index && setup->show_go_up) { b = strdup (buf_go_up_string); } else b = strdup (buffer); diff --git a/src/setup.c b/src/setup.c index 17d8fda..4755ad7 100644 --- a/src/setup.c +++ b/src/setup.c @@ -135,6 +135,9 @@ parse_setup_xml (const char *filename, TGallerySetup *setup) s = xml_file_get_node_attribute (xml, "/gallery_setup/navigation/use_inpage_links", "value"); setup->use_inpage_links = s ? strcasecmp (s, "yes") == 0 : TRUE; /* default to TRUE */ if (s) g_free (s); + s = xml_file_get_node_attribute (xml, "/gallery_setup/navigation/show_go_up", "value"); + setup->show_go_up = s ? strcasecmp (s, "yes") == 0 : TRUE; /* default to TRUE */ + if (s) g_free (s); setup->nofullsize = xml_file_get_node_present (xml, "/gallery_setup/images/nofullsize"); diff --git a/src/setup.h b/src/setup.h index eb12f92..4019184 100644 --- a/src/setup.h +++ b/src/setup.h @@ -73,6 +73,7 @@ typedef struct { char *site_title; char *add_copyright; gboolean use_inpage_links; + gboolean show_go_up; char *favicon_file; char *favicon_type; |
