diff options
author | Pekka Lampila <pekka.lampila@iki.fi> | 2007-10-16 15:14:23 +0300 |
---|---|---|
committer | Pekka Lampila <pekka.lampila@iki.fi> | 2007-10-16 15:14:23 +0300 |
commit | 2ea25933d093a59927f496b793027c075faea80e (patch) | |
tree | 70fc50208a4d1330a35c8632864b1cfc06f41fd7 /thumbnailer | |
parent | c1c93e544435897e1073a91fa94bd9db5c2f0971 (diff) |
Don't have GOption related variables be global in the thumbnailer
Diffstat (limited to 'thumbnailer')
-rw-r--r-- | thumbnailer/swfdec-thumbnailer.c | 32 |
1 files changed, 15 insertions, 17 deletions
diff --git a/thumbnailer/swfdec-thumbnailer.c b/thumbnailer/swfdec-thumbnailer.c index d721ac7..4179f5b 100644 --- a/thumbnailer/swfdec-thumbnailer.c +++ b/thumbnailer/swfdec-thumbnailer.c @@ -23,23 +23,6 @@ #include <libswfdec/swfdec.h> -static int size_output = 128; -static char **filenames = NULL; - -static const GOptionEntry entries[] = { - { - "size", 's', 0, G_OPTION_ARG_INT, &size_output, - "Size of the thumbnail in pixels (default 128)", NULL - }, - { - G_OPTION_REMAINING, '\0', 0, G_OPTION_ARG_FILENAME_ARRAY, &filenames, - NULL, "<INPUT FILE> <OUTPUT FILE>" - }, - { - NULL - } -}; - int main (int argc, char **argv) { @@ -51,6 +34,21 @@ main (int argc, char **argv) guint i, msecs, total; cairo_surface_t *surface; cairo_t *cr; + int size_output = 128; + char **filenames = NULL; + const GOptionEntry entries[] = { + { + "size", 's', 0, G_OPTION_ARG_INT, &size_output, + "Size of the thumbnail in pixels (default 128)", NULL + }, + { + G_OPTION_REMAINING, '\0', 0, G_OPTION_ARG_FILENAME_ARRAY, &filenames, + NULL, "<INPUT FILE> <OUTPUT FILE>" + }, + { + NULL + } + }; // init context = g_option_context_new ("Create a thumbnail for Flash file"); |