Mercurial > geeqie.yaz
changeset 636:2ea7af1fbfe0
Make vf_pop_menu_toggle_view_type_cb() independent of FILEVIEW_LIST/FILEVIEW_ICON real values.
author | zas_ |
---|---|
date | Sun, 11 May 2008 23:56:40 +0000 |
parents | eaca3e910ecd |
children | 8a1202efa51e |
files | src/view_file.c |
diffstat | 1 files changed, 11 insertions(+), 1 deletions(-) [+] |
line wrap: on
line diff
--- a/src/view_file.c Sun May 11 23:47:59 2008 +0000 +++ b/src/view_file.c Sun May 11 23:56:40 2008 +0000 @@ -428,7 +428,17 @@ { ViewFile *vf = data; - if (vf->layout) layout_views_set(vf->layout, vf->layout->dir_view_type, !vf->layout->file_view_type); + if (!vf->layout) return; + + switch(vf->layout->file_view_type) + { + case FILEVIEW_LIST: + layout_views_set(vf->layout, vf->layout->dir_view_type, FILEVIEW_ICON); + break; + case FILEVIEW_ICON: + layout_views_set(vf->layout, vf->layout->dir_view_type, FILEVIEW_LIST); + break; + } }