aboutsummaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorHarry Jeffery <harry@exec64.co.uk>2015-11-12 13:12:44 +0000
committerHarry Jeffery <harry@exec64.co.uk>2015-11-12 13:12:44 +0000
commit9cd0c1bd65cd056cdbc36cb3b9afa892e52553cf (patch)
tree4e3fee2ac10d53a9465d905c8d6744b498a03986 /src
parent0f7b7cfda8eae35f0c68d1f50934f80bef7441f8 (diff)
downloadimv-9cd0c1bd65cd056cdbc36cb3b9afa892e52553cf.tar.gz
Print current image path to stdout
Fixes #10
Diffstat (limited to 'src')
-rw-r--r--src/main.c2
1 files changed, 2 insertions, 0 deletions
diff --git a/src/main.c b/src/main.c
index cc06393..e60a83a 100644
--- a/src/main.c
+++ b/src/main.c
@@ -68,6 +68,7 @@ void print_usage(const char* name)
" 'f': Toggle fullscreen\n"
" ' ': Toggle gif playback\n"
" '.': Step a frame of gif playback\n"
+ " 'p': Print current image path to stdout\n"
"\n"
"Legal:\n"
"imv is published under the MIT open source license.\n"
@@ -208,6 +209,7 @@ int main(int argc, char** argv)
case SDLK_PERIOD: imv_image_load_next_frame(&img); break;
case SDLK_SPACE: imv_viewport_toggle_playing(&view, &img);break;
case SDLK_s: imv_viewport_scale_to_window(&view, &img);break;
+ case SDLK_p: puts(imv_navigator_get_current_path(&nav));break;
}
break;
case SDL_MOUSEWHEEL: