diff options
author | Bert Münnich <be.muennich@googlemail.com> | 2012-05-06 13:02:34 +0200 |
---|---|---|
committer | Bert Münnich <be.muennich@googlemail.com> | 2012-05-06 13:02:34 +0200 |
commit | 4c40cc24bc6b3e11fc9e6cf337ddb035fa750eb3 (patch) | |
tree | ad2a11316cb2328e28a5bb223f87f1bd96b54fe3 /commands.c | |
parent | ba0a5b89fa1e9147c60ddb8bbc2b1bcbe2995cd8 (diff) |
Slightly refactored flipping
Diffstat (limited to 'commands.c')
-rw-r--r-- | commands.c | 14 |
1 files changed, 5 insertions, 9 deletions
@@ -343,18 +343,14 @@ bool i_rotate(arg_t a) { } bool i_flip(arg_t a) { - flip_t flp = (flip_t) a; + flipdir_t dir = (flipdir_t) a; if (mode == MODE_IMAGE) { - if (flp == FLIP_HORIZONTAL) { - img_flip_horizontal(&img); - return true; - } else if (flp == FLIP_VERTICAL) { - img_flip_vertical(&img); - return true; - } + img_flip(&img, dir); + return true; + } else { + return false; } - return false; } bool i_toggle_antialias(arg_t a) { |