From 657d8b8812f16b2c377e5b77ff2ffcc4046a7dce Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?J=C3=B6rg=20Frings-F=C3=BCrst?= Date: Sun, 16 Jul 2017 10:20:56 +0200 Subject: New upstream version 3.25.1 --- src/Makefile.am | 65 - src/Makefile.in | 888 --- src/autosave-manager.c | 2725 -------- src/book-view.c | 3894 ------------ src/book-view.vala | 77 +- src/book.c | 6429 ------------------- src/book.vala | 63 +- src/colord.vapi | 17 - src/fixes.vapi | 4 - src/meson.build | 34 + src/packagekit-glib2.vapi | 1371 ---- src/page-view.c | 6912 --------------------- src/page.c | 4943 --------------- src/page.vala | 8 - src/resources.c | 6482 ------------------- src/sane-backends.vapi | 754 +++ src/sane.vapi | 754 --- src/scanner.c | 13397 ---------------------------------------- src/scanner.vala | 18 +- src/simple-scan.c | 4276 ------------- src/simple-scan.gresource.xml | 6 + src/simple-scan.ui | 1454 +++++ src/simple-scan.vala | 10 +- src/simple_scan_vala.stamp | 1 - src/ui.c | 13000 -------------------------------------- src/ui.vala | 202 +- 26 files changed, 2458 insertions(+), 65326 deletions(-) delete mode 100644 src/Makefile.am delete mode 100644 src/Makefile.in delete mode 100644 src/autosave-manager.c delete mode 100644 src/book-view.c delete mode 100644 src/book.c delete mode 100644 src/colord.vapi delete mode 100644 src/fixes.vapi create mode 100644 src/meson.build delete mode 100644 src/packagekit-glib2.vapi delete mode 100644 src/page-view.c delete mode 100644 src/page.c delete mode 100644 src/resources.c create mode 100644 src/sane-backends.vapi delete mode 100644 src/sane.vapi delete mode 100644 src/scanner.c delete mode 100644 src/simple-scan.c create mode 100644 src/simple-scan.gresource.xml create mode 100644 src/simple-scan.ui delete mode 100644 src/simple_scan_vala.stamp delete mode 100644 src/ui.c (limited to 'src') diff --git a/src/Makefile.am b/src/Makefile.am deleted file mode 100644 index 6c2e1ba..0000000 --- a/src/Makefile.am +++ /dev/null @@ -1,65 +0,0 @@ -bin_PROGRAMS = simple-scan - -resources.c: $(top_srcdir)/data/simple-scan.gresource.xml $(shell $(GLIB_COMPILE_RESOURCES) --generate-dependencies --sourcedir=$(top_srcdir)/data/ $(top_srcdir)/data/simple-scan.gresource.xml) - $(AM_V_GEN) $(GLIB_COMPILE_RESOURCES) --target=$@ --sourcedir=$(top_srcdir)/data/ --generate-source $< - -simple_scan_SOURCES = \ - config.vapi \ - book.vala \ - book-view.vala \ - colord.vapi \ - fixes.vapi \ - packagekit-glib2.vapi \ - page.vala \ - page-view.vala \ - sane.vapi \ - simple-scan.vala \ - scanner.vala \ - ui.vala \ - autosave-manager.vala \ - resources.c - -simple_scan_VALAFLAGS = \ - --pkg=posix \ - --pkg=zlib \ - --pkg=gusb \ - --pkg=gio-2.0 \ - --pkg=gtk+-3.0 \ - --gresources=$(top_srcdir)/data/simple-scan.gresource.xml \ - --debug \ - --target-glib 2.38 - -if HAVE_COLORD -simple_scan_VALAFLAGS += -D HAVE_COLORD -endif - -if HAVE_PACKAGEKIT -simple_scan_VALAFLAGS += -D HAVE_PACKAGEKIT -endif - -simple_scan_CFLAGS = \ - -w \ - $(SIMPLE_SCAN_CFLAGS) \ - $(COLORD_CFLAGS) \ - $(PACKAGEKIT_CFLAGS) \ - $(WARN_CFLAGS) \ - -DVERSION=\"$(VERSION)\" \ - -DGETTEXT_PACKAGE=\"$(GETTEXT_PACKAGE)\" \ - -DLOCALE_DIR=\"$(localedir)\" \ - -DUI_DIR=\"$(datadir)/simple-scan/\" \ - -DICON_DIR=\"$(datadir)/simple-scan/icons\" \ - -DGCONF_DIR=\"/apps/simple-scan\" \ - -DSIMPLE_SCAN_BINARY=\"simple-scan\" \ - -DI_KNOW_THE_PACKAGEKIT_GLIB2_API_IS_SUBJECT_TO_CHANGE - -simple_scan_LDADD = \ - $(SIMPLE_SCAN_LIBS) \ - $(COLORD_LIBS) \ - $(PACKAGEKIT_LIBS) \ - -lsane \ - -lm - -CLEANFILES = \ - $(patsubst %.vala,%.c,$(filter %.vala, $(SOURCES))) \ - resources.c \ - *_vala.stamp diff --git a/src/Makefile.in b/src/Makefile.in deleted file mode 100644 index caf53de..0000000 --- a/src/Makefile.in +++ /dev/null @@ -1,888 +0,0 @@ -# Makefile.in generated by automake 1.15 from Makefile.am. -# @configure_input@ - -# Copyright (C) 1994-2014 Free Software Foundation, Inc. - -# This Makefile.in is free software; the Free Software Foundation -# gives unlimited permission to copy and/or distribute it, -# with or without modifications, as long as this notice is preserved. - -# This program is distributed in the hope that it will be useful, -# but WITHOUT ANY WARRANTY, to the extent permitted by law; without -# even the implied warranty of MERCHANTABILITY or FITNESS FOR A -# PARTICULAR PURPOSE. - -@SET_MAKE@ - -VPATH = @srcdir@ -am__is_gnu_make = { \ - if test -z '$(MAKELEVEL)'; then \ - false; \ - elif test -n '$(MAKE_HOST)'; then \ - true; \ - elif test -n '$(MAKE_VERSION)' && test -n '$(CURDIR)'; then \ - true; \ - else \ - false; \ - fi; \ -} -am__make_running_with_option = \ - case $${target_option-} in \ - ?) ;; \ - *) echo "am__make_running_with_option: internal error: invalid" \ - "target option '$${target_option-}' specified" >&2; \ - exit 1;; \ - esac; \ - has_opt=no; \ - sane_makeflags=$$MAKEFLAGS; \ - if $(am__is_gnu_make); then \ - sane_makeflags=$$MFLAGS; \ - else \ - case $$MAKEFLAGS in \ - *\\[\ \ ]*) \ - bs=\\; \ - sane_makeflags=`printf '%s\n' "$$MAKEFLAGS" \ - | sed "s/$$bs$$bs[$$bs $$bs ]*//g"`;; \ - esac; \ - fi; \ - skip_next=no; \ - strip_trailopt () \ - { \ - flg=`printf '%s\n' "$$flg" | sed "s/$$1.*$$//"`; \ - }; \ - for flg in $$sane_makeflags; do \ - test $$skip_next = yes && { skip_next=no; continue; }; \ - case $$flg in \ - *=*|--*) continue;; \ - -*I) strip_trailopt 'I'; skip_next=yes;; \ - -*I?*) strip_trailopt 'I';; \ - -*O) strip_trailopt 'O'; skip_next=yes;; \ - -*O?*) strip_trailopt 'O';; \ - -*l) strip_trailopt 'l'; skip_next=yes;; \ - -*l?*) strip_trailopt 'l';; \ - -[dEDm]) skip_next=yes;; \ - -[JT]) skip_next=yes;; \ - esac; \ - case $$flg in \ - *$$target_option*) has_opt=yes; break;; \ - esac; \ - done; \ - test $$has_opt = yes -am__make_dryrun = (target_option=n; $(am__make_running_with_option)) -am__make_keepgoing = (target_option=k; $(am__make_running_with_option)) -pkgdatadir = $(datadir)/@PACKAGE@ -pkgincludedir = $(includedir)/@PACKAGE@ -pkglibdir = $(libdir)/@PACKAGE@ -pkglibexecdir = $(libexecdir)/@PACKAGE@ -am__cd = CDPATH="$${ZSH_VERSION+.}$(PATH_SEPARATOR)" && cd -install_sh_DATA = $(install_sh) -c -m 644 -install_sh_PROGRAM = $(install_sh) -c -install_sh_SCRIPT = $(install_sh) -c -INSTALL_HEADER = $(INSTALL_DATA) -transform = $(program_transform_name) -NORMAL_INSTALL = : -PRE_INSTALL = : -POST_INSTALL = : -NORMAL_UNINSTALL = : -PRE_UNINSTALL = : -POST_UNINSTALL = : -build_triplet = @build@ -host_triplet = @host@ -bin_PROGRAMS = simple-scan$(EXEEXT) -@HAVE_COLORD_TRUE@am__append_1 = -D HAVE_COLORD -@HAVE_PACKAGEKIT_TRUE@am__append_2 = -D HAVE_PACKAGEKIT -subdir = src -ACLOCAL_M4 = $(top_srcdir)/aclocal.m4 -am__aclocal_m4_deps = $(top_srcdir)/m4/appstream-xml.m4 \ - $(top_srcdir)/m4/gettext.m4 $(top_srcdir)/m4/gsettings.m4 \ - $(top_srcdir)/m4/iconv.m4 $(top_srcdir)/m4/intlmacosx.m4 \ - $(top_srcdir)/m4/lib-ld.m4 $(top_srcdir)/m4/lib-link.m4 \ - $(top_srcdir)/m4/lib-prefix.m4 $(top_srcdir)/m4/nls.m4 \ - $(top_srcdir)/m4/pkg.m4 $(top_srcdir)/m4/po.m4 \ - $(top_srcdir)/m4/progtest.m4 $(top_srcdir)/m4/yelp.m4 \ - $(top_srcdir)/configure.ac -am__configure_deps = $(am__aclocal_m4_deps) $(CONFIGURE_DEPENDENCIES) \ - $(ACLOCAL_M4) -DIST_COMMON = $(srcdir)/Makefile.am $(am__DIST_COMMON) -mkinstalldirs = $(install_sh) -d -CONFIG_CLEAN_FILES = -CONFIG_CLEAN_VPATH_FILES = -am__installdirs = "$(DESTDIR)$(bindir)" -PROGRAMS = $(bin_PROGRAMS) -am_simple_scan_OBJECTS = simple_scan-book.$(OBJEXT) \ - simple_scan-book-view.$(OBJEXT) simple_scan-page.$(OBJEXT) \ - simple_scan-page-view.$(OBJEXT) \ - simple_scan-simple-scan.$(OBJEXT) \ - simple_scan-scanner.$(OBJEXT) simple_scan-ui.$(OBJEXT) \ - simple_scan-autosave-manager.$(OBJEXT) \ - simple_scan-resources.$(OBJEXT) -simple_scan_OBJECTS = $(am_simple_scan_OBJECTS) -am__DEPENDENCIES_1 = -simple_scan_DEPENDENCIES = $(am__DEPENDENCIES_1) $(am__DEPENDENCIES_1) \ - $(am__DEPENDENCIES_1) -simple_scan_LINK = $(CCLD) $(simple_scan_CFLAGS) $(CFLAGS) \ - $(AM_LDFLAGS) $(LDFLAGS) -o $@ -AM_V_P = $(am__v_P_@AM_V@) -am__v_P_ = $(am__v_P_@AM_DEFAULT_V@) -am__v_P_0 = false -am__v_P_1 = : -AM_V_GEN = $(am__v_GEN_@AM_V@) -am__v_GEN_ = $(am__v_GEN_@AM_DEFAULT_V@) -am__v_GEN_0 = @echo " GEN " $@; -am__v_GEN_1 = -AM_V_at = $(am__v_at_@AM_V@) -am__v_at_ = $(am__v_at_@AM_DEFAULT_V@) -am__v_at_0 = @ -am__v_at_1 = -DEFAULT_INCLUDES = -I.@am__isrc@ -depcomp = $(SHELL) $(top_srcdir)/depcomp -am__depfiles_maybe = depfiles -am__mv = mv -f -AM_V_lt = $(am__v_lt_@AM_V@) -am__v_lt_ = $(am__v_lt_@AM_DEFAULT_V@) -am__v_lt_0 = --silent -am__v_lt_1 = -COMPILE = $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) \ - $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -AM_V_CC = $(am__v_CC_@AM_V@) -am__v_CC_ = $(am__v_CC_@AM_DEFAULT_V@) -am__v_CC_0 = @echo " CC " $@; -am__v_CC_1 = -CCLD = $(CC) -LINK = $(CCLD) $(AM_CFLAGS) $(CFLAGS) $(AM_LDFLAGS) $(LDFLAGS) -o $@ -AM_V_CCLD = $(am__v_CCLD_@AM_V@) -am__v_CCLD_ = $(am__v_CCLD_@AM_DEFAULT_V@) -am__v_CCLD_0 = @echo " CCLD " $@; -am__v_CCLD_1 = -VALACOMPILE = $(VALAC) $(AM_VALAFLAGS) $(VALAFLAGS) -AM_V_VALAC = $(am__v_VALAC_@AM_V@) -am__v_VALAC_ = $(am__v_VALAC_@AM_DEFAULT_V@) -am__v_VALAC_0 = @echo " VALAC " $@; -am__v_VALAC_1 = -SOURCES = $(simple_scan_SOURCES) -DIST_SOURCES = $(simple_scan_SOURCES) -am__can_run_installinfo = \ - case $$AM_UPDATE_INFO_DIR in \ - n|no|NO) false;; \ - *) (install-info --version) >/dev/null 2>&1;; \ - esac -am__tagged_files = $(HEADERS) $(SOURCES) $(TAGS_FILES) $(LISP) -# Read a list of newline-separated strings from the standard input, -# and print each of them once, without duplicates. Input order is -# *not* preserved. -am__uniquify_input = $(AWK) '\ - BEGIN { nonempty = 0; } \ - { items[$$0] = 1; nonempty = 1; } \ - END { if (nonempty) { for (i in items) print i; }; } \ -' -# Make sure the list of sources is unique. This is necessary because, -# e.g., the same source file might be shared among _SOURCES variables -# for different programs/libraries. -am__define_uniq_tagged_files = \ - list='$(am__tagged_files)'; \ - unique=`for i in $$list; do \ - if test -f "$$i"; then echo $$i; else echo $(srcdir)/$$i; fi; \ - done | $(am__uniquify_input)` -ETAGS = etags -CTAGS = ctags -am__DIST_COMMON = $(srcdir)/Makefile.in \ - $(srcdir)/simple_scan_vala.stamp $(top_srcdir)/depcomp \ - autosave-manager.c book-view.c book.c page-view.c page.c \ - scanner.c simple-scan.c ui.c -DISTFILES = $(DIST_COMMON) $(DIST_SOURCES) $(TEXINFOS) $(EXTRA_DIST) -ACLOCAL = @ACLOCAL@ -AMTAR = @AMTAR@ -AM_DEFAULT_VERBOSITY = @AM_DEFAULT_VERBOSITY@ -APPSTREAM_UTIL = @APPSTREAM_UTIL@ -AUTOCONF = @AUTOCONF@ -AUTOHEADER = @AUTOHEADER@ -AUTOMAKE = @AUTOMAKE@ -AWK = @AWK@ -CC = @CC@ -CCDEPMODE = @CCDEPMODE@ -CFLAGS = @CFLAGS@ -COLORD_CFLAGS = @COLORD_CFLAGS@ -COLORD_LIBS = @COLORD_LIBS@ -CPP = @CPP@ -CPPFLAGS = @CPPFLAGS@ -CYGPATH_W = @CYGPATH_W@ -DEFS = @DEFS@ -DEPDIR = @DEPDIR@ -ECHO_C = @ECHO_C@ -ECHO_N = @ECHO_N@ -ECHO_T = @ECHO_T@ -EGREP = @EGREP@ -EXEEXT = @EXEEXT@ -GETTEXT_MACRO_VERSION = @GETTEXT_MACRO_VERSION@ -GETTEXT_PACKAGE = @GETTEXT_PACKAGE@ -GLIB_COMPILE_RESOURCES = @GLIB_COMPILE_RESOURCES@ -GLIB_COMPILE_SCHEMAS = @GLIB_COMPILE_SCHEMAS@ -GMSGFMT = @GMSGFMT@ -GMSGFMT_015 = @GMSGFMT_015@ -GREP = @GREP@ -GSETTINGS_DISABLE_SCHEMAS_COMPILE = @GSETTINGS_DISABLE_SCHEMAS_COMPILE@ -HELP_DIR = @HELP_DIR@ -INSTALL = @INSTALL@ -INSTALL_DATA = @INSTALL_DATA@ -INSTALL_PROGRAM = @INSTALL_PROGRAM@ -INSTALL_SCRIPT = @INSTALL_SCRIPT@ -INSTALL_STRIP_PROGRAM = @INSTALL_STRIP_PROGRAM@ -INTLLIBS = @INTLLIBS@ -INTL_MACOSX_LIBS = @INTL_MACOSX_LIBS@ -ITSTOOL = @ITSTOOL@ -LDFLAGS = @LDFLAGS@ -LIBICONV = @LIBICONV@ -LIBINTL = @LIBINTL@ -LIBOBJS = @LIBOBJS@ -LIBS = @LIBS@ -LN_S = @LN_S@ -LTLIBICONV = @LTLIBICONV@ -LTLIBINTL = @LTLIBINTL@ -LTLIBOBJS = @LTLIBOBJS@ -MAINT = @MAINT@ -MAKEINFO = @MAKEINFO@ -MKDIR_P = @MKDIR_P@ -MSGFMT = @MSGFMT@ -MSGFMT_015 = @MSGFMT_015@ -MSGMERGE = @MSGMERGE@ -OBJEXT = @OBJEXT@ -PACKAGE = @PACKAGE@ -PACKAGEKIT_CFLAGS = @PACKAGEKIT_CFLAGS@ -PACKAGEKIT_LIBS = @PACKAGEKIT_LIBS@ -PACKAGE_BUGREPORT = @PACKAGE_BUGREPORT@ -PACKAGE_NAME = @PACKAGE_NAME@ -PACKAGE_STRING = @PACKAGE_STRING@ -PACKAGE_TARNAME = @PACKAGE_TARNAME@ -PACKAGE_URL = @PACKAGE_URL@ -PACKAGE_VERSION = @PACKAGE_VERSION@ -PATH_SEPARATOR = @PATH_SEPARATOR@ -PKG_CONFIG = @PKG_CONFIG@ -PKG_CONFIG_LIBDIR = @PKG_CONFIG_LIBDIR@ -PKG_CONFIG_PATH = @PKG_CONFIG_PATH@ -POSUB = @POSUB@ -SED = @SED@ -SET_MAKE = @SET_MAKE@ -SHELL = @SHELL@ -SIMPLE_SCAN_CFLAGS = @SIMPLE_SCAN_CFLAGS@ -SIMPLE_SCAN_LIBS = @SIMPLE_SCAN_LIBS@ -STRIP = @STRIP@ -USE_NLS = @USE_NLS@ -VALAC = @VALAC@ -VERSION = @VERSION@ -XGETTEXT = @XGETTEXT@ -XGETTEXT_015 = @XGETTEXT_015@ -XGETTEXT_EXTRA_OPTIONS = @XGETTEXT_EXTRA_OPTIONS@ -XMLLINT = @XMLLINT@ -YELP_LC_DIST = @YELP_LC_DIST@ -YELP_LC_MEDIA_LINKS = @YELP_LC_MEDIA_LINKS@ -abs_builddir = @abs_builddir@ -abs_srcdir = @abs_srcdir@ -abs_top_builddir = @abs_top_builddir@ -abs_top_srcdir = @abs_top_srcdir@ -ac_ct_CC = @ac_ct_CC@ -am__include = @am__include@ -am__leading_dot = @am__leading_dot@ -am__quote = @am__quote@ -am__tar = @am__tar@ -am__untar = @am__untar@ -appstreamxmldir = @appstreamxmldir@ -bindir = @bindir@ -build = @build@ -build_alias = @build_alias@ -build_cpu = @build_cpu@ -build_os = @build_os@ -build_vendor = @build_vendor@ -builddir = @builddir@ -datadir = @datadir@ -datarootdir = @datarootdir@ -docdir = @docdir@ -dvidir = @dvidir@ -exec_prefix = @exec_prefix@ -gsettingsschemadir = @gsettingsschemadir@ -host = @host@ -host_alias = @host_alias@ -host_cpu = @host_cpu@ -host_os = @host_os@ -host_vendor = @host_vendor@ -htmldir = @htmldir@ -includedir = @includedir@ -infodir = @infodir@ -install_sh = @install_sh@ -libdir = @libdir@ -libexecdir = @libexecdir@ -localedir = @localedir@ -localstatedir = @localstatedir@ -mandir = @mandir@ -mkdir_p = @mkdir_p@ -oldincludedir = @oldincludedir@ -pdfdir = @pdfdir@ -prefix = @prefix@ -program_transform_name = @program_transform_name@ -psdir = @psdir@ -runstatedir = @runstatedir@ -sbindir = @sbindir@ -sharedstatedir = @sharedstatedir@ -srcdir = @srcdir@ -sysconfdir = @sysconfdir@ -target_alias = @target_alias@ -top_build_prefix = @top_build_prefix@ -top_builddir = @top_builddir@ -top_srcdir = @top_srcdir@ -simple_scan_SOURCES = \ - config.vapi \ - book.vala \ - book-view.vala \ - colord.vapi \ - fixes.vapi \ - packagekit-glib2.vapi \ - page.vala \ - page-view.vala \ - sane.vapi \ - simple-scan.vala \ - scanner.vala \ - ui.vala \ - autosave-manager.vala \ - resources.c - -simple_scan_VALAFLAGS = --pkg=posix --pkg=zlib --pkg=gusb \ - --pkg=gio-2.0 --pkg=gtk+-3.0 \ - --gresources=$(top_srcdir)/data/simple-scan.gresource.xml \ - --debug --target-glib 2.38 $(am__append_1) $(am__append_2) -simple_scan_CFLAGS = \ - -w \ - $(SIMPLE_SCAN_CFLAGS) \ - $(COLORD_CFLAGS) \ - $(PACKAGEKIT_CFLAGS) \ - $(WARN_CFLAGS) \ - -DVERSION=\"$(VERSION)\" \ - -DGETTEXT_PACKAGE=\"$(GETTEXT_PACKAGE)\" \ - -DLOCALE_DIR=\"$(localedir)\" \ - -DUI_DIR=\"$(datadir)/simple-scan/\" \ - -DICON_DIR=\"$(datadir)/simple-scan/icons\" \ - -DGCONF_DIR=\"/apps/simple-scan\" \ - -DSIMPLE_SCAN_BINARY=\"simple-scan\" \ - -DI_KNOW_THE_PACKAGEKIT_GLIB2_API_IS_SUBJECT_TO_CHANGE - -simple_scan_LDADD = \ - $(SIMPLE_SCAN_LIBS) \ - $(COLORD_LIBS) \ - $(PACKAGEKIT_LIBS) \ - -lsane \ - -lm - -CLEANFILES = \ - $(patsubst %.vala,%.c,$(filter %.vala, $(SOURCES))) \ - resources.c \ - *_vala.stamp - -all: all-am - -.SUFFIXES: -.SUFFIXES: .c .o .obj -$(srcdir)/Makefile.in: @MAINTAINER_MODE_TRUE@ $(srcdir)/Makefile.am $(am__configure_deps) - @for dep in $?; do \ - case '$(am__configure_deps)' in \ - *$$dep*) \ - ( cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh ) \ - && { if test -f $@; then exit 0; else break; fi; }; \ - exit 1;; \ - esac; \ - done; \ - echo ' cd $(top_srcdir) && $(AUTOMAKE) --foreign src/Makefile'; \ - $(am__cd) $(top_srcdir) && \ - $(AUTOMAKE) --foreign src/Makefile -Makefile: $(srcdir)/Makefile.in $(top_builddir)/config.status - @case '$?' in \ - *config.status*) \ - cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh;; \ - *) \ - echo ' cd $(top_builddir) && $(SHELL) ./config.status $(subdir)/$@ $(am__depfiles_maybe)'; \ - cd $(top_builddir) && $(SHELL) ./config.status $(subdir)/$@ $(am__depfiles_maybe);; \ - esac; - -$(top_builddir)/config.status: $(top_srcdir)/configure $(CONFIG_STATUS_DEPENDENCIES) - cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh - -$(top_srcdir)/configure: @MAINTAINER_MODE_TRUE@ $(am__configure_deps) - cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh -$(ACLOCAL_M4): @MAINTAINER_MODE_TRUE@ $(am__aclocal_m4_deps) - cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh -$(am__aclocal_m4_deps): -install-binPROGRAMS: $(bin_PROGRAMS) - @$(NORMAL_INSTALL) - @list='$(bin_PROGRAMS)'; test -n "$(bindir)" || list=; \ - if test -n "$$list"; then \ - echo " $(MKDIR_P) '$(DESTDIR)$(bindir)'"; \ - $(MKDIR_P) "$(DESTDIR)$(bindir)" || exit 1; \ - fi; \ - for p in $$list; do echo "$$p $$p"; done | \ - sed 's/$(EXEEXT)$$//' | \ - while read p p1; do if test -f $$p \ - ; then echo "$$p"; echo "$$p"; else :; fi; \ - done | \ - sed -e 'p;s,.*/,,;n;h' \ - -e 's|.*|.|' \ - -e 'p;x;s,.*/,,;s/$(EXEEXT)$$//;$(transform);s/$$/$(EXEEXT)/' | \ - sed 'N;N;N;s,\n, ,g' | \ - $(AWK) 'BEGIN { files["."] = ""; dirs["."] = 1 } \ - { d=$$3; if (dirs[d] != 1) { print "d", d; dirs[d] = 1 } \ - if ($$2 == $$4) files[d] = files[d] " " $$1; \ - else { print "f", $$3 "/" $$4, $$1; } } \ - END { for (d in files) print "f", d, files[d] }' | \ - while read type dir files; do \ - if test "$$dir" = .; then dir=; else dir=/$$dir; fi; \ - test -z "$$files" || { \ - echo " $(INSTALL_PROGRAM_ENV) $(INSTALL_PROGRAM) $$files '$(DESTDIR)$(bindir)$$dir'"; \ - $(INSTALL_PROGRAM_ENV) $(INSTALL_PROGRAM) $$files "$(DESTDIR)$(bindir)$$dir" || exit $$?; \ - } \ - ; done - -uninstall-binPROGRAMS: - @$(NORMAL_UNINSTALL) - @list='$(bin_PROGRAMS)'; test -n "$(bindir)" || list=; \ - files=`for p in $$list; do echo "$$p"; done | \ - sed -e 'h;s,^.*/,,;s/$(EXEEXT)$$//;$(transform)' \ - -e 's/$$/$(EXEEXT)/' \ - `; \ - test -n "$$list" || exit 0; \ - echo " ( cd '$(DESTDIR)$(bindir)' && rm -f" $$files ")"; \ - cd "$(DESTDIR)$(bindir)" && rm -f $$files - -clean-binPROGRAMS: - -test -z "$(bin_PROGRAMS)" || rm -f $(bin_PROGRAMS) - -simple-scan$(EXEEXT): $(simple_scan_OBJECTS) $(simple_scan_DEPENDENCIES) $(EXTRA_simple_scan_DEPENDENCIES) - @rm -f simple-scan$(EXEEXT) - $(AM_V_CCLD)$(simple_scan_LINK) $(simple_scan_OBJECTS) $(simple_scan_LDADD) $(LIBS) - -mostlyclean-compile: - -rm -f *.$(OBJEXT) - -distclean-compile: - -rm -f *.tab.c - -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/simple_scan-autosave-manager.Po@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/simple_scan-book-view.Po@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/simple_scan-book.Po@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/simple_scan-page-view.Po@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/simple_scan-page.Po@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/simple_scan-resources.Po@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/simple_scan-scanner.Po@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/simple_scan-simple-scan.Po@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/simple_scan-ui.Po@am__quote@ - -.c.o: -@am__fastdepCC_TRUE@ $(AM_V_CC)$(COMPILE) -MT $@ -MD -MP -MF $(DEPDIR)/$*.Tpo -c -o $@ $< -@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/$*.Tpo $(DEPDIR)/$*.Po -@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='$<' object='$@' libtool=no @AMDEPBACKSLASH@ -@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ -@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(COMPILE) -c -o $@ $< - -.c.obj: -@am__fastdepCC_TRUE@ $(AM_V_CC)$(COMPILE) -MT $@ -MD -MP -MF $(DEPDIR)/$*.Tpo -c -o $@ `$(CYGPATH_W) '$<'` -@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/$*.Tpo $(DEPDIR)/$*.Po -@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='$<' object='$@' libtool=no @AMDEPBACKSLASH@ -@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ -@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(COMPILE) -c -o $@ `$(CYGPATH_W) '$<'` - -simple_scan-book.o: book.c -@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(simple_scan_CFLAGS) $(CFLAGS) -MT simple_scan-book.o -MD -MP -MF $(DEPDIR)/simple_scan-book.Tpo -c -o simple_scan-book.o `test -f 'book.c' || echo '$(srcdir)/'`book.c -@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/simple_scan-book.Tpo $(DEPDIR)/simple_scan-book.Po -@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='book.c' object='simple_scan-book.o' libtool=no @AMDEPBACKSLASH@ -@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ -@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(simple_scan_CFLAGS) $(CFLAGS) -c -o simple_scan-book.o `test -f 'book.c' || echo '$(srcdir)/'`book.c - -simple_scan-book.obj: book.c -@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(simple_scan_CFLAGS) $(CFLAGS) -MT simple_scan-book.obj -MD -MP -MF $(DEPDIR)/simple_scan-book.Tpo -c -o simple_scan-book.obj `if test -f 'book.c'; then $(CYGPATH_W) 'book.c'; else $(CYGPATH_W) '$(srcdir)/book.c'; fi` -@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/simple_scan-book.Tpo $(DEPDIR)/simple_scan-book.Po -@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='book.c' object='simple_scan-book.obj' libtool=no @AMDEPBACKSLASH@ -@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ -@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(simple_scan_CFLAGS) $(CFLAGS) -c -o simple_scan-book.obj `if test -f 'book.c'; then $(CYGPATH_W) 'book.c'; else $(CYGPATH_W) '$(srcdir)/book.c'; fi` - -simple_scan-book-view.o: book-view.c -@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(simple_scan_CFLAGS) $(CFLAGS) -MT simple_scan-book-view.o -MD -MP -MF $(DEPDIR)/simple_scan-book-view.Tpo -c -o simple_scan-book-view.o `test -f 'book-view.c' || echo '$(srcdir)/'`book-view.c -@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/simple_scan-book-view.Tpo $(DEPDIR)/simple_scan-book-view.Po -@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='book-view.c' object='simple_scan-book-view.o' libtool=no @AMDEPBACKSLASH@ -@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ -@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(simple_scan_CFLAGS) $(CFLAGS) -c -o simple_scan-book-view.o `test -f 'book-view.c' || echo '$(srcdir)/'`book-view.c - -simple_scan-book-view.obj: book-view.c -@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(simple_scan_CFLAGS) $(CFLAGS) -MT simple_scan-book-view.obj -MD -MP -MF $(DEPDIR)/simple_scan-book-view.Tpo -c -o simple_scan-book-view.obj `if test -f 'book-view.c'; then $(CYGPATH_W) 'book-view.c'; else $(CYGPATH_W) '$(srcdir)/book-view.c'; fi` -@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/simple_scan-book-view.Tpo $(DEPDIR)/simple_scan-book-view.Po -@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='book-view.c' object='simple_scan-book-view.obj' libtool=no @AMDEPBACKSLASH@ -@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ -@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(simple_scan_CFLAGS) $(CFLAGS) -c -o simple_scan-book-view.obj `if test -f 'book-view.c'; then $(CYGPATH_W) 'book-view.c'; else $(CYGPATH_W) '$(srcdir)/book-view.c'; fi` - -simple_scan-page.o: page.c -@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(simple_scan_CFLAGS) $(CFLAGS) -MT simple_scan-page.o -MD -MP -MF $(DEPDIR)/simple_scan-page.Tpo -c -o simple_scan-page.o `test -f 'page.c' || echo '$(srcdir)/'`page.c -@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/simple_scan-page.Tpo $(DEPDIR)/simple_scan-page.Po -@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='page.c' object='simple_scan-page.o' libtool=no @AMDEPBACKSLASH@ -@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ -@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(simple_scan_CFLAGS) $(CFLAGS) -c -o simple_scan-page.o `test -f 'page.c' || echo '$(srcdir)/'`page.c - -simple_scan-page.obj: page.c -@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(simple_scan_CFLAGS) $(CFLAGS) -MT simple_scan-page.obj -MD -MP -MF $(DEPDIR)/simple_scan-page.Tpo -c -o simple_scan-page.obj `if test -f 'page.c'; then $(CYGPATH_W) 'page.c'; else $(CYGPATH_W) '$(srcdir)/page.c'; fi` -@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/simple_scan-page.Tpo $(DEPDIR)/simple_scan-page.Po -@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='page.c' object='simple_scan-page.obj' libtool=no @AMDEPBACKSLASH@ -@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ -@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(simple_scan_CFLAGS) $(CFLAGS) -c -o simple_scan-page.obj `if test -f 'page.c'; then $(CYGPATH_W) 'page.c'; else $(CYGPATH_W) '$(srcdir)/page.c'; fi` - -simple_scan-page-view.o: page-view.c -@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(simple_scan_CFLAGS) $(CFLAGS) -MT simple_scan-page-view.o -MD -MP -MF $(DEPDIR)/simple_scan-page-view.Tpo -c -o simple_scan-page-view.o `test -f 'page-view.c' || echo '$(srcdir)/'`page-view.c -@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/simple_scan-page-view.Tpo $(DEPDIR)/simple_scan-page-view.Po -@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='page-view.c' object='simple_scan-page-view.o' libtool=no @AMDEPBACKSLASH@ -@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ -@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(simple_scan_CFLAGS) $(CFLAGS) -c -o simple_scan-page-view.o `test -f 'page-view.c' || echo '$(srcdir)/'`page-view.c - -simple_scan-page-view.obj: page-view.c -@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(simple_scan_CFLAGS) $(CFLAGS) -MT simple_scan-page-view.obj -MD -MP -MF $(DEPDIR)/simple_scan-page-view.Tpo -c -o simple_scan-page-view.obj `if test -f 'page-view.c'; then $(CYGPATH_W) 'page-view.c'; else $(CYGPATH_W) '$(srcdir)/page-view.c'; fi` -@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/simple_scan-page-view.Tpo $(DEPDIR)/simple_scan-page-view.Po -@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='page-view.c' object='simple_scan-page-view.obj' libtool=no @AMDEPBACKSLASH@ -@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ -@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(simple_scan_CFLAGS) $(CFLAGS) -c -o simple_scan-page-view.obj `if test -f 'page-view.c'; then $(CYGPATH_W) 'page-view.c'; else $(CYGPATH_W) '$(srcdir)/page-view.c'; fi` - -simple_scan-simple-scan.o: simple-scan.c -@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(simple_scan_CFLAGS) $(CFLAGS) -MT simple_scan-simple-scan.o -MD -MP -MF $(DEPDIR)/simple_scan-simple-scan.Tpo -c -o simple_scan-simple-scan.o `test -f 'simple-scan.c' || echo '$(srcdir)/'`simple-scan.c -@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/simple_scan-simple-scan.Tpo $(DEPDIR)/simple_scan-simple-scan.Po -@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='simple-scan.c' object='simple_scan-simple-scan.o' libtool=no @AMDEPBACKSLASH@ -@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ -@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(simple_scan_CFLAGS) $(CFLAGS) -c -o simple_scan-simple-scan.o `test -f 'simple-scan.c' || echo '$(srcdir)/'`simple-scan.c - -simple_scan-simple-scan.obj: simple-scan.c -@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(simple_scan_CFLAGS) $(CFLAGS) -MT simple_scan-simple-scan.obj -MD -MP -MF $(DEPDIR)/simple_scan-simple-scan.Tpo -c -o simple_scan-simple-scan.obj `if test -f 'simple-scan.c'; then $(CYGPATH_W) 'simple-scan.c'; else $(CYGPATH_W) '$(srcdir)/simple-scan.c'; fi` -@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/simple_scan-simple-scan.Tpo $(DEPDIR)/simple_scan-simple-scan.Po -@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='simple-scan.c' object='simple_scan-simple-scan.obj' libtool=no @AMDEPBACKSLASH@ -@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ -@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(simple_scan_CFLAGS) $(CFLAGS) -c -o simple_scan-simple-scan.obj `if test -f 'simple-scan.c'; then $(CYGPATH_W) 'simple-scan.c'; else $(CYGPATH_W) '$(srcdir)/simple-scan.c'; fi` - -simple_scan-scanner.o: scanner.c -@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(simple_scan_CFLAGS) $(CFLAGS) -MT simple_scan-scanner.o -MD -MP -MF $(DEPDIR)/simple_scan-scanner.Tpo -c -o simple_scan-scanner.o `test -f 'scanner.c' || echo '$(srcdir)/'`scanner.c -@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/simple_scan-scanner.Tpo $(DEPDIR)/simple_scan-scanner.Po -@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='scanner.c' object='simple_scan-scanner.o' libtool=no @AMDEPBACKSLASH@ -@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ -@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(simple_scan_CFLAGS) $(CFLAGS) -c -o simple_scan-scanner.o `test -f 'scanner.c' || echo '$(srcdir)/'`scanner.c - -simple_scan-scanner.obj: scanner.c -@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(simple_scan_CFLAGS) $(CFLAGS) -MT simple_scan-scanner.obj -MD -MP -MF $(DEPDIR)/simple_scan-scanner.Tpo -c -o simple_scan-scanner.obj `if test -f 'scanner.c'; then $(CYGPATH_W) 'scanner.c'; else $(CYGPATH_W) '$(srcdir)/scanner.c'; fi` -@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/simple_scan-scanner.Tpo $(DEPDIR)/simple_scan-scanner.Po -@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='scanner.c' object='simple_scan-scanner.obj' libtool=no @AMDEPBACKSLASH@ -@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ -@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(simple_scan_CFLAGS) $(CFLAGS) -c -o simple_scan-scanner.obj `if test -f 'scanner.c'; then $(CYGPATH_W) 'scanner.c'; else $(CYGPATH_W) '$(srcdir)/scanner.c'; fi` - -simple_scan-ui.o: ui.c -@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(simple_scan_CFLAGS) $(CFLAGS) -MT simple_scan-ui.o -MD -MP -MF $(DEPDIR)/simple_scan-ui.Tpo -c -o simple_scan-ui.o `test -f 'ui.c' || echo '$(srcdir)/'`ui.c -@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/simple_scan-ui.Tpo $(DEPDIR)/simple_scan-ui.Po -@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='ui.c' object='simple_scan-ui.o' libtool=no @AMDEPBACKSLASH@ -@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ -@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(simple_scan_CFLAGS) $(CFLAGS) -c -o simple_scan-ui.o `test -f 'ui.c' || echo '$(srcdir)/'`ui.c - -simple_scan-ui.obj: ui.c -@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(simple_scan_CFLAGS) $(CFLAGS) -MT simple_scan-ui.obj -MD -MP -MF $(DEPDIR)/simple_scan-ui.Tpo -c -o simple_scan-ui.obj `if test -f 'ui.c'; then $(CYGPATH_W) 'ui.c'; else $(CYGPATH_W) '$(srcdir)/ui.c'; fi` -@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/simple_scan-ui.Tpo $(DEPDIR)/simple_scan-ui.Po -@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='ui.c' object='simple_scan-ui.obj' libtool=no @AMDEPBACKSLASH@ -@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ -@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(simple_scan_CFLAGS) $(CFLAGS) -c -o simple_scan-ui.obj `if test -f 'ui.c'; then $(CYGPATH_W) 'ui.c'; else $(CYGPATH_W) '$(srcdir)/ui.c'; fi` - -simple_scan-autosave-manager.o: autosave-manager.c -@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(simple_scan_CFLAGS) $(CFLAGS) -MT simple_scan-autosave-manager.o -MD -MP -MF $(DEPDIR)/simple_scan-autosave-manager.Tpo -c -o simple_scan-autosave-manager.o `test -f 'autosave-manager.c' || echo '$(srcdir)/'`autosave-manager.c -@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/simple_scan-autosave-manager.Tpo $(DEPDIR)/simple_scan-autosave-manager.Po -@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='autosave-manager.c' object='simple_scan-autosave-manager.o' libtool=no @AMDEPBACKSLASH@ -@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ -@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(simple_scan_CFLAGS) $(CFLAGS) -c -o simple_scan-autosave-manager.o `test -f 'autosave-manager.c' || echo '$(srcdir)/'`autosave-manager.c - -simple_scan-autosave-manager.obj: autosave-manager.c -@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(simple_scan_CFLAGS) $(CFLAGS) -MT simple_scan-autosave-manager.obj -MD -MP -MF $(DEPDIR)/simple_scan-autosave-manager.Tpo -c -o simple_scan-autosave-manager.obj `if test -f 'autosave-manager.c'; then $(CYGPATH_W) 'autosave-manager.c'; else $(CYGPATH_W) '$(srcdir)/autosave-manager.c'; fi` -@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/simple_scan-autosave-manager.Tpo $(DEPDIR)/simple_scan-autosave-manager.Po -@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='autosave-manager.c' object='simple_scan-autosave-manager.obj' libtool=no @AMDEPBACKSLASH@ -@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ -@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(simple_scan_CFLAGS) $(CFLAGS) -c -o simple_scan-autosave-manager.obj `if test -f 'autosave-manager.c'; then $(CYGPATH_W) 'autosave-manager.c'; else $(CYGPATH_W) '$(srcdir)/autosave-manager.c'; fi` - -simple_scan-resources.o: resources.c -@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(simple_scan_CFLAGS) $(CFLAGS) -MT simple_scan-resources.o -MD -MP -MF $(DEPDIR)/simple_scan-resources.Tpo -c -o simple_scan-resources.o `test -f 'resources.c' || echo '$(srcdir)/'`resources.c -@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/simple_scan-resources.Tpo $(DEPDIR)/simple_scan-resources.Po -@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='resources.c' object='simple_scan-resources.o' libtool=no @AMDEPBACKSLASH@ -@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ -@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(simple_scan_CFLAGS) $(CFLAGS) -c -o simple_scan-resources.o `test -f 'resources.c' || echo '$(srcdir)/'`resources.c - -simple_scan-resources.obj: resources.c -@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(simple_scan_CFLAGS) $(CFLAGS) -MT simple_scan-resources.obj -MD -MP -MF $(DEPDIR)/simple_scan-resources.Tpo -c -o simple_scan-resources.obj `if test -f 'resources.c'; then $(CYGPATH_W) 'resources.c'; else $(CYGPATH_W) '$(srcdir)/resources.c'; fi` -@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/simple_scan-resources.Tpo $(DEPDIR)/simple_scan-resources.Po -@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='resources.c' object='simple_scan-resources.obj' libtool=no @AMDEPBACKSLASH@ -@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ -@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(simple_scan_CFLAGS) $(CFLAGS) -c -o simple_scan-resources.obj `if test -f 'resources.c'; then $(CYGPATH_W) 'resources.c'; else $(CYGPATH_W) '$(srcdir)/resources.c'; fi` -$(srcdir)/book.c: $(srcdir)/simple_scan_vala.stamp - @if test -f $@; then :; else rm -f $(srcdir)/simple_scan_vala.stamp; fi - @if test -f $@; then :; else \ - $(MAKE) $(AM_MAKEFLAGS) $(srcdir)/simple_scan_vala.stamp; \ - fi -$(srcdir)/book-view.c: $(srcdir)/simple_scan_vala.stamp - @if test -f $@; then :; else rm -f $(srcdir)/simple_scan_vala.stamp; fi - @if test -f $@; then :; else \ - $(MAKE) $(AM_MAKEFLAGS) $(srcdir)/simple_scan_vala.stamp; \ - fi -$(srcdir)/page.c: $(srcdir)/simple_scan_vala.stamp - @if test -f $@; then :; else rm -f $(srcdir)/simple_scan_vala.stamp; fi - @if test -f $@; then :; else \ - $(MAKE) $(AM_MAKEFLAGS) $(srcdir)/simple_scan_vala.stamp; \ - fi -$(srcdir)/page-view.c: $(srcdir)/simple_scan_vala.stamp - @if test -f $@; then :; else rm -f $(srcdir)/simple_scan_vala.stamp; fi - @if test -f $@; then :; else \ - $(MAKE) $(AM_MAKEFLAGS) $(srcdir)/simple_scan_vala.stamp; \ - fi -$(srcdir)/simple-scan.c: $(srcdir)/simple_scan_vala.stamp - @if test -f $@; then :; else rm -f $(srcdir)/simple_scan_vala.stamp; fi - @if test -f $@; then :; else \ - $(MAKE) $(AM_MAKEFLAGS) $(srcdir)/simple_scan_vala.stamp; \ - fi -$(srcdir)/scanner.c: $(srcdir)/simple_scan_vala.stamp - @if test -f $@; then :; else rm -f $(srcdir)/simple_scan_vala.stamp; fi - @if test -f $@; then :; else \ - $(MAKE) $(AM_MAKEFLAGS) $(srcdir)/simple_scan_vala.stamp; \ - fi -$(srcdir)/ui.c: $(srcdir)/simple_scan_vala.stamp - @if test -f $@; then :; else rm -f $(srcdir)/simple_scan_vala.stamp; fi - @if test -f $@; then :; else \ - $(MAKE) $(AM_MAKEFLAGS) $(srcdir)/simple_scan_vala.stamp; \ - fi -$(srcdir)/autosave-manager.c: $(srcdir)/simple_scan_vala.stamp - @if test -f $@; then :; else rm -f $(srcdir)/simple_scan_vala.stamp; fi - @if test -f $@; then :; else \ - $(MAKE) $(AM_MAKEFLAGS) $(srcdir)/simple_scan_vala.stamp; \ - fi -$(srcdir)/simple_scan_vala.stamp: config.vapi book.vala book-view.vala colord.vapi fixes.vapi packagekit-glib2.vapi page.vala page-view.vala sane.vapi simple-scan.vala scanner.vala ui.vala autosave-manager.vala - $(AM_V_at)rm -f $@ && echo stamp > $@-t - $(AM_V_VALAC)$(am__cd) $(srcdir) && $(VALAC) $(simple_scan_VALAFLAGS) $(VALAFLAGS) -C config.vapi book.vala book-view.vala colord.vapi fixes.vapi packagekit-glib2.vapi page.vala page-view.vala sane.vapi simple-scan.vala scanner.vala ui.vala autosave-manager.vala - $(AM_V_at)mv -f $@-t $@ - -ID: $(am__tagged_files) - $(am__define_uniq_tagged_files); mkid -fID $$unique -tags: tags-am -TAGS: tags - -tags-am: $(TAGS_DEPENDENCIES) $(am__tagged_files) - set x; \ - here=`pwd`; \ - $(am__define_uniq_tagged_files); \ - shift; \ - if test -z "$(ETAGS_ARGS)$$*$$unique"; then :; else \ - test -n "$$unique" || unique=$$empty_fix; \ - if test $$# -gt 0; then \ - $(ETAGS) $(ETAGSFLAGS) $(AM_ETAGSFLAGS) $(ETAGS_ARGS) \ - "$$@" $$unique; \ - else \ - $(ETAGS) $(ETAGSFLAGS) $(AM_ETAGSFLAGS) $(ETAGS_ARGS) \ - $$unique; \ - fi; \ - fi -ctags: ctags-am - -CTAGS: ctags -ctags-am: $(TAGS_DEPENDENCIES) $(am__tagged_files) - $(am__define_uniq_tagged_files); \ - test -z "$(CTAGS_ARGS)$$unique" \ - || $(CTAGS) $(CTAGSFLAGS) $(AM_CTAGSFLAGS) $(CTAGS_ARGS) \ - $$unique - -GTAGS: - here=`$(am__cd) $(top_builddir) && pwd` \ - && $(am__cd) $(top_srcdir) \ - && gtags -i $(GTAGS_ARGS) "$$here" -cscopelist: cscopelist-am - -cscopelist-am: $(am__tagged_files) - list='$(am__tagged_files)'; \ - case "$(srcdir)" in \ - [\\/]* | ?:[\\/]*) sdir="$(srcdir)" ;; \ - *) sdir=$(subdir)/$(srcdir) ;; \ - esac; \ - for i in $$list; do \ - if test -f "$$i"; then \ - echo "$(subdir)/$$i"; \ - else \ - echo "$$sdir/$$i"; \ - fi; \ - done >> $(top_builddir)/cscope.files - -distclean-tags: - -rm -f TAGS ID GTAGS GRTAGS GSYMS GPATH tags - -distdir: $(DISTFILES) - @srcdirstrip=`echo "$(srcdir)" | sed 's/[].[^$$\\*]/\\\\&/g'`; \ - topsrcdirstrip=`echo "$(top_srcdir)" | sed 's/[].[^$$\\*]/\\\\&/g'`; \ - list='$(DISTFILES)'; \ - dist_files=`for file in $$list; do echo $$file; done | \ - sed -e "s|^$$srcdirstrip/||;t" \ - -e "s|^$$topsrcdirstrip/|$(top_builddir)/|;t"`; \ - case $$dist_files in \ - */*) $(MKDIR_P) `echo "$$dist_files" | \ - sed '/\//!d;s|^|$(distdir)/|;s,/[^/]*$$,,' | \ - sort -u` ;; \ - esac; \ - for file in $$dist_files; do \ - if test -f $$file || test -d $$file; then d=.; else d=$(srcdir); fi; \ - if test -d $$d/$$file; then \ - dir=`echo "/$$file" | sed -e 's,/[^/]*$$,,'`; \ - if test -d "$(distdir)/$$file"; then \ - find "$(distdir)/$$file" -type d ! -perm -700 -exec chmod u+rwx {} \;; \ - fi; \ - if test -d $(srcdir)/$$file && test $$d != $(srcdir); then \ - cp -fpR $(srcdir)/$$file "$(distdir)$$dir" || exit 1; \ - find "$(distdir)/$$file" -type d ! -perm -700 -exec chmod u+rwx {} \;; \ - fi; \ - cp -fpR $$d/$$file "$(distdir)$$dir" || exit 1; \ - else \ - test -f "$(distdir)/$$file" \ - || cp -p $$d/$$file "$(distdir)/$$file" \ - || exit 1; \ - fi; \ - done -check-am: all-am -check: check-am -all-am: Makefile $(PROGRAMS) -installdirs: - for dir in "$(DESTDIR)$(bindir)"; do \ - test -z "$$dir" || $(MKDIR_P) "$$dir"; \ - done -install: install-am -install-exec: install-exec-am -install-data: install-data-am -uninstall: uninstall-am - -install-am: all-am - @$(MAKE) $(AM_MAKEFLAGS) install-exec-am install-data-am - -installcheck: installcheck-am -install-strip: - if test -z '$(STRIP)'; then \ - $(MAKE) $(AM_MAKEFLAGS) INSTALL_PROGRAM="$(INSTALL_STRIP_PROGRAM)" \ - install_sh_PROGRAM="$(INSTALL_STRIP_PROGRAM)" INSTALL_STRIP_FLAG=-s \ - install; \ - else \ - $(MAKE) $(AM_MAKEFLAGS) INSTALL_PROGRAM="$(INSTALL_STRIP_PROGRAM)" \ - install_sh_PROGRAM="$(INSTALL_STRIP_PROGRAM)" INSTALL_STRIP_FLAG=-s \ - "INSTALL_PROGRAM_ENV=STRIPPROG='$(STRIP)'" install; \ - fi -mostlyclean-generic: - -clean-generic: - -test -z "$(CLEANFILES)" || rm -f $(CLEANFILES) - -distclean-generic: - -test -z "$(CONFIG_CLEAN_FILES)" || rm -f $(CONFIG_CLEAN_FILES) - -test . = "$(srcdir)" || test -z "$(CONFIG_CLEAN_VPATH_FILES)" || rm -f $(CONFIG_CLEAN_VPATH_FILES) - -maintainer-clean-generic: - @echo "This command is intended for maintainers to use" - @echo "it deletes files that may require special tools to rebuild." - -rm -f $(srcdir)/autosave-manager.c - -rm -f $(srcdir)/book-view.c - -rm -f $(srcdir)/book.c - -rm -f $(srcdir)/page-view.c - -rm -f $(srcdir)/page.c - -rm -f $(srcdir)/scanner.c - -rm -f $(srcdir)/simple-scan.c - -rm -f $(srcdir)/simple_scan_vala.stamp - -rm -f $(srcdir)/ui.c - -rm -f autosave-manager.c - -rm -f book-view.c - -rm -f book.c - -rm -f page-view.c - -rm -f page.c - -rm -f scanner.c - -rm -f simple-scan.c - -rm -f ui.c -clean: clean-am - -clean-am: clean-binPROGRAMS clean-generic mostlyclean-am - -distclean: distclean-am - -rm -rf ./$(DEPDIR) - -rm -f Makefile -distclean-am: clean-am distclean-compile distclean-generic \ - distclean-tags - -dvi: dvi-am - -dvi-am: - -html: html-am - -html-am: - -info: info-am - -info-am: - -install-data-am: - -install-dvi: install-dvi-am - -install-dvi-am: - -install-exec-am: install-binPROGRAMS - -install-html: install-html-am - -install-html-am: - -install-info: install-info-am - -install-info-am: - -install-man: - -install-pdf: install-pdf-am - -install-pdf-am: - -install-ps: install-ps-am - -install-ps-am: - -installcheck-am: - -maintainer-clean: maintainer-clean-am - -rm -rf ./$(DEPDIR) - -rm -f Makefile -maintainer-clean-am: distclean-am maintainer-clean-generic - -mostlyclean: mostlyclean-am - -mostlyclean-am: mostlyclean-compile mostlyclean-generic - -pdf: pdf-am - -pdf-am: - -ps: ps-am - -ps-am: - -uninstall-am: uninstall-binPROGRAMS - -.MAKE: install-am install-strip - -.PHONY: CTAGS GTAGS TAGS all all-am check check-am clean \ - clean-binPROGRAMS clean-generic cscopelist-am ctags ctags-am \ - distclean distclean-compile distclean-generic distclean-tags \ - distdir dvi dvi-am html html-am info info-am install \ - install-am install-binPROGRAMS install-data install-data-am \ - install-dvi install-dvi-am install-exec install-exec-am \ - install-html install-html-am install-info install-info-am \ - install-man install-pdf install-pdf-am install-ps \ - install-ps-am install-strip installcheck installcheck-am \ - installdirs maintainer-clean maintainer-clean-generic \ - mostlyclean mostlyclean-compile mostlyclean-generic pdf pdf-am \ - ps ps-am tags tags-am uninstall uninstall-am \ - uninstall-binPROGRAMS - -.PRECIOUS: Makefile - - -resources.c: $(top_srcdir)/data/simple-scan.gresource.xml $(shell $(GLIB_COMPILE_RESOURCES) --generate-dependencies --sourcedir=$(top_srcdir)/data/ $(top_srcdir)/data/simple-scan.gresource.xml) - $(AM_V_GEN) $(GLIB_COMPILE_RESOURCES) --target=$@ --sourcedir=$(top_srcdir)/data/ --generate-source $< - -# Tell versions [3.59,3.63) of GNU make to not export all variables. -# Otherwise a system limit (for SysV at least) may be exceeded. -.NOEXPORT: diff --git a/src/autosave-manager.c b/src/autosave-manager.c deleted file mode 100644 index 5ea1792..0000000 --- a/src/autosave-manager.c +++ /dev/null @@ -1,2725 +0,0 @@ -/* autosave-manager.c generated by valac 0.34.6, the Vala compiler - * generated from autosave-manager.vala, do not modify */ - -/* - * Copyright (C) 2011 Timo Kluck - * Authors: Timo Kluck - * Robert Ancell - * - * This program is free software: you can redistribute it and/or modify it under - * the terms of the GNU General Public License as published by the Free Software - * Foundation, either version 3 of the License, or (at your option) any later - * version. See http://www.gnu.org/copyleft/gpl.html the full text of the - * license. - */ - -#include -#include -#include -#include -#include -#include -#include - - -#define TYPE_AUTOSAVE_MANAGER (autosave_manager_get_type ()) -#define AUTOSAVE_MANAGER(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), TYPE_AUTOSAVE_MANAGER, AutosaveManager)) -#define AUTOSAVE_MANAGER_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST ((klass), TYPE_AUTOSAVE_MANAGER, AutosaveManagerClass)) -#define IS_AUTOSAVE_MANAGER(obj) (G_TYPE_CHECK_INSTANCE_TYPE ((obj), TYPE_AUTOSAVE_MANAGER)) -#define IS_AUTOSAVE_MANAGER_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE ((klass), TYPE_AUTOSAVE_MANAGER)) -#define AUTOSAVE_MANAGER_GET_CLASS(obj) (G_TYPE_INSTANCE_GET_CLASS ((obj), TYPE_AUTOSAVE_MANAGER, AutosaveManagerClass)) - -typedef struct _AutosaveManager AutosaveManager; -typedef struct _AutosaveManagerClass AutosaveManagerClass; -typedef struct _AutosaveManagerPrivate AutosaveManagerPrivate; - -#define TYPE_PAGE (page_get_type ()) -#define PAGE(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), TYPE_PAGE, Page)) -#define PAGE_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST ((klass), TYPE_PAGE, PageClass)) -#define IS_PAGE(obj) (G_TYPE_CHECK_INSTANCE_TYPE ((obj), TYPE_PAGE)) -#define IS_PAGE_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE ((klass), TYPE_PAGE)) -#define PAGE_GET_CLASS(obj) (G_TYPE_INSTANCE_GET_CLASS ((obj), TYPE_PAGE, PageClass)) - -typedef struct _Page Page; -typedef struct _PageClass PageClass; - -#define TYPE_BOOK (book_get_type ()) -#define BOOK(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), TYPE_BOOK, Book)) -#define BOOK_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST ((klass), TYPE_BOOK, BookClass)) -#define IS_BOOK(obj) (G_TYPE_CHECK_INSTANCE_TYPE ((obj), TYPE_BOOK)) -#define IS_BOOK_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE ((klass), TYPE_BOOK)) -#define BOOK_GET_CLASS(obj) (G_TYPE_INSTANCE_GET_CLASS ((obj), TYPE_BOOK, BookClass)) - -typedef struct _Book Book; -typedef struct _BookClass BookClass; -#define _g_hash_table_unref0(var) ((var == NULL) ? NULL : (var = (g_hash_table_unref (var), NULL))) -#define _book_unref0(var) ((var == NULL) ? NULL : (var = (book_unref (var), NULL))) -#define _g_error_free0(var) ((var == NULL) ? NULL : (var = (g_error_free (var), NULL))) -#define _g_key_file_unref0(var) ((var == NULL) ? NULL : (var = (g_key_file_unref (var), NULL))) - -#define TYPE_SCAN_DIRECTION (scan_direction_get_type ()) -#define _g_free0(var) (var = (g_free (var), NULL)) -#define _g_object_unref0(var) ((var == NULL) ? NULL : (var = (g_object_unref (var), NULL))) -#define _page_unref0(var) ((var == NULL) ? NULL : (var = (page_unref (var), NULL))) -#define _g_dir_close0(var) ((var == NULL) ? NULL : (var = (g_dir_close (var), NULL))) -typedef struct _ParamSpecAutosaveManager ParamSpecAutosaveManager; - -struct _AutosaveManager { - GTypeInstance parent_instance; - volatile int ref_count; - AutosaveManagerPrivate * priv; -}; - -struct _AutosaveManagerClass { - GTypeClass parent_class; - void (*finalize) (AutosaveManager *self); -}; - -struct _AutosaveManagerPrivate { - guint update_timeout; - GHashTable* page_filenames; - Book* book_; -}; - -typedef enum { - SCAN_DIRECTION_TOP_TO_BOTTOM, - SCAN_DIRECTION_LEFT_TO_RIGHT, - SCAN_DIRECTION_BOTTOM_TO_TOP, - SCAN_DIRECTION_RIGHT_TO_LEFT -} ScanDirection; - -struct _ParamSpecAutosaveManager { - GParamSpec parent_instance; -}; - - -static gpointer autosave_manager_parent_class = NULL; -static gchar* autosave_manager_AUTOSAVE_DIR; -static gchar* autosave_manager_AUTOSAVE_DIR = NULL; -static gchar* autosave_manager_AUTOSAVE_FILENAME; -static gchar* autosave_manager_AUTOSAVE_FILENAME = NULL; -static gchar* autosave_manager_AUTOSAVE_PATH; -static gchar* autosave_manager_AUTOSAVE_PATH = NULL; - -gpointer autosave_manager_ref (gpointer instance); -void autosave_manager_unref (gpointer instance); -GParamSpec* param_spec_autosave_manager (const gchar* name, const gchar* nick, const gchar* blurb, GType object_type, GParamFlags flags); -void value_set_autosave_manager (GValue* value, gpointer v_object); -void value_take_autosave_manager (GValue* value, gpointer v_object); -gpointer value_get_autosave_manager (const GValue* value); -GType autosave_manager_get_type (void) G_GNUC_CONST; -gpointer page_ref (gpointer instance); -void page_unref (gpointer instance); -GParamSpec* param_spec_page (const gchar* name, const gchar* nick, const gchar* blurb, GType object_type, GParamFlags flags); -void value_set_page (GValue* value, gpointer v_object); -void value_take_page (GValue* value, gpointer v_object); -gpointer value_get_page (const GValue* value); -GType page_get_type (void) G_GNUC_CONST; -gpointer book_ref (gpointer instance); -void book_unref (gpointer instance); -GParamSpec* param_spec_book (const gchar* name, const gchar* nick, const gchar* blurb, GType object_type, GParamFlags flags); -void value_set_book (GValue* value, gpointer v_object); -void value_take_book (GValue* value, gpointer v_object); -gpointer value_get_book (const GValue* value); -GType book_get_type (void) G_GNUC_CONST; -#define AUTOSAVE_MANAGER_GET_PRIVATE(o) (G_TYPE_INSTANCE_GET_PRIVATE ((o), TYPE_AUTOSAVE_MANAGER, AutosaveManagerPrivate)) -enum { - AUTOSAVE_MANAGER_DUMMY_PROPERTY -}; -AutosaveManager* autosave_manager_new (void); -AutosaveManager* autosave_manager_construct (GType object_type); -static void _page_unref0_ (gpointer var); -static void _g_free0_ (gpointer var); -void autosave_manager_load (AutosaveManager* self); -Book* autosave_manager_get_book (AutosaveManager* self); -void book_clear (Book* self); -static gchar* autosave_manager_get_value (AutosaveManager* self, GKeyFile* file, const gchar* group_name, const gchar* key, const gchar* _default_); -static gint autosave_manager_get_integer (AutosaveManager* self, GKeyFile* file, const gchar* group_name, const gchar* key, gint _default_); -GType scan_direction_get_type (void) G_GNUC_CONST; -static gboolean autosave_manager_get_boolean (AutosaveManager* self, GKeyFile* file, const gchar* group_name, const gchar* key, gboolean _default_); -Page* page_new_from_data (gint scan_width, gint scan_height, gint rowstride, gint n_channels, gint depth, gint dpi, ScanDirection scan_direction, const gchar* color_profile, guchar* pixels, int pixels_length1, gboolean has_crop, const gchar* crop_name, gint crop_x, gint crop_y, gint crop_width, gint crop_height); -Page* page_construct_from_data (GType object_type, gint scan_width, gint scan_height, gint rowstride, gint n_channels, gint depth, gint dpi, ScanDirection scan_direction, const gchar* color_profile, guchar* pixels, int pixels_length1, gboolean has_crop, const gchar* crop_name, gint crop_x, gint crop_y, gint crop_width, gint crop_height); -void book_append_page (Book* self, Page* page); -void autosave_manager_cleanup (AutosaveManager* self); -void autosave_manager_on_page_added (AutosaveManager* self, Page* page); -void autosave_manager_on_scan_finished (AutosaveManager* self, Page* page); -static void _autosave_manager_on_scan_finished_page_scan_finished (Page* _sender, gpointer self); -void autosave_manager_on_changed (AutosaveManager* self); -static void _autosave_manager_on_changed_page_crop_changed (Page* _sender, gpointer self); -void autosave_manager_on_page_removed (AutosaveManager* self, Page* page); -static void autosave_manager_save_pixels (AutosaveManager* self, Page* page); -static void autosave_manager_save (AutosaveManager* self, gboolean do_timeout); -void autosave_manager_on_cleared (AutosaveManager* self); -static gboolean ___lambda4_ (AutosaveManager* self); -static void autosave_manager_real_save (AutosaveManager* self); -static gboolean ____lambda4__gsource_func (gpointer self); -guint book_get_n_pages (Book* self); -Page* book_get_page (Book* self, gint page_number); -gboolean page_get_has_data (Page* self); -gint page_get_scan_width (Page* self); -gint page_get_scan_height (Page* self); -gint page_get_rowstride (Page* self); -gint page_get_n_channels (Page* self); -gint page_get_depth (Page* self); -gint page_get_dpi (Page* self); -ScanDirection page_get_scan_direction (Page* self); -const gchar* page_get_color_profile (Page* self); -gboolean page_get_has_crop (Page* self); -const gchar* page_get_crop_name (Page* self); -gint page_get_crop_x (Page* self); -gint page_get_crop_y (Page* self); -gint page_get_crop_width (Page* self); -gint page_get_crop_height (Page* self); -guchar* page_get_pixels (Page* self, int* result_length1); -void autosave_manager_set_book (AutosaveManager* self, Book* value); -static void _autosave_manager_on_page_added_book_page_added (Book* _sender, Page* page, gpointer self); -static void _autosave_manager_on_page_removed_book_page_removed (Book* _sender, Page* page, gpointer self); -static void _autosave_manager_on_changed_book_reordered (Book* _sender, gpointer self); -static void _autosave_manager_on_cleared_book_cleared (Book* _sender, gpointer self); -static void autosave_manager_finalize (AutosaveManager* obj); -static void _vala_array_destroy (gpointer array, gint array_length, GDestroyNotify destroy_func); -static void _vala_array_free (gpointer array, gint array_length, GDestroyNotify destroy_func); -static gint _vala_array_length (gpointer array); - - -static void _page_unref0_ (gpointer var) { -#line 59 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - (var == NULL) ? NULL : (var = (page_unref (var), NULL)); -#line 189 "autosave-manager.c" -} - - -static void _g_free0_ (gpointer var) { -#line 59 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - var = (g_free (var), NULL); -#line 196 "autosave-manager.c" -} - - -AutosaveManager* autosave_manager_construct (GType object_type) { - AutosaveManager* self = NULL; - GHashFunc _tmp0_ = NULL; - GEqualFunc _tmp1_ = NULL; - GHashTable* _tmp2_ = NULL; -#line 57 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - self = (AutosaveManager*) g_type_create_instance (object_type); -#line 59 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - _tmp0_ = g_direct_hash; -#line 59 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - _tmp1_ = g_direct_equal; -#line 59 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - _tmp2_ = g_hash_table_new_full (_tmp0_, _tmp1_, _page_unref0_, _g_free0_); -#line 59 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - _g_hash_table_unref0 (self->priv->page_filenames); -#line 59 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - self->priv->page_filenames = _tmp2_; -#line 57 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - return self; -#line 219 "autosave-manager.c" -} - - -AutosaveManager* autosave_manager_new (void) { -#line 57 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - return autosave_manager_construct (TYPE_AUTOSAVE_MANAGER); -#line 226 "autosave-manager.c" -} - - -static gpointer _page_ref0 (gpointer self) { -#line 152 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - return self ? page_ref (self) : NULL; -#line 233 "autosave-manager.c" -} - - -void autosave_manager_load (AutosaveManager* self) { - Book* _tmp0_ = NULL; - Book* _tmp1_ = NULL; - GHashTable* _tmp2_ = NULL; - GKeyFile* file = NULL; - GKeyFile* _tmp3_ = NULL; - gchar* pages = NULL; - GKeyFile* _tmp9_ = NULL; - gchar* _tmp10_ = NULL; - const gchar* _tmp11_ = NULL; - gchar** _tmp12_ = NULL; - gchar** _tmp13_ = NULL; - GError * _inner_error_ = NULL; -#line 62 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - g_return_if_fail (self != NULL); -#line 64 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - g_debug ("autosave-manager.vala:64: Loading autosave information"); -#line 66 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - _tmp0_ = autosave_manager_get_book (self); -#line 66 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - _tmp1_ = _tmp0_; -#line 66 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - book_clear (_tmp1_); -#line 67 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - _tmp2_ = self->priv->page_filenames; -#line 67 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - g_hash_table_remove_all (_tmp2_); -#line 69 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - _tmp3_ = g_key_file_new (); -#line 69 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - file = _tmp3_; -#line 268 "autosave-manager.c" - { - GKeyFile* _tmp4_ = NULL; - const gchar* _tmp5_ = NULL; -#line 72 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - _tmp4_ = file; -#line 72 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - _tmp5_ = autosave_manager_AUTOSAVE_PATH; -#line 72 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - g_key_file_load_from_file (_tmp4_, _tmp5_, G_KEY_FILE_NONE, &_inner_error_); -#line 72 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - if (G_UNLIKELY (_inner_error_ != NULL)) { -#line 280 "autosave-manager.c" - goto __catch29_g_error; - } - } - goto __finally29; - __catch29_g_error: - { - GError* e = NULL; - GError* _tmp6_ = NULL; -#line 70 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - e = _inner_error_; -#line 70 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - _inner_error_ = NULL; -#line 76 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - _tmp6_ = e; -#line 76 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - if (!g_error_matches (_tmp6_, G_FILE_ERROR, G_FILE_ERROR_NOENT)) { -#line 297 "autosave-manager.c" - GError* _tmp7_ = NULL; - const gchar* _tmp8_ = NULL; -#line 77 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - _tmp7_ = e; -#line 77 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - _tmp8_ = _tmp7_->message; -#line 77 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - g_warning ("autosave-manager.vala:77: Could not load autosave information; not res" \ -"toring any autosaves: %s", _tmp8_); -#line 306 "autosave-manager.c" - } -#line 78 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - _g_error_free0 (e); -#line 78 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - _g_key_file_unref0 (file); -#line 78 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - return; -#line 314 "autosave-manager.c" - } - __finally29: -#line 70 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - if (G_UNLIKELY (_inner_error_ != NULL)) { -#line 70 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - _g_key_file_unref0 (file); -#line 70 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - g_critical ("file %s: line %d: uncaught error: %s (%s, %d)", __FILE__, __LINE__, _inner_error_->message, g_quark_to_string (_inner_error_->domain), _inner_error_->code); -#line 70 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - g_clear_error (&_inner_error_); -#line 70 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - return; -#line 327 "autosave-manager.c" - } -#line 80 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - _tmp9_ = file; -#line 80 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - _tmp10_ = autosave_manager_get_value (self, _tmp9_, "simple-scan", "pages", ""); -#line 80 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - pages = _tmp10_; -#line 81 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - _tmp11_ = pages; -#line 81 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - _tmp13_ = _tmp12_ = g_strsplit (_tmp11_, " ", 0); -#line 339 "autosave-manager.c" - { - gchar** page_name_collection = NULL; - gint page_name_collection_length1 = 0; - gint _page_name_collection_size_ = 0; - gint page_name_it = 0; -#line 81 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - page_name_collection = _tmp13_; -#line 81 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - page_name_collection_length1 = _vala_array_length (_tmp12_); -#line 81 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - for (page_name_it = 0; page_name_it < _vala_array_length (_tmp12_); page_name_it = page_name_it + 1) { -#line 351 "autosave-manager.c" - gchar* _tmp14_ = NULL; - gchar* page_name = NULL; -#line 81 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - _tmp14_ = g_strdup (page_name_collection[page_name_it]); -#line 81 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - page_name = _tmp14_; -#line 358 "autosave-manager.c" - { - const gchar* _tmp15_ = NULL; - gint scan_width = 0; - GKeyFile* _tmp16_ = NULL; - const gchar* _tmp17_ = NULL; - gint _tmp18_ = 0; - gint scan_height = 0; - GKeyFile* _tmp19_ = NULL; - const gchar* _tmp20_ = NULL; - gint _tmp21_ = 0; - gint rowstride = 0; - GKeyFile* _tmp22_ = NULL; - const gchar* _tmp23_ = NULL; - gint _tmp24_ = 0; - gint n_channels = 0; - GKeyFile* _tmp25_ = NULL; - const gchar* _tmp26_ = NULL; - gint _tmp27_ = 0; - gint depth = 0; - GKeyFile* _tmp28_ = NULL; - const gchar* _tmp29_ = NULL; - gint _tmp30_ = 0; - gint dpi = 0; - GKeyFile* _tmp31_ = NULL; - const gchar* _tmp32_ = NULL; - gint _tmp33_ = 0; - gchar* scan_direction_name = NULL; - GKeyFile* _tmp34_ = NULL; - const gchar* _tmp35_ = NULL; - gchar* _tmp36_ = NULL; - ScanDirection scan_direction = 0; - const gchar* _tmp37_ = NULL; - const gchar* _tmp38_ = NULL; - GQuark _tmp40_ = 0U; -#line 93 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - static GQuark _tmp39_label0 = 0; -#line 93 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - static GQuark _tmp39_label1 = 0; -#line 93 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - static GQuark _tmp39_label2 = 0; -#line 93 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - static GQuark _tmp39_label3 = 0; -#line 401 "autosave-manager.c" - gchar* color_profile = NULL; - GKeyFile* _tmp41_ = NULL; - const gchar* _tmp42_ = NULL; - gchar* _tmp43_ = NULL; - const gchar* _tmp44_ = NULL; - gchar* pixels_filename = NULL; - GKeyFile* _tmp45_ = NULL; - const gchar* _tmp46_ = NULL; - gchar* _tmp47_ = NULL; - gboolean has_crop = FALSE; - GKeyFile* _tmp48_ = NULL; - const gchar* _tmp49_ = NULL; - gboolean _tmp50_ = FALSE; - gchar* crop_name = NULL; - GKeyFile* _tmp51_ = NULL; - const gchar* _tmp52_ = NULL; - gchar* _tmp53_ = NULL; - const gchar* _tmp54_ = NULL; - gint crop_x = 0; - GKeyFile* _tmp55_ = NULL; - const gchar* _tmp56_ = NULL; - gint _tmp57_ = 0; - gint crop_y = 0; - GKeyFile* _tmp58_ = NULL; - const gchar* _tmp59_ = NULL; - gint _tmp60_ = 0; - gint crop_width = 0; - GKeyFile* _tmp61_ = NULL; - const gchar* _tmp62_ = NULL; - gint _tmp63_ = 0; - gint crop_height = 0; - GKeyFile* _tmp64_ = NULL; - const gchar* _tmp65_ = NULL; - gint _tmp66_ = 0; - guchar* pixels = NULL; - gint pixels_length1 = 0; - gint _pixels_size_ = 0; - const gchar* _tmp67_ = NULL; - Page* page = NULL; - gint _tmp76_ = 0; - gint _tmp77_ = 0; - gint _tmp78_ = 0; - gint _tmp79_ = 0; - gint _tmp80_ = 0; - gint _tmp81_ = 0; - ScanDirection _tmp82_ = 0; - const gchar* _tmp83_ = NULL; - guchar* _tmp84_ = NULL; - gint _tmp84__length1 = 0; - gboolean _tmp85_ = FALSE; - const gchar* _tmp86_ = NULL; - gint _tmp87_ = 0; - gint _tmp88_ = 0; - gint _tmp89_ = 0; - gint _tmp90_ = 0; - Page* _tmp91_ = NULL; - GHashTable* _tmp92_ = NULL; - Page* _tmp93_ = NULL; - Page* _tmp94_ = NULL; - const gchar* _tmp95_ = NULL; - gchar* _tmp96_ = NULL; - Book* _tmp97_ = NULL; - Book* _tmp98_ = NULL; - Page* _tmp99_ = NULL; -#line 83 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - _tmp15_ = page_name; -#line 83 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - g_debug ("autosave-manager.vala:83: Loading automatically saved page %s", _tmp15_); -#line 85 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - _tmp16_ = file; -#line 85 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - _tmp17_ = page_name; -#line 85 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - _tmp18_ = autosave_manager_get_integer (self, _tmp16_, _tmp17_, "scan-width", 0); -#line 85 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - scan_width = _tmp18_; -#line 86 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - _tmp19_ = file; -#line 86 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - _tmp20_ = page_name; -#line 86 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - _tmp21_ = autosave_manager_get_integer (self, _tmp19_, _tmp20_, "scan-height", 0); -#line 86 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - scan_height = _tmp21_; -#line 87 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - _tmp22_ = file; -#line 87 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - _tmp23_ = page_name; -#line 87 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - _tmp24_ = autosave_manager_get_integer (self, _tmp22_, _tmp23_, "rowstride", 0); -#line 87 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - rowstride = _tmp24_; -#line 88 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - _tmp25_ = file; -#line 88 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - _tmp26_ = page_name; -#line 88 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - _tmp27_ = autosave_manager_get_integer (self, _tmp25_, _tmp26_, "n-channels", 0); -#line 88 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - n_channels = _tmp27_; -#line 89 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - _tmp28_ = file; -#line 89 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - _tmp29_ = page_name; -#line 89 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - _tmp30_ = autosave_manager_get_integer (self, _tmp28_, _tmp29_, "depth", 0); -#line 89 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - depth = _tmp30_; -#line 90 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - _tmp31_ = file; -#line 90 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - _tmp32_ = page_name; -#line 90 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - _tmp33_ = autosave_manager_get_integer (self, _tmp31_, _tmp32_, "dpi", 0); -#line 90 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - dpi = _tmp33_; -#line 91 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - _tmp34_ = file; -#line 91 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - _tmp35_ = page_name; -#line 91 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - _tmp36_ = autosave_manager_get_value (self, _tmp34_, _tmp35_, "scan-direction", ""); -#line 91 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - scan_direction_name = _tmp36_; -#line 92 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - scan_direction = SCAN_DIRECTION_TOP_TO_BOTTOM; -#line 93 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - _tmp37_ = scan_direction_name; -#line 93 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - _tmp38_ = _tmp37_; -#line 93 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - _tmp40_ = (NULL == _tmp38_) ? 0 : g_quark_from_string (_tmp38_); -#line 93 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - if (_tmp40_ == ((0 != _tmp39_label0) ? _tmp39_label0 : (_tmp39_label0 = g_quark_from_static_string ("TOP_TO_BOTTOM")))) { -#line 93 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - switch (0) { -#line 538 "autosave-manager.c" - default: - { -#line 96 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - scan_direction = SCAN_DIRECTION_TOP_TO_BOTTOM; -#line 97 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - break; -#line 545 "autosave-manager.c" - } - } - } else if (_tmp40_ == ((0 != _tmp39_label1) ? _tmp39_label1 : (_tmp39_label1 = g_quark_from_static_string ("LEFT_TO_RIGHT")))) { -#line 93 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - switch (0) { -#line 551 "autosave-manager.c" - default: - { -#line 99 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - scan_direction = SCAN_DIRECTION_LEFT_TO_RIGHT; -#line 100 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - break; -#line 558 "autosave-manager.c" - } - } - } else if (_tmp40_ == ((0 != _tmp39_label2) ? _tmp39_label2 : (_tmp39_label2 = g_quark_from_static_string ("BOTTOM_TO_TOP")))) { -#line 93 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - switch (0) { -#line 564 "autosave-manager.c" - default: - { -#line 102 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - scan_direction = SCAN_DIRECTION_BOTTOM_TO_TOP; -#line 103 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - break; -#line 571 "autosave-manager.c" - } - } - } else if (_tmp40_ == ((0 != _tmp39_label3) ? _tmp39_label3 : (_tmp39_label3 = g_quark_from_static_string ("RIGHT_TO_LEFT")))) { -#line 93 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - switch (0) { -#line 577 "autosave-manager.c" - default: - { -#line 105 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - scan_direction = SCAN_DIRECTION_RIGHT_TO_LEFT; -#line 106 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - break; -#line 584 "autosave-manager.c" - } - } - } -#line 108 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - _tmp41_ = file; -#line 108 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - _tmp42_ = page_name; -#line 108 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - _tmp43_ = autosave_manager_get_value (self, _tmp41_, _tmp42_, "color-profile", ""); -#line 108 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - color_profile = _tmp43_; -#line 109 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - _tmp44_ = color_profile; -#line 109 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - if (g_strcmp0 (_tmp44_, "") == 0) { -#line 110 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - _g_free0 (color_profile); -#line 110 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - color_profile = NULL; -#line 604 "autosave-manager.c" - } -#line 111 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - _tmp45_ = file; -#line 111 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - _tmp46_ = page_name; -#line 111 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - _tmp47_ = autosave_manager_get_value (self, _tmp45_, _tmp46_, "pixels-filename", ""); -#line 111 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - pixels_filename = _tmp47_; -#line 112 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - _tmp48_ = file; -#line 112 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - _tmp49_ = page_name; -#line 112 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - _tmp50_ = autosave_manager_get_boolean (self, _tmp48_, _tmp49_, "has-crop", FALSE); -#line 112 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - has_crop = _tmp50_; -#line 113 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - _tmp51_ = file; -#line 113 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - _tmp52_ = page_name; -#line 113 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - _tmp53_ = autosave_manager_get_value (self, _tmp51_, _tmp52_, "crop-name", ""); -#line 113 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - crop_name = _tmp53_; -#line 114 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - _tmp54_ = crop_name; -#line 114 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - if (g_strcmp0 (_tmp54_, "") == 0) { -#line 115 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - _g_free0 (crop_name); -#line 115 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - crop_name = NULL; -#line 638 "autosave-manager.c" - } -#line 116 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - _tmp55_ = file; -#line 116 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - _tmp56_ = page_name; -#line 116 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - _tmp57_ = autosave_manager_get_integer (self, _tmp55_, _tmp56_, "crop-x", 0); -#line 116 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - crop_x = _tmp57_; -#line 117 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - _tmp58_ = file; -#line 117 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - _tmp59_ = page_name; -#line 117 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - _tmp60_ = autosave_manager_get_integer (self, _tmp58_, _tmp59_, "crop-y", 0); -#line 117 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - crop_y = _tmp60_; -#line 118 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - _tmp61_ = file; -#line 118 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - _tmp62_ = page_name; -#line 118 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - _tmp63_ = autosave_manager_get_integer (self, _tmp61_, _tmp62_, "crop-width", 0); -#line 118 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - crop_width = _tmp63_; -#line 119 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - _tmp64_ = file; -#line 119 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - _tmp65_ = page_name; -#line 119 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - _tmp66_ = autosave_manager_get_integer (self, _tmp64_, _tmp65_, "crop-height", 0); -#line 119 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - crop_height = _tmp66_; -#line 121 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - pixels = NULL; -#line 121 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - pixels_length1 = 0; -#line 121 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - _pixels_size_ = pixels_length1; -#line 122 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - _tmp67_ = pixels_filename; -#line 122 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - if (g_strcmp0 (_tmp67_, "") != 0) { -#line 682 "autosave-manager.c" - gchar* path = NULL; - const gchar* _tmp68_ = NULL; - const gchar* _tmp69_ = NULL; - gchar* _tmp70_ = NULL; - GFile* f = NULL; - const gchar* _tmp71_ = NULL; - GFile* _tmp72_ = NULL; -#line 124 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - _tmp68_ = autosave_manager_AUTOSAVE_DIR; -#line 124 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - _tmp69_ = pixels_filename; -#line 124 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - _tmp70_ = g_build_filename (_tmp68_, _tmp69_, NULL); -#line 124 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - path = _tmp70_; -#line 125 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - _tmp71_ = path; -#line 125 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - _tmp72_ = g_file_new_for_path (_tmp71_); -#line 125 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - f = _tmp72_; -#line 704 "autosave-manager.c" - { - GFile* _tmp73_ = NULL; - guint8* _tmp74_ = NULL; - gsize _tmp75_; -#line 128 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - _tmp73_ = f; -#line 128 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - g_file_load_contents (_tmp73_, NULL, &_tmp74_, &_tmp75_, NULL, &_inner_error_); -#line 128 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - pixels = (g_free (pixels), NULL); -#line 128 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - pixels = _tmp74_; -#line 128 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - pixels_length1 = _tmp75_; -#line 128 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - _pixels_size_ = pixels_length1; -#line 128 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - if (G_UNLIKELY (_inner_error_ != NULL)) { -#line 723 "autosave-manager.c" - goto __catch30_g_error; - } - } - goto __finally30; - __catch30_g_error: - { - GError* e = NULL; -#line 126 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - e = _inner_error_; -#line 126 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - _inner_error_ = NULL; -#line 132 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - g_warning ("autosave-manager.vala:132: Failed to load pixel information"); -#line 133 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - _g_error_free0 (e); -#line 133 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - _g_object_unref0 (f); -#line 133 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - _g_free0 (path); -#line 133 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - pixels = (g_free (pixels), NULL); -#line 133 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - _g_free0 (crop_name); -#line 133 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - _g_free0 (pixels_filename); -#line 133 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - _g_free0 (color_profile); -#line 133 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - _g_free0 (scan_direction_name); -#line 133 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - _g_free0 (page_name); -#line 133 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - continue; -#line 757 "autosave-manager.c" - } - __finally30: -#line 126 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - if (G_UNLIKELY (_inner_error_ != NULL)) { -#line 126 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - _g_object_unref0 (f); -#line 126 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - _g_free0 (path); -#line 126 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - pixels = (g_free (pixels), NULL); -#line 126 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - _g_free0 (crop_name); -#line 126 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - _g_free0 (pixels_filename); -#line 126 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - _g_free0 (color_profile); -#line 126 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - _g_free0 (scan_direction_name); -#line 126 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - _g_free0 (page_name); -#line 126 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - page_name_collection = (_vala_array_free (page_name_collection, page_name_collection_length1, (GDestroyNotify) g_free), NULL); -#line 126 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - _g_free0 (pages); -#line 126 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - _g_key_file_unref0 (file); -#line 126 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - g_critical ("file %s: line %d: uncaught error: %s (%s, %d)", __FILE__, __LINE__, _inner_error_->message, g_quark_to_string (_inner_error_->domain), _inner_error_->code); -#line 126 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - g_clear_error (&_inner_error_); -#line 126 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - return; -#line 790 "autosave-manager.c" - } -#line 122 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - _g_object_unref0 (f); -#line 122 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - _g_free0 (path); -#line 796 "autosave-manager.c" - } -#line 137 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - _tmp76_ = scan_width; -#line 137 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - _tmp77_ = scan_height; -#line 137 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - _tmp78_ = rowstride; -#line 137 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - _tmp79_ = n_channels; -#line 137 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - _tmp80_ = depth; -#line 137 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - _tmp81_ = dpi; -#line 137 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - _tmp82_ = scan_direction; -#line 137 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - _tmp83_ = color_profile; -#line 137 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - _tmp84_ = pixels; -#line 137 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - _tmp84__length1 = pixels_length1; -#line 137 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - _tmp85_ = has_crop; -#line 137 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - _tmp86_ = crop_name; -#line 137 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - _tmp87_ = crop_x; -#line 137 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - _tmp88_ = crop_y; -#line 137 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - _tmp89_ = crop_width; -#line 137 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - _tmp90_ = crop_height; -#line 137 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - _tmp91_ = page_new_from_data (_tmp76_, _tmp77_, _tmp78_, _tmp79_, _tmp80_, _tmp81_, _tmp82_, _tmp83_, _tmp84_, _tmp84__length1, _tmp85_, _tmp86_, _tmp87_, _tmp88_, _tmp89_, _tmp90_); -#line 137 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - page = _tmp91_; -#line 152 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - _tmp92_ = self->priv->page_filenames; -#line 152 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - _tmp93_ = page; -#line 152 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - _tmp94_ = _page_ref0 (_tmp93_); -#line 152 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - _tmp95_ = pixels_filename; -#line 152 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - _tmp96_ = g_strdup (_tmp95_); -#line 152 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - g_hash_table_insert (_tmp92_, _tmp94_, _tmp96_); -#line 153 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - _tmp97_ = autosave_manager_get_book (self); -#line 153 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - _tmp98_ = _tmp97_; -#line 153 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - _tmp99_ = page; -#line 153 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - book_append_page (_tmp98_, _tmp99_); -#line 81 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - _page_unref0 (page); -#line 81 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - pixels = (g_free (pixels), NULL); -#line 81 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - _g_free0 (crop_name); -#line 81 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - _g_free0 (pixels_filename); -#line 81 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - _g_free0 (color_profile); -#line 81 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - _g_free0 (scan_direction_name); -#line 81 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - _g_free0 (page_name); -#line 868 "autosave-manager.c" - } - } -#line 81 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - page_name_collection = (_vala_array_free (page_name_collection, page_name_collection_length1, (GDestroyNotify) g_free), NULL); -#line 873 "autosave-manager.c" - } -#line 62 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - _g_free0 (pages); -#line 62 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - _g_key_file_unref0 (file); -#line 879 "autosave-manager.c" -} - - -static gchar* autosave_manager_get_value (AutosaveManager* self, GKeyFile* file, const gchar* group_name, const gchar* key, const gchar* _default_) { - gchar* result = NULL; - GError * _inner_error_ = NULL; -#line 157 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - g_return_val_if_fail (self != NULL, NULL); -#line 157 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - g_return_val_if_fail (file != NULL, NULL); -#line 157 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - g_return_val_if_fail (group_name != NULL, NULL); -#line 157 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - g_return_val_if_fail (key != NULL, NULL); -#line 157 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - g_return_val_if_fail (_default_ != NULL, NULL); -#line 896 "autosave-manager.c" - { - gchar* _tmp0_ = NULL; - GKeyFile* _tmp1_ = NULL; - const gchar* _tmp2_ = NULL; - const gchar* _tmp3_ = NULL; - gchar* _tmp4_ = NULL; - gchar* _tmp5_ = NULL; -#line 161 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - _tmp1_ = file; -#line 161 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - _tmp2_ = group_name; -#line 161 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - _tmp3_ = key; -#line 161 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - _tmp4_ = g_key_file_get_value (_tmp1_, _tmp2_, _tmp3_, &_inner_error_); -#line 161 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - _tmp0_ = _tmp4_; -#line 161 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - if (G_UNLIKELY (_inner_error_ != NULL)) { -#line 916 "autosave-manager.c" - goto __catch31_g_error; - } -#line 161 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - _tmp5_ = _tmp0_; -#line 161 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - _tmp0_ = NULL; -#line 161 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - result = _tmp5_; -#line 161 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - _g_free0 (_tmp0_); -#line 161 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - return result; -#line 929 "autosave-manager.c" - } - goto __finally31; - __catch31_g_error: - { - GError* e = NULL; - const gchar* _tmp6_ = NULL; - gchar* _tmp7_ = NULL; -#line 159 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - e = _inner_error_; -#line 159 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - _inner_error_ = NULL; -#line 165 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - _tmp6_ = _default_; -#line 165 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - _tmp7_ = g_strdup (_tmp6_); -#line 165 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - result = _tmp7_; -#line 165 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - _g_error_free0 (e); -#line 165 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - return result; -#line 951 "autosave-manager.c" - } - __finally31: -#line 159 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - g_critical ("file %s: line %d: uncaught error: %s (%s, %d)", __FILE__, __LINE__, _inner_error_->message, g_quark_to_string (_inner_error_->domain), _inner_error_->code); -#line 159 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - g_clear_error (&_inner_error_); -#line 159 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - return NULL; -#line 960 "autosave-manager.c" -} - - -static gint autosave_manager_get_integer (AutosaveManager* self, GKeyFile* file, const gchar* group_name, const gchar* key, gint _default_) { - gint result = 0; - gint _tmp6_ = 0; - GError * _inner_error_ = NULL; -#line 169 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - g_return_val_if_fail (self != NULL, 0); -#line 169 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - g_return_val_if_fail (file != NULL, 0); -#line 169 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - g_return_val_if_fail (group_name != NULL, 0); -#line 169 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - g_return_val_if_fail (key != NULL, 0); -#line 976 "autosave-manager.c" - { - gint _tmp0_ = 0; - GKeyFile* _tmp1_ = NULL; - const gchar* _tmp2_ = NULL; - const gchar* _tmp3_ = NULL; - gint _tmp4_ = 0; -#line 173 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - _tmp1_ = file; -#line 173 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - _tmp2_ = group_name; -#line 173 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - _tmp3_ = key; -#line 173 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - _tmp4_ = g_key_file_get_integer (_tmp1_, _tmp2_, _tmp3_, &_inner_error_); -#line 173 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - _tmp0_ = _tmp4_; -#line 173 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - if (G_UNLIKELY (_inner_error_ != NULL)) { -#line 995 "autosave-manager.c" - goto __catch32_g_error; - } -#line 173 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - result = _tmp0_; -#line 173 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - return result; -#line 1002 "autosave-manager.c" - } - goto __finally32; - __catch32_g_error: - { - GError* e = NULL; - gint _tmp5_ = 0; -#line 171 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - e = _inner_error_; -#line 171 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - _inner_error_ = NULL; -#line 177 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - _tmp5_ = _default_; -#line 177 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - result = _tmp5_; -#line 177 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - _g_error_free0 (e); -#line 177 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - return result; -#line 1021 "autosave-manager.c" - } - __finally32: -#line 171 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - g_critical ("file %s: line %d: uncaught error: %s (%s, %d)", __FILE__, __LINE__, _inner_error_->message, g_quark_to_string (_inner_error_->domain), _inner_error_->code); -#line 171 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - g_clear_error (&_inner_error_); -#line 171 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - return _tmp6_; -#line 1030 "autosave-manager.c" -} - - -static gboolean autosave_manager_get_boolean (AutosaveManager* self, GKeyFile* file, const gchar* group_name, const gchar* key, gboolean _default_) { - gboolean result = FALSE; - gboolean _tmp6_ = FALSE; - GError * _inner_error_ = NULL; -#line 181 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - g_return_val_if_fail (self != NULL, FALSE); -#line 181 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - g_return_val_if_fail (file != NULL, FALSE); -#line 181 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - g_return_val_if_fail (group_name != NULL, FALSE); -#line 181 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - g_return_val_if_fail (key != NULL, FALSE); -#line 1046 "autosave-manager.c" - { - gboolean _tmp0_ = FALSE; - GKeyFile* _tmp1_ = NULL; - const gchar* _tmp2_ = NULL; - const gchar* _tmp3_ = NULL; - gboolean _tmp4_ = FALSE; -#line 185 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - _tmp1_ = file; -#line 185 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - _tmp2_ = group_name; -#line 185 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - _tmp3_ = key; -#line 185 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - _tmp4_ = g_key_file_get_boolean (_tmp1_, _tmp2_, _tmp3_, &_inner_error_); -#line 185 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - _tmp0_ = _tmp4_; -#line 185 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - if (G_UNLIKELY (_inner_error_ != NULL)) { -#line 1065 "autosave-manager.c" - goto __catch33_g_error; - } -#line 185 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - result = _tmp0_; -#line 185 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - return result; -#line 1072 "autosave-manager.c" - } - goto __finally33; - __catch33_g_error: - { - GError* e = NULL; - gboolean _tmp5_ = FALSE; -#line 183 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - e = _inner_error_; -#line 183 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - _inner_error_ = NULL; -#line 189 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - _tmp5_ = _default_; -#line 189 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - result = _tmp5_; -#line 189 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - _g_error_free0 (e); -#line 189 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - return result; -#line 1091 "autosave-manager.c" - } - __finally33: -#line 183 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - g_critical ("file %s: line %d: uncaught error: %s (%s, %d)", __FILE__, __LINE__, _inner_error_->message, g_quark_to_string (_inner_error_->domain), _inner_error_->code); -#line 183 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - g_clear_error (&_inner_error_); -#line 183 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - return _tmp6_; -#line 1100 "autosave-manager.c" -} - - -void autosave_manager_cleanup (AutosaveManager* self) { - guint _tmp0_ = 0U; - GDir* dir = NULL; - GError * _inner_error_ = NULL; -#line 193 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - g_return_if_fail (self != NULL); -#line 195 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - g_debug ("autosave-manager.vala:195: Deleting autosave records"); -#line 197 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - _tmp0_ = self->priv->update_timeout; -#line 197 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - if (_tmp0_ > ((guint) 0)) { -#line 1116 "autosave-manager.c" - guint _tmp1_ = 0U; -#line 198 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - _tmp1_ = self->priv->update_timeout; -#line 198 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - g_source_remove (_tmp1_); -#line 1122 "autosave-manager.c" - } -#line 199 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - self->priv->update_timeout = (guint) 0; -#line 1126 "autosave-manager.c" - { - GDir* _tmp2_ = NULL; - const gchar* _tmp3_ = NULL; - GDir* _tmp4_ = NULL; - GDir* _tmp5_ = NULL; -#line 204 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - _tmp3_ = autosave_manager_AUTOSAVE_DIR; -#line 204 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - _tmp4_ = g_dir_open (_tmp3_, (guint) 0, &_inner_error_); -#line 204 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - _tmp2_ = _tmp4_; -#line 204 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - if (G_UNLIKELY (_inner_error_ != NULL)) { -#line 1140 "autosave-manager.c" - goto __catch34_g_error; - } -#line 204 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - _tmp5_ = _tmp2_; -#line 204 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - _tmp2_ = NULL; -#line 204 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - _g_dir_close0 (dir); -#line 204 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - dir = _tmp5_; -#line 202 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - _g_dir_close0 (_tmp2_); -#line 1153 "autosave-manager.c" - } - goto __finally34; - __catch34_g_error: - { - GError* e = NULL; - GError* _tmp6_ = NULL; - const gchar* _tmp7_ = NULL; -#line 202 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - e = _inner_error_; -#line 202 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - _inner_error_ = NULL; -#line 208 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - _tmp6_ = e; -#line 208 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - _tmp7_ = _tmp6_->message; -#line 208 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - g_warning ("autosave-manager.vala:208: Failed to delete autosaves: %s", _tmp7_); -#line 209 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - _g_error_free0 (e); -#line 209 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - _g_dir_close0 (dir); -#line 209 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - return; -#line 1177 "autosave-manager.c" - } - __finally34: -#line 202 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - if (G_UNLIKELY (_inner_error_ != NULL)) { -#line 202 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - _g_dir_close0 (dir); -#line 202 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - g_critical ("file %s: line %d: uncaught error: %s (%s, %d)", __FILE__, __LINE__, _inner_error_->message, g_quark_to_string (_inner_error_->domain), _inner_error_->code); -#line 202 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - g_clear_error (&_inner_error_); -#line 202 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - return; -#line 1190 "autosave-manager.c" - } -#line 212 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - while (TRUE) { -#line 1194 "autosave-manager.c" - gchar* filename = NULL; - GDir* _tmp8_ = NULL; - const gchar* _tmp9_ = NULL; - gchar* _tmp10_ = NULL; - const gchar* _tmp11_ = NULL; - gchar* path = NULL; - const gchar* _tmp12_ = NULL; - const gchar* _tmp13_ = NULL; - gchar* _tmp14_ = NULL; - const gchar* _tmp15_ = NULL; -#line 214 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - _tmp8_ = dir; -#line 214 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - _tmp9_ = g_dir_read_name (_tmp8_); -#line 214 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - _tmp10_ = g_strdup (_tmp9_); -#line 214 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - filename = _tmp10_; -#line 215 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - _tmp11_ = filename; -#line 215 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - if (_tmp11_ == NULL) { -#line 216 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - _g_free0 (filename); -#line 216 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - break; -#line 1221 "autosave-manager.c" - } -#line 217 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - _tmp12_ = autosave_manager_AUTOSAVE_DIR; -#line 217 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - _tmp13_ = filename; -#line 217 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - _tmp14_ = g_build_filename (_tmp12_, _tmp13_, NULL); -#line 217 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - path = _tmp14_; -#line 218 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - _tmp15_ = path; -#line 218 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - g_unlink (_tmp15_); -#line 212 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - _g_free0 (path); -#line 212 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - _g_free0 (filename); -#line 1239 "autosave-manager.c" - } -#line 193 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - _g_dir_close0 (dir); -#line 1243 "autosave-manager.c" -} - - -static void _autosave_manager_on_scan_finished_page_scan_finished (Page* _sender, gpointer self) { -#line 224 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - autosave_manager_on_scan_finished ((AutosaveManager*) self, _sender); -#line 1250 "autosave-manager.c" -} - - -static void _autosave_manager_on_changed_page_crop_changed (Page* _sender, gpointer self) { -#line 225 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - autosave_manager_on_changed ((AutosaveManager*) self); -#line 1257 "autosave-manager.c" -} - - -void autosave_manager_on_page_added (AutosaveManager* self, Page* page) { - Page* _tmp0_ = NULL; - Page* _tmp1_ = NULL; -#line 222 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - g_return_if_fail (self != NULL); -#line 222 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - g_return_if_fail (page != NULL); -#line 224 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - _tmp0_ = page; -#line 224 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - g_signal_connect (_tmp0_, "scan-finished", (GCallback) _autosave_manager_on_scan_finished_page_scan_finished, self); -#line 225 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - _tmp1_ = page; -#line 225 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - g_signal_connect (_tmp1_, "crop-changed", (GCallback) _autosave_manager_on_changed_page_crop_changed, self); -#line 1276 "autosave-manager.c" -} - - -void autosave_manager_on_page_removed (AutosaveManager* self, Page* page) { - Page* _tmp0_ = NULL; - guint _tmp1_ = 0U; - Page* _tmp2_ = NULL; - guint _tmp3_ = 0U; - gchar* filename = NULL; - GHashTable* _tmp4_ = NULL; - Page* _tmp5_ = NULL; - gconstpointer _tmp6_ = NULL; - gchar* _tmp7_ = NULL; - const gchar* _tmp8_ = NULL; - GHashTable* _tmp10_ = NULL; - Page* _tmp11_ = NULL; -#line 228 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - g_return_if_fail (self != NULL); -#line 228 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - g_return_if_fail (page != NULL); -#line 230 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - _tmp0_ = page; -#line 230 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - g_signal_parse_name ("scan-finished", TYPE_PAGE, &_tmp1_, NULL, FALSE); -#line 230 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - g_signal_handlers_disconnect_matched (_tmp0_, G_SIGNAL_MATCH_ID | G_SIGNAL_MATCH_FUNC | G_SIGNAL_MATCH_DATA, _tmp1_, 0, NULL, (GCallback) _autosave_manager_on_scan_finished_page_scan_finished, self); -#line 231 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - _tmp2_ = page; -#line 231 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - g_signal_parse_name ("crop-changed", TYPE_PAGE, &_tmp3_, NULL, FALSE); -#line 231 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - g_signal_handlers_disconnect_matched (_tmp2_, G_SIGNAL_MATCH_ID | G_SIGNAL_MATCH_FUNC | G_SIGNAL_MATCH_DATA, _tmp3_, 0, NULL, (GCallback) _autosave_manager_on_changed_page_crop_changed, self); -#line 233 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - _tmp4_ = self->priv->page_filenames; -#line 233 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - _tmp5_ = page; -#line 233 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - _tmp6_ = g_hash_table_lookup (_tmp4_, _tmp5_); -#line 233 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - _tmp7_ = g_strdup ((const gchar*) _tmp6_); -#line 233 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - filename = _tmp7_; -#line 234 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - _tmp8_ = filename; -#line 234 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - if (_tmp8_ != NULL) { -#line 1323 "autosave-manager.c" - const gchar* _tmp9_ = NULL; -#line 235 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - _tmp9_ = filename; -#line 235 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - g_unlink (_tmp9_); -#line 1329 "autosave-manager.c" - } -#line 236 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - _tmp10_ = self->priv->page_filenames; -#line 236 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - _tmp11_ = page; -#line 236 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - g_hash_table_remove (_tmp10_, _tmp11_); -#line 228 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - _g_free0 (filename); -#line 1339 "autosave-manager.c" -} - - -void autosave_manager_on_scan_finished (AutosaveManager* self, Page* page) { - Page* _tmp0_ = NULL; -#line 239 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - g_return_if_fail (self != NULL); -#line 239 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - g_return_if_fail (page != NULL); -#line 241 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - _tmp0_ = page; -#line 241 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - autosave_manager_save_pixels (self, _tmp0_); -#line 242 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - autosave_manager_save (self, FALSE); -#line 1355 "autosave-manager.c" -} - - -void autosave_manager_on_changed (AutosaveManager* self) { -#line 245 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - g_return_if_fail (self != NULL); -#line 247 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - autosave_manager_save (self, TRUE); -#line 1364 "autosave-manager.c" -} - - -void autosave_manager_on_cleared (AutosaveManager* self) { - GHashTable* _tmp0_ = NULL; -#line 250 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - g_return_if_fail (self != NULL); -#line 252 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - _tmp0_ = self->priv->page_filenames; -#line 252 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - g_hash_table_remove_all (_tmp0_); -#line 253 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - autosave_manager_save (self, TRUE); -#line 1378 "autosave-manager.c" -} - - -static gboolean ___lambda4_ (AutosaveManager* self) { - gboolean result = FALSE; -#line 270 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - autosave_manager_real_save (self); -#line 271 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - self->priv->update_timeout = (guint) 0; -#line 272 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - result = FALSE; -#line 272 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - return result; -#line 1392 "autosave-manager.c" -} - - -static gboolean ____lambda4__gsource_func (gpointer self) { - gboolean result; - result = ___lambda4_ ((AutosaveManager*) self); -#line 268 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - return result; -#line 1401 "autosave-manager.c" -} - - -static void autosave_manager_save (AutosaveManager* self, gboolean do_timeout) { - gboolean _tmp0_ = FALSE; - guint _tmp1_ = 0U; - guint _tmp3_ = 0U; - gboolean _tmp5_ = FALSE; -#line 256 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - g_return_if_fail (self != NULL); -#line 258 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - _tmp1_ = self->priv->update_timeout; -#line 258 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - if (_tmp1_ == ((guint) 0)) { -#line 1416 "autosave-manager.c" - gboolean _tmp2_ = FALSE; -#line 258 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - _tmp2_ = do_timeout; -#line 258 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - _tmp0_ = _tmp2_; -#line 1422 "autosave-manager.c" - } else { -#line 258 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - _tmp0_ = FALSE; -#line 1426 "autosave-manager.c" - } -#line 258 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - if (_tmp0_) { -#line 259 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - g_debug ("autosave-manager.vala:259: Waiting to autosave..."); -#line 1432 "autosave-manager.c" - } -#line 262 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - _tmp3_ = self->priv->update_timeout; -#line 262 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - if (_tmp3_ > ((guint) 0)) { -#line 1438 "autosave-manager.c" - guint _tmp4_ = 0U; -#line 263 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - _tmp4_ = self->priv->update_timeout; -#line 263 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - g_source_remove (_tmp4_); -#line 1444 "autosave-manager.c" - } -#line 264 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - self->priv->update_timeout = (guint) 0; -#line 266 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - _tmp5_ = do_timeout; -#line 266 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - if (_tmp5_) { -#line 1452 "autosave-manager.c" - guint _tmp6_ = 0U; -#line 268 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - _tmp6_ = g_timeout_add_full (G_PRIORITY_DEFAULT, (guint) 100, ____lambda4__gsource_func, autosave_manager_ref (self), autosave_manager_unref); -#line 268 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - self->priv->update_timeout = _tmp6_; -#line 1458 "autosave-manager.c" - } else { -#line 276 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - autosave_manager_real_save (self); -#line 1462 "autosave-manager.c" - } -} - - -static void autosave_manager_real_save (AutosaveManager* self) { - GKeyFile* file = NULL; - GKeyFile* _tmp0_ = NULL; - gchar* page_names = NULL; - gchar* _tmp1_ = NULL; - GKeyFile* _tmp109_ = NULL; - const gchar* _tmp110_ = NULL; - GError * _inner_error_ = NULL; -#line 279 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - g_return_if_fail (self != NULL); -#line 281 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - g_debug ("autosave-manager.vala:281: Autosaving book information"); -#line 283 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - _tmp0_ = g_key_file_new (); -#line 283 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - file = _tmp0_; -#line 284 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - _tmp1_ = g_strdup (""); -#line 284 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - page_names = _tmp1_; -#line 1487 "autosave-manager.c" - { - gint i = 0; -#line 285 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - i = 0; -#line 1492 "autosave-manager.c" - { - gboolean _tmp2_ = FALSE; -#line 285 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - _tmp2_ = TRUE; -#line 285 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - while (TRUE) { -#line 1499 "autosave-manager.c" - gint _tmp4_ = 0; - Book* _tmp5_ = NULL; - Book* _tmp6_ = NULL; - guint _tmp7_ = 0U; - guint _tmp8_ = 0U; - Page* page = NULL; - Book* _tmp9_ = NULL; - Book* _tmp10_ = NULL; - gint _tmp11_ = 0; - Page* _tmp12_ = NULL; - Page* _tmp13_ = NULL; - gboolean _tmp14_ = FALSE; - gboolean _tmp15_ = FALSE; - gchar* page_name = NULL; - gint _tmp16_ = 0; - gchar* _tmp17_ = NULL; - const gchar* _tmp18_ = NULL; - const gchar* _tmp21_ = NULL; - const gchar* _tmp22_ = NULL; - gchar* _tmp23_ = NULL; - const gchar* _tmp24_ = NULL; - GKeyFile* _tmp25_ = NULL; - const gchar* _tmp26_ = NULL; - Page* _tmp27_ = NULL; - gint _tmp28_ = 0; - gint _tmp29_ = 0; - GKeyFile* _tmp30_ = NULL; - const gchar* _tmp31_ = NULL; - Page* _tmp32_ = NULL; - gint _tmp33_ = 0; - gint _tmp34_ = 0; - GKeyFile* _tmp35_ = NULL; - const gchar* _tmp36_ = NULL; - Page* _tmp37_ = NULL; - gint _tmp38_ = 0; - gint _tmp39_ = 0; - GKeyFile* _tmp40_ = NULL; - const gchar* _tmp41_ = NULL; - Page* _tmp42_ = NULL; - gint _tmp43_ = 0; - gint _tmp44_ = 0; - GKeyFile* _tmp45_ = NULL; - const gchar* _tmp46_ = NULL; - Page* _tmp47_ = NULL; - gint _tmp48_ = 0; - gint _tmp49_ = 0; - GKeyFile* _tmp50_ = NULL; - const gchar* _tmp51_ = NULL; - Page* _tmp52_ = NULL; - gint _tmp53_ = 0; - gint _tmp54_ = 0; - Page* _tmp55_ = NULL; - ScanDirection _tmp56_ = 0; - ScanDirection _tmp57_ = 0; - const gchar* _tmp66_ = NULL; - Page* _tmp67_ = NULL; - const gchar* _tmp68_ = NULL; - const gchar* _tmp69_ = NULL; - GKeyFile* _tmp70_ = NULL; - const gchar* _tmp71_ = NULL; - const gchar* _tmp72_ = NULL; - GHashTable* _tmp73_ = NULL; - Page* _tmp74_ = NULL; - gconstpointer _tmp75_ = NULL; - GKeyFile* _tmp76_ = NULL; - const gchar* _tmp77_ = NULL; - GKeyFile* _tmp78_ = NULL; - const gchar* _tmp79_ = NULL; - Page* _tmp80_ = NULL; - gboolean _tmp81_ = FALSE; - gboolean _tmp82_ = FALSE; - const gchar* _tmp83_ = NULL; - Page* _tmp84_ = NULL; - const gchar* _tmp85_ = NULL; - const gchar* _tmp86_ = NULL; - GKeyFile* _tmp87_ = NULL; - const gchar* _tmp88_ = NULL; - GKeyFile* _tmp89_ = NULL; - const gchar* _tmp90_ = NULL; - Page* _tmp91_ = NULL; - gint _tmp92_ = 0; - gint _tmp93_ = 0; - GKeyFile* _tmp94_ = NULL; - const gchar* _tmp95_ = NULL; - Page* _tmp96_ = NULL; - gint _tmp97_ = 0; - gint _tmp98_ = 0; - GKeyFile* _tmp99_ = NULL; - const gchar* _tmp100_ = NULL; - Page* _tmp101_ = NULL; - gint _tmp102_ = 0; - gint _tmp103_ = 0; - GKeyFile* _tmp104_ = NULL; - const gchar* _tmp105_ = NULL; - Page* _tmp106_ = NULL; - gint _tmp107_ = 0; - gint _tmp108_ = 0; -#line 285 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - if (!_tmp2_) { -#line 1599 "autosave-manager.c" - gint _tmp3_ = 0; -#line 285 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - _tmp3_ = i; -#line 285 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - i = _tmp3_ + 1; -#line 1605 "autosave-manager.c" - } -#line 285 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - _tmp2_ = FALSE; -#line 285 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - _tmp4_ = i; -#line 285 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - _tmp5_ = autosave_manager_get_book (self); -#line 285 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - _tmp6_ = _tmp5_; -#line 285 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - _tmp7_ = book_get_n_pages (_tmp6_); -#line 285 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - _tmp8_ = _tmp7_; -#line 285 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - if (!(((guint) _tmp4_) < _tmp8_)) { -#line 285 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - break; -#line 1623 "autosave-manager.c" - } -#line 287 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - _tmp9_ = autosave_manager_get_book (self); -#line 287 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - _tmp10_ = _tmp9_; -#line 287 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - _tmp11_ = i; -#line 287 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - _tmp12_ = book_get_page (_tmp10_, _tmp11_); -#line 287 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - page = _tmp12_; -#line 290 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - _tmp13_ = page; -#line 290 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - _tmp14_ = page_get_has_data (_tmp13_); -#line 290 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - _tmp15_ = _tmp14_; -#line 290 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - if (!_tmp15_) { -#line 291 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - _page_unref0 (page); -#line 291 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - continue; -#line 1647 "autosave-manager.c" - } -#line 293 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - _tmp16_ = i; -#line 293 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - _tmp17_ = g_strdup_printf ("page-%d", _tmp16_); -#line 293 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - page_name = _tmp17_; -#line 294 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - _tmp18_ = page_names; -#line 294 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - if (g_strcmp0 (_tmp18_, "") != 0) { -#line 1659 "autosave-manager.c" - const gchar* _tmp19_ = NULL; - gchar* _tmp20_ = NULL; -#line 295 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - _tmp19_ = page_names; -#line 295 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - _tmp20_ = g_strconcat (_tmp19_, " ", NULL); -#line 295 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - _g_free0 (page_names); -#line 295 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - page_names = _tmp20_; -#line 1670 "autosave-manager.c" - } -#line 296 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - _tmp21_ = page_names; -#line 296 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - _tmp22_ = page_name; -#line 296 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - _tmp23_ = g_strconcat (_tmp21_, _tmp22_, NULL); -#line 296 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - _g_free0 (page_names); -#line 296 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - page_names = _tmp23_; -#line 298 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - _tmp24_ = page_name; -#line 298 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - g_debug ("autosave-manager.vala:298: Autosaving page %s", _tmp24_); -#line 300 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - _tmp25_ = file; -#line 300 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - _tmp26_ = page_name; -#line 300 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - _tmp27_ = page; -#line 300 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - _tmp28_ = page_get_scan_width (_tmp27_); -#line 300 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - _tmp29_ = _tmp28_; -#line 300 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - g_key_file_set_integer (_tmp25_, _tmp26_, "scan-width", _tmp29_); -#line 301 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - _tmp30_ = file; -#line 301 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - _tmp31_ = page_name; -#line 301 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - _tmp32_ = page; -#line 301 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - _tmp33_ = page_get_scan_height (_tmp32_); -#line 301 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - _tmp34_ = _tmp33_; -#line 301 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - g_key_file_set_integer (_tmp30_, _tmp31_, "scan-height", _tmp34_); -#line 302 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - _tmp35_ = file; -#line 302 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - _tmp36_ = page_name; -#line 302 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - _tmp37_ = page; -#line 302 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - _tmp38_ = page_get_rowstride (_tmp37_); -#line 302 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - _tmp39_ = _tmp38_; -#line 302 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - g_key_file_set_integer (_tmp35_, _tmp36_, "rowstride", _tmp39_); -#line 303 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - _tmp40_ = file; -#line 303 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - _tmp41_ = page_name; -#line 303 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - _tmp42_ = page; -#line 303 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - _tmp43_ = page_get_n_channels (_tmp42_); -#line 303 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - _tmp44_ = _tmp43_; -#line 303 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - g_key_file_set_integer (_tmp40_, _tmp41_, "n-channels", _tmp44_); -#line 304 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - _tmp45_ = file; -#line 304 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - _tmp46_ = page_name; -#line 304 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - _tmp47_ = page; -#line 304 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - _tmp48_ = page_get_depth (_tmp47_); -#line 304 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - _tmp49_ = _tmp48_; -#line 304 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - g_key_file_set_integer (_tmp45_, _tmp46_, "depth", _tmp49_); -#line 305 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - _tmp50_ = file; -#line 305 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - _tmp51_ = page_name; -#line 305 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - _tmp52_ = page; -#line 305 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - _tmp53_ = page_get_dpi (_tmp52_); -#line 305 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - _tmp54_ = _tmp53_; -#line 305 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - g_key_file_set_integer (_tmp50_, _tmp51_, "dpi", _tmp54_); -#line 306 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - _tmp55_ = page; -#line 306 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - _tmp56_ = page_get_scan_direction (_tmp55_); -#line 306 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - _tmp57_ = _tmp56_; -#line 306 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - switch (_tmp57_) { -#line 306 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - case SCAN_DIRECTION_TOP_TO_BOTTOM: -#line 1768 "autosave-manager.c" - { - GKeyFile* _tmp58_ = NULL; - const gchar* _tmp59_ = NULL; -#line 309 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - _tmp58_ = file; -#line 309 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - _tmp59_ = page_name; -#line 309 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - g_key_file_set_value (_tmp58_, _tmp59_, "scan-direction", "TOP_TO_BOTTOM"); -#line 310 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - break; -#line 1780 "autosave-manager.c" - } -#line 306 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - case SCAN_DIRECTION_LEFT_TO_RIGHT: -#line 1784 "autosave-manager.c" - { - GKeyFile* _tmp60_ = NULL; - const gchar* _tmp61_ = NULL; -#line 312 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - _tmp60_ = file; -#line 312 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - _tmp61_ = page_name; -#line 312 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - g_key_file_set_value (_tmp60_, _tmp61_, "scan-direction", "LEFT_TO_RIGHT"); -#line 313 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - break; -#line 1796 "autosave-manager.c" - } -#line 306 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - case SCAN_DIRECTION_BOTTOM_TO_TOP: -#line 1800 "autosave-manager.c" - { - GKeyFile* _tmp62_ = NULL; - const gchar* _tmp63_ = NULL; -#line 315 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - _tmp62_ = file; -#line 315 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - _tmp63_ = page_name; -#line 315 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - g_key_file_set_value (_tmp62_, _tmp63_, "scan-direction", "BOTTOM_TO_TOP"); -#line 316 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - break; -#line 1812 "autosave-manager.c" - } -#line 306 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - case SCAN_DIRECTION_RIGHT_TO_LEFT: -#line 1816 "autosave-manager.c" - { - GKeyFile* _tmp64_ = NULL; - const gchar* _tmp65_ = NULL; -#line 318 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - _tmp64_ = file; -#line 318 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - _tmp65_ = page_name; -#line 318 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - g_key_file_set_value (_tmp64_, _tmp65_, "scan-direction", "RIGHT_TO_LEFT"); -#line 319 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - break; -#line 1828 "autosave-manager.c" - } - default: -#line 306 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - break; -#line 1833 "autosave-manager.c" - } -#line 321 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - _tmp67_ = page; -#line 321 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - _tmp68_ = page_get_color_profile (_tmp67_); -#line 321 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - _tmp69_ = _tmp68_; -#line 321 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - _tmp66_ = _tmp69_; -#line 321 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - if (_tmp66_ == NULL) { -#line 321 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - _tmp66_ = ""; -#line 1847 "autosave-manager.c" - } -#line 321 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - _tmp70_ = file; -#line 321 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - _tmp71_ = page_name; -#line 321 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - g_key_file_set_value (_tmp70_, _tmp71_, "color-profile", _tmp66_); -#line 322 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - _tmp73_ = self->priv->page_filenames; -#line 322 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - _tmp74_ = page; -#line 322 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - _tmp75_ = g_hash_table_lookup (_tmp73_, _tmp74_); -#line 322 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - _tmp72_ = (const gchar*) _tmp75_; -#line 322 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - if (_tmp72_ == NULL) { -#line 322 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - _tmp72_ = ""; -#line 1867 "autosave-manager.c" - } -#line 322 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - _tmp76_ = file; -#line 322 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - _tmp77_ = page_name; -#line 322 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - g_key_file_set_value (_tmp76_, _tmp77_, "pixels-filename", _tmp72_); -#line 323 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - _tmp78_ = file; -#line 323 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - _tmp79_ = page_name; -#line 323 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - _tmp80_ = page; -#line 323 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - _tmp81_ = page_get_has_crop (_tmp80_); -#line 323 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - _tmp82_ = _tmp81_; -#line 323 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - g_key_file_set_boolean (_tmp78_, _tmp79_, "has-crop", _tmp82_); -#line 324 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - _tmp84_ = page; -#line 324 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - _tmp85_ = page_get_crop_name (_tmp84_); -#line 324 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - _tmp86_ = _tmp85_; -#line 324 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - _tmp83_ = _tmp86_; -#line 324 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - if (_tmp83_ == NULL) { -#line 324 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - _tmp83_ = ""; -#line 1899 "autosave-manager.c" - } -#line 324 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - _tmp87_ = file; -#line 324 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - _tmp88_ = page_name; -#line 324 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - g_key_file_set_value (_tmp87_, _tmp88_, "crop-name", _tmp83_); -#line 325 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - _tmp89_ = file; -#line 325 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - _tmp90_ = page_name; -#line 325 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - _tmp91_ = page; -#line 325 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - _tmp92_ = page_get_crop_x (_tmp91_); -#line 325 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - _tmp93_ = _tmp92_; -#line 325 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - g_key_file_set_integer (_tmp89_, _tmp90_, "crop-x", _tmp93_); -#line 326 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - _tmp94_ = file; -#line 326 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - _tmp95_ = page_name; -#line 326 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - _tmp96_ = page; -#line 326 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - _tmp97_ = page_get_crop_y (_tmp96_); -#line 326 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - _tmp98_ = _tmp97_; -#line 326 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - g_key_file_set_integer (_tmp94_, _tmp95_, "crop-y", _tmp98_); -#line 327 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - _tmp99_ = file; -#line 327 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - _tmp100_ = page_name; -#line 327 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - _tmp101_ = page; -#line 327 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - _tmp102_ = page_get_crop_width (_tmp101_); -#line 327 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - _tmp103_ = _tmp102_; -#line 327 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - g_key_file_set_integer (_tmp99_, _tmp100_, "crop-width", _tmp103_); -#line 328 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - _tmp104_ = file; -#line 328 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - _tmp105_ = page_name; -#line 328 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - _tmp106_ = page; -#line 328 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - _tmp107_ = page_get_crop_height (_tmp106_); -#line 328 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - _tmp108_ = _tmp107_; -#line 328 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - g_key_file_set_integer (_tmp104_, _tmp105_, "crop-height", _tmp108_); -#line 285 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - _g_free0 (page_name); -#line 285 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - _page_unref0 (page); -#line 1959 "autosave-manager.c" - } - } - } -#line 330 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - _tmp109_ = file; -#line 330 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - _tmp110_ = page_names; -#line 330 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - g_key_file_set_value (_tmp109_, "simple-scan", "pages", _tmp110_); -#line 1969 "autosave-manager.c" - { - const gchar* _tmp111_ = NULL; - const gchar* _tmp112_ = NULL; - GKeyFile* _tmp113_ = NULL; - gchar* _tmp114_ = NULL; - gchar* _tmp115_ = NULL; -#line 334 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - _tmp111_ = autosave_manager_AUTOSAVE_DIR; -#line 334 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - g_mkdir_with_parents (_tmp111_, 0777); -#line 335 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - _tmp112_ = autosave_manager_AUTOSAVE_PATH; -#line 335 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - _tmp113_ = file; -#line 335 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - _tmp114_ = g_key_file_to_data (_tmp113_, NULL, NULL); -#line 335 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - _tmp115_ = _tmp114_; -#line 335 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - g_file_set_contents (_tmp112_, _tmp115_, (gssize) -1, &_inner_error_); -#line 335 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - _g_free0 (_tmp115_); -#line 335 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - if (G_UNLIKELY (_inner_error_ != NULL)) { -#line 1994 "autosave-manager.c" - goto __catch35_g_error; - } - } - goto __finally35; - __catch35_g_error: - { - GError* e = NULL; - GError* _tmp116_ = NULL; - const gchar* _tmp117_ = NULL; -#line 332 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - e = _inner_error_; -#line 332 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - _inner_error_ = NULL; -#line 339 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - _tmp116_ = e; -#line 339 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - _tmp117_ = _tmp116_->message; -#line 339 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - g_warning ("autosave-manager.vala:339: Failed to write autosave: %s", _tmp117_); -#line 332 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - _g_error_free0 (e); -#line 2016 "autosave-manager.c" - } - __finally35: -#line 332 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - if (G_UNLIKELY (_inner_error_ != NULL)) { -#line 332 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - _g_free0 (page_names); -#line 332 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - _g_key_file_unref0 (file); -#line 332 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - g_critical ("file %s: line %d: uncaught error: %s (%s, %d)", __FILE__, __LINE__, _inner_error_->message, g_quark_to_string (_inner_error_->domain), _inner_error_->code); -#line 332 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - g_clear_error (&_inner_error_); -#line 332 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - return; -#line 2031 "autosave-manager.c" - } -#line 279 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - _g_free0 (page_names); -#line 279 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - _g_key_file_unref0 (file); -#line 2037 "autosave-manager.c" -} - - -static void autosave_manager_save_pixels (AutosaveManager* self, Page* page) { - gchar* filename = NULL; - GHashFunc _tmp0_ = NULL; - Page* _tmp1_ = NULL; - guint _tmp2_ = 0U; - gchar* _tmp3_ = NULL; - gchar* path = NULL; - const gchar* _tmp4_ = NULL; - gchar* _tmp5_ = NULL; - GHashTable* _tmp6_ = NULL; - Page* _tmp7_ = NULL; - Page* _tmp8_ = NULL; - gchar* _tmp9_ = NULL; - GFile* file = NULL; - GFile* _tmp10_ = NULL; - GError * _inner_error_ = NULL; -#line 343 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - g_return_if_fail (self != NULL); -#line 343 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - g_return_if_fail (page != NULL); -#line 345 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - _tmp0_ = g_direct_hash; -#line 345 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - _tmp1_ = page; -#line 345 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - _tmp2_ = _tmp0_ (_tmp1_); -#line 345 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - _tmp3_ = g_strdup_printf ("%u.pixels", _tmp2_); -#line 345 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - filename = _tmp3_; -#line 346 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - _tmp4_ = autosave_manager_AUTOSAVE_DIR; -#line 346 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - _tmp5_ = g_build_filename (_tmp4_, filename, NULL); -#line 346 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - path = _tmp5_; -#line 347 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - _tmp6_ = self->priv->page_filenames; -#line 347 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - _tmp7_ = page; -#line 347 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - _tmp8_ = _page_ref0 (_tmp7_); -#line 347 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - _tmp9_ = g_strdup (filename); -#line 347 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - g_hash_table_insert (_tmp6_, _tmp8_, _tmp9_); -#line 349 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - g_debug ("autosave-manager.vala:349: Autosaving page pixels to %s", path); -#line 351 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - _tmp10_ = g_file_new_for_path (path); -#line 351 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - file = _tmp10_; -#line 2093 "autosave-manager.c" - { - Page* _tmp11_ = NULL; - gint _tmp12_ = 0; - guchar* _tmp13_ = NULL; -#line 354 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - _tmp11_ = page; -#line 354 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - _tmp13_ = page_get_pixels (_tmp11_, &_tmp12_); -#line 354 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - g_file_replace_contents (file, _tmp13_, (gsize) _tmp12_, NULL, FALSE, G_FILE_CREATE_NONE, NULL, NULL, &_inner_error_); -#line 354 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - if (G_UNLIKELY (_inner_error_ != NULL)) { -#line 2106 "autosave-manager.c" - goto __catch36_g_error; - } - } - goto __finally36; - __catch36_g_error: - { - GError* e = NULL; - GError* _tmp14_ = NULL; - const gchar* _tmp15_ = NULL; -#line 352 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - e = _inner_error_; -#line 352 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - _inner_error_ = NULL; -#line 358 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - _tmp14_ = e; -#line 358 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - _tmp15_ = _tmp14_->message; -#line 358 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - g_warning ("autosave-manager.vala:358: Failed to autosave page contents: %s", _tmp15_); -#line 352 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - _g_error_free0 (e); -#line 2128 "autosave-manager.c" - } - __finally36: -#line 352 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - if (G_UNLIKELY (_inner_error_ != NULL)) { -#line 352 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - _g_object_unref0 (file); -#line 352 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - _g_free0 (path); -#line 352 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - _g_free0 (filename); -#line 352 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - g_critical ("file %s: line %d: uncaught error: %s (%s, %d)", __FILE__, __LINE__, _inner_error_->message, g_quark_to_string (_inner_error_->domain), _inner_error_->code); -#line 352 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - g_clear_error (&_inner_error_); -#line 352 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - return; -#line 2145 "autosave-manager.c" - } -#line 343 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - _g_object_unref0 (file); -#line 343 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - _g_free0 (path); -#line 343 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - _g_free0 (filename); -#line 2153 "autosave-manager.c" -} - - -Book* autosave_manager_get_book (AutosaveManager* self) { - Book* result; - Book* _tmp0_ = NULL; -#line 26 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - g_return_val_if_fail (self != NULL, NULL); -#line 28 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - _tmp0_ = self->priv->book_; -#line 28 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - result = _tmp0_; -#line 28 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - return result; -#line 2168 "autosave-manager.c" -} - - -static void _autosave_manager_on_page_added_book_page_added (Book* _sender, Page* page, gpointer self) { -#line 39 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - autosave_manager_on_page_added ((AutosaveManager*) self, page); -#line 2175 "autosave-manager.c" -} - - -static void _autosave_manager_on_page_removed_book_page_removed (Book* _sender, Page* page, gpointer self) { -#line 40 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - autosave_manager_on_page_removed ((AutosaveManager*) self, page); -#line 2182 "autosave-manager.c" -} - - -static void _autosave_manager_on_changed_book_reordered (Book* _sender, gpointer self) { -#line 41 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - autosave_manager_on_changed ((AutosaveManager*) self); -#line 2189 "autosave-manager.c" -} - - -static void _autosave_manager_on_cleared_book_cleared (Book* _sender, gpointer self) { -#line 42 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - autosave_manager_on_cleared ((AutosaveManager*) self); -#line 2196 "autosave-manager.c" -} - - -static gpointer _book_ref0 (gpointer self) { -#line 44 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - return self ? book_ref (self) : NULL; -#line 2203 "autosave-manager.c" -} - - -void autosave_manager_set_book (AutosaveManager* self, Book* value) { - Book* _tmp0_ = NULL; - Book* _tmp19_ = NULL; - Book* _tmp20_ = NULL; - Book* _tmp21_ = NULL; - Book* _tmp22_ = NULL; - Book* _tmp23_ = NULL; - Book* _tmp24_ = NULL; -#line 30 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - g_return_if_fail (self != NULL); -#line 32 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - _tmp0_ = self->priv->book_; -#line 32 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - if (_tmp0_ != NULL) { -#line 2221 "autosave-manager.c" - Book* _tmp11_ = NULL; - guint _tmp12_ = 0U; - Book* _tmp13_ = NULL; - guint _tmp14_ = 0U; - Book* _tmp15_ = NULL; - guint _tmp16_ = 0U; - Book* _tmp17_ = NULL; - guint _tmp18_ = 0U; - { - gint i = 0; -#line 34 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - i = 0; -#line 2234 "autosave-manager.c" - { - gboolean _tmp1_ = FALSE; -#line 34 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - _tmp1_ = TRUE; -#line 34 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - while (TRUE) { -#line 2241 "autosave-manager.c" - gint _tmp3_ = 0; - Book* _tmp4_ = NULL; - guint _tmp5_ = 0U; - guint _tmp6_ = 0U; - Page* page = NULL; - Book* _tmp7_ = NULL; - gint _tmp8_ = 0; - Page* _tmp9_ = NULL; - Page* _tmp10_ = NULL; -#line 34 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - if (!_tmp1_) { -#line 2253 "autosave-manager.c" - gint _tmp2_ = 0; -#line 34 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - _tmp2_ = i; -#line 34 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - i = _tmp2_ + 1; -#line 2259 "autosave-manager.c" - } -#line 34 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - _tmp1_ = FALSE; -#line 34 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - _tmp3_ = i; -#line 34 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - _tmp4_ = self->priv->book_; -#line 34 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - _tmp5_ = book_get_n_pages (_tmp4_); -#line 34 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - _tmp6_ = _tmp5_; -#line 34 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - if (!(((guint) _tmp3_) < _tmp6_)) { -#line 34 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - break; -#line 2275 "autosave-manager.c" - } -#line 36 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - _tmp7_ = self->priv->book_; -#line 36 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - _tmp8_ = i; -#line 36 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - _tmp9_ = book_get_page (_tmp7_, _tmp8_); -#line 36 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - page = _tmp9_; -#line 37 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - _tmp10_ = page; -#line 37 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - autosave_manager_on_page_removed (self, _tmp10_); -#line 34 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - _page_unref0 (page); -#line 2291 "autosave-manager.c" - } - } - } -#line 39 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - _tmp11_ = self->priv->book_; -#line 39 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - g_signal_parse_name ("page-added", TYPE_BOOK, &_tmp12_, NULL, FALSE); -#line 39 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - g_signal_handlers_disconnect_matched (_tmp11_, G_SIGNAL_MATCH_ID | G_SIGNAL_MATCH_FUNC | G_SIGNAL_MATCH_DATA, _tmp12_, 0, NULL, (GCallback) _autosave_manager_on_page_added_book_page_added, self); -#line 40 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - _tmp13_ = self->priv->book_; -#line 40 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - g_signal_parse_name ("page-removed", TYPE_BOOK, &_tmp14_, NULL, FALSE); -#line 40 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - g_signal_handlers_disconnect_matched (_tmp13_, G_SIGNAL_MATCH_ID | G_SIGNAL_MATCH_FUNC | G_SIGNAL_MATCH_DATA, _tmp14_, 0, NULL, (GCallback) _autosave_manager_on_page_removed_book_page_removed, self); -#line 41 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - _tmp15_ = self->priv->book_; -#line 41 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - g_signal_parse_name ("reordered", TYPE_BOOK, &_tmp16_, NULL, FALSE); -#line 41 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - g_signal_handlers_disconnect_matched (_tmp15_, G_SIGNAL_MATCH_ID | G_SIGNAL_MATCH_FUNC | G_SIGNAL_MATCH_DATA, _tmp16_, 0, NULL, (GCallback) _autosave_manager_on_changed_book_reordered, self); -#line 42 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - _tmp17_ = self->priv->book_; -#line 42 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - g_signal_parse_name ("cleared", TYPE_BOOK, &_tmp18_, NULL, FALSE); -#line 42 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - g_signal_handlers_disconnect_matched (_tmp17_, G_SIGNAL_MATCH_ID | G_SIGNAL_MATCH_FUNC | G_SIGNAL_MATCH_DATA, _tmp18_, 0, NULL, (GCallback) _autosave_manager_on_cleared_book_cleared, self); -#line 2319 "autosave-manager.c" - } -#line 44 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - _tmp19_ = value; -#line 44 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - _tmp20_ = _book_ref0 (_tmp19_); -#line 44 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - _book_unref0 (self->priv->book_); -#line 44 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - self->priv->book_ = _tmp20_; -#line 45 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - _tmp21_ = self->priv->book_; -#line 45 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - g_signal_connect (_tmp21_, "page-added", (GCallback) _autosave_manager_on_page_added_book_page_added, self); -#line 46 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - _tmp22_ = self->priv->book_; -#line 46 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - g_signal_connect (_tmp22_, "page-removed", (GCallback) _autosave_manager_on_page_removed_book_page_removed, self); -#line 47 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - _tmp23_ = self->priv->book_; -#line 47 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - g_signal_connect (_tmp23_, "reordered", (GCallback) _autosave_manager_on_changed_book_reordered, self); -#line 48 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - _tmp24_ = self->priv->book_; -#line 48 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - g_signal_connect (_tmp24_, "cleared", (GCallback) _autosave_manager_on_cleared_book_cleared, self); -#line 2345 "autosave-manager.c" - { - gint i = 0; -#line 49 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - i = 0; -#line 2350 "autosave-manager.c" - { - gboolean _tmp25_ = FALSE; -#line 49 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - _tmp25_ = TRUE; -#line 49 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - while (TRUE) { -#line 2357 "autosave-manager.c" - gint _tmp27_ = 0; - Book* _tmp28_ = NULL; - guint _tmp29_ = 0U; - guint _tmp30_ = 0U; - Page* page = NULL; - Book* _tmp31_ = NULL; - gint _tmp32_ = 0; - Page* _tmp33_ = NULL; - Page* _tmp34_ = NULL; -#line 49 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - if (!_tmp25_) { -#line 2369 "autosave-manager.c" - gint _tmp26_ = 0; -#line 49 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - _tmp26_ = i; -#line 49 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - i = _tmp26_ + 1; -#line 2375 "autosave-manager.c" - } -#line 49 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - _tmp25_ = FALSE; -#line 49 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - _tmp27_ = i; -#line 49 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - _tmp28_ = self->priv->book_; -#line 49 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - _tmp29_ = book_get_n_pages (_tmp28_); -#line 49 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - _tmp30_ = _tmp29_; -#line 49 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - if (!(((guint) _tmp27_) < _tmp30_)) { -#line 49 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - break; -#line 2391 "autosave-manager.c" - } -#line 51 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - _tmp31_ = self->priv->book_; -#line 51 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - _tmp32_ = i; -#line 51 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - _tmp33_ = book_get_page (_tmp31_, _tmp32_); -#line 51 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - page = _tmp33_; -#line 52 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - _tmp34_ = page; -#line 52 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - autosave_manager_on_page_added (self, _tmp34_); -#line 49 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - _page_unref0 (page); -#line 2407 "autosave-manager.c" - } - } - } -} - - -static void value_autosave_manager_init (GValue* value) { -#line 13 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - value->data[0].v_pointer = NULL; -#line 2417 "autosave-manager.c" -} - - -static void value_autosave_manager_free_value (GValue* value) { -#line 13 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - if (value->data[0].v_pointer) { -#line 13 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - autosave_manager_unref (value->data[0].v_pointer); -#line 2426 "autosave-manager.c" - } -} - - -static void value_autosave_manager_copy_value (const GValue* src_value, GValue* dest_value) { -#line 13 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - if (src_value->data[0].v_pointer) { -#line 13 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - dest_value->data[0].v_pointer = autosave_manager_ref (src_value->data[0].v_pointer); -#line 2436 "autosave-manager.c" - } else { -#line 13 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - dest_value->data[0].v_pointer = NULL; -#line 2440 "autosave-manager.c" - } -} - - -static gpointer value_autosave_manager_peek_pointer (const GValue* value) { -#line 13 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - return value->data[0].v_pointer; -#line 2448 "autosave-manager.c" -} - - -static gchar* value_autosave_manager_collect_value (GValue* value, guint n_collect_values, GTypeCValue* collect_values, guint collect_flags) { -#line 13 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - if (collect_values[0].v_pointer) { -#line 2455 "autosave-manager.c" - AutosaveManager* object; - object = collect_values[0].v_pointer; -#line 13 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - if (object->parent_instance.g_class == NULL) { -#line 13 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - return g_strconcat ("invalid unclassed object pointer for value type `", G_VALUE_TYPE_NAME (value), "'", NULL); -#line 2462 "autosave-manager.c" - } else if (!g_value_type_compatible (G_TYPE_FROM_INSTANCE (object), G_VALUE_TYPE (value))) { -#line 13 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - return g_strconcat ("invalid object type `", g_type_name (G_TYPE_FROM_INSTANCE (object)), "' for value type `", G_VALUE_TYPE_NAME (value), "'", NULL); -#line 2466 "autosave-manager.c" - } -#line 13 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - value->data[0].v_pointer = autosave_manager_ref (object); -#line 2470 "autosave-manager.c" - } else { -#line 13 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - value->data[0].v_pointer = NULL; -#line 2474 "autosave-manager.c" - } -#line 13 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - return NULL; -#line 2478 "autosave-manager.c" -} - - -static gchar* value_autosave_manager_lcopy_value (const GValue* value, guint n_collect_values, GTypeCValue* collect_values, guint collect_flags) { - AutosaveManager** object_p; - object_p = collect_values[0].v_pointer; -#line 13 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - if (!object_p) { -#line 13 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - return g_strdup_printf ("value location for `%s' passed as NULL", G_VALUE_TYPE_NAME (value)); -#line 2489 "autosave-manager.c" - } -#line 13 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - if (!value->data[0].v_pointer) { -#line 13 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - *object_p = NULL; -#line 2495 "autosave-manager.c" - } else if (collect_flags & G_VALUE_NOCOPY_CONTENTS) { -#line 13 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - *object_p = value->data[0].v_pointer; -#line 2499 "autosave-manager.c" - } else { -#line 13 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - *object_p = autosave_manager_ref (value->data[0].v_pointer); -#line 2503 "autosave-manager.c" - } -#line 13 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - return NULL; -#line 2507 "autosave-manager.c" -} - - -GParamSpec* param_spec_autosave_manager (const gchar* name, const gchar* nick, const gchar* blurb, GType object_type, GParamFlags flags) { - ParamSpecAutosaveManager* spec; -#line 13 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - g_return_val_if_fail (g_type_is_a (object_type, TYPE_AUTOSAVE_MANAGER), NULL); -#line 13 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - spec = g_param_spec_internal (G_TYPE_PARAM_OBJECT, name, nick, blurb, flags); -#line 13 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - G_PARAM_SPEC (spec)->value_type = object_type; -#line 13 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - return G_PARAM_SPEC (spec); -#line 2521 "autosave-manager.c" -} - - -gpointer value_get_autosave_manager (const GValue* value) { -#line 13 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - g_return_val_if_fail (G_TYPE_CHECK_VALUE_TYPE (value, TYPE_AUTOSAVE_MANAGER), NULL); -#line 13 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - return value->data[0].v_pointer; -#line 2530 "autosave-manager.c" -} - - -void value_set_autosave_manager (GValue* value, gpointer v_object) { - AutosaveManager* old; -#line 13 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - g_return_if_fail (G_TYPE_CHECK_VALUE_TYPE (value, TYPE_AUTOSAVE_MANAGER)); -#line 13 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - old = value->data[0].v_pointer; -#line 13 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - if (v_object) { -#line 13 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - g_return_if_fail (G_TYPE_CHECK_INSTANCE_TYPE (v_object, TYPE_AUTOSAVE_MANAGER)); -#line 13 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - g_return_if_fail (g_value_type_compatible (G_TYPE_FROM_INSTANCE (v_object), G_VALUE_TYPE (value))); -#line 13 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - value->data[0].v_pointer = v_object; -#line 13 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - autosave_manager_ref (value->data[0].v_pointer); -#line 2550 "autosave-manager.c" - } else { -#line 13 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - value->data[0].v_pointer = NULL; -#line 2554 "autosave-manager.c" - } -#line 13 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - if (old) { -#line 13 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - autosave_manager_unref (old); -#line 2560 "autosave-manager.c" - } -} - - -void value_take_autosave_manager (GValue* value, gpointer v_object) { - AutosaveManager* old; -#line 13 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - g_return_if_fail (G_TYPE_CHECK_VALUE_TYPE (value, TYPE_AUTOSAVE_MANAGER)); -#line 13 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - old = value->data[0].v_pointer; -#line 13 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - if (v_object) { -#line 13 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - g_return_if_fail (G_TYPE_CHECK_INSTANCE_TYPE (v_object, TYPE_AUTOSAVE_MANAGER)); -#line 13 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - g_return_if_fail (g_value_type_compatible (G_TYPE_FROM_INSTANCE (v_object), G_VALUE_TYPE (value))); -#line 13 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - value->data[0].v_pointer = v_object; -#line 2579 "autosave-manager.c" - } else { -#line 13 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - value->data[0].v_pointer = NULL; -#line 2583 "autosave-manager.c" - } -#line 13 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - if (old) { -#line 13 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - autosave_manager_unref (old); -#line 2589 "autosave-manager.c" - } -} - - -static void autosave_manager_class_init (AutosaveManagerClass * klass) { - const gchar* _tmp0_ = NULL; - gchar* _tmp1_ = NULL; - gchar* _tmp2_ = NULL; - const gchar* _tmp3_ = NULL; - const gchar* _tmp4_ = NULL; - gchar* _tmp5_ = NULL; -#line 13 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - autosave_manager_parent_class = g_type_class_peek_parent (klass); -#line 13 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - ((AutosaveManagerClass *) klass)->finalize = autosave_manager_finalize; -#line 13 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - g_type_class_add_private (klass, sizeof (AutosaveManagerPrivate)); -#line 15 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - _tmp0_ = g_get_user_cache_dir (); -#line 15 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - _tmp1_ = g_build_filename (_tmp0_, "simple-scan", "autosaves", NULL); -#line 15 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - autosave_manager_AUTOSAVE_DIR = _tmp1_; -#line 16 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - _tmp2_ = g_strdup ("autosave.book"); -#line 16 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - autosave_manager_AUTOSAVE_FILENAME = _tmp2_; -#line 17 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - _tmp3_ = autosave_manager_AUTOSAVE_DIR; -#line 17 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - _tmp4_ = autosave_manager_AUTOSAVE_FILENAME; -#line 17 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - _tmp5_ = g_build_filename (_tmp3_, _tmp4_, NULL); -#line 17 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - autosave_manager_AUTOSAVE_PATH = _tmp5_; -#line 2625 "autosave-manager.c" -} - - -static void autosave_manager_instance_init (AutosaveManager * self) { -#line 13 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - self->priv = AUTOSAVE_MANAGER_GET_PRIVATE (self); -#line 19 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - self->priv->update_timeout = (guint) 0; -#line 23 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - self->priv->book_ = NULL; -#line 13 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - self->ref_count = 1; -#line 2638 "autosave-manager.c" -} - - -static void autosave_manager_finalize (AutosaveManager* obj) { - AutosaveManager * self; -#line 13 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - self = G_TYPE_CHECK_INSTANCE_CAST (obj, TYPE_AUTOSAVE_MANAGER, AutosaveManager); -#line 13 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - g_signal_handlers_destroy (self); -#line 21 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - _g_hash_table_unref0 (self->priv->page_filenames); -#line 23 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - _book_unref0 (self->priv->book_); -#line 2652 "autosave-manager.c" -} - - -GType autosave_manager_get_type (void) { - static volatile gsize autosave_manager_type_id__volatile = 0; - if (g_once_init_enter (&autosave_manager_type_id__volatile)) { - static const GTypeValueTable g_define_type_value_table = { value_autosave_manager_init, value_autosave_manager_free_value, value_autosave_manager_copy_value, value_autosave_manager_peek_pointer, "p", value_autosave_manager_collect_value, "p", value_autosave_manager_lcopy_value }; - static const GTypeInfo g_define_type_info = { sizeof (AutosaveManagerClass), (GBaseInitFunc) NULL, (GBaseFinalizeFunc) NULL, (GClassInitFunc) autosave_manager_class_init, (GClassFinalizeFunc) NULL, NULL, sizeof (AutosaveManager), 0, (GInstanceInitFunc) autosave_manager_instance_init, &g_define_type_value_table }; - static const GTypeFundamentalInfo g_define_type_fundamental_info = { (G_TYPE_FLAG_CLASSED | G_TYPE_FLAG_INSTANTIATABLE | G_TYPE_FLAG_DERIVABLE | G_TYPE_FLAG_DEEP_DERIVABLE) }; - GType autosave_manager_type_id; - autosave_manager_type_id = g_type_register_fundamental (g_type_fundamental_next (), "AutosaveManager", &g_define_type_info, &g_define_type_fundamental_info, 0); - g_once_init_leave (&autosave_manager_type_id__volatile, autosave_manager_type_id); - } - return autosave_manager_type_id__volatile; -} - - -gpointer autosave_manager_ref (gpointer instance) { - AutosaveManager* self; - self = instance; -#line 13 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - g_atomic_int_inc (&self->ref_count); -#line 13 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - return instance; -#line 2677 "autosave-manager.c" -} - - -void autosave_manager_unref (gpointer instance) { - AutosaveManager* self; - self = instance; -#line 13 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - if (g_atomic_int_dec_and_test (&self->ref_count)) { -#line 13 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - AUTOSAVE_MANAGER_GET_CLASS (self)->finalize (self); -#line 13 "/home/bob/bzr/simple-scan/trunk/src/autosave-manager.vala" - g_type_free_instance ((GTypeInstance *) self); -#line 2690 "autosave-manager.c" - } -} - - -static void _vala_array_destroy (gpointer array, gint array_length, GDestroyNotify destroy_func) { - if ((array != NULL) && (destroy_func != NULL)) { - int i; - for (i = 0; i < array_length; i = i + 1) { - if (((gpointer*) array)[i] != NULL) { - destroy_func (((gpointer*) array)[i]); - } - } - } -} - - -static void _vala_array_free (gpointer array, gint array_length, GDestroyNotify destroy_func) { - _vala_array_destroy (array, array_length, destroy_func); - g_free (array); -} - - -static gint _vala_array_length (gpointer array) { - int length; - length = 0; - if (array) { - while (((gpointer*) array)[length]) { - length++; - } - } - return length; -} - - - diff --git a/src/book-view.c b/src/book-view.c deleted file mode 100644 index 849d86d..0000000 --- a/src/book-view.c +++ /dev/null @@ -1,3894 +0,0 @@ -/* book-view.c generated by valac 0.34.6, the Vala compiler - * generated from book-view.vala, do not modify */ - -/* - * Copyright (C) 2009-2015 Canonical Ltd. - * Author: Robert Ancell - * - * This program is free software: you can redistribute it and/or modify it under - * the terms of the GNU General Public License as published by the Free Software - * Foundation, either version 3 of the License, or (at your option) any later - * version. See http://www.gnu.org/copyleft/gpl.html the full text of the - * license. - */ -/* FIXME: When scrolling, copy existing render sideways?*/ -/* FIXME: Only render pages that change and only the part that changed*/ - -#include -#include -#include -#include -#include -#include -#include - - -#define TYPE_BOOK_VIEW (book_view_get_type ()) -#define BOOK_VIEW(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), TYPE_BOOK_VIEW, BookView)) -#define BOOK_VIEW_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST ((klass), TYPE_BOOK_VIEW, BookViewClass)) -#define IS_BOOK_VIEW(obj) (G_TYPE_CHECK_INSTANCE_TYPE ((obj), TYPE_BOOK_VIEW)) -#define IS_BOOK_VIEW_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE ((klass), TYPE_BOOK_VIEW)) -#define BOOK_VIEW_GET_CLASS(obj) (G_TYPE_INSTANCE_GET_CLASS ((obj), TYPE_BOOK_VIEW, BookViewClass)) - -typedef struct _BookView BookView; -typedef struct _BookViewClass BookViewClass; -typedef struct _BookViewPrivate BookViewPrivate; - -#define TYPE_BOOK (book_get_type ()) -#define BOOK(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), TYPE_BOOK, Book)) -#define BOOK_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST ((klass), TYPE_BOOK, BookClass)) -#define IS_BOOK(obj) (G_TYPE_CHECK_INSTANCE_TYPE ((obj), TYPE_BOOK)) -#define IS_BOOK_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE ((klass), TYPE_BOOK)) -#define BOOK_GET_CLASS(obj) (G_TYPE_INSTANCE_GET_CLASS ((obj), TYPE_BOOK, BookClass)) - -typedef struct _Book Book; -typedef struct _BookClass BookClass; - -#define TYPE_PAGE (page_get_type ()) -#define PAGE(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), TYPE_PAGE, Page)) -#define PAGE_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST ((klass), TYPE_PAGE, PageClass)) -#define IS_PAGE(obj) (G_TYPE_CHECK_INSTANCE_TYPE ((obj), TYPE_PAGE)) -#define IS_PAGE_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE ((klass), TYPE_PAGE)) -#define PAGE_GET_CLASS(obj) (G_TYPE_INSTANCE_GET_CLASS ((obj), TYPE_PAGE, PageClass)) - -typedef struct _Page Page; -typedef struct _PageClass PageClass; - -#define TYPE_PAGE_VIEW (page_view_get_type ()) -#define PAGE_VIEW(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), TYPE_PAGE_VIEW, PageView)) -#define PAGE_VIEW_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST ((klass), TYPE_PAGE_VIEW, PageViewClass)) -#define IS_PAGE_VIEW(obj) (G_TYPE_CHECK_INSTANCE_TYPE ((obj), TYPE_PAGE_VIEW)) -#define IS_PAGE_VIEW_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE ((klass), TYPE_PAGE_VIEW)) -#define PAGE_VIEW_GET_CLASS(obj) (G_TYPE_INSTANCE_GET_CLASS ((obj), TYPE_PAGE_VIEW, PageViewClass)) - -typedef struct _PageView PageView; -typedef struct _PageViewClass PageViewClass; -#define _book_unref0(var) ((var == NULL) ? NULL : (var = (book_unref (var), NULL))) -#define _g_hash_table_unref0(var) ((var == NULL) ? NULL : (var = (g_hash_table_unref (var), NULL))) -#define _page_view_unref0(var) ((var == NULL) ? NULL : (var = (page_view_unref (var), NULL))) -#define _g_object_unref0(var) ((var == NULL) ? NULL : (var = (g_object_unref (var), NULL))) -#define _page_unref0(var) ((var == NULL) ? NULL : (var = (page_unref (var), NULL))) - -struct _BookView { - GtkBox parent_instance; - BookViewPrivate * priv; -}; - -struct _BookViewClass { - GtkBoxClass parent_class; -}; - -struct _BookViewPrivate { - Book* _book; - GHashTable* page_data; - gboolean need_layout; - gboolean laying_out; - gboolean show_selected_page; - PageView* selected_page_view; - GtkWidget* drawing_area; - GtkScrollbar* scroll; - GtkAdjustment* adjustment; - GdkCursorType cursor; -}; - - -static gpointer book_view_parent_class = NULL; - -GType book_view_get_type (void) G_GNUC_CONST; -gpointer book_ref (gpointer instance); -void book_unref (gpointer instance); -GParamSpec* param_spec_book (const gchar* name, const gchar* nick, const gchar* blurb, GType object_type, GParamFlags flags); -void value_set_book (GValue* value, gpointer v_object); -void value_take_book (GValue* value, gpointer v_object); -gpointer value_get_book (const GValue* value); -GType book_get_type (void) G_GNUC_CONST; -gpointer page_ref (gpointer instance); -void page_unref (gpointer instance); -GParamSpec* param_spec_page (const gchar* name, const gchar* nick, const gchar* blurb, GType object_type, GParamFlags flags); -void value_set_page (GValue* value, gpointer v_object); -void value_take_page (GValue* value, gpointer v_object); -gpointer value_get_page (const GValue* value); -GType page_get_type (void) G_GNUC_CONST; -gpointer page_view_ref (gpointer instance); -void page_view_unref (gpointer instance); -GParamSpec* param_spec_page_view (const gchar* name, const gchar* nick, const gchar* blurb, GType object_type, GParamFlags flags); -void value_set_page_view (GValue* value, gpointer v_object); -void value_take_page_view (GValue* value, gpointer v_object); -gpointer value_get_page_view (const GValue* value); -GType page_view_get_type (void) G_GNUC_CONST; -#define BOOK_VIEW_GET_PRIVATE(o) (G_TYPE_INSTANCE_GET_PRIVATE ((o), TYPE_BOOK_VIEW, BookViewPrivate)) -enum { - BOOK_VIEW_DUMMY_PROPERTY, - BOOK_VIEW_BOOK, - BOOK_VIEW_SELECTED_PAGE, - BOOK_VIEW_X_OFFSET -}; -Book* book_view_get_book (BookView* self); -static void book_view_add_cb (BookView* self, Book* book, Page* page); -static void _book_view_add_cb_book_page_added (Book* _sender, Page* page, gpointer self); -static void book_view_remove_cb (BookView* self, Book* book, Page* page); -static void _book_view_remove_cb_book_page_removed (Book* _sender, Page* page, gpointer self); -static void book_view_reorder_cb (BookView* self, Book* book); -static void _book_view_reorder_cb_book_reordered (Book* _sender, gpointer self); -static void book_view_clear_cb (BookView* self, Book* book); -static void _book_view_clear_cb_book_cleared (Book* _sender, gpointer self); -static gboolean book_view_configure_cb (BookView* self, GtkWidget* widget, GdkEventConfigure* event); -static gboolean _book_view_configure_cb_gtk_widget_configure_event (GtkWidget* _sender, GdkEventConfigure* event, gpointer self); -static gboolean book_view_draw_cb (BookView* self, GtkWidget* widget, cairo_t* context); -static gboolean _book_view_draw_cb_gtk_widget_draw (GtkWidget* _sender, cairo_t* cr, gpointer self); -static gboolean book_view_motion_cb (BookView* self, GtkWidget* widget, GdkEventMotion* event); -static gboolean _book_view_motion_cb_gtk_widget_motion_notify_event (GtkWidget* _sender, GdkEventMotion* event, gpointer self); -static gboolean book_view_key_cb (BookView* self, GtkWidget* widget, GdkEventKey* event); -static gboolean _book_view_key_cb_gtk_widget_key_press_event (GtkWidget* _sender, GdkEventKey* event, gpointer self); -static gboolean book_view_button_cb (BookView* self, GtkWidget* widget, GdkEventButton* event); -static gboolean _book_view_button_cb_gtk_widget_button_press_event (GtkWidget* _sender, GdkEventButton* event, gpointer self); -static gboolean _book_view_button_cb_gtk_widget_button_release_event (GtkWidget* _sender, GdkEventButton* event, gpointer self); -static gboolean book_view_focus_cb (BookView* self, GtkWidget* widget, GdkEventFocus* event); -static gboolean _book_view_focus_cb_gtk_widget_focus_in_event (GtkWidget* _sender, GdkEventFocus* event, gpointer self); -static gboolean _book_view_focus_cb_gtk_widget_focus_out_event (GtkWidget* _sender, GdkEventFocus* event, gpointer self); -static void book_view_scroll_cb (BookView* self, GtkAdjustment* adjustment); -static void _book_view_scroll_cb_gtk_adjustment_value_changed (GtkAdjustment* _sender, gpointer self); -BookView* book_view_new (Book* book); -BookView* book_view_construct (GType object_type, Book* book); -static void book_view_set_book (BookView* self, Book* value); -guint book_get_n_pages (Book* self); -Page* book_get_page (Book* self, gint page_number); -void book_view_set_selected_page (BookView* self, Page* value); -static void _page_unref0_ (gpointer var); -static void _page_view_unref0_ (gpointer var); -static PageView* book_view_get_nth_page (BookView* self, gint n); -static PageView* book_view_get_next_page (BookView* self, PageView* page); -Page* page_view_get_page (PageView* self); -static PageView* book_view_get_prev_page (BookView* self, PageView* page); -static void book_view_page_view_changed_cb (BookView* self, PageView* page); -void book_view_redraw (BookView* self); -static void book_view_page_view_size_changed_cb (BookView* self, PageView* page); -PageView* page_view_new (Page* page); -PageView* page_view_construct (GType object_type, Page* page); -static void _book_view_page_view_changed_cb_page_view_changed (PageView* _sender, gpointer self); -static void _book_view_page_view_size_changed_cb_page_view_size_changed (PageView* _sender, gpointer self); -static void book_view_set_selected_page_view (BookView* self, PageView* page); -void page_view_set_selected (PageView* self, gboolean value); -static void book_view_show_page_view (BookView* self, PageView* page); -gint page_view_get_x_offset (PageView* self); -gint page_view_get_width (PageView* self); -gint book_view_get_x_offset (BookView* self); -void book_view_set_x_offset (BookView* self, gint value); -static void book_view_select_page_view (BookView* self, PageView* page); -Page* book_view_get_selected_page (BookView* self); -static void book_view_layout_into (BookView* self, gint width, gint height, gint* book_width, gint* book_height); -gint page_get_dpi (Page* self); -gint page_get_width (Page* self); -gint page_get_height (Page* self); -void page_view_set_width (PageView* self, gint value); -void page_view_set_height (PageView* self, gint value); -gint page_view_get_height (PageView* self); -void page_view_set_x_offset (PageView* self, gint value); -void page_view_set_y_offset (PageView* self, gint value); -static void book_view_layout (BookView* self); -void page_view_render (PageView* self, cairo_t* context); -gboolean page_view_get_selected (PageView* self); -gint page_view_get_y_offset (PageView* self); -static PageView* book_view_get_page_at (BookView* self, gint x, gint y, gint* x_, gint* y_); -void page_view_button_press (PageView* self, gint x, gint y); -void page_view_button_release (PageView* self, gint x, gint y); -static void book_view_set_cursor (BookView* self, GdkCursorType cursor); -void page_view_motion (PageView* self, gint x, gint y); -GdkCursorType page_view_get_cursor (PageView* self); -void book_view_select_next_page (BookView* self); -void book_view_select_prev_page (BookView* self); -static void g_cclosure_user_marshal_VOID__PAGE (GClosure * closure, GValue * return_value, guint n_param_values, const GValue * param_values, gpointer invocation_hint, gpointer marshal_data); -static void book_view_finalize (GObject* obj); -static void _vala_book_view_get_property (GObject * object, guint property_id, GValue * value, GParamSpec * pspec); -static void _vala_book_view_set_property (GObject * object, guint property_id, const GValue * value, GParamSpec * pspec); - - -static void _book_view_add_cb_book_page_added (Book* _sender, Page* page, gpointer self) { -#line 123 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - book_view_add_cb ((BookView*) self, _sender, page); -#line 210 "book-view.c" -} - - -static void _book_view_remove_cb_book_page_removed (Book* _sender, Page* page, gpointer self) { -#line 124 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - book_view_remove_cb ((BookView*) self, _sender, page); -#line 217 "book-view.c" -} - - -static void _book_view_reorder_cb_book_reordered (Book* _sender, gpointer self) { -#line 125 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - book_view_reorder_cb ((BookView*) self, _sender); -#line 224 "book-view.c" -} - - -static void _book_view_clear_cb_book_cleared (Book* _sender, gpointer self) { -#line 126 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - book_view_clear_cb ((BookView*) self, _sender); -#line 231 "book-view.c" -} - - -static gboolean _book_view_configure_cb_gtk_widget_configure_event (GtkWidget* _sender, GdkEventConfigure* event, gpointer self) { - gboolean result; - result = book_view_configure_cb ((BookView*) self, _sender, event); -#line 127 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - return result; -#line 240 "book-view.c" -} - - -static gboolean _book_view_draw_cb_gtk_widget_draw (GtkWidget* _sender, cairo_t* cr, gpointer self) { - gboolean result; - result = book_view_draw_cb ((BookView*) self, _sender, cr); -#line 128 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - return result; -#line 249 "book-view.c" -} - - -static gboolean _book_view_motion_cb_gtk_widget_motion_notify_event (GtkWidget* _sender, GdkEventMotion* event, gpointer self) { - gboolean result; - result = book_view_motion_cb ((BookView*) self, _sender, event); -#line 129 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - return result; -#line 258 "book-view.c" -} - - -static gboolean _book_view_key_cb_gtk_widget_key_press_event (GtkWidget* _sender, GdkEventKey* event, gpointer self) { - gboolean result; - result = book_view_key_cb ((BookView*) self, _sender, event); -#line 130 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - return result; -#line 267 "book-view.c" -} - - -static gboolean _book_view_button_cb_gtk_widget_button_press_event (GtkWidget* _sender, GdkEventButton* event, gpointer self) { - gboolean result; - result = book_view_button_cb ((BookView*) self, _sender, event); -#line 131 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - return result; -#line 276 "book-view.c" -} - - -static gboolean _book_view_button_cb_gtk_widget_button_release_event (GtkWidget* _sender, GdkEventButton* event, gpointer self) { - gboolean result; - result = book_view_button_cb ((BookView*) self, _sender, event); -#line 132 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - return result; -#line 285 "book-view.c" -} - - -static gboolean _book_view_focus_cb_gtk_widget_focus_in_event (GtkWidget* _sender, GdkEventFocus* event, gpointer self) { - gboolean result; - result = book_view_focus_cb ((BookView*) self, _sender, event); -#line 133 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - return result; -#line 294 "book-view.c" -} - - -static gboolean _book_view_focus_cb_gtk_widget_focus_out_event (GtkWidget* _sender, GdkEventFocus* event, gpointer self) { - gboolean result; - result = book_view_focus_cb ((BookView*) self, _sender, event); -#line 134 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - return result; -#line 303 "book-view.c" -} - - -static void _book_view_scroll_cb_gtk_adjustment_value_changed (GtkAdjustment* _sender, gpointer self) { -#line 135 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - book_view_scroll_cb ((BookView*) self, _sender); -#line 310 "book-view.c" -} - - -static void _page_unref0_ (gpointer var) { -#line 95 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - (var == NULL) ? NULL : (var = (page_unref (var), NULL)); -#line 317 "book-view.c" -} - - -static void _page_view_unref0_ (gpointer var) { -#line 95 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - (var == NULL) ? NULL : (var = (page_view_unref (var), NULL)); -#line 324 "book-view.c" -} - - -static gpointer _g_object_ref0 (gpointer self) { -#line 105 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - return self ? g_object_ref (self) : NULL; -#line 331 "book-view.c" -} - - -BookView* book_view_construct (GType object_type, Book* book) { - BookView * self = NULL; - Book* _tmp0_ = NULL; - Book* _tmp12_ = NULL; - Page* _tmp13_ = NULL; - Page* _tmp14_ = NULL; - Book* _tmp15_ = NULL; - Book* _tmp16_ = NULL; - Book* _tmp17_ = NULL; - Book* _tmp18_ = NULL; - GHashFunc _tmp19_ = NULL; - GEqualFunc _tmp20_ = NULL; - GHashTable* _tmp21_ = NULL; - GtkDrawingArea* _tmp22_ = NULL; - GtkWidget* _tmp23_ = NULL; - GtkWidget* _tmp24_ = NULL; - GtkWidget* _tmp25_ = NULL; - GtkWidget* _tmp26_ = NULL; - GtkScrollbar* _tmp27_ = NULL; - GtkScrollbar* _tmp28_ = NULL; - GtkAdjustment* _tmp29_ = NULL; - GtkAdjustment* _tmp30_ = NULL; - GtkAdjustment* _tmp31_ = NULL; - GtkScrollbar* _tmp32_ = NULL; - GtkWidget* _tmp33_ = NULL; - GtkWidget* _tmp34_ = NULL; - GtkWidget* _tmp35_ = NULL; - GtkWidget* _tmp36_ = NULL; - GtkWidget* _tmp37_ = NULL; - GtkWidget* _tmp38_ = NULL; - GtkWidget* _tmp39_ = NULL; - GtkWidget* _tmp40_ = NULL; - GtkAdjustment* _tmp41_ = NULL; - GtkWidget* _tmp42_ = NULL; -#line 74 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - g_return_val_if_fail (book != NULL, NULL); -#line 76 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - self = (BookView*) g_object_new (object_type, "orientation", GTK_ORIENTATION_VERTICAL, NULL); -#line 77 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp0_ = book; -#line 77 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - book_view_set_book (self, _tmp0_); -#line 377 "book-view.c" - { - gint i = 0; -#line 80 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - i = 0; -#line 382 "book-view.c" - { - gboolean _tmp1_ = FALSE; -#line 80 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp1_ = TRUE; -#line 80 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - while (TRUE) { -#line 389 "book-view.c" - gint _tmp3_ = 0; - Book* _tmp4_ = NULL; - guint _tmp5_ = 0U; - guint _tmp6_ = 0U; - Page* page = NULL; - Book* _tmp7_ = NULL; - gint _tmp8_ = 0; - Page* _tmp9_ = NULL; - Book* _tmp10_ = NULL; - Page* _tmp11_ = NULL; -#line 80 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - if (!_tmp1_) { -#line 402 "book-view.c" - gint _tmp2_ = 0; -#line 80 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp2_ = i; -#line 80 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - i = _tmp2_ + 1; -#line 408 "book-view.c" - } -#line 80 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp1_ = FALSE; -#line 80 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp3_ = i; -#line 80 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp4_ = book; -#line 80 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp5_ = book_get_n_pages (_tmp4_); -#line 80 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp6_ = _tmp5_; -#line 80 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - if (!(((guint) _tmp3_) < _tmp6_)) { -#line 80 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - break; -#line 424 "book-view.c" - } -#line 82 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp7_ = book; -#line 82 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp8_ = i; -#line 82 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp9_ = book_get_page (_tmp7_, _tmp8_); -#line 82 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - page = _tmp9_; -#line 83 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp10_ = book; -#line 83 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp11_ = page; -#line 83 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - book_view_add_cb (self, _tmp10_, _tmp11_); -#line 80 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _page_unref0 (page); -#line 442 "book-view.c" - } - } - } -#line 86 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp12_ = book; -#line 86 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp13_ = book_get_page (_tmp12_, 0); -#line 86 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp14_ = _tmp13_; -#line 86 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - book_view_set_selected_page (self, _tmp14_); -#line 86 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _page_unref0 (_tmp14_); -#line 89 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp15_ = book; -#line 89 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - g_signal_connect_object (_tmp15_, "page-added", (GCallback) _book_view_add_cb_book_page_added, self, 0); -#line 90 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp16_ = book; -#line 90 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - g_signal_connect_object (_tmp16_, "page-removed", (GCallback) _book_view_remove_cb_book_page_removed, self, 0); -#line 91 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp17_ = book; -#line 91 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - g_signal_connect_object (_tmp17_, "reordered", (GCallback) _book_view_reorder_cb_book_reordered, self, 0); -#line 92 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp18_ = book; -#line 92 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - g_signal_connect_object (_tmp18_, "cleared", (GCallback) _book_view_clear_cb_book_cleared, self, 0); -#line 94 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - self->priv->need_layout = TRUE; -#line 95 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp19_ = g_direct_hash; -#line 95 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp20_ = g_direct_equal; -#line 95 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp21_ = g_hash_table_new_full (_tmp19_, _tmp20_, _page_unref0_, _page_view_unref0_); -#line 95 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _g_hash_table_unref0 (self->priv->page_data); -#line 95 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - self->priv->page_data = _tmp21_; -#line 96 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - self->priv->cursor = GDK_ARROW; -#line 98 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp22_ = (GtkDrawingArea*) gtk_drawing_area_new (); -#line 98 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - g_object_ref_sink (_tmp22_); -#line 98 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _g_object_unref0 (self->priv->drawing_area); -#line 98 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - self->priv->drawing_area = (GtkWidget*) _tmp22_; -#line 99 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp23_ = self->priv->drawing_area; -#line 99 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - gtk_widget_set_size_request (_tmp23_, 200, 100); -#line 100 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp24_ = self->priv->drawing_area; -#line 100 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - g_object_set (_tmp24_, "can-focus", TRUE, NULL); -#line 101 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp25_ = self->priv->drawing_area; -#line 101 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - gtk_widget_set_events (_tmp25_, ((((GDK_POINTER_MOTION_MASK | GDK_BUTTON_PRESS_MASK) | GDK_BUTTON_RELEASE_MASK) | GDK_FOCUS_CHANGE_MASK) | GDK_STRUCTURE_MASK) | GDK_SCROLL_MASK); -#line 102 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp26_ = self->priv->drawing_area; -#line 102 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - gtk_box_pack_start ((GtkBox*) self, _tmp26_, TRUE, TRUE, (guint) 0); -#line 104 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp27_ = (GtkScrollbar*) gtk_scrollbar_new (GTK_ORIENTATION_HORIZONTAL, NULL); -#line 104 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - g_object_ref_sink (_tmp27_); -#line 104 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _g_object_unref0 (self->priv->scroll); -#line 104 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - self->priv->scroll = _tmp27_; -#line 105 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp28_ = self->priv->scroll; -#line 105 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp29_ = gtk_range_get_adjustment ((GtkRange*) _tmp28_); -#line 105 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp30_ = _tmp29_; -#line 105 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp31_ = _g_object_ref0 (_tmp30_); -#line 105 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _g_object_unref0 (self->priv->adjustment); -#line 105 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - self->priv->adjustment = _tmp31_; -#line 106 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp32_ = self->priv->scroll; -#line 106 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - gtk_box_pack_start ((GtkBox*) self, (GtkWidget*) _tmp32_, FALSE, TRUE, (guint) 0); -#line 108 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp33_ = self->priv->drawing_area; -#line 108 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - g_signal_connect_object (_tmp33_, "configure-event", (GCallback) _book_view_configure_cb_gtk_widget_configure_event, self, 0); -#line 109 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp34_ = self->priv->drawing_area; -#line 109 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - g_signal_connect_object (_tmp34_, "draw", (GCallback) _book_view_draw_cb_gtk_widget_draw, self, 0); -#line 110 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp35_ = self->priv->drawing_area; -#line 110 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - g_signal_connect_object (_tmp35_, "motion-notify-event", (GCallback) _book_view_motion_cb_gtk_widget_motion_notify_event, self, 0); -#line 111 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp36_ = self->priv->drawing_area; -#line 111 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - g_signal_connect_object (_tmp36_, "key-press-event", (GCallback) _book_view_key_cb_gtk_widget_key_press_event, self, 0); -#line 112 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp37_ = self->priv->drawing_area; -#line 112 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - g_signal_connect_object (_tmp37_, "button-press-event", (GCallback) _book_view_button_cb_gtk_widget_button_press_event, self, 0); -#line 113 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp38_ = self->priv->drawing_area; -#line 113 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - g_signal_connect_object (_tmp38_, "button-release-event", (GCallback) _book_view_button_cb_gtk_widget_button_release_event, self, 0); -#line 114 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp39_ = self->priv->drawing_area; -#line 114 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - g_signal_connect_object (_tmp39_, "focus-in-event", (GCallback) _book_view_focus_cb_gtk_widget_focus_in_event, self, G_CONNECT_AFTER); -#line 115 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp40_ = self->priv->drawing_area; -#line 115 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - g_signal_connect_object (_tmp40_, "focus-out-event", (GCallback) _book_view_focus_cb_gtk_widget_focus_out_event, self, G_CONNECT_AFTER); -#line 116 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp41_ = self->priv->adjustment; -#line 116 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - g_signal_connect_object (_tmp41_, "value-changed", (GCallback) _book_view_scroll_cb_gtk_adjustment_value_changed, self, 0); -#line 118 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp42_ = self->priv->drawing_area; -#line 118 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - gtk_widget_set_visible (_tmp42_, TRUE); -#line 74 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - return self; -#line 576 "book-view.c" -} - - -BookView* book_view_new (Book* book) { -#line 74 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - return book_view_construct (TYPE_BOOK_VIEW, book); -#line 583 "book-view.c" -} - - -static gpointer _page_view_ref0 (gpointer self) { -#line 141 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - return self ? page_view_ref (self) : NULL; -#line 590 "book-view.c" -} - - -static PageView* book_view_get_nth_page (BookView* self, gint n) { - PageView* result = NULL; - Page* page = NULL; - Book* _tmp0_ = NULL; - gint _tmp1_ = 0; - Page* _tmp2_ = NULL; - GHashTable* _tmp3_ = NULL; - gconstpointer _tmp4_ = NULL; - PageView* _tmp5_ = NULL; -#line 138 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - g_return_val_if_fail (self != NULL, NULL); -#line 140 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp0_ = self->priv->_book; -#line 140 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp1_ = n; -#line 140 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp2_ = book_get_page (_tmp0_, _tmp1_); -#line 140 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - page = _tmp2_; -#line 141 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp3_ = self->priv->page_data; -#line 141 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp4_ = g_hash_table_lookup (_tmp3_, page); -#line 141 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp5_ = _page_view_ref0 ((PageView*) _tmp4_); -#line 141 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - result = _tmp5_; -#line 141 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _page_unref0 (page); -#line 141 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - return result; -#line 625 "book-view.c" -} - - -static PageView* book_view_get_next_page (BookView* self, PageView* page) { - PageView* result = NULL; - PageView* _tmp18_ = NULL; - PageView* _tmp19_ = NULL; -#line 144 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - g_return_val_if_fail (self != NULL, NULL); -#line 144 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - g_return_val_if_fail (page != NULL, NULL); -#line 637 "book-view.c" - { - gint i = 0; -#line 146 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - i = 0; -#line 642 "book-view.c" - { - gboolean _tmp0_ = FALSE; -#line 146 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp0_ = TRUE; -#line 146 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - while (TRUE) { -#line 649 "book-view.c" - Page* p = NULL; - Book* _tmp2_ = NULL; - gint _tmp3_ = 0; - Page* _tmp4_ = NULL; - Page* _tmp5_ = NULL; - Page* _tmp6_ = NULL; - PageView* _tmp7_ = NULL; - Page* _tmp8_ = NULL; - Page* _tmp9_ = NULL; -#line 146 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - if (!_tmp0_) { -#line 661 "book-view.c" - gint _tmp1_ = 0; -#line 146 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp1_ = i; -#line 146 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - i = _tmp1_ + 1; -#line 667 "book-view.c" - } -#line 146 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp0_ = FALSE; -#line 148 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp2_ = self->priv->_book; -#line 148 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp3_ = i; -#line 148 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp4_ = book_get_page (_tmp2_, _tmp3_); -#line 148 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - p = _tmp4_; -#line 149 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp5_ = p; -#line 149 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - if (_tmp5_ == NULL) { -#line 150 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _page_unref0 (p); -#line 150 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - break; -#line 687 "book-view.c" - } -#line 151 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp6_ = p; -#line 151 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp7_ = page; -#line 151 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp8_ = page_view_get_page (_tmp7_); -#line 151 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp9_ = _tmp8_; -#line 151 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - if (_tmp6_ == _tmp9_) { -#line 699 "book-view.c" - Book* _tmp10_ = NULL; - gint _tmp11_ = 0; - Page* _tmp12_ = NULL; - Page* _tmp13_ = NULL; -#line 153 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp10_ = self->priv->_book; -#line 153 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp11_ = i; -#line 153 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp12_ = book_get_page (_tmp10_, _tmp11_ + 1); -#line 153 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _page_unref0 (p); -#line 153 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - p = _tmp12_; -#line 154 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp13_ = p; -#line 154 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - if (_tmp13_ != NULL) { -#line 718 "book-view.c" - GHashTable* _tmp14_ = NULL; - Page* _tmp15_ = NULL; - gconstpointer _tmp16_ = NULL; - PageView* _tmp17_ = NULL; -#line 155 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp14_ = self->priv->page_data; -#line 155 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp15_ = p; -#line 155 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp16_ = g_hash_table_lookup (_tmp14_, _tmp15_); -#line 155 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp17_ = _page_view_ref0 ((PageView*) _tmp16_); -#line 155 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - result = _tmp17_; -#line 155 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _page_unref0 (p); -#line 155 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - return result; -#line 737 "book-view.c" - } - } -#line 146 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _page_unref0 (p); -#line 742 "book-view.c" - } - } - } -#line 159 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp18_ = page; -#line 159 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp19_ = _page_view_ref0 (_tmp18_); -#line 159 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - result = _tmp19_; -#line 159 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - return result; -#line 754 "book-view.c" -} - - -static PageView* book_view_get_prev_page (BookView* self, PageView* page) { - PageView* result = NULL; - PageView* prev_page = NULL; - PageView* _tmp0_ = NULL; - PageView* _tmp1_ = NULL; - PageView* _tmp16_ = NULL; - PageView* _tmp17_ = NULL; -#line 162 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - g_return_val_if_fail (self != NULL, NULL); -#line 162 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - g_return_val_if_fail (page != NULL, NULL); -#line 164 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp0_ = page; -#line 164 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp1_ = _page_view_ref0 (_tmp0_); -#line 164 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - prev_page = _tmp1_; -#line 775 "book-view.c" - { - gint i = 0; -#line 165 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - i = 0; -#line 780 "book-view.c" - { - gboolean _tmp2_ = FALSE; -#line 165 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp2_ = TRUE; -#line 165 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - while (TRUE) { -#line 787 "book-view.c" - Page* p = NULL; - Book* _tmp4_ = NULL; - gint _tmp5_ = 0; - Page* _tmp6_ = NULL; - Page* _tmp7_ = NULL; - Page* _tmp8_ = NULL; - PageView* _tmp9_ = NULL; - Page* _tmp10_ = NULL; - Page* _tmp11_ = NULL; - GHashTable* _tmp12_ = NULL; - Page* _tmp13_ = NULL; - gconstpointer _tmp14_ = NULL; - PageView* _tmp15_ = NULL; -#line 165 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - if (!_tmp2_) { -#line 803 "book-view.c" - gint _tmp3_ = 0; -#line 165 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp3_ = i; -#line 165 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - i = _tmp3_ + 1; -#line 809 "book-view.c" - } -#line 165 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp2_ = FALSE; -#line 167 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp4_ = self->priv->_book; -#line 167 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp5_ = i; -#line 167 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp6_ = book_get_page (_tmp4_, _tmp5_); -#line 167 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - p = _tmp6_; -#line 168 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp7_ = p; -#line 168 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - if (_tmp7_ == NULL) { -#line 169 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _page_unref0 (p); -#line 169 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - break; -#line 829 "book-view.c" - } -#line 170 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp8_ = p; -#line 170 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp9_ = page; -#line 170 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp10_ = page_view_get_page (_tmp9_); -#line 170 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp11_ = _tmp10_; -#line 170 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - if (_tmp8_ == _tmp11_) { -#line 171 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - result = prev_page; -#line 171 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _page_unref0 (p); -#line 171 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - return result; -#line 847 "book-view.c" - } -#line 172 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp12_ = self->priv->page_data; -#line 172 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp13_ = p; -#line 172 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp14_ = g_hash_table_lookup (_tmp12_, _tmp13_); -#line 172 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp15_ = _page_view_ref0 ((PageView*) _tmp14_); -#line 172 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _page_view_unref0 (prev_page); -#line 172 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - prev_page = _tmp15_; -#line 165 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _page_unref0 (p); -#line 863 "book-view.c" - } - } - } -#line 175 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp16_ = page; -#line 175 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp17_ = _page_view_ref0 (_tmp16_); -#line 175 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - result = _tmp17_; -#line 175 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _page_view_unref0 (prev_page); -#line 175 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - return result; -#line 877 "book-view.c" -} - - -static void book_view_page_view_changed_cb (BookView* self, PageView* page) { -#line 178 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - g_return_if_fail (self != NULL); -#line 178 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - g_return_if_fail (page != NULL); -#line 180 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - book_view_redraw (self); -#line 888 "book-view.c" -} - - -static void book_view_page_view_size_changed_cb (BookView* self, PageView* page) { -#line 183 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - g_return_if_fail (self != NULL); -#line 183 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - g_return_if_fail (page != NULL); -#line 185 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - self->priv->need_layout = TRUE; -#line 186 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - book_view_redraw (self); -#line 901 "book-view.c" -} - - -static void _book_view_page_view_changed_cb_page_view_changed (PageView* _sender, gpointer self) { -#line 192 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - book_view_page_view_changed_cb ((BookView*) self, _sender); -#line 908 "book-view.c" -} - - -static void _book_view_page_view_size_changed_cb_page_view_size_changed (PageView* _sender, gpointer self) { -#line 193 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - book_view_page_view_size_changed_cb ((BookView*) self, _sender); -#line 915 "book-view.c" -} - - -static gpointer _page_ref0 (gpointer self) { -#line 194 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - return self ? page_ref (self) : NULL; -#line 922 "book-view.c" -} - - -static void book_view_add_cb (BookView* self, Book* book, Page* page) { - PageView* page_view = NULL; - Page* _tmp0_ = NULL; - PageView* _tmp1_ = NULL; - GHashTable* _tmp2_ = NULL; - Page* _tmp3_ = NULL; - Page* _tmp4_ = NULL; - PageView* _tmp5_ = NULL; -#line 189 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - g_return_if_fail (self != NULL); -#line 189 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - g_return_if_fail (book != NULL); -#line 189 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - g_return_if_fail (page != NULL); -#line 191 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp0_ = page; -#line 191 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp1_ = page_view_new (_tmp0_); -#line 191 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - page_view = _tmp1_; -#line 192 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - g_signal_connect_object (page_view, "changed", (GCallback) _book_view_page_view_changed_cb_page_view_changed, self, 0); -#line 193 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - g_signal_connect_object (page_view, "size-changed", (GCallback) _book_view_page_view_size_changed_cb_page_view_size_changed, self, 0); -#line 194 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp2_ = self->priv->page_data; -#line 194 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp3_ = page; -#line 194 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp4_ = _page_ref0 (_tmp3_); -#line 194 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp5_ = _page_view_ref0 (page_view); -#line 194 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - g_hash_table_insert (_tmp2_, _tmp4_, _tmp5_); -#line 195 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - self->priv->need_layout = TRUE; -#line 196 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - book_view_redraw (self); -#line 189 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _page_view_unref0 (page_view); -#line 966 "book-view.c" -} - - -static void book_view_set_selected_page_view (BookView* self, PageView* page) { - gboolean _tmp0_ = FALSE; - PageView* _tmp1_ = NULL; - PageView* _tmp5_ = NULL; - PageView* _tmp6_ = NULL; - PageView* _tmp7_ = NULL; - GtkWidget* _tmp8_ = NULL; - gboolean _tmp9_ = FALSE; - gboolean _tmp10_ = FALSE; -#line 199 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - g_return_if_fail (self != NULL); -#line 202 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp1_ = self->priv->selected_page_view; -#line 202 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - if (_tmp1_ != NULL) { -#line 985 "book-view.c" - PageView* _tmp2_ = NULL; - PageView* _tmp3_ = NULL; -#line 202 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp2_ = page; -#line 202 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp3_ = self->priv->selected_page_view; -#line 202 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp0_ = _tmp2_ != _tmp3_; -#line 994 "book-view.c" - } else { -#line 202 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp0_ = FALSE; -#line 998 "book-view.c" - } -#line 202 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - if (_tmp0_) { -#line 1002 "book-view.c" - PageView* _tmp4_ = NULL; -#line 203 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp4_ = self->priv->selected_page_view; -#line 203 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - page_view_set_selected (_tmp4_, TRUE); -#line 1008 "book-view.c" - } -#line 205 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp5_ = page; -#line 205 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp6_ = _page_view_ref0 (_tmp5_); -#line 205 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _page_view_unref0 (self->priv->selected_page_view); -#line 205 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - self->priv->selected_page_view = _tmp6_; -#line 206 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp7_ = self->priv->selected_page_view; -#line 206 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - if (_tmp7_ == NULL) { -#line 207 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - return; -#line 1024 "book-view.c" - } -#line 210 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp8_ = self->priv->drawing_area; -#line 210 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - g_object_get (_tmp8_, "has-focus", &_tmp9_, NULL); -#line 210 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp10_ = _tmp9_; -#line 210 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - if (!_tmp10_) { -#line 1034 "book-view.c" - PageView* _tmp11_ = NULL; -#line 211 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp11_ = self->priv->selected_page_view; -#line 211 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - page_view_set_selected (_tmp11_, FALSE); -#line 1040 "book-view.c" - } else { - PageView* _tmp12_ = NULL; -#line 213 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp12_ = self->priv->selected_page_view; -#line 213 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - page_view_set_selected (_tmp12_, TRUE); -#line 1047 "book-view.c" - } -} - - -static void book_view_show_page_view (BookView* self, PageView* page) { - gboolean _tmp0_ = FALSE; - PageView* _tmp1_ = NULL; - GtkAllocation allocation = {0}; - GtkWidget* _tmp4_ = NULL; - GtkAllocation _tmp5_ = {0}; - gint left_edge = 0; - PageView* _tmp6_ = NULL; - gint _tmp7_ = 0; - gint _tmp8_ = 0; - gint right_edge = 0; - PageView* _tmp9_ = NULL; - gint _tmp10_ = 0; - gint _tmp11_ = 0; - PageView* _tmp12_ = NULL; - gint _tmp13_ = 0; - gint _tmp14_ = 0; - gint _tmp15_ = 0; - gint _tmp16_ = 0; - gint _tmp17_ = 0; -#line 216 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - g_return_if_fail (self != NULL); -#line 218 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp1_ = page; -#line 218 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - if (_tmp1_ == NULL) { -#line 218 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp0_ = TRUE; -#line 1080 "book-view.c" - } else { - GtkScrollbar* _tmp2_ = NULL; - gboolean _tmp3_ = FALSE; -#line 218 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp2_ = self->priv->scroll; -#line 218 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp3_ = gtk_widget_get_visible ((GtkWidget*) _tmp2_); -#line 218 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp0_ = !_tmp3_; -#line 1090 "book-view.c" - } -#line 218 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - if (_tmp0_) { -#line 219 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - return; -#line 1096 "book-view.c" - } -#line 222 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp4_ = self->priv->drawing_area; -#line 222 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - gtk_widget_get_allocation (_tmp4_, &_tmp5_); -#line 222 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - allocation = _tmp5_; -#line 223 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp6_ = page; -#line 223 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp7_ = page_view_get_x_offset (_tmp6_); -#line 223 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp8_ = _tmp7_; -#line 223 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - left_edge = _tmp8_; -#line 224 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp9_ = page; -#line 224 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp10_ = page_view_get_x_offset (_tmp9_); -#line 224 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp11_ = _tmp10_; -#line 224 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp12_ = page; -#line 224 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp13_ = page_view_get_width (_tmp12_); -#line 224 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp14_ = _tmp13_; -#line 224 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - right_edge = _tmp11_ + _tmp14_; -#line 226 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp15_ = left_edge; -#line 226 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp16_ = book_view_get_x_offset (self); -#line 226 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp17_ = _tmp16_; -#line 226 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - if ((_tmp15_ - _tmp17_) < 0) { -#line 1134 "book-view.c" - gint _tmp18_ = 0; -#line 227 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp18_ = left_edge; -#line 227 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - book_view_set_x_offset (self, _tmp18_); -#line 1140 "book-view.c" - } else { - gint _tmp19_ = 0; - gint _tmp20_ = 0; - gint _tmp21_ = 0; - GtkAllocation _tmp22_ = {0}; - gint _tmp23_ = 0; -#line 228 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp19_ = right_edge; -#line 228 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp20_ = book_view_get_x_offset (self); -#line 228 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp21_ = _tmp20_; -#line 228 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp22_ = allocation; -#line 228 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp23_ = _tmp22_.width; -#line 228 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - if ((_tmp19_ - _tmp21_) > _tmp23_) { -#line 1159 "book-view.c" - gint _tmp24_ = 0; - GtkAllocation _tmp25_ = {0}; - gint _tmp26_ = 0; -#line 229 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp24_ = right_edge; -#line 229 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp25_ = allocation; -#line 229 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp26_ = _tmp25_.width; -#line 229 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - book_view_set_x_offset (self, _tmp24_ - _tmp26_); -#line 1171 "book-view.c" - } - } -} - - -static void book_view_select_page_view (BookView* self, PageView* page) { - Page* p = NULL; - PageView* _tmp0_ = NULL; - PageView* _tmp1_ = NULL; - PageView* _tmp2_ = NULL; - gboolean _tmp3_ = FALSE; - PageView* _tmp5_ = NULL; - Page* _tmp10_ = NULL; -#line 232 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - g_return_if_fail (self != NULL); -#line 234 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - p = NULL; -#line 236 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp0_ = self->priv->selected_page_view; -#line 236 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp1_ = page; -#line 236 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - if (_tmp0_ == _tmp1_) { -#line 237 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _page_unref0 (p); -#line 237 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - return; -#line 1199 "book-view.c" - } -#line 239 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp2_ = page; -#line 239 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - book_view_set_selected_page_view (self, _tmp2_); -#line 241 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp3_ = self->priv->need_layout; -#line 241 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - if (_tmp3_) { -#line 242 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - self->priv->show_selected_page = TRUE; -#line 1211 "book-view.c" - } else { - PageView* _tmp4_ = NULL; -#line 244 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp4_ = page; -#line 244 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - book_view_show_page_view (self, _tmp4_); -#line 1218 "book-view.c" - } -#line 246 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp5_ = page; -#line 246 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - if (_tmp5_ != NULL) { -#line 1224 "book-view.c" - PageView* _tmp6_ = NULL; - Page* _tmp7_ = NULL; - Page* _tmp8_ = NULL; - Page* _tmp9_ = NULL; -#line 247 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp6_ = page; -#line 247 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp7_ = page_view_get_page (_tmp6_); -#line 247 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp8_ = _tmp7_; -#line 247 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp9_ = _page_ref0 (_tmp8_); -#line 247 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _page_unref0 (p); -#line 247 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - p = _tmp9_; -#line 1241 "book-view.c" - } -#line 248 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp10_ = p; -#line 248 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - g_signal_emit_by_name (self, "page-selected", _tmp10_); -#line 232 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _page_unref0 (p); -#line 1249 "book-view.c" -} - - -static void book_view_remove_cb (BookView* self, Book* book, Page* page) { - PageView* new_selection = NULL; - PageView* _tmp0_ = NULL; - PageView* _tmp1_ = NULL; - Page* _tmp2_ = NULL; - Page* _tmp3_ = NULL; - Page* _tmp4_ = NULL; - PageView* page_view = NULL; - GHashTable* _tmp11_ = NULL; - Page* _tmp12_ = NULL; - gconstpointer _tmp13_ = NULL; - PageView* _tmp14_ = NULL; - guint _tmp15_ = 0U; - guint _tmp16_ = 0U; - GHashTable* _tmp17_ = NULL; - Page* _tmp18_ = NULL; - PageView* _tmp19_ = NULL; -#line 251 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - g_return_if_fail (self != NULL); -#line 251 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - g_return_if_fail (book != NULL); -#line 251 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - g_return_if_fail (page != NULL); -#line 253 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp0_ = self->priv->selected_page_view; -#line 253 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp1_ = _page_view_ref0 (_tmp0_); -#line 253 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - new_selection = _tmp1_; -#line 256 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp2_ = page; -#line 256 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp3_ = book_view_get_selected_page (self); -#line 256 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp4_ = _tmp3_; -#line 256 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - if (_tmp2_ == _tmp4_) { -#line 1290 "book-view.c" - PageView* _tmp5_ = NULL; - PageView* _tmp6_ = NULL; - PageView* _tmp7_ = NULL; - PageView* _tmp8_ = NULL; -#line 258 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp5_ = self->priv->selected_page_view; -#line 258 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp6_ = book_view_get_prev_page (self, _tmp5_); -#line 258 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _page_view_unref0 (new_selection); -#line 258 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - new_selection = _tmp6_; -#line 259 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp7_ = new_selection; -#line 259 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp8_ = self->priv->selected_page_view; -#line 259 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - if (_tmp7_ == _tmp8_) { -#line 1309 "book-view.c" - PageView* _tmp9_ = NULL; - PageView* _tmp10_ = NULL; -#line 260 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp9_ = self->priv->selected_page_view; -#line 260 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp10_ = book_view_get_next_page (self, _tmp9_); -#line 260 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _page_view_unref0 (new_selection); -#line 260 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - new_selection = _tmp10_; -#line 1320 "book-view.c" - } -#line 261 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _page_view_unref0 (self->priv->selected_page_view); -#line 261 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - self->priv->selected_page_view = NULL; -#line 1326 "book-view.c" - } -#line 264 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp11_ = self->priv->page_data; -#line 264 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp12_ = page; -#line 264 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp13_ = g_hash_table_lookup (_tmp11_, _tmp12_); -#line 264 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp14_ = _page_view_ref0 ((PageView*) _tmp13_); -#line 264 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - page_view = _tmp14_; -#line 265 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - g_signal_parse_name ("changed", TYPE_PAGE_VIEW, &_tmp15_, NULL, FALSE); -#line 265 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - g_signal_handlers_disconnect_matched (page_view, G_SIGNAL_MATCH_ID | G_SIGNAL_MATCH_FUNC | G_SIGNAL_MATCH_DATA, _tmp15_, 0, NULL, (GCallback) _book_view_page_view_changed_cb_page_view_changed, self); -#line 266 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - g_signal_parse_name ("size-changed", TYPE_PAGE_VIEW, &_tmp16_, NULL, FALSE); -#line 266 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - g_signal_handlers_disconnect_matched (page_view, G_SIGNAL_MATCH_ID | G_SIGNAL_MATCH_FUNC | G_SIGNAL_MATCH_DATA, _tmp16_, 0, NULL, (GCallback) _book_view_page_view_size_changed_cb_page_view_size_changed, self); -#line 267 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp17_ = self->priv->page_data; -#line 267 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp18_ = page; -#line 267 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - g_hash_table_remove (_tmp17_, _tmp18_); -#line 269 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp19_ = new_selection; -#line 269 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - book_view_select_page_view (self, _tmp19_); -#line 271 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - self->priv->need_layout = TRUE; -#line 272 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - book_view_redraw (self); -#line 251 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _page_view_unref0 (page_view); -#line 251 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _page_view_unref0 (new_selection); -#line 1364 "book-view.c" -} - - -static void book_view_reorder_cb (BookView* self, Book* book) { -#line 275 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - g_return_if_fail (self != NULL); -#line 275 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - g_return_if_fail (book != NULL); -#line 277 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - self->priv->need_layout = TRUE; -#line 278 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - book_view_redraw (self); -#line 1377 "book-view.c" -} - - -static void book_view_clear_cb (BookView* self, Book* book) { - GHashTable* _tmp0_ = NULL; -#line 281 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - g_return_if_fail (self != NULL); -#line 281 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - g_return_if_fail (book != NULL); -#line 283 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp0_ = self->priv->page_data; -#line 283 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - g_hash_table_remove_all (_tmp0_); -#line 284 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _page_view_unref0 (self->priv->selected_page_view); -#line 284 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - self->priv->selected_page_view = NULL; -#line 285 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - g_signal_emit_by_name (self, "page-selected", NULL); -#line 286 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - self->priv->need_layout = TRUE; -#line 287 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - book_view_redraw (self); -#line 1401 "book-view.c" -} - - -static gboolean book_view_configure_cb (BookView* self, GtkWidget* widget, GdkEventConfigure* event) { - gboolean result = FALSE; -#line 290 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - g_return_val_if_fail (self != NULL, FALSE); -#line 290 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - g_return_val_if_fail (widget != NULL, FALSE); -#line 290 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - g_return_val_if_fail (event != NULL, FALSE); -#line 292 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - self->priv->need_layout = TRUE; -#line 293 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - result = FALSE; -#line 293 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - return result; -#line 1419 "book-view.c" -} - - -static void book_view_layout_into (BookView* self, gint width, gint height, gint* book_width, gint* book_height) { - gint _vala_book_width = 0; - gint _vala_book_height = 0; - gint max_dpi = 0; - gint max_width = 0; - gint max_height = 0; - gdouble aspect = 0.0; - gint _tmp47_ = 0; - gint _tmp48_ = 0; - gdouble max_aspect = 0.0; - gint _tmp49_ = 0; - gint _tmp50_ = 0; - gint spacing = 0; - gint x_offset = 0; -#line 296 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - g_return_if_fail (self != NULL); -#line 299 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - max_dpi = 0; -#line 1441 "book-view.c" - { - gint i = 0; -#line 300 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - i = 0; -#line 1446 "book-view.c" - { - gboolean _tmp0_ = FALSE; -#line 300 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp0_ = TRUE; -#line 300 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - while (TRUE) { -#line 1453 "book-view.c" - gint _tmp2_ = 0; - Book* _tmp3_ = NULL; - guint _tmp4_ = 0U; - guint _tmp5_ = 0U; - Page* page = NULL; - Book* _tmp6_ = NULL; - gint _tmp7_ = 0; - Page* _tmp8_ = NULL; - Page* _tmp9_ = NULL; - gint _tmp10_ = 0; - gint _tmp11_ = 0; - gint _tmp12_ = 0; -#line 300 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - if (!_tmp0_) { -#line 1468 "book-view.c" - gint _tmp1_ = 0; -#line 300 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp1_ = i; -#line 300 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - i = _tmp1_ + 1; -#line 1474 "book-view.c" - } -#line 300 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp0_ = FALSE; -#line 300 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp2_ = i; -#line 300 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp3_ = self->priv->_book; -#line 300 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp4_ = book_get_n_pages (_tmp3_); -#line 300 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp5_ = _tmp4_; -#line 300 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - if (!(((guint) _tmp2_) < _tmp5_)) { -#line 300 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - break; -#line 1490 "book-view.c" - } -#line 302 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp6_ = self->priv->_book; -#line 302 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp7_ = i; -#line 302 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp8_ = book_get_page (_tmp6_, _tmp7_); -#line 302 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - page = _tmp8_; -#line 303 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp9_ = page; -#line 303 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp10_ = page_get_dpi (_tmp9_); -#line 303 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp11_ = _tmp10_; -#line 303 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp12_ = max_dpi; -#line 303 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - if (_tmp11_ > _tmp12_) { -#line 1510 "book-view.c" - Page* _tmp13_ = NULL; - gint _tmp14_ = 0; - gint _tmp15_ = 0; -#line 304 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp13_ = page; -#line 304 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp14_ = page_get_dpi (_tmp13_); -#line 304 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp15_ = _tmp14_; -#line 304 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - max_dpi = _tmp15_; -#line 1522 "book-view.c" - } -#line 300 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _page_unref0 (page); -#line 1526 "book-view.c" - } - } - } -#line 308 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - max_width = 0; -#line 308 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - max_height = 0; -#line 1534 "book-view.c" - { - gint i = 0; -#line 309 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - i = 0; -#line 1539 "book-view.c" - { - gboolean _tmp16_ = FALSE; -#line 309 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp16_ = TRUE; -#line 309 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - while (TRUE) { -#line 1546 "book-view.c" - gint _tmp18_ = 0; - Book* _tmp19_ = NULL; - guint _tmp20_ = 0U; - guint _tmp21_ = 0U; - Page* page = NULL; - Book* _tmp22_ = NULL; - gint _tmp23_ = 0; - Page* _tmp24_ = NULL; - gint w = 0; - Page* _tmp25_ = NULL; - gint _tmp26_ = 0; - gint _tmp27_ = 0; - gint h = 0; - Page* _tmp28_ = NULL; - gint _tmp29_ = 0; - gint _tmp30_ = 0; - gint _tmp31_ = 0; - gint _tmp32_ = 0; - Page* _tmp33_ = NULL; - gint _tmp34_ = 0; - gint _tmp35_ = 0; - gint _tmp36_ = 0; - gint _tmp37_ = 0; - Page* _tmp38_ = NULL; - gint _tmp39_ = 0; - gint _tmp40_ = 0; - gint _tmp41_ = 0; - gint _tmp42_ = 0; - gint _tmp44_ = 0; - gint _tmp45_ = 0; -#line 309 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - if (!_tmp16_) { -#line 1579 "book-view.c" - gint _tmp17_ = 0; -#line 309 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp17_ = i; -#line 309 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - i = _tmp17_ + 1; -#line 1585 "book-view.c" - } -#line 309 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp16_ = FALSE; -#line 309 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp18_ = i; -#line 309 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp19_ = self->priv->_book; -#line 309 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp20_ = book_get_n_pages (_tmp19_); -#line 309 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp21_ = _tmp20_; -#line 309 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - if (!(((guint) _tmp18_) < _tmp21_)) { -#line 309 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - break; -#line 1601 "book-view.c" - } -#line 311 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp22_ = self->priv->_book; -#line 311 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp23_ = i; -#line 311 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp24_ = book_get_page (_tmp22_, _tmp23_); -#line 311 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - page = _tmp24_; -#line 312 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp25_ = page; -#line 312 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp26_ = page_get_width (_tmp25_); -#line 312 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp27_ = _tmp26_; -#line 312 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - w = _tmp27_; -#line 313 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp28_ = page; -#line 313 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp29_ = page_get_height (_tmp28_); -#line 313 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp30_ = _tmp29_; -#line 313 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - h = _tmp30_; -#line 316 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp31_ = w; -#line 316 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp32_ = max_dpi; -#line 316 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp33_ = page; -#line 316 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp34_ = page_get_dpi (_tmp33_); -#line 316 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp35_ = _tmp34_; -#line 316 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - w = (gint) (((((gdouble) _tmp31_) * _tmp32_) / _tmp35_) + 0.5); -#line 317 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp36_ = h; -#line 317 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp37_ = max_dpi; -#line 317 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp38_ = page; -#line 317 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp39_ = page_get_dpi (_tmp38_); -#line 317 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp40_ = _tmp39_; -#line 317 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - h = (gint) (((((gdouble) _tmp36_) * _tmp37_) / _tmp40_) + 0.5); -#line 319 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp41_ = w; -#line 319 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp42_ = max_width; -#line 319 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - if (_tmp41_ > _tmp42_) { -#line 1657 "book-view.c" - gint _tmp43_ = 0; -#line 320 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp43_ = w; -#line 320 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - max_width = _tmp43_; -#line 1663 "book-view.c" - } -#line 321 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp44_ = h; -#line 321 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp45_ = max_height; -#line 321 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - if (_tmp44_ > _tmp45_) { -#line 1671 "book-view.c" - gint _tmp46_ = 0; -#line 322 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp46_ = h; -#line 322 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - max_height = _tmp46_; -#line 1677 "book-view.c" - } -#line 309 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _page_unref0 (page); -#line 1681 "book-view.c" - } - } - } -#line 325 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp47_ = width; -#line 325 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp48_ = height; -#line 325 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - aspect = ((gdouble) _tmp47_) / _tmp48_; -#line 326 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp49_ = max_width; -#line 326 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp50_ = max_height; -#line 326 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - max_aspect = ((gdouble) _tmp49_) / _tmp50_; -#line 329 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - spacing = 12; -#line 330 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _vala_book_width = 0; -#line 331 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _vala_book_height = 0; -#line 1703 "book-view.c" - { - gint i = 0; -#line 332 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - i = 0; -#line 1708 "book-view.c" - { - gboolean _tmp51_ = FALSE; -#line 332 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp51_ = TRUE; -#line 332 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - while (TRUE) { -#line 1715 "book-view.c" - gint _tmp53_ = 0; - Book* _tmp54_ = NULL; - guint _tmp55_ = 0U; - guint _tmp56_ = 0U; - PageView* page = NULL; - gint _tmp57_ = 0; - PageView* _tmp58_ = NULL; - Page* p = NULL; - PageView* _tmp59_ = NULL; - Page* _tmp60_ = NULL; - Page* _tmp61_ = NULL; - Page* _tmp62_ = NULL; - gdouble _tmp63_ = 0.0; - gdouble _tmp64_ = 0.0; - gint h = 0; - PageView* _tmp87_ = NULL; - gint _tmp88_ = 0; - gint _tmp89_ = 0; - gint _tmp90_ = 0; - gint _tmp91_ = 0; - gint _tmp93_ = 0; - PageView* _tmp94_ = NULL; - gint _tmp95_ = 0; - gint _tmp96_ = 0; - gint _tmp97_ = 0; -#line 332 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - if (!_tmp51_) { -#line 1743 "book-view.c" - gint _tmp52_ = 0; -#line 332 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp52_ = i; -#line 332 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - i = _tmp52_ + 1; -#line 1749 "book-view.c" - } -#line 332 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp51_ = FALSE; -#line 332 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp53_ = i; -#line 332 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp54_ = self->priv->_book; -#line 332 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp55_ = book_get_n_pages (_tmp54_); -#line 332 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp56_ = _tmp55_; -#line 332 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - if (!(((guint) _tmp53_) < _tmp56_)) { -#line 332 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - break; -#line 1765 "book-view.c" - } -#line 334 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp57_ = i; -#line 334 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp58_ = book_view_get_nth_page (self, _tmp57_); -#line 334 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - page = _tmp58_; -#line 335 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp59_ = page; -#line 335 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp60_ = page_view_get_page (_tmp59_); -#line 335 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp61_ = _tmp60_; -#line 335 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp62_ = _page_ref0 (_tmp61_); -#line 335 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - p = _tmp62_; -#line 338 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp63_ = max_aspect; -#line 338 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp64_ = aspect; -#line 338 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - if (_tmp63_ > _tmp64_) { -#line 1789 "book-view.c" - gint w = 0; - Page* _tmp65_ = NULL; - gint _tmp66_ = 0; - gint _tmp67_ = 0; - gint _tmp68_ = 0; - gint _tmp69_ = 0; - Page* _tmp70_ = NULL; - gint _tmp71_ = 0; - gint _tmp72_ = 0; - gint _tmp73_ = 0; - PageView* _tmp74_ = NULL; - gint _tmp75_ = 0; -#line 341 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp65_ = p; -#line 341 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp66_ = page_get_width (_tmp65_); -#line 341 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp67_ = _tmp66_; -#line 341 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp68_ = max_dpi; -#line 341 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp69_ = width; -#line 341 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp70_ = p; -#line 341 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp71_ = page_get_dpi (_tmp70_); -#line 341 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp72_ = _tmp71_; -#line 341 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp73_ = max_width; -#line 341 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - w = (gint) (((((gdouble) _tmp67_) * _tmp68_) * _tmp69_) / (_tmp72_ * _tmp73_)); -#line 342 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp74_ = page; -#line 342 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp75_ = w; -#line 342 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - page_view_set_width (_tmp74_, _tmp75_); -#line 1828 "book-view.c" - } else { - gint h = 0; - Page* _tmp76_ = NULL; - gint _tmp77_ = 0; - gint _tmp78_ = 0; - gint _tmp79_ = 0; - gint _tmp80_ = 0; - Page* _tmp81_ = NULL; - gint _tmp82_ = 0; - gint _tmp83_ = 0; - gint _tmp84_ = 0; - PageView* _tmp85_ = NULL; - gint _tmp86_ = 0; -#line 347 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp76_ = p; -#line 347 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp77_ = page_get_height (_tmp76_); -#line 347 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp78_ = _tmp77_; -#line 347 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp79_ = max_dpi; -#line 347 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp80_ = height; -#line 347 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp81_ = p; -#line 347 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp82_ = page_get_dpi (_tmp81_); -#line 347 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp83_ = _tmp82_; -#line 347 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp84_ = max_height; -#line 347 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - h = (gint) (((((gdouble) _tmp78_) * _tmp79_) * _tmp80_) / (_tmp83_ * _tmp84_)); -#line 348 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp85_ = page; -#line 348 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp86_ = h; -#line 348 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - page_view_set_height (_tmp85_, _tmp86_); -#line 1868 "book-view.c" - } -#line 351 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp87_ = page; -#line 351 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp88_ = page_view_get_height (_tmp87_); -#line 351 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp89_ = _tmp88_; -#line 351 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - h = _tmp89_; -#line 352 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp90_ = h; -#line 352 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp91_ = _vala_book_height; -#line 352 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - if (_tmp90_ > _tmp91_) { -#line 1884 "book-view.c" - gint _tmp92_ = 0; -#line 353 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp92_ = h; -#line 353 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _vala_book_height = _tmp92_; -#line 1890 "book-view.c" - } -#line 354 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp93_ = _vala_book_width; -#line 354 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp94_ = page; -#line 354 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp95_ = page_view_get_width (_tmp94_); -#line 354 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp96_ = _tmp95_; -#line 354 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _vala_book_width = _tmp93_ + _tmp96_; -#line 355 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp97_ = i; -#line 355 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - if (_tmp97_ != 0) { -#line 1906 "book-view.c" - gint _tmp98_ = 0; - gint _tmp99_ = 0; -#line 356 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp98_ = _vala_book_width; -#line 356 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp99_ = spacing; -#line 356 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _vala_book_width = _tmp98_ + _tmp99_; -#line 1915 "book-view.c" - } -#line 332 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _page_unref0 (p); -#line 332 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _page_view_unref0 (page); -#line 1921 "book-view.c" - } - } - } -#line 359 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - x_offset = 0; -#line 1927 "book-view.c" - { - gint i = 0; -#line 360 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - i = 0; -#line 1932 "book-view.c" - { - gboolean _tmp100_ = FALSE; -#line 360 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp100_ = TRUE; -#line 360 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - while (TRUE) { -#line 1939 "book-view.c" - gint _tmp102_ = 0; - Book* _tmp103_ = NULL; - guint _tmp104_ = 0U; - guint _tmp105_ = 0U; - PageView* page = NULL; - gint _tmp106_ = 0; - PageView* _tmp107_ = NULL; - PageView* _tmp108_ = NULL; - gint _tmp109_ = 0; - gint _tmp110_ = 0; - PageView* _tmp111_ = NULL; - gint _tmp112_ = 0; - gint _tmp113_ = 0; - gint _tmp114_ = 0; - PageView* _tmp115_ = NULL; - gint _tmp116_ = 0; - PageView* _tmp117_ = NULL; - gint _tmp118_ = 0; - gint _tmp119_ = 0; -#line 360 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - if (!_tmp100_) { -#line 1961 "book-view.c" - gint _tmp101_ = 0; -#line 360 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp101_ = i; -#line 360 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - i = _tmp101_ + 1; -#line 1967 "book-view.c" - } -#line 360 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp100_ = FALSE; -#line 360 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp102_ = i; -#line 360 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp103_ = self->priv->_book; -#line 360 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp104_ = book_get_n_pages (_tmp103_); -#line 360 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp105_ = _tmp104_; -#line 360 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - if (!(((guint) _tmp102_) < _tmp105_)) { -#line 360 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - break; -#line 1983 "book-view.c" - } -#line 362 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp106_ = i; -#line 362 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp107_ = book_view_get_nth_page (self, _tmp106_); -#line 362 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - page = _tmp107_; -#line 365 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp108_ = page; -#line 365 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp109_ = x_offset; -#line 365 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - page_view_set_x_offset (_tmp108_, _tmp109_); -#line 366 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp110_ = x_offset; -#line 366 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp111_ = page; -#line 366 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp112_ = page_view_get_width (_tmp111_); -#line 366 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp113_ = _tmp112_; -#line 366 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp114_ = spacing; -#line 366 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - x_offset = _tmp110_ + (_tmp113_ + _tmp114_); -#line 369 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp115_ = page; -#line 369 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp116_ = height; -#line 369 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp117_ = page; -#line 369 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp118_ = page_view_get_height (_tmp117_); -#line 369 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp119_ = _tmp118_; -#line 369 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - page_view_set_y_offset (_tmp115_, (_tmp116_ - _tmp119_) / 2); -#line 360 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _page_view_unref0 (page); -#line 2023 "book-view.c" - } - } - } -#line 296 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - if (book_width) { -#line 296 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - *book_width = _vala_book_width; -#line 2031 "book-view.c" - } -#line 296 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - if (book_height) { -#line 296 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - *book_height = _vala_book_height; -#line 2037 "book-view.c" - } -} - - -static void book_view_layout (BookView* self) { - gboolean _tmp0_ = FALSE; - GtkAllocation allocation = {0}; - GtkWidget* _tmp1_ = NULL; - GtkAllocation _tmp2_ = {0}; - GtkAllocation box_allocation = {0}; - GtkAllocation _tmp3_ = {0}; - gboolean right_aligned = FALSE; - GtkAdjustment* _tmp4_ = NULL; - gdouble _tmp5_ = 0.0; - GtkAdjustment* _tmp6_ = NULL; - gdouble _tmp7_ = 0.0; - GtkAdjustment* _tmp8_ = NULL; - gdouble _tmp9_ = 0.0; - gint width = 0; - GtkAllocation _tmp10_ = {0}; - gint _tmp11_ = 0; - gint height = 0; - GtkAllocation _tmp12_ = {0}; - gint _tmp13_ = 0; - guint _tmp14_ = 0U; - gint book_width = 0; - gint book_height = 0; - gint _tmp15_ = 0; - gint _tmp16_ = 0; - gint _tmp17_ = 0; - gint _tmp18_ = 0; - gint _tmp19_ = 0; - GtkAllocation _tmp20_ = {0}; - gint _tmp21_ = 0; - gboolean _tmp54_ = FALSE; -#line 373 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - g_return_if_fail (self != NULL); -#line 375 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp0_ = self->priv->need_layout; -#line 375 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - if (!_tmp0_) { -#line 376 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - return; -#line 2081 "book-view.c" - } -#line 378 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - self->priv->laying_out = TRUE; -#line 381 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp1_ = self->priv->drawing_area; -#line 381 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - gtk_widget_get_allocation (_tmp1_, &_tmp2_); -#line 381 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - allocation = _tmp2_; -#line 383 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - gtk_widget_get_allocation ((GtkWidget*) self, &_tmp3_); -#line 383 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - box_allocation = _tmp3_; -#line 386 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - right_aligned = TRUE; -#line 387 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp4_ = self->priv->adjustment; -#line 387 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp5_ = gtk_adjustment_get_value (_tmp4_); -#line 387 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp6_ = self->priv->adjustment; -#line 387 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp7_ = gtk_adjustment_get_upper (_tmp6_); -#line 387 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp8_ = self->priv->adjustment; -#line 387 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp9_ = gtk_adjustment_get_page_size (_tmp8_); -#line 387 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - if (_tmp5_ < (_tmp7_ - _tmp9_)) { -#line 388 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - right_aligned = FALSE; -#line 2113 "book-view.c" - } -#line 391 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp10_ = allocation; -#line 391 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp11_ = _tmp10_.width; -#line 391 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - width = (gint) _tmp11_; -#line 392 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp12_ = box_allocation; -#line 392 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp13_ = _tmp12_.height; -#line 392 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp14_ = gtk_container_get_border_width ((GtkContainer*) self); -#line 392 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - height = (gint) (_tmp13_ - (_tmp14_ * 2)); -#line 394 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp15_ = width; -#line 394 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp16_ = height; -#line 394 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - book_view_layout_into (self, _tmp15_, _tmp16_, &_tmp17_, &_tmp18_); -#line 394 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - book_width = _tmp17_; -#line 394 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - book_height = _tmp18_; -#line 397 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp19_ = book_width; -#line 397 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp20_ = allocation; -#line 397 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp21_ = _tmp20_.width; -#line 397 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - if (_tmp19_ > _tmp21_) { -#line 2147 "book-view.c" - GtkAllocation _tmp22_ = {0}; - gint _tmp23_ = 0; - gint _tmp24_ = 0; - gint _tmp25_ = 0; - gint _tmp26_ = 0; - gint _tmp27_ = 0; - GtkAdjustment* _tmp28_ = NULL; - GtkAdjustment* _tmp29_ = NULL; - gint _tmp30_ = 0; - GtkAdjustment* _tmp31_ = NULL; - GtkAllocation _tmp32_ = {0}; - gint _tmp33_ = 0; - gint max_offset = 0; - gint _tmp34_ = 0; - GtkAllocation _tmp35_ = {0}; - gint _tmp36_ = 0; - gboolean _tmp37_ = FALSE; - gboolean _tmp38_ = FALSE; - GtkScrollbar* _tmp43_ = NULL; -#line 400 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp22_ = allocation; -#line 400 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp23_ = _tmp22_.height; -#line 400 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - height = _tmp23_; -#line 401 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp24_ = width; -#line 401 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp25_ = height; -#line 401 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - book_view_layout_into (self, _tmp24_, _tmp25_, &_tmp26_, &_tmp27_); -#line 401 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - book_width = _tmp26_; -#line 401 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - book_height = _tmp27_; -#line 404 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp28_ = self->priv->adjustment; -#line 404 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - gtk_adjustment_set_lower (_tmp28_, (gdouble) 0); -#line 405 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp29_ = self->priv->adjustment; -#line 405 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp30_ = book_width; -#line 405 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - gtk_adjustment_set_upper (_tmp29_, (gdouble) _tmp30_); -#line 406 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp31_ = self->priv->adjustment; -#line 406 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp32_ = allocation; -#line 406 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp33_ = _tmp32_.width; -#line 406 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - gtk_adjustment_set_page_size (_tmp31_, (gdouble) _tmp33_); -#line 409 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp34_ = book_width; -#line 409 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp35_ = allocation; -#line 409 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp36_ = _tmp35_.width; -#line 409 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - max_offset = _tmp34_ - _tmp36_; -#line 410 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp38_ = right_aligned; -#line 410 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - if (_tmp38_) { -#line 410 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp37_ = TRUE; -#line 2215 "book-view.c" - } else { - gint _tmp39_ = 0; - gint _tmp40_ = 0; - gint _tmp41_ = 0; -#line 410 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp39_ = book_view_get_x_offset (self); -#line 410 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp40_ = _tmp39_; -#line 410 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp41_ = max_offset; -#line 410 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp37_ = _tmp40_ > _tmp41_; -#line 2228 "book-view.c" - } -#line 410 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - if (_tmp37_) { -#line 2232 "book-view.c" - gint _tmp42_ = 0; -#line 411 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp42_ = max_offset; -#line 411 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - book_view_set_x_offset (self, _tmp42_); -#line 2238 "book-view.c" - } -#line 413 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp43_ = self->priv->scroll; -#line 413 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - gtk_widget_set_visible ((GtkWidget*) _tmp43_, TRUE); -#line 2244 "book-view.c" - } else { - GtkScrollbar* _tmp44_ = NULL; - gint offset = 0; - gint _tmp45_ = 0; - GtkAllocation _tmp46_ = {0}; - gint _tmp47_ = 0; - GtkAdjustment* _tmp48_ = NULL; - gint _tmp49_ = 0; - GtkAdjustment* _tmp50_ = NULL; - gint _tmp51_ = 0; - GtkAdjustment* _tmp52_ = NULL; - gint _tmp53_ = 0; -#line 417 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp44_ = self->priv->scroll; -#line 417 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - gtk_widget_set_visible ((GtkWidget*) _tmp44_, FALSE); -#line 418 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp45_ = book_width; -#line 418 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp46_ = allocation; -#line 418 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp47_ = _tmp46_.width; -#line 418 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - offset = (_tmp45_ - _tmp47_) / 2; -#line 419 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp48_ = self->priv->adjustment; -#line 419 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp49_ = offset; -#line 419 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - gtk_adjustment_set_lower (_tmp48_, (gdouble) _tmp49_); -#line 420 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp50_ = self->priv->adjustment; -#line 420 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp51_ = offset; -#line 420 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - gtk_adjustment_set_upper (_tmp50_, (gdouble) _tmp51_); -#line 421 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp52_ = self->priv->adjustment; -#line 421 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - gtk_adjustment_set_page_size (_tmp52_, (gdouble) 0); -#line 422 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp53_ = offset; -#line 422 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - book_view_set_x_offset (self, _tmp53_); -#line 2289 "book-view.c" - } -#line 425 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp54_ = self->priv->show_selected_page; -#line 425 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - if (_tmp54_) { -#line 2295 "book-view.c" - PageView* _tmp55_ = NULL; -#line 426 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp55_ = self->priv->selected_page_view; -#line 426 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - book_view_show_page_view (self, _tmp55_); -#line 2301 "book-view.c" - } -#line 428 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - self->priv->need_layout = FALSE; -#line 429 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - self->priv->show_selected_page = FALSE; -#line 430 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - self->priv->laying_out = FALSE; -#line 2309 "book-view.c" -} - - -static gboolean book_view_draw_cb (BookView* self, GtkWidget* widget, cairo_t* context) { - gboolean result = FALSE; - Book* _tmp0_ = NULL; - guint _tmp1_ = 0U; - guint _tmp2_ = 0U; - gdouble left = 0.0; - gdouble top = 0.0; - gdouble right = 0.0; - gdouble bottom = 0.0; - cairo_t* _tmp3_ = NULL; - gdouble _tmp4_ = 0.0; - gdouble _tmp5_ = 0.0; - gdouble _tmp6_ = 0.0; - gdouble _tmp7_ = 0.0; -#line 433 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - g_return_val_if_fail (self != NULL, FALSE); -#line 433 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - g_return_val_if_fail (widget != NULL, FALSE); -#line 433 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - g_return_val_if_fail (context != NULL, FALSE); -#line 435 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp0_ = self->priv->_book; -#line 435 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp1_ = book_get_n_pages (_tmp0_); -#line 435 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp2_ = _tmp1_; -#line 435 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - if (_tmp2_ == ((guint) 0)) { -#line 436 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - result = FALSE; -#line 436 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - return result; -#line 2345 "book-view.c" - } -#line 438 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - book_view_layout (self); -#line 441 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp3_ = context; -#line 441 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - cairo_clip_extents (_tmp3_, &_tmp4_, &_tmp5_, &_tmp6_, &_tmp7_); -#line 441 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - left = _tmp4_; -#line 441 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - top = _tmp5_; -#line 441 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - right = _tmp6_; -#line 441 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - bottom = _tmp7_; -#line 2361 "book-view.c" - { - gint i = 0; -#line 444 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - i = 0; -#line 2366 "book-view.c" - { - gboolean _tmp8_ = FALSE; -#line 444 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp8_ = TRUE; -#line 444 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - while (TRUE) { -#line 2373 "book-view.c" - gint _tmp10_ = 0; - Book* _tmp11_ = NULL; - guint _tmp12_ = 0U; - guint _tmp13_ = 0U; - PageView* page = NULL; - gint _tmp14_ = 0; - PageView* _tmp15_ = NULL; - gint left_edge = 0; - PageView* _tmp16_ = NULL; - gint _tmp17_ = 0; - gint _tmp18_ = 0; - gint _tmp19_ = 0; - gint _tmp20_ = 0; - gint right_edge = 0; - PageView* _tmp21_ = NULL; - gint _tmp22_ = 0; - gint _tmp23_ = 0; - PageView* _tmp24_ = NULL; - gint _tmp25_ = 0; - gint _tmp26_ = 0; - gint _tmp27_ = 0; - gint _tmp28_ = 0; - gboolean _tmp29_ = FALSE; - gint _tmp30_ = 0; - gdouble _tmp31_ = 0.0; - cairo_t* _tmp34_ = NULL; - cairo_t* _tmp35_ = NULL; - gint _tmp36_ = 0; - gint _tmp37_ = 0; - PageView* _tmp38_ = NULL; - cairo_t* _tmp39_ = NULL; - cairo_t* _tmp40_ = NULL; - PageView* _tmp41_ = NULL; - gboolean _tmp42_ = FALSE; - gboolean _tmp43_ = FALSE; -#line 444 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - if (!_tmp8_) { -#line 2411 "book-view.c" - gint _tmp9_ = 0; -#line 444 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp9_ = i; -#line 444 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - i = _tmp9_ + 1; -#line 2417 "book-view.c" - } -#line 444 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp8_ = FALSE; -#line 444 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp10_ = i; -#line 444 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp11_ = self->priv->_book; -#line 444 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp12_ = book_get_n_pages (_tmp11_); -#line 444 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp13_ = _tmp12_; -#line 444 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - if (!(((guint) _tmp10_) < _tmp13_)) { -#line 444 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - break; -#line 2433 "book-view.c" - } -#line 446 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp14_ = i; -#line 446 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp15_ = book_view_get_nth_page (self, _tmp14_); -#line 446 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - page = _tmp15_; -#line 447 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp16_ = page; -#line 447 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp17_ = page_view_get_x_offset (_tmp16_); -#line 447 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp18_ = _tmp17_; -#line 447 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp19_ = book_view_get_x_offset (self); -#line 447 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp20_ = _tmp19_; -#line 447 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - left_edge = _tmp18_ - _tmp20_; -#line 448 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp21_ = page; -#line 448 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp22_ = page_view_get_x_offset (_tmp21_); -#line 448 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp23_ = _tmp22_; -#line 448 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp24_ = page; -#line 448 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp25_ = page_view_get_width (_tmp24_); -#line 448 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp26_ = _tmp25_; -#line 448 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp27_ = book_view_get_x_offset (self); -#line 448 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp28_ = _tmp27_; -#line 448 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - right_edge = (_tmp23_ + _tmp26_) - _tmp28_; -#line 451 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp30_ = right_edge; -#line 451 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp31_ = left; -#line 451 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - if (((gdouble) _tmp30_) < _tmp31_) { -#line 451 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp29_ = TRUE; -#line 2479 "book-view.c" - } else { - gint _tmp32_ = 0; - gdouble _tmp33_ = 0.0; -#line 451 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp32_ = left_edge; -#line 451 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp33_ = right; -#line 451 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp29_ = ((gdouble) _tmp32_) > _tmp33_; -#line 2489 "book-view.c" - } -#line 451 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - if (_tmp29_) { -#line 452 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _page_view_unref0 (page); -#line 452 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - continue; -#line 2497 "book-view.c" - } -#line 454 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp34_ = context; -#line 454 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - cairo_save (_tmp34_); -#line 455 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp35_ = context; -#line 455 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp36_ = book_view_get_x_offset (self); -#line 455 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp37_ = _tmp36_; -#line 455 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - cairo_translate (_tmp35_, (gdouble) (-_tmp37_), (gdouble) 0); -#line 456 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp38_ = page; -#line 456 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp39_ = context; -#line 456 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - page_view_render (_tmp38_, _tmp39_); -#line 457 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp40_ = context; -#line 457 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - cairo_restore (_tmp40_); -#line 459 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp41_ = page; -#line 459 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp42_ = page_view_get_selected (_tmp41_); -#line 459 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp43_ = _tmp42_; -#line 459 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - if (_tmp43_) { -#line 2529 "book-view.c" - GtkWidget* _tmp44_ = NULL; - GtkStyleContext* _tmp45_ = NULL; - cairo_t* _tmp46_ = NULL; - PageView* _tmp47_ = NULL; - gint _tmp48_ = 0; - gint _tmp49_ = 0; - gint _tmp50_ = 0; - gint _tmp51_ = 0; - PageView* _tmp52_ = NULL; - gint _tmp53_ = 0; - gint _tmp54_ = 0; - PageView* _tmp55_ = NULL; - gint _tmp56_ = 0; - gint _tmp57_ = 0; - PageView* _tmp58_ = NULL; - gint _tmp59_ = 0; - gint _tmp60_ = 0; -#line 460 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp44_ = self->priv->drawing_area; -#line 460 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp45_ = gtk_widget_get_style_context (_tmp44_); -#line 460 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp46_ = context; -#line 460 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp47_ = page; -#line 460 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp48_ = page_view_get_x_offset (_tmp47_); -#line 460 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp49_ = _tmp48_; -#line 460 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp50_ = book_view_get_x_offset (self); -#line 460 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp51_ = _tmp50_; -#line 460 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp52_ = page; -#line 460 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp53_ = page_view_get_y_offset (_tmp52_); -#line 460 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp54_ = _tmp53_; -#line 460 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp55_ = page; -#line 460 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp56_ = page_view_get_width (_tmp55_); -#line 460 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp57_ = _tmp56_; -#line 460 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp58_ = page; -#line 460 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp59_ = page_view_get_height (_tmp58_); -#line 460 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp60_ = _tmp59_; -#line 460 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - gtk_render_focus (_tmp45_, _tmp46_, (gdouble) (_tmp49_ - _tmp51_), (gdouble) _tmp54_, (gdouble) _tmp57_, (gdouble) _tmp60_); -#line 2583 "book-view.c" - } -#line 444 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _page_view_unref0 (page); -#line 2587 "book-view.c" - } - } - } -#line 467 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - result = FALSE; -#line 467 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - return result; -#line 2595 "book-view.c" -} - - -static PageView* book_view_get_page_at (BookView* self, gint x, gint y, gint* x_, gint* y_) { - gint _vala_x_ = 0; - gint _vala_y_ = 0; - PageView* result = NULL; - gint _tmp0_ = 0; -#line 470 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - g_return_val_if_fail (self != NULL, NULL); -#line 472 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _vala_y_ = 0; -#line 472 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp0_ = _vala_y_; -#line 472 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _vala_x_ = _tmp0_; -#line 2612 "book-view.c" - { - gint i = 0; -#line 473 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - i = 0; -#line 2617 "book-view.c" - { - gboolean _tmp1_ = FALSE; -#line 473 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp1_ = TRUE; -#line 473 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - while (TRUE) { -#line 2624 "book-view.c" - gint _tmp3_ = 0; - Book* _tmp4_ = NULL; - guint _tmp5_ = 0U; - guint _tmp6_ = 0U; - PageView* page = NULL; - gint _tmp7_ = 0; - PageView* _tmp8_ = NULL; - gint left = 0; - PageView* _tmp9_ = NULL; - gint _tmp10_ = 0; - gint _tmp11_ = 0; - gint right = 0; - gint _tmp12_ = 0; - PageView* _tmp13_ = NULL; - gint _tmp14_ = 0; - gint _tmp15_ = 0; - gint top = 0; - PageView* _tmp16_ = NULL; - gint _tmp17_ = 0; - gint _tmp18_ = 0; - gint bottom = 0; - gint _tmp19_ = 0; - PageView* _tmp20_ = NULL; - gint _tmp21_ = 0; - gint _tmp22_ = 0; - gboolean _tmp23_ = FALSE; - gboolean _tmp24_ = FALSE; - gboolean _tmp25_ = FALSE; - gint _tmp26_ = 0; - gint _tmp27_ = 0; -#line 473 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - if (!_tmp1_) { -#line 2657 "book-view.c" - gint _tmp2_ = 0; -#line 473 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp2_ = i; -#line 473 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - i = _tmp2_ + 1; -#line 2663 "book-view.c" - } -#line 473 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp1_ = FALSE; -#line 473 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp3_ = i; -#line 473 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp4_ = self->priv->_book; -#line 473 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp5_ = book_get_n_pages (_tmp4_); -#line 473 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp6_ = _tmp5_; -#line 473 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - if (!(((guint) _tmp3_) < _tmp6_)) { -#line 473 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - break; -#line 2679 "book-view.c" - } -#line 475 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp7_ = i; -#line 475 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp8_ = book_view_get_nth_page (self, _tmp7_); -#line 475 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - page = _tmp8_; -#line 476 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp9_ = page; -#line 476 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp10_ = page_view_get_x_offset (_tmp9_); -#line 476 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp11_ = _tmp10_; -#line 476 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - left = _tmp11_; -#line 477 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp12_ = left; -#line 477 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp13_ = page; -#line 477 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp14_ = page_view_get_width (_tmp13_); -#line 477 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp15_ = _tmp14_; -#line 477 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - right = _tmp12_ + _tmp15_; -#line 478 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp16_ = page; -#line 478 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp17_ = page_view_get_y_offset (_tmp16_); -#line 478 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp18_ = _tmp17_; -#line 478 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - top = _tmp18_; -#line 479 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp19_ = top; -#line 479 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp20_ = page; -#line 479 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp21_ = page_view_get_height (_tmp20_); -#line 479 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp22_ = _tmp21_; -#line 479 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - bottom = _tmp19_ + _tmp22_; -#line 480 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp26_ = x; -#line 480 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp27_ = left; -#line 480 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - if (_tmp26_ >= _tmp27_) { -#line 2729 "book-view.c" - gint _tmp28_ = 0; - gint _tmp29_ = 0; -#line 480 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp28_ = x; -#line 480 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp29_ = right; -#line 480 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp25_ = _tmp28_ <= _tmp29_; -#line 2738 "book-view.c" - } else { -#line 480 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp25_ = FALSE; -#line 2742 "book-view.c" - } -#line 480 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - if (_tmp25_) { -#line 2746 "book-view.c" - gint _tmp30_ = 0; - gint _tmp31_ = 0; -#line 480 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp30_ = y; -#line 480 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp31_ = top; -#line 480 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp24_ = _tmp30_ >= _tmp31_; -#line 2755 "book-view.c" - } else { -#line 480 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp24_ = FALSE; -#line 2759 "book-view.c" - } -#line 480 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - if (_tmp24_) { -#line 2763 "book-view.c" - gint _tmp32_ = 0; - gint _tmp33_ = 0; -#line 480 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp32_ = y; -#line 480 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp33_ = bottom; -#line 480 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp23_ = _tmp32_ <= _tmp33_; -#line 2772 "book-view.c" - } else { -#line 480 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp23_ = FALSE; -#line 2776 "book-view.c" - } -#line 480 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - if (_tmp23_) { -#line 2780 "book-view.c" - gint _tmp34_ = 0; - gint _tmp35_ = 0; - gint _tmp36_ = 0; - gint _tmp37_ = 0; -#line 482 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp34_ = x; -#line 482 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp35_ = left; -#line 482 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _vala_x_ = _tmp34_ - _tmp35_; -#line 483 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp36_ = y; -#line 483 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp37_ = top; -#line 483 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _vala_y_ = _tmp36_ - _tmp37_; -#line 484 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - result = page; -#line 484 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - if (x_) { -#line 484 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - *x_ = _vala_x_; -#line 2803 "book-view.c" - } -#line 484 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - if (y_) { -#line 484 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - *y_ = _vala_y_; -#line 2809 "book-view.c" - } -#line 484 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - return result; -#line 2813 "book-view.c" - } -#line 473 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _page_view_unref0 (page); -#line 2817 "book-view.c" - } - } - } -#line 488 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - result = NULL; -#line 488 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - if (x_) { -#line 488 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - *x_ = _vala_x_; -#line 2827 "book-view.c" - } -#line 488 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - if (y_) { -#line 488 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - *y_ = _vala_y_; -#line 2833 "book-view.c" - } -#line 488 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - return result; -#line 2837 "book-view.c" -} - - -static gboolean book_view_button_cb (BookView* self, GtkWidget* widget, GdkEventButton* event) { - gboolean result = FALSE; - GtkWidget* _tmp0_ = NULL; - gint x = 0; - gint y = 0; - GdkEventButton* _tmp1_ = NULL; - GdkEventType _tmp2_ = 0; - PageView* _tmp13_ = NULL; - GdkEventButton* _tmp14_ = NULL; - guint _tmp15_ = 0U; - GdkEventButton* _tmp30_ = NULL; - guint _tmp31_ = 0U; -#line 491 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - g_return_val_if_fail (self != NULL, FALSE); -#line 491 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - g_return_val_if_fail (widget != NULL, FALSE); -#line 491 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - g_return_val_if_fail (event != NULL, FALSE); -#line 493 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - book_view_layout (self); -#line 495 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp0_ = self->priv->drawing_area; -#line 495 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - gtk_widget_grab_focus (_tmp0_); -#line 497 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - x = 0; -#line 497 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - y = 0; -#line 498 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp1_ = event; -#line 498 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp2_ = _tmp1_->type; -#line 498 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - if (_tmp2_ == GDK_BUTTON_PRESS) { -#line 2875 "book-view.c" - GdkEventButton* _tmp3_ = NULL; - gdouble _tmp4_ = 0.0; - gint _tmp5_ = 0; - gint _tmp6_ = 0; - GdkEventButton* _tmp7_ = NULL; - gdouble _tmp8_ = 0.0; - gint _tmp9_ = 0; - gint _tmp10_ = 0; - PageView* _tmp11_ = NULL; - PageView* _tmp12_ = NULL; -#line 499 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp3_ = event; -#line 499 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp4_ = _tmp3_->x; -#line 499 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp5_ = book_view_get_x_offset (self); -#line 499 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp6_ = _tmp5_; -#line 499 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp7_ = event; -#line 499 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp8_ = _tmp7_->y; -#line 499 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp11_ = book_view_get_page_at (self, (gint) (_tmp4_ + _tmp6_), (gint) _tmp8_, &_tmp9_, &_tmp10_); -#line 499 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - x = _tmp9_; -#line 499 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - y = _tmp10_; -#line 499 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp12_ = _tmp11_; -#line 499 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - book_view_select_page_view (self, _tmp12_); -#line 499 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _page_view_unref0 (_tmp12_); -#line 2910 "book-view.c" - } -#line 501 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp13_ = self->priv->selected_page_view; -#line 501 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - if (_tmp13_ == NULL) { -#line 502 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - result = FALSE; -#line 502 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - return result; -#line 2920 "book-view.c" - } -#line 505 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp14_ = event; -#line 505 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp15_ = _tmp14_->button; -#line 505 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - if (_tmp15_ == ((guint) 1)) { -#line 2928 "book-view.c" - GdkEventButton* _tmp16_ = NULL; - GdkEventType _tmp17_ = 0; -#line 507 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp16_ = event; -#line 507 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp17_ = _tmp16_->type; -#line 507 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - if (_tmp17_ == GDK_BUTTON_PRESS) { -#line 2937 "book-view.c" - PageView* _tmp18_ = NULL; - gint _tmp19_ = 0; - gint _tmp20_ = 0; -#line 508 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp18_ = self->priv->selected_page_view; -#line 508 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp19_ = x; -#line 508 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp20_ = y; -#line 508 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - page_view_button_press (_tmp18_, _tmp19_, _tmp20_); -#line 2949 "book-view.c" - } else { - GdkEventButton* _tmp21_ = NULL; - GdkEventType _tmp22_ = 0; -#line 509 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp21_ = event; -#line 509 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp22_ = _tmp21_->type; -#line 509 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - if (_tmp22_ == GDK_BUTTON_RELEASE) { -#line 2959 "book-view.c" - PageView* _tmp23_ = NULL; - gint _tmp24_ = 0; - gint _tmp25_ = 0; -#line 510 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp23_ = self->priv->selected_page_view; -#line 510 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp24_ = x; -#line 510 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp25_ = y; -#line 510 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - page_view_button_release (_tmp23_, _tmp24_, _tmp25_); -#line 2971 "book-view.c" - } else { - GdkEventButton* _tmp26_ = NULL; - GdkEventType _tmp27_ = 0; -#line 511 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp26_ = event; -#line 511 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp27_ = _tmp26_->type; -#line 511 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - if (_tmp27_ == GDK_2BUTTON_PRESS) { -#line 2981 "book-view.c" - Page* _tmp28_ = NULL; - Page* _tmp29_ = NULL; -#line 512 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp28_ = book_view_get_selected_page (self); -#line 512 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp29_ = _tmp28_; -#line 512 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - g_signal_emit_by_name (self, "show-page", _tmp29_); -#line 2990 "book-view.c" - } - } - } - } -#line 516 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp30_ = event; -#line 516 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp31_ = _tmp30_->button; -#line 516 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - if (_tmp31_ == ((guint) 3)) { -#line 517 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - g_signal_emit_by_name (self, "show-menu"); -#line 3003 "book-view.c" - } -#line 519 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - result = FALSE; -#line 519 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - return result; -#line 3009 "book-view.c" -} - - -static void book_view_set_cursor (BookView* self, GdkCursorType cursor) { - GdkCursor* c = NULL; - GdkCursorType _tmp0_ = 0; - GdkCursorType _tmp1_ = 0; - GdkCursorType _tmp2_ = 0; - GdkDisplay* _tmp3_ = NULL; - GdkCursorType _tmp4_ = 0; - GdkCursor* _tmp5_ = NULL; - GtkWidget* _tmp6_ = NULL; - GdkWindow* _tmp7_ = NULL; - GdkCursor* _tmp8_ = NULL; -#line 522 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - g_return_if_fail (self != NULL); -#line 526 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp0_ = self->priv->cursor; -#line 526 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp1_ = cursor; -#line 526 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - if (_tmp0_ == _tmp1_) { -#line 527 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _g_object_unref0 (c); -#line 527 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - return; -#line 3036 "book-view.c" - } -#line 528 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp2_ = cursor; -#line 528 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - self->priv->cursor = _tmp2_; -#line 530 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp3_ = gtk_widget_get_display ((GtkWidget*) self); -#line 530 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp4_ = cursor; -#line 530 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp5_ = gdk_cursor_new_for_display (_tmp3_, _tmp4_); -#line 530 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _g_object_unref0 (c); -#line 530 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - c = _tmp5_; -#line 531 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp6_ = self->priv->drawing_area; -#line 531 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp7_ = gtk_widget_get_window (_tmp6_); -#line 531 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp8_ = c; -#line 531 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - gdk_window_set_cursor (_tmp7_, _tmp8_); -#line 522 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _g_object_unref0 (c); -#line 3062 "book-view.c" -} - - -static gboolean book_view_motion_cb (BookView* self, GtkWidget* widget, GdkEventMotion* event) { - gboolean result = FALSE; - GdkCursorType cursor = 0; - gboolean _tmp0_ = FALSE; - PageView* _tmp1_ = NULL; - GdkCursorType _tmp38_ = 0; -#line 534 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - g_return_val_if_fail (self != NULL, FALSE); -#line 534 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - g_return_val_if_fail (widget != NULL, FALSE); -#line 534 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - g_return_val_if_fail (event != NULL, FALSE); -#line 536 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - cursor = GDK_ARROW; -#line 539 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp1_ = self->priv->selected_page_view; -#line 539 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - if (_tmp1_ != NULL) { -#line 3084 "book-view.c" - GdkEventMotion* _tmp2_ = NULL; - GdkModifierType _tmp3_ = 0; -#line 539 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp2_ = event; -#line 539 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp3_ = _tmp2_->state; -#line 539 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp0_ = (_tmp3_ & GDK_BUTTON1_MASK) != 0; -#line 3093 "book-view.c" - } else { -#line 539 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp0_ = FALSE; -#line 3097 "book-view.c" - } -#line 539 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - if (_tmp0_) { -#line 3101 "book-view.c" - gint x = 0; - GdkEventMotion* _tmp4_ = NULL; - gdouble _tmp5_ = 0.0; - gint _tmp6_ = 0; - gint _tmp7_ = 0; - PageView* _tmp8_ = NULL; - gint _tmp9_ = 0; - gint _tmp10_ = 0; - gint y = 0; - GdkEventMotion* _tmp11_ = NULL; - gdouble _tmp12_ = 0.0; - PageView* _tmp13_ = NULL; - gint _tmp14_ = 0; - gint _tmp15_ = 0; - PageView* _tmp16_ = NULL; - gint _tmp17_ = 0; - gint _tmp18_ = 0; - PageView* _tmp19_ = NULL; - GdkCursorType _tmp20_ = 0; - GdkCursorType _tmp21_ = 0; -#line 541 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp4_ = event; -#line 541 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp5_ = _tmp4_->x; -#line 541 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp6_ = book_view_get_x_offset (self); -#line 541 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp7_ = _tmp6_; -#line 541 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp8_ = self->priv->selected_page_view; -#line 541 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp9_ = page_view_get_x_offset (_tmp8_); -#line 541 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp10_ = _tmp9_; -#line 541 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - x = (gint) ((_tmp5_ + _tmp7_) - _tmp10_); -#line 542 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp11_ = event; -#line 542 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp12_ = _tmp11_->y; -#line 542 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp13_ = self->priv->selected_page_view; -#line 542 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp14_ = page_view_get_y_offset (_tmp13_); -#line 542 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp15_ = _tmp14_; -#line 542 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - y = (gint) (_tmp12_ - _tmp15_); -#line 543 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp16_ = self->priv->selected_page_view; -#line 543 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp17_ = x; -#line 543 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp18_ = y; -#line 543 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - page_view_motion (_tmp16_, _tmp17_, _tmp18_); -#line 544 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp19_ = self->priv->selected_page_view; -#line 544 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp20_ = page_view_get_cursor (_tmp19_); -#line 544 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp21_ = _tmp20_; -#line 544 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - cursor = _tmp21_; -#line 3166 "book-view.c" - } else { - gint x = 0; - gint y = 0; - PageView* over_page = NULL; - GdkEventMotion* _tmp22_ = NULL; - gdouble _tmp23_ = 0.0; - gint _tmp24_ = 0; - gint _tmp25_ = 0; - GdkEventMotion* _tmp26_ = NULL; - gdouble _tmp27_ = 0.0; - gint _tmp28_ = 0; - gint _tmp29_ = 0; - PageView* _tmp30_ = NULL; - PageView* _tmp31_ = NULL; -#line 549 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp22_ = event; -#line 549 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp23_ = _tmp22_->x; -#line 549 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp24_ = book_view_get_x_offset (self); -#line 549 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp25_ = _tmp24_; -#line 549 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp26_ = event; -#line 549 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp27_ = _tmp26_->y; -#line 549 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp30_ = book_view_get_page_at (self, (gint) (_tmp23_ + _tmp25_), (gint) _tmp27_, &_tmp28_, &_tmp29_); -#line 549 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - x = _tmp28_; -#line 549 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - y = _tmp29_; -#line 549 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - over_page = _tmp30_; -#line 550 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp31_ = over_page; -#line 550 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - if (_tmp31_ != NULL) { -#line 3205 "book-view.c" - PageView* _tmp32_ = NULL; - gint _tmp33_ = 0; - gint _tmp34_ = 0; - PageView* _tmp35_ = NULL; - GdkCursorType _tmp36_ = 0; - GdkCursorType _tmp37_ = 0; -#line 552 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp32_ = over_page; -#line 552 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp33_ = x; -#line 552 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp34_ = y; -#line 552 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - page_view_motion (_tmp32_, _tmp33_, _tmp34_); -#line 553 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp35_ = over_page; -#line 553 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp36_ = page_view_get_cursor (_tmp35_); -#line 553 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp37_ = _tmp36_; -#line 553 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - cursor = _tmp37_; -#line 3228 "book-view.c" - } -#line 539 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _page_view_unref0 (over_page); -#line 3232 "book-view.c" - } -#line 557 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp38_ = cursor; -#line 557 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - book_view_set_cursor (self, _tmp38_); -#line 559 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - result = FALSE; -#line 559 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - return result; -#line 3242 "book-view.c" -} - - -static gboolean book_view_key_cb (BookView* self, GtkWidget* widget, GdkEventKey* event) { - gboolean result = FALSE; - GdkEventKey* _tmp0_ = NULL; - guint _tmp1_ = 0U; -#line 562 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - g_return_val_if_fail (self != NULL, FALSE); -#line 562 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - g_return_val_if_fail (widget != NULL, FALSE); -#line 562 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - g_return_val_if_fail (event != NULL, FALSE); -#line 564 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp0_ = event; -#line 564 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp1_ = _tmp0_->keyval; -#line 564 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - switch (_tmp1_) { -#line 564 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - case 0xff50: -#line 3264 "book-view.c" - { - Book* _tmp2_ = NULL; - Page* _tmp3_ = NULL; - Page* _tmp4_ = NULL; -#line 567 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp2_ = self->priv->_book; -#line 567 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp3_ = book_get_page (_tmp2_, 0); -#line 567 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp4_ = _tmp3_; -#line 567 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - book_view_set_selected_page (self, _tmp4_); -#line 567 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _page_unref0 (_tmp4_); -#line 568 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - result = TRUE; -#line 568 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - return result; -#line 3283 "book-view.c" - } -#line 564 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - case 0xff51: -#line 3287 "book-view.c" - { - PageView* _tmp5_ = NULL; - PageView* _tmp6_ = NULL; - PageView* _tmp7_ = NULL; -#line 570 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp5_ = self->priv->selected_page_view; -#line 570 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp6_ = book_view_get_prev_page (self, _tmp5_); -#line 570 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp7_ = _tmp6_; -#line 570 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - book_view_select_page_view (self, _tmp7_); -#line 570 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _page_view_unref0 (_tmp7_); -#line 571 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - result = TRUE; -#line 571 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - return result; -#line 3306 "book-view.c" - } -#line 564 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - case 0xff53: -#line 3310 "book-view.c" - { - PageView* _tmp8_ = NULL; - PageView* _tmp9_ = NULL; - PageView* _tmp10_ = NULL; -#line 573 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp8_ = self->priv->selected_page_view; -#line 573 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp9_ = book_view_get_next_page (self, _tmp8_); -#line 573 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp10_ = _tmp9_; -#line 573 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - book_view_select_page_view (self, _tmp10_); -#line 573 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _page_view_unref0 (_tmp10_); -#line 574 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - result = TRUE; -#line 574 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - return result; -#line 3329 "book-view.c" - } -#line 564 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - case 0xFF57: -#line 3333 "book-view.c" - { - Book* _tmp11_ = NULL; - Book* _tmp12_ = NULL; - guint _tmp13_ = 0U; - guint _tmp14_ = 0U; - Page* _tmp15_ = NULL; - Page* _tmp16_ = NULL; -#line 576 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp11_ = self->priv->_book; -#line 576 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp12_ = self->priv->_book; -#line 576 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp13_ = book_get_n_pages (_tmp12_); -#line 576 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp14_ = _tmp13_; -#line 576 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp15_ = book_get_page (_tmp11_, ((gint) _tmp14_) - 1); -#line 576 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp16_ = _tmp15_; -#line 576 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - book_view_set_selected_page (self, _tmp16_); -#line 576 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _page_unref0 (_tmp16_); -#line 577 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - result = TRUE; -#line 577 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - return result; -#line 3361 "book-view.c" - } - default: - { -#line 580 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - result = FALSE; -#line 580 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - return result; -#line 3369 "book-view.c" - } - } -} - - -static gboolean book_view_focus_cb (BookView* self, GtkWidget* widget, GdkEventFocus* event) { - gboolean result = FALSE; - PageView* _tmp0_ = NULL; -#line 584 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - g_return_val_if_fail (self != NULL, FALSE); -#line 584 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - g_return_val_if_fail (widget != NULL, FALSE); -#line 584 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - g_return_val_if_fail (event != NULL, FALSE); -#line 586 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp0_ = self->priv->selected_page_view; -#line 586 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - book_view_set_selected_page_view (self, _tmp0_); -#line 587 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - result = FALSE; -#line 587 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - return result; -#line 3392 "book-view.c" -} - - -static void book_view_scroll_cb (BookView* self, GtkAdjustment* adjustment) { - gboolean _tmp0_ = FALSE; -#line 590 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - g_return_if_fail (self != NULL); -#line 590 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - g_return_if_fail (adjustment != NULL); -#line 592 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp0_ = self->priv->laying_out; -#line 592 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - if (!_tmp0_) { -#line 593 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - book_view_redraw (self); -#line 3408 "book-view.c" - } -} - - -void book_view_redraw (BookView* self) { - GtkWidget* _tmp0_ = NULL; -#line 596 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - g_return_if_fail (self != NULL); -#line 598 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp0_ = self->priv->drawing_area; -#line 598 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - gtk_widget_queue_draw (_tmp0_); -#line 3421 "book-view.c" -} - - -void book_view_select_next_page (BookView* self) { - PageView* _tmp0_ = NULL; - PageView* _tmp1_ = NULL; - PageView* _tmp2_ = NULL; -#line 601 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - g_return_if_fail (self != NULL); -#line 603 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp0_ = self->priv->selected_page_view; -#line 603 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp1_ = book_view_get_next_page (self, _tmp0_); -#line 603 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp2_ = _tmp1_; -#line 603 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - book_view_select_page_view (self, _tmp2_); -#line 603 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _page_view_unref0 (_tmp2_); -#line 3441 "book-view.c" -} - - -void book_view_select_prev_page (BookView* self) { - PageView* _tmp0_ = NULL; - PageView* _tmp1_ = NULL; - PageView* _tmp2_ = NULL; -#line 606 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - g_return_if_fail (self != NULL); -#line 608 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp0_ = self->priv->selected_page_view; -#line 608 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp1_ = book_view_get_prev_page (self, _tmp0_); -#line 608 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp2_ = _tmp1_; -#line 608 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - book_view_select_page_view (self, _tmp2_); -#line 608 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _page_view_unref0 (_tmp2_); -#line 3461 "book-view.c" -} - - -Book* book_view_get_book (BookView* self) { - Book* result; - Book* _tmp0_ = NULL; -#line 18 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - g_return_val_if_fail (self != NULL, NULL); -#line 18 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp0_ = self->priv->_book; -#line 18 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - result = _tmp0_; -#line 18 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - return result; -#line 3476 "book-view.c" -} - - -static gpointer _book_ref0 (gpointer self) { -#line 18 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - return self ? book_ref (self) : NULL; -#line 3483 "book-view.c" -} - - -static void book_view_set_book (BookView* self, Book* value) { - Book* _tmp0_ = NULL; - Book* _tmp1_ = NULL; -#line 18 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - g_return_if_fail (self != NULL); -#line 18 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp0_ = value; -#line 18 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp1_ = _book_ref0 (_tmp0_); -#line 18 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _book_unref0 (self->priv->_book); -#line 18 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - self->priv->_book = _tmp1_; -#line 18 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - g_object_notify ((GObject *) self, "book"); -#line 3502 "book-view.c" -} - - -Page* book_view_get_selected_page (BookView* self) { - Page* result; - PageView* _tmp0_ = NULL; -#line 30 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - g_return_val_if_fail (self != NULL, NULL); -#line 32 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp0_ = self->priv->selected_page_view; -#line 32 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - if (_tmp0_ != NULL) { -#line 3515 "book-view.c" - PageView* _tmp1_ = NULL; - Page* _tmp2_ = NULL; - Page* _tmp3_ = NULL; -#line 33 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp1_ = self->priv->selected_page_view; -#line 33 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp2_ = page_view_get_page (_tmp1_); -#line 33 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp3_ = _tmp2_; -#line 33 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - result = _tmp3_; -#line 33 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - return result; -#line 3529 "book-view.c" - } else { -#line 35 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - result = NULL; -#line 35 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - return result; -#line 3535 "book-view.c" - } -} - - -void book_view_set_selected_page (BookView* self, Page* value) { - Page* _tmp0_ = NULL; - Page* _tmp1_ = NULL; - Page* _tmp2_ = NULL; - Page* _tmp3_ = NULL; -#line 37 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - g_return_if_fail (self != NULL); -#line 39 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp0_ = book_view_get_selected_page (self); -#line 39 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp1_ = _tmp0_; -#line 39 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp2_ = value; -#line 39 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - if (_tmp1_ == _tmp2_) { -#line 40 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - return; -#line 3557 "book-view.c" - } -#line 42 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp3_ = value; -#line 42 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - if (_tmp3_ != NULL) { -#line 3563 "book-view.c" - GHashTable* _tmp4_ = NULL; - Page* _tmp5_ = NULL; - gconstpointer _tmp6_ = NULL; -#line 43 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp4_ = self->priv->page_data; -#line 43 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp5_ = value; -#line 43 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp6_ = g_hash_table_lookup (_tmp4_, _tmp5_); -#line 43 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - book_view_select_page_view (self, (PageView*) _tmp6_); -#line 3575 "book-view.c" - } else { -#line 45 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - book_view_select_page_view (self, NULL); -#line 3579 "book-view.c" - } -#line 37 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - g_object_notify ((GObject *) self, "selected-page"); -#line 3583 "book-view.c" -} - - -gint book_view_get_x_offset (BookView* self) { - gint result; - GtkAdjustment* _tmp0_ = NULL; - gdouble _tmp1_ = 0.0; -#line 64 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - g_return_val_if_fail (self != NULL, 0); -#line 66 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp0_ = self->priv->adjustment; -#line 66 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp1_ = gtk_adjustment_get_value (_tmp0_); -#line 66 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - result = (gint) _tmp1_; -#line 66 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - return result; -#line 3601 "book-view.c" -} - - -void book_view_set_x_offset (BookView* self, gint value) { - GtkAdjustment* _tmp0_ = NULL; - gint _tmp1_ = 0; -#line 68 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - g_return_if_fail (self != NULL); -#line 70 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp0_ = self->priv->adjustment; -#line 70 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp1_ = value; -#line 70 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - gtk_adjustment_set_value (_tmp0_, (gdouble) _tmp1_); -#line 68 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - g_object_notify ((GObject *) self, "x-offset"); -#line 3618 "book-view.c" -} - - -static void g_cclosure_user_marshal_VOID__PAGE (GClosure * closure, GValue * return_value, guint n_param_values, const GValue * param_values, gpointer invocation_hint, gpointer marshal_data) { - typedef void (*GMarshalFunc_VOID__PAGE) (gpointer data1, gpointer arg_1, gpointer data2); - register GMarshalFunc_VOID__PAGE callback; - register GCClosure * cc; - register gpointer data1; - register gpointer data2; - cc = (GCClosure *) closure; -#line 15 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - g_return_if_fail (n_param_values == 2); -#line 15 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - if (G_CCLOSURE_SWAP_DATA (closure)) { -#line 15 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - data1 = closure->data; -#line 15 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - data2 = param_values->data[0].v_pointer; -#line 3637 "book-view.c" - } else { -#line 15 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - data1 = param_values->data[0].v_pointer; -#line 15 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - data2 = closure->data; -#line 3643 "book-view.c" - } -#line 15 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - callback = (GMarshalFunc_VOID__PAGE) (marshal_data ? marshal_data : cc->callback); -#line 15 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - callback (data1, value_get_page (param_values + 1), data2); -#line 3649 "book-view.c" -} - - -static void book_view_class_init (BookViewClass * klass) { -#line 15 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - book_view_parent_class = g_type_class_peek_parent (klass); -#line 15 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - g_type_class_add_private (klass, sizeof (BookViewPrivate)); -#line 15 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - G_OBJECT_CLASS (klass)->get_property = _vala_book_view_get_property; -#line 15 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - G_OBJECT_CLASS (klass)->set_property = _vala_book_view_set_property; -#line 15 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - G_OBJECT_CLASS (klass)->finalize = book_view_finalize; -#line 15 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - g_object_class_install_property (G_OBJECT_CLASS (klass), BOOK_VIEW_BOOK, param_spec_book ("book", "book", "book", TYPE_BOOK, G_PARAM_STATIC_NAME | G_PARAM_STATIC_NICK | G_PARAM_STATIC_BLURB | G_PARAM_READABLE)); -#line 15 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - g_object_class_install_property (G_OBJECT_CLASS (klass), BOOK_VIEW_SELECTED_PAGE, param_spec_page ("selected-page", "selected-page", "selected-page", TYPE_PAGE, G_PARAM_STATIC_NAME | G_PARAM_STATIC_NICK | G_PARAM_STATIC_BLURB | G_PARAM_READABLE | G_PARAM_WRITABLE)); -#line 15 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - g_object_class_install_property (G_OBJECT_CLASS (klass), BOOK_VIEW_X_OFFSET, g_param_spec_int ("x-offset", "x-offset", "x-offset", G_MININT, G_MAXINT, 0, G_PARAM_STATIC_NAME | G_PARAM_STATIC_NICK | G_PARAM_STATIC_BLURB | G_PARAM_READABLE | G_PARAM_WRITABLE)); -#line 15 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - g_signal_new ("page_selected", TYPE_BOOK_VIEW, G_SIGNAL_RUN_LAST, 0, NULL, NULL, g_cclosure_user_marshal_VOID__PAGE, G_TYPE_NONE, 1, TYPE_PAGE); -#line 15 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - g_signal_new ("show_page", TYPE_BOOK_VIEW, G_SIGNAL_RUN_LAST, 0, NULL, NULL, g_cclosure_user_marshal_VOID__PAGE, G_TYPE_NONE, 1, TYPE_PAGE); -#line 15 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - g_signal_new ("show_menu", TYPE_BOOK_VIEW, G_SIGNAL_RUN_LAST, 0, NULL, NULL, g_cclosure_marshal_VOID__VOID, G_TYPE_NONE, 0); -#line 3676 "book-view.c" -} - - -static void book_view_instance_init (BookView * self) { -#line 15 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - self->priv = BOOK_VIEW_GET_PRIVATE (self); -#line 27 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - self->priv->selected_page_view = NULL; -#line 3685 "book-view.c" -} - - -static void book_view_finalize (GObject* obj) { - BookView * self; - Book* _tmp0_ = NULL; - guint _tmp1_ = 0U; - Book* _tmp2_ = NULL; - guint _tmp3_ = 0U; - Book* _tmp4_ = NULL; - guint _tmp5_ = 0U; - Book* _tmp6_ = NULL; - guint _tmp7_ = 0U; - GtkWidget* _tmp8_ = NULL; - guint _tmp9_ = 0U; - GtkWidget* _tmp10_ = NULL; - guint _tmp11_ = 0U; - GtkWidget* _tmp12_ = NULL; - guint _tmp13_ = 0U; - GtkWidget* _tmp14_ = NULL; - guint _tmp15_ = 0U; - GtkWidget* _tmp16_ = NULL; - guint _tmp17_ = 0U; - GtkWidget* _tmp18_ = NULL; - guint _tmp19_ = 0U; - GtkWidget* _tmp20_ = NULL; - guint _tmp21_ = 0U; - GtkWidget* _tmp22_ = NULL; - guint _tmp23_ = 0U; - GtkAdjustment* _tmp24_ = NULL; - guint _tmp25_ = 0U; -#line 15 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - self = G_TYPE_CHECK_INSTANCE_CAST (obj, TYPE_BOOK_VIEW, BookView); -#line 123 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp0_ = self->priv->_book; -#line 123 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - g_signal_parse_name ("page-added", TYPE_BOOK, &_tmp1_, NULL, FALSE); -#line 123 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - g_signal_handlers_disconnect_matched (_tmp0_, G_SIGNAL_MATCH_ID | G_SIGNAL_MATCH_FUNC | G_SIGNAL_MATCH_DATA, _tmp1_, 0, NULL, (GCallback) _book_view_add_cb_book_page_added, self); -#line 124 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp2_ = self->priv->_book; -#line 124 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - g_signal_parse_name ("page-removed", TYPE_BOOK, &_tmp3_, NULL, FALSE); -#line 124 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - g_signal_handlers_disconnect_matched (_tmp2_, G_SIGNAL_MATCH_ID | G_SIGNAL_MATCH_FUNC | G_SIGNAL_MATCH_DATA, _tmp3_, 0, NULL, (GCallback) _book_view_remove_cb_book_page_removed, self); -#line 125 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp4_ = self->priv->_book; -#line 125 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - g_signal_parse_name ("reordered", TYPE_BOOK, &_tmp5_, NULL, FALSE); -#line 125 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - g_signal_handlers_disconnect_matched (_tmp4_, G_SIGNAL_MATCH_ID | G_SIGNAL_MATCH_FUNC | G_SIGNAL_MATCH_DATA, _tmp5_, 0, NULL, (GCallback) _book_view_reorder_cb_book_reordered, self); -#line 126 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp6_ = self->priv->_book; -#line 126 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - g_signal_parse_name ("cleared", TYPE_BOOK, &_tmp7_, NULL, FALSE); -#line 126 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - g_signal_handlers_disconnect_matched (_tmp6_, G_SIGNAL_MATCH_ID | G_SIGNAL_MATCH_FUNC | G_SIGNAL_MATCH_DATA, _tmp7_, 0, NULL, (GCallback) _book_view_clear_cb_book_cleared, self); -#line 127 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp8_ = self->priv->drawing_area; -#line 127 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - g_signal_parse_name ("configure-event", gtk_widget_get_type (), &_tmp9_, NULL, FALSE); -#line 127 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - g_signal_handlers_disconnect_matched (_tmp8_, G_SIGNAL_MATCH_ID | G_SIGNAL_MATCH_FUNC | G_SIGNAL_MATCH_DATA, _tmp9_, 0, NULL, (GCallback) _book_view_configure_cb_gtk_widget_configure_event, self); -#line 128 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp10_ = self->priv->drawing_area; -#line 128 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - g_signal_parse_name ("draw", gtk_widget_get_type (), &_tmp11_, NULL, FALSE); -#line 128 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - g_signal_handlers_disconnect_matched (_tmp10_, G_SIGNAL_MATCH_ID | G_SIGNAL_MATCH_FUNC | G_SIGNAL_MATCH_DATA, _tmp11_, 0, NULL, (GCallback) _book_view_draw_cb_gtk_widget_draw, self); -#line 129 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp12_ = self->priv->drawing_area; -#line 129 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - g_signal_parse_name ("motion-notify-event", gtk_widget_get_type (), &_tmp13_, NULL, FALSE); -#line 129 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - g_signal_handlers_disconnect_matched (_tmp12_, G_SIGNAL_MATCH_ID | G_SIGNAL_MATCH_FUNC | G_SIGNAL_MATCH_DATA, _tmp13_, 0, NULL, (GCallback) _book_view_motion_cb_gtk_widget_motion_notify_event, self); -#line 130 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp14_ = self->priv->drawing_area; -#line 130 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - g_signal_parse_name ("key-press-event", gtk_widget_get_type (), &_tmp15_, NULL, FALSE); -#line 130 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - g_signal_handlers_disconnect_matched (_tmp14_, G_SIGNAL_MATCH_ID | G_SIGNAL_MATCH_FUNC | G_SIGNAL_MATCH_DATA, _tmp15_, 0, NULL, (GCallback) _book_view_key_cb_gtk_widget_key_press_event, self); -#line 131 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp16_ = self->priv->drawing_area; -#line 131 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - g_signal_parse_name ("button-press-event", gtk_widget_get_type (), &_tmp17_, NULL, FALSE); -#line 131 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - g_signal_handlers_disconnect_matched (_tmp16_, G_SIGNAL_MATCH_ID | G_SIGNAL_MATCH_FUNC | G_SIGNAL_MATCH_DATA, _tmp17_, 0, NULL, (GCallback) _book_view_button_cb_gtk_widget_button_press_event, self); -#line 132 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp18_ = self->priv->drawing_area; -#line 132 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - g_signal_parse_name ("button-release-event", gtk_widget_get_type (), &_tmp19_, NULL, FALSE); -#line 132 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - g_signal_handlers_disconnect_matched (_tmp18_, G_SIGNAL_MATCH_ID | G_SIGNAL_MATCH_FUNC | G_SIGNAL_MATCH_DATA, _tmp19_, 0, NULL, (GCallback) _book_view_button_cb_gtk_widget_button_release_event, self); -#line 133 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp20_ = self->priv->drawing_area; -#line 133 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - g_signal_parse_name ("focus-in-event", gtk_widget_get_type (), &_tmp21_, NULL, FALSE); -#line 133 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - g_signal_handlers_disconnect_matched (_tmp20_, G_SIGNAL_MATCH_ID | G_SIGNAL_MATCH_FUNC | G_SIGNAL_MATCH_DATA, _tmp21_, 0, NULL, (GCallback) _book_view_focus_cb_gtk_widget_focus_in_event, self); -#line 134 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp22_ = self->priv->drawing_area; -#line 134 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - g_signal_parse_name ("focus-out-event", gtk_widget_get_type (), &_tmp23_, NULL, FALSE); -#line 134 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - g_signal_handlers_disconnect_matched (_tmp22_, G_SIGNAL_MATCH_ID | G_SIGNAL_MATCH_FUNC | G_SIGNAL_MATCH_DATA, _tmp23_, 0, NULL, (GCallback) _book_view_focus_cb_gtk_widget_focus_out_event, self); -#line 135 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _tmp24_ = self->priv->adjustment; -#line 135 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - g_signal_parse_name ("value-changed", gtk_adjustment_get_type (), &_tmp25_, NULL, FALSE); -#line 135 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - g_signal_handlers_disconnect_matched (_tmp24_, G_SIGNAL_MATCH_ID | G_SIGNAL_MATCH_FUNC | G_SIGNAL_MATCH_DATA, _tmp25_, 0, NULL, (GCallback) _book_view_scroll_cb_gtk_adjustment_value_changed, self); -#line 18 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _book_unref0 (self->priv->_book); -#line 19 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _g_hash_table_unref0 (self->priv->page_data); -#line 27 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _page_view_unref0 (self->priv->selected_page_view); -#line 50 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _g_object_unref0 (self->priv->drawing_area); -#line 53 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _g_object_unref0 (self->priv->scroll); -#line 54 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - _g_object_unref0 (self->priv->adjustment); -#line 15 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - G_OBJECT_CLASS (book_view_parent_class)->finalize (obj); -#line 3811 "book-view.c" -} - - -GType book_view_get_type (void) { - static volatile gsize book_view_type_id__volatile = 0; - if (g_once_init_enter (&book_view_type_id__volatile)) { - static const GTypeInfo g_define_type_info = { sizeof (BookViewClass), (GBaseInitFunc) NULL, (GBaseFinalizeFunc) NULL, (GClassInitFunc) book_view_class_init, (GClassFinalizeFunc) NULL, NULL, sizeof (BookView), 0, (GInstanceInitFunc) book_view_instance_init, NULL }; - GType book_view_type_id; - book_view_type_id = g_type_register_static (gtk_box_get_type (), "BookView", &g_define_type_info, 0); - g_once_init_leave (&book_view_type_id__volatile, book_view_type_id); - } - return book_view_type_id__volatile; -} - - -static void _vala_book_view_get_property (GObject * object, guint property_id, GValue * value, GParamSpec * pspec) { - BookView * self; - self = G_TYPE_CHECK_INSTANCE_CAST (object, TYPE_BOOK_VIEW, BookView); -#line 15 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - switch (property_id) { -#line 15 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - case BOOK_VIEW_BOOK: -#line 15 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - value_set_book (value, book_view_get_book (self)); -#line 15 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - break; -#line 15 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - case BOOK_VIEW_SELECTED_PAGE: -#line 15 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - value_set_page (value, book_view_get_selected_page (self)); -#line 15 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - break; -#line 15 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - case BOOK_VIEW_X_OFFSET: -#line 15 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - g_value_set_int (value, book_view_get_x_offset (self)); -#line 15 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - break; -#line 3850 "book-view.c" - default: -#line 15 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - G_OBJECT_WARN_INVALID_PROPERTY_ID (object, property_id, pspec); -#line 15 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - break; -#line 3856 "book-view.c" - } -} - - -static void _vala_book_view_set_property (GObject * object, guint property_id, const GValue * value, GParamSpec * pspec) { - BookView * self; - self = G_TYPE_CHECK_INSTANCE_CAST (object, TYPE_BOOK_VIEW, BookView); -#line 15 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - switch (property_id) { -#line 15 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - case BOOK_VIEW_BOOK: -#line 15 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - book_view_set_book (self, value_get_book (value)); -#line 15 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - break; -#line 15 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - case BOOK_VIEW_SELECTED_PAGE: -#line 15 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - book_view_set_selected_page (self, value_get_page (value)); -#line 15 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - break; -#line 15 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - case BOOK_VIEW_X_OFFSET: -#line 15 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - book_view_set_x_offset (self, g_value_get_int (value)); -#line 15 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - break; -#line 3884 "book-view.c" - default: -#line 15 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - G_OBJECT_WARN_INVALID_PROPERTY_ID (object, property_id, pspec); -#line 15 "/home/bob/bzr/simple-scan/trunk/src/book-view.vala" - break; -#line 3890 "book-view.c" - } -} - - - diff --git a/src/book-view.vala b/src/book-view.vala index 069525e..182edc7 100644 --- a/src/book-view.vala +++ b/src/book-view.vala @@ -23,6 +23,20 @@ public class BookView : Gtk.Box private bool laying_out; private bool show_selected_page; + /* Page to show when book empty */ + private PageView? default_page_view = null; + public Page default_page + { + set + { + if (value == null) + default_page_view = null; + else + default_page_view = new PageView (value); + need_layout = true; + } + } + /* Currently selected page */ private PageView? selected_page_view = null; public Page? selected_page @@ -295,26 +309,38 @@ public class BookView : Gtk.Box private void layout_into (int width, int height, out int book_width, out int book_height) { + var pages = new List (); + if (book.n_pages == 0) + { + if (default_page_view != null) + pages.append (default_page_view); + } + else + { + for (var i = 0; i < book.n_pages; i++) + pages.append (get_nth_page (i)); + } + /* Get maximum page resolution */ int max_dpi = 0; - for (var i = 0; i < book.n_pages; i++) + foreach (var page in pages) { - var page = book.get_page (i); - if (page.dpi > max_dpi) - max_dpi = page.dpi; + var p = page.page; + if (p.dpi > max_dpi) + max_dpi = p.dpi; } /* Get area required to fit all pages */ int max_width = 0, max_height = 0; - for (var i = 0; i < book.n_pages; i++) + foreach (var page in pages) { - var page = book.get_page (i); - var w = page.width; - var h = page.height; + var p = page.page; + var w = p.width; + var h = p.height; /* Scale to the same DPI */ - w = (int) ((double)w * max_dpi / page.dpi + 0.5); - h = (int) ((double)h * max_dpi / page.dpi + 0.5); + w = (int) ((double)w * max_dpi / p.dpi + 0.5); + h = (int) ((double)h * max_dpi / p.dpi + 0.5); if (w > max_width) max_width = w; @@ -329,9 +355,8 @@ public class BookView : Gtk.Box int spacing = 12; book_width = 0; book_height = 0; - for (var i = 0; i < book.n_pages; i++) + foreach (var page in pages) { - var page = get_nth_page (i); var p = page.page; /* NOTE: Using double to avoid overflow for large images */ @@ -351,16 +376,14 @@ public class BookView : Gtk.Box var h = page.height; if (h > book_height) book_height = h; - book_width += page.width; - if (i != 0) - book_width += spacing; + book_width += page.width + spacing; } + if (pages != null) + book_width -= spacing; int x_offset = 0; - for (var i = 0; i < book.n_pages; i++) + foreach (var page in pages) { - var page = get_nth_page (i); - /* Layout pages left to right */ page.x_offset = x_offset; x_offset += page.width + spacing; @@ -432,18 +455,26 @@ public class BookView : Gtk.Box private bool draw_cb (Gtk.Widget widget, Cairo.Context context) { - if (book.n_pages == 0) - return false; - layout (); double left, top, right, bottom; context.clip_extents (out left, out top, out right, out bottom); + var pages = new List (); + if (book.n_pages == 0) + { + if (default_page_view != null) + pages.append (default_page_view); + } + else + { + for (var i = 0; i < book.n_pages; i++) + pages.append (get_nth_page (i)); + } + /* Render each page */ - for (var i = 0; i < book.n_pages; i++) + foreach (var page in pages) { - var page = get_nth_page (i); var left_edge = page.x_offset - x_offset; var right_edge = page.x_offset + page.width - x_offset; diff --git a/src/book.c b/src/book.c deleted file mode 100644 index a74c530..0000000 --- a/src/book.c +++ /dev/null @@ -1,6429 +0,0 @@ -/* book.c generated by valac 0.34.6, the Vala compiler - * generated from book.vala, do not modify */ - -/* - * Copyright (C) 2009-2015 Canonical Ltd. - * Author: Robert Ancell - * - * This program is free software: you can redistribute it and/or modify it under - * the terms of the GNU General Public License as published by the Free Software - * Foundation, either version 3 of the License, or (at your option) any later - * version. See http://www.gnu.org/copyleft/gpl.html the full text of the - * license. - */ - -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include - - -#define TYPE_BOOK (book_get_type ()) -#define BOOK(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), TYPE_BOOK, Book)) -#define BOOK_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST ((klass), TYPE_BOOK, BookClass)) -#define IS_BOOK(obj) (G_TYPE_CHECK_INSTANCE_TYPE ((obj), TYPE_BOOK)) -#define IS_BOOK_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE ((klass), TYPE_BOOK)) -#define BOOK_GET_CLASS(obj) (G_TYPE_INSTANCE_GET_CLASS ((obj), TYPE_BOOK, BookClass)) - -typedef struct _Book Book; -typedef struct _BookClass BookClass; -typedef struct _BookPrivate BookPrivate; - -#define TYPE_PAGE (page_get_type ()) -#define PAGE(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), TYPE_PAGE, Page)) -#define PAGE_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST ((klass), TYPE_PAGE, PageClass)) -#define IS_PAGE(obj) (G_TYPE_CHECK_INSTANCE_TYPE ((obj), TYPE_PAGE)) -#define IS_PAGE_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE ((klass), TYPE_PAGE)) -#define PAGE_GET_CLASS(obj) (G_TYPE_INSTANCE_GET_CLASS ((obj), TYPE_PAGE, PageClass)) - -typedef struct _Page Page; -typedef struct _PageClass PageClass; -#define _page_unref0(var) ((var == NULL) ? NULL : (var = (page_unref (var), NULL))) -#define __g_list_free__page_unref0_0(var) ((var == NULL) ? NULL : (var = (_g_list_free__page_unref0_ (var), NULL))) -#define _g_byte_array_unref0(var) ((var == NULL) ? NULL : (var = (g_byte_array_unref (var), NULL))) -#define _g_free0(var) (var = (g_free (var), NULL)) -#define _g_object_unref0(var) ((var == NULL) ? NULL : (var = (g_object_unref (var), NULL))) -#define _cairo_destroy0(var) ((var == NULL) ? NULL : (var = (cairo_destroy (var), NULL))) - -#define TYPE_PS_WRITER (ps_writer_get_type ()) -#define PS_WRITER(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), TYPE_PS_WRITER, PsWriter)) -#define PS_WRITER_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST ((klass), TYPE_PS_WRITER, PsWriterClass)) -#define IS_PS_WRITER(obj) (G_TYPE_CHECK_INSTANCE_TYPE ((obj), TYPE_PS_WRITER)) -#define IS_PS_WRITER_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE ((klass), TYPE_PS_WRITER)) -#define PS_WRITER_GET_CLASS(obj) (G_TYPE_INSTANCE_GET_CLASS ((obj), TYPE_PS_WRITER, PsWriterClass)) - -typedef struct _PsWriter PsWriter; -typedef struct _PsWriterClass PsWriterClass; -typedef struct _PsWriterPrivate PsWriterPrivate; -#define _cairo_surface_destroy0(var) ((var == NULL) ? NULL : (var = (cairo_surface_destroy (var), NULL))) -#define _ps_writer_unref0(var) ((var == NULL) ? NULL : (var = (ps_writer_unref (var), NULL))) -#define _g_error_free0(var) ((var == NULL) ? NULL : (var = (g_error_free (var), NULL))) - -#define TYPE_PDF_WRITER (pdf_writer_get_type ()) -#define PDF_WRITER(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), TYPE_PDF_WRITER, PDFWriter)) -#define PDF_WRITER_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST ((klass), TYPE_PDF_WRITER, PDFWriterClass)) -#define IS_PDF_WRITER(obj) (G_TYPE_CHECK_INSTANCE_TYPE ((obj), TYPE_PDF_WRITER)) -#define IS_PDF_WRITER_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE ((klass), TYPE_PDF_WRITER)) -#define PDF_WRITER_GET_CLASS(obj) (G_TYPE_INSTANCE_GET_CLASS ((obj), TYPE_PDF_WRITER, PDFWriterClass)) - -typedef struct _PDFWriter PDFWriter; -typedef struct _PDFWriterClass PDFWriterClass; -typedef struct _PDFWriterPrivate PDFWriterPrivate; -#define _g_date_time_unref0(var) ((var == NULL) ? NULL : (var = (g_date_time_unref (var), NULL))) -#define _pdf_writer_unref0(var) ((var == NULL) ? NULL : (var = (pdf_writer_unref (var), NULL))) -typedef struct _ParamSpecBook ParamSpecBook; -typedef struct _ParamSpecPDFWriter ParamSpecPDFWriter; -typedef struct _ParamSpecPsWriter ParamSpecPsWriter; - -struct _Book { - GTypeInstance parent_instance; - volatile int ref_count; - BookPrivate * priv; -}; - -struct _BookClass { - GTypeClass parent_class; - void (*finalize) (Book *self); -}; - -struct _BookPrivate { - GList* pages; - gboolean needs_saving_; - GByteArray* jpeg_data; -}; - -struct _PsWriter { - GTypeInstance parent_instance; - volatile int ref_count; - PsWriterPrivate * priv; - cairo_surface_t* surface; - GFileOutputStream* stream; -}; - -struct _PsWriterClass { - GTypeClass parent_class; - void (*finalize) (PsWriter *self); -}; - -struct _PDFWriter { - GTypeInstance parent_instance; - volatile int ref_count; - PDFWriterPrivate * priv; - gsize offset; - guint* object_offsets; - gint object_offsets_length1; - gint _object_offsets_size_; -}; - -struct _PDFWriterClass { - GTypeClass parent_class; - void (*finalize) (PDFWriter *self); -}; - -struct _ParamSpecBook { - GParamSpec parent_instance; -}; - -struct _PDFWriterPrivate { - GFileOutputStream* stream; -}; - -struct _ParamSpecPDFWriter { - GParamSpec parent_instance; -}; - -struct _ParamSpecPsWriter { - GParamSpec parent_instance; -}; - - -static gpointer book_parent_class = NULL; -static gpointer pdf_writer_parent_class = NULL; -static gpointer ps_writer_parent_class = NULL; - -gpointer book_ref (gpointer instance); -void book_unref (gpointer instance); -GParamSpec* param_spec_book (const gchar* name, const gchar* nick, const gchar* blurb, GType object_type, GParamFlags flags); -void value_set_book (GValue* value, gpointer v_object); -void value_take_book (GValue* value, gpointer v_object); -gpointer value_get_book (const GValue* value); -GType book_get_type (void) G_GNUC_CONST; -gpointer page_ref (gpointer instance); -void page_unref (gpointer instance); -GParamSpec* param_spec_page (const gchar* name, const gchar* nick, const gchar* blurb, GType object_type, GParamFlags flags); -void value_set_page (GValue* value, gpointer v_object); -void value_take_page (GValue* value, gpointer v_object); -gpointer value_get_page (const GValue* value); -GType page_get_type (void) G_GNUC_CONST; -#define BOOK_GET_PRIVATE(o) (G_TYPE_INSTANCE_GET_PRIVATE ((o), TYPE_BOOK, BookPrivate)) -enum { - BOOK_DUMMY_PROPERTY -}; -static void book_page_changed_cb (Book* self, Page* page); -static void _book_page_changed_cb_page_pixels_changed (Page* _sender, gpointer self); -static void _book_page_changed_cb_page_crop_changed (Page* _sender, gpointer self); -static void _page_unref0_ (gpointer var); -static void _g_list_free__page_unref0_ (GList* self); -Book* book_new (void); -Book* book_construct (GType object_type); -void book_clear (Book* self); -void book_set_needs_saving (Book* self, gboolean value); -void book_append_page (Book* self, Page* page); -void book_move_page (Book* self, Page* page, guint location); -void book_reverse (Book* self); -void book_combine_sides (Book* self); -guint book_get_n_pages (Book* self); -void book_combine_sides_reverse (Book* self); -void book_delete_page (Book* self, Page* page); -Page* book_get_page (Book* self, gint page_number); -guint book_get_page_index (Book* self, Page* page); -static GFile* book_make_indexed_file (Book* self, const gchar* uri, gint i); -static void book_save_multi_file (Book* self, const gchar* type, gint quality, GFile* file, GError** error); -void page_save (Page* self, const gchar* type, gint quality, GFile* file, GError** error); -static void book_save_ps_pdf_surface (Book* self, cairo_surface_t* surface, GdkPixbuf* image, gdouble dpi); -static void book_save_ps (Book* self, GFile* file, GError** error); -gpointer ps_writer_ref (gpointer instance); -void ps_writer_unref (gpointer instance); -GParamSpec* param_spec_ps_writer (const gchar* name, const gchar* nick, const gchar* blurb, GType object_type, GParamFlags flags); -void value_set_ps_writer (GValue* value, gpointer v_object); -void value_take_ps_writer (GValue* value, gpointer v_object); -gpointer value_get_ps_writer (const GValue* value); -GType ps_writer_get_type (void) G_GNUC_CONST; -PsWriter* ps_writer_new (GFileOutputStream* stream); -PsWriter* ps_writer_construct (GType object_type, GFileOutputStream* stream); -GdkPixbuf* page_get_image (Page* self, gboolean apply_crop); -gint page_get_dpi (Page* self); -static guint8* book_compress_zlib (Book* self, guint8* data, int data_length1, int* result_length1); -static guint8* book_compress_jpeg (Book* self, GdkPixbuf* image, gint quality, gint dpi, int* result_length1); -static gboolean book_write_pixbuf_data (Book* self, guint8* buf, int buf_length1, GError** error); -static gboolean _book_write_pixbuf_data_gdk_pixbuf_save_func (guint8* buf, gsize buf_length1, GError** error, gpointer self); -static void book_save_pdf (Book* self, GFile* file, gint quality, GError** error); -gpointer pdf_writer_ref (gpointer instance); -void pdf_writer_unref (gpointer instance); -GParamSpec* param_spec_pdf_writer (const gchar* name, const gchar* nick, const gchar* blurb, GType object_type, GParamFlags flags); -void value_set_pdf_writer (GValue* value, gpointer v_object); -void value_take_pdf_writer (GValue* value, gpointer v_object); -gpointer value_get_pdf_writer (const GValue* value); -GType pdf_writer_get_type (void) G_GNUC_CONST; -PDFWriter* pdf_writer_new (GFileOutputStream* stream); -PDFWriter* pdf_writer_construct (GType object_type, GFileOutputStream* stream); -guint pdf_writer_add_object (PDFWriter* self); -void pdf_writer_write_string (PDFWriter* self, const gchar* text); -void pdf_writer_start_object (PDFWriter* self, guint index); -gboolean page_get_is_color (Page* self); -gint page_get_depth (Page* self); -static guint8* _vala_array_dup1 (guint8* self, int length); -static guint8* _vala_array_dup2 (guint8* self, int length); -void pdf_writer_write (PDFWriter* self, guint8* data, int data_length1); -static gint book_next_empty_object (PDFWriter* writer, gint start); -void book_save (Book* self, const gchar* type, gint quality, GFile* file, GError** error); -gboolean book_get_needs_saving (Book* self); -static void g_cclosure_user_marshal_VOID__PAGE (GClosure * closure, GValue * return_value, guint n_param_values, const GValue * param_values, gpointer invocation_hint, gpointer marshal_data); -static void book_finalize (Book* obj); -#define PDF_WRITER_GET_PRIVATE(o) (G_TYPE_INSTANCE_GET_PRIVATE ((o), TYPE_PDF_WRITER, PDFWriterPrivate)) -enum { - PDF_WRITER_DUMMY_PROPERTY -}; -static void pdf_writer_finalize (PDFWriter* obj); -enum { - PS_WRITER_DUMMY_PROPERTY -}; -static cairo_status_t ps_writer_write_cairo_data (PsWriter* self, guint8* data, int data_length1); -static cairo_status_t _ps_writer_write_cairo_data_cairo_write_func_t (gpointer self, guchar* data, int data_length1); -static void ps_writer_finalize (PsWriter* obj); -static void _vala_array_destroy (gpointer array, gint array_length, GDestroyNotify destroy_func); -static void _vala_array_free (gpointer array, gint array_length, GDestroyNotify destroy_func); - - -static gpointer _page_ref0 (gpointer self) { -#line 45 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - return self ? page_ref (self) : NULL; -#line 251 "book.c" -} - - -static void _book_page_changed_cb_page_pixels_changed (Page* _sender, gpointer self) { -#line 47 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - book_page_changed_cb ((Book*) self, _sender); -#line 258 "book.c" -} - - -static void _book_page_changed_cb_page_crop_changed (Page* _sender, gpointer self) { -#line 48 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - book_page_changed_cb ((Book*) self, _sender); -#line 265 "book.c" -} - - -static void _page_unref0_ (gpointer var) { -#line 14 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - (var == NULL) ? NULL : (var = (page_unref (var), NULL)); -#line 272 "book.c" -} - - -static void _g_list_free__page_unref0_ (GList* self) { -#line 14 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - g_list_foreach (self, (GFunc) _page_unref0_, NULL); -#line 14 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - g_list_free (self); -#line 281 "book.c" -} - - -Book* book_construct (GType object_type) { - Book* self = NULL; -#line 38 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - self = (Book*) g_type_create_instance (object_type); -#line 40 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - __g_list_free__page_unref0_0 (self->priv->pages); -#line 40 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - self->priv->pages = NULL; -#line 38 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - return self; -#line 295 "book.c" -} - - -Book* book_new (void) { -#line 38 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - return book_construct (TYPE_BOOK); -#line 302 "book.c" -} - - -void book_clear (Book* self) { - GList* _tmp0_ = NULL; -#line 52 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - g_return_if_fail (self != NULL); -#line 54 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp0_ = self->priv->pages; -#line 312 "book.c" - { - GList* page_collection = NULL; - GList* page_it = NULL; -#line 54 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - page_collection = _tmp0_; -#line 54 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - for (page_it = page_collection; page_it != NULL; page_it = page_it->next) { -#line 320 "book.c" - Page* _tmp1_ = NULL; - Page* page = NULL; -#line 54 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp1_ = _page_ref0 ((Page*) page_it->data); -#line 54 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - page = _tmp1_; -#line 327 "book.c" - { - Page* _tmp2_ = NULL; - guint _tmp3_ = 0U; - Page* _tmp4_ = NULL; - guint _tmp5_ = 0U; -#line 56 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp2_ = page; -#line 56 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - g_signal_parse_name ("pixels-changed", TYPE_PAGE, &_tmp3_, NULL, FALSE); -#line 56 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - g_signal_handlers_disconnect_matched (_tmp2_, G_SIGNAL_MATCH_ID | G_SIGNAL_MATCH_FUNC | G_SIGNAL_MATCH_DATA, _tmp3_, 0, NULL, (GCallback) _book_page_changed_cb_page_pixels_changed, self); -#line 57 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp4_ = page; -#line 57 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - g_signal_parse_name ("crop-changed", TYPE_PAGE, &_tmp5_, NULL, FALSE); -#line 57 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - g_signal_handlers_disconnect_matched (_tmp4_, G_SIGNAL_MATCH_ID | G_SIGNAL_MATCH_FUNC | G_SIGNAL_MATCH_DATA, _tmp5_, 0, NULL, (GCallback) _book_page_changed_cb_page_crop_changed, self); -#line 54 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _page_unref0 (page); -#line 347 "book.c" - } - } - } -#line 59 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - __g_list_free__page_unref0_0 (self->priv->pages); -#line 59 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - self->priv->pages = NULL; -#line 60 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - g_signal_emit_by_name (self, "cleared"); -#line 357 "book.c" -} - - -static void book_page_changed_cb (Book* self, Page* page) { -#line 63 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - g_return_if_fail (self != NULL); -#line 63 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - g_return_if_fail (page != NULL); -#line 65 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - book_set_needs_saving (self, TRUE); -#line 368 "book.c" -} - - -void book_append_page (Book* self, Page* page) { - Page* _tmp0_ = NULL; - Page* _tmp1_ = NULL; - Page* _tmp2_ = NULL; - Page* _tmp3_ = NULL; - Page* _tmp4_ = NULL; -#line 68 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - g_return_if_fail (self != NULL); -#line 68 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - g_return_if_fail (page != NULL); -#line 70 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp0_ = page; -#line 70 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - g_signal_connect (_tmp0_, "pixels-changed", (GCallback) _book_page_changed_cb_page_pixels_changed, self); -#line 71 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp1_ = page; -#line 71 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - g_signal_connect (_tmp1_, "crop-changed", (GCallback) _book_page_changed_cb_page_crop_changed, self); -#line 73 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp2_ = page; -#line 73 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp3_ = _page_ref0 (_tmp2_); -#line 73 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - self->priv->pages = g_list_append (self->priv->pages, _tmp3_); -#line 74 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp4_ = page; -#line 74 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - g_signal_emit_by_name (self, "page-added", _tmp4_); -#line 75 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - book_set_needs_saving (self, TRUE); -#line 402 "book.c" -} - - -void book_move_page (Book* self, Page* page, guint location) { - Page* _tmp0_ = NULL; - Page* _tmp1_ = NULL; - Page* _tmp2_ = NULL; - guint _tmp3_ = 0U; -#line 78 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - g_return_if_fail (self != NULL); -#line 78 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - g_return_if_fail (page != NULL); -#line 80 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp0_ = page; -#line 80 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - self->priv->pages = g_list_remove (self->priv->pages, _tmp0_); -#line 81 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp1_ = page; -#line 81 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp2_ = _page_ref0 (_tmp1_); -#line 81 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp3_ = location; -#line 81 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - self->priv->pages = g_list_insert (self->priv->pages, _tmp2_, (gint) _tmp3_); -#line 82 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - g_signal_emit_by_name (self, "reordered"); -#line 83 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - book_set_needs_saving (self, TRUE); -#line 431 "book.c" -} - - -void book_reverse (Book* self) { - GList* new_pages = NULL; - GList* _tmp0_ = NULL; - GList* _tmp4_ = NULL; -#line 86 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - g_return_if_fail (self != NULL); -#line 88 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - new_pages = NULL; -#line 89 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp0_ = self->priv->pages; -#line 445 "book.c" - { - GList* page_collection = NULL; - GList* page_it = NULL; -#line 89 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - page_collection = _tmp0_; -#line 89 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - for (page_it = page_collection; page_it != NULL; page_it = page_it->next) { -#line 453 "book.c" - Page* _tmp1_ = NULL; - Page* page = NULL; -#line 89 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp1_ = _page_ref0 ((Page*) page_it->data); -#line 89 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - page = _tmp1_; -#line 460 "book.c" - { - Page* _tmp2_ = NULL; - Page* _tmp3_ = NULL; -#line 90 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp2_ = page; -#line 90 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp3_ = _page_ref0 (_tmp2_); -#line 90 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - new_pages = g_list_prepend (new_pages, _tmp3_); -#line 89 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _page_unref0 (page); -#line 472 "book.c" - } - } - } -#line 91 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp4_ = new_pages; -#line 91 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - new_pages = NULL; -#line 91 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - __g_list_free__page_unref0_0 (self->priv->pages); -#line 91 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - self->priv->pages = _tmp4_; -#line 93 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - g_signal_emit_by_name (self, "reordered"); -#line 94 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - book_set_needs_saving (self, TRUE); -#line 86 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - __g_list_free__page_unref0_0 (new_pages); -#line 490 "book.c" -} - - -void book_combine_sides (Book* self) { - guint n_front = 0U; - guint _tmp0_ = 0U; - guint _tmp1_ = 0U; - guint _tmp2_ = 0U; - guint _tmp3_ = 0U; - GList* new_pages = NULL; - GList* _tmp19_ = NULL; -#line 97 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - g_return_if_fail (self != NULL); -#line 99 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp0_ = book_get_n_pages (self); -#line 99 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp1_ = _tmp0_; -#line 99 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp2_ = book_get_n_pages (self); -#line 99 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp3_ = _tmp2_; -#line 99 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - n_front = _tmp1_ - (_tmp3_ / 2); -#line 100 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - new_pages = NULL; -#line 516 "book.c" - { - gint i = 0; -#line 101 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - i = 0; -#line 521 "book.c" - { - gboolean _tmp4_ = FALSE; -#line 101 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp4_ = TRUE; -#line 101 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - while (TRUE) { -#line 528 "book.c" - gint _tmp6_ = 0; - guint _tmp7_ = 0U; - guint _tmp8_ = 0U; - gint _tmp9_ = 0; -#line 101 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - if (!_tmp4_) { -#line 535 "book.c" - gint _tmp5_ = 0; -#line 101 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp5_ = i; -#line 101 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - i = _tmp5_ + 1; -#line 541 "book.c" - } -#line 101 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp4_ = FALSE; -#line 101 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp6_ = i; -#line 101 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp7_ = book_get_n_pages (self); -#line 101 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp8_ = _tmp7_; -#line 101 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - if (!(((guint) _tmp6_) < _tmp8_)) { -#line 101 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - break; -#line 555 "book.c" - } -#line 103 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp9_ = i; -#line 103 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - if ((_tmp9_ % 2) == 0) { -#line 561 "book.c" - GList* _tmp10_ = NULL; - gint _tmp11_ = 0; - gconstpointer _tmp12_ = NULL; - Page* _tmp13_ = NULL; -#line 104 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp10_ = self->priv->pages; -#line 104 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp11_ = i; -#line 104 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp12_ = g_list_nth_data (_tmp10_, (guint) (_tmp11_ / 2)); -#line 104 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp13_ = _page_ref0 ((Page*) _tmp12_); -#line 104 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - new_pages = g_list_append (new_pages, _tmp13_); -#line 576 "book.c" - } else { - GList* _tmp14_ = NULL; - guint _tmp15_ = 0U; - gint _tmp16_ = 0; - gconstpointer _tmp17_ = NULL; - Page* _tmp18_ = NULL; -#line 106 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp14_ = self->priv->pages; -#line 106 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp15_ = n_front; -#line 106 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp16_ = i; -#line 106 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp17_ = g_list_nth_data (_tmp14_, _tmp15_ + (_tmp16_ / 2)); -#line 106 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp18_ = _page_ref0 ((Page*) _tmp17_); -#line 106 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - new_pages = g_list_append (new_pages, _tmp18_); -#line 595 "book.c" - } - } - } - } -#line 108 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp19_ = new_pages; -#line 108 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - new_pages = NULL; -#line 108 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - __g_list_free__page_unref0_0 (self->priv->pages); -#line 108 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - self->priv->pages = _tmp19_; -#line 110 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - g_signal_emit_by_name (self, "reordered"); -#line 111 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - book_set_needs_saving (self, TRUE); -#line 97 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - __g_list_free__page_unref0_0 (new_pages); -#line 614 "book.c" -} - - -void book_combine_sides_reverse (Book* self) { - GList* new_pages = NULL; - GList* _tmp16_ = NULL; -#line 114 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - g_return_if_fail (self != NULL); -#line 116 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - new_pages = NULL; -#line 625 "book.c" - { - gint i = 0; -#line 117 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - i = 0; -#line 630 "book.c" - { - gboolean _tmp0_ = FALSE; -#line 117 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp0_ = TRUE; -#line 117 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - while (TRUE) { -#line 637 "book.c" - gint _tmp2_ = 0; - guint _tmp3_ = 0U; - guint _tmp4_ = 0U; - gint _tmp5_ = 0; -#line 117 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - if (!_tmp0_) { -#line 644 "book.c" - gint _tmp1_ = 0; -#line 117 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp1_ = i; -#line 117 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - i = _tmp1_ + 1; -#line 650 "book.c" - } -#line 117 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp0_ = FALSE; -#line 117 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp2_ = i; -#line 117 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp3_ = book_get_n_pages (self); -#line 117 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp4_ = _tmp3_; -#line 117 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - if (!(((guint) _tmp2_) < _tmp4_)) { -#line 117 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - break; -#line 664 "book.c" - } -#line 119 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp5_ = i; -#line 119 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - if ((_tmp5_ % 2) == 0) { -#line 670 "book.c" - GList* _tmp6_ = NULL; - gint _tmp7_ = 0; - gconstpointer _tmp8_ = NULL; - Page* _tmp9_ = NULL; -#line 120 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp6_ = self->priv->pages; -#line 120 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp7_ = i; -#line 120 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp8_ = g_list_nth_data (_tmp6_, (guint) (_tmp7_ / 2)); -#line 120 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp9_ = _page_ref0 ((Page*) _tmp8_); -#line 120 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - new_pages = g_list_append (new_pages, _tmp9_); -#line 685 "book.c" - } else { - GList* _tmp10_ = NULL; - guint _tmp11_ = 0U; - guint _tmp12_ = 0U; - gint _tmp13_ = 0; - gconstpointer _tmp14_ = NULL; - Page* _tmp15_ = NULL; -#line 122 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp10_ = self->priv->pages; -#line 122 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp11_ = book_get_n_pages (self); -#line 122 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp12_ = _tmp11_; -#line 122 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp13_ = i; -#line 122 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp14_ = g_list_nth_data (_tmp10_, (_tmp12_ - 1) - (_tmp13_ / 2)); -#line 122 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp15_ = _page_ref0 ((Page*) _tmp14_); -#line 122 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - new_pages = g_list_append (new_pages, _tmp15_); -#line 707 "book.c" - } - } - } - } -#line 124 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp16_ = new_pages; -#line 124 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - new_pages = NULL; -#line 124 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - __g_list_free__page_unref0_0 (self->priv->pages); -#line 124 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - self->priv->pages = _tmp16_; -#line 126 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - g_signal_emit_by_name (self, "reordered"); -#line 127 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - book_set_needs_saving (self, TRUE); -#line 114 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - __g_list_free__page_unref0_0 (new_pages); -#line 726 "book.c" -} - - -void book_delete_page (Book* self, Page* page) { - Page* _tmp0_ = NULL; - guint _tmp1_ = 0U; - Page* _tmp2_ = NULL; - guint _tmp3_ = 0U; - Page* _tmp4_ = NULL; - Page* _tmp5_ = NULL; -#line 130 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - g_return_if_fail (self != NULL); -#line 130 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - g_return_if_fail (page != NULL); -#line 132 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp0_ = page; -#line 132 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - g_signal_parse_name ("pixels-changed", TYPE_PAGE, &_tmp1_, NULL, FALSE); -#line 132 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - g_signal_handlers_disconnect_matched (_tmp0_, G_SIGNAL_MATCH_ID | G_SIGNAL_MATCH_FUNC | G_SIGNAL_MATCH_DATA, _tmp1_, 0, NULL, (GCallback) _book_page_changed_cb_page_pixels_changed, self); -#line 133 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp2_ = page; -#line 133 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - g_signal_parse_name ("crop-changed", TYPE_PAGE, &_tmp3_, NULL, FALSE); -#line 133 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - g_signal_handlers_disconnect_matched (_tmp2_, G_SIGNAL_MATCH_ID | G_SIGNAL_MATCH_FUNC | G_SIGNAL_MATCH_DATA, _tmp3_, 0, NULL, (GCallback) _book_page_changed_cb_page_crop_changed, self); -#line 134 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp4_ = page; -#line 134 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - self->priv->pages = g_list_remove (self->priv->pages, _tmp4_); -#line 135 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp5_ = page; -#line 135 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - g_signal_emit_by_name (self, "page-removed", _tmp5_); -#line 136 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - book_set_needs_saving (self, TRUE); -#line 763 "book.c" -} - - -Page* book_get_page (Book* self, gint page_number) { - Page* result = NULL; - gint _tmp0_ = 0; - GList* _tmp4_ = NULL; - gint _tmp5_ = 0; - gconstpointer _tmp6_ = NULL; - Page* _tmp7_ = NULL; -#line 139 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - g_return_val_if_fail (self != NULL, NULL); -#line 141 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp0_ = page_number; -#line 141 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - if (_tmp0_ < 0) { -#line 780 "book.c" - GList* _tmp1_ = NULL; - guint _tmp2_ = 0U; - gint _tmp3_ = 0; -#line 142 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp1_ = self->priv->pages; -#line 142 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp2_ = g_list_length (_tmp1_); -#line 142 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp3_ = page_number; -#line 142 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - page_number = ((gint) _tmp2_) + _tmp3_; -#line 792 "book.c" - } -#line 143 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp4_ = self->priv->pages; -#line 143 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp5_ = page_number; -#line 143 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp6_ = g_list_nth_data (_tmp4_, (guint) _tmp5_); -#line 143 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp7_ = _page_ref0 ((Page*) _tmp6_); -#line 143 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - result = _tmp7_; -#line 143 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - return result; -#line 806 "book.c" -} - - -guint book_get_page_index (Book* self, Page* page) { - guint result = 0U; - GList* _tmp0_ = NULL; - Page* _tmp1_ = NULL; - gint _tmp2_ = 0; -#line 146 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - g_return_val_if_fail (self != NULL, 0U); -#line 146 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - g_return_val_if_fail (page != NULL, 0U); -#line 148 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp0_ = self->priv->pages; -#line 148 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp1_ = page; -#line 148 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp2_ = g_list_index (_tmp0_, _tmp1_); -#line 148 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - result = (guint) _tmp2_; -#line 148 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - return result; -#line 829 "book.c" -} - - -static gint string_last_index_of_char (const gchar* self, gunichar c, gint start_index) { - gint result = 0; - gchar* _result_ = NULL; - gint _tmp0_ = 0; - gunichar _tmp1_ = 0U; - gchar* _tmp2_ = NULL; - gchar* _tmp3_ = NULL; -#line 1017 "/usr/share/vala-0.34/vapi/glib-2.0.vapi" - g_return_val_if_fail (self != NULL, 0); -#line 1018 "/usr/share/vala-0.34/vapi/glib-2.0.vapi" - _tmp0_ = start_index; -#line 1018 "/usr/share/vala-0.34/vapi/glib-2.0.vapi" - _tmp1_ = c; -#line 1018 "/usr/share/vala-0.34/vapi/glib-2.0.vapi" - _tmp2_ = g_utf8_strrchr (((gchar*) self) + _tmp0_, (gssize) -1, _tmp1_); -#line 1018 "/usr/share/vala-0.34/vapi/glib-2.0.vapi" - _result_ = _tmp2_; -#line 1020 "/usr/share/vala-0.34/vapi/glib-2.0.vapi" - _tmp3_ = _result_; -#line 1020 "/usr/share/vala-0.34/vapi/glib-2.0.vapi" - if (_tmp3_ != NULL) { -#line 854 "book.c" - gchar* _tmp4_ = NULL; -#line 1021 "/usr/share/vala-0.34/vapi/glib-2.0.vapi" - _tmp4_ = _result_; -#line 1021 "/usr/share/vala-0.34/vapi/glib-2.0.vapi" - result = (gint) (_tmp4_ - ((gchar*) self)); -#line 1021 "/usr/share/vala-0.34/vapi/glib-2.0.vapi" - return result; -#line 862 "book.c" - } else { -#line 1023 "/usr/share/vala-0.34/vapi/glib-2.0.vapi" - result = -1; -#line 1023 "/usr/share/vala-0.34/vapi/glib-2.0.vapi" - return result; -#line 868 "book.c" - } -} - - -static gchar* string_slice (const gchar* self, glong start, glong end) { - gchar* result = NULL; - glong string_length = 0L; - gint _tmp0_ = 0; - gint _tmp1_ = 0; - glong _tmp2_ = 0L; - glong _tmp5_ = 0L; - gboolean _tmp8_ = FALSE; - glong _tmp9_ = 0L; - gboolean _tmp12_ = FALSE; - glong _tmp13_ = 0L; - glong _tmp16_ = 0L; - glong _tmp17_ = 0L; - glong _tmp18_ = 0L; - glong _tmp19_ = 0L; - glong _tmp20_ = 0L; - gchar* _tmp21_ = NULL; -#line 1328 "/usr/share/vala-0.34/vapi/glib-2.0.vapi" - g_return_val_if_fail (self != NULL, NULL); -#line 1329 "/usr/share/vala-0.34/vapi/glib-2.0.vapi" - _tmp0_ = strlen (self); -#line 1329 "/usr/share/vala-0.34/vapi/glib-2.0.vapi" - _tmp1_ = _tmp0_; -#line 1329 "/usr/share/vala-0.34/vapi/glib-2.0.vapi" - string_length = (glong) _tmp1_; -#line 1330 "/usr/share/vala-0.34/vapi/glib-2.0.vapi" - _tmp2_ = start; -#line 1330 "/usr/share/vala-0.34/vapi/glib-2.0.vapi" - if (_tmp2_ < ((glong) 0)) { -#line 902 "book.c" - glong _tmp3_ = 0L; - glong _tmp4_ = 0L; -#line 1331 "/usr/share/vala-0.34/vapi/glib-2.0.vapi" - _tmp3_ = string_length; -#line 1331 "/usr/share/vala-0.34/vapi/glib-2.0.vapi" - _tmp4_ = start; -#line 1331 "/usr/share/vala-0.34/vapi/glib-2.0.vapi" - start = _tmp3_ + _tmp4_; -#line 911 "book.c" - } -#line 1333 "/usr/share/vala-0.34/vapi/glib-2.0.vapi" - _tmp5_ = end; -#line 1333 "/usr/share/vala-0.34/vapi/glib-2.0.vapi" - if (_tmp5_ < ((glong) 0)) { -#line 917 "book.c" - glong _tmp6_ = 0L; - glong _tmp7_ = 0L; -#line 1334 "/usr/share/vala-0.34/vapi/glib-2.0.vapi" - _tmp6_ = string_length; -#line 1334 "/usr/share/vala-0.34/vapi/glib-2.0.vapi" - _tmp7_ = end; -#line 1334 "/usr/share/vala-0.34/vapi/glib-2.0.vapi" - end = _tmp6_ + _tmp7_; -#line 926 "book.c" - } -#line 1336 "/usr/share/vala-0.34/vapi/glib-2.0.vapi" - _tmp9_ = start; -#line 1336 "/usr/share/vala-0.34/vapi/glib-2.0.vapi" - if (_tmp9_ >= ((glong) 0)) { -#line 932 "book.c" - glong _tmp10_ = 0L; - glong _tmp11_ = 0L; -#line 1336 "/usr/share/vala-0.34/vapi/glib-2.0.vapi" - _tmp10_ = start; -#line 1336 "/usr/share/vala-0.34/vapi/glib-2.0.vapi" - _tmp11_ = string_length; -#line 1336 "/usr/share/vala-0.34/vapi/glib-2.0.vapi" - _tmp8_ = _tmp10_ <= _tmp11_; -#line 941 "book.c" - } else { -#line 1336 "/usr/share/vala-0.34/vapi/glib-2.0.vapi" - _tmp8_ = FALSE; -#line 945 "book.c" - } -#line 1336 "/usr/share/vala-0.34/vapi/glib-2.0.vapi" - g_return_val_if_fail (_tmp8_, NULL); -#line 1337 "/usr/share/vala-0.34/vapi/glib-2.0.vapi" - _tmp13_ = end; -#line 1337 "/usr/share/vala-0.34/vapi/glib-2.0.vapi" - if (_tmp13_ >= ((glong) 0)) { -#line 953 "book.c" - glong _tmp14_ = 0L; - glong _tmp15_ = 0L; -#line 1337 "/usr/share/vala-0.34/vapi/glib-2.0.vapi" - _tmp14_ = end; -#line 1337 "/usr/share/vala-0.34/vapi/glib-2.0.vapi" - _tmp15_ = string_length; -#line 1337 "/usr/share/vala-0.34/vapi/glib-2.0.vapi" - _tmp12_ = _tmp14_ <= _tmp15_; -#line 962 "book.c" - } else { -#line 1337 "/usr/share/vala-0.34/vapi/glib-2.0.vapi" - _tmp12_ = FALSE; -#line 966 "book.c" - } -#line 1337 "/usr/share/vala-0.34/vapi/glib-2.0.vapi" - g_return_val_if_fail (_tmp12_, NULL); -#line 1338 "/usr/share/vala-0.34/vapi/glib-2.0.vapi" - _tmp16_ = start; -#line 1338 "/usr/share/vala-0.34/vapi/glib-2.0.vapi" - _tmp17_ = end; -#line 1338 "/usr/share/vala-0.34/vapi/glib-2.0.vapi" - g_return_val_if_fail (_tmp16_ <= _tmp17_, NULL); -#line 1339 "/usr/share/vala-0.34/vapi/glib-2.0.vapi" - _tmp18_ = start; -#line 1339 "/usr/share/vala-0.34/vapi/glib-2.0.vapi" - _tmp19_ = end; -#line 1339 "/usr/share/vala-0.34/vapi/glib-2.0.vapi" - _tmp20_ = start; -#line 1339 "/usr/share/vala-0.34/vapi/glib-2.0.vapi" - _tmp21_ = g_strndup (((gchar*) self) + _tmp18_, (gsize) (_tmp19_ - _tmp20_)); -#line 1339 "/usr/share/vala-0.34/vapi/glib-2.0.vapi" - result = _tmp21_; -#line 1339 "/usr/share/vala-0.34/vapi/glib-2.0.vapi" - return result; -#line 988 "book.c" -} - - -static GFile* book_make_indexed_file (Book* self, const gchar* uri, gint i) { - GFile* result = NULL; - guint _tmp0_ = 0U; - guint _tmp1_ = 0U; - gchar* basename = NULL; - const gchar* _tmp4_ = NULL; - gchar* _tmp5_ = NULL; - gchar* prefix = NULL; - const gchar* _tmp6_ = NULL; - gchar* _tmp7_ = NULL; - gchar* suffix = NULL; - gchar* _tmp8_ = NULL; - gint extension_index = 0; - const gchar* _tmp9_ = NULL; - gint _tmp10_ = 0; - gint _tmp11_ = 0; - gint width = 0; - guint _tmp26_ = 0U; - guint _tmp27_ = 0U; - gchar* _tmp28_ = NULL; - gchar* _tmp29_ = NULL; - gint _tmp30_ = 0; - gint _tmp31_ = 0; - gint _tmp32_ = 0; - gchar* number_format = NULL; - gint _tmp33_ = 0; - gchar* _tmp34_ = NULL; - gchar* filename = NULL; - const gchar* _tmp35_ = NULL; - gchar* _tmp36_ = NULL; - gchar* _tmp37_ = NULL; - const gchar* _tmp38_ = NULL; - gint _tmp39_ = 0; - gchar* _tmp40_ = NULL; - gchar* _tmp41_ = NULL; - gchar* _tmp42_ = NULL; - gchar* _tmp43_ = NULL; - const gchar* _tmp44_ = NULL; - gchar* _tmp45_ = NULL; - gchar* _tmp46_ = NULL; - const gchar* _tmp47_ = NULL; - GFile* _tmp48_ = NULL; -#line 151 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - g_return_val_if_fail (self != NULL, NULL); -#line 151 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - g_return_val_if_fail (uri != NULL, NULL); -#line 153 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp0_ = book_get_n_pages (self); -#line 153 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp1_ = _tmp0_; -#line 153 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - if (_tmp1_ == ((guint) 1)) { -#line 1044 "book.c" - const gchar* _tmp2_ = NULL; - GFile* _tmp3_ = NULL; -#line 154 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp2_ = uri; -#line 154 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp3_ = g_file_new_for_uri (_tmp2_); -#line 154 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - result = _tmp3_; -#line 154 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - return result; -#line 1055 "book.c" - } -#line 157 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp4_ = uri; -#line 157 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp5_ = g_path_get_basename (_tmp4_); -#line 157 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - basename = _tmp5_; -#line 158 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp6_ = uri; -#line 158 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp7_ = g_strdup (_tmp6_); -#line 158 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - prefix = _tmp7_; -#line 158 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp8_ = g_strdup (""); -#line 158 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - suffix = _tmp8_; -#line 159 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp9_ = basename; -#line 159 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp10_ = string_last_index_of_char (_tmp9_, (gunichar) '.', 0); -#line 159 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - extension_index = _tmp10_; -#line 160 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp11_ = extension_index; -#line 160 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - if (_tmp11_ >= 0) { -#line 1083 "book.c" - const gchar* _tmp12_ = NULL; - gint _tmp13_ = 0; - const gchar* _tmp14_ = NULL; - gint _tmp15_ = 0; - gint _tmp16_ = 0; - gchar* _tmp17_ = NULL; - const gchar* _tmp18_ = NULL; - const gchar* _tmp19_ = NULL; - gint _tmp20_ = 0; - gint _tmp21_ = 0; - const gchar* _tmp22_ = NULL; - gint _tmp23_ = 0; - gint _tmp24_ = 0; - gchar* _tmp25_ = NULL; -#line 162 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp12_ = basename; -#line 162 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp13_ = extension_index; -#line 162 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp14_ = basename; -#line 162 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp15_ = strlen (_tmp14_); -#line 162 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp16_ = _tmp15_; -#line 162 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp17_ = string_slice (_tmp12_, (glong) _tmp13_, (glong) _tmp16_); -#line 162 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _g_free0 (suffix); -#line 162 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - suffix = _tmp17_; -#line 163 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp18_ = uri; -#line 163 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp19_ = uri; -#line 163 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp20_ = strlen (_tmp19_); -#line 163 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp21_ = _tmp20_; -#line 163 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp22_ = suffix; -#line 163 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp23_ = strlen (_tmp22_); -#line 163 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp24_ = _tmp23_; -#line 163 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp25_ = string_slice (_tmp18_, (glong) 0, (glong) (_tmp21_ - _tmp24_)); -#line 163 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _g_free0 (prefix); -#line 163 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - prefix = _tmp25_; -#line 1134 "book.c" - } -#line 165 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp26_ = book_get_n_pages (self); -#line 165 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp27_ = _tmp26_; -#line 165 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp28_ = g_strdup_printf ("%u", _tmp27_); -#line 165 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp29_ = _tmp28_; -#line 165 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp30_ = strlen (_tmp29_); -#line 165 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp31_ = _tmp30_; -#line 165 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp32_ = _tmp31_; -#line 165 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _g_free0 (_tmp29_); -#line 165 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - width = _tmp32_; -#line 166 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp33_ = width; -#line 166 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp34_ = g_strdup_printf ("%%0%dd", _tmp33_); -#line 166 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - number_format = _tmp34_; -#line 167 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp35_ = prefix; -#line 167 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp36_ = g_strconcat (_tmp35_, "-", NULL); -#line 167 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp37_ = _tmp36_; -#line 167 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp38_ = number_format; -#line 167 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp39_ = i; -#line 167 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp40_ = g_strdup_printf (_tmp38_, _tmp39_ + 1); -#line 167 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp41_ = _tmp40_; -#line 167 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp42_ = g_strconcat (_tmp37_, _tmp41_, NULL); -#line 167 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp43_ = _tmp42_; -#line 167 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp44_ = suffix; -#line 167 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp45_ = g_strconcat (_tmp43_, _tmp44_, NULL); -#line 167 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp46_ = _tmp45_; -#line 167 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _g_free0 (_tmp43_); -#line 167 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _g_free0 (_tmp41_); -#line 167 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _g_free0 (_tmp37_); -#line 167 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - filename = _tmp46_; -#line 168 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp47_ = filename; -#line 168 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp48_ = g_file_new_for_uri (_tmp47_); -#line 168 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - result = _tmp48_; -#line 168 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _g_free0 (filename); -#line 168 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _g_free0 (number_format); -#line 168 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _g_free0 (suffix); -#line 168 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _g_free0 (prefix); -#line 168 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _g_free0 (basename); -#line 168 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - return result; -#line 1210 "book.c" -} - - -static void book_save_multi_file (Book* self, const gchar* type, gint quality, GFile* file, GError** error) { - GError * _inner_error_ = NULL; -#line 171 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - g_return_if_fail (self != NULL); -#line 171 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - g_return_if_fail (type != NULL); -#line 171 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - g_return_if_fail (file != NULL); -#line 1222 "book.c" - { - gint i = 0; -#line 173 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - i = 0; -#line 1227 "book.c" - { - gboolean _tmp0_ = FALSE; -#line 173 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp0_ = TRUE; -#line 173 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - while (TRUE) { -#line 1234 "book.c" - gint _tmp2_ = 0; - guint _tmp3_ = 0U; - guint _tmp4_ = 0U; - Page* page = NULL; - gint _tmp5_ = 0; - Page* _tmp6_ = NULL; - Page* _tmp7_ = NULL; - const gchar* _tmp8_ = NULL; - gint _tmp9_ = 0; - GFile* _tmp10_ = NULL; - gchar* _tmp11_ = NULL; - gchar* _tmp12_ = NULL; - gint _tmp13_ = 0; - GFile* _tmp14_ = NULL; - GFile* _tmp15_ = NULL; - gint _tmp16_ = 0; -#line 173 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - if (!_tmp0_) { -#line 1253 "book.c" - gint _tmp1_ = 0; -#line 173 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp1_ = i; -#line 173 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - i = _tmp1_ + 1; -#line 1259 "book.c" - } -#line 173 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp0_ = FALSE; -#line 173 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp2_ = i; -#line 173 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp3_ = book_get_n_pages (self); -#line 173 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp4_ = _tmp3_; -#line 173 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - if (!(((guint) _tmp2_) < _tmp4_)) { -#line 173 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - break; -#line 1273 "book.c" - } -#line 175 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp5_ = i; -#line 175 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp6_ = book_get_page (self, _tmp5_); -#line 175 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - page = _tmp6_; -#line 176 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp7_ = page; -#line 176 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp8_ = type; -#line 176 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp9_ = quality; -#line 176 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp10_ = file; -#line 176 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp11_ = g_file_get_uri (_tmp10_); -#line 176 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp12_ = _tmp11_; -#line 176 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp13_ = i; -#line 176 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp14_ = book_make_indexed_file (self, _tmp12_, _tmp13_); -#line 176 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp15_ = _tmp14_; -#line 176 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - page_save (_tmp7_, _tmp8_, _tmp9_, _tmp15_, &_inner_error_); -#line 176 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _g_object_unref0 (_tmp15_); -#line 176 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _g_free0 (_tmp12_); -#line 176 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - if (G_UNLIKELY (_inner_error_ != NULL)) { -#line 176 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - g_propagate_error (error, _inner_error_); -#line 176 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _page_unref0 (page); -#line 176 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - return; -#line 1313 "book.c" - } -#line 177 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp16_ = i; -#line 177 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - g_signal_emit_by_name (self, "saving", _tmp16_); -#line 173 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _page_unref0 (page); -#line 1321 "book.c" - } - } - } -} - - -static void book_save_ps_pdf_surface (Book* self, cairo_surface_t* surface, GdkPixbuf* image, gdouble dpi) { - cairo_t* context = NULL; - cairo_surface_t* _tmp0_ = NULL; - cairo_t* _tmp1_ = NULL; - gdouble _tmp2_ = 0.0; - gdouble _tmp3_ = 0.0; - GdkPixbuf* _tmp4_ = NULL; - cairo_pattern_t* _tmp5_ = NULL; -#line 181 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - g_return_if_fail (self != NULL); -#line 181 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - g_return_if_fail (surface != NULL); -#line 181 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - g_return_if_fail (image != NULL); -#line 183 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp0_ = surface; -#line 183 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp1_ = cairo_create (_tmp0_); -#line 183 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - context = _tmp1_; -#line 184 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp2_ = dpi; -#line 184 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp3_ = dpi; -#line 184 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - cairo_scale (context, 72.0 / _tmp2_, 72.0 / _tmp3_); -#line 185 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp4_ = image; -#line 185 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - gdk_cairo_set_source_pixbuf (context, _tmp4_, (gdouble) 0, (gdouble) 0); -#line 186 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp5_ = cairo_get_source (context); -#line 186 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - cairo_pattern_set_filter (_tmp5_, CAIRO_FILTER_BEST); -#line 187 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - cairo_paint (context); -#line 181 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _cairo_destroy0 (context); -#line 1366 "book.c" -} - - -static gpointer _cairo_surface_reference0 (gpointer self) { -#line 194 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - return self ? cairo_surface_reference (self) : NULL; -#line 1373 "book.c" -} - - -static void book_save_ps (Book* self, GFile* file, GError** error) { - GFileOutputStream* stream = NULL; - GFile* _tmp0_ = NULL; - GFileOutputStream* _tmp1_ = NULL; - PsWriter* writer = NULL; - PsWriter* _tmp2_ = NULL; - cairo_surface_t* surface = NULL; - PsWriter* _tmp3_ = NULL; - cairo_surface_t* _tmp4_ = NULL; - cairo_surface_t* _tmp5_ = NULL; - GError * _inner_error_ = NULL; -#line 190 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - g_return_if_fail (self != NULL); -#line 190 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - g_return_if_fail (file != NULL); -#line 192 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp0_ = file; -#line 192 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp1_ = g_file_replace (_tmp0_, NULL, FALSE, G_FILE_CREATE_NONE, NULL, &_inner_error_); -#line 192 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - stream = _tmp1_; -#line 192 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - if (G_UNLIKELY (_inner_error_ != NULL)) { -#line 192 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - g_propagate_error (error, _inner_error_); -#line 192 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - return; -#line 1404 "book.c" - } -#line 193 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp2_ = ps_writer_new (stream); -#line 193 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - writer = _tmp2_; -#line 194 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp3_ = writer; -#line 194 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp4_ = _tmp3_->surface; -#line 194 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp5_ = _cairo_surface_reference0 (_tmp4_); -#line 194 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - surface = _tmp5_; -#line 1418 "book.c" - { - gint i = 0; -#line 196 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - i = 0; -#line 1423 "book.c" - { - gboolean _tmp6_ = FALSE; -#line 196 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp6_ = TRUE; -#line 196 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - while (TRUE) { -#line 1430 "book.c" - gint _tmp8_ = 0; - guint _tmp9_ = 0U; - guint _tmp10_ = 0U; - Page* page = NULL; - gint _tmp11_ = 0; - Page* _tmp12_ = NULL; - GdkPixbuf* image = NULL; - Page* _tmp13_ = NULL; - GdkPixbuf* _tmp14_ = NULL; - gdouble width = 0.0; - GdkPixbuf* _tmp15_ = NULL; - gint _tmp16_ = 0; - gint _tmp17_ = 0; - Page* _tmp18_ = NULL; - gint _tmp19_ = 0; - gint _tmp20_ = 0; - gdouble height = 0.0; - GdkPixbuf* _tmp21_ = NULL; - gint _tmp22_ = 0; - gint _tmp23_ = 0; - Page* _tmp24_ = NULL; - gint _tmp25_ = 0; - gint _tmp26_ = 0; - cairo_surface_t* _tmp27_ = NULL; - gdouble _tmp28_ = 0.0; - gdouble _tmp29_ = 0.0; - cairo_surface_t* _tmp30_ = NULL; - GdkPixbuf* _tmp31_ = NULL; - Page* _tmp32_ = NULL; - gint _tmp33_ = 0; - gint _tmp34_ = 0; - cairo_surface_t* _tmp35_ = NULL; - gint _tmp36_ = 0; -#line 196 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - if (!_tmp6_) { -#line 1466 "book.c" - gint _tmp7_ = 0; -#line 196 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp7_ = i; -#line 196 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - i = _tmp7_ + 1; -#line 1472 "book.c" - } -#line 196 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp6_ = FALSE; -#line 196 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp8_ = i; -#line 196 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp9_ = book_get_n_pages (self); -#line 196 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp10_ = _tmp9_; -#line 196 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - if (!(((guint) _tmp8_) < _tmp10_)) { -#line 196 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - break; -#line 1486 "book.c" - } -#line 198 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp11_ = i; -#line 198 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp12_ = book_get_page (self, _tmp11_); -#line 198 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - page = _tmp12_; -#line 199 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp13_ = page; -#line 199 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp14_ = page_get_image (_tmp13_, TRUE); -#line 199 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - image = _tmp14_; -#line 200 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp15_ = image; -#line 200 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp16_ = gdk_pixbuf_get_width (_tmp15_); -#line 200 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp17_ = _tmp16_; -#line 200 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp18_ = page; -#line 200 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp19_ = page_get_dpi (_tmp18_); -#line 200 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp20_ = _tmp19_; -#line 200 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - width = (_tmp17_ * 72.0) / _tmp20_; -#line 201 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp21_ = image; -#line 201 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp22_ = gdk_pixbuf_get_height (_tmp21_); -#line 201 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp23_ = _tmp22_; -#line 201 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp24_ = page; -#line 201 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp25_ = page_get_dpi (_tmp24_); -#line 201 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp26_ = _tmp25_; -#line 201 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - height = (_tmp23_ * 72.0) / _tmp26_; -#line 202 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp27_ = surface; -#line 202 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp28_ = width; -#line 202 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp29_ = height; -#line 202 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - cairo_ps_surface_set_size (_tmp27_, _tmp28_, _tmp29_); -#line 203 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp30_ = surface; -#line 203 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp31_ = image; -#line 203 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp32_ = page; -#line 203 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp33_ = page_get_dpi (_tmp32_); -#line 203 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp34_ = _tmp33_; -#line 203 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - book_save_ps_pdf_surface (self, _tmp30_, _tmp31_, (gdouble) _tmp34_); -#line 204 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp35_ = surface; -#line 204 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - cairo_surface_show_page (_tmp35_); -#line 205 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp36_ = i; -#line 205 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - g_signal_emit_by_name (self, "saving", _tmp36_); -#line 196 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _g_object_unref0 (image); -#line 196 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _page_unref0 (page); -#line 1560 "book.c" - } - } - } -#line 190 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _cairo_surface_destroy0 (surface); -#line 190 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _ps_writer_unref0 (writer); -#line 190 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _g_object_unref0 (stream); -#line 1570 "book.c" -} - - -static guint8* book_compress_zlib (Book* self, guint8* data, int data_length1, int* result_length1) { - guint8* result = NULL; - z_stream stream = {0}; - guint8* out_data = NULL; - guint8* _tmp0_ = NULL; - gint _tmp0__length1 = 0; - guint8* _tmp1_ = NULL; - gint out_data_length1 = 0; - gint _out_data_size_ = 0; - guint8* _tmp2_ = NULL; - gint _tmp2__length1 = 0; - guint8* _tmp3_ = NULL; - gint _tmp3__length1 = 0; - z_stream _tmp7_ = {0}; - guint _tmp8_ = 0U; - guint n_written = 0U; - guint8* _tmp10_ = NULL; - gint _tmp10__length1 = 0; - z_stream _tmp11_ = {0}; - guint _tmp12_ = 0U; - guint _tmp13_ = 0U; - gint _tmp14_ = 0; - guint8* _tmp15_ = NULL; - gint _tmp15__length1 = 0; -#line 209 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - g_return_val_if_fail (self != NULL, NULL); -#line 211 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - deflateInit (&stream, (gint) Z_BEST_COMPRESSION); -#line 212 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp0_ = data; -#line 212 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp0__length1 = data_length1; -#line 212 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp1_ = g_new0 (guint8, _tmp0__length1); -#line 212 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - out_data = _tmp1_; -#line 212 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - out_data_length1 = _tmp0__length1; -#line 212 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _out_data_size_ = out_data_length1; -#line 214 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp2_ = data; -#line 214 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp2__length1 = data_length1; -#line 214 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - stream.next_in = _tmp2_; -#line 214 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - stream.avail_in = _tmp2__length1; -#line 215 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp3_ = out_data; -#line 215 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp3__length1 = out_data_length1; -#line 215 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - stream.next_out = _tmp3_; -#line 215 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - stream.avail_out = _tmp3__length1; -#line 216 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - while (TRUE) { -#line 1632 "book.c" - z_stream _tmp4_ = {0}; - guint _tmp5_ = 0U; - gint _tmp6_ = 0; -#line 216 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp4_ = stream; -#line 216 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp5_ = _tmp4_.avail_in; -#line 216 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - if (!(_tmp5_ > ((guint) 0))) { -#line 216 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - break; -#line 1644 "book.c" - } -#line 218 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp6_ = deflate (&stream, (gint) Z_FINISH); -#line 218 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - if (_tmp6_ == ((gint) Z_STREAM_ERROR)) { -#line 219 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - break; -#line 1652 "book.c" - } - } -#line 222 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp7_ = stream; -#line 222 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp8_ = _tmp7_.avail_in; -#line 222 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - if (_tmp8_ > ((guint) 0)) { -#line 1661 "book.c" - guint8* _tmp9_ = NULL; - gint _tmp9__length1 = 0; -#line 223 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp9_ = NULL; -#line 223 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp9__length1 = 0; -#line 223 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - if (result_length1) { -#line 223 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - *result_length1 = _tmp9__length1; -#line 1672 "book.c" - } -#line 223 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - result = _tmp9_; -#line 223 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - out_data = (g_free (out_data), NULL); -#line 223 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - deflateEnd (&stream); -#line 223 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - return result; -#line 1682 "book.c" - } -#line 225 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp10_ = data; -#line 225 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp10__length1 = data_length1; -#line 225 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp11_ = stream; -#line 225 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp12_ = _tmp11_.avail_out; -#line 225 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - n_written = _tmp10__length1 - _tmp12_; -#line 226 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp13_ = n_written; -#line 226 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp14_ = (gint) _tmp13_; -#line 226 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - out_data = g_renew (guint8, out_data, (gint) _tmp13_); -#line 226 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - (_tmp14_ > out_data_length1) ? memset (out_data + out_data_length1, 0, sizeof (guint8) * (_tmp14_ - out_data_length1)) : NULL; -#line 226 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - out_data_length1 = _tmp14_; -#line 226 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _out_data_size_ = _tmp14_; -#line 228 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp15_ = out_data; -#line 228 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp15__length1 = out_data_length1; -#line 228 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - if (result_length1) { -#line 228 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - *result_length1 = _tmp15__length1; -#line 1714 "book.c" - } -#line 228 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - result = _tmp15_; -#line 228 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - deflateEnd (&stream); -#line 228 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - return result; -#line 1722 "book.c" -} - - -static gboolean _book_write_pixbuf_data_gdk_pixbuf_save_func (guint8* buf, gsize buf_length1, GError** error, gpointer self) { - gboolean result; - result = book_write_pixbuf_data ((Book*) self, buf, buf_length1, error); -#line 240 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - return result; -#line 1731 "book.c" -} - - -static guint8* book_compress_jpeg (Book* self, GdkPixbuf* image, gint quality, gint dpi, int* result_length1) { - guint8* result = NULL; - GByteArray* _tmp0_ = NULL; - gchar** keys = NULL; - gchar* _tmp1_ = NULL; - gchar* _tmp2_ = NULL; - gchar* _tmp3_ = NULL; - gchar* _tmp4_ = NULL; - gchar** _tmp5_ = NULL; - gint keys_length1 = 0; - gint _keys_size_ = 0; - gchar** values = NULL; - gint _tmp6_ = 0; - gchar* _tmp7_ = NULL; - gchar* _tmp8_ = NULL; - gint _tmp9_ = 0; - gchar* _tmp10_ = NULL; - gint _tmp11_ = 0; - gchar* _tmp12_ = NULL; - gchar** _tmp13_ = NULL; - gint values_length1 = 0; - gint _values_size_ = 0; - guint8* data = NULL; - GByteArray* _tmp15_ = NULL; - guint8* _tmp16_ = NULL; - gint _tmp16__length1 = 0; - gint data_length1 = 0; - gint _data_size_ = 0; - guint8* _tmp17_ = NULL; - gint _tmp17__length1 = 0; - GError * _inner_error_ = NULL; -#line 233 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - g_return_val_if_fail (self != NULL, NULL); -#line 233 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - g_return_val_if_fail (image != NULL, NULL); -#line 235 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp0_ = g_byte_array_new (); -#line 235 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _g_byte_array_unref0 (self->priv->jpeg_data); -#line 235 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - self->priv->jpeg_data = _tmp0_; -#line 236 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp1_ = g_strdup ("quality"); -#line 236 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp2_ = g_strdup ("density-unit"); -#line 236 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp3_ = g_strdup ("x-density"); -#line 236 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp4_ = g_strdup ("y-density"); -#line 236 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp5_ = g_new0 (gchar*, 5 + 1); -#line 236 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp5_[0] = _tmp1_; -#line 236 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp5_[1] = _tmp2_; -#line 236 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp5_[2] = _tmp3_; -#line 236 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp5_[3] = _tmp4_; -#line 236 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp5_[4] = NULL; -#line 236 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - keys = _tmp5_; -#line 236 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - keys_length1 = 5; -#line 236 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _keys_size_ = keys_length1; -#line 237 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp6_ = quality; -#line 237 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp7_ = g_strdup_printf ("%d", _tmp6_); -#line 237 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp8_ = g_strdup ("dots-per-inch"); -#line 237 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp9_ = dpi; -#line 237 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp10_ = g_strdup_printf ("%d", _tmp9_); -#line 237 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp11_ = dpi; -#line 237 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp12_ = g_strdup_printf ("%d", _tmp11_); -#line 237 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp13_ = g_new0 (gchar*, 5 + 1); -#line 237 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp13_[0] = _tmp7_; -#line 237 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp13_[1] = _tmp8_; -#line 237 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp13_[2] = _tmp10_; -#line 237 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp13_[3] = _tmp12_; -#line 237 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp13_[4] = NULL; -#line 237 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - values = _tmp13_; -#line 237 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - values_length1 = 5; -#line 237 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _values_size_ = values_length1; -#line 1834 "book.c" - { - GdkPixbuf* _tmp14_ = NULL; -#line 240 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp14_ = image; -#line 240 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - gdk_pixbuf_save_to_callbackv (_tmp14_, _book_write_pixbuf_data_gdk_pixbuf_save_func, self, "jpeg", keys, values, &_inner_error_); -#line 240 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - if (G_UNLIKELY (_inner_error_ != NULL)) { -#line 1843 "book.c" - goto __catch0_g_error; - } - } - goto __finally0; - __catch0_g_error: - { - GError* e = NULL; -#line 238 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - e = _inner_error_; -#line 238 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _inner_error_ = NULL; -#line 238 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _g_error_free0 (e); -#line 1857 "book.c" - } - __finally0: -#line 238 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - if (G_UNLIKELY (_inner_error_ != NULL)) { -#line 238 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - values = (_vala_array_free (values, values_length1, (GDestroyNotify) g_free), NULL); -#line 238 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - keys = (_vala_array_free (keys, keys_length1, (GDestroyNotify) g_free), NULL); -#line 238 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - g_critical ("file %s: line %d: uncaught error: %s (%s, %d)", __FILE__, __LINE__, _inner_error_->message, g_quark_to_string (_inner_error_->domain), _inner_error_->code); -#line 238 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - g_clear_error (&_inner_error_); -#line 238 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - return NULL; -#line 1872 "book.c" - } -#line 245 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp15_ = self->priv->jpeg_data; -#line 245 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp16_ = _tmp15_->data; -#line 245 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp16__length1 = _tmp15_->len; -#line 245 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp15_->data = NULL; -#line 245 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp15_->len = 0; -#line 245 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - data = _tmp16_; -#line 245 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - data_length1 = _tmp16__length1; -#line 245 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _data_size_ = data_length1; -#line 246 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _g_byte_array_unref0 (self->priv->jpeg_data); -#line 246 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - self->priv->jpeg_data = NULL; -#line 248 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp17_ = data; -#line 248 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp17__length1 = data_length1; -#line 248 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - if (result_length1) { -#line 248 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - *result_length1 = _tmp17__length1; -#line 1902 "book.c" - } -#line 248 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - result = _tmp17_; -#line 248 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - values = (_vala_array_free (values, values_length1, (GDestroyNotify) g_free), NULL); -#line 248 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - keys = (_vala_array_free (keys, keys_length1, (GDestroyNotify) g_free), NULL); -#line 248 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - return result; -#line 1912 "book.c" -} - - -static gboolean book_write_pixbuf_data (Book* self, guint8* buf, int buf_length1, GError** error) { - gboolean result = FALSE; - GByteArray* _tmp0_ = NULL; - guint8* _tmp1_ = NULL; - gint _tmp1__length1 = 0; -#line 251 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - g_return_val_if_fail (self != NULL, FALSE); -#line 253 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp0_ = self->priv->jpeg_data; -#line 253 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp1_ = buf; -#line 253 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp1__length1 = buf_length1; -#line 253 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - g_byte_array_append (_tmp0_, _tmp1_, _tmp1__length1); -#line 254 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - result = TRUE; -#line 254 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - return result; -#line 1935 "book.c" -} - - -static gchar* g_unichar_to_string (gunichar self) { - gchar* result = NULL; - gchar* str = NULL; - gchar* _tmp0_ = NULL; - const gchar* _tmp1_ = NULL; -#line 941 "/usr/share/vala-0.34/vapi/glib-2.0.vapi" - _tmp0_ = g_new0 (gchar, 7); -#line 941 "/usr/share/vala-0.34/vapi/glib-2.0.vapi" - str = (gchar*) _tmp0_; -#line 942 "/usr/share/vala-0.34/vapi/glib-2.0.vapi" - _tmp1_ = str; -#line 942 "/usr/share/vala-0.34/vapi/glib-2.0.vapi" - g_unichar_to_utf8 (self, _tmp1_); -#line 943 "/usr/share/vala-0.34/vapi/glib-2.0.vapi" - result = str; -#line 943 "/usr/share/vala-0.34/vapi/glib-2.0.vapi" - return result; -#line 1956 "book.c" -} - - -static guint8* _vala_array_dup1 (guint8* self, int length) { -#line 494 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - return g_memdup (self, length * sizeof (guint8)); -#line 1963 "book.c" -} - - -static guint8* _vala_array_dup2 (guint8* self, int length) { -#line 501 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - return g_memdup (self, length * sizeof (guint8)); -#line 1970 "book.c" -} - - -static void book_save_pdf (Book* self, GFile* file, gint quality, GError** error) { - gchar* id = NULL; - gchar* _tmp0_ = NULL; - GFileOutputStream* stream = NULL; - GFile* _tmp9_ = NULL; - GFileOutputStream* _tmp10_ = NULL; - PDFWriter* writer = NULL; - PDFWriter* _tmp11_ = NULL; - guint catalog_number = 0U; - PDFWriter* _tmp12_ = NULL; - guint _tmp13_ = 0U; - guint metadata_number = 0U; - PDFWriter* _tmp14_ = NULL; - guint _tmp15_ = 0U; - guint pages_number = 0U; - PDFWriter* _tmp16_ = NULL; - guint _tmp17_ = 0U; - guint info_number = 0U; - PDFWriter* _tmp18_ = NULL; - guint _tmp19_ = 0U; - guint* page_numbers = NULL; - guint _tmp20_ = 0U; - guint _tmp21_ = 0U; - guint* _tmp22_ = NULL; - gint page_numbers_length1 = 0; - gint _page_numbers_size_ = 0; - guint* page_image_numbers = NULL; - guint _tmp23_ = 0U; - guint _tmp24_ = 0U; - guint* _tmp25_ = NULL; - gint page_image_numbers_length1 = 0; - gint _page_image_numbers_size_ = 0; - guint* page_content_numbers = NULL; - guint _tmp26_ = 0U; - guint _tmp27_ = 0U; - guint* _tmp28_ = NULL; - gint page_content_numbers_length1 = 0; - gint _page_content_numbers_size_ = 0; - guint struct_tree_root_number = 0U; - PDFWriter* _tmp49_ = NULL; - guint _tmp50_ = 0U; - PDFWriter* _tmp51_ = NULL; - PDFWriter* _tmp52_ = NULL; - PDFWriter* _tmp53_ = NULL; - guint _tmp54_ = 0U; - PDFWriter* _tmp55_ = NULL; - guint _tmp56_ = 0U; - gchar* _tmp57_ = NULL; - gchar* _tmp58_ = NULL; - PDFWriter* _tmp59_ = NULL; - PDFWriter* _tmp60_ = NULL; - PDFWriter* _tmp61_ = NULL; - guint _tmp62_ = 0U; - gchar* _tmp63_ = NULL; - gchar* _tmp64_ = NULL; - PDFWriter* _tmp65_ = NULL; - PDFWriter* _tmp66_ = NULL; - guint _tmp67_ = 0U; - gchar* _tmp68_ = NULL; - gchar* _tmp69_ = NULL; - PDFWriter* _tmp70_ = NULL; - guint _tmp71_ = 0U; - gchar* _tmp72_ = NULL; - gchar* _tmp73_ = NULL; - PDFWriter* _tmp74_ = NULL; - PDFWriter* _tmp75_ = NULL; - GDateTime* now = NULL; - GDateTime* _tmp76_ = NULL; - gchar* date_string = NULL; - GDateTime* _tmp77_ = NULL; - gchar* _tmp78_ = NULL; - gchar* metadata = NULL; - gchar* _tmp79_ = NULL; - gchar* _tmp80_ = NULL; - const gchar* _tmp81_ = NULL; - const gchar* _tmp82_ = NULL; - const gchar* _tmp83_ = NULL; - gchar* _tmp84_ = NULL; - gchar* _tmp85_ = NULL; - PDFWriter* _tmp86_ = NULL; - PDFWriter* _tmp87_ = NULL; - guint _tmp88_ = 0U; - PDFWriter* _tmp89_ = NULL; - guint _tmp90_ = 0U; - gchar* _tmp91_ = NULL; - gchar* _tmp92_ = NULL; - PDFWriter* _tmp93_ = NULL; - PDFWriter* _tmp94_ = NULL; - PDFWriter* _tmp95_ = NULL; - PDFWriter* _tmp96_ = NULL; - const gchar* _tmp97_ = NULL; - gint _tmp98_ = 0; - gint _tmp99_ = 0; - gchar* _tmp100_ = NULL; - gchar* _tmp101_ = NULL; - PDFWriter* _tmp102_ = NULL; - PDFWriter* _tmp103_ = NULL; - PDFWriter* _tmp104_ = NULL; - const gchar* _tmp105_ = NULL; - PDFWriter* _tmp106_ = NULL; - PDFWriter* _tmp107_ = NULL; - PDFWriter* _tmp108_ = NULL; - PDFWriter* _tmp109_ = NULL; - PDFWriter* _tmp110_ = NULL; - guint _tmp111_ = 0U; - PDFWriter* _tmp112_ = NULL; - guint _tmp113_ = 0U; - gchar* _tmp114_ = NULL; - gchar* _tmp115_ = NULL; - PDFWriter* _tmp116_ = NULL; - PDFWriter* _tmp117_ = NULL; - PDFWriter* _tmp118_ = NULL; - PDFWriter* _tmp130_ = NULL; - PDFWriter* _tmp131_ = NULL; - guint _tmp132_ = 0U; - guint _tmp133_ = 0U; - gchar* _tmp134_ = NULL; - gchar* _tmp135_ = NULL; - PDFWriter* _tmp136_ = NULL; - PDFWriter* _tmp137_ = NULL; - PDFWriter* _tmp475_ = NULL; - PDFWriter* _tmp476_ = NULL; - guint _tmp477_ = 0U; - PDFWriter* _tmp478_ = NULL; - guint _tmp479_ = 0U; - gchar* _tmp480_ = NULL; - gchar* _tmp481_ = NULL; - PDFWriter* _tmp482_ = NULL; - PDFWriter* _tmp483_ = NULL; - gchar* _tmp484_ = NULL; - gchar* _tmp485_ = NULL; - PDFWriter* _tmp486_ = NULL; - PDFWriter* _tmp487_ = NULL; - PDFWriter* _tmp488_ = NULL; - gsize xref_offset = 0UL; - PDFWriter* _tmp489_ = NULL; - gsize _tmp490_ = 0UL; - PDFWriter* _tmp491_ = NULL; - PDFWriter* _tmp492_ = NULL; - PDFWriter* _tmp493_ = NULL; - guint* _tmp494_ = NULL; - gint _tmp494__length1 = 0; - gchar* _tmp495_ = NULL; - gchar* _tmp496_ = NULL; - PDFWriter* _tmp497_ = NULL; - PDFWriter* _tmp498_ = NULL; - gint _tmp499_ = 0; - gchar* _tmp500_ = NULL; - gchar* _tmp501_ = NULL; - PDFWriter* _tmp524_ = NULL; - PDFWriter* _tmp525_ = NULL; - PDFWriter* _tmp526_ = NULL; - PDFWriter* _tmp527_ = NULL; - PDFWriter* _tmp528_ = NULL; - guint* _tmp529_ = NULL; - gint _tmp529__length1 = 0; - gchar* _tmp530_ = NULL; - gchar* _tmp531_ = NULL; - PDFWriter* _tmp532_ = NULL; - guint _tmp533_ = 0U; - gchar* _tmp534_ = NULL; - gchar* _tmp535_ = NULL; - PDFWriter* _tmp536_ = NULL; - guint _tmp537_ = 0U; - gchar* _tmp538_ = NULL; - gchar* _tmp539_ = NULL; - PDFWriter* _tmp540_ = NULL; - const gchar* _tmp541_ = NULL; - const gchar* _tmp542_ = NULL; - gchar* _tmp543_ = NULL; - gchar* _tmp544_ = NULL; - PDFWriter* _tmp545_ = NULL; - PDFWriter* _tmp546_ = NULL; - PDFWriter* _tmp547_ = NULL; - gsize _tmp548_ = 0UL; - gchar* _tmp549_ = NULL; - gchar* _tmp550_ = NULL; - PDFWriter* _tmp551_ = NULL; - GError * _inner_error_ = NULL; -#line 257 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - g_return_if_fail (self != NULL); -#line 257 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - g_return_if_fail (file != NULL); -#line 260 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp0_ = g_strdup (""); -#line 260 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - id = _tmp0_; -#line 2161 "book.c" - { - gint i = 0; -#line 261 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - i = 0; -#line 2166 "book.c" - { - gboolean _tmp1_ = FALSE; -#line 261 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp1_ = TRUE; -#line 261 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - while (TRUE) { -#line 2173 "book.c" - gint _tmp3_ = 0; - const gchar* _tmp4_ = NULL; - guint32 _tmp5_ = 0U; - gchar* _tmp6_ = NULL; - gchar* _tmp7_ = NULL; - gchar* _tmp8_ = NULL; -#line 261 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - if (!_tmp1_) { -#line 2182 "book.c" - gint _tmp2_ = 0; -#line 261 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp2_ = i; -#line 261 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - i = _tmp2_ + 1; -#line 2188 "book.c" - } -#line 261 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp1_ = FALSE; -#line 261 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp3_ = i; -#line 261 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - if (!(_tmp3_ < 4)) { -#line 261 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - break; -#line 2198 "book.c" - } -#line 262 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp4_ = id; -#line 262 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp5_ = g_random_int (); -#line 262 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp6_ = g_strdup_printf ("%08x", (guint) _tmp5_); -#line 262 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp7_ = _tmp6_; -#line 262 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp8_ = g_strconcat (_tmp4_, _tmp7_, NULL); -#line 262 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _g_free0 (id); -#line 262 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - id = _tmp8_; -#line 262 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _g_free0 (_tmp7_); -#line 2216 "book.c" - } - } - } -#line 264 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp9_ = file; -#line 264 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp10_ = g_file_replace (_tmp9_, NULL, FALSE, G_FILE_CREATE_NONE, NULL, &_inner_error_); -#line 264 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - stream = _tmp10_; -#line 264 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - if (G_UNLIKELY (_inner_error_ != NULL)) { -#line 264 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - g_propagate_error (error, _inner_error_); -#line 264 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _g_free0 (id); -#line 264 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - return; -#line 2234 "book.c" - } -#line 265 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp11_ = pdf_writer_new (stream); -#line 265 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - writer = _tmp11_; -#line 268 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp12_ = writer; -#line 268 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp13_ = pdf_writer_add_object (_tmp12_); -#line 268 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - catalog_number = _tmp13_; -#line 269 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp14_ = writer; -#line 269 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp15_ = pdf_writer_add_object (_tmp14_); -#line 269 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - metadata_number = _tmp15_; -#line 270 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp16_ = writer; -#line 270 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp17_ = pdf_writer_add_object (_tmp16_); -#line 270 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - pages_number = _tmp17_; -#line 271 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp18_ = writer; -#line 271 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp19_ = pdf_writer_add_object (_tmp18_); -#line 271 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - info_number = _tmp19_; -#line 272 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp20_ = book_get_n_pages (self); -#line 272 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp21_ = _tmp20_; -#line 272 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp22_ = g_new0 (guint, _tmp21_); -#line 272 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - page_numbers = _tmp22_; -#line 272 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - page_numbers_length1 = _tmp21_; -#line 272 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _page_numbers_size_ = page_numbers_length1; -#line 273 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp23_ = book_get_n_pages (self); -#line 273 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp24_ = _tmp23_; -#line 273 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp25_ = g_new0 (guint, _tmp24_); -#line 273 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - page_image_numbers = _tmp25_; -#line 273 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - page_image_numbers_length1 = _tmp24_; -#line 273 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _page_image_numbers_size_ = page_image_numbers_length1; -#line 274 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp26_ = book_get_n_pages (self); -#line 274 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp27_ = _tmp26_; -#line 274 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp28_ = g_new0 (guint, _tmp27_); -#line 274 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - page_content_numbers = _tmp28_; -#line 274 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - page_content_numbers_length1 = _tmp27_; -#line 274 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _page_content_numbers_size_ = page_content_numbers_length1; -#line 2300 "book.c" - { - gint i = 0; -#line 275 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - i = 0; -#line 2305 "book.c" - { - gboolean _tmp29_ = FALSE; -#line 275 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp29_ = TRUE; -#line 275 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - while (TRUE) { -#line 2312 "book.c" - gint _tmp31_ = 0; - guint _tmp32_ = 0U; - guint _tmp33_ = 0U; - guint* _tmp34_ = NULL; - gint _tmp34__length1 = 0; - gint _tmp35_ = 0; - PDFWriter* _tmp36_ = NULL; - guint _tmp37_ = 0U; - guint _tmp38_ = 0U; - guint* _tmp39_ = NULL; - gint _tmp39__length1 = 0; - gint _tmp40_ = 0; - PDFWriter* _tmp41_ = NULL; - guint _tmp42_ = 0U; - guint _tmp43_ = 0U; - guint* _tmp44_ = NULL; - gint _tmp44__length1 = 0; - gint _tmp45_ = 0; - PDFWriter* _tmp46_ = NULL; - guint _tmp47_ = 0U; - guint _tmp48_ = 0U; -#line 275 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - if (!_tmp29_) { -#line 2336 "book.c" - gint _tmp30_ = 0; -#line 275 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp30_ = i; -#line 275 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - i = _tmp30_ + 1; -#line 2342 "book.c" - } -#line 275 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp29_ = FALSE; -#line 275 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp31_ = i; -#line 275 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp32_ = book_get_n_pages (self); -#line 275 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp33_ = _tmp32_; -#line 275 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - if (!(((guint) _tmp31_) < _tmp33_)) { -#line 275 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - break; -#line 2356 "book.c" - } -#line 277 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp34_ = page_numbers; -#line 277 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp34__length1 = page_numbers_length1; -#line 277 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp35_ = i; -#line 277 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp36_ = writer; -#line 277 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp37_ = pdf_writer_add_object (_tmp36_); -#line 277 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp34_[_tmp35_] = _tmp37_; -#line 277 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp38_ = _tmp34_[_tmp35_]; -#line 278 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp39_ = page_image_numbers; -#line 278 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp39__length1 = page_image_numbers_length1; -#line 278 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp40_ = i; -#line 278 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp41_ = writer; -#line 278 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp42_ = pdf_writer_add_object (_tmp41_); -#line 278 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp39_[_tmp40_] = _tmp42_; -#line 278 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp43_ = _tmp39_[_tmp40_]; -#line 279 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp44_ = page_content_numbers; -#line 279 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp44__length1 = page_content_numbers_length1; -#line 279 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp45_ = i; -#line 279 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp46_ = writer; -#line 279 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp47_ = pdf_writer_add_object (_tmp46_); -#line 279 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp44_[_tmp45_] = _tmp47_; -#line 279 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp48_ = _tmp44_[_tmp45_]; -#line 2400 "book.c" - } - } - } -#line 281 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp49_ = writer; -#line 281 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp50_ = pdf_writer_add_object (_tmp49_); -#line 281 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - struct_tree_root_number = _tmp50_; -#line 284 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp51_ = writer; -#line 284 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - pdf_writer_write_string (_tmp51_, "%PDF-1.3\n"); -#line 287 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp52_ = writer; -#line 287 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - pdf_writer_write_string (_tmp52_, "%\xe2\xe3\xcf\xd3\n"); -#line 290 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp53_ = writer; -#line 290 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp54_ = catalog_number; -#line 290 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - pdf_writer_start_object (_tmp53_, _tmp54_); -#line 291 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp55_ = writer; -#line 291 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp56_ = catalog_number; -#line 291 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp57_ = g_strdup_printf ("%u 0 obj\n", _tmp56_); -#line 291 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp58_ = _tmp57_; -#line 291 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - pdf_writer_write_string (_tmp55_, _tmp58_); -#line 291 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _g_free0 (_tmp58_); -#line 292 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp59_ = writer; -#line 292 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - pdf_writer_write_string (_tmp59_, "<<\n"); -#line 293 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp60_ = writer; -#line 293 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - pdf_writer_write_string (_tmp60_, "/Type /Catalog\n"); -#line 294 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp61_ = writer; -#line 294 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp62_ = metadata_number; -#line 294 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp63_ = g_strdup_printf ("/Metadata %u 0 R\n", _tmp62_); -#line 294 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp64_ = _tmp63_; -#line 294 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - pdf_writer_write_string (_tmp61_, _tmp64_); -#line 294 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _g_free0 (_tmp64_); -#line 295 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp65_ = writer; -#line 295 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - pdf_writer_write_string (_tmp65_, "/MarkInfo << /Marked true >>\n"); -#line 296 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp66_ = writer; -#line 296 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp67_ = struct_tree_root_number; -#line 296 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp68_ = g_strdup_printf ("/StructTreeRoot %u 0 R\n", _tmp67_); -#line 296 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp69_ = _tmp68_; -#line 296 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - pdf_writer_write_string (_tmp66_, _tmp69_); -#line 296 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _g_free0 (_tmp69_); -#line 297 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp70_ = writer; -#line 297 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp71_ = pages_number; -#line 297 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp72_ = g_strdup_printf ("/Pages %u 0 R\n", _tmp71_); -#line 297 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp73_ = _tmp72_; -#line 297 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - pdf_writer_write_string (_tmp70_, _tmp73_); -#line 297 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _g_free0 (_tmp73_); -#line 298 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp74_ = writer; -#line 298 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - pdf_writer_write_string (_tmp74_, ">>\n"); -#line 299 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp75_ = writer; -#line 299 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - pdf_writer_write_string (_tmp75_, "endobj\n"); -#line 302 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp76_ = g_date_time_new_now_local (); -#line 302 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - now = _tmp76_; -#line 303 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp77_ = now; -#line 303 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp78_ = g_date_time_format (_tmp77_, "%FT%H:%M:%S%:z"); -#line 303 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - date_string = _tmp78_; -#line 305 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp79_ = g_unichar_to_string ((gunichar) 0xFEFF); -#line 305 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp80_ = _tmp79_; -#line 305 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp81_ = date_string; -#line 305 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp82_ = date_string; -#line 305 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp83_ = date_string; -#line 305 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp84_ = g_strdup_printf ("\n" \ -"\n" \ -" \n" \ -" 1\n" \ -" A\n" \ -" Simple Scan %s\n" \ -" %s\n" \ -" %s\n" \ -" %s\n" \ -" \n" \ -"\n" \ -"", _tmp80_, VERSION, _tmp81_, _tmp82_, _tmp83_); -#line 305 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp85_ = _tmp84_; -#line 305 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _g_free0 (_tmp80_); -#line 305 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - metadata = _tmp85_; -#line 320 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp86_ = writer; -#line 320 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - pdf_writer_write_string (_tmp86_, "\n"); -#line 321 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp87_ = writer; -#line 321 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp88_ = metadata_number; -#line 321 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - pdf_writer_start_object (_tmp87_, _tmp88_); -#line 322 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp89_ = writer; -#line 322 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp90_ = metadata_number; -#line 322 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp91_ = g_strdup_printf ("%u 0 obj\n", _tmp90_); -#line 322 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp92_ = _tmp91_; -#line 322 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - pdf_writer_write_string (_tmp89_, _tmp92_); -#line 322 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _g_free0 (_tmp92_); -#line 323 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp93_ = writer; -#line 323 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - pdf_writer_write_string (_tmp93_, "<<\n"); -#line 324 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp94_ = writer; -#line 324 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - pdf_writer_write_string (_tmp94_, "/Type /Metadata\n"); -#line 325 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp95_ = writer; -#line 325 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - pdf_writer_write_string (_tmp95_, "/Subtype /XML\n"); -#line 326 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp96_ = writer; -#line 326 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp97_ = metadata; -#line 326 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp98_ = strlen (_tmp97_); -#line 326 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp99_ = _tmp98_; -#line 326 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp100_ = g_strdup_printf ("/Length %u\n", (guint) _tmp99_); -#line 326 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp101_ = _tmp100_; -#line 326 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - pdf_writer_write_string (_tmp96_, _tmp101_); -#line 326 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _g_free0 (_tmp101_); -#line 327 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp102_ = writer; -#line 327 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - pdf_writer_write_string (_tmp102_, ">>\n"); -#line 328 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp103_ = writer; -#line 328 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - pdf_writer_write_string (_tmp103_, "stream\n"); -#line 329 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp104_ = writer; -#line 329 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp105_ = metadata; -#line 329 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - pdf_writer_write_string (_tmp104_, _tmp105_); -#line 330 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp106_ = writer; -#line 330 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - pdf_writer_write_string (_tmp106_, "\n"); -#line 331 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp107_ = writer; -#line 331 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - pdf_writer_write_string (_tmp107_, "endstream\n"); -#line 332 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp108_ = writer; -#line 332 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - pdf_writer_write_string (_tmp108_, "endobj\n"); -#line 335 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp109_ = writer; -#line 335 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - pdf_writer_write_string (_tmp109_, "\n"); -#line 336 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp110_ = writer; -#line 336 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp111_ = pages_number; -#line 336 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - pdf_writer_start_object (_tmp110_, _tmp111_); -#line 337 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp112_ = writer; -#line 337 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp113_ = pages_number; -#line 337 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp114_ = g_strdup_printf ("%u 0 obj\n", _tmp113_); -#line 337 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp115_ = _tmp114_; -#line 337 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - pdf_writer_write_string (_tmp112_, _tmp115_); -#line 337 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _g_free0 (_tmp115_); -#line 338 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp116_ = writer; -#line 338 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - pdf_writer_write_string (_tmp116_, "<<\n"); -#line 339 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp117_ = writer; -#line 339 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - pdf_writer_write_string (_tmp117_, "/Type /Pages\n"); -#line 340 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp118_ = writer; -#line 340 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - pdf_writer_write_string (_tmp118_, "/Kids ["); -#line 2630 "book.c" - { - gint i = 0; -#line 341 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - i = 0; -#line 2635 "book.c" - { - gboolean _tmp119_ = FALSE; -#line 341 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp119_ = TRUE; -#line 341 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - while (TRUE) { -#line 2642 "book.c" - gint _tmp121_ = 0; - guint _tmp122_ = 0U; - guint _tmp123_ = 0U; - PDFWriter* _tmp124_ = NULL; - guint* _tmp125_ = NULL; - gint _tmp125__length1 = 0; - gint _tmp126_ = 0; - guint _tmp127_ = 0U; - gchar* _tmp128_ = NULL; - gchar* _tmp129_ = NULL; -#line 341 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - if (!_tmp119_) { -#line 2655 "book.c" - gint _tmp120_ = 0; -#line 341 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp120_ = i; -#line 341 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - i = _tmp120_ + 1; -#line 2661 "book.c" - } -#line 341 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp119_ = FALSE; -#line 341 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp121_ = i; -#line 341 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp122_ = book_get_n_pages (self); -#line 341 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp123_ = _tmp122_; -#line 341 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - if (!(((guint) _tmp121_) < _tmp123_)) { -#line 341 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - break; -#line 2675 "book.c" - } -#line 342 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp124_ = writer; -#line 342 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp125_ = page_numbers; -#line 342 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp125__length1 = page_numbers_length1; -#line 342 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp126_ = i; -#line 342 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp127_ = _tmp125_[_tmp126_]; -#line 342 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp128_ = g_strdup_printf (" %u 0 R", _tmp127_); -#line 342 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp129_ = _tmp128_; -#line 342 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - pdf_writer_write_string (_tmp124_, _tmp129_); -#line 342 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _g_free0 (_tmp129_); -#line 2695 "book.c" - } - } - } -#line 343 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp130_ = writer; -#line 343 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - pdf_writer_write_string (_tmp130_, " ]\n"); -#line 344 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp131_ = writer; -#line 344 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp132_ = book_get_n_pages (self); -#line 344 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp133_ = _tmp132_; -#line 344 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp134_ = g_strdup_printf ("/Count %u\n", _tmp133_); -#line 344 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp135_ = _tmp134_; -#line 344 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - pdf_writer_write_string (_tmp131_, _tmp135_); -#line 344 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _g_free0 (_tmp135_); -#line 345 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp136_ = writer; -#line 345 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - pdf_writer_write_string (_tmp136_, ">>\n"); -#line 346 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp137_ = writer; -#line 346 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - pdf_writer_write_string (_tmp137_, "endobj\n"); -#line 2725 "book.c" - { - gint i = 0; -#line 348 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - i = 0; -#line 2730 "book.c" - { - gboolean _tmp138_ = FALSE; -#line 348 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp138_ = TRUE; -#line 348 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - while (TRUE) { -#line 2737 "book.c" - gint _tmp140_ = 0; - guint _tmp141_ = 0U; - guint _tmp142_ = 0U; - Page* page = NULL; - gint _tmp143_ = 0; - Page* _tmp144_ = NULL; - GdkPixbuf* image = NULL; - Page* _tmp145_ = NULL; - GdkPixbuf* _tmp146_ = NULL; - gint width = 0; - GdkPixbuf* _tmp147_ = NULL; - gint _tmp148_ = 0; - gint _tmp149_ = 0; - gint height = 0; - GdkPixbuf* _tmp150_ = NULL; - gint _tmp151_ = 0; - gint _tmp152_ = 0; - guint8* pixels = NULL; - GdkPixbuf* _tmp153_ = NULL; - guint8* _tmp154_ = NULL; - gint pixels_length1 = 0; - gint _pixels_size_ = 0; - gdouble page_width = 0.0; - gint _tmp155_ = 0; - Page* _tmp156_ = NULL; - gint _tmp157_ = 0; - gint _tmp158_ = 0; - gdouble page_height = 0.0; - gint _tmp159_ = 0; - Page* _tmp160_ = NULL; - gint _tmp161_ = 0; - gint _tmp162_ = 0; - gint depth = 0; - gchar* color_space = NULL; - gchar* _tmp163_ = NULL; - gchar* filter = NULL; - gchar* width_buffer = NULL; - gchar* _tmp164_ = NULL; - gint width_buffer_length1 = 0; - gint _width_buffer_size_ = 0; - gchar* height_buffer = NULL; - gchar* _tmp165_ = NULL; - gint height_buffer_length1 = 0; - gint _height_buffer_size_ = 0; - guint8* data = NULL; - gint data_length1 = 0; - gint _data_size_ = 0; - Page* _tmp166_ = NULL; - gboolean _tmp167_ = FALSE; - gboolean _tmp168_ = FALSE; - guint8* compressed_data = NULL; - guint8* _tmp322_ = NULL; - gint _tmp322__length1 = 0; - gint _tmp323_ = 0; - guint8* _tmp324_ = NULL; - gint compressed_data_length1 = 0; - gint _compressed_data_size_ = 0; - guint8* _tmp325_ = NULL; - gint _tmp325__length1 = 0; - PDFWriter* _tmp343_ = NULL; - PDFWriter* _tmp344_ = NULL; - guint* _tmp345_ = NULL; - gint _tmp345__length1 = 0; - gint _tmp346_ = 0; - guint _tmp347_ = 0U; - PDFWriter* _tmp348_ = NULL; - guint* _tmp349_ = NULL; - gint _tmp349__length1 = 0; - gint _tmp350_ = 0; - guint _tmp351_ = 0U; - gchar* _tmp352_ = NULL; - gchar* _tmp353_ = NULL; - PDFWriter* _tmp354_ = NULL; - PDFWriter* _tmp355_ = NULL; - PDFWriter* _tmp356_ = NULL; - guint _tmp357_ = 0U; - gchar* _tmp358_ = NULL; - gchar* _tmp359_ = NULL; - PDFWriter* _tmp360_ = NULL; - gint _tmp361_ = 0; - guint* _tmp362_ = NULL; - gint _tmp362__length1 = 0; - gint _tmp363_ = 0; - guint _tmp364_ = 0U; - gchar* _tmp365_ = NULL; - gchar* _tmp366_ = NULL; - PDFWriter* _tmp367_ = NULL; - gdouble _tmp368_ = 0.0; - gchar* _tmp369_ = NULL; - gint _tmp369__length1 = 0; - const gchar* _tmp370_ = NULL; - gdouble _tmp371_ = 0.0; - gchar* _tmp372_ = NULL; - gint _tmp372__length1 = 0; - const gchar* _tmp373_ = NULL; - gchar* _tmp374_ = NULL; - gchar* _tmp375_ = NULL; - PDFWriter* _tmp376_ = NULL; - guint* _tmp377_ = NULL; - gint _tmp377__length1 = 0; - gint _tmp378_ = 0; - guint _tmp379_ = 0U; - gchar* _tmp380_ = NULL; - gchar* _tmp381_ = NULL; - PDFWriter* _tmp382_ = NULL; - PDFWriter* _tmp383_ = NULL; - PDFWriter* _tmp384_ = NULL; - PDFWriter* _tmp385_ = NULL; - guint* _tmp386_ = NULL; - gint _tmp386__length1 = 0; - gint _tmp387_ = 0; - guint _tmp388_ = 0U; - PDFWriter* _tmp389_ = NULL; - guint* _tmp390_ = NULL; - gint _tmp390__length1 = 0; - gint _tmp391_ = 0; - guint _tmp392_ = 0U; - gchar* _tmp393_ = NULL; - gchar* _tmp394_ = NULL; - PDFWriter* _tmp395_ = NULL; - PDFWriter* _tmp396_ = NULL; - PDFWriter* _tmp397_ = NULL; - PDFWriter* _tmp398_ = NULL; - gint _tmp399_ = 0; - gchar* _tmp400_ = NULL; - gchar* _tmp401_ = NULL; - PDFWriter* _tmp402_ = NULL; - gint _tmp403_ = 0; - gchar* _tmp404_ = NULL; - gchar* _tmp405_ = NULL; - PDFWriter* _tmp406_ = NULL; - const gchar* _tmp407_ = NULL; - gchar* _tmp408_ = NULL; - gchar* _tmp409_ = NULL; - PDFWriter* _tmp410_ = NULL; - gint _tmp411_ = 0; - gchar* _tmp412_ = NULL; - gchar* _tmp413_ = NULL; - PDFWriter* _tmp414_ = NULL; - guint8* _tmp415_ = NULL; - gint _tmp415__length1 = 0; - gchar* _tmp416_ = NULL; - gchar* _tmp417_ = NULL; - const gchar* _tmp418_ = NULL; - PDFWriter* _tmp423_ = NULL; - PDFWriter* _tmp424_ = NULL; - PDFWriter* _tmp425_ = NULL; - guint8* _tmp426_ = NULL; - gint _tmp426__length1 = 0; - PDFWriter* _tmp427_ = NULL; - PDFWriter* _tmp428_ = NULL; - PDFWriter* _tmp429_ = NULL; - PDFWriter* _tmp430_ = NULL; - PDFWriter* _tmp431_ = NULL; - guint _tmp432_ = 0U; - PDFWriter* _tmp433_ = NULL; - guint _tmp434_ = 0U; - gchar* _tmp435_ = NULL; - gchar* _tmp436_ = NULL; - PDFWriter* _tmp437_ = NULL; - PDFWriter* _tmp438_ = NULL; - PDFWriter* _tmp439_ = NULL; - PDFWriter* _tmp440_ = NULL; - gchar* command = NULL; - gdouble _tmp441_ = 0.0; - gchar* _tmp442_ = NULL; - gint _tmp442__length1 = 0; - const gchar* _tmp443_ = NULL; - gdouble _tmp444_ = 0.0; - gchar* _tmp445_ = NULL; - gint _tmp445__length1 = 0; - const gchar* _tmp446_ = NULL; - gint _tmp447_ = 0; - gchar* _tmp448_ = NULL; - PDFWriter* _tmp449_ = NULL; - PDFWriter* _tmp450_ = NULL; - guint* _tmp451_ = NULL; - gint _tmp451__length1 = 0; - gint _tmp452_ = 0; - guint _tmp453_ = 0U; - PDFWriter* _tmp454_ = NULL; - guint* _tmp455_ = NULL; - gint _tmp455__length1 = 0; - gint _tmp456_ = 0; - guint _tmp457_ = 0U; - gchar* _tmp458_ = NULL; - gchar* _tmp459_ = NULL; - PDFWriter* _tmp460_ = NULL; - PDFWriter* _tmp461_ = NULL; - const gchar* _tmp462_ = NULL; - gint _tmp463_ = 0; - gint _tmp464_ = 0; - gchar* _tmp465_ = NULL; - gchar* _tmp466_ = NULL; - PDFWriter* _tmp467_ = NULL; - PDFWriter* _tmp468_ = NULL; - PDFWriter* _tmp469_ = NULL; - const gchar* _tmp470_ = NULL; - PDFWriter* _tmp471_ = NULL; - PDFWriter* _tmp472_ = NULL; - PDFWriter* _tmp473_ = NULL; - gint _tmp474_ = 0; -#line 348 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - if (!_tmp138_) { -#line 2942 "book.c" - gint _tmp139_ = 0; -#line 348 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp139_ = i; -#line 348 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - i = _tmp139_ + 1; -#line 2948 "book.c" - } -#line 348 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp138_ = FALSE; -#line 348 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp140_ = i; -#line 348 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp141_ = book_get_n_pages (self); -#line 348 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp142_ = _tmp141_; -#line 348 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - if (!(((guint) _tmp140_) < _tmp142_)) { -#line 348 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - break; -#line 2962 "book.c" - } -#line 350 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp143_ = i; -#line 350 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp144_ = book_get_page (self, _tmp143_); -#line 350 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - page = _tmp144_; -#line 351 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp145_ = page; -#line 351 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp146_ = page_get_image (_tmp145_, TRUE); -#line 351 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - image = _tmp146_; -#line 352 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp147_ = image; -#line 352 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp148_ = gdk_pixbuf_get_width (_tmp147_); -#line 352 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp149_ = _tmp148_; -#line 352 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - width = _tmp149_; -#line 353 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp150_ = image; -#line 353 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp151_ = gdk_pixbuf_get_height (_tmp150_); -#line 353 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp152_ = _tmp151_; -#line 353 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - height = _tmp152_; -#line 354 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp153_ = image; -#line 354 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp154_ = gdk_pixbuf_get_pixels (_tmp153_); -#line 354 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - pixels = _tmp154_; -#line 354 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - pixels_length1 = -1; -#line 354 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _pixels_size_ = pixels_length1; -#line 355 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp155_ = width; -#line 355 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp156_ = page; -#line 355 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp157_ = page_get_dpi (_tmp156_); -#line 355 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp158_ = _tmp157_; -#line 355 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - page_width = (_tmp155_ * 72.0) / _tmp158_; -#line 356 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp159_ = height; -#line 356 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp160_ = page; -#line 356 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp161_ = page_get_dpi (_tmp160_); -#line 356 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp162_ = _tmp161_; -#line 356 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - page_height = (_tmp159_ * 72.0) / _tmp162_; -#line 358 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - depth = 8; -#line 359 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp163_ = g_strdup ("DeviceRGB"); -#line 359 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - color_space = _tmp163_; -#line 360 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - filter = NULL; -#line 361 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp164_ = g_new0 (gchar, G_ASCII_DTOSTR_BUF_SIZE); -#line 361 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - width_buffer = _tmp164_; -#line 361 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - width_buffer_length1 = G_ASCII_DTOSTR_BUF_SIZE; -#line 361 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _width_buffer_size_ = width_buffer_length1; -#line 362 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp165_ = g_new0 (gchar, G_ASCII_DTOSTR_BUF_SIZE); -#line 362 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - height_buffer = _tmp165_; -#line 362 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - height_buffer_length1 = G_ASCII_DTOSTR_BUF_SIZE; -#line 362 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _height_buffer_size_ = height_buffer_length1; -#line 364 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp166_ = page; -#line 364 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp167_ = page_get_is_color (_tmp166_); -#line 364 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp168_ = _tmp167_; -#line 364 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - if (_tmp168_) { -#line 3054 "book.c" - gchar* _tmp169_ = NULL; - gint data_length = 0; - gint _tmp170_ = 0; - gint _tmp171_ = 0; - gint _tmp172_ = 0; - guint8* _tmp173_ = NULL; -#line 366 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - depth = 8; -#line 367 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp169_ = g_strdup ("DeviceRGB"); -#line 367 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _g_free0 (color_space); -#line 367 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - color_space = _tmp169_; -#line 368 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp170_ = height; -#line 368 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp171_ = width; -#line 368 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - data_length = (_tmp170_ * _tmp171_) * 3; -#line 369 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp172_ = data_length; -#line 369 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp173_ = g_new0 (guint8, _tmp172_); -#line 369 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - data = (g_free (data), NULL); -#line 369 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - data = _tmp173_; -#line 369 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - data_length1 = _tmp172_; -#line 369 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _data_size_ = data_length1; -#line 3087 "book.c" - { - gint row = 0; -#line 370 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - row = 0; -#line 3092 "book.c" - { - gboolean _tmp174_ = FALSE; -#line 370 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp174_ = TRUE; -#line 370 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - while (TRUE) { -#line 3099 "book.c" - gint _tmp176_ = 0; - gint _tmp177_ = 0; - gint in_offset = 0; - gint _tmp178_ = 0; - GdkPixbuf* _tmp179_ = NULL; - gint _tmp180_ = 0; - gint _tmp181_ = 0; - gint out_offset = 0; - gint _tmp182_ = 0; - gint _tmp183_ = 0; -#line 370 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - if (!_tmp174_) { -#line 3112 "book.c" - gint _tmp175_ = 0; -#line 370 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp175_ = row; -#line 370 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - row = _tmp175_ + 1; -#line 3118 "book.c" - } -#line 370 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp174_ = FALSE; -#line 370 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp176_ = row; -#line 370 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp177_ = height; -#line 370 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - if (!(_tmp176_ < _tmp177_)) { -#line 370 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - break; -#line 3130 "book.c" - } -#line 372 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp178_ = row; -#line 372 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp179_ = image; -#line 372 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp180_ = gdk_pixbuf_get_rowstride (_tmp179_); -#line 372 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp181_ = _tmp180_; -#line 372 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - in_offset = _tmp178_ * _tmp181_; -#line 373 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp182_ = row; -#line 373 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp183_ = width; -#line 373 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - out_offset = (_tmp182_ * _tmp183_) * 3; -#line 3148 "book.c" - { - gint x = 0; -#line 374 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - x = 0; -#line 3153 "book.c" - { - gboolean _tmp184_ = FALSE; -#line 374 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp184_ = TRUE; -#line 374 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - while (TRUE) { -#line 3160 "book.c" - gint _tmp186_ = 0; - gint _tmp187_ = 0; - gint in_o = 0; - gint _tmp188_ = 0; - gint _tmp189_ = 0; - gint out_o = 0; - gint _tmp190_ = 0; - gint _tmp191_ = 0; - guint8* _tmp192_ = NULL; - gint _tmp192__length1 = 0; - gint _tmp193_ = 0; - guint8* _tmp194_ = NULL; - gint _tmp194__length1 = 0; - gint _tmp195_ = 0; - guint8 _tmp196_ = 0U; - guint8 _tmp197_ = 0U; - guint8* _tmp198_ = NULL; - gint _tmp198__length1 = 0; - gint _tmp199_ = 0; - guint8* _tmp200_ = NULL; - gint _tmp200__length1 = 0; - gint _tmp201_ = 0; - guint8 _tmp202_ = 0U; - guint8 _tmp203_ = 0U; - guint8* _tmp204_ = NULL; - gint _tmp204__length1 = 0; - gint _tmp205_ = 0; - guint8* _tmp206_ = NULL; - gint _tmp206__length1 = 0; - gint _tmp207_ = 0; - guint8 _tmp208_ = 0U; - guint8 _tmp209_ = 0U; -#line 374 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - if (!_tmp184_) { -#line 3195 "book.c" - gint _tmp185_ = 0; -#line 374 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp185_ = x; -#line 374 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - x = _tmp185_ + 1; -#line 3201 "book.c" - } -#line 374 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp184_ = FALSE; -#line 374 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp186_ = x; -#line 374 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp187_ = width; -#line 374 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - if (!(_tmp186_ < _tmp187_)) { -#line 374 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - break; -#line 3213 "book.c" - } -#line 376 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp188_ = in_offset; -#line 376 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp189_ = x; -#line 376 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - in_o = _tmp188_ + (_tmp189_ * 3); -#line 377 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp190_ = out_offset; -#line 377 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp191_ = x; -#line 377 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - out_o = _tmp190_ + (_tmp191_ * 3); -#line 379 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp192_ = data; -#line 379 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp192__length1 = data_length1; -#line 379 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp193_ = out_o; -#line 379 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp194_ = pixels; -#line 379 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp194__length1 = pixels_length1; -#line 379 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp195_ = in_o; -#line 379 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp196_ = _tmp194_[_tmp195_]; -#line 379 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp192_[_tmp193_] = _tmp196_; -#line 379 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp197_ = _tmp192_[_tmp193_]; -#line 380 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp198_ = data; -#line 380 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp198__length1 = data_length1; -#line 380 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp199_ = out_o; -#line 380 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp200_ = pixels; -#line 380 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp200__length1 = pixels_length1; -#line 380 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp201_ = in_o; -#line 380 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp202_ = _tmp200_[_tmp201_ + 1]; -#line 380 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp198_[_tmp199_ + 1] = _tmp202_; -#line 380 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp203_ = _tmp198_[_tmp199_ + 1]; -#line 381 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp204_ = data; -#line 381 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp204__length1 = data_length1; -#line 381 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp205_ = out_o; -#line 381 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp206_ = pixels; -#line 381 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp206__length1 = pixels_length1; -#line 381 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp207_ = in_o; -#line 381 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp208_ = _tmp206_[_tmp207_ + 2]; -#line 381 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp204_[_tmp205_ + 2] = _tmp208_; -#line 381 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp209_ = _tmp204_[_tmp205_ + 2]; -#line 3281 "book.c" - } - } - } - } - } - } - } else { - Page* _tmp210_ = NULL; - gint _tmp211_ = 0; - gint _tmp212_ = 0; -#line 385 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp210_ = page; -#line 385 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp211_ = page_get_depth (_tmp210_); -#line 385 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp212_ = _tmp211_; -#line 385 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - if (_tmp212_ == 2) { -#line 3300 "book.c" - gint shift_count = 0; - gchar* _tmp213_ = NULL; - gint data_length = 0; - gint _tmp214_ = 0; - gint _tmp215_ = 0; - gint _tmp216_ = 0; - guint8* _tmp217_ = NULL; - gint offset = 0; -#line 387 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - shift_count = 6; -#line 388 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - depth = 2; -#line 389 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp213_ = g_strdup ("DeviceGray"); -#line 389 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _g_free0 (color_space); -#line 389 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - color_space = _tmp213_; -#line 390 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp214_ = height; -#line 390 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp215_ = width; -#line 390 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - data_length = _tmp214_ * (((_tmp215_ * 2) + 7) / 8); -#line 391 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp216_ = data_length; -#line 391 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp217_ = g_new0 (guint8, _tmp216_); -#line 391 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - data = (g_free (data), NULL); -#line 391 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - data = _tmp217_; -#line 391 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - data_length1 = _tmp216_; -#line 391 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _data_size_ = data_length1; -#line 392 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - offset = 0; -#line 3339 "book.c" - { - gint row = 0; -#line 393 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - row = 0; -#line 3344 "book.c" - { - gboolean _tmp218_ = FALSE; -#line 393 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp218_ = TRUE; -#line 393 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - while (TRUE) { -#line 3351 "book.c" - gint _tmp220_ = 0; - gint _tmp221_ = 0; - gint _tmp222_ = 0; - gint in_offset = 0; - gint _tmp224_ = 0; - GdkPixbuf* _tmp225_ = NULL; - gint _tmp226_ = 0; - gint _tmp227_ = 0; -#line 393 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - if (!_tmp218_) { -#line 3362 "book.c" - gint _tmp219_ = 0; -#line 393 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp219_ = row; -#line 393 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - row = _tmp219_ + 1; -#line 3368 "book.c" - } -#line 393 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp218_ = FALSE; -#line 393 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp220_ = row; -#line 393 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp221_ = height; -#line 393 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - if (!(_tmp220_ < _tmp221_)) { -#line 393 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - break; -#line 3380 "book.c" - } -#line 396 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp222_ = shift_count; -#line 396 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - if (_tmp222_ != 6) { -#line 3386 "book.c" - gint _tmp223_ = 0; -#line 398 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp223_ = offset; -#line 398 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - offset = _tmp223_ + 1; -#line 399 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - shift_count = 6; -#line 3394 "book.c" - } -#line 402 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp224_ = row; -#line 402 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp225_ = image; -#line 402 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp226_ = gdk_pixbuf_get_rowstride (_tmp225_); -#line 402 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp227_ = _tmp226_; -#line 402 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - in_offset = _tmp224_ * _tmp227_; -#line 3406 "book.c" - { - gint x = 0; -#line 403 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - x = 0; -#line 3411 "book.c" - { - gboolean _tmp228_ = FALSE; -#line 403 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp228_ = TRUE; -#line 403 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - while (TRUE) { -#line 3418 "book.c" - gint _tmp230_ = 0; - gint _tmp231_ = 0; - gint _tmp232_ = 0; - guint8 p = 0U; - guint8* _tmp236_ = NULL; - gint _tmp236__length1 = 0; - gint _tmp237_ = 0; - gint _tmp238_ = 0; - guint8 _tmp239_ = 0U; - guint8 _tmp240_ = 0U; - gint _tmp255_ = 0; -#line 403 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - if (!_tmp228_) { -#line 3432 "book.c" - gint _tmp229_ = 0; -#line 403 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp229_ = x; -#line 403 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - x = _tmp229_ + 1; -#line 3438 "book.c" - } -#line 403 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp228_ = FALSE; -#line 403 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp230_ = x; -#line 403 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp231_ = width; -#line 403 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - if (!(_tmp230_ < _tmp231_)) { -#line 403 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - break; -#line 3450 "book.c" - } -#line 406 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp232_ = shift_count; -#line 406 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - if (_tmp232_ == 6) { -#line 3456 "book.c" - guint8* _tmp233_ = NULL; - gint _tmp233__length1 = 0; - gint _tmp234_ = 0; - guint8 _tmp235_ = 0U; -#line 407 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp233_ = data; -#line 407 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp233__length1 = data_length1; -#line 407 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp234_ = offset; -#line 407 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp233_[_tmp234_] = (guint8) 0; -#line 407 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp235_ = _tmp233_[_tmp234_]; -#line 3471 "book.c" - } -#line 410 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp236_ = pixels; -#line 410 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp236__length1 = pixels_length1; -#line 410 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp237_ = in_offset; -#line 410 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp238_ = x; -#line 410 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp239_ = _tmp236_[_tmp237_ + (_tmp238_ * 3)]; -#line 410 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - p = _tmp239_; -#line 411 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp240_ = p; -#line 411 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - if (((gint) _tmp240_) >= 192) { -#line 3489 "book.c" - guint8* _tmp241_ = NULL; - gint _tmp241__length1 = 0; - gint _tmp242_ = 0; - gint _tmp243_ = 0; - guint8 _tmp244_ = 0U; -#line 412 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp241_ = data; -#line 412 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp241__length1 = data_length1; -#line 412 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp242_ = offset; -#line 412 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp243_ = shift_count; -#line 412 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp241_[_tmp242_] |= (guint8) (3 << _tmp243_); -#line 412 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp244_ = _tmp241_[_tmp242_]; -#line 3507 "book.c" - } else { - guint8 _tmp245_ = 0U; -#line 413 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp245_ = p; -#line 413 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - if (((gint) _tmp245_) >= 128) { -#line 3514 "book.c" - guint8* _tmp246_ = NULL; - gint _tmp246__length1 = 0; - gint _tmp247_ = 0; - gint _tmp248_ = 0; - guint8 _tmp249_ = 0U; -#line 414 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp246_ = data; -#line 414 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp246__length1 = data_length1; -#line 414 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp247_ = offset; -#line 414 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp248_ = shift_count; -#line 414 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp246_[_tmp247_] |= (guint8) (2 << _tmp248_); -#line 414 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp249_ = _tmp246_[_tmp247_]; -#line 3532 "book.c" - } else { - guint8 _tmp250_ = 0U; -#line 415 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp250_ = p; -#line 415 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - if (((gint) _tmp250_) >= 64) { -#line 3539 "book.c" - guint8* _tmp251_ = NULL; - gint _tmp251__length1 = 0; - gint _tmp252_ = 0; - gint _tmp253_ = 0; - guint8 _tmp254_ = 0U; -#line 416 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp251_ = data; -#line 416 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp251__length1 = data_length1; -#line 416 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp252_ = offset; -#line 416 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp253_ = shift_count; -#line 416 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp251_[_tmp252_] |= (guint8) (1 << _tmp253_); -#line 416 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp254_ = _tmp251_[_tmp252_]; -#line 3557 "book.c" - } - } - } -#line 419 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp255_ = shift_count; -#line 419 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - if (_tmp255_ == 0) { -#line 3565 "book.c" - gint _tmp256_ = 0; -#line 421 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp256_ = offset; -#line 421 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - offset = _tmp256_ + 1; -#line 422 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - shift_count = 6; -#line 3573 "book.c" - } else { - gint _tmp257_ = 0; -#line 425 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp257_ = shift_count; -#line 425 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - shift_count = _tmp257_ - 2; -#line 3580 "book.c" - } - } - } - } - } - } - } - } else { - Page* _tmp258_ = NULL; - gint _tmp259_ = 0; - gint _tmp260_ = 0; -#line 429 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp258_ = page; -#line 429 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp259_ = page_get_depth (_tmp258_); -#line 429 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp260_ = _tmp259_; -#line 429 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - if (_tmp260_ == 1) { -#line 3600 "book.c" - gint mask = 0; - gchar* _tmp261_ = NULL; - gint data_length = 0; - gint _tmp262_ = 0; - gint _tmp263_ = 0; - gint _tmp264_ = 0; - guint8* _tmp265_ = NULL; - gint offset = 0; -#line 431 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - mask = 0x80; -#line 433 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - depth = 1; -#line 434 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp261_ = g_strdup ("DeviceGray"); -#line 434 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _g_free0 (color_space); -#line 434 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - color_space = _tmp261_; -#line 435 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp262_ = height; -#line 435 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp263_ = width; -#line 435 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - data_length = _tmp262_ * ((_tmp263_ + 7) / 8); -#line 436 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp264_ = data_length; -#line 436 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp265_ = g_new0 (guint8, _tmp264_); -#line 436 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - data = (g_free (data), NULL); -#line 436 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - data = _tmp265_; -#line 436 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - data_length1 = _tmp264_; -#line 436 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _data_size_ = data_length1; -#line 437 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - offset = 0; -#line 3639 "book.c" - { - gint row = 0; -#line 438 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - row = 0; -#line 3644 "book.c" - { - gboolean _tmp266_ = FALSE; -#line 438 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp266_ = TRUE; -#line 438 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - while (TRUE) { -#line 3651 "book.c" - gint _tmp268_ = 0; - gint _tmp269_ = 0; - gint _tmp270_ = 0; - gint in_offset = 0; - gint _tmp272_ = 0; - GdkPixbuf* _tmp273_ = NULL; - gint _tmp274_ = 0; - gint _tmp275_ = 0; -#line 438 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - if (!_tmp266_) { -#line 3662 "book.c" - gint _tmp267_ = 0; -#line 438 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp267_ = row; -#line 438 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - row = _tmp267_ + 1; -#line 3668 "book.c" - } -#line 438 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp266_ = FALSE; -#line 438 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp268_ = row; -#line 438 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp269_ = height; -#line 438 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - if (!(_tmp268_ < _tmp269_)) { -#line 438 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - break; -#line 3680 "book.c" - } -#line 441 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp270_ = mask; -#line 441 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - if (_tmp270_ != 0x80) { -#line 3686 "book.c" - gint _tmp271_ = 0; -#line 443 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp271_ = offset; -#line 443 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - offset = _tmp271_ + 1; -#line 444 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - mask = 0x80; -#line 3694 "book.c" - } -#line 447 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp272_ = row; -#line 447 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp273_ = image; -#line 447 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp274_ = gdk_pixbuf_get_rowstride (_tmp273_); -#line 447 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp275_ = _tmp274_; -#line 447 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - in_offset = _tmp272_ * _tmp275_; -#line 3706 "book.c" - { - gint x = 0; -#line 448 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - x = 0; -#line 3711 "book.c" - { - gboolean _tmp276_ = FALSE; -#line 448 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp276_ = TRUE; -#line 448 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - while (TRUE) { -#line 3718 "book.c" - gint _tmp278_ = 0; - gint _tmp279_ = 0; - gint _tmp280_ = 0; - guint8* _tmp284_ = NULL; - gint _tmp284__length1 = 0; - gint _tmp285_ = 0; - gint _tmp286_ = 0; - guint8 _tmp287_ = 0U; - gint _tmp292_ = 0; - gint _tmp293_ = 0; -#line 448 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - if (!_tmp276_) { -#line 3731 "book.c" - gint _tmp277_ = 0; -#line 448 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp277_ = x; -#line 448 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - x = _tmp277_ + 1; -#line 3737 "book.c" - } -#line 448 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp276_ = FALSE; -#line 448 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp278_ = x; -#line 448 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp279_ = width; -#line 448 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - if (!(_tmp278_ < _tmp279_)) { -#line 448 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - break; -#line 3749 "book.c" - } -#line 451 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp280_ = mask; -#line 451 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - if (_tmp280_ == 0x80) { -#line 3755 "book.c" - guint8* _tmp281_ = NULL; - gint _tmp281__length1 = 0; - gint _tmp282_ = 0; - guint8 _tmp283_ = 0U; -#line 452 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp281_ = data; -#line 452 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp281__length1 = data_length1; -#line 452 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp282_ = offset; -#line 452 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp281_[_tmp282_] = (guint8) 0; -#line 452 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp283_ = _tmp281_[_tmp282_]; -#line 3770 "book.c" - } -#line 455 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp284_ = pixels; -#line 455 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp284__length1 = pixels_length1; -#line 455 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp285_ = in_offset; -#line 455 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp286_ = x; -#line 455 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp287_ = _tmp284_[_tmp285_ + (_tmp286_ * 3)]; -#line 455 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - if (((gint) _tmp287_) != 0) { -#line 3784 "book.c" - guint8* _tmp288_ = NULL; - gint _tmp288__length1 = 0; - gint _tmp289_ = 0; - gint _tmp290_ = 0; - guint8 _tmp291_ = 0U; -#line 456 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp288_ = data; -#line 456 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp288__length1 = data_length1; -#line 456 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp289_ = offset; -#line 456 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp290_ = mask; -#line 456 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp288_[_tmp289_] |= (guint8) _tmp290_; -#line 456 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp291_ = _tmp288_[_tmp289_]; -#line 3802 "book.c" - } -#line 459 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp292_ = mask; -#line 459 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - mask = _tmp292_ >> 1; -#line 460 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp293_ = mask; -#line 460 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - if (_tmp293_ == 0) { -#line 3812 "book.c" - gint _tmp294_ = 0; -#line 462 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp294_ = offset; -#line 462 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - offset = _tmp294_ + 1; -#line 463 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - mask = 0x80; -#line 3820 "book.c" - } - } - } - } - } - } - } - } else { - gchar* _tmp295_ = NULL; - gint data_length = 0; - gint _tmp296_ = 0; - gint _tmp297_ = 0; - gint _tmp298_ = 0; - guint8* _tmp299_ = NULL; -#line 470 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - depth = 8; -#line 471 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp295_ = g_strdup ("DeviceGray"); -#line 471 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _g_free0 (color_space); -#line 471 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - color_space = _tmp295_; -#line 472 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp296_ = height; -#line 472 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp297_ = width; -#line 472 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - data_length = _tmp296_ * _tmp297_; -#line 473 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp298_ = data_length; -#line 473 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp299_ = g_new0 (guint8, _tmp298_); -#line 473 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - data = (g_free (data), NULL); -#line 473 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - data = _tmp299_; -#line 473 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - data_length1 = _tmp298_; -#line 473 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _data_size_ = data_length1; -#line 3861 "book.c" - { - gint row = 0; -#line 474 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - row = 0; -#line 3866 "book.c" - { - gboolean _tmp300_ = FALSE; -#line 474 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp300_ = TRUE; -#line 474 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - while (TRUE) { -#line 3873 "book.c" - gint _tmp302_ = 0; - gint _tmp303_ = 0; - gint in_offset = 0; - gint _tmp304_ = 0; - GdkPixbuf* _tmp305_ = NULL; - gint _tmp306_ = 0; - gint _tmp307_ = 0; - gint out_offset = 0; - gint _tmp308_ = 0; - gint _tmp309_ = 0; -#line 474 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - if (!_tmp300_) { -#line 3886 "book.c" - gint _tmp301_ = 0; -#line 474 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp301_ = row; -#line 474 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - row = _tmp301_ + 1; -#line 3892 "book.c" - } -#line 474 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp300_ = FALSE; -#line 474 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp302_ = row; -#line 474 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp303_ = height; -#line 474 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - if (!(_tmp302_ < _tmp303_)) { -#line 474 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - break; -#line 3904 "book.c" - } -#line 476 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp304_ = row; -#line 476 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp305_ = image; -#line 476 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp306_ = gdk_pixbuf_get_rowstride (_tmp305_); -#line 476 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp307_ = _tmp306_; -#line 476 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - in_offset = _tmp304_ * _tmp307_; -#line 477 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp308_ = row; -#line 477 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp309_ = width; -#line 477 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - out_offset = _tmp308_ * _tmp309_; -#line 3922 "book.c" - { - gint x = 0; -#line 478 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - x = 0; -#line 3927 "book.c" - { - gboolean _tmp310_ = FALSE; -#line 478 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp310_ = TRUE; -#line 478 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - while (TRUE) { -#line 3934 "book.c" - gint _tmp312_ = 0; - gint _tmp313_ = 0; - guint8* _tmp314_ = NULL; - gint _tmp314__length1 = 0; - gint _tmp315_ = 0; - gint _tmp316_ = 0; - guint8* _tmp317_ = NULL; - gint _tmp317__length1 = 0; - gint _tmp318_ = 0; - gint _tmp319_ = 0; - guint8 _tmp320_ = 0U; - guint8 _tmp321_ = 0U; -#line 478 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - if (!_tmp310_) { -#line 3949 "book.c" - gint _tmp311_ = 0; -#line 478 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp311_ = x; -#line 478 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - x = _tmp311_ + 1; -#line 3955 "book.c" - } -#line 478 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp310_ = FALSE; -#line 478 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp312_ = x; -#line 478 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp313_ = width; -#line 478 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - if (!(_tmp312_ < _tmp313_)) { -#line 478 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - break; -#line 3967 "book.c" - } -#line 479 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp314_ = data; -#line 479 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp314__length1 = data_length1; -#line 479 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp315_ = out_offset; -#line 479 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp316_ = x; -#line 479 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp317_ = pixels; -#line 479 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp317__length1 = pixels_length1; -#line 479 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp318_ = in_offset; -#line 479 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp319_ = x; -#line 479 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp320_ = _tmp317_[_tmp318_ + (_tmp319_ * 3)]; -#line 479 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp314_[_tmp315_ + _tmp316_] = _tmp320_; -#line 479 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp321_ = _tmp314_[_tmp315_ + _tmp316_]; -#line 3991 "book.c" - } - } - } - } - } - } - } - } - } -#line 484 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp322_ = data; -#line 484 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp322__length1 = data_length1; -#line 484 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp324_ = book_compress_zlib (self, _tmp322_, _tmp322__length1, &_tmp323_); -#line 484 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - compressed_data = _tmp324_; -#line 484 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - compressed_data_length1 = _tmp323_; -#line 484 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _compressed_data_size_ = compressed_data_length1; -#line 485 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp325_ = compressed_data; -#line 485 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp325__length1 = compressed_data_length1; -#line 485 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - if (_tmp325_ != NULL) { -#line 4019 "book.c" - gint _tmp326_ = 0; - const gchar* _tmp339_ = NULL; -#line 488 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp326_ = depth; -#line 488 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - if (_tmp326_ > 1) { -#line 4026 "book.c" - guint8* jpeg_data = NULL; - GdkPixbuf* _tmp327_ = NULL; - gint _tmp328_ = 0; - Page* _tmp329_ = NULL; - gint _tmp330_ = 0; - gint _tmp331_ = 0; - gint _tmp332_ = 0; - guint8* _tmp333_ = NULL; - gint jpeg_data_length1 = 0; - gint _jpeg_data_size_ = 0; - guint8* _tmp334_ = NULL; - gint _tmp334__length1 = 0; - guint8* _tmp335_ = NULL; - gint _tmp335__length1 = 0; -#line 490 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp327_ = image; -#line 490 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp328_ = quality; -#line 490 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp329_ = page; -#line 490 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp330_ = page_get_dpi (_tmp329_); -#line 490 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp331_ = _tmp330_; -#line 490 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp333_ = book_compress_jpeg (self, _tmp327_, _tmp328_, _tmp331_, &_tmp332_); -#line 490 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - jpeg_data = _tmp333_; -#line 490 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - jpeg_data_length1 = _tmp332_; -#line 490 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _jpeg_data_size_ = jpeg_data_length1; -#line 491 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp334_ = jpeg_data; -#line 491 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp334__length1 = jpeg_data_length1; -#line 491 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp335_ = compressed_data; -#line 491 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp335__length1 = compressed_data_length1; -#line 491 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - if (_tmp334__length1 < _tmp335__length1) { -#line 4069 "book.c" - gchar* _tmp336_ = NULL; - guint8* _tmp337_ = NULL; - gint _tmp337__length1 = 0; - guint8* _tmp338_ = NULL; - gint _tmp338__length1 = 0; -#line 493 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp336_ = g_strdup ("DCTDecode"); -#line 493 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _g_free0 (filter); -#line 493 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - filter = _tmp336_; -#line 494 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp337_ = jpeg_data; -#line 494 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp337__length1 = jpeg_data_length1; -#line 494 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp338_ = (_tmp337_ != NULL) ? _vala_array_dup1 (_tmp337_, _tmp337__length1) : ((gpointer) _tmp337_); -#line 494 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp338__length1 = _tmp337__length1; -#line 494 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - data = (g_free (data), NULL); -#line 494 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - data = _tmp338_; -#line 494 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - data_length1 = _tmp338__length1; -#line 494 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _data_size_ = data_length1; -#line 4097 "book.c" - } -#line 488 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - jpeg_data = (g_free (jpeg_data), NULL); -#line 4101 "book.c" - } -#line 498 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp339_ = filter; -#line 498 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - if (_tmp339_ == NULL) { -#line 4107 "book.c" - gchar* _tmp340_ = NULL; - guint8* _tmp341_ = NULL; - gint _tmp341__length1 = 0; - guint8* _tmp342_ = NULL; - gint _tmp342__length1 = 0; -#line 500 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp340_ = g_strdup ("FlateDecode"); -#line 500 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _g_free0 (filter); -#line 500 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - filter = _tmp340_; -#line 501 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp341_ = compressed_data; -#line 501 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp341__length1 = compressed_data_length1; -#line 501 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp342_ = (_tmp341_ != NULL) ? _vala_array_dup2 (_tmp341_, _tmp341__length1) : ((gpointer) _tmp341_); -#line 501 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp342__length1 = _tmp341__length1; -#line 501 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - data = (g_free (data), NULL); -#line 501 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - data = _tmp342_; -#line 501 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - data_length1 = _tmp342__length1; -#line 501 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _data_size_ = data_length1; -#line 4135 "book.c" - } - } -#line 506 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp343_ = writer; -#line 506 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - pdf_writer_write_string (_tmp343_, "\n"); -#line 507 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp344_ = writer; -#line 507 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp345_ = page_numbers; -#line 507 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp345__length1 = page_numbers_length1; -#line 507 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp346_ = i; -#line 507 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp347_ = _tmp345_[_tmp346_]; -#line 507 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - pdf_writer_start_object (_tmp344_, _tmp347_); -#line 508 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp348_ = writer; -#line 508 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp349_ = page_numbers; -#line 508 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp349__length1 = page_numbers_length1; -#line 508 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp350_ = i; -#line 508 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp351_ = _tmp349_[_tmp350_]; -#line 508 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp352_ = g_strdup_printf ("%u 0 obj\n", _tmp351_); -#line 508 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp353_ = _tmp352_; -#line 508 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - pdf_writer_write_string (_tmp348_, _tmp353_); -#line 508 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _g_free0 (_tmp353_); -#line 509 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp354_ = writer; -#line 509 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - pdf_writer_write_string (_tmp354_, "<<\n"); -#line 510 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp355_ = writer; -#line 510 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - pdf_writer_write_string (_tmp355_, "/Type /Page\n"); -#line 511 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp356_ = writer; -#line 511 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp357_ = pages_number; -#line 511 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp358_ = g_strdup_printf ("/Parent %u 0 R\n", _tmp357_); -#line 511 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp359_ = _tmp358_; -#line 511 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - pdf_writer_write_string (_tmp356_, _tmp359_); -#line 511 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _g_free0 (_tmp359_); -#line 512 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp360_ = writer; -#line 512 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp361_ = i; -#line 512 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp362_ = page_image_numbers; -#line 512 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp362__length1 = page_image_numbers_length1; -#line 512 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp363_ = i; -#line 512 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp364_ = _tmp362_[_tmp363_]; -#line 512 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp365_ = g_strdup_printf ("/Resources << /XObject << /Im%d %u 0 R >> >>\n", _tmp361_, _tmp364_); -#line 512 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp366_ = _tmp365_; -#line 512 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - pdf_writer_write_string (_tmp360_, _tmp366_); -#line 512 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _g_free0 (_tmp366_); -#line 513 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp367_ = writer; -#line 513 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp368_ = page_width; -#line 513 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp369_ = width_buffer; -#line 513 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp369__length1 = width_buffer_length1; -#line 513 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp370_ = g_ascii_formatd (_tmp369_, _tmp369__length1, "%.2f", _tmp368_); -#line 513 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp371_ = page_height; -#line 513 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp372_ = height_buffer; -#line 513 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp372__length1 = height_buffer_length1; -#line 513 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp373_ = g_ascii_formatd (_tmp372_, _tmp372__length1, "%.2f", _tmp371_); -#line 513 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp374_ = g_strdup_printf ("/MediaBox [ 0 0 %s %s ]\n", _tmp370_, _tmp373_); -#line 513 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp375_ = _tmp374_; -#line 513 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - pdf_writer_write_string (_tmp367_, _tmp375_); -#line 513 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _g_free0 (_tmp375_); -#line 514 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp376_ = writer; -#line 514 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp377_ = page_content_numbers; -#line 514 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp377__length1 = page_content_numbers_length1; -#line 514 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp378_ = i; -#line 514 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp379_ = _tmp377_[_tmp378_]; -#line 514 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp380_ = g_strdup_printf ("/Contents %u 0 R\n", _tmp379_); -#line 514 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp381_ = _tmp380_; -#line 514 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - pdf_writer_write_string (_tmp376_, _tmp381_); -#line 514 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _g_free0 (_tmp381_); -#line 515 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp382_ = writer; -#line 515 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - pdf_writer_write_string (_tmp382_, ">>\n"); -#line 516 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp383_ = writer; -#line 516 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - pdf_writer_write_string (_tmp383_, "endobj\n"); -#line 519 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp384_ = writer; -#line 519 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - pdf_writer_write_string (_tmp384_, "\n"); -#line 520 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp385_ = writer; -#line 520 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp386_ = page_image_numbers; -#line 520 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp386__length1 = page_image_numbers_length1; -#line 520 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp387_ = i; -#line 520 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp388_ = _tmp386_[_tmp387_]; -#line 520 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - pdf_writer_start_object (_tmp385_, _tmp388_); -#line 521 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp389_ = writer; -#line 521 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp390_ = page_image_numbers; -#line 521 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp390__length1 = page_image_numbers_length1; -#line 521 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp391_ = i; -#line 521 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp392_ = _tmp390_[_tmp391_]; -#line 521 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp393_ = g_strdup_printf ("%u 0 obj\n", _tmp392_); -#line 521 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp394_ = _tmp393_; -#line 521 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - pdf_writer_write_string (_tmp389_, _tmp394_); -#line 521 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _g_free0 (_tmp394_); -#line 522 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp395_ = writer; -#line 522 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - pdf_writer_write_string (_tmp395_, "<<\n"); -#line 523 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp396_ = writer; -#line 523 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - pdf_writer_write_string (_tmp396_, "/Type /XObject\n"); -#line 524 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp397_ = writer; -#line 524 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - pdf_writer_write_string (_tmp397_, "/Subtype /Image\n"); -#line 525 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp398_ = writer; -#line 525 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp399_ = width; -#line 525 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp400_ = g_strdup_printf ("/Width %d\n", _tmp399_); -#line 525 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp401_ = _tmp400_; -#line 525 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - pdf_writer_write_string (_tmp398_, _tmp401_); -#line 525 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _g_free0 (_tmp401_); -#line 526 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp402_ = writer; -#line 526 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp403_ = height; -#line 526 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp404_ = g_strdup_printf ("/Height %d\n", _tmp403_); -#line 526 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp405_ = _tmp404_; -#line 526 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - pdf_writer_write_string (_tmp402_, _tmp405_); -#line 526 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _g_free0 (_tmp405_); -#line 527 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp406_ = writer; -#line 527 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp407_ = color_space; -#line 527 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp408_ = g_strdup_printf ("/ColorSpace /%s\n", _tmp407_); -#line 527 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp409_ = _tmp408_; -#line 527 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - pdf_writer_write_string (_tmp406_, _tmp409_); -#line 527 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _g_free0 (_tmp409_); -#line 528 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp410_ = writer; -#line 528 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp411_ = depth; -#line 528 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp412_ = g_strdup_printf ("/BitsPerComponent %d\n", _tmp411_); -#line 528 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp413_ = _tmp412_; -#line 528 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - pdf_writer_write_string (_tmp410_, _tmp413_); -#line 528 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _g_free0 (_tmp413_); -#line 529 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp414_ = writer; -#line 529 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp415_ = data; -#line 529 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp415__length1 = data_length1; -#line 529 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp416_ = g_strdup_printf ("/Length %d\n", _tmp415__length1); -#line 529 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp417_ = _tmp416_; -#line 529 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - pdf_writer_write_string (_tmp414_, _tmp417_); -#line 529 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _g_free0 (_tmp417_); -#line 530 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp418_ = filter; -#line 530 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - if (_tmp418_ != NULL) { -#line 4376 "book.c" - PDFWriter* _tmp419_ = NULL; - const gchar* _tmp420_ = NULL; - gchar* _tmp421_ = NULL; - gchar* _tmp422_ = NULL; -#line 531 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp419_ = writer; -#line 531 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp420_ = filter; -#line 531 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp421_ = g_strdup_printf ("/Filter /%s\n", _tmp420_); -#line 531 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp422_ = _tmp421_; -#line 531 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - pdf_writer_write_string (_tmp419_, _tmp422_); -#line 531 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _g_free0 (_tmp422_); -#line 4393 "book.c" - } -#line 532 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp423_ = writer; -#line 532 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - pdf_writer_write_string (_tmp423_, ">>\n"); -#line 533 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp424_ = writer; -#line 533 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - pdf_writer_write_string (_tmp424_, "stream\n"); -#line 534 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp425_ = writer; -#line 534 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp426_ = data; -#line 534 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp426__length1 = data_length1; -#line 534 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - pdf_writer_write (_tmp425_, _tmp426_, _tmp426__length1); -#line 535 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp427_ = writer; -#line 535 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - pdf_writer_write_string (_tmp427_, "\n"); -#line 536 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp428_ = writer; -#line 536 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - pdf_writer_write_string (_tmp428_, "endstream\n"); -#line 537 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp429_ = writer; -#line 537 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - pdf_writer_write_string (_tmp429_, "endobj\n"); -#line 540 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp430_ = writer; -#line 540 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - pdf_writer_write_string (_tmp430_, "\n"); -#line 541 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp431_ = writer; -#line 541 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp432_ = struct_tree_root_number; -#line 541 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - pdf_writer_start_object (_tmp431_, _tmp432_); -#line 542 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp433_ = writer; -#line 542 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp434_ = struct_tree_root_number; -#line 542 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp435_ = g_strdup_printf ("%u 0 obj\n", _tmp434_); -#line 542 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp436_ = _tmp435_; -#line 542 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - pdf_writer_write_string (_tmp433_, _tmp436_); -#line 542 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _g_free0 (_tmp436_); -#line 543 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp437_ = writer; -#line 543 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - pdf_writer_write_string (_tmp437_, "<<\n"); -#line 544 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp438_ = writer; -#line 544 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - pdf_writer_write_string (_tmp438_, "/Type /StructTreeRoot\n"); -#line 545 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp439_ = writer; -#line 545 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - pdf_writer_write_string (_tmp439_, ">>\n"); -#line 546 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp440_ = writer; -#line 546 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - pdf_writer_write_string (_tmp440_, "endobj\n"); -#line 549 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp441_ = page_width; -#line 549 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp442_ = width_buffer; -#line 549 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp442__length1 = width_buffer_length1; -#line 549 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp443_ = g_ascii_formatd (_tmp442_, _tmp442__length1, "%f", _tmp441_); -#line 549 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp444_ = page_height; -#line 549 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp445_ = height_buffer; -#line 549 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp445__length1 = height_buffer_length1; -#line 549 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp446_ = g_ascii_formatd (_tmp445_, _tmp445__length1, "%f", _tmp444_); -#line 549 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp447_ = i; -#line 549 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp448_ = g_strdup_printf ("q\n%s 0 0 %s 0 0 cm\n/Im%d Do\nQ", _tmp443_, _tmp446_, _tmp447_); -#line 549 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - command = _tmp448_; -#line 550 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp449_ = writer; -#line 550 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - pdf_writer_write_string (_tmp449_, "\n"); -#line 551 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp450_ = writer; -#line 551 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp451_ = page_content_numbers; -#line 551 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp451__length1 = page_content_numbers_length1; -#line 551 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp452_ = i; -#line 551 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp453_ = _tmp451_[_tmp452_]; -#line 551 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - pdf_writer_start_object (_tmp450_, _tmp453_); -#line 552 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp454_ = writer; -#line 552 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp455_ = page_content_numbers; -#line 552 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp455__length1 = page_content_numbers_length1; -#line 552 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp456_ = i; -#line 552 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp457_ = _tmp455_[_tmp456_]; -#line 552 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp458_ = g_strdup_printf ("%u 0 obj\n", _tmp457_); -#line 552 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp459_ = _tmp458_; -#line 552 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - pdf_writer_write_string (_tmp454_, _tmp459_); -#line 552 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _g_free0 (_tmp459_); -#line 553 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp460_ = writer; -#line 553 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - pdf_writer_write_string (_tmp460_, "<<\n"); -#line 554 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp461_ = writer; -#line 554 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp462_ = command; -#line 554 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp463_ = strlen (_tmp462_); -#line 554 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp464_ = _tmp463_; -#line 554 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp465_ = g_strdup_printf ("/Length %d\n", _tmp464_); -#line 554 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp466_ = _tmp465_; -#line 554 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - pdf_writer_write_string (_tmp461_, _tmp466_); -#line 554 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _g_free0 (_tmp466_); -#line 555 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp467_ = writer; -#line 555 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - pdf_writer_write_string (_tmp467_, ">>\n"); -#line 556 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp468_ = writer; -#line 556 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - pdf_writer_write_string (_tmp468_, "stream\n"); -#line 557 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp469_ = writer; -#line 557 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp470_ = command; -#line 557 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - pdf_writer_write_string (_tmp469_, _tmp470_); -#line 558 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp471_ = writer; -#line 558 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - pdf_writer_write_string (_tmp471_, "\n"); -#line 559 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp472_ = writer; -#line 559 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - pdf_writer_write_string (_tmp472_, "endstream\n"); -#line 560 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp473_ = writer; -#line 560 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - pdf_writer_write_string (_tmp473_, "endobj\n"); -#line 562 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp474_ = i; -#line 562 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - g_signal_emit_by_name (self, "saving", _tmp474_); -#line 348 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _g_free0 (command); -#line 348 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - compressed_data = (g_free (compressed_data), NULL); -#line 348 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - data = (g_free (data), NULL); -#line 348 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - height_buffer = (g_free (height_buffer), NULL); -#line 348 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - width_buffer = (g_free (width_buffer), NULL); -#line 348 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _g_free0 (filter); -#line 348 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _g_free0 (color_space); -#line 348 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _g_object_unref0 (image); -#line 348 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _page_unref0 (page); -#line 4585 "book.c" - } - } - } -#line 566 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp475_ = writer; -#line 566 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - pdf_writer_write_string (_tmp475_, "\n"); -#line 567 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp476_ = writer; -#line 567 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp477_ = info_number; -#line 567 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - pdf_writer_start_object (_tmp476_, _tmp477_); -#line 568 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp478_ = writer; -#line 568 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp479_ = info_number; -#line 568 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp480_ = g_strdup_printf ("%u 0 obj\n", _tmp479_); -#line 568 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp481_ = _tmp480_; -#line 568 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - pdf_writer_write_string (_tmp478_, _tmp481_); -#line 568 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _g_free0 (_tmp481_); -#line 569 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp482_ = writer; -#line 569 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - pdf_writer_write_string (_tmp482_, "<<\n"); -#line 570 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp483_ = writer; -#line 570 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp484_ = g_strdup_printf ("/Creator (Simple Scan %s)\n", VERSION); -#line 570 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp485_ = _tmp484_; -#line 570 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - pdf_writer_write_string (_tmp483_, _tmp485_); -#line 570 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _g_free0 (_tmp485_); -#line 571 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp486_ = writer; -#line 571 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - pdf_writer_write_string (_tmp486_, ">>\n"); -#line 572 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp487_ = writer; -#line 572 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - pdf_writer_write_string (_tmp487_, "endobj\n"); -#line 575 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp488_ = writer; -#line 575 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - pdf_writer_write_string (_tmp488_, "\n"); -#line 576 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp489_ = writer; -#line 576 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp490_ = _tmp489_->offset; -#line 576 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - xref_offset = _tmp490_; -#line 577 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp491_ = writer; -#line 577 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - pdf_writer_write_string (_tmp491_, "xref\n"); -#line 578 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp492_ = writer; -#line 578 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp493_ = writer; -#line 578 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp494_ = _tmp493_->object_offsets; -#line 578 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp494__length1 = _tmp493_->object_offsets_length1; -#line 578 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp495_ = g_strdup_printf ("0 %zu\n", (gsize) (_tmp494__length1 + 1)); -#line 578 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp496_ = _tmp495_; -#line 578 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - pdf_writer_write_string (_tmp492_, _tmp496_); -#line 578 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _g_free0 (_tmp496_); -#line 579 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp497_ = writer; -#line 579 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp498_ = writer; -#line 579 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp499_ = book_next_empty_object (_tmp498_, 0); -#line 579 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp500_ = g_strdup_printf ("%010zu 65535 f \n", (gsize) _tmp499_); -#line 579 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp501_ = _tmp500_; -#line 579 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - pdf_writer_write_string (_tmp497_, _tmp501_); -#line 579 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _g_free0 (_tmp501_); -#line 4677 "book.c" - { - gint i = 0; -#line 580 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - i = 0; -#line 4682 "book.c" - { - gboolean _tmp502_ = FALSE; -#line 580 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp502_ = TRUE; -#line 580 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - while (TRUE) { -#line 4689 "book.c" - gint _tmp504_ = 0; - PDFWriter* _tmp505_ = NULL; - guint* _tmp506_ = NULL; - gint _tmp506__length1 = 0; - PDFWriter* _tmp507_ = NULL; - guint* _tmp508_ = NULL; - gint _tmp508__length1 = 0; - gint _tmp509_ = 0; - guint _tmp510_ = 0U; -#line 580 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - if (!_tmp502_) { -#line 4701 "book.c" - gint _tmp503_ = 0; -#line 580 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp503_ = i; -#line 580 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - i = _tmp503_ + 1; -#line 4707 "book.c" - } -#line 580 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp502_ = FALSE; -#line 580 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp504_ = i; -#line 580 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp505_ = writer; -#line 580 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp506_ = _tmp505_->object_offsets; -#line 580 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp506__length1 = _tmp505_->object_offsets_length1; -#line 580 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - if (!(_tmp504_ < _tmp506__length1)) { -#line 580 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - break; -#line 4723 "book.c" - } -#line 581 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp507_ = writer; -#line 581 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp508_ = _tmp507_->object_offsets; -#line 581 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp508__length1 = _tmp507_->object_offsets_length1; -#line 581 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp509_ = i; -#line 581 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp510_ = _tmp508_[_tmp509_]; -#line 581 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - if (_tmp510_ == ((guint) 0)) { -#line 4737 "book.c" - PDFWriter* _tmp511_ = NULL; - PDFWriter* _tmp512_ = NULL; - gint _tmp513_ = 0; - gint _tmp514_ = 0; - gchar* _tmp515_ = NULL; - gchar* _tmp516_ = NULL; -#line 582 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp511_ = writer; -#line 582 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp512_ = writer; -#line 582 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp513_ = i; -#line 582 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp514_ = book_next_empty_object (_tmp512_, _tmp513_ + 1); -#line 582 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp515_ = g_strdup_printf ("%010zu 65535 f \n", (gsize) _tmp514_); -#line 582 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp516_ = _tmp515_; -#line 582 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - pdf_writer_write_string (_tmp511_, _tmp516_); -#line 582 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _g_free0 (_tmp516_); -#line 4760 "book.c" - } else { - PDFWriter* _tmp517_ = NULL; - PDFWriter* _tmp518_ = NULL; - guint* _tmp519_ = NULL; - gint _tmp519__length1 = 0; - gint _tmp520_ = 0; - guint _tmp521_ = 0U; - gchar* _tmp522_ = NULL; - gchar* _tmp523_ = NULL; -#line 584 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp517_ = writer; -#line 584 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp518_ = writer; -#line 584 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp519_ = _tmp518_->object_offsets; -#line 584 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp519__length1 = _tmp518_->object_offsets_length1; -#line 584 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp520_ = i; -#line 584 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp521_ = _tmp519_[_tmp520_]; -#line 584 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp522_ = g_strdup_printf ("%010zu 00000 n \n", (gsize) _tmp521_); -#line 584 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp523_ = _tmp522_; -#line 584 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - pdf_writer_write_string (_tmp517_, _tmp523_); -#line 584 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _g_free0 (_tmp523_); -#line 4790 "book.c" - } - } - } - } -#line 587 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp524_ = writer; -#line 587 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - pdf_writer_write_string (_tmp524_, "\n"); -#line 588 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp525_ = writer; -#line 588 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - pdf_writer_write_string (_tmp525_, "trailer\n"); -#line 589 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp526_ = writer; -#line 589 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - pdf_writer_write_string (_tmp526_, "<<\n"); -#line 590 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp527_ = writer; -#line 590 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp528_ = writer; -#line 590 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp529_ = _tmp528_->object_offsets; -#line 590 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp529__length1 = _tmp528_->object_offsets_length1; -#line 590 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp530_ = g_strdup_printf ("/Size %zu\n", (gsize) (_tmp529__length1 + 1)); -#line 590 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp531_ = _tmp530_; -#line 590 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - pdf_writer_write_string (_tmp527_, _tmp531_); -#line 590 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _g_free0 (_tmp531_); -#line 591 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp532_ = writer; -#line 591 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp533_ = info_number; -#line 591 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp534_ = g_strdup_printf ("/Info %u 0 R\n", _tmp533_); -#line 591 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp535_ = _tmp534_; -#line 591 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - pdf_writer_write_string (_tmp532_, _tmp535_); -#line 591 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _g_free0 (_tmp535_); -#line 592 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp536_ = writer; -#line 592 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp537_ = catalog_number; -#line 592 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp538_ = g_strdup_printf ("/Root %u 0 R\n", _tmp537_); -#line 592 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp539_ = _tmp538_; -#line 592 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - pdf_writer_write_string (_tmp536_, _tmp539_); -#line 592 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _g_free0 (_tmp539_); -#line 593 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp540_ = writer; -#line 593 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp541_ = id; -#line 593 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp542_ = id; -#line 593 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp543_ = g_strdup_printf ("/ID [<%s> <%s>]\n", _tmp541_, _tmp542_); -#line 593 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp544_ = _tmp543_; -#line 593 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - pdf_writer_write_string (_tmp540_, _tmp544_); -#line 593 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _g_free0 (_tmp544_); -#line 594 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp545_ = writer; -#line 594 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - pdf_writer_write_string (_tmp545_, ">>\n"); -#line 595 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp546_ = writer; -#line 595 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - pdf_writer_write_string (_tmp546_, "startxref\n"); -#line 596 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp547_ = writer; -#line 596 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp548_ = xref_offset; -#line 596 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp549_ = g_strdup_printf ("%zu\n", _tmp548_); -#line 596 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp550_ = _tmp549_; -#line 596 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - pdf_writer_write_string (_tmp547_, _tmp550_); -#line 596 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _g_free0 (_tmp550_); -#line 597 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp551_ = writer; -#line 597 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - pdf_writer_write_string (_tmp551_, "%%EOF\n"); -#line 257 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _g_free0 (metadata); -#line 257 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _g_free0 (date_string); -#line 257 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _g_date_time_unref0 (now); -#line 257 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - page_content_numbers = (g_free (page_content_numbers), NULL); -#line 257 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - page_image_numbers = (g_free (page_image_numbers), NULL); -#line 257 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - page_numbers = (g_free (page_numbers), NULL); -#line 257 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _pdf_writer_unref0 (writer); -#line 257 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _g_object_unref0 (stream); -#line 257 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _g_free0 (id); -#line 4903 "book.c" -} - - -static gint book_next_empty_object (PDFWriter* writer, gint start) { - gint result = 0; -#line 600 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - g_return_val_if_fail (writer != NULL, 0); -#line 4911 "book.c" - { - gint i = 0; - gint _tmp0_ = 0; -#line 602 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp0_ = start; -#line 602 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - i = _tmp0_; -#line 4919 "book.c" - { - gboolean _tmp1_ = FALSE; -#line 602 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp1_ = TRUE; -#line 602 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - while (TRUE) { -#line 4926 "book.c" - gint _tmp3_ = 0; - PDFWriter* _tmp4_ = NULL; - guint* _tmp5_ = NULL; - gint _tmp5__length1 = 0; - PDFWriter* _tmp6_ = NULL; - guint* _tmp7_ = NULL; - gint _tmp7__length1 = 0; - gint _tmp8_ = 0; - guint _tmp9_ = 0U; -#line 602 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - if (!_tmp1_) { -#line 4938 "book.c" - gint _tmp2_ = 0; -#line 602 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp2_ = i; -#line 602 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - i = _tmp2_ + 1; -#line 4944 "book.c" - } -#line 602 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp1_ = FALSE; -#line 602 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp3_ = i; -#line 602 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp4_ = writer; -#line 602 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp5_ = _tmp4_->object_offsets; -#line 602 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp5__length1 = _tmp4_->object_offsets_length1; -#line 602 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - if (!(_tmp3_ < _tmp5__length1)) { -#line 602 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - break; -#line 4960 "book.c" - } -#line 603 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp6_ = writer; -#line 603 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp7_ = _tmp6_->object_offsets; -#line 603 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp7__length1 = _tmp6_->object_offsets_length1; -#line 603 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp8_ = i; -#line 603 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp9_ = _tmp7_[_tmp8_]; -#line 603 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - if (_tmp9_ == ((guint) 0)) { -#line 4974 "book.c" - gint _tmp10_ = 0; -#line 604 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp10_ = i; -#line 604 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - result = _tmp10_ + 1; -#line 604 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - return result; -#line 4982 "book.c" - } - } - } - } -#line 605 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - result = 0; -#line 605 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - return result; -#line 4991 "book.c" -} - - -void book_save (Book* self, const gchar* type, gint quality, GFile* file, GError** error) { - const gchar* _tmp0_ = NULL; - const gchar* _tmp1_ = NULL; - GQuark _tmp3_ = 0U; -#line 610 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - static GQuark _tmp2_label0 = 0; -#line 610 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - static GQuark _tmp2_label1 = 0; -#line 610 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - static GQuark _tmp2_label2 = 0; -#line 610 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - static GQuark _tmp2_label3 = 0; -#line 610 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - static GQuark _tmp2_label4 = 0; -#line 5009 "book.c" - GError * _inner_error_ = NULL; -#line 608 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - g_return_if_fail (self != NULL); -#line 608 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - g_return_if_fail (type != NULL); -#line 608 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - g_return_if_fail (file != NULL); -#line 610 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp0_ = type; -#line 610 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp1_ = _tmp0_; -#line 610 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp3_ = (NULL == _tmp1_) ? 0 : g_quark_from_string (_tmp1_); -#line 610 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - if (((_tmp3_ == ((0 != _tmp2_label0) ? _tmp2_label0 : (_tmp2_label0 = g_quark_from_static_string ("jpeg")))) || (_tmp3_ == ((0 != _tmp2_label1) ? _tmp2_label1 : (_tmp2_label1 = g_quark_from_static_string ("png"))))) || (_tmp3_ == ((0 != _tmp2_label2) ? _tmp2_label2 : (_tmp2_label2 = g_quark_from_static_string ("tiff"))))) { -#line 610 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - switch (0) { -#line 5027 "book.c" - default: - { - const gchar* _tmp4_ = NULL; - gint _tmp5_ = 0; - GFile* _tmp6_ = NULL; -#line 615 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp4_ = type; -#line 615 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp5_ = quality; -#line 615 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp6_ = file; -#line 615 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - book_save_multi_file (self, _tmp4_, _tmp5_, _tmp6_, &_inner_error_); -#line 615 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - if (G_UNLIKELY (_inner_error_ != NULL)) { -#line 615 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - g_propagate_error (error, _inner_error_); -#line 615 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - return; -#line 5047 "book.c" - } -#line 616 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - break; -#line 5051 "book.c" - } - } - } else if (_tmp3_ == ((0 != _tmp2_label3) ? _tmp2_label3 : (_tmp2_label3 = g_quark_from_static_string ("ps")))) { -#line 610 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - switch (0) { -#line 5057 "book.c" - default: - { - GFile* _tmp7_ = NULL; -#line 618 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp7_ = file; -#line 618 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - book_save_ps (self, _tmp7_, &_inner_error_); -#line 618 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - if (G_UNLIKELY (_inner_error_ != NULL)) { -#line 618 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - g_propagate_error (error, _inner_error_); -#line 618 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - return; -#line 5071 "book.c" - } -#line 619 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - break; -#line 5075 "book.c" - } - } - } else if (_tmp3_ == ((0 != _tmp2_label4) ? _tmp2_label4 : (_tmp2_label4 = g_quark_from_static_string ("pdf")))) { -#line 610 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - switch (0) { -#line 5081 "book.c" - default: - { - GFile* _tmp8_ = NULL; - gint _tmp9_ = 0; -#line 621 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp8_ = file; -#line 621 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp9_ = quality; -#line 621 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - book_save_pdf (self, _tmp8_, _tmp9_, &_inner_error_); -#line 621 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - if (G_UNLIKELY (_inner_error_ != NULL)) { -#line 621 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - g_propagate_error (error, _inner_error_); -#line 621 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - return; -#line 5098 "book.c" - } -#line 622 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - break; -#line 5102 "book.c" - } - } - } -} - - -guint book_get_n_pages (Book* self) { - guint result; - GList* _tmp0_ = NULL; - guint _tmp1_ = 0U; -#line 16 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - g_return_val_if_fail (self != NULL, 0U); -#line 16 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp0_ = self->priv->pages; -#line 16 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp1_ = g_list_length (_tmp0_); -#line 16 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - result = _tmp1_; -#line 16 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - return result; -#line 5123 "book.c" -} - - -gboolean book_get_needs_saving (Book* self) { - gboolean result; - gboolean _tmp0_ = FALSE; -#line 21 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - g_return_val_if_fail (self != NULL, FALSE); -#line 21 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp0_ = self->priv->needs_saving_; -#line 21 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - result = _tmp0_; -#line 21 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - return result; -#line 5138 "book.c" -} - - -void book_set_needs_saving (Book* self, gboolean value) { - gboolean _tmp0_ = FALSE; - gboolean _tmp1_ = FALSE; - gboolean _tmp2_ = FALSE; -#line 22 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - g_return_if_fail (self != NULL); -#line 24 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp0_ = self->priv->needs_saving_; -#line 24 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp1_ = value; -#line 24 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - if (_tmp0_ == _tmp1_) { -#line 25 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - return; -#line 5156 "book.c" - } -#line 26 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp2_ = value; -#line 26 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - self->priv->needs_saving_ = _tmp2_; -#line 27 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - g_signal_emit_by_name (self, "needs-saving-changed"); -#line 5164 "book.c" -} - - -static void g_cclosure_user_marshal_VOID__PAGE (GClosure * closure, GValue * return_value, guint n_param_values, const GValue * param_values, gpointer invocation_hint, gpointer marshal_data) { - typedef void (*GMarshalFunc_VOID__PAGE) (gpointer data1, gpointer arg_1, gpointer data2); - register GMarshalFunc_VOID__PAGE callback; - register GCClosure * cc; - register gpointer data1; - register gpointer data2; - cc = (GCClosure *) closure; -#line 12 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - g_return_if_fail (n_param_values == 2); -#line 12 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - if (G_CCLOSURE_SWAP_DATA (closure)) { -#line 12 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - data1 = closure->data; -#line 12 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - data2 = param_values->data[0].v_pointer; -#line 5183 "book.c" - } else { -#line 12 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - data1 = param_values->data[0].v_pointer; -#line 12 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - data2 = closure->data; -#line 5189 "book.c" - } -#line 12 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - callback = (GMarshalFunc_VOID__PAGE) (marshal_data ? marshal_data : cc->callback); -#line 12 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - callback (data1, value_get_page (param_values + 1), data2); -#line 5195 "book.c" -} - - -static void value_book_init (GValue* value) { -#line 12 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - value->data[0].v_pointer = NULL; -#line 5202 "book.c" -} - - -static void value_book_free_value (GValue* value) { -#line 12 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - if (value->data[0].v_pointer) { -#line 12 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - book_unref (value->data[0].v_pointer); -#line 5211 "book.c" - } -} - - -static void value_book_copy_value (const GValue* src_value, GValue* dest_value) { -#line 12 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - if (src_value->data[0].v_pointer) { -#line 12 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - dest_value->data[0].v_pointer = book_ref (src_value->data[0].v_pointer); -#line 5221 "book.c" - } else { -#line 12 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - dest_value->data[0].v_pointer = NULL; -#line 5225 "book.c" - } -} - - -static gpointer value_book_peek_pointer (const GValue* value) { -#line 12 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - return value->data[0].v_pointer; -#line 5233 "book.c" -} - - -static gchar* value_book_collect_value (GValue* value, guint n_collect_values, GTypeCValue* collect_values, guint collect_flags) { -#line 12 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - if (collect_values[0].v_pointer) { -#line 5240 "book.c" - Book* object; - object = collect_values[0].v_pointer; -#line 12 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - if (object->parent_instance.g_class == NULL) { -#line 12 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - return g_strconcat ("invalid unclassed object pointer for value type `", G_VALUE_TYPE_NAME (value), "'", NULL); -#line 5247 "book.c" - } else if (!g_value_type_compatible (G_TYPE_FROM_INSTANCE (object), G_VALUE_TYPE (value))) { -#line 12 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - return g_strconcat ("invalid object type `", g_type_name (G_TYPE_FROM_INSTANCE (object)), "' for value type `", G_VALUE_TYPE_NAME (value), "'", NULL); -#line 5251 "book.c" - } -#line 12 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - value->data[0].v_pointer = book_ref (object); -#line 5255 "book.c" - } else { -#line 12 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - value->data[0].v_pointer = NULL; -#line 5259 "book.c" - } -#line 12 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - return NULL; -#line 5263 "book.c" -} - - -static gchar* value_book_lcopy_value (const GValue* value, guint n_collect_values, GTypeCValue* collect_values, guint collect_flags) { - Book** object_p; - object_p = collect_values[0].v_pointer; -#line 12 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - if (!object_p) { -#line 12 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - return g_strdup_printf ("value location for `%s' passed as NULL", G_VALUE_TYPE_NAME (value)); -#line 5274 "book.c" - } -#line 12 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - if (!value->data[0].v_pointer) { -#line 12 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - *object_p = NULL; -#line 5280 "book.c" - } else if (collect_flags & G_VALUE_NOCOPY_CONTENTS) { -#line 12 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - *object_p = value->data[0].v_pointer; -#line 5284 "book.c" - } else { -#line 12 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - *object_p = book_ref (value->data[0].v_pointer); -#line 5288 "book.c" - } -#line 12 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - return NULL; -#line 5292 "book.c" -} - - -GParamSpec* param_spec_book (const gchar* name, const gchar* nick, const gchar* blurb, GType object_type, GParamFlags flags) { - ParamSpecBook* spec; -#line 12 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - g_return_val_if_fail (g_type_is_a (object_type, TYPE_BOOK), NULL); -#line 12 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - spec = g_param_spec_internal (G_TYPE_PARAM_OBJECT, name, nick, blurb, flags); -#line 12 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - G_PARAM_SPEC (spec)->value_type = object_type; -#line 12 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - return G_PARAM_SPEC (spec); -#line 5306 "book.c" -} - - -gpointer value_get_book (const GValue* value) { -#line 12 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - g_return_val_if_fail (G_TYPE_CHECK_VALUE_TYPE (value, TYPE_BOOK), NULL); -#line 12 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - return value->data[0].v_pointer; -#line 5315 "book.c" -} - - -void value_set_book (GValue* value, gpointer v_object) { - Book* old; -#line 12 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - g_return_if_fail (G_TYPE_CHECK_VALUE_TYPE (value, TYPE_BOOK)); -#line 12 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - old = value->data[0].v_pointer; -#line 12 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - if (v_object) { -#line 12 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - g_return_if_fail (G_TYPE_CHECK_INSTANCE_TYPE (v_object, TYPE_BOOK)); -#line 12 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - g_return_if_fail (g_value_type_compatible (G_TYPE_FROM_INSTANCE (v_object), G_VALUE_TYPE (value))); -#line 12 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - value->data[0].v_pointer = v_object; -#line 12 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - book_ref (value->data[0].v_pointer); -#line 5335 "book.c" - } else { -#line 12 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - value->data[0].v_pointer = NULL; -#line 5339 "book.c" - } -#line 12 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - if (old) { -#line 12 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - book_unref (old); -#line 5345 "book.c" - } -} - - -void value_take_book (GValue* value, gpointer v_object) { - Book* old; -#line 12 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - g_return_if_fail (G_TYPE_CHECK_VALUE_TYPE (value, TYPE_BOOK)); -#line 12 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - old = value->data[0].v_pointer; -#line 12 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - if (v_object) { -#line 12 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - g_return_if_fail (G_TYPE_CHECK_INSTANCE_TYPE (v_object, TYPE_BOOK)); -#line 12 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - g_return_if_fail (g_value_type_compatible (G_TYPE_FROM_INSTANCE (v_object), G_VALUE_TYPE (value))); -#line 12 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - value->data[0].v_pointer = v_object; -#line 5364 "book.c" - } else { -#line 12 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - value->data[0].v_pointer = NULL; -#line 5368 "book.c" - } -#line 12 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - if (old) { -#line 12 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - book_unref (old); -#line 5374 "book.c" - } -} - - -static void book_class_init (BookClass * klass) { -#line 12 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - book_parent_class = g_type_class_peek_parent (klass); -#line 12 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - ((BookClass *) klass)->finalize = book_finalize; -#line 12 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - g_type_class_add_private (klass, sizeof (BookPrivate)); -#line 12 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - g_signal_new ("page_added", TYPE_BOOK, G_SIGNAL_RUN_LAST, 0, NULL, NULL, g_cclosure_user_marshal_VOID__PAGE, G_TYPE_NONE, 1, TYPE_PAGE); -#line 12 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - g_signal_new ("page_removed", TYPE_BOOK, G_SIGNAL_RUN_LAST, 0, NULL, NULL, g_cclosure_user_marshal_VOID__PAGE, G_TYPE_NONE, 1, TYPE_PAGE); -#line 12 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - g_signal_new ("reordered", TYPE_BOOK, G_SIGNAL_RUN_LAST, 0, NULL, NULL, g_cclosure_marshal_VOID__VOID, G_TYPE_NONE, 0); -#line 12 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - g_signal_new ("cleared", TYPE_BOOK, G_SIGNAL_RUN_LAST, 0, NULL, NULL, g_cclosure_marshal_VOID__VOID, G_TYPE_NONE, 0); -#line 12 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - g_signal_new ("needs_saving_changed", TYPE_BOOK, G_SIGNAL_RUN_LAST, 0, NULL, NULL, g_cclosure_marshal_VOID__VOID, G_TYPE_NONE, 0); -#line 12 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - g_signal_new ("saving", TYPE_BOOK, G_SIGNAL_RUN_LAST, 0, NULL, NULL, g_cclosure_marshal_VOID__INT, G_TYPE_NONE, 1, G_TYPE_INT); -#line 5398 "book.c" -} - - -static void book_instance_init (Book * self) { -#line 12 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - self->priv = BOOK_GET_PRIVATE (self); -#line 12 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - self->ref_count = 1; -#line 5407 "book.c" -} - - -static void book_finalize (Book* obj) { - Book * self; - GList* _tmp0_ = NULL; -#line 12 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - self = G_TYPE_CHECK_INSTANCE_CAST (obj, TYPE_BOOK, Book); -#line 12 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - g_signal_handlers_destroy (self); -#line 45 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp0_ = self->priv->pages; -#line 5420 "book.c" - { - GList* page_collection = NULL; - GList* page_it = NULL; -#line 45 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - page_collection = _tmp0_; -#line 45 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - for (page_it = page_collection; page_it != NULL; page_it = page_it->next) { -#line 5428 "book.c" - Page* _tmp1_ = NULL; - Page* page = NULL; -#line 45 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp1_ = _page_ref0 ((Page*) page_it->data); -#line 45 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - page = _tmp1_; -#line 5435 "book.c" - { - Page* _tmp2_ = NULL; - guint _tmp3_ = 0U; - Page* _tmp4_ = NULL; - guint _tmp5_ = 0U; -#line 47 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp2_ = page; -#line 47 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - g_signal_parse_name ("pixels-changed", TYPE_PAGE, &_tmp3_, NULL, FALSE); -#line 47 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - g_signal_handlers_disconnect_matched (_tmp2_, G_SIGNAL_MATCH_ID | G_SIGNAL_MATCH_FUNC | G_SIGNAL_MATCH_DATA, _tmp3_, 0, NULL, (GCallback) _book_page_changed_cb_page_pixels_changed, self); -#line 48 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp4_ = page; -#line 48 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - g_signal_parse_name ("crop-changed", TYPE_PAGE, &_tmp5_, NULL, FALSE); -#line 48 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - g_signal_handlers_disconnect_matched (_tmp4_, G_SIGNAL_MATCH_ID | G_SIGNAL_MATCH_FUNC | G_SIGNAL_MATCH_DATA, _tmp5_, 0, NULL, (GCallback) _book_page_changed_cb_page_crop_changed, self); -#line 45 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _page_unref0 (page); -#line 5455 "book.c" - } - } - } -#line 14 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - __g_list_free__page_unref0_0 (self->priv->pages); -#line 231 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _g_byte_array_unref0 (self->priv->jpeg_data); -#line 5463 "book.c" -} - - -GType book_get_type (void) { - static volatile gsize book_type_id__volatile = 0; - if (g_once_init_enter (&book_type_id__volatile)) { - static const GTypeValueTable g_define_type_value_table = { value_book_init, value_book_free_value, value_book_copy_value, value_book_peek_pointer, "p", value_book_collect_value, "p", value_book_lcopy_value }; - static const GTypeInfo g_define_type_info = { sizeof (BookClass), (GBaseInitFunc) NULL, (GBaseFinalizeFunc) NULL, (GClassInitFunc) book_class_init, (GClassFinalizeFunc) NULL, NULL, sizeof (Book), 0, (GInstanceInitFunc) book_instance_init, &g_define_type_value_table }; - static const GTypeFundamentalInfo g_define_type_fundamental_info = { (G_TYPE_FLAG_CLASSED | G_TYPE_FLAG_INSTANTIATABLE | G_TYPE_FLAG_DERIVABLE | G_TYPE_FLAG_DEEP_DERIVABLE) }; - GType book_type_id; - book_type_id = g_type_register_fundamental (g_type_fundamental_next (), "Book", &g_define_type_info, &g_define_type_fundamental_info, 0); - g_once_init_leave (&book_type_id__volatile, book_type_id); - } - return book_type_id__volatile; -} - - -gpointer book_ref (gpointer instance) { - Book* self; - self = instance; -#line 12 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - g_atomic_int_inc (&self->ref_count); -#line 12 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - return instance; -#line 5488 "book.c" -} - - -void book_unref (gpointer instance) { - Book* self; - self = instance; -#line 12 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - if (g_atomic_int_dec_and_test (&self->ref_count)) { -#line 12 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - BOOK_GET_CLASS (self)->finalize (self); -#line 12 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - g_type_free_instance ((GTypeInstance *) self); -#line 5501 "book.c" - } -} - - -static gpointer _g_object_ref0 (gpointer self) { -#line 635 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - return self ? g_object_ref (self) : NULL; -#line 5509 "book.c" -} - - -PDFWriter* pdf_writer_construct (GType object_type, GFileOutputStream* stream) { - PDFWriter* self = NULL; - GFileOutputStream* _tmp0_ = NULL; - GFileOutputStream* _tmp1_ = NULL; - guint* _tmp2_ = NULL; -#line 633 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - g_return_val_if_fail (stream != NULL, NULL); -#line 633 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - self = (PDFWriter*) g_type_create_instance (object_type); -#line 635 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp0_ = stream; -#line 635 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp1_ = _g_object_ref0 (_tmp0_); -#line 635 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _g_object_unref0 (self->priv->stream); -#line 635 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - self->priv->stream = _tmp1_; -#line 636 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp2_ = g_new0 (guint, 0); -#line 636 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - self->object_offsets = (g_free (self->object_offsets), NULL); -#line 636 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - self->object_offsets = _tmp2_; -#line 636 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - self->object_offsets_length1 = 0; -#line 636 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - self->_object_offsets_size_ = self->object_offsets_length1; -#line 633 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - return self; -#line 5542 "book.c" -} - - -PDFWriter* pdf_writer_new (GFileOutputStream* stream) { -#line 633 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - return pdf_writer_construct (TYPE_PDF_WRITER, stream); -#line 5549 "book.c" -} - - -void pdf_writer_write (PDFWriter* self, guint8* data, int data_length1) { - gsize _tmp4_ = 0UL; - guint8* _tmp5_ = NULL; - gint _tmp5__length1 = 0; - GError * _inner_error_ = NULL; -#line 639 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - g_return_if_fail (self != NULL); -#line 5560 "book.c" - { - GFileOutputStream* _tmp0_ = NULL; - guint8* _tmp1_ = NULL; - gint _tmp1__length1 = 0; -#line 643 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp0_ = self->priv->stream; -#line 643 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp1_ = data; -#line 643 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp1__length1 = data_length1; -#line 643 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - g_output_stream_write_all ((GOutputStream*) _tmp0_, _tmp1_, (gsize) _tmp1__length1, NULL, NULL, &_inner_error_); -#line 643 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - if (G_UNLIKELY (_inner_error_ != NULL)) { -#line 5575 "book.c" - goto __catch1_g_error; - } - } - goto __finally1; - __catch1_g_error: - { - GError* e = NULL; - GError* _tmp2_ = NULL; - const gchar* _tmp3_ = NULL; -#line 641 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - e = _inner_error_; -#line 641 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _inner_error_ = NULL; -#line 647 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp2_ = e; -#line 647 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp3_ = _tmp2_->message; -#line 647 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - g_warning ("book.vala:647: Error writing PDF: %s", _tmp3_); -#line 641 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _g_error_free0 (e); -#line 5597 "book.c" - } - __finally1: -#line 641 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - if (G_UNLIKELY (_inner_error_ != NULL)) { -#line 641 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - g_critical ("file %s: line %d: uncaught error: %s (%s, %d)", __FILE__, __LINE__, _inner_error_->message, g_quark_to_string (_inner_error_->domain), _inner_error_->code); -#line 641 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - g_clear_error (&_inner_error_); -#line 641 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - return; -#line 5608 "book.c" - } -#line 649 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp4_ = self->offset; -#line 649 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp5_ = data; -#line 649 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp5__length1 = data_length1; -#line 649 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - self->offset = _tmp4_ + _tmp5__length1; -#line 5618 "book.c" -} - - -static gchar* string_to_utf8 (const gchar* self, int* result_length1) { - gchar* result = NULL; - gchar* _result_ = NULL; - gint _tmp0_ = 0; - gint _tmp1_ = 0; - gchar* _tmp2_ = NULL; - gint _result__length1 = 0; - gint __result__size_ = 0; - gint _tmp3_ = 0; - gchar* _tmp4_ = NULL; - gint _tmp4__length1 = 0; - gint _tmp5_ = 0; - gint _tmp6_ = 0; - gchar* _tmp7_ = NULL; - gint _tmp7__length1 = 0; -#line 1405 "/usr/share/vala-0.34/vapi/glib-2.0.vapi" - g_return_val_if_fail (self != NULL, NULL); -#line 1406 "/usr/share/vala-0.34/vapi/glib-2.0.vapi" - _tmp0_ = strlen (self); -#line 1406 "/usr/share/vala-0.34/vapi/glib-2.0.vapi" - _tmp1_ = _tmp0_; -#line 1406 "/usr/share/vala-0.34/vapi/glib-2.0.vapi" - _tmp2_ = g_new0 (gchar, _tmp1_ + 1); -#line 1406 "/usr/share/vala-0.34/vapi/glib-2.0.vapi" - _result_ = _tmp2_; -#line 1406 "/usr/share/vala-0.34/vapi/glib-2.0.vapi" - _result__length1 = _tmp1_ + 1; -#line 1406 "/usr/share/vala-0.34/vapi/glib-2.0.vapi" - __result__size_ = _result__length1; -#line 1407 "/usr/share/vala-0.34/vapi/glib-2.0.vapi" - _tmp3_ = _result__length1; -#line 1407 "/usr/share/vala-0.34/vapi/glib-2.0.vapi" - _result__length1 = _tmp3_ - 1; -#line 1408 "/usr/share/vala-0.34/vapi/glib-2.0.vapi" - _tmp4_ = _result_; -#line 1408 "/usr/share/vala-0.34/vapi/glib-2.0.vapi" - _tmp4__length1 = _result__length1; -#line 1408 "/usr/share/vala-0.34/vapi/glib-2.0.vapi" - _tmp5_ = strlen (self); -#line 1408 "/usr/share/vala-0.34/vapi/glib-2.0.vapi" - _tmp6_ = _tmp5_; -#line 1408 "/usr/share/vala-0.34/vapi/glib-2.0.vapi" - memcpy (_tmp4_, self, (gsize) _tmp6_); -#line 1409 "/usr/share/vala-0.34/vapi/glib-2.0.vapi" - _tmp7_ = _result_; -#line 1409 "/usr/share/vala-0.34/vapi/glib-2.0.vapi" - _tmp7__length1 = _result__length1; -#line 1409 "/usr/share/vala-0.34/vapi/glib-2.0.vapi" - if (result_length1) { -#line 1409 "/usr/share/vala-0.34/vapi/glib-2.0.vapi" - *result_length1 = _tmp7__length1; -#line 5673 "book.c" - } -#line 1409 "/usr/share/vala-0.34/vapi/glib-2.0.vapi" - result = _tmp7_; -#line 1409 "/usr/share/vala-0.34/vapi/glib-2.0.vapi" - return result; -#line 5679 "book.c" -} - - -void pdf_writer_write_string (PDFWriter* self, const gchar* text) { - const gchar* _tmp0_ = NULL; - gint _tmp1_ = 0; - gchar* _tmp2_ = NULL; - guint8* _tmp3_ = NULL; - gint _tmp3__length1 = 0; -#line 652 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - g_return_if_fail (self != NULL); -#line 652 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - g_return_if_fail (text != NULL); -#line 654 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp0_ = text; -#line 654 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp2_ = string_to_utf8 (_tmp0_, &_tmp1_); -#line 654 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp3_ = (guint8*) _tmp2_; -#line 654 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp3__length1 = (_tmp1_ * sizeof (gchar)) / sizeof (guint8); -#line 654 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - pdf_writer_write (self, _tmp3_, (_tmp1_ * sizeof (gchar)) / sizeof (guint8)); -#line 654 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp3_ = (g_free (_tmp3_), NULL); -#line 5705 "book.c" -} - - -guint pdf_writer_add_object (PDFWriter* self) { - guint result = 0U; - guint* _tmp0_ = NULL; - gint _tmp0__length1 = 0; - gint _tmp1_ = 0; - gint index = 0; - guint* _tmp2_ = NULL; - gint _tmp2__length1 = 0; - guint* _tmp3_ = NULL; - gint _tmp3__length1 = 0; - guint _tmp4_ = 0U; -#line 657 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - g_return_val_if_fail (self != NULL, 0U); -#line 659 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp0_ = self->object_offsets; -#line 659 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp0__length1 = self->object_offsets_length1; -#line 659 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp1_ = _tmp0__length1 + 1; -#line 659 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - self->object_offsets = g_renew (guint, self->object_offsets, _tmp0__length1 + 1); -#line 659 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - (_tmp1_ > self->object_offsets_length1) ? memset (self->object_offsets + self->object_offsets_length1, 0, sizeof (guint) * (_tmp1_ - self->object_offsets_length1)) : NULL; -#line 659 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - self->object_offsets_length1 = _tmp1_; -#line 659 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - self->_object_offsets_size_ = _tmp1_; -#line 660 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp2_ = self->object_offsets; -#line 660 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp2__length1 = self->object_offsets_length1; -#line 660 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - index = _tmp2__length1 - 1; -#line 661 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp3_ = self->object_offsets; -#line 661 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp3__length1 = self->object_offsets_length1; -#line 661 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp3_[index] = (guint) 0; -#line 661 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp4_ = _tmp3_[index]; -#line 662 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - result = (guint) (index + 1); -#line 662 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - return result; -#line 5754 "book.c" -} - - -void pdf_writer_start_object (PDFWriter* self, guint index) { - guint* _tmp0_ = NULL; - gint _tmp0__length1 = 0; - guint _tmp1_ = 0U; - gsize _tmp2_ = 0UL; - guint _tmp3_ = 0U; -#line 665 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - g_return_if_fail (self != NULL); -#line 667 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp0_ = self->object_offsets; -#line 667 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp0__length1 = self->object_offsets_length1; -#line 667 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp1_ = index; -#line 667 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp2_ = self->offset; -#line 667 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp0_[_tmp1_ - 1] = (guint) _tmp2_; -#line 667 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp3_ = _tmp0_[_tmp1_ - 1]; -#line 5778 "book.c" -} - - -static void value_pdf_writer_init (GValue* value) { -#line 627 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - value->data[0].v_pointer = NULL; -#line 5785 "book.c" -} - - -static void value_pdf_writer_free_value (GValue* value) { -#line 627 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - if (value->data[0].v_pointer) { -#line 627 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - pdf_writer_unref (value->data[0].v_pointer); -#line 5794 "book.c" - } -} - - -static void value_pdf_writer_copy_value (const GValue* src_value, GValue* dest_value) { -#line 627 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - if (src_value->data[0].v_pointer) { -#line 627 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - dest_value->data[0].v_pointer = pdf_writer_ref (src_value->data[0].v_pointer); -#line 5804 "book.c" - } else { -#line 627 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - dest_value->data[0].v_pointer = NULL; -#line 5808 "book.c" - } -} - - -static gpointer value_pdf_writer_peek_pointer (const GValue* value) { -#line 627 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - return value->data[0].v_pointer; -#line 5816 "book.c" -} - - -static gchar* value_pdf_writer_collect_value (GValue* value, guint n_collect_values, GTypeCValue* collect_values, guint collect_flags) { -#line 627 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - if (collect_values[0].v_pointer) { -#line 5823 "book.c" - PDFWriter* object; - object = collect_values[0].v_pointer; -#line 627 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - if (object->parent_instance.g_class == NULL) { -#line 627 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - return g_strconcat ("invalid unclassed object pointer for value type `", G_VALUE_TYPE_NAME (value), "'", NULL); -#line 5830 "book.c" - } else if (!g_value_type_compatible (G_TYPE_FROM_INSTANCE (object), G_VALUE_TYPE (value))) { -#line 627 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - return g_strconcat ("invalid object type `", g_type_name (G_TYPE_FROM_INSTANCE (object)), "' for value type `", G_VALUE_TYPE_NAME (value), "'", NULL); -#line 5834 "book.c" - } -#line 627 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - value->data[0].v_pointer = pdf_writer_ref (object); -#line 5838 "book.c" - } else { -#line 627 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - value->data[0].v_pointer = NULL; -#line 5842 "book.c" - } -#line 627 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - return NULL; -#line 5846 "book.c" -} - - -static gchar* value_pdf_writer_lcopy_value (const GValue* value, guint n_collect_values, GTypeCValue* collect_values, guint collect_flags) { - PDFWriter** object_p; - object_p = collect_values[0].v_pointer; -#line 627 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - if (!object_p) { -#line 627 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - return g_strdup_printf ("value location for `%s' passed as NULL", G_VALUE_TYPE_NAME (value)); -#line 5857 "book.c" - } -#line 627 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - if (!value->data[0].v_pointer) { -#line 627 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - *object_p = NULL; -#line 5863 "book.c" - } else if (collect_flags & G_VALUE_NOCOPY_CONTENTS) { -#line 627 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - *object_p = value->data[0].v_pointer; -#line 5867 "book.c" - } else { -#line 627 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - *object_p = pdf_writer_ref (value->data[0].v_pointer); -#line 5871 "book.c" - } -#line 627 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - return NULL; -#line 5875 "book.c" -} - - -GParamSpec* param_spec_pdf_writer (const gchar* name, const gchar* nick, const gchar* blurb, GType object_type, GParamFlags flags) { - ParamSpecPDFWriter* spec; -#line 627 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - g_return_val_if_fail (g_type_is_a (object_type, TYPE_PDF_WRITER), NULL); -#line 627 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - spec = g_param_spec_internal (G_TYPE_PARAM_OBJECT, name, nick, blurb, flags); -#line 627 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - G_PARAM_SPEC (spec)->value_type = object_type; -#line 627 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - return G_PARAM_SPEC (spec); -#line 5889 "book.c" -} - - -gpointer value_get_pdf_writer (const GValue* value) { -#line 627 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - g_return_val_if_fail (G_TYPE_CHECK_VALUE_TYPE (value, TYPE_PDF_WRITER), NULL); -#line 627 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - return value->data[0].v_pointer; -#line 5898 "book.c" -} - - -void value_set_pdf_writer (GValue* value, gpointer v_object) { - PDFWriter* old; -#line 627 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - g_return_if_fail (G_TYPE_CHECK_VALUE_TYPE (value, TYPE_PDF_WRITER)); -#line 627 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - old = value->data[0].v_pointer; -#line 627 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - if (v_object) { -#line 627 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - g_return_if_fail (G_TYPE_CHECK_INSTANCE_TYPE (v_object, TYPE_PDF_WRITER)); -#line 627 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - g_return_if_fail (g_value_type_compatible (G_TYPE_FROM_INSTANCE (v_object), G_VALUE_TYPE (value))); -#line 627 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - value->data[0].v_pointer = v_object; -#line 627 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - pdf_writer_ref (value->data[0].v_pointer); -#line 5918 "book.c" - } else { -#line 627 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - value->data[0].v_pointer = NULL; -#line 5922 "book.c" - } -#line 627 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - if (old) { -#line 627 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - pdf_writer_unref (old); -#line 5928 "book.c" - } -} - - -void value_take_pdf_writer (GValue* value, gpointer v_object) { - PDFWriter* old; -#line 627 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - g_return_if_fail (G_TYPE_CHECK_VALUE_TYPE (value, TYPE_PDF_WRITER)); -#line 627 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - old = value->data[0].v_pointer; -#line 627 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - if (v_object) { -#line 627 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - g_return_if_fail (G_TYPE_CHECK_INSTANCE_TYPE (v_object, TYPE_PDF_WRITER)); -#line 627 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - g_return_if_fail (g_value_type_compatible (G_TYPE_FROM_INSTANCE (v_object), G_VALUE_TYPE (value))); -#line 627 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - value->data[0].v_pointer = v_object; -#line 5947 "book.c" - } else { -#line 627 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - value->data[0].v_pointer = NULL; -#line 5951 "book.c" - } -#line 627 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - if (old) { -#line 627 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - pdf_writer_unref (old); -#line 5957 "book.c" - } -} - - -static void pdf_writer_class_init (PDFWriterClass * klass) { -#line 627 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - pdf_writer_parent_class = g_type_class_peek_parent (klass); -#line 627 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - ((PDFWriterClass *) klass)->finalize = pdf_writer_finalize; -#line 627 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - g_type_class_add_private (klass, sizeof (PDFWriterPrivate)); -#line 5969 "book.c" -} - - -static void pdf_writer_instance_init (PDFWriter * self) { -#line 627 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - self->priv = PDF_WRITER_GET_PRIVATE (self); -#line 629 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - self->offset = (gsize) 0; -#line 627 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - self->ref_count = 1; -#line 5980 "book.c" -} - - -static void pdf_writer_finalize (PDFWriter* obj) { - PDFWriter * self; -#line 627 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - self = G_TYPE_CHECK_INSTANCE_CAST (obj, TYPE_PDF_WRITER, PDFWriter); -#line 627 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - g_signal_handlers_destroy (self); -#line 630 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - self->object_offsets = (g_free (self->object_offsets), NULL); -#line 631 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _g_object_unref0 (self->priv->stream); -#line 5994 "book.c" -} - - -GType pdf_writer_get_type (void) { - static volatile gsize pdf_writer_type_id__volatile = 0; - if (g_once_init_enter (&pdf_writer_type_id__volatile)) { - static const GTypeValueTable g_define_type_value_table = { value_pdf_writer_init, value_pdf_writer_free_value, value_pdf_writer_copy_value, value_pdf_writer_peek_pointer, "p", value_pdf_writer_collect_value, "p", value_pdf_writer_lcopy_value }; - static const GTypeInfo g_define_type_info = { sizeof (PDFWriterClass), (GBaseInitFunc) NULL, (GBaseFinalizeFunc) NULL, (GClassInitFunc) pdf_writer_class_init, (GClassFinalizeFunc) NULL, NULL, sizeof (PDFWriter), 0, (GInstanceInitFunc) pdf_writer_instance_init, &g_define_type_value_table }; - static const GTypeFundamentalInfo g_define_type_fundamental_info = { (G_TYPE_FLAG_CLASSED | G_TYPE_FLAG_INSTANTIATABLE | G_TYPE_FLAG_DERIVABLE | G_TYPE_FLAG_DEEP_DERIVABLE) }; - GType pdf_writer_type_id; - pdf_writer_type_id = g_type_register_fundamental (g_type_fundamental_next (), "PDFWriter", &g_define_type_info, &g_define_type_fundamental_info, 0); - g_once_init_leave (&pdf_writer_type_id__volatile, pdf_writer_type_id); - } - return pdf_writer_type_id__volatile; -} - - -gpointer pdf_writer_ref (gpointer instance) { - PDFWriter* self; - self = instance; -#line 627 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - g_atomic_int_inc (&self->ref_count); -#line 627 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - return instance; -#line 6019 "book.c" -} - - -void pdf_writer_unref (gpointer instance) { - PDFWriter* self; - self = instance; -#line 627 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - if (g_atomic_int_dec_and_test (&self->ref_count)) { -#line 627 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - PDF_WRITER_GET_CLASS (self)->finalize (self); -#line 627 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - g_type_free_instance ((GTypeInstance *) self); -#line 6032 "book.c" - } -} - - -static cairo_status_t _ps_writer_write_cairo_data_cairo_write_func_t (gpointer self, guchar* data, int data_length1) { - cairo_status_t result; - result = ps_writer_write_cairo_data ((PsWriter*) self, data, data_length1); -#line 679 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - return result; -#line 6042 "book.c" -} - - -PsWriter* ps_writer_construct (GType object_type, GFileOutputStream* stream) { - PsWriter* self = NULL; - GFileOutputStream* _tmp0_ = NULL; - GFileOutputStream* _tmp1_ = NULL; - cairo_surface_t* _tmp2_ = NULL; -#line 676 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - g_return_val_if_fail (stream != NULL, NULL); -#line 676 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - self = (PsWriter*) g_type_create_instance (object_type); -#line 678 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp0_ = stream; -#line 678 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp1_ = _g_object_ref0 (_tmp0_); -#line 678 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _g_object_unref0 (self->stream); -#line 678 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - self->stream = _tmp1_; -#line 679 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp2_ = cairo_ps_surface_create_for_stream (_ps_writer_write_cairo_data_cairo_write_func_t, self, (gdouble) 0, (gdouble) 0); -#line 679 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _cairo_surface_destroy0 (self->surface); -#line 679 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - self->surface = _tmp2_; -#line 676 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - return self; -#line 6071 "book.c" -} - - -PsWriter* ps_writer_new (GFileOutputStream* stream) { -#line 676 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - return ps_writer_construct (TYPE_PS_WRITER, stream); -#line 6078 "book.c" -} - - -static cairo_status_t ps_writer_write_cairo_data (PsWriter* self, guint8* data, int data_length1) { - cairo_status_t result = 0; - GError * _inner_error_ = NULL; -#line 682 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - g_return_val_if_fail (self != NULL, 0); -#line 6087 "book.c" - { - GFileOutputStream* _tmp0_ = NULL; - guint8* _tmp1_ = NULL; - gint _tmp1__length1 = 0; -#line 686 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp0_ = self->stream; -#line 686 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp1_ = data; -#line 686 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp1__length1 = data_length1; -#line 686 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - g_output_stream_write_all ((GOutputStream*) _tmp0_, _tmp1_, (gsize) _tmp1__length1, NULL, NULL, &_inner_error_); -#line 686 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - if (G_UNLIKELY (_inner_error_ != NULL)) { -#line 6102 "book.c" - goto __catch2_g_error; - } - } - goto __finally2; - __catch2_g_error: - { - GError* e = NULL; - GError* _tmp2_ = NULL; - const gchar* _tmp3_ = NULL; -#line 684 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - e = _inner_error_; -#line 684 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _inner_error_ = NULL; -#line 690 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp2_ = e; -#line 690 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _tmp3_ = _tmp2_->message; -#line 690 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - g_warning ("book.vala:690: Error writing data: %s", _tmp3_); -#line 691 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - result = CAIRO_STATUS_WRITE_ERROR; -#line 691 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _g_error_free0 (e); -#line 691 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - return result; -#line 6128 "book.c" - } - __finally2: -#line 684 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - if (G_UNLIKELY (_inner_error_ != NULL)) { -#line 684 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - g_critical ("file %s: line %d: uncaught error: %s (%s, %d)", __FILE__, __LINE__, _inner_error_->message, g_quark_to_string (_inner_error_->domain), _inner_error_->code); -#line 684 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - g_clear_error (&_inner_error_); -#line 684 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - return 0; -#line 6139 "book.c" - } -#line 694 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - result = CAIRO_STATUS_SUCCESS; -#line 694 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - return result; -#line 6145 "book.c" -} - - -static void value_ps_writer_init (GValue* value) { -#line 671 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - value->data[0].v_pointer = NULL; -#line 6152 "book.c" -} - - -static void value_ps_writer_free_value (GValue* value) { -#line 671 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - if (value->data[0].v_pointer) { -#line 671 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - ps_writer_unref (value->data[0].v_pointer); -#line 6161 "book.c" - } -} - - -static void value_ps_writer_copy_value (const GValue* src_value, GValue* dest_value) { -#line 671 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - if (src_value->data[0].v_pointer) { -#line 671 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - dest_value->data[0].v_pointer = ps_writer_ref (src_value->data[0].v_pointer); -#line 6171 "book.c" - } else { -#line 671 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - dest_value->data[0].v_pointer = NULL; -#line 6175 "book.c" - } -} - - -static gpointer value_ps_writer_peek_pointer (const GValue* value) { -#line 671 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - return value->data[0].v_pointer; -#line 6183 "book.c" -} - - -static gchar* value_ps_writer_collect_value (GValue* value, guint n_collect_values, GTypeCValue* collect_values, guint collect_flags) { -#line 671 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - if (collect_values[0].v_pointer) { -#line 6190 "book.c" - PsWriter* object; - object = collect_values[0].v_pointer; -#line 671 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - if (object->parent_instance.g_class == NULL) { -#line 671 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - return g_strconcat ("invalid unclassed object pointer for value type `", G_VALUE_TYPE_NAME (value), "'", NULL); -#line 6197 "book.c" - } else if (!g_value_type_compatible (G_TYPE_FROM_INSTANCE (object), G_VALUE_TYPE (value))) { -#line 671 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - return g_strconcat ("invalid object type `", g_type_name (G_TYPE_FROM_INSTANCE (object)), "' for value type `", G_VALUE_TYPE_NAME (value), "'", NULL); -#line 6201 "book.c" - } -#line 671 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - value->data[0].v_pointer = ps_writer_ref (object); -#line 6205 "book.c" - } else { -#line 671 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - value->data[0].v_pointer = NULL; -#line 6209 "book.c" - } -#line 671 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - return NULL; -#line 6213 "book.c" -} - - -static gchar* value_ps_writer_lcopy_value (const GValue* value, guint n_collect_values, GTypeCValue* collect_values, guint collect_flags) { - PsWriter** object_p; - object_p = collect_values[0].v_pointer; -#line 671 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - if (!object_p) { -#line 671 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - return g_strdup_printf ("value location for `%s' passed as NULL", G_VALUE_TYPE_NAME (value)); -#line 6224 "book.c" - } -#line 671 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - if (!value->data[0].v_pointer) { -#line 671 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - *object_p = NULL; -#line 6230 "book.c" - } else if (collect_flags & G_VALUE_NOCOPY_CONTENTS) { -#line 671 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - *object_p = value->data[0].v_pointer; -#line 6234 "book.c" - } else { -#line 671 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - *object_p = ps_writer_ref (value->data[0].v_pointer); -#line 6238 "book.c" - } -#line 671 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - return NULL; -#line 6242 "book.c" -} - - -GParamSpec* param_spec_ps_writer (const gchar* name, const gchar* nick, const gchar* blurb, GType object_type, GParamFlags flags) { - ParamSpecPsWriter* spec; -#line 671 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - g_return_val_if_fail (g_type_is_a (object_type, TYPE_PS_WRITER), NULL); -#line 671 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - spec = g_param_spec_internal (G_TYPE_PARAM_OBJECT, name, nick, blurb, flags); -#line 671 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - G_PARAM_SPEC (spec)->value_type = object_type; -#line 671 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - return G_PARAM_SPEC (spec); -#line 6256 "book.c" -} - - -gpointer value_get_ps_writer (const GValue* value) { -#line 671 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - g_return_val_if_fail (G_TYPE_CHECK_VALUE_TYPE (value, TYPE_PS_WRITER), NULL); -#line 671 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - return value->data[0].v_pointer; -#line 6265 "book.c" -} - - -void value_set_ps_writer (GValue* value, gpointer v_object) { - PsWriter* old; -#line 671 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - g_return_if_fail (G_TYPE_CHECK_VALUE_TYPE (value, TYPE_PS_WRITER)); -#line 671 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - old = value->data[0].v_pointer; -#line 671 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - if (v_object) { -#line 671 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - g_return_if_fail (G_TYPE_CHECK_INSTANCE_TYPE (v_object, TYPE_PS_WRITER)); -#line 671 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - g_return_if_fail (g_value_type_compatible (G_TYPE_FROM_INSTANCE (v_object), G_VALUE_TYPE (value))); -#line 671 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - value->data[0].v_pointer = v_object; -#line 671 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - ps_writer_ref (value->data[0].v_pointer); -#line 6285 "book.c" - } else { -#line 671 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - value->data[0].v_pointer = NULL; -#line 6289 "book.c" - } -#line 671 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - if (old) { -#line 671 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - ps_writer_unref (old); -#line 6295 "book.c" - } -} - - -void value_take_ps_writer (GValue* value, gpointer v_object) { - PsWriter* old; -#line 671 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - g_return_if_fail (G_TYPE_CHECK_VALUE_TYPE (value, TYPE_PS_WRITER)); -#line 671 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - old = value->data[0].v_pointer; -#line 671 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - if (v_object) { -#line 671 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - g_return_if_fail (G_TYPE_CHECK_INSTANCE_TYPE (v_object, TYPE_PS_WRITER)); -#line 671 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - g_return_if_fail (g_value_type_compatible (G_TYPE_FROM_INSTANCE (v_object), G_VALUE_TYPE (value))); -#line 671 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - value->data[0].v_pointer = v_object; -#line 6314 "book.c" - } else { -#line 671 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - value->data[0].v_pointer = NULL; -#line 6318 "book.c" - } -#line 671 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - if (old) { -#line 671 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - ps_writer_unref (old); -#line 6324 "book.c" - } -} - - -static void ps_writer_class_init (PsWriterClass * klass) { -#line 671 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - ps_writer_parent_class = g_type_class_peek_parent (klass); -#line 671 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - ((PsWriterClass *) klass)->finalize = ps_writer_finalize; -#line 6334 "book.c" -} - - -static void ps_writer_instance_init (PsWriter * self) { -#line 671 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - self->ref_count = 1; -#line 6341 "book.c" -} - - -static void ps_writer_finalize (PsWriter* obj) { - PsWriter * self; -#line 671 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - self = G_TYPE_CHECK_INSTANCE_CAST (obj, TYPE_PS_WRITER, PsWriter); -#line 671 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - g_signal_handlers_destroy (self); -#line 673 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _cairo_surface_destroy0 (self->surface); -#line 674 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - _g_object_unref0 (self->stream); -#line 6355 "book.c" -} - - -GType ps_writer_get_type (void) { - static volatile gsize ps_writer_type_id__volatile = 0; - if (g_once_init_enter (&ps_writer_type_id__volatile)) { - static const GTypeValueTable g_define_type_value_table = { value_ps_writer_init, value_ps_writer_free_value, value_ps_writer_copy_value, value_ps_writer_peek_pointer, "p", value_ps_writer_collect_value, "p", value_ps_writer_lcopy_value }; - static const GTypeInfo g_define_type_info = { sizeof (PsWriterClass), (GBaseInitFunc) NULL, (GBaseFinalizeFunc) NULL, (GClassInitFunc) ps_writer_class_init, (GClassFinalizeFunc) NULL, NULL, sizeof (PsWriter), 0, (GInstanceInitFunc) ps_writer_instance_init, &g_define_type_value_table }; - static const GTypeFundamentalInfo g_define_type_fundamental_info = { (G_TYPE_FLAG_CLASSED | G_TYPE_FLAG_INSTANTIATABLE | G_TYPE_FLAG_DERIVABLE | G_TYPE_FLAG_DEEP_DERIVABLE) }; - GType ps_writer_type_id; - ps_writer_type_id = g_type_register_fundamental (g_type_fundamental_next (), "PsWriter", &g_define_type_info, &g_define_type_fundamental_info, 0); - g_once_init_leave (&ps_writer_type_id__volatile, ps_writer_type_id); - } - return ps_writer_type_id__volatile; -} - - -gpointer ps_writer_ref (gpointer instance) { - PsWriter* self; - self = instance; -#line 671 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - g_atomic_int_inc (&self->ref_count); -#line 671 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - return instance; -#line 6380 "book.c" -} - - -void ps_writer_unref (gpointer instance) { - PsWriter* self; - self = instance; -#line 671 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - if (g_atomic_int_dec_and_test (&self->ref_count)) { -#line 671 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - PS_WRITER_GET_CLASS (self)->finalize (self); -#line 671 "/home/bob/bzr/simple-scan/trunk/src/book.vala" - g_type_free_instance ((GTypeInstance *) self); -#line 6393 "book.c" - } -} - - -static void _vala_array_destroy (gpointer array, gint array_length, GDestroyNotify destroy_func) { - if ((array != NULL) && (destroy_func != NULL)) { - int i; - for (i = 0; i < array_length; i = i + 1) { - if (((gpointer*) array)[i] != NULL) { - destroy_func (((gpointer*) array)[i]); - } - } - } -} - - -static void _vala_array_free (gpointer array, gint array_length, GDestroyNotify destroy_func) { - _vala_array_destroy (array, array_length, destroy_func); - g_free (array); -} - - - diff --git a/src/book.vala b/src/book.vala index 4119cfc..a843981 100644 --- a/src/book.vala +++ b/src/book.vala @@ -15,24 +15,11 @@ public class Book public uint n_pages { get { return pages.length (); } } - private bool needs_saving_; - public bool needs_saving - { - get { return needs_saving_; } - set - { - if (needs_saving_ == value) - return; - needs_saving_ = value; - needs_saving_changed (); - } - } - public signal void page_added (Page page); public signal void page_removed (Page page); public signal void reordered (); public signal void cleared (); - public signal void needs_saving_changed (); + public signal void changed (); public signal void saving (int i); public Book () @@ -62,7 +49,7 @@ public class Book private void page_changed_cb (Page page) { - needs_saving = true; + changed (); } public void append_page (Page page) @@ -72,7 +59,7 @@ public class Book pages.append (page); page_added (page); - needs_saving = true; + changed (); } public void move_page (Page page, uint location) @@ -80,7 +67,7 @@ public class Book pages.remove (page); pages.insert (page, (int) location); reordered (); - needs_saving = true; + changed (); } public void reverse () @@ -91,7 +78,7 @@ public class Book pages = (owned) new_pages; reordered (); - needs_saving = true; + changed (); } public void combine_sides () @@ -108,7 +95,7 @@ public class Book pages = (owned) new_pages; reordered (); - needs_saving = true; + changed (); } public void combine_sides_reverse () @@ -124,7 +111,7 @@ public class Book pages = (owned) new_pages; reordered (); - needs_saving = true; + changed (); } public void delete_page (Page page) @@ -133,7 +120,7 @@ public class Book page.crop_changed.disconnect (page_changed_cb); pages.remove (page); page_removed (page); - needs_saving = true; + changed (); } public Page get_page (int page_number) @@ -148,7 +135,7 @@ public class Book return pages.index (page); } - private File make_indexed_file (string uri, int i) + public File make_indexed_file (string uri, int i) { if (n_pages == 1) return File.new_for_uri (uri); @@ -178,34 +165,6 @@ public class Book } } - private void save_ps_pdf_surface (Cairo.Surface surface, Gdk.Pixbuf image, double dpi) - { - var context = new Cairo.Context (surface); - context.scale (72.0 / dpi, 72.0 / dpi); - Gdk.cairo_set_source_pixbuf (context, image, 0, 0); - context.get_source ().set_filter (Cairo.Filter.BEST); - context.paint (); - } - - private void save_ps (File file) throws Error - { - var stream = file.replace (null, false, FileCreateFlags.NONE, null); - var writer = new PsWriter (stream); - var surface = writer.surface; - - for (var i = 0; i < n_pages; i++) - { - var page = get_page (i); - var image = page.get_image (true); - var width = image.width * 72.0 / page.dpi; - var height = image.height * 72.0 / page.dpi; - surface.set_size (width, height); - save_ps_pdf_surface (surface, image, page.dpi); - surface.show_page (); - saving (i); - } - } - private uint8[]? compress_zlib (uint8[] data) { var stream = ZLib.DeflateStream (ZLib.Level.BEST_COMPRESSION); @@ -611,12 +570,8 @@ public class Book { case "jpeg": case "png": - case "tiff": save_multi_file (type, quality, file); break; - case "ps": - save_ps (file); - break; case "pdf": save_pdf (file, quality); break; diff --git a/src/colord.vapi b/src/colord.vapi deleted file mode 100644 index 817673f..0000000 --- a/src/colord.vapi +++ /dev/null @@ -1,17 +0,0 @@ -[CCode (cprefix = "Cd", lower_case_cprefix = "cd_", cheader_filename = "colord.h")] -namespace Colord { - public class Client : GLib.Object { - public Client (); - public bool connect_sync (GLib.Cancellable? cancellable = null) throws GLib.Error; - public Device find_device_by_property_sync (string key, string value, GLib.Cancellable? cancellable = null) throws GLib.Error; - } - public class Device : GLib.Object { - public bool connect_sync (GLib.Cancellable? cancellable = null) throws GLib.Error; - public Profile? get_default_profile (); - } - public class Profile : GLib.Object { - public bool connect_sync (GLib.Cancellable? cancellable = null) throws GLib.Error; - public string? filename { get; } - } - public const string DEVICE_PROPERTY_SERIAL; -} diff --git a/src/fixes.vapi b/src/fixes.vapi deleted file mode 100644 index b83c36c..0000000 --- a/src/fixes.vapi +++ /dev/null @@ -1,4 +0,0 @@ -namespace GUsb { - /* Fixed in 0.2.7: https://github.com/hughsie/libgusb/commit/83a6b1a20653c1a17f0a909f08652b5e1df44075 */ - public GLib.GenericArray context_get_devices (GUsb.Context context); -} diff --git a/src/meson.build b/src/meson.build new file mode 100644 index 0000000..cfda86d --- /dev/null +++ b/src/meson.build @@ -0,0 +1,34 @@ +resources = gnome.compile_resources ('resources', 'simple-scan.gresource.xml', + source_dir: '.', + c_name: 'resources') + +vala_args = [ '--pkg=posix', '--vapidir=' + meson.current_source_dir () ] +dependencies = [ glib_dep, gtk_dep, zlib_dep, cairo_dep, gdk_pixbuf_dep, gusb_dep, sane_dep ] +if colord_dep.found () + vala_args += [ '-D', 'HAVE_COLORD' ] + dependencies += colord_dep +endif +if packagekit_dep.found () + vala_args += [ '-D', 'HAVE_PACKAGEKIT' ] + dependencies += packagekit_dep +endif + +simple_scan = executable ('simple-scan', + [ 'config.vapi', + 'book.vala', + 'book-view.vala', + 'page.vala', + 'page-view.vala', + 'simple-scan.vala', + 'scanner.vala', + 'ui.vala', + 'autosave-manager.vala' ] + resources, + dependencies: dependencies, + vala_args: vala_args, + c_args: [ '-DVERSION="@0@"'.format (meson.project_version ()), + '-DGETTEXT_PACKAGE="simple-scan"', + '-DLOCALE_DIR="@0@"'.format (localedir), + '-DICON_DIR="@0@"'.format (icondir), + '-DI_KNOW_THE_PACKAGEKIT_GLIB2_API_IS_SUBJECT_TO_CHANGE' ], + link_args: [ '-lm' ], + install: true ) diff --git a/src/packagekit-glib2.vapi b/src/packagekit-glib2.vapi deleted file mode 100644 index 66c3907..0000000 --- a/src/packagekit-glib2.vapi +++ /dev/null @@ -1,1371 +0,0 @@ -/* packagekit-glib2.vapi generated by vapigen-0.28, do not modify. */ - -[CCode (cprefix = "Pk", gir_namespace = "PackageKitGlib", gir_version = "1.0", lower_case_cprefix = "pk_")] -namespace Pk { - [CCode (cheader_filename = "packagekit-glib2/packagekit.h", type_id = "pk_category_get_type ()")] - public class Category : Pk.Source { - [CCode (has_construct_function = false)] - public Category (); - public unowned string get_icon (); - public unowned string get_id (); - public unowned string get_name (); - public unowned string get_parent_id (); - public unowned string get_summary (); - public void set_icon (string icon); - public void set_id (string cat_id); - public void set_name (string name); - public void set_parent_id (string parent_id); - public void set_summary (string summary); - [NoAccessorMethod] - public string cat_id { owned get; set; } - public string icon { get; set; } - public string name { get; set; } - public string parent_id { get; set; } - public string summary { get; set; } - } - [CCode (cheader_filename = "packagekit-glib2/packagekit.h", type_id = "pk_client_get_type ()")] - public class Client : GLib.Object { - [CCode (has_construct_function = false)] - public Client (); - public Pk.Results accept_eula (string eula_id, GLib.Cancellable? cancellable, Pk.ProgressCallback progress_callback) throws GLib.Error; - [CCode (finish_name = "pk_client_generic_finish")] - public async Pk.Results accept_eula_async (string eula_id, GLib.Cancellable? cancellable, Pk.ProgressCallback progress_callback) throws GLib.Error; - public Pk.Results adopt (string transaction_id, GLib.Cancellable? cancellable, Pk.ProgressCallback progress_callback) throws GLib.Error; - [CCode (finish_name = "pk_client_generic_finish")] - public async Pk.Results adopt_async (string transaction_id, GLib.Cancellable? cancellable, Pk.ProgressCallback progress_callback) throws GLib.Error; - [NoWrapper] - public virtual void changed (); - public Pk.Results depends_on (Pk.Bitfield filters, [CCode (array_length = false, array_null_terminated = true)] string[] package_ids, bool recursive, GLib.Cancellable? cancellable, Pk.ProgressCallback progress_callback) throws GLib.Error; - [CCode (finish_name = "pk_client_generic_finish")] - public async Pk.Results depends_on_async (Pk.Bitfield filters, [CCode (array_length = false, array_null_terminated = true)] string[] package_ids, bool recursive, GLib.Cancellable? cancellable, Pk.ProgressCallback progress_callback) throws GLib.Error; - public Pk.Results download_packages ([CCode (array_length = false, array_null_terminated = true)] string[] package_ids, string directory, GLib.Cancellable? cancellable, Pk.ProgressCallback progress_callback) throws GLib.Error; - [CCode (finish_name = "pk_client_generic_finish")] - public async Pk.Results download_packages_async ([CCode (array_length = false, array_null_terminated = true)] string[] package_ids, string directory, GLib.Cancellable? cancellable, Pk.ProgressCallback progress_callback) throws GLib.Error; - public bool get_background (); - public uint get_cache_age (); - public Pk.Results get_categories (GLib.Cancellable? cancellable, Pk.ProgressCallback progress_callback) throws GLib.Error; - [CCode (finish_name = "pk_client_generic_finish")] - public async Pk.Results get_categories_async (GLib.Cancellable? cancellable, Pk.ProgressCallback progress_callback) throws GLib.Error; - public Pk.Results get_details ([CCode (array_length = false, array_null_terminated = true)] string[] package_ids, GLib.Cancellable? cancellable, Pk.ProgressCallback progress_callback) throws GLib.Error; - [CCode (finish_name = "pk_client_generic_finish")] - public async Pk.Results get_details_async ([CCode (array_length = false, array_null_terminated = true)] string[] package_ids, GLib.Cancellable? cancellable, Pk.ProgressCallback progress_callback) throws GLib.Error; - public Pk.Results get_details_local ([CCode (array_length = false, array_null_terminated = true)] string[] files, GLib.Cancellable? cancellable, Pk.ProgressCallback progress_callback) throws GLib.Error; - [CCode (finish_name = "pk_client_generic_finish")] - public async Pk.Results get_details_local_async ([CCode (array_length = false, array_null_terminated = true)] string[] files, GLib.Cancellable? cancellable, Pk.ProgressCallback progress_callback) throws GLib.Error; - public Pk.Results get_distro_upgrades (GLib.Cancellable? cancellable, Pk.ProgressCallback progress_callback) throws GLib.Error; - [CCode (finish_name = "pk_client_generic_finish")] - public async Pk.Results get_distro_upgrades_async (GLib.Cancellable? cancellable, Pk.ProgressCallback progress_callback) throws GLib.Error; - public Pk.Results get_files ([CCode (array_length = false, array_null_terminated = true)] string[] package_ids, GLib.Cancellable? cancellable, Pk.ProgressCallback progress_callback) throws GLib.Error; - [CCode (finish_name = "pk_client_generic_finish")] - public async Pk.Results get_files_async ([CCode (array_length = false, array_null_terminated = true)] string[] package_ids, GLib.Cancellable? cancellable, Pk.ProgressCallback progress_callback) throws GLib.Error; - public Pk.Results get_files_local ([CCode (array_length = false, array_null_terminated = true)] string[] files, GLib.Cancellable? cancellable, Pk.ProgressCallback progress_callback) throws GLib.Error; - [CCode (finish_name = "pk_client_generic_finish")] - public async Pk.Results get_files_local_async ([CCode (array_length = false, array_null_terminated = true)] string[] files, GLib.Cancellable? cancellable, Pk.ProgressCallback progress_callback) throws GLib.Error; - public bool get_idle (); - public bool get_interactive (); - public unowned string get_locale (); - public Pk.Results get_old_transactions (uint number, GLib.Cancellable? cancellable, Pk.ProgressCallback progress_callback) throws GLib.Error; - [CCode (finish_name = "pk_client_generic_finish")] - public async Pk.Results get_old_transactions_async (uint number, GLib.Cancellable? cancellable, Pk.ProgressCallback progress_callback) throws GLib.Error; - public Pk.Results get_packages (Pk.Bitfield filters, GLib.Cancellable? cancellable, Pk.ProgressCallback progress_callback) throws GLib.Error; - [CCode (finish_name = "pk_client_generic_finish")] - public async Pk.Results get_packages_async (Pk.Bitfield filters, GLib.Cancellable? cancellable, Pk.ProgressCallback progress_callback) throws GLib.Error; - public Pk.Progress get_progress (string transaction_id, GLib.Cancellable? cancellable = null) throws GLib.Error; - public async Pk.Progress get_progress_async (string transaction_id, GLib.Cancellable? cancellable) throws GLib.Error; - public Pk.Results get_repo_list (Pk.Bitfield filters, GLib.Cancellable? cancellable, Pk.ProgressCallback progress_callback) throws GLib.Error; - [CCode (finish_name = "pk_client_generic_finish")] - public async Pk.Results get_repo_list_async (Pk.Bitfield filters, GLib.Cancellable? cancellable, Pk.ProgressCallback progress_callback) throws GLib.Error; - public Pk.Results get_update_detail ([CCode (array_length = false, array_null_terminated = true)] string[] package_ids, GLib.Cancellable? cancellable, Pk.ProgressCallback progress_callback) throws GLib.Error; - [CCode (finish_name = "pk_client_generic_finish")] - public async Pk.Results get_update_detail_async ([CCode (array_length = false, array_null_terminated = true)] string[] package_ids, GLib.Cancellable? cancellable, Pk.ProgressCallback progress_callback) throws GLib.Error; - public Pk.Results get_updates (Pk.Bitfield filters, GLib.Cancellable? cancellable, Pk.ProgressCallback progress_callback) throws GLib.Error; - [CCode (finish_name = "pk_client_generic_finish")] - public async Pk.Results get_updates_async (Pk.Bitfield filters, GLib.Cancellable? cancellable, Pk.ProgressCallback progress_callback) throws GLib.Error; - public Pk.Results install_files (Pk.Bitfield transaction_flags, [CCode (array_length = false, array_null_terminated = true)] string[] files, GLib.Cancellable? cancellable, Pk.ProgressCallback progress_callback) throws GLib.Error; - [CCode (finish_name = "pk_client_generic_finish")] - public async Pk.Results install_files_async (Pk.Bitfield transaction_flags, [CCode (array_length = false, array_null_terminated = true)] string[] files, GLib.Cancellable? cancellable, Pk.ProgressCallback progress_callback) throws GLib.Error; - public Pk.Results install_packages (Pk.Bitfield transaction_flags, [CCode (array_length = false, array_null_terminated = true)] string[] package_ids, GLib.Cancellable? cancellable, Pk.ProgressCallback progress_callback) throws GLib.Error; - [CCode (finish_name = "pk_client_generic_finish")] - public async Pk.Results install_packages_async (Pk.Bitfield transaction_flags, [CCode (array_length = false, array_null_terminated = true)] string[] package_ids, GLib.Cancellable? cancellable, Pk.ProgressCallback progress_callback) throws GLib.Error; - public Pk.Results install_signature (Pk.SigType type, string key_id, string package_id, GLib.Cancellable? cancellable, Pk.ProgressCallback progress_callback) throws GLib.Error; - [CCode (finish_name = "pk_client_generic_finish")] - public async Pk.Results install_signature_async (Pk.SigType type, string key_id, string package_id, GLib.Cancellable? cancellable, Pk.ProgressCallback progress_callback) throws GLib.Error; - public Pk.Results refresh_cache (bool force, GLib.Cancellable? cancellable, Pk.ProgressCallback progress_callback) throws GLib.Error; - [CCode (finish_name = "pk_client_generic_finish")] - public async Pk.Results refresh_cache_async (bool force, GLib.Cancellable? cancellable, Pk.ProgressCallback progress_callback) throws GLib.Error; - public Pk.Results remove_packages (Pk.Bitfield transaction_flags, [CCode (array_length = false, array_null_terminated = true)] string[] package_ids, bool allow_deps, bool autoremove, GLib.Cancellable? cancellable, Pk.ProgressCallback progress_callback) throws GLib.Error; - [CCode (finish_name = "pk_client_generic_finish")] - public async Pk.Results remove_packages_async (Pk.Bitfield transaction_flags, [CCode (array_length = false, array_null_terminated = true)] string[] package_ids, bool allow_deps, bool autoremove, GLib.Cancellable? cancellable, Pk.ProgressCallback progress_callback) throws GLib.Error; - public Pk.Results repair_system (Pk.Bitfield transaction_flags, GLib.Cancellable? cancellable, Pk.ProgressCallback progress_callback) throws GLib.Error; - [CCode (finish_name = "pk_client_generic_finish")] - public async Pk.Results repair_system_async (Pk.Bitfield transaction_flags, GLib.Cancellable? cancellable, Pk.ProgressCallback progress_callback) throws GLib.Error; - public Pk.Results repo_enable (string repo_id, bool enabled, GLib.Cancellable? cancellable, Pk.ProgressCallback progress_callback) throws GLib.Error; - [CCode (finish_name = "pk_client_generic_finish")] - public async Pk.Results repo_enable_async (string repo_id, bool enabled, GLib.Cancellable? cancellable, Pk.ProgressCallback progress_callback) throws GLib.Error; - public Pk.Results repo_remove (Pk.Bitfield transaction_flags, string repo_id, bool autoremove, GLib.Cancellable? cancellable, Pk.ProgressCallback progress_callback) throws GLib.Error; - [CCode (finish_name = "pk_client_generic_finish")] - public async Pk.Results repo_remove_async (Pk.Bitfield transaction_flags, string repo_id, bool autoremove, GLib.Cancellable? cancellable, Pk.ProgressCallback progress_callback) throws GLib.Error; - public Pk.Results repo_set_data (string repo_id, string parameter, string value, GLib.Cancellable? cancellable, Pk.ProgressCallback progress_callback) throws GLib.Error; - [CCode (finish_name = "pk_client_generic_finish")] - public async Pk.Results repo_set_data_async (string repo_id, string parameter, string value, GLib.Cancellable? cancellable, Pk.ProgressCallback progress_callback) throws GLib.Error; - public Pk.Results required_by (Pk.Bitfield filters, [CCode (array_length = false, array_null_terminated = true)] string[] package_ids, bool recursive, GLib.Cancellable? cancellable, Pk.ProgressCallback progress_callback) throws GLib.Error; - [CCode (finish_name = "pk_client_generic_finish")] - public async Pk.Results required_by_async (Pk.Bitfield filters, [CCode (array_length = false, array_null_terminated = true)] string[] package_ids, bool recursive, GLib.Cancellable? cancellable, Pk.ProgressCallback progress_callback) throws GLib.Error; - public Pk.Results resolve (Pk.Bitfield filters, [CCode (array_length = false, array_null_terminated = true)] string[] packages, GLib.Cancellable? cancellable, Pk.ProgressCallback progress_callback) throws GLib.Error; - [CCode (finish_name = "pk_client_generic_finish")] - public async Pk.Results resolve_async (Pk.Bitfield filters, [CCode (array_length = false, array_null_terminated = true)] string[] packages, GLib.Cancellable? cancellable, Pk.ProgressCallback progress_callback) throws GLib.Error; - public Pk.Results search_details (Pk.Bitfield filters, [CCode (array_length = false, array_null_terminated = true)] string[] values, GLib.Cancellable? cancellable, Pk.ProgressCallback progress_callback) throws GLib.Error; - [CCode (finish_name = "pk_client_generic_finish")] - public async Pk.Results search_details_async (Pk.Bitfield filters, [CCode (array_length = false, array_null_terminated = true)] string[] values, GLib.Cancellable? cancellable, Pk.ProgressCallback progress_callback) throws GLib.Error; - public Pk.Results search_files (Pk.Bitfield filters, [CCode (array_length = false, array_null_terminated = true)] string[] values, GLib.Cancellable? cancellable, Pk.ProgressCallback progress_callback) throws GLib.Error; - [CCode (finish_name = "pk_client_generic_finish")] - public async Pk.Results search_files_async (Pk.Bitfield filters, [CCode (array_length = false, array_null_terminated = true)] string[] values, GLib.Cancellable? cancellable, Pk.ProgressCallback progress_callback) throws GLib.Error; - public Pk.Results search_groups (Pk.Bitfield filters, [CCode (array_length = false, array_null_terminated = true)] string[] values, GLib.Cancellable? cancellable, Pk.ProgressCallback progress_callback) throws GLib.Error; - [CCode (finish_name = "pk_client_generic_finish")] - public async Pk.Results search_groups_async (Pk.Bitfield filters, [CCode (array_length = false, array_null_terminated = true)] string[] values, GLib.Cancellable? cancellable, Pk.ProgressCallback progress_callback) throws GLib.Error; - public Pk.Results search_names (Pk.Bitfield filters, [CCode (array_length = false, array_null_terminated = true)] string[] values, GLib.Cancellable? cancellable, Pk.ProgressCallback progress_callback) throws GLib.Error; - [CCode (finish_name = "pk_client_generic_finish")] - public async Pk.Results search_names_async (Pk.Bitfield filters, [CCode (array_length = false, array_null_terminated = true)] string[] values, GLib.Cancellable? cancellable, Pk.ProgressCallback progress_callback) throws GLib.Error; - public void set_background (bool background); - public void set_cache_age (uint cache_age); - public void set_interactive (bool interactive); - public void set_locale (string locale); - public static void test (void* user_data); - public Pk.Results update_packages (Pk.Bitfield transaction_flags, [CCode (array_length = false, array_null_terminated = true)] string[] package_ids, GLib.Cancellable? cancellable, Pk.ProgressCallback progress_callback) throws GLib.Error; - [CCode (finish_name = "pk_client_generic_finish")] - public async Pk.Results update_packages_async (Pk.Bitfield transaction_flags, [CCode (array_length = false, array_null_terminated = true)] string[] package_ids, GLib.Cancellable? cancellable, Pk.ProgressCallback progress_callback) throws GLib.Error; - public Pk.Results what_provides (Pk.Bitfield filters, [CCode (array_length = false, array_null_terminated = true)] string[] values, GLib.Cancellable? cancellable, Pk.ProgressCallback progress_callback) throws GLib.Error; - [CCode (finish_name = "pk_client_generic_finish")] - public async Pk.Results what_provides_async (Pk.Bitfield filters, [CCode (array_length = false, array_null_terminated = true)] string[] values, GLib.Cancellable? cancellable, Pk.ProgressCallback progress_callback) throws GLib.Error; - public bool background { get; set; } - public uint cache_age { get; set; } - public bool idle { get; } - public bool interactive { get; set; } - public string locale { get; set; } - } - [CCode (cheader_filename = "packagekit-glib2/packagekit.h", type_id = "pk_client_helper_get_type ()")] - public class ClientHelper : GLib.Object { - [CCode (has_construct_function = false)] - public ClientHelper (); - public bool start (string socket_filename, string argv, string envp) throws GLib.Error; - public bool stop () throws GLib.Error; - } - [CCode (cheader_filename = "packagekit-glib2/packagekit.h", type_id = "pk_control_get_type ()")] - public class Control : GLib.Object { - [CCode (has_construct_function = false)] - public Control (); - public async Pk.Authorize can_authorize_async (string action_id, GLib.Cancellable? cancellable) throws GLib.Error; - [NoWrapper] - public virtual void connection_changed (bool connected); - public async string get_daemon_state_async (GLib.Cancellable? cancellable) throws GLib.Error; - public bool get_properties (GLib.Cancellable? cancellable = null) throws GLib.Error; - public async bool get_properties_async (GLib.Cancellable? cancellable) throws GLib.Error; - public async string get_tid_async (GLib.Cancellable? cancellable) throws GLib.Error; - public async uint get_time_since_action_async (Pk.Role role, GLib.Cancellable? cancellable) throws GLib.Error; - [CCode (array_length = false, array_null_terminated = true)] - public string[] get_transaction_list (GLib.Cancellable? cancellable = null) throws GLib.Error; - [CCode (array_length = false, array_null_terminated = true)] - public async string[] get_transaction_list_async (GLib.Cancellable? cancellable) throws GLib.Error; - [NoWrapper] - public virtual void network_state_changed (); - public bool set_proxy (string proxy_http, string proxy_ftp, GLib.Cancellable? cancellable = null) throws GLib.Error; - public bool set_proxy2 (string proxy_http, string proxy_https, string proxy_ftp, string proxy_socks, string no_proxy, string pac, GLib.Cancellable? cancellable = null) throws GLib.Error; - public async void set_proxy2_async (string proxy_http, string proxy_https, string proxy_ftp, string proxy_socks, string no_proxy, string pac, GLib.Cancellable? cancellable); - public async bool set_proxy_async (string proxy_http, string proxy_ftp, GLib.Cancellable? cancellable) throws GLib.Error; - public bool suggest_daemon_quit (GLib.Cancellable? cancellable = null) throws GLib.Error; - public async bool suggest_daemon_quit_async (GLib.Cancellable? cancellable) throws GLib.Error; - public static void test (void* user_data); - [NoAccessorMethod] - public string backend_author { owned get; set; } - [NoAccessorMethod] - public string backend_description { owned get; set; } - [NoAccessorMethod] - public string backend_name { owned get; set; } - [NoAccessorMethod] - public bool connected { get; set; } - [NoAccessorMethod] - public string distro_id { owned get; set; } - [NoAccessorMethod] - public uint64 filters { get; set; } - [NoAccessorMethod] - public uint64 groups { get; set; } - [NoAccessorMethod] - public virtual bool locked { get; set; } - [CCode (array_length = false, array_null_terminated = true)] - [NoAccessorMethod] - public string[] mime_types { owned get; set; } - [NoAccessorMethod] - public Pk.Network network_state { get; set; } - [NoAccessorMethod] - public uint64 provides { get; set; } - [NoAccessorMethod] - public uint64 roles { get; set; } - [NoAccessorMethod] - public uint version_major { get; } - [NoAccessorMethod] - public uint version_micro { get; } - [NoAccessorMethod] - public uint version_minor { get; } - public virtual signal void repo_list_changed (); - public virtual signal void restart_schedule (); - public virtual signal void transaction_list_changed ([CCode (array_length = false, array_null_terminated = true)] string[] transaction_ids); - public virtual signal void updates_changed (); - } - [CCode (cheader_filename = "packagekit-glib2/packagekit.h", type_id = "pk_desktop_get_type ()")] - public class Desktop : GLib.Object { - [CCode (has_construct_function = false)] - public Desktop (); - public GLib.GenericArray get_files_for_package (string package) throws GLib.Error; - public string get_package_for_file (string filename) throws GLib.Error; - public GLib.GenericArray get_shown_for_package (string package) throws GLib.Error; - public bool open_database () throws GLib.Error; - public static void test (void* user_data); - } - [CCode (cheader_filename = "packagekit-glib2/packagekit.h", type_id = "pk_details_get_type ()")] - public class Details : Pk.Source { - [CCode (has_construct_function = false)] - public Details (); - public unowned string get_description (); - public Pk.Group get_group (); - public unowned string get_license (); - public unowned string get_package_id (); - public uint64 get_size (); - public unowned string get_summary (); - public unowned string get_url (); - [NoAccessorMethod] - public string description { owned get; set; } - [NoAccessorMethod] - public Pk.Group group { get; set; } - [NoAccessorMethod] - public string license { owned get; set; } - [NoAccessorMethod] - public string package_id { owned get; set; } - [NoAccessorMethod] - public uint64 size { get; set; } - [NoAccessorMethod] - public string summary { owned get; set; } - [NoAccessorMethod] - public string url { owned get; set; } - } - [CCode (cheader_filename = "packagekit-glib2/packagekit.h", type_id = "pk_distro_upgrade_get_type ()")] - public class DistroUpgrade : Pk.Source { - [CCode (has_construct_function = false)] - public DistroUpgrade (); - public unowned string get_id (); - public Pk.DistroUpgradeEnum get_state (); - public unowned string get_summary (); - [NoAccessorMethod] - public string name { owned get; set; } - [NoAccessorMethod] - public Pk.DistroUpgradeEnum state { get; set; } - [NoAccessorMethod] - public string summary { owned get; set; } - } - [CCode (cheader_filename = "packagekit-glib2/packagekit.h", type_id = "pk_error_get_type ()")] - public class Error : Pk.Source { - [CCode (has_construct_function = false)] - public Error (); - public Pk.ErrorEnum get_code (); - public unowned string get_details (); - [NoAccessorMethod] - public Pk.ErrorEnum code { get; set; } - [NoAccessorMethod] - public string details { owned get; set; } - } - [CCode (cheader_filename = "packagekit-glib2/packagekit.h", type_id = "pk_eula_required_get_type ()")] - public class EulaRequired : Pk.Source { - [CCode (has_construct_function = false)] - public EulaRequired (); - [NoAccessorMethod] - public string eula_id { owned get; set; } - [NoAccessorMethod] - public string license_agreement { owned get; set; } - [NoAccessorMethod] - public string package_id { owned get; set; } - [NoAccessorMethod] - public string vendor_name { owned get; set; } - } - [CCode (cheader_filename = "packagekit-glib2/packagekit.h", type_id = "pk_files_get_type ()")] - public class Files : Pk.Source { - [CCode (has_construct_function = false)] - public Files (); - [CCode (array_length = false, array_null_terminated = true)] - public unowned string[] get_files (); - public unowned string get_package_id (); - [CCode (array_length = false, array_null_terminated = true)] - [NoAccessorMethod] - public string[] files { owned get; set; } - [NoAccessorMethod] - public string package_id { owned get; set; } - } - [CCode (cheader_filename = "packagekit-glib2/packagekit.h", type_id = "pk_item_progress_get_type ()")] - public class ItemProgress : Pk.Source { - [CCode (has_construct_function = false)] - public ItemProgress (); - public unowned string get_package_id (); - public uint get_percentage (); - public Pk.Status get_status (); - [NoAccessorMethod] - public string package_id { owned get; set; } - [NoAccessorMethod] - public uint percentage { get; set; } - [NoAccessorMethod] - public uint status { get; set; } - } - [CCode (cheader_filename = "packagekit-glib2/packagekit.h", type_id = "pk_media_change_required_get_type ()")] - public class MediaChangeRequired : Pk.Source { - [CCode (has_construct_function = false)] - public MediaChangeRequired (); - [NoAccessorMethod] - public string media_id { owned get; set; } - [NoAccessorMethod] - public string media_text { owned get; set; } - [NoAccessorMethod] - public Pk.MediaType media_type { get; set; } - } - [CCode (cheader_filename = "packagekit-glib2/packagekit.h", type_id = "pk_package_get_type ()")] - public class Package : Pk.Source { - [CCode (has_construct_function = false)] - public Package (); - public bool equal (Pk.Package package2); - public bool equal_id (Pk.Package package2); - public unowned string get_arch (); - public unowned string get_data (); - public unowned string get_id (); - public Pk.Info get_info (); - public unowned string get_name (); - public unowned string get_summary (); - public unowned string get_version (); - public static string id_build (string name, string version, string arch, string data); - public static bool id_check (string package_id); - public static bool id_equal_fuzzy_arch (string package_id1, string package_id2); - [CCode (array_length = false, array_null_terminated = true)] - public static string[] id_split (string package_id); - public static void id_test (void* user_data); - public static string id_to_printable (string package_id); - [CCode (array_length = false, array_null_terminated = true)] - public static string[] ids_add_id (string package_ids, string package_id); - [CCode (array_length = false, array_null_terminated = true)] - public static string[] ids_add_ids (string package_ids, string package_ids_new); - public static bool ids_check (string package_ids); - [CCode (array_length = false, array_null_terminated = true)] - public static string[] ids_from_id (string package_id); - [CCode (array_length = false, array_null_terminated = true)] - public static string[] ids_from_string (string package_id); - public static bool ids_present_id (string package_ids, string package_id); - [CCode (array_length = false, array_null_terminated = true)] - public static string[] ids_remove_id (string package_ids, string package_id); - public static void ids_test (void* user_data); - public static string ids_to_string (string package_ids); - public bool parse (string data) throws GLib.Error; - public void print (); - public bool set_id (string package_id) throws GLib.Error; - public void set_info (Pk.Info info); - public void set_summary (string summary); - public static void test (void* user_data); - [NoAccessorMethod] - public string description { owned get; set; } - [NoAccessorMethod] - public Pk.Group group { get; set; } - public Pk.Info info { get; set; } - [NoAccessorMethod] - public string license { owned get; set; } - [NoAccessorMethod] - public string package_id { owned get; } - [NoAccessorMethod] - public uint64 size { get; set; } - public string summary { get; set; } - [CCode (array_length = false, array_null_terminated = true)] - [NoAccessorMethod] - public string[] update_bugzilla_urls { owned get; set; } - [NoAccessorMethod] - public string update_changelog { owned get; set; } - [CCode (array_length = false, array_null_terminated = true)] - [NoAccessorMethod] - public string[] update_cve_urls { owned get; set; } - [NoAccessorMethod] - public string update_issued { owned get; set; } - [NoAccessorMethod] - public string update_obsoletes { owned get; set; } - [NoAccessorMethod] - public Pk.Restart update_restart { get; set; } - [NoAccessorMethod] - public Pk.UpdateState update_state { get; set; } - [NoAccessorMethod] - public string update_text { owned get; set; } - [NoAccessorMethod] - public string update_updated { owned get; set; } - [NoAccessorMethod] - public string update_updates { owned get; set; } - [CCode (array_length = false, array_null_terminated = true)] - [NoAccessorMethod] - public string[] update_vendor_urls { owned get; set; } - [NoAccessorMethod] - public string url { owned get; set; } - public virtual signal void changed (); - } - [CCode (cheader_filename = "packagekit-glib2/packagekit.h", type_id = "pk_package_sack_get_type ()")] - public class PackageSack : GLib.Object { - [CCode (has_construct_function = false)] - public PackageSack (); - public bool add_package (Pk.Package package); - public bool add_package_by_id (string package_id) throws GLib.Error; - public bool add_packages_from_file (GLib.File file) throws GLib.Error; - [NoWrapper] - public virtual void changed (); - public void clear (); - public Pk.PackageSack filter (Pk.PackageSackFilterFunc filter_cb); - public Pk.PackageSack filter_by_info (Pk.Info info); - public Pk.Package find_by_id (string package_id); - public Pk.Package find_by_id_name_arch (string package_id); - public GLib.GenericArray get_array (); - public bool get_details (GLib.Cancellable? cancellable = null) throws GLib.Error; - [CCode (finish_name = "pk_package_sack_merge_generic_finish")] - public async bool get_details_async (GLib.Cancellable? cancellable, Pk.ProgressCallback progress_callback) throws GLib.Error; - [CCode (array_length = false, array_null_terminated = true)] - public string[] get_ids (); - public uint get_size (); - public uint64 get_total_bytes (); - public bool get_update_detail (GLib.Cancellable? cancellable = null) throws GLib.Error; - [CCode (finish_name = "pk_package_sack_merge_generic_finish")] - public async bool get_update_detail_async (GLib.Cancellable? cancellable, Pk.ProgressCallback progress_callback) throws GLib.Error; - public bool remove_by_filter (Pk.PackageSackFilterFunc filter_cb); - public bool remove_package (Pk.Package package); - public bool remove_package_by_id (string package_id); - public bool resolve (GLib.Cancellable? cancellable = null) throws GLib.Error; - [CCode (finish_name = "pk_package_sack_merge_generic_finish")] - public async bool resolve_async (GLib.Cancellable? cancellable, Pk.ProgressCallback progress_callback) throws GLib.Error; - public void sort (Pk.PackageSackSortType type); - public static void test (void* user_data); - public bool to_file (GLib.File file) throws GLib.Error; - } - [CCode (cheader_filename = "packagekit-glib2/packagekit.h")] - [Compact] - public class PackageSackResults { - } - [CCode (cheader_filename = "packagekit-glib2/packagekit.h", type_id = "pk_progress_get_type ()")] - public class Progress : GLib.Object { - [CCode (has_construct_function = false)] - public Progress (); - public bool set_allow_cancel (bool allow_cancel); - public bool set_caller_active (bool caller_active); - public bool set_download_size_remaining (uint64 download_size_remaining); - public bool set_elapsed_time (uint elapsed_time); - public bool set_item_progress (Pk.ItemProgress item_progress); - public bool set_package (Pk.Package package); - public bool set_package_id (string package_id); - public bool set_percentage (int percentage); - public bool set_remaining_time (uint remaining_time); - public bool set_role (Pk.Role role); - public bool set_speed (uint speed); - public bool set_status (Pk.Status status); - public bool set_transaction_flags (uint64 transaction_flags); - public bool set_transaction_id (string package_id); - public bool set_uid (uint uid); - public static void test (void* user_data); - [NoAccessorMethod] - public bool allow_cancel { get; set; } - [NoAccessorMethod] - public bool caller_active { get; set; } - [NoAccessorMethod] - public uint download_size_remaining { get; set; } - [NoAccessorMethod] - public uint elapsed_time { get; set; } - [NoAccessorMethod] - public Pk.ItemProgress item_progress { owned get; set; } - [NoAccessorMethod] - public Pk.Package package { owned get; set; } - [NoAccessorMethod] - public string package_id { owned get; set; } - [NoAccessorMethod] - public int percentage { get; set; } - [NoAccessorMethod] - public uint remaining_time { get; set; } - [NoAccessorMethod] - public uint role { get; set; } - [NoAccessorMethod] - public uint speed { get; set; } - [NoAccessorMethod] - public uint status { get; set; } - [NoAccessorMethod] - public uint64 transaction_flags { get; set; } - [NoAccessorMethod] - public string transaction_id { owned get; set; } - [NoAccessorMethod] - public uint uid { get; set; } - } - [CCode (cheader_filename = "packagekit-glib2/packagekit.h", type_id = "pk_repo_detail_get_type ()")] - public class RepoDetail : Pk.Source { - [CCode (has_construct_function = false)] - public RepoDetail (); - public unowned string get_description (); - public bool get_enabled (); - public unowned string get_id (); - [NoAccessorMethod] - public string description { owned get; set; } - [NoAccessorMethod] - public bool enabled { get; set; } - [NoAccessorMethod] - public string repo_id { owned get; set; } - } - [CCode (cheader_filename = "packagekit-glib2/packagekit.h", type_id = "pk_repo_signature_required_get_type ()")] - public class RepoSignatureRequired : Pk.Source { - [CCode (has_construct_function = false)] - public RepoSignatureRequired (); - [NoAccessorMethod] - public string key_fingerprint { owned get; set; } - [NoAccessorMethod] - public string key_id { owned get; set; } - [NoAccessorMethod] - public string key_timestamp { owned get; set; } - [NoAccessorMethod] - public string key_url { owned get; set; } - [NoAccessorMethod] - public string key_userid { owned get; set; } - [NoAccessorMethod] - public string package_id { owned get; set; } - [NoAccessorMethod] - public string repository_name { owned get; set; } - [NoAccessorMethod] - public Pk.SigType type { get; set; } - } - [CCode (cheader_filename = "packagekit-glib2/packagekit.h", type_id = "pk_require_restart_get_type ()")] - public class RequireRestart : Pk.Source { - [CCode (has_construct_function = false)] - public RequireRestart (); - [NoAccessorMethod] - public string package_id { owned get; set; } - [NoAccessorMethod] - public Pk.Restart restart { get; set; } - } - [CCode (cheader_filename = "packagekit-glib2/packagekit.h", type_id = "pk_results_get_type ()")] - public class Results : GLib.Object { - [CCode (has_construct_function = false)] - public Results (); - public bool add_category (Pk.Category item); - public bool add_details (Pk.Details item); - public bool add_distro_upgrade (Pk.DistroUpgrade item); - public bool add_eula_required (Pk.EulaRequired item); - public bool add_files (Pk.Files item); - public bool add_media_change_required (Pk.MediaChangeRequired item); - public bool add_package (Pk.Package item); - public bool add_repo_detail (Pk.RepoDetail item); - public bool add_repo_signature_required (Pk.RepoSignatureRequired item); - public bool add_require_restart (Pk.RequireRestart item); - public bool add_transaction (Pk.TransactionPast item); - public bool add_update_detail (Pk.UpdateDetail item); - public GLib.GenericArray get_category_array (); - public GLib.GenericArray get_details_array (); - public GLib.GenericArray get_distro_upgrade_array (); - public Pk.Error get_error_code (); - public GLib.GenericArray get_eula_required_array (); - public Pk.Exit get_exit_code (); - public GLib.GenericArray get_files_array (); - public GLib.GenericArray get_media_change_required_array (); - public GLib.GenericArray get_package_array (); - public Pk.PackageSack get_package_sack (); - public GLib.GenericArray get_repo_detail_array (); - public GLib.GenericArray get_repo_signature_required_array (); - public GLib.GenericArray get_require_restart_array (); - public Pk.Restart get_require_restart_worst (); - public Pk.Role get_role (); - public GLib.GenericArray get_transaction_array (); - public Pk.Bitfield get_transaction_flags (); - public GLib.GenericArray get_update_detail_array (); - public bool set_error_code (Pk.Error item); - public bool set_exit_code (Pk.Exit exit_enum); - public static void test (void* user_data); - [NoAccessorMethod] - public uint inputs { get; set; } - [NoAccessorMethod] - public Pk.Progress progress { owned get; set; } - [NoAccessorMethod] - public Pk.Role role { get; set; } - [NoAccessorMethod] - public uint64 transaction_flags { get; set; } - } - [CCode (cheader_filename = "packagekit-glib2/packagekit.h", type_id = "pk_source_get_type ()")] - public class Source : GLib.Object { - [CCode (has_construct_function = false)] - public Source (); - [NoAccessorMethod] - public Pk.Role role { get; set; } - [NoAccessorMethod] - public string transaction_id { owned get; set; } - } - [CCode (cheader_filename = "packagekit-glib2/packagekit.h", type_id = "pk_task_get_type ()")] - public class Task : Pk.Client { - [CCode (has_construct_function = false)] - public Task (); - [CCode (finish_name = "pk_task_generic_finish")] - public async Pk.Results depends_on_async (Pk.Bitfield filters, [CCode (array_length = false, array_null_terminated = true)] string[] package_ids, bool recursive, GLib.Cancellable? cancellable, Pk.ProgressCallback progress_callback) throws GLib.Error; - public Pk.Results depends_on_sync (Pk.Bitfield filters, [CCode (array_length = false, array_null_terminated = true)] string[] package_ids, bool recursive, GLib.Cancellable? cancellable, Pk.ProgressCallback progress_callback) throws GLib.Error; - [CCode (finish_name = "pk_task_generic_finish")] - public async Pk.Results download_packages_async ([CCode (array_length = false, array_null_terminated = true)] string[] package_ids, string directory, GLib.Cancellable? cancellable, Pk.ProgressCallback progress_callback) throws GLib.Error; - public Pk.Results download_packages_sync ([CCode (array_length = false, array_null_terminated = true)] string[] package_ids, string directory, GLib.Cancellable? cancellable, Pk.ProgressCallback progress_callback) throws GLib.Error; - [NoWrapper] - public virtual void eula_question (uint request, Pk.Results results); - public bool get_allow_downgrade (); - public bool get_allow_reinstall (); - [CCode (finish_name = "pk_task_generic_finish")] - public async Pk.Results get_categories_async (GLib.Cancellable? cancellable, Pk.ProgressCallback progress_callback) throws GLib.Error; - public Pk.Results get_categories_sync (GLib.Cancellable? cancellable, Pk.ProgressCallback progress_callback) throws GLib.Error; - [CCode (finish_name = "pk_task_generic_finish")] - public async Pk.Results get_details_async ([CCode (array_length = false, array_null_terminated = true)] string[] package_ids, GLib.Cancellable? cancellable, Pk.ProgressCallback progress_callback) throws GLib.Error; - public Pk.Results get_details_sync ([CCode (array_length = false, array_null_terminated = true)] string[] package_ids, GLib.Cancellable? cancellable, Pk.ProgressCallback progress_callback) throws GLib.Error; - [CCode (finish_name = "pk_task_generic_finish")] - public async Pk.Results get_files_async ([CCode (array_length = false, array_null_terminated = true)] string[] package_ids, GLib.Cancellable? cancellable, Pk.ProgressCallback progress_callback) throws GLib.Error; - public Pk.Results get_files_sync ([CCode (array_length = false, array_null_terminated = true)] string[] package_ids, GLib.Cancellable? cancellable, Pk.ProgressCallback progress_callback) throws GLib.Error; - public bool get_interactive (); - public bool get_only_download (); - public bool get_only_trusted (); - [CCode (finish_name = "pk_task_generic_finish")] - public async Pk.Results get_packages_async (Pk.Bitfield filters, GLib.Cancellable? cancellable, Pk.ProgressCallback progress_callback) throws GLib.Error; - public Pk.Results get_packages_sync (Pk.Bitfield filters, GLib.Cancellable? cancellable, Pk.ProgressCallback progress_callback) throws GLib.Error; - [CCode (finish_name = "pk_task_generic_finish")] - public async Pk.Results get_repo_list_async (Pk.Bitfield filters, GLib.Cancellable? cancellable, Pk.ProgressCallback progress_callback) throws GLib.Error; - public Pk.Results get_repo_list_sync (Pk.Bitfield filters, GLib.Cancellable? cancellable, Pk.ProgressCallback progress_callback) throws GLib.Error; - public bool get_simulate (); - [CCode (finish_name = "pk_task_generic_finish")] - public async Pk.Results get_update_detail_async ([CCode (array_length = false, array_null_terminated = true)] string[] package_ids, GLib.Cancellable? cancellable, Pk.ProgressCallback progress_callback) throws GLib.Error; - public Pk.Results get_update_detail_sync ([CCode (array_length = false, array_null_terminated = true)] string[] package_ids, GLib.Cancellable? cancellable, Pk.ProgressCallback progress_callback) throws GLib.Error; - [CCode (finish_name = "pk_task_generic_finish")] - public async Pk.Results get_updates_async (Pk.Bitfield filters, GLib.Cancellable? cancellable, Pk.ProgressCallback progress_callback) throws GLib.Error; - public Pk.Results get_updates_sync (Pk.Bitfield filters, GLib.Cancellable? cancellable, Pk.ProgressCallback progress_callback) throws GLib.Error; - [CCode (finish_name = "pk_task_generic_finish")] - public async Pk.Results install_files_async ([CCode (array_length = false, array_null_terminated = true)] string[] files, GLib.Cancellable? cancellable, Pk.ProgressCallback progress_callback) throws GLib.Error; - public Pk.Results install_files_sync ([CCode (array_length = false, array_null_terminated = true)] string[] files, GLib.Cancellable? cancellable, Pk.ProgressCallback progress_callback) throws GLib.Error; - [CCode (finish_name = "pk_task_generic_finish")] - public async Pk.Results install_packages_async ([CCode (array_length = false, array_null_terminated = true)] string[] package_ids, GLib.Cancellable? cancellable, Pk.ProgressCallback progress_callback) throws GLib.Error; - public Pk.Results install_packages_sync ([CCode (array_length = false, array_null_terminated = true)] string[] package_ids, GLib.Cancellable? cancellable, Pk.ProgressCallback progress_callback) throws GLib.Error; - [NoWrapper] - public virtual void key_question (uint request, Pk.Results results); - [NoWrapper] - public virtual void media_change_question (uint request, Pk.Results results); - [CCode (finish_name = "pk_task_generic_finish")] - public async Pk.Results refresh_cache_async (bool force, GLib.Cancellable? cancellable, Pk.ProgressCallback progress_callback) throws GLib.Error; - public Pk.Results refresh_cache_sync (bool force, GLib.Cancellable? cancellable, Pk.ProgressCallback progress_callback) throws GLib.Error; - [CCode (finish_name = "pk_task_generic_finish")] - public async Pk.Results remove_packages_async ([CCode (array_length = false, array_null_terminated = true)] string[] package_ids, bool allow_deps, bool autoremove, GLib.Cancellable? cancellable, Pk.ProgressCallback progress_callback) throws GLib.Error; - public Pk.Results remove_packages_sync ([CCode (array_length = false, array_null_terminated = true)] string[] package_ids, bool allow_deps, bool autoremove, GLib.Cancellable? cancellable, Pk.ProgressCallback progress_callback) throws GLib.Error; - [NoWrapper] - public virtual void repair_question (uint request, Pk.Results results); - [CCode (finish_name = "pk_task_generic_finish")] - public async Pk.Results repair_system_async (GLib.Cancellable? cancellable, Pk.ProgressCallback progress_callback) throws GLib.Error; - public Pk.Results repair_system_sync (GLib.Cancellable? cancellable, Pk.ProgressCallback progress_callback) throws GLib.Error; - [CCode (finish_name = "pk_task_generic_finish")] - public async Pk.Results repo_enable_async (string repo_id, bool enabled, GLib.Cancellable? cancellable, Pk.ProgressCallback progress_callback) throws GLib.Error; - public Pk.Results repo_enable_sync (string repo_id, bool enabled, GLib.Cancellable? cancellable, Pk.ProgressCallback progress_callback) throws GLib.Error; - [CCode (finish_name = "pk_task_generic_finish")] - public async Pk.Results required_by_async (Pk.Bitfield filters, [CCode (array_length = false, array_null_terminated = true)] string[] package_ids, bool recursive, GLib.Cancellable? cancellable, Pk.ProgressCallback progress_callback) throws GLib.Error; - public Pk.Results required_by_sync (Pk.Bitfield filters, [CCode (array_length = false, array_null_terminated = true)] string[] package_ids, bool recursive, GLib.Cancellable? cancellable, Pk.ProgressCallback progress_callback) throws GLib.Error; - [CCode (finish_name = "pk_task_generic_finish")] - public async Pk.Results resolve_async (Pk.Bitfield filters, [CCode (array_length = false, array_null_terminated = true)] string[] packages, GLib.Cancellable? cancellable, Pk.ProgressCallback progress_callback) throws GLib.Error; - public Pk.Results resolve_sync (Pk.Bitfield filters, [CCode (array_length = false, array_null_terminated = true)] string[] packages, GLib.Cancellable? cancellable, Pk.ProgressCallback progress_callback) throws GLib.Error; - [CCode (finish_name = "pk_task_generic_finish")] - public async Pk.Results search_details_async (Pk.Bitfield filters, [CCode (array_length = false, array_null_terminated = true)] string[] values, GLib.Cancellable? cancellable, Pk.ProgressCallback progress_callback) throws GLib.Error; - public Pk.Results search_details_sync (Pk.Bitfield filters, [CCode (array_length = false, array_null_terminated = true)] string[] values, GLib.Cancellable? cancellable, Pk.ProgressCallback progress_callback) throws GLib.Error; - [CCode (finish_name = "pk_task_generic_finish")] - public async Pk.Results search_files_async (Pk.Bitfield filters, [CCode (array_length = false, array_null_terminated = true)] string[] values, GLib.Cancellable? cancellable, Pk.ProgressCallback progress_callback) throws GLib.Error; - public Pk.Results search_files_sync (Pk.Bitfield filters, [CCode (array_length = false, array_null_terminated = true)] string[] values, GLib.Cancellable? cancellable, Pk.ProgressCallback progress_callback) throws GLib.Error; - [CCode (finish_name = "pk_task_generic_finish")] - public async Pk.Results search_groups_async (Pk.Bitfield filters, [CCode (array_length = false, array_null_terminated = true)] string[] values, GLib.Cancellable? cancellable, Pk.ProgressCallback progress_callback) throws GLib.Error; - public Pk.Results search_groups_sync (Pk.Bitfield filters, [CCode (array_length = false, array_null_terminated = true)] string[] values, GLib.Cancellable? cancellable, Pk.ProgressCallback progress_callback) throws GLib.Error; - [CCode (finish_name = "pk_task_generic_finish")] - public async Pk.Results search_names_async (Pk.Bitfield filters, [CCode (array_length = false, array_null_terminated = true)] string[] values, GLib.Cancellable? cancellable, Pk.ProgressCallback progress_callback) throws GLib.Error; - public Pk.Results search_names_sync (Pk.Bitfield filters, [CCode (array_length = false, array_null_terminated = true)] string[] values, GLib.Cancellable? cancellable, Pk.ProgressCallback progress_callback) throws GLib.Error; - public void set_allow_downgrade (bool allow_downgrade); - public void set_allow_reinstall (bool allow_reinstall); - public void set_interactive (bool interactive); - public void set_only_download (bool only_download); - public void set_only_trusted (bool only_trusted); - public void set_simulate (bool simulate); - [NoWrapper] - public virtual void simulate_question (uint request, Pk.Results results); - public static void test (void* user_data); - [NoWrapper] - public virtual void untrusted_question (uint request, Pk.Results results); - [CCode (finish_name = "pk_task_generic_finish")] - public async Pk.Results update_packages_async ([CCode (array_length = false, array_null_terminated = true)] string[] package_ids, GLib.Cancellable? cancellable, Pk.ProgressCallback progress_callback) throws GLib.Error; - public Pk.Results update_packages_sync ([CCode (array_length = false, array_null_terminated = true)] string[] package_ids, GLib.Cancellable? cancellable, Pk.ProgressCallback progress_callback) throws GLib.Error; - public bool user_accepted (uint request); - public bool user_declined (uint request); - [CCode (finish_name = "pk_task_generic_finish")] - public async Pk.Results what_provides_async (Pk.Bitfield filters, [CCode (array_length = false, array_null_terminated = true)] string[] values, GLib.Cancellable? cancellable, Pk.ProgressCallback progress_callback) throws GLib.Error; - public Pk.Results what_provides_sync (Pk.Bitfield filters, [CCode (array_length = false, array_null_terminated = true)] string[] values, GLib.Cancellable? cancellable, Pk.ProgressCallback progress_callback) throws GLib.Error; - public bool allow_downgrade { get; set; } - public bool allow_reinstall { get; set; } - public bool only_download { get; set; } - public bool only_trusted { get; set; } - public bool simulate { get; set; } - } - [CCode (cheader_filename = "packagekit-glib2/packagekit.h", type_id = "pk_transaction_list_get_type ()")] - public class TransactionList : GLib.Object { - [CCode (has_construct_function = false)] - public TransactionList (); - [CCode (array_length = false, array_null_terminated = true)] - public string[] get_ids (); - public static void test (void* user_data); - public virtual signal void added (string tid); - public virtual signal void removed (string tid); - } - [CCode (cheader_filename = "packagekit-glib2/packagekit.h", type_id = "pk_transaction_past_get_type ()")] - public class TransactionPast : Pk.Source { - [CCode (has_construct_function = false)] - public TransactionPast (); - public unowned string get_cmdline (); - public unowned string get_data (); - public GLib.DateTime get_datetime (); - public uint get_duration (); - public unowned string get_id (); - public Pk.Role get_role (); - public bool get_succeeded (); - public unowned string get_timespec (); - public int64 get_timestamp (); - public uint get_uid (); - [NoAccessorMethod] - public string cmdline { owned get; set; } - [NoAccessorMethod] - public string data { owned get; set; } - [NoAccessorMethod] - public uint duration { get; set; } - [NoAccessorMethod] - public Pk.Role role { get; set; } - [NoAccessorMethod] - public bool succeeded { get; set; } - [NoAccessorMethod] - public string tid { owned get; set; } - [NoAccessorMethod] - public string timespec { owned get; set; } - [NoAccessorMethod] - public uint uid { get; set; } - } - [CCode (cheader_filename = "packagekit-glib2/packagekit.h", type_id = "pk_update_detail_get_type ()")] - public class UpdateDetail : Pk.Source { - [CCode (has_construct_function = false)] - public UpdateDetail (); - [CCode (array_length = false, array_null_terminated = true)] - public unowned string[] get_bugzilla_urls (); - public unowned string get_changelog (); - [CCode (array_length = false, array_null_terminated = true)] - public unowned string[] get_cve_urls (); - public unowned string get_issued (); - [CCode (array_length = false, array_null_terminated = true)] - public unowned string[] get_obsoletes (); - public unowned string get_package_id (); - public Pk.Restart get_restart (); - public Pk.UpdateState get_state (); - public unowned string get_update_text (); - public unowned string get_updated (); - [CCode (array_length = false, array_null_terminated = true)] - public unowned string[] get_updates (); - [CCode (array_length = false, array_null_terminated = true)] - public unowned string[] get_vendor_urls (); - [CCode (array_length = false, array_null_terminated = true)] - [NoAccessorMethod] - public string[] bugzilla_urls { owned get; set; } - [NoAccessorMethod] - public string changelog { owned get; set; } - [CCode (array_length = false, array_null_terminated = true)] - [NoAccessorMethod] - public string[] cve_urls { owned get; set; } - [NoAccessorMethod] - public string issued { owned get; set; } - [CCode (array_length = false, array_null_terminated = true)] - [NoAccessorMethod] - public string[] obsoletes { owned get; set; } - [NoAccessorMethod] - public string package_id { owned get; set; } - [NoAccessorMethod] - public Pk.Restart restart { get; set; } - [NoAccessorMethod] - public Pk.UpdateState state { get; set; } - [NoAccessorMethod] - public string update_text { owned get; set; } - [NoAccessorMethod] - public string updated { owned get; set; } - [CCode (array_length = false, array_null_terminated = true)] - [NoAccessorMethod] - public string[] updates { owned get; set; } - [CCode (array_length = false, array_null_terminated = true)] - [NoAccessorMethod] - public string[] vendor_urls { owned get; set; } - } - [CCode (cheader_filename = "packagekit-glib2/packagekit.h")] - [SimpleType] - public struct Bitfield : uint64 { - public static void test (void* user_data); - } - [CCode (cheader_filename = "packagekit-glib2/packagekit.h", has_type_id = false)] - public struct EnumMatch { - public uint value; - public weak global::string string; - } - [CCode (cheader_filename = "packagekit-glib2/packagekit.h", cname = "PkAuthorizeEnum", cprefix = "PK_AUTHORIZE_ENUM_", type_id = "pk_authorize_enum_get_type ()")] - [GIR (name = "AuthorizeEnum")] - public enum Authorize { - UNKNOWN, - YES, - NO, - INTERACTIVE, - LAST; - public static Pk.Authorize type_enum_from_string (string authorize_type); - public static unowned string type_enum_to_string (Pk.Authorize authorize_type); - } - [CCode (cheader_filename = "packagekit-glib2/packagekit.h", cprefix = "PK_DISTRO_UPGRADE_ENUM_", type_id = "pk_distro_upgrade_enum_get_type ()")] - public enum DistroUpgradeEnum { - UNKNOWN, - STABLE, - UNSTABLE, - LAST; - public static Pk.DistroUpgradeEnum from_string (string upgrade); - public static unowned string to_string (Pk.DistroUpgradeEnum upgrade); - } - [CCode (cheader_filename = "packagekit-glib2/packagekit.h", cprefix = "PK_ERROR_ENUM_", type_id = "pk_error_enum_get_type ()")] - public enum ErrorEnum { - UNKNOWN, - OOM, - NO_NETWORK, - NOT_SUPPORTED, - INTERNAL_ERROR, - GPG_FAILURE, - PACKAGE_ID_INVALID, - PACKAGE_NOT_INSTALLED, - PACKAGE_NOT_FOUND, - PACKAGE_ALREADY_INSTALLED, - PACKAGE_DOWNLOAD_FAILED, - GROUP_NOT_FOUND, - GROUP_LIST_INVALID, - DEP_RESOLUTION_FAILED, - FILTER_INVALID, - CREATE_THREAD_FAILED, - TRANSACTION_ERROR, - TRANSACTION_CANCELLED, - NO_CACHE, - REPO_NOT_FOUND, - CANNOT_REMOVE_SYSTEM_PACKAGE, - PROCESS_KILL, - FAILED_INITIALIZATION, - FAILED_FINALISE, - FAILED_CONFIG_PARSING, - CANNOT_CANCEL, - CANNOT_GET_LOCK, - NO_PACKAGES_TO_UPDATE, - CANNOT_WRITE_REPO_CONFIG, - LOCAL_INSTALL_FAILED, - BAD_GPG_SIGNATURE, - MISSING_GPG_SIGNATURE, - CANNOT_INSTALL_SOURCE_PACKAGE, - REPO_CONFIGURATION_ERROR, - NO_LICENSE_AGREEMENT, - FILE_CONFLICTS, - PACKAGE_CONFLICTS, - REPO_NOT_AVAILABLE, - INVALID_PACKAGE_FILE, - PACKAGE_INSTALL_BLOCKED, - PACKAGE_CORRUPT, - ALL_PACKAGES_ALREADY_INSTALLED, - FILE_NOT_FOUND, - NO_MORE_MIRRORS_TO_TRY, - NO_DISTRO_UPGRADE_DATA, - INCOMPATIBLE_ARCHITECTURE, - NO_SPACE_ON_DEVICE, - MEDIA_CHANGE_REQUIRED, - NOT_AUTHORIZED, - UPDATE_NOT_FOUND, - CANNOT_INSTALL_REPO_UNSIGNED, - CANNOT_UPDATE_REPO_UNSIGNED, - CANNOT_GET_FILELIST, - CANNOT_GET_REQUIRES, - CANNOT_DISABLE_REPOSITORY, - RESTRICTED_DOWNLOAD, - PACKAGE_FAILED_TO_CONFIGURE, - PACKAGE_FAILED_TO_BUILD, - PACKAGE_FAILED_TO_INSTALL, - PACKAGE_FAILED_TO_REMOVE, - UPDATE_FAILED_DUE_TO_RUNNING_PROCESS, - PACKAGE_DATABASE_CHANGED, - PROVIDE_TYPE_NOT_SUPPORTED, - INSTALL_ROOT_INVALID, - CANNOT_FETCH_SOURCES, - CANCELLED_PRIORITY, - UNFINISHED_TRANSACTION, - LOCK_REQUIRED, - LAST; - public static Pk.ErrorEnum from_string (string code); - public static unowned string to_string (Pk.ErrorEnum code); - } - [CCode (cheader_filename = "packagekit-glib2/packagekit.h", cname = "PkExitEnum", cprefix = "PK_EXIT_ENUM_", type_id = "pk_exit_enum_get_type ()")] - [GIR (name = "ExitEnum")] - public enum Exit { - UNKNOWN, - SUCCESS, - FAILED, - CANCELLED, - KEY_REQUIRED, - EULA_REQUIRED, - KILLED, - MEDIA_CHANGE_REQUIRED, - NEED_UNTRUSTED, - CANCELLED_PRIORITY, - SKIP_TRANSACTION, - REPAIR_REQUIRED, - LAST; - public static Pk.Exit enum_from_string (string exit); - public static unowned string enum_to_string (Pk.Exit exit); - } - [CCode (cheader_filename = "packagekit-glib2/packagekit.h", cname = "PkFilterEnum", cprefix = "PK_FILTER_ENUM_", type_id = "pk_filter_enum_get_type ()")] - [GIR (name = "FilterEnum")] - public enum Filter { - UNKNOWN, - NONE, - INSTALLED, - NOT_INSTALLED, - DEVELOPMENT, - NOT_DEVELOPMENT, - GUI, - NOT_GUI, - FREE, - NOT_FREE, - VISIBLE, - NOT_VISIBLE, - SUPPORTED, - NOT_SUPPORTED, - BASENAME, - NOT_BASENAME, - NEWEST, - NOT_NEWEST, - ARCH, - NOT_ARCH, - SOURCE, - NOT_SOURCE, - COLLECTIONS, - NOT_COLLECTIONS, - APPLICATION, - NOT_APPLICATION, - DOWNLOADED, - NOT_DOWNLOADED, - LAST; - public static Pk.Bitfield bitfield_from_string (string filters); - public static string bitfield_to_string (Pk.Bitfield filters); - public static Pk.Filter enum_from_string (string filter); - public static unowned string enum_to_string (Pk.Filter filter); - } - [CCode (cheader_filename = "packagekit-glib2/packagekit.h", cname = "PkGroupEnum", cprefix = "PK_GROUP_ENUM_", type_id = "pk_group_enum_get_type ()")] - [GIR (name = "GroupEnum")] - public enum Group { - UNKNOWN, - ACCESSIBILITY, - ACCESSORIES, - ADMIN_TOOLS, - COMMUNICATION, - DESKTOP_GNOME, - DESKTOP_KDE, - DESKTOP_OTHER, - DESKTOP_XFCE, - EDUCATION, - FONTS, - GAMES, - GRAPHICS, - INTERNET, - LEGACY, - LOCALIZATION, - MAPS, - MULTIMEDIA, - NETWORK, - OFFICE, - OTHER, - POWER_MANAGEMENT, - PROGRAMMING, - PUBLISHING, - REPOS, - SECURITY, - SERVERS, - SYSTEM, - VIRTUALIZATION, - SCIENCE, - DOCUMENTATION, - ELECTRONICS, - COLLECTIONS, - VENDOR, - NEWEST, - LAST; - public static Pk.Bitfield bitfield_from_string (string groups); - public static string bitfield_to_string (Pk.Bitfield groups); - public static Pk.Group enum_from_string (string group); - public static unowned string enum_to_string (Pk.Group group); - } - [CCode (cheader_filename = "packagekit-glib2/packagekit.h", cname = "PkInfoEnum", cprefix = "PK_INFO_ENUM_", type_id = "pk_info_enum_get_type ()")] - [GIR (name = "InfoEnum")] - public enum Info { - UNKNOWN, - INSTALLED, - AVAILABLE, - LOW, - ENHANCEMENT, - NORMAL, - BUGFIX, - IMPORTANT, - SECURITY, - BLOCKED, - DOWNLOADING, - UPDATING, - INSTALLING, - REMOVING, - CLEANUP, - OBSOLETING, - COLLECTION_INSTALLED, - COLLECTION_AVAILABLE, - FINISHED, - REINSTALLING, - DOWNGRADING, - PREPARING, - DECOMPRESSING, - UNTRUSTED, - TRUSTED, - UNAVAILABLE, - LAST; - public static Pk.Info enum_from_string (string info); - public static unowned string enum_to_localised_past (Pk.Info info); - public static unowned string enum_to_localised_present (Pk.Info info); - public static unowned string enum_to_string (Pk.Info info); - } - [CCode (cheader_filename = "packagekit-glib2/packagekit.h", cname = "PkMediaTypeEnum", cprefix = "PK_MEDIA_TYPE_ENUM_", type_id = "pk_media_type_enum_get_type ()")] - [GIR (name = "MediaTypeEnum")] - public enum MediaType { - UNKNOWN, - CD, - DVD, - DISC, - LAST; - public static Pk.MediaType enum_from_string (string media_type); - public static unowned string enum_to_string (Pk.MediaType media_type); - } - [CCode (cheader_filename = "packagekit-glib2/packagekit.h", cname = "PkNetworkEnum", cprefix = "PK_NETWORK_ENUM_", type_id = "pk_network_enum_get_type ()")] - [GIR (name = "NetworkEnum")] - public enum Network { - UNKNOWN, - OFFLINE, - ONLINE, - WIRED, - WIFI, - MOBILE, - LAST; - public static Pk.Network enum_from_string (string network); - public static unowned string enum_to_string (Pk.Network network); - } - [CCode (cheader_filename = "packagekit-glib2/packagekit.h", cprefix = "PK_OFFLINE_ACTION_", type_id = "pk_offline_action_get_type ()")] - public enum OfflineAction { - UNKNOWN, - REBOOT, - POWER_OFF, - UNSET, - LAST; - public static Pk.OfflineAction from_string (string action); - public static unowned string to_string (Pk.OfflineAction action); - } - [CCode (cheader_filename = "packagekit-glib2/packagekit.h", cprefix = "PK_PACKAGE_SACK_SORT_TYPE_", type_id = "pk_package_sack_sort_type_get_type ()")] - public enum PackageSackSortType { - NAME, - INFO, - PACKAGE_ID, - SUMMARY, - LAST - } - [CCode (cheader_filename = "packagekit-glib2/packagekit.h", cprefix = "PK_PROGRESS_TYPE_", type_id = "pk_progress_type_get_type ()")] - public enum ProgressType { - PACKAGE_ID, - TRANSACTION_ID, - PERCENTAGE, - ALLOW_CANCEL, - STATUS, - ROLE, - CALLER_ACTIVE, - ELAPSED_TIME, - REMAINING_TIME, - SPEED, - DOWNLOAD_SIZE_REMAINING, - UID, - PACKAGE, - ITEM_PROGRESS, - TRANSACTION_FLAGS, - INVALID - } - [CCode (cheader_filename = "packagekit-glib2/packagekit.h", cname = "PkRestartEnum", cprefix = "PK_RESTART_ENUM_", type_id = "pk_restart_enum_get_type ()")] - [GIR (name = "RestartEnum")] - public enum Restart { - UNKNOWN, - NONE, - APPLICATION, - SESSION, - SYSTEM, - SECURITY_SESSION, - SECURITY_SYSTEM, - LAST; - public static Pk.Restart enum_from_string (string restart); - public static unowned string enum_to_string (Pk.Restart restart); - } - [CCode (cheader_filename = "packagekit-glib2/packagekit.h", cname = "PkRoleEnum", cprefix = "PK_ROLE_ENUM_", type_id = "pk_role_enum_get_type ()")] - [GIR (name = "RoleEnum")] - public enum Role { - UNKNOWN, - CANCEL, - DEPENDS_ON, - GET_DETAILS, - GET_FILES, - GET_PACKAGES, - GET_REPO_LIST, - REQUIRED_BY, - GET_UPDATE_DETAIL, - GET_UPDATES, - INSTALL_FILES, - INSTALL_PACKAGES, - INSTALL_SIGNATURE, - REFRESH_CACHE, - REMOVE_PACKAGES, - REPO_ENABLE, - REPO_SET_DATA, - RESOLVE, - SEARCH_DETAILS, - SEARCH_FILE, - SEARCH_GROUP, - SEARCH_NAME, - UPDATE_PACKAGES, - WHAT_PROVIDES, - ACCEPT_EULA, - DOWNLOAD_PACKAGES, - GET_DISTRO_UPGRADES, - GET_CATEGORIES, - GET_OLD_TRANSACTIONS, - REPAIR_SYSTEM, - GET_DETAILS_LOCAL, - GET_FILES_LOCAL, - REPO_REMOVE, - LAST; - public static Pk.Bitfield bitfield_from_string (string roles); - public static string bitfield_to_string (Pk.Bitfield roles); - public static Pk.Role enum_from_string (string role); - public static unowned string enum_to_localised_present (Pk.Role role); - public static unowned string enum_to_string (Pk.Role role); - } - [CCode (cheader_filename = "packagekit-glib2/packagekit.h", cname = "PkSigTypeEnum", cprefix = "PK_SIGTYPE_ENUM_", type_id = "pk_sig_type_enum_get_type ()")] - [GIR (name = "SigTypeEnum")] - public enum SigType { - UNKNOWN, - GPG, - LAST; - public static Pk.SigType enum_from_string (string sig_type); - public static unowned string enum_to_string (Pk.SigType sig_type); - } - [CCode (cheader_filename = "packagekit-glib2/packagekit.h", cname = "PkStatusEnum", cprefix = "PK_STATUS_ENUM_", type_id = "pk_status_enum_get_type ()")] - [GIR (name = "StatusEnum")] - public enum Status { - UNKNOWN, - WAIT, - SETUP, - RUNNING, - QUERY, - INFO, - REMOVE, - REFRESH_CACHE, - DOWNLOAD, - INSTALL, - UPDATE, - CLEANUP, - OBSOLETE, - DEP_RESOLVE, - SIG_CHECK, - TEST_COMMIT, - COMMIT, - REQUEST, - FINISHED, - CANCEL, - DOWNLOAD_REPOSITORY, - DOWNLOAD_PACKAGELIST, - DOWNLOAD_FILELIST, - DOWNLOAD_CHANGELOG, - DOWNLOAD_GROUP, - DOWNLOAD_UPDATEINFO, - REPACKAGING, - LOADING_CACHE, - SCAN_APPLICATIONS, - GENERATE_PACKAGE_LIST, - WAITING_FOR_LOCK, - WAITING_FOR_AUTH, - SCAN_PROCESS_LIST, - CHECK_EXECUTABLE_FILES, - CHECK_LIBRARIES, - COPY_FILES, - LAST; - public static Pk.Status enum_from_string (string status); - public static unowned string enum_to_localised_text (Pk.Status status); - public static unowned string enum_to_string (Pk.Status status); - } - [CCode (cheader_filename = "packagekit-glib2/packagekit.h", cname = "PkTransactionFlagEnum", cprefix = "PK_TRANSACTION_FLAG_ENUM_", type_id = "pk_transaction_flag_enum_get_type ()")] - [GIR (name = "TransactionFlagEnum")] - public enum TransactionFlag { - NONE, - ONLY_TRUSTED, - SIMULATE, - ONLY_DOWNLOAD, - ALLOW_REINSTALL, - JUST_REINSTALL, - ALLOW_DOWNGRADE, - LAST; - public static Pk.Bitfield bitfield_from_string (string transaction_flags); - public static string bitfield_to_string (Pk.Bitfield transaction_flags); - public static Pk.TransactionFlag enum_from_string (string transaction_flag); - public static unowned string enum_to_string (Pk.TransactionFlag transaction_flag); - } - [CCode (cheader_filename = "packagekit-glib2/packagekit.h", cname = "PkUpdateStateEnum", cprefix = "PK_UPDATE_STATE_ENUM_", type_id = "pk_update_state_enum_get_type ()")] - [GIR (name = "UpdateStateEnum")] - public enum UpdateState { - UNKNOWN, - STABLE, - UNSTABLE, - TESTING, - LAST; - public static Pk.UpdateState enum_from_string (string update_state); - public static unowned string enum_to_string (Pk.UpdateState update_state); - } - [CCode (cheader_filename = "packagekit-glib2/packagekit.h", cname = "PkUpgradeKindEnum", cprefix = "PK_UPGRADE_KIND_ENUM_", type_id = "pk_upgrade_kind_enum_get_type ()")] - [GIR (name = "UpgradeKindEnum")] - public enum UpgradeKind { - UNKNOWN, - MINIMAL, - DEFAULT, - COMPLETE, - LAST; - public static Pk.UpgradeKind enum_from_string (string upgrade_kind); - public static unowned string enum_to_string (Pk.UpgradeKind upgrade_kind); - } - [CCode (cheader_filename = "packagekit-glib2/packagekit.h", cprefix = "PK_CLIENT_ERROR_")] - public errordomain ClientError { - FAILED, - FAILED_AUTH, - NO_TID, - ALREADY_TID, - ROLE_UNKNOWN, - CANNOT_START_DAEMON, - INVALID_INPUT, - INVALID_FILE, - NOT_SUPPORTED, - DECLINED_SIMULATION, - LAST; - public static GLib.Quark quark (); - } - [CCode (cheader_filename = "packagekit-glib2/packagekit.h", cprefix = "PK_CONTROL_ERROR_")] - public errordomain ControlError { - FAILED, - CANNOT_START_DAEMON; - public static GLib.Quark quark (); - } - [CCode (cheader_filename = "packagekit-glib2/packagekit.h", cprefix = "PK_OFFLINE_ERROR_")] - public errordomain OfflineError { - FAILED, - INVALID_VALUE, - NO_DATA, - LAST; - public static GLib.Quark quark (); - } - [CCode (cheader_filename = "packagekit-glib2/packagekit.h", instance_pos = 1.9)] - public delegate bool PackageSackFilterFunc (Pk.Package package); - [CCode (cheader_filename = "packagekit-glib2/packagekit.h", instance_pos = 2.9)] - public delegate void ProgressCallback (Pk.Progress progress, Pk.ProgressType type); - [CCode (cheader_filename = "packagekit-glib2/packagekit.h", cname = "PK_DBUS_INTERFACE")] - public const string DBUS_INTERFACE; - [CCode (cheader_filename = "packagekit-glib2/packagekit.h", cname = "PK_DBUS_INTERFACE_OFFLINE")] - public const string DBUS_INTERFACE_OFFLINE; - [CCode (cheader_filename = "packagekit-glib2/packagekit.h", cname = "PK_DBUS_INTERFACE_TRANSACTION")] - public const string DBUS_INTERFACE_TRANSACTION; - [CCode (cheader_filename = "packagekit-glib2/packagekit.h", cname = "PK_DBUS_PATH")] - public const string DBUS_PATH; - [CCode (cheader_filename = "packagekit-glib2/packagekit.h", cname = "PK_DBUS_SERVICE")] - public const string DBUS_SERVICE; - [CCode (cheader_filename = "packagekit-glib2/packagekit.h", cname = "PK_DESKTOP_DEFAULT_APPLICATION_DIR")] - public const string DESKTOP_DEFAULT_APPLICATION_DIR; - [CCode (cheader_filename = "packagekit-glib2/packagekit.h", cname = "PK_MAJOR_VERSION")] - public const int MAJOR_VERSION; - [CCode (cheader_filename = "packagekit-glib2/packagekit.h", cname = "PK_MICRO_VERSION")] - public const int MICRO_VERSION; - [CCode (cheader_filename = "packagekit-glib2/packagekit.h", cname = "PK_MINOR_VERSION")] - public const int MINOR_VERSION; - [CCode (cheader_filename = "packagekit-glib2/packagekit.h", cname = "PK_OFFLINE_DESTDIR")] - public const string OFFLINE_DESTDIR; - [CCode (cheader_filename = "packagekit-glib2/packagekit.h", cname = "PK_OFFLINE_RESULTS_GROUP")] - public const string OFFLINE_RESULTS_GROUP; - [CCode (cheader_filename = "packagekit-glib2/packagekit.h", cname = "PK_PACKAGE_IDS_DELIM")] - public const string PACKAGE_IDS_DELIM; - [CCode (cheader_filename = "packagekit-glib2/packagekit.h", cname = "PK_PACKAGE_ID_ARCH")] - public const int PACKAGE_ID_ARCH; - [CCode (cheader_filename = "packagekit-glib2/packagekit.h", cname = "PK_PACKAGE_ID_DATA")] - public const int PACKAGE_ID_DATA; - [CCode (cheader_filename = "packagekit-glib2/packagekit.h", cname = "PK_PACKAGE_ID_NAME")] - public const int PACKAGE_ID_NAME; - [CCode (cheader_filename = "packagekit-glib2/packagekit.h", cname = "PK_PACKAGE_ID_VERSION")] - public const int PACKAGE_ID_VERSION; - [CCode (cheader_filename = "packagekit-glib2/packagekit.h", cname = "PK_SYSTEM_PACKAGE_CACHE_FILENAME")] - public const string SYSTEM_PACKAGE_CACHE_FILENAME; - [CCode (cheader_filename = "packagekit-glib2/packagekit.h", cname = "PK_SYSTEM_PACKAGE_LIST_FILENAME")] - public const string SYSTEM_PACKAGE_LIST_FILENAME; - [CCode (cheader_filename = "packagekit-glib2/packagekit.h")] - public static void common_test (void* user_data); - [CCode (cheader_filename = "packagekit-glib2/packagekit.h")] - public static void debug_add_log_domain (string log_domain); - [CCode (cheader_filename = "packagekit-glib2/packagekit.h")] - public static bool debug_is_verbose (); - [CCode (cheader_filename = "packagekit-glib2/packagekit.h")] - public static void debug_set_verbose (bool verbose); - [CCode (cheader_filename = "packagekit-glib2/packagekit.h")] - public static unowned string enum_find_string (Pk.EnumMatch table, uint value); - [CCode (cheader_filename = "packagekit-glib2/packagekit.h")] - public static uint enum_find_value (Pk.EnumMatch table, string string); - [CCode (cheader_filename = "packagekit-glib2/packagekit.h")] - public static void enum_test (void* user_data); - [CCode (cheader_filename = "packagekit-glib2/packagekit.h")] - public static string get_distro_id (); - [CCode (cheader_filename = "packagekit-glib2/packagekit.h")] - public static string iso8601_from_date (GLib.Date date); - [CCode (cheader_filename = "packagekit-glib2/packagekit.h")] - public static string iso8601_present (); - [CCode (cheader_filename = "packagekit-glib2/packagekit.h")] - public static bool offline_auth_cancel () throws GLib.Error; - [CCode (cheader_filename = "packagekit-glib2/packagekit.h")] - public static bool offline_auth_clear_results () throws GLib.Error; - [CCode (cheader_filename = "packagekit-glib2/packagekit.h")] - public static bool offline_auth_invalidate () throws GLib.Error; - [CCode (cheader_filename = "packagekit-glib2/packagekit.h")] - public static bool offline_auth_set_action (Pk.OfflineAction action) throws GLib.Error; - [CCode (cheader_filename = "packagekit-glib2/packagekit.h")] - public static bool offline_auth_set_prepared_ids (string package_ids) throws GLib.Error; - [CCode (cheader_filename = "packagekit-glib2/packagekit.h")] - public static bool offline_auth_set_results (Pk.Results results) throws GLib.Error; - [CCode (cheader_filename = "packagekit-glib2/packagekit.h")] - public static bool offline_auth_trigger (Pk.OfflineAction action) throws GLib.Error; - [CCode (cheader_filename = "packagekit-glib2/packagekit.h")] - public static bool offline_cancel (GLib.Cancellable? cancellable = null) throws GLib.Error; - [CCode (cheader_filename = "packagekit-glib2/packagekit.h")] - public static bool offline_clear_results (GLib.Cancellable? cancellable = null) throws GLib.Error; - [CCode (cheader_filename = "packagekit-glib2/packagekit.h")] - public static Pk.OfflineAction offline_get_action () throws GLib.Error; - [CCode (cheader_filename = "packagekit-glib2/packagekit.h")] - public static GLib.FileMonitor offline_get_action_monitor (GLib.Cancellable? cancellable = null) throws GLib.Error; - [CCode (array_length = false, array_null_terminated = true, cheader_filename = "packagekit-glib2/packagekit.h")] - public static string[] offline_get_prepared_ids () throws GLib.Error; - [CCode (cheader_filename = "packagekit-glib2/packagekit.h")] - public static GLib.FileMonitor offline_get_prepared_monitor (GLib.Cancellable? cancellable = null) throws GLib.Error; - [CCode (cheader_filename = "packagekit-glib2/packagekit.h")] - public static Pk.PackageSack offline_get_prepared_sack () throws GLib.Error; - [CCode (cheader_filename = "packagekit-glib2/packagekit.h")] - public static Pk.Results offline_get_results () throws GLib.Error; - [CCode (cheader_filename = "packagekit-glib2/packagekit.h")] - public static uint64 offline_get_results_mtime () throws GLib.Error; - [CCode (cheader_filename = "packagekit-glib2/packagekit.h")] - public static bool offline_trigger (Pk.OfflineAction action, GLib.Cancellable? cancellable = null) throws GLib.Error; - [CCode (cheader_filename = "packagekit-glib2/packagekit.h")] - public static void polkit_agent_close (); - [CCode (cheader_filename = "packagekit-glib2/packagekit.h")] - public static int polkit_agent_open (); - [CCode (array_length = false, array_null_terminated = true, cheader_filename = "packagekit-glib2/packagekit.h")] - public static string[] ptr_array_to_strv (GLib.GenericArray array); -} diff --git a/src/page-view.c b/src/page-view.c deleted file mode 100644 index 96732cc..0000000 --- a/src/page-view.c +++ /dev/null @@ -1,6912 +0,0 @@ -/* page-view.c generated by valac 0.34.6, the Vala compiler - * generated from page-view.vala, do not modify */ - -/* - * Copyright (C) 2009-2015 Canonical Ltd. - * Author: Robert Ancell - * - * This program is free software: you can redistribute it and/or modify it under - * the terms of the GNU General Public License as published by the Free Software - * Foundation, either version 3 of the License, or (at your option) any later - * version. See http://www.gnu.org/copyleft/gpl.html the full text of the - * license. - */ - -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include - - -#define TYPE_CROP_LOCATION (crop_location_get_type ()) - -#define TYPE_PAGE_VIEW (page_view_get_type ()) -#define PAGE_VIEW(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), TYPE_PAGE_VIEW, PageView)) -#define PAGE_VIEW_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST ((klass), TYPE_PAGE_VIEW, PageViewClass)) -#define IS_PAGE_VIEW(obj) (G_TYPE_CHECK_INSTANCE_TYPE ((obj), TYPE_PAGE_VIEW)) -#define IS_PAGE_VIEW_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE ((klass), TYPE_PAGE_VIEW)) -#define PAGE_VIEW_GET_CLASS(obj) (G_TYPE_INSTANCE_GET_CLASS ((obj), TYPE_PAGE_VIEW, PageViewClass)) - -typedef struct _PageView PageView; -typedef struct _PageViewClass PageViewClass; -typedef struct _PageViewPrivate PageViewPrivate; - -#define TYPE_PAGE (page_get_type ()) -#define PAGE(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), TYPE_PAGE, Page)) -#define PAGE_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST ((klass), TYPE_PAGE, PageClass)) -#define IS_PAGE(obj) (G_TYPE_CHECK_INSTANCE_TYPE ((obj), TYPE_PAGE)) -#define IS_PAGE_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE ((klass), TYPE_PAGE)) -#define PAGE_GET_CLASS(obj) (G_TYPE_INSTANCE_GET_CLASS ((obj), TYPE_PAGE, PageClass)) - -typedef struct _Page Page; -typedef struct _PageClass PageClass; - -#define TYPE_SCAN_DIRECTION (scan_direction_get_type ()) -#define _page_unref0(var) ((var == NULL) ? NULL : (var = (page_unref (var), NULL))) -#define _g_object_unref0(var) ((var == NULL) ? NULL : (var = (g_object_unref (var), NULL))) -#define _g_free0(var) (var = (g_free (var), NULL)) -typedef struct _ParamSpecPageView ParamSpecPageView; - -typedef enum { - CROP_LOCATION_NONE = 0, - CROP_LOCATION_MIDDLE, - CROP_LOCATION_TOP, - CROP_LOCATION_BOTTOM, - CROP_LOCATION_LEFT, - CROP_LOCATION_RIGHT, - CROP_LOCATION_TOP_LEFT, - CROP_LOCATION_TOP_RIGHT, - CROP_LOCATION_BOTTOM_LEFT, - CROP_LOCATION_BOTTOM_RIGHT -} CropLocation; - -struct _PageView { - GTypeInstance parent_instance; - volatile int ref_count; - PageViewPrivate * priv; -}; - -struct _PageViewClass { - GTypeClass parent_class; - void (*finalize) (PageView *self); -}; - -typedef enum { - SCAN_DIRECTION_TOP_TO_BOTTOM, - SCAN_DIRECTION_LEFT_TO_RIGHT, - SCAN_DIRECTION_BOTTOM_TO_TOP, - SCAN_DIRECTION_RIGHT_TO_LEFT -} ScanDirection; - -struct _PageViewPrivate { - Page* _page; - GdkPixbuf* image; - gboolean selected_; - gint border_width; - gboolean update_image; - ScanDirection scan_direction; - gint scan_line; - gint width_; - gint height_; - gint _x_offset; - gint _y_offset; - CropLocation crop_location; - gdouble selected_crop_px; - gdouble selected_crop_py; - gint selected_crop_x; - gint selected_crop_y; - gint selected_crop_w; - gint selected_crop_h; - GdkCursorType _cursor; - gint animate_n_segments; - gint animate_segment; - guint animate_timeout; -}; - -struct _ParamSpecPageView { - GParamSpec parent_instance; -}; - - -static gpointer page_view_parent_class = NULL; - -GType crop_location_get_type (void) G_GNUC_CONST; -gpointer page_view_ref (gpointer instance); -void page_view_unref (gpointer instance); -GParamSpec* param_spec_page_view (const gchar* name, const gchar* nick, const gchar* blurb, GType object_type, GParamFlags flags); -void value_set_page_view (GValue* value, gpointer v_object); -void value_take_page_view (GValue* value, gpointer v_object); -gpointer value_get_page_view (const GValue* value); -GType page_view_get_type (void) G_GNUC_CONST; -gpointer page_ref (gpointer instance); -void page_unref (gpointer instance); -GParamSpec* param_spec_page (const gchar* name, const gchar* nick, const gchar* blurb, GType object_type, GParamFlags flags); -void value_set_page (GValue* value, gpointer v_object); -void value_take_page (GValue* value, gpointer v_object); -gpointer value_get_page (const GValue* value); -GType page_get_type (void) G_GNUC_CONST; -GType scan_direction_get_type (void) G_GNUC_CONST; -#define PAGE_VIEW_GET_PRIVATE(o) (G_TYPE_INSTANCE_GET_PRIVATE ((o), TYPE_PAGE_VIEW, PageViewPrivate)) -enum { - PAGE_VIEW_DUMMY_PROPERTY -}; -Page* page_view_get_page (PageView* self); -static void page_view_page_pixels_changed_cb (PageView* self, Page* p); -static void _page_view_page_pixels_changed_cb_page_pixels_changed (Page* _sender, gpointer self); -static void page_view_page_size_changed_cb (PageView* self, Page* p); -static void _page_view_page_size_changed_cb_page_size_changed (Page* _sender, gpointer self); -static void page_view_page_overlay_changed_cb (PageView* self, Page* p); -static void _page_view_page_overlay_changed_cb_page_crop_changed (Page* _sender, gpointer self); -static void _page_view_page_overlay_changed_cb_page_scan_line_changed (Page* _sender, gpointer self); -static void page_view_scan_direction_changed_cb (PageView* self, Page* p); -static void _page_view_scan_direction_changed_cb_page_scan_direction_changed (Page* _sender, gpointer self); -PageView* page_view_new (Page* page); -PageView* page_view_construct (GType object_type, Page* page); -static void page_view_set_page (PageView* self, Page* value); -static guchar page_view_get_sample (PageView* self, guchar* pixels, int pixels_length1, gint offset, gint x, gint depth, gint sample); -static void page_view_get_pixel (PageView* self, Page* page, gint x, gint y, guchar* pixel, int pixel_length1); -ScanDirection page_get_scan_direction (Page* self); -gint page_get_scan_width (Page* self); -gint page_get_scan_height (Page* self); -gint page_get_depth (Page* self); -gint page_get_n_channels (Page* self); -guchar* page_get_pixels (Page* self, int* result_length1); -gint page_get_rowstride (Page* self); -static void page_view_set_pixel (PageView* self, Page* page, gdouble l, gdouble r, gdouble t, gdouble b, guchar* output, int output_length1, gint offset); -static void page_view_update_preview (PageView* self, Page* page, GdkPixbuf** output_image, gint output_width, gint output_height, ScanDirection scan_direction, gint old_scan_line, gint scan_line); -gint page_get_width (Page* self); -gint page_get_height (Page* self); -gboolean page_get_has_data (Page* self); -static gint page_view_get_preview_width (PageView* self); -static gint page_view_get_preview_height (PageView* self); -static void page_view_update_page_view (PageView* self); -gint page_get_scan_line (Page* self); -static gint page_view_page_to_screen_x (PageView* self, gint x); -static gint page_view_page_to_screen_y (PageView* self, gint y); -static gint page_view_screen_to_page_x (PageView* self, gint x); -static gint page_view_screen_to_page_y (PageView* self, gint y); -static CropLocation page_view_get_crop_location (PageView* self, gint x, gint y); -gboolean page_get_has_crop (Page* self); -gint page_get_crop_x (Page* self); -gint page_get_crop_y (Page* self); -gint page_get_crop_width (Page* self); -gint page_get_crop_height (Page* self); -const gchar* page_get_crop_name (Page* self); -void page_view_button_press (PageView* self, gint x, gint y); -void page_view_motion (PageView* self, gint x, gint y); -static void page_view_set_cursor (PageView* self, GdkCursorType value); -void page_move_crop (Page* self, gint x, gint y); -void page_set_custom_crop (Page* self, gint width, gint height); -void page_view_button_release (PageView* self, gint x, gint y); -static gboolean page_view_animation_cb (PageView* self); -static void page_view_update_animation (PageView* self); -gboolean page_get_is_scanning (Page* self); -static gboolean _page_view_animation_cb_gsource_func (gpointer self); -void page_view_render (PageView* self, cairo_t* context); -gint page_view_get_x_offset (PageView* self); -gint page_view_get_y_offset (PageView* self); -gboolean page_view_get_selected (PageView* self); -void page_view_set_selected (PageView* self, gboolean value); -void page_view_set_x_offset (PageView* self, gint value); -void page_view_set_y_offset (PageView* self, gint value); -GdkCursorType page_view_get_cursor (PageView* self); -gint page_view_get_width (PageView* self); -void page_view_set_width (PageView* self, gint value); -gint page_view_get_height (PageView* self); -void page_view_set_height (PageView* self, gint value); -static void page_view_finalize (PageView* obj); - - -GType crop_location_get_type (void) { - static volatile gsize crop_location_type_id__volatile = 0; - if (g_once_init_enter (&crop_location_type_id__volatile)) { - static const GEnumValue values[] = {{CROP_LOCATION_NONE, "CROP_LOCATION_NONE", "none"}, {CROP_LOCATION_MIDDLE, "CROP_LOCATION_MIDDLE", "middle"}, {CROP_LOCATION_TOP, "CROP_LOCATION_TOP", "top"}, {CROP_LOCATION_BOTTOM, "CROP_LOCATION_BOTTOM", "bottom"}, {CROP_LOCATION_LEFT, "CROP_LOCATION_LEFT", "left"}, {CROP_LOCATION_RIGHT, "CROP_LOCATION_RIGHT", "right"}, {CROP_LOCATION_TOP_LEFT, "CROP_LOCATION_TOP_LEFT", "top-left"}, {CROP_LOCATION_TOP_RIGHT, "CROP_LOCATION_TOP_RIGHT", "top-right"}, {CROP_LOCATION_BOTTOM_LEFT, "CROP_LOCATION_BOTTOM_LEFT", "bottom-left"}, {CROP_LOCATION_BOTTOM_RIGHT, "CROP_LOCATION_BOTTOM_RIGHT", "bottom-right"}, {0, NULL, NULL}}; - GType crop_location_type_id; - crop_location_type_id = g_enum_register_static ("CropLocation", values); - g_once_init_leave (&crop_location_type_id__volatile, crop_location_type_id); - } - return crop_location_type_id__volatile; -} - - -static void _page_view_page_pixels_changed_cb_page_pixels_changed (Page* _sender, gpointer self) { -#line 97 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - page_view_page_pixels_changed_cb ((PageView*) self, _sender); -#line 222 "page-view.c" -} - - -static void _page_view_page_size_changed_cb_page_size_changed (Page* _sender, gpointer self) { -#line 98 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - page_view_page_size_changed_cb ((PageView*) self, _sender); -#line 229 "page-view.c" -} - - -static void _page_view_page_overlay_changed_cb_page_crop_changed (Page* _sender, gpointer self) { -#line 99 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - page_view_page_overlay_changed_cb ((PageView*) self, _sender); -#line 236 "page-view.c" -} - - -static void _page_view_page_overlay_changed_cb_page_scan_line_changed (Page* _sender, gpointer self) { -#line 100 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - page_view_page_overlay_changed_cb ((PageView*) self, _sender); -#line 243 "page-view.c" -} - - -static void _page_view_scan_direction_changed_cb_page_scan_direction_changed (Page* _sender, gpointer self) { -#line 101 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - page_view_scan_direction_changed_cb ((PageView*) self, _sender); -#line 250 "page-view.c" -} - - -PageView* page_view_construct (GType object_type, Page* page) { - PageView* self = NULL; - Page* _tmp0_ = NULL; - Page* _tmp1_ = NULL; - Page* _tmp2_ = NULL; - Page* _tmp3_ = NULL; - Page* _tmp4_ = NULL; - Page* _tmp5_ = NULL; -#line 85 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - g_return_val_if_fail (page != NULL, NULL); -#line 85 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - self = (PageView*) g_type_create_instance (object_type); -#line 87 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp0_ = page; -#line 87 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - page_view_set_page (self, _tmp0_); -#line 88 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp1_ = page; -#line 88 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - g_signal_connect (_tmp1_, "pixels-changed", (GCallback) _page_view_page_pixels_changed_cb_page_pixels_changed, self); -#line 89 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp2_ = page; -#line 89 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - g_signal_connect (_tmp2_, "size-changed", (GCallback) _page_view_page_size_changed_cb_page_size_changed, self); -#line 90 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp3_ = page; -#line 90 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - g_signal_connect (_tmp3_, "crop-changed", (GCallback) _page_view_page_overlay_changed_cb_page_crop_changed, self); -#line 91 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp4_ = page; -#line 91 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - g_signal_connect (_tmp4_, "scan-line-changed", (GCallback) _page_view_page_overlay_changed_cb_page_scan_line_changed, self); -#line 92 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp5_ = page; -#line 92 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - g_signal_connect (_tmp5_, "scan-direction-changed", (GCallback) _page_view_scan_direction_changed_cb_page_scan_direction_changed, self); -#line 85 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - return self; -#line 292 "page-view.c" -} - - -PageView* page_view_new (Page* page) { -#line 85 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - return page_view_construct (TYPE_PAGE_VIEW, page); -#line 299 "page-view.c" -} - - -static guchar page_view_get_sample (PageView* self, guchar* pixels, int pixels_length1, gint offset, gint x, gint depth, gint sample) { - guchar result = '\0'; -#line 104 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - g_return_val_if_fail (self != NULL, '\0'); -#line 107 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - result = (guchar) 0xFF; -#line 107 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - return result; -#line 311 "page-view.c" -} - - -static void page_view_get_pixel (PageView* self, Page* page, gint x, gint y, guchar* pixel, int pixel_length1) { - Page* _tmp0_ = NULL; - ScanDirection _tmp1_ = 0; - ScanDirection _tmp2_ = 0; - gint depth = 0; - Page* _tmp23_ = NULL; - gint _tmp24_ = 0; - gint _tmp25_ = 0; - gint n_channels = 0; - Page* _tmp26_ = NULL; - gint _tmp27_ = 0; - gint _tmp28_ = 0; - guchar* pixels = NULL; - Page* _tmp29_ = NULL; - gint _tmp30_ = 0; - guchar* _tmp31_ = NULL; - gint pixels_length1 = 0; - gint _pixels_size_ = 0; - gint offset = 0; - Page* _tmp32_ = NULL; - gint _tmp33_ = 0; - gint _tmp34_ = 0; - gint _tmp35_ = 0; - gboolean _tmp36_ = FALSE; - gint _tmp37_ = 0; - guchar* _tmp105_ = NULL; - gint _tmp105__length1 = 0; - guchar* _tmp106_ = NULL; - gint _tmp106__length1 = 0; - gint _tmp107_ = 0; - gint _tmp108_ = 0; - gint _tmp109_ = 0; - gint _tmp110_ = 0; - gint _tmp111_ = 0; - guchar _tmp112_ = '\0'; - guchar _tmp113_ = '\0'; - guchar* _tmp114_ = NULL; - gint _tmp114__length1 = 0; - guchar* _tmp115_ = NULL; - gint _tmp115__length1 = 0; - gint _tmp116_ = 0; - gint _tmp117_ = 0; - gint _tmp118_ = 0; - gint _tmp119_ = 0; - gint _tmp120_ = 0; - guchar _tmp121_ = '\0'; - guchar _tmp122_ = '\0'; - guchar* _tmp123_ = NULL; - gint _tmp123__length1 = 0; - guchar* _tmp124_ = NULL; - gint _tmp124__length1 = 0; - gint _tmp125_ = 0; - gint _tmp126_ = 0; - gint _tmp127_ = 0; - gint _tmp128_ = 0; - gint _tmp129_ = 0; - guchar _tmp130_ = '\0'; - guchar _tmp131_ = '\0'; -#line 110 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - g_return_if_fail (self != NULL); -#line 110 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - g_return_if_fail (page != NULL); -#line 112 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp0_ = page; -#line 112 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp1_ = page_get_scan_direction (_tmp0_); -#line 112 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp2_ = _tmp1_; -#line 112 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - switch (_tmp2_) { -#line 112 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - case SCAN_DIRECTION_TOP_TO_BOTTOM: -#line 387 "page-view.c" - { -#line 115 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - break; -#line 391 "page-view.c" - } -#line 112 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - case SCAN_DIRECTION_BOTTOM_TO_TOP: -#line 395 "page-view.c" - { - Page* _tmp3_ = NULL; - gint _tmp4_ = 0; - gint _tmp5_ = 0; - gint _tmp6_ = 0; - Page* _tmp7_ = NULL; - gint _tmp8_ = 0; - gint _tmp9_ = 0; - gint _tmp10_ = 0; -#line 117 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp3_ = page; -#line 117 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp4_ = page_get_scan_width (_tmp3_); -#line 117 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp5_ = _tmp4_; -#line 117 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp6_ = x; -#line 117 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - x = (_tmp5_ - _tmp6_) - 1; -#line 118 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp7_ = page; -#line 118 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp8_ = page_get_scan_height (_tmp7_); -#line 118 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp9_ = _tmp8_; -#line 118 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp10_ = y; -#line 118 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - y = (_tmp9_ - _tmp10_) - 1; -#line 119 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - break; -#line 427 "page-view.c" - } -#line 112 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - case SCAN_DIRECTION_LEFT_TO_RIGHT: -#line 431 "page-view.c" - { - gint t = 0; - gint _tmp11_ = 0; - Page* _tmp12_ = NULL; - gint _tmp13_ = 0; - gint _tmp14_ = 0; - gint _tmp15_ = 0; - gint _tmp16_ = 0; -#line 121 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp11_ = x; -#line 121 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - t = _tmp11_; -#line 122 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp12_ = page; -#line 122 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp13_ = page_get_scan_width (_tmp12_); -#line 122 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp14_ = _tmp13_; -#line 122 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp15_ = y; -#line 122 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - x = (_tmp14_ - _tmp15_) - 1; -#line 123 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp16_ = t; -#line 123 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - y = _tmp16_; -#line 124 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - break; -#line 460 "page-view.c" - } -#line 112 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - case SCAN_DIRECTION_RIGHT_TO_LEFT: -#line 464 "page-view.c" - { - gint t = 0; - gint _tmp17_ = 0; - gint _tmp18_ = 0; - Page* _tmp19_ = NULL; - gint _tmp20_ = 0; - gint _tmp21_ = 0; - gint _tmp22_ = 0; -#line 126 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp17_ = x; -#line 126 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - t = _tmp17_; -#line 127 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp18_ = y; -#line 127 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - x = _tmp18_; -#line 128 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp19_ = page; -#line 128 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp20_ = page_get_scan_height (_tmp19_); -#line 128 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp21_ = _tmp20_; -#line 128 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp22_ = t; -#line 128 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - y = (_tmp21_ - _tmp22_) - 1; -#line 129 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - break; -#line 493 "page-view.c" - } - default: -#line 112 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - break; -#line 498 "page-view.c" - } -#line 132 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp23_ = page; -#line 132 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp24_ = page_get_depth (_tmp23_); -#line 132 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp25_ = _tmp24_; -#line 132 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - depth = _tmp25_; -#line 133 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp26_ = page; -#line 133 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp27_ = page_get_n_channels (_tmp26_); -#line 133 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp28_ = _tmp27_; -#line 133 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - n_channels = _tmp28_; -#line 134 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp29_ = page; -#line 134 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp31_ = page_get_pixels (_tmp29_, &_tmp30_); -#line 134 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - pixels = _tmp31_; -#line 134 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - pixels_length1 = _tmp30_; -#line 134 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _pixels_size_ = pixels_length1; -#line 135 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp32_ = page; -#line 135 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp33_ = page_get_rowstride (_tmp32_); -#line 135 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp34_ = _tmp33_; -#line 135 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp35_ = y; -#line 135 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - offset = _tmp34_ * _tmp35_; -#line 138 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp37_ = depth; -#line 138 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - if (_tmp37_ == 8) { -#line 540 "page-view.c" - gint _tmp38_ = 0; -#line 138 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp38_ = n_channels; -#line 138 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp36_ = _tmp38_ == 3; -#line 546 "page-view.c" - } else { -#line 138 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp36_ = FALSE; -#line 550 "page-view.c" - } -#line 138 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - if (_tmp36_) { -#line 554 "page-view.c" - gint o = 0; - gint _tmp39_ = 0; - gint _tmp40_ = 0; - gint _tmp41_ = 0; - guchar* _tmp42_ = NULL; - gint _tmp42__length1 = 0; - guchar* _tmp43_ = NULL; - gint _tmp43__length1 = 0; - gint _tmp44_ = 0; - guchar _tmp45_ = '\0'; - guchar _tmp46_ = '\0'; - guchar* _tmp47_ = NULL; - gint _tmp47__length1 = 0; - guchar* _tmp48_ = NULL; - gint _tmp48__length1 = 0; - gint _tmp49_ = 0; - guchar _tmp50_ = '\0'; - guchar _tmp51_ = '\0'; - guchar* _tmp52_ = NULL; - gint _tmp52__length1 = 0; - guchar* _tmp53_ = NULL; - gint _tmp53__length1 = 0; - gint _tmp54_ = 0; - guchar _tmp55_ = '\0'; - guchar _tmp56_ = '\0'; -#line 140 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp39_ = offset; -#line 140 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp40_ = x; -#line 140 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp41_ = n_channels; -#line 140 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - o = _tmp39_ + (_tmp40_ * _tmp41_); -#line 141 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp42_ = pixel; -#line 141 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp42__length1 = pixel_length1; -#line 141 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp43_ = pixels; -#line 141 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp43__length1 = pixels_length1; -#line 141 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp44_ = o; -#line 141 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp45_ = _tmp43_[_tmp44_]; -#line 141 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp42_[0] = _tmp45_; -#line 141 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp46_ = _tmp42_[0]; -#line 142 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp47_ = pixel; -#line 142 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp47__length1 = pixel_length1; -#line 142 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp48_ = pixels; -#line 142 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp48__length1 = pixels_length1; -#line 142 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp49_ = o; -#line 142 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp50_ = _tmp48_[_tmp49_ + 1]; -#line 142 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp47_[1] = _tmp50_; -#line 142 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp51_ = _tmp47_[1]; -#line 143 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp52_ = pixel; -#line 143 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp52__length1 = pixel_length1; -#line 143 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp53_ = pixels; -#line 143 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp53__length1 = pixels_length1; -#line 143 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp54_ = o; -#line 143 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp55_ = _tmp53_[_tmp54_ + 2]; -#line 143 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp52_[2] = _tmp55_; -#line 143 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp56_ = _tmp52_[2]; -#line 144 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - return; -#line 638 "page-view.c" - } else { - gboolean _tmp57_ = FALSE; - gint _tmp58_ = 0; -#line 146 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp58_ = depth; -#line 146 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - if (_tmp58_ == 8) { -#line 646 "page-view.c" - gint _tmp59_ = 0; -#line 146 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp59_ = n_channels; -#line 146 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp57_ = _tmp59_ == 1; -#line 652 "page-view.c" - } else { -#line 146 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp57_ = FALSE; -#line 656 "page-view.c" - } -#line 146 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - if (_tmp57_) { -#line 660 "page-view.c" - guchar* _tmp60_ = NULL; - gint _tmp60__length1 = 0; - guchar* _tmp61_ = NULL; - gint _tmp61__length1 = 0; - guchar* _tmp62_ = NULL; - gint _tmp62__length1 = 0; - guchar* _tmp63_ = NULL; - gint _tmp63__length1 = 0; - gint _tmp64_ = 0; - gint _tmp65_ = 0; - guchar _tmp66_ = '\0'; - guchar _tmp67_ = '\0'; - guchar _tmp68_ = '\0'; - guchar _tmp69_ = '\0'; -#line 148 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp60_ = pixel; -#line 148 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp60__length1 = pixel_length1; -#line 148 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp61_ = pixel; -#line 148 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp61__length1 = pixel_length1; -#line 148 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp62_ = pixel; -#line 148 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp62__length1 = pixel_length1; -#line 148 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp63_ = pixels; -#line 148 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp63__length1 = pixels_length1; -#line 148 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp64_ = offset; -#line 148 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp65_ = x; -#line 148 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp66_ = _tmp63_[_tmp64_ + _tmp65_]; -#line 148 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp62_[2] = _tmp66_; -#line 148 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp67_ = _tmp62_[2]; -#line 148 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp61_[1] = _tmp67_; -#line 148 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp68_ = _tmp61_[1]; -#line 148 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp60_[0] = _tmp68_; -#line 148 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp69_ = _tmp60_[0]; -#line 149 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - return; -#line 711 "page-view.c" - } else { - gboolean _tmp70_ = FALSE; - gint _tmp71_ = 0; -#line 153 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp71_ = depth; -#line 153 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - if (_tmp71_ == 1) { -#line 719 "page-view.c" - gint _tmp72_ = 0; -#line 153 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp72_ = n_channels; -#line 153 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp70_ = _tmp72_ == 1; -#line 725 "page-view.c" - } else { -#line 153 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp70_ = FALSE; -#line 729 "page-view.c" - } -#line 153 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - if (_tmp70_) { -#line 733 "page-view.c" - gint o = 0; - gint _tmp73_ = 0; - gint _tmp74_ = 0; - gint _tmp75_ = 0; - guchar* _tmp76_ = NULL; - gint _tmp76__length1 = 0; - gint _tmp77_ = 0; - guchar _tmp78_ = '\0'; - gint _tmp79_ = 0; - guchar* _tmp80_ = NULL; - gint _tmp80__length1 = 0; - guchar* _tmp81_ = NULL; - gint _tmp81__length1 = 0; - guchar* _tmp82_ = NULL; - gint _tmp82__length1 = 0; - guchar _tmp83_ = '\0'; - guchar _tmp84_ = '\0'; - guchar _tmp85_ = '\0'; -#line 155 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp73_ = offset; -#line 155 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp74_ = x; -#line 155 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - o = _tmp73_ + (_tmp74_ / 8); -#line 156 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp76_ = pixels; -#line 156 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp76__length1 = pixels_length1; -#line 156 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp77_ = o; -#line 156 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp78_ = _tmp76_[_tmp77_]; -#line 156 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp79_ = x; -#line 156 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - if (((gint) (_tmp78_ & (0x80 >> (_tmp79_ % 8)))) != 0) { -#line 156 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp75_ = 0x00; -#line 772 "page-view.c" - } else { -#line 156 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp75_ = 0xFF; -#line 776 "page-view.c" - } -#line 156 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp80_ = pixel; -#line 156 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp80__length1 = pixel_length1; -#line 156 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp81_ = pixel; -#line 156 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp81__length1 = pixel_length1; -#line 156 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp82_ = pixel; -#line 156 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp82__length1 = pixel_length1; -#line 156 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp82_[2] = (guchar) _tmp75_; -#line 156 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp83_ = _tmp82_[2]; -#line 156 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp81_[1] = _tmp83_; -#line 156 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp84_ = _tmp81_[1]; -#line 156 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp80_[0] = _tmp84_; -#line 156 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp85_ = _tmp80_[0]; -#line 157 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - return; -#line 804 "page-view.c" - } else { - gboolean _tmp86_ = FALSE; - gint _tmp87_ = 0; -#line 161 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp87_ = depth; -#line 161 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - if (_tmp87_ == 2) { -#line 812 "page-view.c" - gint _tmp88_ = 0; -#line 161 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp88_ = n_channels; -#line 161 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp86_ = _tmp88_ == 1; -#line 818 "page-view.c" - } else { -#line 161 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp86_ = FALSE; -#line 822 "page-view.c" - } -#line 161 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - if (_tmp86_) { -#line 826 "page-view.c" - gint block_shift[4] = {0}; - gint _tmp89_[4] = {0}; - gint o = 0; - gint _tmp90_ = 0; - gint _tmp91_ = 0; - gint sample = 0; - guchar* _tmp92_ = NULL; - gint _tmp92__length1 = 0; - gint _tmp93_ = 0; - guchar _tmp94_ = '\0'; - gint _tmp95_ = 0; - gint _tmp96_ = 0; - gint _tmp97_ = 0; - guchar* _tmp98_ = NULL; - gint _tmp98__length1 = 0; - guchar* _tmp99_ = NULL; - gint _tmp99__length1 = 0; - guchar* _tmp100_ = NULL; - gint _tmp100__length1 = 0; - gint _tmp101_ = 0; - guchar _tmp102_ = '\0'; - guchar _tmp103_ = '\0'; - guchar _tmp104_ = '\0'; -#line 163 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp89_[0] = 6; -#line 163 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp89_[1] = 4; -#line 163 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp89_[2] = 2; -#line 163 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp89_[3] = 0; -#line 163 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - memcpy (block_shift, _tmp89_, 4 * sizeof (gint)); -#line 165 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp90_ = offset; -#line 165 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp91_ = x; -#line 165 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - o = _tmp90_ + (_tmp91_ / 4); -#line 166 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp92_ = pixels; -#line 166 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp92__length1 = pixels_length1; -#line 166 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp93_ = o; -#line 166 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp94_ = _tmp92_[_tmp93_]; -#line 166 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp95_ = x; -#line 166 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp96_ = block_shift[_tmp95_ % 4]; -#line 166 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - sample = (_tmp94_ >> _tmp96_) & 0x3; -#line 167 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp97_ = sample; -#line 167 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - sample = (_tmp97_ * 255) / 3; -#line 169 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp98_ = pixel; -#line 169 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp98__length1 = pixel_length1; -#line 169 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp99_ = pixel; -#line 169 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp99__length1 = pixel_length1; -#line 169 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp100_ = pixel; -#line 169 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp100__length1 = pixel_length1; -#line 169 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp101_ = sample; -#line 169 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp100_[2] = (guchar) _tmp101_; -#line 169 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp102_ = _tmp100_[2]; -#line 169 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp99_[1] = _tmp102_; -#line 169 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp103_ = _tmp99_[1]; -#line 169 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp98_[0] = _tmp103_; -#line 169 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp104_ = _tmp98_[0]; -#line 170 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - return; -#line 912 "page-view.c" - } - } - } - } -#line 174 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp105_ = pixel; -#line 174 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp105__length1 = pixel_length1; -#line 174 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp106_ = pixels; -#line 174 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp106__length1 = pixels_length1; -#line 174 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp107_ = offset; -#line 174 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp108_ = x; -#line 174 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp109_ = depth; -#line 174 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp110_ = x; -#line 174 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp111_ = n_channels; -#line 174 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp112_ = page_view_get_sample (self, _tmp106_, _tmp106__length1, _tmp107_, _tmp108_, _tmp109_, _tmp110_ * _tmp111_); -#line 174 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp105_[0] = _tmp112_; -#line 174 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp113_ = _tmp105_[0]; -#line 175 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp114_ = pixel; -#line 175 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp114__length1 = pixel_length1; -#line 175 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp115_ = pixels; -#line 175 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp115__length1 = pixels_length1; -#line 175 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp116_ = offset; -#line 175 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp117_ = x; -#line 175 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp118_ = depth; -#line 175 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp119_ = x; -#line 175 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp120_ = n_channels; -#line 175 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp121_ = page_view_get_sample (self, _tmp115_, _tmp115__length1, _tmp116_, _tmp117_, _tmp118_, (_tmp119_ * _tmp120_) + 1); -#line 175 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp114_[1] = _tmp121_; -#line 175 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp122_ = _tmp114_[1]; -#line 176 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp123_ = pixel; -#line 176 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp123__length1 = pixel_length1; -#line 176 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp124_ = pixels; -#line 176 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp124__length1 = pixels_length1; -#line 176 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp125_ = offset; -#line 176 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp126_ = x; -#line 176 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp127_ = depth; -#line 176 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp128_ = x; -#line 176 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp129_ = n_channels; -#line 176 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp130_ = page_view_get_sample (self, _tmp124_, _tmp124__length1, _tmp125_, _tmp126_, _tmp127_, (_tmp128_ * _tmp129_) + 2); -#line 176 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp123_[2] = _tmp130_; -#line 176 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp131_ = _tmp123_[2]; -#line 989 "page-view.c" -} - - -static void page_view_set_pixel (PageView* self, Page* page, gdouble l, gdouble r, gdouble t, gdouble b, guchar* output, int output_length1, gint offset) { - gint L = 0; - gdouble _tmp0_ = 0.0; - gint _tmp1_ = 0; - gdouble _tmp2_ = 0.0; - gint R = 0; - gdouble _tmp4_ = 0.0; - gint T = 0; - gdouble _tmp5_ = 0.0; - gint _tmp6_ = 0; - gdouble _tmp7_ = 0.0; - gint B = 0; - gdouble _tmp9_ = 0.0; - gdouble red = 0.0; - gdouble green = 0.0; - gdouble blue = 0.0; - gboolean _tmp10_ = FALSE; - gboolean _tmp11_ = FALSE; - gdouble _tmp12_ = 0.0; - gdouble _tmp13_ = 0.0; - gboolean _tmp283_ = FALSE; - gdouble _tmp284_ = 0.0; - gint _tmp285_ = 0; - gboolean _tmp309_ = FALSE; - gdouble _tmp310_ = 0.0; - gint _tmp311_ = 0; - gboolean _tmp335_ = FALSE; - gdouble _tmp336_ = 0.0; - gint _tmp337_ = 0; - gboolean _tmp361_ = FALSE; - gdouble _tmp362_ = 0.0; - gint _tmp363_ = 0; - gdouble scale = 0.0; - gdouble _tmp387_ = 0.0; - gdouble _tmp388_ = 0.0; - gdouble _tmp389_ = 0.0; - gdouble _tmp390_ = 0.0; - guchar* _tmp391_ = NULL; - gint _tmp391__length1 = 0; - gint _tmp392_ = 0; - gdouble _tmp393_ = 0.0; - gdouble _tmp394_ = 0.0; - guchar _tmp395_ = '\0'; - guchar* _tmp396_ = NULL; - gint _tmp396__length1 = 0; - gint _tmp397_ = 0; - gdouble _tmp398_ = 0.0; - gdouble _tmp399_ = 0.0; - guchar _tmp400_ = '\0'; - guchar* _tmp401_ = NULL; - gint _tmp401__length1 = 0; - gint _tmp402_ = 0; - gdouble _tmp403_ = 0.0; - gdouble _tmp404_ = 0.0; - guchar _tmp405_ = '\0'; -#line 179 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - g_return_if_fail (self != NULL); -#line 179 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - g_return_if_fail (page != NULL); -#line 225 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp0_ = l; -#line 225 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - L = (gint) _tmp0_; -#line 226 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp1_ = L; -#line 226 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp2_ = l; -#line 226 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - if (((gdouble) _tmp1_) != _tmp2_) { -#line 1062 "page-view.c" - gint _tmp3_ = 0; -#line 227 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp3_ = L; -#line 227 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - L = _tmp3_ + 1; -#line 1068 "page-view.c" - } -#line 228 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp4_ = r; -#line 228 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - R = (gint) _tmp4_; -#line 229 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp5_ = t; -#line 229 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - T = (gint) _tmp5_; -#line 230 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp6_ = T; -#line 230 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp7_ = t; -#line 230 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - if (((gdouble) _tmp6_) != _tmp7_) { -#line 1084 "page-view.c" - gint _tmp8_ = 0; -#line 231 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp8_ = T; -#line 231 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - T = _tmp8_ + 1; -#line 1090 "page-view.c" - } -#line 232 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp9_ = b; -#line 232 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - B = (gint) _tmp9_; -#line 234 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - red = 0.0; -#line 235 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - green = 0.0; -#line 236 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - blue = 0.0; -#line 247 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp12_ = r; -#line 247 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp13_ = l; -#line 247 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - if ((_tmp12_ - _tmp13_) <= 1.0) { -#line 1108 "page-view.c" - gdouble _tmp14_ = 0.0; - gdouble _tmp15_ = 0.0; -#line 247 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp14_ = r; -#line 247 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp15_ = l; -#line 247 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp11_ = ((gint) _tmp14_) == ((gint) _tmp15_); -#line 1117 "page-view.c" - } else { -#line 247 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp11_ = FALSE; -#line 1121 "page-view.c" - } -#line 247 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - if (_tmp11_) { -#line 247 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp10_ = TRUE; -#line 1127 "page-view.c" - } else { - gboolean _tmp16_ = FALSE; - gdouble _tmp17_ = 0.0; - gdouble _tmp18_ = 0.0; -#line 247 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp17_ = b; -#line 247 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp18_ = t; -#line 247 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - if ((_tmp17_ - _tmp18_) <= 1.0) { -#line 1138 "page-view.c" - gdouble _tmp19_ = 0.0; - gdouble _tmp20_ = 0.0; -#line 247 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp19_ = b; -#line 247 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp20_ = t; -#line 247 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp16_ = ((gint) _tmp19_) == ((gint) _tmp20_); -#line 1147 "page-view.c" - } else { -#line 247 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp16_ = FALSE; -#line 1151 "page-view.c" - } -#line 247 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp10_ = _tmp16_; -#line 1155 "page-view.c" - } -#line 247 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - if (_tmp10_) { -#line 1159 "page-view.c" - gboolean _tmp21_ = FALSE; - gdouble _tmp22_ = 0.0; - gdouble _tmp23_ = 0.0; - gint _tmp41_ = 0; - gint _tmp42_ = 0; - gdouble scale = 0.0; - gdouble _tmp167_ = 0.0; - gdouble _tmp168_ = 0.0; - gdouble _tmp169_ = 0.0; - gdouble _tmp170_ = 0.0; - guchar* _tmp171_ = NULL; - gint _tmp171__length1 = 0; - gint _tmp172_ = 0; - gdouble _tmp173_ = 0.0; - gdouble _tmp174_ = 0.0; - guchar _tmp175_ = '\0'; - guchar* _tmp176_ = NULL; - gint _tmp176__length1 = 0; - gint _tmp177_ = 0; - gdouble _tmp178_ = 0.0; - gdouble _tmp179_ = 0.0; - guchar _tmp180_ = '\0'; - guchar* _tmp181_ = NULL; - gint _tmp181__length1 = 0; - gint _tmp182_ = 0; - gdouble _tmp183_ = 0.0; - gdouble _tmp184_ = 0.0; - guchar _tmp185_ = '\0'; -#line 250 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp22_ = l; -#line 250 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp23_ = r; -#line 250 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - if (((gint) _tmp22_) == ((gint) _tmp23_)) { -#line 250 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp21_ = TRUE; -#line 1196 "page-view.c" - } else { - gdouble _tmp24_ = 0.0; - gdouble _tmp25_ = 0.0; -#line 250 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp24_ = t; -#line 250 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp25_ = b; -#line 250 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp21_ = ((gint) _tmp24_) == ((gint) _tmp25_); -#line 1206 "page-view.c" - } -#line 250 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - if (_tmp21_) { -#line 1210 "page-view.c" - guchar p[3] = {0}; - Page* _tmp26_ = NULL; - gdouble _tmp27_ = 0.0; - gdouble _tmp28_ = 0.0; - guchar* _tmp29_ = NULL; - gint _tmp29__length1 = 0; - gint _tmp30_ = 0; - guchar _tmp31_ = '\0'; - guchar _tmp32_ = '\0'; - guchar* _tmp33_ = NULL; - gint _tmp33__length1 = 0; - gint _tmp34_ = 0; - guchar _tmp35_ = '\0'; - guchar _tmp36_ = '\0'; - guchar* _tmp37_ = NULL; - gint _tmp37__length1 = 0; - gint _tmp38_ = 0; - guchar _tmp39_ = '\0'; - guchar _tmp40_ = '\0'; -#line 253 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp26_ = page; -#line 253 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp27_ = l; -#line 253 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp28_ = t; -#line 253 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - page_view_get_pixel (self, _tmp26_, (gint) _tmp27_, (gint) _tmp28_, p, 3); -#line 254 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp29_ = output; -#line 254 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp29__length1 = output_length1; -#line 254 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp30_ = offset; -#line 254 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp31_ = p[0]; -#line 254 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp29_[_tmp30_] = _tmp31_; -#line 254 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp32_ = _tmp29_[_tmp30_]; -#line 255 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp33_ = output; -#line 255 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp33__length1 = output_length1; -#line 255 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp34_ = offset; -#line 255 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp35_ = p[1]; -#line 255 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp33_[_tmp34_ + 1] = _tmp35_; -#line 255 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp36_ = _tmp33_[_tmp34_ + 1]; -#line 256 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp37_ = output; -#line 256 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp37__length1 = output_length1; -#line 256 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp38_ = offset; -#line 256 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp39_ = p[2]; -#line 256 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp37_[_tmp38_ + 2] = _tmp39_; -#line 256 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp40_ = _tmp37_[_tmp38_ + 2]; -#line 257 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - return; -#line 1276 "page-view.c" - } -#line 261 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp41_ = L; -#line 261 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp42_ = R; -#line 261 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - if (_tmp41_ > _tmp42_) { -#line 1284 "page-view.c" - guchar p[3] = {0}; - Page* _tmp43_ = NULL; - gint _tmp44_ = 0; - gint _tmp45_ = 0; - gdouble _tmp46_ = 0.0; - guchar _tmp47_ = '\0'; - gdouble _tmp48_ = 0.0; - gdouble _tmp49_ = 0.0; - gint _tmp50_ = 0; - gdouble _tmp51_ = 0.0; - gdouble _tmp52_ = 0.0; - guchar _tmp53_ = '\0'; - gdouble _tmp54_ = 0.0; - gdouble _tmp55_ = 0.0; - gint _tmp56_ = 0; - gdouble _tmp57_ = 0.0; - gdouble _tmp58_ = 0.0; - guchar _tmp59_ = '\0'; - gdouble _tmp60_ = 0.0; - gdouble _tmp61_ = 0.0; - gint _tmp62_ = 0; - gdouble _tmp63_ = 0.0; - Page* _tmp84_ = NULL; - gint _tmp85_ = 0; - gint _tmp86_ = 0; - gdouble _tmp87_ = 0.0; - guchar _tmp88_ = '\0'; - gdouble _tmp89_ = 0.0; - gdouble _tmp90_ = 0.0; - gdouble _tmp91_ = 0.0; - gint _tmp92_ = 0; - gdouble _tmp93_ = 0.0; - guchar _tmp94_ = '\0'; - gdouble _tmp95_ = 0.0; - gdouble _tmp96_ = 0.0; - gdouble _tmp97_ = 0.0; - gint _tmp98_ = 0; - gdouble _tmp99_ = 0.0; - guchar _tmp100_ = '\0'; - gdouble _tmp101_ = 0.0; - gdouble _tmp102_ = 0.0; - gdouble _tmp103_ = 0.0; - gint _tmp104_ = 0; -#line 264 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp43_ = page; -#line 264 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp44_ = R; -#line 264 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp45_ = T; -#line 264 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - page_view_get_pixel (self, _tmp43_, _tmp44_, _tmp45_ - 1, p, 3); -#line 265 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp46_ = red; -#line 265 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp47_ = p[0]; -#line 265 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp48_ = r; -#line 265 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp49_ = l; -#line 265 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp50_ = T; -#line 265 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp51_ = t; -#line 265 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - red = _tmp46_ + ((_tmp47_ * (_tmp48_ - _tmp49_)) * (_tmp50_ - _tmp51_)); -#line 266 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp52_ = green; -#line 266 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp53_ = p[1]; -#line 266 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp54_ = r; -#line 266 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp55_ = l; -#line 266 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp56_ = T; -#line 266 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp57_ = t; -#line 266 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - green = _tmp52_ + ((_tmp53_ * (_tmp54_ - _tmp55_)) * (_tmp56_ - _tmp57_)); -#line 267 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp58_ = blue; -#line 267 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp59_ = p[2]; -#line 267 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp60_ = r; -#line 267 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp61_ = l; -#line 267 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp62_ = T; -#line 267 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp63_ = t; -#line 267 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - blue = _tmp58_ + ((_tmp59_ * (_tmp60_ - _tmp61_)) * (_tmp62_ - _tmp63_)); -#line 1378 "page-view.c" - { - gint y = 0; - gint _tmp64_ = 0; -#line 268 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp64_ = T; -#line 268 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - y = _tmp64_; -#line 1386 "page-view.c" - { - gboolean _tmp65_ = FALSE; -#line 268 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp65_ = TRUE; -#line 268 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - while (TRUE) { -#line 1393 "page-view.c" - gint _tmp67_ = 0; - gint _tmp68_ = 0; - Page* _tmp69_ = NULL; - gint _tmp70_ = 0; - gint _tmp71_ = 0; - gdouble _tmp72_ = 0.0; - guchar _tmp73_ = '\0'; - gdouble _tmp74_ = 0.0; - gdouble _tmp75_ = 0.0; - gdouble _tmp76_ = 0.0; - guchar _tmp77_ = '\0'; - gdouble _tmp78_ = 0.0; - gdouble _tmp79_ = 0.0; - gdouble _tmp80_ = 0.0; - guchar _tmp81_ = '\0'; - gdouble _tmp82_ = 0.0; - gdouble _tmp83_ = 0.0; -#line 268 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - if (!_tmp65_) { -#line 1413 "page-view.c" - gint _tmp66_ = 0; -#line 268 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp66_ = y; -#line 268 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - y = _tmp66_ + 1; -#line 1419 "page-view.c" - } -#line 268 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp65_ = FALSE; -#line 268 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp67_ = y; -#line 268 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp68_ = B; -#line 268 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - if (!(_tmp67_ < _tmp68_)) { -#line 268 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - break; -#line 1431 "page-view.c" - } -#line 270 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp69_ = page; -#line 270 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp70_ = R; -#line 270 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp71_ = y; -#line 270 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - page_view_get_pixel (self, _tmp69_, _tmp70_, _tmp71_, p, 3); -#line 271 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp72_ = red; -#line 271 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp73_ = p[0]; -#line 271 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp74_ = r; -#line 271 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp75_ = l; -#line 271 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - red = _tmp72_ + (_tmp73_ * (_tmp74_ - _tmp75_)); -#line 272 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp76_ = green; -#line 272 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp77_ = p[1]; -#line 272 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp78_ = r; -#line 272 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp79_ = l; -#line 272 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - green = _tmp76_ + (_tmp77_ * (_tmp78_ - _tmp79_)); -#line 273 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp80_ = blue; -#line 273 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp81_ = p[2]; -#line 273 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp82_ = r; -#line 273 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp83_ = l; -#line 273 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - blue = _tmp80_ + (_tmp81_ * (_tmp82_ - _tmp83_)); -#line 1471 "page-view.c" - } - } - } -#line 275 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp84_ = page; -#line 275 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp85_ = R; -#line 275 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp86_ = B; -#line 275 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - page_view_get_pixel (self, _tmp84_, _tmp85_, _tmp86_, p, 3); -#line 276 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp87_ = red; -#line 276 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp88_ = p[0]; -#line 276 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp89_ = r; -#line 276 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp90_ = l; -#line 276 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp91_ = b; -#line 276 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp92_ = B; -#line 276 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - red = _tmp87_ + ((_tmp88_ * (_tmp89_ - _tmp90_)) * (_tmp91_ - _tmp92_)); -#line 277 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp93_ = green; -#line 277 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp94_ = p[1]; -#line 277 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp95_ = r; -#line 277 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp96_ = l; -#line 277 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp97_ = b; -#line 277 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp98_ = B; -#line 277 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - green = _tmp93_ + ((_tmp94_ * (_tmp95_ - _tmp96_)) * (_tmp97_ - _tmp98_)); -#line 278 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp99_ = blue; -#line 278 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp100_ = p[2]; -#line 278 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp101_ = r; -#line 278 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp102_ = l; -#line 278 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp103_ = b; -#line 278 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp104_ = B; -#line 278 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - blue = _tmp99_ + ((_tmp100_ * (_tmp101_ - _tmp102_)) * (_tmp103_ - _tmp104_)); -#line 1525 "page-view.c" - } else { - guchar p[3] = {0}; - Page* _tmp105_ = NULL; - gint _tmp106_ = 0; - gint _tmp107_ = 0; - gdouble _tmp108_ = 0.0; - guchar _tmp109_ = '\0'; - gdouble _tmp110_ = 0.0; - gdouble _tmp111_ = 0.0; - gint _tmp112_ = 0; - gdouble _tmp113_ = 0.0; - gdouble _tmp114_ = 0.0; - guchar _tmp115_ = '\0'; - gdouble _tmp116_ = 0.0; - gdouble _tmp117_ = 0.0; - gint _tmp118_ = 0; - gdouble _tmp119_ = 0.0; - gdouble _tmp120_ = 0.0; - guchar _tmp121_ = '\0'; - gdouble _tmp122_ = 0.0; - gdouble _tmp123_ = 0.0; - gint _tmp124_ = 0; - gdouble _tmp125_ = 0.0; - Page* _tmp146_ = NULL; - gint _tmp147_ = 0; - gint _tmp148_ = 0; - gdouble _tmp149_ = 0.0; - guchar _tmp150_ = '\0'; - gdouble _tmp151_ = 0.0; - gdouble _tmp152_ = 0.0; - gdouble _tmp153_ = 0.0; - gint _tmp154_ = 0; - gdouble _tmp155_ = 0.0; - guchar _tmp156_ = '\0'; - gdouble _tmp157_ = 0.0; - gdouble _tmp158_ = 0.0; - gdouble _tmp159_ = 0.0; - gint _tmp160_ = 0; - gdouble _tmp161_ = 0.0; - guchar _tmp162_ = '\0'; - gdouble _tmp163_ = 0.0; - gdouble _tmp164_ = 0.0; - gdouble _tmp165_ = 0.0; - gint _tmp166_ = 0; -#line 284 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp105_ = page; -#line 284 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp106_ = L; -#line 284 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp107_ = B; -#line 284 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - page_view_get_pixel (self, _tmp105_, _tmp106_ - 1, _tmp107_, p, 3); -#line 285 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp108_ = red; -#line 285 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp109_ = p[0]; -#line 285 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp110_ = b; -#line 285 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp111_ = t; -#line 285 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp112_ = L; -#line 285 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp113_ = l; -#line 285 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - red = _tmp108_ + ((_tmp109_ * (_tmp110_ - _tmp111_)) * (_tmp112_ - _tmp113_)); -#line 286 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp114_ = green; -#line 286 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp115_ = p[1]; -#line 286 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp116_ = b; -#line 286 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp117_ = t; -#line 286 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp118_ = L; -#line 286 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp119_ = l; -#line 286 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - green = _tmp114_ + ((_tmp115_ * (_tmp116_ - _tmp117_)) * (_tmp118_ - _tmp119_)); -#line 287 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp120_ = blue; -#line 287 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp121_ = p[2]; -#line 287 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp122_ = b; -#line 287 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp123_ = t; -#line 287 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp124_ = L; -#line 287 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp125_ = l; -#line 287 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - blue = _tmp120_ + ((_tmp121_ * (_tmp122_ - _tmp123_)) * (_tmp124_ - _tmp125_)); -#line 1620 "page-view.c" - { - gint x = 0; - gint _tmp126_ = 0; -#line 288 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp126_ = L; -#line 288 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - x = _tmp126_; -#line 1628 "page-view.c" - { - gboolean _tmp127_ = FALSE; -#line 288 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp127_ = TRUE; -#line 288 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - while (TRUE) { -#line 1635 "page-view.c" - gint _tmp129_ = 0; - gint _tmp130_ = 0; - Page* _tmp131_ = NULL; - gint _tmp132_ = 0; - gint _tmp133_ = 0; - gdouble _tmp134_ = 0.0; - guchar _tmp135_ = '\0'; - gdouble _tmp136_ = 0.0; - gdouble _tmp137_ = 0.0; - gdouble _tmp138_ = 0.0; - guchar _tmp139_ = '\0'; - gdouble _tmp140_ = 0.0; - gdouble _tmp141_ = 0.0; - gdouble _tmp142_ = 0.0; - guchar _tmp143_ = '\0'; - gdouble _tmp144_ = 0.0; - gdouble _tmp145_ = 0.0; -#line 288 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - if (!_tmp127_) { -#line 1655 "page-view.c" - gint _tmp128_ = 0; -#line 288 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp128_ = x; -#line 288 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - x = _tmp128_ + 1; -#line 1661 "page-view.c" - } -#line 288 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp127_ = FALSE; -#line 288 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp129_ = x; -#line 288 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp130_ = R; -#line 288 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - if (!(_tmp129_ < _tmp130_)) { -#line 288 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - break; -#line 1673 "page-view.c" - } -#line 289 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp131_ = page; -#line 289 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp132_ = x; -#line 289 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp133_ = B; -#line 289 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - page_view_get_pixel (self, _tmp131_, _tmp132_, _tmp133_, p, 3); -#line 290 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp134_ = red; -#line 290 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp135_ = p[0]; -#line 290 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp136_ = b; -#line 290 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp137_ = t; -#line 290 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - red = _tmp134_ + (_tmp135_ * (_tmp136_ - _tmp137_)); -#line 291 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp138_ = green; -#line 291 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp139_ = p[1]; -#line 291 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp140_ = b; -#line 291 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp141_ = t; -#line 291 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - green = _tmp138_ + (_tmp139_ * (_tmp140_ - _tmp141_)); -#line 292 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp142_ = blue; -#line 292 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp143_ = p[2]; -#line 292 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp144_ = b; -#line 292 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp145_ = t; -#line 292 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - blue = _tmp142_ + (_tmp143_ * (_tmp144_ - _tmp145_)); -#line 1713 "page-view.c" - } - } - } -#line 294 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp146_ = page; -#line 294 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp147_ = R; -#line 294 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp148_ = B; -#line 294 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - page_view_get_pixel (self, _tmp146_, _tmp147_, _tmp148_, p, 3); -#line 295 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp149_ = red; -#line 295 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp150_ = p[0]; -#line 295 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp151_ = b; -#line 295 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp152_ = t; -#line 295 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp153_ = r; -#line 295 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp154_ = R; -#line 295 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - red = _tmp149_ + ((_tmp150_ * (_tmp151_ - _tmp152_)) * (_tmp153_ - _tmp154_)); -#line 296 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp155_ = green; -#line 296 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp156_ = p[1]; -#line 296 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp157_ = b; -#line 296 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp158_ = t; -#line 296 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp159_ = r; -#line 296 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp160_ = R; -#line 296 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - green = _tmp155_ + ((_tmp156_ * (_tmp157_ - _tmp158_)) * (_tmp159_ - _tmp160_)); -#line 297 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp161_ = blue; -#line 297 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp162_ = p[2]; -#line 297 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp163_ = b; -#line 297 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp164_ = t; -#line 297 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp165_ = r; -#line 297 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp166_ = R; -#line 297 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - blue = _tmp161_ + ((_tmp162_ * (_tmp163_ - _tmp164_)) * (_tmp165_ - _tmp166_)); -#line 1767 "page-view.c" - } -#line 300 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp167_ = r; -#line 300 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp168_ = l; -#line 300 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp169_ = b; -#line 300 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp170_ = t; -#line 300 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - scale = 1.0 / ((_tmp167_ - _tmp168_) * (_tmp169_ - _tmp170_)); -#line 301 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp171_ = output; -#line 301 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp171__length1 = output_length1; -#line 301 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp172_ = offset; -#line 301 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp173_ = red; -#line 301 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp174_ = scale; -#line 301 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp171_[_tmp172_] = (guchar) ((_tmp173_ * _tmp174_) + 0.5); -#line 301 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp175_ = _tmp171_[_tmp172_]; -#line 302 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp176_ = output; -#line 302 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp176__length1 = output_length1; -#line 302 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp177_ = offset; -#line 302 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp178_ = green; -#line 302 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp179_ = scale; -#line 302 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp176_[_tmp177_ + 1] = (guchar) ((_tmp178_ * _tmp179_) + 0.5); -#line 302 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp180_ = _tmp176_[_tmp177_ + 1]; -#line 303 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp181_ = output; -#line 303 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp181__length1 = output_length1; -#line 303 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp182_ = offset; -#line 303 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp183_ = blue; -#line 303 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp184_ = scale; -#line 303 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp181_[_tmp182_ + 2] = (guchar) ((_tmp183_ * _tmp184_) + 0.5); -#line 303 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp185_ = _tmp181_[_tmp182_ + 2]; -#line 304 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - return; -#line 1823 "page-view.c" - } - { - gint x = 0; - gint _tmp186_ = 0; -#line 308 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp186_ = L; -#line 308 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - x = _tmp186_; -#line 1832 "page-view.c" - { - gboolean _tmp187_ = FALSE; -#line 308 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp187_ = TRUE; -#line 308 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - while (TRUE) { -#line 1839 "page-view.c" - gint _tmp189_ = 0; - gint _tmp190_ = 0; -#line 308 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - if (!_tmp187_) { -#line 1844 "page-view.c" - gint _tmp188_ = 0; -#line 308 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp188_ = x; -#line 308 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - x = _tmp188_ + 1; -#line 1850 "page-view.c" - } -#line 308 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp187_ = FALSE; -#line 308 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp189_ = x; -#line 308 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp190_ = R; -#line 308 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - if (!(_tmp189_ < _tmp190_)) { -#line 308 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - break; -#line 1862 "page-view.c" - } - { - gint y = 0; - gint _tmp191_ = 0; -#line 310 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp191_ = T; -#line 310 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - y = _tmp191_; -#line 1871 "page-view.c" - { - gboolean _tmp192_ = FALSE; -#line 310 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp192_ = TRUE; -#line 310 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - while (TRUE) { -#line 1878 "page-view.c" - gint _tmp194_ = 0; - gint _tmp195_ = 0; - guchar p[3] = {0}; - Page* _tmp196_ = NULL; - gint _tmp197_ = 0; - gint _tmp198_ = 0; - gdouble _tmp199_ = 0.0; - guchar _tmp200_ = '\0'; - gdouble _tmp201_ = 0.0; - guchar _tmp202_ = '\0'; - gdouble _tmp203_ = 0.0; - guchar _tmp204_ = '\0'; -#line 310 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - if (!_tmp192_) { -#line 1893 "page-view.c" - gint _tmp193_ = 0; -#line 310 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp193_ = y; -#line 310 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - y = _tmp193_ + 1; -#line 1899 "page-view.c" - } -#line 310 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp192_ = FALSE; -#line 310 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp194_ = y; -#line 310 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp195_ = B; -#line 310 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - if (!(_tmp194_ < _tmp195_)) { -#line 310 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - break; -#line 1911 "page-view.c" - } -#line 313 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp196_ = page; -#line 313 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp197_ = x; -#line 313 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp198_ = y; -#line 313 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - page_view_get_pixel (self, _tmp196_, _tmp197_, _tmp198_, p, 3); -#line 314 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp199_ = red; -#line 314 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp200_ = p[0]; -#line 314 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - red = _tmp199_ + _tmp200_; -#line 315 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp201_ = green; -#line 315 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp202_ = p[1]; -#line 315 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - green = _tmp201_ + _tmp202_; -#line 316 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp203_ = blue; -#line 316 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp204_ = p[2]; -#line 316 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - blue = _tmp203_ + _tmp204_; -#line 1939 "page-view.c" - } - } - } - } - } - } - { - gint x = 0; - gint _tmp205_ = 0; -#line 321 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp205_ = L; -#line 321 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - x = _tmp205_; -#line 1953 "page-view.c" - { - gboolean _tmp206_ = FALSE; -#line 321 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp206_ = TRUE; -#line 321 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - while (TRUE) { -#line 1960 "page-view.c" - gint _tmp208_ = 0; - gint _tmp209_ = 0; - gdouble _tmp210_ = 0.0; - gint _tmp211_ = 0; - gdouble _tmp227_ = 0.0; - gint _tmp228_ = 0; -#line 321 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - if (!_tmp206_) { -#line 1969 "page-view.c" - gint _tmp207_ = 0; -#line 321 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp207_ = x; -#line 321 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - x = _tmp207_ + 1; -#line 1975 "page-view.c" - } -#line 321 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp206_ = FALSE; -#line 321 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp208_ = x; -#line 321 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp209_ = R; -#line 321 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - if (!(_tmp208_ < _tmp209_)) { -#line 321 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - break; -#line 1987 "page-view.c" - } -#line 323 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp210_ = t; -#line 323 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp211_ = T; -#line 323 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - if (_tmp210_ != ((gdouble) _tmp211_)) { -#line 1995 "page-view.c" - guchar p[3] = {0}; - Page* _tmp212_ = NULL; - gint _tmp213_ = 0; - gint _tmp214_ = 0; - gdouble _tmp215_ = 0.0; - guchar _tmp216_ = '\0'; - gint _tmp217_ = 0; - gdouble _tmp218_ = 0.0; - gdouble _tmp219_ = 0.0; - guchar _tmp220_ = '\0'; - gint _tmp221_ = 0; - gdouble _tmp222_ = 0.0; - gdouble _tmp223_ = 0.0; - guchar _tmp224_ = '\0'; - gint _tmp225_ = 0; - gdouble _tmp226_ = 0.0; -#line 326 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp212_ = page; -#line 326 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp213_ = x; -#line 326 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp214_ = T; -#line 326 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - page_view_get_pixel (self, _tmp212_, _tmp213_, _tmp214_ - 1, p, 3); -#line 327 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp215_ = red; -#line 327 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp216_ = p[0]; -#line 327 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp217_ = T; -#line 327 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp218_ = t; -#line 327 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - red = _tmp215_ + (_tmp216_ * (_tmp217_ - _tmp218_)); -#line 328 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp219_ = green; -#line 328 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp220_ = p[1]; -#line 328 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp221_ = T; -#line 328 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp222_ = t; -#line 328 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - green = _tmp219_ + (_tmp220_ * (_tmp221_ - _tmp222_)); -#line 329 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp223_ = blue; -#line 329 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp224_ = p[2]; -#line 329 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp225_ = T; -#line 329 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp226_ = t; -#line 329 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - blue = _tmp223_ + (_tmp224_ * (_tmp225_ - _tmp226_)); -#line 2050 "page-view.c" - } -#line 332 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp227_ = b; -#line 332 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp228_ = B; -#line 332 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - if (_tmp227_ != ((gdouble) _tmp228_)) { -#line 2058 "page-view.c" - guchar p[3] = {0}; - Page* _tmp229_ = NULL; - gint _tmp230_ = 0; - gint _tmp231_ = 0; - gdouble _tmp232_ = 0.0; - guchar _tmp233_ = '\0'; - gdouble _tmp234_ = 0.0; - gint _tmp235_ = 0; - gdouble _tmp236_ = 0.0; - guchar _tmp237_ = '\0'; - gdouble _tmp238_ = 0.0; - gint _tmp239_ = 0; - gdouble _tmp240_ = 0.0; - guchar _tmp241_ = '\0'; - gdouble _tmp242_ = 0.0; - gint _tmp243_ = 0; -#line 335 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp229_ = page; -#line 335 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp230_ = x; -#line 335 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp231_ = B; -#line 335 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - page_view_get_pixel (self, _tmp229_, _tmp230_, _tmp231_, p, 3); -#line 336 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp232_ = red; -#line 336 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp233_ = p[0]; -#line 336 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp234_ = b; -#line 336 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp235_ = B; -#line 336 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - red = _tmp232_ + (_tmp233_ * (_tmp234_ - _tmp235_)); -#line 337 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp236_ = green; -#line 337 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp237_ = p[1]; -#line 337 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp238_ = b; -#line 337 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp239_ = B; -#line 337 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - green = _tmp236_ + (_tmp237_ * (_tmp238_ - _tmp239_)); -#line 338 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp240_ = blue; -#line 338 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp241_ = p[2]; -#line 338 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp242_ = b; -#line 338 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp243_ = B; -#line 338 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - blue = _tmp240_ + (_tmp241_ * (_tmp242_ - _tmp243_)); -#line 2113 "page-view.c" - } - } - } - } - { - gint y = 0; - gint _tmp244_ = 0; -#line 343 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp244_ = T; -#line 343 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - y = _tmp244_; -#line 2125 "page-view.c" - { - gboolean _tmp245_ = FALSE; -#line 343 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp245_ = TRUE; -#line 343 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - while (TRUE) { -#line 2132 "page-view.c" - gint _tmp247_ = 0; - gint _tmp248_ = 0; - gdouble _tmp249_ = 0.0; - gint _tmp250_ = 0; - gdouble _tmp266_ = 0.0; - gint _tmp267_ = 0; -#line 343 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - if (!_tmp245_) { -#line 2141 "page-view.c" - gint _tmp246_ = 0; -#line 343 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp246_ = y; -#line 343 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - y = _tmp246_ + 1; -#line 2147 "page-view.c" - } -#line 343 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp245_ = FALSE; -#line 343 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp247_ = y; -#line 343 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp248_ = B; -#line 343 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - if (!(_tmp247_ < _tmp248_)) { -#line 343 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - break; -#line 2159 "page-view.c" - } -#line 345 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp249_ = l; -#line 345 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp250_ = L; -#line 345 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - if (_tmp249_ != ((gdouble) _tmp250_)) { -#line 2167 "page-view.c" - guchar p[3] = {0}; - Page* _tmp251_ = NULL; - gint _tmp252_ = 0; - gint _tmp253_ = 0; - gdouble _tmp254_ = 0.0; - guchar _tmp255_ = '\0'; - gint _tmp256_ = 0; - gdouble _tmp257_ = 0.0; - gdouble _tmp258_ = 0.0; - guchar _tmp259_ = '\0'; - gint _tmp260_ = 0; - gdouble _tmp261_ = 0.0; - gdouble _tmp262_ = 0.0; - guchar _tmp263_ = '\0'; - gint _tmp264_ = 0; - gdouble _tmp265_ = 0.0; -#line 348 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp251_ = page; -#line 348 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp252_ = L; -#line 348 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp253_ = y; -#line 348 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - page_view_get_pixel (self, _tmp251_, _tmp252_ - 1, _tmp253_, p, 3); -#line 349 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp254_ = red; -#line 349 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp255_ = p[0]; -#line 349 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp256_ = L; -#line 349 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp257_ = l; -#line 349 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - red = _tmp254_ + (_tmp255_ * (_tmp256_ - _tmp257_)); -#line 350 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp258_ = green; -#line 350 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp259_ = p[1]; -#line 350 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp260_ = L; -#line 350 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp261_ = l; -#line 350 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - green = _tmp258_ + (_tmp259_ * (_tmp260_ - _tmp261_)); -#line 351 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp262_ = blue; -#line 351 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp263_ = p[2]; -#line 351 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp264_ = L; -#line 351 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp265_ = l; -#line 351 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - blue = _tmp262_ + (_tmp263_ * (_tmp264_ - _tmp265_)); -#line 2222 "page-view.c" - } -#line 354 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp266_ = r; -#line 354 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp267_ = R; -#line 354 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - if (_tmp266_ != ((gdouble) _tmp267_)) { -#line 2230 "page-view.c" - guchar p[3] = {0}; - Page* _tmp268_ = NULL; - gint _tmp269_ = 0; - gint _tmp270_ = 0; - gdouble _tmp271_ = 0.0; - guchar _tmp272_ = '\0'; - gdouble _tmp273_ = 0.0; - gint _tmp274_ = 0; - gdouble _tmp275_ = 0.0; - guchar _tmp276_ = '\0'; - gdouble _tmp277_ = 0.0; - gint _tmp278_ = 0; - gdouble _tmp279_ = 0.0; - guchar _tmp280_ = '\0'; - gdouble _tmp281_ = 0.0; - gint _tmp282_ = 0; -#line 357 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp268_ = page; -#line 357 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp269_ = R; -#line 357 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp270_ = y; -#line 357 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - page_view_get_pixel (self, _tmp268_, _tmp269_, _tmp270_, p, 3); -#line 358 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp271_ = red; -#line 358 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp272_ = p[0]; -#line 358 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp273_ = r; -#line 358 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp274_ = R; -#line 358 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - red = _tmp271_ + (_tmp272_ * (_tmp273_ - _tmp274_)); -#line 359 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp275_ = green; -#line 359 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp276_ = p[1]; -#line 359 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp277_ = r; -#line 359 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp278_ = R; -#line 359 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - green = _tmp275_ + (_tmp276_ * (_tmp277_ - _tmp278_)); -#line 360 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp279_ = blue; -#line 360 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp280_ = p[2]; -#line 360 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp281_ = r; -#line 360 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp282_ = R; -#line 360 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - blue = _tmp279_ + (_tmp280_ * (_tmp281_ - _tmp282_)); -#line 2285 "page-view.c" - } - } - } - } -#line 365 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp284_ = l; -#line 365 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp285_ = L; -#line 365 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - if (_tmp284_ != ((gdouble) _tmp285_)) { -#line 2296 "page-view.c" - gdouble _tmp286_ = 0.0; - gint _tmp287_ = 0; -#line 365 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp286_ = t; -#line 365 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp287_ = T; -#line 365 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp283_ = _tmp286_ != ((gdouble) _tmp287_); -#line 2305 "page-view.c" - } else { -#line 365 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp283_ = FALSE; -#line 2309 "page-view.c" - } -#line 365 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - if (_tmp283_) { -#line 2313 "page-view.c" - guchar p[3] = {0}; - Page* _tmp288_ = NULL; - gint _tmp289_ = 0; - gint _tmp290_ = 0; - gdouble _tmp291_ = 0.0; - guchar _tmp292_ = '\0'; - gint _tmp293_ = 0; - gdouble _tmp294_ = 0.0; - gint _tmp295_ = 0; - gdouble _tmp296_ = 0.0; - gdouble _tmp297_ = 0.0; - guchar _tmp298_ = '\0'; - gint _tmp299_ = 0; - gdouble _tmp300_ = 0.0; - gint _tmp301_ = 0; - gdouble _tmp302_ = 0.0; - gdouble _tmp303_ = 0.0; - guchar _tmp304_ = '\0'; - gint _tmp305_ = 0; - gdouble _tmp306_ = 0.0; - gint _tmp307_ = 0; - gdouble _tmp308_ = 0.0; -#line 368 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp288_ = page; -#line 368 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp289_ = L; -#line 368 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp290_ = T; -#line 368 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - page_view_get_pixel (self, _tmp288_, _tmp289_ - 1, _tmp290_ - 1, p, 3); -#line 369 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp291_ = red; -#line 369 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp292_ = p[0]; -#line 369 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp293_ = L; -#line 369 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp294_ = l; -#line 369 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp295_ = T; -#line 369 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp296_ = t; -#line 369 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - red = _tmp291_ + ((_tmp292_ * (_tmp293_ - _tmp294_)) * (_tmp295_ - _tmp296_)); -#line 370 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp297_ = green; -#line 370 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp298_ = p[1]; -#line 370 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp299_ = L; -#line 370 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp300_ = l; -#line 370 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp301_ = T; -#line 370 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp302_ = t; -#line 370 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - green = _tmp297_ + ((_tmp298_ * (_tmp299_ - _tmp300_)) * (_tmp301_ - _tmp302_)); -#line 371 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp303_ = blue; -#line 371 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp304_ = p[2]; -#line 371 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp305_ = L; -#line 371 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp306_ = l; -#line 371 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp307_ = T; -#line 371 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp308_ = t; -#line 371 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - blue = _tmp303_ + ((_tmp304_ * (_tmp305_ - _tmp306_)) * (_tmp307_ - _tmp308_)); -#line 2386 "page-view.c" - } -#line 373 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp310_ = r; -#line 373 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp311_ = R; -#line 373 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - if (_tmp310_ != ((gdouble) _tmp311_)) { -#line 2394 "page-view.c" - gdouble _tmp312_ = 0.0; - gint _tmp313_ = 0; -#line 373 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp312_ = t; -#line 373 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp313_ = T; -#line 373 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp309_ = _tmp312_ != ((gdouble) _tmp313_); -#line 2403 "page-view.c" - } else { -#line 373 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp309_ = FALSE; -#line 2407 "page-view.c" - } -#line 373 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - if (_tmp309_) { -#line 2411 "page-view.c" - guchar p[3] = {0}; - Page* _tmp314_ = NULL; - gint _tmp315_ = 0; - gint _tmp316_ = 0; - gdouble _tmp317_ = 0.0; - guchar _tmp318_ = '\0'; - gdouble _tmp319_ = 0.0; - gint _tmp320_ = 0; - gint _tmp321_ = 0; - gdouble _tmp322_ = 0.0; - gdouble _tmp323_ = 0.0; - guchar _tmp324_ = '\0'; - gdouble _tmp325_ = 0.0; - gint _tmp326_ = 0; - gint _tmp327_ = 0; - gdouble _tmp328_ = 0.0; - gdouble _tmp329_ = 0.0; - guchar _tmp330_ = '\0'; - gdouble _tmp331_ = 0.0; - gint _tmp332_ = 0; - gint _tmp333_ = 0; - gdouble _tmp334_ = 0.0; -#line 376 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp314_ = page; -#line 376 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp315_ = R; -#line 376 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp316_ = T; -#line 376 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - page_view_get_pixel (self, _tmp314_, _tmp315_, _tmp316_ - 1, p, 3); -#line 377 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp317_ = red; -#line 377 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp318_ = p[0]; -#line 377 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp319_ = r; -#line 377 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp320_ = R; -#line 377 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp321_ = T; -#line 377 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp322_ = t; -#line 377 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - red = _tmp317_ + ((_tmp318_ * (_tmp319_ - _tmp320_)) * (_tmp321_ - _tmp322_)); -#line 378 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp323_ = green; -#line 378 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp324_ = p[1]; -#line 378 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp325_ = r; -#line 378 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp326_ = R; -#line 378 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp327_ = T; -#line 378 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp328_ = t; -#line 378 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - green = _tmp323_ + ((_tmp324_ * (_tmp325_ - _tmp326_)) * (_tmp327_ - _tmp328_)); -#line 379 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp329_ = blue; -#line 379 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp330_ = p[2]; -#line 379 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp331_ = r; -#line 379 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp332_ = R; -#line 379 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp333_ = T; -#line 379 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp334_ = t; -#line 379 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - blue = _tmp329_ + ((_tmp330_ * (_tmp331_ - _tmp332_)) * (_tmp333_ - _tmp334_)); -#line 2484 "page-view.c" - } -#line 381 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp336_ = r; -#line 381 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp337_ = R; -#line 381 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - if (_tmp336_ != ((gdouble) _tmp337_)) { -#line 2492 "page-view.c" - gdouble _tmp338_ = 0.0; - gint _tmp339_ = 0; -#line 381 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp338_ = b; -#line 381 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp339_ = B; -#line 381 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp335_ = _tmp338_ != ((gdouble) _tmp339_); -#line 2501 "page-view.c" - } else { -#line 381 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp335_ = FALSE; -#line 2505 "page-view.c" - } -#line 381 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - if (_tmp335_) { -#line 2509 "page-view.c" - guchar p[3] = {0}; - Page* _tmp340_ = NULL; - gint _tmp341_ = 0; - gint _tmp342_ = 0; - gdouble _tmp343_ = 0.0; - guchar _tmp344_ = '\0'; - gdouble _tmp345_ = 0.0; - gint _tmp346_ = 0; - gdouble _tmp347_ = 0.0; - gint _tmp348_ = 0; - gdouble _tmp349_ = 0.0; - guchar _tmp350_ = '\0'; - gdouble _tmp351_ = 0.0; - gint _tmp352_ = 0; - gdouble _tmp353_ = 0.0; - gint _tmp354_ = 0; - gdouble _tmp355_ = 0.0; - guchar _tmp356_ = '\0'; - gdouble _tmp357_ = 0.0; - gint _tmp358_ = 0; - gdouble _tmp359_ = 0.0; - gint _tmp360_ = 0; -#line 384 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp340_ = page; -#line 384 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp341_ = R; -#line 384 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp342_ = B; -#line 384 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - page_view_get_pixel (self, _tmp340_, _tmp341_, _tmp342_, p, 3); -#line 385 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp343_ = red; -#line 385 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp344_ = p[0]; -#line 385 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp345_ = r; -#line 385 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp346_ = R; -#line 385 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp347_ = b; -#line 385 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp348_ = B; -#line 385 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - red = _tmp343_ + ((_tmp344_ * (_tmp345_ - _tmp346_)) * (_tmp347_ - _tmp348_)); -#line 386 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp349_ = green; -#line 386 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp350_ = p[1]; -#line 386 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp351_ = r; -#line 386 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp352_ = R; -#line 386 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp353_ = b; -#line 386 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp354_ = B; -#line 386 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - green = _tmp349_ + ((_tmp350_ * (_tmp351_ - _tmp352_)) * (_tmp353_ - _tmp354_)); -#line 387 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp355_ = blue; -#line 387 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp356_ = p[2]; -#line 387 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp357_ = r; -#line 387 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp358_ = R; -#line 387 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp359_ = b; -#line 387 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp360_ = B; -#line 387 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - blue = _tmp355_ + ((_tmp356_ * (_tmp357_ - _tmp358_)) * (_tmp359_ - _tmp360_)); -#line 2582 "page-view.c" - } -#line 389 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp362_ = l; -#line 389 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp363_ = L; -#line 389 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - if (_tmp362_ != ((gdouble) _tmp363_)) { -#line 2590 "page-view.c" - gdouble _tmp364_ = 0.0; - gint _tmp365_ = 0; -#line 389 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp364_ = b; -#line 389 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp365_ = B; -#line 389 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp361_ = _tmp364_ != ((gdouble) _tmp365_); -#line 2599 "page-view.c" - } else { -#line 389 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp361_ = FALSE; -#line 2603 "page-view.c" - } -#line 389 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - if (_tmp361_) { -#line 2607 "page-view.c" - guchar p[3] = {0}; - Page* _tmp366_ = NULL; - gint _tmp367_ = 0; - gint _tmp368_ = 0; - gdouble _tmp369_ = 0.0; - guchar _tmp370_ = '\0'; - gint _tmp371_ = 0; - gdouble _tmp372_ = 0.0; - gdouble _tmp373_ = 0.0; - gint _tmp374_ = 0; - gdouble _tmp375_ = 0.0; - guchar _tmp376_ = '\0'; - gint _tmp377_ = 0; - gdouble _tmp378_ = 0.0; - gdouble _tmp379_ = 0.0; - gint _tmp380_ = 0; - gdouble _tmp381_ = 0.0; - guchar _tmp382_ = '\0'; - gint _tmp383_ = 0; - gdouble _tmp384_ = 0.0; - gdouble _tmp385_ = 0.0; - gint _tmp386_ = 0; -#line 392 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp366_ = page; -#line 392 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp367_ = L; -#line 392 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp368_ = B; -#line 392 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - page_view_get_pixel (self, _tmp366_, _tmp367_ - 1, _tmp368_, p, 3); -#line 393 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp369_ = red; -#line 393 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp370_ = p[0]; -#line 393 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp371_ = L; -#line 393 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp372_ = l; -#line 393 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp373_ = b; -#line 393 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp374_ = B; -#line 393 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - red = _tmp369_ + ((_tmp370_ * (_tmp371_ - _tmp372_)) * (_tmp373_ - _tmp374_)); -#line 394 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp375_ = green; -#line 394 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp376_ = p[1]; -#line 394 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp377_ = L; -#line 394 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp378_ = l; -#line 394 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp379_ = b; -#line 394 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp380_ = B; -#line 394 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - green = _tmp375_ + ((_tmp376_ * (_tmp377_ - _tmp378_)) * (_tmp379_ - _tmp380_)); -#line 395 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp381_ = blue; -#line 395 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp382_ = p[2]; -#line 395 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp383_ = L; -#line 395 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp384_ = l; -#line 395 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp385_ = b; -#line 395 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp386_ = B; -#line 395 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - blue = _tmp381_ + ((_tmp382_ * (_tmp383_ - _tmp384_)) * (_tmp385_ - _tmp386_)); -#line 2680 "page-view.c" - } -#line 399 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp387_ = r; -#line 399 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp388_ = l; -#line 399 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp389_ = b; -#line 399 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp390_ = t; -#line 399 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - scale = 1.0 / ((_tmp387_ - _tmp388_) * (_tmp389_ - _tmp390_)); -#line 400 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp391_ = output; -#line 400 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp391__length1 = output_length1; -#line 400 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp392_ = offset; -#line 400 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp393_ = red; -#line 400 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp394_ = scale; -#line 400 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp391_[_tmp392_] = (guchar) ((_tmp393_ * _tmp394_) + 0.5); -#line 400 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp395_ = _tmp391_[_tmp392_]; -#line 401 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp396_ = output; -#line 401 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp396__length1 = output_length1; -#line 401 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp397_ = offset; -#line 401 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp398_ = green; -#line 401 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp399_ = scale; -#line 401 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp396_[_tmp397_ + 1] = (guchar) ((_tmp398_ * _tmp399_) + 0.5); -#line 401 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp400_ = _tmp396_[_tmp397_ + 1]; -#line 402 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp401_ = output; -#line 402 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp401__length1 = output_length1; -#line 402 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp402_ = offset; -#line 402 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp403_ = blue; -#line 402 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp404_ = scale; -#line 402 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp401_[_tmp402_ + 2] = (guchar) ((_tmp403_ * _tmp404_) + 0.5); -#line 402 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp405_ = _tmp401_[_tmp402_ + 2]; -#line 2734 "page-view.c" -} - - -static void page_view_update_preview (PageView* self, Page* page, GdkPixbuf** output_image, gint output_width, gint output_height, ScanDirection scan_direction, gint old_scan_line, gint scan_line) { - gint input_width = 0; - Page* _tmp0_ = NULL; - gint _tmp1_ = 0; - gint _tmp2_ = 0; - gint input_height = 0; - Page* _tmp3_ = NULL; - gint _tmp4_ = 0; - gint _tmp5_ = 0; - gint L = 0; - gint R = 0; - gint T = 0; - gint B = 0; - gboolean _tmp6_ = FALSE; - gboolean _tmp7_ = FALSE; - GdkPixbuf* _tmp8_ = NULL; - gint _tmp58_ = 0; - gint _tmp59_ = 0; - gint _tmp61_ = 0; - gint _tmp62_ = 0; - gint _tmp64_ = 0; - gint _tmp65_ = 0; - gint _tmp66_ = 0; - gint _tmp67_ = 0; - gint _tmp68_ = 0; - gint _tmp69_ = 0; - GdkPixbuf* _tmp70_ = NULL; - guchar* output = NULL; - GdkPixbuf* _tmp71_ = NULL; - guint8* _tmp72_ = NULL; - gint output_length1 = 0; - gint _output_size_ = 0; - gint output_rowstride = 0; - GdkPixbuf* _tmp73_ = NULL; - gint _tmp74_ = 0; - gint _tmp75_ = 0; - gint output_n_channels = 0; - GdkPixbuf* _tmp76_ = NULL; - gint _tmp77_ = 0; - gint _tmp78_ = 0; - Page* _tmp79_ = NULL; - gboolean _tmp80_ = FALSE; - gboolean _tmp81_ = FALSE; -#line 405 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - g_return_if_fail (self != NULL); -#line 405 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - g_return_if_fail (page != NULL); -#line 408 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp0_ = page; -#line 408 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp1_ = page_get_width (_tmp0_); -#line 408 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp2_ = _tmp1_; -#line 408 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - input_width = _tmp2_; -#line 409 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp3_ = page; -#line 409 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp4_ = page_get_height (_tmp3_); -#line 409 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp5_ = _tmp4_; -#line 409 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - input_height = _tmp5_; -#line 413 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp8_ = *output_image; -#line 413 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - if (_tmp8_ == NULL) { -#line 413 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp7_ = TRUE; -#line 2807 "page-view.c" - } else { - GdkPixbuf* _tmp9_ = NULL; - gint _tmp10_ = 0; - gint _tmp11_ = 0; - gint _tmp12_ = 0; -#line 414 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp9_ = *output_image; -#line 414 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp10_ = gdk_pixbuf_get_width (_tmp9_); -#line 414 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp11_ = _tmp10_; -#line 414 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp12_ = output_width; -#line 414 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp7_ = _tmp11_ != _tmp12_; -#line 2823 "page-view.c" - } -#line 413 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - if (_tmp7_) { -#line 413 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp6_ = TRUE; -#line 2829 "page-view.c" - } else { - GdkPixbuf* _tmp13_ = NULL; - gint _tmp14_ = 0; - gint _tmp15_ = 0; - gint _tmp16_ = 0; -#line 415 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp13_ = *output_image; -#line 415 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp14_ = gdk_pixbuf_get_height (_tmp13_); -#line 415 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp15_ = _tmp14_; -#line 415 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp16_ = output_height; -#line 415 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp6_ = _tmp15_ != _tmp16_; -#line 2845 "page-view.c" - } -#line 413 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - if (_tmp6_) { -#line 2849 "page-view.c" - gint _tmp17_ = 0; - gint _tmp18_ = 0; - GdkPixbuf* _tmp19_ = NULL; - gint _tmp20_ = 0; - gint _tmp21_ = 0; -#line 417 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp17_ = output_width; -#line 417 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp18_ = output_height; -#line 417 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp19_ = gdk_pixbuf_new (GDK_COLORSPACE_RGB, FALSE, 8, _tmp17_, _tmp18_); -#line 417 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _g_object_unref0 (*output_image); -#line 417 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - *output_image = _tmp19_; -#line 424 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - L = 0; -#line 425 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp20_ = output_width; -#line 425 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - R = _tmp20_ - 1; -#line 426 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - T = 0; -#line 427 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp21_ = output_height; -#line 427 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - B = _tmp21_ - 1; -#line 2877 "page-view.c" - } else { - ScanDirection _tmp22_ = 0; -#line 432 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp22_ = scan_direction; -#line 432 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - switch (_tmp22_) { -#line 432 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - case SCAN_DIRECTION_TOP_TO_BOTTOM: -#line 2886 "page-view.c" - { - gint _tmp23_ = 0; - gint _tmp24_ = 0; - gint _tmp25_ = 0; - gint _tmp26_ = 0; - gint _tmp27_ = 0; - gint _tmp28_ = 0; - gint _tmp29_ = 0; -#line 435 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - L = 0; -#line 436 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp23_ = output_width; -#line 436 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - R = _tmp23_ - 1; -#line 437 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp24_ = old_scan_line; -#line 437 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp25_ = output_height; -#line 437 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp26_ = input_height; -#line 437 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - T = (gint) ((((gdouble) _tmp24_) * _tmp25_) / _tmp26_); -#line 438 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp27_ = scan_line; -#line 438 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp28_ = output_height; -#line 438 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp29_ = input_height; -#line 438 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - B = (gint) (((((gdouble) _tmp27_) * _tmp28_) / _tmp29_) + 0.5); -#line 439 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - break; -#line 2919 "page-view.c" - } -#line 432 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - case SCAN_DIRECTION_LEFT_TO_RIGHT: -#line 2923 "page-view.c" - { - gint _tmp30_ = 0; - gint _tmp31_ = 0; - gint _tmp32_ = 0; - gint _tmp33_ = 0; - gint _tmp34_ = 0; - gint _tmp35_ = 0; - gint _tmp36_ = 0; -#line 441 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp30_ = old_scan_line; -#line 441 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp31_ = output_width; -#line 441 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp32_ = input_width; -#line 441 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - L = (gint) ((((gdouble) _tmp30_) * _tmp31_) / _tmp32_); -#line 442 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp33_ = scan_line; -#line 442 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp34_ = output_width; -#line 442 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp35_ = input_width; -#line 442 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - R = (gint) (((((gdouble) _tmp33_) * _tmp34_) / _tmp35_) + 0.5); -#line 443 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - T = 0; -#line 444 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp36_ = output_height; -#line 444 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - B = _tmp36_ - 1; -#line 445 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - break; -#line 2956 "page-view.c" - } -#line 432 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - case SCAN_DIRECTION_BOTTOM_TO_TOP: -#line 2960 "page-view.c" - { - gint _tmp37_ = 0; - gint _tmp38_ = 0; - gint _tmp39_ = 0; - gint _tmp40_ = 0; - gint _tmp41_ = 0; - gint _tmp42_ = 0; - gint _tmp43_ = 0; - gint _tmp44_ = 0; - gint _tmp45_ = 0; -#line 447 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - L = 0; -#line 448 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp37_ = output_width; -#line 448 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - R = _tmp37_ - 1; -#line 449 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp38_ = input_height; -#line 449 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp39_ = scan_line; -#line 449 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp40_ = output_height; -#line 449 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp41_ = input_height; -#line 449 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - T = (gint) ((((gdouble) (_tmp38_ - _tmp39_)) * _tmp40_) / _tmp41_); -#line 450 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp42_ = input_height; -#line 450 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp43_ = old_scan_line; -#line 450 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp44_ = output_height; -#line 450 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp45_ = input_height; -#line 450 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - B = (gint) (((((gdouble) (_tmp42_ - _tmp43_)) * _tmp44_) / _tmp45_) + 0.5); -#line 451 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - break; -#line 2999 "page-view.c" - } -#line 432 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - case SCAN_DIRECTION_RIGHT_TO_LEFT: -#line 3003 "page-view.c" - { - gint _tmp46_ = 0; - gint _tmp47_ = 0; - gint _tmp48_ = 0; - gint _tmp49_ = 0; - gint _tmp50_ = 0; - gint _tmp51_ = 0; - gint _tmp52_ = 0; - gint _tmp53_ = 0; - gint _tmp54_ = 0; -#line 453 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp46_ = input_width; -#line 453 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp47_ = scan_line; -#line 453 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp48_ = output_width; -#line 453 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp49_ = input_width; -#line 453 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - L = (gint) ((((gdouble) (_tmp46_ - _tmp47_)) * _tmp48_) / _tmp49_); -#line 454 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp50_ = input_width; -#line 454 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp51_ = old_scan_line; -#line 454 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp52_ = output_width; -#line 454 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp53_ = input_width; -#line 454 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - R = (gint) (((((gdouble) (_tmp50_ - _tmp51_)) * _tmp52_) / _tmp53_) + 0.5); -#line 455 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - T = 0; -#line 456 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp54_ = output_height; -#line 456 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - B = _tmp54_ - 1; -#line 457 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - break; -#line 3042 "page-view.c" - } - default: - { - gint _tmp55_ = 0; - gint _tmp56_ = 0; - gint _tmp57_ = 0; -#line 459 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - T = 0; -#line 459 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp55_ = T; -#line 459 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - B = _tmp55_; -#line 459 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp56_ = B; -#line 459 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - R = _tmp56_; -#line 459 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp57_ = R; -#line 459 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - L = _tmp57_; -#line 460 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - break; -#line 3065 "page-view.c" - } - } - } -#line 465 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp58_ = R; -#line 465 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp59_ = output_width; -#line 465 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - if (_tmp58_ >= _tmp59_) { -#line 3075 "page-view.c" - gint _tmp60_ = 0; -#line 466 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp60_ = output_width; -#line 466 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - R = _tmp60_ - 1; -#line 3081 "page-view.c" - } -#line 467 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp61_ = B; -#line 467 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp62_ = output_height; -#line 467 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - if (_tmp61_ >= _tmp62_) { -#line 3089 "page-view.c" - gint _tmp63_ = 0; -#line 468 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp63_ = output_height; -#line 468 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - B = _tmp63_ - 1; -#line 3095 "page-view.c" - } -#line 470 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp64_ = L; -#line 470 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - g_return_if_fail (_tmp64_ >= 0); -#line 471 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp65_ = R; -#line 471 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp66_ = output_width; -#line 471 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - g_return_if_fail (_tmp65_ < _tmp66_); -#line 472 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp67_ = T; -#line 472 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - g_return_if_fail (_tmp67_ >= 0); -#line 473 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp68_ = B; -#line 473 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp69_ = output_height; -#line 473 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - g_return_if_fail (_tmp68_ < _tmp69_); -#line 474 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp70_ = *output_image; -#line 474 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - g_return_if_fail (_tmp70_ != NULL); -#line 476 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp71_ = *output_image; -#line 476 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp72_ = gdk_pixbuf_get_pixels (_tmp71_); -#line 476 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - output = _tmp72_; -#line 476 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - output_length1 = -1; -#line 476 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _output_size_ = output_length1; -#line 477 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp73_ = *output_image; -#line 477 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp74_ = gdk_pixbuf_get_rowstride (_tmp73_); -#line 477 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp75_ = _tmp74_; -#line 477 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - output_rowstride = _tmp75_; -#line 478 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp76_ = *output_image; -#line 478 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp77_ = gdk_pixbuf_get_n_channels (_tmp76_); -#line 478 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp78_ = _tmp77_; -#line 478 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - output_n_channels = _tmp78_; -#line 480 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp79_ = page; -#line 480 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp80_ = page_get_has_data (_tmp79_); -#line 480 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp81_ = _tmp80_; -#line 480 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - if (!_tmp81_) { -#line 3155 "page-view.c" - { - gint x = 0; - gint _tmp82_ = 0; -#line 482 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp82_ = L; -#line 482 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - x = _tmp82_; -#line 3163 "page-view.c" - { - gboolean _tmp83_ = FALSE; -#line 482 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp83_ = TRUE; -#line 482 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - while (TRUE) { -#line 3170 "page-view.c" - gint _tmp85_ = 0; - gint _tmp86_ = 0; -#line 482 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - if (!_tmp83_) { -#line 3175 "page-view.c" - gint _tmp84_ = 0; -#line 482 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp84_ = x; -#line 482 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - x = _tmp84_ + 1; -#line 3181 "page-view.c" - } -#line 482 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp83_ = FALSE; -#line 482 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp85_ = x; -#line 482 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp86_ = R; -#line 482 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - if (!(_tmp85_ <= _tmp86_)) { -#line 482 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - break; -#line 3193 "page-view.c" - } - { - gint y = 0; - gint _tmp87_ = 0; -#line 483 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp87_ = T; -#line 483 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - y = _tmp87_; -#line 3202 "page-view.c" - { - gboolean _tmp88_ = FALSE; -#line 483 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp88_ = TRUE; -#line 483 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - while (TRUE) { -#line 3209 "page-view.c" - gint _tmp90_ = 0; - gint _tmp91_ = 0; - gint o = 0; - gint _tmp92_ = 0; - gint _tmp93_ = 0; - gint _tmp94_ = 0; - gint _tmp95_ = 0; - guchar* _tmp96_ = NULL; - gint _tmp96__length1 = 0; - gint _tmp97_ = 0; - guchar* _tmp98_ = NULL; - gint _tmp98__length1 = 0; - gint _tmp99_ = 0; - guchar* _tmp100_ = NULL; - gint _tmp100__length1 = 0; - gint _tmp101_ = 0; - guchar _tmp102_ = '\0'; - guchar _tmp103_ = '\0'; - guchar _tmp104_ = '\0'; -#line 483 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - if (!_tmp88_) { -#line 3231 "page-view.c" - gint _tmp89_ = 0; -#line 483 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp89_ = y; -#line 483 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - y = _tmp89_ + 1; -#line 3237 "page-view.c" - } -#line 483 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp88_ = FALSE; -#line 483 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp90_ = y; -#line 483 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp91_ = B; -#line 483 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - if (!(_tmp90_ <= _tmp91_)) { -#line 483 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - break; -#line 3249 "page-view.c" - } -#line 485 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp92_ = output_rowstride; -#line 485 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp93_ = y; -#line 485 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp94_ = x; -#line 485 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp95_ = output_n_channels; -#line 485 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - o = (_tmp92_ * _tmp93_) + (_tmp94_ * _tmp95_); -#line 486 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp96_ = output; -#line 486 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp96__length1 = output_length1; -#line 486 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp97_ = o; -#line 486 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp98_ = output; -#line 486 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp98__length1 = output_length1; -#line 486 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp99_ = o; -#line 486 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp100_ = output; -#line 486 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp100__length1 = output_length1; -#line 486 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp101_ = o; -#line 486 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp100_[_tmp101_ + 2] = (guchar) 0xFF; -#line 486 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp102_ = _tmp100_[_tmp101_ + 2]; -#line 486 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp98_[_tmp99_ + 1] = _tmp102_; -#line 486 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp103_ = _tmp98_[_tmp99_ + 1]; -#line 486 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp96_[_tmp97_] = _tmp103_; -#line 486 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp104_ = _tmp96_[_tmp97_]; -#line 3291 "page-view.c" - } - } - } - } - } - } -#line 488 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - return; -#line 3300 "page-view.c" - } - { - gint x = 0; - gint _tmp105_ = 0; -#line 492 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp105_ = L; -#line 492 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - x = _tmp105_; -#line 3309 "page-view.c" - { - gboolean _tmp106_ = FALSE; -#line 492 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp106_ = TRUE; -#line 492 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - while (TRUE) { -#line 3316 "page-view.c" - gint _tmp108_ = 0; - gint _tmp109_ = 0; - gdouble l = 0.0; - gint _tmp110_ = 0; - gint _tmp111_ = 0; - gint _tmp112_ = 0; - gdouble r = 0.0; - gint _tmp113_ = 0; - gint _tmp114_ = 0; - gint _tmp115_ = 0; -#line 492 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - if (!_tmp106_) { -#line 3329 "page-view.c" - gint _tmp107_ = 0; -#line 492 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp107_ = x; -#line 492 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - x = _tmp107_ + 1; -#line 3335 "page-view.c" - } -#line 492 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp106_ = FALSE; -#line 492 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp108_ = x; -#line 492 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp109_ = R; -#line 492 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - if (!(_tmp108_ <= _tmp109_)) { -#line 492 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - break; -#line 3347 "page-view.c" - } -#line 494 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp110_ = x; -#line 494 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp111_ = input_width; -#line 494 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp112_ = output_width; -#line 494 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - l = (((gdouble) _tmp110_) * _tmp111_) / _tmp112_; -#line 495 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp113_ = x; -#line 495 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp114_ = input_width; -#line 495 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp115_ = output_width; -#line 495 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - r = (((gdouble) (_tmp113_ + 1)) * _tmp114_) / _tmp115_; -#line 3365 "page-view.c" - { - gint y = 0; - gint _tmp116_ = 0; -#line 497 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp116_ = T; -#line 497 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - y = _tmp116_; -#line 3373 "page-view.c" - { - gboolean _tmp117_ = FALSE; -#line 497 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp117_ = TRUE; -#line 497 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - while (TRUE) { -#line 3380 "page-view.c" - gint _tmp119_ = 0; - gint _tmp120_ = 0; - gdouble t = 0.0; - gint _tmp121_ = 0; - gint _tmp122_ = 0; - gint _tmp123_ = 0; - gdouble b = 0.0; - gint _tmp124_ = 0; - gint _tmp125_ = 0; - gint _tmp126_ = 0; - Page* _tmp127_ = NULL; - gdouble _tmp128_ = 0.0; - gdouble _tmp129_ = 0.0; - gdouble _tmp130_ = 0.0; - gdouble _tmp131_ = 0.0; - guchar* _tmp132_ = NULL; - gint _tmp132__length1 = 0; - gint _tmp133_ = 0; - gint _tmp134_ = 0; - gint _tmp135_ = 0; - gint _tmp136_ = 0; -#line 497 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - if (!_tmp117_) { -#line 3404 "page-view.c" - gint _tmp118_ = 0; -#line 497 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp118_ = y; -#line 497 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - y = _tmp118_ + 1; -#line 3410 "page-view.c" - } -#line 497 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp117_ = FALSE; -#line 497 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp119_ = y; -#line 497 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp120_ = B; -#line 497 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - if (!(_tmp119_ <= _tmp120_)) { -#line 497 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - break; -#line 3422 "page-view.c" - } -#line 499 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp121_ = y; -#line 499 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp122_ = input_height; -#line 499 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp123_ = output_height; -#line 499 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - t = (((gdouble) _tmp121_) * _tmp122_) / _tmp123_; -#line 500 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp124_ = y; -#line 500 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp125_ = input_height; -#line 500 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp126_ = output_height; -#line 500 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - b = (((gdouble) (_tmp124_ + 1)) * _tmp125_) / _tmp126_; -#line 502 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp127_ = page; -#line 502 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp128_ = l; -#line 502 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp129_ = r; -#line 502 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp130_ = t; -#line 502 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp131_ = b; -#line 502 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp132_ = output; -#line 502 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp132__length1 = output_length1; -#line 502 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp133_ = output_rowstride; -#line 502 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp134_ = y; -#line 502 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp135_ = x; -#line 502 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp136_ = output_n_channels; -#line 502 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - page_view_set_pixel (self, _tmp127_, _tmp128_, _tmp129_, _tmp130_, _tmp131_, _tmp132_, _tmp132__length1, (_tmp133_ * _tmp134_) + (_tmp135_ * _tmp136_)); -#line 3464 "page-view.c" - } - } - } - } - } - } -} - - -static gint page_view_get_preview_width (PageView* self) { - gint result = 0; - gint _tmp0_ = 0; - gint _tmp1_ = 0; -#line 509 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - g_return_val_if_fail (self != NULL, 0); -#line 511 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp0_ = self->priv->width_; -#line 511 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp1_ = self->priv->border_width; -#line 511 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - result = _tmp0_ - (_tmp1_ * 2); -#line 511 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - return result; -#line 3488 "page-view.c" -} - - -static gint page_view_get_preview_height (PageView* self) { - gint result = 0; - gint _tmp0_ = 0; - gint _tmp1_ = 0; -#line 514 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - g_return_val_if_fail (self != NULL, 0); -#line 516 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp0_ = self->priv->height_; -#line 516 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp1_ = self->priv->border_width; -#line 516 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - result = _tmp0_ - (_tmp1_ * 2); -#line 516 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - return result; -#line 3506 "page-view.c" -} - - -static void page_view_update_page_view (PageView* self) { - gboolean _tmp0_ = FALSE; - gint old_scan_line = 0; - gint _tmp1_ = 0; - gint scan_line = 0; - Page* _tmp2_ = NULL; - gint _tmp3_ = 0; - gint _tmp4_ = 0; - ScanDirection left_steps = 0; - ScanDirection _tmp5_ = 0; - Page* _tmp6_ = NULL; - ScanDirection _tmp7_ = 0; - ScanDirection _tmp8_ = 0; - gboolean _tmp9_ = FALSE; - ScanDirection _tmp10_ = 0; - Page* _tmp12_ = NULL; - ScanDirection _tmp13_ = 0; - ScanDirection _tmp14_ = 0; - Page* _tmp15_ = NULL; - gint _tmp16_ = 0; - gint _tmp17_ = 0; - Page* _tmp18_ = NULL; - ScanDirection _tmp19_ = 0; - ScanDirection _tmp20_ = 0; - gint _tmp21_ = 0; - gint _tmp22_ = 0; - gint _tmp23_ = 0; -#line 519 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - g_return_if_fail (self != NULL); -#line 521 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp0_ = self->priv->update_image; -#line 521 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - if (!_tmp0_) { -#line 522 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - return; -#line 3545 "page-view.c" - } -#line 524 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp1_ = self->priv->scan_line; -#line 524 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - old_scan_line = _tmp1_; -#line 525 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp2_ = self->priv->_page; -#line 525 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp3_ = page_get_scan_line (_tmp2_); -#line 525 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp4_ = _tmp3_; -#line 525 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - scan_line = _tmp4_; -#line 528 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp5_ = self->priv->scan_direction; -#line 528 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp6_ = self->priv->_page; -#line 528 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp7_ = page_get_scan_direction (_tmp6_); -#line 528 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp8_ = _tmp7_; -#line 528 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - left_steps = _tmp5_ - _tmp8_; -#line 529 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp10_ = left_steps; -#line 529 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - if (_tmp10_ != 0) { -#line 3573 "page-view.c" - GdkPixbuf* _tmp11_ = NULL; -#line 529 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp11_ = self->priv->image; -#line 529 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp9_ = _tmp11_ != NULL; -#line 3579 "page-view.c" - } else { -#line 529 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp9_ = FALSE; -#line 3583 "page-view.c" - } -#line 529 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - if (_tmp9_) { -#line 530 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _g_object_unref0 (self->priv->image); -#line 530 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - self->priv->image = NULL; -#line 3591 "page-view.c" - } -#line 531 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp12_ = self->priv->_page; -#line 531 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp13_ = page_get_scan_direction (_tmp12_); -#line 531 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp14_ = _tmp13_; -#line 531 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - self->priv->scan_direction = _tmp14_; -#line 533 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp15_ = self->priv->_page; -#line 533 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp16_ = page_view_get_preview_width (self); -#line 533 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp17_ = page_view_get_preview_height (self); -#line 533 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp18_ = self->priv->_page; -#line 533 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp19_ = page_get_scan_direction (_tmp18_); -#line 533 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp20_ = _tmp19_; -#line 533 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp21_ = old_scan_line; -#line 533 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp22_ = scan_line; -#line 533 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - page_view_update_preview (self, _tmp15_, &self->priv->image, _tmp16_, _tmp17_, _tmp20_, _tmp21_, _tmp22_); -#line 539 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - self->priv->update_image = FALSE; -#line 540 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp23_ = scan_line; -#line 540 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - self->priv->scan_line = _tmp23_; -#line 3625 "page-view.c" -} - - -static gint page_view_page_to_screen_x (PageView* self, gint x) { - gint result = 0; - gint _tmp0_ = 0; - gint _tmp1_ = 0; - Page* _tmp2_ = NULL; - gint _tmp3_ = 0; - gint _tmp4_ = 0; -#line 543 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - g_return_val_if_fail (self != NULL, 0); -#line 545 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp0_ = x; -#line 545 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp1_ = page_view_get_preview_width (self); -#line 545 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp2_ = self->priv->_page; -#line 545 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp3_ = page_get_width (_tmp2_); -#line 545 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp4_ = _tmp3_; -#line 545 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - result = (gint) (((((gdouble) _tmp0_) * _tmp1_) / _tmp4_) + 0.5); -#line 545 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - return result; -#line 3652 "page-view.c" -} - - -static gint page_view_page_to_screen_y (PageView* self, gint y) { - gint result = 0; - gint _tmp0_ = 0; - gint _tmp1_ = 0; - Page* _tmp2_ = NULL; - gint _tmp3_ = 0; - gint _tmp4_ = 0; -#line 548 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - g_return_val_if_fail (self != NULL, 0); -#line 550 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp0_ = y; -#line 550 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp1_ = page_view_get_preview_height (self); -#line 550 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp2_ = self->priv->_page; -#line 550 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp3_ = page_get_height (_tmp2_); -#line 550 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp4_ = _tmp3_; -#line 550 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - result = (gint) (((((gdouble) _tmp0_) * _tmp1_) / _tmp4_) + 0.5); -#line 550 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - return result; -#line 3679 "page-view.c" -} - - -static gint page_view_screen_to_page_x (PageView* self, gint x) { - gint result = 0; - gint _tmp0_ = 0; - Page* _tmp1_ = NULL; - gint _tmp2_ = 0; - gint _tmp3_ = 0; - gint _tmp4_ = 0; -#line 553 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - g_return_val_if_fail (self != NULL, 0); -#line 555 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp0_ = x; -#line 555 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp1_ = self->priv->_page; -#line 555 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp2_ = page_get_width (_tmp1_); -#line 555 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp3_ = _tmp2_; -#line 555 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp4_ = page_view_get_preview_width (self); -#line 555 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - result = (gint) (((((gdouble) _tmp0_) * _tmp3_) / _tmp4_) + 0.5); -#line 555 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - return result; -#line 3706 "page-view.c" -} - - -static gint page_view_screen_to_page_y (PageView* self, gint y) { - gint result = 0; - gint _tmp0_ = 0; - Page* _tmp1_ = NULL; - gint _tmp2_ = 0; - gint _tmp3_ = 0; - gint _tmp4_ = 0; -#line 558 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - g_return_val_if_fail (self != NULL, 0); -#line 560 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp0_ = y; -#line 560 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp1_ = self->priv->_page; -#line 560 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp2_ = page_get_height (_tmp1_); -#line 560 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp3_ = _tmp2_; -#line 560 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp4_ = page_view_get_preview_height (self); -#line 560 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - result = (gint) (((((gdouble) _tmp0_) * _tmp3_) / _tmp4_) + 0.5); -#line 560 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - return result; -#line 3733 "page-view.c" -} - - -static CropLocation page_view_get_crop_location (PageView* self, gint x, gint y) { - CropLocation result = 0; - Page* _tmp0_ = NULL; - gboolean _tmp1_ = FALSE; - gboolean _tmp2_ = FALSE; - gint cx = 0; - Page* _tmp3_ = NULL; - gint _tmp4_ = 0; - gint _tmp5_ = 0; - gint cy = 0; - Page* _tmp6_ = NULL; - gint _tmp7_ = 0; - gint _tmp8_ = 0; - gint cw = 0; - Page* _tmp9_ = NULL; - gint _tmp10_ = 0; - gint _tmp11_ = 0; - gint ch = 0; - Page* _tmp12_ = NULL; - gint _tmp13_ = 0; - gint _tmp14_ = 0; - gint dx = 0; - gint _tmp15_ = 0; - gint _tmp16_ = 0; - gint dy = 0; - gint _tmp17_ = 0; - gint _tmp18_ = 0; - gint dw = 0; - gint _tmp19_ = 0; - gint _tmp20_ = 0; - gint dh = 0; - gint _tmp21_ = 0; - gint _tmp22_ = 0; - gint ix = 0; - gint _tmp23_ = 0; - gint _tmp24_ = 0; - gint iy = 0; - gint _tmp25_ = 0; - gint _tmp26_ = 0; - gboolean _tmp27_ = FALSE; - gboolean _tmp28_ = FALSE; - gboolean _tmp29_ = FALSE; - gint _tmp30_ = 0; - gchar* name = NULL; - Page* _tmp36_ = NULL; - const gchar* _tmp37_ = NULL; - const gchar* _tmp38_ = NULL; - gchar* _tmp39_ = NULL; - const gchar* _tmp40_ = NULL; - gint crop_border = 0; - gint _tmp41_ = 0; - gint _tmp42_ = 0; - gint _tmp44_ = 0; - gint _tmp45_ = 0; - gboolean _tmp47_ = FALSE; - gint _tmp48_ = 0; - gint _tmp49_ = 0; - gboolean _tmp52_ = FALSE; - gint _tmp53_ = 0; - gint _tmp54_ = 0; - gint _tmp55_ = 0; - gboolean _tmp58_ = FALSE; - gint _tmp59_ = 0; - gint _tmp60_ = 0; - gboolean _tmp64_ = FALSE; - gint _tmp65_ = 0; - gint _tmp66_ = 0; - gint _tmp67_ = 0; - gint _tmp71_ = 0; - gint _tmp72_ = 0; - gint _tmp73_ = 0; - gint _tmp74_ = 0; - gint _tmp75_ = 0; - gint _tmp76_ = 0; - gint _tmp77_ = 0; - gint _tmp78_ = 0; - gint _tmp79_ = 0; - gint _tmp80_ = 0; -#line 563 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - g_return_val_if_fail (self != NULL, 0); -#line 565 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp0_ = self->priv->_page; -#line 565 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp1_ = page_get_has_crop (_tmp0_); -#line 565 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp2_ = _tmp1_; -#line 565 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - if (!_tmp2_) { -#line 566 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - result = 0; -#line 566 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - return result; -#line 3829 "page-view.c" - } -#line 568 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp3_ = self->priv->_page; -#line 568 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp4_ = page_get_crop_x (_tmp3_); -#line 568 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp5_ = _tmp4_; -#line 568 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - cx = _tmp5_; -#line 569 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp6_ = self->priv->_page; -#line 569 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp7_ = page_get_crop_y (_tmp6_); -#line 569 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp8_ = _tmp7_; -#line 569 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - cy = _tmp8_; -#line 570 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp9_ = self->priv->_page; -#line 570 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp10_ = page_get_crop_width (_tmp9_); -#line 570 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp11_ = _tmp10_; -#line 570 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - cw = _tmp11_; -#line 571 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp12_ = self->priv->_page; -#line 571 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp13_ = page_get_crop_height (_tmp12_); -#line 571 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp14_ = _tmp13_; -#line 571 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - ch = _tmp14_; -#line 572 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp15_ = cx; -#line 572 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp16_ = page_view_page_to_screen_x (self, _tmp15_); -#line 572 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - dx = _tmp16_; -#line 573 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp17_ = cy; -#line 573 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp18_ = page_view_page_to_screen_y (self, _tmp17_); -#line 573 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - dy = _tmp18_; -#line 574 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp19_ = cw; -#line 574 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp20_ = page_view_page_to_screen_x (self, _tmp19_); -#line 574 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - dw = _tmp20_; -#line 575 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp21_ = ch; -#line 575 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp22_ = page_view_page_to_screen_y (self, _tmp21_); -#line 575 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - dh = _tmp22_; -#line 576 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp23_ = x; -#line 576 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp24_ = dx; -#line 576 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - ix = _tmp23_ - _tmp24_; -#line 577 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp25_ = y; -#line 577 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp26_ = dy; -#line 577 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - iy = _tmp25_ - _tmp26_; -#line 579 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp30_ = ix; -#line 579 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - if (_tmp30_ < 0) { -#line 579 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp29_ = TRUE; -#line 3905 "page-view.c" - } else { - gint _tmp31_ = 0; - gint _tmp32_ = 0; -#line 579 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp31_ = ix; -#line 579 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp32_ = dw; -#line 579 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp29_ = _tmp31_ > _tmp32_; -#line 3915 "page-view.c" - } -#line 579 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - if (_tmp29_) { -#line 579 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp28_ = TRUE; -#line 3921 "page-view.c" - } else { - gint _tmp33_ = 0; -#line 579 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp33_ = iy; -#line 579 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp28_ = _tmp33_ < 0; -#line 3928 "page-view.c" - } -#line 579 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - if (_tmp28_) { -#line 579 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp27_ = TRUE; -#line 3934 "page-view.c" - } else { - gint _tmp34_ = 0; - gint _tmp35_ = 0; -#line 579 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp34_ = iy; -#line 579 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp35_ = dh; -#line 579 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp27_ = _tmp34_ > _tmp35_; -#line 3944 "page-view.c" - } -#line 579 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - if (_tmp27_) { -#line 580 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - result = CROP_LOCATION_NONE; -#line 580 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - return result; -#line 3952 "page-view.c" - } -#line 583 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp36_ = self->priv->_page; -#line 583 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp37_ = page_get_crop_name (_tmp36_); -#line 583 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp38_ = _tmp37_; -#line 583 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp39_ = g_strdup (_tmp38_); -#line 583 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - name = _tmp39_; -#line 584 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp40_ = name; -#line 584 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - if (_tmp40_ != NULL) { -#line 585 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - result = CROP_LOCATION_MIDDLE; -#line 585 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _g_free0 (name); -#line 585 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - return result; -#line 3974 "page-view.c" - } -#line 588 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - crop_border = 20; -#line 589 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp41_ = dw; -#line 589 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp42_ = crop_border; -#line 589 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - if (_tmp41_ < (_tmp42_ * 3)) { -#line 3984 "page-view.c" - gint _tmp43_ = 0; -#line 590 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp43_ = dw; -#line 590 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - crop_border = _tmp43_ / 3; -#line 3990 "page-view.c" - } -#line 591 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp44_ = dh; -#line 591 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp45_ = crop_border; -#line 591 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - if (_tmp44_ < (_tmp45_ * 3)) { -#line 3998 "page-view.c" - gint _tmp46_ = 0; -#line 592 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp46_ = dh; -#line 592 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - crop_border = _tmp46_ / 3; -#line 4004 "page-view.c" - } -#line 595 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp48_ = ix; -#line 595 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp49_ = crop_border; -#line 595 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - if (_tmp48_ < _tmp49_) { -#line 4012 "page-view.c" - gint _tmp50_ = 0; - gint _tmp51_ = 0; -#line 595 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp50_ = iy; -#line 595 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp51_ = crop_border; -#line 595 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp47_ = _tmp50_ < _tmp51_; -#line 4021 "page-view.c" - } else { -#line 595 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp47_ = FALSE; -#line 4025 "page-view.c" - } -#line 595 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - if (_tmp47_) { -#line 596 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - result = CROP_LOCATION_TOP_LEFT; -#line 596 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _g_free0 (name); -#line 596 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - return result; -#line 4035 "page-view.c" - } -#line 598 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp53_ = ix; -#line 598 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp54_ = dw; -#line 598 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp55_ = crop_border; -#line 598 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - if (_tmp53_ > (_tmp54_ - _tmp55_)) { -#line 4045 "page-view.c" - gint _tmp56_ = 0; - gint _tmp57_ = 0; -#line 598 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp56_ = iy; -#line 598 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp57_ = crop_border; -#line 598 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp52_ = _tmp56_ < _tmp57_; -#line 4054 "page-view.c" - } else { -#line 598 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp52_ = FALSE; -#line 4058 "page-view.c" - } -#line 598 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - if (_tmp52_) { -#line 599 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - result = CROP_LOCATION_TOP_RIGHT; -#line 599 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _g_free0 (name); -#line 599 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - return result; -#line 4068 "page-view.c" - } -#line 601 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp59_ = ix; -#line 601 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp60_ = crop_border; -#line 601 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - if (_tmp59_ < _tmp60_) { -#line 4076 "page-view.c" - gint _tmp61_ = 0; - gint _tmp62_ = 0; - gint _tmp63_ = 0; -#line 601 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp61_ = iy; -#line 601 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp62_ = dh; -#line 601 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp63_ = crop_border; -#line 601 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp58_ = _tmp61_ > (_tmp62_ - _tmp63_); -#line 4088 "page-view.c" - } else { -#line 601 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp58_ = FALSE; -#line 4092 "page-view.c" - } -#line 601 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - if (_tmp58_) { -#line 602 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - result = CROP_LOCATION_BOTTOM_LEFT; -#line 602 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _g_free0 (name); -#line 602 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - return result; -#line 4102 "page-view.c" - } -#line 604 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp65_ = ix; -#line 604 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp66_ = dw; -#line 604 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp67_ = crop_border; -#line 604 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - if (_tmp65_ > (_tmp66_ - _tmp67_)) { -#line 4112 "page-view.c" - gint _tmp68_ = 0; - gint _tmp69_ = 0; - gint _tmp70_ = 0; -#line 604 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp68_ = iy; -#line 604 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp69_ = dh; -#line 604 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp70_ = crop_border; -#line 604 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp64_ = _tmp68_ > (_tmp69_ - _tmp70_); -#line 4124 "page-view.c" - } else { -#line 604 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp64_ = FALSE; -#line 4128 "page-view.c" - } -#line 604 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - if (_tmp64_) { -#line 605 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - result = CROP_LOCATION_BOTTOM_RIGHT; -#line 605 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _g_free0 (name); -#line 605 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - return result; -#line 4138 "page-view.c" - } -#line 608 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp71_ = ix; -#line 608 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp72_ = crop_border; -#line 608 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - if (_tmp71_ < _tmp72_) { -#line 609 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - result = CROP_LOCATION_LEFT; -#line 609 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _g_free0 (name); -#line 609 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - return result; -#line 4152 "page-view.c" - } -#line 611 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp73_ = ix; -#line 611 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp74_ = dw; -#line 611 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp75_ = crop_border; -#line 611 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - if (_tmp73_ > (_tmp74_ - _tmp75_)) { -#line 612 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - result = CROP_LOCATION_RIGHT; -#line 612 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _g_free0 (name); -#line 612 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - return result; -#line 4168 "page-view.c" - } -#line 614 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp76_ = iy; -#line 614 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp77_ = crop_border; -#line 614 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - if (_tmp76_ < _tmp77_) { -#line 615 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - result = CROP_LOCATION_TOP; -#line 615 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _g_free0 (name); -#line 615 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - return result; -#line 4182 "page-view.c" - } -#line 617 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp78_ = iy; -#line 617 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp79_ = dh; -#line 617 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp80_ = crop_border; -#line 617 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - if (_tmp78_ > (_tmp79_ - _tmp80_)) { -#line 618 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - result = CROP_LOCATION_BOTTOM; -#line 618 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _g_free0 (name); -#line 618 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - return result; -#line 4198 "page-view.c" - } -#line 621 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - result = CROP_LOCATION_MIDDLE; -#line 621 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _g_free0 (name); -#line 621 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - return result; -#line 4206 "page-view.c" -} - - -void page_view_button_press (PageView* self, gint x, gint y) { - CropLocation location = 0; - gint _tmp0_ = 0; - gint _tmp1_ = 0; - CropLocation _tmp2_ = 0; - CropLocation _tmp3_ = 0; -#line 624 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - g_return_if_fail (self != NULL); -#line 627 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp0_ = x; -#line 627 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp1_ = y; -#line 627 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp2_ = page_view_get_crop_location (self, _tmp0_, _tmp1_); -#line 627 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - location = _tmp2_; -#line 628 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp3_ = location; -#line 628 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - if (_tmp3_ != CROP_LOCATION_NONE) { -#line 4230 "page-view.c" - CropLocation _tmp4_ = 0; - gint _tmp5_ = 0; - gint _tmp6_ = 0; - Page* _tmp7_ = NULL; - gint _tmp8_ = 0; - gint _tmp9_ = 0; - Page* _tmp10_ = NULL; - gint _tmp11_ = 0; - gint _tmp12_ = 0; - Page* _tmp13_ = NULL; - gint _tmp14_ = 0; - gint _tmp15_ = 0; - Page* _tmp16_ = NULL; - gint _tmp17_ = 0; - gint _tmp18_ = 0; -#line 630 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp4_ = location; -#line 630 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - self->priv->crop_location = _tmp4_; -#line 631 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp5_ = x; -#line 631 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - self->priv->selected_crop_px = (gdouble) _tmp5_; -#line 632 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp6_ = y; -#line 632 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - self->priv->selected_crop_py = (gdouble) _tmp6_; -#line 633 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp7_ = self->priv->_page; -#line 633 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp8_ = page_get_crop_x (_tmp7_); -#line 633 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp9_ = _tmp8_; -#line 633 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - self->priv->selected_crop_x = _tmp9_; -#line 634 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp10_ = self->priv->_page; -#line 634 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp11_ = page_get_crop_y (_tmp10_); -#line 634 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp12_ = _tmp11_; -#line 634 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - self->priv->selected_crop_y = _tmp12_; -#line 635 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp13_ = self->priv->_page; -#line 635 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp14_ = page_get_crop_width (_tmp13_); -#line 635 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp15_ = _tmp14_; -#line 635 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - self->priv->selected_crop_w = _tmp15_; -#line 636 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp16_ = self->priv->_page; -#line 636 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp17_ = page_get_crop_height (_tmp16_); -#line 636 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp18_ = _tmp17_; -#line 636 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - self->priv->selected_crop_h = _tmp18_; -#line 4290 "page-view.c" - } -} - - -void page_view_motion (PageView* self, gint x, gint y) { - CropLocation location = 0; - gint _tmp0_ = 0; - gint _tmp1_ = 0; - CropLocation _tmp2_ = 0; - GdkCursorType cursor = 0; - CropLocation _tmp3_ = 0; - CropLocation _tmp4_ = 0; - gint pw = 0; - Page* _tmp6_ = NULL; - gint _tmp7_ = 0; - gint _tmp8_ = 0; - gint ph = 0; - Page* _tmp9_ = NULL; - gint _tmp10_ = 0; - gint _tmp11_ = 0; - gint cw = 0; - Page* _tmp12_ = NULL; - gint _tmp13_ = 0; - gint _tmp14_ = 0; - gint ch = 0; - Page* _tmp15_ = NULL; - gint _tmp16_ = 0; - gint _tmp17_ = 0; - gint dx = 0; - gint _tmp18_ = 0; - gdouble _tmp19_ = 0.0; - gint _tmp20_ = 0; - gint dy = 0; - gint _tmp21_ = 0; - gdouble _tmp22_ = 0.0; - gint _tmp23_ = 0; - gint new_x = 0; - gint _tmp24_ = 0; - gint new_y = 0; - gint _tmp25_ = 0; - gint new_w = 0; - gint _tmp26_ = 0; - gint new_h = 0; - gint _tmp27_ = 0; - gint min_size = 0; - gint _tmp28_ = 0; - gboolean _tmp29_ = FALSE; - gboolean _tmp30_ = FALSE; - CropLocation _tmp31_ = 0; - gboolean _tmp42_ = FALSE; - gboolean _tmp43_ = FALSE; - CropLocation _tmp44_ = 0; - gboolean _tmp55_ = FALSE; - gboolean _tmp56_ = FALSE; - CropLocation _tmp57_ = 0; - gboolean _tmp72_ = FALSE; - gboolean _tmp73_ = FALSE; - CropLocation _tmp74_ = 0; - CropLocation _tmp89_ = 0; - CropLocation _tmp110_ = 0; - gboolean _tmp115_ = FALSE; - gboolean _tmp116_ = FALSE; - CropLocation _tmp117_ = 0; - gboolean _tmp124_ = FALSE; - gboolean _tmp125_ = FALSE; - CropLocation _tmp126_ = 0; - gboolean _tmp133_ = FALSE; - gboolean _tmp134_ = FALSE; - CropLocation _tmp135_ = 0; - gboolean _tmp140_ = FALSE; - gboolean _tmp141_ = FALSE; - CropLocation _tmp142_ = 0; - Page* _tmp147_ = NULL; - gint _tmp148_ = 0; - gint _tmp149_ = 0; - gboolean _tmp150_ = FALSE; - gint _tmp151_ = 0; - gint _tmp152_ = 0; -#line 640 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - g_return_if_fail (self != NULL); -#line 642 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp0_ = x; -#line 642 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp1_ = y; -#line 642 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp2_ = page_view_get_crop_location (self, _tmp0_, _tmp1_); -#line 642 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - location = _tmp2_; -#line 644 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp3_ = location; -#line 644 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - switch (_tmp3_) { -#line 644 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - case CROP_LOCATION_MIDDLE: -#line 4385 "page-view.c" - { -#line 647 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - cursor = GDK_HAND1; -#line 648 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - break; -#line 4391 "page-view.c" - } -#line 644 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - case CROP_LOCATION_TOP: -#line 4395 "page-view.c" - { -#line 650 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - cursor = GDK_TOP_SIDE; -#line 651 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - break; -#line 4401 "page-view.c" - } -#line 644 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - case CROP_LOCATION_BOTTOM: -#line 4405 "page-view.c" - { -#line 653 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - cursor = GDK_BOTTOM_SIDE; -#line 654 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - break; -#line 4411 "page-view.c" - } -#line 644 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - case CROP_LOCATION_LEFT: -#line 4415 "page-view.c" - { -#line 656 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - cursor = GDK_LEFT_SIDE; -#line 657 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - break; -#line 4421 "page-view.c" - } -#line 644 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - case CROP_LOCATION_RIGHT: -#line 4425 "page-view.c" - { -#line 659 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - cursor = GDK_RIGHT_SIDE; -#line 660 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - break; -#line 4431 "page-view.c" - } -#line 644 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - case CROP_LOCATION_TOP_LEFT: -#line 4435 "page-view.c" - { -#line 662 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - cursor = GDK_TOP_LEFT_CORNER; -#line 663 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - break; -#line 4441 "page-view.c" - } -#line 644 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - case CROP_LOCATION_TOP_RIGHT: -#line 4445 "page-view.c" - { -#line 665 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - cursor = GDK_TOP_RIGHT_CORNER; -#line 666 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - break; -#line 4451 "page-view.c" - } -#line 644 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - case CROP_LOCATION_BOTTOM_LEFT: -#line 4455 "page-view.c" - { -#line 668 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - cursor = GDK_BOTTOM_LEFT_CORNER; -#line 669 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - break; -#line 4461 "page-view.c" - } -#line 644 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - case CROP_LOCATION_BOTTOM_RIGHT: -#line 4465 "page-view.c" - { -#line 671 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - cursor = GDK_BOTTOM_RIGHT_CORNER; -#line 672 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - break; -#line 4471 "page-view.c" - } - default: - { -#line 674 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - cursor = GDK_ARROW; -#line 675 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - break; -#line 4479 "page-view.c" - } - } -#line 678 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp4_ = self->priv->crop_location; -#line 678 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - if (_tmp4_ == CROP_LOCATION_NONE) { -#line 4486 "page-view.c" - GdkCursorType _tmp5_ = 0; -#line 680 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp5_ = cursor; -#line 680 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - page_view_set_cursor (self, _tmp5_); -#line 681 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - return; -#line 4494 "page-view.c" - } -#line 685 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp6_ = self->priv->_page; -#line 685 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp7_ = page_get_width (_tmp6_); -#line 685 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp8_ = _tmp7_; -#line 685 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - pw = _tmp8_; -#line 686 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp9_ = self->priv->_page; -#line 686 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp10_ = page_get_height (_tmp9_); -#line 686 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp11_ = _tmp10_; -#line 686 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - ph = _tmp11_; -#line 687 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp12_ = self->priv->_page; -#line 687 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp13_ = page_get_crop_width (_tmp12_); -#line 687 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp14_ = _tmp13_; -#line 687 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - cw = _tmp14_; -#line 688 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp15_ = self->priv->_page; -#line 688 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp16_ = page_get_crop_height (_tmp15_); -#line 688 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp17_ = _tmp16_; -#line 688 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - ch = _tmp17_; -#line 690 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp18_ = x; -#line 690 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp19_ = self->priv->selected_crop_px; -#line 690 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp20_ = page_view_screen_to_page_x (self, _tmp18_ - ((gint) _tmp19_)); -#line 690 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - dx = _tmp20_; -#line 691 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp21_ = y; -#line 691 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp22_ = self->priv->selected_crop_py; -#line 691 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp23_ = page_view_screen_to_page_y (self, _tmp21_ - ((gint) _tmp22_)); -#line 691 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - dy = _tmp23_; -#line 693 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp24_ = self->priv->selected_crop_x; -#line 693 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - new_x = _tmp24_; -#line 694 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp25_ = self->priv->selected_crop_y; -#line 694 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - new_y = _tmp25_; -#line 695 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp26_ = self->priv->selected_crop_w; -#line 695 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - new_w = _tmp26_; -#line 696 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp27_ = self->priv->selected_crop_h; -#line 696 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - new_h = _tmp27_; -#line 699 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp28_ = page_view_screen_to_page_x (self, 15); -#line 699 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - min_size = _tmp28_; -#line 700 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp31_ = self->priv->crop_location; -#line 700 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - if (_tmp31_ == CROP_LOCATION_TOP_LEFT) { -#line 700 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp30_ = TRUE; -#line 4570 "page-view.c" - } else { - CropLocation _tmp32_ = 0; -#line 701 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp32_ = self->priv->crop_location; -#line 701 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp30_ = _tmp32_ == CROP_LOCATION_LEFT; -#line 4577 "page-view.c" - } -#line 700 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - if (_tmp30_) { -#line 700 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp29_ = TRUE; -#line 4583 "page-view.c" - } else { - CropLocation _tmp33_ = 0; -#line 702 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp33_ = self->priv->crop_location; -#line 702 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp29_ = _tmp33_ == CROP_LOCATION_BOTTOM_LEFT; -#line 4590 "page-view.c" - } -#line 700 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - if (_tmp29_) { -#line 4594 "page-view.c" - gint _tmp34_ = 0; - gint _tmp35_ = 0; - gint _tmp36_ = 0; - gint _tmp39_ = 0; - gint _tmp40_ = 0; -#line 704 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp34_ = dx; -#line 704 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp35_ = new_w; -#line 704 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp36_ = min_size; -#line 704 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - if (_tmp34_ > (_tmp35_ - _tmp36_)) { -#line 4608 "page-view.c" - gint _tmp37_ = 0; - gint _tmp38_ = 0; -#line 705 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp37_ = new_w; -#line 705 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp38_ = min_size; -#line 705 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - dx = _tmp37_ - _tmp38_; -#line 4617 "page-view.c" - } -#line 706 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp39_ = new_x; -#line 706 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp40_ = dx; -#line 706 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - if ((_tmp39_ + _tmp40_) < 0) { -#line 4625 "page-view.c" - gint _tmp41_ = 0; -#line 707 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp41_ = new_x; -#line 707 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - dx = -_tmp41_; -#line 4631 "page-view.c" - } - } -#line 709 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp44_ = self->priv->crop_location; -#line 709 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - if (_tmp44_ == CROP_LOCATION_TOP_LEFT) { -#line 709 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp43_ = TRUE; -#line 4640 "page-view.c" - } else { - CropLocation _tmp45_ = 0; -#line 710 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp45_ = self->priv->crop_location; -#line 710 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp43_ = _tmp45_ == CROP_LOCATION_TOP; -#line 4647 "page-view.c" - } -#line 709 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - if (_tmp43_) { -#line 709 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp42_ = TRUE; -#line 4653 "page-view.c" - } else { - CropLocation _tmp46_ = 0; -#line 711 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp46_ = self->priv->crop_location; -#line 711 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp42_ = _tmp46_ == CROP_LOCATION_TOP_RIGHT; -#line 4660 "page-view.c" - } -#line 709 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - if (_tmp42_) { -#line 4664 "page-view.c" - gint _tmp47_ = 0; - gint _tmp48_ = 0; - gint _tmp49_ = 0; - gint _tmp52_ = 0; - gint _tmp53_ = 0; -#line 713 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp47_ = dy; -#line 713 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp48_ = new_h; -#line 713 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp49_ = min_size; -#line 713 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - if (_tmp47_ > (_tmp48_ - _tmp49_)) { -#line 4678 "page-view.c" - gint _tmp50_ = 0; - gint _tmp51_ = 0; -#line 714 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp50_ = new_h; -#line 714 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp51_ = min_size; -#line 714 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - dy = _tmp50_ - _tmp51_; -#line 4687 "page-view.c" - } -#line 715 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp52_ = new_y; -#line 715 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp53_ = dy; -#line 715 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - if ((_tmp52_ + _tmp53_) < 0) { -#line 4695 "page-view.c" - gint _tmp54_ = 0; -#line 716 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp54_ = new_y; -#line 716 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - dy = -_tmp54_; -#line 4701 "page-view.c" - } - } -#line 719 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp57_ = self->priv->crop_location; -#line 719 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - if (_tmp57_ == CROP_LOCATION_TOP_RIGHT) { -#line 719 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp56_ = TRUE; -#line 4710 "page-view.c" - } else { - CropLocation _tmp58_ = 0; -#line 720 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp58_ = self->priv->crop_location; -#line 720 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp56_ = _tmp58_ == CROP_LOCATION_RIGHT; -#line 4717 "page-view.c" - } -#line 719 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - if (_tmp56_) { -#line 719 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp55_ = TRUE; -#line 4723 "page-view.c" - } else { - CropLocation _tmp59_ = 0; -#line 721 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp59_ = self->priv->crop_location; -#line 721 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp55_ = _tmp59_ == CROP_LOCATION_BOTTOM_RIGHT; -#line 4730 "page-view.c" - } -#line 719 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - if (_tmp55_) { -#line 4734 "page-view.c" - gint _tmp60_ = 0; - gint _tmp61_ = 0; - gint _tmp62_ = 0; - gint _tmp65_ = 0; - gint _tmp66_ = 0; - gint _tmp67_ = 0; - gint _tmp68_ = 0; -#line 723 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp60_ = dx; -#line 723 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp61_ = min_size; -#line 723 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp62_ = new_w; -#line 723 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - if (_tmp60_ < (_tmp61_ - _tmp62_)) { -#line 4750 "page-view.c" - gint _tmp63_ = 0; - gint _tmp64_ = 0; -#line 724 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp63_ = min_size; -#line 724 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp64_ = new_w; -#line 724 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - dx = _tmp63_ - _tmp64_; -#line 4759 "page-view.c" - } -#line 725 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp65_ = new_x; -#line 725 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp66_ = new_w; -#line 725 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp67_ = dx; -#line 725 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp68_ = pw; -#line 725 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - if (((_tmp65_ + _tmp66_) + _tmp67_) > _tmp68_) { -#line 4771 "page-view.c" - gint _tmp69_ = 0; - gint _tmp70_ = 0; - gint _tmp71_ = 0; -#line 726 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp69_ = pw; -#line 726 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp70_ = new_x; -#line 726 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp71_ = new_w; -#line 726 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - dx = (_tmp69_ - _tmp70_) - _tmp71_; -#line 4783 "page-view.c" - } - } -#line 728 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp74_ = self->priv->crop_location; -#line 728 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - if (_tmp74_ == CROP_LOCATION_BOTTOM_LEFT) { -#line 728 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp73_ = TRUE; -#line 4792 "page-view.c" - } else { - CropLocation _tmp75_ = 0; -#line 729 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp75_ = self->priv->crop_location; -#line 729 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp73_ = _tmp75_ == CROP_LOCATION_BOTTOM; -#line 4799 "page-view.c" - } -#line 728 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - if (_tmp73_) { -#line 728 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp72_ = TRUE; -#line 4805 "page-view.c" - } else { - CropLocation _tmp76_ = 0; -#line 730 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp76_ = self->priv->crop_location; -#line 730 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp72_ = _tmp76_ == CROP_LOCATION_BOTTOM_RIGHT; -#line 4812 "page-view.c" - } -#line 728 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - if (_tmp72_) { -#line 4816 "page-view.c" - gint _tmp77_ = 0; - gint _tmp78_ = 0; - gint _tmp79_ = 0; - gint _tmp82_ = 0; - gint _tmp83_ = 0; - gint _tmp84_ = 0; - gint _tmp85_ = 0; -#line 732 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp77_ = dy; -#line 732 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp78_ = min_size; -#line 732 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp79_ = new_h; -#line 732 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - if (_tmp77_ < (_tmp78_ - _tmp79_)) { -#line 4832 "page-view.c" - gint _tmp80_ = 0; - gint _tmp81_ = 0; -#line 733 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp80_ = min_size; -#line 733 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp81_ = new_h; -#line 733 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - dy = _tmp80_ - _tmp81_; -#line 4841 "page-view.c" - } -#line 734 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp82_ = new_y; -#line 734 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp83_ = new_h; -#line 734 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp84_ = dy; -#line 734 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp85_ = ph; -#line 734 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - if (((_tmp82_ + _tmp83_) + _tmp84_) > _tmp85_) { -#line 4853 "page-view.c" - gint _tmp86_ = 0; - gint _tmp87_ = 0; - gint _tmp88_ = 0; -#line 735 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp86_ = ph; -#line 735 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp87_ = new_y; -#line 735 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp88_ = new_h; -#line 735 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - dy = (_tmp86_ - _tmp87_) - _tmp88_; -#line 4865 "page-view.c" - } - } -#line 737 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp89_ = self->priv->crop_location; -#line 737 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - if (_tmp89_ == CROP_LOCATION_MIDDLE) { -#line 4872 "page-view.c" - gint _tmp90_ = 0; - gint _tmp91_ = 0; - gint _tmp92_ = 0; - gint _tmp93_ = 0; - gint _tmp97_ = 0; - gint _tmp98_ = 0; - gint _tmp100_ = 0; - gint _tmp101_ = 0; - gint _tmp102_ = 0; - gint _tmp103_ = 0; - gint _tmp107_ = 0; - gint _tmp108_ = 0; -#line 739 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp90_ = new_x; -#line 739 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp91_ = dx; -#line 739 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp92_ = new_w; -#line 739 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp93_ = pw; -#line 739 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - if (((_tmp90_ + _tmp91_) + _tmp92_) > _tmp93_) { -#line 4895 "page-view.c" - gint _tmp94_ = 0; - gint _tmp95_ = 0; - gint _tmp96_ = 0; -#line 740 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp94_ = pw; -#line 740 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp95_ = new_x; -#line 740 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp96_ = new_w; -#line 740 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - dx = (_tmp94_ - _tmp95_) - _tmp96_; -#line 4907 "page-view.c" - } -#line 741 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp97_ = new_x; -#line 741 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp98_ = dx; -#line 741 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - if ((_tmp97_ + _tmp98_) < 0) { -#line 4915 "page-view.c" - gint _tmp99_ = 0; -#line 742 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp99_ = new_x; -#line 742 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - dx = -_tmp99_; -#line 4921 "page-view.c" - } -#line 743 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp100_ = new_y; -#line 743 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp101_ = dy; -#line 743 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp102_ = new_h; -#line 743 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp103_ = ph; -#line 743 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - if (((_tmp100_ + _tmp101_) + _tmp102_) > _tmp103_) { -#line 4933 "page-view.c" - gint _tmp104_ = 0; - gint _tmp105_ = 0; - gint _tmp106_ = 0; -#line 744 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp104_ = ph; -#line 744 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp105_ = new_y; -#line 744 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp106_ = new_h; -#line 744 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - dy = (_tmp104_ - _tmp105_) - _tmp106_; -#line 4945 "page-view.c" - } -#line 745 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp107_ = new_y; -#line 745 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp108_ = dy; -#line 745 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - if ((_tmp107_ + _tmp108_) < 0) { -#line 4953 "page-view.c" - gint _tmp109_ = 0; -#line 746 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp109_ = new_y; -#line 746 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - dy = -_tmp109_; -#line 4959 "page-view.c" - } - } -#line 750 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp110_ = self->priv->crop_location; -#line 750 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - if (_tmp110_ == CROP_LOCATION_MIDDLE) { -#line 4966 "page-view.c" - gint _tmp111_ = 0; - gint _tmp112_ = 0; - gint _tmp113_ = 0; - gint _tmp114_ = 0; -#line 752 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp111_ = new_x; -#line 752 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp112_ = dx; -#line 752 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - new_x = _tmp111_ + _tmp112_; -#line 753 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp113_ = new_y; -#line 753 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp114_ = dy; -#line 753 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - new_y = _tmp113_ + _tmp114_; -#line 4983 "page-view.c" - } -#line 755 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp117_ = self->priv->crop_location; -#line 755 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - if (_tmp117_ == CROP_LOCATION_TOP_LEFT) { -#line 755 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp116_ = TRUE; -#line 4991 "page-view.c" - } else { - CropLocation _tmp118_ = 0; -#line 756 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp118_ = self->priv->crop_location; -#line 756 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp116_ = _tmp118_ == CROP_LOCATION_LEFT; -#line 4998 "page-view.c" - } -#line 755 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - if (_tmp116_) { -#line 755 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp115_ = TRUE; -#line 5004 "page-view.c" - } else { - CropLocation _tmp119_ = 0; -#line 757 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp119_ = self->priv->crop_location; -#line 757 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp115_ = _tmp119_ == CROP_LOCATION_BOTTOM_LEFT; -#line 5011 "page-view.c" - } -#line 755 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - if (_tmp115_) { -#line 5015 "page-view.c" - gint _tmp120_ = 0; - gint _tmp121_ = 0; - gint _tmp122_ = 0; - gint _tmp123_ = 0; -#line 759 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp120_ = new_x; -#line 759 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp121_ = dx; -#line 759 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - new_x = _tmp120_ + _tmp121_; -#line 760 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp122_ = new_w; -#line 760 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp123_ = dx; -#line 760 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - new_w = _tmp122_ - _tmp123_; -#line 5032 "page-view.c" - } -#line 762 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp126_ = self->priv->crop_location; -#line 762 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - if (_tmp126_ == CROP_LOCATION_TOP_LEFT) { -#line 762 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp125_ = TRUE; -#line 5040 "page-view.c" - } else { - CropLocation _tmp127_ = 0; -#line 763 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp127_ = self->priv->crop_location; -#line 763 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp125_ = _tmp127_ == CROP_LOCATION_TOP; -#line 5047 "page-view.c" - } -#line 762 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - if (_tmp125_) { -#line 762 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp124_ = TRUE; -#line 5053 "page-view.c" - } else { - CropLocation _tmp128_ = 0; -#line 764 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp128_ = self->priv->crop_location; -#line 764 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp124_ = _tmp128_ == CROP_LOCATION_TOP_RIGHT; -#line 5060 "page-view.c" - } -#line 762 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - if (_tmp124_) { -#line 5064 "page-view.c" - gint _tmp129_ = 0; - gint _tmp130_ = 0; - gint _tmp131_ = 0; - gint _tmp132_ = 0; -#line 766 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp129_ = new_y; -#line 766 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp130_ = dy; -#line 766 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - new_y = _tmp129_ + _tmp130_; -#line 767 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp131_ = new_h; -#line 767 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp132_ = dy; -#line 767 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - new_h = _tmp131_ - _tmp132_; -#line 5081 "page-view.c" - } -#line 770 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp135_ = self->priv->crop_location; -#line 770 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - if (_tmp135_ == CROP_LOCATION_TOP_RIGHT) { -#line 770 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp134_ = TRUE; -#line 5089 "page-view.c" - } else { - CropLocation _tmp136_ = 0; -#line 771 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp136_ = self->priv->crop_location; -#line 771 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp134_ = _tmp136_ == CROP_LOCATION_RIGHT; -#line 5096 "page-view.c" - } -#line 770 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - if (_tmp134_) { -#line 770 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp133_ = TRUE; -#line 5102 "page-view.c" - } else { - CropLocation _tmp137_ = 0; -#line 772 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp137_ = self->priv->crop_location; -#line 772 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp133_ = _tmp137_ == CROP_LOCATION_BOTTOM_RIGHT; -#line 5109 "page-view.c" - } -#line 770 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - if (_tmp133_) { -#line 5113 "page-view.c" - gint _tmp138_ = 0; - gint _tmp139_ = 0; -#line 773 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp138_ = new_w; -#line 773 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp139_ = dx; -#line 773 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - new_w = _tmp138_ + _tmp139_; -#line 5122 "page-view.c" - } -#line 774 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp142_ = self->priv->crop_location; -#line 774 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - if (_tmp142_ == CROP_LOCATION_BOTTOM_LEFT) { -#line 774 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp141_ = TRUE; -#line 5130 "page-view.c" - } else { - CropLocation _tmp143_ = 0; -#line 775 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp143_ = self->priv->crop_location; -#line 775 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp141_ = _tmp143_ == CROP_LOCATION_BOTTOM; -#line 5137 "page-view.c" - } -#line 774 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - if (_tmp141_) { -#line 774 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp140_ = TRUE; -#line 5143 "page-view.c" - } else { - CropLocation _tmp144_ = 0; -#line 776 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp144_ = self->priv->crop_location; -#line 776 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp140_ = _tmp144_ == CROP_LOCATION_BOTTOM_RIGHT; -#line 5150 "page-view.c" - } -#line 774 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - if (_tmp140_) { -#line 5154 "page-view.c" - gint _tmp145_ = 0; - gint _tmp146_ = 0; -#line 777 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp145_ = new_h; -#line 777 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp146_ = dy; -#line 777 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - new_h = _tmp145_ + _tmp146_; -#line 5163 "page-view.c" - } -#line 779 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp147_ = self->priv->_page; -#line 779 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp148_ = new_x; -#line 779 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp149_ = new_y; -#line 779 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - page_move_crop (_tmp147_, _tmp148_, _tmp149_); -#line 782 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp151_ = new_w; -#line 782 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp152_ = cw; -#line 782 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - if (_tmp151_ != _tmp152_) { -#line 782 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp150_ = TRUE; -#line 5181 "page-view.c" - } else { - gint _tmp153_ = 0; - gint _tmp154_ = 0; -#line 782 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp153_ = new_h; -#line 782 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp154_ = ch; -#line 782 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp150_ = _tmp153_ != _tmp154_; -#line 5191 "page-view.c" - } -#line 782 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - if (_tmp150_) { -#line 5195 "page-view.c" - Page* _tmp155_ = NULL; - gint _tmp156_ = 0; - gint _tmp157_ = 0; -#line 783 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp155_ = self->priv->_page; -#line 783 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp156_ = new_w; -#line 783 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp157_ = new_h; -#line 783 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - page_set_custom_crop (_tmp155_, _tmp156_, _tmp157_); -#line 5207 "page-view.c" - } -} - - -void page_view_button_release (PageView* self, gint x, gint y) { -#line 786 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - g_return_if_fail (self != NULL); -#line 789 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - self->priv->crop_location = CROP_LOCATION_NONE; -#line 790 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - g_signal_emit_by_name (self, "changed"); -#line 5219 "page-view.c" -} - - -static gboolean page_view_animation_cb (PageView* self) { - gboolean result = FALSE; - gint _tmp0_ = 0; - gint _tmp1_ = 0; -#line 793 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - g_return_val_if_fail (self != NULL, FALSE); -#line 795 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp0_ = self->priv->animate_segment; -#line 795 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp1_ = self->priv->animate_n_segments; -#line 795 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - self->priv->animate_segment = (_tmp0_ + 1) % _tmp1_; -#line 796 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - g_signal_emit_by_name (self, "changed"); -#line 797 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - result = TRUE; -#line 797 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - return result; -#line 5241 "page-view.c" -} - - -static gboolean _page_view_animation_cb_gsource_func (gpointer self) { - gboolean result; - result = page_view_animation_cb ((PageView*) self); -#line 813 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - return result; -#line 5250 "page-view.c" -} - - -static void page_view_update_animation (PageView* self) { - gboolean animate = FALSE; - gboolean is_animating = FALSE; - gboolean _tmp0_ = FALSE; - Page* _tmp1_ = NULL; - gboolean _tmp2_ = FALSE; - gboolean _tmp3_ = FALSE; - guint _tmp7_ = 0U; - gboolean _tmp8_ = FALSE; - gboolean _tmp9_ = FALSE; - gboolean _tmp10_ = FALSE; -#line 800 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - g_return_if_fail (self != NULL); -#line 804 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp1_ = self->priv->_page; -#line 804 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp2_ = page_get_is_scanning (_tmp1_); -#line 804 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp3_ = _tmp2_; -#line 804 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - if (_tmp3_) { -#line 5275 "page-view.c" - Page* _tmp4_ = NULL; - gboolean _tmp5_ = FALSE; - gboolean _tmp6_ = FALSE; -#line 804 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp4_ = self->priv->_page; -#line 804 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp5_ = page_get_has_data (_tmp4_); -#line 804 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp6_ = _tmp5_; -#line 804 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp0_ = !_tmp6_; -#line 5287 "page-view.c" - } else { -#line 804 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp0_ = FALSE; -#line 5291 "page-view.c" - } -#line 804 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - animate = _tmp0_; -#line 805 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp7_ = self->priv->animate_timeout; -#line 805 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - is_animating = _tmp7_ != ((guint) 0); -#line 806 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp8_ = animate; -#line 806 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp9_ = is_animating; -#line 806 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - if (_tmp8_ == _tmp9_) { -#line 807 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - return; -#line 5307 "page-view.c" - } -#line 809 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp10_ = animate; -#line 809 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - if (_tmp10_) { -#line 5313 "page-view.c" - guint _tmp11_ = 0U; -#line 811 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - self->priv->animate_segment = 0; -#line 812 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp11_ = self->priv->animate_timeout; -#line 812 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - if (_tmp11_ == ((guint) 0)) { -#line 5321 "page-view.c" - guint _tmp12_ = 0U; -#line 813 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp12_ = g_timeout_add_full (G_PRIORITY_DEFAULT, (guint) 150, _page_view_animation_cb_gsource_func, page_view_ref (self), page_view_unref); -#line 813 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - self->priv->animate_timeout = _tmp12_; -#line 5327 "page-view.c" - } - } else { - guint _tmp13_ = 0U; -#line 817 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp13_ = self->priv->animate_timeout; -#line 817 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - if (_tmp13_ != ((guint) 0)) { -#line 5335 "page-view.c" - guint _tmp14_ = 0U; -#line 818 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp14_ = self->priv->animate_timeout; -#line 818 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - g_source_remove (_tmp14_); -#line 5341 "page-view.c" - } -#line 819 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - self->priv->animate_timeout = (guint) 0; -#line 5345 "page-view.c" - } -} - - -void page_view_render (PageView* self, cairo_t* context) { - gint w = 0; - gint _tmp0_ = 0; - gint h = 0; - gint _tmp1_ = 0; - cairo_t* _tmp2_ = NULL; - cairo_t* _tmp3_ = NULL; - gint _tmp4_ = 0; - gint _tmp5_ = 0; - cairo_t* _tmp6_ = NULL; - cairo_t* _tmp7_ = NULL; - gint _tmp8_ = 0; - cairo_t* _tmp9_ = NULL; - gint _tmp10_ = 0; - gint _tmp11_ = 0; - gint _tmp12_ = 0; - gint _tmp13_ = 0; - gint _tmp14_ = 0; - gint _tmp15_ = 0; - cairo_t* _tmp16_ = NULL; - cairo_t* _tmp17_ = NULL; - gint _tmp18_ = 0; - gint _tmp19_ = 0; - cairo_t* _tmp20_ = NULL; - GdkPixbuf* _tmp21_ = NULL; - cairo_t* _tmp22_ = NULL; - gboolean _tmp23_ = FALSE; - Page* _tmp24_ = NULL; - gboolean _tmp25_ = FALSE; - gboolean _tmp26_ = FALSE; - gboolean _tmp70_ = FALSE; - Page* _tmp71_ = NULL; - gboolean _tmp72_ = FALSE; - gboolean _tmp73_ = FALSE; - Page* _tmp118_ = NULL; - gboolean _tmp119_ = FALSE; - gboolean _tmp120_ = FALSE; -#line 823 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - g_return_if_fail (self != NULL); -#line 823 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - g_return_if_fail (context != NULL); -#line 825 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - page_view_update_animation (self); -#line 826 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - page_view_update_page_view (self); -#line 828 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp0_ = page_view_get_preview_width (self); -#line 828 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - w = _tmp0_; -#line 829 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp1_ = page_view_get_preview_height (self); -#line 829 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - h = _tmp1_; -#line 831 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp2_ = context; -#line 831 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - cairo_set_line_width (_tmp2_, (gdouble) 1); -#line 832 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp3_ = context; -#line 832 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp4_ = self->priv->_x_offset; -#line 832 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp5_ = self->priv->_y_offset; -#line 832 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - cairo_translate (_tmp3_, (gdouble) _tmp4_, (gdouble) _tmp5_); -#line 835 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp6_ = context; -#line 835 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - cairo_set_source_rgb (_tmp6_, (gdouble) 0, (gdouble) 0, (gdouble) 0); -#line 836 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp7_ = context; -#line 836 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp8_ = self->priv->border_width; -#line 836 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - cairo_set_line_width (_tmp7_, (gdouble) _tmp8_); -#line 837 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp9_ = context; -#line 837 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp10_ = self->priv->border_width; -#line 837 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp11_ = self->priv->border_width; -#line 837 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp12_ = self->priv->width_; -#line 837 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp13_ = self->priv->border_width; -#line 837 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp14_ = self->priv->height_; -#line 837 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp15_ = self->priv->border_width; -#line 837 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - cairo_rectangle (_tmp9_, ((gdouble) _tmp10_) / 2, ((gdouble) _tmp11_) / 2, (gdouble) (_tmp12_ - _tmp13_), (gdouble) (_tmp14_ - _tmp15_)); -#line 841 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp16_ = context; -#line 841 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - cairo_stroke (_tmp16_); -#line 844 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp17_ = context; -#line 844 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp18_ = self->priv->border_width; -#line 844 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp19_ = self->priv->border_width; -#line 844 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - cairo_translate (_tmp17_, (gdouble) _tmp18_, (gdouble) _tmp19_); -#line 845 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp20_ = context; -#line 845 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp21_ = self->priv->image; -#line 845 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - gdk_cairo_set_source_pixbuf (_tmp20_, _tmp21_, (gdouble) 0, (gdouble) 0); -#line 846 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp22_ = context; -#line 846 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - cairo_paint (_tmp22_); -#line 849 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp24_ = self->priv->_page; -#line 849 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp25_ = page_get_is_scanning (_tmp24_); -#line 849 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp26_ = _tmp25_; -#line 849 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - if (_tmp26_) { -#line 5471 "page-view.c" - Page* _tmp27_ = NULL; - gboolean _tmp28_ = FALSE; - gboolean _tmp29_ = FALSE; -#line 849 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp27_ = self->priv->_page; -#line 849 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp28_ = page_get_has_data (_tmp27_); -#line 849 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp29_ = _tmp28_; -#line 849 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp23_ = !_tmp29_; -#line 5483 "page-view.c" - } else { -#line 849 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp23_ = FALSE; -#line 5487 "page-view.c" - } -#line 849 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - if (_tmp23_) { -#line 5491 "page-view.c" - gdouble outer_radius = 0.0; - gint _tmp30_ = 0; - gint _tmp31_ = 0; - gdouble arc = 0.0; - gint _tmp34_ = 0; - gdouble x = 0.0; - gdouble _tmp35_ = 0.0; - gdouble _tmp36_ = 0.0; - gdouble _tmp37_ = 0.0; - gdouble y = 0.0; - gdouble _tmp38_ = 0.0; - gdouble _tmp39_ = 0.0; - gdouble _tmp40_ = 0.0; - gdouble inner_radius = 0.0; - gdouble _tmp41_ = 0.0; - gdouble _tmp42_ = 0.0; - gdouble _tmp43_ = 0.0; - gdouble _tmp44_ = 0.0; - gdouble _tmp45_ = 0.0; - gdouble offset = 0.0; -#line 852 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp30_ = w; -#line 852 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp31_ = h; -#line 852 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - if (_tmp30_ > _tmp31_) { -#line 5518 "page-view.c" - gint _tmp32_ = 0; -#line 853 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp32_ = w; -#line 853 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - outer_radius = 0.15 * _tmp32_; -#line 5524 "page-view.c" - } else { - gint _tmp33_ = 0; -#line 855 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp33_ = h; -#line 855 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - outer_radius = 0.15 * _tmp33_; -#line 5531 "page-view.c" - } -#line 856 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp34_ = self->priv->animate_n_segments; -#line 856 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - arc = G_PI / _tmp34_; -#line 859 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp35_ = outer_radius; -#line 859 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp36_ = arc; -#line 859 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp37_ = sin (_tmp36_); -#line 859 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - x = _tmp35_ * _tmp37_; -#line 860 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp38_ = outer_radius; -#line 860 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp39_ = arc; -#line 860 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp40_ = cos (_tmp39_); -#line 860 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - y = _tmp38_ * (_tmp40_ - 1.0); -#line 861 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp41_ = x; -#line 861 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp42_ = x; -#line 861 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp43_ = y; -#line 861 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp44_ = y; -#line 861 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp45_ = sqrt ((_tmp41_ * _tmp42_) + (_tmp43_ * _tmp44_)); -#line 861 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - inner_radius = 0.6 * _tmp45_; -#line 863 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - offset = 0.0; -#line 5567 "page-view.c" - { - gint i = 0; -#line 864 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - i = 0; -#line 5572 "page-view.c" - { - gboolean _tmp46_ = FALSE; -#line 864 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp46_ = TRUE; -#line 864 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - while (TRUE) { -#line 5579 "page-view.c" - gint _tmp50_ = 0; - gint _tmp51_ = 0; - gint _tmp52_ = 0; - gdouble _tmp53_ = 0.0; - gdouble _tmp54_ = 0.0; - gdouble _tmp55_ = 0.0; - gint _tmp56_ = 0; - gdouble _tmp57_ = 0.0; - gdouble _tmp58_ = 0.0; - gdouble _tmp59_ = 0.0; - cairo_t* _tmp60_ = NULL; - gdouble _tmp61_ = 0.0; - gdouble _tmp62_ = 0.0; - gdouble _tmp63_ = 0.0; - gint _tmp64_ = 0; - gint _tmp65_ = 0; - cairo_t* _tmp68_ = NULL; - cairo_t* _tmp69_ = NULL; -#line 864 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - if (!_tmp46_) { -#line 5600 "page-view.c" - gint _tmp47_ = 0; - gdouble _tmp48_ = 0.0; - gdouble _tmp49_ = 0.0; -#line 864 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp47_ = i; -#line 864 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - i = _tmp47_ + 1; -#line 864 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp48_ = offset; -#line 864 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp49_ = arc; -#line 864 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - offset = _tmp48_ + (_tmp49_ * 2); -#line 5614 "page-view.c" - } -#line 864 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp46_ = FALSE; -#line 864 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp50_ = i; -#line 864 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp51_ = self->priv->animate_n_segments; -#line 864 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - if (!(_tmp50_ < _tmp51_)) { -#line 864 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - break; -#line 5626 "page-view.c" - } -#line 866 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp52_ = w; -#line 866 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp53_ = outer_radius; -#line 866 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp54_ = offset; -#line 866 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp55_ = sin (_tmp54_); -#line 866 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - x = (_tmp52_ / 2) + (_tmp53_ * _tmp55_); -#line 867 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp56_ = h; -#line 867 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp57_ = outer_radius; -#line 867 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp58_ = offset; -#line 867 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp59_ = cos (_tmp58_); -#line 867 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - y = (_tmp56_ / 2) - (_tmp57_ * _tmp59_); -#line 868 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp60_ = context; -#line 868 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp61_ = x; -#line 868 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp62_ = y; -#line 868 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp63_ = inner_radius; -#line 868 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - cairo_arc (_tmp60_, _tmp61_, _tmp62_, _tmp63_, (gdouble) 0, 2 * G_PI); -#line 870 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp64_ = i; -#line 870 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp65_ = self->priv->animate_segment; -#line 870 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - if (_tmp64_ == _tmp65_) { -#line 5664 "page-view.c" - cairo_t* _tmp66_ = NULL; - cairo_t* _tmp67_ = NULL; -#line 872 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp66_ = context; -#line 872 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - cairo_set_source_rgb (_tmp66_, 0.75, 0.75, 0.75); -#line 873 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp67_ = context; -#line 873 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - cairo_fill_preserve (_tmp67_); -#line 5675 "page-view.c" - } -#line 876 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp68_ = context; -#line 876 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - cairo_set_source_rgb (_tmp68_, 0.5, 0.5, 0.5); -#line 877 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp69_ = context; -#line 877 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - cairo_stroke (_tmp69_); -#line 5685 "page-view.c" - } - } - } - } -#line 882 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp71_ = self->priv->_page; -#line 882 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp72_ = page_get_is_scanning (_tmp71_); -#line 882 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp73_ = _tmp72_; -#line 882 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - if (_tmp73_) { -#line 5698 "page-view.c" - Page* _tmp74_ = NULL; - gint _tmp75_ = 0; - gint _tmp76_ = 0; -#line 882 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp74_ = self->priv->_page; -#line 882 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp75_ = page_get_scan_line (_tmp74_); -#line 882 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp76_ = _tmp75_; -#line 882 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp70_ = _tmp76_ > 0; -#line 5710 "page-view.c" - } else { -#line 882 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp70_ = FALSE; -#line 5714 "page-view.c" - } -#line 882 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - if (_tmp70_) { -#line 5718 "page-view.c" - gint scan_line = 0; - Page* _tmp77_ = NULL; - gint _tmp78_ = 0; - gint _tmp79_ = 0; - gdouble s = 0.0; - gdouble x1 = 0.0; - gdouble y1 = 0.0; - gdouble x2 = 0.0; - gdouble y2 = 0.0; - Page* _tmp80_ = NULL; - ScanDirection _tmp81_ = 0; - ScanDirection _tmp82_ = 0; - cairo_t* _tmp110_ = NULL; - gdouble _tmp111_ = 0.0; - gdouble _tmp112_ = 0.0; - cairo_t* _tmp113_ = NULL; - gdouble _tmp114_ = 0.0; - gdouble _tmp115_ = 0.0; - cairo_t* _tmp116_ = NULL; - cairo_t* _tmp117_ = NULL; -#line 884 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp77_ = self->priv->_page; -#line 884 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp78_ = page_get_scan_line (_tmp77_); -#line 884 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp79_ = _tmp78_; -#line 884 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - scan_line = _tmp79_; -#line 888 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp80_ = self->priv->_page; -#line 888 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp81_ = page_get_scan_direction (_tmp80_); -#line 888 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp82_ = _tmp81_; -#line 888 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - switch (_tmp82_) { -#line 888 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - case SCAN_DIRECTION_TOP_TO_BOTTOM: -#line 5757 "page-view.c" - { - gint _tmp83_ = 0; - gint _tmp84_ = 0; - gdouble _tmp85_ = 0.0; - gint _tmp86_ = 0; - gdouble _tmp87_ = 0.0; -#line 891 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp83_ = scan_line; -#line 891 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp84_ = page_view_page_to_screen_y (self, _tmp83_); -#line 891 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - s = (gdouble) _tmp84_; -#line 892 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - x1 = (gdouble) 0; -#line 892 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp85_ = s; -#line 892 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - y1 = _tmp85_ + 0.5; -#line 893 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp86_ = w; -#line 893 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - x2 = (gdouble) _tmp86_; -#line 893 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp87_ = s; -#line 893 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - y2 = _tmp87_ + 0.5; -#line 894 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - break; -#line 5786 "page-view.c" - } -#line 888 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - case SCAN_DIRECTION_BOTTOM_TO_TOP: -#line 5790 "page-view.c" - { - gint _tmp88_ = 0; - gint _tmp89_ = 0; - gint _tmp90_ = 0; - gdouble _tmp91_ = 0.0; - gint _tmp92_ = 0; - gint _tmp93_ = 0; - gdouble _tmp94_ = 0.0; -#line 896 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp88_ = scan_line; -#line 896 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp89_ = page_view_page_to_screen_y (self, _tmp88_); -#line 896 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - s = (gdouble) _tmp89_; -#line 897 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - x1 = (gdouble) 0; -#line 897 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp90_ = h; -#line 897 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp91_ = s; -#line 897 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - y1 = (_tmp90_ - _tmp91_) + 0.5; -#line 898 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp92_ = w; -#line 898 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - x2 = (gdouble) _tmp92_; -#line 898 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp93_ = h; -#line 898 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp94_ = s; -#line 898 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - y2 = (_tmp93_ - _tmp94_) + 0.5; -#line 899 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - break; -#line 5825 "page-view.c" - } -#line 888 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - case SCAN_DIRECTION_LEFT_TO_RIGHT: -#line 5829 "page-view.c" - { - gint _tmp95_ = 0; - gint _tmp96_ = 0; - gdouble _tmp97_ = 0.0; - gdouble _tmp98_ = 0.0; - gint _tmp99_ = 0; -#line 901 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp95_ = scan_line; -#line 901 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp96_ = page_view_page_to_screen_x (self, _tmp95_); -#line 901 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - s = (gdouble) _tmp96_; -#line 902 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp97_ = s; -#line 902 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - x1 = _tmp97_ + 0.5; -#line 902 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - y1 = (gdouble) 0; -#line 903 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp98_ = s; -#line 903 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - x2 = _tmp98_ + 0.5; -#line 903 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp99_ = h; -#line 903 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - y2 = (gdouble) _tmp99_; -#line 904 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - break; -#line 5858 "page-view.c" - } -#line 888 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - case SCAN_DIRECTION_RIGHT_TO_LEFT: -#line 5862 "page-view.c" - { - gint _tmp100_ = 0; - gint _tmp101_ = 0; - gint _tmp102_ = 0; - gdouble _tmp103_ = 0.0; - gint _tmp104_ = 0; - gdouble _tmp105_ = 0.0; - gint _tmp106_ = 0; -#line 906 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp100_ = scan_line; -#line 906 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp101_ = page_view_page_to_screen_x (self, _tmp100_); -#line 906 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - s = (gdouble) _tmp101_; -#line 907 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp102_ = w; -#line 907 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp103_ = s; -#line 907 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - x1 = (_tmp102_ - _tmp103_) + 0.5; -#line 907 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - y1 = (gdouble) 0; -#line 908 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp104_ = w; -#line 908 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp105_ = s; -#line 908 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - x2 = (_tmp104_ - _tmp105_) + 0.5; -#line 908 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp106_ = h; -#line 908 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - y2 = (gdouble) _tmp106_; -#line 909 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - break; -#line 5897 "page-view.c" - } - default: - { - gdouble _tmp107_ = 0.0; - gdouble _tmp108_ = 0.0; - gdouble _tmp109_ = 0.0; -#line 911 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - y2 = (gdouble) 0; -#line 911 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp107_ = y2; -#line 911 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - x2 = _tmp107_; -#line 911 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp108_ = x2; -#line 911 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - y1 = _tmp108_; -#line 911 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp109_ = y1; -#line 911 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - x1 = _tmp109_; -#line 912 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - break; -#line 5920 "page-view.c" - } - } -#line 915 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp110_ = context; -#line 915 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp111_ = x1; -#line 915 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp112_ = y1; -#line 915 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - cairo_move_to (_tmp110_, _tmp111_, _tmp112_); -#line 916 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp113_ = context; -#line 916 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp114_ = x2; -#line 916 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp115_ = y2; -#line 916 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - cairo_line_to (_tmp113_, _tmp114_, _tmp115_); -#line 917 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp116_ = context; -#line 917 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - cairo_set_source_rgb (_tmp116_, 1.0, 0.0, 0.0); -#line 918 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp117_ = context; -#line 918 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - cairo_stroke (_tmp117_); -#line 5947 "page-view.c" - } -#line 922 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp118_ = self->priv->_page; -#line 922 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp119_ = page_get_has_crop (_tmp118_); -#line 922 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp120_ = _tmp119_; -#line 922 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - if (_tmp120_) { -#line 5957 "page-view.c" - gint x = 0; - Page* _tmp121_ = NULL; - gint _tmp122_ = 0; - gint _tmp123_ = 0; - gint y = 0; - Page* _tmp124_ = NULL; - gint _tmp125_ = 0; - gint _tmp126_ = 0; - gint crop_width = 0; - Page* _tmp127_ = NULL; - gint _tmp128_ = 0; - gint _tmp129_ = 0; - gint crop_height = 0; - Page* _tmp130_ = NULL; - gint _tmp131_ = 0; - gint _tmp132_ = 0; - gint dx = 0; - gint _tmp133_ = 0; - gint _tmp134_ = 0; - gint dy = 0; - gint _tmp135_ = 0; - gint _tmp136_ = 0; - gint dw = 0; - gint _tmp137_ = 0; - gint _tmp138_ = 0; - gint dh = 0; - gint _tmp139_ = 0; - gint _tmp140_ = 0; - cairo_t* _tmp141_ = NULL; - gint _tmp142_ = 0; - gint _tmp143_ = 0; - cairo_t* _tmp144_ = NULL; - cairo_t* _tmp145_ = NULL; - gint _tmp146_ = 0; - gint _tmp147_ = 0; - gint _tmp148_ = 0; - gint _tmp149_ = 0; - cairo_t* _tmp150_ = NULL; - cairo_t* _tmp151_ = NULL; - cairo_t* _tmp152_ = NULL; - cairo_t* _tmp153_ = NULL; - gint _tmp154_ = 0; - gint _tmp155_ = 0; - gint _tmp156_ = 0; - gint _tmp157_ = 0; - cairo_t* _tmp158_ = NULL; - cairo_t* _tmp159_ = NULL; - cairo_t* _tmp160_ = NULL; - gint _tmp161_ = 0; - gint _tmp162_ = 0; - gint _tmp163_ = 0; - gint _tmp164_ = 0; - cairo_t* _tmp165_ = NULL; - cairo_t* _tmp166_ = NULL; -#line 924 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp121_ = self->priv->_page; -#line 924 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp122_ = page_get_crop_x (_tmp121_); -#line 924 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp123_ = _tmp122_; -#line 924 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - x = _tmp123_; -#line 925 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp124_ = self->priv->_page; -#line 925 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp125_ = page_get_crop_y (_tmp124_); -#line 925 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp126_ = _tmp125_; -#line 925 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - y = _tmp126_; -#line 926 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp127_ = self->priv->_page; -#line 926 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp128_ = page_get_crop_width (_tmp127_); -#line 926 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp129_ = _tmp128_; -#line 926 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - crop_width = _tmp129_; -#line 927 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp130_ = self->priv->_page; -#line 927 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp131_ = page_get_crop_height (_tmp130_); -#line 927 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp132_ = _tmp131_; -#line 927 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - crop_height = _tmp132_; -#line 929 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp133_ = x; -#line 929 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp134_ = page_view_page_to_screen_x (self, _tmp133_); -#line 929 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - dx = _tmp134_; -#line 930 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp135_ = y; -#line 930 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp136_ = page_view_page_to_screen_y (self, _tmp135_); -#line 930 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - dy = _tmp136_; -#line 931 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp137_ = crop_width; -#line 931 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp138_ = page_view_page_to_screen_x (self, _tmp137_); -#line 931 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - dw = _tmp138_; -#line 932 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp139_ = crop_height; -#line 932 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp140_ = page_view_page_to_screen_y (self, _tmp139_); -#line 932 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - dh = _tmp140_; -#line 935 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp141_ = context; -#line 935 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp142_ = w; -#line 935 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp143_ = h; -#line 935 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - cairo_rectangle (_tmp141_, (gdouble) 0, (gdouble) 0, (gdouble) _tmp142_, (gdouble) _tmp143_); -#line 936 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp144_ = context; -#line 936 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - cairo_new_sub_path (_tmp144_); -#line 937 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp145_ = context; -#line 937 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp146_ = dx; -#line 937 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp147_ = dy; -#line 937 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp148_ = dw; -#line 937 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp149_ = dh; -#line 937 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - cairo_rectangle (_tmp145_, (gdouble) _tmp146_, (gdouble) _tmp147_, (gdouble) _tmp148_, (gdouble) _tmp149_); -#line 938 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp150_ = context; -#line 938 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - cairo_set_fill_rule (_tmp150_, CAIRO_FILL_RULE_EVEN_ODD); -#line 939 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp151_ = context; -#line 939 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - cairo_set_source_rgba (_tmp151_, 0.25, 0.25, 0.25, 0.2); -#line 940 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp152_ = context; -#line 940 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - cairo_fill (_tmp152_); -#line 943 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp153_ = context; -#line 943 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp154_ = dx; -#line 943 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp155_ = dy; -#line 943 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp156_ = dw; -#line 943 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp157_ = dh; -#line 943 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - cairo_rectangle (_tmp153_, _tmp154_ - 1.5, _tmp155_ - 1.5, (gdouble) (_tmp156_ + 3), (gdouble) (_tmp157_ + 3)); -#line 944 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp158_ = context; -#line 944 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - cairo_set_source_rgb (_tmp158_, 1.0, 1.0, 1.0); -#line 945 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp159_ = context; -#line 945 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - cairo_stroke (_tmp159_); -#line 946 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp160_ = context; -#line 946 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp161_ = dx; -#line 946 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp162_ = dy; -#line 946 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp163_ = dw; -#line 946 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp164_ = dh; -#line 946 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - cairo_rectangle (_tmp160_, _tmp161_ - 0.5, _tmp162_ - 0.5, (gdouble) (_tmp163_ + 1), (gdouble) (_tmp164_ + 1)); -#line 947 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp165_ = context; -#line 947 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - cairo_set_source_rgb (_tmp165_, 0.0, 0.0, 0.0); -#line 948 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp166_ = context; -#line 948 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - cairo_stroke (_tmp166_); -#line 6144 "page-view.c" - } -} - - -static void page_view_page_pixels_changed_cb (PageView* self, Page* p) { -#line 994 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - g_return_if_fail (self != NULL); -#line 994 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - g_return_if_fail (p != NULL); -#line 997 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - self->priv->update_image = TRUE; -#line 998 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - g_signal_emit_by_name (self, "changed"); -#line 6158 "page-view.c" -} - - -static void page_view_page_size_changed_cb (PageView* self, Page* p) { -#line 1001 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - g_return_if_fail (self != NULL); -#line 1001 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - g_return_if_fail (p != NULL); -#line 1004 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - self->priv->update_image = TRUE; -#line 1005 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - g_signal_emit_by_name (self, "size-changed"); -#line 1006 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - g_signal_emit_by_name (self, "changed"); -#line 6173 "page-view.c" -} - - -static void page_view_page_overlay_changed_cb (PageView* self, Page* p) { -#line 1009 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - g_return_if_fail (self != NULL); -#line 1009 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - g_return_if_fail (p != NULL); -#line 1011 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - g_signal_emit_by_name (self, "changed"); -#line 6184 "page-view.c" -} - - -static void page_view_scan_direction_changed_cb (PageView* self, Page* p) { -#line 1014 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - g_return_if_fail (self != NULL); -#line 1014 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - g_return_if_fail (p != NULL); -#line 1017 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - self->priv->update_image = TRUE; -#line 1018 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - g_signal_emit_by_name (self, "size-changed"); -#line 1019 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - g_signal_emit_by_name (self, "changed"); -#line 6199 "page-view.c" -} - - -Page* page_view_get_page (PageView* self) { - Page* result; - Page* _tmp0_ = NULL; -#line 29 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - g_return_val_if_fail (self != NULL, NULL); -#line 29 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp0_ = self->priv->_page; -#line 29 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - result = _tmp0_; -#line 29 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - return result; -#line 6214 "page-view.c" -} - - -static gpointer _page_ref0 (gpointer self) { -#line 29 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - return self ? page_ref (self) : NULL; -#line 6221 "page-view.c" -} - - -static void page_view_set_page (PageView* self, Page* value) { - Page* _tmp0_ = NULL; - Page* _tmp1_ = NULL; -#line 29 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - g_return_if_fail (self != NULL); -#line 29 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp0_ = value; -#line 29 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp1_ = _page_ref0 (_tmp0_); -#line 29 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _page_unref0 (self->priv->_page); -#line 29 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - self->priv->_page = _tmp1_; -#line 6238 "page-view.c" -} - - -gboolean page_view_get_selected (PageView* self) { - gboolean result; - gboolean _tmp0_ = FALSE; -#line 38 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - g_return_val_if_fail (self != NULL, FALSE); -#line 38 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp0_ = self->priv->selected_; -#line 38 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - result = _tmp0_; -#line 38 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - return result; -#line 6253 "page-view.c" -} - - -void page_view_set_selected (PageView* self, gboolean value) { - gboolean _tmp0_ = FALSE; - gboolean _tmp1_ = FALSE; - gboolean _tmp2_ = FALSE; - gboolean _tmp3_ = FALSE; - gboolean _tmp11_ = FALSE; - gboolean _tmp12_ = FALSE; -#line 39 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - g_return_if_fail (self != NULL); -#line 41 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp2_ = page_view_get_selected (self); -#line 41 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp3_ = _tmp2_; -#line 41 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - if (_tmp3_) { -#line 6272 "page-view.c" - gboolean _tmp4_ = FALSE; - gboolean _tmp5_ = FALSE; -#line 41 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp4_ = page_view_get_selected (self); -#line 41 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp5_ = _tmp4_; -#line 41 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp1_ = _tmp5_; -#line 6281 "page-view.c" - } else { -#line 41 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp1_ = FALSE; -#line 6285 "page-view.c" - } -#line 41 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - if (_tmp1_) { -#line 41 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp0_ = TRUE; -#line 6291 "page-view.c" - } else { - gboolean _tmp6_ = FALSE; - gboolean _tmp7_ = FALSE; - gboolean _tmp8_ = FALSE; -#line 41 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp7_ = page_view_get_selected (self); -#line 41 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp8_ = _tmp7_; -#line 41 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - if (!_tmp8_) { -#line 6302 "page-view.c" - gboolean _tmp9_ = FALSE; - gboolean _tmp10_ = FALSE; -#line 41 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp9_ = page_view_get_selected (self); -#line 41 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp10_ = _tmp9_; -#line 41 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp6_ = !_tmp10_; -#line 6311 "page-view.c" - } else { -#line 41 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp6_ = FALSE; -#line 6315 "page-view.c" - } -#line 41 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp0_ = _tmp6_; -#line 6319 "page-view.c" - } -#line 41 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - if (_tmp0_) { -#line 42 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - return; -#line 6325 "page-view.c" - } -#line 43 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp11_ = page_view_get_selected (self); -#line 43 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp12_ = _tmp11_; -#line 43 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - page_view_set_selected (self, _tmp12_); -#line 44 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - g_signal_emit_by_name (self, "changed"); -#line 6335 "page-view.c" -} - - -gint page_view_get_x_offset (PageView* self) { - gint result; - gint _tmp0_ = 0; -#line 64 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - g_return_val_if_fail (self != NULL, 0); -#line 64 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp0_ = self->priv->_x_offset; -#line 64 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - result = _tmp0_; -#line 64 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - return result; -#line 6350 "page-view.c" -} - - -void page_view_set_x_offset (PageView* self, gint value) { - gint _tmp0_ = 0; -#line 64 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - g_return_if_fail (self != NULL); -#line 64 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp0_ = value; -#line 64 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - self->priv->_x_offset = _tmp0_; -#line 6362 "page-view.c" -} - - -gint page_view_get_y_offset (PageView* self) { - gint result; - gint _tmp0_ = 0; -#line 65 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - g_return_val_if_fail (self != NULL, 0); -#line 65 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp0_ = self->priv->_y_offset; -#line 65 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - result = _tmp0_; -#line 65 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - return result; -#line 6377 "page-view.c" -} - - -void page_view_set_y_offset (PageView* self, gint value) { - gint _tmp0_ = 0; -#line 65 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - g_return_if_fail (self != NULL); -#line 65 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp0_ = value; -#line 65 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - self->priv->_y_offset = _tmp0_; -#line 6389 "page-view.c" -} - - -GdkCursorType page_view_get_cursor (PageView* self) { - GdkCursorType result; - GdkCursorType _tmp0_ = 0; -#line 76 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - g_return_val_if_fail (self != NULL, 0); -#line 76 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp0_ = self->priv->_cursor; -#line 76 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - result = _tmp0_; -#line 76 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - return result; -#line 6404 "page-view.c" -} - - -static void page_view_set_cursor (PageView* self, GdkCursorType value) { - GdkCursorType _tmp0_ = 0; -#line 76 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - g_return_if_fail (self != NULL); -#line 76 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp0_ = value; -#line 76 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - self->priv->_cursor = _tmp0_; -#line 6416 "page-view.c" -} - - -gint page_view_get_width (PageView* self) { - gint result; - gint _tmp0_ = 0; -#line 954 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - g_return_val_if_fail (self != NULL, 0); -#line 954 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp0_ = self->priv->width_; -#line 954 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - result = _tmp0_; -#line 954 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - return result; -#line 6431 "page-view.c" -} - - -void page_view_set_width (PageView* self, gint value) { - gint h = 0; - gint _tmp0_ = 0; - Page* _tmp1_ = NULL; - gint _tmp2_ = 0; - gint _tmp3_ = 0; - Page* _tmp4_ = NULL; - gint _tmp5_ = 0; - gint _tmp6_ = 0; - gboolean _tmp7_ = FALSE; - gint _tmp8_ = 0; - gint _tmp9_ = 0; - gint _tmp12_ = 0; - gint _tmp13_ = 0; -#line 955 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - g_return_if_fail (self != NULL); -#line 958 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp0_ = value; -#line 958 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp1_ = self->priv->_page; -#line 958 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp2_ = page_get_height (_tmp1_); -#line 958 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp3_ = _tmp2_; -#line 958 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp4_ = self->priv->_page; -#line 958 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp5_ = page_get_width (_tmp4_); -#line 958 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp6_ = _tmp5_; -#line 958 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - h = (gint) ((((gdouble) _tmp0_) * _tmp3_) / _tmp6_); -#line 959 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp8_ = self->priv->width_; -#line 959 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp9_ = value; -#line 959 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - if (_tmp8_ == _tmp9_) { -#line 6473 "page-view.c" - gint _tmp10_ = 0; - gint _tmp11_ = 0; -#line 959 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp10_ = self->priv->height_; -#line 959 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp11_ = h; -#line 959 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp7_ = _tmp10_ == _tmp11_; -#line 6482 "page-view.c" - } else { -#line 959 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp7_ = FALSE; -#line 6486 "page-view.c" - } -#line 959 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - if (_tmp7_) { -#line 960 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - return; -#line 6492 "page-view.c" - } -#line 962 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp12_ = value; -#line 962 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - self->priv->width_ = _tmp12_; -#line 963 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp13_ = h; -#line 963 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - self->priv->height_ = _tmp13_; -#line 966 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - self->priv->update_image = TRUE; -#line 968 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - g_signal_emit_by_name (self, "size-changed"); -#line 969 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - g_signal_emit_by_name (self, "changed"); -#line 6508 "page-view.c" -} - - -gint page_view_get_height (PageView* self) { - gint result; - gint _tmp0_ = 0; -#line 975 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - g_return_val_if_fail (self != NULL, 0); -#line 975 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp0_ = self->priv->height_; -#line 975 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - result = _tmp0_; -#line 975 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - return result; -#line 6523 "page-view.c" -} - - -void page_view_set_height (PageView* self, gint value) { - gint w = 0; - gint _tmp0_ = 0; - Page* _tmp1_ = NULL; - gint _tmp2_ = 0; - gint _tmp3_ = 0; - Page* _tmp4_ = NULL; - gint _tmp5_ = 0; - gint _tmp6_ = 0; - gboolean _tmp7_ = FALSE; - gint _tmp8_ = 0; - gint _tmp9_ = 0; - gint _tmp12_ = 0; - gint _tmp13_ = 0; -#line 976 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - g_return_if_fail (self != NULL); -#line 979 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp0_ = value; -#line 979 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp1_ = self->priv->_page; -#line 979 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp2_ = page_get_width (_tmp1_); -#line 979 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp3_ = _tmp2_; -#line 979 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp4_ = self->priv->_page; -#line 979 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp5_ = page_get_height (_tmp4_); -#line 979 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp6_ = _tmp5_; -#line 979 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - w = (gint) ((((gdouble) _tmp0_) * _tmp3_) / _tmp6_); -#line 980 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp8_ = self->priv->width_; -#line 980 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp9_ = w; -#line 980 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - if (_tmp8_ == _tmp9_) { -#line 6565 "page-view.c" - gint _tmp10_ = 0; - gint _tmp11_ = 0; -#line 980 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp10_ = self->priv->height_; -#line 980 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp11_ = value; -#line 980 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp7_ = _tmp10_ == _tmp11_; -#line 6574 "page-view.c" - } else { -#line 980 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp7_ = FALSE; -#line 6578 "page-view.c" - } -#line 980 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - if (_tmp7_) { -#line 981 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - return; -#line 6584 "page-view.c" - } -#line 983 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp12_ = w; -#line 983 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - self->priv->width_ = _tmp12_; -#line 984 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp13_ = value; -#line 984 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - self->priv->height_ = _tmp13_; -#line 987 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - self->priv->update_image = TRUE; -#line 989 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - g_signal_emit_by_name (self, "size-changed"); -#line 990 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - g_signal_emit_by_name (self, "changed"); -#line 6600 "page-view.c" -} - - -static void value_page_view_init (GValue* value) { -#line 26 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - value->data[0].v_pointer = NULL; -#line 6607 "page-view.c" -} - - -static void value_page_view_free_value (GValue* value) { -#line 26 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - if (value->data[0].v_pointer) { -#line 26 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - page_view_unref (value->data[0].v_pointer); -#line 6616 "page-view.c" - } -} - - -static void value_page_view_copy_value (const GValue* src_value, GValue* dest_value) { -#line 26 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - if (src_value->data[0].v_pointer) { -#line 26 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - dest_value->data[0].v_pointer = page_view_ref (src_value->data[0].v_pointer); -#line 6626 "page-view.c" - } else { -#line 26 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - dest_value->data[0].v_pointer = NULL; -#line 6630 "page-view.c" - } -} - - -static gpointer value_page_view_peek_pointer (const GValue* value) { -#line 26 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - return value->data[0].v_pointer; -#line 6638 "page-view.c" -} - - -static gchar* value_page_view_collect_value (GValue* value, guint n_collect_values, GTypeCValue* collect_values, guint collect_flags) { -#line 26 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - if (collect_values[0].v_pointer) { -#line 6645 "page-view.c" - PageView* object; - object = collect_values[0].v_pointer; -#line 26 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - if (object->parent_instance.g_class == NULL) { -#line 26 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - return g_strconcat ("invalid unclassed object pointer for value type `", G_VALUE_TYPE_NAME (value), "'", NULL); -#line 6652 "page-view.c" - } else if (!g_value_type_compatible (G_TYPE_FROM_INSTANCE (object), G_VALUE_TYPE (value))) { -#line 26 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - return g_strconcat ("invalid object type `", g_type_name (G_TYPE_FROM_INSTANCE (object)), "' for value type `", G_VALUE_TYPE_NAME (value), "'", NULL); -#line 6656 "page-view.c" - } -#line 26 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - value->data[0].v_pointer = page_view_ref (object); -#line 6660 "page-view.c" - } else { -#line 26 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - value->data[0].v_pointer = NULL; -#line 6664 "page-view.c" - } -#line 26 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - return NULL; -#line 6668 "page-view.c" -} - - -static gchar* value_page_view_lcopy_value (const GValue* value, guint n_collect_values, GTypeCValue* collect_values, guint collect_flags) { - PageView** object_p; - object_p = collect_values[0].v_pointer; -#line 26 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - if (!object_p) { -#line 26 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - return g_strdup_printf ("value location for `%s' passed as NULL", G_VALUE_TYPE_NAME (value)); -#line 6679 "page-view.c" - } -#line 26 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - if (!value->data[0].v_pointer) { -#line 26 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - *object_p = NULL; -#line 6685 "page-view.c" - } else if (collect_flags & G_VALUE_NOCOPY_CONTENTS) { -#line 26 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - *object_p = value->data[0].v_pointer; -#line 6689 "page-view.c" - } else { -#line 26 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - *object_p = page_view_ref (value->data[0].v_pointer); -#line 6693 "page-view.c" - } -#line 26 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - return NULL; -#line 6697 "page-view.c" -} - - -GParamSpec* param_spec_page_view (const gchar* name, const gchar* nick, const gchar* blurb, GType object_type, GParamFlags flags) { - ParamSpecPageView* spec; -#line 26 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - g_return_val_if_fail (g_type_is_a (object_type, TYPE_PAGE_VIEW), NULL); -#line 26 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - spec = g_param_spec_internal (G_TYPE_PARAM_OBJECT, name, nick, blurb, flags); -#line 26 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - G_PARAM_SPEC (spec)->value_type = object_type; -#line 26 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - return G_PARAM_SPEC (spec); -#line 6711 "page-view.c" -} - - -gpointer value_get_page_view (const GValue* value) { -#line 26 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - g_return_val_if_fail (G_TYPE_CHECK_VALUE_TYPE (value, TYPE_PAGE_VIEW), NULL); -#line 26 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - return value->data[0].v_pointer; -#line 6720 "page-view.c" -} - - -void value_set_page_view (GValue* value, gpointer v_object) { - PageView* old; -#line 26 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - g_return_if_fail (G_TYPE_CHECK_VALUE_TYPE (value, TYPE_PAGE_VIEW)); -#line 26 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - old = value->data[0].v_pointer; -#line 26 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - if (v_object) { -#line 26 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - g_return_if_fail (G_TYPE_CHECK_INSTANCE_TYPE (v_object, TYPE_PAGE_VIEW)); -#line 26 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - g_return_if_fail (g_value_type_compatible (G_TYPE_FROM_INSTANCE (v_object), G_VALUE_TYPE (value))); -#line 26 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - value->data[0].v_pointer = v_object; -#line 26 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - page_view_ref (value->data[0].v_pointer); -#line 6740 "page-view.c" - } else { -#line 26 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - value->data[0].v_pointer = NULL; -#line 6744 "page-view.c" - } -#line 26 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - if (old) { -#line 26 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - page_view_unref (old); -#line 6750 "page-view.c" - } -} - - -void value_take_page_view (GValue* value, gpointer v_object) { - PageView* old; -#line 26 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - g_return_if_fail (G_TYPE_CHECK_VALUE_TYPE (value, TYPE_PAGE_VIEW)); -#line 26 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - old = value->data[0].v_pointer; -#line 26 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - if (v_object) { -#line 26 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - g_return_if_fail (G_TYPE_CHECK_INSTANCE_TYPE (v_object, TYPE_PAGE_VIEW)); -#line 26 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - g_return_if_fail (g_value_type_compatible (G_TYPE_FROM_INSTANCE (v_object), G_VALUE_TYPE (value))); -#line 26 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - value->data[0].v_pointer = v_object; -#line 6769 "page-view.c" - } else { -#line 26 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - value->data[0].v_pointer = NULL; -#line 6773 "page-view.c" - } -#line 26 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - if (old) { -#line 26 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - page_view_unref (old); -#line 6779 "page-view.c" - } -} - - -static void page_view_class_init (PageViewClass * klass) { -#line 26 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - page_view_parent_class = g_type_class_peek_parent (klass); -#line 26 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - ((PageViewClass *) klass)->finalize = page_view_finalize; -#line 26 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - g_type_class_add_private (klass, sizeof (PageViewPrivate)); -#line 26 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - g_signal_new ("size_changed", TYPE_PAGE_VIEW, G_SIGNAL_RUN_LAST, 0, NULL, NULL, g_cclosure_marshal_VOID__VOID, G_TYPE_NONE, 0); -#line 26 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - g_signal_new ("changed", TYPE_PAGE_VIEW, G_SIGNAL_RUN_LAST, 0, NULL, NULL, g_cclosure_marshal_VOID__VOID, G_TYPE_NONE, 0); -#line 6795 "page-view.c" -} - - -static void page_view_instance_init (PageView * self) { -#line 26 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - self->priv = PAGE_VIEW_GET_PRIVATE (self); -#line 32 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - self->priv->image = NULL; -#line 35 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - self->priv->selected_ = FALSE; -#line 48 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - self->priv->border_width = 1; -#line 51 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - self->priv->update_image = TRUE; -#line 76 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - self->priv->_cursor = GDK_ARROW; -#line 78 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - self->priv->animate_n_segments = 7; -#line 26 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - self->ref_count = 1; -#line 6816 "page-view.c" -} - - -static void page_view_finalize (PageView* obj) { - PageView * self; - Page* _tmp0_ = NULL; - guint _tmp1_ = 0U; - Page* _tmp2_ = NULL; - guint _tmp3_ = 0U; - Page* _tmp4_ = NULL; - guint _tmp5_ = 0U; - Page* _tmp6_ = NULL; - guint _tmp7_ = 0U; - Page* _tmp8_ = NULL; - guint _tmp9_ = 0U; -#line 26 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - self = G_TYPE_CHECK_INSTANCE_CAST (obj, TYPE_PAGE_VIEW, PageView); -#line 26 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - g_signal_handlers_destroy (self); -#line 97 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp0_ = self->priv->_page; -#line 97 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - g_signal_parse_name ("pixels-changed", TYPE_PAGE, &_tmp1_, NULL, FALSE); -#line 97 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - g_signal_handlers_disconnect_matched (_tmp0_, G_SIGNAL_MATCH_ID | G_SIGNAL_MATCH_FUNC | G_SIGNAL_MATCH_DATA, _tmp1_, 0, NULL, (GCallback) _page_view_page_pixels_changed_cb_page_pixels_changed, self); -#line 98 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp2_ = self->priv->_page; -#line 98 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - g_signal_parse_name ("size-changed", TYPE_PAGE, &_tmp3_, NULL, FALSE); -#line 98 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - g_signal_handlers_disconnect_matched (_tmp2_, G_SIGNAL_MATCH_ID | G_SIGNAL_MATCH_FUNC | G_SIGNAL_MATCH_DATA, _tmp3_, 0, NULL, (GCallback) _page_view_page_size_changed_cb_page_size_changed, self); -#line 99 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp4_ = self->priv->_page; -#line 99 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - g_signal_parse_name ("crop-changed", TYPE_PAGE, &_tmp5_, NULL, FALSE); -#line 99 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - g_signal_handlers_disconnect_matched (_tmp4_, G_SIGNAL_MATCH_ID | G_SIGNAL_MATCH_FUNC | G_SIGNAL_MATCH_DATA, _tmp5_, 0, NULL, (GCallback) _page_view_page_overlay_changed_cb_page_crop_changed, self); -#line 100 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp6_ = self->priv->_page; -#line 100 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - g_signal_parse_name ("scan-line-changed", TYPE_PAGE, &_tmp7_, NULL, FALSE); -#line 100 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - g_signal_handlers_disconnect_matched (_tmp6_, G_SIGNAL_MATCH_ID | G_SIGNAL_MATCH_FUNC | G_SIGNAL_MATCH_DATA, _tmp7_, 0, NULL, (GCallback) _page_view_page_overlay_changed_cb_page_scan_line_changed, self); -#line 101 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _tmp8_ = self->priv->_page; -#line 101 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - g_signal_parse_name ("scan-direction-changed", TYPE_PAGE, &_tmp9_, NULL, FALSE); -#line 101 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - g_signal_handlers_disconnect_matched (_tmp8_, G_SIGNAL_MATCH_ID | G_SIGNAL_MATCH_FUNC | G_SIGNAL_MATCH_DATA, _tmp9_, 0, NULL, (GCallback) _page_view_scan_direction_changed_cb_page_scan_direction_changed, self); -#line 29 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _page_unref0 (self->priv->_page); -#line 32 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - _g_object_unref0 (self->priv->image); -#line 6870 "page-view.c" -} - - -GType page_view_get_type (void) { - static volatile gsize page_view_type_id__volatile = 0; - if (g_once_init_enter (&page_view_type_id__volatile)) { - static const GTypeValueTable g_define_type_value_table = { value_page_view_init, value_page_view_free_value, value_page_view_copy_value, value_page_view_peek_pointer, "p", value_page_view_collect_value, "p", value_page_view_lcopy_value }; - static const GTypeInfo g_define_type_info = { sizeof (PageViewClass), (GBaseInitFunc) NULL, (GBaseFinalizeFunc) NULL, (GClassInitFunc) page_view_class_init, (GClassFinalizeFunc) NULL, NULL, sizeof (PageView), 0, (GInstanceInitFunc) page_view_instance_init, &g_define_type_value_table }; - static const GTypeFundamentalInfo g_define_type_fundamental_info = { (G_TYPE_FLAG_CLASSED | G_TYPE_FLAG_INSTANTIATABLE | G_TYPE_FLAG_DERIVABLE | G_TYPE_FLAG_DEEP_DERIVABLE) }; - GType page_view_type_id; - page_view_type_id = g_type_register_fundamental (g_type_fundamental_next (), "PageView", &g_define_type_info, &g_define_type_fundamental_info, 0); - g_once_init_leave (&page_view_type_id__volatile, page_view_type_id); - } - return page_view_type_id__volatile; -} - - -gpointer page_view_ref (gpointer instance) { - PageView* self; - self = instance; -#line 26 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - g_atomic_int_inc (&self->ref_count); -#line 26 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - return instance; -#line 6895 "page-view.c" -} - - -void page_view_unref (gpointer instance) { - PageView* self; - self = instance; -#line 26 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - if (g_atomic_int_dec_and_test (&self->ref_count)) { -#line 26 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - PAGE_VIEW_GET_CLASS (self)->finalize (self); -#line 26 "/home/bob/bzr/simple-scan/trunk/src/page-view.vala" - g_type_free_instance ((GTypeInstance *) self); -#line 6908 "page-view.c" - } -} - - - diff --git a/src/page.c b/src/page.c deleted file mode 100644 index 9a3db07..0000000 --- a/src/page.c +++ /dev/null @@ -1,4943 +0,0 @@ -/* page.c generated by valac 0.34.6, the Vala compiler - * generated from page.vala, do not modify */ - -/* - * Copyright (C) 2009-2015 Canonical Ltd. - * Author: Robert Ancell - * - * This program is free software: you can redistribute it and/or modify it under - * the terms of the GNU General Public License as published by the Free Software - * Foundation, either version 3 of the License, or (at your option) any later - * version. See http://www.gnu.org/copyleft/gpl.html the full text of the - * license. - */ - -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include - - -#define TYPE_SCAN_DIRECTION (scan_direction_get_type ()) - -#define TYPE_PAGE (page_get_type ()) -#define PAGE(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), TYPE_PAGE, Page)) -#define PAGE_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST ((klass), TYPE_PAGE, PageClass)) -#define IS_PAGE(obj) (G_TYPE_CHECK_INSTANCE_TYPE ((obj), TYPE_PAGE)) -#define IS_PAGE_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE ((klass), TYPE_PAGE)) -#define PAGE_GET_CLASS(obj) (G_TYPE_INSTANCE_GET_CLASS ((obj), TYPE_PAGE, PageClass)) - -typedef struct _Page Page; -typedef struct _PageClass PageClass; -typedef struct _PagePrivate PagePrivate; -#define _g_free0(var) (var = (g_free (var), NULL)) - -#define TYPE_SCAN_PAGE_INFO (scan_page_info_get_type ()) -#define SCAN_PAGE_INFO(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), TYPE_SCAN_PAGE_INFO, ScanPageInfo)) -#define SCAN_PAGE_INFO_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST ((klass), TYPE_SCAN_PAGE_INFO, ScanPageInfoClass)) -#define IS_SCAN_PAGE_INFO(obj) (G_TYPE_CHECK_INSTANCE_TYPE ((obj), TYPE_SCAN_PAGE_INFO)) -#define IS_SCAN_PAGE_INFO_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE ((klass), TYPE_SCAN_PAGE_INFO)) -#define SCAN_PAGE_INFO_GET_CLASS(obj) (G_TYPE_INSTANCE_GET_CLASS ((obj), TYPE_SCAN_PAGE_INFO, ScanPageInfoClass)) - -typedef struct _ScanPageInfo ScanPageInfo; -typedef struct _ScanPageInfoClass ScanPageInfoClass; -typedef struct _ScanPageInfoPrivate ScanPageInfoPrivate; - -#define TYPE_SCAN_LINE (scan_line_get_type ()) -#define SCAN_LINE(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), TYPE_SCAN_LINE, ScanLine)) -#define SCAN_LINE_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST ((klass), TYPE_SCAN_LINE, ScanLineClass)) -#define IS_SCAN_LINE(obj) (G_TYPE_CHECK_INSTANCE_TYPE ((obj), TYPE_SCAN_LINE)) -#define IS_SCAN_LINE_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE ((klass), TYPE_SCAN_LINE)) -#define SCAN_LINE_GET_CLASS(obj) (G_TYPE_INSTANCE_GET_CLASS ((obj), TYPE_SCAN_LINE, ScanLineClass)) - -typedef struct _ScanLine ScanLine; -typedef struct _ScanLineClass ScanLineClass; -typedef struct _ScanLinePrivate ScanLinePrivate; -#define _g_object_unref0(var) ((var == NULL) ? NULL : (var = (g_object_unref (var), NULL))) -#define _g_error_free0(var) ((var == NULL) ? NULL : (var = (g_error_free (var), NULL))) - -#define TYPE_PIXBUF_WRITER (pixbuf_writer_get_type ()) -#define PIXBUF_WRITER(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), TYPE_PIXBUF_WRITER, PixbufWriter)) -#define PIXBUF_WRITER_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST ((klass), TYPE_PIXBUF_WRITER, PixbufWriterClass)) -#define IS_PIXBUF_WRITER(obj) (G_TYPE_CHECK_INSTANCE_TYPE ((obj), TYPE_PIXBUF_WRITER)) -#define IS_PIXBUF_WRITER_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE ((klass), TYPE_PIXBUF_WRITER)) -#define PIXBUF_WRITER_GET_CLASS(obj) (G_TYPE_INSTANCE_GET_CLASS ((obj), TYPE_PIXBUF_WRITER, PixbufWriterClass)) - -typedef struct _PixbufWriter PixbufWriter; -typedef struct _PixbufWriterClass PixbufWriterClass; -#define _pixbuf_writer_unref0(var) ((var == NULL) ? NULL : (var = (pixbuf_writer_unref (var), NULL))) -typedef struct _ParamSpecPage ParamSpecPage; -typedef struct _PixbufWriterPrivate PixbufWriterPrivate; -typedef struct _ParamSpecPixbufWriter ParamSpecPixbufWriter; - -typedef enum { - SCAN_DIRECTION_TOP_TO_BOTTOM, - SCAN_DIRECTION_LEFT_TO_RIGHT, - SCAN_DIRECTION_BOTTOM_TO_TOP, - SCAN_DIRECTION_RIGHT_TO_LEFT -} ScanDirection; - -struct _Page { - GTypeInstance parent_instance; - volatile int ref_count; - PagePrivate * priv; -}; - -struct _PageClass { - GTypeClass parent_class; - void (*finalize) (Page *self); -}; - -struct _PagePrivate { - gint _dpi; - gint expected_rows; - gint _depth; - gchar* _color_profile; - gint _scan_width; - gint _scan_height; - gint _rowstride; - gint _n_channels; - guchar* pixels; - gint pixels_length1; - gint _pixels_size_; - gboolean _is_scanning; - gboolean _has_data; - gint _scan_line; - ScanDirection scan_direction_; - gboolean _has_crop; - gchar* _crop_name; - gint _crop_x; - gint _crop_y; - gint _crop_width; - gint _crop_height; -}; - -struct _ScanPageInfo { - GTypeInstance parent_instance; - volatile int ref_count; - ScanPageInfoPrivate * priv; - gint width; - gint height; - gint depth; - gint n_channels; - gdouble dpi; - gchar* device; -}; - -struct _ScanPageInfoClass { - GTypeClass parent_class; - void (*finalize) (ScanPageInfo *self); -}; - -struct _ScanLine { - GTypeInstance parent_instance; - volatile int ref_count; - ScanLinePrivate * priv; - gint number; - gint n_lines; - gint width; - gint depth; - gint channel; - guchar* data; - gint data_length1; - gint data_length; -}; - -struct _ScanLineClass { - GTypeClass parent_class; - void (*finalize) (ScanLine *self); -}; - -struct _ParamSpecPage { - GParamSpec parent_instance; -}; - -struct _PixbufWriter { - GTypeInstance parent_instance; - volatile int ref_count; - PixbufWriterPrivate * priv; - GFileOutputStream* stream; -}; - -struct _PixbufWriterClass { - GTypeClass parent_class; - void (*finalize) (PixbufWriter *self); -}; - -struct _ParamSpecPixbufWriter { - GParamSpec parent_instance; -}; - - -static gpointer page_parent_class = NULL; -static gpointer pixbuf_writer_parent_class = NULL; - -GType scan_direction_get_type (void) G_GNUC_CONST; -gpointer page_ref (gpointer instance); -void page_unref (gpointer instance); -GParamSpec* param_spec_page (const gchar* name, const gchar* nick, const gchar* blurb, GType object_type, GParamFlags flags); -void value_set_page (GValue* value, gpointer v_object); -void value_take_page (GValue* value, gpointer v_object); -gpointer value_get_page (const GValue* value); -GType page_get_type (void) G_GNUC_CONST; -#define PAGE_GET_PRIVATE(o) (G_TYPE_INSTANCE_GET_PRIVATE ((o), TYPE_PAGE, PagePrivate)) -enum { - PAGE_DUMMY_PROPERTY -}; -Page* page_new (gint width, gint height, gint dpi, ScanDirection scan_direction); -Page* page_construct (GType object_type, gint width, gint height, gint dpi, ScanDirection scan_direction); -static void page_set_scan_width (Page* self, gint value); -static void page_set_scan_height (Page* self, gint value); -static void page_set_dpi (Page* self, gint value); -void page_set_scan_direction (Page* self, ScanDirection value); -Page* page_new_from_data (gint scan_width, gint scan_height, gint rowstride, gint n_channels, gint depth, gint dpi, ScanDirection scan_direction, const gchar* color_profile, guchar* pixels, int pixels_length1, gboolean has_crop, const gchar* crop_name, gint crop_x, gint crop_y, gint crop_width, gint crop_height); -Page* page_construct_from_data (GType object_type, gint scan_width, gint scan_height, gint rowstride, gint n_channels, gint depth, gint dpi, ScanDirection scan_direction, const gchar* color_profile, guchar* pixels, int pixels_length1, gboolean has_crop, const gchar* crop_name, gint crop_x, gint crop_y, gint crop_width, gint crop_height); -static void page_set_rowstride (Page* self, gint value); -static void page_set_n_channels (Page* self, gint value); -static void page_set_depth (Page* self, gint value); -void page_set_color_profile (Page* self, const gchar* value); -static guchar* _vala_array_dup3 (guchar* self, int length); -static void page_set_has_data (Page* self, gboolean value); -static void page_set_has_crop (Page* self, gboolean value); -static void page_set_crop_name (Page* self, const gchar* value); -static void page_set_crop_x (Page* self, gint value); -static void page_set_crop_y (Page* self, gint value); -static void page_set_crop_width (Page* self, gint value); -static void page_set_crop_height (Page* self, gint value); -gpointer scan_page_info_ref (gpointer instance); -void scan_page_info_unref (gpointer instance); -GParamSpec* param_spec_scan_page_info (const gchar* name, const gchar* nick, const gchar* blurb, GType object_type, GParamFlags flags); -void value_set_scan_page_info (GValue* value, gpointer v_object); -void value_take_scan_page_info (GValue* value, gpointer v_object); -gpointer value_get_scan_page_info (const GValue* value); -GType scan_page_info_get_type (void) G_GNUC_CONST; -void page_set_page_info (Page* self, ScanPageInfo* info); -gint page_get_scan_height (Page* self); -gint page_get_scan_width (Page* self); -gint page_get_depth (Page* self); -gint page_get_n_channels (Page* self); -gint page_get_rowstride (Page* self); -void page_start (Page* self); -static void page_set_is_scanning (Page* self, gboolean value); -gpointer scan_line_ref (gpointer instance); -void scan_line_unref (gpointer instance); -GParamSpec* param_spec_scan_line (const gchar* name, const gchar* nick, const gchar* blurb, GType object_type, GParamFlags flags); -void value_set_scan_line (GValue* value, gpointer v_object); -void value_take_scan_line (GValue* value, gpointer v_object); -gpointer value_get_scan_line (const GValue* value); -GType scan_line_get_type (void) G_GNUC_CONST; -static void page_parse_line (Page* self, ScanLine* line, gint n, gboolean* size_changed); -static void page_set_scan_line (Page* self, gint value); -void page_parse_scan_line (Page* self, ScanLine* line); -void page_finish (Page* self); -gint page_get_scan_line (Page* self); -void page_rotate_left (Page* self); -ScanDirection page_get_scan_direction (Page* self); -void page_rotate_right (Page* self); -void page_set_no_crop (Page* self); -gboolean page_get_has_crop (Page* self); -void page_set_custom_crop (Page* self, gint width, gint height); -const gchar* page_get_crop_name (Page* self); -gint page_get_crop_width (Page* self); -gint page_get_crop_height (Page* self); -void page_set_named_crop (Page* self, const gchar* name); -gint page_get_width (Page* self); -gint page_get_height (Page* self); -gint page_get_dpi (Page* self); -void page_move_crop (Page* self, gint x, gint y); -void page_rotate_crop (Page* self); -gint page_get_crop_x (Page* self); -gint page_get_crop_y (Page* self); -guchar* page_get_pixels (Page* self, int* result_length1); -static guchar page_get_sample (Page* self, guchar* pixels, int pixels_length1, gint offset, gint x, gint depth, gint n_channels, gint channel); -static void page_get_pixel (Page* self, gint x, gint y, guchar* pixel, int pixel_length1, gint offset); -GdkPixbuf* page_get_image (Page* self, gboolean apply_crop); -static gchar* page_get_icc_data_encoded (Page* self, const gchar* icc_profile_filename); -void page_copy_to_clipboard (Page* self, GtkWindow* window); -void page_save (Page* self, const gchar* type, gint quality, GFile* file, GError** error); -gpointer pixbuf_writer_ref (gpointer instance); -void pixbuf_writer_unref (gpointer instance); -GParamSpec* param_spec_pixbuf_writer (const gchar* name, const gchar* nick, const gchar* blurb, GType object_type, GParamFlags flags); -void value_set_pixbuf_writer (GValue* value, gpointer v_object); -void value_take_pixbuf_writer (GValue* value, gpointer v_object); -gpointer value_get_pixbuf_writer (const GValue* value); -GType pixbuf_writer_get_type (void) G_GNUC_CONST; -PixbufWriter* pixbuf_writer_new (GFileOutputStream* stream); -PixbufWriter* pixbuf_writer_construct (GType object_type, GFileOutputStream* stream); -const gchar* page_get_color_profile (Page* self); -void pixbuf_writer_save (PixbufWriter* self, GdkPixbuf* image, const gchar* type, gchar** option_keys, int option_keys_length1, gchar** option_values, int option_values_length1, GError** error); -gboolean page_get_is_landscape (Page* self); -gboolean page_get_is_scanning (Page* self); -gboolean page_get_has_data (Page* self); -gboolean page_get_is_color (Page* self); -static void page_finalize (Page* obj); -enum { - PIXBUF_WRITER_DUMMY_PROPERTY -}; -static gboolean pixbuf_writer_write_pixbuf_data (PixbufWriter* self, guint8* buf, int buf_length1, GError** error); -static gboolean _pixbuf_writer_write_pixbuf_data_gdk_pixbuf_save_func (guint8* buf, gsize buf_length1, GError** error, gpointer self); -static void pixbuf_writer_finalize (PixbufWriter* obj); -static void _vala_array_destroy (gpointer array, gint array_length, GDestroyNotify destroy_func); -static void _vala_array_free (gpointer array, gint array_length, GDestroyNotify destroy_func); - - -GType scan_direction_get_type (void) { - static volatile gsize scan_direction_type_id__volatile = 0; - if (g_once_init_enter (&scan_direction_type_id__volatile)) { - static const GEnumValue values[] = {{SCAN_DIRECTION_TOP_TO_BOTTOM, "SCAN_DIRECTION_TOP_TO_BOTTOM", "top-to-bottom"}, {SCAN_DIRECTION_LEFT_TO_RIGHT, "SCAN_DIRECTION_LEFT_TO_RIGHT", "left-to-right"}, {SCAN_DIRECTION_BOTTOM_TO_TOP, "SCAN_DIRECTION_BOTTOM_TO_TOP", "bottom-to-top"}, {SCAN_DIRECTION_RIGHT_TO_LEFT, "SCAN_DIRECTION_RIGHT_TO_LEFT", "right-to-left"}, {0, NULL, NULL}}; - GType scan_direction_type_id; - scan_direction_type_id = g_enum_register_static ("ScanDirection", values); - g_once_init_leave (&scan_direction_type_id__volatile, scan_direction_type_id); - } - return scan_direction_type_id__volatile; -} - - -Page* page_construct (GType object_type, gint width, gint height, gint dpi, ScanDirection scan_direction) { - Page* self = NULL; - gboolean _tmp0_ = FALSE; - ScanDirection _tmp1_ = 0; - gint _tmp7_ = 0; - ScanDirection _tmp8_ = 0; -#line 174 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - self = (Page*) g_type_create_instance (object_type); -#line 176 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp1_ = scan_direction; -#line 176 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - if (_tmp1_ == SCAN_DIRECTION_TOP_TO_BOTTOM) { -#line 176 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp0_ = TRUE; -#line 319 "page.c" - } else { - ScanDirection _tmp2_ = 0; -#line 176 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp2_ = scan_direction; -#line 176 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp0_ = _tmp2_ == SCAN_DIRECTION_BOTTOM_TO_TOP; -#line 326 "page.c" - } -#line 176 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - if (_tmp0_) { -#line 330 "page.c" - gint _tmp3_ = 0; - gint _tmp4_ = 0; -#line 178 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp3_ = width; -#line 178 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - page_set_scan_width (self, _tmp3_); -#line 179 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp4_ = height; -#line 179 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - page_set_scan_height (self, _tmp4_); -#line 341 "page.c" - } else { - gint _tmp5_ = 0; - gint _tmp6_ = 0; -#line 183 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp5_ = height; -#line 183 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - page_set_scan_width (self, _tmp5_); -#line 184 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp6_ = width; -#line 184 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - page_set_scan_height (self, _tmp6_); -#line 353 "page.c" - } -#line 186 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp7_ = dpi; -#line 186 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - page_set_dpi (self, _tmp7_); -#line 187 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp8_ = scan_direction; -#line 187 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - page_set_scan_direction (self, _tmp8_); -#line 174 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - return self; -#line 365 "page.c" -} - - -Page* page_new (gint width, gint height, gint dpi, ScanDirection scan_direction) { -#line 174 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - return page_construct (TYPE_PAGE, width, height, dpi, scan_direction); -#line 372 "page.c" -} - - -static guchar* _vala_array_dup3 (guchar* self, int length) { -#line 215 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - return g_memdup (self, length * sizeof (guchar)); -#line 379 "page.c" -} - - -Page* page_construct_from_data (GType object_type, gint scan_width, gint scan_height, gint rowstride, gint n_channels, gint depth, gint dpi, ScanDirection scan_direction, const gchar* color_profile, guchar* pixels, int pixels_length1, gboolean has_crop, const gchar* crop_name, gint crop_x, gint crop_y, gint crop_width, gint crop_height) { - Page* self = NULL; - gint _tmp0_ = 0; - gint _tmp1_ = 0; - gint _tmp2_ = 0; - gint _tmp3_ = 0; - gint _tmp4_ = 0; - gint _tmp5_ = 0; - gint _tmp6_ = 0; - ScanDirection _tmp7_ = 0; - const gchar* _tmp8_ = NULL; - guchar* _tmp9_ = NULL; - gint _tmp9__length1 = 0; - guchar* _tmp10_ = NULL; - gint _tmp10__length1 = 0; - guchar* _tmp11_ = NULL; - gint _tmp11__length1 = 0; - gboolean _tmp12_ = FALSE; - const gchar* _tmp13_ = NULL; - gint _tmp14_ = 0; - gint _tmp15_ = 0; - gint _tmp16_ = 0; - gint _tmp17_ = 0; -#line 190 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - self = (Page*) g_type_create_instance (object_type); -#line 206 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp0_ = scan_width; -#line 206 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - page_set_scan_width (self, _tmp0_); -#line 207 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp1_ = scan_height; -#line 207 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - page_set_scan_height (self, _tmp1_); -#line 208 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp2_ = scan_height; -#line 208 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - self->priv->expected_rows = _tmp2_; -#line 209 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp3_ = rowstride; -#line 209 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - page_set_rowstride (self, _tmp3_); -#line 210 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp4_ = n_channels; -#line 210 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - page_set_n_channels (self, _tmp4_); -#line 211 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp5_ = depth; -#line 211 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - page_set_depth (self, _tmp5_); -#line 212 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp6_ = dpi; -#line 212 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - page_set_dpi (self, _tmp6_); -#line 213 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp7_ = scan_direction; -#line 213 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - page_set_scan_direction (self, _tmp7_); -#line 214 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp8_ = color_profile; -#line 214 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - page_set_color_profile (self, _tmp8_); -#line 215 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp9_ = pixels; -#line 215 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp9__length1 = pixels_length1; -#line 215 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp10_ = (_tmp9_ != NULL) ? _vala_array_dup3 (_tmp9_, _tmp9__length1) : ((gpointer) _tmp9_); -#line 215 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp10__length1 = _tmp9__length1; -#line 215 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - self->priv->pixels = (g_free (self->priv->pixels), NULL); -#line 215 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - self->priv->pixels = _tmp10_; -#line 215 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - self->priv->pixels_length1 = _tmp10__length1; -#line 215 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - self->priv->_pixels_size_ = self->priv->pixels_length1; -#line 216 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp11_ = pixels; -#line 216 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp11__length1 = pixels_length1; -#line 216 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - page_set_has_data (self, _tmp11_ != NULL); -#line 217 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp12_ = has_crop; -#line 217 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - page_set_has_crop (self, _tmp12_); -#line 218 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp13_ = crop_name; -#line 218 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - page_set_crop_name (self, _tmp13_); -#line 219 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp14_ = crop_x; -#line 219 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - page_set_crop_x (self, _tmp14_); -#line 220 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp15_ = crop_y; -#line 220 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - page_set_crop_y (self, _tmp15_); -#line 221 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp16_ = crop_width; -#line 221 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - page_set_crop_width (self, _tmp16_); -#line 222 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp17_ = crop_height; -#line 222 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - page_set_crop_height (self, _tmp17_); -#line 190 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - return self; -#line 492 "page.c" -} - - -Page* page_new_from_data (gint scan_width, gint scan_height, gint rowstride, gint n_channels, gint depth, gint dpi, ScanDirection scan_direction, const gchar* color_profile, guchar* pixels, int pixels_length1, gboolean has_crop, const gchar* crop_name, gint crop_x, gint crop_y, gint crop_width, gint crop_height) { -#line 190 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - return page_construct_from_data (TYPE_PAGE, scan_width, scan_height, rowstride, n_channels, depth, dpi, scan_direction, color_profile, pixels, pixels_length1, has_crop, crop_name, crop_x, crop_y, crop_width, crop_height); -#line 499 "page.c" -} - - -void page_set_page_info (Page* self, ScanPageInfo* info) { - ScanPageInfo* _tmp0_ = NULL; - gint _tmp1_ = 0; - ScanPageInfo* _tmp2_ = NULL; - gdouble _tmp3_ = 0.0; - ScanPageInfo* _tmp4_ = NULL; - gint _tmp5_ = 0; - ScanPageInfo* _tmp6_ = NULL; - gint _tmp7_ = 0; - gint _tmp8_ = 0; - ScanPageInfo* _tmp10_ = NULL; - gint _tmp11_ = 0; - ScanPageInfo* _tmp12_ = NULL; - gint _tmp13_ = 0; - gint _tmp14_ = 0; - gint _tmp15_ = 0; - gint _tmp16_ = 0; - gint _tmp17_ = 0; - gint _tmp18_ = 0; - gint _tmp19_ = 0; - guchar* _tmp20_ = NULL; - gint _tmp20__length1 = 0; - gint _tmp21_ = 0; -#line 225 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - g_return_if_fail (self != NULL); -#line 225 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - g_return_if_fail (info != NULL); -#line 227 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp0_ = info; -#line 227 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp1_ = _tmp0_->height; -#line 227 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - self->priv->expected_rows = _tmp1_; -#line 228 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp2_ = info; -#line 228 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp3_ = _tmp2_->dpi; -#line 228 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - page_set_dpi (self, (gint) _tmp3_); -#line 231 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp4_ = info; -#line 231 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp5_ = _tmp4_->width; -#line 231 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - page_set_scan_width (self, _tmp5_); -#line 232 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp6_ = info; -#line 232 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp7_ = _tmp6_->height; -#line 232 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - page_set_scan_height (self, _tmp7_); -#line 234 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp8_ = self->priv->_scan_height; -#line 234 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - if (_tmp8_ < 0) { -#line 558 "page.c" - gint _tmp9_ = 0; -#line 235 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp9_ = self->priv->_scan_width; -#line 235 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - page_set_scan_height (self, _tmp9_ / 2); -#line 564 "page.c" - } -#line 236 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp10_ = info; -#line 236 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp11_ = _tmp10_->depth; -#line 236 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - page_set_depth (self, _tmp11_); -#line 237 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp12_ = info; -#line 237 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp13_ = _tmp12_->n_channels; -#line 237 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - page_set_n_channels (self, _tmp13_); -#line 238 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp14_ = self->priv->_scan_width; -#line 238 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp15_ = self->priv->_depth; -#line 238 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp16_ = self->priv->_n_channels; -#line 238 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - page_set_rowstride (self, (((_tmp14_ * _tmp15_) * _tmp16_) + 7) / 8); -#line 239 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp17_ = self->priv->_scan_height; -#line 239 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp18_ = self->priv->_rowstride; -#line 239 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp19_ = _tmp17_ * _tmp18_; -#line 239 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - self->priv->pixels = g_renew (guchar, self->priv->pixels, _tmp17_ * _tmp18_); -#line 239 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - (_tmp19_ > self->priv->pixels_length1) ? memset (self->priv->pixels + self->priv->pixels_length1, 0, sizeof (guchar) * (_tmp19_ - self->priv->pixels_length1)) : NULL; -#line 239 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - self->priv->pixels_length1 = _tmp19_; -#line 239 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - self->priv->_pixels_size_ = _tmp19_; -#line 240 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp20_ = self->priv->pixels; -#line 240 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp20__length1 = self->priv->pixels_length1; -#line 240 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - g_return_if_fail (_tmp20_ != NULL); -#line 243 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp21_ = self->priv->_depth; -#line 243 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - if (_tmp21_ == 1) { -#line 610 "page.c" - guchar* _tmp22_ = NULL; - gint _tmp22__length1 = 0; - gint _tmp23_ = 0; - gint _tmp24_ = 0; -#line 244 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp22_ = self->priv->pixels; -#line 244 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp22__length1 = self->priv->pixels_length1; -#line 244 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp23_ = self->priv->_scan_height; -#line 244 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp24_ = self->priv->_rowstride; -#line 244 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - memset (_tmp22_, 0x00, (gsize) (_tmp23_ * _tmp24_)); -#line 625 "page.c" - } else { - guchar* _tmp25_ = NULL; - gint _tmp25__length1 = 0; - gint _tmp26_ = 0; - gint _tmp27_ = 0; -#line 246 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp25_ = self->priv->pixels; -#line 246 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp25__length1 = self->priv->pixels_length1; -#line 246 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp26_ = self->priv->_scan_height; -#line 246 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp27_ = self->priv->_rowstride; -#line 246 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - memset (_tmp25_, 0xFF, (gsize) (_tmp26_ * _tmp27_)); -#line 641 "page.c" - } -#line 248 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - g_signal_emit_by_name (self, "size-changed"); -#line 249 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - g_signal_emit_by_name (self, "pixels-changed"); -#line 647 "page.c" -} - - -void page_start (Page* self) { -#line 252 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - g_return_if_fail (self != NULL); -#line 254 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - page_set_is_scanning (self, TRUE); -#line 255 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - g_signal_emit_by_name (self, "scan-line-changed"); -#line 658 "page.c" -} - - -static void page_parse_line (Page* self, ScanLine* line, gint n, gboolean* size_changed) { - gboolean _vala_size_changed = FALSE; - gint line_number = 0; - ScanLine* _tmp0_ = NULL; - gint _tmp1_ = 0; - gint _tmp2_ = 0; - gint offset = 0; - gint _tmp13_ = 0; - gint _tmp14_ = 0; - gint line_offset = 0; - gint _tmp15_ = 0; - ScanLine* _tmp16_ = NULL; - gint _tmp17_ = 0; - gint _tmp32_ = 0; -#line 258 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - g_return_if_fail (self != NULL); -#line 258 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - g_return_if_fail (line != NULL); -#line 260 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp0_ = line; -#line 260 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp1_ = _tmp0_->number; -#line 260 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp2_ = n; -#line 260 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - line_number = _tmp1_ + _tmp2_; -#line 263 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _vala_size_changed = FALSE; -#line 264 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - while (TRUE) { -#line 692 "page.c" - gint _tmp3_ = 0; - gint _tmp4_ = 0; - gint rows = 0; - gint _tmp5_ = 0; - gint _tmp6_ = 0; - gint _tmp7_ = 0; - gint _tmp8_ = 0; - gint _tmp9_ = 0; - gint _tmp10_ = 0; - gint _tmp11_ = 0; - gint _tmp12_ = 0; -#line 264 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp3_ = line_number; -#line 264 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp4_ = self->priv->_scan_height; -#line 264 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - if (!(_tmp3_ >= _tmp4_)) { -#line 264 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - break; -#line 712 "page.c" - } -#line 267 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp5_ = self->priv->_scan_height; -#line 267 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - rows = _tmp5_; -#line 268 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp6_ = rows; -#line 268 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp7_ = self->priv->_scan_width; -#line 268 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - page_set_scan_height (self, _tmp6_ + (_tmp7_ / 2)); -#line 269 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp8_ = rows; -#line 269 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp9_ = self->priv->_scan_height; -#line 269 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - g_debug ("page.vala:269: Extending image from %d lines to %d lines", _tmp8_, _tmp9_); -#line 270 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp10_ = self->priv->_scan_height; -#line 270 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp11_ = self->priv->_rowstride; -#line 270 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp12_ = _tmp10_ * _tmp11_; -#line 270 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - self->priv->pixels = g_renew (guchar, self->priv->pixels, _tmp10_ * _tmp11_); -#line 270 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - (_tmp12_ > self->priv->pixels_length1) ? memset (self->priv->pixels + self->priv->pixels_length1, 0, sizeof (guchar) * (_tmp12_ - self->priv->pixels_length1)) : NULL; -#line 270 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - self->priv->pixels_length1 = _tmp12_; -#line 270 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - self->priv->_pixels_size_ = _tmp12_; -#line 272 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _vala_size_changed = TRUE; -#line 746 "page.c" - } -#line 276 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp13_ = line_number; -#line 276 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp14_ = self->priv->_rowstride; -#line 276 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - offset = _tmp13_ * _tmp14_; -#line 277 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp15_ = n; -#line 277 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp16_ = line; -#line 277 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp17_ = _tmp16_->data_length; -#line 277 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - line_offset = _tmp15_ * _tmp17_; -#line 762 "page.c" - { - gint i = 0; -#line 278 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - i = 0; -#line 767 "page.c" - { - gboolean _tmp18_ = FALSE; -#line 278 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp18_ = TRUE; -#line 278 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - while (TRUE) { -#line 774 "page.c" - gint _tmp20_ = 0; - ScanLine* _tmp21_ = NULL; - gint _tmp22_ = 0; - guchar* _tmp23_ = NULL; - gint _tmp23__length1 = 0; - gint _tmp24_ = 0; - gint _tmp25_ = 0; - ScanLine* _tmp26_ = NULL; - guchar* _tmp27_ = NULL; - gint _tmp27__length1 = 0; - gint _tmp28_ = 0; - gint _tmp29_ = 0; - guchar _tmp30_ = '\0'; - guchar _tmp31_ = '\0'; -#line 278 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - if (!_tmp18_) { -#line 791 "page.c" - gint _tmp19_ = 0; -#line 278 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp19_ = i; -#line 278 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - i = _tmp19_ + 1; -#line 797 "page.c" - } -#line 278 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp18_ = FALSE; -#line 278 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp20_ = i; -#line 278 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp21_ = line; -#line 278 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp22_ = _tmp21_->data_length; -#line 278 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - if (!(_tmp20_ < _tmp22_)) { -#line 278 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - break; -#line 811 "page.c" - } -#line 279 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp23_ = self->priv->pixels; -#line 279 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp23__length1 = self->priv->pixels_length1; -#line 279 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp24_ = offset; -#line 279 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp25_ = i; -#line 279 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp26_ = line; -#line 279 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp27_ = _tmp26_->data; -#line 279 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp27__length1 = _tmp26_->data_length1; -#line 279 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp28_ = line_offset; -#line 279 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp29_ = i; -#line 279 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp30_ = _tmp27_[_tmp28_ + _tmp29_]; -#line 279 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp23_[_tmp24_ + _tmp25_] = _tmp30_; -#line 279 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp31_ = _tmp23_[_tmp24_ + _tmp25_]; -#line 837 "page.c" - } - } - } -#line 281 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp32_ = line_number; -#line 281 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - page_set_scan_line (self, _tmp32_); -#line 258 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - if (size_changed) { -#line 258 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - *size_changed = _vala_size_changed; -#line 849 "page.c" - } -} - - -void page_parse_scan_line (Page* self, ScanLine* line) { - gboolean size_has_changed = FALSE; - gboolean _tmp8_ = FALSE; -#line 284 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - g_return_if_fail (self != NULL); -#line 284 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - g_return_if_fail (line != NULL); -#line 286 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - size_has_changed = FALSE; -#line 863 "page.c" - { - gint i = 0; -#line 287 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - i = 0; -#line 868 "page.c" - { - gboolean _tmp0_ = FALSE; -#line 287 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp0_ = TRUE; -#line 287 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - while (TRUE) { -#line 875 "page.c" - gint _tmp2_ = 0; - ScanLine* _tmp3_ = NULL; - gint _tmp4_ = 0; - ScanLine* _tmp5_ = NULL; - gint _tmp6_ = 0; - gboolean _tmp7_ = FALSE; -#line 287 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - if (!_tmp0_) { -#line 884 "page.c" - gint _tmp1_ = 0; -#line 287 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp1_ = i; -#line 287 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - i = _tmp1_ + 1; -#line 890 "page.c" - } -#line 287 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp0_ = FALSE; -#line 287 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp2_ = i; -#line 287 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp3_ = line; -#line 287 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp4_ = _tmp3_->n_lines; -#line 287 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - if (!(_tmp2_ < _tmp4_)) { -#line 287 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - break; -#line 904 "page.c" - } -#line 288 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp5_ = line; -#line 288 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp6_ = i; -#line 288 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - page_parse_line (self, _tmp5_, _tmp6_, &_tmp7_); -#line 288 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - size_has_changed = _tmp7_; -#line 914 "page.c" - } - } - } -#line 290 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - page_set_has_data (self, TRUE); -#line 292 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp8_ = size_has_changed; -#line 292 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - if (_tmp8_) { -#line 293 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - g_signal_emit_by_name (self, "size-changed"); -#line 926 "page.c" - } -#line 294 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - g_signal_emit_by_name (self, "scan-line-changed"); -#line 295 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - g_signal_emit_by_name (self, "pixels-changed"); -#line 932 "page.c" -} - - -void page_finish (Page* self) { - gboolean size_has_changed = FALSE; - gboolean _tmp0_ = FALSE; - gint _tmp1_ = 0; - gboolean _tmp11_ = FALSE; -#line 298 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - g_return_if_fail (self != NULL); -#line 300 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - size_has_changed = FALSE; -#line 303 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp1_ = self->priv->expected_rows; -#line 303 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - if (_tmp1_ < 0) { -#line 949 "page.c" - gint _tmp2_ = 0; - gint _tmp3_ = 0; -#line 304 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp2_ = self->priv->_scan_line; -#line 304 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp3_ = self->priv->_scan_height; -#line 304 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp0_ = _tmp2_ != _tmp3_; -#line 958 "page.c" - } else { -#line 303 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp0_ = FALSE; -#line 962 "page.c" - } -#line 303 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - if (_tmp0_) { -#line 966 "page.c" - gint rows = 0; - gint _tmp4_ = 0; - gint _tmp5_ = 0; - gint _tmp6_ = 0; - gint _tmp7_ = 0; - gint _tmp8_ = 0; - gint _tmp9_ = 0; - gint _tmp10_ = 0; -#line 306 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp4_ = self->priv->_scan_height; -#line 306 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - rows = _tmp4_; -#line 307 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp5_ = self->priv->_scan_line; -#line 307 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - page_set_scan_height (self, _tmp5_); -#line 308 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp6_ = self->priv->_scan_height; -#line 308 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp7_ = self->priv->_rowstride; -#line 308 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp8_ = _tmp6_ * _tmp7_; -#line 308 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - self->priv->pixels = g_renew (guchar, self->priv->pixels, _tmp6_ * _tmp7_); -#line 308 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - (_tmp8_ > self->priv->pixels_length1) ? memset (self->priv->pixels + self->priv->pixels_length1, 0, sizeof (guchar) * (_tmp8_ - self->priv->pixels_length1)) : NULL; -#line 308 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - self->priv->pixels_length1 = _tmp8_; -#line 308 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - self->priv->_pixels_size_ = _tmp8_; -#line 309 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp9_ = rows; -#line 309 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp10_ = self->priv->_scan_height; -#line 309 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - g_debug ("page.vala:309: Trimming page from %d lines to %d lines", _tmp9_, _tmp10_); -#line 311 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - size_has_changed = TRUE; -#line 1005 "page.c" - } -#line 313 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - page_set_is_scanning (self, FALSE); -#line 315 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp11_ = size_has_changed; -#line 315 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - if (_tmp11_) { -#line 316 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - g_signal_emit_by_name (self, "size-changed"); -#line 1015 "page.c" - } -#line 317 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - g_signal_emit_by_name (self, "scan-line-changed"); -#line 318 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - g_signal_emit_by_name (self, "scan-finished"); -#line 1021 "page.c" -} - - -void page_rotate_left (Page* self) { - ScanDirection _tmp0_ = 0; - ScanDirection _tmp1_ = 0; -#line 321 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - g_return_if_fail (self != NULL); -#line 323 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp0_ = page_get_scan_direction (self); -#line 323 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp1_ = _tmp0_; -#line 323 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - switch (_tmp1_) { -#line 323 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - case SCAN_DIRECTION_TOP_TO_BOTTOM: -#line 1038 "page.c" - { -#line 326 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - page_set_scan_direction (self, SCAN_DIRECTION_LEFT_TO_RIGHT); -#line 327 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - break; -#line 1044 "page.c" - } -#line 323 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - case SCAN_DIRECTION_LEFT_TO_RIGHT: -#line 1048 "page.c" - { -#line 329 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - page_set_scan_direction (self, SCAN_DIRECTION_BOTTOM_TO_TOP); -#line 330 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - break; -#line 1054 "page.c" - } -#line 323 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - case SCAN_DIRECTION_BOTTOM_TO_TOP: -#line 1058 "page.c" - { -#line 332 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - page_set_scan_direction (self, SCAN_DIRECTION_RIGHT_TO_LEFT); -#line 333 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - break; -#line 1064 "page.c" - } -#line 323 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - case SCAN_DIRECTION_RIGHT_TO_LEFT: -#line 1068 "page.c" - { -#line 335 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - page_set_scan_direction (self, SCAN_DIRECTION_TOP_TO_BOTTOM); -#line 336 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - break; -#line 1074 "page.c" - } - default: -#line 323 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - break; -#line 1079 "page.c" - } -} - - -void page_rotate_right (Page* self) { - ScanDirection _tmp0_ = 0; - ScanDirection _tmp1_ = 0; -#line 340 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - g_return_if_fail (self != NULL); -#line 342 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp0_ = page_get_scan_direction (self); -#line 342 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp1_ = _tmp0_; -#line 342 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - switch (_tmp1_) { -#line 342 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - case SCAN_DIRECTION_TOP_TO_BOTTOM: -#line 1097 "page.c" - { -#line 345 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - page_set_scan_direction (self, SCAN_DIRECTION_RIGHT_TO_LEFT); -#line 346 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - break; -#line 1103 "page.c" - } -#line 342 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - case SCAN_DIRECTION_LEFT_TO_RIGHT: -#line 1107 "page.c" - { -#line 348 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - page_set_scan_direction (self, SCAN_DIRECTION_TOP_TO_BOTTOM); -#line 349 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - break; -#line 1113 "page.c" - } -#line 342 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - case SCAN_DIRECTION_BOTTOM_TO_TOP: -#line 1117 "page.c" - { -#line 351 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - page_set_scan_direction (self, SCAN_DIRECTION_LEFT_TO_RIGHT); -#line 352 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - break; -#line 1123 "page.c" - } -#line 342 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - case SCAN_DIRECTION_RIGHT_TO_LEFT: -#line 1127 "page.c" - { -#line 354 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - page_set_scan_direction (self, SCAN_DIRECTION_BOTTOM_TO_TOP); -#line 355 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - break; -#line 1133 "page.c" - } - default: -#line 342 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - break; -#line 1138 "page.c" - } -} - - -void page_set_no_crop (Page* self) { - gboolean _tmp0_ = FALSE; -#line 359 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - g_return_if_fail (self != NULL); -#line 361 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp0_ = self->priv->_has_crop; -#line 361 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - if (!_tmp0_) { -#line 362 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - return; -#line 1153 "page.c" - } -#line 363 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - page_set_has_crop (self, FALSE); -#line 364 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - page_set_crop_name (self, NULL); -#line 365 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - page_set_crop_x (self, 0); -#line 366 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - page_set_crop_y (self, 0); -#line 367 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - page_set_crop_width (self, 0); -#line 368 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - page_set_crop_height (self, 0); -#line 369 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - g_signal_emit_by_name (self, "crop-changed"); -#line 1169 "page.c" -} - - -void page_set_custom_crop (Page* self, gint width, gint height) { - gint _tmp0_ = 0; - gint _tmp1_ = 0; - gboolean _tmp2_ = FALSE; - gboolean _tmp3_ = FALSE; - gboolean _tmp4_ = FALSE; - const gchar* _tmp5_ = NULL; - gint _tmp11_ = 0; - gint _tmp12_ = 0; -#line 372 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - g_return_if_fail (self != NULL); -#line 374 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp0_ = width; -#line 374 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - g_return_if_fail (_tmp0_ >= 1); -#line 375 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp1_ = height; -#line 375 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - g_return_if_fail (_tmp1_ >= 1); -#line 377 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp5_ = self->priv->_crop_name; -#line 377 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - if (_tmp5_ == NULL) { -#line 1196 "page.c" - gboolean _tmp6_ = FALSE; -#line 377 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp6_ = self->priv->_has_crop; -#line 377 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp4_ = _tmp6_; -#line 1202 "page.c" - } else { -#line 377 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp4_ = FALSE; -#line 1206 "page.c" - } -#line 377 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - if (_tmp4_) { -#line 1210 "page.c" - gint _tmp7_ = 0; - gint _tmp8_ = 0; -#line 377 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp7_ = self->priv->_crop_width; -#line 377 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp8_ = width; -#line 377 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp3_ = _tmp7_ == _tmp8_; -#line 1219 "page.c" - } else { -#line 377 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp3_ = FALSE; -#line 1223 "page.c" - } -#line 377 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - if (_tmp3_) { -#line 1227 "page.c" - gint _tmp9_ = 0; - gint _tmp10_ = 0; -#line 377 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp9_ = self->priv->_crop_height; -#line 377 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp10_ = height; -#line 377 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp2_ = _tmp9_ == _tmp10_; -#line 1236 "page.c" - } else { -#line 377 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp2_ = FALSE; -#line 1240 "page.c" - } -#line 377 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - if (_tmp2_) { -#line 378 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - return; -#line 1246 "page.c" - } -#line 379 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - page_set_crop_name (self, NULL); -#line 380 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - page_set_has_crop (self, TRUE); -#line 382 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp11_ = width; -#line 382 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - page_set_crop_width (self, _tmp11_); -#line 383 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp12_ = height; -#line 383 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - page_set_crop_height (self, _tmp12_); -#line 396 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - g_signal_emit_by_name (self, "crop-changed"); -#line 1262 "page.c" -} - - -void page_set_named_crop (Page* self, const gchar* name) { - gdouble w = 0.0; - gdouble h = 0.0; - const gchar* _tmp0_ = NULL; - const gchar* _tmp1_ = NULL; - GQuark _tmp3_ = 0U; -#line 402 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - static GQuark _tmp2_label0 = 0; -#line 402 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - static GQuark _tmp2_label1 = 0; -#line 402 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - static GQuark _tmp2_label2 = 0; -#line 402 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - static GQuark _tmp2_label3 = 0; -#line 402 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - static GQuark _tmp2_label4 = 0; -#line 402 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - static GQuark _tmp2_label5 = 0; -#line 1284 "page.c" - const gchar* _tmp5_ = NULL; - gint pw = 0; - gint _tmp6_ = 0; - gint _tmp7_ = 0; - gint ph = 0; - gint _tmp8_ = 0; - gint _tmp9_ = 0; - gint _tmp10_ = 0; - gint _tmp11_ = 0; - gdouble _tmp15_ = 0.0; - gint _tmp16_ = 0; - gdouble _tmp17_ = 0.0; - gint _tmp18_ = 0; - gint _tmp19_ = 0; - gint _tmp20_ = 0; - gint _tmp23_ = 0; - gint _tmp24_ = 0; -#line 399 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - g_return_if_fail (self != NULL); -#line 399 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - g_return_if_fail (name != NULL); -#line 402 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp0_ = name; -#line 402 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp1_ = _tmp0_; -#line 402 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp3_ = (NULL == _tmp1_) ? 0 : g_quark_from_string (_tmp1_); -#line 402 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - if (_tmp3_ == ((0 != _tmp2_label0) ? _tmp2_label0 : (_tmp2_label0 = g_quark_from_static_string ("A4")))) { -#line 402 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - switch (0) { -#line 1316 "page.c" - default: - { -#line 405 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - w = 8.3; -#line 406 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - h = 11.7; -#line 407 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - break; -#line 1325 "page.c" - } - } - } else if (_tmp3_ == ((0 != _tmp2_label1) ? _tmp2_label1 : (_tmp2_label1 = g_quark_from_static_string ("A5")))) { -#line 402 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - switch (0) { -#line 1331 "page.c" - default: - { -#line 409 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - w = 5.8; -#line 410 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - h = 8.3; -#line 411 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - break; -#line 1340 "page.c" - } - } - } else if (_tmp3_ == ((0 != _tmp2_label2) ? _tmp2_label2 : (_tmp2_label2 = g_quark_from_static_string ("A6")))) { -#line 402 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - switch (0) { -#line 1346 "page.c" - default: - { -#line 413 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - w = 4.1; -#line 414 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - h = 5.8; -#line 415 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - break; -#line 1355 "page.c" - } - } - } else if (_tmp3_ == ((0 != _tmp2_label3) ? _tmp2_label3 : (_tmp2_label3 = g_quark_from_static_string ("letter")))) { -#line 402 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - switch (0) { -#line 1361 "page.c" - default: - { -#line 417 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - w = 8.5; -#line 418 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - h = (gdouble) 11; -#line 419 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - break; -#line 1370 "page.c" - } - } - } else if (_tmp3_ == ((0 != _tmp2_label4) ? _tmp2_label4 : (_tmp2_label4 = g_quark_from_static_string ("legal")))) { -#line 402 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - switch (0) { -#line 1376 "page.c" - default: - { -#line 421 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - w = 8.5; -#line 422 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - h = (gdouble) 14; -#line 423 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - break; -#line 1385 "page.c" - } - } - } else if (_tmp3_ == ((0 != _tmp2_label5) ? _tmp2_label5 : (_tmp2_label5 = g_quark_from_static_string ("4x6")))) { -#line 402 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - switch (0) { -#line 1391 "page.c" - default: - { -#line 425 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - w = (gdouble) 4; -#line 426 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - h = (gdouble) 6; -#line 427 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - break; -#line 1400 "page.c" - } - } - } else { -#line 402 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - switch (0) { -#line 1406 "page.c" - default: - { - const gchar* _tmp4_ = NULL; -#line 429 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp4_ = name; -#line 429 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - g_warning ("page.vala:429: Unknown paper size '%s'", _tmp4_); -#line 430 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - return; -#line 1416 "page.c" - } - } - } -#line 433 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp5_ = name; -#line 433 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - page_set_crop_name (self, _tmp5_); -#line 434 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - page_set_has_crop (self, TRUE); -#line 436 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp6_ = page_get_width (self); -#line 436 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp7_ = _tmp6_; -#line 436 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - pw = _tmp7_; -#line 437 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp8_ = page_get_height (self); -#line 437 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp9_ = _tmp8_; -#line 437 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - ph = _tmp9_; -#line 440 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp10_ = pw; -#line 440 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp11_ = ph; -#line 440 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - if (_tmp10_ > _tmp11_) { -#line 1444 "page.c" - gdouble t = 0.0; - gdouble _tmp12_ = 0.0; - gdouble _tmp13_ = 0.0; - gdouble _tmp14_ = 0.0; -#line 442 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp12_ = w; -#line 442 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - t = _tmp12_; -#line 443 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp13_ = h; -#line 443 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - w = _tmp13_; -#line 444 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp14_ = t; -#line 444 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - h = _tmp14_; -#line 1461 "page.c" - } -#line 448 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp15_ = w; -#line 448 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp16_ = self->priv->_dpi; -#line 448 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - page_set_crop_width (self, (gint) ((_tmp15_ * _tmp16_) + 0.5)); -#line 449 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp17_ = h; -#line 449 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp18_ = self->priv->_dpi; -#line 449 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - page_set_crop_height (self, (gint) ((_tmp17_ * _tmp18_) + 0.5)); -#line 451 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp19_ = self->priv->_crop_width; -#line 451 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp20_ = pw; -#line 451 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - if (_tmp19_ < _tmp20_) { -#line 1481 "page.c" - gint _tmp21_ = 0; - gint _tmp22_ = 0; -#line 452 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp21_ = pw; -#line 452 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp22_ = self->priv->_crop_width; -#line 452 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - page_set_crop_x (self, (_tmp21_ - _tmp22_) / 2); -#line 1490 "page.c" - } else { -#line 454 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - page_set_crop_x (self, 0); -#line 1494 "page.c" - } -#line 455 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp23_ = self->priv->_crop_height; -#line 455 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp24_ = ph; -#line 455 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - if (_tmp23_ < _tmp24_) { -#line 1502 "page.c" - gint _tmp25_ = 0; - gint _tmp26_ = 0; -#line 456 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp25_ = ph; -#line 456 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp26_ = self->priv->_crop_height; -#line 456 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - page_set_crop_y (self, (_tmp25_ - _tmp26_) / 2); -#line 1511 "page.c" - } else { -#line 458 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - page_set_crop_y (self, 0); -#line 1515 "page.c" - } -#line 459 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - g_signal_emit_by_name (self, "crop-changed"); -#line 1519 "page.c" -} - - -void page_move_crop (Page* self, gint x, gint y) { - gint _tmp0_ = 0; - gint _tmp1_ = 0; - gint _tmp2_ = 0; - gint _tmp3_ = 0; - gint _tmp4_ = 0; - gint _tmp5_ = 0; - gint _tmp6_ = 0; - gint _tmp7_ = 0; - gint _tmp8_ = 0; - gint _tmp9_ = 0; -#line 462 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - g_return_if_fail (self != NULL); -#line 464 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp0_ = x; -#line 464 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - g_return_if_fail (_tmp0_ >= 0); -#line 465 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp1_ = y; -#line 465 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - g_return_if_fail (_tmp1_ >= 0); -#line 466 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp2_ = x; -#line 466 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp3_ = page_get_width (self); -#line 466 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp4_ = _tmp3_; -#line 466 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - g_return_if_fail (_tmp2_ < _tmp4_); -#line 467 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp5_ = y; -#line 467 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp6_ = page_get_height (self); -#line 467 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp7_ = _tmp6_; -#line 467 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - g_return_if_fail (_tmp5_ < _tmp7_); -#line 469 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp8_ = x; -#line 469 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - page_set_crop_x (self, _tmp8_); -#line 470 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp9_ = y; -#line 470 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - page_set_crop_y (self, _tmp9_); -#line 471 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - g_signal_emit_by_name (self, "crop-changed"); -#line 1570 "page.c" -} - - -void page_rotate_crop (Page* self) { - gboolean _tmp0_ = FALSE; - gint t = 0; - gint _tmp1_ = 0; - gint _tmp2_ = 0; - gint _tmp3_ = 0; - const gchar* _tmp4_ = NULL; -#line 474 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - g_return_if_fail (self != NULL); -#line 476 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp0_ = self->priv->_has_crop; -#line 476 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - if (!_tmp0_) { -#line 477 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - return; -#line 1589 "page.c" - } -#line 479 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp1_ = self->priv->_crop_width; -#line 479 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - t = _tmp1_; -#line 480 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp2_ = self->priv->_crop_height; -#line 480 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - page_set_crop_width (self, _tmp2_); -#line 481 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp3_ = t; -#line 481 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - page_set_crop_height (self, _tmp3_); -#line 484 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp4_ = self->priv->_crop_name; -#line 484 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - if (_tmp4_ == NULL) { -#line 1607 "page.c" - gint w = 0; - gint _tmp5_ = 0; - gint _tmp6_ = 0; - gint h = 0; - gint _tmp7_ = 0; - gint _tmp8_ = 0; - gint _tmp9_ = 0; - gint _tmp10_ = 0; - gint _tmp11_ = 0; - gint _tmp14_ = 0; - gint _tmp16_ = 0; - gint _tmp17_ = 0; - gint _tmp18_ = 0; - gint _tmp21_ = 0; -#line 486 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp5_ = page_get_width (self); -#line 486 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp6_ = _tmp5_; -#line 486 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - w = _tmp6_; -#line 487 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp7_ = page_get_height (self); -#line 487 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp8_ = _tmp7_; -#line 487 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - h = _tmp8_; -#line 489 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp9_ = self->priv->_crop_x; -#line 489 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp10_ = self->priv->_crop_width; -#line 489 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp11_ = w; -#line 489 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - if ((_tmp9_ + _tmp10_) > _tmp11_) { -#line 1642 "page.c" - gint _tmp12_ = 0; - gint _tmp13_ = 0; -#line 490 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp12_ = w; -#line 490 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp13_ = self->priv->_crop_width; -#line 490 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - page_set_crop_x (self, _tmp12_ - _tmp13_); -#line 1651 "page.c" - } -#line 491 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp14_ = self->priv->_crop_x; -#line 491 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - if (_tmp14_ < 0) { -#line 1657 "page.c" - gint _tmp15_ = 0; -#line 493 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - page_set_crop_x (self, 0); -#line 494 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp15_ = w; -#line 494 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - page_set_crop_width (self, _tmp15_); -#line 1665 "page.c" - } -#line 496 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp16_ = self->priv->_crop_y; -#line 496 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp17_ = self->priv->_crop_height; -#line 496 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp18_ = h; -#line 496 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - if ((_tmp16_ + _tmp17_) > _tmp18_) { -#line 1675 "page.c" - gint _tmp19_ = 0; - gint _tmp20_ = 0; -#line 497 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp19_ = h; -#line 497 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp20_ = self->priv->_crop_height; -#line 497 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - page_set_crop_y (self, _tmp19_ - _tmp20_); -#line 1684 "page.c" - } -#line 498 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp21_ = self->priv->_crop_y; -#line 498 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - if (_tmp21_ < 0) { -#line 1690 "page.c" - gint _tmp22_ = 0; -#line 500 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - page_set_crop_y (self, 0); -#line 501 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp22_ = h; -#line 501 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - page_set_crop_height (self, _tmp22_); -#line 1698 "page.c" - } - } -#line 505 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - g_signal_emit_by_name (self, "crop-changed"); -#line 1703 "page.c" -} - - -guchar* page_get_pixels (Page* self, int* result_length1) { - guchar* result = NULL; - guchar* _tmp0_ = NULL; - gint _tmp0__length1 = 0; - guchar* _tmp1_ = NULL; - gint _tmp1__length1 = 0; -#line 508 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - g_return_val_if_fail (self != NULL, NULL); -#line 510 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp0_ = self->priv->pixels; -#line 510 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp0__length1 = self->priv->pixels_length1; -#line 510 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp1_ = _tmp0_; -#line 510 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp1__length1 = _tmp0__length1; -#line 510 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - if (result_length1) { -#line 510 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - *result_length1 = _tmp1__length1; -#line 1727 "page.c" - } -#line 510 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - result = _tmp1_; -#line 510 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - return result; -#line 1733 "page.c" -} - - -static guchar page_get_sample (Page* self, guchar* pixels, int pixels_length1, gint offset, gint x, gint depth, gint n_channels, gint channel) { - guchar result = '\0'; -#line 514 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - g_return_val_if_fail (self != NULL, '\0'); -#line 517 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - result = (guchar) 0xFF; -#line 517 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - return result; -#line 1745 "page.c" -} - - -static void page_get_pixel (Page* self, gint x, gint y, guchar* pixel, int pixel_length1, gint offset) { - ScanDirection _tmp0_ = 0; - ScanDirection _tmp1_ = 0; - gint line_offset = 0; - gint _tmp14_ = 0; - gint _tmp15_ = 0; - gboolean _tmp16_ = FALSE; - gint _tmp17_ = 0; - guchar* _tmp98_ = NULL; - gint _tmp98__length1 = 0; - gint _tmp99_ = 0; - guchar* _tmp100_ = NULL; - gint _tmp100__length1 = 0; - gint _tmp101_ = 0; - gint _tmp102_ = 0; - gint _tmp103_ = 0; - gint _tmp104_ = 0; - guchar _tmp105_ = '\0'; - guchar _tmp106_ = '\0'; - guchar* _tmp107_ = NULL; - gint _tmp107__length1 = 0; - gint _tmp108_ = 0; - guchar* _tmp109_ = NULL; - gint _tmp109__length1 = 0; - gint _tmp110_ = 0; - gint _tmp111_ = 0; - gint _tmp112_ = 0; - gint _tmp113_ = 0; - guchar _tmp114_ = '\0'; - guchar _tmp115_ = '\0'; - guchar* _tmp116_ = NULL; - gint _tmp116__length1 = 0; - gint _tmp117_ = 0; - guchar* _tmp118_ = NULL; - gint _tmp118__length1 = 0; - gint _tmp119_ = 0; - gint _tmp120_ = 0; - gint _tmp121_ = 0; - gint _tmp122_ = 0; - guchar _tmp123_ = '\0'; - guchar _tmp124_ = '\0'; -#line 521 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - g_return_if_fail (self != NULL); -#line 523 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp0_ = page_get_scan_direction (self); -#line 523 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp1_ = _tmp0_; -#line 523 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - switch (_tmp1_) { -#line 523 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - case SCAN_DIRECTION_TOP_TO_BOTTOM: -#line 1800 "page.c" - { -#line 526 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - break; -#line 1804 "page.c" - } -#line 523 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - case SCAN_DIRECTION_BOTTOM_TO_TOP: -#line 1808 "page.c" - { - gint _tmp2_ = 0; - gint _tmp3_ = 0; - gint _tmp4_ = 0; - gint _tmp5_ = 0; -#line 528 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp2_ = self->priv->_scan_width; -#line 528 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp3_ = x; -#line 528 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - x = (_tmp2_ - _tmp3_) - 1; -#line 529 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp4_ = self->priv->_scan_height; -#line 529 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp5_ = y; -#line 529 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - y = (_tmp4_ - _tmp5_) - 1; -#line 530 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - break; -#line 1828 "page.c" - } -#line 523 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - case SCAN_DIRECTION_LEFT_TO_RIGHT: -#line 1832 "page.c" - { - gint t = 0; - gint _tmp6_ = 0; - gint _tmp7_ = 0; - gint _tmp8_ = 0; - gint _tmp9_ = 0; -#line 532 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp6_ = x; -#line 532 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - t = _tmp6_; -#line 533 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp7_ = self->priv->_scan_width; -#line 533 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp8_ = y; -#line 533 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - x = (_tmp7_ - _tmp8_) - 1; -#line 534 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp9_ = t; -#line 534 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - y = _tmp9_; -#line 535 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - break; -#line 1855 "page.c" - } -#line 523 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - case SCAN_DIRECTION_RIGHT_TO_LEFT: -#line 1859 "page.c" - { - gint t = 0; - gint _tmp10_ = 0; - gint _tmp11_ = 0; - gint _tmp12_ = 0; - gint _tmp13_ = 0; -#line 537 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp10_ = x; -#line 537 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - t = _tmp10_; -#line 538 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp11_ = y; -#line 538 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - x = _tmp11_; -#line 539 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp12_ = self->priv->_scan_height; -#line 539 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp13_ = t; -#line 539 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - y = (_tmp12_ - _tmp13_) - 1; -#line 540 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - break; -#line 1882 "page.c" - } - default: -#line 523 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - break; -#line 1887 "page.c" - } -#line 543 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp14_ = self->priv->_rowstride; -#line 543 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp15_ = y; -#line 543 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - line_offset = _tmp14_ * _tmp15_; -#line 546 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp17_ = self->priv->_depth; -#line 546 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - if (_tmp17_ == 8) { -#line 1899 "page.c" - gint _tmp18_ = 0; -#line 546 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp18_ = self->priv->_n_channels; -#line 546 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp16_ = _tmp18_ == 3; -#line 1905 "page.c" - } else { -#line 546 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp16_ = FALSE; -#line 1909 "page.c" - } -#line 546 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - if (_tmp16_) { -#line 1913 "page.c" - gint o = 0; - gint _tmp19_ = 0; - gint _tmp20_ = 0; - gint _tmp21_ = 0; - guchar* _tmp22_ = NULL; - gint _tmp22__length1 = 0; - gint _tmp23_ = 0; - guchar* _tmp24_ = NULL; - gint _tmp24__length1 = 0; - gint _tmp25_ = 0; - guchar _tmp26_ = '\0'; - guchar _tmp27_ = '\0'; - guchar* _tmp28_ = NULL; - gint _tmp28__length1 = 0; - gint _tmp29_ = 0; - guchar* _tmp30_ = NULL; - gint _tmp30__length1 = 0; - gint _tmp31_ = 0; - guchar _tmp32_ = '\0'; - guchar _tmp33_ = '\0'; - guchar* _tmp34_ = NULL; - gint _tmp34__length1 = 0; - gint _tmp35_ = 0; - guchar* _tmp36_ = NULL; - gint _tmp36__length1 = 0; - gint _tmp37_ = 0; - guchar _tmp38_ = '\0'; - guchar _tmp39_ = '\0'; -#line 548 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp19_ = line_offset; -#line 548 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp20_ = x; -#line 548 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp21_ = self->priv->_n_channels; -#line 548 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - o = _tmp19_ + (_tmp20_ * _tmp21_); -#line 549 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp22_ = pixel; -#line 549 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp22__length1 = pixel_length1; -#line 549 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp23_ = offset; -#line 549 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp24_ = self->priv->pixels; -#line 549 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp24__length1 = self->priv->pixels_length1; -#line 549 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp25_ = o; -#line 549 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp26_ = _tmp24_[_tmp25_]; -#line 549 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp22_[_tmp23_ + 0] = _tmp26_; -#line 549 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp27_ = _tmp22_[_tmp23_ + 0]; -#line 550 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp28_ = pixel; -#line 550 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp28__length1 = pixel_length1; -#line 550 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp29_ = offset; -#line 550 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp30_ = self->priv->pixels; -#line 550 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp30__length1 = self->priv->pixels_length1; -#line 550 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp31_ = o; -#line 550 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp32_ = _tmp30_[_tmp31_ + 1]; -#line 550 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp28_[_tmp29_ + 1] = _tmp32_; -#line 550 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp33_ = _tmp28_[_tmp29_ + 1]; -#line 551 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp34_ = pixel; -#line 551 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp34__length1 = pixel_length1; -#line 551 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp35_ = offset; -#line 551 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp36_ = self->priv->pixels; -#line 551 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp36__length1 = self->priv->pixels_length1; -#line 551 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp37_ = o; -#line 551 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp38_ = _tmp36_[_tmp37_ + 2]; -#line 551 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp34_[_tmp35_ + 2] = _tmp38_; -#line 551 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp39_ = _tmp34_[_tmp35_ + 2]; -#line 552 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - return; -#line 2006 "page.c" - } else { - gboolean _tmp40_ = FALSE; - gint _tmp41_ = 0; -#line 554 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp41_ = self->priv->_depth; -#line 554 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - if (_tmp41_ == 8) { -#line 2014 "page.c" - gint _tmp42_ = 0; -#line 554 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp42_ = self->priv->_n_channels; -#line 554 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp40_ = _tmp42_ == 1; -#line 2020 "page.c" - } else { -#line 554 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp40_ = FALSE; -#line 2024 "page.c" - } -#line 554 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - if (_tmp40_) { -#line 2028 "page.c" - guchar p = '\0'; - guchar* _tmp43_ = NULL; - gint _tmp43__length1 = 0; - gint _tmp44_ = 0; - gint _tmp45_ = 0; - guchar _tmp46_ = '\0'; - guchar* _tmp47_ = NULL; - gint _tmp47__length1 = 0; - gint _tmp48_ = 0; - guchar* _tmp49_ = NULL; - gint _tmp49__length1 = 0; - gint _tmp50_ = 0; - guchar* _tmp51_ = NULL; - gint _tmp51__length1 = 0; - gint _tmp52_ = 0; - guchar _tmp53_ = '\0'; - guchar _tmp54_ = '\0'; - guchar _tmp55_ = '\0'; - guchar _tmp56_ = '\0'; -#line 556 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp43_ = self->priv->pixels; -#line 556 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp43__length1 = self->priv->pixels_length1; -#line 556 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp44_ = line_offset; -#line 556 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp45_ = x; -#line 556 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp46_ = _tmp43_[_tmp44_ + _tmp45_]; -#line 556 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - p = _tmp46_; -#line 557 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp47_ = pixel; -#line 557 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp47__length1 = pixel_length1; -#line 557 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp48_ = offset; -#line 557 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp49_ = pixel; -#line 557 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp49__length1 = pixel_length1; -#line 557 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp50_ = offset; -#line 557 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp51_ = pixel; -#line 557 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp51__length1 = pixel_length1; -#line 557 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp52_ = offset; -#line 557 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp53_ = p; -#line 557 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp51_[_tmp52_ + 2] = _tmp53_; -#line 557 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp54_ = _tmp51_[_tmp52_ + 2]; -#line 557 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp49_[_tmp50_ + 1] = _tmp54_; -#line 557 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp55_ = _tmp49_[_tmp50_ + 1]; -#line 557 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp47_[_tmp48_ + 0] = _tmp55_; -#line 557 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp56_ = _tmp47_[_tmp48_ + 0]; -#line 558 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - return; -#line 2094 "page.c" - } else { - gboolean _tmp57_ = FALSE; - gint _tmp58_ = 0; -#line 562 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp58_ = self->priv->_depth; -#line 562 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - if (_tmp58_ == 1) { -#line 2102 "page.c" - gint _tmp59_ = 0; -#line 562 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp59_ = self->priv->_n_channels; -#line 562 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp57_ = _tmp59_ == 1; -#line 2108 "page.c" - } else { -#line 562 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp57_ = FALSE; -#line 2112 "page.c" - } -#line 562 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - if (_tmp57_) { -#line 2116 "page.c" - guchar p = '\0'; - guchar* _tmp60_ = NULL; - gint _tmp60__length1 = 0; - gint _tmp61_ = 0; - gint _tmp62_ = 0; - guchar _tmp63_ = '\0'; - gint _tmp64_ = 0; - guchar _tmp65_ = '\0'; - gint _tmp66_ = 0; - guchar* _tmp67_ = NULL; - gint _tmp67__length1 = 0; - gint _tmp68_ = 0; - guchar* _tmp69_ = NULL; - gint _tmp69__length1 = 0; - gint _tmp70_ = 0; - guchar* _tmp71_ = NULL; - gint _tmp71__length1 = 0; - gint _tmp72_ = 0; - guchar _tmp73_ = '\0'; - guchar _tmp74_ = '\0'; - guchar _tmp75_ = '\0'; -#line 564 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp60_ = self->priv->pixels; -#line 564 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp60__length1 = self->priv->pixels_length1; -#line 564 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp61_ = line_offset; -#line 564 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp62_ = x; -#line 564 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp63_ = _tmp60_[_tmp61_ + (_tmp62_ / 8)]; -#line 564 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - p = _tmp63_; -#line 565 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp65_ = p; -#line 565 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp66_ = x; -#line 565 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - if (((gint) (_tmp65_ & (0x80 >> (_tmp66_ % 8)))) != 0) { -#line 565 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp64_ = 0x00; -#line 2158 "page.c" - } else { -#line 565 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp64_ = 0xFF; -#line 2162 "page.c" - } -#line 565 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp67_ = pixel; -#line 565 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp67__length1 = pixel_length1; -#line 565 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp68_ = offset; -#line 565 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp69_ = pixel; -#line 565 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp69__length1 = pixel_length1; -#line 565 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp70_ = offset; -#line 565 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp71_ = pixel; -#line 565 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp71__length1 = pixel_length1; -#line 565 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp72_ = offset; -#line 565 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp71_[_tmp72_ + 2] = (guchar) _tmp64_; -#line 565 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp73_ = _tmp71_[_tmp72_ + 2]; -#line 565 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp69_[_tmp70_ + 1] = _tmp73_; -#line 565 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp74_ = _tmp69_[_tmp70_ + 1]; -#line 565 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp67_[_tmp68_ + 0] = _tmp74_; -#line 565 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp75_ = _tmp67_[_tmp68_ + 0]; -#line 566 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - return; -#line 2196 "page.c" - } else { - gboolean _tmp76_ = FALSE; - gint _tmp77_ = 0; -#line 570 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp77_ = self->priv->_depth; -#line 570 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - if (_tmp77_ == 2) { -#line 2204 "page.c" - gint _tmp78_ = 0; -#line 570 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp78_ = self->priv->_n_channels; -#line 570 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp76_ = _tmp78_ == 1; -#line 2210 "page.c" - } else { -#line 570 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp76_ = FALSE; -#line 2214 "page.c" - } -#line 570 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - if (_tmp76_) { -#line 2218 "page.c" - gint block_shift[4] = {0}; - gint _tmp79_[4] = {0}; - guchar p = '\0'; - guchar* _tmp80_ = NULL; - gint _tmp80__length1 = 0; - gint _tmp81_ = 0; - gint _tmp82_ = 0; - guchar _tmp83_ = '\0'; - gint sample = 0; - guchar _tmp84_ = '\0'; - gint _tmp85_ = 0; - gint _tmp86_ = 0; - gint _tmp87_ = 0; - guchar* _tmp88_ = NULL; - gint _tmp88__length1 = 0; - gint _tmp89_ = 0; - guchar* _tmp90_ = NULL; - gint _tmp90__length1 = 0; - gint _tmp91_ = 0; - guchar* _tmp92_ = NULL; - gint _tmp92__length1 = 0; - gint _tmp93_ = 0; - gint _tmp94_ = 0; - guchar _tmp95_ = '\0'; - guchar _tmp96_ = '\0'; - guchar _tmp97_ = '\0'; -#line 572 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp79_[0] = 6; -#line 572 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp79_[1] = 4; -#line 572 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp79_[2] = 2; -#line 572 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp79_[3] = 0; -#line 572 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - memcpy (block_shift, _tmp79_, 4 * sizeof (gint)); -#line 574 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp80_ = self->priv->pixels; -#line 574 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp80__length1 = self->priv->pixels_length1; -#line 574 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp81_ = line_offset; -#line 574 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp82_ = x; -#line 574 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp83_ = _tmp80_[_tmp81_ + (_tmp82_ / 4)]; -#line 574 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - p = _tmp83_; -#line 575 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp84_ = p; -#line 575 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp85_ = x; -#line 575 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp86_ = block_shift[_tmp85_ % 4]; -#line 575 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - sample = (_tmp84_ >> _tmp86_) & 0x3; -#line 576 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp87_ = sample; -#line 576 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - sample = (_tmp87_ * 255) / 3; -#line 578 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp88_ = pixel; -#line 578 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp88__length1 = pixel_length1; -#line 578 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp89_ = offset; -#line 578 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp90_ = pixel; -#line 578 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp90__length1 = pixel_length1; -#line 578 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp91_ = offset; -#line 578 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp92_ = pixel; -#line 578 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp92__length1 = pixel_length1; -#line 578 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp93_ = offset; -#line 578 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp94_ = sample; -#line 578 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp92_[_tmp93_ + 2] = (guchar) _tmp94_; -#line 578 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp95_ = _tmp92_[_tmp93_ + 2]; -#line 578 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp90_[_tmp91_ + 1] = _tmp95_; -#line 578 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp96_ = _tmp90_[_tmp91_ + 1]; -#line 578 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp88_[_tmp89_ + 0] = _tmp96_; -#line 578 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp97_ = _tmp88_[_tmp89_ + 0]; -#line 579 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - return; -#line 2313 "page.c" - } - } - } - } -#line 583 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp98_ = pixel; -#line 583 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp98__length1 = pixel_length1; -#line 583 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp99_ = offset; -#line 583 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp100_ = self->priv->pixels; -#line 583 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp100__length1 = self->priv->pixels_length1; -#line 583 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp101_ = line_offset; -#line 583 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp102_ = x; -#line 583 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp103_ = self->priv->_depth; -#line 583 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp104_ = self->priv->_n_channels; -#line 583 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp105_ = page_get_sample (self, _tmp100_, _tmp100__length1, _tmp101_, _tmp102_, _tmp103_, _tmp104_, 0); -#line 583 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp98_[_tmp99_ + 0] = _tmp105_; -#line 583 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp106_ = _tmp98_[_tmp99_ + 0]; -#line 584 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp107_ = pixel; -#line 584 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp107__length1 = pixel_length1; -#line 584 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp108_ = offset; -#line 584 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp109_ = self->priv->pixels; -#line 584 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp109__length1 = self->priv->pixels_length1; -#line 584 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp110_ = line_offset; -#line 584 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp111_ = x; -#line 584 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp112_ = self->priv->_depth; -#line 584 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp113_ = self->priv->_n_channels; -#line 584 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp114_ = page_get_sample (self, _tmp109_, _tmp109__length1, _tmp110_, _tmp111_, _tmp112_, _tmp113_, 1); -#line 584 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp107_[_tmp108_ + 1] = _tmp114_; -#line 584 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp115_ = _tmp107_[_tmp108_ + 1]; -#line 585 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp116_ = pixel; -#line 585 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp116__length1 = pixel_length1; -#line 585 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp117_ = offset; -#line 585 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp118_ = self->priv->pixels; -#line 585 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp118__length1 = self->priv->pixels_length1; -#line 585 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp119_ = line_offset; -#line 585 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp120_ = x; -#line 585 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp121_ = self->priv->_depth; -#line 585 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp122_ = self->priv->_n_channels; -#line 585 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp123_ = page_get_sample (self, _tmp118_, _tmp118__length1, _tmp119_, _tmp120_, _tmp121_, _tmp122_, 2); -#line 585 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp116_[_tmp117_ + 2] = _tmp123_; -#line 585 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp124_ = _tmp116_[_tmp117_ + 2]; -#line 2390 "page.c" -} - - -GdkPixbuf* page_get_image (Page* self, gboolean apply_crop) { - GdkPixbuf* result = NULL; - gint l = 0; - gint r = 0; - gint t = 0; - gint b = 0; - gboolean _tmp0_ = FALSE; - gboolean _tmp1_ = FALSE; - GdkPixbuf* image = NULL; - gint _tmp25_ = 0; - gint _tmp26_ = 0; - gint _tmp27_ = 0; - gint _tmp28_ = 0; - GdkPixbuf* _tmp29_ = NULL; - guint8* image_pixels = NULL; - GdkPixbuf* _tmp30_ = NULL; - guint8* _tmp31_ = NULL; - gint image_pixels_length1 = 0; - gint _image_pixels_size_ = 0; -#line 588 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - g_return_val_if_fail (self != NULL, NULL); -#line 591 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp1_ = apply_crop; -#line 591 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - if (_tmp1_) { -#line 2419 "page.c" - gboolean _tmp2_ = FALSE; -#line 591 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp2_ = self->priv->_has_crop; -#line 591 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp0_ = _tmp2_; -#line 2425 "page.c" - } else { -#line 591 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp0_ = FALSE; -#line 2429 "page.c" - } -#line 591 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - if (_tmp0_) { -#line 2433 "page.c" - gint _tmp3_ = 0; - gint _tmp4_ = 0; - gint _tmp5_ = 0; - gint _tmp6_ = 0; - gint _tmp7_ = 0; - gint _tmp8_ = 0; - gint _tmp9_ = 0; - gint _tmp10_ = 0; - gint _tmp11_ = 0; - gint _tmp12_ = 0; - gint _tmp15_ = 0; - gint _tmp16_ = 0; - gint _tmp17_ = 0; - gint _tmp18_ = 0; -#line 593 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp3_ = self->priv->_crop_x; -#line 593 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - l = _tmp3_; -#line 594 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp4_ = l; -#line 594 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp5_ = self->priv->_crop_width; -#line 594 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - r = _tmp4_ + _tmp5_; -#line 595 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp6_ = self->priv->_crop_y; -#line 595 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - t = _tmp6_; -#line 596 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp7_ = t; -#line 596 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp8_ = self->priv->_crop_height; -#line 596 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - b = _tmp7_ + _tmp8_; -#line 598 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp9_ = l; -#line 598 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - if (_tmp9_ < 0) { -#line 599 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - l = 0; -#line 2474 "page.c" - } -#line 600 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp10_ = r; -#line 600 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp11_ = page_get_width (self); -#line 600 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp12_ = _tmp11_; -#line 600 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - if (_tmp10_ > _tmp12_) { -#line 2484 "page.c" - gint _tmp13_ = 0; - gint _tmp14_ = 0; -#line 601 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp13_ = page_get_width (self); -#line 601 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp14_ = _tmp13_; -#line 601 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - r = _tmp14_; -#line 2493 "page.c" - } -#line 602 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp15_ = t; -#line 602 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - if (_tmp15_ < 0) { -#line 603 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - t = 0; -#line 2501 "page.c" - } -#line 604 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp16_ = b; -#line 604 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp17_ = page_get_height (self); -#line 604 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp18_ = _tmp17_; -#line 604 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - if (_tmp16_ > _tmp18_) { -#line 2511 "page.c" - gint _tmp19_ = 0; - gint _tmp20_ = 0; -#line 605 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp19_ = page_get_height (self); -#line 605 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp20_ = _tmp19_; -#line 605 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - b = _tmp20_; -#line 2520 "page.c" - } - } else { - gint _tmp21_ = 0; - gint _tmp22_ = 0; - gint _tmp23_ = 0; - gint _tmp24_ = 0; -#line 609 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - l = 0; -#line 610 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp21_ = page_get_width (self); -#line 610 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp22_ = _tmp21_; -#line 610 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - r = _tmp22_; -#line 611 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - t = 0; -#line 612 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp23_ = page_get_height (self); -#line 612 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp24_ = _tmp23_; -#line 612 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - b = _tmp24_; -#line 2543 "page.c" - } -#line 615 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp25_ = r; -#line 615 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp26_ = l; -#line 615 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp27_ = b; -#line 615 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp28_ = t; -#line 615 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp29_ = gdk_pixbuf_new (GDK_COLORSPACE_RGB, FALSE, 8, _tmp25_ - _tmp26_, _tmp27_ - _tmp28_); -#line 615 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - image = _tmp29_; -#line 616 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp30_ = image; -#line 616 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp31_ = gdk_pixbuf_get_pixels (_tmp30_); -#line 616 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - image_pixels = _tmp31_; -#line 616 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - image_pixels_length1 = -1; -#line 616 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _image_pixels_size_ = image_pixels_length1; -#line 2567 "page.c" - { - gint y = 0; - gint _tmp32_ = 0; -#line 617 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp32_ = t; -#line 617 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - y = _tmp32_; -#line 2575 "page.c" - { - gboolean _tmp33_ = FALSE; -#line 617 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp33_ = TRUE; -#line 617 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - while (TRUE) { -#line 2582 "page.c" - gint _tmp35_ = 0; - gint _tmp36_ = 0; - gint offset = 0; - GdkPixbuf* _tmp37_ = NULL; - gint _tmp38_ = 0; - gint _tmp39_ = 0; - gint _tmp40_ = 0; -#line 617 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - if (!_tmp33_) { -#line 2592 "page.c" - gint _tmp34_ = 0; -#line 617 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp34_ = y; -#line 617 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - y = _tmp34_ + 1; -#line 2598 "page.c" - } -#line 617 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp33_ = FALSE; -#line 617 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp35_ = y; -#line 617 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp36_ = b; -#line 617 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - if (!(_tmp35_ < _tmp36_)) { -#line 617 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - break; -#line 2610 "page.c" - } -#line 619 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp37_ = image; -#line 619 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp38_ = gdk_pixbuf_get_rowstride (_tmp37_); -#line 619 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp39_ = y; -#line 619 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp40_ = t; -#line 619 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - offset = _tmp38_ * (_tmp39_ - _tmp40_); -#line 2622 "page.c" - { - gint x = 0; - gint _tmp41_ = 0; -#line 620 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp41_ = l; -#line 620 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - x = _tmp41_; -#line 2630 "page.c" - { - gboolean _tmp42_ = FALSE; -#line 620 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp42_ = TRUE; -#line 620 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - while (TRUE) { -#line 2637 "page.c" - gint _tmp44_ = 0; - gint _tmp45_ = 0; - gint _tmp46_ = 0; - gint _tmp47_ = 0; - guint8* _tmp48_ = NULL; - gint _tmp48__length1 = 0; - gint _tmp49_ = 0; - gint _tmp50_ = 0; - gint _tmp51_ = 0; -#line 620 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - if (!_tmp42_) { -#line 2649 "page.c" - gint _tmp43_ = 0; -#line 620 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp43_ = x; -#line 620 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - x = _tmp43_ + 1; -#line 2655 "page.c" - } -#line 620 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp42_ = FALSE; -#line 620 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp44_ = x; -#line 620 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp45_ = r; -#line 620 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - if (!(_tmp44_ < _tmp45_)) { -#line 620 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - break; -#line 2667 "page.c" - } -#line 621 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp46_ = x; -#line 621 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp47_ = y; -#line 621 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp48_ = image_pixels; -#line 621 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp48__length1 = image_pixels_length1; -#line 621 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp49_ = offset; -#line 621 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp50_ = x; -#line 621 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp51_ = l; -#line 621 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - page_get_pixel (self, _tmp46_, _tmp47_, _tmp48_, _tmp48__length1, _tmp49_ + ((_tmp50_ - _tmp51_) * 3)); -#line 2685 "page.c" - } - } - } - } - } - } -#line 624 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - result = image; -#line 624 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - return result; -#line 2696 "page.c" -} - - -static gchar* string_to_utf8 (const gchar* self, int* result_length1) { - gchar* result = NULL; - gchar* _result_ = NULL; - gint _tmp0_ = 0; - gint _tmp1_ = 0; - gchar* _tmp2_ = NULL; - gint _result__length1 = 0; - gint __result__size_ = 0; - gint _tmp3_ = 0; - gchar* _tmp4_ = NULL; - gint _tmp4__length1 = 0; - gint _tmp5_ = 0; - gint _tmp6_ = 0; - gchar* _tmp7_ = NULL; - gint _tmp7__length1 = 0; -#line 1405 "/usr/share/vala-0.34/vapi/glib-2.0.vapi" - g_return_val_if_fail (self != NULL, NULL); -#line 1406 "/usr/share/vala-0.34/vapi/glib-2.0.vapi" - _tmp0_ = strlen (self); -#line 1406 "/usr/share/vala-0.34/vapi/glib-2.0.vapi" - _tmp1_ = _tmp0_; -#line 1406 "/usr/share/vala-0.34/vapi/glib-2.0.vapi" - _tmp2_ = g_new0 (gchar, _tmp1_ + 1); -#line 1406 "/usr/share/vala-0.34/vapi/glib-2.0.vapi" - _result_ = _tmp2_; -#line 1406 "/usr/share/vala-0.34/vapi/glib-2.0.vapi" - _result__length1 = _tmp1_ + 1; -#line 1406 "/usr/share/vala-0.34/vapi/glib-2.0.vapi" - __result__size_ = _result__length1; -#line 1407 "/usr/share/vala-0.34/vapi/glib-2.0.vapi" - _tmp3_ = _result__length1; -#line 1407 "/usr/share/vala-0.34/vapi/glib-2.0.vapi" - _result__length1 = _tmp3_ - 1; -#line 1408 "/usr/share/vala-0.34/vapi/glib-2.0.vapi" - _tmp4_ = _result_; -#line 1408 "/usr/share/vala-0.34/vapi/glib-2.0.vapi" - _tmp4__length1 = _result__length1; -#line 1408 "/usr/share/vala-0.34/vapi/glib-2.0.vapi" - _tmp5_ = strlen (self); -#line 1408 "/usr/share/vala-0.34/vapi/glib-2.0.vapi" - _tmp6_ = _tmp5_; -#line 1408 "/usr/share/vala-0.34/vapi/glib-2.0.vapi" - memcpy (_tmp4_, self, (gsize) _tmp6_); -#line 1409 "/usr/share/vala-0.34/vapi/glib-2.0.vapi" - _tmp7_ = _result_; -#line 1409 "/usr/share/vala-0.34/vapi/glib-2.0.vapi" - _tmp7__length1 = _result__length1; -#line 1409 "/usr/share/vala-0.34/vapi/glib-2.0.vapi" - if (result_length1) { -#line 1409 "/usr/share/vala-0.34/vapi/glib-2.0.vapi" - *result_length1 = _tmp7__length1; -#line 2751 "page.c" - } -#line 1409 "/usr/share/vala-0.34/vapi/glib-2.0.vapi" - result = _tmp7_; -#line 1409 "/usr/share/vala-0.34/vapi/glib-2.0.vapi" - return result; -#line 2757 "page.c" -} - - -static gchar* page_get_icc_data_encoded (Page* self, const gchar* icc_profile_filename) { - gchar* result = NULL; - gchar* contents = NULL; - const gchar* _tmp4_ = NULL; - gint _tmp5_ = 0; - gchar* _tmp6_ = NULL; - guchar* _tmp7_ = NULL; - gint _tmp7__length1 = 0; - gchar* _tmp8_ = NULL; - gchar* _tmp9_ = NULL; - GError * _inner_error_ = NULL; -#line 627 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - g_return_val_if_fail (self != NULL, NULL); -#line 627 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - g_return_val_if_fail (icc_profile_filename != NULL, NULL); -#line 2776 "page.c" - { - const gchar* _tmp0_ = NULL; - gchar* _tmp1_ = NULL; -#line 633 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp0_ = icc_profile_filename; -#line 633 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - g_file_get_contents (_tmp0_, &_tmp1_, NULL, &_inner_error_); -#line 633 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _g_free0 (contents); -#line 633 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - contents = _tmp1_; -#line 633 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - if (G_UNLIKELY (_inner_error_ != NULL)) { -#line 2790 "page.c" - goto __catch3_g_error; - } - } - goto __finally3; - __catch3_g_error: - { - GError* e = NULL; - GError* _tmp2_ = NULL; - const gchar* _tmp3_ = NULL; -#line 631 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - e = _inner_error_; -#line 631 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _inner_error_ = NULL; -#line 637 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp2_ = e; -#line 637 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp3_ = _tmp2_->message; -#line 637 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - g_warning ("page.vala:637: failed to get icc profile data: %s", _tmp3_); -#line 638 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - result = NULL; -#line 638 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _g_error_free0 (e); -#line 638 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _g_free0 (contents); -#line 638 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - return result; -#line 2818 "page.c" - } - __finally3: -#line 631 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - if (G_UNLIKELY (_inner_error_ != NULL)) { -#line 631 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _g_free0 (contents); -#line 631 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - g_critical ("file %s: line %d: uncaught error: %s (%s, %d)", __FILE__, __LINE__, _inner_error_->message, g_quark_to_string (_inner_error_->domain), _inner_error_->code); -#line 631 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - g_clear_error (&_inner_error_); -#line 631 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - return NULL; -#line 2831 "page.c" - } -#line 642 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp4_ = contents; -#line 642 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp6_ = string_to_utf8 (_tmp4_, &_tmp5_); -#line 642 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp7_ = (guchar*) _tmp6_; -#line 642 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp7__length1 = (_tmp5_ * sizeof (gchar)) / sizeof (guchar); -#line 642 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp8_ = g_base64_encode (_tmp7_, (_tmp5_ * sizeof (gchar)) / sizeof (guchar)); -#line 642 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp9_ = _tmp8_; -#line 642 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp7_ = (g_free (_tmp7_), NULL); -#line 642 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - result = _tmp9_; -#line 642 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _g_free0 (contents); -#line 642 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - return result; -#line 2853 "page.c" -} - - -static gpointer _g_object_ref0 (gpointer self) { -#line 647 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - return self ? g_object_ref (self) : NULL; -#line 2860 "page.c" -} - - -void page_copy_to_clipboard (Page* self, GtkWindow* window) { - GdkDisplay* display = NULL; - GtkWindow* _tmp0_ = NULL; - GdkDisplay* _tmp1_ = NULL; - GdkDisplay* _tmp2_ = NULL; - GtkClipboard* clipboard = NULL; - GtkClipboard* _tmp3_ = NULL; - GtkClipboard* _tmp4_ = NULL; - GdkPixbuf* image = NULL; - GdkPixbuf* _tmp5_ = NULL; -#line 645 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - g_return_if_fail (self != NULL); -#line 645 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - g_return_if_fail (window != NULL); -#line 647 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp0_ = window; -#line 647 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp1_ = gtk_widget_get_display ((GtkWidget*) _tmp0_); -#line 647 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp2_ = _g_object_ref0 (_tmp1_); -#line 647 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - display = _tmp2_; -#line 648 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp3_ = gtk_clipboard_get_for_display (display, GDK_SELECTION_CLIPBOARD); -#line 648 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp4_ = _g_object_ref0 (_tmp3_); -#line 648 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - clipboard = _tmp4_; -#line 649 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp5_ = page_get_image (self, TRUE); -#line 649 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - image = _tmp5_; -#line 650 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - gtk_clipboard_set_image (clipboard, image); -#line 645 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _g_object_unref0 (image); -#line 645 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _g_object_unref0 (clipboard); -#line 645 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _g_object_unref0 (display); -#line 2904 "page.c" -} - - -void page_save (Page* self, const gchar* type, gint quality, GFile* file, GError** error) { - GFileOutputStream* stream = NULL; - GFile* _tmp0_ = NULL; - GFileOutputStream* _tmp1_ = NULL; - PixbufWriter* writer = NULL; - GFileOutputStream* _tmp2_ = NULL; - PixbufWriter* _tmp3_ = NULL; - GdkPixbuf* image = NULL; - GdkPixbuf* _tmp4_ = NULL; - gchar* icc_profile_data = NULL; - const gchar* _tmp5_ = NULL; - GCompareFunc _tmp8_ = NULL; - const gchar* _tmp9_ = NULL; - gint _tmp10_ = 0; - GError * _inner_error_ = NULL; -#line 653 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - g_return_if_fail (self != NULL); -#line 653 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - g_return_if_fail (type != NULL); -#line 653 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - g_return_if_fail (file != NULL); -#line 655 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp0_ = file; -#line 655 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp1_ = g_file_replace (_tmp0_, NULL, FALSE, G_FILE_CREATE_NONE, NULL, &_inner_error_); -#line 655 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - stream = _tmp1_; -#line 655 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - if (G_UNLIKELY (_inner_error_ != NULL)) { -#line 655 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - g_propagate_error (error, _inner_error_); -#line 655 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - return; -#line 2941 "page.c" - } -#line 656 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp2_ = stream; -#line 656 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp3_ = pixbuf_writer_new (_tmp2_); -#line 656 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - writer = _tmp3_; -#line 657 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp4_ = page_get_image (self, TRUE); -#line 657 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - image = _tmp4_; -#line 659 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - icc_profile_data = NULL; -#line 660 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp5_ = self->priv->_color_profile; -#line 660 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - if (_tmp5_ != NULL) { -#line 2959 "page.c" - const gchar* _tmp6_ = NULL; - gchar* _tmp7_ = NULL; -#line 661 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp6_ = self->priv->_color_profile; -#line 661 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp7_ = page_get_icc_data_encoded (self, _tmp6_); -#line 661 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _g_free0 (icc_profile_data); -#line 661 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - icc_profile_data = _tmp7_; -#line 2970 "page.c" - } -#line 663 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp8_ = g_strcmp0; -#line 663 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp9_ = type; -#line 663 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp10_ = _tmp8_ (_tmp9_, "jpeg"); -#line 663 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - if (_tmp10_ == 0) { -#line 2980 "page.c" - gchar** keys = NULL; - gchar* _tmp11_ = NULL; - gchar* _tmp12_ = NULL; - gchar* _tmp13_ = NULL; - gchar* _tmp14_ = NULL; - gchar** _tmp15_ = NULL; - gint keys_length1 = 0; - gint _keys_size_ = 0; - gchar** values = NULL; - gint _tmp16_ = 0; - gchar* _tmp17_ = NULL; - gint _tmp18_ = 0; - gchar* _tmp19_ = NULL; - gint _tmp20_ = 0; - gchar* _tmp21_ = NULL; - const gchar* _tmp22_ = NULL; - gchar* _tmp23_ = NULL; - gchar** _tmp24_ = NULL; - gint values_length1 = 0; - gint _values_size_ = 0; - const gchar* _tmp25_ = NULL; - PixbufWriter* _tmp28_ = NULL; - GdkPixbuf* _tmp29_ = NULL; - gchar** _tmp30_ = NULL; - gint _tmp30__length1 = 0; - gchar** _tmp31_ = NULL; - gint _tmp31__length1 = 0; -#line 665 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp11_ = g_strdup ("x-dpi"); -#line 665 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp12_ = g_strdup ("y-dpi"); -#line 665 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp13_ = g_strdup ("quality"); -#line 665 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp14_ = g_strdup ("icc-profile"); -#line 665 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp15_ = g_new0 (gchar*, 5 + 1); -#line 665 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp15_[0] = _tmp11_; -#line 665 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp15_[1] = _tmp12_; -#line 665 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp15_[2] = _tmp13_; -#line 665 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp15_[3] = _tmp14_; -#line 665 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp15_[4] = NULL; -#line 665 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - keys = _tmp15_; -#line 665 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - keys_length1 = 5; -#line 665 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _keys_size_ = keys_length1; -#line 666 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp16_ = self->priv->_dpi; -#line 666 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp17_ = g_strdup_printf ("%d", _tmp16_); -#line 666 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp18_ = self->priv->_dpi; -#line 666 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp19_ = g_strdup_printf ("%d", _tmp18_); -#line 666 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp20_ = quality; -#line 666 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp21_ = g_strdup_printf ("%d", _tmp20_); -#line 666 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp22_ = icc_profile_data; -#line 666 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp23_ = g_strdup (_tmp22_); -#line 666 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp24_ = g_new0 (gchar*, 5 + 1); -#line 666 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp24_[0] = _tmp17_; -#line 666 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp24_[1] = _tmp19_; -#line 666 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp24_[2] = _tmp21_; -#line 666 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp24_[3] = _tmp23_; -#line 666 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp24_[4] = NULL; -#line 666 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - values = _tmp24_; -#line 666 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - values_length1 = 5; -#line 666 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _values_size_ = values_length1; -#line 667 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp25_ = icc_profile_data; -#line 667 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - if (_tmp25_ == NULL) { -#line 3072 "page.c" - gchar** _tmp26_ = NULL; - gint _tmp26__length1 = 0; - gchar* _tmp27_ = NULL; -#line 668 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp26_ = keys; -#line 668 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp26__length1 = keys_length1; -#line 668 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _g_free0 (_tmp26_[3]); -#line 668 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp26_[3] = NULL; -#line 668 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp27_ = _tmp26_[3]; -#line 3086 "page.c" - } -#line 669 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp28_ = writer; -#line 669 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp29_ = image; -#line 669 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp30_ = keys; -#line 669 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp30__length1 = keys_length1; -#line 669 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp31_ = values; -#line 669 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp31__length1 = values_length1; -#line 669 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - pixbuf_writer_save (_tmp28_, _tmp29_, "jpeg", _tmp30_, _tmp30__length1, _tmp31_, _tmp31__length1, &_inner_error_); -#line 669 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - if (G_UNLIKELY (_inner_error_ != NULL)) { -#line 669 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - g_propagate_error (error, _inner_error_); -#line 669 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - values = (_vala_array_free (values, values_length1, (GDestroyNotify) g_free), NULL); -#line 669 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - keys = (_vala_array_free (keys, keys_length1, (GDestroyNotify) g_free), NULL); -#line 669 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _g_free0 (icc_profile_data); -#line 669 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _g_object_unref0 (image); -#line 669 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _pixbuf_writer_unref0 (writer); -#line 669 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _g_object_unref0 (stream); -#line 669 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - return; -#line 3120 "page.c" - } -#line 663 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - values = (_vala_array_free (values, values_length1, (GDestroyNotify) g_free), NULL); -#line 663 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - keys = (_vala_array_free (keys, keys_length1, (GDestroyNotify) g_free), NULL); -#line 3126 "page.c" - } else { - GCompareFunc _tmp32_ = NULL; - const gchar* _tmp33_ = NULL; - gint _tmp34_ = 0; -#line 671 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp32_ = g_strcmp0; -#line 671 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp33_ = type; -#line 671 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp34_ = _tmp32_ (_tmp33_, "png"); -#line 671 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - if (_tmp34_ == 0) { -#line 3139 "page.c" - gchar** keys = NULL; - gchar* _tmp35_ = NULL; - gchar* _tmp36_ = NULL; - gchar* _tmp37_ = NULL; - gchar** _tmp38_ = NULL; - gint keys_length1 = 0; - gint _keys_size_ = 0; - gchar** values = NULL; - gint _tmp39_ = 0; - gchar* _tmp40_ = NULL; - gint _tmp41_ = 0; - gchar* _tmp42_ = NULL; - const gchar* _tmp43_ = NULL; - gchar* _tmp44_ = NULL; - gchar** _tmp45_ = NULL; - gint values_length1 = 0; - gint _values_size_ = 0; - const gchar* _tmp46_ = NULL; - PixbufWriter* _tmp49_ = NULL; - GdkPixbuf* _tmp50_ = NULL; - gchar** _tmp51_ = NULL; - gint _tmp51__length1 = 0; - gchar** _tmp52_ = NULL; - gint _tmp52__length1 = 0; -#line 673 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp35_ = g_strdup ("x-dpi"); -#line 673 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp36_ = g_strdup ("y-dpi"); -#line 673 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp37_ = g_strdup ("icc-profile"); -#line 673 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp38_ = g_new0 (gchar*, 4 + 1); -#line 673 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp38_[0] = _tmp35_; -#line 673 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp38_[1] = _tmp36_; -#line 673 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp38_[2] = _tmp37_; -#line 673 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp38_[3] = NULL; -#line 673 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - keys = _tmp38_; -#line 673 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - keys_length1 = 4; -#line 673 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _keys_size_ = keys_length1; -#line 674 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp39_ = self->priv->_dpi; -#line 674 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp40_ = g_strdup_printf ("%d", _tmp39_); -#line 674 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp41_ = self->priv->_dpi; -#line 674 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp42_ = g_strdup_printf ("%d", _tmp41_); -#line 674 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp43_ = icc_profile_data; -#line 674 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp44_ = g_strdup (_tmp43_); -#line 674 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp45_ = g_new0 (gchar*, 4 + 1); -#line 674 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp45_[0] = _tmp40_; -#line 674 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp45_[1] = _tmp42_; -#line 674 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp45_[2] = _tmp44_; -#line 674 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp45_[3] = NULL; -#line 674 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - values = _tmp45_; -#line 674 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - values_length1 = 4; -#line 674 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _values_size_ = values_length1; -#line 675 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp46_ = icc_profile_data; -#line 675 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - if (_tmp46_ == NULL) { -#line 3218 "page.c" - gchar** _tmp47_ = NULL; - gint _tmp47__length1 = 0; - gchar* _tmp48_ = NULL; -#line 676 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp47_ = keys; -#line 676 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp47__length1 = keys_length1; -#line 676 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _g_free0 (_tmp47_[2]); -#line 676 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp47_[2] = NULL; -#line 676 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp48_ = _tmp47_[2]; -#line 3232 "page.c" - } -#line 677 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp49_ = writer; -#line 677 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp50_ = image; -#line 677 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp51_ = keys; -#line 677 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp51__length1 = keys_length1; -#line 677 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp52_ = values; -#line 677 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp52__length1 = values_length1; -#line 677 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - pixbuf_writer_save (_tmp49_, _tmp50_, "png", _tmp51_, _tmp51__length1, _tmp52_, _tmp52__length1, &_inner_error_); -#line 677 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - if (G_UNLIKELY (_inner_error_ != NULL)) { -#line 677 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - g_propagate_error (error, _inner_error_); -#line 677 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - values = (_vala_array_free (values, values_length1, (GDestroyNotify) g_free), NULL); -#line 677 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - keys = (_vala_array_free (keys, keys_length1, (GDestroyNotify) g_free), NULL); -#line 677 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _g_free0 (icc_profile_data); -#line 677 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _g_object_unref0 (image); -#line 677 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _pixbuf_writer_unref0 (writer); -#line 677 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _g_object_unref0 (stream); -#line 677 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - return; -#line 3266 "page.c" - } -#line 671 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - values = (_vala_array_free (values, values_length1, (GDestroyNotify) g_free), NULL); -#line 671 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - keys = (_vala_array_free (keys, keys_length1, (GDestroyNotify) g_free), NULL); -#line 3272 "page.c" - } else { - GCompareFunc _tmp53_ = NULL; - const gchar* _tmp54_ = NULL; - gint _tmp55_ = 0; -#line 679 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp53_ = g_strcmp0; -#line 679 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp54_ = type; -#line 679 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp55_ = _tmp53_ (_tmp54_, "tiff"); -#line 679 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - if (_tmp55_ == 0) { -#line 3285 "page.c" - gchar** keys = NULL; - gchar* _tmp56_ = NULL; - gchar* _tmp57_ = NULL; - gchar* _tmp58_ = NULL; - gchar* _tmp59_ = NULL; - gchar** _tmp60_ = NULL; - gint keys_length1 = 0; - gint _keys_size_ = 0; - gchar** values = NULL; - gint _tmp61_ = 0; - gchar* _tmp62_ = NULL; - gint _tmp63_ = 0; - gchar* _tmp64_ = NULL; - gchar* _tmp65_ = NULL; - const gchar* _tmp66_ = NULL; - gchar* _tmp67_ = NULL; - gchar** _tmp68_ = NULL; - gint values_length1 = 0; - gint _values_size_ = 0; - const gchar* _tmp69_ = NULL; - PixbufWriter* _tmp72_ = NULL; - GdkPixbuf* _tmp73_ = NULL; - gchar** _tmp74_ = NULL; - gint _tmp74__length1 = 0; - gchar** _tmp75_ = NULL; - gint _tmp75__length1 = 0; -#line 681 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp56_ = g_strdup ("x-dpi"); -#line 681 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp57_ = g_strdup ("y-dpi"); -#line 681 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp58_ = g_strdup ("compression"); -#line 681 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp59_ = g_strdup ("icc-profile"); -#line 681 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp60_ = g_new0 (gchar*, 5 + 1); -#line 681 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp60_[0] = _tmp56_; -#line 681 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp60_[1] = _tmp57_; -#line 681 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp60_[2] = _tmp58_; -#line 681 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp60_[3] = _tmp59_; -#line 681 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp60_[4] = NULL; -#line 681 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - keys = _tmp60_; -#line 681 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - keys_length1 = 5; -#line 681 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _keys_size_ = keys_length1; -#line 682 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp61_ = self->priv->_dpi; -#line 682 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp62_ = g_strdup_printf ("%d", _tmp61_); -#line 682 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp63_ = self->priv->_dpi; -#line 682 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp64_ = g_strdup_printf ("%d", _tmp63_); -#line 682 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp65_ = g_strdup ("8"); -#line 682 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp66_ = icc_profile_data; -#line 682 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp67_ = g_strdup (_tmp66_); -#line 682 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp68_ = g_new0 (gchar*, 5 + 1); -#line 682 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp68_[0] = _tmp62_; -#line 682 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp68_[1] = _tmp64_; -#line 682 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp68_[2] = _tmp65_; -#line 682 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp68_[3] = _tmp67_; -#line 682 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp68_[4] = NULL; -#line 682 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - values = _tmp68_; -#line 682 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - values_length1 = 5; -#line 682 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _values_size_ = values_length1; -#line 683 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp69_ = icc_profile_data; -#line 683 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - if (_tmp69_ == NULL) { -#line 3374 "page.c" - gchar** _tmp70_ = NULL; - gint _tmp70__length1 = 0; - gchar* _tmp71_ = NULL; -#line 684 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp70_ = keys; -#line 684 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp70__length1 = keys_length1; -#line 684 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _g_free0 (_tmp70_[3]); -#line 684 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp70_[3] = NULL; -#line 684 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp71_ = _tmp70_[3]; -#line 3388 "page.c" - } -#line 685 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp72_ = writer; -#line 685 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp73_ = image; -#line 685 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp74_ = keys; -#line 685 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp74__length1 = keys_length1; -#line 685 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp75_ = values; -#line 685 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp75__length1 = values_length1; -#line 685 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - pixbuf_writer_save (_tmp72_, _tmp73_, "tiff", _tmp74_, _tmp74__length1, _tmp75_, _tmp75__length1, &_inner_error_); -#line 685 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - if (G_UNLIKELY (_inner_error_ != NULL)) { -#line 685 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - g_propagate_error (error, _inner_error_); -#line 685 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - values = (_vala_array_free (values, values_length1, (GDestroyNotify) g_free), NULL); -#line 685 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - keys = (_vala_array_free (keys, keys_length1, (GDestroyNotify) g_free), NULL); -#line 685 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _g_free0 (icc_profile_data); -#line 685 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _g_object_unref0 (image); -#line 685 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _pixbuf_writer_unref0 (writer); -#line 685 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _g_object_unref0 (stream); -#line 685 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - return; -#line 3422 "page.c" - } -#line 679 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - values = (_vala_array_free (values, values_length1, (GDestroyNotify) g_free), NULL); -#line 679 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - keys = (_vala_array_free (keys, keys_length1, (GDestroyNotify) g_free), NULL); -#line 3428 "page.c" - } else { - const gchar* _tmp76_ = NULL; - gchar* _tmp77_ = NULL; - gchar* _tmp78_ = NULL; - GError* _tmp79_ = NULL; - GError* _tmp80_ = NULL; -#line 688 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp76_ = type; -#line 688 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp77_ = g_strdup_printf ("Unknown file type: %s", _tmp76_); -#line 688 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp78_ = _tmp77_; -#line 688 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp79_ = g_error_new_literal (G_FILE_ERROR, G_FILE_ERROR_INVAL, _tmp78_); -#line 688 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp80_ = _tmp79_; -#line 688 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _g_free0 (_tmp78_); -#line 688 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _inner_error_ = _tmp80_; -#line 688 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - g_propagate_error (error, _inner_error_); -#line 688 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _g_free0 (icc_profile_data); -#line 688 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _g_object_unref0 (image); -#line 688 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _pixbuf_writer_unref0 (writer); -#line 688 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _g_object_unref0 (stream); -#line 688 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - return; -#line 3461 "page.c" - } - } - } -#line 653 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _g_free0 (icc_profile_data); -#line 653 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _g_object_unref0 (image); -#line 653 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _pixbuf_writer_unref0 (writer); -#line 653 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _g_object_unref0 (stream); -#line 3473 "page.c" -} - - -gint page_get_width (Page* self) { - gint result; - gboolean _tmp0_ = FALSE; - ScanDirection _tmp1_ = 0; - ScanDirection _tmp2_ = 0; -#line 25 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - g_return_val_if_fail (self != NULL, 0); -#line 27 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp1_ = page_get_scan_direction (self); -#line 27 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp2_ = _tmp1_; -#line 27 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - if (_tmp2_ == SCAN_DIRECTION_TOP_TO_BOTTOM) { -#line 27 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp0_ = TRUE; -#line 3492 "page.c" - } else { - ScanDirection _tmp3_ = 0; - ScanDirection _tmp4_ = 0; -#line 27 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp3_ = page_get_scan_direction (self); -#line 27 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp4_ = _tmp3_; -#line 27 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp0_ = _tmp4_ == SCAN_DIRECTION_BOTTOM_TO_TOP; -#line 3502 "page.c" - } -#line 27 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - if (_tmp0_) { -#line 3506 "page.c" - gint _tmp5_ = 0; -#line 28 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp5_ = self->priv->_scan_width; -#line 28 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - result = _tmp5_; -#line 28 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - return result; -#line 3514 "page.c" - } else { - gint _tmp6_ = 0; -#line 30 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp6_ = self->priv->_scan_height; -#line 30 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - result = _tmp6_; -#line 30 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - return result; -#line 3523 "page.c" - } -} - - -gint page_get_height (Page* self) { - gint result; - gboolean _tmp0_ = FALSE; - ScanDirection _tmp1_ = 0; - ScanDirection _tmp2_ = 0; -#line 37 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - g_return_val_if_fail (self != NULL, 0); -#line 39 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp1_ = page_get_scan_direction (self); -#line 39 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp2_ = _tmp1_; -#line 39 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - if (_tmp2_ == SCAN_DIRECTION_TOP_TO_BOTTOM) { -#line 39 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp0_ = TRUE; -#line 3543 "page.c" - } else { - ScanDirection _tmp3_ = 0; - ScanDirection _tmp4_ = 0; -#line 39 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp3_ = page_get_scan_direction (self); -#line 39 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp4_ = _tmp3_; -#line 39 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp0_ = _tmp4_ == SCAN_DIRECTION_BOTTOM_TO_TOP; -#line 3553 "page.c" - } -#line 39 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - if (_tmp0_) { -#line 3557 "page.c" - gint _tmp5_ = 0; -#line 40 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp5_ = self->priv->_scan_height; -#line 40 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - result = _tmp5_; -#line 40 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - return result; -#line 3565 "page.c" - } else { - gint _tmp6_ = 0; -#line 42 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp6_ = self->priv->_scan_width; -#line 42 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - result = _tmp6_; -#line 42 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - return result; -#line 3574 "page.c" - } -} - - -gboolean page_get_is_landscape (Page* self) { - gboolean result; - gint _tmp0_ = 0; - gint _tmp1_ = 0; - gint _tmp2_ = 0; - gint _tmp3_ = 0; -#line 47 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - g_return_val_if_fail (self != NULL, FALSE); -#line 47 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp0_ = page_get_width (self); -#line 47 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp1_ = _tmp0_; -#line 47 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp2_ = page_get_height (self); -#line 47 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp3_ = _tmp2_; -#line 47 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - result = _tmp1_ > _tmp3_; -#line 47 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - return result; -#line 3599 "page.c" -} - - -gint page_get_dpi (Page* self) { - gint result; - gint _tmp0_ = 0; -#line 50 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - g_return_val_if_fail (self != NULL, 0); -#line 50 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp0_ = self->priv->_dpi; -#line 50 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - result = _tmp0_; -#line 50 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - return result; -#line 3614 "page.c" -} - - -static void page_set_dpi (Page* self, gint value) { - gint _tmp0_ = 0; -#line 50 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - g_return_if_fail (self != NULL); -#line 50 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp0_ = value; -#line 50 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - self->priv->_dpi = _tmp0_; -#line 3626 "page.c" -} - - -gint page_get_depth (Page* self) { - gint result; - gint _tmp0_ = 0; -#line 56 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - g_return_val_if_fail (self != NULL, 0); -#line 56 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp0_ = self->priv->_depth; -#line 56 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - result = _tmp0_; -#line 56 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - return result; -#line 3641 "page.c" -} - - -static void page_set_depth (Page* self, gint value) { - gint _tmp0_ = 0; -#line 56 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - g_return_if_fail (self != NULL); -#line 56 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp0_ = value; -#line 56 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - self->priv->_depth = _tmp0_; -#line 3653 "page.c" -} - - -const gchar* page_get_color_profile (Page* self) { - const gchar* result; - const gchar* _tmp0_ = NULL; -#line 59 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - g_return_val_if_fail (self != NULL, NULL); -#line 59 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp0_ = self->priv->_color_profile; -#line 59 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - result = _tmp0_; -#line 59 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - return result; -#line 3668 "page.c" -} - - -void page_set_color_profile (Page* self, const gchar* value) { - const gchar* _tmp0_ = NULL; - gchar* _tmp1_ = NULL; -#line 59 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - g_return_if_fail (self != NULL); -#line 59 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp0_ = value; -#line 59 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp1_ = g_strdup (_tmp0_); -#line 59 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _g_free0 (self->priv->_color_profile); -#line 59 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - self->priv->_color_profile = _tmp1_; -#line 3685 "page.c" -} - - -gint page_get_scan_width (Page* self) { - gint result; - gint _tmp0_ = 0; -#line 62 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - g_return_val_if_fail (self != NULL, 0); -#line 62 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp0_ = self->priv->_scan_width; -#line 62 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - result = _tmp0_; -#line 62 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - return result; -#line 3700 "page.c" -} - - -static void page_set_scan_width (Page* self, gint value) { - gint _tmp0_ = 0; -#line 62 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - g_return_if_fail (self != NULL); -#line 62 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp0_ = value; -#line 62 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - self->priv->_scan_width = _tmp0_; -#line 3712 "page.c" -} - - -gint page_get_scan_height (Page* self) { - gint result; - gint _tmp0_ = 0; -#line 65 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - g_return_val_if_fail (self != NULL, 0); -#line 65 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp0_ = self->priv->_scan_height; -#line 65 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - result = _tmp0_; -#line 65 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - return result; -#line 3727 "page.c" -} - - -static void page_set_scan_height (Page* self, gint value) { - gint _tmp0_ = 0; -#line 65 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - g_return_if_fail (self != NULL); -#line 65 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp0_ = value; -#line 65 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - self->priv->_scan_height = _tmp0_; -#line 3739 "page.c" -} - - -gint page_get_rowstride (Page* self) { - gint result; - gint _tmp0_ = 0; -#line 68 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - g_return_val_if_fail (self != NULL, 0); -#line 68 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp0_ = self->priv->_rowstride; -#line 68 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - result = _tmp0_; -#line 68 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - return result; -#line 3754 "page.c" -} - - -static void page_set_rowstride (Page* self, gint value) { - gint _tmp0_ = 0; -#line 68 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - g_return_if_fail (self != NULL); -#line 68 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp0_ = value; -#line 68 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - self->priv->_rowstride = _tmp0_; -#line 3766 "page.c" -} - - -gint page_get_n_channels (Page* self) { - gint result; - gint _tmp0_ = 0; -#line 71 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - g_return_val_if_fail (self != NULL, 0); -#line 71 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp0_ = self->priv->_n_channels; -#line 71 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - result = _tmp0_; -#line 71 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - return result; -#line 3781 "page.c" -} - - -static void page_set_n_channels (Page* self, gint value) { - gint _tmp0_ = 0; -#line 71 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - g_return_if_fail (self != NULL); -#line 71 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp0_ = value; -#line 71 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - self->priv->_n_channels = _tmp0_; -#line 3793 "page.c" -} - - -gboolean page_get_is_scanning (Page* self) { - gboolean result; - gboolean _tmp0_ = FALSE; -#line 77 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - g_return_val_if_fail (self != NULL, FALSE); -#line 77 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp0_ = self->priv->_is_scanning; -#line 77 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - result = _tmp0_; -#line 77 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - return result; -#line 3808 "page.c" -} - - -static void page_set_is_scanning (Page* self, gboolean value) { - gboolean _tmp0_ = FALSE; -#line 77 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - g_return_if_fail (self != NULL); -#line 77 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp0_ = value; -#line 77 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - self->priv->_is_scanning = _tmp0_; -#line 3820 "page.c" -} - - -gboolean page_get_has_data (Page* self) { - gboolean result; - gboolean _tmp0_ = FALSE; -#line 80 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - g_return_val_if_fail (self != NULL, FALSE); -#line 80 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp0_ = self->priv->_has_data; -#line 80 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - result = _tmp0_; -#line 80 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - return result; -#line 3835 "page.c" -} - - -static void page_set_has_data (Page* self, gboolean value) { - gboolean _tmp0_ = FALSE; -#line 80 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - g_return_if_fail (self != NULL); -#line 80 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp0_ = value; -#line 80 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - self->priv->_has_data = _tmp0_; -#line 3847 "page.c" -} - - -gint page_get_scan_line (Page* self) { - gint result; - gint _tmp0_ = 0; -#line 83 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - g_return_val_if_fail (self != NULL, 0); -#line 83 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp0_ = self->priv->_scan_line; -#line 83 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - result = _tmp0_; -#line 83 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - return result; -#line 3862 "page.c" -} - - -static void page_set_scan_line (Page* self, gint value) { - gint _tmp0_ = 0; -#line 83 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - g_return_if_fail (self != NULL); -#line 83 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp0_ = value; -#line 83 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - self->priv->_scan_line = _tmp0_; -#line 3874 "page.c" -} - - -gboolean page_get_is_color (Page* self) { - gboolean result; - gint _tmp0_ = 0; -#line 86 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - g_return_val_if_fail (self != NULL, FALSE); -#line 86 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp0_ = self->priv->_n_channels; -#line 86 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - result = _tmp0_ > 1; -#line 86 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - return result; -#line 3889 "page.c" -} - - -ScanDirection page_get_scan_direction (Page* self) { - ScanDirection result; - ScanDirection _tmp0_ = 0; -#line 92 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - g_return_val_if_fail (self != NULL, 0); -#line 92 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp0_ = self->priv->scan_direction_; -#line 92 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - result = _tmp0_; -#line 92 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - return result; -#line 3904 "page.c" -} - - -void page_set_scan_direction (Page* self, ScanDirection value) { - ScanDirection _tmp0_ = 0; - ScanDirection _tmp1_ = 0; - gboolean size_has_changed = FALSE; - gint left_steps = 0; - ScanDirection _tmp2_ = 0; - ScanDirection _tmp3_ = 0; - gint _tmp4_ = 0; - gint _tmp6_ = 0; - gboolean _tmp7_ = FALSE; - ScanDirection _tmp35_ = 0; - gboolean _tmp36_ = FALSE; - gboolean _tmp37_ = FALSE; -#line 94 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - g_return_if_fail (self != NULL); -#line 96 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp0_ = self->priv->scan_direction_; -#line 96 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp1_ = value; -#line 96 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - if (_tmp0_ == _tmp1_) { -#line 97 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - return; -#line 3931 "page.c" - } -#line 100 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - size_has_changed = FALSE; -#line 101 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp2_ = value; -#line 101 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp3_ = self->priv->scan_direction_; -#line 101 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - left_steps = (gint) (_tmp2_ - _tmp3_); -#line 102 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp4_ = left_steps; -#line 102 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - if (_tmp4_ < 0) { -#line 3945 "page.c" - gint _tmp5_ = 0; -#line 103 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp5_ = left_steps; -#line 103 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - left_steps = _tmp5_ + 4; -#line 3951 "page.c" - } -#line 104 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp6_ = left_steps; -#line 104 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - if (_tmp6_ != 2) { -#line 105 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - size_has_changed = TRUE; -#line 3959 "page.c" - } -#line 108 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp7_ = self->priv->_has_crop; -#line 108 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - if (_tmp7_) { -#line 3965 "page.c" - gint _tmp8_ = 0; -#line 110 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp8_ = left_steps; -#line 110 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - switch (_tmp8_) { -#line 110 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - case 1: -#line 3973 "page.c" - { - gint t = 0; - gint _tmp9_ = 0; - gint _tmp10_ = 0; - gint _tmp11_ = 0; - gint _tmp12_ = 0; - gint _tmp13_ = 0; - gint _tmp14_ = 0; - gint _tmp15_ = 0; - gint _tmp16_ = 0; - gint _tmp17_ = 0; -#line 114 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp9_ = self->priv->_crop_x; -#line 114 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - t = _tmp9_; -#line 115 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp10_ = self->priv->_crop_y; -#line 115 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - page_set_crop_x (self, _tmp10_); -#line 116 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp11_ = page_get_width (self); -#line 116 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp12_ = _tmp11_; -#line 116 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp13_ = t; -#line 116 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp14_ = self->priv->_crop_width; -#line 116 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - page_set_crop_y (self, _tmp12_ - (_tmp13_ + _tmp14_)); -#line 117 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp15_ = self->priv->_crop_width; -#line 117 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - t = _tmp15_; -#line 118 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp16_ = self->priv->_crop_height; -#line 118 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - page_set_crop_width (self, _tmp16_); -#line 119 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp17_ = t; -#line 119 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - page_set_crop_height (self, _tmp17_); -#line 120 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - break; -#line 4017 "page.c" - } -#line 110 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - case 2: -#line 4021 "page.c" - { - gint _tmp18_ = 0; - gint _tmp19_ = 0; - gint _tmp20_ = 0; - gint _tmp21_ = 0; - gint _tmp22_ = 0; - gint _tmp23_ = 0; - gint _tmp24_ = 0; - gint _tmp25_ = 0; -#line 123 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp18_ = page_get_width (self); -#line 123 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp19_ = _tmp18_; -#line 123 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp20_ = self->priv->_crop_x; -#line 123 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp21_ = self->priv->_crop_width; -#line 123 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - page_set_crop_x (self, _tmp19_ - (_tmp20_ + _tmp21_)); -#line 124 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp22_ = page_get_width (self); -#line 124 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp23_ = _tmp22_; -#line 124 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp24_ = self->priv->_crop_y; -#line 124 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp25_ = self->priv->_crop_height; -#line 124 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - page_set_crop_y (self, _tmp23_ - (_tmp24_ + _tmp25_)); -#line 125 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - break; -#line 4053 "page.c" - } -#line 110 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - case 3: -#line 4057 "page.c" - { - gint t = 0; - gint _tmp26_ = 0; - gint _tmp27_ = 0; - gint _tmp28_ = 0; - gint _tmp29_ = 0; - gint _tmp30_ = 0; - gint _tmp31_ = 0; - gint _tmp32_ = 0; - gint _tmp33_ = 0; - gint _tmp34_ = 0; -#line 128 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp26_ = self->priv->_crop_y; -#line 128 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - t = _tmp26_; -#line 129 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp27_ = self->priv->_crop_x; -#line 129 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - page_set_crop_y (self, _tmp27_); -#line 130 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp28_ = page_get_height (self); -#line 130 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp29_ = _tmp28_; -#line 130 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp30_ = t; -#line 130 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp31_ = self->priv->_crop_height; -#line 130 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - page_set_crop_x (self, _tmp29_ - (_tmp30_ + _tmp31_)); -#line 131 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp32_ = self->priv->_crop_width; -#line 131 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - t = _tmp32_; -#line 132 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp33_ = self->priv->_crop_height; -#line 132 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - page_set_crop_width (self, _tmp33_); -#line 133 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp34_ = t; -#line 133 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - page_set_crop_height (self, _tmp34_); -#line 134 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - break; -#line 4101 "page.c" - } - default: -#line 110 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - break; -#line 4106 "page.c" - } - } -#line 138 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp35_ = value; -#line 138 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - self->priv->scan_direction_ = _tmp35_; -#line 139 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp36_ = size_has_changed; -#line 139 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - if (_tmp36_) { -#line 140 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - g_signal_emit_by_name (self, "size-changed"); -#line 4119 "page.c" - } -#line 141 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - g_signal_emit_by_name (self, "scan-direction-changed"); -#line 142 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp37_ = self->priv->_has_crop; -#line 142 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - if (_tmp37_) { -#line 143 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - g_signal_emit_by_name (self, "crop-changed"); -#line 4129 "page.c" - } -} - - -gboolean page_get_has_crop (Page* self) { - gboolean result; - gboolean _tmp0_ = FALSE; -#line 150 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - g_return_val_if_fail (self != NULL, FALSE); -#line 150 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp0_ = self->priv->_has_crop; -#line 150 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - result = _tmp0_; -#line 150 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - return result; -#line 4145 "page.c" -} - - -static void page_set_has_crop (Page* self, gboolean value) { - gboolean _tmp0_ = FALSE; -#line 150 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - g_return_if_fail (self != NULL); -#line 150 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp0_ = value; -#line 150 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - self->priv->_has_crop = _tmp0_; -#line 4157 "page.c" -} - - -const gchar* page_get_crop_name (Page* self) { - const gchar* result; - const gchar* _tmp0_ = NULL; -#line 153 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - g_return_val_if_fail (self != NULL, NULL); -#line 153 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp0_ = self->priv->_crop_name; -#line 153 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - result = _tmp0_; -#line 153 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - return result; -#line 4172 "page.c" -} - - -static void page_set_crop_name (Page* self, const gchar* value) { - const gchar* _tmp0_ = NULL; - gchar* _tmp1_ = NULL; -#line 153 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - g_return_if_fail (self != NULL); -#line 153 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp0_ = value; -#line 153 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp1_ = g_strdup (_tmp0_); -#line 153 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _g_free0 (self->priv->_crop_name); -#line 153 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - self->priv->_crop_name = _tmp1_; -#line 4189 "page.c" -} - - -gint page_get_crop_x (Page* self) { - gint result; - gint _tmp0_ = 0; -#line 156 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - g_return_val_if_fail (self != NULL, 0); -#line 156 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp0_ = self->priv->_crop_x; -#line 156 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - result = _tmp0_; -#line 156 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - return result; -#line 4204 "page.c" -} - - -static void page_set_crop_x (Page* self, gint value) { - gint _tmp0_ = 0; -#line 156 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - g_return_if_fail (self != NULL); -#line 156 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp0_ = value; -#line 156 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - self->priv->_crop_x = _tmp0_; -#line 4216 "page.c" -} - - -gint page_get_crop_y (Page* self) { - gint result; - gint _tmp0_ = 0; -#line 159 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - g_return_val_if_fail (self != NULL, 0); -#line 159 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp0_ = self->priv->_crop_y; -#line 159 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - result = _tmp0_; -#line 159 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - return result; -#line 4231 "page.c" -} - - -static void page_set_crop_y (Page* self, gint value) { - gint _tmp0_ = 0; -#line 159 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - g_return_if_fail (self != NULL); -#line 159 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp0_ = value; -#line 159 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - self->priv->_crop_y = _tmp0_; -#line 4243 "page.c" -} - - -gint page_get_crop_width (Page* self) { - gint result; - gint _tmp0_ = 0; -#line 162 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - g_return_val_if_fail (self != NULL, 0); -#line 162 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp0_ = self->priv->_crop_width; -#line 162 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - result = _tmp0_; -#line 162 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - return result; -#line 4258 "page.c" -} - - -static void page_set_crop_width (Page* self, gint value) { - gint _tmp0_ = 0; -#line 162 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - g_return_if_fail (self != NULL); -#line 162 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp0_ = value; -#line 162 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - self->priv->_crop_width = _tmp0_; -#line 4270 "page.c" -} - - -gint page_get_crop_height (Page* self) { - gint result; - gint _tmp0_ = 0; -#line 165 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - g_return_val_if_fail (self != NULL, 0); -#line 165 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp0_ = self->priv->_crop_height; -#line 165 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - result = _tmp0_; -#line 165 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - return result; -#line 4285 "page.c" -} - - -static void page_set_crop_height (Page* self, gint value) { - gint _tmp0_ = 0; -#line 165 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - g_return_if_fail (self != NULL); -#line 165 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp0_ = value; -#line 165 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - self->priv->_crop_height = _tmp0_; -#line 4297 "page.c" -} - - -static void value_page_init (GValue* value) { -#line 20 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - value->data[0].v_pointer = NULL; -#line 4304 "page.c" -} - - -static void value_page_free_value (GValue* value) { -#line 20 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - if (value->data[0].v_pointer) { -#line 20 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - page_unref (value->data[0].v_pointer); -#line 4313 "page.c" - } -} - - -static void value_page_copy_value (const GValue* src_value, GValue* dest_value) { -#line 20 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - if (src_value->data[0].v_pointer) { -#line 20 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - dest_value->data[0].v_pointer = page_ref (src_value->data[0].v_pointer); -#line 4323 "page.c" - } else { -#line 20 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - dest_value->data[0].v_pointer = NULL; -#line 4327 "page.c" - } -} - - -static gpointer value_page_peek_pointer (const GValue* value) { -#line 20 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - return value->data[0].v_pointer; -#line 4335 "page.c" -} - - -static gchar* value_page_collect_value (GValue* value, guint n_collect_values, GTypeCValue* collect_values, guint collect_flags) { -#line 20 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - if (collect_values[0].v_pointer) { -#line 4342 "page.c" - Page* object; - object = collect_values[0].v_pointer; -#line 20 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - if (object->parent_instance.g_class == NULL) { -#line 20 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - return g_strconcat ("invalid unclassed object pointer for value type `", G_VALUE_TYPE_NAME (value), "'", NULL); -#line 4349 "page.c" - } else if (!g_value_type_compatible (G_TYPE_FROM_INSTANCE (object), G_VALUE_TYPE (value))) { -#line 20 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - return g_strconcat ("invalid object type `", g_type_name (G_TYPE_FROM_INSTANCE (object)), "' for value type `", G_VALUE_TYPE_NAME (value), "'", NULL); -#line 4353 "page.c" - } -#line 20 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - value->data[0].v_pointer = page_ref (object); -#line 4357 "page.c" - } else { -#line 20 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - value->data[0].v_pointer = NULL; -#line 4361 "page.c" - } -#line 20 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - return NULL; -#line 4365 "page.c" -} - - -static gchar* value_page_lcopy_value (const GValue* value, guint n_collect_values, GTypeCValue* collect_values, guint collect_flags) { - Page** object_p; - object_p = collect_values[0].v_pointer; -#line 20 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - if (!object_p) { -#line 20 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - return g_strdup_printf ("value location for `%s' passed as NULL", G_VALUE_TYPE_NAME (value)); -#line 4376 "page.c" - } -#line 20 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - if (!value->data[0].v_pointer) { -#line 20 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - *object_p = NULL; -#line 4382 "page.c" - } else if (collect_flags & G_VALUE_NOCOPY_CONTENTS) { -#line 20 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - *object_p = value->data[0].v_pointer; -#line 4386 "page.c" - } else { -#line 20 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - *object_p = page_ref (value->data[0].v_pointer); -#line 4390 "page.c" - } -#line 20 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - return NULL; -#line 4394 "page.c" -} - - -GParamSpec* param_spec_page (const gchar* name, const gchar* nick, const gchar* blurb, GType object_type, GParamFlags flags) { - ParamSpecPage* spec; -#line 20 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - g_return_val_if_fail (g_type_is_a (object_type, TYPE_PAGE), NULL); -#line 20 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - spec = g_param_spec_internal (G_TYPE_PARAM_OBJECT, name, nick, blurb, flags); -#line 20 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - G_PARAM_SPEC (spec)->value_type = object_type; -#line 20 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - return G_PARAM_SPEC (spec); -#line 4408 "page.c" -} - - -gpointer value_get_page (const GValue* value) { -#line 20 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - g_return_val_if_fail (G_TYPE_CHECK_VALUE_TYPE (value, TYPE_PAGE), NULL); -#line 20 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - return value->data[0].v_pointer; -#line 4417 "page.c" -} - - -void value_set_page (GValue* value, gpointer v_object) { - Page* old; -#line 20 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - g_return_if_fail (G_TYPE_CHECK_VALUE_TYPE (value, TYPE_PAGE)); -#line 20 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - old = value->data[0].v_pointer; -#line 20 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - if (v_object) { -#line 20 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - g_return_if_fail (G_TYPE_CHECK_INSTANCE_TYPE (v_object, TYPE_PAGE)); -#line 20 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - g_return_if_fail (g_value_type_compatible (G_TYPE_FROM_INSTANCE (v_object), G_VALUE_TYPE (value))); -#line 20 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - value->data[0].v_pointer = v_object; -#line 20 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - page_ref (value->data[0].v_pointer); -#line 4437 "page.c" - } else { -#line 20 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - value->data[0].v_pointer = NULL; -#line 4441 "page.c" - } -#line 20 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - if (old) { -#line 20 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - page_unref (old); -#line 4447 "page.c" - } -} - - -void value_take_page (GValue* value, gpointer v_object) { - Page* old; -#line 20 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - g_return_if_fail (G_TYPE_CHECK_VALUE_TYPE (value, TYPE_PAGE)); -#line 20 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - old = value->data[0].v_pointer; -#line 20 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - if (v_object) { -#line 20 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - g_return_if_fail (G_TYPE_CHECK_INSTANCE_TYPE (v_object, TYPE_PAGE)); -#line 20 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - g_return_if_fail (g_value_type_compatible (G_TYPE_FROM_INSTANCE (v_object), G_VALUE_TYPE (value))); -#line 20 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - value->data[0].v_pointer = v_object; -#line 4466 "page.c" - } else { -#line 20 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - value->data[0].v_pointer = NULL; -#line 4470 "page.c" - } -#line 20 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - if (old) { -#line 20 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - page_unref (old); -#line 4476 "page.c" - } -} - - -static void page_class_init (PageClass * klass) { -#line 20 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - page_parent_class = g_type_class_peek_parent (klass); -#line 20 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - ((PageClass *) klass)->finalize = page_finalize; -#line 20 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - g_type_class_add_private (klass, sizeof (PagePrivate)); -#line 20 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - g_signal_new ("pixels_changed", TYPE_PAGE, G_SIGNAL_RUN_LAST, 0, NULL, NULL, g_cclosure_marshal_VOID__VOID, G_TYPE_NONE, 0); -#line 20 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - g_signal_new ("size_changed", TYPE_PAGE, G_SIGNAL_RUN_LAST, 0, NULL, NULL, g_cclosure_marshal_VOID__VOID, G_TYPE_NONE, 0); -#line 20 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - g_signal_new ("scan_line_changed", TYPE_PAGE, G_SIGNAL_RUN_LAST, 0, NULL, NULL, g_cclosure_marshal_VOID__VOID, G_TYPE_NONE, 0); -#line 20 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - g_signal_new ("scan_direction_changed", TYPE_PAGE, G_SIGNAL_RUN_LAST, 0, NULL, NULL, g_cclosure_marshal_VOID__VOID, G_TYPE_NONE, 0); -#line 20 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - g_signal_new ("crop_changed", TYPE_PAGE, G_SIGNAL_RUN_LAST, 0, NULL, NULL, g_cclosure_marshal_VOID__VOID, G_TYPE_NONE, 0); -#line 20 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - g_signal_new ("scan_finished", TYPE_PAGE, G_SIGNAL_RUN_LAST, 0, NULL, NULL, g_cclosure_marshal_VOID__VOID, G_TYPE_NONE, 0); -#line 4500 "page.c" -} - - -static void page_instance_init (Page * self) { -#line 20 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - self->priv = PAGE_GET_PRIVATE (self); -#line 20 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - self->ref_count = 1; -#line 4509 "page.c" -} - - -static void page_finalize (Page* obj) { - Page * self; -#line 20 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - self = G_TYPE_CHECK_INSTANCE_CAST (obj, TYPE_PAGE, Page); -#line 20 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - g_signal_handlers_destroy (self); -#line 59 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _g_free0 (self->priv->_color_profile); -#line 74 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - self->priv->pixels = (g_free (self->priv->pixels), NULL); -#line 153 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _g_free0 (self->priv->_crop_name); -#line 4525 "page.c" -} - - -GType page_get_type (void) { - static volatile gsize page_type_id__volatile = 0; - if (g_once_init_enter (&page_type_id__volatile)) { - static const GTypeValueTable g_define_type_value_table = { value_page_init, value_page_free_value, value_page_copy_value, value_page_peek_pointer, "p", value_page_collect_value, "p", value_page_lcopy_value }; - static const GTypeInfo g_define_type_info = { sizeof (PageClass), (GBaseInitFunc) NULL, (GBaseFinalizeFunc) NULL, (GClassInitFunc) page_class_init, (GClassFinalizeFunc) NULL, NULL, sizeof (Page), 0, (GInstanceInitFunc) page_instance_init, &g_define_type_value_table }; - static const GTypeFundamentalInfo g_define_type_fundamental_info = { (G_TYPE_FLAG_CLASSED | G_TYPE_FLAG_INSTANTIATABLE | G_TYPE_FLAG_DERIVABLE | G_TYPE_FLAG_DEEP_DERIVABLE) }; - GType page_type_id; - page_type_id = g_type_register_fundamental (g_type_fundamental_next (), "Page", &g_define_type_info, &g_define_type_fundamental_info, 0); - g_once_init_leave (&page_type_id__volatile, page_type_id); - } - return page_type_id__volatile; -} - - -gpointer page_ref (gpointer instance) { - Page* self; - self = instance; -#line 20 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - g_atomic_int_inc (&self->ref_count); -#line 20 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - return instance; -#line 4550 "page.c" -} - - -void page_unref (gpointer instance) { - Page* self; - self = instance; -#line 20 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - if (g_atomic_int_dec_and_test (&self->ref_count)) { -#line 20 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - PAGE_GET_CLASS (self)->finalize (self); -#line 20 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - g_type_free_instance ((GTypeInstance *) self); -#line 4563 "page.c" - } -} - - -PixbufWriter* pixbuf_writer_construct (GType object_type, GFileOutputStream* stream) { - PixbufWriter* self = NULL; - GFileOutputStream* _tmp0_ = NULL; - GFileOutputStream* _tmp1_ = NULL; -#line 696 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - g_return_val_if_fail (stream != NULL, NULL); -#line 696 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - self = (PixbufWriter*) g_type_create_instance (object_type); -#line 698 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp0_ = stream; -#line 698 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp1_ = _g_object_ref0 (_tmp0_); -#line 698 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _g_object_unref0 (self->stream); -#line 698 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - self->stream = _tmp1_; -#line 696 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - return self; -#line 4586 "page.c" -} - - -PixbufWriter* pixbuf_writer_new (GFileOutputStream* stream) { -#line 696 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - return pixbuf_writer_construct (TYPE_PIXBUF_WRITER, stream); -#line 4593 "page.c" -} - - -static gboolean _pixbuf_writer_write_pixbuf_data_gdk_pixbuf_save_func (guint8* buf, gsize buf_length1, GError** error, gpointer self) { - gboolean result; - result = pixbuf_writer_write_pixbuf_data ((PixbufWriter*) self, buf, buf_length1, error); -#line 703 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - return result; -#line 4602 "page.c" -} - - -void pixbuf_writer_save (PixbufWriter* self, GdkPixbuf* image, const gchar* type, gchar** option_keys, int option_keys_length1, gchar** option_values, int option_values_length1, GError** error) { - GdkPixbuf* _tmp0_ = NULL; - const gchar* _tmp1_ = NULL; - gchar** _tmp2_ = NULL; - gint _tmp2__length1 = 0; - gchar** _tmp3_ = NULL; - gint _tmp3__length1 = 0; - GError * _inner_error_ = NULL; -#line 701 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - g_return_if_fail (self != NULL); -#line 701 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - g_return_if_fail (image != NULL); -#line 701 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - g_return_if_fail (type != NULL); -#line 703 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp0_ = image; -#line 703 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp1_ = type; -#line 703 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp2_ = option_keys; -#line 703 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp2__length1 = option_keys_length1; -#line 703 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp3_ = option_values; -#line 703 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp3__length1 = option_values_length1; -#line 703 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - gdk_pixbuf_save_to_callbackv (_tmp0_, _pixbuf_writer_write_pixbuf_data_gdk_pixbuf_save_func, self, _tmp1_, _tmp2_, _tmp3_, &_inner_error_); -#line 703 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - if (G_UNLIKELY (_inner_error_ != NULL)) { -#line 703 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - g_propagate_error (error, _inner_error_); -#line 703 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - return; -#line 4640 "page.c" - } -} - - -static gboolean pixbuf_writer_write_pixbuf_data (PixbufWriter* self, guint8* buf, int buf_length1, GError** error) { - gboolean result = FALSE; - GFileOutputStream* _tmp0_ = NULL; - guint8* _tmp1_ = NULL; - gint _tmp1__length1 = 0; - GError * _inner_error_ = NULL; -#line 706 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - g_return_val_if_fail (self != NULL, FALSE); -#line 708 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp0_ = self->stream; -#line 708 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp1_ = buf; -#line 708 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _tmp1__length1 = buf_length1; -#line 708 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - g_output_stream_write_all ((GOutputStream*) _tmp0_, _tmp1_, (gsize) _tmp1__length1, NULL, NULL, &_inner_error_); -#line 708 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - if (G_UNLIKELY (_inner_error_ != NULL)) { -#line 4663 "page.c" - gboolean _tmp2_ = FALSE; -#line 708 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - g_propagate_error (error, _inner_error_); -#line 708 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - return _tmp2_; -#line 4669 "page.c" - } -#line 709 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - result = TRUE; -#line 709 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - return result; -#line 4675 "page.c" -} - - -static void value_pixbuf_writer_init (GValue* value) { -#line 692 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - value->data[0].v_pointer = NULL; -#line 4682 "page.c" -} - - -static void value_pixbuf_writer_free_value (GValue* value) { -#line 692 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - if (value->data[0].v_pointer) { -#line 692 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - pixbuf_writer_unref (value->data[0].v_pointer); -#line 4691 "page.c" - } -} - - -static void value_pixbuf_writer_copy_value (const GValue* src_value, GValue* dest_value) { -#line 692 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - if (src_value->data[0].v_pointer) { -#line 692 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - dest_value->data[0].v_pointer = pixbuf_writer_ref (src_value->data[0].v_pointer); -#line 4701 "page.c" - } else { -#line 692 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - dest_value->data[0].v_pointer = NULL; -#line 4705 "page.c" - } -} - - -static gpointer value_pixbuf_writer_peek_pointer (const GValue* value) { -#line 692 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - return value->data[0].v_pointer; -#line 4713 "page.c" -} - - -static gchar* value_pixbuf_writer_collect_value (GValue* value, guint n_collect_values, GTypeCValue* collect_values, guint collect_flags) { -#line 692 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - if (collect_values[0].v_pointer) { -#line 4720 "page.c" - PixbufWriter* object; - object = collect_values[0].v_pointer; -#line 692 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - if (object->parent_instance.g_class == NULL) { -#line 692 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - return g_strconcat ("invalid unclassed object pointer for value type `", G_VALUE_TYPE_NAME (value), "'", NULL); -#line 4727 "page.c" - } else if (!g_value_type_compatible (G_TYPE_FROM_INSTANCE (object), G_VALUE_TYPE (value))) { -#line 692 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - return g_strconcat ("invalid object type `", g_type_name (G_TYPE_FROM_INSTANCE (object)), "' for value type `", G_VALUE_TYPE_NAME (value), "'", NULL); -#line 4731 "page.c" - } -#line 692 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - value->data[0].v_pointer = pixbuf_writer_ref (object); -#line 4735 "page.c" - } else { -#line 692 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - value->data[0].v_pointer = NULL; -#line 4739 "page.c" - } -#line 692 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - return NULL; -#line 4743 "page.c" -} - - -static gchar* value_pixbuf_writer_lcopy_value (const GValue* value, guint n_collect_values, GTypeCValue* collect_values, guint collect_flags) { - PixbufWriter** object_p; - object_p = collect_values[0].v_pointer; -#line 692 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - if (!object_p) { -#line 692 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - return g_strdup_printf ("value location for `%s' passed as NULL", G_VALUE_TYPE_NAME (value)); -#line 4754 "page.c" - } -#line 692 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - if (!value->data[0].v_pointer) { -#line 692 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - *object_p = NULL; -#line 4760 "page.c" - } else if (collect_flags & G_VALUE_NOCOPY_CONTENTS) { -#line 692 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - *object_p = value->data[0].v_pointer; -#line 4764 "page.c" - } else { -#line 692 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - *object_p = pixbuf_writer_ref (value->data[0].v_pointer); -#line 4768 "page.c" - } -#line 692 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - return NULL; -#line 4772 "page.c" -} - - -GParamSpec* param_spec_pixbuf_writer (const gchar* name, const gchar* nick, const gchar* blurb, GType object_type, GParamFlags flags) { - ParamSpecPixbufWriter* spec; -#line 692 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - g_return_val_if_fail (g_type_is_a (object_type, TYPE_PIXBUF_WRITER), NULL); -#line 692 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - spec = g_param_spec_internal (G_TYPE_PARAM_OBJECT, name, nick, blurb, flags); -#line 692 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - G_PARAM_SPEC (spec)->value_type = object_type; -#line 692 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - return G_PARAM_SPEC (spec); -#line 4786 "page.c" -} - - -gpointer value_get_pixbuf_writer (const GValue* value) { -#line 692 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - g_return_val_if_fail (G_TYPE_CHECK_VALUE_TYPE (value, TYPE_PIXBUF_WRITER), NULL); -#line 692 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - return value->data[0].v_pointer; -#line 4795 "page.c" -} - - -void value_set_pixbuf_writer (GValue* value, gpointer v_object) { - PixbufWriter* old; -#line 692 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - g_return_if_fail (G_TYPE_CHECK_VALUE_TYPE (value, TYPE_PIXBUF_WRITER)); -#line 692 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - old = value->data[0].v_pointer; -#line 692 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - if (v_object) { -#line 692 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - g_return_if_fail (G_TYPE_CHECK_INSTANCE_TYPE (v_object, TYPE_PIXBUF_WRITER)); -#line 692 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - g_return_if_fail (g_value_type_compatible (G_TYPE_FROM_INSTANCE (v_object), G_VALUE_TYPE (value))); -#line 692 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - value->data[0].v_pointer = v_object; -#line 692 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - pixbuf_writer_ref (value->data[0].v_pointer); -#line 4815 "page.c" - } else { -#line 692 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - value->data[0].v_pointer = NULL; -#line 4819 "page.c" - } -#line 692 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - if (old) { -#line 692 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - pixbuf_writer_unref (old); -#line 4825 "page.c" - } -} - - -void value_take_pixbuf_writer (GValue* value, gpointer v_object) { - PixbufWriter* old; -#line 692 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - g_return_if_fail (G_TYPE_CHECK_VALUE_TYPE (value, TYPE_PIXBUF_WRITER)); -#line 692 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - old = value->data[0].v_pointer; -#line 692 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - if (v_object) { -#line 692 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - g_return_if_fail (G_TYPE_CHECK_INSTANCE_TYPE (v_object, TYPE_PIXBUF_WRITER)); -#line 692 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - g_return_if_fail (g_value_type_compatible (G_TYPE_FROM_INSTANCE (v_object), G_VALUE_TYPE (value))); -#line 692 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - value->data[0].v_pointer = v_object; -#line 4844 "page.c" - } else { -#line 692 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - value->data[0].v_pointer = NULL; -#line 4848 "page.c" - } -#line 692 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - if (old) { -#line 692 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - pixbuf_writer_unref (old); -#line 4854 "page.c" - } -} - - -static void pixbuf_writer_class_init (PixbufWriterClass * klass) { -#line 692 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - pixbuf_writer_parent_class = g_type_class_peek_parent (klass); -#line 692 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - ((PixbufWriterClass *) klass)->finalize = pixbuf_writer_finalize; -#line 4864 "page.c" -} - - -static void pixbuf_writer_instance_init (PixbufWriter * self) { -#line 692 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - self->ref_count = 1; -#line 4871 "page.c" -} - - -static void pixbuf_writer_finalize (PixbufWriter* obj) { - PixbufWriter * self; -#line 692 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - self = G_TYPE_CHECK_INSTANCE_CAST (obj, TYPE_PIXBUF_WRITER, PixbufWriter); -#line 692 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - g_signal_handlers_destroy (self); -#line 694 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - _g_object_unref0 (self->stream); -#line 4883 "page.c" -} - - -GType pixbuf_writer_get_type (void) { - static volatile gsize pixbuf_writer_type_id__volatile = 0; - if (g_once_init_enter (&pixbuf_writer_type_id__volatile)) { - static const GTypeValueTable g_define_type_value_table = { value_pixbuf_writer_init, value_pixbuf_writer_free_value, value_pixbuf_writer_copy_value, value_pixbuf_writer_peek_pointer, "p", value_pixbuf_writer_collect_value, "p", value_pixbuf_writer_lcopy_value }; - static const GTypeInfo g_define_type_info = { sizeof (PixbufWriterClass), (GBaseInitFunc) NULL, (GBaseFinalizeFunc) NULL, (GClassInitFunc) pixbuf_writer_class_init, (GClassFinalizeFunc) NULL, NULL, sizeof (PixbufWriter), 0, (GInstanceInitFunc) pixbuf_writer_instance_init, &g_define_type_value_table }; - static const GTypeFundamentalInfo g_define_type_fundamental_info = { (G_TYPE_FLAG_CLASSED | G_TYPE_FLAG_INSTANTIATABLE | G_TYPE_FLAG_DERIVABLE | G_TYPE_FLAG_DEEP_DERIVABLE) }; - GType pixbuf_writer_type_id; - pixbuf_writer_type_id = g_type_register_fundamental (g_type_fundamental_next (), "PixbufWriter", &g_define_type_info, &g_define_type_fundamental_info, 0); - g_once_init_leave (&pixbuf_writer_type_id__volatile, pixbuf_writer_type_id); - } - return pixbuf_writer_type_id__volatile; -} - - -gpointer pixbuf_writer_ref (gpointer instance) { - PixbufWriter* self; - self = instance; -#line 692 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - g_atomic_int_inc (&self->ref_count); -#line 692 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - return instance; -#line 4908 "page.c" -} - - -void pixbuf_writer_unref (gpointer instance) { - PixbufWriter* self; - self = instance; -#line 692 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - if (g_atomic_int_dec_and_test (&self->ref_count)) { -#line 692 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - PIXBUF_WRITER_GET_CLASS (self)->finalize (self); -#line 692 "/home/bob/bzr/simple-scan/trunk/src/page.vala" - g_type_free_instance ((GTypeInstance *) self); -#line 4921 "page.c" - } -} - - -static void _vala_array_destroy (gpointer array, gint array_length, GDestroyNotify destroy_func) { - if ((array != NULL) && (destroy_func != NULL)) { - int i; - for (i = 0; i < array_length; i = i + 1) { - if (((gpointer*) array)[i] != NULL) { - destroy_func (((gpointer*) array)[i]); - } - } - } -} - - -static void _vala_array_free (gpointer array, gint array_length, GDestroyNotify destroy_func) { - _vala_array_destroy (array, array_length, destroy_func); - g_free (array); -} - - - diff --git a/src/page.vala b/src/page.vala index 9636d0d..8936187 100644 --- a/src/page.vala +++ b/src/page.vala @@ -676,14 +676,6 @@ public class Page keys[2] = null; writer.save (image, "png", keys, values); } - else if (strcmp (type, "tiff") == 0) - { - string[] keys = { "x-dpi", "y-dpi", "compression", "icc-profile", null }; - string[] values = { "%d".printf (dpi), "%d".printf (dpi), "8" /* Deflate compression */, icc_profile_data, null }; - if (icc_profile_data == null) - keys[3] = null; - writer.save (image, "tiff", keys, values); - } else throw new FileError.INVAL ("Unknown file type: %s".printf (type)); } diff --git a/src/resources.c b/src/resources.c deleted file mode 100644 index e7147d9..0000000 --- a/src/resources.c +++ /dev/null @@ -1,6482 +0,0 @@ -#include - -#if defined (__ELF__) && ( __GNUC__ > 2 || (__GNUC__ == 2 && __GNUC_MINOR__ >= 6)) -# define SECTION __attribute__ ((section (".gresource.simple_scan"), aligned (8))) -#else -# define SECTION -#endif - -static const SECTION union { const guint8 data[50559]; const double alignment; void * const ptr;} simple_scan_resource_data = { { - 0x47, 0x56, 0x61, 0x72, 0x69, 0x61, 0x6e, 0x74, - 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, - 0x18, 0x00, 0x00, 0x00, 0xac, 0x00, 0x00, 0x00, - 0x00, 0x00, 0x00, 0x28, 0x05, 0x00, 0x00, 0x00, - 0x00, 0x00, 0x00, 0x00, 0x02, 0x00, 0x00, 0x00, - 0x02, 0x00, 0x00, 0x00, 0x03, 0x00, 0x00, 0x00, - 0x05, 0x00, 0x00, 0x00, 0xd4, 0xb5, 0x02, 0x00, - 0xff, 0xff, 0xff, 0xff, 0xac, 0x00, 0x00, 0x00, - 0x01, 0x00, 0x4c, 0x00, 0xb0, 0x00, 0x00, 0x00, - 0xb4, 0x00, 0x00, 0x00, 0x4b, 0x50, 0x90, 0x0b, - 0x00, 0x00, 0x00, 0x00, 0xb4, 0x00, 0x00, 0x00, - 0x04, 0x00, 0x4c, 0x00, 0xb8, 0x00, 0x00, 0x00, - 0xbc, 0x00, 0x00, 0x00, 0x6e, 0xa3, 0x22, 0x37, - 0x03, 0x00, 0x00, 0x00, 0xbc, 0x00, 0x00, 0x00, - 0x0b, 0x00, 0x4c, 0x00, 0xc8, 0x00, 0x00, 0x00, - 0xcc, 0x00, 0x00, 0x00, 0xb0, 0xb7, 0x24, 0x30, - 0x01, 0x00, 0x00, 0x00, 0xcc, 0x00, 0x00, 0x00, - 0x06, 0x00, 0x4c, 0x00, 0xd4, 0x00, 0x00, 0x00, - 0xd8, 0x00, 0x00, 0x00, 0x76, 0x8d, 0xc8, 0xbd, - 0x02, 0x00, 0x00, 0x00, 0xd8, 0x00, 0x00, 0x00, - 0x0e, 0x00, 0x76, 0x00, 0xe8, 0x00, 0x00, 0x00, - 0x7f, 0xc5, 0x00, 0x00, 0x2f, 0x00, 0x00, 0x00, - 0x01, 0x00, 0x00, 0x00, 0x6f, 0x72, 0x67, 0x2f, - 0x03, 0x00, 0x00, 0x00, 0x53, 0x69, 0x6d, 0x70, - 0x6c, 0x65, 0x53, 0x63, 0x61, 0x6e, 0x2f, 0x00, - 0x04, 0x00, 0x00, 0x00, 0x67, 0x6e, 0x6f, 0x6d, - 0x65, 0x2f, 0x00, 0x00, 0x02, 0x00, 0x00, 0x00, - 0x73, 0x69, 0x6d, 0x70, 0x6c, 0x65, 0x2d, 0x73, - 0x63, 0x61, 0x6e, 0x2e, 0x75, 0x69, 0x00, 0x00, - 0x87, 0xc4, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, - 0x3c, 0x3f, 0x78, 0x6d, 0x6c, 0x20, 0x76, 0x65, - 0x72, 0x73, 0x69, 0x6f, 0x6e, 0x3d, 0x22, 0x31, - 0x2e, 0x30, 0x22, 0x20, 0x65, 0x6e, 0x63, 0x6f, - 0x64, 0x69, 0x6e, 0x67, 0x3d, 0x22, 0x55, 0x54, - 0x46, 0x2d, 0x38, 0x22, 0x3f, 0x3e, 0x0a, 0x3c, - 0x69, 0x6e, 0x74, 0x65, 0x72, 0x66, 0x61, 0x63, - 0x65, 0x3e, 0x3c, 0x21, 0x2d, 0x2d, 0x20, 0x69, - 0x6e, 0x74, 0x65, 0x72, 0x66, 0x61, 0x63, 0x65, - 0x2d, 0x72, 0x65, 0x71, 0x75, 0x69, 0x72, 0x65, - 0x73, 0x20, 0x67, 0x74, 0x6b, 0x2b, 0x20, 0x33, - 0x2e, 0x31, 0x30, 0x20, 0x2d, 0x2d, 0x3e, 0x3c, - 0x6f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x20, 0x63, - 0x6c, 0x61, 0x73, 0x73, 0x3d, 0x22, 0x47, 0x74, - 0x6b, 0x44, 0x69, 0x61, 0x6c, 0x6f, 0x67, 0x22, - 0x20, 0x69, 0x64, 0x3d, 0x22, 0x61, 0x75, 0x74, - 0x68, 0x6f, 0x72, 0x69, 0x7a, 0x65, 0x5f, 0x64, - 0x69, 0x61, 0x6c, 0x6f, 0x67, 0x22, 0x3e, 0x3c, - 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, - 0x20, 0x6e, 0x61, 0x6d, 0x65, 0x3d, 0x22, 0x63, - 0x61, 0x6e, 0x5f, 0x66, 0x6f, 0x63, 0x75, 0x73, - 0x22, 0x3e, 0x46, 0x61, 0x6c, 0x73, 0x65, 0x3c, - 0x2f, 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, - 0x79, 0x3e, 0x3c, 0x70, 0x72, 0x6f, 0x70, 0x65, - 0x72, 0x74, 0x79, 0x20, 0x6e, 0x61, 0x6d, 0x65, - 0x3d, 0x22, 0x62, 0x6f, 0x72, 0x64, 0x65, 0x72, - 0x5f, 0x77, 0x69, 0x64, 0x74, 0x68, 0x22, 0x3e, - 0x31, 0x32, 0x3c, 0x2f, 0x70, 0x72, 0x6f, 0x70, - 0x65, 0x72, 0x74, 0x79, 0x3e, 0x3c, 0x70, 0x72, - 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, 0x20, 0x6e, - 0x61, 0x6d, 0x65, 0x3d, 0x22, 0x72, 0x65, 0x73, - 0x69, 0x7a, 0x61, 0x62, 0x6c, 0x65, 0x22, 0x3e, - 0x46, 0x61, 0x6c, 0x73, 0x65, 0x3c, 0x2f, 0x70, - 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, 0x3e, - 0x3c, 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, - 0x79, 0x20, 0x6e, 0x61, 0x6d, 0x65, 0x3d, 0x22, - 0x6d, 0x6f, 0x64, 0x61, 0x6c, 0x22, 0x3e, 0x54, - 0x72, 0x75, 0x65, 0x3c, 0x2f, 0x70, 0x72, 0x6f, - 0x70, 0x65, 0x72, 0x74, 0x79, 0x3e, 0x3c, 0x70, - 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, 0x20, - 0x6e, 0x61, 0x6d, 0x65, 0x3d, 0x22, 0x74, 0x79, - 0x70, 0x65, 0x5f, 0x68, 0x69, 0x6e, 0x74, 0x22, - 0x3e, 0x6e, 0x6f, 0x72, 0x6d, 0x61, 0x6c, 0x3c, - 0x2f, 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, - 0x79, 0x3e, 0x3c, 0x70, 0x72, 0x6f, 0x70, 0x65, - 0x72, 0x74, 0x79, 0x20, 0x6e, 0x61, 0x6d, 0x65, - 0x3d, 0x22, 0x75, 0x72, 0x67, 0x65, 0x6e, 0x63, - 0x79, 0x5f, 0x68, 0x69, 0x6e, 0x74, 0x22, 0x3e, - 0x54, 0x72, 0x75, 0x65, 0x3c, 0x2f, 0x70, 0x72, - 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, 0x3e, 0x3c, - 0x63, 0x68, 0x69, 0x6c, 0x64, 0x20, 0x69, 0x6e, - 0x74, 0x65, 0x72, 0x6e, 0x61, 0x6c, 0x2d, 0x63, - 0x68, 0x69, 0x6c, 0x64, 0x3d, 0x22, 0x76, 0x62, - 0x6f, 0x78, 0x22, 0x3e, 0x3c, 0x6f, 0x62, 0x6a, - 0x65, 0x63, 0x74, 0x20, 0x63, 0x6c, 0x61, 0x73, - 0x73, 0x3d, 0x22, 0x47, 0x74, 0x6b, 0x42, 0x6f, - 0x78, 0x22, 0x20, 0x69, 0x64, 0x3d, 0x22, 0x64, - 0x69, 0x61, 0x6c, 0x6f, 0x67, 0x2d, 0x76, 0x62, - 0x6f, 0x78, 0x31, 0x22, 0x3e, 0x3c, 0x70, 0x72, - 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, 0x20, 0x6e, - 0x61, 0x6d, 0x65, 0x3d, 0x22, 0x76, 0x69, 0x73, - 0x69, 0x62, 0x6c, 0x65, 0x22, 0x3e, 0x54, 0x72, - 0x75, 0x65, 0x3c, 0x2f, 0x70, 0x72, 0x6f, 0x70, - 0x65, 0x72, 0x74, 0x79, 0x3e, 0x3c, 0x70, 0x72, - 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, 0x20, 0x6e, - 0x61, 0x6d, 0x65, 0x3d, 0x22, 0x63, 0x61, 0x6e, - 0x5f, 0x66, 0x6f, 0x63, 0x75, 0x73, 0x22, 0x3e, - 0x46, 0x61, 0x6c, 0x73, 0x65, 0x3c, 0x2f, 0x70, - 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, 0x3e, - 0x3c, 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, - 0x79, 0x20, 0x6e, 0x61, 0x6d, 0x65, 0x3d, 0x22, - 0x6f, 0x72, 0x69, 0x65, 0x6e, 0x74, 0x61, 0x74, - 0x69, 0x6f, 0x6e, 0x22, 0x3e, 0x76, 0x65, 0x72, - 0x74, 0x69, 0x63, 0x61, 0x6c, 0x3c, 0x2f, 0x70, - 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, 0x3e, - 0x3c, 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, - 0x79, 0x20, 0x6e, 0x61, 0x6d, 0x65, 0x3d, 0x22, - 0x73, 0x70, 0x61, 0x63, 0x69, 0x6e, 0x67, 0x22, - 0x3e, 0x31, 0x32, 0x3c, 0x2f, 0x70, 0x72, 0x6f, - 0x70, 0x65, 0x72, 0x74, 0x79, 0x3e, 0x3c, 0x63, - 0x68, 0x69, 0x6c, 0x64, 0x20, 0x69, 0x6e, 0x74, - 0x65, 0x72, 0x6e, 0x61, 0x6c, 0x2d, 0x63, 0x68, - 0x69, 0x6c, 0x64, 0x3d, 0x22, 0x61, 0x63, 0x74, - 0x69, 0x6f, 0x6e, 0x5f, 0x61, 0x72, 0x65, 0x61, - 0x22, 0x3e, 0x3c, 0x6f, 0x62, 0x6a, 0x65, 0x63, - 0x74, 0x20, 0x63, 0x6c, 0x61, 0x73, 0x73, 0x3d, - 0x22, 0x47, 0x74, 0x6b, 0x42, 0x75, 0x74, 0x74, - 0x6f, 0x6e, 0x42, 0x6f, 0x78, 0x22, 0x20, 0x69, - 0x64, 0x3d, 0x22, 0x64, 0x69, 0x61, 0x6c, 0x6f, - 0x67, 0x2d, 0x61, 0x63, 0x74, 0x69, 0x6f, 0x6e, - 0x5f, 0x61, 0x72, 0x65, 0x61, 0x31, 0x22, 0x3e, - 0x3c, 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, - 0x79, 0x20, 0x6e, 0x61, 0x6d, 0x65, 0x3d, 0x22, - 0x76, 0x69, 0x73, 0x69, 0x62, 0x6c, 0x65, 0x22, - 0x3e, 0x54, 0x72, 0x75, 0x65, 0x3c, 0x2f, 0x70, - 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, 0x3e, - 0x3c, 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, - 0x79, 0x20, 0x6e, 0x61, 0x6d, 0x65, 0x3d, 0x22, - 0x63, 0x61, 0x6e, 0x5f, 0x66, 0x6f, 0x63, 0x75, - 0x73, 0x22, 0x3e, 0x46, 0x61, 0x6c, 0x73, 0x65, - 0x3c, 0x2f, 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, - 0x74, 0x79, 0x3e, 0x3c, 0x70, 0x72, 0x6f, 0x70, - 0x65, 0x72, 0x74, 0x79, 0x20, 0x6e, 0x61, 0x6d, - 0x65, 0x3d, 0x22, 0x6c, 0x61, 0x79, 0x6f, 0x75, - 0x74, 0x5f, 0x73, 0x74, 0x79, 0x6c, 0x65, 0x22, - 0x3e, 0x65, 0x6e, 0x64, 0x3c, 0x2f, 0x70, 0x72, - 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, 0x3e, 0x3c, - 0x63, 0x68, 0x69, 0x6c, 0x64, 0x3e, 0x3c, 0x6f, - 0x62, 0x6a, 0x65, 0x63, 0x74, 0x20, 0x63, 0x6c, - 0x61, 0x73, 0x73, 0x3d, 0x22, 0x47, 0x74, 0x6b, - 0x42, 0x75, 0x74, 0x74, 0x6f, 0x6e, 0x22, 0x20, - 0x69, 0x64, 0x3d, 0x22, 0x61, 0x75, 0x74, 0x68, - 0x6f, 0x72, 0x69, 0x7a, 0x65, 0x5f, 0x62, 0x75, - 0x74, 0x74, 0x6f, 0x6e, 0x22, 0x3e, 0x3c, 0x70, - 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, 0x20, - 0x6e, 0x61, 0x6d, 0x65, 0x3d, 0x22, 0x6c, 0x61, - 0x62, 0x65, 0x6c, 0x22, 0x20, 0x74, 0x72, 0x61, - 0x6e, 0x73, 0x6c, 0x61, 0x74, 0x61, 0x62, 0x6c, - 0x65, 0x3d, 0x22, 0x79, 0x65, 0x73, 0x22, 0x20, - 0x63, 0x6f, 0x6d, 0x6d, 0x65, 0x6e, 0x74, 0x73, - 0x3d, 0x22, 0x42, 0x75, 0x74, 0x74, 0x6f, 0x6e, - 0x20, 0x74, 0x6f, 0x20, 0x73, 0x75, 0x62, 0x6d, - 0x69, 0x74, 0x20, 0x61, 0x75, 0x74, 0x68, 0x6f, - 0x72, 0x69, 0x7a, 0x61, 0x74, 0x69, 0x6f, 0x6e, - 0x20, 0x64, 0x69, 0x61, 0x6c, 0x6f, 0x67, 0x22, - 0x3e, 0x5f, 0x41, 0x75, 0x74, 0x68, 0x6f, 0x72, - 0x69, 0x7a, 0x65, 0x3c, 0x2f, 0x70, 0x72, 0x6f, - 0x70, 0x65, 0x72, 0x74, 0x79, 0x3e, 0x3c, 0x70, - 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, 0x20, - 0x6e, 0x61, 0x6d, 0x65, 0x3d, 0x22, 0x76, 0x69, - 0x73, 0x69, 0x62, 0x6c, 0x65, 0x22, 0x3e, 0x54, - 0x72, 0x75, 0x65, 0x3c, 0x2f, 0x70, 0x72, 0x6f, - 0x70, 0x65, 0x72, 0x74, 0x79, 0x3e, 0x3c, 0x70, - 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, 0x20, - 0x6e, 0x61, 0x6d, 0x65, 0x3d, 0x22, 0x63, 0x61, - 0x6e, 0x5f, 0x66, 0x6f, 0x63, 0x75, 0x73, 0x22, - 0x3e, 0x54, 0x72, 0x75, 0x65, 0x3c, 0x2f, 0x70, - 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, 0x3e, - 0x3c, 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, - 0x79, 0x20, 0x6e, 0x61, 0x6d, 0x65, 0x3d, 0x22, - 0x72, 0x65, 0x63, 0x65, 0x69, 0x76, 0x65, 0x73, - 0x5f, 0x64, 0x65, 0x66, 0x61, 0x75, 0x6c, 0x74, - 0x22, 0x3e, 0x54, 0x72, 0x75, 0x65, 0x3c, 0x2f, - 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, - 0x3e, 0x3c, 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, - 0x74, 0x79, 0x20, 0x6e, 0x61, 0x6d, 0x65, 0x3d, - 0x22, 0x75, 0x73, 0x65, 0x5f, 0x75, 0x6e, 0x64, - 0x65, 0x72, 0x6c, 0x69, 0x6e, 0x65, 0x22, 0x3e, - 0x54, 0x72, 0x75, 0x65, 0x3c, 0x2f, 0x70, 0x72, - 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, 0x3e, 0x3c, - 0x2f, 0x6f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x3e, - 0x3c, 0x70, 0x61, 0x63, 0x6b, 0x69, 0x6e, 0x67, - 0x3e, 0x3c, 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, - 0x74, 0x79, 0x20, 0x6e, 0x61, 0x6d, 0x65, 0x3d, - 0x22, 0x65, 0x78, 0x70, 0x61, 0x6e, 0x64, 0x22, - 0x3e, 0x46, 0x61, 0x6c, 0x73, 0x65, 0x3c, 0x2f, - 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, - 0x3e, 0x3c, 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, - 0x74, 0x79, 0x20, 0x6e, 0x61, 0x6d, 0x65, 0x3d, - 0x22, 0x66, 0x69, 0x6c, 0x6c, 0x22, 0x3e, 0x46, - 0x61, 0x6c, 0x73, 0x65, 0x3c, 0x2f, 0x70, 0x72, - 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, 0x3e, 0x3c, - 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, - 0x20, 0x6e, 0x61, 0x6d, 0x65, 0x3d, 0x22, 0x70, - 0x6f, 0x73, 0x69, 0x74, 0x69, 0x6f, 0x6e, 0x22, - 0x3e, 0x30, 0x3c, 0x2f, 0x70, 0x72, 0x6f, 0x70, - 0x65, 0x72, 0x74, 0x79, 0x3e, 0x3c, 0x2f, 0x70, - 0x61, 0x63, 0x6b, 0x69, 0x6e, 0x67, 0x3e, 0x3c, - 0x2f, 0x63, 0x68, 0x69, 0x6c, 0x64, 0x3e, 0x3c, - 0x2f, 0x6f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x3e, - 0x3c, 0x70, 0x61, 0x63, 0x6b, 0x69, 0x6e, 0x67, - 0x3e, 0x3c, 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, - 0x74, 0x79, 0x20, 0x6e, 0x61, 0x6d, 0x65, 0x3d, - 0x22, 0x65, 0x78, 0x70, 0x61, 0x6e, 0x64, 0x22, - 0x3e, 0x46, 0x61, 0x6c, 0x73, 0x65, 0x3c, 0x2f, - 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, - 0x3e, 0x3c, 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, - 0x74, 0x79, 0x20, 0x6e, 0x61, 0x6d, 0x65, 0x3d, - 0x22, 0x66, 0x69, 0x6c, 0x6c, 0x22, 0x3e, 0x54, - 0x72, 0x75, 0x65, 0x3c, 0x2f, 0x70, 0x72, 0x6f, - 0x70, 0x65, 0x72, 0x74, 0x79, 0x3e, 0x3c, 0x70, - 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, 0x20, - 0x6e, 0x61, 0x6d, 0x65, 0x3d, 0x22, 0x70, 0x61, - 0x63, 0x6b, 0x5f, 0x74, 0x79, 0x70, 0x65, 0x22, - 0x3e, 0x65, 0x6e, 0x64, 0x3c, 0x2f, 0x70, 0x72, - 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, 0x3e, 0x3c, - 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, - 0x20, 0x6e, 0x61, 0x6d, 0x65, 0x3d, 0x22, 0x70, - 0x6f, 0x73, 0x69, 0x74, 0x69, 0x6f, 0x6e, 0x22, - 0x3e, 0x30, 0x3c, 0x2f, 0x70, 0x72, 0x6f, 0x70, - 0x65, 0x72, 0x74, 0x79, 0x3e, 0x3c, 0x2f, 0x70, - 0x61, 0x63, 0x6b, 0x69, 0x6e, 0x67, 0x3e, 0x3c, - 0x2f, 0x63, 0x68, 0x69, 0x6c, 0x64, 0x3e, 0x3c, - 0x63, 0x68, 0x69, 0x6c, 0x64, 0x3e, 0x3c, 0x6f, - 0x62, 0x6a, 0x65, 0x63, 0x74, 0x20, 0x63, 0x6c, - 0x61, 0x73, 0x73, 0x3d, 0x22, 0x47, 0x74, 0x6b, - 0x42, 0x6f, 0x78, 0x22, 0x20, 0x69, 0x64, 0x3d, - 0x22, 0x76, 0x62, 0x6f, 0x78, 0x35, 0x22, 0x3e, - 0x3c, 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, - 0x79, 0x20, 0x6e, 0x61, 0x6d, 0x65, 0x3d, 0x22, - 0x76, 0x69, 0x73, 0x69, 0x62, 0x6c, 0x65, 0x22, - 0x3e, 0x54, 0x72, 0x75, 0x65, 0x3c, 0x2f, 0x70, - 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, 0x3e, - 0x3c, 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, - 0x79, 0x20, 0x6e, 0x61, 0x6d, 0x65, 0x3d, 0x22, - 0x63, 0x61, 0x6e, 0x5f, 0x66, 0x6f, 0x63, 0x75, - 0x73, 0x22, 0x3e, 0x46, 0x61, 0x6c, 0x73, 0x65, - 0x3c, 0x2f, 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, - 0x74, 0x79, 0x3e, 0x3c, 0x70, 0x72, 0x6f, 0x70, - 0x65, 0x72, 0x74, 0x79, 0x20, 0x6e, 0x61, 0x6d, - 0x65, 0x3d, 0x22, 0x62, 0x6f, 0x72, 0x64, 0x65, - 0x72, 0x5f, 0x77, 0x69, 0x64, 0x74, 0x68, 0x22, - 0x3e, 0x35, 0x3c, 0x2f, 0x70, 0x72, 0x6f, 0x70, - 0x65, 0x72, 0x74, 0x79, 0x3e, 0x3c, 0x70, 0x72, - 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, 0x20, 0x6e, - 0x61, 0x6d, 0x65, 0x3d, 0x22, 0x6f, 0x72, 0x69, - 0x65, 0x6e, 0x74, 0x61, 0x74, 0x69, 0x6f, 0x6e, - 0x22, 0x3e, 0x76, 0x65, 0x72, 0x74, 0x69, 0x63, - 0x61, 0x6c, 0x3c, 0x2f, 0x70, 0x72, 0x6f, 0x70, - 0x65, 0x72, 0x74, 0x79, 0x3e, 0x3c, 0x70, 0x72, - 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, 0x20, 0x6e, - 0x61, 0x6d, 0x65, 0x3d, 0x22, 0x73, 0x70, 0x61, - 0x63, 0x69, 0x6e, 0x67, 0x22, 0x3e, 0x31, 0x32, - 0x3c, 0x2f, 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, - 0x74, 0x79, 0x3e, 0x3c, 0x63, 0x68, 0x69, 0x6c, - 0x64, 0x3e, 0x3c, 0x6f, 0x62, 0x6a, 0x65, 0x63, - 0x74, 0x20, 0x63, 0x6c, 0x61, 0x73, 0x73, 0x3d, - 0x22, 0x47, 0x74, 0x6b, 0x4c, 0x61, 0x62, 0x65, - 0x6c, 0x22, 0x20, 0x69, 0x64, 0x3d, 0x22, 0x61, - 0x75, 0x74, 0x68, 0x6f, 0x72, 0x69, 0x7a, 0x65, - 0x5f, 0x6c, 0x61, 0x62, 0x65, 0x6c, 0x22, 0x3e, - 0x3c, 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, - 0x79, 0x20, 0x6e, 0x61, 0x6d, 0x65, 0x3d, 0x22, - 0x76, 0x69, 0x73, 0x69, 0x62, 0x6c, 0x65, 0x22, - 0x3e, 0x54, 0x72, 0x75, 0x65, 0x3c, 0x2f, 0x70, - 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, 0x3e, - 0x3c, 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, - 0x79, 0x20, 0x6e, 0x61, 0x6d, 0x65, 0x3d, 0x22, - 0x63, 0x61, 0x6e, 0x5f, 0x66, 0x6f, 0x63, 0x75, - 0x73, 0x22, 0x3e, 0x46, 0x61, 0x6c, 0x73, 0x65, - 0x3c, 0x2f, 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, - 0x74, 0x79, 0x3e, 0x3c, 0x70, 0x72, 0x6f, 0x70, - 0x65, 0x72, 0x74, 0x79, 0x20, 0x6e, 0x61, 0x6d, - 0x65, 0x3d, 0x22, 0x6c, 0x61, 0x62, 0x65, 0x6c, - 0x22, 0x20, 0x63, 0x6f, 0x6d, 0x6d, 0x65, 0x6e, - 0x74, 0x73, 0x3d, 0x22, 0x54, 0x68, 0x69, 0x73, - 0x20, 0x6c, 0x61, 0x62, 0x65, 0x6c, 0x20, 0x69, - 0x73, 0x20, 0x73, 0x65, 0x74, 0x20, 0x64, 0x79, - 0x6e, 0x61, 0x6d, 0x69, 0x63, 0x61, 0x6c, 0x6c, - 0x79, 0x20, 0x61, 0x6e, 0x64, 0x20, 0x69, 0x73, - 0x20, 0x6e, 0x6f, 0x74, 0x20, 0x74, 0x72, 0x61, - 0x6e, 0x73, 0x6c, 0x61, 0x74, 0x65, 0x64, 0x22, - 0x3e, 0x54, 0x6f, 0x20, 0x63, 0x6f, 0x6e, 0x6e, - 0x65, 0x63, 0x74, 0x20, 0x74, 0x6f, 0x20, 0x3f, - 0x20, 0x79, 0x6f, 0x75, 0x20, 0x6e, 0x65, 0x65, - 0x64, 0x20, 0x74, 0x6f, 0x20, 0x61, 0x75, 0x74, - 0x68, 0x6f, 0x72, 0x69, 0x7a, 0x65, 0x3c, 0x2f, - 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, - 0x3e, 0x3c, 0x2f, 0x6f, 0x62, 0x6a, 0x65, 0x63, - 0x74, 0x3e, 0x3c, 0x70, 0x61, 0x63, 0x6b, 0x69, - 0x6e, 0x67, 0x3e, 0x3c, 0x70, 0x72, 0x6f, 0x70, - 0x65, 0x72, 0x74, 0x79, 0x20, 0x6e, 0x61, 0x6d, - 0x65, 0x3d, 0x22, 0x65, 0x78, 0x70, 0x61, 0x6e, - 0x64, 0x22, 0x3e, 0x54, 0x72, 0x75, 0x65, 0x3c, - 0x2f, 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, - 0x79, 0x3e, 0x3c, 0x70, 0x72, 0x6f, 0x70, 0x65, - 0x72, 0x74, 0x79, 0x20, 0x6e, 0x61, 0x6d, 0x65, - 0x3d, 0x22, 0x66, 0x69, 0x6c, 0x6c, 0x22, 0x3e, - 0x54, 0x72, 0x75, 0x65, 0x3c, 0x2f, 0x70, 0x72, - 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, 0x3e, 0x3c, - 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, - 0x20, 0x6e, 0x61, 0x6d, 0x65, 0x3d, 0x22, 0x70, - 0x6f, 0x73, 0x69, 0x74, 0x69, 0x6f, 0x6e, 0x22, - 0x3e, 0x30, 0x3c, 0x2f, 0x70, 0x72, 0x6f, 0x70, - 0x65, 0x72, 0x74, 0x79, 0x3e, 0x3c, 0x2f, 0x70, - 0x61, 0x63, 0x6b, 0x69, 0x6e, 0x67, 0x3e, 0x3c, - 0x2f, 0x63, 0x68, 0x69, 0x6c, 0x64, 0x3e, 0x3c, - 0x63, 0x68, 0x69, 0x6c, 0x64, 0x3e, 0x3c, 0x6f, - 0x62, 0x6a, 0x65, 0x63, 0x74, 0x20, 0x63, 0x6c, - 0x61, 0x73, 0x73, 0x3d, 0x22, 0x47, 0x74, 0x6b, - 0x47, 0x72, 0x69, 0x64, 0x22, 0x20, 0x69, 0x64, - 0x3d, 0x22, 0x67, 0x72, 0x69, 0x64, 0x32, 0x22, - 0x3e, 0x3c, 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, - 0x74, 0x79, 0x20, 0x6e, 0x61, 0x6d, 0x65, 0x3d, - 0x22, 0x76, 0x69, 0x73, 0x69, 0x62, 0x6c, 0x65, - 0x22, 0x3e, 0x54, 0x72, 0x75, 0x65, 0x3c, 0x2f, - 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, - 0x3e, 0x3c, 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, - 0x74, 0x79, 0x20, 0x6e, 0x61, 0x6d, 0x65, 0x3d, - 0x22, 0x63, 0x61, 0x6e, 0x5f, 0x66, 0x6f, 0x63, - 0x75, 0x73, 0x22, 0x3e, 0x46, 0x61, 0x6c, 0x73, - 0x65, 0x3c, 0x2f, 0x70, 0x72, 0x6f, 0x70, 0x65, - 0x72, 0x74, 0x79, 0x3e, 0x3c, 0x70, 0x72, 0x6f, - 0x70, 0x65, 0x72, 0x74, 0x79, 0x20, 0x6e, 0x61, - 0x6d, 0x65, 0x3d, 0x22, 0x72, 0x6f, 0x77, 0x5f, - 0x73, 0x70, 0x61, 0x63, 0x69, 0x6e, 0x67, 0x22, - 0x3e, 0x36, 0x3c, 0x2f, 0x70, 0x72, 0x6f, 0x70, - 0x65, 0x72, 0x74, 0x79, 0x3e, 0x3c, 0x70, 0x72, - 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, 0x20, 0x6e, - 0x61, 0x6d, 0x65, 0x3d, 0x22, 0x63, 0x6f, 0x6c, - 0x75, 0x6d, 0x6e, 0x5f, 0x73, 0x70, 0x61, 0x63, - 0x69, 0x6e, 0x67, 0x22, 0x3e, 0x36, 0x3c, 0x2f, - 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, - 0x3e, 0x3c, 0x63, 0x68, 0x69, 0x6c, 0x64, 0x3e, - 0x3c, 0x6f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x20, - 0x63, 0x6c, 0x61, 0x73, 0x73, 0x3d, 0x22, 0x47, - 0x74, 0x6b, 0x45, 0x6e, 0x74, 0x72, 0x79, 0x22, - 0x20, 0x69, 0x64, 0x3d, 0x22, 0x75, 0x73, 0x65, - 0x72, 0x6e, 0x61, 0x6d, 0x65, 0x5f, 0x65, 0x6e, - 0x74, 0x72, 0x79, 0x22, 0x3e, 0x3c, 0x70, 0x72, - 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, 0x20, 0x6e, - 0x61, 0x6d, 0x65, 0x3d, 0x22, 0x76, 0x69, 0x73, - 0x69, 0x62, 0x6c, 0x65, 0x22, 0x3e, 0x54, 0x72, - 0x75, 0x65, 0x3c, 0x2f, 0x70, 0x72, 0x6f, 0x70, - 0x65, 0x72, 0x74, 0x79, 0x3e, 0x3c, 0x70, 0x72, - 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, 0x20, 0x6e, - 0x61, 0x6d, 0x65, 0x3d, 0x22, 0x63, 0x61, 0x6e, - 0x5f, 0x66, 0x6f, 0x63, 0x75, 0x73, 0x22, 0x3e, - 0x54, 0x72, 0x75, 0x65, 0x3c, 0x2f, 0x70, 0x72, - 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, 0x3e, 0x3c, - 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, - 0x20, 0x6e, 0x61, 0x6d, 0x65, 0x3d, 0x22, 0x68, - 0x65, 0x78, 0x70, 0x61, 0x6e, 0x64, 0x22, 0x3e, - 0x54, 0x72, 0x75, 0x65, 0x3c, 0x2f, 0x70, 0x72, - 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, 0x3e, 0x3c, - 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, - 0x20, 0x6e, 0x61, 0x6d, 0x65, 0x3d, 0x22, 0x69, - 0x6e, 0x76, 0x69, 0x73, 0x69, 0x62, 0x6c, 0x65, - 0x5f, 0x63, 0x68, 0x61, 0x72, 0x22, 0x3e, 0xe2, - 0x97, 0x8f, 0x3c, 0x2f, 0x70, 0x72, 0x6f, 0x70, - 0x65, 0x72, 0x74, 0x79, 0x3e, 0x3c, 0x2f, 0x6f, - 0x62, 0x6a, 0x65, 0x63, 0x74, 0x3e, 0x3c, 0x70, - 0x61, 0x63, 0x6b, 0x69, 0x6e, 0x67, 0x3e, 0x3c, - 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, - 0x20, 0x6e, 0x61, 0x6d, 0x65, 0x3d, 0x22, 0x6c, - 0x65, 0x66, 0x74, 0x5f, 0x61, 0x74, 0x74, 0x61, - 0x63, 0x68, 0x22, 0x3e, 0x31, 0x3c, 0x2f, 0x70, - 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, 0x3e, - 0x3c, 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, - 0x79, 0x20, 0x6e, 0x61, 0x6d, 0x65, 0x3d, 0x22, - 0x74, 0x6f, 0x70, 0x5f, 0x61, 0x74, 0x74, 0x61, - 0x63, 0x68, 0x22, 0x3e, 0x30, 0x3c, 0x2f, 0x70, - 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, 0x3e, - 0x3c, 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, - 0x79, 0x20, 0x6e, 0x61, 0x6d, 0x65, 0x3d, 0x22, - 0x77, 0x69, 0x64, 0x74, 0x68, 0x22, 0x3e, 0x31, - 0x3c, 0x2f, 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, - 0x74, 0x79, 0x3e, 0x3c, 0x70, 0x72, 0x6f, 0x70, - 0x65, 0x72, 0x74, 0x79, 0x20, 0x6e, 0x61, 0x6d, - 0x65, 0x3d, 0x22, 0x68, 0x65, 0x69, 0x67, 0x68, - 0x74, 0x22, 0x3e, 0x31, 0x3c, 0x2f, 0x70, 0x72, - 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, 0x3e, 0x3c, - 0x2f, 0x70, 0x61, 0x63, 0x6b, 0x69, 0x6e, 0x67, - 0x3e, 0x3c, 0x2f, 0x63, 0x68, 0x69, 0x6c, 0x64, - 0x3e, 0x3c, 0x63, 0x68, 0x69, 0x6c, 0x64, 0x3e, - 0x3c, 0x6f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x20, - 0x63, 0x6c, 0x61, 0x73, 0x73, 0x3d, 0x22, 0x47, - 0x74, 0x6b, 0x45, 0x6e, 0x74, 0x72, 0x79, 0x22, - 0x20, 0x69, 0x64, 0x3d, 0x22, 0x70, 0x61, 0x73, - 0x73, 0x77, 0x6f, 0x72, 0x64, 0x5f, 0x65, 0x6e, - 0x74, 0x72, 0x79, 0x22, 0x3e, 0x3c, 0x70, 0x72, - 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, 0x20, 0x6e, - 0x61, 0x6d, 0x65, 0x3d, 0x22, 0x76, 0x69, 0x73, - 0x69, 0x62, 0x6c, 0x65, 0x22, 0x3e, 0x54, 0x72, - 0x75, 0x65, 0x3c, 0x2f, 0x70, 0x72, 0x6f, 0x70, - 0x65, 0x72, 0x74, 0x79, 0x3e, 0x3c, 0x70, 0x72, - 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, 0x20, 0x6e, - 0x61, 0x6d, 0x65, 0x3d, 0x22, 0x63, 0x61, 0x6e, - 0x5f, 0x66, 0x6f, 0x63, 0x75, 0x73, 0x22, 0x3e, - 0x54, 0x72, 0x75, 0x65, 0x3c, 0x2f, 0x70, 0x72, - 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, 0x3e, 0x3c, - 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, - 0x20, 0x6e, 0x61, 0x6d, 0x65, 0x3d, 0x22, 0x68, - 0x65, 0x78, 0x70, 0x61, 0x6e, 0x64, 0x22, 0x3e, - 0x54, 0x72, 0x75, 0x65, 0x3c, 0x2f, 0x70, 0x72, - 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, 0x3e, 0x3c, - 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, - 0x20, 0x6e, 0x61, 0x6d, 0x65, 0x3d, 0x22, 0x76, - 0x69, 0x73, 0x69, 0x62, 0x69, 0x6c, 0x69, 0x74, - 0x79, 0x22, 0x3e, 0x46, 0x61, 0x6c, 0x73, 0x65, - 0x3c, 0x2f, 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, - 0x74, 0x79, 0x3e, 0x3c, 0x70, 0x72, 0x6f, 0x70, - 0x65, 0x72, 0x74, 0x79, 0x20, 0x6e, 0x61, 0x6d, - 0x65, 0x3d, 0x22, 0x69, 0x6e, 0x76, 0x69, 0x73, - 0x69, 0x62, 0x6c, 0x65, 0x5f, 0x63, 0x68, 0x61, - 0x72, 0x22, 0x3e, 0xe2, 0x97, 0x8f, 0x3c, 0x2f, - 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, - 0x3e, 0x3c, 0x2f, 0x6f, 0x62, 0x6a, 0x65, 0x63, - 0x74, 0x3e, 0x3c, 0x70, 0x61, 0x63, 0x6b, 0x69, - 0x6e, 0x67, 0x3e, 0x3c, 0x70, 0x72, 0x6f, 0x70, - 0x65, 0x72, 0x74, 0x79, 0x20, 0x6e, 0x61, 0x6d, - 0x65, 0x3d, 0x22, 0x6c, 0x65, 0x66, 0x74, 0x5f, - 0x61, 0x74, 0x74, 0x61, 0x63, 0x68, 0x22, 0x3e, - 0x31, 0x3c, 0x2f, 0x70, 0x72, 0x6f, 0x70, 0x65, - 0x72, 0x74, 0x79, 0x3e, 0x3c, 0x70, 0x72, 0x6f, - 0x70, 0x65, 0x72, 0x74, 0x79, 0x20, 0x6e, 0x61, - 0x6d, 0x65, 0x3d, 0x22, 0x74, 0x6f, 0x70, 0x5f, - 0x61, 0x74, 0x74, 0x61, 0x63, 0x68, 0x22, 0x3e, - 0x31, 0x3c, 0x2f, 0x70, 0x72, 0x6f, 0x70, 0x65, - 0x72, 0x74, 0x79, 0x3e, 0x3c, 0x70, 0x72, 0x6f, - 0x70, 0x65, 0x72, 0x74, 0x79, 0x20, 0x6e, 0x61, - 0x6d, 0x65, 0x3d, 0x22, 0x77, 0x69, 0x64, 0x74, - 0x68, 0x22, 0x3e, 0x31, 0x3c, 0x2f, 0x70, 0x72, - 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, 0x3e, 0x3c, - 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, - 0x20, 0x6e, 0x61, 0x6d, 0x65, 0x3d, 0x22, 0x68, - 0x65, 0x69, 0x67, 0x68, 0x74, 0x22, 0x3e, 0x31, - 0x3c, 0x2f, 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, - 0x74, 0x79, 0x3e, 0x3c, 0x2f, 0x70, 0x61, 0x63, - 0x6b, 0x69, 0x6e, 0x67, 0x3e, 0x3c, 0x2f, 0x63, - 0x68, 0x69, 0x6c, 0x64, 0x3e, 0x3c, 0x63, 0x68, - 0x69, 0x6c, 0x64, 0x3e, 0x3c, 0x6f, 0x62, 0x6a, - 0x65, 0x63, 0x74, 0x20, 0x63, 0x6c, 0x61, 0x73, - 0x73, 0x3d, 0x22, 0x47, 0x74, 0x6b, 0x4c, 0x61, - 0x62, 0x65, 0x6c, 0x22, 0x20, 0x69, 0x64, 0x3d, - 0x22, 0x75, 0x73, 0x65, 0x72, 0x6e, 0x61, 0x6d, - 0x65, 0x5f, 0x6c, 0x61, 0x62, 0x65, 0x6c, 0x22, - 0x3e, 0x3c, 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, - 0x74, 0x79, 0x20, 0x6e, 0x61, 0x6d, 0x65, 0x3d, - 0x22, 0x76, 0x69, 0x73, 0x69, 0x62, 0x6c, 0x65, - 0x22, 0x3e, 0x54, 0x72, 0x75, 0x65, 0x3c, 0x2f, - 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, - 0x3e, 0x3c, 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, - 0x74, 0x79, 0x20, 0x6e, 0x61, 0x6d, 0x65, 0x3d, - 0x22, 0x63, 0x61, 0x6e, 0x5f, 0x66, 0x6f, 0x63, - 0x75, 0x73, 0x22, 0x3e, 0x46, 0x61, 0x6c, 0x73, - 0x65, 0x3c, 0x2f, 0x70, 0x72, 0x6f, 0x70, 0x65, - 0x72, 0x74, 0x79, 0x3e, 0x3c, 0x70, 0x72, 0x6f, - 0x70, 0x65, 0x72, 0x74, 0x79, 0x20, 0x6e, 0x61, - 0x6d, 0x65, 0x3d, 0x22, 0x6c, 0x61, 0x62, 0x65, - 0x6c, 0x22, 0x20, 0x74, 0x72, 0x61, 0x6e, 0x73, - 0x6c, 0x61, 0x74, 0x61, 0x62, 0x6c, 0x65, 0x3d, - 0x22, 0x79, 0x65, 0x73, 0x22, 0x20, 0x63, 0x6f, - 0x6d, 0x6d, 0x65, 0x6e, 0x74, 0x73, 0x3d, 0x22, - 0x4c, 0x61, 0x62, 0x65, 0x6c, 0x20, 0x62, 0x65, - 0x73, 0x69, 0x64, 0x65, 0x20, 0x75, 0x73, 0x65, - 0x72, 0x6e, 0x61, 0x6d, 0x65, 0x20, 0x65, 0x6e, - 0x74, 0x72, 0x79, 0x22, 0x3e, 0x5f, 0x55, 0x73, - 0x65, 0x72, 0x6e, 0x61, 0x6d, 0x65, 0x20, 0x66, - 0x6f, 0x72, 0x20, 0x72, 0x65, 0x73, 0x6f, 0x75, - 0x72, 0x63, 0x65, 0x3a, 0x3c, 0x2f, 0x70, 0x72, - 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, 0x3e, 0x3c, - 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, - 0x20, 0x6e, 0x61, 0x6d, 0x65, 0x3d, 0x22, 0x75, - 0x73, 0x65, 0x5f, 0x75, 0x6e, 0x64, 0x65, 0x72, - 0x6c, 0x69, 0x6e, 0x65, 0x22, 0x3e, 0x54, 0x72, - 0x75, 0x65, 0x3c, 0x2f, 0x70, 0x72, 0x6f, 0x70, - 0x65, 0x72, 0x74, 0x79, 0x3e, 0x3c, 0x70, 0x72, - 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, 0x20, 0x6e, - 0x61, 0x6d, 0x65, 0x3d, 0x22, 0x6d, 0x6e, 0x65, - 0x6d, 0x6f, 0x6e, 0x69, 0x63, 0x5f, 0x77, 0x69, - 0x64, 0x67, 0x65, 0x74, 0x22, 0x3e, 0x75, 0x73, - 0x65, 0x72, 0x6e, 0x61, 0x6d, 0x65, 0x5f, 0x65, - 0x6e, 0x74, 0x72, 0x79, 0x3c, 0x2f, 0x70, 0x72, - 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, 0x3e, 0x3c, - 0x2f, 0x6f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x3e, - 0x3c, 0x70, 0x61, 0x63, 0x6b, 0x69, 0x6e, 0x67, - 0x3e, 0x3c, 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, - 0x74, 0x79, 0x20, 0x6e, 0x61, 0x6d, 0x65, 0x3d, - 0x22, 0x6c, 0x65, 0x66, 0x74, 0x5f, 0x61, 0x74, - 0x74, 0x61, 0x63, 0x68, 0x22, 0x3e, 0x30, 0x3c, - 0x2f, 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, - 0x79, 0x3e, 0x3c, 0x70, 0x72, 0x6f, 0x70, 0x65, - 0x72, 0x74, 0x79, 0x20, 0x6e, 0x61, 0x6d, 0x65, - 0x3d, 0x22, 0x74, 0x6f, 0x70, 0x5f, 0x61, 0x74, - 0x74, 0x61, 0x63, 0x68, 0x22, 0x3e, 0x30, 0x3c, - 0x2f, 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, - 0x79, 0x3e, 0x3c, 0x70, 0x72, 0x6f, 0x70, 0x65, - 0x72, 0x74, 0x79, 0x20, 0x6e, 0x61, 0x6d, 0x65, - 0x3d, 0x22, 0x77, 0x69, 0x64, 0x74, 0x68, 0x22, - 0x3e, 0x31, 0x3c, 0x2f, 0x70, 0x72, 0x6f, 0x70, - 0x65, 0x72, 0x74, 0x79, 0x3e, 0x3c, 0x70, 0x72, - 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, 0x20, 0x6e, - 0x61, 0x6d, 0x65, 0x3d, 0x22, 0x68, 0x65, 0x69, - 0x67, 0x68, 0x74, 0x22, 0x3e, 0x31, 0x3c, 0x2f, - 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, - 0x3e, 0x3c, 0x2f, 0x70, 0x61, 0x63, 0x6b, 0x69, - 0x6e, 0x67, 0x3e, 0x3c, 0x2f, 0x63, 0x68, 0x69, - 0x6c, 0x64, 0x3e, 0x3c, 0x63, 0x68, 0x69, 0x6c, - 0x64, 0x3e, 0x3c, 0x6f, 0x62, 0x6a, 0x65, 0x63, - 0x74, 0x20, 0x63, 0x6c, 0x61, 0x73, 0x73, 0x3d, - 0x22, 0x47, 0x74, 0x6b, 0x4c, 0x61, 0x62, 0x65, - 0x6c, 0x22, 0x20, 0x69, 0x64, 0x3d, 0x22, 0x70, - 0x61, 0x73, 0x73, 0x77, 0x6f, 0x72, 0x64, 0x5f, - 0x6c, 0x61, 0x62, 0x65, 0x6c, 0x22, 0x3e, 0x3c, - 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, - 0x20, 0x6e, 0x61, 0x6d, 0x65, 0x3d, 0x22, 0x76, - 0x69, 0x73, 0x69, 0x62, 0x6c, 0x65, 0x22, 0x3e, - 0x54, 0x72, 0x75, 0x65, 0x3c, 0x2f, 0x70, 0x72, - 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, 0x3e, 0x3c, - 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, - 0x20, 0x6e, 0x61, 0x6d, 0x65, 0x3d, 0x22, 0x63, - 0x61, 0x6e, 0x5f, 0x66, 0x6f, 0x63, 0x75, 0x73, - 0x22, 0x3e, 0x46, 0x61, 0x6c, 0x73, 0x65, 0x3c, - 0x2f, 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, - 0x79, 0x3e, 0x3c, 0x70, 0x72, 0x6f, 0x70, 0x65, - 0x72, 0x74, 0x79, 0x20, 0x6e, 0x61, 0x6d, 0x65, - 0x3d, 0x22, 0x6c, 0x61, 0x62, 0x65, 0x6c, 0x22, - 0x20, 0x74, 0x72, 0x61, 0x6e, 0x73, 0x6c, 0x61, - 0x74, 0x61, 0x62, 0x6c, 0x65, 0x3d, 0x22, 0x79, - 0x65, 0x73, 0x22, 0x20, 0x63, 0x6f, 0x6d, 0x6d, - 0x65, 0x6e, 0x74, 0x73, 0x3d, 0x22, 0x4c, 0x61, - 0x62, 0x65, 0x6c, 0x20, 0x62, 0x65, 0x73, 0x69, - 0x64, 0x65, 0x20, 0x70, 0x61, 0x73, 0x73, 0x77, - 0x6f, 0x72, 0x64, 0x20, 0x65, 0x6e, 0x74, 0x72, - 0x79, 0x22, 0x3e, 0x5f, 0x50, 0x61, 0x73, 0x73, - 0x77, 0x6f, 0x72, 0x64, 0x3a, 0x3c, 0x2f, 0x70, - 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, 0x3e, - 0x3c, 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, - 0x79, 0x20, 0x6e, 0x61, 0x6d, 0x65, 0x3d, 0x22, - 0x75, 0x73, 0x65, 0x5f, 0x75, 0x6e, 0x64, 0x65, - 0x72, 0x6c, 0x69, 0x6e, 0x65, 0x22, 0x3e, 0x54, - 0x72, 0x75, 0x65, 0x3c, 0x2f, 0x70, 0x72, 0x6f, - 0x70, 0x65, 0x72, 0x74, 0x79, 0x3e, 0x3c, 0x70, - 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, 0x20, - 0x6e, 0x61, 0x6d, 0x65, 0x3d, 0x22, 0x6d, 0x6e, - 0x65, 0x6d, 0x6f, 0x6e, 0x69, 0x63, 0x5f, 0x77, - 0x69, 0x64, 0x67, 0x65, 0x74, 0x22, 0x3e, 0x70, - 0x61, 0x73, 0x73, 0x77, 0x6f, 0x72, 0x64, 0x5f, - 0x65, 0x6e, 0x74, 0x72, 0x79, 0x3c, 0x2f, 0x70, - 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, 0x3e, - 0x3c, 0x2f, 0x6f, 0x62, 0x6a, 0x65, 0x63, 0x74, - 0x3e, 0x3c, 0x70, 0x61, 0x63, 0x6b, 0x69, 0x6e, - 0x67, 0x3e, 0x3c, 0x70, 0x72, 0x6f, 0x70, 0x65, - 0x72, 0x74, 0x79, 0x20, 0x6e, 0x61, 0x6d, 0x65, - 0x3d, 0x22, 0x6c, 0x65, 0x66, 0x74, 0x5f, 0x61, - 0x74, 0x74, 0x61, 0x63, 0x68, 0x22, 0x3e, 0x30, - 0x3c, 0x2f, 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, - 0x74, 0x79, 0x3e, 0x3c, 0x70, 0x72, 0x6f, 0x70, - 0x65, 0x72, 0x74, 0x79, 0x20, 0x6e, 0x61, 0x6d, - 0x65, 0x3d, 0x22, 0x74, 0x6f, 0x70, 0x5f, 0x61, - 0x74, 0x74, 0x61, 0x63, 0x68, 0x22, 0x3e, 0x31, - 0x3c, 0x2f, 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, - 0x74, 0x79, 0x3e, 0x3c, 0x70, 0x72, 0x6f, 0x70, - 0x65, 0x72, 0x74, 0x79, 0x20, 0x6e, 0x61, 0x6d, - 0x65, 0x3d, 0x22, 0x77, 0x69, 0x64, 0x74, 0x68, - 0x22, 0x3e, 0x31, 0x3c, 0x2f, 0x70, 0x72, 0x6f, - 0x70, 0x65, 0x72, 0x74, 0x79, 0x3e, 0x3c, 0x70, - 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, 0x20, - 0x6e, 0x61, 0x6d, 0x65, 0x3d, 0x22, 0x68, 0x65, - 0x69, 0x67, 0x68, 0x74, 0x22, 0x3e, 0x31, 0x3c, - 0x2f, 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, - 0x79, 0x3e, 0x3c, 0x2f, 0x70, 0x61, 0x63, 0x6b, - 0x69, 0x6e, 0x67, 0x3e, 0x3c, 0x2f, 0x63, 0x68, - 0x69, 0x6c, 0x64, 0x3e, 0x3c, 0x2f, 0x6f, 0x62, - 0x6a, 0x65, 0x63, 0x74, 0x3e, 0x3c, 0x70, 0x61, - 0x63, 0x6b, 0x69, 0x6e, 0x67, 0x3e, 0x3c, 0x70, - 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, 0x20, - 0x6e, 0x61, 0x6d, 0x65, 0x3d, 0x22, 0x65, 0x78, - 0x70, 0x61, 0x6e, 0x64, 0x22, 0x3e, 0x46, 0x61, - 0x6c, 0x73, 0x65, 0x3c, 0x2f, 0x70, 0x72, 0x6f, - 0x70, 0x65, 0x72, 0x74, 0x79, 0x3e, 0x3c, 0x70, - 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, 0x20, - 0x6e, 0x61, 0x6d, 0x65, 0x3d, 0x22, 0x66, 0x69, - 0x6c, 0x6c, 0x22, 0x3e, 0x54, 0x72, 0x75, 0x65, - 0x3c, 0x2f, 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, - 0x74, 0x79, 0x3e, 0x3c, 0x70, 0x72, 0x6f, 0x70, - 0x65, 0x72, 0x74, 0x79, 0x20, 0x6e, 0x61, 0x6d, - 0x65, 0x3d, 0x22, 0x70, 0x6f, 0x73, 0x69, 0x74, - 0x69, 0x6f, 0x6e, 0x22, 0x3e, 0x31, 0x3c, 0x2f, - 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, - 0x3e, 0x3c, 0x2f, 0x70, 0x61, 0x63, 0x6b, 0x69, - 0x6e, 0x67, 0x3e, 0x3c, 0x2f, 0x63, 0x68, 0x69, - 0x6c, 0x64, 0x3e, 0x3c, 0x2f, 0x6f, 0x62, 0x6a, - 0x65, 0x63, 0x74, 0x3e, 0x3c, 0x70, 0x61, 0x63, - 0x6b, 0x69, 0x6e, 0x67, 0x3e, 0x3c, 0x70, 0x72, - 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, 0x20, 0x6e, - 0x61, 0x6d, 0x65, 0x3d, 0x22, 0x65, 0x78, 0x70, - 0x61, 0x6e, 0x64, 0x22, 0x3e, 0x46, 0x61, 0x6c, - 0x73, 0x65, 0x3c, 0x2f, 0x70, 0x72, 0x6f, 0x70, - 0x65, 0x72, 0x74, 0x79, 0x3e, 0x3c, 0x70, 0x72, - 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, 0x20, 0x6e, - 0x61, 0x6d, 0x65, 0x3d, 0x22, 0x66, 0x69, 0x6c, - 0x6c, 0x22, 0x3e, 0x54, 0x72, 0x75, 0x65, 0x3c, - 0x2f, 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, - 0x79, 0x3e, 0x3c, 0x70, 0x72, 0x6f, 0x70, 0x65, - 0x72, 0x74, 0x79, 0x20, 0x6e, 0x61, 0x6d, 0x65, - 0x3d, 0x22, 0x70, 0x6f, 0x73, 0x69, 0x74, 0x69, - 0x6f, 0x6e, 0x22, 0x3e, 0x31, 0x3c, 0x2f, 0x70, - 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, 0x3e, - 0x3c, 0x2f, 0x70, 0x61, 0x63, 0x6b, 0x69, 0x6e, - 0x67, 0x3e, 0x3c, 0x2f, 0x63, 0x68, 0x69, 0x6c, - 0x64, 0x3e, 0x3c, 0x2f, 0x6f, 0x62, 0x6a, 0x65, - 0x63, 0x74, 0x3e, 0x3c, 0x2f, 0x63, 0x68, 0x69, - 0x6c, 0x64, 0x3e, 0x3c, 0x61, 0x63, 0x74, 0x69, - 0x6f, 0x6e, 0x2d, 0x77, 0x69, 0x64, 0x67, 0x65, - 0x74, 0x73, 0x3e, 0x3c, 0x61, 0x63, 0x74, 0x69, - 0x6f, 0x6e, 0x2d, 0x77, 0x69, 0x64, 0x67, 0x65, - 0x74, 0x20, 0x72, 0x65, 0x73, 0x70, 0x6f, 0x6e, - 0x73, 0x65, 0x3d, 0x22, 0x30, 0x22, 0x3e, 0x61, - 0x75, 0x74, 0x68, 0x6f, 0x72, 0x69, 0x7a, 0x65, - 0x5f, 0x62, 0x75, 0x74, 0x74, 0x6f, 0x6e, 0x3c, - 0x2f, 0x61, 0x63, 0x74, 0x69, 0x6f, 0x6e, 0x2d, - 0x77, 0x69, 0x64, 0x67, 0x65, 0x74, 0x3e, 0x3c, - 0x2f, 0x61, 0x63, 0x74, 0x69, 0x6f, 0x6e, 0x2d, - 0x77, 0x69, 0x64, 0x67, 0x65, 0x74, 0x73, 0x3e, - 0x3c, 0x2f, 0x6f, 0x62, 0x6a, 0x65, 0x63, 0x74, - 0x3e, 0x3c, 0x6f, 0x62, 0x6a, 0x65, 0x63, 0x74, - 0x20, 0x63, 0x6c, 0x61, 0x73, 0x73, 0x3d, 0x22, - 0x47, 0x74, 0x6b, 0x41, 0x64, 0x6a, 0x75, 0x73, - 0x74, 0x6d, 0x65, 0x6e, 0x74, 0x22, 0x20, 0x69, - 0x64, 0x3d, 0x22, 0x62, 0x72, 0x69, 0x67, 0x68, - 0x74, 0x6e, 0x65, 0x73, 0x73, 0x5f, 0x61, 0x64, - 0x6a, 0x75, 0x73, 0x74, 0x6d, 0x65, 0x6e, 0x74, - 0x22, 0x3e, 0x3c, 0x70, 0x72, 0x6f, 0x70, 0x65, - 0x72, 0x74, 0x79, 0x20, 0x6e, 0x61, 0x6d, 0x65, - 0x3d, 0x22, 0x6c, 0x6f, 0x77, 0x65, 0x72, 0x22, - 0x3e, 0x2d, 0x31, 0x30, 0x30, 0x3c, 0x2f, 0x70, - 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, 0x3e, - 0x3c, 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, - 0x79, 0x20, 0x6e, 0x61, 0x6d, 0x65, 0x3d, 0x22, - 0x75, 0x70, 0x70, 0x65, 0x72, 0x22, 0x3e, 0x31, - 0x30, 0x30, 0x3c, 0x2f, 0x70, 0x72, 0x6f, 0x70, - 0x65, 0x72, 0x74, 0x79, 0x3e, 0x3c, 0x70, 0x72, - 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, 0x20, 0x6e, - 0x61, 0x6d, 0x65, 0x3d, 0x22, 0x73, 0x74, 0x65, - 0x70, 0x5f, 0x69, 0x6e, 0x63, 0x72, 0x65, 0x6d, - 0x65, 0x6e, 0x74, 0x22, 0x3e, 0x31, 0x3c, 0x2f, - 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, - 0x3e, 0x3c, 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, - 0x74, 0x79, 0x20, 0x6e, 0x61, 0x6d, 0x65, 0x3d, - 0x22, 0x70, 0x61, 0x67, 0x65, 0x5f, 0x69, 0x6e, - 0x63, 0x72, 0x65, 0x6d, 0x65, 0x6e, 0x74, 0x22, - 0x3e, 0x31, 0x30, 0x3c, 0x2f, 0x70, 0x72, 0x6f, - 0x70, 0x65, 0x72, 0x74, 0x79, 0x3e, 0x3c, 0x2f, - 0x6f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x3e, 0x3c, - 0x6f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x20, 0x63, - 0x6c, 0x61, 0x73, 0x73, 0x3d, 0x22, 0x47, 0x74, - 0x6b, 0x41, 0x64, 0x6a, 0x75, 0x73, 0x74, 0x6d, - 0x65, 0x6e, 0x74, 0x22, 0x20, 0x69, 0x64, 0x3d, - 0x22, 0x63, 0x6f, 0x6e, 0x74, 0x72, 0x61, 0x73, - 0x74, 0x5f, 0x61, 0x64, 0x6a, 0x75, 0x73, 0x74, - 0x6d, 0x65, 0x6e, 0x74, 0x22, 0x3e, 0x3c, 0x70, - 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, 0x20, - 0x6e, 0x61, 0x6d, 0x65, 0x3d, 0x22, 0x6c, 0x6f, - 0x77, 0x65, 0x72, 0x22, 0x3e, 0x2d, 0x31, 0x30, - 0x30, 0x3c, 0x2f, 0x70, 0x72, 0x6f, 0x70, 0x65, - 0x72, 0x74, 0x79, 0x3e, 0x3c, 0x70, 0x72, 0x6f, - 0x70, 0x65, 0x72, 0x74, 0x79, 0x20, 0x6e, 0x61, - 0x6d, 0x65, 0x3d, 0x22, 0x75, 0x70, 0x70, 0x65, - 0x72, 0x22, 0x3e, 0x31, 0x30, 0x30, 0x3c, 0x2f, - 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, - 0x3e, 0x3c, 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, - 0x74, 0x79, 0x20, 0x6e, 0x61, 0x6d, 0x65, 0x3d, - 0x22, 0x73, 0x74, 0x65, 0x70, 0x5f, 0x69, 0x6e, - 0x63, 0x72, 0x65, 0x6d, 0x65, 0x6e, 0x74, 0x22, - 0x3e, 0x31, 0x3c, 0x2f, 0x70, 0x72, 0x6f, 0x70, - 0x65, 0x72, 0x74, 0x79, 0x3e, 0x3c, 0x70, 0x72, - 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, 0x20, 0x6e, - 0x61, 0x6d, 0x65, 0x3d, 0x22, 0x70, 0x61, 0x67, - 0x65, 0x5f, 0x69, 0x6e, 0x63, 0x72, 0x65, 0x6d, - 0x65, 0x6e, 0x74, 0x22, 0x3e, 0x31, 0x30, 0x3c, - 0x2f, 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, - 0x79, 0x3e, 0x3c, 0x2f, 0x6f, 0x62, 0x6a, 0x65, - 0x63, 0x74, 0x3e, 0x3c, 0x6f, 0x62, 0x6a, 0x65, - 0x63, 0x74, 0x20, 0x63, 0x6c, 0x61, 0x73, 0x73, - 0x3d, 0x22, 0x47, 0x74, 0x6b, 0x4c, 0x69, 0x73, - 0x74, 0x53, 0x74, 0x6f, 0x72, 0x65, 0x22, 0x20, - 0x69, 0x64, 0x3d, 0x22, 0x64, 0x65, 0x76, 0x69, - 0x63, 0x65, 0x5f, 0x6d, 0x6f, 0x64, 0x65, 0x6c, - 0x22, 0x3e, 0x3c, 0x63, 0x6f, 0x6c, 0x75, 0x6d, - 0x6e, 0x73, 0x3e, 0x3c, 0x21, 0x2d, 0x2d, 0x20, - 0x63, 0x6f, 0x6c, 0x75, 0x6d, 0x6e, 0x2d, 0x6e, - 0x61, 0x6d, 0x65, 0x20, 0x64, 0x65, 0x76, 0x69, - 0x63, 0x65, 0x5f, 0x6e, 0x61, 0x6d, 0x65, 0x20, - 0x2d, 0x2d, 0x3e, 0x3c, 0x63, 0x6f, 0x6c, 0x75, - 0x6d, 0x6e, 0x20, 0x74, 0x79, 0x70, 0x65, 0x3d, - 0x22, 0x67, 0x63, 0x68, 0x61, 0x72, 0x61, 0x72, - 0x72, 0x61, 0x79, 0x22, 0x2f, 0x3e, 0x3c, 0x21, - 0x2d, 0x2d, 0x20, 0x63, 0x6f, 0x6c, 0x75, 0x6d, - 0x6e, 0x2d, 0x6e, 0x61, 0x6d, 0x65, 0x20, 0x6c, - 0x61, 0x62, 0x65, 0x6c, 0x20, 0x2d, 0x2d, 0x3e, - 0x3c, 0x63, 0x6f, 0x6c, 0x75, 0x6d, 0x6e, 0x20, - 0x74, 0x79, 0x70, 0x65, 0x3d, 0x22, 0x67, 0x63, - 0x68, 0x61, 0x72, 0x61, 0x72, 0x72, 0x61, 0x79, - 0x22, 0x2f, 0x3e, 0x3c, 0x2f, 0x63, 0x6f, 0x6c, - 0x75, 0x6d, 0x6e, 0x73, 0x3e, 0x3c, 0x2f, 0x6f, - 0x62, 0x6a, 0x65, 0x63, 0x74, 0x3e, 0x3c, 0x6f, - 0x62, 0x6a, 0x65, 0x63, 0x74, 0x20, 0x63, 0x6c, - 0x61, 0x73, 0x73, 0x3d, 0x22, 0x47, 0x74, 0x6b, - 0x49, 0x6d, 0x61, 0x67, 0x65, 0x22, 0x20, 0x69, - 0x64, 0x3d, 0x22, 0x65, 0x6d, 0x61, 0x69, 0x6c, - 0x5f, 0x69, 0x6d, 0x61, 0x67, 0x65, 0x22, 0x3e, - 0x3c, 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, - 0x79, 0x20, 0x6e, 0x61, 0x6d, 0x65, 0x3d, 0x22, - 0x76, 0x69, 0x73, 0x69, 0x62, 0x6c, 0x65, 0x22, - 0x3e, 0x54, 0x72, 0x75, 0x65, 0x3c, 0x2f, 0x70, - 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, 0x3e, - 0x3c, 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, - 0x79, 0x20, 0x6e, 0x61, 0x6d, 0x65, 0x3d, 0x22, - 0x63, 0x61, 0x6e, 0x5f, 0x66, 0x6f, 0x63, 0x75, - 0x73, 0x22, 0x3e, 0x46, 0x61, 0x6c, 0x73, 0x65, - 0x3c, 0x2f, 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, - 0x74, 0x79, 0x3e, 0x3c, 0x70, 0x72, 0x6f, 0x70, - 0x65, 0x72, 0x74, 0x79, 0x20, 0x6e, 0x61, 0x6d, - 0x65, 0x3d, 0x22, 0x69, 0x63, 0x6f, 0x6e, 0x5f, - 0x6e, 0x61, 0x6d, 0x65, 0x22, 0x3e, 0x6d, 0x61, - 0x69, 0x6c, 0x2d, 0x73, 0x65, 0x6e, 0x64, 0x3c, - 0x2f, 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, - 0x79, 0x3e, 0x3c, 0x2f, 0x6f, 0x62, 0x6a, 0x65, - 0x63, 0x74, 0x3e, 0x3c, 0x6f, 0x62, 0x6a, 0x65, - 0x63, 0x74, 0x20, 0x63, 0x6c, 0x61, 0x73, 0x73, - 0x3d, 0x22, 0x47, 0x74, 0x6b, 0x49, 0x6d, 0x61, - 0x67, 0x65, 0x22, 0x20, 0x69, 0x64, 0x3d, 0x22, - 0x68, 0x65, 0x6c, 0x70, 0x5f, 0x69, 0x6d, 0x61, - 0x67, 0x65, 0x22, 0x3e, 0x3c, 0x70, 0x72, 0x6f, - 0x70, 0x65, 0x72, 0x74, 0x79, 0x20, 0x6e, 0x61, - 0x6d, 0x65, 0x3d, 0x22, 0x76, 0x69, 0x73, 0x69, - 0x62, 0x6c, 0x65, 0x22, 0x3e, 0x54, 0x72, 0x75, - 0x65, 0x3c, 0x2f, 0x70, 0x72, 0x6f, 0x70, 0x65, - 0x72, 0x74, 0x79, 0x3e, 0x3c, 0x70, 0x72, 0x6f, - 0x70, 0x65, 0x72, 0x74, 0x79, 0x20, 0x6e, 0x61, - 0x6d, 0x65, 0x3d, 0x22, 0x63, 0x61, 0x6e, 0x5f, - 0x66, 0x6f, 0x63, 0x75, 0x73, 0x22, 0x3e, 0x46, - 0x61, 0x6c, 0x73, 0x65, 0x3c, 0x2f, 0x70, 0x72, - 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, 0x3e, 0x3c, - 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, - 0x20, 0x6e, 0x61, 0x6d, 0x65, 0x3d, 0x22, 0x73, - 0x74, 0x6f, 0x63, 0x6b, 0x22, 0x3e, 0x67, 0x74, - 0x6b, 0x2d, 0x68, 0x65, 0x6c, 0x70, 0x3c, 0x2f, - 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, - 0x3e, 0x3c, 0x2f, 0x6f, 0x62, 0x6a, 0x65, 0x63, - 0x74, 0x3e, 0x3c, 0x6f, 0x62, 0x6a, 0x65, 0x63, - 0x74, 0x20, 0x63, 0x6c, 0x61, 0x73, 0x73, 0x3d, - 0x22, 0x47, 0x74, 0x6b, 0x4c, 0x69, 0x73, 0x74, - 0x53, 0x74, 0x6f, 0x72, 0x65, 0x22, 0x20, 0x69, - 0x64, 0x3d, 0x22, 0x70, 0x61, 0x67, 0x65, 0x5f, - 0x73, 0x69, 0x64, 0x65, 0x5f, 0x6d, 0x6f, 0x64, - 0x65, 0x6c, 0x22, 0x3e, 0x3c, 0x63, 0x6f, 0x6c, - 0x75, 0x6d, 0x6e, 0x73, 0x3e, 0x3c, 0x21, 0x2d, - 0x2d, 0x20, 0x63, 0x6f, 0x6c, 0x75, 0x6d, 0x6e, - 0x2d, 0x6e, 0x61, 0x6d, 0x65, 0x20, 0x73, 0x69, - 0x64, 0x65, 0x20, 0x2d, 0x2d, 0x3e, 0x3c, 0x63, - 0x6f, 0x6c, 0x75, 0x6d, 0x6e, 0x20, 0x74, 0x79, - 0x70, 0x65, 0x3d, 0x22, 0x67, 0x69, 0x6e, 0x74, - 0x22, 0x2f, 0x3e, 0x3c, 0x21, 0x2d, 0x2d, 0x20, - 0x63, 0x6f, 0x6c, 0x75, 0x6d, 0x6e, 0x2d, 0x6e, - 0x61, 0x6d, 0x65, 0x20, 0x6c, 0x61, 0x62, 0x65, - 0x6c, 0x20, 0x2d, 0x2d, 0x3e, 0x3c, 0x63, 0x6f, - 0x6c, 0x75, 0x6d, 0x6e, 0x20, 0x74, 0x79, 0x70, - 0x65, 0x3d, 0x22, 0x67, 0x63, 0x68, 0x61, 0x72, - 0x61, 0x72, 0x72, 0x61, 0x79, 0x22, 0x2f, 0x3e, - 0x3c, 0x2f, 0x63, 0x6f, 0x6c, 0x75, 0x6d, 0x6e, - 0x73, 0x3e, 0x3c, 0x64, 0x61, 0x74, 0x61, 0x3e, - 0x3c, 0x72, 0x6f, 0x77, 0x3e, 0x3c, 0x63, 0x6f, - 0x6c, 0x20, 0x69, 0x64, 0x3d, 0x22, 0x30, 0x22, - 0x3e, 0x33, 0x3c, 0x2f, 0x63, 0x6f, 0x6c, 0x3e, - 0x3c, 0x63, 0x6f, 0x6c, 0x20, 0x69, 0x64, 0x3d, - 0x22, 0x31, 0x22, 0x20, 0x74, 0x72, 0x61, 0x6e, - 0x73, 0x6c, 0x61, 0x74, 0x61, 0x62, 0x6c, 0x65, - 0x3d, 0x22, 0x79, 0x65, 0x73, 0x22, 0x20, 0x63, - 0x6f, 0x6d, 0x6d, 0x65, 0x6e, 0x74, 0x73, 0x3d, - 0x22, 0x43, 0x6f, 0x6d, 0x62, 0x6f, 0x20, 0x62, - 0x6f, 0x78, 0x20, 0x6c, 0x61, 0x62, 0x65, 0x6c, - 0x20, 0x66, 0x6f, 0x72, 0x20, 0x73, 0x63, 0x61, - 0x6e, 0x6e, 0x69, 0x6e, 0x67, 0x20, 0x62, 0x6f, - 0x74, 0x68, 0x20, 0x73, 0x69, 0x64, 0x65, 0x73, - 0x20, 0x6f, 0x66, 0x20, 0x61, 0x20, 0x70, 0x61, - 0x67, 0x65, 0x22, 0x3e, 0x46, 0x72, 0x6f, 0x6e, - 0x74, 0x20, 0x61, 0x6e, 0x64, 0x20, 0x42, 0x61, - 0x63, 0x6b, 0x3c, 0x2f, 0x63, 0x6f, 0x6c, 0x3e, - 0x3c, 0x2f, 0x72, 0x6f, 0x77, 0x3e, 0x3c, 0x72, - 0x6f, 0x77, 0x3e, 0x3c, 0x63, 0x6f, 0x6c, 0x20, - 0x69, 0x64, 0x3d, 0x22, 0x30, 0x22, 0x3e, 0x31, - 0x3c, 0x2f, 0x63, 0x6f, 0x6c, 0x3e, 0x3c, 0x63, - 0x6f, 0x6c, 0x20, 0x69, 0x64, 0x3d, 0x22, 0x31, - 0x22, 0x20, 0x74, 0x72, 0x61, 0x6e, 0x73, 0x6c, - 0x61, 0x74, 0x61, 0x62, 0x6c, 0x65, 0x3d, 0x22, - 0x79, 0x65, 0x73, 0x22, 0x20, 0x63, 0x6f, 0x6d, - 0x6d, 0x65, 0x6e, 0x74, 0x73, 0x3d, 0x22, 0x43, - 0x6f, 0x6d, 0x62, 0x6f, 0x20, 0x62, 0x6f, 0x78, - 0x20, 0x6c, 0x61, 0x62, 0x65, 0x6c, 0x20, 0x66, - 0x6f, 0x72, 0x20, 0x73, 0x63, 0x61, 0x6e, 0x6e, - 0x69, 0x6e, 0x67, 0x20, 0x74, 0x68, 0x65, 0x20, - 0x66, 0x72, 0x6f, 0x6e, 0x74, 0x20, 0x73, 0x69, - 0x64, 0x65, 0x20, 0x6f, 0x66, 0x20, 0x61, 0x20, - 0x70, 0x61, 0x67, 0x65, 0x22, 0x3e, 0x46, 0x72, - 0x6f, 0x6e, 0x74, 0x3c, 0x2f, 0x63, 0x6f, 0x6c, - 0x3e, 0x3c, 0x2f, 0x72, 0x6f, 0x77, 0x3e, 0x3c, - 0x72, 0x6f, 0x77, 0x3e, 0x3c, 0x63, 0x6f, 0x6c, - 0x20, 0x69, 0x64, 0x3d, 0x22, 0x30, 0x22, 0x3e, - 0x32, 0x3c, 0x2f, 0x63, 0x6f, 0x6c, 0x3e, 0x3c, - 0x63, 0x6f, 0x6c, 0x20, 0x69, 0x64, 0x3d, 0x22, - 0x31, 0x22, 0x20, 0x74, 0x72, 0x61, 0x6e, 0x73, - 0x6c, 0x61, 0x74, 0x61, 0x62, 0x6c, 0x65, 0x3d, - 0x22, 0x79, 0x65, 0x73, 0x22, 0x20, 0x63, 0x6f, - 0x6d, 0x6d, 0x65, 0x6e, 0x74, 0x73, 0x3d, 0x22, - 0x43, 0x6f, 0x6d, 0x62, 0x6f, 0x20, 0x62, 0x6f, - 0x78, 0x20, 0x6c, 0x61, 0x62, 0x65, 0x6c, 0x20, - 0x66, 0x6f, 0x72, 0x20, 0x73, 0x63, 0x61, 0x6e, - 0x6e, 0x69, 0x6e, 0x67, 0x20, 0x74, 0x68, 0x65, - 0x20, 0x62, 0x61, 0x63, 0x6b, 0x20, 0x73, 0x69, - 0x64, 0x65, 0x20, 0x6f, 0x66, 0x20, 0x61, 0x20, - 0x70, 0x61, 0x67, 0x65, 0x22, 0x3e, 0x42, 0x61, - 0x63, 0x6b, 0x3c, 0x2f, 0x63, 0x6f, 0x6c, 0x3e, - 0x3c, 0x2f, 0x72, 0x6f, 0x77, 0x3e, 0x3c, 0x2f, - 0x64, 0x61, 0x74, 0x61, 0x3e, 0x3c, 0x2f, 0x6f, - 0x62, 0x6a, 0x65, 0x63, 0x74, 0x3e, 0x3c, 0x6f, - 0x62, 0x6a, 0x65, 0x63, 0x74, 0x20, 0x63, 0x6c, - 0x61, 0x73, 0x73, 0x3d, 0x22, 0x47, 0x74, 0x6b, - 0x4c, 0x69, 0x73, 0x74, 0x53, 0x74, 0x6f, 0x72, - 0x65, 0x22, 0x20, 0x69, 0x64, 0x3d, 0x22, 0x70, - 0x61, 0x70, 0x65, 0x72, 0x5f, 0x73, 0x69, 0x7a, - 0x65, 0x5f, 0x6d, 0x6f, 0x64, 0x65, 0x6c, 0x22, - 0x3e, 0x3c, 0x63, 0x6f, 0x6c, 0x75, 0x6d, 0x6e, - 0x73, 0x3e, 0x3c, 0x21, 0x2d, 0x2d, 0x20, 0x63, - 0x6f, 0x6c, 0x75, 0x6d, 0x6e, 0x2d, 0x6e, 0x61, - 0x6d, 0x65, 0x20, 0x77, 0x69, 0x64, 0x74, 0x68, - 0x20, 0x2d, 0x2d, 0x3e, 0x3c, 0x63, 0x6f, 0x6c, - 0x75, 0x6d, 0x6e, 0x20, 0x74, 0x79, 0x70, 0x65, - 0x3d, 0x22, 0x67, 0x69, 0x6e, 0x74, 0x22, 0x2f, - 0x3e, 0x3c, 0x21, 0x2d, 0x2d, 0x20, 0x63, 0x6f, - 0x6c, 0x75, 0x6d, 0x6e, 0x2d, 0x6e, 0x61, 0x6d, - 0x65, 0x20, 0x68, 0x65, 0x69, 0x67, 0x68, 0x74, - 0x20, 0x2d, 0x2d, 0x3e, 0x3c, 0x63, 0x6f, 0x6c, - 0x75, 0x6d, 0x6e, 0x20, 0x74, 0x79, 0x70, 0x65, - 0x3d, 0x22, 0x67, 0x69, 0x6e, 0x74, 0x22, 0x2f, - 0x3e, 0x3c, 0x21, 0x2d, 0x2d, 0x20, 0x63, 0x6f, - 0x6c, 0x75, 0x6d, 0x6e, 0x2d, 0x6e, 0x61, 0x6d, - 0x65, 0x20, 0x6c, 0x61, 0x62, 0x65, 0x6c, 0x20, - 0x2d, 0x2d, 0x3e, 0x3c, 0x63, 0x6f, 0x6c, 0x75, - 0x6d, 0x6e, 0x20, 0x74, 0x79, 0x70, 0x65, 0x3d, - 0x22, 0x67, 0x63, 0x68, 0x61, 0x72, 0x61, 0x72, - 0x72, 0x61, 0x79, 0x22, 0x2f, 0x3e, 0x3c, 0x2f, - 0x63, 0x6f, 0x6c, 0x75, 0x6d, 0x6e, 0x73, 0x3e, - 0x3c, 0x2f, 0x6f, 0x62, 0x6a, 0x65, 0x63, 0x74, - 0x3e, 0x3c, 0x6f, 0x62, 0x6a, 0x65, 0x63, 0x74, - 0x20, 0x63, 0x6c, 0x61, 0x73, 0x73, 0x3d, 0x22, - 0x47, 0x74, 0x6b, 0x4c, 0x69, 0x73, 0x74, 0x53, - 0x74, 0x6f, 0x72, 0x65, 0x22, 0x20, 0x69, 0x64, - 0x3d, 0x22, 0x70, 0x68, 0x6f, 0x74, 0x6f, 0x5f, - 0x64, 0x70, 0x69, 0x5f, 0x6d, 0x6f, 0x64, 0x65, - 0x6c, 0x22, 0x3e, 0x3c, 0x63, 0x6f, 0x6c, 0x75, - 0x6d, 0x6e, 0x73, 0x3e, 0x3c, 0x21, 0x2d, 0x2d, - 0x20, 0x63, 0x6f, 0x6c, 0x75, 0x6d, 0x6e, 0x2d, - 0x6e, 0x61, 0x6d, 0x65, 0x20, 0x64, 0x70, 0x69, - 0x20, 0x2d, 0x2d, 0x3e, 0x3c, 0x63, 0x6f, 0x6c, - 0x75, 0x6d, 0x6e, 0x20, 0x74, 0x79, 0x70, 0x65, - 0x3d, 0x22, 0x67, 0x69, 0x6e, 0x74, 0x22, 0x2f, - 0x3e, 0x3c, 0x21, 0x2d, 0x2d, 0x20, 0x63, 0x6f, - 0x6c, 0x75, 0x6d, 0x6e, 0x2d, 0x6e, 0x61, 0x6d, - 0x65, 0x20, 0x6c, 0x61, 0x62, 0x65, 0x6c, 0x20, - 0x2d, 0x2d, 0x3e, 0x3c, 0x63, 0x6f, 0x6c, 0x75, - 0x6d, 0x6e, 0x20, 0x74, 0x79, 0x70, 0x65, 0x3d, - 0x22, 0x67, 0x63, 0x68, 0x61, 0x72, 0x61, 0x72, - 0x72, 0x61, 0x79, 0x22, 0x2f, 0x3e, 0x3c, 0x2f, - 0x63, 0x6f, 0x6c, 0x75, 0x6d, 0x6e, 0x73, 0x3e, - 0x3c, 0x2f, 0x6f, 0x62, 0x6a, 0x65, 0x63, 0x74, - 0x3e, 0x3c, 0x6f, 0x62, 0x6a, 0x65, 0x63, 0x74, - 0x20, 0x63, 0x6c, 0x61, 0x73, 0x73, 0x3d, 0x22, - 0x47, 0x74, 0x6b, 0x41, 0x64, 0x6a, 0x75, 0x73, - 0x74, 0x6d, 0x65, 0x6e, 0x74, 0x22, 0x20, 0x69, - 0x64, 0x3d, 0x22, 0x71, 0x75, 0x61, 0x6c, 0x69, - 0x74, 0x79, 0x5f, 0x61, 0x64, 0x6a, 0x75, 0x73, - 0x74, 0x6d, 0x65, 0x6e, 0x74, 0x22, 0x3e, 0x3c, - 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, - 0x20, 0x6e, 0x61, 0x6d, 0x65, 0x3d, 0x22, 0x75, - 0x70, 0x70, 0x65, 0x72, 0x22, 0x3e, 0x31, 0x30, - 0x30, 0x3c, 0x2f, 0x70, 0x72, 0x6f, 0x70, 0x65, - 0x72, 0x74, 0x79, 0x3e, 0x3c, 0x70, 0x72, 0x6f, - 0x70, 0x65, 0x72, 0x74, 0x79, 0x20, 0x6e, 0x61, - 0x6d, 0x65, 0x3d, 0x22, 0x73, 0x74, 0x65, 0x70, - 0x5f, 0x69, 0x6e, 0x63, 0x72, 0x65, 0x6d, 0x65, - 0x6e, 0x74, 0x22, 0x3e, 0x31, 0x3c, 0x2f, 0x70, - 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, 0x3e, - 0x3c, 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, - 0x79, 0x20, 0x6e, 0x61, 0x6d, 0x65, 0x3d, 0x22, - 0x70, 0x61, 0x67, 0x65, 0x5f, 0x69, 0x6e, 0x63, - 0x72, 0x65, 0x6d, 0x65, 0x6e, 0x74, 0x22, 0x3e, - 0x31, 0x30, 0x3c, 0x2f, 0x70, 0x72, 0x6f, 0x70, - 0x65, 0x72, 0x74, 0x79, 0x3e, 0x3c, 0x2f, 0x6f, - 0x62, 0x6a, 0x65, 0x63, 0x74, 0x3e, 0x3c, 0x74, - 0x65, 0x6d, 0x70, 0x6c, 0x61, 0x74, 0x65, 0x20, - 0x63, 0x6c, 0x61, 0x73, 0x73, 0x3d, 0x22, 0x55, - 0x73, 0x65, 0x72, 0x49, 0x6e, 0x74, 0x65, 0x72, - 0x66, 0x61, 0x63, 0x65, 0x22, 0x20, 0x70, 0x61, - 0x72, 0x65, 0x6e, 0x74, 0x3d, 0x22, 0x47, 0x74, - 0x6b, 0x41, 0x70, 0x70, 0x6c, 0x69, 0x63, 0x61, - 0x74, 0x69, 0x6f, 0x6e, 0x57, 0x69, 0x6e, 0x64, - 0x6f, 0x77, 0x22, 0x3e, 0x3c, 0x70, 0x72, 0x6f, - 0x70, 0x65, 0x72, 0x74, 0x79, 0x20, 0x6e, 0x61, - 0x6d, 0x65, 0x3d, 0x22, 0x63, 0x61, 0x6e, 0x5f, - 0x66, 0x6f, 0x63, 0x75, 0x73, 0x22, 0x3e, 0x46, - 0x61, 0x6c, 0x73, 0x65, 0x3c, 0x2f, 0x70, 0x72, - 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, 0x3e, 0x3c, - 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, - 0x20, 0x6e, 0x61, 0x6d, 0x65, 0x3d, 0x22, 0x74, - 0x69, 0x74, 0x6c, 0x65, 0x22, 0x20, 0x74, 0x72, - 0x61, 0x6e, 0x73, 0x6c, 0x61, 0x74, 0x61, 0x62, - 0x6c, 0x65, 0x3d, 0x22, 0x79, 0x65, 0x73, 0x22, - 0x20, 0x63, 0x6f, 0x6d, 0x6d, 0x65, 0x6e, 0x74, - 0x73, 0x3d, 0x22, 0x54, 0x69, 0x74, 0x6c, 0x65, - 0x20, 0x6f, 0x66, 0x20, 0x73, 0x63, 0x61, 0x6e, - 0x20, 0x77, 0x69, 0x6e, 0x64, 0x6f, 0x77, 0x22, - 0x3e, 0x53, 0x69, 0x6d, 0x70, 0x6c, 0x65, 0x20, - 0x53, 0x63, 0x61, 0x6e, 0x3c, 0x2f, 0x70, 0x72, - 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, 0x3e, 0x3c, - 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, - 0x20, 0x6e, 0x61, 0x6d, 0x65, 0x3d, 0x22, 0x69, - 0x63, 0x6f, 0x6e, 0x5f, 0x6e, 0x61, 0x6d, 0x65, - 0x22, 0x3e, 0x73, 0x63, 0x61, 0x6e, 0x6e, 0x65, - 0x72, 0x3c, 0x2f, 0x70, 0x72, 0x6f, 0x70, 0x65, - 0x72, 0x74, 0x79, 0x3e, 0x3c, 0x73, 0x69, 0x67, - 0x6e, 0x61, 0x6c, 0x20, 0x6e, 0x61, 0x6d, 0x65, - 0x3d, 0x22, 0x64, 0x65, 0x6c, 0x65, 0x74, 0x65, - 0x2d, 0x65, 0x76, 0x65, 0x6e, 0x74, 0x22, 0x20, - 0x68, 0x61, 0x6e, 0x64, 0x6c, 0x65, 0x72, 0x3d, - 0x22, 0x77, 0x69, 0x6e, 0x64, 0x6f, 0x77, 0x5f, - 0x64, 0x65, 0x6c, 0x65, 0x74, 0x65, 0x5f, 0x65, - 0x76, 0x65, 0x6e, 0x74, 0x5f, 0x63, 0x62, 0x22, - 0x20, 0x73, 0x77, 0x61, 0x70, 0x70, 0x65, 0x64, - 0x3d, 0x22, 0x6e, 0x6f, 0x22, 0x2f, 0x3e, 0x3c, - 0x63, 0x68, 0x69, 0x6c, 0x64, 0x3e, 0x3c, 0x6f, - 0x62, 0x6a, 0x65, 0x63, 0x74, 0x20, 0x63, 0x6c, - 0x61, 0x73, 0x73, 0x3d, 0x22, 0x47, 0x74, 0x6b, - 0x42, 0x6f, 0x78, 0x22, 0x20, 0x69, 0x64, 0x3d, - 0x22, 0x6d, 0x61, 0x69, 0x6e, 0x5f, 0x76, 0x62, - 0x6f, 0x78, 0x22, 0x3e, 0x3c, 0x70, 0x72, 0x6f, - 0x70, 0x65, 0x72, 0x74, 0x79, 0x20, 0x6e, 0x61, - 0x6d, 0x65, 0x3d, 0x22, 0x76, 0x69, 0x73, 0x69, - 0x62, 0x6c, 0x65, 0x22, 0x3e, 0x54, 0x72, 0x75, - 0x65, 0x3c, 0x2f, 0x70, 0x72, 0x6f, 0x70, 0x65, - 0x72, 0x74, 0x79, 0x3e, 0x3c, 0x70, 0x72, 0x6f, - 0x70, 0x65, 0x72, 0x74, 0x79, 0x20, 0x6e, 0x61, - 0x6d, 0x65, 0x3d, 0x22, 0x63, 0x61, 0x6e, 0x5f, - 0x66, 0x6f, 0x63, 0x75, 0x73, 0x22, 0x3e, 0x46, - 0x61, 0x6c, 0x73, 0x65, 0x3c, 0x2f, 0x70, 0x72, - 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, 0x3e, 0x3c, - 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, - 0x20, 0x6e, 0x61, 0x6d, 0x65, 0x3d, 0x22, 0x6f, - 0x72, 0x69, 0x65, 0x6e, 0x74, 0x61, 0x74, 0x69, - 0x6f, 0x6e, 0x22, 0x3e, 0x76, 0x65, 0x72, 0x74, - 0x69, 0x63, 0x61, 0x6c, 0x3c, 0x2f, 0x70, 0x72, - 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, 0x3e, 0x3c, - 0x63, 0x68, 0x69, 0x6c, 0x64, 0x3e, 0x3c, 0x6f, - 0x62, 0x6a, 0x65, 0x63, 0x74, 0x20, 0x63, 0x6c, - 0x61, 0x73, 0x73, 0x3d, 0x22, 0x47, 0x74, 0x6b, - 0x4d, 0x65, 0x6e, 0x75, 0x42, 0x61, 0x72, 0x22, - 0x20, 0x69, 0x64, 0x3d, 0x22, 0x6d, 0x65, 0x6e, - 0x75, 0x62, 0x61, 0x72, 0x22, 0x3e, 0x3c, 0x70, - 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, 0x20, - 0x6e, 0x61, 0x6d, 0x65, 0x3d, 0x22, 0x76, 0x69, - 0x73, 0x69, 0x62, 0x6c, 0x65, 0x22, 0x3e, 0x46, - 0x61, 0x6c, 0x73, 0x65, 0x3c, 0x2f, 0x70, 0x72, - 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, 0x3e, 0x3c, - 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, - 0x20, 0x6e, 0x61, 0x6d, 0x65, 0x3d, 0x22, 0x63, - 0x61, 0x6e, 0x5f, 0x66, 0x6f, 0x63, 0x75, 0x73, - 0x22, 0x3e, 0x46, 0x61, 0x6c, 0x73, 0x65, 0x3c, - 0x2f, 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, - 0x79, 0x3e, 0x3c, 0x63, 0x68, 0x69, 0x6c, 0x64, - 0x3e, 0x3c, 0x6f, 0x62, 0x6a, 0x65, 0x63, 0x74, - 0x20, 0x63, 0x6c, 0x61, 0x73, 0x73, 0x3d, 0x22, - 0x47, 0x74, 0x6b, 0x4d, 0x65, 0x6e, 0x75, 0x49, - 0x74, 0x65, 0x6d, 0x22, 0x20, 0x69, 0x64, 0x3d, - 0x22, 0x64, 0x6f, 0x63, 0x75, 0x6d, 0x65, 0x6e, - 0x74, 0x5f, 0x6d, 0x65, 0x6e, 0x75, 0x69, 0x74, - 0x65, 0x6d, 0x22, 0x3e, 0x3c, 0x70, 0x72, 0x6f, - 0x70, 0x65, 0x72, 0x74, 0x79, 0x20, 0x6e, 0x61, - 0x6d, 0x65, 0x3d, 0x22, 0x76, 0x69, 0x73, 0x69, - 0x62, 0x6c, 0x65, 0x22, 0x3e, 0x54, 0x72, 0x75, - 0x65, 0x3c, 0x2f, 0x70, 0x72, 0x6f, 0x70, 0x65, - 0x72, 0x74, 0x79, 0x3e, 0x3c, 0x70, 0x72, 0x6f, - 0x70, 0x65, 0x72, 0x74, 0x79, 0x20, 0x6e, 0x61, - 0x6d, 0x65, 0x3d, 0x22, 0x63, 0x61, 0x6e, 0x5f, - 0x66, 0x6f, 0x63, 0x75, 0x73, 0x22, 0x3e, 0x46, - 0x61, 0x6c, 0x73, 0x65, 0x3c, 0x2f, 0x70, 0x72, - 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, 0x3e, 0x3c, - 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, - 0x20, 0x6e, 0x61, 0x6d, 0x65, 0x3d, 0x22, 0x6c, - 0x61, 0x62, 0x65, 0x6c, 0x22, 0x20, 0x74, 0x72, - 0x61, 0x6e, 0x73, 0x6c, 0x61, 0x74, 0x61, 0x62, - 0x6c, 0x65, 0x3d, 0x22, 0x79, 0x65, 0x73, 0x22, - 0x20, 0x63, 0x6f, 0x6d, 0x6d, 0x65, 0x6e, 0x74, - 0x73, 0x3d, 0x22, 0x4c, 0x61, 0x62, 0x65, 0x6c, - 0x20, 0x6f, 0x6e, 0x20, 0x64, 0x6f, 0x63, 0x75, - 0x6d, 0x65, 0x6e, 0x74, 0x20, 0x6d, 0x65, 0x6e, - 0x75, 0x20, 0x28, 0x63, 0x6f, 0x6e, 0x74, 0x61, - 0x69, 0x6e, 0x73, 0x20, 0x61, 0x63, 0x74, 0x69, - 0x6f, 0x6e, 0x73, 0x20, 0x66, 0x6f, 0x72, 0x20, - 0x74, 0x68, 0x69, 0x73, 0x20, 0x64, 0x6f, 0x63, - 0x75, 0x6d, 0x65, 0x6e, 0x74, 0x2c, 0x20, 0x65, - 0x2e, 0x67, 0x2e, 0x20, 0x73, 0x61, 0x76, 0x65, - 0x2c, 0x20, 0x70, 0x72, 0x69, 0x6e, 0x74, 0x29, - 0x22, 0x3e, 0x5f, 0x44, 0x6f, 0x63, 0x75, 0x6d, - 0x65, 0x6e, 0x74, 0x3c, 0x2f, 0x70, 0x72, 0x6f, - 0x70, 0x65, 0x72, 0x74, 0x79, 0x3e, 0x3c, 0x70, - 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, 0x20, - 0x6e, 0x61, 0x6d, 0x65, 0x3d, 0x22, 0x75, 0x73, - 0x65, 0x5f, 0x75, 0x6e, 0x64, 0x65, 0x72, 0x6c, - 0x69, 0x6e, 0x65, 0x22, 0x3e, 0x54, 0x72, 0x75, - 0x65, 0x3c, 0x2f, 0x70, 0x72, 0x6f, 0x70, 0x65, - 0x72, 0x74, 0x79, 0x3e, 0x3c, 0x63, 0x68, 0x69, - 0x6c, 0x64, 0x20, 0x74, 0x79, 0x70, 0x65, 0x3d, - 0x22, 0x73, 0x75, 0x62, 0x6d, 0x65, 0x6e, 0x75, - 0x22, 0x3e, 0x3c, 0x6f, 0x62, 0x6a, 0x65, 0x63, - 0x74, 0x20, 0x63, 0x6c, 0x61, 0x73, 0x73, 0x3d, - 0x22, 0x47, 0x74, 0x6b, 0x4d, 0x65, 0x6e, 0x75, - 0x22, 0x20, 0x69, 0x64, 0x3d, 0x22, 0x64, 0x6f, - 0x63, 0x75, 0x6d, 0x65, 0x6e, 0x74, 0x5f, 0x6d, - 0x65, 0x6e, 0x75, 0x22, 0x3e, 0x3c, 0x70, 0x72, - 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, 0x20, 0x6e, - 0x61, 0x6d, 0x65, 0x3d, 0x22, 0x76, 0x69, 0x73, - 0x69, 0x62, 0x6c, 0x65, 0x22, 0x3e, 0x54, 0x72, - 0x75, 0x65, 0x3c, 0x2f, 0x70, 0x72, 0x6f, 0x70, - 0x65, 0x72, 0x74, 0x79, 0x3e, 0x3c, 0x70, 0x72, - 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, 0x20, 0x6e, - 0x61, 0x6d, 0x65, 0x3d, 0x22, 0x63, 0x61, 0x6e, - 0x5f, 0x66, 0x6f, 0x63, 0x75, 0x73, 0x22, 0x3e, - 0x46, 0x61, 0x6c, 0x73, 0x65, 0x3c, 0x2f, 0x70, - 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, 0x3e, - 0x3c, 0x63, 0x68, 0x69, 0x6c, 0x64, 0x3e, 0x3c, - 0x6f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x20, 0x63, - 0x6c, 0x61, 0x73, 0x73, 0x3d, 0x22, 0x47, 0x74, - 0x6b, 0x49, 0x6d, 0x61, 0x67, 0x65, 0x4d, 0x65, - 0x6e, 0x75, 0x49, 0x74, 0x65, 0x6d, 0x22, 0x20, - 0x69, 0x64, 0x3d, 0x22, 0x6e, 0x65, 0x77, 0x5f, - 0x6d, 0x65, 0x6e, 0x75, 0x69, 0x74, 0x65, 0x6d, - 0x22, 0x3e, 0x3c, 0x70, 0x72, 0x6f, 0x70, 0x65, - 0x72, 0x74, 0x79, 0x20, 0x6e, 0x61, 0x6d, 0x65, - 0x3d, 0x22, 0x6c, 0x61, 0x62, 0x65, 0x6c, 0x22, - 0x3e, 0x67, 0x74, 0x6b, 0x2d, 0x6e, 0x65, 0x77, - 0x3c, 0x2f, 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, - 0x74, 0x79, 0x3e, 0x3c, 0x70, 0x72, 0x6f, 0x70, - 0x65, 0x72, 0x74, 0x79, 0x20, 0x6e, 0x61, 0x6d, - 0x65, 0x3d, 0x22, 0x76, 0x69, 0x73, 0x69, 0x62, - 0x6c, 0x65, 0x22, 0x3e, 0x54, 0x72, 0x75, 0x65, - 0x3c, 0x2f, 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, - 0x74, 0x79, 0x3e, 0x3c, 0x70, 0x72, 0x6f, 0x70, - 0x65, 0x72, 0x74, 0x79, 0x20, 0x6e, 0x61, 0x6d, - 0x65, 0x3d, 0x22, 0x63, 0x61, 0x6e, 0x5f, 0x66, - 0x6f, 0x63, 0x75, 0x73, 0x22, 0x3e, 0x46, 0x61, - 0x6c, 0x73, 0x65, 0x3c, 0x2f, 0x70, 0x72, 0x6f, - 0x70, 0x65, 0x72, 0x74, 0x79, 0x3e, 0x3c, 0x70, - 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, 0x20, - 0x6e, 0x61, 0x6d, 0x65, 0x3d, 0x22, 0x75, 0x73, - 0x65, 0x5f, 0x75, 0x6e, 0x64, 0x65, 0x72, 0x6c, - 0x69, 0x6e, 0x65, 0x22, 0x3e, 0x54, 0x72, 0x75, - 0x65, 0x3c, 0x2f, 0x70, 0x72, 0x6f, 0x70, 0x65, - 0x72, 0x74, 0x79, 0x3e, 0x3c, 0x70, 0x72, 0x6f, - 0x70, 0x65, 0x72, 0x74, 0x79, 0x20, 0x6e, 0x61, - 0x6d, 0x65, 0x3d, 0x22, 0x75, 0x73, 0x65, 0x5f, - 0x73, 0x74, 0x6f, 0x63, 0x6b, 0x22, 0x3e, 0x54, - 0x72, 0x75, 0x65, 0x3c, 0x2f, 0x70, 0x72, 0x6f, - 0x70, 0x65, 0x72, 0x74, 0x79, 0x3e, 0x3c, 0x61, - 0x63, 0x63, 0x65, 0x6c, 0x65, 0x72, 0x61, 0x74, - 0x6f, 0x72, 0x20, 0x6b, 0x65, 0x79, 0x3d, 0x22, - 0x6e, 0x22, 0x20, 0x73, 0x69, 0x67, 0x6e, 0x61, - 0x6c, 0x3d, 0x22, 0x61, 0x63, 0x74, 0x69, 0x76, - 0x61, 0x74, 0x65, 0x22, 0x20, 0x6d, 0x6f, 0x64, - 0x69, 0x66, 0x69, 0x65, 0x72, 0x73, 0x3d, 0x22, - 0x47, 0x44, 0x4b, 0x5f, 0x43, 0x4f, 0x4e, 0x54, - 0x52, 0x4f, 0x4c, 0x5f, 0x4d, 0x41, 0x53, 0x4b, - 0x22, 0x2f, 0x3e, 0x3c, 0x73, 0x69, 0x67, 0x6e, - 0x61, 0x6c, 0x20, 0x6e, 0x61, 0x6d, 0x65, 0x3d, - 0x22, 0x61, 0x63, 0x74, 0x69, 0x76, 0x61, 0x74, - 0x65, 0x22, 0x20, 0x68, 0x61, 0x6e, 0x64, 0x6c, - 0x65, 0x72, 0x3d, 0x22, 0x6e, 0x65, 0x77, 0x5f, - 0x62, 0x75, 0x74, 0x74, 0x6f, 0x6e, 0x5f, 0x63, - 0x6c, 0x69, 0x63, 0x6b, 0x65, 0x64, 0x5f, 0x63, - 0x62, 0x22, 0x20, 0x73, 0x77, 0x61, 0x70, 0x70, - 0x65, 0x64, 0x3d, 0x22, 0x6e, 0x6f, 0x22, 0x2f, - 0x3e, 0x3c, 0x2f, 0x6f, 0x62, 0x6a, 0x65, 0x63, - 0x74, 0x3e, 0x3c, 0x2f, 0x63, 0x68, 0x69, 0x6c, - 0x64, 0x3e, 0x3c, 0x63, 0x68, 0x69, 0x6c, 0x64, - 0x3e, 0x3c, 0x6f, 0x62, 0x6a, 0x65, 0x63, 0x74, - 0x20, 0x63, 0x6c, 0x61, 0x73, 0x73, 0x3d, 0x22, - 0x47, 0x74, 0x6b, 0x49, 0x6d, 0x61, 0x67, 0x65, - 0x4d, 0x65, 0x6e, 0x75, 0x49, 0x74, 0x65, 0x6d, - 0x22, 0x20, 0x69, 0x64, 0x3d, 0x22, 0x73, 0x63, - 0x61, 0x6e, 0x5f, 0x6d, 0x65, 0x6e, 0x75, 0x69, - 0x74, 0x65, 0x6d, 0x22, 0x3e, 0x3c, 0x70, 0x72, - 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, 0x20, 0x6e, - 0x61, 0x6d, 0x65, 0x3d, 0x22, 0x6c, 0x61, 0x62, - 0x65, 0x6c, 0x22, 0x20, 0x74, 0x72, 0x61, 0x6e, - 0x73, 0x6c, 0x61, 0x74, 0x61, 0x62, 0x6c, 0x65, - 0x3d, 0x22, 0x79, 0x65, 0x73, 0x22, 0x20, 0x63, - 0x6f, 0x6d, 0x6d, 0x65, 0x6e, 0x74, 0x73, 0x3d, - 0x22, 0x53, 0x63, 0x61, 0x6e, 0x20, 0x6d, 0x65, - 0x6e, 0x75, 0x20, 0x69, 0x74, 0x65, 0x6d, 0x22, - 0x3e, 0x53, 0x63, 0x5f, 0x61, 0x6e, 0x3c, 0x2f, - 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, - 0x3e, 0x3c, 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, - 0x74, 0x79, 0x20, 0x6e, 0x61, 0x6d, 0x65, 0x3d, - 0x22, 0x76, 0x69, 0x73, 0x69, 0x62, 0x6c, 0x65, - 0x22, 0x3e, 0x54, 0x72, 0x75, 0x65, 0x3c, 0x2f, - 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, - 0x3e, 0x3c, 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, - 0x74, 0x79, 0x20, 0x6e, 0x61, 0x6d, 0x65, 0x3d, - 0x22, 0x63, 0x61, 0x6e, 0x5f, 0x66, 0x6f, 0x63, - 0x75, 0x73, 0x22, 0x3e, 0x46, 0x61, 0x6c, 0x73, - 0x65, 0x3c, 0x2f, 0x70, 0x72, 0x6f, 0x70, 0x65, - 0x72, 0x74, 0x79, 0x3e, 0x3c, 0x70, 0x72, 0x6f, - 0x70, 0x65, 0x72, 0x74, 0x79, 0x20, 0x6e, 0x61, - 0x6d, 0x65, 0x3d, 0x22, 0x75, 0x73, 0x65, 0x5f, - 0x75, 0x6e, 0x64, 0x65, 0x72, 0x6c, 0x69, 0x6e, - 0x65, 0x22, 0x3e, 0x54, 0x72, 0x75, 0x65, 0x3c, - 0x2f, 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, - 0x79, 0x3e, 0x3c, 0x70, 0x72, 0x6f, 0x70, 0x65, - 0x72, 0x74, 0x79, 0x20, 0x6e, 0x61, 0x6d, 0x65, - 0x3d, 0x22, 0x75, 0x73, 0x65, 0x5f, 0x73, 0x74, - 0x6f, 0x63, 0x6b, 0x22, 0x3e, 0x46, 0x61, 0x6c, - 0x73, 0x65, 0x3c, 0x2f, 0x70, 0x72, 0x6f, 0x70, - 0x65, 0x72, 0x74, 0x79, 0x3e, 0x3c, 0x63, 0x68, - 0x69, 0x6c, 0x64, 0x20, 0x74, 0x79, 0x70, 0x65, - 0x3d, 0x22, 0x73, 0x75, 0x62, 0x6d, 0x65, 0x6e, - 0x75, 0x22, 0x3e, 0x3c, 0x6f, 0x62, 0x6a, 0x65, - 0x63, 0x74, 0x20, 0x63, 0x6c, 0x61, 0x73, 0x73, - 0x3d, 0x22, 0x47, 0x74, 0x6b, 0x4d, 0x65, 0x6e, - 0x75, 0x22, 0x20, 0x69, 0x64, 0x3d, 0x22, 0x73, - 0x63, 0x61, 0x6e, 0x5f, 0x6d, 0x65, 0x6e, 0x75, - 0x22, 0x3e, 0x3c, 0x70, 0x72, 0x6f, 0x70, 0x65, - 0x72, 0x74, 0x79, 0x20, 0x6e, 0x61, 0x6d, 0x65, - 0x3d, 0x22, 0x76, 0x69, 0x73, 0x69, 0x62, 0x6c, - 0x65, 0x22, 0x3e, 0x54, 0x72, 0x75, 0x65, 0x3c, - 0x2f, 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, - 0x79, 0x3e, 0x3c, 0x70, 0x72, 0x6f, 0x70, 0x65, - 0x72, 0x74, 0x79, 0x20, 0x6e, 0x61, 0x6d, 0x65, - 0x3d, 0x22, 0x63, 0x61, 0x6e, 0x5f, 0x66, 0x6f, - 0x63, 0x75, 0x73, 0x22, 0x3e, 0x46, 0x61, 0x6c, - 0x73, 0x65, 0x3c, 0x2f, 0x70, 0x72, 0x6f, 0x70, - 0x65, 0x72, 0x74, 0x79, 0x3e, 0x3c, 0x63, 0x68, - 0x69, 0x6c, 0x64, 0x3e, 0x3c, 0x6f, 0x62, 0x6a, - 0x65, 0x63, 0x74, 0x20, 0x63, 0x6c, 0x61, 0x73, - 0x73, 0x3d, 0x22, 0x47, 0x74, 0x6b, 0x4d, 0x65, - 0x6e, 0x75, 0x49, 0x74, 0x65, 0x6d, 0x22, 0x20, - 0x69, 0x64, 0x3d, 0x22, 0x73, 0x63, 0x61, 0x6e, - 0x5f, 0x73, 0x69, 0x6e, 0x67, 0x6c, 0x65, 0x5f, - 0x6d, 0x65, 0x6e, 0x75, 0x69, 0x74, 0x65, 0x6d, - 0x22, 0x3e, 0x3c, 0x70, 0x72, 0x6f, 0x70, 0x65, - 0x72, 0x74, 0x79, 0x20, 0x6e, 0x61, 0x6d, 0x65, - 0x3d, 0x22, 0x76, 0x69, 0x73, 0x69, 0x62, 0x6c, - 0x65, 0x22, 0x3e, 0x54, 0x72, 0x75, 0x65, 0x3c, - 0x2f, 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, - 0x79, 0x3e, 0x3c, 0x70, 0x72, 0x6f, 0x70, 0x65, - 0x72, 0x74, 0x79, 0x20, 0x6e, 0x61, 0x6d, 0x65, - 0x3d, 0x22, 0x63, 0x61, 0x6e, 0x5f, 0x66, 0x6f, - 0x63, 0x75, 0x73, 0x22, 0x3e, 0x46, 0x61, 0x6c, - 0x73, 0x65, 0x3c, 0x2f, 0x70, 0x72, 0x6f, 0x70, - 0x65, 0x72, 0x74, 0x79, 0x3e, 0x3c, 0x70, 0x72, - 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, 0x20, 0x6e, - 0x61, 0x6d, 0x65, 0x3d, 0x22, 0x6c, 0x61, 0x62, - 0x65, 0x6c, 0x22, 0x20, 0x74, 0x72, 0x61, 0x6e, - 0x73, 0x6c, 0x61, 0x74, 0x61, 0x62, 0x6c, 0x65, - 0x3d, 0x22, 0x79, 0x65, 0x73, 0x22, 0x20, 0x63, - 0x6f, 0x6d, 0x6d, 0x65, 0x6e, 0x74, 0x73, 0x3d, - 0x22, 0x53, 0x63, 0x61, 0x6e, 0x20, 0x6d, 0x65, - 0x6e, 0x75, 0x20, 0x69, 0x74, 0x65, 0x6d, 0x20, - 0x74, 0x6f, 0x20, 0x73, 0x63, 0x61, 0x6e, 0x20, - 0x61, 0x20, 0x73, 0x69, 0x6e, 0x67, 0x6c, 0x65, - 0x20, 0x70, 0x61, 0x67, 0x65, 0x20, 0x66, 0x72, - 0x6f, 0x6d, 0x20, 0x74, 0x68, 0x65, 0x20, 0x73, - 0x63, 0x61, 0x6e, 0x6e, 0x65, 0x72, 0x22, 0x3e, - 0x53, 0x69, 0x6e, 0x67, 0x6c, 0x65, 0x20, 0x5f, - 0x50, 0x61, 0x67, 0x65, 0x3c, 0x2f, 0x70, 0x72, - 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, 0x3e, 0x3c, - 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, - 0x20, 0x6e, 0x61, 0x6d, 0x65, 0x3d, 0x22, 0x75, - 0x73, 0x65, 0x5f, 0x75, 0x6e, 0x64, 0x65, 0x72, - 0x6c, 0x69, 0x6e, 0x65, 0x22, 0x3e, 0x54, 0x72, - 0x75, 0x65, 0x3c, 0x2f, 0x70, 0x72, 0x6f, 0x70, - 0x65, 0x72, 0x74, 0x79, 0x3e, 0x3c, 0x61, 0x63, - 0x63, 0x65, 0x6c, 0x65, 0x72, 0x61, 0x74, 0x6f, - 0x72, 0x20, 0x6b, 0x65, 0x79, 0x3d, 0x22, 0x31, - 0x22, 0x20, 0x73, 0x69, 0x67, 0x6e, 0x61, 0x6c, - 0x3d, 0x22, 0x61, 0x63, 0x74, 0x69, 0x76, 0x61, - 0x74, 0x65, 0x22, 0x20, 0x6d, 0x6f, 0x64, 0x69, - 0x66, 0x69, 0x65, 0x72, 0x73, 0x3d, 0x22, 0x47, - 0x44, 0x4b, 0x5f, 0x43, 0x4f, 0x4e, 0x54, 0x52, - 0x4f, 0x4c, 0x5f, 0x4d, 0x41, 0x53, 0x4b, 0x22, - 0x2f, 0x3e, 0x3c, 0x73, 0x69, 0x67, 0x6e, 0x61, - 0x6c, 0x20, 0x6e, 0x61, 0x6d, 0x65, 0x3d, 0x22, - 0x61, 0x63, 0x74, 0x69, 0x76, 0x61, 0x74, 0x65, - 0x22, 0x20, 0x68, 0x61, 0x6e, 0x64, 0x6c, 0x65, - 0x72, 0x3d, 0x22, 0x73, 0x63, 0x61, 0x6e, 0x5f, - 0x62, 0x75, 0x74, 0x74, 0x6f, 0x6e, 0x5f, 0x63, - 0x6c, 0x69, 0x63, 0x6b, 0x65, 0x64, 0x5f, 0x63, - 0x62, 0x22, 0x20, 0x73, 0x77, 0x61, 0x70, 0x70, - 0x65, 0x64, 0x3d, 0x22, 0x6e, 0x6f, 0x22, 0x2f, - 0x3e, 0x3c, 0x2f, 0x6f, 0x62, 0x6a, 0x65, 0x63, - 0x74, 0x3e, 0x3c, 0x2f, 0x63, 0x68, 0x69, 0x6c, - 0x64, 0x3e, 0x3c, 0x63, 0x68, 0x69, 0x6c, 0x64, - 0x3e, 0x3c, 0x6f, 0x62, 0x6a, 0x65, 0x63, 0x74, - 0x20, 0x63, 0x6c, 0x61, 0x73, 0x73, 0x3d, 0x22, - 0x47, 0x74, 0x6b, 0x4d, 0x65, 0x6e, 0x75, 0x49, - 0x74, 0x65, 0x6d, 0x22, 0x20, 0x69, 0x64, 0x3d, - 0x22, 0x73, 0x63, 0x61, 0x6e, 0x5f, 0x61, 0x6c, - 0x6c, 0x5f, 0x6d, 0x65, 0x6e, 0x75, 0x69, 0x74, - 0x65, 0x6d, 0x22, 0x3e, 0x3c, 0x70, 0x72, 0x6f, - 0x70, 0x65, 0x72, 0x74, 0x79, 0x20, 0x6e, 0x61, - 0x6d, 0x65, 0x3d, 0x22, 0x76, 0x69, 0x73, 0x69, - 0x62, 0x6c, 0x65, 0x22, 0x3e, 0x54, 0x72, 0x75, - 0x65, 0x3c, 0x2f, 0x70, 0x72, 0x6f, 0x70, 0x65, - 0x72, 0x74, 0x79, 0x3e, 0x3c, 0x70, 0x72, 0x6f, - 0x70, 0x65, 0x72, 0x74, 0x79, 0x20, 0x6e, 0x61, - 0x6d, 0x65, 0x3d, 0x22, 0x63, 0x61, 0x6e, 0x5f, - 0x66, 0x6f, 0x63, 0x75, 0x73, 0x22, 0x3e, 0x46, - 0x61, 0x6c, 0x73, 0x65, 0x3c, 0x2f, 0x70, 0x72, - 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, 0x3e, 0x3c, - 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, - 0x20, 0x6e, 0x61, 0x6d, 0x65, 0x3d, 0x22, 0x6c, - 0x61, 0x62, 0x65, 0x6c, 0x22, 0x20, 0x74, 0x72, - 0x61, 0x6e, 0x73, 0x6c, 0x61, 0x74, 0x61, 0x62, - 0x6c, 0x65, 0x3d, 0x22, 0x79, 0x65, 0x73, 0x22, - 0x20, 0x63, 0x6f, 0x6d, 0x6d, 0x65, 0x6e, 0x74, - 0x73, 0x3d, 0x22, 0x53, 0x63, 0x61, 0x6e, 0x20, - 0x6d, 0x65, 0x6e, 0x75, 0x20, 0x69, 0x74, 0x65, - 0x6d, 0x20, 0x74, 0x6f, 0x20, 0x73, 0x63, 0x61, - 0x6e, 0x20, 0x61, 0x6c, 0x6c, 0x20, 0x70, 0x61, - 0x67, 0x65, 0x73, 0x20, 0x66, 0x72, 0x6f, 0x6d, - 0x20, 0x61, 0x20, 0x64, 0x6f, 0x63, 0x75, 0x6d, - 0x65, 0x6e, 0x74, 0x20, 0x66, 0x65, 0x65, 0x64, - 0x65, 0x72, 0x22, 0x3e, 0x41, 0x6c, 0x6c, 0x20, - 0x50, 0x61, 0x67, 0x65, 0x73, 0x20, 0x46, 0x72, - 0x6f, 0x6d, 0x20, 0x5f, 0x46, 0x65, 0x65, 0x64, - 0x65, 0x72, 0x3c, 0x2f, 0x70, 0x72, 0x6f, 0x70, - 0x65, 0x72, 0x74, 0x79, 0x3e, 0x3c, 0x70, 0x72, - 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, 0x20, 0x6e, - 0x61, 0x6d, 0x65, 0x3d, 0x22, 0x75, 0x73, 0x65, - 0x5f, 0x75, 0x6e, 0x64, 0x65, 0x72, 0x6c, 0x69, - 0x6e, 0x65, 0x22, 0x3e, 0x54, 0x72, 0x75, 0x65, - 0x3c, 0x2f, 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, - 0x74, 0x79, 0x3e, 0x3c, 0x61, 0x63, 0x63, 0x65, - 0x6c, 0x65, 0x72, 0x61, 0x74, 0x6f, 0x72, 0x20, - 0x6b, 0x65, 0x79, 0x3d, 0x22, 0x66, 0x22, 0x20, - 0x73, 0x69, 0x67, 0x6e, 0x61, 0x6c, 0x3d, 0x22, - 0x61, 0x63, 0x74, 0x69, 0x76, 0x61, 0x74, 0x65, - 0x22, 0x20, 0x6d, 0x6f, 0x64, 0x69, 0x66, 0x69, - 0x65, 0x72, 0x73, 0x3d, 0x22, 0x47, 0x44, 0x4b, - 0x5f, 0x43, 0x4f, 0x4e, 0x54, 0x52, 0x4f, 0x4c, - 0x5f, 0x4d, 0x41, 0x53, 0x4b, 0x22, 0x2f, 0x3e, - 0x3c, 0x73, 0x69, 0x67, 0x6e, 0x61, 0x6c, 0x20, - 0x6e, 0x61, 0x6d, 0x65, 0x3d, 0x22, 0x61, 0x63, - 0x74, 0x69, 0x76, 0x61, 0x74, 0x65, 0x22, 0x20, - 0x68, 0x61, 0x6e, 0x64, 0x6c, 0x65, 0x72, 0x3d, - 0x22, 0x63, 0x6f, 0x6e, 0x74, 0x69, 0x6e, 0x75, - 0x6f, 0x75, 0x73, 0x5f, 0x73, 0x63, 0x61, 0x6e, - 0x5f, 0x62, 0x75, 0x74, 0x74, 0x6f, 0x6e, 0x5f, - 0x63, 0x6c, 0x69, 0x63, 0x6b, 0x65, 0x64, 0x5f, - 0x63, 0x62, 0x22, 0x20, 0x73, 0x77, 0x61, 0x70, - 0x70, 0x65, 0x64, 0x3d, 0x22, 0x6e, 0x6f, 0x22, - 0x2f, 0x3e, 0x3c, 0x2f, 0x6f, 0x62, 0x6a, 0x65, - 0x63, 0x74, 0x3e, 0x3c, 0x2f, 0x63, 0x68, 0x69, - 0x6c, 0x64, 0x3e, 0x3c, 0x63, 0x68, 0x69, 0x6c, - 0x64, 0x3e, 0x3c, 0x6f, 0x62, 0x6a, 0x65, 0x63, - 0x74, 0x20, 0x63, 0x6c, 0x61, 0x73, 0x73, 0x3d, - 0x22, 0x47, 0x74, 0x6b, 0x4d, 0x65, 0x6e, 0x75, - 0x49, 0x74, 0x65, 0x6d, 0x22, 0x20, 0x69, 0x64, - 0x3d, 0x22, 0x73, 0x74, 0x6f, 0x70, 0x5f, 0x73, - 0x63, 0x61, 0x6e, 0x5f, 0x6d, 0x65, 0x6e, 0x75, - 0x69, 0x74, 0x65, 0x6d, 0x22, 0x3e, 0x3c, 0x70, - 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, 0x20, - 0x6e, 0x61, 0x6d, 0x65, 0x3d, 0x22, 0x76, 0x69, - 0x73, 0x69, 0x62, 0x6c, 0x65, 0x22, 0x3e, 0x54, - 0x72, 0x75, 0x65, 0x3c, 0x2f, 0x70, 0x72, 0x6f, - 0x70, 0x65, 0x72, 0x74, 0x79, 0x3e, 0x3c, 0x70, - 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, 0x20, - 0x6e, 0x61, 0x6d, 0x65, 0x3d, 0x22, 0x73, 0x65, - 0x6e, 0x73, 0x69, 0x74, 0x69, 0x76, 0x65, 0x22, - 0x3e, 0x46, 0x61, 0x6c, 0x73, 0x65, 0x3c, 0x2f, - 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, - 0x3e, 0x3c, 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, - 0x74, 0x79, 0x20, 0x6e, 0x61, 0x6d, 0x65, 0x3d, - 0x22, 0x63, 0x61, 0x6e, 0x5f, 0x66, 0x6f, 0x63, - 0x75, 0x73, 0x22, 0x3e, 0x46, 0x61, 0x6c, 0x73, - 0x65, 0x3c, 0x2f, 0x70, 0x72, 0x6f, 0x70, 0x65, - 0x72, 0x74, 0x79, 0x3e, 0x3c, 0x70, 0x72, 0x6f, - 0x70, 0x65, 0x72, 0x74, 0x79, 0x20, 0x6e, 0x61, - 0x6d, 0x65, 0x3d, 0x22, 0x6c, 0x61, 0x62, 0x65, - 0x6c, 0x22, 0x20, 0x74, 0x72, 0x61, 0x6e, 0x73, - 0x6c, 0x61, 0x74, 0x61, 0x62, 0x6c, 0x65, 0x3d, - 0x22, 0x79, 0x65, 0x73, 0x22, 0x20, 0x63, 0x6f, - 0x6d, 0x6d, 0x65, 0x6e, 0x74, 0x73, 0x3d, 0x22, - 0x4d, 0x65, 0x6e, 0x75, 0x20, 0x65, 0x6e, 0x74, - 0x72, 0x79, 0x20, 0x74, 0x6f, 0x20, 0x73, 0x74, - 0x6f, 0x70, 0x20, 0x63, 0x75, 0x72, 0x72, 0x65, - 0x6e, 0x74, 0x20, 0x73, 0x63, 0x61, 0x6e, 0x22, - 0x3e, 0x5f, 0x53, 0x74, 0x6f, 0x70, 0x20, 0x53, - 0x63, 0x61, 0x6e, 0x3c, 0x2f, 0x70, 0x72, 0x6f, - 0x70, 0x65, 0x72, 0x74, 0x79, 0x3e, 0x3c, 0x70, - 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, 0x20, - 0x6e, 0x61, 0x6d, 0x65, 0x3d, 0x22, 0x75, 0x73, - 0x65, 0x5f, 0x75, 0x6e, 0x64, 0x65, 0x72, 0x6c, - 0x69, 0x6e, 0x65, 0x22, 0x3e, 0x54, 0x72, 0x75, - 0x65, 0x3c, 0x2f, 0x70, 0x72, 0x6f, 0x70, 0x65, - 0x72, 0x74, 0x79, 0x3e, 0x3c, 0x61, 0x63, 0x63, - 0x65, 0x6c, 0x65, 0x72, 0x61, 0x74, 0x6f, 0x72, - 0x20, 0x6b, 0x65, 0x79, 0x3d, 0x22, 0x45, 0x73, - 0x63, 0x61, 0x70, 0x65, 0x22, 0x20, 0x73, 0x69, - 0x67, 0x6e, 0x61, 0x6c, 0x3d, 0x22, 0x61, 0x63, - 0x74, 0x69, 0x76, 0x61, 0x74, 0x65, 0x22, 0x2f, - 0x3e, 0x3c, 0x73, 0x69, 0x67, 0x6e, 0x61, 0x6c, - 0x20, 0x6e, 0x61, 0x6d, 0x65, 0x3d, 0x22, 0x61, - 0x63, 0x74, 0x69, 0x76, 0x61, 0x74, 0x65, 0x22, - 0x20, 0x68, 0x61, 0x6e, 0x64, 0x6c, 0x65, 0x72, - 0x3d, 0x22, 0x73, 0x74, 0x6f, 0x70, 0x5f, 0x73, - 0x63, 0x61, 0x6e, 0x5f, 0x62, 0x75, 0x74, 0x74, - 0x6f, 0x6e, 0x5f, 0x63, 0x6c, 0x69, 0x63, 0x6b, - 0x65, 0x64, 0x5f, 0x63, 0x62, 0x22, 0x20, 0x73, - 0x77, 0x61, 0x70, 0x70, 0x65, 0x64, 0x3d, 0x22, - 0x6e, 0x6f, 0x22, 0x2f, 0x3e, 0x3c, 0x2f, 0x6f, - 0x62, 0x6a, 0x65, 0x63, 0x74, 0x3e, 0x3c, 0x2f, - 0x63, 0x68, 0x69, 0x6c, 0x64, 0x3e, 0x3c, 0x63, - 0x68, 0x69, 0x6c, 0x64, 0x3e, 0x3c, 0x6f, 0x62, - 0x6a, 0x65, 0x63, 0x74, 0x20, 0x63, 0x6c, 0x61, - 0x73, 0x73, 0x3d, 0x22, 0x47, 0x74, 0x6b, 0x53, - 0x65, 0x70, 0x61, 0x72, 0x61, 0x74, 0x6f, 0x72, - 0x4d, 0x65, 0x6e, 0x75, 0x49, 0x74, 0x65, 0x6d, - 0x22, 0x20, 0x69, 0x64, 0x3d, 0x22, 0x6d, 0x65, - 0x6e, 0x75, 0x69, 0x74, 0x65, 0x6d, 0x32, 0x22, - 0x3e, 0x3c, 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, - 0x74, 0x79, 0x20, 0x6e, 0x61, 0x6d, 0x65, 0x3d, - 0x22, 0x76, 0x69, 0x73, 0x69, 0x62, 0x6c, 0x65, - 0x22, 0x3e, 0x54, 0x72, 0x75, 0x65, 0x3c, 0x2f, - 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, - 0x3e, 0x3c, 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, - 0x74, 0x79, 0x20, 0x6e, 0x61, 0x6d, 0x65, 0x3d, - 0x22, 0x63, 0x61, 0x6e, 0x5f, 0x66, 0x6f, 0x63, - 0x75, 0x73, 0x22, 0x3e, 0x46, 0x61, 0x6c, 0x73, - 0x65, 0x3c, 0x2f, 0x70, 0x72, 0x6f, 0x70, 0x65, - 0x72, 0x74, 0x79, 0x3e, 0x3c, 0x2f, 0x6f, 0x62, - 0x6a, 0x65, 0x63, 0x74, 0x3e, 0x3c, 0x2f, 0x63, - 0x68, 0x69, 0x6c, 0x64, 0x3e, 0x3c, 0x63, 0x68, - 0x69, 0x6c, 0x64, 0x3e, 0x3c, 0x6f, 0x62, 0x6a, - 0x65, 0x63, 0x74, 0x20, 0x63, 0x6c, 0x61, 0x73, - 0x73, 0x3d, 0x22, 0x47, 0x74, 0x6b, 0x52, 0x61, - 0x64, 0x69, 0x6f, 0x4d, 0x65, 0x6e, 0x75, 0x49, - 0x74, 0x65, 0x6d, 0x22, 0x20, 0x69, 0x64, 0x3d, - 0x22, 0x74, 0x65, 0x78, 0x74, 0x5f, 0x6d, 0x65, - 0x6e, 0x75, 0x69, 0x74, 0x65, 0x6d, 0x22, 0x3e, - 0x3c, 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, - 0x79, 0x20, 0x6e, 0x61, 0x6d, 0x65, 0x3d, 0x22, - 0x76, 0x69, 0x73, 0x69, 0x62, 0x6c, 0x65, 0x22, - 0x3e, 0x54, 0x72, 0x75, 0x65, 0x3c, 0x2f, 0x70, - 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, 0x3e, - 0x3c, 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, - 0x79, 0x20, 0x6e, 0x61, 0x6d, 0x65, 0x3d, 0x22, - 0x63, 0x61, 0x6e, 0x5f, 0x66, 0x6f, 0x63, 0x75, - 0x73, 0x22, 0x3e, 0x46, 0x61, 0x6c, 0x73, 0x65, - 0x3c, 0x2f, 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, - 0x74, 0x79, 0x3e, 0x3c, 0x70, 0x72, 0x6f, 0x70, - 0x65, 0x72, 0x74, 0x79, 0x20, 0x6e, 0x61, 0x6d, - 0x65, 0x3d, 0x22, 0x6c, 0x61, 0x62, 0x65, 0x6c, - 0x22, 0x20, 0x74, 0x72, 0x61, 0x6e, 0x73, 0x6c, - 0x61, 0x74, 0x61, 0x62, 0x6c, 0x65, 0x3d, 0x22, - 0x79, 0x65, 0x73, 0x22, 0x3e, 0x54, 0x65, 0x78, - 0x74, 0x3c, 0x2f, 0x70, 0x72, 0x6f, 0x70, 0x65, - 0x72, 0x74, 0x79, 0x3e, 0x3c, 0x70, 0x72, 0x6f, - 0x70, 0x65, 0x72, 0x74, 0x79, 0x20, 0x6e, 0x61, - 0x6d, 0x65, 0x3d, 0x22, 0x75, 0x73, 0x65, 0x5f, - 0x75, 0x6e, 0x64, 0x65, 0x72, 0x6c, 0x69, 0x6e, - 0x65, 0x22, 0x3e, 0x54, 0x72, 0x75, 0x65, 0x3c, - 0x2f, 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, - 0x79, 0x3e, 0x3c, 0x70, 0x72, 0x6f, 0x70, 0x65, - 0x72, 0x74, 0x79, 0x20, 0x6e, 0x61, 0x6d, 0x65, - 0x3d, 0x22, 0x64, 0x72, 0x61, 0x77, 0x5f, 0x61, - 0x73, 0x5f, 0x72, 0x61, 0x64, 0x69, 0x6f, 0x22, - 0x3e, 0x54, 0x72, 0x75, 0x65, 0x3c, 0x2f, 0x70, - 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, 0x3e, - 0x3c, 0x73, 0x69, 0x67, 0x6e, 0x61, 0x6c, 0x20, - 0x6e, 0x61, 0x6d, 0x65, 0x3d, 0x22, 0x74, 0x6f, - 0x67, 0x67, 0x6c, 0x65, 0x64, 0x22, 0x20, 0x68, - 0x61, 0x6e, 0x64, 0x6c, 0x65, 0x72, 0x3d, 0x22, - 0x74, 0x65, 0x78, 0x74, 0x5f, 0x6d, 0x65, 0x6e, - 0x75, 0x69, 0x74, 0x65, 0x6d, 0x5f, 0x74, 0x6f, - 0x67, 0x67, 0x6c, 0x65, 0x64, 0x5f, 0x63, 0x62, - 0x22, 0x20, 0x73, 0x77, 0x61, 0x70, 0x70, 0x65, - 0x64, 0x3d, 0x22, 0x6e, 0x6f, 0x22, 0x2f, 0x3e, - 0x3c, 0x2f, 0x6f, 0x62, 0x6a, 0x65, 0x63, 0x74, - 0x3e, 0x3c, 0x2f, 0x63, 0x68, 0x69, 0x6c, 0x64, - 0x3e, 0x3c, 0x63, 0x68, 0x69, 0x6c, 0x64, 0x3e, - 0x3c, 0x6f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x20, - 0x63, 0x6c, 0x61, 0x73, 0x73, 0x3d, 0x22, 0x47, - 0x74, 0x6b, 0x52, 0x61, 0x64, 0x69, 0x6f, 0x4d, - 0x65, 0x6e, 0x75, 0x49, 0x74, 0x65, 0x6d, 0x22, - 0x20, 0x69, 0x64, 0x3d, 0x22, 0x70, 0x68, 0x6f, - 0x74, 0x6f, 0x5f, 0x6d, 0x65, 0x6e, 0x75, 0x69, - 0x74, 0x65, 0x6d, 0x22, 0x3e, 0x3c, 0x70, 0x72, - 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, 0x20, 0x6e, - 0x61, 0x6d, 0x65, 0x3d, 0x22, 0x76, 0x69, 0x73, - 0x69, 0x62, 0x6c, 0x65, 0x22, 0x3e, 0x54, 0x72, - 0x75, 0x65, 0x3c, 0x2f, 0x70, 0x72, 0x6f, 0x70, - 0x65, 0x72, 0x74, 0x79, 0x3e, 0x3c, 0x70, 0x72, - 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, 0x20, 0x6e, - 0x61, 0x6d, 0x65, 0x3d, 0x22, 0x63, 0x61, 0x6e, - 0x5f, 0x66, 0x6f, 0x63, 0x75, 0x73, 0x22, 0x3e, - 0x46, 0x61, 0x6c, 0x73, 0x65, 0x3c, 0x2f, 0x70, - 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, 0x3e, - 0x3c, 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, - 0x79, 0x20, 0x6e, 0x61, 0x6d, 0x65, 0x3d, 0x22, - 0x6c, 0x61, 0x62, 0x65, 0x6c, 0x22, 0x20, 0x74, - 0x72, 0x61, 0x6e, 0x73, 0x6c, 0x61, 0x74, 0x61, - 0x62, 0x6c, 0x65, 0x3d, 0x22, 0x79, 0x65, 0x73, - 0x22, 0x3e, 0x50, 0x68, 0x6f, 0x74, 0x6f, 0x3c, - 0x2f, 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, - 0x79, 0x3e, 0x3c, 0x70, 0x72, 0x6f, 0x70, 0x65, - 0x72, 0x74, 0x79, 0x20, 0x6e, 0x61, 0x6d, 0x65, - 0x3d, 0x22, 0x75, 0x73, 0x65, 0x5f, 0x75, 0x6e, - 0x64, 0x65, 0x72, 0x6c, 0x69, 0x6e, 0x65, 0x22, - 0x3e, 0x54, 0x72, 0x75, 0x65, 0x3c, 0x2f, 0x70, - 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, 0x3e, - 0x3c, 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, - 0x79, 0x20, 0x6e, 0x61, 0x6d, 0x65, 0x3d, 0x22, - 0x61, 0x63, 0x74, 0x69, 0x76, 0x65, 0x22, 0x3e, - 0x54, 0x72, 0x75, 0x65, 0x3c, 0x2f, 0x70, 0x72, - 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, 0x3e, 0x3c, - 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, - 0x20, 0x6e, 0x61, 0x6d, 0x65, 0x3d, 0x22, 0x64, - 0x72, 0x61, 0x77, 0x5f, 0x61, 0x73, 0x5f, 0x72, - 0x61, 0x64, 0x69, 0x6f, 0x22, 0x3e, 0x54, 0x72, - 0x75, 0x65, 0x3c, 0x2f, 0x70, 0x72, 0x6f, 0x70, - 0x65, 0x72, 0x74, 0x79, 0x3e, 0x3c, 0x70, 0x72, - 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, 0x20, 0x6e, - 0x61, 0x6d, 0x65, 0x3d, 0x22, 0x67, 0x72, 0x6f, - 0x75, 0x70, 0x22, 0x3e, 0x74, 0x65, 0x78, 0x74, - 0x5f, 0x6d, 0x65, 0x6e, 0x75, 0x69, 0x74, 0x65, - 0x6d, 0x3c, 0x2f, 0x70, 0x72, 0x6f, 0x70, 0x65, - 0x72, 0x74, 0x79, 0x3e, 0x3c, 0x73, 0x69, 0x67, - 0x6e, 0x61, 0x6c, 0x20, 0x6e, 0x61, 0x6d, 0x65, - 0x3d, 0x22, 0x74, 0x6f, 0x67, 0x67, 0x6c, 0x65, - 0x64, 0x22, 0x20, 0x68, 0x61, 0x6e, 0x64, 0x6c, - 0x65, 0x72, 0x3d, 0x22, 0x70, 0x68, 0x6f, 0x74, - 0x6f, 0x5f, 0x6d, 0x65, 0x6e, 0x75, 0x69, 0x74, - 0x65, 0x6d, 0x5f, 0x74, 0x6f, 0x67, 0x67, 0x6c, - 0x65, 0x64, 0x5f, 0x63, 0x62, 0x22, 0x20, 0x73, - 0x77, 0x61, 0x70, 0x70, 0x65, 0x64, 0x3d, 0x22, - 0x6e, 0x6f, 0x22, 0x2f, 0x3e, 0x3c, 0x2f, 0x6f, - 0x62, 0x6a, 0x65, 0x63, 0x74, 0x3e, 0x3c, 0x2f, - 0x63, 0x68, 0x69, 0x6c, 0x64, 0x3e, 0x3c, 0x2f, - 0x6f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x3e, 0x3c, - 0x2f, 0x63, 0x68, 0x69, 0x6c, 0x64, 0x3e, 0x3c, - 0x2f, 0x6f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x3e, - 0x3c, 0x2f, 0x63, 0x68, 0x69, 0x6c, 0x64, 0x3e, - 0x3c, 0x63, 0x68, 0x69, 0x6c, 0x64, 0x3e, 0x3c, - 0x6f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x20, 0x63, - 0x6c, 0x61, 0x73, 0x73, 0x3d, 0x22, 0x47, 0x74, - 0x6b, 0x4d, 0x65, 0x6e, 0x75, 0x49, 0x74, 0x65, - 0x6d, 0x22, 0x20, 0x69, 0x64, 0x3d, 0x22, 0x72, - 0x65, 0x6f, 0x72, 0x64, 0x65, 0x72, 0x5f, 0x6d, - 0x65, 0x6e, 0x75, 0x69, 0x74, 0x65, 0x6d, 0x22, - 0x3e, 0x3c, 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, - 0x74, 0x79, 0x20, 0x6e, 0x61, 0x6d, 0x65, 0x3d, - 0x22, 0x76, 0x69, 0x73, 0x69, 0x62, 0x6c, 0x65, - 0x22, 0x3e, 0x54, 0x72, 0x75, 0x65, 0x3c, 0x2f, - 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, - 0x3e, 0x3c, 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, - 0x74, 0x79, 0x20, 0x6e, 0x61, 0x6d, 0x65, 0x3d, - 0x22, 0x63, 0x61, 0x6e, 0x5f, 0x66, 0x6f, 0x63, - 0x75, 0x73, 0x22, 0x3e, 0x46, 0x61, 0x6c, 0x73, - 0x65, 0x3c, 0x2f, 0x70, 0x72, 0x6f, 0x70, 0x65, - 0x72, 0x74, 0x79, 0x3e, 0x3c, 0x70, 0x72, 0x6f, - 0x70, 0x65, 0x72, 0x74, 0x79, 0x20, 0x6e, 0x61, - 0x6d, 0x65, 0x3d, 0x22, 0x6c, 0x61, 0x62, 0x65, - 0x6c, 0x22, 0x20, 0x74, 0x72, 0x61, 0x6e, 0x73, - 0x6c, 0x61, 0x74, 0x61, 0x62, 0x6c, 0x65, 0x3d, - 0x22, 0x79, 0x65, 0x73, 0x22, 0x20, 0x63, 0x6f, - 0x6d, 0x6d, 0x65, 0x6e, 0x74, 0x73, 0x3d, 0x22, - 0x4d, 0x65, 0x6e, 0x75, 0x20, 0x69, 0x74, 0x65, - 0x6d, 0x20, 0x74, 0x6f, 0x20, 0x72, 0x65, 0x6f, - 0x72, 0x64, 0x65, 0x72, 0x20, 0x70, 0x61, 0x67, - 0x65, 0x73, 0x22, 0x3e, 0x52, 0x65, 0x6f, 0x72, - 0x64, 0x65, 0x72, 0x20, 0x50, 0x61, 0x67, 0x65, - 0x73, 0x3c, 0x2f, 0x70, 0x72, 0x6f, 0x70, 0x65, - 0x72, 0x74, 0x79, 0x3e, 0x3c, 0x70, 0x72, 0x6f, - 0x70, 0x65, 0x72, 0x74, 0x79, 0x20, 0x6e, 0x61, - 0x6d, 0x65, 0x3d, 0x22, 0x75, 0x73, 0x65, 0x5f, - 0x75, 0x6e, 0x64, 0x65, 0x72, 0x6c, 0x69, 0x6e, - 0x65, 0x22, 0x3e, 0x54, 0x72, 0x75, 0x65, 0x3c, - 0x2f, 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, - 0x79, 0x3e, 0x3c, 0x73, 0x69, 0x67, 0x6e, 0x61, - 0x6c, 0x20, 0x6e, 0x61, 0x6d, 0x65, 0x3d, 0x22, - 0x61, 0x63, 0x74, 0x69, 0x76, 0x61, 0x74, 0x65, - 0x22, 0x20, 0x68, 0x61, 0x6e, 0x64, 0x6c, 0x65, - 0x72, 0x3d, 0x22, 0x72, 0x65, 0x6f, 0x72, 0x64, - 0x65, 0x72, 0x5f, 0x6d, 0x65, 0x6e, 0x75, 0x69, - 0x74, 0x65, 0x6d, 0x5f, 0x61, 0x63, 0x74, 0x69, - 0x76, 0x61, 0x74, 0x65, 0x5f, 0x63, 0x62, 0x22, - 0x20, 0x73, 0x77, 0x61, 0x70, 0x70, 0x65, 0x64, - 0x3d, 0x22, 0x6e, 0x6f, 0x22, 0x2f, 0x3e, 0x3c, - 0x2f, 0x6f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x3e, - 0x3c, 0x2f, 0x63, 0x68, 0x69, 0x6c, 0x64, 0x3e, - 0x3c, 0x63, 0x68, 0x69, 0x6c, 0x64, 0x3e, 0x3c, - 0x6f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x20, 0x63, - 0x6c, 0x61, 0x73, 0x73, 0x3d, 0x22, 0x47, 0x74, - 0x6b, 0x49, 0x6d, 0x61, 0x67, 0x65, 0x4d, 0x65, - 0x6e, 0x75, 0x49, 0x74, 0x65, 0x6d, 0x22, 0x20, - 0x69, 0x64, 0x3d, 0x22, 0x73, 0x61, 0x76, 0x65, - 0x5f, 0x6d, 0x65, 0x6e, 0x75, 0x69, 0x74, 0x65, - 0x6d, 0x22, 0x3e, 0x3c, 0x70, 0x72, 0x6f, 0x70, - 0x65, 0x72, 0x74, 0x79, 0x20, 0x6e, 0x61, 0x6d, - 0x65, 0x3d, 0x22, 0x6c, 0x61, 0x62, 0x65, 0x6c, - 0x22, 0x3e, 0x67, 0x74, 0x6b, 0x2d, 0x73, 0x61, - 0x76, 0x65, 0x3c, 0x2f, 0x70, 0x72, 0x6f, 0x70, - 0x65, 0x72, 0x74, 0x79, 0x3e, 0x3c, 0x70, 0x72, - 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, 0x20, 0x6e, - 0x61, 0x6d, 0x65, 0x3d, 0x22, 0x76, 0x69, 0x73, - 0x69, 0x62, 0x6c, 0x65, 0x22, 0x3e, 0x54, 0x72, - 0x75, 0x65, 0x3c, 0x2f, 0x70, 0x72, 0x6f, 0x70, - 0x65, 0x72, 0x74, 0x79, 0x3e, 0x3c, 0x70, 0x72, - 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, 0x20, 0x6e, - 0x61, 0x6d, 0x65, 0x3d, 0x22, 0x73, 0x65, 0x6e, - 0x73, 0x69, 0x74, 0x69, 0x76, 0x65, 0x22, 0x3e, - 0x46, 0x61, 0x6c, 0x73, 0x65, 0x3c, 0x2f, 0x70, - 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, 0x3e, - 0x3c, 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, - 0x79, 0x20, 0x6e, 0x61, 0x6d, 0x65, 0x3d, 0x22, - 0x63, 0x61, 0x6e, 0x5f, 0x66, 0x6f, 0x63, 0x75, - 0x73, 0x22, 0x3e, 0x46, 0x61, 0x6c, 0x73, 0x65, - 0x3c, 0x2f, 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, - 0x74, 0x79, 0x3e, 0x3c, 0x70, 0x72, 0x6f, 0x70, - 0x65, 0x72, 0x74, 0x79, 0x20, 0x6e, 0x61, 0x6d, - 0x65, 0x3d, 0x22, 0x75, 0x73, 0x65, 0x5f, 0x75, - 0x6e, 0x64, 0x65, 0x72, 0x6c, 0x69, 0x6e, 0x65, - 0x22, 0x3e, 0x54, 0x72, 0x75, 0x65, 0x3c, 0x2f, - 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, - 0x3e, 0x3c, 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, - 0x74, 0x79, 0x20, 0x6e, 0x61, 0x6d, 0x65, 0x3d, - 0x22, 0x75, 0x73, 0x65, 0x5f, 0x73, 0x74, 0x6f, - 0x63, 0x6b, 0x22, 0x3e, 0x54, 0x72, 0x75, 0x65, - 0x3c, 0x2f, 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, - 0x74, 0x79, 0x3e, 0x3c, 0x61, 0x63, 0x63, 0x65, - 0x6c, 0x65, 0x72, 0x61, 0x74, 0x6f, 0x72, 0x20, - 0x6b, 0x65, 0x79, 0x3d, 0x22, 0x73, 0x22, 0x20, - 0x73, 0x69, 0x67, 0x6e, 0x61, 0x6c, 0x3d, 0x22, - 0x61, 0x63, 0x74, 0x69, 0x76, 0x61, 0x74, 0x65, - 0x22, 0x20, 0x6d, 0x6f, 0x64, 0x69, 0x66, 0x69, - 0x65, 0x72, 0x73, 0x3d, 0x22, 0x47, 0x44, 0x4b, - 0x5f, 0x43, 0x4f, 0x4e, 0x54, 0x52, 0x4f, 0x4c, - 0x5f, 0x4d, 0x41, 0x53, 0x4b, 0x22, 0x2f, 0x3e, - 0x3c, 0x73, 0x69, 0x67, 0x6e, 0x61, 0x6c, 0x20, - 0x6e, 0x61, 0x6d, 0x65, 0x3d, 0x22, 0x61, 0x63, - 0x74, 0x69, 0x76, 0x61, 0x74, 0x65, 0x22, 0x20, - 0x68, 0x61, 0x6e, 0x64, 0x6c, 0x65, 0x72, 0x3d, - 0x22, 0x73, 0x61, 0x76, 0x65, 0x5f, 0x66, 0x69, - 0x6c, 0x65, 0x5f, 0x62, 0x75, 0x74, 0x74, 0x6f, - 0x6e, 0x5f, 0x63, 0x6c, 0x69, 0x63, 0x6b, 0x65, - 0x64, 0x5f, 0x63, 0x62, 0x22, 0x20, 0x73, 0x77, - 0x61, 0x70, 0x70, 0x65, 0x64, 0x3d, 0x22, 0x6e, - 0x6f, 0x22, 0x2f, 0x3e, 0x3c, 0x2f, 0x6f, 0x62, - 0x6a, 0x65, 0x63, 0x74, 0x3e, 0x3c, 0x2f, 0x63, - 0x68, 0x69, 0x6c, 0x64, 0x3e, 0x3c, 0x63, 0x68, - 0x69, 0x6c, 0x64, 0x3e, 0x3c, 0x6f, 0x62, 0x6a, - 0x65, 0x63, 0x74, 0x20, 0x63, 0x6c, 0x61, 0x73, - 0x73, 0x3d, 0x22, 0x47, 0x74, 0x6b, 0x49, 0x6d, - 0x61, 0x67, 0x65, 0x4d, 0x65, 0x6e, 0x75, 0x49, - 0x74, 0x65, 0x6d, 0x22, 0x20, 0x69, 0x64, 0x3d, - 0x22, 0x73, 0x61, 0x76, 0x65, 0x5f, 0x61, 0x73, - 0x5f, 0x6d, 0x65, 0x6e, 0x75, 0x69, 0x74, 0x65, - 0x6d, 0x22, 0x3e, 0x3c, 0x70, 0x72, 0x6f, 0x70, - 0x65, 0x72, 0x74, 0x79, 0x20, 0x6e, 0x61, 0x6d, - 0x65, 0x3d, 0x22, 0x6c, 0x61, 0x62, 0x65, 0x6c, - 0x22, 0x3e, 0x67, 0x74, 0x6b, 0x2d, 0x73, 0x61, - 0x76, 0x65, 0x2d, 0x61, 0x73, 0x3c, 0x2f, 0x70, - 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, 0x3e, - 0x3c, 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, - 0x79, 0x20, 0x6e, 0x61, 0x6d, 0x65, 0x3d, 0x22, - 0x76, 0x69, 0x73, 0x69, 0x62, 0x6c, 0x65, 0x22, - 0x3e, 0x54, 0x72, 0x75, 0x65, 0x3c, 0x2f, 0x70, - 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, 0x3e, - 0x3c, 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, - 0x79, 0x20, 0x6e, 0x61, 0x6d, 0x65, 0x3d, 0x22, - 0x73, 0x65, 0x6e, 0x73, 0x69, 0x74, 0x69, 0x76, - 0x65, 0x22, 0x3e, 0x46, 0x61, 0x6c, 0x73, 0x65, - 0x3c, 0x2f, 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, - 0x74, 0x79, 0x3e, 0x3c, 0x70, 0x72, 0x6f, 0x70, - 0x65, 0x72, 0x74, 0x79, 0x20, 0x6e, 0x61, 0x6d, - 0x65, 0x3d, 0x22, 0x63, 0x61, 0x6e, 0x5f, 0x66, - 0x6f, 0x63, 0x75, 0x73, 0x22, 0x3e, 0x46, 0x61, - 0x6c, 0x73, 0x65, 0x3c, 0x2f, 0x70, 0x72, 0x6f, - 0x70, 0x65, 0x72, 0x74, 0x79, 0x3e, 0x3c, 0x70, - 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, 0x20, - 0x6e, 0x61, 0x6d, 0x65, 0x3d, 0x22, 0x75, 0x73, - 0x65, 0x5f, 0x75, 0x6e, 0x64, 0x65, 0x72, 0x6c, - 0x69, 0x6e, 0x65, 0x22, 0x3e, 0x54, 0x72, 0x75, - 0x65, 0x3c, 0x2f, 0x70, 0x72, 0x6f, 0x70, 0x65, - 0x72, 0x74, 0x79, 0x3e, 0x3c, 0x70, 0x72, 0x6f, - 0x70, 0x65, 0x72, 0x74, 0x79, 0x20, 0x6e, 0x61, - 0x6d, 0x65, 0x3d, 0x22, 0x75, 0x73, 0x65, 0x5f, - 0x73, 0x74, 0x6f, 0x63, 0x6b, 0x22, 0x3e, 0x54, - 0x72, 0x75, 0x65, 0x3c, 0x2f, 0x70, 0x72, 0x6f, - 0x70, 0x65, 0x72, 0x74, 0x79, 0x3e, 0x3c, 0x61, - 0x63, 0x63, 0x65, 0x6c, 0x65, 0x72, 0x61, 0x74, - 0x6f, 0x72, 0x20, 0x6b, 0x65, 0x79, 0x3d, 0x22, - 0x73, 0x22, 0x20, 0x73, 0x69, 0x67, 0x6e, 0x61, - 0x6c, 0x3d, 0x22, 0x61, 0x63, 0x74, 0x69, 0x76, - 0x61, 0x74, 0x65, 0x22, 0x20, 0x6d, 0x6f, 0x64, - 0x69, 0x66, 0x69, 0x65, 0x72, 0x73, 0x3d, 0x22, - 0x47, 0x44, 0x4b, 0x5f, 0x53, 0x48, 0x49, 0x46, - 0x54, 0x5f, 0x4d, 0x41, 0x53, 0x4b, 0x20, 0x7c, - 0x20, 0x47, 0x44, 0x4b, 0x5f, 0x43, 0x4f, 0x4e, - 0x54, 0x52, 0x4f, 0x4c, 0x5f, 0x4d, 0x41, 0x53, - 0x4b, 0x22, 0x2f, 0x3e, 0x3c, 0x73, 0x69, 0x67, - 0x6e, 0x61, 0x6c, 0x20, 0x6e, 0x61, 0x6d, 0x65, - 0x3d, 0x22, 0x61, 0x63, 0x74, 0x69, 0x76, 0x61, - 0x74, 0x65, 0x22, 0x20, 0x68, 0x61, 0x6e, 0x64, - 0x6c, 0x65, 0x72, 0x3d, 0x22, 0x73, 0x61, 0x76, - 0x65, 0x5f, 0x61, 0x73, 0x5f, 0x66, 0x69, 0x6c, - 0x65, 0x5f, 0x62, 0x75, 0x74, 0x74, 0x6f, 0x6e, - 0x5f, 0x63, 0x6c, 0x69, 0x63, 0x6b, 0x65, 0x64, - 0x5f, 0x63, 0x62, 0x22, 0x20, 0x73, 0x77, 0x61, - 0x70, 0x70, 0x65, 0x64, 0x3d, 0x22, 0x6e, 0x6f, - 0x22, 0x2f, 0x3e, 0x3c, 0x2f, 0x6f, 0x62, 0x6a, - 0x65, 0x63, 0x74, 0x3e, 0x3c, 0x2f, 0x63, 0x68, - 0x69, 0x6c, 0x64, 0x3e, 0x3c, 0x63, 0x68, 0x69, - 0x6c, 0x64, 0x3e, 0x3c, 0x6f, 0x62, 0x6a, 0x65, - 0x63, 0x74, 0x20, 0x63, 0x6c, 0x61, 0x73, 0x73, - 0x3d, 0x22, 0x47, 0x74, 0x6b, 0x49, 0x6d, 0x61, - 0x67, 0x65, 0x4d, 0x65, 0x6e, 0x75, 0x49, 0x74, - 0x65, 0x6d, 0x22, 0x20, 0x69, 0x64, 0x3d, 0x22, - 0x65, 0x6d, 0x61, 0x69, 0x6c, 0x5f, 0x6d, 0x65, - 0x6e, 0x75, 0x69, 0x74, 0x65, 0x6d, 0x22, 0x3e, - 0x3c, 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, - 0x79, 0x20, 0x6e, 0x61, 0x6d, 0x65, 0x3d, 0x22, - 0x6c, 0x61, 0x62, 0x65, 0x6c, 0x22, 0x20, 0x74, - 0x72, 0x61, 0x6e, 0x73, 0x6c, 0x61, 0x74, 0x61, - 0x62, 0x6c, 0x65, 0x3d, 0x22, 0x79, 0x65, 0x73, - 0x22, 0x20, 0x63, 0x6f, 0x6d, 0x6d, 0x65, 0x6e, - 0x74, 0x73, 0x3d, 0x22, 0x4c, 0x61, 0x62, 0x65, - 0x6c, 0x20, 0x6f, 0x6e, 0x20, 0x65, 0x6d, 0x61, - 0x69, 0x6c, 0x20, 0x6d, 0x65, 0x6e, 0x75, 0x20, - 0x69, 0x74, 0x65, 0x6d, 0x22, 0x3e, 0x5f, 0x45, - 0x6d, 0x61, 0x69, 0x6c, 0x3c, 0x2f, 0x70, 0x72, - 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, 0x3e, 0x3c, - 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, - 0x20, 0x6e, 0x61, 0x6d, 0x65, 0x3d, 0x22, 0x76, - 0x69, 0x73, 0x69, 0x62, 0x6c, 0x65, 0x22, 0x3e, - 0x54, 0x72, 0x75, 0x65, 0x3c, 0x2f, 0x70, 0x72, - 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, 0x3e, 0x3c, - 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, - 0x20, 0x6e, 0x61, 0x6d, 0x65, 0x3d, 0x22, 0x63, - 0x61, 0x6e, 0x5f, 0x66, 0x6f, 0x63, 0x75, 0x73, - 0x22, 0x3e, 0x46, 0x61, 0x6c, 0x73, 0x65, 0x3c, - 0x2f, 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, - 0x79, 0x3e, 0x3c, 0x70, 0x72, 0x6f, 0x70, 0x65, - 0x72, 0x74, 0x79, 0x20, 0x6e, 0x61, 0x6d, 0x65, - 0x3d, 0x22, 0x75, 0x73, 0x65, 0x5f, 0x75, 0x6e, - 0x64, 0x65, 0x72, 0x6c, 0x69, 0x6e, 0x65, 0x22, - 0x3e, 0x54, 0x72, 0x75, 0x65, 0x3c, 0x2f, 0x70, - 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, 0x3e, - 0x3c, 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, - 0x79, 0x20, 0x6e, 0x61, 0x6d, 0x65, 0x3d, 0x22, - 0x69, 0x6d, 0x61, 0x67, 0x65, 0x22, 0x3e, 0x65, - 0x6d, 0x61, 0x69, 0x6c, 0x5f, 0x69, 0x6d, 0x61, - 0x67, 0x65, 0x3c, 0x2f, 0x70, 0x72, 0x6f, 0x70, - 0x65, 0x72, 0x74, 0x79, 0x3e, 0x3c, 0x70, 0x72, - 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, 0x20, 0x6e, - 0x61, 0x6d, 0x65, 0x3d, 0x22, 0x75, 0x73, 0x65, - 0x5f, 0x73, 0x74, 0x6f, 0x63, 0x6b, 0x22, 0x3e, - 0x46, 0x61, 0x6c, 0x73, 0x65, 0x3c, 0x2f, 0x70, - 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, 0x3e, - 0x3c, 0x61, 0x63, 0x63, 0x65, 0x6c, 0x65, 0x72, - 0x61, 0x74, 0x6f, 0x72, 0x20, 0x6b, 0x65, 0x79, - 0x3d, 0x22, 0x65, 0x22, 0x20, 0x73, 0x69, 0x67, - 0x6e, 0x61, 0x6c, 0x3d, 0x22, 0x61, 0x63, 0x74, - 0x69, 0x76, 0x61, 0x74, 0x65, 0x22, 0x20, 0x6d, - 0x6f, 0x64, 0x69, 0x66, 0x69, 0x65, 0x72, 0x73, - 0x3d, 0x22, 0x47, 0x44, 0x4b, 0x5f, 0x43, 0x4f, - 0x4e, 0x54, 0x52, 0x4f, 0x4c, 0x5f, 0x4d, 0x41, - 0x53, 0x4b, 0x22, 0x2f, 0x3e, 0x3c, 0x73, 0x69, - 0x67, 0x6e, 0x61, 0x6c, 0x20, 0x6e, 0x61, 0x6d, - 0x65, 0x3d, 0x22, 0x61, 0x63, 0x74, 0x69, 0x76, - 0x61, 0x74, 0x65, 0x22, 0x20, 0x68, 0x61, 0x6e, - 0x64, 0x6c, 0x65, 0x72, 0x3d, 0x22, 0x65, 0x6d, - 0x61, 0x69, 0x6c, 0x5f, 0x62, 0x75, 0x74, 0x74, - 0x6f, 0x6e, 0x5f, 0x63, 0x6c, 0x69, 0x63, 0x6b, - 0x65, 0x64, 0x5f, 0x63, 0x62, 0x22, 0x20, 0x73, - 0x77, 0x61, 0x70, 0x70, 0x65, 0x64, 0x3d, 0x22, - 0x6e, 0x6f, 0x22, 0x2f, 0x3e, 0x3c, 0x2f, 0x6f, - 0x62, 0x6a, 0x65, 0x63, 0x74, 0x3e, 0x3c, 0x2f, - 0x63, 0x68, 0x69, 0x6c, 0x64, 0x3e, 0x3c, 0x63, - 0x68, 0x69, 0x6c, 0x64, 0x3e, 0x3c, 0x6f, 0x62, - 0x6a, 0x65, 0x63, 0x74, 0x20, 0x63, 0x6c, 0x61, - 0x73, 0x73, 0x3d, 0x22, 0x47, 0x74, 0x6b, 0x49, - 0x6d, 0x61, 0x67, 0x65, 0x4d, 0x65, 0x6e, 0x75, - 0x49, 0x74, 0x65, 0x6d, 0x22, 0x20, 0x69, 0x64, - 0x3d, 0x22, 0x70, 0x72, 0x69, 0x6e, 0x74, 0x5f, - 0x6d, 0x65, 0x6e, 0x75, 0x69, 0x74, 0x65, 0x6d, - 0x22, 0x3e, 0x3c, 0x70, 0x72, 0x6f, 0x70, 0x65, - 0x72, 0x74, 0x79, 0x20, 0x6e, 0x61, 0x6d, 0x65, - 0x3d, 0x22, 0x6c, 0x61, 0x62, 0x65, 0x6c, 0x22, - 0x3e, 0x67, 0x74, 0x6b, 0x2d, 0x70, 0x72, 0x69, - 0x6e, 0x74, 0x3c, 0x2f, 0x70, 0x72, 0x6f, 0x70, - 0x65, 0x72, 0x74, 0x79, 0x3e, 0x3c, 0x70, 0x72, - 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, 0x20, 0x6e, - 0x61, 0x6d, 0x65, 0x3d, 0x22, 0x76, 0x69, 0x73, - 0x69, 0x62, 0x6c, 0x65, 0x22, 0x3e, 0x54, 0x72, - 0x75, 0x65, 0x3c, 0x2f, 0x70, 0x72, 0x6f, 0x70, - 0x65, 0x72, 0x74, 0x79, 0x3e, 0x3c, 0x70, 0x72, - 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, 0x20, 0x6e, - 0x61, 0x6d, 0x65, 0x3d, 0x22, 0x63, 0x61, 0x6e, - 0x5f, 0x66, 0x6f, 0x63, 0x75, 0x73, 0x22, 0x3e, - 0x46, 0x61, 0x6c, 0x73, 0x65, 0x3c, 0x2f, 0x70, - 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, 0x3e, - 0x3c, 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, - 0x79, 0x20, 0x6e, 0x61, 0x6d, 0x65, 0x3d, 0x22, - 0x75, 0x73, 0x65, 0x5f, 0x75, 0x6e, 0x64, 0x65, - 0x72, 0x6c, 0x69, 0x6e, 0x65, 0x22, 0x3e, 0x54, - 0x72, 0x75, 0x65, 0x3c, 0x2f, 0x70, 0x72, 0x6f, - 0x70, 0x65, 0x72, 0x74, 0x79, 0x3e, 0x3c, 0x70, - 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, 0x20, - 0x6e, 0x61, 0x6d, 0x65, 0x3d, 0x22, 0x75, 0x73, - 0x65, 0x5f, 0x73, 0x74, 0x6f, 0x63, 0x6b, 0x22, - 0x3e, 0x54, 0x72, 0x75, 0x65, 0x3c, 0x2f, 0x70, - 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, 0x3e, - 0x3c, 0x61, 0x63, 0x63, 0x65, 0x6c, 0x65, 0x72, - 0x61, 0x74, 0x6f, 0x72, 0x20, 0x6b, 0x65, 0x79, - 0x3d, 0x22, 0x70, 0x22, 0x20, 0x73, 0x69, 0x67, - 0x6e, 0x61, 0x6c, 0x3d, 0x22, 0x61, 0x63, 0x74, - 0x69, 0x76, 0x61, 0x74, 0x65, 0x22, 0x20, 0x6d, - 0x6f, 0x64, 0x69, 0x66, 0x69, 0x65, 0x72, 0x73, - 0x3d, 0x22, 0x47, 0x44, 0x4b, 0x5f, 0x43, 0x4f, - 0x4e, 0x54, 0x52, 0x4f, 0x4c, 0x5f, 0x4d, 0x41, - 0x53, 0x4b, 0x22, 0x2f, 0x3e, 0x3c, 0x73, 0x69, - 0x67, 0x6e, 0x61, 0x6c, 0x20, 0x6e, 0x61, 0x6d, - 0x65, 0x3d, 0x22, 0x61, 0x63, 0x74, 0x69, 0x76, - 0x61, 0x74, 0x65, 0x22, 0x20, 0x68, 0x61, 0x6e, - 0x64, 0x6c, 0x65, 0x72, 0x3d, 0x22, 0x70, 0x72, - 0x69, 0x6e, 0x74, 0x5f, 0x62, 0x75, 0x74, 0x74, - 0x6f, 0x6e, 0x5f, 0x63, 0x6c, 0x69, 0x63, 0x6b, - 0x65, 0x64, 0x5f, 0x63, 0x62, 0x22, 0x20, 0x73, - 0x77, 0x61, 0x70, 0x70, 0x65, 0x64, 0x3d, 0x22, - 0x6e, 0x6f, 0x22, 0x2f, 0x3e, 0x3c, 0x2f, 0x6f, - 0x62, 0x6a, 0x65, 0x63, 0x74, 0x3e, 0x3c, 0x2f, - 0x63, 0x68, 0x69, 0x6c, 0x64, 0x3e, 0x3c, 0x63, - 0x68, 0x69, 0x6c, 0x64, 0x3e, 0x3c, 0x6f, 0x62, - 0x6a, 0x65, 0x63, 0x74, 0x20, 0x63, 0x6c, 0x61, - 0x73, 0x73, 0x3d, 0x22, 0x47, 0x74, 0x6b, 0x53, - 0x65, 0x70, 0x61, 0x72, 0x61, 0x74, 0x6f, 0x72, - 0x4d, 0x65, 0x6e, 0x75, 0x49, 0x74, 0x65, 0x6d, - 0x22, 0x20, 0x69, 0x64, 0x3d, 0x22, 0x64, 0x6f, - 0x63, 0x75, 0x6d, 0x65, 0x6e, 0x74, 0x5f, 0x73, - 0x65, 0x70, 0x5f, 0x6d, 0x65, 0x6e, 0x75, 0x69, - 0x74, 0x65, 0x6d, 0x22, 0x3e, 0x3c, 0x70, 0x72, - 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, 0x20, 0x6e, - 0x61, 0x6d, 0x65, 0x3d, 0x22, 0x76, 0x69, 0x73, - 0x69, 0x62, 0x6c, 0x65, 0x22, 0x3e, 0x54, 0x72, - 0x75, 0x65, 0x3c, 0x2f, 0x70, 0x72, 0x6f, 0x70, - 0x65, 0x72, 0x74, 0x79, 0x3e, 0x3c, 0x70, 0x72, - 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, 0x20, 0x6e, - 0x61, 0x6d, 0x65, 0x3d, 0x22, 0x63, 0x61, 0x6e, - 0x5f, 0x66, 0x6f, 0x63, 0x75, 0x73, 0x22, 0x3e, - 0x46, 0x61, 0x6c, 0x73, 0x65, 0x3c, 0x2f, 0x70, - 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, 0x3e, - 0x3c, 0x2f, 0x6f, 0x62, 0x6a, 0x65, 0x63, 0x74, - 0x3e, 0x3c, 0x2f, 0x63, 0x68, 0x69, 0x6c, 0x64, - 0x3e, 0x3c, 0x63, 0x68, 0x69, 0x6c, 0x64, 0x3e, - 0x3c, 0x6f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x20, - 0x63, 0x6c, 0x61, 0x73, 0x73, 0x3d, 0x22, 0x47, - 0x74, 0x6b, 0x49, 0x6d, 0x61, 0x67, 0x65, 0x4d, - 0x65, 0x6e, 0x75, 0x49, 0x74, 0x65, 0x6d, 0x22, - 0x20, 0x69, 0x64, 0x3d, 0x22, 0x70, 0x72, 0x65, - 0x66, 0x65, 0x72, 0x65, 0x6e, 0x63, 0x65, 0x73, - 0x5f, 0x6d, 0x65, 0x6e, 0x75, 0x69, 0x74, 0x65, - 0x6d, 0x22, 0x3e, 0x3c, 0x70, 0x72, 0x6f, 0x70, - 0x65, 0x72, 0x74, 0x79, 0x20, 0x6e, 0x61, 0x6d, - 0x65, 0x3d, 0x22, 0x6c, 0x61, 0x62, 0x65, 0x6c, - 0x22, 0x3e, 0x67, 0x74, 0x6b, 0x2d, 0x70, 0x72, - 0x65, 0x66, 0x65, 0x72, 0x65, 0x6e, 0x63, 0x65, - 0x73, 0x3c, 0x2f, 0x70, 0x72, 0x6f, 0x70, 0x65, - 0x72, 0x74, 0x79, 0x3e, 0x3c, 0x70, 0x72, 0x6f, - 0x70, 0x65, 0x72, 0x74, 0x79, 0x20, 0x6e, 0x61, - 0x6d, 0x65, 0x3d, 0x22, 0x76, 0x69, 0x73, 0x69, - 0x62, 0x6c, 0x65, 0x22, 0x3e, 0x54, 0x72, 0x75, - 0x65, 0x3c, 0x2f, 0x70, 0x72, 0x6f, 0x70, 0x65, - 0x72, 0x74, 0x79, 0x3e, 0x3c, 0x70, 0x72, 0x6f, - 0x70, 0x65, 0x72, 0x74, 0x79, 0x20, 0x6e, 0x61, - 0x6d, 0x65, 0x3d, 0x22, 0x63, 0x61, 0x6e, 0x5f, - 0x66, 0x6f, 0x63, 0x75, 0x73, 0x22, 0x3e, 0x46, - 0x61, 0x6c, 0x73, 0x65, 0x3c, 0x2f, 0x70, 0x72, - 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, 0x3e, 0x3c, - 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, - 0x20, 0x6e, 0x61, 0x6d, 0x65, 0x3d, 0x22, 0x75, - 0x73, 0x65, 0x5f, 0x75, 0x6e, 0x64, 0x65, 0x72, - 0x6c, 0x69, 0x6e, 0x65, 0x22, 0x3e, 0x54, 0x72, - 0x75, 0x65, 0x3c, 0x2f, 0x70, 0x72, 0x6f, 0x70, - 0x65, 0x72, 0x74, 0x79, 0x3e, 0x3c, 0x70, 0x72, - 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, 0x20, 0x6e, - 0x61, 0x6d, 0x65, 0x3d, 0x22, 0x75, 0x73, 0x65, - 0x5f, 0x73, 0x74, 0x6f, 0x63, 0x6b, 0x22, 0x3e, - 0x54, 0x72, 0x75, 0x65, 0x3c, 0x2f, 0x70, 0x72, - 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, 0x3e, 0x3c, - 0x73, 0x69, 0x67, 0x6e, 0x61, 0x6c, 0x20, 0x6e, - 0x61, 0x6d, 0x65, 0x3d, 0x22, 0x61, 0x63, 0x74, - 0x69, 0x76, 0x61, 0x74, 0x65, 0x22, 0x20, 0x68, - 0x61, 0x6e, 0x64, 0x6c, 0x65, 0x72, 0x3d, 0x22, - 0x70, 0x72, 0x65, 0x66, 0x65, 0x72, 0x65, 0x6e, - 0x63, 0x65, 0x73, 0x5f, 0x62, 0x75, 0x74, 0x74, - 0x6f, 0x6e, 0x5f, 0x63, 0x6c, 0x69, 0x63, 0x6b, - 0x65, 0x64, 0x5f, 0x63, 0x62, 0x22, 0x20, 0x73, - 0x77, 0x61, 0x70, 0x70, 0x65, 0x64, 0x3d, 0x22, - 0x6e, 0x6f, 0x22, 0x2f, 0x3e, 0x3c, 0x2f, 0x6f, - 0x62, 0x6a, 0x65, 0x63, 0x74, 0x3e, 0x3c, 0x2f, - 0x63, 0x68, 0x69, 0x6c, 0x64, 0x3e, 0x3c, 0x63, - 0x68, 0x69, 0x6c, 0x64, 0x3e, 0x3c, 0x6f, 0x62, - 0x6a, 0x65, 0x63, 0x74, 0x20, 0x63, 0x6c, 0x61, - 0x73, 0x73, 0x3d, 0x22, 0x47, 0x74, 0x6b, 0x53, - 0x65, 0x70, 0x61, 0x72, 0x61, 0x74, 0x6f, 0x72, - 0x4d, 0x65, 0x6e, 0x75, 0x49, 0x74, 0x65, 0x6d, - 0x22, 0x20, 0x69, 0x64, 0x3d, 0x22, 0x73, 0x65, - 0x70, 0x61, 0x72, 0x61, 0x74, 0x6f, 0x72, 0x6d, - 0x65, 0x6e, 0x75, 0x69, 0x74, 0x65, 0x6d, 0x31, - 0x22, 0x3e, 0x3c, 0x70, 0x72, 0x6f, 0x70, 0x65, - 0x72, 0x74, 0x79, 0x20, 0x6e, 0x61, 0x6d, 0x65, - 0x3d, 0x22, 0x76, 0x69, 0x73, 0x69, 0x62, 0x6c, - 0x65, 0x22, 0x3e, 0x54, 0x72, 0x75, 0x65, 0x3c, - 0x2f, 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, - 0x79, 0x3e, 0x3c, 0x70, 0x72, 0x6f, 0x70, 0x65, - 0x72, 0x74, 0x79, 0x20, 0x6e, 0x61, 0x6d, 0x65, - 0x3d, 0x22, 0x63, 0x61, 0x6e, 0x5f, 0x66, 0x6f, - 0x63, 0x75, 0x73, 0x22, 0x3e, 0x46, 0x61, 0x6c, - 0x73, 0x65, 0x3c, 0x2f, 0x70, 0x72, 0x6f, 0x70, - 0x65, 0x72, 0x74, 0x79, 0x3e, 0x3c, 0x2f, 0x6f, - 0x62, 0x6a, 0x65, 0x63, 0x74, 0x3e, 0x3c, 0x2f, - 0x63, 0x68, 0x69, 0x6c, 0x64, 0x3e, 0x3c, 0x63, - 0x68, 0x69, 0x6c, 0x64, 0x3e, 0x3c, 0x6f, 0x62, - 0x6a, 0x65, 0x63, 0x74, 0x20, 0x63, 0x6c, 0x61, - 0x73, 0x73, 0x3d, 0x22, 0x47, 0x74, 0x6b, 0x49, - 0x6d, 0x61, 0x67, 0x65, 0x4d, 0x65, 0x6e, 0x75, - 0x49, 0x74, 0x65, 0x6d, 0x22, 0x20, 0x69, 0x64, - 0x3d, 0x22, 0x71, 0x75, 0x69, 0x74, 0x5f, 0x6d, - 0x65, 0x6e, 0x75, 0x69, 0x74, 0x65, 0x6d, 0x22, - 0x3e, 0x3c, 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, - 0x74, 0x79, 0x20, 0x6e, 0x61, 0x6d, 0x65, 0x3d, - 0x22, 0x6c, 0x61, 0x62, 0x65, 0x6c, 0x22, 0x3e, - 0x67, 0x74, 0x6b, 0x2d, 0x71, 0x75, 0x69, 0x74, - 0x3c, 0x2f, 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, - 0x74, 0x79, 0x3e, 0x3c, 0x70, 0x72, 0x6f, 0x70, - 0x65, 0x72, 0x74, 0x79, 0x20, 0x6e, 0x61, 0x6d, - 0x65, 0x3d, 0x22, 0x76, 0x69, 0x73, 0x69, 0x62, - 0x6c, 0x65, 0x22, 0x3e, 0x54, 0x72, 0x75, 0x65, - 0x3c, 0x2f, 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, - 0x74, 0x79, 0x3e, 0x3c, 0x70, 0x72, 0x6f, 0x70, - 0x65, 0x72, 0x74, 0x79, 0x20, 0x6e, 0x61, 0x6d, - 0x65, 0x3d, 0x22, 0x63, 0x61, 0x6e, 0x5f, 0x66, - 0x6f, 0x63, 0x75, 0x73, 0x22, 0x3e, 0x46, 0x61, - 0x6c, 0x73, 0x65, 0x3c, 0x2f, 0x70, 0x72, 0x6f, - 0x70, 0x65, 0x72, 0x74, 0x79, 0x3e, 0x3c, 0x70, - 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, 0x20, - 0x6e, 0x61, 0x6d, 0x65, 0x3d, 0x22, 0x75, 0x73, - 0x65, 0x5f, 0x75, 0x6e, 0x64, 0x65, 0x72, 0x6c, - 0x69, 0x6e, 0x65, 0x22, 0x3e, 0x54, 0x72, 0x75, - 0x65, 0x3c, 0x2f, 0x70, 0x72, 0x6f, 0x70, 0x65, - 0x72, 0x74, 0x79, 0x3e, 0x3c, 0x70, 0x72, 0x6f, - 0x70, 0x65, 0x72, 0x74, 0x79, 0x20, 0x6e, 0x61, - 0x6d, 0x65, 0x3d, 0x22, 0x75, 0x73, 0x65, 0x5f, - 0x73, 0x74, 0x6f, 0x63, 0x6b, 0x22, 0x3e, 0x54, - 0x72, 0x75, 0x65, 0x3c, 0x2f, 0x70, 0x72, 0x6f, - 0x70, 0x65, 0x72, 0x74, 0x79, 0x3e, 0x3c, 0x61, - 0x63, 0x63, 0x65, 0x6c, 0x65, 0x72, 0x61, 0x74, - 0x6f, 0x72, 0x20, 0x6b, 0x65, 0x79, 0x3d, 0x22, - 0x77, 0x22, 0x20, 0x73, 0x69, 0x67, 0x6e, 0x61, - 0x6c, 0x3d, 0x22, 0x61, 0x63, 0x74, 0x69, 0x76, - 0x61, 0x74, 0x65, 0x22, 0x20, 0x6d, 0x6f, 0x64, - 0x69, 0x66, 0x69, 0x65, 0x72, 0x73, 0x3d, 0x22, - 0x47, 0x44, 0x4b, 0x5f, 0x43, 0x4f, 0x4e, 0x54, - 0x52, 0x4f, 0x4c, 0x5f, 0x4d, 0x41, 0x53, 0x4b, - 0x22, 0x2f, 0x3e, 0x3c, 0x61, 0x63, 0x63, 0x65, - 0x6c, 0x65, 0x72, 0x61, 0x74, 0x6f, 0x72, 0x20, - 0x6b, 0x65, 0x79, 0x3d, 0x22, 0x71, 0x22, 0x20, - 0x73, 0x69, 0x67, 0x6e, 0x61, 0x6c, 0x3d, 0x22, - 0x61, 0x63, 0x74, 0x69, 0x76, 0x61, 0x74, 0x65, - 0x22, 0x20, 0x6d, 0x6f, 0x64, 0x69, 0x66, 0x69, - 0x65, 0x72, 0x73, 0x3d, 0x22, 0x47, 0x44, 0x4b, - 0x5f, 0x43, 0x4f, 0x4e, 0x54, 0x52, 0x4f, 0x4c, - 0x5f, 0x4d, 0x41, 0x53, 0x4b, 0x22, 0x2f, 0x3e, - 0x3c, 0x73, 0x69, 0x67, 0x6e, 0x61, 0x6c, 0x20, - 0x6e, 0x61, 0x6d, 0x65, 0x3d, 0x22, 0x61, 0x63, - 0x74, 0x69, 0x76, 0x61, 0x74, 0x65, 0x22, 0x20, - 0x68, 0x61, 0x6e, 0x64, 0x6c, 0x65, 0x72, 0x3d, - 0x22, 0x71, 0x75, 0x69, 0x74, 0x5f, 0x6d, 0x65, - 0x6e, 0x75, 0x69, 0x74, 0x65, 0x6d, 0x5f, 0x61, - 0x63, 0x74, 0x69, 0x76, 0x61, 0x74, 0x65, 0x5f, - 0x63, 0x62, 0x22, 0x20, 0x73, 0x77, 0x61, 0x70, - 0x70, 0x65, 0x64, 0x3d, 0x22, 0x6e, 0x6f, 0x22, - 0x2f, 0x3e, 0x3c, 0x2f, 0x6f, 0x62, 0x6a, 0x65, - 0x63, 0x74, 0x3e, 0x3c, 0x2f, 0x63, 0x68, 0x69, - 0x6c, 0x64, 0x3e, 0x3c, 0x2f, 0x6f, 0x62, 0x6a, - 0x65, 0x63, 0x74, 0x3e, 0x3c, 0x2f, 0x63, 0x68, - 0x69, 0x6c, 0x64, 0x3e, 0x3c, 0x2f, 0x6f, 0x62, - 0x6a, 0x65, 0x63, 0x74, 0x3e, 0x3c, 0x2f, 0x63, - 0x68, 0x69, 0x6c, 0x64, 0x3e, 0x3c, 0x63, 0x68, - 0x69, 0x6c, 0x64, 0x3e, 0x3c, 0x6f, 0x62, 0x6a, - 0x65, 0x63, 0x74, 0x20, 0x63, 0x6c, 0x61, 0x73, - 0x73, 0x3d, 0x22, 0x47, 0x74, 0x6b, 0x4d, 0x65, - 0x6e, 0x75, 0x49, 0x74, 0x65, 0x6d, 0x22, 0x20, - 0x69, 0x64, 0x3d, 0x22, 0x70, 0x61, 0x67, 0x65, - 0x5f, 0x6d, 0x65, 0x6e, 0x75, 0x69, 0x74, 0x65, - 0x6d, 0x22, 0x3e, 0x3c, 0x70, 0x72, 0x6f, 0x70, - 0x65, 0x72, 0x74, 0x79, 0x20, 0x6e, 0x61, 0x6d, - 0x65, 0x3d, 0x22, 0x76, 0x69, 0x73, 0x69, 0x62, - 0x6c, 0x65, 0x22, 0x3e, 0x54, 0x72, 0x75, 0x65, - 0x3c, 0x2f, 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, - 0x74, 0x79, 0x3e, 0x3c, 0x70, 0x72, 0x6f, 0x70, - 0x65, 0x72, 0x74, 0x79, 0x20, 0x6e, 0x61, 0x6d, - 0x65, 0x3d, 0x22, 0x63, 0x61, 0x6e, 0x5f, 0x66, - 0x6f, 0x63, 0x75, 0x73, 0x22, 0x3e, 0x46, 0x61, - 0x6c, 0x73, 0x65, 0x3c, 0x2f, 0x70, 0x72, 0x6f, - 0x70, 0x65, 0x72, 0x74, 0x79, 0x3e, 0x3c, 0x70, - 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, 0x20, - 0x6e, 0x61, 0x6d, 0x65, 0x3d, 0x22, 0x6c, 0x61, - 0x62, 0x65, 0x6c, 0x22, 0x20, 0x74, 0x72, 0x61, - 0x6e, 0x73, 0x6c, 0x61, 0x74, 0x61, 0x62, 0x6c, - 0x65, 0x3d, 0x22, 0x79, 0x65, 0x73, 0x22, 0x20, - 0x63, 0x6f, 0x6d, 0x6d, 0x65, 0x6e, 0x74, 0x73, - 0x3d, 0x22, 0x50, 0x61, 0x67, 0x65, 0x20, 0x6d, - 0x65, 0x6e, 0x75, 0x20, 0x28, 0x63, 0x6f, 0x6e, - 0x74, 0x61, 0x69, 0x6e, 0x73, 0x20, 0x61, 0x63, - 0x74, 0x69, 0x6f, 0x6e, 0x20, 0x66, 0x6f, 0x72, - 0x20, 0x65, 0x61, 0x63, 0x68, 0x20, 0x70, 0x61, - 0x67, 0x65, 0x2c, 0x20, 0x65, 0x2e, 0x67, 0x2e, - 0x20, 0x64, 0x65, 0x6c, 0x65, 0x74, 0x65, 0x2c, - 0x20, 0x63, 0x72, 0x6f, 0x70, 0x29, 0x22, 0x3e, - 0x5f, 0x50, 0x61, 0x67, 0x65, 0x3c, 0x2f, 0x70, - 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, 0x3e, - 0x3c, 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, - 0x79, 0x20, 0x6e, 0x61, 0x6d, 0x65, 0x3d, 0x22, - 0x75, 0x73, 0x65, 0x5f, 0x75, 0x6e, 0x64, 0x65, - 0x72, 0x6c, 0x69, 0x6e, 0x65, 0x22, 0x3e, 0x54, - 0x72, 0x75, 0x65, 0x3c, 0x2f, 0x70, 0x72, 0x6f, - 0x70, 0x65, 0x72, 0x74, 0x79, 0x3e, 0x3c, 0x63, - 0x68, 0x69, 0x6c, 0x64, 0x20, 0x74, 0x79, 0x70, - 0x65, 0x3d, 0x22, 0x73, 0x75, 0x62, 0x6d, 0x65, - 0x6e, 0x75, 0x22, 0x3e, 0x3c, 0x6f, 0x62, 0x6a, - 0x65, 0x63, 0x74, 0x20, 0x63, 0x6c, 0x61, 0x73, - 0x73, 0x3d, 0x22, 0x47, 0x74, 0x6b, 0x4d, 0x65, - 0x6e, 0x75, 0x22, 0x20, 0x69, 0x64, 0x3d, 0x22, - 0x70, 0x61, 0x67, 0x65, 0x5f, 0x6d, 0x65, 0x6e, - 0x75, 0x22, 0x3e, 0x3c, 0x70, 0x72, 0x6f, 0x70, - 0x65, 0x72, 0x74, 0x79, 0x20, 0x6e, 0x61, 0x6d, - 0x65, 0x3d, 0x22, 0x76, 0x69, 0x73, 0x69, 0x62, - 0x6c, 0x65, 0x22, 0x3e, 0x54, 0x72, 0x75, 0x65, - 0x3c, 0x2f, 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, - 0x74, 0x79, 0x3e, 0x3c, 0x70, 0x72, 0x6f, 0x70, - 0x65, 0x72, 0x74, 0x79, 0x20, 0x6e, 0x61, 0x6d, - 0x65, 0x3d, 0x22, 0x63, 0x61, 0x6e, 0x5f, 0x66, - 0x6f, 0x63, 0x75, 0x73, 0x22, 0x3e, 0x46, 0x61, - 0x6c, 0x73, 0x65, 0x3c, 0x2f, 0x70, 0x72, 0x6f, - 0x70, 0x65, 0x72, 0x74, 0x79, 0x3e, 0x3c, 0x63, - 0x68, 0x69, 0x6c, 0x64, 0x3e, 0x3c, 0x6f, 0x62, - 0x6a, 0x65, 0x63, 0x74, 0x20, 0x63, 0x6c, 0x61, - 0x73, 0x73, 0x3d, 0x22, 0x47, 0x74, 0x6b, 0x4d, - 0x65, 0x6e, 0x75, 0x49, 0x74, 0x65, 0x6d, 0x22, - 0x20, 0x69, 0x64, 0x3d, 0x22, 0x72, 0x6f, 0x74, - 0x61, 0x74, 0x65, 0x5f, 0x6c, 0x65, 0x66, 0x74, - 0x5f, 0x6d, 0x65, 0x6e, 0x75, 0x69, 0x74, 0x65, - 0x6d, 0x22, 0x3e, 0x3c, 0x70, 0x72, 0x6f, 0x70, - 0x65, 0x72, 0x74, 0x79, 0x20, 0x6e, 0x61, 0x6d, - 0x65, 0x3d, 0x22, 0x76, 0x69, 0x73, 0x69, 0x62, - 0x6c, 0x65, 0x22, 0x3e, 0x54, 0x72, 0x75, 0x65, - 0x3c, 0x2f, 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, - 0x74, 0x79, 0x3e, 0x3c, 0x70, 0x72, 0x6f, 0x70, - 0x65, 0x72, 0x74, 0x79, 0x20, 0x6e, 0x61, 0x6d, - 0x65, 0x3d, 0x22, 0x63, 0x61, 0x6e, 0x5f, 0x66, - 0x6f, 0x63, 0x75, 0x73, 0x22, 0x3e, 0x46, 0x61, - 0x6c, 0x73, 0x65, 0x3c, 0x2f, 0x70, 0x72, 0x6f, - 0x70, 0x65, 0x72, 0x74, 0x79, 0x3e, 0x3c, 0x70, - 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, 0x20, - 0x6e, 0x61, 0x6d, 0x65, 0x3d, 0x22, 0x6c, 0x61, - 0x62, 0x65, 0x6c, 0x22, 0x20, 0x74, 0x72, 0x61, - 0x6e, 0x73, 0x6c, 0x61, 0x74, 0x61, 0x62, 0x6c, - 0x65, 0x3d, 0x22, 0x79, 0x65, 0x73, 0x22, 0x20, - 0x63, 0x6f, 0x6d, 0x6d, 0x65, 0x6e, 0x74, 0x73, - 0x3d, 0x22, 0x4d, 0x65, 0x6e, 0x75, 0x20, 0x69, - 0x74, 0x65, 0x6d, 0x20, 0x74, 0x6f, 0x20, 0x72, - 0x6f, 0x74, 0x61, 0x74, 0x65, 0x20, 0x70, 0x61, - 0x67, 0x65, 0x20, 0x74, 0x6f, 0x20, 0x6c, 0x65, - 0x66, 0x74, 0x20, 0x28, 0x61, 0x6e, 0x74, 0x69, - 0x2d, 0x63, 0x6c, 0x6f, 0x63, 0x6b, 0x77, 0x69, - 0x73, 0x65, 0x29, 0x22, 0x3e, 0x52, 0x6f, 0x74, - 0x61, 0x74, 0x65, 0x20, 0x5f, 0x4c, 0x65, 0x66, - 0x74, 0x3c, 0x2f, 0x70, 0x72, 0x6f, 0x70, 0x65, - 0x72, 0x74, 0x79, 0x3e, 0x3c, 0x70, 0x72, 0x6f, - 0x70, 0x65, 0x72, 0x74, 0x79, 0x20, 0x6e, 0x61, - 0x6d, 0x65, 0x3d, 0x22, 0x75, 0x73, 0x65, 0x5f, - 0x75, 0x6e, 0x64, 0x65, 0x72, 0x6c, 0x69, 0x6e, - 0x65, 0x22, 0x3e, 0x54, 0x72, 0x75, 0x65, 0x3c, - 0x2f, 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, - 0x79, 0x3e, 0x3c, 0x61, 0x63, 0x63, 0x65, 0x6c, - 0x65, 0x72, 0x61, 0x74, 0x6f, 0x72, 0x20, 0x6b, - 0x65, 0x79, 0x3d, 0x22, 0x62, 0x72, 0x61, 0x63, - 0x6b, 0x65, 0x74, 0x6c, 0x65, 0x66, 0x74, 0x22, - 0x20, 0x73, 0x69, 0x67, 0x6e, 0x61, 0x6c, 0x3d, - 0x22, 0x61, 0x63, 0x74, 0x69, 0x76, 0x61, 0x74, - 0x65, 0x22, 0x2f, 0x3e, 0x3c, 0x73, 0x69, 0x67, - 0x6e, 0x61, 0x6c, 0x20, 0x6e, 0x61, 0x6d, 0x65, - 0x3d, 0x22, 0x61, 0x63, 0x74, 0x69, 0x76, 0x61, - 0x74, 0x65, 0x22, 0x20, 0x68, 0x61, 0x6e, 0x64, - 0x6c, 0x65, 0x72, 0x3d, 0x22, 0x72, 0x6f, 0x74, - 0x61, 0x74, 0x65, 0x5f, 0x6c, 0x65, 0x66, 0x74, - 0x5f, 0x62, 0x75, 0x74, 0x74, 0x6f, 0x6e, 0x5f, - 0x63, 0x6c, 0x69, 0x63, 0x6b, 0x65, 0x64, 0x5f, - 0x63, 0x62, 0x22, 0x20, 0x73, 0x77, 0x61, 0x70, - 0x70, 0x65, 0x64, 0x3d, 0x22, 0x6e, 0x6f, 0x22, - 0x2f, 0x3e, 0x3c, 0x2f, 0x6f, 0x62, 0x6a, 0x65, - 0x63, 0x74, 0x3e, 0x3c, 0x2f, 0x63, 0x68, 0x69, - 0x6c, 0x64, 0x3e, 0x3c, 0x63, 0x68, 0x69, 0x6c, - 0x64, 0x3e, 0x3c, 0x6f, 0x62, 0x6a, 0x65, 0x63, - 0x74, 0x20, 0x63, 0x6c, 0x61, 0x73, 0x73, 0x3d, - 0x22, 0x47, 0x74, 0x6b, 0x4d, 0x65, 0x6e, 0x75, - 0x49, 0x74, 0x65, 0x6d, 0x22, 0x20, 0x69, 0x64, - 0x3d, 0x22, 0x72, 0x6f, 0x74, 0x61, 0x74, 0x65, - 0x5f, 0x72, 0x69, 0x67, 0x68, 0x74, 0x5f, 0x6d, - 0x65, 0x6e, 0x75, 0x69, 0x74, 0x65, 0x6d, 0x22, - 0x3e, 0x3c, 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, - 0x74, 0x79, 0x20, 0x6e, 0x61, 0x6d, 0x65, 0x3d, - 0x22, 0x76, 0x69, 0x73, 0x69, 0x62, 0x6c, 0x65, - 0x22, 0x3e, 0x54, 0x72, 0x75, 0x65, 0x3c, 0x2f, - 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, - 0x3e, 0x3c, 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, - 0x74, 0x79, 0x20, 0x6e, 0x61, 0x6d, 0x65, 0x3d, - 0x22, 0x63, 0x61, 0x6e, 0x5f, 0x66, 0x6f, 0x63, - 0x75, 0x73, 0x22, 0x3e, 0x46, 0x61, 0x6c, 0x73, - 0x65, 0x3c, 0x2f, 0x70, 0x72, 0x6f, 0x70, 0x65, - 0x72, 0x74, 0x79, 0x3e, 0x3c, 0x70, 0x72, 0x6f, - 0x70, 0x65, 0x72, 0x74, 0x79, 0x20, 0x6e, 0x61, - 0x6d, 0x65, 0x3d, 0x22, 0x6c, 0x61, 0x62, 0x65, - 0x6c, 0x22, 0x20, 0x74, 0x72, 0x61, 0x6e, 0x73, - 0x6c, 0x61, 0x74, 0x61, 0x62, 0x6c, 0x65, 0x3d, - 0x22, 0x79, 0x65, 0x73, 0x22, 0x20, 0x63, 0x6f, - 0x6d, 0x6d, 0x65, 0x6e, 0x74, 0x73, 0x3d, 0x22, - 0x4d, 0x65, 0x6e, 0x75, 0x20, 0x69, 0x74, 0x65, - 0x6d, 0x20, 0x74, 0x6f, 0x20, 0x72, 0x6f, 0x74, - 0x61, 0x74, 0x65, 0x20, 0x70, 0x61, 0x67, 0x65, - 0x20, 0x74, 0x6f, 0x20, 0x72, 0x69, 0x67, 0x68, - 0x74, 0x20, 0x28, 0x63, 0x6c, 0x6f, 0x63, 0x6b, - 0x77, 0x69, 0x73, 0x65, 0x29, 0x22, 0x3e, 0x52, - 0x6f, 0x74, 0x61, 0x74, 0x65, 0x20, 0x5f, 0x52, - 0x69, 0x67, 0x68, 0x74, 0x3c, 0x2f, 0x70, 0x72, - 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, 0x3e, 0x3c, - 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, - 0x20, 0x6e, 0x61, 0x6d, 0x65, 0x3d, 0x22, 0x75, - 0x73, 0x65, 0x5f, 0x75, 0x6e, 0x64, 0x65, 0x72, - 0x6c, 0x69, 0x6e, 0x65, 0x22, 0x3e, 0x54, 0x72, - 0x75, 0x65, 0x3c, 0x2f, 0x70, 0x72, 0x6f, 0x70, - 0x65, 0x72, 0x74, 0x79, 0x3e, 0x3c, 0x61, 0x63, - 0x63, 0x65, 0x6c, 0x65, 0x72, 0x61, 0x74, 0x6f, - 0x72, 0x20, 0x6b, 0x65, 0x79, 0x3d, 0x22, 0x62, - 0x72, 0x61, 0x63, 0x6b, 0x65, 0x74, 0x72, 0x69, - 0x67, 0x68, 0x74, 0x22, 0x20, 0x73, 0x69, 0x67, - 0x6e, 0x61, 0x6c, 0x3d, 0x22, 0x61, 0x63, 0x74, - 0x69, 0x76, 0x61, 0x74, 0x65, 0x22, 0x2f, 0x3e, - 0x3c, 0x73, 0x69, 0x67, 0x6e, 0x61, 0x6c, 0x20, - 0x6e, 0x61, 0x6d, 0x65, 0x3d, 0x22, 0x61, 0x63, - 0x74, 0x69, 0x76, 0x61, 0x74, 0x65, 0x22, 0x20, - 0x68, 0x61, 0x6e, 0x64, 0x6c, 0x65, 0x72, 0x3d, - 0x22, 0x72, 0x6f, 0x74, 0x61, 0x74, 0x65, 0x5f, - 0x72, 0x69, 0x67, 0x68, 0x74, 0x5f, 0x62, 0x75, - 0x74, 0x74, 0x6f, 0x6e, 0x5f, 0x63, 0x6c, 0x69, - 0x63, 0x6b, 0x65, 0x64, 0x5f, 0x63, 0x62, 0x22, - 0x20, 0x73, 0x77, 0x61, 0x70, 0x70, 0x65, 0x64, - 0x3d, 0x22, 0x6e, 0x6f, 0x22, 0x2f, 0x3e, 0x3c, - 0x2f, 0x6f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x3e, - 0x3c, 0x2f, 0x63, 0x68, 0x69, 0x6c, 0x64, 0x3e, - 0x3c, 0x63, 0x68, 0x69, 0x6c, 0x64, 0x3e, 0x3c, - 0x6f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x20, 0x63, - 0x6c, 0x61, 0x73, 0x73, 0x3d, 0x22, 0x47, 0x74, - 0x6b, 0x4d, 0x65, 0x6e, 0x75, 0x49, 0x74, 0x65, - 0x6d, 0x22, 0x20, 0x69, 0x64, 0x3d, 0x22, 0x63, - 0x72, 0x6f, 0x70, 0x5f, 0x6d, 0x65, 0x6e, 0x75, - 0x69, 0x74, 0x65, 0x6d, 0x22, 0x3e, 0x3c, 0x70, - 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, 0x20, - 0x6e, 0x61, 0x6d, 0x65, 0x3d, 0x22, 0x76, 0x69, - 0x73, 0x69, 0x62, 0x6c, 0x65, 0x22, 0x3e, 0x54, - 0x72, 0x75, 0x65, 0x3c, 0x2f, 0x70, 0x72, 0x6f, - 0x70, 0x65, 0x72, 0x74, 0x79, 0x3e, 0x3c, 0x70, - 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, 0x20, - 0x6e, 0x61, 0x6d, 0x65, 0x3d, 0x22, 0x63, 0x61, - 0x6e, 0x5f, 0x66, 0x6f, 0x63, 0x75, 0x73, 0x22, - 0x3e, 0x46, 0x61, 0x6c, 0x73, 0x65, 0x3c, 0x2f, - 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, - 0x3e, 0x3c, 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, - 0x74, 0x79, 0x20, 0x6e, 0x61, 0x6d, 0x65, 0x3d, - 0x22, 0x6c, 0x61, 0x62, 0x65, 0x6c, 0x22, 0x20, - 0x74, 0x72, 0x61, 0x6e, 0x73, 0x6c, 0x61, 0x74, - 0x61, 0x62, 0x6c, 0x65, 0x3d, 0x22, 0x79, 0x65, - 0x73, 0x22, 0x20, 0x63, 0x6f, 0x6d, 0x6d, 0x65, - 0x6e, 0x74, 0x73, 0x3d, 0x22, 0x4c, 0x61, 0x62, - 0x65, 0x6c, 0x20, 0x66, 0x6f, 0x72, 0x20, 0x70, - 0x61, 0x67, 0x65, 0x20, 0x63, 0x72, 0x6f, 0x70, - 0x20, 0x73, 0x75, 0x62, 0x6d, 0x65, 0x6e, 0x75, - 0x22, 0x3e, 0x5f, 0x43, 0x72, 0x6f, 0x70, 0x3c, - 0x2f, 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, - 0x79, 0x3e, 0x3c, 0x70, 0x72, 0x6f, 0x70, 0x65, - 0x72, 0x74, 0x79, 0x20, 0x6e, 0x61, 0x6d, 0x65, - 0x3d, 0x22, 0x75, 0x73, 0x65, 0x5f, 0x75, 0x6e, - 0x64, 0x65, 0x72, 0x6c, 0x69, 0x6e, 0x65, 0x22, - 0x3e, 0x54, 0x72, 0x75, 0x65, 0x3c, 0x2f, 0x70, - 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, 0x3e, - 0x3c, 0x63, 0x68, 0x69, 0x6c, 0x64, 0x20, 0x74, - 0x79, 0x70, 0x65, 0x3d, 0x22, 0x73, 0x75, 0x62, - 0x6d, 0x65, 0x6e, 0x75, 0x22, 0x3e, 0x3c, 0x6f, - 0x62, 0x6a, 0x65, 0x63, 0x74, 0x20, 0x63, 0x6c, - 0x61, 0x73, 0x73, 0x3d, 0x22, 0x47, 0x74, 0x6b, - 0x4d, 0x65, 0x6e, 0x75, 0x22, 0x20, 0x69, 0x64, - 0x3d, 0x22, 0x63, 0x72, 0x6f, 0x70, 0x5f, 0x6d, - 0x65, 0x6e, 0x75, 0x22, 0x3e, 0x3c, 0x70, 0x72, - 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, 0x20, 0x6e, - 0x61, 0x6d, 0x65, 0x3d, 0x22, 0x76, 0x69, 0x73, - 0x69, 0x62, 0x6c, 0x65, 0x22, 0x3e, 0x54, 0x72, - 0x75, 0x65, 0x3c, 0x2f, 0x70, 0x72, 0x6f, 0x70, - 0x65, 0x72, 0x74, 0x79, 0x3e, 0x3c, 0x70, 0x72, - 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, 0x20, 0x6e, - 0x61, 0x6d, 0x65, 0x3d, 0x22, 0x63, 0x61, 0x6e, - 0x5f, 0x66, 0x6f, 0x63, 0x75, 0x73, 0x22, 0x3e, - 0x46, 0x61, 0x6c, 0x73, 0x65, 0x3c, 0x2f, 0x70, - 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, 0x3e, - 0x3c, 0x63, 0x68, 0x69, 0x6c, 0x64, 0x3e, 0x3c, - 0x6f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x20, 0x63, - 0x6c, 0x61, 0x73, 0x73, 0x3d, 0x22, 0x47, 0x74, - 0x6b, 0x52, 0x61, 0x64, 0x69, 0x6f, 0x4d, 0x65, - 0x6e, 0x75, 0x49, 0x74, 0x65, 0x6d, 0x22, 0x20, - 0x69, 0x64, 0x3d, 0x22, 0x6e, 0x6f, 0x5f, 0x63, - 0x72, 0x6f, 0x70, 0x5f, 0x6d, 0x65, 0x6e, 0x75, - 0x69, 0x74, 0x65, 0x6d, 0x22, 0x3e, 0x3c, 0x70, - 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, 0x20, - 0x6e, 0x61, 0x6d, 0x65, 0x3d, 0x22, 0x76, 0x69, - 0x73, 0x69, 0x62, 0x6c, 0x65, 0x22, 0x3e, 0x54, - 0x72, 0x75, 0x65, 0x3c, 0x2f, 0x70, 0x72, 0x6f, - 0x70, 0x65, 0x72, 0x74, 0x79, 0x3e, 0x3c, 0x70, - 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, 0x20, - 0x6e, 0x61, 0x6d, 0x65, 0x3d, 0x22, 0x63, 0x61, - 0x6e, 0x5f, 0x66, 0x6f, 0x63, 0x75, 0x73, 0x22, - 0x3e, 0x46, 0x61, 0x6c, 0x73, 0x65, 0x3c, 0x2f, - 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, - 0x3e, 0x3c, 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, - 0x74, 0x79, 0x20, 0x6e, 0x61, 0x6d, 0x65, 0x3d, - 0x22, 0x6c, 0x61, 0x62, 0x65, 0x6c, 0x22, 0x20, - 0x74, 0x72, 0x61, 0x6e, 0x73, 0x6c, 0x61, 0x74, - 0x61, 0x62, 0x6c, 0x65, 0x3d, 0x22, 0x79, 0x65, - 0x73, 0x22, 0x20, 0x63, 0x6f, 0x6d, 0x6d, 0x65, - 0x6e, 0x74, 0x73, 0x3d, 0x22, 0x52, 0x61, 0x64, - 0x69, 0x6f, 0x20, 0x62, 0x75, 0x74, 0x74, 0x6f, - 0x6e, 0x20, 0x66, 0x6f, 0x72, 0x20, 0x6e, 0x6f, - 0x20, 0x63, 0x72, 0x6f, 0x70, 0x22, 0x3e, 0x5f, - 0x4e, 0x6f, 0x6e, 0x65, 0x3c, 0x2f, 0x70, 0x72, - 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, 0x3e, 0x3c, - 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, - 0x20, 0x6e, 0x61, 0x6d, 0x65, 0x3d, 0x22, 0x75, - 0x73, 0x65, 0x5f, 0x75, 0x6e, 0x64, 0x65, 0x72, - 0x6c, 0x69, 0x6e, 0x65, 0x22, 0x3e, 0x54, 0x72, - 0x75, 0x65, 0x3c, 0x2f, 0x70, 0x72, 0x6f, 0x70, - 0x65, 0x72, 0x74, 0x79, 0x3e, 0x3c, 0x70, 0x72, - 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, 0x20, 0x6e, - 0x61, 0x6d, 0x65, 0x3d, 0x22, 0x61, 0x63, 0x74, - 0x69, 0x76, 0x65, 0x22, 0x3e, 0x54, 0x72, 0x75, - 0x65, 0x3c, 0x2f, 0x70, 0x72, 0x6f, 0x70, 0x65, - 0x72, 0x74, 0x79, 0x3e, 0x3c, 0x70, 0x72, 0x6f, - 0x70, 0x65, 0x72, 0x74, 0x79, 0x20, 0x6e, 0x61, - 0x6d, 0x65, 0x3d, 0x22, 0x64, 0x72, 0x61, 0x77, - 0x5f, 0x61, 0x73, 0x5f, 0x72, 0x61, 0x64, 0x69, - 0x6f, 0x22, 0x3e, 0x54, 0x72, 0x75, 0x65, 0x3c, - 0x2f, 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, - 0x79, 0x3e, 0x3c, 0x73, 0x69, 0x67, 0x6e, 0x61, - 0x6c, 0x20, 0x6e, 0x61, 0x6d, 0x65, 0x3d, 0x22, - 0x74, 0x6f, 0x67, 0x67, 0x6c, 0x65, 0x64, 0x22, - 0x20, 0x68, 0x61, 0x6e, 0x64, 0x6c, 0x65, 0x72, - 0x3d, 0x22, 0x6e, 0x6f, 0x5f, 0x63, 0x72, 0x6f, - 0x70, 0x5f, 0x6d, 0x65, 0x6e, 0x75, 0x69, 0x74, - 0x65, 0x6d, 0x5f, 0x74, 0x6f, 0x67, 0x67, 0x6c, - 0x65, 0x64, 0x5f, 0x63, 0x62, 0x22, 0x20, 0x73, - 0x77, 0x61, 0x70, 0x70, 0x65, 0x64, 0x3d, 0x22, - 0x6e, 0x6f, 0x22, 0x2f, 0x3e, 0x3c, 0x2f, 0x6f, - 0x62, 0x6a, 0x65, 0x63, 0x74, 0x3e, 0x3c, 0x2f, - 0x63, 0x68, 0x69, 0x6c, 0x64, 0x3e, 0x3c, 0x63, - 0x68, 0x69, 0x6c, 0x64, 0x3e, 0x3c, 0x6f, 0x62, - 0x6a, 0x65, 0x63, 0x74, 0x20, 0x63, 0x6c, 0x61, - 0x73, 0x73, 0x3d, 0x22, 0x47, 0x74, 0x6b, 0x52, - 0x61, 0x64, 0x69, 0x6f, 0x4d, 0x65, 0x6e, 0x75, - 0x49, 0x74, 0x65, 0x6d, 0x22, 0x20, 0x69, 0x64, - 0x3d, 0x22, 0x61, 0x34, 0x5f, 0x6d, 0x65, 0x6e, - 0x75, 0x69, 0x74, 0x65, 0x6d, 0x22, 0x3e, 0x3c, - 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, - 0x20, 0x6e, 0x61, 0x6d, 0x65, 0x3d, 0x22, 0x76, - 0x69, 0x73, 0x69, 0x62, 0x6c, 0x65, 0x22, 0x3e, - 0x54, 0x72, 0x75, 0x65, 0x3c, 0x2f, 0x70, 0x72, - 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, 0x3e, 0x3c, - 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, - 0x20, 0x6e, 0x61, 0x6d, 0x65, 0x3d, 0x22, 0x63, - 0x61, 0x6e, 0x5f, 0x66, 0x6f, 0x63, 0x75, 0x73, - 0x22, 0x3e, 0x46, 0x61, 0x6c, 0x73, 0x65, 0x3c, - 0x2f, 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, - 0x79, 0x3e, 0x3c, 0x70, 0x72, 0x6f, 0x70, 0x65, - 0x72, 0x74, 0x79, 0x20, 0x6e, 0x61, 0x6d, 0x65, - 0x3d, 0x22, 0x6c, 0x61, 0x62, 0x65, 0x6c, 0x22, - 0x20, 0x74, 0x72, 0x61, 0x6e, 0x73, 0x6c, 0x61, - 0x74, 0x61, 0x62, 0x6c, 0x65, 0x3d, 0x22, 0x79, - 0x65, 0x73, 0x22, 0x20, 0x63, 0x6f, 0x6d, 0x6d, - 0x65, 0x6e, 0x74, 0x73, 0x3d, 0x22, 0x52, 0x61, - 0x64, 0x69, 0x6f, 0x20, 0x62, 0x75, 0x74, 0x74, - 0x6f, 0x6e, 0x20, 0x66, 0x6f, 0x72, 0x20, 0x63, - 0x72, 0x6f, 0x70, 0x70, 0x69, 0x6e, 0x67, 0x20, - 0x70, 0x61, 0x67, 0x65, 0x20, 0x74, 0x6f, 0x20, - 0x41, 0x34, 0x20, 0x73, 0x69, 0x7a, 0x65, 0x22, - 0x3e, 0x41, 0x5f, 0x34, 0x3c, 0x2f, 0x70, 0x72, - 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, 0x3e, 0x3c, - 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, - 0x20, 0x6e, 0x61, 0x6d, 0x65, 0x3d, 0x22, 0x75, - 0x73, 0x65, 0x5f, 0x75, 0x6e, 0x64, 0x65, 0x72, - 0x6c, 0x69, 0x6e, 0x65, 0x22, 0x3e, 0x54, 0x72, - 0x75, 0x65, 0x3c, 0x2f, 0x70, 0x72, 0x6f, 0x70, - 0x65, 0x72, 0x74, 0x79, 0x3e, 0x3c, 0x70, 0x72, - 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, 0x20, 0x6e, - 0x61, 0x6d, 0x65, 0x3d, 0x22, 0x64, 0x72, 0x61, - 0x77, 0x5f, 0x61, 0x73, 0x5f, 0x72, 0x61, 0x64, - 0x69, 0x6f, 0x22, 0x3e, 0x54, 0x72, 0x75, 0x65, - 0x3c, 0x2f, 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, - 0x74, 0x79, 0x3e, 0x3c, 0x70, 0x72, 0x6f, 0x70, - 0x65, 0x72, 0x74, 0x79, 0x20, 0x6e, 0x61, 0x6d, - 0x65, 0x3d, 0x22, 0x67, 0x72, 0x6f, 0x75, 0x70, - 0x22, 0x3e, 0x6e, 0x6f, 0x5f, 0x63, 0x72, 0x6f, - 0x70, 0x5f, 0x6d, 0x65, 0x6e, 0x75, 0x69, 0x74, - 0x65, 0x6d, 0x3c, 0x2f, 0x70, 0x72, 0x6f, 0x70, - 0x65, 0x72, 0x74, 0x79, 0x3e, 0x3c, 0x73, 0x69, - 0x67, 0x6e, 0x61, 0x6c, 0x20, 0x6e, 0x61, 0x6d, - 0x65, 0x3d, 0x22, 0x74, 0x6f, 0x67, 0x67, 0x6c, - 0x65, 0x64, 0x22, 0x20, 0x68, 0x61, 0x6e, 0x64, - 0x6c, 0x65, 0x72, 0x3d, 0x22, 0x61, 0x34, 0x5f, - 0x6d, 0x65, 0x6e, 0x75, 0x69, 0x74, 0x65, 0x6d, - 0x5f, 0x74, 0x6f, 0x67, 0x67, 0x6c, 0x65, 0x64, - 0x5f, 0x63, 0x62, 0x22, 0x20, 0x73, 0x77, 0x61, - 0x70, 0x70, 0x65, 0x64, 0x3d, 0x22, 0x6e, 0x6f, - 0x22, 0x2f, 0x3e, 0x3c, 0x2f, 0x6f, 0x62, 0x6a, - 0x65, 0x63, 0x74, 0x3e, 0x3c, 0x2f, 0x63, 0x68, - 0x69, 0x6c, 0x64, 0x3e, 0x3c, 0x63, 0x68, 0x69, - 0x6c, 0x64, 0x3e, 0x3c, 0x6f, 0x62, 0x6a, 0x65, - 0x63, 0x74, 0x20, 0x63, 0x6c, 0x61, 0x73, 0x73, - 0x3d, 0x22, 0x47, 0x74, 0x6b, 0x52, 0x61, 0x64, - 0x69, 0x6f, 0x4d, 0x65, 0x6e, 0x75, 0x49, 0x74, - 0x65, 0x6d, 0x22, 0x20, 0x69, 0x64, 0x3d, 0x22, - 0x61, 0x35, 0x5f, 0x6d, 0x65, 0x6e, 0x75, 0x69, - 0x74, 0x65, 0x6d, 0x22, 0x3e, 0x3c, 0x70, 0x72, - 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, 0x20, 0x6e, - 0x61, 0x6d, 0x65, 0x3d, 0x22, 0x76, 0x69, 0x73, - 0x69, 0x62, 0x6c, 0x65, 0x22, 0x3e, 0x54, 0x72, - 0x75, 0x65, 0x3c, 0x2f, 0x70, 0x72, 0x6f, 0x70, - 0x65, 0x72, 0x74, 0x79, 0x3e, 0x3c, 0x70, 0x72, - 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, 0x20, 0x6e, - 0x61, 0x6d, 0x65, 0x3d, 0x22, 0x63, 0x61, 0x6e, - 0x5f, 0x66, 0x6f, 0x63, 0x75, 0x73, 0x22, 0x3e, - 0x46, 0x61, 0x6c, 0x73, 0x65, 0x3c, 0x2f, 0x70, - 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, 0x3e, - 0x3c, 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, - 0x79, 0x20, 0x6e, 0x61, 0x6d, 0x65, 0x3d, 0x22, - 0x6c, 0x61, 0x62, 0x65, 0x6c, 0x22, 0x20, 0x74, - 0x72, 0x61, 0x6e, 0x73, 0x6c, 0x61, 0x74, 0x61, - 0x62, 0x6c, 0x65, 0x3d, 0x22, 0x79, 0x65, 0x73, - 0x22, 0x20, 0x63, 0x6f, 0x6d, 0x6d, 0x65, 0x6e, - 0x74, 0x73, 0x3d, 0x22, 0x52, 0x61, 0x64, 0x69, - 0x6f, 0x20, 0x62, 0x75, 0x74, 0x74, 0x6f, 0x6e, - 0x20, 0x66, 0x6f, 0x72, 0x20, 0x63, 0x72, 0x6f, - 0x70, 0x70, 0x69, 0x6e, 0x67, 0x20, 0x70, 0x61, - 0x67, 0x65, 0x20, 0x74, 0x6f, 0x20, 0x41, 0x35, - 0x20, 0x73, 0x69, 0x7a, 0x65, 0x22, 0x3e, 0x41, - 0x5f, 0x35, 0x3c, 0x2f, 0x70, 0x72, 0x6f, 0x70, - 0x65, 0x72, 0x74, 0x79, 0x3e, 0x3c, 0x70, 0x72, - 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, 0x20, 0x6e, - 0x61, 0x6d, 0x65, 0x3d, 0x22, 0x75, 0x73, 0x65, - 0x5f, 0x75, 0x6e, 0x64, 0x65, 0x72, 0x6c, 0x69, - 0x6e, 0x65, 0x22, 0x3e, 0x54, 0x72, 0x75, 0x65, - 0x3c, 0x2f, 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, - 0x74, 0x79, 0x3e, 0x3c, 0x70, 0x72, 0x6f, 0x70, - 0x65, 0x72, 0x74, 0x79, 0x20, 0x6e, 0x61, 0x6d, - 0x65, 0x3d, 0x22, 0x64, 0x72, 0x61, 0x77, 0x5f, - 0x61, 0x73, 0x5f, 0x72, 0x61, 0x64, 0x69, 0x6f, - 0x22, 0x3e, 0x54, 0x72, 0x75, 0x65, 0x3c, 0x2f, - 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, - 0x3e, 0x3c, 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, - 0x74, 0x79, 0x20, 0x6e, 0x61, 0x6d, 0x65, 0x3d, - 0x22, 0x67, 0x72, 0x6f, 0x75, 0x70, 0x22, 0x3e, - 0x6e, 0x6f, 0x5f, 0x63, 0x72, 0x6f, 0x70, 0x5f, - 0x6d, 0x65, 0x6e, 0x75, 0x69, 0x74, 0x65, 0x6d, - 0x3c, 0x2f, 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, - 0x74, 0x79, 0x3e, 0x3c, 0x73, 0x69, 0x67, 0x6e, - 0x61, 0x6c, 0x20, 0x6e, 0x61, 0x6d, 0x65, 0x3d, - 0x22, 0x74, 0x6f, 0x67, 0x67, 0x6c, 0x65, 0x64, - 0x22, 0x20, 0x68, 0x61, 0x6e, 0x64, 0x6c, 0x65, - 0x72, 0x3d, 0x22, 0x61, 0x35, 0x5f, 0x6d, 0x65, - 0x6e, 0x75, 0x69, 0x74, 0x65, 0x6d, 0x5f, 0x74, - 0x6f, 0x67, 0x67, 0x6c, 0x65, 0x64, 0x5f, 0x63, - 0x62, 0x22, 0x20, 0x73, 0x77, 0x61, 0x70, 0x70, - 0x65, 0x64, 0x3d, 0x22, 0x6e, 0x6f, 0x22, 0x2f, - 0x3e, 0x3c, 0x2f, 0x6f, 0x62, 0x6a, 0x65, 0x63, - 0x74, 0x3e, 0x3c, 0x2f, 0x63, 0x68, 0x69, 0x6c, - 0x64, 0x3e, 0x3c, 0x63, 0x68, 0x69, 0x6c, 0x64, - 0x3e, 0x3c, 0x6f, 0x62, 0x6a, 0x65, 0x63, 0x74, - 0x20, 0x63, 0x6c, 0x61, 0x73, 0x73, 0x3d, 0x22, - 0x47, 0x74, 0x6b, 0x52, 0x61, 0x64, 0x69, 0x6f, - 0x4d, 0x65, 0x6e, 0x75, 0x49, 0x74, 0x65, 0x6d, - 0x22, 0x20, 0x69, 0x64, 0x3d, 0x22, 0x61, 0x36, - 0x5f, 0x6d, 0x65, 0x6e, 0x75, 0x69, 0x74, 0x65, - 0x6d, 0x22, 0x3e, 0x3c, 0x70, 0x72, 0x6f, 0x70, - 0x65, 0x72, 0x74, 0x79, 0x20, 0x6e, 0x61, 0x6d, - 0x65, 0x3d, 0x22, 0x76, 0x69, 0x73, 0x69, 0x62, - 0x6c, 0x65, 0x22, 0x3e, 0x54, 0x72, 0x75, 0x65, - 0x3c, 0x2f, 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, - 0x74, 0x79, 0x3e, 0x3c, 0x70, 0x72, 0x6f, 0x70, - 0x65, 0x72, 0x74, 0x79, 0x20, 0x6e, 0x61, 0x6d, - 0x65, 0x3d, 0x22, 0x63, 0x61, 0x6e, 0x5f, 0x66, - 0x6f, 0x63, 0x75, 0x73, 0x22, 0x3e, 0x46, 0x61, - 0x6c, 0x73, 0x65, 0x3c, 0x2f, 0x70, 0x72, 0x6f, - 0x70, 0x65, 0x72, 0x74, 0x79, 0x3e, 0x3c, 0x70, - 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, 0x20, - 0x6e, 0x61, 0x6d, 0x65, 0x3d, 0x22, 0x6c, 0x61, - 0x62, 0x65, 0x6c, 0x22, 0x20, 0x74, 0x72, 0x61, - 0x6e, 0x73, 0x6c, 0x61, 0x74, 0x61, 0x62, 0x6c, - 0x65, 0x3d, 0x22, 0x79, 0x65, 0x73, 0x22, 0x20, - 0x63, 0x6f, 0x6d, 0x6d, 0x65, 0x6e, 0x74, 0x73, - 0x3d, 0x22, 0x52, 0x61, 0x64, 0x69, 0x6f, 0x20, - 0x62, 0x75, 0x74, 0x74, 0x6f, 0x6e, 0x20, 0x66, - 0x6f, 0x72, 0x20, 0x63, 0x72, 0x6f, 0x70, 0x70, - 0x69, 0x6e, 0x67, 0x20, 0x70, 0x61, 0x67, 0x65, - 0x20, 0x74, 0x6f, 0x20, 0x41, 0x36, 0x20, 0x73, - 0x69, 0x7a, 0x65, 0x22, 0x3e, 0x41, 0x5f, 0x36, - 0x3c, 0x2f, 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, - 0x74, 0x79, 0x3e, 0x3c, 0x70, 0x72, 0x6f, 0x70, - 0x65, 0x72, 0x74, 0x79, 0x20, 0x6e, 0x61, 0x6d, - 0x65, 0x3d, 0x22, 0x75, 0x73, 0x65, 0x5f, 0x75, - 0x6e, 0x64, 0x65, 0x72, 0x6c, 0x69, 0x6e, 0x65, - 0x22, 0x3e, 0x54, 0x72, 0x75, 0x65, 0x3c, 0x2f, - 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, - 0x3e, 0x3c, 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, - 0x74, 0x79, 0x20, 0x6e, 0x61, 0x6d, 0x65, 0x3d, - 0x22, 0x64, 0x72, 0x61, 0x77, 0x5f, 0x61, 0x73, - 0x5f, 0x72, 0x61, 0x64, 0x69, 0x6f, 0x22, 0x3e, - 0x54, 0x72, 0x75, 0x65, 0x3c, 0x2f, 0x70, 0x72, - 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, 0x3e, 0x3c, - 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, - 0x20, 0x6e, 0x61, 0x6d, 0x65, 0x3d, 0x22, 0x67, - 0x72, 0x6f, 0x75, 0x70, 0x22, 0x3e, 0x6e, 0x6f, - 0x5f, 0x63, 0x72, 0x6f, 0x70, 0x5f, 0x6d, 0x65, - 0x6e, 0x75, 0x69, 0x74, 0x65, 0x6d, 0x3c, 0x2f, - 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, - 0x3e, 0x3c, 0x73, 0x69, 0x67, 0x6e, 0x61, 0x6c, - 0x20, 0x6e, 0x61, 0x6d, 0x65, 0x3d, 0x22, 0x74, - 0x6f, 0x67, 0x67, 0x6c, 0x65, 0x64, 0x22, 0x20, - 0x68, 0x61, 0x6e, 0x64, 0x6c, 0x65, 0x72, 0x3d, - 0x22, 0x61, 0x36, 0x5f, 0x6d, 0x65, 0x6e, 0x75, - 0x69, 0x74, 0x65, 0x6d, 0x5f, 0x74, 0x6f, 0x67, - 0x67, 0x6c, 0x65, 0x64, 0x5f, 0x63, 0x62, 0x22, - 0x20, 0x73, 0x77, 0x61, 0x70, 0x70, 0x65, 0x64, - 0x3d, 0x22, 0x6e, 0x6f, 0x22, 0x2f, 0x3e, 0x3c, - 0x2f, 0x6f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x3e, - 0x3c, 0x2f, 0x63, 0x68, 0x69, 0x6c, 0x64, 0x3e, - 0x3c, 0x63, 0x68, 0x69, 0x6c, 0x64, 0x3e, 0x3c, - 0x6f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x20, 0x63, - 0x6c, 0x61, 0x73, 0x73, 0x3d, 0x22, 0x47, 0x74, - 0x6b, 0x52, 0x61, 0x64, 0x69, 0x6f, 0x4d, 0x65, - 0x6e, 0x75, 0x49, 0x74, 0x65, 0x6d, 0x22, 0x20, - 0x69, 0x64, 0x3d, 0x22, 0x6c, 0x65, 0x74, 0x74, - 0x65, 0x72, 0x5f, 0x6d, 0x65, 0x6e, 0x75, 0x69, - 0x74, 0x65, 0x6d, 0x22, 0x3e, 0x3c, 0x70, 0x72, - 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, 0x20, 0x6e, - 0x61, 0x6d, 0x65, 0x3d, 0x22, 0x76, 0x69, 0x73, - 0x69, 0x62, 0x6c, 0x65, 0x22, 0x3e, 0x54, 0x72, - 0x75, 0x65, 0x3c, 0x2f, 0x70, 0x72, 0x6f, 0x70, - 0x65, 0x72, 0x74, 0x79, 0x3e, 0x3c, 0x70, 0x72, - 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, 0x20, 0x6e, - 0x61, 0x6d, 0x65, 0x3d, 0x22, 0x63, 0x61, 0x6e, - 0x5f, 0x66, 0x6f, 0x63, 0x75, 0x73, 0x22, 0x3e, - 0x46, 0x61, 0x6c, 0x73, 0x65, 0x3c, 0x2f, 0x70, - 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, 0x3e, - 0x3c, 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, - 0x79, 0x20, 0x6e, 0x61, 0x6d, 0x65, 0x3d, 0x22, - 0x6c, 0x61, 0x62, 0x65, 0x6c, 0x22, 0x20, 0x74, - 0x72, 0x61, 0x6e, 0x73, 0x6c, 0x61, 0x74, 0x61, - 0x62, 0x6c, 0x65, 0x3d, 0x22, 0x79, 0x65, 0x73, - 0x22, 0x20, 0x63, 0x6f, 0x6d, 0x6d, 0x65, 0x6e, - 0x74, 0x73, 0x3d, 0x22, 0x52, 0x61, 0x64, 0x69, - 0x6f, 0x20, 0x62, 0x75, 0x74, 0x74, 0x6f, 0x6e, - 0x20, 0x66, 0x6f, 0x72, 0x20, 0x63, 0x72, 0x6f, - 0x70, 0x70, 0x69, 0x6e, 0x67, 0x20, 0x70, 0x61, - 0x67, 0x65, 0x20, 0x74, 0x6f, 0x20, 0x55, 0x53, - 0x20, 0x6c, 0x65, 0x74, 0x74, 0x65, 0x72, 0x20, - 0x73, 0x69, 0x7a, 0x65, 0x22, 0x3e, 0x5f, 0x4c, - 0x65, 0x74, 0x74, 0x65, 0x72, 0x3c, 0x2f, 0x70, - 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, 0x3e, - 0x3c, 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, - 0x79, 0x20, 0x6e, 0x61, 0x6d, 0x65, 0x3d, 0x22, - 0x75, 0x73, 0x65, 0x5f, 0x75, 0x6e, 0x64, 0x65, - 0x72, 0x6c, 0x69, 0x6e, 0x65, 0x22, 0x3e, 0x54, - 0x72, 0x75, 0x65, 0x3c, 0x2f, 0x70, 0x72, 0x6f, - 0x70, 0x65, 0x72, 0x74, 0x79, 0x3e, 0x3c, 0x70, - 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, 0x20, - 0x6e, 0x61, 0x6d, 0x65, 0x3d, 0x22, 0x64, 0x72, - 0x61, 0x77, 0x5f, 0x61, 0x73, 0x5f, 0x72, 0x61, - 0x64, 0x69, 0x6f, 0x22, 0x3e, 0x54, 0x72, 0x75, - 0x65, 0x3c, 0x2f, 0x70, 0x72, 0x6f, 0x70, 0x65, - 0x72, 0x74, 0x79, 0x3e, 0x3c, 0x70, 0x72, 0x6f, - 0x70, 0x65, 0x72, 0x74, 0x79, 0x20, 0x6e, 0x61, - 0x6d, 0x65, 0x3d, 0x22, 0x67, 0x72, 0x6f, 0x75, - 0x70, 0x22, 0x3e, 0x6e, 0x6f, 0x5f, 0x63, 0x72, - 0x6f, 0x70, 0x5f, 0x6d, 0x65, 0x6e, 0x75, 0x69, - 0x74, 0x65, 0x6d, 0x3c, 0x2f, 0x70, 0x72, 0x6f, - 0x70, 0x65, 0x72, 0x74, 0x79, 0x3e, 0x3c, 0x73, - 0x69, 0x67, 0x6e, 0x61, 0x6c, 0x20, 0x6e, 0x61, - 0x6d, 0x65, 0x3d, 0x22, 0x74, 0x6f, 0x67, 0x67, - 0x6c, 0x65, 0x64, 0x22, 0x20, 0x68, 0x61, 0x6e, - 0x64, 0x6c, 0x65, 0x72, 0x3d, 0x22, 0x6c, 0x65, - 0x74, 0x74, 0x65, 0x72, 0x5f, 0x6d, 0x65, 0x6e, - 0x75, 0x69, 0x74, 0x65, 0x6d, 0x5f, 0x74, 0x6f, - 0x67, 0x67, 0x6c, 0x65, 0x64, 0x5f, 0x63, 0x62, - 0x22, 0x20, 0x73, 0x77, 0x61, 0x70, 0x70, 0x65, - 0x64, 0x3d, 0x22, 0x6e, 0x6f, 0x22, 0x2f, 0x3e, - 0x3c, 0x2f, 0x6f, 0x62, 0x6a, 0x65, 0x63, 0x74, - 0x3e, 0x3c, 0x2f, 0x63, 0x68, 0x69, 0x6c, 0x64, - 0x3e, 0x3c, 0x63, 0x68, 0x69, 0x6c, 0x64, 0x3e, - 0x3c, 0x6f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x20, - 0x63, 0x6c, 0x61, 0x73, 0x73, 0x3d, 0x22, 0x47, - 0x74, 0x6b, 0x52, 0x61, 0x64, 0x69, 0x6f, 0x4d, - 0x65, 0x6e, 0x75, 0x49, 0x74, 0x65, 0x6d, 0x22, - 0x20, 0x69, 0x64, 0x3d, 0x22, 0x6c, 0x65, 0x67, - 0x61, 0x6c, 0x5f, 0x6d, 0x65, 0x6e, 0x75, 0x69, - 0x74, 0x65, 0x6d, 0x22, 0x3e, 0x3c, 0x70, 0x72, - 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, 0x20, 0x6e, - 0x61, 0x6d, 0x65, 0x3d, 0x22, 0x76, 0x69, 0x73, - 0x69, 0x62, 0x6c, 0x65, 0x22, 0x3e, 0x54, 0x72, - 0x75, 0x65, 0x3c, 0x2f, 0x70, 0x72, 0x6f, 0x70, - 0x65, 0x72, 0x74, 0x79, 0x3e, 0x3c, 0x70, 0x72, - 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, 0x20, 0x6e, - 0x61, 0x6d, 0x65, 0x3d, 0x22, 0x63, 0x61, 0x6e, - 0x5f, 0x66, 0x6f, 0x63, 0x75, 0x73, 0x22, 0x3e, - 0x46, 0x61, 0x6c, 0x73, 0x65, 0x3c, 0x2f, 0x70, - 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, 0x3e, - 0x3c, 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, - 0x79, 0x20, 0x6e, 0x61, 0x6d, 0x65, 0x3d, 0x22, - 0x6c, 0x61, 0x62, 0x65, 0x6c, 0x22, 0x20, 0x74, - 0x72, 0x61, 0x6e, 0x73, 0x6c, 0x61, 0x74, 0x61, - 0x62, 0x6c, 0x65, 0x3d, 0x22, 0x79, 0x65, 0x73, - 0x22, 0x20, 0x63, 0x6f, 0x6d, 0x6d, 0x65, 0x6e, - 0x74, 0x73, 0x3d, 0x22, 0x52, 0x61, 0x64, 0x69, - 0x6f, 0x20, 0x62, 0x75, 0x74, 0x74, 0x6f, 0x6e, - 0x20, 0x66, 0x6f, 0x72, 0x20, 0x63, 0x72, 0x6f, - 0x70, 0x70, 0x69, 0x6e, 0x67, 0x20, 0x74, 0x6f, - 0x20, 0x70, 0x61, 0x67, 0x65, 0x20, 0x74, 0x6f, - 0x20, 0x55, 0x53, 0x20, 0x6c, 0x65, 0x67, 0x61, - 0x6c, 0x20, 0x73, 0x69, 0x7a, 0x65, 0x22, 0x3e, - 0x4c, 0x65, 0x5f, 0x67, 0x61, 0x6c, 0x3c, 0x2f, - 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, - 0x3e, 0x3c, 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, - 0x74, 0x79, 0x20, 0x6e, 0x61, 0x6d, 0x65, 0x3d, - 0x22, 0x75, 0x73, 0x65, 0x5f, 0x75, 0x6e, 0x64, - 0x65, 0x72, 0x6c, 0x69, 0x6e, 0x65, 0x22, 0x3e, - 0x54, 0x72, 0x75, 0x65, 0x3c, 0x2f, 0x70, 0x72, - 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, 0x3e, 0x3c, - 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, - 0x20, 0x6e, 0x61, 0x6d, 0x65, 0x3d, 0x22, 0x64, - 0x72, 0x61, 0x77, 0x5f, 0x61, 0x73, 0x5f, 0x72, - 0x61, 0x64, 0x69, 0x6f, 0x22, 0x3e, 0x54, 0x72, - 0x75, 0x65, 0x3c, 0x2f, 0x70, 0x72, 0x6f, 0x70, - 0x65, 0x72, 0x74, 0x79, 0x3e, 0x3c, 0x70, 0x72, - 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, 0x20, 0x6e, - 0x61, 0x6d, 0x65, 0x3d, 0x22, 0x67, 0x72, 0x6f, - 0x75, 0x70, 0x22, 0x3e, 0x6e, 0x6f, 0x5f, 0x63, - 0x72, 0x6f, 0x70, 0x5f, 0x6d, 0x65, 0x6e, 0x75, - 0x69, 0x74, 0x65, 0x6d, 0x3c, 0x2f, 0x70, 0x72, - 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, 0x3e, 0x3c, - 0x73, 0x69, 0x67, 0x6e, 0x61, 0x6c, 0x20, 0x6e, - 0x61, 0x6d, 0x65, 0x3d, 0x22, 0x74, 0x6f, 0x67, - 0x67, 0x6c, 0x65, 0x64, 0x22, 0x20, 0x68, 0x61, - 0x6e, 0x64, 0x6c, 0x65, 0x72, 0x3d, 0x22, 0x6c, - 0x65, 0x67, 0x61, 0x6c, 0x5f, 0x6d, 0x65, 0x6e, - 0x75, 0x69, 0x74, 0x65, 0x6d, 0x5f, 0x74, 0x6f, - 0x67, 0x67, 0x6c, 0x65, 0x64, 0x5f, 0x63, 0x62, - 0x22, 0x20, 0x73, 0x77, 0x61, 0x70, 0x70, 0x65, - 0x64, 0x3d, 0x22, 0x6e, 0x6f, 0x22, 0x2f, 0x3e, - 0x3c, 0x2f, 0x6f, 0x62, 0x6a, 0x65, 0x63, 0x74, - 0x3e, 0x3c, 0x2f, 0x63, 0x68, 0x69, 0x6c, 0x64, - 0x3e, 0x3c, 0x63, 0x68, 0x69, 0x6c, 0x64, 0x3e, - 0x3c, 0x6f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x20, - 0x63, 0x6c, 0x61, 0x73, 0x73, 0x3d, 0x22, 0x47, - 0x74, 0x6b, 0x52, 0x61, 0x64, 0x69, 0x6f, 0x4d, - 0x65, 0x6e, 0x75, 0x49, 0x74, 0x65, 0x6d, 0x22, - 0x20, 0x69, 0x64, 0x3d, 0x22, 0x66, 0x6f, 0x75, - 0x72, 0x5f, 0x62, 0x79, 0x5f, 0x73, 0x69, 0x78, - 0x5f, 0x6d, 0x65, 0x6e, 0x75, 0x69, 0x74, 0x65, - 0x6d, 0x22, 0x3e, 0x3c, 0x70, 0x72, 0x6f, 0x70, - 0x65, 0x72, 0x74, 0x79, 0x20, 0x6e, 0x61, 0x6d, - 0x65, 0x3d, 0x22, 0x76, 0x69, 0x73, 0x69, 0x62, - 0x6c, 0x65, 0x22, 0x3e, 0x54, 0x72, 0x75, 0x65, - 0x3c, 0x2f, 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, - 0x74, 0x79, 0x3e, 0x3c, 0x70, 0x72, 0x6f, 0x70, - 0x65, 0x72, 0x74, 0x79, 0x20, 0x6e, 0x61, 0x6d, - 0x65, 0x3d, 0x22, 0x63, 0x61, 0x6e, 0x5f, 0x66, - 0x6f, 0x63, 0x75, 0x73, 0x22, 0x3e, 0x46, 0x61, - 0x6c, 0x73, 0x65, 0x3c, 0x2f, 0x70, 0x72, 0x6f, - 0x70, 0x65, 0x72, 0x74, 0x79, 0x3e, 0x3c, 0x70, - 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, 0x20, - 0x6e, 0x61, 0x6d, 0x65, 0x3d, 0x22, 0x6c, 0x61, - 0x62, 0x65, 0x6c, 0x22, 0x20, 0x74, 0x72, 0x61, - 0x6e, 0x73, 0x6c, 0x61, 0x74, 0x61, 0x62, 0x6c, - 0x65, 0x3d, 0x22, 0x79, 0x65, 0x73, 0x22, 0x20, - 0x63, 0x6f, 0x6d, 0x6d, 0x65, 0x6e, 0x74, 0x73, - 0x3d, 0x22, 0x52, 0x61, 0x64, 0x69, 0x6f, 0x20, - 0x62, 0x75, 0x74, 0x74, 0x6f, 0x6e, 0x20, 0x66, - 0x6f, 0x72, 0x20, 0x63, 0x72, 0x6f, 0x70, 0x70, - 0x69, 0x6e, 0x67, 0x20, 0x70, 0x61, 0x67, 0x65, - 0x20, 0x74, 0x6f, 0x20, 0x34, 0x78, 0x36, 0x20, - 0x69, 0x6e, 0x63, 0x68, 0x22, 0x3e, 0x34, 0xc3, - 0x97, 0x36, 0x3c, 0x2f, 0x70, 0x72, 0x6f, 0x70, - 0x65, 0x72, 0x74, 0x79, 0x3e, 0x3c, 0x70, 0x72, - 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, 0x20, 0x6e, - 0x61, 0x6d, 0x65, 0x3d, 0x22, 0x75, 0x73, 0x65, - 0x5f, 0x75, 0x6e, 0x64, 0x65, 0x72, 0x6c, 0x69, - 0x6e, 0x65, 0x22, 0x3e, 0x54, 0x72, 0x75, 0x65, - 0x3c, 0x2f, 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, - 0x74, 0x79, 0x3e, 0x3c, 0x70, 0x72, 0x6f, 0x70, - 0x65, 0x72, 0x74, 0x79, 0x20, 0x6e, 0x61, 0x6d, - 0x65, 0x3d, 0x22, 0x64, 0x72, 0x61, 0x77, 0x5f, - 0x61, 0x73, 0x5f, 0x72, 0x61, 0x64, 0x69, 0x6f, - 0x22, 0x3e, 0x54, 0x72, 0x75, 0x65, 0x3c, 0x2f, - 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, - 0x3e, 0x3c, 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, - 0x74, 0x79, 0x20, 0x6e, 0x61, 0x6d, 0x65, 0x3d, - 0x22, 0x67, 0x72, 0x6f, 0x75, 0x70, 0x22, 0x3e, - 0x6e, 0x6f, 0x5f, 0x63, 0x72, 0x6f, 0x70, 0x5f, - 0x6d, 0x65, 0x6e, 0x75, 0x69, 0x74, 0x65, 0x6d, - 0x3c, 0x2f, 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, - 0x74, 0x79, 0x3e, 0x3c, 0x73, 0x69, 0x67, 0x6e, - 0x61, 0x6c, 0x20, 0x6e, 0x61, 0x6d, 0x65, 0x3d, - 0x22, 0x74, 0x6f, 0x67, 0x67, 0x6c, 0x65, 0x64, - 0x22, 0x20, 0x68, 0x61, 0x6e, 0x64, 0x6c, 0x65, - 0x72, 0x3d, 0x22, 0x66, 0x6f, 0x75, 0x72, 0x5f, - 0x62, 0x79, 0x5f, 0x73, 0x69, 0x78, 0x5f, 0x6d, - 0x65, 0x6e, 0x75, 0x69, 0x74, 0x65, 0x6d, 0x5f, - 0x74, 0x6f, 0x67, 0x67, 0x6c, 0x65, 0x64, 0x5f, - 0x63, 0x62, 0x22, 0x20, 0x73, 0x77, 0x61, 0x70, - 0x70, 0x65, 0x64, 0x3d, 0x22, 0x6e, 0x6f, 0x22, - 0x2f, 0x3e, 0x3c, 0x2f, 0x6f, 0x62, 0x6a, 0x65, - 0x63, 0x74, 0x3e, 0x3c, 0x2f, 0x63, 0x68, 0x69, - 0x6c, 0x64, 0x3e, 0x3c, 0x63, 0x68, 0x69, 0x6c, - 0x64, 0x3e, 0x3c, 0x6f, 0x62, 0x6a, 0x65, 0x63, - 0x74, 0x20, 0x63, 0x6c, 0x61, 0x73, 0x73, 0x3d, - 0x22, 0x47, 0x74, 0x6b, 0x52, 0x61, 0x64, 0x69, - 0x6f, 0x4d, 0x65, 0x6e, 0x75, 0x49, 0x74, 0x65, - 0x6d, 0x22, 0x20, 0x69, 0x64, 0x3d, 0x22, 0x63, - 0x75, 0x73, 0x74, 0x6f, 0x6d, 0x5f, 0x63, 0x72, - 0x6f, 0x70, 0x5f, 0x6d, 0x65, 0x6e, 0x75, 0x69, - 0x74, 0x65, 0x6d, 0x22, 0x3e, 0x3c, 0x70, 0x72, - 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, 0x20, 0x6e, - 0x61, 0x6d, 0x65, 0x3d, 0x22, 0x76, 0x69, 0x73, - 0x69, 0x62, 0x6c, 0x65, 0x22, 0x3e, 0x54, 0x72, - 0x75, 0x65, 0x3c, 0x2f, 0x70, 0x72, 0x6f, 0x70, - 0x65, 0x72, 0x74, 0x79, 0x3e, 0x3c, 0x70, 0x72, - 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, 0x20, 0x6e, - 0x61, 0x6d, 0x65, 0x3d, 0x22, 0x63, 0x61, 0x6e, - 0x5f, 0x66, 0x6f, 0x63, 0x75, 0x73, 0x22, 0x3e, - 0x46, 0x61, 0x6c, 0x73, 0x65, 0x3c, 0x2f, 0x70, - 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, 0x3e, - 0x3c, 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, - 0x79, 0x20, 0x6e, 0x61, 0x6d, 0x65, 0x3d, 0x22, - 0x6c, 0x61, 0x62, 0x65, 0x6c, 0x22, 0x20, 0x74, - 0x72, 0x61, 0x6e, 0x73, 0x6c, 0x61, 0x74, 0x61, - 0x62, 0x6c, 0x65, 0x3d, 0x22, 0x79, 0x65, 0x73, - 0x22, 0x20, 0x63, 0x6f, 0x6d, 0x6d, 0x65, 0x6e, - 0x74, 0x73, 0x3d, 0x22, 0x52, 0x61, 0x64, 0x69, - 0x6f, 0x20, 0x62, 0x75, 0x74, 0x74, 0x6f, 0x6e, - 0x20, 0x66, 0x6f, 0x72, 0x20, 0x63, 0x72, 0x6f, - 0x70, 0x70, 0x69, 0x6e, 0x67, 0x20, 0x74, 0x6f, - 0x20, 0x63, 0x75, 0x73, 0x74, 0x6f, 0x6d, 0x20, - 0x70, 0x61, 0x67, 0x65, 0x20, 0x73, 0x69, 0x7a, - 0x65, 0x22, 0x3e, 0x5f, 0x43, 0x75, 0x73, 0x74, - 0x6f, 0x6d, 0x3c, 0x2f, 0x70, 0x72, 0x6f, 0x70, - 0x65, 0x72, 0x74, 0x79, 0x3e, 0x3c, 0x70, 0x72, - 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, 0x20, 0x6e, - 0x61, 0x6d, 0x65, 0x3d, 0x22, 0x75, 0x73, 0x65, - 0x5f, 0x75, 0x6e, 0x64, 0x65, 0x72, 0x6c, 0x69, - 0x6e, 0x65, 0x22, 0x3e, 0x54, 0x72, 0x75, 0x65, - 0x3c, 0x2f, 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, - 0x74, 0x79, 0x3e, 0x3c, 0x70, 0x72, 0x6f, 0x70, - 0x65, 0x72, 0x74, 0x79, 0x20, 0x6e, 0x61, 0x6d, - 0x65, 0x3d, 0x22, 0x64, 0x72, 0x61, 0x77, 0x5f, - 0x61, 0x73, 0x5f, 0x72, 0x61, 0x64, 0x69, 0x6f, - 0x22, 0x3e, 0x54, 0x72, 0x75, 0x65, 0x3c, 0x2f, - 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, - 0x3e, 0x3c, 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, - 0x74, 0x79, 0x20, 0x6e, 0x61, 0x6d, 0x65, 0x3d, - 0x22, 0x67, 0x72, 0x6f, 0x75, 0x70, 0x22, 0x3e, - 0x6e, 0x6f, 0x5f, 0x63, 0x72, 0x6f, 0x70, 0x5f, - 0x6d, 0x65, 0x6e, 0x75, 0x69, 0x74, 0x65, 0x6d, - 0x3c, 0x2f, 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, - 0x74, 0x79, 0x3e, 0x3c, 0x73, 0x69, 0x67, 0x6e, - 0x61, 0x6c, 0x20, 0x6e, 0x61, 0x6d, 0x65, 0x3d, - 0x22, 0x74, 0x6f, 0x67, 0x67, 0x6c, 0x65, 0x64, - 0x22, 0x20, 0x68, 0x61, 0x6e, 0x64, 0x6c, 0x65, - 0x72, 0x3d, 0x22, 0x63, 0x75, 0x73, 0x74, 0x6f, - 0x6d, 0x5f, 0x63, 0x72, 0x6f, 0x70, 0x5f, 0x6d, - 0x65, 0x6e, 0x75, 0x69, 0x74, 0x65, 0x6d, 0x5f, - 0x74, 0x6f, 0x67, 0x67, 0x6c, 0x65, 0x64, 0x5f, - 0x63, 0x62, 0x22, 0x20, 0x73, 0x77, 0x61, 0x70, - 0x70, 0x65, 0x64, 0x3d, 0x22, 0x6e, 0x6f, 0x22, - 0x2f, 0x3e, 0x3c, 0x2f, 0x6f, 0x62, 0x6a, 0x65, - 0x63, 0x74, 0x3e, 0x3c, 0x2f, 0x63, 0x68, 0x69, - 0x6c, 0x64, 0x3e, 0x3c, 0x63, 0x68, 0x69, 0x6c, - 0x64, 0x3e, 0x3c, 0x6f, 0x62, 0x6a, 0x65, 0x63, - 0x74, 0x20, 0x63, 0x6c, 0x61, 0x73, 0x73, 0x3d, - 0x22, 0x47, 0x74, 0x6b, 0x53, 0x65, 0x70, 0x61, - 0x72, 0x61, 0x74, 0x6f, 0x72, 0x4d, 0x65, 0x6e, - 0x75, 0x49, 0x74, 0x65, 0x6d, 0x22, 0x20, 0x69, - 0x64, 0x3d, 0x22, 0x63, 0x72, 0x6f, 0x70, 0x5f, - 0x73, 0x65, 0x70, 0x5f, 0x6d, 0x65, 0x6e, 0x75, - 0x69, 0x74, 0x65, 0x6d, 0x22, 0x3e, 0x3c, 0x70, - 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, 0x20, - 0x6e, 0x61, 0x6d, 0x65, 0x3d, 0x22, 0x76, 0x69, - 0x73, 0x69, 0x62, 0x6c, 0x65, 0x22, 0x3e, 0x54, - 0x72, 0x75, 0x65, 0x3c, 0x2f, 0x70, 0x72, 0x6f, - 0x70, 0x65, 0x72, 0x74, 0x79, 0x3e, 0x3c, 0x70, - 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, 0x20, - 0x6e, 0x61, 0x6d, 0x65, 0x3d, 0x22, 0x63, 0x61, - 0x6e, 0x5f, 0x66, 0x6f, 0x63, 0x75, 0x73, 0x22, - 0x3e, 0x46, 0x61, 0x6c, 0x73, 0x65, 0x3c, 0x2f, - 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, - 0x3e, 0x3c, 0x2f, 0x6f, 0x62, 0x6a, 0x65, 0x63, - 0x74, 0x3e, 0x3c, 0x2f, 0x63, 0x68, 0x69, 0x6c, - 0x64, 0x3e, 0x3c, 0x63, 0x68, 0x69, 0x6c, 0x64, - 0x3e, 0x3c, 0x6f, 0x62, 0x6a, 0x65, 0x63, 0x74, - 0x20, 0x63, 0x6c, 0x61, 0x73, 0x73, 0x3d, 0x22, - 0x47, 0x74, 0x6b, 0x4d, 0x65, 0x6e, 0x75, 0x49, - 0x74, 0x65, 0x6d, 0x22, 0x20, 0x69, 0x64, 0x3d, - 0x22, 0x63, 0x72, 0x6f, 0x70, 0x5f, 0x72, 0x6f, - 0x74, 0x61, 0x74, 0x65, 0x5f, 0x6d, 0x65, 0x6e, - 0x75, 0x69, 0x74, 0x65, 0x6d, 0x22, 0x3e, 0x3c, - 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, - 0x20, 0x6e, 0x61, 0x6d, 0x65, 0x3d, 0x22, 0x76, - 0x69, 0x73, 0x69, 0x62, 0x6c, 0x65, 0x22, 0x3e, - 0x54, 0x72, 0x75, 0x65, 0x3c, 0x2f, 0x70, 0x72, - 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, 0x3e, 0x3c, - 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, - 0x20, 0x6e, 0x61, 0x6d, 0x65, 0x3d, 0x22, 0x73, - 0x65, 0x6e, 0x73, 0x69, 0x74, 0x69, 0x76, 0x65, - 0x22, 0x3e, 0x46, 0x61, 0x6c, 0x73, 0x65, 0x3c, - 0x2f, 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, - 0x79, 0x3e, 0x3c, 0x70, 0x72, 0x6f, 0x70, 0x65, - 0x72, 0x74, 0x79, 0x20, 0x6e, 0x61, 0x6d, 0x65, - 0x3d, 0x22, 0x63, 0x61, 0x6e, 0x5f, 0x66, 0x6f, - 0x63, 0x75, 0x73, 0x22, 0x3e, 0x46, 0x61, 0x6c, - 0x73, 0x65, 0x3c, 0x2f, 0x70, 0x72, 0x6f, 0x70, - 0x65, 0x72, 0x74, 0x79, 0x3e, 0x3c, 0x70, 0x72, - 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, 0x20, 0x6e, - 0x61, 0x6d, 0x65, 0x3d, 0x22, 0x6c, 0x61, 0x62, - 0x65, 0x6c, 0x22, 0x20, 0x74, 0x72, 0x61, 0x6e, - 0x73, 0x6c, 0x61, 0x74, 0x61, 0x62, 0x6c, 0x65, - 0x3d, 0x22, 0x79, 0x65, 0x73, 0x22, 0x20, 0x63, - 0x6f, 0x6d, 0x6d, 0x65, 0x6e, 0x74, 0x73, 0x3d, - 0x22, 0x4d, 0x65, 0x6e, 0x75, 0x20, 0x69, 0x74, - 0x65, 0x6d, 0x20, 0x74, 0x6f, 0x20, 0x72, 0x6f, - 0x74, 0x61, 0x74, 0x65, 0x20, 0x74, 0x68, 0x65, - 0x20, 0x63, 0x72, 0x6f, 0x70, 0x20, 0x61, 0x72, - 0x65, 0x61, 0x22, 0x3e, 0x5f, 0x52, 0x6f, 0x74, - 0x61, 0x74, 0x65, 0x20, 0x43, 0x72, 0x6f, 0x70, - 0x3c, 0x2f, 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, - 0x74, 0x79, 0x3e, 0x3c, 0x70, 0x72, 0x6f, 0x70, - 0x65, 0x72, 0x74, 0x79, 0x20, 0x6e, 0x61, 0x6d, - 0x65, 0x3d, 0x22, 0x75, 0x73, 0x65, 0x5f, 0x75, - 0x6e, 0x64, 0x65, 0x72, 0x6c, 0x69, 0x6e, 0x65, - 0x22, 0x3e, 0x54, 0x72, 0x75, 0x65, 0x3c, 0x2f, - 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, - 0x3e, 0x3c, 0x73, 0x69, 0x67, 0x6e, 0x61, 0x6c, - 0x20, 0x6e, 0x61, 0x6d, 0x65, 0x3d, 0x22, 0x61, - 0x63, 0x74, 0x69, 0x76, 0x61, 0x74, 0x65, 0x22, - 0x20, 0x68, 0x61, 0x6e, 0x64, 0x6c, 0x65, 0x72, - 0x3d, 0x22, 0x63, 0x72, 0x6f, 0x70, 0x5f, 0x72, - 0x6f, 0x74, 0x61, 0x74, 0x65, 0x5f, 0x6d, 0x65, - 0x6e, 0x75, 0x69, 0x74, 0x65, 0x6d, 0x5f, 0x61, - 0x63, 0x74, 0x69, 0x76, 0x61, 0x74, 0x65, 0x5f, - 0x63, 0x62, 0x22, 0x20, 0x73, 0x77, 0x61, 0x70, - 0x70, 0x65, 0x64, 0x3d, 0x22, 0x6e, 0x6f, 0x22, - 0x2f, 0x3e, 0x3c, 0x2f, 0x6f, 0x62, 0x6a, 0x65, - 0x63, 0x74, 0x3e, 0x3c, 0x2f, 0x63, 0x68, 0x69, - 0x6c, 0x64, 0x3e, 0x3c, 0x2f, 0x6f, 0x62, 0x6a, - 0x65, 0x63, 0x74, 0x3e, 0x3c, 0x2f, 0x63, 0x68, - 0x69, 0x6c, 0x64, 0x3e, 0x3c, 0x2f, 0x6f, 0x62, - 0x6a, 0x65, 0x63, 0x74, 0x3e, 0x3c, 0x2f, 0x63, - 0x68, 0x69, 0x6c, 0x64, 0x3e, 0x3c, 0x63, 0x68, - 0x69, 0x6c, 0x64, 0x3e, 0x3c, 0x6f, 0x62, 0x6a, - 0x65, 0x63, 0x74, 0x20, 0x63, 0x6c, 0x61, 0x73, - 0x73, 0x3d, 0x22, 0x47, 0x74, 0x6b, 0x4d, 0x65, - 0x6e, 0x75, 0x49, 0x74, 0x65, 0x6d, 0x22, 0x20, - 0x69, 0x64, 0x3d, 0x22, 0x70, 0x61, 0x67, 0x65, - 0x5f, 0x6d, 0x6f, 0x76, 0x65, 0x5f, 0x6c, 0x65, - 0x66, 0x74, 0x5f, 0x6d, 0x65, 0x6e, 0x75, 0x69, - 0x74, 0x65, 0x6d, 0x22, 0x3e, 0x3c, 0x70, 0x72, - 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, 0x20, 0x6e, - 0x61, 0x6d, 0x65, 0x3d, 0x22, 0x76, 0x69, 0x73, - 0x69, 0x62, 0x6c, 0x65, 0x22, 0x3e, 0x54, 0x72, - 0x75, 0x65, 0x3c, 0x2f, 0x70, 0x72, 0x6f, 0x70, - 0x65, 0x72, 0x74, 0x79, 0x3e, 0x3c, 0x70, 0x72, - 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, 0x20, 0x6e, - 0x61, 0x6d, 0x65, 0x3d, 0x22, 0x63, 0x61, 0x6e, - 0x5f, 0x66, 0x6f, 0x63, 0x75, 0x73, 0x22, 0x3e, - 0x46, 0x61, 0x6c, 0x73, 0x65, 0x3c, 0x2f, 0x70, - 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, 0x3e, - 0x3c, 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, - 0x79, 0x20, 0x6e, 0x61, 0x6d, 0x65, 0x3d, 0x22, - 0x6c, 0x61, 0x62, 0x65, 0x6c, 0x22, 0x20, 0x74, - 0x72, 0x61, 0x6e, 0x73, 0x6c, 0x61, 0x74, 0x61, - 0x62, 0x6c, 0x65, 0x3d, 0x22, 0x79, 0x65, 0x73, - 0x22, 0x20, 0x63, 0x6f, 0x6d, 0x6d, 0x65, 0x6e, - 0x74, 0x73, 0x3d, 0x22, 0x4d, 0x65, 0x6e, 0x75, - 0x20, 0x69, 0x74, 0x65, 0x6d, 0x20, 0x74, 0x6f, - 0x20, 0x6d, 0x6f, 0x76, 0x65, 0x20, 0x74, 0x68, - 0x65, 0x20, 0x73, 0x65, 0x6c, 0x65, 0x63, 0x74, - 0x65, 0x64, 0x20, 0x70, 0x61, 0x67, 0x65, 0x20, - 0x74, 0x6f, 0x20, 0x74, 0x68, 0x65, 0x20, 0x6c, - 0x65, 0x66, 0x74, 0x22, 0x3e, 0x4d, 0x6f, 0x76, - 0x65, 0x20, 0x4c, 0x65, 0x66, 0x74, 0x3c, 0x2f, - 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, - 0x3e, 0x3c, 0x61, 0x63, 0x63, 0x65, 0x6c, 0x65, - 0x72, 0x61, 0x74, 0x6f, 0x72, 0x20, 0x6b, 0x65, - 0x79, 0x3d, 0x22, 0x6c, 0x65, 0x73, 0x73, 0x22, - 0x20, 0x73, 0x69, 0x67, 0x6e, 0x61, 0x6c, 0x3d, - 0x22, 0x61, 0x63, 0x74, 0x69, 0x76, 0x61, 0x74, - 0x65, 0x22, 0x2f, 0x3e, 0x3c, 0x73, 0x69, 0x67, - 0x6e, 0x61, 0x6c, 0x20, 0x6e, 0x61, 0x6d, 0x65, - 0x3d, 0x22, 0x61, 0x63, 0x74, 0x69, 0x76, 0x61, - 0x74, 0x65, 0x22, 0x20, 0x68, 0x61, 0x6e, 0x64, - 0x6c, 0x65, 0x72, 0x3d, 0x22, 0x70, 0x61, 0x67, - 0x65, 0x5f, 0x6d, 0x6f, 0x76, 0x65, 0x5f, 0x6c, - 0x65, 0x66, 0x74, 0x5f, 0x6d, 0x65, 0x6e, 0x75, - 0x69, 0x74, 0x65, 0x6d, 0x5f, 0x61, 0x63, 0x74, - 0x69, 0x76, 0x61, 0x74, 0x65, 0x5f, 0x63, 0x62, - 0x22, 0x20, 0x73, 0x77, 0x61, 0x70, 0x70, 0x65, - 0x64, 0x3d, 0x22, 0x6e, 0x6f, 0x22, 0x2f, 0x3e, - 0x3c, 0x2f, 0x6f, 0x62, 0x6a, 0x65, 0x63, 0x74, - 0x3e, 0x3c, 0x2f, 0x63, 0x68, 0x69, 0x6c, 0x64, - 0x3e, 0x3c, 0x63, 0x68, 0x69, 0x6c, 0x64, 0x3e, - 0x3c, 0x6f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x20, - 0x63, 0x6c, 0x61, 0x73, 0x73, 0x3d, 0x22, 0x47, - 0x74, 0x6b, 0x4d, 0x65, 0x6e, 0x75, 0x49, 0x74, - 0x65, 0x6d, 0x22, 0x20, 0x69, 0x64, 0x3d, 0x22, - 0x70, 0x61, 0x67, 0x65, 0x5f, 0x6d, 0x6f, 0x76, - 0x65, 0x5f, 0x72, 0x69, 0x67, 0x68, 0x74, 0x5f, - 0x6d, 0x65, 0x6e, 0x75, 0x69, 0x74, 0x65, 0x6d, - 0x22, 0x3e, 0x3c, 0x70, 0x72, 0x6f, 0x70, 0x65, - 0x72, 0x74, 0x79, 0x20, 0x6e, 0x61, 0x6d, 0x65, - 0x3d, 0x22, 0x76, 0x69, 0x73, 0x69, 0x62, 0x6c, - 0x65, 0x22, 0x3e, 0x54, 0x72, 0x75, 0x65, 0x3c, - 0x2f, 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, - 0x79, 0x3e, 0x3c, 0x70, 0x72, 0x6f, 0x70, 0x65, - 0x72, 0x74, 0x79, 0x20, 0x6e, 0x61, 0x6d, 0x65, - 0x3d, 0x22, 0x63, 0x61, 0x6e, 0x5f, 0x66, 0x6f, - 0x63, 0x75, 0x73, 0x22, 0x3e, 0x46, 0x61, 0x6c, - 0x73, 0x65, 0x3c, 0x2f, 0x70, 0x72, 0x6f, 0x70, - 0x65, 0x72, 0x74, 0x79, 0x3e, 0x3c, 0x70, 0x72, - 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, 0x20, 0x6e, - 0x61, 0x6d, 0x65, 0x3d, 0x22, 0x6c, 0x61, 0x62, - 0x65, 0x6c, 0x22, 0x20, 0x74, 0x72, 0x61, 0x6e, - 0x73, 0x6c, 0x61, 0x74, 0x61, 0x62, 0x6c, 0x65, - 0x3d, 0x22, 0x79, 0x65, 0x73, 0x22, 0x20, 0x63, - 0x6f, 0x6d, 0x6d, 0x65, 0x6e, 0x74, 0x73, 0x3d, - 0x22, 0x4d, 0x65, 0x6e, 0x75, 0x20, 0x69, 0x74, - 0x65, 0x6d, 0x20, 0x74, 0x6f, 0x20, 0x6d, 0x6f, - 0x76, 0x65, 0x20, 0x74, 0x68, 0x65, 0x20, 0x73, - 0x65, 0x6c, 0x65, 0x63, 0x74, 0x65, 0x64, 0x20, - 0x70, 0x61, 0x67, 0x65, 0x20, 0x74, 0x6f, 0x20, - 0x74, 0x68, 0x65, 0x20, 0x72, 0x69, 0x67, 0x68, - 0x74, 0x22, 0x3e, 0x4d, 0x6f, 0x76, 0x65, 0x20, - 0x52, 0x69, 0x67, 0x68, 0x74, 0x3c, 0x2f, 0x70, - 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, 0x3e, - 0x3c, 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, - 0x79, 0x20, 0x6e, 0x61, 0x6d, 0x65, 0x3d, 0x22, - 0x75, 0x73, 0x65, 0x5f, 0x75, 0x6e, 0x64, 0x65, - 0x72, 0x6c, 0x69, 0x6e, 0x65, 0x22, 0x3e, 0x54, - 0x72, 0x75, 0x65, 0x3c, 0x2f, 0x70, 0x72, 0x6f, - 0x70, 0x65, 0x72, 0x74, 0x79, 0x3e, 0x3c, 0x61, - 0x63, 0x63, 0x65, 0x6c, 0x65, 0x72, 0x61, 0x74, - 0x6f, 0x72, 0x20, 0x6b, 0x65, 0x79, 0x3d, 0x22, - 0x67, 0x72, 0x65, 0x61, 0x74, 0x65, 0x72, 0x22, - 0x20, 0x73, 0x69, 0x67, 0x6e, 0x61, 0x6c, 0x3d, - 0x22, 0x61, 0x63, 0x74, 0x69, 0x76, 0x61, 0x74, - 0x65, 0x22, 0x2f, 0x3e, 0x3c, 0x73, 0x69, 0x67, - 0x6e, 0x61, 0x6c, 0x20, 0x6e, 0x61, 0x6d, 0x65, - 0x3d, 0x22, 0x61, 0x63, 0x74, 0x69, 0x76, 0x61, - 0x74, 0x65, 0x22, 0x20, 0x68, 0x61, 0x6e, 0x64, - 0x6c, 0x65, 0x72, 0x3d, 0x22, 0x70, 0x61, 0x67, - 0x65, 0x5f, 0x6d, 0x6f, 0x76, 0x65, 0x5f, 0x72, - 0x69, 0x67, 0x68, 0x74, 0x5f, 0x6d, 0x65, 0x6e, - 0x75, 0x69, 0x74, 0x65, 0x6d, 0x5f, 0x61, 0x63, - 0x74, 0x69, 0x76, 0x61, 0x74, 0x65, 0x5f, 0x63, - 0x62, 0x22, 0x20, 0x73, 0x77, 0x61, 0x70, 0x70, - 0x65, 0x64, 0x3d, 0x22, 0x6e, 0x6f, 0x22, 0x2f, - 0x3e, 0x3c, 0x2f, 0x6f, 0x62, 0x6a, 0x65, 0x63, - 0x74, 0x3e, 0x3c, 0x2f, 0x63, 0x68, 0x69, 0x6c, - 0x64, 0x3e, 0x3c, 0x63, 0x68, 0x69, 0x6c, 0x64, - 0x3e, 0x3c, 0x6f, 0x62, 0x6a, 0x65, 0x63, 0x74, - 0x20, 0x63, 0x6c, 0x61, 0x73, 0x73, 0x3d, 0x22, - 0x47, 0x74, 0x6b, 0x49, 0x6d, 0x61, 0x67, 0x65, - 0x4d, 0x65, 0x6e, 0x75, 0x49, 0x74, 0x65, 0x6d, - 0x22, 0x20, 0x69, 0x64, 0x3d, 0x22, 0x63, 0x6f, - 0x70, 0x79, 0x5f, 0x74, 0x6f, 0x5f, 0x63, 0x6c, - 0x69, 0x70, 0x62, 0x6f, 0x61, 0x72, 0x64, 0x5f, - 0x6d, 0x65, 0x6e, 0x75, 0x69, 0x74, 0x65, 0x6d, - 0x22, 0x3e, 0x3c, 0x70, 0x72, 0x6f, 0x70, 0x65, - 0x72, 0x74, 0x79, 0x20, 0x6e, 0x61, 0x6d, 0x65, - 0x3d, 0x22, 0x6c, 0x61, 0x62, 0x65, 0x6c, 0x22, - 0x3e, 0x67, 0x74, 0x6b, 0x2d, 0x63, 0x6f, 0x70, - 0x79, 0x3c, 0x2f, 0x70, 0x72, 0x6f, 0x70, 0x65, - 0x72, 0x74, 0x79, 0x3e, 0x3c, 0x70, 0x72, 0x6f, - 0x70, 0x65, 0x72, 0x74, 0x79, 0x20, 0x6e, 0x61, - 0x6d, 0x65, 0x3d, 0x22, 0x76, 0x69, 0x73, 0x69, - 0x62, 0x6c, 0x65, 0x22, 0x3e, 0x54, 0x72, 0x75, - 0x65, 0x3c, 0x2f, 0x70, 0x72, 0x6f, 0x70, 0x65, - 0x72, 0x74, 0x79, 0x3e, 0x3c, 0x70, 0x72, 0x6f, - 0x70, 0x65, 0x72, 0x74, 0x79, 0x20, 0x6e, 0x61, - 0x6d, 0x65, 0x3d, 0x22, 0x73, 0x65, 0x6e, 0x73, - 0x69, 0x74, 0x69, 0x76, 0x65, 0x22, 0x3e, 0x46, - 0x61, 0x6c, 0x73, 0x65, 0x3c, 0x2f, 0x70, 0x72, - 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, 0x3e, 0x3c, - 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, - 0x20, 0x6e, 0x61, 0x6d, 0x65, 0x3d, 0x22, 0x63, - 0x61, 0x6e, 0x5f, 0x66, 0x6f, 0x63, 0x75, 0x73, - 0x22, 0x3e, 0x46, 0x61, 0x6c, 0x73, 0x65, 0x3c, - 0x2f, 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, - 0x79, 0x3e, 0x3c, 0x70, 0x72, 0x6f, 0x70, 0x65, - 0x72, 0x74, 0x79, 0x20, 0x6e, 0x61, 0x6d, 0x65, - 0x3d, 0x22, 0x75, 0x73, 0x65, 0x5f, 0x75, 0x6e, - 0x64, 0x65, 0x72, 0x6c, 0x69, 0x6e, 0x65, 0x22, - 0x3e, 0x54, 0x72, 0x75, 0x65, 0x3c, 0x2f, 0x70, - 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, 0x3e, - 0x3c, 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, - 0x79, 0x20, 0x6e, 0x61, 0x6d, 0x65, 0x3d, 0x22, - 0x75, 0x73, 0x65, 0x5f, 0x73, 0x74, 0x6f, 0x63, - 0x6b, 0x22, 0x3e, 0x54, 0x72, 0x75, 0x65, 0x3c, - 0x2f, 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, - 0x79, 0x3e, 0x3c, 0x61, 0x63, 0x63, 0x65, 0x6c, - 0x65, 0x72, 0x61, 0x74, 0x6f, 0x72, 0x20, 0x6b, - 0x65, 0x79, 0x3d, 0x22, 0x63, 0x22, 0x20, 0x73, - 0x69, 0x67, 0x6e, 0x61, 0x6c, 0x3d, 0x22, 0x61, - 0x63, 0x74, 0x69, 0x76, 0x61, 0x74, 0x65, 0x22, - 0x20, 0x6d, 0x6f, 0x64, 0x69, 0x66, 0x69, 0x65, - 0x72, 0x73, 0x3d, 0x22, 0x47, 0x44, 0x4b, 0x5f, - 0x43, 0x4f, 0x4e, 0x54, 0x52, 0x4f, 0x4c, 0x5f, - 0x4d, 0x41, 0x53, 0x4b, 0x22, 0x2f, 0x3e, 0x3c, - 0x73, 0x69, 0x67, 0x6e, 0x61, 0x6c, 0x20, 0x6e, - 0x61, 0x6d, 0x65, 0x3d, 0x22, 0x61, 0x63, 0x74, - 0x69, 0x76, 0x61, 0x74, 0x65, 0x22, 0x20, 0x68, - 0x61, 0x6e, 0x64, 0x6c, 0x65, 0x72, 0x3d, 0x22, - 0x63, 0x6f, 0x70, 0x79, 0x5f, 0x74, 0x6f, 0x5f, - 0x63, 0x6c, 0x69, 0x70, 0x62, 0x6f, 0x61, 0x72, - 0x64, 0x5f, 0x62, 0x75, 0x74, 0x74, 0x6f, 0x6e, - 0x5f, 0x63, 0x6c, 0x69, 0x63, 0x6b, 0x65, 0x64, - 0x5f, 0x63, 0x62, 0x22, 0x20, 0x73, 0x77, 0x61, - 0x70, 0x70, 0x65, 0x64, 0x3d, 0x22, 0x6e, 0x6f, - 0x22, 0x2f, 0x3e, 0x3c, 0x2f, 0x6f, 0x62, 0x6a, - 0x65, 0x63, 0x74, 0x3e, 0x3c, 0x2f, 0x63, 0x68, - 0x69, 0x6c, 0x64, 0x3e, 0x3c, 0x63, 0x68, 0x69, - 0x6c, 0x64, 0x3e, 0x3c, 0x6f, 0x62, 0x6a, 0x65, - 0x63, 0x74, 0x20, 0x63, 0x6c, 0x61, 0x73, 0x73, - 0x3d, 0x22, 0x47, 0x74, 0x6b, 0x49, 0x6d, 0x61, - 0x67, 0x65, 0x4d, 0x65, 0x6e, 0x75, 0x49, 0x74, - 0x65, 0x6d, 0x22, 0x20, 0x69, 0x64, 0x3d, 0x22, - 0x70, 0x61, 0x67, 0x65, 0x5f, 0x64, 0x65, 0x6c, - 0x65, 0x74, 0x65, 0x5f, 0x6d, 0x65, 0x6e, 0x75, - 0x69, 0x74, 0x65, 0x6d, 0x22, 0x3e, 0x3c, 0x70, - 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, 0x20, - 0x6e, 0x61, 0x6d, 0x65, 0x3d, 0x22, 0x6c, 0x61, - 0x62, 0x65, 0x6c, 0x22, 0x3e, 0x67, 0x74, 0x6b, - 0x2d, 0x64, 0x65, 0x6c, 0x65, 0x74, 0x65, 0x3c, - 0x2f, 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, - 0x79, 0x3e, 0x3c, 0x70, 0x72, 0x6f, 0x70, 0x65, - 0x72, 0x74, 0x79, 0x20, 0x6e, 0x61, 0x6d, 0x65, - 0x3d, 0x22, 0x76, 0x69, 0x73, 0x69, 0x62, 0x6c, - 0x65, 0x22, 0x3e, 0x54, 0x72, 0x75, 0x65, 0x3c, - 0x2f, 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, - 0x79, 0x3e, 0x3c, 0x70, 0x72, 0x6f, 0x70, 0x65, - 0x72, 0x74, 0x79, 0x20, 0x6e, 0x61, 0x6d, 0x65, - 0x3d, 0x22, 0x63, 0x61, 0x6e, 0x5f, 0x66, 0x6f, - 0x63, 0x75, 0x73, 0x22, 0x3e, 0x46, 0x61, 0x6c, - 0x73, 0x65, 0x3c, 0x2f, 0x70, 0x72, 0x6f, 0x70, - 0x65, 0x72, 0x74, 0x79, 0x3e, 0x3c, 0x70, 0x72, - 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, 0x20, 0x6e, - 0x61, 0x6d, 0x65, 0x3d, 0x22, 0x75, 0x73, 0x65, - 0x5f, 0x75, 0x6e, 0x64, 0x65, 0x72, 0x6c, 0x69, - 0x6e, 0x65, 0x22, 0x3e, 0x54, 0x72, 0x75, 0x65, - 0x3c, 0x2f, 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, - 0x74, 0x79, 0x3e, 0x3c, 0x70, 0x72, 0x6f, 0x70, - 0x65, 0x72, 0x74, 0x79, 0x20, 0x6e, 0x61, 0x6d, - 0x65, 0x3d, 0x22, 0x75, 0x73, 0x65, 0x5f, 0x73, - 0x74, 0x6f, 0x63, 0x6b, 0x22, 0x3e, 0x54, 0x72, - 0x75, 0x65, 0x3c, 0x2f, 0x70, 0x72, 0x6f, 0x70, - 0x65, 0x72, 0x74, 0x79, 0x3e, 0x3c, 0x61, 0x63, - 0x63, 0x65, 0x6c, 0x65, 0x72, 0x61, 0x74, 0x6f, - 0x72, 0x20, 0x6b, 0x65, 0x79, 0x3d, 0x22, 0x44, - 0x65, 0x6c, 0x65, 0x74, 0x65, 0x22, 0x20, 0x73, - 0x69, 0x67, 0x6e, 0x61, 0x6c, 0x3d, 0x22, 0x61, - 0x63, 0x74, 0x69, 0x76, 0x61, 0x74, 0x65, 0x22, - 0x2f, 0x3e, 0x3c, 0x73, 0x69, 0x67, 0x6e, 0x61, - 0x6c, 0x20, 0x6e, 0x61, 0x6d, 0x65, 0x3d, 0x22, - 0x61, 0x63, 0x74, 0x69, 0x76, 0x61, 0x74, 0x65, - 0x22, 0x20, 0x68, 0x61, 0x6e, 0x64, 0x6c, 0x65, - 0x72, 0x3d, 0x22, 0x70, 0x61, 0x67, 0x65, 0x5f, - 0x64, 0x65, 0x6c, 0x65, 0x74, 0x65, 0x5f, 0x6d, - 0x65, 0x6e, 0x75, 0x69, 0x74, 0x65, 0x6d, 0x5f, - 0x61, 0x63, 0x74, 0x69, 0x76, 0x61, 0x74, 0x65, - 0x5f, 0x63, 0x62, 0x22, 0x20, 0x73, 0x77, 0x61, - 0x70, 0x70, 0x65, 0x64, 0x3d, 0x22, 0x6e, 0x6f, - 0x22, 0x2f, 0x3e, 0x3c, 0x2f, 0x6f, 0x62, 0x6a, - 0x65, 0x63, 0x74, 0x3e, 0x3c, 0x2f, 0x63, 0x68, - 0x69, 0x6c, 0x64, 0x3e, 0x3c, 0x2f, 0x6f, 0x62, - 0x6a, 0x65, 0x63, 0x74, 0x3e, 0x3c, 0x2f, 0x63, - 0x68, 0x69, 0x6c, 0x64, 0x3e, 0x3c, 0x2f, 0x6f, - 0x62, 0x6a, 0x65, 0x63, 0x74, 0x3e, 0x3c, 0x2f, - 0x63, 0x68, 0x69, 0x6c, 0x64, 0x3e, 0x3c, 0x63, - 0x68, 0x69, 0x6c, 0x64, 0x3e, 0x3c, 0x6f, 0x62, - 0x6a, 0x65, 0x63, 0x74, 0x20, 0x63, 0x6c, 0x61, - 0x73, 0x73, 0x3d, 0x22, 0x47, 0x74, 0x6b, 0x4d, - 0x65, 0x6e, 0x75, 0x49, 0x74, 0x65, 0x6d, 0x22, - 0x20, 0x69, 0x64, 0x3d, 0x22, 0x68, 0x65, 0x6c, - 0x70, 0x5f, 0x6d, 0x65, 0x6e, 0x75, 0x69, 0x74, - 0x65, 0x6d, 0x22, 0x3e, 0x3c, 0x70, 0x72, 0x6f, - 0x70, 0x65, 0x72, 0x74, 0x79, 0x20, 0x6e, 0x61, - 0x6d, 0x65, 0x3d, 0x22, 0x76, 0x69, 0x73, 0x69, - 0x62, 0x6c, 0x65, 0x22, 0x3e, 0x54, 0x72, 0x75, - 0x65, 0x3c, 0x2f, 0x70, 0x72, 0x6f, 0x70, 0x65, - 0x72, 0x74, 0x79, 0x3e, 0x3c, 0x70, 0x72, 0x6f, - 0x70, 0x65, 0x72, 0x74, 0x79, 0x20, 0x6e, 0x61, - 0x6d, 0x65, 0x3d, 0x22, 0x63, 0x61, 0x6e, 0x5f, - 0x66, 0x6f, 0x63, 0x75, 0x73, 0x22, 0x3e, 0x46, - 0x61, 0x6c, 0x73, 0x65, 0x3c, 0x2f, 0x70, 0x72, - 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, 0x3e, 0x3c, - 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, - 0x20, 0x6e, 0x61, 0x6d, 0x65, 0x3d, 0x22, 0x6c, - 0x61, 0x62, 0x65, 0x6c, 0x22, 0x20, 0x74, 0x72, - 0x61, 0x6e, 0x73, 0x6c, 0x61, 0x74, 0x61, 0x62, - 0x6c, 0x65, 0x3d, 0x22, 0x79, 0x65, 0x73, 0x22, - 0x20, 0x63, 0x6f, 0x6d, 0x6d, 0x65, 0x6e, 0x74, - 0x73, 0x3d, 0x22, 0x4c, 0x61, 0x62, 0x65, 0x6c, - 0x20, 0x6f, 0x6e, 0x20, 0x68, 0x65, 0x6c, 0x70, - 0x20, 0x6d, 0x65, 0x6e, 0x75, 0x22, 0x3e, 0x5f, - 0x48, 0x65, 0x6c, 0x70, 0x3c, 0x2f, 0x70, 0x72, - 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, 0x3e, 0x3c, - 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, - 0x20, 0x6e, 0x61, 0x6d, 0x65, 0x3d, 0x22, 0x75, - 0x73, 0x65, 0x5f, 0x75, 0x6e, 0x64, 0x65, 0x72, - 0x6c, 0x69, 0x6e, 0x65, 0x22, 0x3e, 0x54, 0x72, - 0x75, 0x65, 0x3c, 0x2f, 0x70, 0x72, 0x6f, 0x70, - 0x65, 0x72, 0x74, 0x79, 0x3e, 0x3c, 0x63, 0x68, - 0x69, 0x6c, 0x64, 0x20, 0x74, 0x79, 0x70, 0x65, - 0x3d, 0x22, 0x73, 0x75, 0x62, 0x6d, 0x65, 0x6e, - 0x75, 0x22, 0x3e, 0x3c, 0x6f, 0x62, 0x6a, 0x65, - 0x63, 0x74, 0x20, 0x63, 0x6c, 0x61, 0x73, 0x73, - 0x3d, 0x22, 0x47, 0x74, 0x6b, 0x4d, 0x65, 0x6e, - 0x75, 0x22, 0x20, 0x69, 0x64, 0x3d, 0x22, 0x68, - 0x65, 0x6c, 0x70, 0x5f, 0x6d, 0x65, 0x6e, 0x75, - 0x22, 0x3e, 0x3c, 0x70, 0x72, 0x6f, 0x70, 0x65, - 0x72, 0x74, 0x79, 0x20, 0x6e, 0x61, 0x6d, 0x65, - 0x3d, 0x22, 0x76, 0x69, 0x73, 0x69, 0x62, 0x6c, - 0x65, 0x22, 0x3e, 0x54, 0x72, 0x75, 0x65, 0x3c, - 0x2f, 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, - 0x79, 0x3e, 0x3c, 0x70, 0x72, 0x6f, 0x70, 0x65, - 0x72, 0x74, 0x79, 0x20, 0x6e, 0x61, 0x6d, 0x65, - 0x3d, 0x22, 0x63, 0x61, 0x6e, 0x5f, 0x66, 0x6f, - 0x63, 0x75, 0x73, 0x22, 0x3e, 0x46, 0x61, 0x6c, - 0x73, 0x65, 0x3c, 0x2f, 0x70, 0x72, 0x6f, 0x70, - 0x65, 0x72, 0x74, 0x79, 0x3e, 0x3c, 0x63, 0x68, - 0x69, 0x6c, 0x64, 0x3e, 0x3c, 0x6f, 0x62, 0x6a, - 0x65, 0x63, 0x74, 0x20, 0x63, 0x6c, 0x61, 0x73, - 0x73, 0x3d, 0x22, 0x47, 0x74, 0x6b, 0x49, 0x6d, - 0x61, 0x67, 0x65, 0x4d, 0x65, 0x6e, 0x75, 0x49, - 0x74, 0x65, 0x6d, 0x22, 0x20, 0x69, 0x64, 0x3d, - 0x22, 0x68, 0x65, 0x6c, 0x70, 0x5f, 0x63, 0x6f, - 0x6e, 0x74, 0x65, 0x6e, 0x74, 0x73, 0x5f, 0x6d, - 0x65, 0x6e, 0x75, 0x69, 0x74, 0x65, 0x6d, 0x22, - 0x3e, 0x3c, 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, - 0x74, 0x79, 0x20, 0x6e, 0x61, 0x6d, 0x65, 0x3d, - 0x22, 0x6c, 0x61, 0x62, 0x65, 0x6c, 0x22, 0x20, - 0x74, 0x72, 0x61, 0x6e, 0x73, 0x6c, 0x61, 0x74, - 0x61, 0x62, 0x6c, 0x65, 0x3d, 0x22, 0x79, 0x65, - 0x73, 0x22, 0x20, 0x63, 0x6f, 0x6d, 0x6d, 0x65, - 0x6e, 0x74, 0x73, 0x3d, 0x22, 0x48, 0x65, 0x6c, - 0x70, 0x7c, 0x43, 0x6f, 0x6e, 0x74, 0x65, 0x6e, - 0x74, 0x73, 0x20, 0x6d, 0x65, 0x6e, 0x75, 0x22, - 0x3e, 0x5f, 0x43, 0x6f, 0x6e, 0x74, 0x65, 0x6e, - 0x74, 0x73, 0x3c, 0x2f, 0x70, 0x72, 0x6f, 0x70, - 0x65, 0x72, 0x74, 0x79, 0x3e, 0x3c, 0x70, 0x72, - 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, 0x20, 0x6e, - 0x61, 0x6d, 0x65, 0x3d, 0x22, 0x76, 0x69, 0x73, - 0x69, 0x62, 0x6c, 0x65, 0x22, 0x3e, 0x54, 0x72, - 0x75, 0x65, 0x3c, 0x2f, 0x70, 0x72, 0x6f, 0x70, - 0x65, 0x72, 0x74, 0x79, 0x3e, 0x3c, 0x70, 0x72, - 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, 0x20, 0x6e, - 0x61, 0x6d, 0x65, 0x3d, 0x22, 0x63, 0x61, 0x6e, - 0x5f, 0x66, 0x6f, 0x63, 0x75, 0x73, 0x22, 0x3e, - 0x46, 0x61, 0x6c, 0x73, 0x65, 0x3c, 0x2f, 0x70, - 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, 0x3e, - 0x3c, 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, - 0x79, 0x20, 0x6e, 0x61, 0x6d, 0x65, 0x3d, 0x22, - 0x75, 0x73, 0x65, 0x5f, 0x75, 0x6e, 0x64, 0x65, - 0x72, 0x6c, 0x69, 0x6e, 0x65, 0x22, 0x3e, 0x54, - 0x72, 0x75, 0x65, 0x3c, 0x2f, 0x70, 0x72, 0x6f, - 0x70, 0x65, 0x72, 0x74, 0x79, 0x3e, 0x3c, 0x70, - 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, 0x20, - 0x6e, 0x61, 0x6d, 0x65, 0x3d, 0x22, 0x69, 0x6d, - 0x61, 0x67, 0x65, 0x22, 0x3e, 0x68, 0x65, 0x6c, - 0x70, 0x5f, 0x69, 0x6d, 0x61, 0x67, 0x65, 0x3c, - 0x2f, 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, - 0x79, 0x3e, 0x3c, 0x70, 0x72, 0x6f, 0x70, 0x65, - 0x72, 0x74, 0x79, 0x20, 0x6e, 0x61, 0x6d, 0x65, - 0x3d, 0x22, 0x75, 0x73, 0x65, 0x5f, 0x73, 0x74, - 0x6f, 0x63, 0x6b, 0x22, 0x3e, 0x46, 0x61, 0x6c, - 0x73, 0x65, 0x3c, 0x2f, 0x70, 0x72, 0x6f, 0x70, - 0x65, 0x72, 0x74, 0x79, 0x3e, 0x3c, 0x61, 0x63, - 0x63, 0x65, 0x6c, 0x65, 0x72, 0x61, 0x74, 0x6f, - 0x72, 0x20, 0x6b, 0x65, 0x79, 0x3d, 0x22, 0x46, - 0x31, 0x22, 0x20, 0x73, 0x69, 0x67, 0x6e, 0x61, - 0x6c, 0x3d, 0x22, 0x61, 0x63, 0x74, 0x69, 0x76, - 0x61, 0x74, 0x65, 0x22, 0x2f, 0x3e, 0x3c, 0x73, - 0x69, 0x67, 0x6e, 0x61, 0x6c, 0x20, 0x6e, 0x61, - 0x6d, 0x65, 0x3d, 0x22, 0x61, 0x63, 0x74, 0x69, - 0x76, 0x61, 0x74, 0x65, 0x22, 0x20, 0x68, 0x61, - 0x6e, 0x64, 0x6c, 0x65, 0x72, 0x3d, 0x22, 0x68, - 0x65, 0x6c, 0x70, 0x5f, 0x63, 0x6f, 0x6e, 0x74, - 0x65, 0x6e, 0x74, 0x73, 0x5f, 0x6d, 0x65, 0x6e, - 0x75, 0x69, 0x74, 0x65, 0x6d, 0x5f, 0x61, 0x63, - 0x74, 0x69, 0x76, 0x61, 0x74, 0x65, 0x5f, 0x63, - 0x62, 0x22, 0x20, 0x73, 0x77, 0x61, 0x70, 0x70, - 0x65, 0x64, 0x3d, 0x22, 0x6e, 0x6f, 0x22, 0x2f, - 0x3e, 0x3c, 0x2f, 0x6f, 0x62, 0x6a, 0x65, 0x63, - 0x74, 0x3e, 0x3c, 0x2f, 0x63, 0x68, 0x69, 0x6c, - 0x64, 0x3e, 0x3c, 0x63, 0x68, 0x69, 0x6c, 0x64, - 0x3e, 0x3c, 0x6f, 0x62, 0x6a, 0x65, 0x63, 0x74, - 0x20, 0x63, 0x6c, 0x61, 0x73, 0x73, 0x3d, 0x22, - 0x47, 0x74, 0x6b, 0x49, 0x6d, 0x61, 0x67, 0x65, - 0x4d, 0x65, 0x6e, 0x75, 0x49, 0x74, 0x65, 0x6d, - 0x22, 0x20, 0x69, 0x64, 0x3d, 0x22, 0x61, 0x62, - 0x6f, 0x75, 0x74, 0x5f, 0x6d, 0x65, 0x6e, 0x75, - 0x69, 0x74, 0x65, 0x6d, 0x22, 0x3e, 0x3c, 0x70, - 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, 0x20, - 0x6e, 0x61, 0x6d, 0x65, 0x3d, 0x22, 0x6c, 0x61, - 0x62, 0x65, 0x6c, 0x22, 0x3e, 0x67, 0x74, 0x6b, - 0x2d, 0x61, 0x62, 0x6f, 0x75, 0x74, 0x3c, 0x2f, - 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, - 0x3e, 0x3c, 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, - 0x74, 0x79, 0x20, 0x6e, 0x61, 0x6d, 0x65, 0x3d, - 0x22, 0x76, 0x69, 0x73, 0x69, 0x62, 0x6c, 0x65, - 0x22, 0x3e, 0x54, 0x72, 0x75, 0x65, 0x3c, 0x2f, - 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, - 0x3e, 0x3c, 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, - 0x74, 0x79, 0x20, 0x6e, 0x61, 0x6d, 0x65, 0x3d, - 0x22, 0x63, 0x61, 0x6e, 0x5f, 0x66, 0x6f, 0x63, - 0x75, 0x73, 0x22, 0x3e, 0x46, 0x61, 0x6c, 0x73, - 0x65, 0x3c, 0x2f, 0x70, 0x72, 0x6f, 0x70, 0x65, - 0x72, 0x74, 0x79, 0x3e, 0x3c, 0x70, 0x72, 0x6f, - 0x70, 0x65, 0x72, 0x74, 0x79, 0x20, 0x6e, 0x61, - 0x6d, 0x65, 0x3d, 0x22, 0x75, 0x73, 0x65, 0x5f, - 0x75, 0x6e, 0x64, 0x65, 0x72, 0x6c, 0x69, 0x6e, - 0x65, 0x22, 0x3e, 0x54, 0x72, 0x75, 0x65, 0x3c, - 0x2f, 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, - 0x79, 0x3e, 0x3c, 0x70, 0x72, 0x6f, 0x70, 0x65, - 0x72, 0x74, 0x79, 0x20, 0x6e, 0x61, 0x6d, 0x65, - 0x3d, 0x22, 0x75, 0x73, 0x65, 0x5f, 0x73, 0x74, - 0x6f, 0x63, 0x6b, 0x22, 0x3e, 0x54, 0x72, 0x75, - 0x65, 0x3c, 0x2f, 0x70, 0x72, 0x6f, 0x70, 0x65, - 0x72, 0x74, 0x79, 0x3e, 0x3c, 0x73, 0x69, 0x67, - 0x6e, 0x61, 0x6c, 0x20, 0x6e, 0x61, 0x6d, 0x65, - 0x3d, 0x22, 0x61, 0x63, 0x74, 0x69, 0x76, 0x61, - 0x74, 0x65, 0x22, 0x20, 0x68, 0x61, 0x6e, 0x64, - 0x6c, 0x65, 0x72, 0x3d, 0x22, 0x61, 0x62, 0x6f, - 0x75, 0x74, 0x5f, 0x6d, 0x65, 0x6e, 0x75, 0x69, - 0x74, 0x65, 0x6d, 0x5f, 0x61, 0x63, 0x74, 0x69, - 0x76, 0x61, 0x74, 0x65, 0x5f, 0x63, 0x62, 0x22, - 0x20, 0x73, 0x77, 0x61, 0x70, 0x70, 0x65, 0x64, - 0x3d, 0x22, 0x6e, 0x6f, 0x22, 0x2f, 0x3e, 0x3c, - 0x2f, 0x6f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x3e, - 0x3c, 0x2f, 0x63, 0x68, 0x69, 0x6c, 0x64, 0x3e, - 0x3c, 0x2f, 0x6f, 0x62, 0x6a, 0x65, 0x63, 0x74, - 0x3e, 0x3c, 0x2f, 0x63, 0x68, 0x69, 0x6c, 0x64, - 0x3e, 0x3c, 0x2f, 0x6f, 0x62, 0x6a, 0x65, 0x63, - 0x74, 0x3e, 0x3c, 0x2f, 0x63, 0x68, 0x69, 0x6c, - 0x64, 0x3e, 0x3c, 0x2f, 0x6f, 0x62, 0x6a, 0x65, - 0x63, 0x74, 0x3e, 0x3c, 0x70, 0x61, 0x63, 0x6b, - 0x69, 0x6e, 0x67, 0x3e, 0x3c, 0x70, 0x72, 0x6f, - 0x70, 0x65, 0x72, 0x74, 0x79, 0x20, 0x6e, 0x61, - 0x6d, 0x65, 0x3d, 0x22, 0x65, 0x78, 0x70, 0x61, - 0x6e, 0x64, 0x22, 0x3e, 0x46, 0x61, 0x6c, 0x73, - 0x65, 0x3c, 0x2f, 0x70, 0x72, 0x6f, 0x70, 0x65, - 0x72, 0x74, 0x79, 0x3e, 0x3c, 0x70, 0x72, 0x6f, - 0x70, 0x65, 0x72, 0x74, 0x79, 0x20, 0x6e, 0x61, - 0x6d, 0x65, 0x3d, 0x22, 0x66, 0x69, 0x6c, 0x6c, - 0x22, 0x3e, 0x54, 0x72, 0x75, 0x65, 0x3c, 0x2f, - 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, - 0x3e, 0x3c, 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, - 0x74, 0x79, 0x20, 0x6e, 0x61, 0x6d, 0x65, 0x3d, - 0x22, 0x70, 0x6f, 0x73, 0x69, 0x74, 0x69, 0x6f, - 0x6e, 0x22, 0x3e, 0x30, 0x3c, 0x2f, 0x70, 0x72, - 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, 0x3e, 0x3c, - 0x2f, 0x70, 0x61, 0x63, 0x6b, 0x69, 0x6e, 0x67, - 0x3e, 0x3c, 0x2f, 0x63, 0x68, 0x69, 0x6c, 0x64, - 0x3e, 0x3c, 0x63, 0x68, 0x69, 0x6c, 0x64, 0x3e, - 0x3c, 0x6f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x20, - 0x63, 0x6c, 0x61, 0x73, 0x73, 0x3d, 0x22, 0x47, - 0x74, 0x6b, 0x54, 0x6f, 0x6f, 0x6c, 0x62, 0x61, - 0x72, 0x22, 0x20, 0x69, 0x64, 0x3d, 0x22, 0x74, - 0x6f, 0x6f, 0x6c, 0x62, 0x61, 0x72, 0x22, 0x3e, - 0x3c, 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, - 0x79, 0x20, 0x6e, 0x61, 0x6d, 0x65, 0x3d, 0x22, - 0x76, 0x69, 0x73, 0x69, 0x62, 0x6c, 0x65, 0x22, - 0x3e, 0x46, 0x61, 0x6c, 0x73, 0x65, 0x3c, 0x2f, - 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, - 0x3e, 0x3c, 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, - 0x74, 0x79, 0x20, 0x6e, 0x61, 0x6d, 0x65, 0x3d, - 0x22, 0x63, 0x61, 0x6e, 0x5f, 0x66, 0x6f, 0x63, - 0x75, 0x73, 0x22, 0x3e, 0x46, 0x61, 0x6c, 0x73, - 0x65, 0x3c, 0x2f, 0x70, 0x72, 0x6f, 0x70, 0x65, - 0x72, 0x74, 0x79, 0x3e, 0x3c, 0x73, 0x74, 0x79, - 0x6c, 0x65, 0x3e, 0x3c, 0x63, 0x6c, 0x61, 0x73, - 0x73, 0x20, 0x6e, 0x61, 0x6d, 0x65, 0x3d, 0x22, - 0x70, 0x72, 0x69, 0x6d, 0x61, 0x72, 0x79, 0x2d, - 0x74, 0x6f, 0x6f, 0x6c, 0x62, 0x61, 0x72, 0x22, - 0x2f, 0x3e, 0x3c, 0x2f, 0x73, 0x74, 0x79, 0x6c, - 0x65, 0x3e, 0x3c, 0x63, 0x68, 0x69, 0x6c, 0x64, - 0x3e, 0x3c, 0x6f, 0x62, 0x6a, 0x65, 0x63, 0x74, - 0x20, 0x63, 0x6c, 0x61, 0x73, 0x73, 0x3d, 0x22, - 0x47, 0x74, 0x6b, 0x54, 0x6f, 0x6f, 0x6c, 0x42, - 0x75, 0x74, 0x74, 0x6f, 0x6e, 0x22, 0x20, 0x69, - 0x64, 0x3d, 0x22, 0x6e, 0x65, 0x77, 0x5f, 0x74, - 0x6f, 0x6f, 0x6c, 0x62, 0x75, 0x74, 0x74, 0x6f, - 0x6e, 0x22, 0x3e, 0x3c, 0x70, 0x72, 0x6f, 0x70, - 0x65, 0x72, 0x74, 0x79, 0x20, 0x6e, 0x61, 0x6d, - 0x65, 0x3d, 0x22, 0x76, 0x69, 0x73, 0x69, 0x62, - 0x6c, 0x65, 0x22, 0x3e, 0x54, 0x72, 0x75, 0x65, - 0x3c, 0x2f, 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, - 0x74, 0x79, 0x3e, 0x3c, 0x70, 0x72, 0x6f, 0x70, - 0x65, 0x72, 0x74, 0x79, 0x20, 0x6e, 0x61, 0x6d, - 0x65, 0x3d, 0x22, 0x63, 0x61, 0x6e, 0x5f, 0x66, - 0x6f, 0x63, 0x75, 0x73, 0x22, 0x3e, 0x46, 0x61, - 0x6c, 0x73, 0x65, 0x3c, 0x2f, 0x70, 0x72, 0x6f, - 0x70, 0x65, 0x72, 0x74, 0x79, 0x3e, 0x3c, 0x70, - 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, 0x20, - 0x6e, 0x61, 0x6d, 0x65, 0x3d, 0x22, 0x74, 0x6f, - 0x6f, 0x6c, 0x74, 0x69, 0x70, 0x5f, 0x74, 0x65, - 0x78, 0x74, 0x22, 0x20, 0x74, 0x72, 0x61, 0x6e, - 0x73, 0x6c, 0x61, 0x74, 0x61, 0x62, 0x6c, 0x65, - 0x3d, 0x22, 0x79, 0x65, 0x73, 0x22, 0x20, 0x63, - 0x6f, 0x6d, 0x6d, 0x65, 0x6e, 0x74, 0x73, 0x3d, - 0x22, 0x54, 0x6f, 0x6f, 0x6c, 0x74, 0x69, 0x70, - 0x20, 0x66, 0x6f, 0x72, 0x20, 0x6e, 0x65, 0x77, - 0x20, 0x64, 0x6f, 0x63, 0x75, 0x6d, 0x65, 0x6e, - 0x74, 0x20, 0x62, 0x75, 0x74, 0x74, 0x6f, 0x6e, - 0x22, 0x3e, 0x53, 0x74, 0x61, 0x72, 0x74, 0x20, - 0x61, 0x20, 0x6e, 0x65, 0x77, 0x20, 0x64, 0x6f, - 0x63, 0x75, 0x6d, 0x65, 0x6e, 0x74, 0x3c, 0x2f, - 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, - 0x3e, 0x3c, 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, - 0x74, 0x79, 0x20, 0x6e, 0x61, 0x6d, 0x65, 0x3d, - 0x22, 0x6c, 0x61, 0x62, 0x65, 0x6c, 0x22, 0x20, - 0x74, 0x72, 0x61, 0x6e, 0x73, 0x6c, 0x61, 0x74, - 0x61, 0x62, 0x6c, 0x65, 0x3d, 0x22, 0x79, 0x65, - 0x73, 0x22, 0x3e, 0x4e, 0x65, 0x77, 0x3c, 0x2f, - 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, - 0x3e, 0x3c, 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, - 0x74, 0x79, 0x20, 0x6e, 0x61, 0x6d, 0x65, 0x3d, - 0x22, 0x75, 0x73, 0x65, 0x5f, 0x75, 0x6e, 0x64, - 0x65, 0x72, 0x6c, 0x69, 0x6e, 0x65, 0x22, 0x3e, - 0x54, 0x72, 0x75, 0x65, 0x3c, 0x2f, 0x70, 0x72, - 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, 0x3e, 0x3c, - 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, - 0x20, 0x6e, 0x61, 0x6d, 0x65, 0x3d, 0x22, 0x73, - 0x74, 0x6f, 0x63, 0x6b, 0x5f, 0x69, 0x64, 0x22, - 0x3e, 0x67, 0x74, 0x6b, 0x2d, 0x6e, 0x65, 0x77, - 0x3c, 0x2f, 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, - 0x74, 0x79, 0x3e, 0x3c, 0x73, 0x69, 0x67, 0x6e, - 0x61, 0x6c, 0x20, 0x6e, 0x61, 0x6d, 0x65, 0x3d, - 0x22, 0x63, 0x6c, 0x69, 0x63, 0x6b, 0x65, 0x64, - 0x22, 0x20, 0x68, 0x61, 0x6e, 0x64, 0x6c, 0x65, - 0x72, 0x3d, 0x22, 0x6e, 0x65, 0x77, 0x5f, 0x62, - 0x75, 0x74, 0x74, 0x6f, 0x6e, 0x5f, 0x63, 0x6c, - 0x69, 0x63, 0x6b, 0x65, 0x64, 0x5f, 0x63, 0x62, - 0x22, 0x20, 0x73, 0x77, 0x61, 0x70, 0x70, 0x65, - 0x64, 0x3d, 0x22, 0x6e, 0x6f, 0x22, 0x2f, 0x3e, - 0x3c, 0x2f, 0x6f, 0x62, 0x6a, 0x65, 0x63, 0x74, - 0x3e, 0x3c, 0x70, 0x61, 0x63, 0x6b, 0x69, 0x6e, - 0x67, 0x3e, 0x3c, 0x70, 0x72, 0x6f, 0x70, 0x65, - 0x72, 0x74, 0x79, 0x20, 0x6e, 0x61, 0x6d, 0x65, - 0x3d, 0x22, 0x65, 0x78, 0x70, 0x61, 0x6e, 0x64, - 0x22, 0x3e, 0x46, 0x61, 0x6c, 0x73, 0x65, 0x3c, - 0x2f, 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, - 0x79, 0x3e, 0x3c, 0x70, 0x72, 0x6f, 0x70, 0x65, - 0x72, 0x74, 0x79, 0x20, 0x6e, 0x61, 0x6d, 0x65, - 0x3d, 0x22, 0x68, 0x6f, 0x6d, 0x6f, 0x67, 0x65, - 0x6e, 0x65, 0x6f, 0x75, 0x73, 0x22, 0x3e, 0x54, - 0x72, 0x75, 0x65, 0x3c, 0x2f, 0x70, 0x72, 0x6f, - 0x70, 0x65, 0x72, 0x74, 0x79, 0x3e, 0x3c, 0x2f, - 0x70, 0x61, 0x63, 0x6b, 0x69, 0x6e, 0x67, 0x3e, - 0x3c, 0x2f, 0x63, 0x68, 0x69, 0x6c, 0x64, 0x3e, - 0x3c, 0x63, 0x68, 0x69, 0x6c, 0x64, 0x3e, 0x3c, - 0x6f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x20, 0x63, - 0x6c, 0x61, 0x73, 0x73, 0x3d, 0x22, 0x47, 0x74, - 0x6b, 0x4d, 0x65, 0x6e, 0x75, 0x54, 0x6f, 0x6f, - 0x6c, 0x42, 0x75, 0x74, 0x74, 0x6f, 0x6e, 0x22, - 0x20, 0x69, 0x64, 0x3d, 0x22, 0x73, 0x63, 0x61, - 0x6e, 0x5f, 0x74, 0x6f, 0x6f, 0x6c, 0x62, 0x75, - 0x74, 0x74, 0x6f, 0x6e, 0x22, 0x3e, 0x3c, 0x70, - 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, 0x20, - 0x6e, 0x61, 0x6d, 0x65, 0x3d, 0x22, 0x76, 0x69, - 0x73, 0x69, 0x62, 0x6c, 0x65, 0x22, 0x3e, 0x54, - 0x72, 0x75, 0x65, 0x3c, 0x2f, 0x70, 0x72, 0x6f, - 0x70, 0x65, 0x72, 0x74, 0x79, 0x3e, 0x3c, 0x70, - 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, 0x20, - 0x6e, 0x61, 0x6d, 0x65, 0x3d, 0x22, 0x63, 0x61, - 0x6e, 0x5f, 0x66, 0x6f, 0x63, 0x75, 0x73, 0x22, - 0x3e, 0x46, 0x61, 0x6c, 0x73, 0x65, 0x3c, 0x2f, - 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, - 0x3e, 0x3c, 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, - 0x74, 0x79, 0x20, 0x6e, 0x61, 0x6d, 0x65, 0x3d, - 0x22, 0x74, 0x6f, 0x6f, 0x6c, 0x74, 0x69, 0x70, - 0x5f, 0x74, 0x65, 0x78, 0x74, 0x22, 0x20, 0x74, - 0x72, 0x61, 0x6e, 0x73, 0x6c, 0x61, 0x74, 0x61, - 0x62, 0x6c, 0x65, 0x3d, 0x22, 0x79, 0x65, 0x73, - 0x22, 0x20, 0x63, 0x6f, 0x6d, 0x6d, 0x65, 0x6e, - 0x74, 0x73, 0x3d, 0x22, 0x54, 0x6f, 0x6f, 0x6c, - 0x74, 0x69, 0x70, 0x20, 0x66, 0x6f, 0x72, 0x20, - 0x73, 0x63, 0x61, 0x6e, 0x20, 0x74, 0x6f, 0x6f, - 0x6c, 0x62, 0x61, 0x72, 0x20, 0x62, 0x75, 0x74, - 0x74, 0x6f, 0x6e, 0x22, 0x3e, 0x53, 0x63, 0x61, - 0x6e, 0x20, 0x61, 0x20, 0x73, 0x69, 0x6e, 0x67, - 0x6c, 0x65, 0x20, 0x70, 0x61, 0x67, 0x65, 0x20, - 0x66, 0x72, 0x6f, 0x6d, 0x20, 0x74, 0x68, 0x65, - 0x20, 0x73, 0x63, 0x61, 0x6e, 0x6e, 0x65, 0x72, - 0x3c, 0x2f, 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, - 0x74, 0x79, 0x3e, 0x3c, 0x70, 0x72, 0x6f, 0x70, - 0x65, 0x72, 0x74, 0x79, 0x20, 0x6e, 0x61, 0x6d, - 0x65, 0x3d, 0x22, 0x69, 0x73, 0x5f, 0x69, 0x6d, - 0x70, 0x6f, 0x72, 0x74, 0x61, 0x6e, 0x74, 0x22, - 0x3e, 0x54, 0x72, 0x75, 0x65, 0x3c, 0x2f, 0x70, - 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, 0x3e, - 0x3c, 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, - 0x79, 0x20, 0x6e, 0x61, 0x6d, 0x65, 0x3d, 0x22, - 0x6c, 0x61, 0x62, 0x65, 0x6c, 0x22, 0x20, 0x74, - 0x72, 0x61, 0x6e, 0x73, 0x6c, 0x61, 0x74, 0x61, - 0x62, 0x6c, 0x65, 0x3d, 0x22, 0x79, 0x65, 0x73, - 0x22, 0x20, 0x63, 0x6f, 0x6d, 0x6d, 0x65, 0x6e, - 0x74, 0x73, 0x3d, 0x22, 0x4c, 0x61, 0x62, 0x65, - 0x6c, 0x20, 0x6f, 0x6e, 0x20, 0x73, 0x63, 0x61, - 0x6e, 0x20, 0x74, 0x6f, 0x6f, 0x6c, 0x62, 0x61, - 0x72, 0x20, 0x69, 0x74, 0x65, 0x6d, 0x22, 0x3e, - 0x53, 0x63, 0x61, 0x6e, 0x3c, 0x2f, 0x70, 0x72, - 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, 0x3e, 0x3c, - 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, - 0x20, 0x6e, 0x61, 0x6d, 0x65, 0x3d, 0x22, 0x75, - 0x73, 0x65, 0x5f, 0x75, 0x6e, 0x64, 0x65, 0x72, - 0x6c, 0x69, 0x6e, 0x65, 0x22, 0x3e, 0x54, 0x72, - 0x75, 0x65, 0x3c, 0x2f, 0x70, 0x72, 0x6f, 0x70, - 0x65, 0x72, 0x74, 0x79, 0x3e, 0x3c, 0x70, 0x72, - 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, 0x20, 0x6e, - 0x61, 0x6d, 0x65, 0x3d, 0x22, 0x69, 0x63, 0x6f, - 0x6e, 0x5f, 0x6e, 0x61, 0x6d, 0x65, 0x22, 0x3e, - 0x73, 0x63, 0x61, 0x6e, 0x6e, 0x65, 0x72, 0x3c, - 0x2f, 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, - 0x79, 0x3e, 0x3c, 0x70, 0x72, 0x6f, 0x70, 0x65, - 0x72, 0x74, 0x79, 0x20, 0x6e, 0x61, 0x6d, 0x65, - 0x3d, 0x22, 0x6d, 0x65, 0x6e, 0x75, 0x22, 0x3e, - 0x73, 0x63, 0x61, 0x6e, 0x5f, 0x62, 0x75, 0x74, - 0x74, 0x6f, 0x6e, 0x5f, 0x6d, 0x65, 0x6e, 0x75, - 0x3c, 0x2f, 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, - 0x74, 0x79, 0x3e, 0x3c, 0x73, 0x69, 0x67, 0x6e, - 0x61, 0x6c, 0x20, 0x6e, 0x61, 0x6d, 0x65, 0x3d, - 0x22, 0x63, 0x6c, 0x69, 0x63, 0x6b, 0x65, 0x64, - 0x22, 0x20, 0x68, 0x61, 0x6e, 0x64, 0x6c, 0x65, - 0x72, 0x3d, 0x22, 0x73, 0x63, 0x61, 0x6e, 0x5f, - 0x62, 0x75, 0x74, 0x74, 0x6f, 0x6e, 0x5f, 0x63, - 0x6c, 0x69, 0x63, 0x6b, 0x65, 0x64, 0x5f, 0x63, - 0x62, 0x22, 0x20, 0x73, 0x77, 0x61, 0x70, 0x70, - 0x65, 0x64, 0x3d, 0x22, 0x6e, 0x6f, 0x22, 0x2f, - 0x3e, 0x3c, 0x2f, 0x6f, 0x62, 0x6a, 0x65, 0x63, - 0x74, 0x3e, 0x3c, 0x70, 0x61, 0x63, 0x6b, 0x69, - 0x6e, 0x67, 0x3e, 0x3c, 0x70, 0x72, 0x6f, 0x70, - 0x65, 0x72, 0x74, 0x79, 0x20, 0x6e, 0x61, 0x6d, - 0x65, 0x3d, 0x22, 0x65, 0x78, 0x70, 0x61, 0x6e, - 0x64, 0x22, 0x3e, 0x46, 0x61, 0x6c, 0x73, 0x65, - 0x3c, 0x2f, 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, - 0x74, 0x79, 0x3e, 0x3c, 0x70, 0x72, 0x6f, 0x70, - 0x65, 0x72, 0x74, 0x79, 0x20, 0x6e, 0x61, 0x6d, - 0x65, 0x3d, 0x22, 0x68, 0x6f, 0x6d, 0x6f, 0x67, - 0x65, 0x6e, 0x65, 0x6f, 0x75, 0x73, 0x22, 0x3e, - 0x46, 0x61, 0x6c, 0x73, 0x65, 0x3c, 0x2f, 0x70, - 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, 0x3e, - 0x3c, 0x2f, 0x70, 0x61, 0x63, 0x6b, 0x69, 0x6e, - 0x67, 0x3e, 0x3c, 0x2f, 0x63, 0x68, 0x69, 0x6c, - 0x64, 0x3e, 0x3c, 0x63, 0x68, 0x69, 0x6c, 0x64, - 0x3e, 0x3c, 0x6f, 0x62, 0x6a, 0x65, 0x63, 0x74, - 0x20, 0x63, 0x6c, 0x61, 0x73, 0x73, 0x3d, 0x22, - 0x47, 0x74, 0x6b, 0x54, 0x6f, 0x6f, 0x6c, 0x42, - 0x75, 0x74, 0x74, 0x6f, 0x6e, 0x22, 0x20, 0x69, - 0x64, 0x3d, 0x22, 0x73, 0x61, 0x76, 0x65, 0x5f, - 0x74, 0x6f, 0x6f, 0x6c, 0x62, 0x75, 0x74, 0x74, - 0x6f, 0x6e, 0x22, 0x3e, 0x3c, 0x70, 0x72, 0x6f, - 0x70, 0x65, 0x72, 0x74, 0x79, 0x20, 0x6e, 0x61, - 0x6d, 0x65, 0x3d, 0x22, 0x76, 0x69, 0x73, 0x69, - 0x62, 0x6c, 0x65, 0x22, 0x3e, 0x54, 0x72, 0x75, - 0x65, 0x3c, 0x2f, 0x70, 0x72, 0x6f, 0x70, 0x65, - 0x72, 0x74, 0x79, 0x3e, 0x3c, 0x70, 0x72, 0x6f, - 0x70, 0x65, 0x72, 0x74, 0x79, 0x20, 0x6e, 0x61, - 0x6d, 0x65, 0x3d, 0x22, 0x73, 0x65, 0x6e, 0x73, - 0x69, 0x74, 0x69, 0x76, 0x65, 0x22, 0x3e, 0x46, - 0x61, 0x6c, 0x73, 0x65, 0x3c, 0x2f, 0x70, 0x72, - 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, 0x3e, 0x3c, - 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, - 0x20, 0x6e, 0x61, 0x6d, 0x65, 0x3d, 0x22, 0x63, - 0x61, 0x6e, 0x5f, 0x66, 0x6f, 0x63, 0x75, 0x73, - 0x22, 0x3e, 0x46, 0x61, 0x6c, 0x73, 0x65, 0x3c, - 0x2f, 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, - 0x79, 0x3e, 0x3c, 0x70, 0x72, 0x6f, 0x70, 0x65, - 0x72, 0x74, 0x79, 0x20, 0x6e, 0x61, 0x6d, 0x65, - 0x3d, 0x22, 0x74, 0x6f, 0x6f, 0x6c, 0x74, 0x69, - 0x70, 0x5f, 0x74, 0x65, 0x78, 0x74, 0x22, 0x20, - 0x74, 0x72, 0x61, 0x6e, 0x73, 0x6c, 0x61, 0x74, - 0x61, 0x62, 0x6c, 0x65, 0x3d, 0x22, 0x79, 0x65, - 0x73, 0x22, 0x20, 0x63, 0x6f, 0x6d, 0x6d, 0x65, - 0x6e, 0x74, 0x73, 0x3d, 0x22, 0x54, 0x6f, 0x6f, - 0x6c, 0x74, 0x69, 0x70, 0x20, 0x66, 0x6f, 0x72, - 0x20, 0x73, 0x61, 0x76, 0x65, 0x20, 0x74, 0x6f, - 0x6f, 0x6c, 0x62, 0x61, 0x72, 0x20, 0x62, 0x75, - 0x74, 0x74, 0x6f, 0x6e, 0x22, 0x3e, 0x53, 0x61, - 0x76, 0x65, 0x20, 0x64, 0x6f, 0x63, 0x75, 0x6d, - 0x65, 0x6e, 0x74, 0x20, 0x74, 0x6f, 0x20, 0x61, - 0x20, 0x66, 0x69, 0x6c, 0x65, 0x3c, 0x2f, 0x70, - 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, 0x3e, - 0x3c, 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, - 0x79, 0x20, 0x6e, 0x61, 0x6d, 0x65, 0x3d, 0x22, - 0x69, 0x73, 0x5f, 0x69, 0x6d, 0x70, 0x6f, 0x72, - 0x74, 0x61, 0x6e, 0x74, 0x22, 0x3e, 0x54, 0x72, - 0x75, 0x65, 0x3c, 0x2f, 0x70, 0x72, 0x6f, 0x70, - 0x65, 0x72, 0x74, 0x79, 0x3e, 0x3c, 0x70, 0x72, - 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, 0x20, 0x6e, - 0x61, 0x6d, 0x65, 0x3d, 0x22, 0x6c, 0x61, 0x62, - 0x65, 0x6c, 0x22, 0x20, 0x74, 0x72, 0x61, 0x6e, - 0x73, 0x6c, 0x61, 0x74, 0x61, 0x62, 0x6c, 0x65, - 0x3d, 0x22, 0x79, 0x65, 0x73, 0x22, 0x3e, 0x53, - 0x61, 0x76, 0x65, 0x3c, 0x2f, 0x70, 0x72, 0x6f, - 0x70, 0x65, 0x72, 0x74, 0x79, 0x3e, 0x3c, 0x70, - 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, 0x20, - 0x6e, 0x61, 0x6d, 0x65, 0x3d, 0x22, 0x75, 0x73, - 0x65, 0x5f, 0x75, 0x6e, 0x64, 0x65, 0x72, 0x6c, - 0x69, 0x6e, 0x65, 0x22, 0x3e, 0x54, 0x72, 0x75, - 0x65, 0x3c, 0x2f, 0x70, 0x72, 0x6f, 0x70, 0x65, - 0x72, 0x74, 0x79, 0x3e, 0x3c, 0x70, 0x72, 0x6f, - 0x70, 0x65, 0x72, 0x74, 0x79, 0x20, 0x6e, 0x61, - 0x6d, 0x65, 0x3d, 0x22, 0x73, 0x74, 0x6f, 0x63, - 0x6b, 0x5f, 0x69, 0x64, 0x22, 0x3e, 0x67, 0x74, - 0x6b, 0x2d, 0x73, 0x61, 0x76, 0x65, 0x3c, 0x2f, - 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, - 0x3e, 0x3c, 0x73, 0x69, 0x67, 0x6e, 0x61, 0x6c, - 0x20, 0x6e, 0x61, 0x6d, 0x65, 0x3d, 0x22, 0x63, - 0x6c, 0x69, 0x63, 0x6b, 0x65, 0x64, 0x22, 0x20, - 0x68, 0x61, 0x6e, 0x64, 0x6c, 0x65, 0x72, 0x3d, - 0x22, 0x73, 0x61, 0x76, 0x65, 0x5f, 0x66, 0x69, - 0x6c, 0x65, 0x5f, 0x62, 0x75, 0x74, 0x74, 0x6f, - 0x6e, 0x5f, 0x63, 0x6c, 0x69, 0x63, 0x6b, 0x65, - 0x64, 0x5f, 0x63, 0x62, 0x22, 0x20, 0x73, 0x77, - 0x61, 0x70, 0x70, 0x65, 0x64, 0x3d, 0x22, 0x6e, - 0x6f, 0x22, 0x2f, 0x3e, 0x3c, 0x2f, 0x6f, 0x62, - 0x6a, 0x65, 0x63, 0x74, 0x3e, 0x3c, 0x70, 0x61, - 0x63, 0x6b, 0x69, 0x6e, 0x67, 0x3e, 0x3c, 0x70, - 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, 0x20, - 0x6e, 0x61, 0x6d, 0x65, 0x3d, 0x22, 0x65, 0x78, - 0x70, 0x61, 0x6e, 0x64, 0x22, 0x3e, 0x46, 0x61, - 0x6c, 0x73, 0x65, 0x3c, 0x2f, 0x70, 0x72, 0x6f, - 0x70, 0x65, 0x72, 0x74, 0x79, 0x3e, 0x3c, 0x70, - 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, 0x20, - 0x6e, 0x61, 0x6d, 0x65, 0x3d, 0x22, 0x68, 0x6f, - 0x6d, 0x6f, 0x67, 0x65, 0x6e, 0x65, 0x6f, 0x75, - 0x73, 0x22, 0x3e, 0x54, 0x72, 0x75, 0x65, 0x3c, - 0x2f, 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, - 0x79, 0x3e, 0x3c, 0x2f, 0x70, 0x61, 0x63, 0x6b, - 0x69, 0x6e, 0x67, 0x3e, 0x3c, 0x2f, 0x63, 0x68, - 0x69, 0x6c, 0x64, 0x3e, 0x3c, 0x63, 0x68, 0x69, - 0x6c, 0x64, 0x3e, 0x3c, 0x6f, 0x62, 0x6a, 0x65, - 0x63, 0x74, 0x20, 0x63, 0x6c, 0x61, 0x73, 0x73, - 0x3d, 0x22, 0x47, 0x74, 0x6b, 0x54, 0x6f, 0x6f, - 0x6c, 0x42, 0x75, 0x74, 0x74, 0x6f, 0x6e, 0x22, - 0x20, 0x69, 0x64, 0x3d, 0x22, 0x73, 0x74, 0x6f, - 0x70, 0x5f, 0x74, 0x6f, 0x6f, 0x6c, 0x62, 0x75, - 0x74, 0x74, 0x6f, 0x6e, 0x22, 0x3e, 0x3c, 0x70, - 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, 0x20, - 0x6e, 0x61, 0x6d, 0x65, 0x3d, 0x22, 0x76, 0x69, - 0x73, 0x69, 0x62, 0x6c, 0x65, 0x22, 0x3e, 0x54, - 0x72, 0x75, 0x65, 0x3c, 0x2f, 0x70, 0x72, 0x6f, - 0x70, 0x65, 0x72, 0x74, 0x79, 0x3e, 0x3c, 0x70, - 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, 0x20, - 0x6e, 0x61, 0x6d, 0x65, 0x3d, 0x22, 0x73, 0x65, - 0x6e, 0x73, 0x69, 0x74, 0x69, 0x76, 0x65, 0x22, - 0x3e, 0x46, 0x61, 0x6c, 0x73, 0x65, 0x3c, 0x2f, - 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, - 0x3e, 0x3c, 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, - 0x74, 0x79, 0x20, 0x6e, 0x61, 0x6d, 0x65, 0x3d, - 0x22, 0x63, 0x61, 0x6e, 0x5f, 0x66, 0x6f, 0x63, - 0x75, 0x73, 0x22, 0x3e, 0x46, 0x61, 0x6c, 0x73, - 0x65, 0x3c, 0x2f, 0x70, 0x72, 0x6f, 0x70, 0x65, - 0x72, 0x74, 0x79, 0x3e, 0x3c, 0x70, 0x72, 0x6f, - 0x70, 0x65, 0x72, 0x74, 0x79, 0x20, 0x6e, 0x61, - 0x6d, 0x65, 0x3d, 0x22, 0x74, 0x6f, 0x6f, 0x6c, - 0x74, 0x69, 0x70, 0x5f, 0x74, 0x65, 0x78, 0x74, - 0x22, 0x20, 0x74, 0x72, 0x61, 0x6e, 0x73, 0x6c, - 0x61, 0x74, 0x61, 0x62, 0x6c, 0x65, 0x3d, 0x22, - 0x79, 0x65, 0x73, 0x22, 0x20, 0x63, 0x6f, 0x6d, - 0x6d, 0x65, 0x6e, 0x74, 0x73, 0x3d, 0x22, 0x54, - 0x6f, 0x6f, 0x6c, 0x74, 0x69, 0x70, 0x20, 0x66, - 0x6f, 0x72, 0x20, 0x73, 0x74, 0x6f, 0x70, 0x20, - 0x62, 0x75, 0x74, 0x74, 0x6f, 0x6e, 0x22, 0x3e, - 0x53, 0x74, 0x6f, 0x70, 0x20, 0x74, 0x68, 0x65, - 0x20, 0x63, 0x75, 0x72, 0x72, 0x65, 0x6e, 0x74, - 0x20, 0x73, 0x63, 0x61, 0x6e, 0x3c, 0x2f, 0x70, - 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, 0x3e, - 0x3c, 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, - 0x79, 0x20, 0x6e, 0x61, 0x6d, 0x65, 0x3d, 0x22, - 0x6c, 0x61, 0x62, 0x65, 0x6c, 0x22, 0x20, 0x74, - 0x72, 0x61, 0x6e, 0x73, 0x6c, 0x61, 0x74, 0x61, - 0x62, 0x6c, 0x65, 0x3d, 0x22, 0x79, 0x65, 0x73, - 0x22, 0x3e, 0x53, 0x74, 0x6f, 0x70, 0x3c, 0x2f, - 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, - 0x3e, 0x3c, 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, - 0x74, 0x79, 0x20, 0x6e, 0x61, 0x6d, 0x65, 0x3d, - 0x22, 0x75, 0x73, 0x65, 0x5f, 0x75, 0x6e, 0x64, - 0x65, 0x72, 0x6c, 0x69, 0x6e, 0x65, 0x22, 0x3e, - 0x54, 0x72, 0x75, 0x65, 0x3c, 0x2f, 0x70, 0x72, - 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, 0x3e, 0x3c, - 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, - 0x20, 0x6e, 0x61, 0x6d, 0x65, 0x3d, 0x22, 0x73, - 0x74, 0x6f, 0x63, 0x6b, 0x5f, 0x69, 0x64, 0x22, - 0x3e, 0x67, 0x74, 0x6b, 0x2d, 0x73, 0x74, 0x6f, - 0x70, 0x3c, 0x2f, 0x70, 0x72, 0x6f, 0x70, 0x65, - 0x72, 0x74, 0x79, 0x3e, 0x3c, 0x73, 0x69, 0x67, - 0x6e, 0x61, 0x6c, 0x20, 0x6e, 0x61, 0x6d, 0x65, - 0x3d, 0x22, 0x63, 0x6c, 0x69, 0x63, 0x6b, 0x65, - 0x64, 0x22, 0x20, 0x68, 0x61, 0x6e, 0x64, 0x6c, - 0x65, 0x72, 0x3d, 0x22, 0x73, 0x74, 0x6f, 0x70, - 0x5f, 0x73, 0x63, 0x61, 0x6e, 0x5f, 0x62, 0x75, - 0x74, 0x74, 0x6f, 0x6e, 0x5f, 0x63, 0x6c, 0x69, - 0x63, 0x6b, 0x65, 0x64, 0x5f, 0x63, 0x62, 0x22, - 0x20, 0x73, 0x77, 0x61, 0x70, 0x70, 0x65, 0x64, - 0x3d, 0x22, 0x6e, 0x6f, 0x22, 0x2f, 0x3e, 0x3c, - 0x2f, 0x6f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x3e, - 0x3c, 0x70, 0x61, 0x63, 0x6b, 0x69, 0x6e, 0x67, - 0x3e, 0x3c, 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, - 0x74, 0x79, 0x20, 0x6e, 0x61, 0x6d, 0x65, 0x3d, - 0x22, 0x65, 0x78, 0x70, 0x61, 0x6e, 0x64, 0x22, - 0x3e, 0x46, 0x61, 0x6c, 0x73, 0x65, 0x3c, 0x2f, - 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, - 0x3e, 0x3c, 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, - 0x74, 0x79, 0x20, 0x6e, 0x61, 0x6d, 0x65, 0x3d, - 0x22, 0x68, 0x6f, 0x6d, 0x6f, 0x67, 0x65, 0x6e, - 0x65, 0x6f, 0x75, 0x73, 0x22, 0x3e, 0x54, 0x72, - 0x75, 0x65, 0x3c, 0x2f, 0x70, 0x72, 0x6f, 0x70, - 0x65, 0x72, 0x74, 0x79, 0x3e, 0x3c, 0x2f, 0x70, - 0x61, 0x63, 0x6b, 0x69, 0x6e, 0x67, 0x3e, 0x3c, - 0x2f, 0x63, 0x68, 0x69, 0x6c, 0x64, 0x3e, 0x3c, - 0x63, 0x68, 0x69, 0x6c, 0x64, 0x3e, 0x3c, 0x6f, - 0x62, 0x6a, 0x65, 0x63, 0x74, 0x20, 0x63, 0x6c, - 0x61, 0x73, 0x73, 0x3d, 0x22, 0x47, 0x74, 0x6b, - 0x53, 0x65, 0x70, 0x61, 0x72, 0x61, 0x74, 0x6f, - 0x72, 0x54, 0x6f, 0x6f, 0x6c, 0x49, 0x74, 0x65, - 0x6d, 0x22, 0x20, 0x69, 0x64, 0x3d, 0x22, 0x74, - 0x6f, 0x6f, 0x6c, 0x62, 0x75, 0x74, 0x74, 0x6f, - 0x6e, 0x32, 0x22, 0x3e, 0x3c, 0x70, 0x72, 0x6f, - 0x70, 0x65, 0x72, 0x74, 0x79, 0x20, 0x6e, 0x61, - 0x6d, 0x65, 0x3d, 0x22, 0x76, 0x69, 0x73, 0x69, - 0x62, 0x6c, 0x65, 0x22, 0x3e, 0x54, 0x72, 0x75, - 0x65, 0x3c, 0x2f, 0x70, 0x72, 0x6f, 0x70, 0x65, - 0x72, 0x74, 0x79, 0x3e, 0x3c, 0x70, 0x72, 0x6f, - 0x70, 0x65, 0x72, 0x74, 0x79, 0x20, 0x6e, 0x61, - 0x6d, 0x65, 0x3d, 0x22, 0x63, 0x61, 0x6e, 0x5f, - 0x66, 0x6f, 0x63, 0x75, 0x73, 0x22, 0x3e, 0x46, - 0x61, 0x6c, 0x73, 0x65, 0x3c, 0x2f, 0x70, 0x72, - 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, 0x3e, 0x3c, - 0x2f, 0x6f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x3e, - 0x3c, 0x70, 0x61, 0x63, 0x6b, 0x69, 0x6e, 0x67, - 0x3e, 0x3c, 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, - 0x74, 0x79, 0x20, 0x6e, 0x61, 0x6d, 0x65, 0x3d, - 0x22, 0x65, 0x78, 0x70, 0x61, 0x6e, 0x64, 0x22, - 0x3e, 0x46, 0x61, 0x6c, 0x73, 0x65, 0x3c, 0x2f, - 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, - 0x3e, 0x3c, 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, - 0x74, 0x79, 0x20, 0x6e, 0x61, 0x6d, 0x65, 0x3d, - 0x22, 0x68, 0x6f, 0x6d, 0x6f, 0x67, 0x65, 0x6e, - 0x65, 0x6f, 0x75, 0x73, 0x22, 0x3e, 0x54, 0x72, - 0x75, 0x65, 0x3c, 0x2f, 0x70, 0x72, 0x6f, 0x70, - 0x65, 0x72, 0x74, 0x79, 0x3e, 0x3c, 0x2f, 0x70, - 0x61, 0x63, 0x6b, 0x69, 0x6e, 0x67, 0x3e, 0x3c, - 0x2f, 0x63, 0x68, 0x69, 0x6c, 0x64, 0x3e, 0x3c, - 0x63, 0x68, 0x69, 0x6c, 0x64, 0x3e, 0x3c, 0x6f, - 0x62, 0x6a, 0x65, 0x63, 0x74, 0x20, 0x63, 0x6c, - 0x61, 0x73, 0x73, 0x3d, 0x22, 0x47, 0x74, 0x6b, - 0x54, 0x6f, 0x6f, 0x6c, 0x42, 0x75, 0x74, 0x74, - 0x6f, 0x6e, 0x22, 0x20, 0x69, 0x64, 0x3d, 0x22, - 0x72, 0x6f, 0x74, 0x61, 0x74, 0x65, 0x5f, 0x6c, - 0x65, 0x66, 0x74, 0x5f, 0x74, 0x6f, 0x6f, 0x6c, - 0x62, 0x75, 0x74, 0x74, 0x6f, 0x6e, 0x22, 0x3e, - 0x3c, 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, - 0x79, 0x20, 0x6e, 0x61, 0x6d, 0x65, 0x3d, 0x22, - 0x76, 0x69, 0x73, 0x69, 0x62, 0x6c, 0x65, 0x22, - 0x3e, 0x54, 0x72, 0x75, 0x65, 0x3c, 0x2f, 0x70, - 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, 0x3e, - 0x3c, 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, - 0x79, 0x20, 0x6e, 0x61, 0x6d, 0x65, 0x3d, 0x22, - 0x63, 0x61, 0x6e, 0x5f, 0x66, 0x6f, 0x63, 0x75, - 0x73, 0x22, 0x3e, 0x46, 0x61, 0x6c, 0x73, 0x65, - 0x3c, 0x2f, 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, - 0x74, 0x79, 0x3e, 0x3c, 0x70, 0x72, 0x6f, 0x70, - 0x65, 0x72, 0x74, 0x79, 0x20, 0x6e, 0x61, 0x6d, - 0x65, 0x3d, 0x22, 0x74, 0x6f, 0x6f, 0x6c, 0x74, - 0x69, 0x70, 0x5f, 0x74, 0x65, 0x78, 0x74, 0x22, - 0x20, 0x74, 0x72, 0x61, 0x6e, 0x73, 0x6c, 0x61, - 0x74, 0x61, 0x62, 0x6c, 0x65, 0x3d, 0x22, 0x79, - 0x65, 0x73, 0x22, 0x20, 0x63, 0x6f, 0x6d, 0x6d, - 0x65, 0x6e, 0x74, 0x73, 0x3d, 0x22, 0x54, 0x6f, - 0x6f, 0x6c, 0x74, 0x69, 0x70, 0x20, 0x66, 0x6f, - 0x72, 0x20, 0x72, 0x6f, 0x74, 0x61, 0x74, 0x65, - 0x20, 0x6c, 0x65, 0x66, 0x74, 0x20, 0x28, 0x63, - 0x6f, 0x75, 0x6e, 0x74, 0x65, 0x72, 0x2d, 0x63, - 0x6c, 0x6f, 0x63, 0x6b, 0x77, 0x69, 0x73, 0x65, - 0x29, 0x20, 0x62, 0x75, 0x74, 0x74, 0x6f, 0x6e, - 0x22, 0x3e, 0x52, 0x6f, 0x74, 0x61, 0x74, 0x65, - 0x20, 0x74, 0x68, 0x65, 0x20, 0x70, 0x61, 0x67, - 0x65, 0x20, 0x74, 0x6f, 0x20, 0x74, 0x68, 0x65, - 0x20, 0x6c, 0x65, 0x66, 0x74, 0x20, 0x28, 0x63, - 0x6f, 0x75, 0x6e, 0x74, 0x65, 0x72, 0x2d, 0x63, - 0x6c, 0x6f, 0x63, 0x6b, 0x77, 0x69, 0x73, 0x65, - 0x29, 0x3c, 0x2f, 0x70, 0x72, 0x6f, 0x70, 0x65, - 0x72, 0x74, 0x79, 0x3e, 0x3c, 0x70, 0x72, 0x6f, - 0x70, 0x65, 0x72, 0x74, 0x79, 0x20, 0x6e, 0x61, - 0x6d, 0x65, 0x3d, 0x22, 0x6c, 0x61, 0x62, 0x65, - 0x6c, 0x22, 0x20, 0x74, 0x72, 0x61, 0x6e, 0x73, - 0x6c, 0x61, 0x74, 0x61, 0x62, 0x6c, 0x65, 0x3d, - 0x22, 0x79, 0x65, 0x73, 0x22, 0x20, 0x63, 0x6f, - 0x6d, 0x6d, 0x65, 0x6e, 0x74, 0x73, 0x3d, 0x22, - 0x4c, 0x61, 0x62, 0x65, 0x6c, 0x20, 0x6f, 0x6e, - 0x20, 0x72, 0x6f, 0x74, 0x61, 0x74, 0x65, 0x20, - 0x70, 0x61, 0x67, 0x65, 0x20, 0x6c, 0x65, 0x66, - 0x74, 0x20, 0x28, 0x61, 0x6e, 0x74, 0x69, 0x2d, - 0x63, 0x6c, 0x6f, 0x63, 0x6b, 0x77, 0x69, 0x73, - 0x65, 0x29, 0x20, 0x69, 0x74, 0x65, 0x6d, 0x22, - 0x3e, 0x52, 0x6f, 0x74, 0x61, 0x74, 0x65, 0x20, - 0x4c, 0x65, 0x66, 0x74, 0x3c, 0x2f, 0x70, 0x72, - 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, 0x3e, 0x3c, - 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, - 0x20, 0x6e, 0x61, 0x6d, 0x65, 0x3d, 0x22, 0x75, - 0x73, 0x65, 0x5f, 0x75, 0x6e, 0x64, 0x65, 0x72, - 0x6c, 0x69, 0x6e, 0x65, 0x22, 0x3e, 0x54, 0x72, - 0x75, 0x65, 0x3c, 0x2f, 0x70, 0x72, 0x6f, 0x70, - 0x65, 0x72, 0x74, 0x79, 0x3e, 0x3c, 0x70, 0x72, - 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, 0x20, 0x6e, - 0x61, 0x6d, 0x65, 0x3d, 0x22, 0x69, 0x63, 0x6f, - 0x6e, 0x5f, 0x6e, 0x61, 0x6d, 0x65, 0x22, 0x3e, - 0x6f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x2d, 0x72, - 0x6f, 0x74, 0x61, 0x74, 0x65, 0x2d, 0x6c, 0x65, - 0x66, 0x74, 0x3c, 0x2f, 0x70, 0x72, 0x6f, 0x70, - 0x65, 0x72, 0x74, 0x79, 0x3e, 0x3c, 0x73, 0x69, - 0x67, 0x6e, 0x61, 0x6c, 0x20, 0x6e, 0x61, 0x6d, - 0x65, 0x3d, 0x22, 0x63, 0x6c, 0x69, 0x63, 0x6b, - 0x65, 0x64, 0x22, 0x20, 0x68, 0x61, 0x6e, 0x64, - 0x6c, 0x65, 0x72, 0x3d, 0x22, 0x72, 0x6f, 0x74, - 0x61, 0x74, 0x65, 0x5f, 0x6c, 0x65, 0x66, 0x74, - 0x5f, 0x62, 0x75, 0x74, 0x74, 0x6f, 0x6e, 0x5f, - 0x63, 0x6c, 0x69, 0x63, 0x6b, 0x65, 0x64, 0x5f, - 0x63, 0x62, 0x22, 0x20, 0x73, 0x77, 0x61, 0x70, - 0x70, 0x65, 0x64, 0x3d, 0x22, 0x6e, 0x6f, 0x22, - 0x2f, 0x3e, 0x3c, 0x2f, 0x6f, 0x62, 0x6a, 0x65, - 0x63, 0x74, 0x3e, 0x3c, 0x70, 0x61, 0x63, 0x6b, - 0x69, 0x6e, 0x67, 0x3e, 0x3c, 0x70, 0x72, 0x6f, - 0x70, 0x65, 0x72, 0x74, 0x79, 0x20, 0x6e, 0x61, - 0x6d, 0x65, 0x3d, 0x22, 0x65, 0x78, 0x70, 0x61, - 0x6e, 0x64, 0x22, 0x3e, 0x46, 0x61, 0x6c, 0x73, - 0x65, 0x3c, 0x2f, 0x70, 0x72, 0x6f, 0x70, 0x65, - 0x72, 0x74, 0x79, 0x3e, 0x3c, 0x70, 0x72, 0x6f, - 0x70, 0x65, 0x72, 0x74, 0x79, 0x20, 0x6e, 0x61, - 0x6d, 0x65, 0x3d, 0x22, 0x68, 0x6f, 0x6d, 0x6f, - 0x67, 0x65, 0x6e, 0x65, 0x6f, 0x75, 0x73, 0x22, - 0x3e, 0x54, 0x72, 0x75, 0x65, 0x3c, 0x2f, 0x70, - 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, 0x3e, - 0x3c, 0x2f, 0x70, 0x61, 0x63, 0x6b, 0x69, 0x6e, - 0x67, 0x3e, 0x3c, 0x2f, 0x63, 0x68, 0x69, 0x6c, - 0x64, 0x3e, 0x3c, 0x63, 0x68, 0x69, 0x6c, 0x64, - 0x3e, 0x3c, 0x6f, 0x62, 0x6a, 0x65, 0x63, 0x74, - 0x20, 0x63, 0x6c, 0x61, 0x73, 0x73, 0x3d, 0x22, - 0x47, 0x74, 0x6b, 0x54, 0x6f, 0x6f, 0x6c, 0x42, - 0x75, 0x74, 0x74, 0x6f, 0x6e, 0x22, 0x20, 0x69, - 0x64, 0x3d, 0x22, 0x72, 0x6f, 0x74, 0x61, 0x74, - 0x65, 0x5f, 0x72, 0x69, 0x67, 0x68, 0x74, 0x5f, - 0x74, 0x6f, 0x6f, 0x6c, 0x62, 0x75, 0x74, 0x74, - 0x6f, 0x6e, 0x22, 0x3e, 0x3c, 0x70, 0x72, 0x6f, - 0x70, 0x65, 0x72, 0x74, 0x79, 0x20, 0x6e, 0x61, - 0x6d, 0x65, 0x3d, 0x22, 0x76, 0x69, 0x73, 0x69, - 0x62, 0x6c, 0x65, 0x22, 0x3e, 0x54, 0x72, 0x75, - 0x65, 0x3c, 0x2f, 0x70, 0x72, 0x6f, 0x70, 0x65, - 0x72, 0x74, 0x79, 0x3e, 0x3c, 0x70, 0x72, 0x6f, - 0x70, 0x65, 0x72, 0x74, 0x79, 0x20, 0x6e, 0x61, - 0x6d, 0x65, 0x3d, 0x22, 0x63, 0x61, 0x6e, 0x5f, - 0x66, 0x6f, 0x63, 0x75, 0x73, 0x22, 0x3e, 0x46, - 0x61, 0x6c, 0x73, 0x65, 0x3c, 0x2f, 0x70, 0x72, - 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, 0x3e, 0x3c, - 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, - 0x20, 0x6e, 0x61, 0x6d, 0x65, 0x3d, 0x22, 0x74, - 0x6f, 0x6f, 0x6c, 0x74, 0x69, 0x70, 0x5f, 0x74, - 0x65, 0x78, 0x74, 0x22, 0x20, 0x74, 0x72, 0x61, - 0x6e, 0x73, 0x6c, 0x61, 0x74, 0x61, 0x62, 0x6c, - 0x65, 0x3d, 0x22, 0x79, 0x65, 0x73, 0x22, 0x20, - 0x63, 0x6f, 0x6d, 0x6d, 0x65, 0x6e, 0x74, 0x73, - 0x3d, 0x22, 0x54, 0x6f, 0x6f, 0x6c, 0x74, 0x69, - 0x70, 0x20, 0x66, 0x6f, 0x72, 0x20, 0x72, 0x6f, - 0x74, 0x61, 0x74, 0x65, 0x20, 0x72, 0x69, 0x67, - 0x68, 0x74, 0x20, 0x28, 0x63, 0x6c, 0x6f, 0x63, - 0x6b, 0x77, 0x69, 0x73, 0x65, 0x29, 0x20, 0x62, - 0x75, 0x74, 0x74, 0x6f, 0x6e, 0x22, 0x3e, 0x52, - 0x6f, 0x74, 0x61, 0x74, 0x65, 0x20, 0x74, 0x68, - 0x65, 0x20, 0x70, 0x61, 0x67, 0x65, 0x20, 0x74, - 0x6f, 0x20, 0x74, 0x68, 0x65, 0x20, 0x72, 0x69, - 0x67, 0x68, 0x74, 0x20, 0x28, 0x63, 0x6c, 0x6f, - 0x63, 0x6b, 0x77, 0x69, 0x73, 0x65, 0x29, 0x3c, - 0x2f, 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, - 0x79, 0x3e, 0x3c, 0x70, 0x72, 0x6f, 0x70, 0x65, - 0x72, 0x74, 0x79, 0x20, 0x6e, 0x61, 0x6d, 0x65, - 0x3d, 0x22, 0x6c, 0x61, 0x62, 0x65, 0x6c, 0x22, - 0x20, 0x74, 0x72, 0x61, 0x6e, 0x73, 0x6c, 0x61, - 0x74, 0x61, 0x62, 0x6c, 0x65, 0x3d, 0x22, 0x79, - 0x65, 0x73, 0x22, 0x20, 0x63, 0x6f, 0x6d, 0x6d, - 0x65, 0x6e, 0x74, 0x73, 0x3d, 0x22, 0x4c, 0x61, - 0x62, 0x65, 0x6c, 0x20, 0x6f, 0x6e, 0x20, 0x72, - 0x6f, 0x74, 0x61, 0x74, 0x65, 0x20, 0x70, 0x61, - 0x67, 0x65, 0x20, 0x72, 0x69, 0x67, 0x68, 0x74, - 0x20, 0x28, 0x63, 0x6c, 0x6f, 0x63, 0x6b, 0x77, - 0x69, 0x73, 0x65, 0x29, 0x20, 0x69, 0x74, 0x65, - 0x6d, 0x22, 0x3e, 0x52, 0x6f, 0x74, 0x61, 0x74, - 0x65, 0x20, 0x52, 0x69, 0x67, 0x68, 0x74, 0x3c, - 0x2f, 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, - 0x79, 0x3e, 0x3c, 0x70, 0x72, 0x6f, 0x70, 0x65, - 0x72, 0x74, 0x79, 0x20, 0x6e, 0x61, 0x6d, 0x65, - 0x3d, 0x22, 0x75, 0x73, 0x65, 0x5f, 0x75, 0x6e, - 0x64, 0x65, 0x72, 0x6c, 0x69, 0x6e, 0x65, 0x22, - 0x3e, 0x54, 0x72, 0x75, 0x65, 0x3c, 0x2f, 0x70, - 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, 0x3e, - 0x3c, 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, - 0x79, 0x20, 0x6e, 0x61, 0x6d, 0x65, 0x3d, 0x22, - 0x69, 0x63, 0x6f, 0x6e, 0x5f, 0x6e, 0x61, 0x6d, - 0x65, 0x22, 0x3e, 0x6f, 0x62, 0x6a, 0x65, 0x63, - 0x74, 0x2d, 0x72, 0x6f, 0x74, 0x61, 0x74, 0x65, - 0x2d, 0x72, 0x69, 0x67, 0x68, 0x74, 0x3c, 0x2f, - 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, - 0x3e, 0x3c, 0x73, 0x69, 0x67, 0x6e, 0x61, 0x6c, - 0x20, 0x6e, 0x61, 0x6d, 0x65, 0x3d, 0x22, 0x63, - 0x6c, 0x69, 0x63, 0x6b, 0x65, 0x64, 0x22, 0x20, - 0x68, 0x61, 0x6e, 0x64, 0x6c, 0x65, 0x72, 0x3d, - 0x22, 0x72, 0x6f, 0x74, 0x61, 0x74, 0x65, 0x5f, - 0x72, 0x69, 0x67, 0x68, 0x74, 0x5f, 0x62, 0x75, - 0x74, 0x74, 0x6f, 0x6e, 0x5f, 0x63, 0x6c, 0x69, - 0x63, 0x6b, 0x65, 0x64, 0x5f, 0x63, 0x62, 0x22, - 0x20, 0x73, 0x77, 0x61, 0x70, 0x70, 0x65, 0x64, - 0x3d, 0x22, 0x6e, 0x6f, 0x22, 0x2f, 0x3e, 0x3c, - 0x2f, 0x6f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x3e, - 0x3c, 0x70, 0x61, 0x63, 0x6b, 0x69, 0x6e, 0x67, - 0x3e, 0x3c, 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, - 0x74, 0x79, 0x20, 0x6e, 0x61, 0x6d, 0x65, 0x3d, - 0x22, 0x65, 0x78, 0x70, 0x61, 0x6e, 0x64, 0x22, - 0x3e, 0x46, 0x61, 0x6c, 0x73, 0x65, 0x3c, 0x2f, - 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, - 0x3e, 0x3c, 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, - 0x74, 0x79, 0x20, 0x6e, 0x61, 0x6d, 0x65, 0x3d, - 0x22, 0x68, 0x6f, 0x6d, 0x6f, 0x67, 0x65, 0x6e, - 0x65, 0x6f, 0x75, 0x73, 0x22, 0x3e, 0x54, 0x72, - 0x75, 0x65, 0x3c, 0x2f, 0x70, 0x72, 0x6f, 0x70, - 0x65, 0x72, 0x74, 0x79, 0x3e, 0x3c, 0x2f, 0x70, - 0x61, 0x63, 0x6b, 0x69, 0x6e, 0x67, 0x3e, 0x3c, - 0x2f, 0x63, 0x68, 0x69, 0x6c, 0x64, 0x3e, 0x3c, - 0x63, 0x68, 0x69, 0x6c, 0x64, 0x3e, 0x3c, 0x6f, - 0x62, 0x6a, 0x65, 0x63, 0x74, 0x20, 0x63, 0x6c, - 0x61, 0x73, 0x73, 0x3d, 0x22, 0x47, 0x74, 0x6b, - 0x54, 0x6f, 0x67, 0x67, 0x6c, 0x65, 0x54, 0x6f, - 0x6f, 0x6c, 0x42, 0x75, 0x74, 0x74, 0x6f, 0x6e, - 0x22, 0x20, 0x69, 0x64, 0x3d, 0x22, 0x63, 0x72, - 0x6f, 0x70, 0x5f, 0x74, 0x6f, 0x6f, 0x6c, 0x62, - 0x75, 0x74, 0x74, 0x6f, 0x6e, 0x22, 0x3e, 0x3c, - 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, - 0x20, 0x6e, 0x61, 0x6d, 0x65, 0x3d, 0x22, 0x76, - 0x69, 0x73, 0x69, 0x62, 0x6c, 0x65, 0x22, 0x3e, - 0x54, 0x72, 0x75, 0x65, 0x3c, 0x2f, 0x70, 0x72, - 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, 0x3e, 0x3c, - 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, - 0x20, 0x6e, 0x61, 0x6d, 0x65, 0x3d, 0x22, 0x63, - 0x61, 0x6e, 0x5f, 0x66, 0x6f, 0x63, 0x75, 0x73, - 0x22, 0x3e, 0x46, 0x61, 0x6c, 0x73, 0x65, 0x3c, - 0x2f, 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, - 0x79, 0x3e, 0x3c, 0x70, 0x72, 0x6f, 0x70, 0x65, - 0x72, 0x74, 0x79, 0x20, 0x6e, 0x61, 0x6d, 0x65, - 0x3d, 0x22, 0x74, 0x6f, 0x6f, 0x6c, 0x74, 0x69, - 0x70, 0x5f, 0x74, 0x65, 0x78, 0x74, 0x22, 0x20, - 0x74, 0x72, 0x61, 0x6e, 0x73, 0x6c, 0x61, 0x74, - 0x61, 0x62, 0x6c, 0x65, 0x3d, 0x22, 0x79, 0x65, - 0x73, 0x22, 0x3e, 0x43, 0x72, 0x6f, 0x70, 0x20, - 0x74, 0x68, 0x65, 0x20, 0x73, 0x65, 0x6c, 0x65, - 0x63, 0x74, 0x65, 0x64, 0x20, 0x70, 0x61, 0x67, - 0x65, 0x3c, 0x2f, 0x70, 0x72, 0x6f, 0x70, 0x65, - 0x72, 0x74, 0x79, 0x3e, 0x3c, 0x70, 0x72, 0x6f, - 0x70, 0x65, 0x72, 0x74, 0x79, 0x20, 0x6e, 0x61, - 0x6d, 0x65, 0x3d, 0x22, 0x69, 0x73, 0x5f, 0x69, - 0x6d, 0x70, 0x6f, 0x72, 0x74, 0x61, 0x6e, 0x74, - 0x22, 0x3e, 0x54, 0x72, 0x75, 0x65, 0x3c, 0x2f, - 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, - 0x3e, 0x3c, 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, - 0x74, 0x79, 0x20, 0x6e, 0x61, 0x6d, 0x65, 0x3d, - 0x22, 0x6c, 0x61, 0x62, 0x65, 0x6c, 0x22, 0x20, - 0x74, 0x72, 0x61, 0x6e, 0x73, 0x6c, 0x61, 0x74, - 0x61, 0x62, 0x6c, 0x65, 0x3d, 0x22, 0x79, 0x65, - 0x73, 0x22, 0x3e, 0x43, 0x72, 0x6f, 0x70, 0x3c, - 0x2f, 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, - 0x79, 0x3e, 0x3c, 0x70, 0x72, 0x6f, 0x70, 0x65, - 0x72, 0x74, 0x79, 0x20, 0x6e, 0x61, 0x6d, 0x65, - 0x3d, 0x22, 0x75, 0x73, 0x65, 0x5f, 0x75, 0x6e, - 0x64, 0x65, 0x72, 0x6c, 0x69, 0x6e, 0x65, 0x22, - 0x3e, 0x54, 0x72, 0x75, 0x65, 0x3c, 0x2f, 0x70, - 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, 0x3e, - 0x3c, 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, - 0x79, 0x20, 0x6e, 0x61, 0x6d, 0x65, 0x3d, 0x22, - 0x69, 0x63, 0x6f, 0x6e, 0x5f, 0x6e, 0x61, 0x6d, - 0x65, 0x22, 0x3e, 0x6f, 0x62, 0x6a, 0x65, 0x63, - 0x74, 0x2d, 0x63, 0x72, 0x6f, 0x70, 0x3c, 0x2f, - 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, - 0x3e, 0x3c, 0x73, 0x69, 0x67, 0x6e, 0x61, 0x6c, - 0x20, 0x6e, 0x61, 0x6d, 0x65, 0x3d, 0x22, 0x74, - 0x6f, 0x67, 0x67, 0x6c, 0x65, 0x64, 0x22, 0x20, - 0x68, 0x61, 0x6e, 0x64, 0x6c, 0x65, 0x72, 0x3d, - 0x22, 0x63, 0x72, 0x6f, 0x70, 0x5f, 0x74, 0x6f, - 0x6f, 0x6c, 0x62, 0x75, 0x74, 0x74, 0x6f, 0x6e, - 0x5f, 0x74, 0x6f, 0x67, 0x67, 0x6c, 0x65, 0x64, - 0x5f, 0x63, 0x62, 0x22, 0x20, 0x73, 0x77, 0x61, - 0x70, 0x70, 0x65, 0x64, 0x3d, 0x22, 0x6e, 0x6f, - 0x22, 0x2f, 0x3e, 0x3c, 0x2f, 0x6f, 0x62, 0x6a, - 0x65, 0x63, 0x74, 0x3e, 0x3c, 0x70, 0x61, 0x63, - 0x6b, 0x69, 0x6e, 0x67, 0x3e, 0x3c, 0x70, 0x72, - 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, 0x20, 0x6e, - 0x61, 0x6d, 0x65, 0x3d, 0x22, 0x65, 0x78, 0x70, - 0x61, 0x6e, 0x64, 0x22, 0x3e, 0x46, 0x61, 0x6c, - 0x73, 0x65, 0x3c, 0x2f, 0x70, 0x72, 0x6f, 0x70, - 0x65, 0x72, 0x74, 0x79, 0x3e, 0x3c, 0x70, 0x72, - 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, 0x20, 0x6e, - 0x61, 0x6d, 0x65, 0x3d, 0x22, 0x68, 0x6f, 0x6d, - 0x6f, 0x67, 0x65, 0x6e, 0x65, 0x6f, 0x75, 0x73, - 0x22, 0x3e, 0x54, 0x72, 0x75, 0x65, 0x3c, 0x2f, - 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, - 0x3e, 0x3c, 0x2f, 0x70, 0x61, 0x63, 0x6b, 0x69, - 0x6e, 0x67, 0x3e, 0x3c, 0x2f, 0x63, 0x68, 0x69, - 0x6c, 0x64, 0x3e, 0x3c, 0x2f, 0x6f, 0x62, 0x6a, - 0x65, 0x63, 0x74, 0x3e, 0x3c, 0x70, 0x61, 0x63, - 0x6b, 0x69, 0x6e, 0x67, 0x3e, 0x3c, 0x70, 0x72, - 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, 0x20, 0x6e, - 0x61, 0x6d, 0x65, 0x3d, 0x22, 0x65, 0x78, 0x70, - 0x61, 0x6e, 0x64, 0x22, 0x3e, 0x46, 0x61, 0x6c, - 0x73, 0x65, 0x3c, 0x2f, 0x70, 0x72, 0x6f, 0x70, - 0x65, 0x72, 0x74, 0x79, 0x3e, 0x3c, 0x70, 0x72, - 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, 0x20, 0x6e, - 0x61, 0x6d, 0x65, 0x3d, 0x22, 0x66, 0x69, 0x6c, - 0x6c, 0x22, 0x3e, 0x54, 0x72, 0x75, 0x65, 0x3c, - 0x2f, 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, - 0x79, 0x3e, 0x3c, 0x70, 0x72, 0x6f, 0x70, 0x65, - 0x72, 0x74, 0x79, 0x20, 0x6e, 0x61, 0x6d, 0x65, - 0x3d, 0x22, 0x70, 0x6f, 0x73, 0x69, 0x74, 0x69, - 0x6f, 0x6e, 0x22, 0x3e, 0x31, 0x3c, 0x2f, 0x70, - 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, 0x3e, - 0x3c, 0x2f, 0x70, 0x61, 0x63, 0x6b, 0x69, 0x6e, - 0x67, 0x3e, 0x3c, 0x2f, 0x63, 0x68, 0x69, 0x6c, - 0x64, 0x3e, 0x3c, 0x63, 0x68, 0x69, 0x6c, 0x64, - 0x3e, 0x3c, 0x70, 0x6c, 0x61, 0x63, 0x65, 0x68, - 0x6f, 0x6c, 0x64, 0x65, 0x72, 0x2f, 0x3e, 0x3c, - 0x2f, 0x63, 0x68, 0x69, 0x6c, 0x64, 0x3e, 0x3c, - 0x2f, 0x6f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x3e, - 0x3c, 0x2f, 0x63, 0x68, 0x69, 0x6c, 0x64, 0x3e, - 0x3c, 0x63, 0x68, 0x69, 0x6c, 0x64, 0x20, 0x74, - 0x79, 0x70, 0x65, 0x3d, 0x22, 0x74, 0x69, 0x74, - 0x6c, 0x65, 0x62, 0x61, 0x72, 0x22, 0x3e, 0x3c, - 0x6f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x20, 0x63, - 0x6c, 0x61, 0x73, 0x73, 0x3d, 0x22, 0x47, 0x74, - 0x6b, 0x48, 0x65, 0x61, 0x64, 0x65, 0x72, 0x42, - 0x61, 0x72, 0x22, 0x20, 0x69, 0x64, 0x3d, 0x22, - 0x68, 0x65, 0x61, 0x64, 0x65, 0x72, 0x62, 0x61, - 0x72, 0x22, 0x3e, 0x3c, 0x70, 0x72, 0x6f, 0x70, - 0x65, 0x72, 0x74, 0x79, 0x20, 0x6e, 0x61, 0x6d, - 0x65, 0x3d, 0x22, 0x76, 0x69, 0x73, 0x69, 0x62, - 0x6c, 0x65, 0x22, 0x3e, 0x54, 0x72, 0x75, 0x65, - 0x3c, 0x2f, 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, - 0x74, 0x79, 0x3e, 0x3c, 0x70, 0x72, 0x6f, 0x70, - 0x65, 0x72, 0x74, 0x79, 0x20, 0x6e, 0x61, 0x6d, - 0x65, 0x3d, 0x22, 0x63, 0x61, 0x6e, 0x5f, 0x66, - 0x6f, 0x63, 0x75, 0x73, 0x22, 0x3e, 0x46, 0x61, - 0x6c, 0x73, 0x65, 0x3c, 0x2f, 0x70, 0x72, 0x6f, - 0x70, 0x65, 0x72, 0x74, 0x79, 0x3e, 0x3c, 0x70, - 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, 0x20, - 0x6e, 0x61, 0x6d, 0x65, 0x3d, 0x22, 0x76, 0x65, - 0x78, 0x70, 0x61, 0x6e, 0x64, 0x22, 0x3e, 0x54, - 0x72, 0x75, 0x65, 0x3c, 0x2f, 0x70, 0x72, 0x6f, - 0x70, 0x65, 0x72, 0x74, 0x79, 0x3e, 0x3c, 0x70, - 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, 0x20, - 0x6e, 0x61, 0x6d, 0x65, 0x3d, 0x22, 0x73, 0x68, - 0x6f, 0x77, 0x5f, 0x63, 0x6c, 0x6f, 0x73, 0x65, - 0x5f, 0x62, 0x75, 0x74, 0x74, 0x6f, 0x6e, 0x22, - 0x3e, 0x54, 0x72, 0x75, 0x65, 0x3c, 0x2f, 0x70, - 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, 0x3e, - 0x3c, 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, - 0x79, 0x20, 0x6e, 0x61, 0x6d, 0x65, 0x3d, 0x22, - 0x74, 0x69, 0x74, 0x6c, 0x65, 0x22, 0x20, 0x74, - 0x72, 0x61, 0x6e, 0x73, 0x6c, 0x61, 0x74, 0x61, - 0x62, 0x6c, 0x65, 0x3d, 0x22, 0x79, 0x65, 0x73, - 0x22, 0x20, 0x63, 0x6f, 0x6d, 0x6d, 0x65, 0x6e, - 0x74, 0x73, 0x3d, 0x22, 0x54, 0x69, 0x74, 0x6c, - 0x65, 0x20, 0x6f, 0x66, 0x20, 0x73, 0x63, 0x61, - 0x6e, 0x20, 0x77, 0x69, 0x6e, 0x64, 0x6f, 0x77, - 0x22, 0x3e, 0x53, 0x69, 0x6d, 0x70, 0x6c, 0x65, - 0x20, 0x53, 0x63, 0x61, 0x6e, 0x3c, 0x2f, 0x70, - 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, 0x3e, - 0x3c, 0x73, 0x74, 0x79, 0x6c, 0x65, 0x3e, 0x3c, - 0x63, 0x6c, 0x61, 0x73, 0x73, 0x20, 0x6e, 0x61, - 0x6d, 0x65, 0x3d, 0x22, 0x74, 0x69, 0x74, 0x6c, - 0x65, 0x62, 0x61, 0x72, 0x22, 0x2f, 0x3e, 0x3c, - 0x2f, 0x73, 0x74, 0x79, 0x6c, 0x65, 0x3e, 0x3c, - 0x63, 0x68, 0x69, 0x6c, 0x64, 0x3e, 0x3c, 0x6f, - 0x62, 0x6a, 0x65, 0x63, 0x74, 0x20, 0x63, 0x6c, - 0x61, 0x73, 0x73, 0x3d, 0x22, 0x47, 0x74, 0x6b, - 0x42, 0x6f, 0x78, 0x22, 0x20, 0x69, 0x64, 0x3d, - 0x22, 0x6f, 0x70, 0x65, 0x6e, 0x5f, 0x62, 0x6f, - 0x78, 0x22, 0x3e, 0x3c, 0x70, 0x72, 0x6f, 0x70, - 0x65, 0x72, 0x74, 0x79, 0x20, 0x6e, 0x61, 0x6d, - 0x65, 0x3d, 0x22, 0x76, 0x69, 0x73, 0x69, 0x62, - 0x6c, 0x65, 0x22, 0x3e, 0x54, 0x72, 0x75, 0x65, - 0x3c, 0x2f, 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, - 0x74, 0x79, 0x3e, 0x3c, 0x70, 0x72, 0x6f, 0x70, - 0x65, 0x72, 0x74, 0x79, 0x20, 0x6e, 0x61, 0x6d, - 0x65, 0x3d, 0x22, 0x6f, 0x72, 0x69, 0x65, 0x6e, - 0x74, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x22, 0x3e, - 0x68, 0x6f, 0x72, 0x69, 0x7a, 0x6f, 0x6e, 0x74, - 0x61, 0x6c, 0x3c, 0x2f, 0x70, 0x72, 0x6f, 0x70, - 0x65, 0x72, 0x74, 0x79, 0x3e, 0x3c, 0x70, 0x72, - 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, 0x20, 0x6e, - 0x61, 0x6d, 0x65, 0x3d, 0x22, 0x76, 0x61, 0x6c, - 0x69, 0x67, 0x6e, 0x22, 0x3e, 0x63, 0x65, 0x6e, - 0x74, 0x65, 0x72, 0x3c, 0x2f, 0x70, 0x72, 0x6f, - 0x70, 0x65, 0x72, 0x74, 0x79, 0x3e, 0x3c, 0x73, - 0x74, 0x79, 0x6c, 0x65, 0x3e, 0x3c, 0x63, 0x6c, - 0x61, 0x73, 0x73, 0x20, 0x6e, 0x61, 0x6d, 0x65, - 0x3d, 0x22, 0x6c, 0x69, 0x6e, 0x6b, 0x65, 0x64, - 0x22, 0x2f, 0x3e, 0x3c, 0x2f, 0x73, 0x74, 0x79, - 0x6c, 0x65, 0x3e, 0x3c, 0x63, 0x68, 0x69, 0x6c, - 0x64, 0x3e, 0x3c, 0x6f, 0x62, 0x6a, 0x65, 0x63, - 0x74, 0x20, 0x63, 0x6c, 0x61, 0x73, 0x73, 0x3d, - 0x22, 0x47, 0x74, 0x6b, 0x42, 0x75, 0x74, 0x74, - 0x6f, 0x6e, 0x22, 0x20, 0x69, 0x64, 0x3d, 0x22, - 0x73, 0x74, 0x6f, 0x70, 0x5f, 0x62, 0x75, 0x74, - 0x74, 0x6f, 0x6e, 0x22, 0x3e, 0x3c, 0x70, 0x72, - 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, 0x20, 0x6e, - 0x61, 0x6d, 0x65, 0x3d, 0x22, 0x76, 0x69, 0x73, - 0x69, 0x62, 0x6c, 0x65, 0x22, 0x3e, 0x46, 0x61, - 0x6c, 0x73, 0x65, 0x3c, 0x2f, 0x70, 0x72, 0x6f, - 0x70, 0x65, 0x72, 0x74, 0x79, 0x3e, 0x3c, 0x70, - 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, 0x20, - 0x6e, 0x61, 0x6d, 0x65, 0x3d, 0x22, 0x74, 0x6f, - 0x6f, 0x6c, 0x74, 0x69, 0x70, 0x5f, 0x74, 0x65, - 0x78, 0x74, 0x22, 0x20, 0x74, 0x72, 0x61, 0x6e, - 0x73, 0x6c, 0x61, 0x74, 0x61, 0x62, 0x6c, 0x65, - 0x3d, 0x22, 0x79, 0x65, 0x73, 0x22, 0x20, 0x63, - 0x6f, 0x6d, 0x6d, 0x65, 0x6e, 0x74, 0x73, 0x3d, - 0x22, 0x54, 0x6f, 0x6f, 0x6c, 0x74, 0x69, 0x70, - 0x20, 0x66, 0x6f, 0x72, 0x20, 0x73, 0x74, 0x6f, - 0x70, 0x20, 0x62, 0x75, 0x74, 0x74, 0x6f, 0x6e, - 0x22, 0x3e, 0x53, 0x74, 0x6f, 0x70, 0x20, 0x74, - 0x68, 0x65, 0x20, 0x63, 0x75, 0x72, 0x72, 0x65, - 0x6e, 0x74, 0x20, 0x73, 0x63, 0x61, 0x6e, 0x3c, - 0x2f, 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, - 0x79, 0x3e, 0x3c, 0x70, 0x72, 0x6f, 0x70, 0x65, - 0x72, 0x74, 0x79, 0x20, 0x6e, 0x61, 0x6d, 0x65, - 0x3d, 0x22, 0x6c, 0x61, 0x62, 0x65, 0x6c, 0x22, - 0x20, 0x74, 0x72, 0x61, 0x6e, 0x73, 0x6c, 0x61, - 0x74, 0x61, 0x62, 0x6c, 0x65, 0x3d, 0x22, 0x79, - 0x65, 0x73, 0x22, 0x3e, 0x53, 0x74, 0x6f, 0x70, - 0x3c, 0x2f, 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, - 0x74, 0x79, 0x3e, 0x3c, 0x70, 0x72, 0x6f, 0x70, - 0x65, 0x72, 0x74, 0x79, 0x20, 0x6e, 0x61, 0x6d, - 0x65, 0x3d, 0x22, 0x75, 0x73, 0x65, 0x5f, 0x75, - 0x6e, 0x64, 0x65, 0x72, 0x6c, 0x69, 0x6e, 0x65, - 0x22, 0x3e, 0x54, 0x72, 0x75, 0x65, 0x3c, 0x2f, - 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, - 0x3e, 0x3c, 0x73, 0x69, 0x67, 0x6e, 0x61, 0x6c, - 0x20, 0x6e, 0x61, 0x6d, 0x65, 0x3d, 0x22, 0x63, - 0x6c, 0x69, 0x63, 0x6b, 0x65, 0x64, 0x22, 0x20, - 0x68, 0x61, 0x6e, 0x64, 0x6c, 0x65, 0x72, 0x3d, - 0x22, 0x73, 0x74, 0x6f, 0x70, 0x5f, 0x73, 0x63, - 0x61, 0x6e, 0x5f, 0x62, 0x75, 0x74, 0x74, 0x6f, - 0x6e, 0x5f, 0x63, 0x6c, 0x69, 0x63, 0x6b, 0x65, - 0x64, 0x5f, 0x63, 0x62, 0x22, 0x20, 0x73, 0x77, - 0x61, 0x70, 0x70, 0x65, 0x64, 0x3d, 0x22, 0x6e, - 0x6f, 0x22, 0x2f, 0x3e, 0x3c, 0x73, 0x74, 0x79, - 0x6c, 0x65, 0x3e, 0x3c, 0x63, 0x6c, 0x61, 0x73, - 0x73, 0x20, 0x6e, 0x61, 0x6d, 0x65, 0x3d, 0x22, - 0x74, 0x65, 0x78, 0x74, 0x2d, 0x62, 0x75, 0x74, - 0x74, 0x6f, 0x6e, 0x22, 0x2f, 0x3e, 0x3c, 0x2f, - 0x73, 0x74, 0x79, 0x6c, 0x65, 0x3e, 0x3c, 0x2f, - 0x6f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x3e, 0x3c, - 0x2f, 0x63, 0x68, 0x69, 0x6c, 0x64, 0x3e, 0x3c, - 0x63, 0x68, 0x69, 0x6c, 0x64, 0x3e, 0x3c, 0x6f, - 0x62, 0x6a, 0x65, 0x63, 0x74, 0x20, 0x63, 0x6c, - 0x61, 0x73, 0x73, 0x3d, 0x22, 0x47, 0x74, 0x6b, - 0x42, 0x75, 0x74, 0x74, 0x6f, 0x6e, 0x22, 0x20, - 0x69, 0x64, 0x3d, 0x22, 0x73, 0x63, 0x61, 0x6e, - 0x5f, 0x62, 0x75, 0x74, 0x74, 0x6f, 0x6e, 0x22, - 0x3e, 0x3c, 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, - 0x74, 0x79, 0x20, 0x6e, 0x61, 0x6d, 0x65, 0x3d, - 0x22, 0x76, 0x69, 0x73, 0x69, 0x62, 0x6c, 0x65, - 0x22, 0x3e, 0x54, 0x72, 0x75, 0x65, 0x3c, 0x2f, - 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, - 0x3e, 0x3c, 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, - 0x74, 0x79, 0x20, 0x6e, 0x61, 0x6d, 0x65, 0x3d, - 0x22, 0x74, 0x6f, 0x6f, 0x6c, 0x74, 0x69, 0x70, - 0x5f, 0x74, 0x65, 0x78, 0x74, 0x22, 0x20, 0x74, - 0x72, 0x61, 0x6e, 0x73, 0x6c, 0x61, 0x74, 0x61, - 0x62, 0x6c, 0x65, 0x3d, 0x22, 0x79, 0x65, 0x73, - 0x22, 0x20, 0x63, 0x6f, 0x6d, 0x6d, 0x65, 0x6e, - 0x74, 0x73, 0x3d, 0x22, 0x54, 0x6f, 0x6f, 0x6c, - 0x74, 0x69, 0x70, 0x20, 0x66, 0x6f, 0x72, 0x20, - 0x73, 0x63, 0x61, 0x6e, 0x20, 0x74, 0x6f, 0x6f, - 0x6c, 0x62, 0x61, 0x72, 0x20, 0x62, 0x75, 0x74, - 0x74, 0x6f, 0x6e, 0x22, 0x3e, 0x53, 0x63, 0x61, - 0x6e, 0x20, 0x61, 0x20, 0x73, 0x69, 0x6e, 0x67, - 0x6c, 0x65, 0x20, 0x70, 0x61, 0x67, 0x65, 0x20, - 0x66, 0x72, 0x6f, 0x6d, 0x20, 0x74, 0x68, 0x65, - 0x20, 0x73, 0x63, 0x61, 0x6e, 0x6e, 0x65, 0x72, - 0x3c, 0x2f, 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, - 0x74, 0x79, 0x3e, 0x3c, 0x70, 0x72, 0x6f, 0x70, - 0x65, 0x72, 0x74, 0x79, 0x20, 0x6e, 0x61, 0x6d, - 0x65, 0x3d, 0x22, 0x6c, 0x61, 0x62, 0x65, 0x6c, - 0x22, 0x20, 0x74, 0x72, 0x61, 0x6e, 0x73, 0x6c, - 0x61, 0x74, 0x61, 0x62, 0x6c, 0x65, 0x3d, 0x22, - 0x79, 0x65, 0x73, 0x22, 0x20, 0x63, 0x6f, 0x6d, - 0x6d, 0x65, 0x6e, 0x74, 0x73, 0x3d, 0x22, 0x4c, - 0x61, 0x62, 0x65, 0x6c, 0x20, 0x6f, 0x6e, 0x20, - 0x73, 0x63, 0x61, 0x6e, 0x20, 0x74, 0x6f, 0x6f, - 0x6c, 0x62, 0x61, 0x72, 0x20, 0x69, 0x74, 0x65, - 0x6d, 0x22, 0x3e, 0x53, 0x63, 0x61, 0x6e, 0x3c, - 0x2f, 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, - 0x79, 0x3e, 0x3c, 0x70, 0x72, 0x6f, 0x70, 0x65, - 0x72, 0x74, 0x79, 0x20, 0x6e, 0x61, 0x6d, 0x65, - 0x3d, 0x22, 0x75, 0x73, 0x65, 0x5f, 0x75, 0x6e, - 0x64, 0x65, 0x72, 0x6c, 0x69, 0x6e, 0x65, 0x22, - 0x3e, 0x54, 0x72, 0x75, 0x65, 0x3c, 0x2f, 0x70, - 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, 0x3e, - 0x3c, 0x73, 0x69, 0x67, 0x6e, 0x61, 0x6c, 0x20, - 0x6e, 0x61, 0x6d, 0x65, 0x3d, 0x22, 0x63, 0x6c, - 0x69, 0x63, 0x6b, 0x65, 0x64, 0x22, 0x20, 0x68, - 0x61, 0x6e, 0x64, 0x6c, 0x65, 0x72, 0x3d, 0x22, - 0x73, 0x63, 0x61, 0x6e, 0x5f, 0x62, 0x75, 0x74, - 0x74, 0x6f, 0x6e, 0x5f, 0x63, 0x6c, 0x69, 0x63, - 0x6b, 0x65, 0x64, 0x5f, 0x63, 0x62, 0x22, 0x20, - 0x73, 0x77, 0x61, 0x70, 0x70, 0x65, 0x64, 0x3d, - 0x22, 0x6e, 0x6f, 0x22, 0x2f, 0x3e, 0x3c, 0x73, - 0x74, 0x79, 0x6c, 0x65, 0x3e, 0x3c, 0x63, 0x6c, - 0x61, 0x73, 0x73, 0x20, 0x6e, 0x61, 0x6d, 0x65, - 0x3d, 0x22, 0x74, 0x65, 0x78, 0x74, 0x2d, 0x62, - 0x75, 0x74, 0x74, 0x6f, 0x6e, 0x22, 0x2f, 0x3e, - 0x3c, 0x2f, 0x73, 0x74, 0x79, 0x6c, 0x65, 0x3e, - 0x3c, 0x2f, 0x6f, 0x62, 0x6a, 0x65, 0x63, 0x74, - 0x3e, 0x3c, 0x2f, 0x63, 0x68, 0x69, 0x6c, 0x64, - 0x3e, 0x3c, 0x63, 0x68, 0x69, 0x6c, 0x64, 0x3e, - 0x3c, 0x6f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x20, - 0x63, 0x6c, 0x61, 0x73, 0x73, 0x3d, 0x22, 0x47, - 0x74, 0x6b, 0x4d, 0x65, 0x6e, 0x75, 0x42, 0x75, - 0x74, 0x74, 0x6f, 0x6e, 0x22, 0x20, 0x69, 0x64, - 0x3d, 0x22, 0x6f, 0x70, 0x65, 0x6e, 0x5f, 0x62, - 0x75, 0x74, 0x74, 0x6f, 0x6e, 0x22, 0x3e, 0x3c, - 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, - 0x20, 0x6e, 0x61, 0x6d, 0x65, 0x3d, 0x22, 0x76, - 0x69, 0x73, 0x69, 0x62, 0x6c, 0x65, 0x22, 0x3e, - 0x54, 0x72, 0x75, 0x65, 0x3c, 0x2f, 0x70, 0x72, - 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, 0x3e, 0x3c, - 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, - 0x20, 0x6e, 0x61, 0x6d, 0x65, 0x3d, 0x22, 0x70, - 0x6f, 0x70, 0x75, 0x70, 0x22, 0x3e, 0x73, 0x63, - 0x61, 0x6e, 0x5f, 0x62, 0x75, 0x74, 0x74, 0x6f, - 0x6e, 0x5f, 0x68, 0x62, 0x5f, 0x6d, 0x65, 0x6e, - 0x75, 0x3c, 0x2f, 0x70, 0x72, 0x6f, 0x70, 0x65, - 0x72, 0x74, 0x79, 0x3e, 0x3c, 0x73, 0x74, 0x79, - 0x6c, 0x65, 0x3e, 0x3c, 0x63, 0x6c, 0x61, 0x73, - 0x73, 0x20, 0x6e, 0x61, 0x6d, 0x65, 0x3d, 0x22, - 0x74, 0x65, 0x78, 0x74, 0x2d, 0x62, 0x75, 0x74, - 0x74, 0x6f, 0x6e, 0x22, 0x2f, 0x3e, 0x3c, 0x2f, - 0x73, 0x74, 0x79, 0x6c, 0x65, 0x3e, 0x3c, 0x2f, - 0x6f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x3e, 0x3c, - 0x2f, 0x63, 0x68, 0x69, 0x6c, 0x64, 0x3e, 0x3c, - 0x2f, 0x6f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x3e, - 0x3c, 0x70, 0x61, 0x63, 0x6b, 0x69, 0x6e, 0x67, - 0x3e, 0x3c, 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, - 0x74, 0x79, 0x20, 0x6e, 0x61, 0x6d, 0x65, 0x3d, - 0x22, 0x70, 0x61, 0x63, 0x6b, 0x5f, 0x74, 0x79, - 0x70, 0x65, 0x22, 0x3e, 0x73, 0x74, 0x61, 0x72, - 0x74, 0x3c, 0x2f, 0x70, 0x72, 0x6f, 0x70, 0x65, - 0x72, 0x74, 0x79, 0x3e, 0x3c, 0x2f, 0x70, 0x61, - 0x63, 0x6b, 0x69, 0x6e, 0x67, 0x3e, 0x3c, 0x2f, - 0x63, 0x68, 0x69, 0x6c, 0x64, 0x3e, 0x3c, 0x63, - 0x68, 0x69, 0x6c, 0x64, 0x3e, 0x3c, 0x6f, 0x62, - 0x6a, 0x65, 0x63, 0x74, 0x20, 0x63, 0x6c, 0x61, - 0x73, 0x73, 0x3d, 0x22, 0x47, 0x74, 0x6b, 0x42, - 0x75, 0x74, 0x74, 0x6f, 0x6e, 0x22, 0x20, 0x69, - 0x64, 0x3d, 0x22, 0x73, 0x61, 0x76, 0x65, 0x5f, - 0x62, 0x75, 0x74, 0x74, 0x6f, 0x6e, 0x22, 0x3e, - 0x3c, 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, - 0x79, 0x20, 0x6e, 0x61, 0x6d, 0x65, 0x3d, 0x22, - 0x76, 0x69, 0x73, 0x69, 0x62, 0x6c, 0x65, 0x22, - 0x3e, 0x54, 0x72, 0x75, 0x65, 0x3c, 0x2f, 0x70, - 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, 0x3e, - 0x3c, 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, - 0x79, 0x20, 0x6e, 0x61, 0x6d, 0x65, 0x3d, 0x22, - 0x73, 0x65, 0x6e, 0x73, 0x69, 0x74, 0x69, 0x76, - 0x65, 0x22, 0x3e, 0x46, 0x61, 0x6c, 0x73, 0x65, - 0x3c, 0x2f, 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, - 0x74, 0x79, 0x3e, 0x3c, 0x70, 0x72, 0x6f, 0x70, - 0x65, 0x72, 0x74, 0x79, 0x20, 0x6e, 0x61, 0x6d, - 0x65, 0x3d, 0x22, 0x63, 0x61, 0x6e, 0x5f, 0x66, - 0x6f, 0x63, 0x75, 0x73, 0x22, 0x3e, 0x46, 0x61, - 0x6c, 0x73, 0x65, 0x3c, 0x2f, 0x70, 0x72, 0x6f, - 0x70, 0x65, 0x72, 0x74, 0x79, 0x3e, 0x3c, 0x70, - 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, 0x20, - 0x6e, 0x61, 0x6d, 0x65, 0x3d, 0x22, 0x74, 0x6f, - 0x6f, 0x6c, 0x74, 0x69, 0x70, 0x5f, 0x74, 0x65, - 0x78, 0x74, 0x22, 0x20, 0x74, 0x72, 0x61, 0x6e, - 0x73, 0x6c, 0x61, 0x74, 0x61, 0x62, 0x6c, 0x65, - 0x3d, 0x22, 0x79, 0x65, 0x73, 0x22, 0x20, 0x63, - 0x6f, 0x6d, 0x6d, 0x65, 0x6e, 0x74, 0x73, 0x3d, - 0x22, 0x54, 0x6f, 0x6f, 0x6c, 0x74, 0x69, 0x70, - 0x20, 0x66, 0x6f, 0x72, 0x20, 0x73, 0x61, 0x76, - 0x65, 0x20, 0x74, 0x6f, 0x6f, 0x6c, 0x62, 0x61, - 0x72, 0x20, 0x62, 0x75, 0x74, 0x74, 0x6f, 0x6e, - 0x22, 0x3e, 0x53, 0x61, 0x76, 0x65, 0x20, 0x64, - 0x6f, 0x63, 0x75, 0x6d, 0x65, 0x6e, 0x74, 0x20, - 0x74, 0x6f, 0x20, 0x61, 0x20, 0x66, 0x69, 0x6c, - 0x65, 0x3c, 0x2f, 0x70, 0x72, 0x6f, 0x70, 0x65, - 0x72, 0x74, 0x79, 0x3e, 0x3c, 0x70, 0x72, 0x6f, - 0x70, 0x65, 0x72, 0x74, 0x79, 0x20, 0x6e, 0x61, - 0x6d, 0x65, 0x3d, 0x22, 0x75, 0x73, 0x65, 0x5f, - 0x75, 0x6e, 0x64, 0x65, 0x72, 0x6c, 0x69, 0x6e, - 0x65, 0x22, 0x3e, 0x54, 0x72, 0x75, 0x65, 0x3c, - 0x2f, 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, - 0x79, 0x3e, 0x3c, 0x73, 0x69, 0x67, 0x6e, 0x61, - 0x6c, 0x20, 0x6e, 0x61, 0x6d, 0x65, 0x3d, 0x22, - 0x63, 0x6c, 0x69, 0x63, 0x6b, 0x65, 0x64, 0x22, - 0x20, 0x68, 0x61, 0x6e, 0x64, 0x6c, 0x65, 0x72, - 0x3d, 0x22, 0x73, 0x61, 0x76, 0x65, 0x5f, 0x66, - 0x69, 0x6c, 0x65, 0x5f, 0x62, 0x75, 0x74, 0x74, - 0x6f, 0x6e, 0x5f, 0x63, 0x6c, 0x69, 0x63, 0x6b, - 0x65, 0x64, 0x5f, 0x63, 0x62, 0x22, 0x20, 0x73, - 0x77, 0x61, 0x70, 0x70, 0x65, 0x64, 0x3d, 0x22, - 0x6e, 0x6f, 0x22, 0x2f, 0x3e, 0x3c, 0x73, 0x74, - 0x79, 0x6c, 0x65, 0x3e, 0x3c, 0x63, 0x6c, 0x61, - 0x73, 0x73, 0x20, 0x6e, 0x61, 0x6d, 0x65, 0x3d, - 0x22, 0x69, 0x6d, 0x61, 0x67, 0x65, 0x2d, 0x62, - 0x75, 0x74, 0x74, 0x6f, 0x6e, 0x22, 0x2f, 0x3e, - 0x3c, 0x2f, 0x73, 0x74, 0x79, 0x6c, 0x65, 0x3e, - 0x3c, 0x63, 0x68, 0x69, 0x6c, 0x64, 0x3e, 0x3c, - 0x6f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x20, 0x63, - 0x6c, 0x61, 0x73, 0x73, 0x3d, 0x22, 0x47, 0x74, - 0x6b, 0x49, 0x6d, 0x61, 0x67, 0x65, 0x22, 0x20, - 0x69, 0x64, 0x3d, 0x22, 0x73, 0x61, 0x76, 0x65, - 0x5f, 0x69, 0x6d, 0x61, 0x67, 0x65, 0x22, 0x3e, - 0x3c, 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, - 0x79, 0x20, 0x6e, 0x61, 0x6d, 0x65, 0x3d, 0x22, - 0x76, 0x69, 0x73, 0x69, 0x62, 0x6c, 0x65, 0x22, - 0x3e, 0x54, 0x72, 0x75, 0x65, 0x3c, 0x2f, 0x70, - 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, 0x3e, - 0x3c, 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, - 0x79, 0x20, 0x6e, 0x61, 0x6d, 0x65, 0x3d, 0x22, - 0x69, 0x63, 0x6f, 0x6e, 0x5f, 0x73, 0x69, 0x7a, - 0x65, 0x22, 0x3e, 0x31, 0x3c, 0x2f, 0x70, 0x72, - 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, 0x3e, 0x3c, - 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, - 0x20, 0x6e, 0x61, 0x6d, 0x65, 0x3d, 0x22, 0x69, - 0x63, 0x6f, 0x6e, 0x5f, 0x6e, 0x61, 0x6d, 0x65, - 0x22, 0x3e, 0x64, 0x6f, 0x63, 0x75, 0x6d, 0x65, - 0x6e, 0x74, 0x2d, 0x73, 0x61, 0x76, 0x65, 0x2d, - 0x73, 0x79, 0x6d, 0x62, 0x6f, 0x6c, 0x69, 0x63, - 0x3c, 0x2f, 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, - 0x74, 0x79, 0x3e, 0x3c, 0x2f, 0x6f, 0x62, 0x6a, - 0x65, 0x63, 0x74, 0x3e, 0x3c, 0x2f, 0x63, 0x68, - 0x69, 0x6c, 0x64, 0x3e, 0x3c, 0x2f, 0x6f, 0x62, - 0x6a, 0x65, 0x63, 0x74, 0x3e, 0x3c, 0x70, 0x61, - 0x63, 0x6b, 0x69, 0x6e, 0x67, 0x3e, 0x0a, 0x20, - 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, - 0x20, 0x3c, 0x2f, 0x70, 0x61, 0x63, 0x6b, 0x69, - 0x6e, 0x67, 0x3e, 0x3c, 0x2f, 0x63, 0x68, 0x69, - 0x6c, 0x64, 0x3e, 0x3c, 0x63, 0x68, 0x69, 0x6c, - 0x64, 0x3e, 0x3c, 0x6f, 0x62, 0x6a, 0x65, 0x63, - 0x74, 0x20, 0x63, 0x6c, 0x61, 0x73, 0x73, 0x3d, - 0x22, 0x47, 0x74, 0x6b, 0x42, 0x75, 0x74, 0x74, - 0x6f, 0x6e, 0x22, 0x20, 0x69, 0x64, 0x3d, 0x22, - 0x6e, 0x65, 0x77, 0x5f, 0x62, 0x75, 0x74, 0x74, - 0x6f, 0x6e, 0x22, 0x3e, 0x3c, 0x70, 0x72, 0x6f, - 0x70, 0x65, 0x72, 0x74, 0x79, 0x20, 0x6e, 0x61, - 0x6d, 0x65, 0x3d, 0x22, 0x76, 0x69, 0x73, 0x69, - 0x62, 0x6c, 0x65, 0x22, 0x3e, 0x54, 0x72, 0x75, - 0x65, 0x3c, 0x2f, 0x70, 0x72, 0x6f, 0x70, 0x65, - 0x72, 0x74, 0x79, 0x3e, 0x3c, 0x70, 0x72, 0x6f, - 0x70, 0x65, 0x72, 0x74, 0x79, 0x20, 0x6e, 0x61, - 0x6d, 0x65, 0x3d, 0x22, 0x63, 0x61, 0x6e, 0x5f, - 0x66, 0x6f, 0x63, 0x75, 0x73, 0x22, 0x3e, 0x46, - 0x61, 0x6c, 0x73, 0x65, 0x3c, 0x2f, 0x70, 0x72, - 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, 0x3e, 0x3c, - 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, - 0x20, 0x6e, 0x61, 0x6d, 0x65, 0x3d, 0x22, 0x74, - 0x6f, 0x6f, 0x6c, 0x74, 0x69, 0x70, 0x5f, 0x74, - 0x65, 0x78, 0x74, 0x22, 0x20, 0x74, 0x72, 0x61, - 0x6e, 0x73, 0x6c, 0x61, 0x74, 0x61, 0x62, 0x6c, - 0x65, 0x3d, 0x22, 0x79, 0x65, 0x73, 0x22, 0x20, - 0x63, 0x6f, 0x6d, 0x6d, 0x65, 0x6e, 0x74, 0x73, - 0x3d, 0x22, 0x54, 0x6f, 0x6f, 0x6c, 0x74, 0x69, - 0x70, 0x20, 0x66, 0x6f, 0x72, 0x20, 0x6e, 0x65, - 0x77, 0x20, 0x64, 0x6f, 0x63, 0x75, 0x6d, 0x65, - 0x6e, 0x74, 0x20, 0x62, 0x75, 0x74, 0x74, 0x6f, - 0x6e, 0x22, 0x3e, 0x53, 0x74, 0x61, 0x72, 0x74, - 0x20, 0x61, 0x20, 0x6e, 0x65, 0x77, 0x20, 0x64, - 0x6f, 0x63, 0x75, 0x6d, 0x65, 0x6e, 0x74, 0x3c, - 0x2f, 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, - 0x79, 0x3e, 0x3c, 0x70, 0x72, 0x6f, 0x70, 0x65, - 0x72, 0x74, 0x79, 0x20, 0x6e, 0x61, 0x6d, 0x65, - 0x3d, 0x22, 0x75, 0x73, 0x65, 0x5f, 0x75, 0x6e, - 0x64, 0x65, 0x72, 0x6c, 0x69, 0x6e, 0x65, 0x22, - 0x3e, 0x54, 0x72, 0x75, 0x65, 0x3c, 0x2f, 0x70, - 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, 0x3e, - 0x3c, 0x73, 0x69, 0x67, 0x6e, 0x61, 0x6c, 0x20, - 0x6e, 0x61, 0x6d, 0x65, 0x3d, 0x22, 0x63, 0x6c, - 0x69, 0x63, 0x6b, 0x65, 0x64, 0x22, 0x20, 0x68, - 0x61, 0x6e, 0x64, 0x6c, 0x65, 0x72, 0x3d, 0x22, - 0x6e, 0x65, 0x77, 0x5f, 0x62, 0x75, 0x74, 0x74, - 0x6f, 0x6e, 0x5f, 0x63, 0x6c, 0x69, 0x63, 0x6b, - 0x65, 0x64, 0x5f, 0x63, 0x62, 0x22, 0x20, 0x73, - 0x77, 0x61, 0x70, 0x70, 0x65, 0x64, 0x3d, 0x22, - 0x6e, 0x6f, 0x22, 0x2f, 0x3e, 0x3c, 0x73, 0x74, - 0x79, 0x6c, 0x65, 0x3e, 0x3c, 0x63, 0x6c, 0x61, - 0x73, 0x73, 0x20, 0x6e, 0x61, 0x6d, 0x65, 0x3d, - 0x22, 0x69, 0x6d, 0x61, 0x67, 0x65, 0x2d, 0x62, - 0x75, 0x74, 0x74, 0x6f, 0x6e, 0x22, 0x2f, 0x3e, - 0x3c, 0x2f, 0x73, 0x74, 0x79, 0x6c, 0x65, 0x3e, - 0x3c, 0x63, 0x68, 0x69, 0x6c, 0x64, 0x3e, 0x3c, - 0x6f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x20, 0x63, - 0x6c, 0x61, 0x73, 0x73, 0x3d, 0x22, 0x47, 0x74, - 0x6b, 0x49, 0x6d, 0x61, 0x67, 0x65, 0x22, 0x20, - 0x69, 0x64, 0x3d, 0x22, 0x6e, 0x65, 0x77, 0x5f, - 0x69, 0x6d, 0x61, 0x67, 0x65, 0x22, 0x3e, 0x3c, - 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, - 0x20, 0x6e, 0x61, 0x6d, 0x65, 0x3d, 0x22, 0x76, - 0x69, 0x73, 0x69, 0x62, 0x6c, 0x65, 0x22, 0x3e, - 0x54, 0x72, 0x75, 0x65, 0x3c, 0x2f, 0x70, 0x72, - 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, 0x3e, 0x3c, - 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, - 0x20, 0x6e, 0x61, 0x6d, 0x65, 0x3d, 0x22, 0x69, - 0x63, 0x6f, 0x6e, 0x5f, 0x73, 0x69, 0x7a, 0x65, - 0x22, 0x3e, 0x31, 0x3c, 0x2f, 0x70, 0x72, 0x6f, - 0x70, 0x65, 0x72, 0x74, 0x79, 0x3e, 0x3c, 0x70, - 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, 0x20, - 0x6e, 0x61, 0x6d, 0x65, 0x3d, 0x22, 0x69, 0x63, - 0x6f, 0x6e, 0x5f, 0x6e, 0x61, 0x6d, 0x65, 0x22, - 0x3e, 0x64, 0x6f, 0x63, 0x75, 0x6d, 0x65, 0x6e, - 0x74, 0x2d, 0x6e, 0x65, 0x77, 0x2d, 0x73, 0x79, - 0x6d, 0x62, 0x6f, 0x6c, 0x69, 0x63, 0x3c, 0x2f, - 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, - 0x3e, 0x3c, 0x2f, 0x6f, 0x62, 0x6a, 0x65, 0x63, - 0x74, 0x3e, 0x3c, 0x2f, 0x63, 0x68, 0x69, 0x6c, - 0x64, 0x3e, 0x3c, 0x2f, 0x6f, 0x62, 0x6a, 0x65, - 0x63, 0x74, 0x3e, 0x3c, 0x70, 0x61, 0x63, 0x6b, - 0x69, 0x6e, 0x67, 0x3e, 0x0a, 0x20, 0x20, 0x20, - 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x3c, - 0x2f, 0x70, 0x61, 0x63, 0x6b, 0x69, 0x6e, 0x67, - 0x3e, 0x3c, 0x2f, 0x63, 0x68, 0x69, 0x6c, 0x64, - 0x3e, 0x3c, 0x63, 0x68, 0x69, 0x6c, 0x64, 0x3e, - 0x3c, 0x6f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x20, - 0x63, 0x6c, 0x61, 0x73, 0x73, 0x3d, 0x22, 0x47, - 0x74, 0x6b, 0x42, 0x6f, 0x78, 0x22, 0x20, 0x69, - 0x64, 0x3d, 0x22, 0x72, 0x6f, 0x74, 0x61, 0x74, - 0x65, 0x5f, 0x62, 0x6f, 0x78, 0x22, 0x3e, 0x3c, - 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, - 0x20, 0x6e, 0x61, 0x6d, 0x65, 0x3d, 0x22, 0x76, - 0x69, 0x73, 0x69, 0x62, 0x6c, 0x65, 0x22, 0x3e, - 0x54, 0x72, 0x75, 0x65, 0x3c, 0x2f, 0x70, 0x72, - 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, 0x3e, 0x3c, - 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, - 0x20, 0x6e, 0x61, 0x6d, 0x65, 0x3d, 0x22, 0x6f, - 0x72, 0x69, 0x65, 0x6e, 0x74, 0x61, 0x74, 0x69, - 0x6f, 0x6e, 0x22, 0x3e, 0x68, 0x6f, 0x72, 0x69, - 0x7a, 0x6f, 0x6e, 0x74, 0x61, 0x6c, 0x3c, 0x2f, - 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, - 0x3e, 0x3c, 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, - 0x74, 0x79, 0x20, 0x6e, 0x61, 0x6d, 0x65, 0x3d, - 0x22, 0x76, 0x61, 0x6c, 0x69, 0x67, 0x6e, 0x22, - 0x3e, 0x63, 0x65, 0x6e, 0x74, 0x65, 0x72, 0x3c, - 0x2f, 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, - 0x79, 0x3e, 0x3c, 0x73, 0x74, 0x79, 0x6c, 0x65, - 0x3e, 0x3c, 0x63, 0x6c, 0x61, 0x73, 0x73, 0x20, - 0x6e, 0x61, 0x6d, 0x65, 0x3d, 0x22, 0x6c, 0x69, - 0x6e, 0x6b, 0x65, 0x64, 0x22, 0x2f, 0x3e, 0x3c, - 0x2f, 0x73, 0x74, 0x79, 0x6c, 0x65, 0x3e, 0x3c, - 0x63, 0x68, 0x69, 0x6c, 0x64, 0x3e, 0x3c, 0x6f, - 0x62, 0x6a, 0x65, 0x63, 0x74, 0x20, 0x63, 0x6c, - 0x61, 0x73, 0x73, 0x3d, 0x22, 0x47, 0x74, 0x6b, - 0x42, 0x75, 0x74, 0x74, 0x6f, 0x6e, 0x22, 0x20, - 0x69, 0x64, 0x3d, 0x22, 0x72, 0x6f, 0x74, 0x61, - 0x74, 0x65, 0x5f, 0x72, 0x69, 0x67, 0x68, 0x74, - 0x5f, 0x62, 0x75, 0x74, 0x74, 0x6f, 0x6e, 0x22, - 0x3e, 0x3c, 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, - 0x74, 0x79, 0x20, 0x6e, 0x61, 0x6d, 0x65, 0x3d, - 0x22, 0x76, 0x69, 0x73, 0x69, 0x62, 0x6c, 0x65, - 0x22, 0x3e, 0x54, 0x72, 0x75, 0x65, 0x3c, 0x2f, - 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, - 0x3e, 0x3c, 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, - 0x74, 0x79, 0x20, 0x6e, 0x61, 0x6d, 0x65, 0x3d, - 0x22, 0x63, 0x61, 0x6e, 0x5f, 0x66, 0x6f, 0x63, - 0x75, 0x73, 0x22, 0x3e, 0x46, 0x61, 0x6c, 0x73, - 0x65, 0x3c, 0x2f, 0x70, 0x72, 0x6f, 0x70, 0x65, - 0x72, 0x74, 0x79, 0x3e, 0x3c, 0x70, 0x72, 0x6f, - 0x70, 0x65, 0x72, 0x74, 0x79, 0x20, 0x6e, 0x61, - 0x6d, 0x65, 0x3d, 0x22, 0x74, 0x6f, 0x6f, 0x6c, - 0x74, 0x69, 0x70, 0x5f, 0x74, 0x65, 0x78, 0x74, - 0x22, 0x20, 0x74, 0x72, 0x61, 0x6e, 0x73, 0x6c, - 0x61, 0x74, 0x61, 0x62, 0x6c, 0x65, 0x3d, 0x22, - 0x79, 0x65, 0x73, 0x22, 0x20, 0x63, 0x6f, 0x6d, - 0x6d, 0x65, 0x6e, 0x74, 0x73, 0x3d, 0x22, 0x54, - 0x6f, 0x6f, 0x6c, 0x74, 0x69, 0x70, 0x20, 0x66, - 0x6f, 0x72, 0x20, 0x72, 0x6f, 0x74, 0x61, 0x74, - 0x65, 0x20, 0x72, 0x69, 0x67, 0x68, 0x74, 0x20, - 0x28, 0x63, 0x6c, 0x6f, 0x63, 0x6b, 0x77, 0x69, - 0x73, 0x65, 0x29, 0x20, 0x62, 0x75, 0x74, 0x74, - 0x6f, 0x6e, 0x22, 0x3e, 0x52, 0x6f, 0x74, 0x61, - 0x74, 0x65, 0x20, 0x74, 0x68, 0x65, 0x20, 0x70, - 0x61, 0x67, 0x65, 0x20, 0x74, 0x6f, 0x20, 0x74, - 0x68, 0x65, 0x20, 0x72, 0x69, 0x67, 0x68, 0x74, - 0x20, 0x28, 0x63, 0x6c, 0x6f, 0x63, 0x6b, 0x77, - 0x69, 0x73, 0x65, 0x29, 0x3c, 0x2f, 0x70, 0x72, - 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, 0x3e, 0x3c, - 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, - 0x20, 0x6e, 0x61, 0x6d, 0x65, 0x3d, 0x22, 0x75, - 0x73, 0x65, 0x5f, 0x75, 0x6e, 0x64, 0x65, 0x72, - 0x6c, 0x69, 0x6e, 0x65, 0x22, 0x3e, 0x54, 0x72, - 0x75, 0x65, 0x3c, 0x2f, 0x70, 0x72, 0x6f, 0x70, - 0x65, 0x72, 0x74, 0x79, 0x3e, 0x3c, 0x73, 0x69, - 0x67, 0x6e, 0x61, 0x6c, 0x20, 0x6e, 0x61, 0x6d, - 0x65, 0x3d, 0x22, 0x63, 0x6c, 0x69, 0x63, 0x6b, - 0x65, 0x64, 0x22, 0x20, 0x68, 0x61, 0x6e, 0x64, - 0x6c, 0x65, 0x72, 0x3d, 0x22, 0x72, 0x6f, 0x74, - 0x61, 0x74, 0x65, 0x5f, 0x72, 0x69, 0x67, 0x68, - 0x74, 0x5f, 0x62, 0x75, 0x74, 0x74, 0x6f, 0x6e, - 0x5f, 0x63, 0x6c, 0x69, 0x63, 0x6b, 0x65, 0x64, - 0x5f, 0x63, 0x62, 0x22, 0x20, 0x73, 0x77, 0x61, - 0x70, 0x70, 0x65, 0x64, 0x3d, 0x22, 0x6e, 0x6f, - 0x22, 0x2f, 0x3e, 0x3c, 0x73, 0x74, 0x79, 0x6c, - 0x65, 0x3e, 0x3c, 0x63, 0x6c, 0x61, 0x73, 0x73, - 0x20, 0x6e, 0x61, 0x6d, 0x65, 0x3d, 0x22, 0x69, - 0x6d, 0x61, 0x67, 0x65, 0x2d, 0x62, 0x75, 0x74, - 0x74, 0x6f, 0x6e, 0x22, 0x2f, 0x3e, 0x3c, 0x2f, - 0x73, 0x74, 0x79, 0x6c, 0x65, 0x3e, 0x3c, 0x63, - 0x68, 0x69, 0x6c, 0x64, 0x3e, 0x3c, 0x6f, 0x62, - 0x6a, 0x65, 0x63, 0x74, 0x20, 0x63, 0x6c, 0x61, - 0x73, 0x73, 0x3d, 0x22, 0x47, 0x74, 0x6b, 0x49, - 0x6d, 0x61, 0x67, 0x65, 0x22, 0x20, 0x69, 0x64, - 0x3d, 0x22, 0x6f, 0x62, 0x6a, 0x65, 0x63, 0x74, - 0x72, 0x6f, 0x74, 0x61, 0x74, 0x65, 0x72, 0x69, - 0x67, 0x68, 0x74, 0x2d, 0x62, 0x75, 0x74, 0x74, - 0x6f, 0x6e, 0x22, 0x3e, 0x3c, 0x70, 0x72, 0x6f, - 0x70, 0x65, 0x72, 0x74, 0x79, 0x20, 0x6e, 0x61, - 0x6d, 0x65, 0x3d, 0x22, 0x76, 0x69, 0x73, 0x69, - 0x62, 0x6c, 0x65, 0x22, 0x3e, 0x54, 0x72, 0x75, - 0x65, 0x3c, 0x2f, 0x70, 0x72, 0x6f, 0x70, 0x65, - 0x72, 0x74, 0x79, 0x3e, 0x3c, 0x70, 0x72, 0x6f, - 0x70, 0x65, 0x72, 0x74, 0x79, 0x20, 0x6e, 0x61, - 0x6d, 0x65, 0x3d, 0x22, 0x69, 0x63, 0x6f, 0x6e, - 0x5f, 0x73, 0x69, 0x7a, 0x65, 0x22, 0x3e, 0x31, - 0x3c, 0x2f, 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, - 0x74, 0x79, 0x3e, 0x3c, 0x70, 0x72, 0x6f, 0x70, - 0x65, 0x72, 0x74, 0x79, 0x20, 0x6e, 0x61, 0x6d, - 0x65, 0x3d, 0x22, 0x69, 0x63, 0x6f, 0x6e, 0x5f, - 0x6e, 0x61, 0x6d, 0x65, 0x22, 0x3e, 0x6f, 0x62, - 0x6a, 0x65, 0x63, 0x74, 0x2d, 0x72, 0x6f, 0x74, - 0x61, 0x74, 0x65, 0x2d, 0x72, 0x69, 0x67, 0x68, - 0x74, 0x2d, 0x73, 0x79, 0x6d, 0x62, 0x6f, 0x6c, - 0x69, 0x63, 0x3c, 0x2f, 0x70, 0x72, 0x6f, 0x70, - 0x65, 0x72, 0x74, 0x79, 0x3e, 0x3c, 0x2f, 0x6f, - 0x62, 0x6a, 0x65, 0x63, 0x74, 0x3e, 0x3c, 0x2f, - 0x63, 0x68, 0x69, 0x6c, 0x64, 0x3e, 0x3c, 0x2f, - 0x6f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x3e, 0x3c, - 0x70, 0x61, 0x63, 0x6b, 0x69, 0x6e, 0x67, 0x3e, - 0x3c, 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, - 0x79, 0x20, 0x6e, 0x61, 0x6d, 0x65, 0x3d, 0x22, - 0x70, 0x61, 0x63, 0x6b, 0x5f, 0x74, 0x79, 0x70, - 0x65, 0x22, 0x3e, 0x65, 0x6e, 0x64, 0x3c, 0x2f, - 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, - 0x3e, 0x3c, 0x2f, 0x70, 0x61, 0x63, 0x6b, 0x69, - 0x6e, 0x67, 0x3e, 0x3c, 0x2f, 0x63, 0x68, 0x69, - 0x6c, 0x64, 0x3e, 0x3c, 0x63, 0x68, 0x69, 0x6c, - 0x64, 0x3e, 0x3c, 0x6f, 0x62, 0x6a, 0x65, 0x63, - 0x74, 0x20, 0x63, 0x6c, 0x61, 0x73, 0x73, 0x3d, - 0x22, 0x47, 0x74, 0x6b, 0x42, 0x75, 0x74, 0x74, - 0x6f, 0x6e, 0x22, 0x20, 0x69, 0x64, 0x3d, 0x22, - 0x72, 0x6f, 0x74, 0x61, 0x74, 0x65, 0x5f, 0x6c, - 0x65, 0x66, 0x74, 0x5f, 0x62, 0x75, 0x74, 0x74, - 0x6f, 0x6e, 0x22, 0x3e, 0x3c, 0x70, 0x72, 0x6f, - 0x70, 0x65, 0x72, 0x74, 0x79, 0x20, 0x6e, 0x61, - 0x6d, 0x65, 0x3d, 0x22, 0x76, 0x69, 0x73, 0x69, - 0x62, 0x6c, 0x65, 0x22, 0x3e, 0x54, 0x72, 0x75, - 0x65, 0x3c, 0x2f, 0x70, 0x72, 0x6f, 0x70, 0x65, - 0x72, 0x74, 0x79, 0x3e, 0x3c, 0x70, 0x72, 0x6f, - 0x70, 0x65, 0x72, 0x74, 0x79, 0x20, 0x6e, 0x61, - 0x6d, 0x65, 0x3d, 0x22, 0x63, 0x61, 0x6e, 0x5f, - 0x66, 0x6f, 0x63, 0x75, 0x73, 0x22, 0x3e, 0x46, - 0x61, 0x6c, 0x73, 0x65, 0x3c, 0x2f, 0x70, 0x72, - 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, 0x3e, 0x3c, - 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, - 0x20, 0x6e, 0x61, 0x6d, 0x65, 0x3d, 0x22, 0x74, - 0x6f, 0x6f, 0x6c, 0x74, 0x69, 0x70, 0x5f, 0x74, - 0x65, 0x78, 0x74, 0x22, 0x20, 0x74, 0x72, 0x61, - 0x6e, 0x73, 0x6c, 0x61, 0x74, 0x61, 0x62, 0x6c, - 0x65, 0x3d, 0x22, 0x79, 0x65, 0x73, 0x22, 0x20, - 0x63, 0x6f, 0x6d, 0x6d, 0x65, 0x6e, 0x74, 0x73, - 0x3d, 0x22, 0x54, 0x6f, 0x6f, 0x6c, 0x74, 0x69, - 0x70, 0x20, 0x66, 0x6f, 0x72, 0x20, 0x72, 0x6f, - 0x74, 0x61, 0x74, 0x65, 0x20, 0x6c, 0x65, 0x66, - 0x74, 0x20, 0x28, 0x63, 0x6f, 0x75, 0x6e, 0x74, - 0x65, 0x72, 0x2d, 0x63, 0x6c, 0x6f, 0x63, 0x6b, - 0x77, 0x69, 0x73, 0x65, 0x29, 0x20, 0x62, 0x75, - 0x74, 0x74, 0x6f, 0x6e, 0x22, 0x3e, 0x52, 0x6f, - 0x74, 0x61, 0x74, 0x65, 0x20, 0x74, 0x68, 0x65, - 0x20, 0x70, 0x61, 0x67, 0x65, 0x20, 0x74, 0x6f, - 0x20, 0x74, 0x68, 0x65, 0x20, 0x6c, 0x65, 0x66, - 0x74, 0x20, 0x28, 0x63, 0x6f, 0x75, 0x6e, 0x74, - 0x65, 0x72, 0x2d, 0x63, 0x6c, 0x6f, 0x63, 0x6b, - 0x77, 0x69, 0x73, 0x65, 0x29, 0x3c, 0x2f, 0x70, - 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, 0x3e, - 0x3c, 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, - 0x79, 0x20, 0x6e, 0x61, 0x6d, 0x65, 0x3d, 0x22, - 0x75, 0x73, 0x65, 0x5f, 0x75, 0x6e, 0x64, 0x65, - 0x72, 0x6c, 0x69, 0x6e, 0x65, 0x22, 0x3e, 0x54, - 0x72, 0x75, 0x65, 0x3c, 0x2f, 0x70, 0x72, 0x6f, - 0x70, 0x65, 0x72, 0x74, 0x79, 0x3e, 0x3c, 0x73, - 0x69, 0x67, 0x6e, 0x61, 0x6c, 0x20, 0x6e, 0x61, - 0x6d, 0x65, 0x3d, 0x22, 0x63, 0x6c, 0x69, 0x63, - 0x6b, 0x65, 0x64, 0x22, 0x20, 0x68, 0x61, 0x6e, - 0x64, 0x6c, 0x65, 0x72, 0x3d, 0x22, 0x72, 0x6f, - 0x74, 0x61, 0x74, 0x65, 0x5f, 0x6c, 0x65, 0x66, - 0x74, 0x5f, 0x62, 0x75, 0x74, 0x74, 0x6f, 0x6e, - 0x5f, 0x63, 0x6c, 0x69, 0x63, 0x6b, 0x65, 0x64, - 0x5f, 0x63, 0x62, 0x22, 0x20, 0x73, 0x77, 0x61, - 0x70, 0x70, 0x65, 0x64, 0x3d, 0x22, 0x6e, 0x6f, - 0x22, 0x2f, 0x3e, 0x3c, 0x73, 0x74, 0x79, 0x6c, - 0x65, 0x3e, 0x3c, 0x63, 0x6c, 0x61, 0x73, 0x73, - 0x20, 0x6e, 0x61, 0x6d, 0x65, 0x3d, 0x22, 0x69, - 0x6d, 0x61, 0x67, 0x65, 0x2d, 0x62, 0x75, 0x74, - 0x74, 0x6f, 0x6e, 0x22, 0x2f, 0x3e, 0x3c, 0x2f, - 0x73, 0x74, 0x79, 0x6c, 0x65, 0x3e, 0x3c, 0x63, - 0x68, 0x69, 0x6c, 0x64, 0x3e, 0x3c, 0x6f, 0x62, - 0x6a, 0x65, 0x63, 0x74, 0x20, 0x63, 0x6c, 0x61, - 0x73, 0x73, 0x3d, 0x22, 0x47, 0x74, 0x6b, 0x49, - 0x6d, 0x61, 0x67, 0x65, 0x22, 0x20, 0x69, 0x64, - 0x3d, 0x22, 0x6f, 0x62, 0x6a, 0x65, 0x63, 0x74, - 0x72, 0x6f, 0x74, 0x61, 0x74, 0x65, 0x6c, 0x65, - 0x66, 0x74, 0x2d, 0x62, 0x75, 0x74, 0x74, 0x6f, - 0x6e, 0x22, 0x3e, 0x3c, 0x70, 0x72, 0x6f, 0x70, - 0x65, 0x72, 0x74, 0x79, 0x20, 0x6e, 0x61, 0x6d, - 0x65, 0x3d, 0x22, 0x76, 0x69, 0x73, 0x69, 0x62, - 0x6c, 0x65, 0x22, 0x3e, 0x54, 0x72, 0x75, 0x65, - 0x3c, 0x2f, 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, - 0x74, 0x79, 0x3e, 0x3c, 0x70, 0x72, 0x6f, 0x70, - 0x65, 0x72, 0x74, 0x79, 0x20, 0x6e, 0x61, 0x6d, - 0x65, 0x3d, 0x22, 0x69, 0x63, 0x6f, 0x6e, 0x5f, - 0x73, 0x69, 0x7a, 0x65, 0x22, 0x3e, 0x31, 0x3c, - 0x2f, 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, - 0x79, 0x3e, 0x3c, 0x70, 0x72, 0x6f, 0x70, 0x65, - 0x72, 0x74, 0x79, 0x20, 0x6e, 0x61, 0x6d, 0x65, - 0x3d, 0x22, 0x69, 0x63, 0x6f, 0x6e, 0x5f, 0x6e, - 0x61, 0x6d, 0x65, 0x22, 0x3e, 0x6f, 0x62, 0x6a, - 0x65, 0x63, 0x74, 0x2d, 0x72, 0x6f, 0x74, 0x61, - 0x74, 0x65, 0x2d, 0x6c, 0x65, 0x66, 0x74, 0x2d, - 0x73, 0x79, 0x6d, 0x62, 0x6f, 0x6c, 0x69, 0x63, - 0x3c, 0x2f, 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, - 0x74, 0x79, 0x3e, 0x3c, 0x2f, 0x6f, 0x62, 0x6a, - 0x65, 0x63, 0x74, 0x3e, 0x3c, 0x2f, 0x63, 0x68, - 0x69, 0x6c, 0x64, 0x3e, 0x3c, 0x2f, 0x6f, 0x62, - 0x6a, 0x65, 0x63, 0x74, 0x3e, 0x3c, 0x70, 0x61, - 0x63, 0x6b, 0x69, 0x6e, 0x67, 0x3e, 0x3c, 0x70, - 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, 0x20, - 0x6e, 0x61, 0x6d, 0x65, 0x3d, 0x22, 0x70, 0x61, - 0x63, 0x6b, 0x5f, 0x74, 0x79, 0x70, 0x65, 0x22, - 0x3e, 0x65, 0x6e, 0x64, 0x3c, 0x2f, 0x70, 0x72, - 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, 0x3e, 0x3c, - 0x2f, 0x70, 0x61, 0x63, 0x6b, 0x69, 0x6e, 0x67, - 0x3e, 0x3c, 0x2f, 0x63, 0x68, 0x69, 0x6c, 0x64, - 0x3e, 0x3c, 0x2f, 0x6f, 0x62, 0x6a, 0x65, 0x63, - 0x74, 0x3e, 0x3c, 0x70, 0x61, 0x63, 0x6b, 0x69, - 0x6e, 0x67, 0x3e, 0x3c, 0x70, 0x72, 0x6f, 0x70, - 0x65, 0x72, 0x74, 0x79, 0x20, 0x6e, 0x61, 0x6d, - 0x65, 0x3d, 0x22, 0x70, 0x61, 0x63, 0x6b, 0x5f, - 0x74, 0x79, 0x70, 0x65, 0x22, 0x3e, 0x65, 0x6e, - 0x64, 0x3c, 0x2f, 0x70, 0x72, 0x6f, 0x70, 0x65, - 0x72, 0x74, 0x79, 0x3e, 0x3c, 0x2f, 0x70, 0x61, - 0x63, 0x6b, 0x69, 0x6e, 0x67, 0x3e, 0x3c, 0x2f, - 0x63, 0x68, 0x69, 0x6c, 0x64, 0x3e, 0x3c, 0x63, - 0x68, 0x69, 0x6c, 0x64, 0x3e, 0x3c, 0x6f, 0x62, - 0x6a, 0x65, 0x63, 0x74, 0x20, 0x63, 0x6c, 0x61, - 0x73, 0x73, 0x3d, 0x22, 0x47, 0x74, 0x6b, 0x54, - 0x6f, 0x67, 0x67, 0x6c, 0x65, 0x42, 0x75, 0x74, - 0x74, 0x6f, 0x6e, 0x22, 0x20, 0x69, 0x64, 0x3d, - 0x22, 0x63, 0x72, 0x6f, 0x70, 0x5f, 0x62, 0x75, - 0x74, 0x74, 0x6f, 0x6e, 0x22, 0x3e, 0x3c, 0x70, - 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, 0x20, - 0x6e, 0x61, 0x6d, 0x65, 0x3d, 0x22, 0x76, 0x69, - 0x73, 0x69, 0x62, 0x6c, 0x65, 0x22, 0x3e, 0x54, - 0x72, 0x75, 0x65, 0x3c, 0x2f, 0x70, 0x72, 0x6f, - 0x70, 0x65, 0x72, 0x74, 0x79, 0x3e, 0x3c, 0x70, - 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, 0x20, - 0x6e, 0x61, 0x6d, 0x65, 0x3d, 0x22, 0x63, 0x61, - 0x6e, 0x5f, 0x66, 0x6f, 0x63, 0x75, 0x73, 0x22, - 0x3e, 0x46, 0x61, 0x6c, 0x73, 0x65, 0x3c, 0x2f, - 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, - 0x3e, 0x3c, 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, - 0x74, 0x79, 0x20, 0x6e, 0x61, 0x6d, 0x65, 0x3d, - 0x22, 0x74, 0x6f, 0x6f, 0x6c, 0x74, 0x69, 0x70, - 0x5f, 0x74, 0x65, 0x78, 0x74, 0x22, 0x20, 0x74, - 0x72, 0x61, 0x6e, 0x73, 0x6c, 0x61, 0x74, 0x61, - 0x62, 0x6c, 0x65, 0x3d, 0x22, 0x79, 0x65, 0x73, - 0x22, 0x3e, 0x43, 0x72, 0x6f, 0x70, 0x20, 0x74, - 0x68, 0x65, 0x20, 0x73, 0x65, 0x6c, 0x65, 0x63, - 0x74, 0x65, 0x64, 0x20, 0x70, 0x61, 0x67, 0x65, - 0x3c, 0x2f, 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, - 0x74, 0x79, 0x3e, 0x3c, 0x70, 0x72, 0x6f, 0x70, - 0x65, 0x72, 0x74, 0x79, 0x20, 0x6e, 0x61, 0x6d, - 0x65, 0x3d, 0x22, 0x75, 0x73, 0x65, 0x5f, 0x75, - 0x6e, 0x64, 0x65, 0x72, 0x6c, 0x69, 0x6e, 0x65, - 0x22, 0x3e, 0x54, 0x72, 0x75, 0x65, 0x3c, 0x2f, - 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, - 0x3e, 0x3c, 0x73, 0x69, 0x67, 0x6e, 0x61, 0x6c, - 0x20, 0x6e, 0x61, 0x6d, 0x65, 0x3d, 0x22, 0x74, - 0x6f, 0x67, 0x67, 0x6c, 0x65, 0x64, 0x22, 0x20, - 0x68, 0x61, 0x6e, 0x64, 0x6c, 0x65, 0x72, 0x3d, - 0x22, 0x63, 0x72, 0x6f, 0x70, 0x5f, 0x62, 0x75, - 0x74, 0x74, 0x6f, 0x6e, 0x5f, 0x74, 0x6f, 0x67, - 0x67, 0x6c, 0x65, 0x64, 0x5f, 0x63, 0x62, 0x22, - 0x20, 0x73, 0x77, 0x61, 0x70, 0x70, 0x65, 0x64, - 0x3d, 0x22, 0x6e, 0x6f, 0x22, 0x2f, 0x3e, 0x3c, - 0x73, 0x74, 0x79, 0x6c, 0x65, 0x3e, 0x3c, 0x63, - 0x6c, 0x61, 0x73, 0x73, 0x20, 0x6e, 0x61, 0x6d, - 0x65, 0x3d, 0x22, 0x69, 0x6d, 0x61, 0x67, 0x65, - 0x2d, 0x62, 0x75, 0x74, 0x74, 0x6f, 0x6e, 0x22, - 0x2f, 0x3e, 0x3c, 0x2f, 0x73, 0x74, 0x79, 0x6c, - 0x65, 0x3e, 0x3c, 0x63, 0x68, 0x69, 0x6c, 0x64, - 0x3e, 0x3c, 0x6f, 0x62, 0x6a, 0x65, 0x63, 0x74, - 0x20, 0x63, 0x6c, 0x61, 0x73, 0x73, 0x3d, 0x22, - 0x47, 0x74, 0x6b, 0x49, 0x6d, 0x61, 0x67, 0x65, - 0x22, 0x20, 0x69, 0x64, 0x3d, 0x22, 0x6f, 0x62, - 0x6a, 0x65, 0x63, 0x74, 0x63, 0x72, 0x6f, 0x70, - 0x2d, 0x62, 0x75, 0x74, 0x74, 0x6f, 0x6e, 0x22, - 0x3e, 0x3c, 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, - 0x74, 0x79, 0x20, 0x6e, 0x61, 0x6d, 0x65, 0x3d, - 0x22, 0x76, 0x69, 0x73, 0x69, 0x62, 0x6c, 0x65, - 0x22, 0x3e, 0x54, 0x72, 0x75, 0x65, 0x3c, 0x2f, - 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, - 0x3e, 0x3c, 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, - 0x74, 0x79, 0x20, 0x6e, 0x61, 0x6d, 0x65, 0x3d, - 0x22, 0x69, 0x63, 0x6f, 0x6e, 0x5f, 0x73, 0x69, - 0x7a, 0x65, 0x22, 0x3e, 0x31, 0x3c, 0x2f, 0x70, - 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, 0x3e, - 0x3c, 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, - 0x79, 0x20, 0x6e, 0x61, 0x6d, 0x65, 0x3d, 0x22, - 0x69, 0x63, 0x6f, 0x6e, 0x5f, 0x6e, 0x61, 0x6d, - 0x65, 0x22, 0x3e, 0x65, 0x64, 0x69, 0x74, 0x2d, - 0x63, 0x75, 0x74, 0x2d, 0x73, 0x79, 0x6d, 0x62, - 0x6f, 0x6c, 0x69, 0x63, 0x3c, 0x2f, 0x70, 0x72, - 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, 0x3e, 0x3c, - 0x2f, 0x6f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x3e, - 0x3c, 0x2f, 0x63, 0x68, 0x69, 0x6c, 0x64, 0x3e, - 0x3c, 0x2f, 0x6f, 0x62, 0x6a, 0x65, 0x63, 0x74, - 0x3e, 0x3c, 0x70, 0x61, 0x63, 0x6b, 0x69, 0x6e, - 0x67, 0x3e, 0x3c, 0x70, 0x72, 0x6f, 0x70, 0x65, - 0x72, 0x74, 0x79, 0x20, 0x6e, 0x61, 0x6d, 0x65, - 0x3d, 0x22, 0x70, 0x61, 0x63, 0x6b, 0x5f, 0x74, - 0x79, 0x70, 0x65, 0x22, 0x3e, 0x65, 0x6e, 0x64, - 0x3c, 0x2f, 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, - 0x74, 0x79, 0x3e, 0x3c, 0x2f, 0x70, 0x61, 0x63, - 0x6b, 0x69, 0x6e, 0x67, 0x3e, 0x3c, 0x2f, 0x63, - 0x68, 0x69, 0x6c, 0x64, 0x3e, 0x3c, 0x2f, 0x6f, - 0x62, 0x6a, 0x65, 0x63, 0x74, 0x3e, 0x3c, 0x70, - 0x61, 0x63, 0x6b, 0x69, 0x6e, 0x67, 0x3e, 0x0a, - 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x3c, 0x2f, - 0x70, 0x61, 0x63, 0x6b, 0x69, 0x6e, 0x67, 0x3e, - 0x3c, 0x2f, 0x63, 0x68, 0x69, 0x6c, 0x64, 0x3e, - 0x3c, 0x2f, 0x74, 0x65, 0x6d, 0x70, 0x6c, 0x61, - 0x74, 0x65, 0x3e, 0x3c, 0x6f, 0x62, 0x6a, 0x65, - 0x63, 0x74, 0x20, 0x63, 0x6c, 0x61, 0x73, 0x73, - 0x3d, 0x22, 0x47, 0x74, 0x6b, 0x4c, 0x69, 0x73, - 0x74, 0x53, 0x74, 0x6f, 0x72, 0x65, 0x22, 0x20, - 0x69, 0x64, 0x3d, 0x22, 0x74, 0x65, 0x78, 0x74, - 0x5f, 0x64, 0x70, 0x69, 0x5f, 0x6d, 0x6f, 0x64, - 0x65, 0x6c, 0x22, 0x3e, 0x3c, 0x63, 0x6f, 0x6c, - 0x75, 0x6d, 0x6e, 0x73, 0x3e, 0x3c, 0x21, 0x2d, - 0x2d, 0x20, 0x63, 0x6f, 0x6c, 0x75, 0x6d, 0x6e, - 0x2d, 0x6e, 0x61, 0x6d, 0x65, 0x20, 0x64, 0x70, - 0x69, 0x20, 0x2d, 0x2d, 0x3e, 0x3c, 0x63, 0x6f, - 0x6c, 0x75, 0x6d, 0x6e, 0x20, 0x74, 0x79, 0x70, - 0x65, 0x3d, 0x22, 0x67, 0x69, 0x6e, 0x74, 0x22, - 0x2f, 0x3e, 0x3c, 0x21, 0x2d, 0x2d, 0x20, 0x63, - 0x6f, 0x6c, 0x75, 0x6d, 0x6e, 0x2d, 0x6e, 0x61, - 0x6d, 0x65, 0x20, 0x6c, 0x61, 0x62, 0x65, 0x6c, - 0x20, 0x2d, 0x2d, 0x3e, 0x3c, 0x63, 0x6f, 0x6c, - 0x75, 0x6d, 0x6e, 0x20, 0x74, 0x79, 0x70, 0x65, - 0x3d, 0x22, 0x67, 0x63, 0x68, 0x61, 0x72, 0x61, - 0x72, 0x72, 0x61, 0x79, 0x22, 0x2f, 0x3e, 0x3c, - 0x2f, 0x63, 0x6f, 0x6c, 0x75, 0x6d, 0x6e, 0x73, - 0x3e, 0x3c, 0x2f, 0x6f, 0x62, 0x6a, 0x65, 0x63, - 0x74, 0x3e, 0x3c, 0x6f, 0x62, 0x6a, 0x65, 0x63, - 0x74, 0x20, 0x63, 0x6c, 0x61, 0x73, 0x73, 0x3d, - 0x22, 0x47, 0x74, 0x6b, 0x44, 0x69, 0x61, 0x6c, - 0x6f, 0x67, 0x22, 0x20, 0x69, 0x64, 0x3d, 0x22, - 0x70, 0x72, 0x65, 0x66, 0x65, 0x72, 0x65, 0x6e, - 0x63, 0x65, 0x73, 0x5f, 0x64, 0x69, 0x61, 0x6c, - 0x6f, 0x67, 0x22, 0x3e, 0x3c, 0x70, 0x72, 0x6f, - 0x70, 0x65, 0x72, 0x74, 0x79, 0x20, 0x6e, 0x61, - 0x6d, 0x65, 0x3d, 0x22, 0x63, 0x61, 0x6e, 0x5f, - 0x66, 0x6f, 0x63, 0x75, 0x73, 0x22, 0x3e, 0x46, - 0x61, 0x6c, 0x73, 0x65, 0x3c, 0x2f, 0x70, 0x72, - 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, 0x3e, 0x3c, - 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, - 0x20, 0x6e, 0x61, 0x6d, 0x65, 0x3d, 0x22, 0x62, - 0x6f, 0x72, 0x64, 0x65, 0x72, 0x5f, 0x77, 0x69, - 0x64, 0x74, 0x68, 0x22, 0x3e, 0x37, 0x3c, 0x2f, - 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, - 0x3e, 0x3c, 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, - 0x74, 0x79, 0x20, 0x6e, 0x61, 0x6d, 0x65, 0x3d, - 0x22, 0x74, 0x69, 0x74, 0x6c, 0x65, 0x22, 0x20, - 0x74, 0x72, 0x61, 0x6e, 0x73, 0x6c, 0x61, 0x74, - 0x61, 0x62, 0x6c, 0x65, 0x3d, 0x22, 0x79, 0x65, - 0x73, 0x22, 0x20, 0x63, 0x6f, 0x6d, 0x6d, 0x65, - 0x6e, 0x74, 0x73, 0x3d, 0x22, 0x54, 0x69, 0x74, - 0x6c, 0x65, 0x20, 0x6f, 0x66, 0x20, 0x70, 0x72, - 0x65, 0x66, 0x65, 0x72, 0x65, 0x6e, 0x63, 0x65, - 0x73, 0x20, 0x64, 0x69, 0x61, 0x6c, 0x6f, 0x67, - 0x22, 0x3e, 0x50, 0x72, 0x65, 0x66, 0x65, 0x72, - 0x65, 0x6e, 0x63, 0x65, 0x73, 0x3c, 0x2f, 0x70, - 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, 0x3e, - 0x3c, 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, - 0x79, 0x20, 0x6e, 0x61, 0x6d, 0x65, 0x3d, 0x22, - 0x72, 0x65, 0x73, 0x69, 0x7a, 0x61, 0x62, 0x6c, - 0x65, 0x22, 0x3e, 0x46, 0x61, 0x6c, 0x73, 0x65, - 0x3c, 0x2f, 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, - 0x74, 0x79, 0x3e, 0x3c, 0x70, 0x72, 0x6f, 0x70, - 0x65, 0x72, 0x74, 0x79, 0x20, 0x6e, 0x61, 0x6d, - 0x65, 0x3d, 0x22, 0x69, 0x63, 0x6f, 0x6e, 0x5f, - 0x6e, 0x61, 0x6d, 0x65, 0x22, 0x3e, 0x73, 0x63, - 0x61, 0x6e, 0x6e, 0x65, 0x72, 0x3c, 0x2f, 0x70, - 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, 0x3e, - 0x3c, 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, - 0x79, 0x20, 0x6e, 0x61, 0x6d, 0x65, 0x3d, 0x22, - 0x74, 0x79, 0x70, 0x65, 0x5f, 0x68, 0x69, 0x6e, - 0x74, 0x22, 0x3e, 0x6e, 0x6f, 0x72, 0x6d, 0x61, - 0x6c, 0x3c, 0x2f, 0x70, 0x72, 0x6f, 0x70, 0x65, - 0x72, 0x74, 0x79, 0x3e, 0x3c, 0x73, 0x69, 0x67, - 0x6e, 0x61, 0x6c, 0x20, 0x6e, 0x61, 0x6d, 0x65, - 0x3d, 0x22, 0x64, 0x65, 0x6c, 0x65, 0x74, 0x65, - 0x2d, 0x65, 0x76, 0x65, 0x6e, 0x74, 0x22, 0x20, - 0x68, 0x61, 0x6e, 0x64, 0x6c, 0x65, 0x72, 0x3d, - 0x22, 0x70, 0x72, 0x65, 0x66, 0x65, 0x72, 0x65, - 0x6e, 0x63, 0x65, 0x73, 0x5f, 0x64, 0x69, 0x61, - 0x6c, 0x6f, 0x67, 0x5f, 0x64, 0x65, 0x6c, 0x65, - 0x74, 0x65, 0x5f, 0x65, 0x76, 0x65, 0x6e, 0x74, - 0x5f, 0x63, 0x62, 0x22, 0x20, 0x73, 0x77, 0x61, - 0x70, 0x70, 0x65, 0x64, 0x3d, 0x22, 0x6e, 0x6f, - 0x22, 0x2f, 0x3e, 0x3c, 0x73, 0x69, 0x67, 0x6e, - 0x61, 0x6c, 0x20, 0x6e, 0x61, 0x6d, 0x65, 0x3d, - 0x22, 0x72, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, - 0x65, 0x22, 0x20, 0x68, 0x61, 0x6e, 0x64, 0x6c, - 0x65, 0x72, 0x3d, 0x22, 0x70, 0x72, 0x65, 0x66, - 0x65, 0x72, 0x65, 0x6e, 0x63, 0x65, 0x73, 0x5f, - 0x64, 0x69, 0x61, 0x6c, 0x6f, 0x67, 0x5f, 0x72, - 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x5f, - 0x63, 0x62, 0x22, 0x20, 0x73, 0x77, 0x61, 0x70, - 0x70, 0x65, 0x64, 0x3d, 0x22, 0x6e, 0x6f, 0x22, - 0x2f, 0x3e, 0x3c, 0x63, 0x68, 0x69, 0x6c, 0x64, - 0x20, 0x69, 0x6e, 0x74, 0x65, 0x72, 0x6e, 0x61, - 0x6c, 0x2d, 0x63, 0x68, 0x69, 0x6c, 0x64, 0x3d, - 0x22, 0x76, 0x62, 0x6f, 0x78, 0x22, 0x3e, 0x3c, - 0x6f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x20, 0x63, - 0x6c, 0x61, 0x73, 0x73, 0x3d, 0x22, 0x47, 0x74, - 0x6b, 0x42, 0x6f, 0x78, 0x22, 0x20, 0x69, 0x64, - 0x3d, 0x22, 0x64, 0x69, 0x61, 0x6c, 0x6f, 0x67, - 0x2d, 0x76, 0x62, 0x6f, 0x78, 0x32, 0x22, 0x3e, - 0x3c, 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, - 0x79, 0x20, 0x6e, 0x61, 0x6d, 0x65, 0x3d, 0x22, - 0x76, 0x69, 0x73, 0x69, 0x62, 0x6c, 0x65, 0x22, - 0x3e, 0x54, 0x72, 0x75, 0x65, 0x3c, 0x2f, 0x70, - 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, 0x3e, - 0x3c, 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, - 0x79, 0x20, 0x6e, 0x61, 0x6d, 0x65, 0x3d, 0x22, - 0x63, 0x61, 0x6e, 0x5f, 0x66, 0x6f, 0x63, 0x75, - 0x73, 0x22, 0x3e, 0x46, 0x61, 0x6c, 0x73, 0x65, - 0x3c, 0x2f, 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, - 0x74, 0x79, 0x3e, 0x3c, 0x70, 0x72, 0x6f, 0x70, - 0x65, 0x72, 0x74, 0x79, 0x20, 0x6e, 0x61, 0x6d, - 0x65, 0x3d, 0x22, 0x6f, 0x72, 0x69, 0x65, 0x6e, - 0x74, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x22, 0x3e, - 0x76, 0x65, 0x72, 0x74, 0x69, 0x63, 0x61, 0x6c, - 0x3c, 0x2f, 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, - 0x74, 0x79, 0x3e, 0x3c, 0x70, 0x72, 0x6f, 0x70, - 0x65, 0x72, 0x74, 0x79, 0x20, 0x6e, 0x61, 0x6d, - 0x65, 0x3d, 0x22, 0x73, 0x70, 0x61, 0x63, 0x69, - 0x6e, 0x67, 0x22, 0x3e, 0x32, 0x3c, 0x2f, 0x70, - 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, 0x3e, - 0x3c, 0x63, 0x68, 0x69, 0x6c, 0x64, 0x20, 0x69, - 0x6e, 0x74, 0x65, 0x72, 0x6e, 0x61, 0x6c, 0x2d, - 0x63, 0x68, 0x69, 0x6c, 0x64, 0x3d, 0x22, 0x61, - 0x63, 0x74, 0x69, 0x6f, 0x6e, 0x5f, 0x61, 0x72, - 0x65, 0x61, 0x22, 0x3e, 0x3c, 0x6f, 0x62, 0x6a, - 0x65, 0x63, 0x74, 0x20, 0x63, 0x6c, 0x61, 0x73, - 0x73, 0x3d, 0x22, 0x47, 0x74, 0x6b, 0x42, 0x75, - 0x74, 0x74, 0x6f, 0x6e, 0x42, 0x6f, 0x78, 0x22, - 0x20, 0x69, 0x64, 0x3d, 0x22, 0x64, 0x69, 0x61, - 0x6c, 0x6f, 0x67, 0x2d, 0x61, 0x63, 0x74, 0x69, - 0x6f, 0x6e, 0x5f, 0x61, 0x72, 0x65, 0x61, 0x32, - 0x22, 0x3e, 0x3c, 0x70, 0x72, 0x6f, 0x70, 0x65, - 0x72, 0x74, 0x79, 0x20, 0x6e, 0x61, 0x6d, 0x65, - 0x3d, 0x22, 0x76, 0x69, 0x73, 0x69, 0x62, 0x6c, - 0x65, 0x22, 0x3e, 0x54, 0x72, 0x75, 0x65, 0x3c, - 0x2f, 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, - 0x79, 0x3e, 0x3c, 0x70, 0x72, 0x6f, 0x70, 0x65, - 0x72, 0x74, 0x79, 0x20, 0x6e, 0x61, 0x6d, 0x65, - 0x3d, 0x22, 0x63, 0x61, 0x6e, 0x5f, 0x66, 0x6f, - 0x63, 0x75, 0x73, 0x22, 0x3e, 0x46, 0x61, 0x6c, - 0x73, 0x65, 0x3c, 0x2f, 0x70, 0x72, 0x6f, 0x70, - 0x65, 0x72, 0x74, 0x79, 0x3e, 0x3c, 0x70, 0x72, - 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, 0x20, 0x6e, - 0x61, 0x6d, 0x65, 0x3d, 0x22, 0x6c, 0x61, 0x79, - 0x6f, 0x75, 0x74, 0x5f, 0x73, 0x74, 0x79, 0x6c, - 0x65, 0x22, 0x3e, 0x65, 0x6e, 0x64, 0x3c, 0x2f, - 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, - 0x3e, 0x3c, 0x63, 0x68, 0x69, 0x6c, 0x64, 0x3e, - 0x3c, 0x6f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x20, - 0x63, 0x6c, 0x61, 0x73, 0x73, 0x3d, 0x22, 0x47, - 0x74, 0x6b, 0x42, 0x75, 0x74, 0x74, 0x6f, 0x6e, - 0x22, 0x20, 0x69, 0x64, 0x3d, 0x22, 0x70, 0x72, - 0x65, 0x66, 0x65, 0x72, 0x65, 0x6e, 0x63, 0x65, - 0x73, 0x5f, 0x63, 0x6c, 0x6f, 0x73, 0x65, 0x5f, - 0x62, 0x75, 0x74, 0x74, 0x6f, 0x6e, 0x22, 0x3e, - 0x3c, 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, - 0x79, 0x20, 0x6e, 0x61, 0x6d, 0x65, 0x3d, 0x22, - 0x6c, 0x61, 0x62, 0x65, 0x6c, 0x22, 0x3e, 0x67, - 0x74, 0x6b, 0x2d, 0x63, 0x6c, 0x6f, 0x73, 0x65, - 0x3c, 0x2f, 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, - 0x74, 0x79, 0x3e, 0x3c, 0x70, 0x72, 0x6f, 0x70, - 0x65, 0x72, 0x74, 0x79, 0x20, 0x6e, 0x61, 0x6d, - 0x65, 0x3d, 0x22, 0x76, 0x69, 0x73, 0x69, 0x62, - 0x6c, 0x65, 0x22, 0x3e, 0x54, 0x72, 0x75, 0x65, - 0x3c, 0x2f, 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, - 0x74, 0x79, 0x3e, 0x3c, 0x70, 0x72, 0x6f, 0x70, - 0x65, 0x72, 0x74, 0x79, 0x20, 0x6e, 0x61, 0x6d, - 0x65, 0x3d, 0x22, 0x63, 0x61, 0x6e, 0x5f, 0x66, - 0x6f, 0x63, 0x75, 0x73, 0x22, 0x3e, 0x54, 0x72, - 0x75, 0x65, 0x3c, 0x2f, 0x70, 0x72, 0x6f, 0x70, - 0x65, 0x72, 0x74, 0x79, 0x3e, 0x3c, 0x70, 0x72, - 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, 0x20, 0x6e, - 0x61, 0x6d, 0x65, 0x3d, 0x22, 0x72, 0x65, 0x63, - 0x65, 0x69, 0x76, 0x65, 0x73, 0x5f, 0x64, 0x65, - 0x66, 0x61, 0x75, 0x6c, 0x74, 0x22, 0x3e, 0x54, - 0x72, 0x75, 0x65, 0x3c, 0x2f, 0x70, 0x72, 0x6f, - 0x70, 0x65, 0x72, 0x74, 0x79, 0x3e, 0x3c, 0x70, - 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, 0x20, - 0x6e, 0x61, 0x6d, 0x65, 0x3d, 0x22, 0x75, 0x73, - 0x65, 0x5f, 0x73, 0x74, 0x6f, 0x63, 0x6b, 0x22, - 0x3e, 0x54, 0x72, 0x75, 0x65, 0x3c, 0x2f, 0x70, - 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, 0x3e, - 0x3c, 0x2f, 0x6f, 0x62, 0x6a, 0x65, 0x63, 0x74, - 0x3e, 0x3c, 0x70, 0x61, 0x63, 0x6b, 0x69, 0x6e, - 0x67, 0x3e, 0x3c, 0x70, 0x72, 0x6f, 0x70, 0x65, - 0x72, 0x74, 0x79, 0x20, 0x6e, 0x61, 0x6d, 0x65, - 0x3d, 0x22, 0x65, 0x78, 0x70, 0x61, 0x6e, 0x64, - 0x22, 0x3e, 0x46, 0x61, 0x6c, 0x73, 0x65, 0x3c, - 0x2f, 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, - 0x79, 0x3e, 0x3c, 0x70, 0x72, 0x6f, 0x70, 0x65, - 0x72, 0x74, 0x79, 0x20, 0x6e, 0x61, 0x6d, 0x65, - 0x3d, 0x22, 0x66, 0x69, 0x6c, 0x6c, 0x22, 0x3e, - 0x46, 0x61, 0x6c, 0x73, 0x65, 0x3c, 0x2f, 0x70, - 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, 0x3e, - 0x3c, 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, - 0x79, 0x20, 0x6e, 0x61, 0x6d, 0x65, 0x3d, 0x22, - 0x70, 0x6f, 0x73, 0x69, 0x74, 0x69, 0x6f, 0x6e, - 0x22, 0x3e, 0x30, 0x3c, 0x2f, 0x70, 0x72, 0x6f, - 0x70, 0x65, 0x72, 0x74, 0x79, 0x3e, 0x3c, 0x2f, - 0x70, 0x61, 0x63, 0x6b, 0x69, 0x6e, 0x67, 0x3e, - 0x3c, 0x2f, 0x63, 0x68, 0x69, 0x6c, 0x64, 0x3e, - 0x3c, 0x2f, 0x6f, 0x62, 0x6a, 0x65, 0x63, 0x74, - 0x3e, 0x3c, 0x70, 0x61, 0x63, 0x6b, 0x69, 0x6e, - 0x67, 0x3e, 0x3c, 0x70, 0x72, 0x6f, 0x70, 0x65, - 0x72, 0x74, 0x79, 0x20, 0x6e, 0x61, 0x6d, 0x65, - 0x3d, 0x22, 0x65, 0x78, 0x70, 0x61, 0x6e, 0x64, - 0x22, 0x3e, 0x46, 0x61, 0x6c, 0x73, 0x65, 0x3c, - 0x2f, 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, - 0x79, 0x3e, 0x3c, 0x70, 0x72, 0x6f, 0x70, 0x65, - 0x72, 0x74, 0x79, 0x20, 0x6e, 0x61, 0x6d, 0x65, - 0x3d, 0x22, 0x66, 0x69, 0x6c, 0x6c, 0x22, 0x3e, - 0x54, 0x72, 0x75, 0x65, 0x3c, 0x2f, 0x70, 0x72, - 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, 0x3e, 0x3c, - 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, - 0x20, 0x6e, 0x61, 0x6d, 0x65, 0x3d, 0x22, 0x70, - 0x61, 0x63, 0x6b, 0x5f, 0x74, 0x79, 0x70, 0x65, - 0x22, 0x3e, 0x65, 0x6e, 0x64, 0x3c, 0x2f, 0x70, - 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, 0x3e, - 0x3c, 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, - 0x79, 0x20, 0x6e, 0x61, 0x6d, 0x65, 0x3d, 0x22, - 0x70, 0x6f, 0x73, 0x69, 0x74, 0x69, 0x6f, 0x6e, - 0x22, 0x3e, 0x30, 0x3c, 0x2f, 0x70, 0x72, 0x6f, - 0x70, 0x65, 0x72, 0x74, 0x79, 0x3e, 0x3c, 0x2f, - 0x70, 0x61, 0x63, 0x6b, 0x69, 0x6e, 0x67, 0x3e, - 0x3c, 0x2f, 0x63, 0x68, 0x69, 0x6c, 0x64, 0x3e, - 0x3c, 0x63, 0x68, 0x69, 0x6c, 0x64, 0x3e, 0x3c, - 0x6f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x20, 0x63, - 0x6c, 0x61, 0x73, 0x73, 0x3d, 0x22, 0x47, 0x74, - 0x6b, 0x47, 0x72, 0x69, 0x64, 0x22, 0x20, 0x69, - 0x64, 0x3d, 0x22, 0x67, 0x72, 0x69, 0x64, 0x33, - 0x22, 0x3e, 0x3c, 0x70, 0x72, 0x6f, 0x70, 0x65, - 0x72, 0x74, 0x79, 0x20, 0x6e, 0x61, 0x6d, 0x65, - 0x3d, 0x22, 0x76, 0x69, 0x73, 0x69, 0x62, 0x6c, - 0x65, 0x22, 0x3e, 0x54, 0x72, 0x75, 0x65, 0x3c, - 0x2f, 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, - 0x79, 0x3e, 0x3c, 0x70, 0x72, 0x6f, 0x70, 0x65, - 0x72, 0x74, 0x79, 0x20, 0x6e, 0x61, 0x6d, 0x65, - 0x3d, 0x22, 0x63, 0x61, 0x6e, 0x5f, 0x66, 0x6f, - 0x63, 0x75, 0x73, 0x22, 0x3e, 0x46, 0x61, 0x6c, - 0x73, 0x65, 0x3c, 0x2f, 0x70, 0x72, 0x6f, 0x70, - 0x65, 0x72, 0x74, 0x79, 0x3e, 0x3c, 0x70, 0x72, - 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, 0x20, 0x6e, - 0x61, 0x6d, 0x65, 0x3d, 0x22, 0x62, 0x6f, 0x72, - 0x64, 0x65, 0x72, 0x5f, 0x77, 0x69, 0x64, 0x74, - 0x68, 0x22, 0x3e, 0x35, 0x3c, 0x2f, 0x70, 0x72, - 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, 0x3e, 0x3c, - 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, - 0x20, 0x6e, 0x61, 0x6d, 0x65, 0x3d, 0x22, 0x72, - 0x6f, 0x77, 0x5f, 0x73, 0x70, 0x61, 0x63, 0x69, - 0x6e, 0x67, 0x22, 0x3e, 0x36, 0x3c, 0x2f, 0x70, - 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, 0x3e, - 0x3c, 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, - 0x79, 0x20, 0x6e, 0x61, 0x6d, 0x65, 0x3d, 0x22, - 0x63, 0x6f, 0x6c, 0x75, 0x6d, 0x6e, 0x5f, 0x73, - 0x70, 0x61, 0x63, 0x69, 0x6e, 0x67, 0x22, 0x3e, - 0x36, 0x3c, 0x2f, 0x70, 0x72, 0x6f, 0x70, 0x65, - 0x72, 0x74, 0x79, 0x3e, 0x3c, 0x63, 0x68, 0x69, - 0x6c, 0x64, 0x3e, 0x3c, 0x6f, 0x62, 0x6a, 0x65, - 0x63, 0x74, 0x20, 0x63, 0x6c, 0x61, 0x73, 0x73, - 0x3d, 0x22, 0x47, 0x74, 0x6b, 0x4c, 0x61, 0x62, - 0x65, 0x6c, 0x22, 0x20, 0x69, 0x64, 0x3d, 0x22, - 0x73, 0x6f, 0x75, 0x72, 0x63, 0x65, 0x5f, 0x6c, - 0x61, 0x62, 0x65, 0x6c, 0x22, 0x3e, 0x3c, 0x70, - 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, 0x20, - 0x6e, 0x61, 0x6d, 0x65, 0x3d, 0x22, 0x76, 0x69, - 0x73, 0x69, 0x62, 0x6c, 0x65, 0x22, 0x3e, 0x54, - 0x72, 0x75, 0x65, 0x3c, 0x2f, 0x70, 0x72, 0x6f, - 0x70, 0x65, 0x72, 0x74, 0x79, 0x3e, 0x3c, 0x70, - 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, 0x20, - 0x6e, 0x61, 0x6d, 0x65, 0x3d, 0x22, 0x63, 0x61, - 0x6e, 0x5f, 0x66, 0x6f, 0x63, 0x75, 0x73, 0x22, - 0x3e, 0x46, 0x61, 0x6c, 0x73, 0x65, 0x3c, 0x2f, - 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, - 0x3e, 0x3c, 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, - 0x74, 0x79, 0x20, 0x6e, 0x61, 0x6d, 0x65, 0x3d, - 0x22, 0x78, 0x61, 0x6c, 0x69, 0x67, 0x6e, 0x22, - 0x3e, 0x30, 0x3c, 0x2f, 0x70, 0x72, 0x6f, 0x70, - 0x65, 0x72, 0x74, 0x79, 0x3e, 0x3c, 0x70, 0x72, - 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, 0x20, 0x6e, - 0x61, 0x6d, 0x65, 0x3d, 0x22, 0x6c, 0x61, 0x62, - 0x65, 0x6c, 0x22, 0x20, 0x74, 0x72, 0x61, 0x6e, - 0x73, 0x6c, 0x61, 0x74, 0x61, 0x62, 0x6c, 0x65, - 0x3d, 0x22, 0x79, 0x65, 0x73, 0x22, 0x20, 0x63, - 0x6f, 0x6d, 0x6d, 0x65, 0x6e, 0x74, 0x73, 0x3d, - 0x22, 0x4c, 0x61, 0x62, 0x65, 0x6c, 0x20, 0x62, - 0x65, 0x73, 0x69, 0x64, 0x65, 0x20, 0x73, 0x63, - 0x61, 0x6e, 0x20, 0x73, 0x6f, 0x75, 0x72, 0x63, - 0x65, 0x20, 0x63, 0x6f, 0x6d, 0x62, 0x6f, 0x20, - 0x62, 0x6f, 0x78, 0x22, 0x3e, 0x53, 0x63, 0x61, - 0x6e, 0x20, 0x53, 0x5f, 0x6f, 0x75, 0x72, 0x63, - 0x65, 0x3a, 0x3c, 0x2f, 0x70, 0x72, 0x6f, 0x70, - 0x65, 0x72, 0x74, 0x79, 0x3e, 0x3c, 0x70, 0x72, - 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, 0x20, 0x6e, - 0x61, 0x6d, 0x65, 0x3d, 0x22, 0x75, 0x73, 0x65, - 0x5f, 0x75, 0x6e, 0x64, 0x65, 0x72, 0x6c, 0x69, - 0x6e, 0x65, 0x22, 0x3e, 0x54, 0x72, 0x75, 0x65, - 0x3c, 0x2f, 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, - 0x74, 0x79, 0x3e, 0x3c, 0x70, 0x72, 0x6f, 0x70, - 0x65, 0x72, 0x74, 0x79, 0x20, 0x6e, 0x61, 0x6d, - 0x65, 0x3d, 0x22, 0x6d, 0x6e, 0x65, 0x6d, 0x6f, - 0x6e, 0x69, 0x63, 0x5f, 0x77, 0x69, 0x64, 0x67, - 0x65, 0x74, 0x22, 0x3e, 0x64, 0x65, 0x76, 0x69, - 0x63, 0x65, 0x5f, 0x63, 0x6f, 0x6d, 0x62, 0x6f, - 0x3c, 0x2f, 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, - 0x74, 0x79, 0x3e, 0x3c, 0x2f, 0x6f, 0x62, 0x6a, - 0x65, 0x63, 0x74, 0x3e, 0x3c, 0x70, 0x61, 0x63, - 0x6b, 0x69, 0x6e, 0x67, 0x3e, 0x3c, 0x70, 0x72, - 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, 0x20, 0x6e, - 0x61, 0x6d, 0x65, 0x3d, 0x22, 0x6c, 0x65, 0x66, - 0x74, 0x5f, 0x61, 0x74, 0x74, 0x61, 0x63, 0x68, - 0x22, 0x3e, 0x30, 0x3c, 0x2f, 0x70, 0x72, 0x6f, - 0x70, 0x65, 0x72, 0x74, 0x79, 0x3e, 0x3c, 0x70, - 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, 0x20, - 0x6e, 0x61, 0x6d, 0x65, 0x3d, 0x22, 0x74, 0x6f, - 0x70, 0x5f, 0x61, 0x74, 0x74, 0x61, 0x63, 0x68, - 0x22, 0x3e, 0x30, 0x3c, 0x2f, 0x70, 0x72, 0x6f, - 0x70, 0x65, 0x72, 0x74, 0x79, 0x3e, 0x3c, 0x70, - 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, 0x20, - 0x6e, 0x61, 0x6d, 0x65, 0x3d, 0x22, 0x77, 0x69, - 0x64, 0x74, 0x68, 0x22, 0x3e, 0x31, 0x3c, 0x2f, - 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, - 0x3e, 0x3c, 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, - 0x74, 0x79, 0x20, 0x6e, 0x61, 0x6d, 0x65, 0x3d, - 0x22, 0x68, 0x65, 0x69, 0x67, 0x68, 0x74, 0x22, - 0x3e, 0x31, 0x3c, 0x2f, 0x70, 0x72, 0x6f, 0x70, - 0x65, 0x72, 0x74, 0x79, 0x3e, 0x3c, 0x2f, 0x70, - 0x61, 0x63, 0x6b, 0x69, 0x6e, 0x67, 0x3e, 0x3c, - 0x2f, 0x63, 0x68, 0x69, 0x6c, 0x64, 0x3e, 0x3c, - 0x63, 0x68, 0x69, 0x6c, 0x64, 0x3e, 0x3c, 0x6f, - 0x62, 0x6a, 0x65, 0x63, 0x74, 0x20, 0x63, 0x6c, - 0x61, 0x73, 0x73, 0x3d, 0x22, 0x47, 0x74, 0x6b, - 0x43, 0x6f, 0x6d, 0x62, 0x6f, 0x42, 0x6f, 0x78, - 0x22, 0x20, 0x69, 0x64, 0x3d, 0x22, 0x64, 0x65, - 0x76, 0x69, 0x63, 0x65, 0x5f, 0x63, 0x6f, 0x6d, - 0x62, 0x6f, 0x22, 0x3e, 0x3c, 0x70, 0x72, 0x6f, - 0x70, 0x65, 0x72, 0x74, 0x79, 0x20, 0x6e, 0x61, - 0x6d, 0x65, 0x3d, 0x22, 0x76, 0x69, 0x73, 0x69, - 0x62, 0x6c, 0x65, 0x22, 0x3e, 0x54, 0x72, 0x75, - 0x65, 0x3c, 0x2f, 0x70, 0x72, 0x6f, 0x70, 0x65, - 0x72, 0x74, 0x79, 0x3e, 0x3c, 0x70, 0x72, 0x6f, - 0x70, 0x65, 0x72, 0x74, 0x79, 0x20, 0x6e, 0x61, - 0x6d, 0x65, 0x3d, 0x22, 0x63, 0x61, 0x6e, 0x5f, - 0x66, 0x6f, 0x63, 0x75, 0x73, 0x22, 0x3e, 0x46, - 0x61, 0x6c, 0x73, 0x65, 0x3c, 0x2f, 0x70, 0x72, - 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, 0x3e, 0x3c, - 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, - 0x20, 0x6e, 0x61, 0x6d, 0x65, 0x3d, 0x22, 0x68, - 0x65, 0x78, 0x70, 0x61, 0x6e, 0x64, 0x22, 0x3e, - 0x54, 0x72, 0x75, 0x65, 0x3c, 0x2f, 0x70, 0x72, - 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, 0x3e, 0x3c, - 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, - 0x20, 0x6e, 0x61, 0x6d, 0x65, 0x3d, 0x22, 0x6d, - 0x6f, 0x64, 0x65, 0x6c, 0x22, 0x3e, 0x64, 0x65, - 0x76, 0x69, 0x63, 0x65, 0x5f, 0x6d, 0x6f, 0x64, - 0x65, 0x6c, 0x3c, 0x2f, 0x70, 0x72, 0x6f, 0x70, - 0x65, 0x72, 0x74, 0x79, 0x3e, 0x3c, 0x73, 0x69, - 0x67, 0x6e, 0x61, 0x6c, 0x20, 0x6e, 0x61, 0x6d, - 0x65, 0x3d, 0x22, 0x63, 0x68, 0x61, 0x6e, 0x67, - 0x65, 0x64, 0x22, 0x20, 0x68, 0x61, 0x6e, 0x64, - 0x6c, 0x65, 0x72, 0x3d, 0x22, 0x64, 0x65, 0x76, - 0x69, 0x63, 0x65, 0x5f, 0x63, 0x6f, 0x6d, 0x62, - 0x6f, 0x5f, 0x63, 0x68, 0x61, 0x6e, 0x67, 0x65, - 0x64, 0x5f, 0x63, 0x62, 0x22, 0x20, 0x73, 0x77, - 0x61, 0x70, 0x70, 0x65, 0x64, 0x3d, 0x22, 0x6e, - 0x6f, 0x22, 0x2f, 0x3e, 0x3c, 0x2f, 0x6f, 0x62, - 0x6a, 0x65, 0x63, 0x74, 0x3e, 0x3c, 0x70, 0x61, - 0x63, 0x6b, 0x69, 0x6e, 0x67, 0x3e, 0x3c, 0x70, - 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, 0x20, - 0x6e, 0x61, 0x6d, 0x65, 0x3d, 0x22, 0x6c, 0x65, - 0x66, 0x74, 0x5f, 0x61, 0x74, 0x74, 0x61, 0x63, - 0x68, 0x22, 0x3e, 0x31, 0x3c, 0x2f, 0x70, 0x72, - 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, 0x3e, 0x3c, - 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, - 0x20, 0x6e, 0x61, 0x6d, 0x65, 0x3d, 0x22, 0x74, - 0x6f, 0x70, 0x5f, 0x61, 0x74, 0x74, 0x61, 0x63, - 0x68, 0x22, 0x3e, 0x30, 0x3c, 0x2f, 0x70, 0x72, - 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, 0x3e, 0x3c, - 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, - 0x20, 0x6e, 0x61, 0x6d, 0x65, 0x3d, 0x22, 0x77, - 0x69, 0x64, 0x74, 0x68, 0x22, 0x3e, 0x31, 0x3c, - 0x2f, 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, - 0x79, 0x3e, 0x3c, 0x70, 0x72, 0x6f, 0x70, 0x65, - 0x72, 0x74, 0x79, 0x20, 0x6e, 0x61, 0x6d, 0x65, - 0x3d, 0x22, 0x68, 0x65, 0x69, 0x67, 0x68, 0x74, - 0x22, 0x3e, 0x31, 0x3c, 0x2f, 0x70, 0x72, 0x6f, - 0x70, 0x65, 0x72, 0x74, 0x79, 0x3e, 0x3c, 0x2f, - 0x70, 0x61, 0x63, 0x6b, 0x69, 0x6e, 0x67, 0x3e, - 0x3c, 0x2f, 0x63, 0x68, 0x69, 0x6c, 0x64, 0x3e, - 0x3c, 0x63, 0x68, 0x69, 0x6c, 0x64, 0x3e, 0x3c, - 0x6f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x20, 0x63, - 0x6c, 0x61, 0x73, 0x73, 0x3d, 0x22, 0x47, 0x74, - 0x6b, 0x4c, 0x61, 0x62, 0x65, 0x6c, 0x22, 0x20, - 0x69, 0x64, 0x3d, 0x22, 0x74, 0x65, 0x78, 0x74, - 0x5f, 0x64, 0x70, 0x69, 0x5f, 0x6c, 0x61, 0x62, - 0x65, 0x6c, 0x22, 0x3e, 0x3c, 0x70, 0x72, 0x6f, - 0x70, 0x65, 0x72, 0x74, 0x79, 0x20, 0x6e, 0x61, - 0x6d, 0x65, 0x3d, 0x22, 0x76, 0x69, 0x73, 0x69, - 0x62, 0x6c, 0x65, 0x22, 0x3e, 0x54, 0x72, 0x75, - 0x65, 0x3c, 0x2f, 0x70, 0x72, 0x6f, 0x70, 0x65, - 0x72, 0x74, 0x79, 0x3e, 0x3c, 0x70, 0x72, 0x6f, - 0x70, 0x65, 0x72, 0x74, 0x79, 0x20, 0x6e, 0x61, - 0x6d, 0x65, 0x3d, 0x22, 0x63, 0x61, 0x6e, 0x5f, - 0x66, 0x6f, 0x63, 0x75, 0x73, 0x22, 0x3e, 0x46, - 0x61, 0x6c, 0x73, 0x65, 0x3c, 0x2f, 0x70, 0x72, - 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, 0x3e, 0x3c, - 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, - 0x20, 0x6e, 0x61, 0x6d, 0x65, 0x3d, 0x22, 0x78, - 0x61, 0x6c, 0x69, 0x67, 0x6e, 0x22, 0x3e, 0x30, - 0x3c, 0x2f, 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, - 0x74, 0x79, 0x3e, 0x3c, 0x70, 0x72, 0x6f, 0x70, - 0x65, 0x72, 0x74, 0x79, 0x20, 0x6e, 0x61, 0x6d, - 0x65, 0x3d, 0x22, 0x6c, 0x61, 0x62, 0x65, 0x6c, - 0x22, 0x20, 0x74, 0x72, 0x61, 0x6e, 0x73, 0x6c, - 0x61, 0x74, 0x61, 0x62, 0x6c, 0x65, 0x3d, 0x22, - 0x79, 0x65, 0x73, 0x22, 0x20, 0x63, 0x6f, 0x6d, - 0x6d, 0x65, 0x6e, 0x74, 0x73, 0x3d, 0x22, 0x4c, - 0x61, 0x62, 0x65, 0x6c, 0x20, 0x62, 0x65, 0x73, - 0x69, 0x64, 0x65, 0x20, 0x73, 0x63, 0x61, 0x6e, - 0x20, 0x73, 0x6f, 0x75, 0x72, 0x63, 0x65, 0x20, - 0x63, 0x6f, 0x6d, 0x62, 0x6f, 0x20, 0x62, 0x6f, - 0x78, 0x22, 0x3e, 0x5f, 0x54, 0x65, 0x78, 0x74, - 0x20, 0x52, 0x65, 0x73, 0x6f, 0x6c, 0x75, 0x74, - 0x69, 0x6f, 0x6e, 0x3a, 0x3c, 0x2f, 0x70, 0x72, - 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, 0x3e, 0x3c, - 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, - 0x20, 0x6e, 0x61, 0x6d, 0x65, 0x3d, 0x22, 0x75, - 0x73, 0x65, 0x5f, 0x75, 0x6e, 0x64, 0x65, 0x72, - 0x6c, 0x69, 0x6e, 0x65, 0x22, 0x3e, 0x54, 0x72, - 0x75, 0x65, 0x3c, 0x2f, 0x70, 0x72, 0x6f, 0x70, - 0x65, 0x72, 0x74, 0x79, 0x3e, 0x3c, 0x70, 0x72, - 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, 0x20, 0x6e, - 0x61, 0x6d, 0x65, 0x3d, 0x22, 0x6d, 0x6e, 0x65, - 0x6d, 0x6f, 0x6e, 0x69, 0x63, 0x5f, 0x77, 0x69, - 0x64, 0x67, 0x65, 0x74, 0x22, 0x3e, 0x74, 0x65, - 0x78, 0x74, 0x5f, 0x64, 0x70, 0x69, 0x5f, 0x63, - 0x6f, 0x6d, 0x62, 0x6f, 0x3c, 0x2f, 0x70, 0x72, - 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, 0x3e, 0x3c, - 0x2f, 0x6f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x3e, - 0x3c, 0x70, 0x61, 0x63, 0x6b, 0x69, 0x6e, 0x67, - 0x3e, 0x3c, 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, - 0x74, 0x79, 0x20, 0x6e, 0x61, 0x6d, 0x65, 0x3d, - 0x22, 0x6c, 0x65, 0x66, 0x74, 0x5f, 0x61, 0x74, - 0x74, 0x61, 0x63, 0x68, 0x22, 0x3e, 0x30, 0x3c, - 0x2f, 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, - 0x79, 0x3e, 0x3c, 0x70, 0x72, 0x6f, 0x70, 0x65, - 0x72, 0x74, 0x79, 0x20, 0x6e, 0x61, 0x6d, 0x65, - 0x3d, 0x22, 0x74, 0x6f, 0x70, 0x5f, 0x61, 0x74, - 0x74, 0x61, 0x63, 0x68, 0x22, 0x3e, 0x31, 0x3c, - 0x2f, 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, - 0x79, 0x3e, 0x3c, 0x70, 0x72, 0x6f, 0x70, 0x65, - 0x72, 0x74, 0x79, 0x20, 0x6e, 0x61, 0x6d, 0x65, - 0x3d, 0x22, 0x77, 0x69, 0x64, 0x74, 0x68, 0x22, - 0x3e, 0x31, 0x3c, 0x2f, 0x70, 0x72, 0x6f, 0x70, - 0x65, 0x72, 0x74, 0x79, 0x3e, 0x3c, 0x70, 0x72, - 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, 0x20, 0x6e, - 0x61, 0x6d, 0x65, 0x3d, 0x22, 0x68, 0x65, 0x69, - 0x67, 0x68, 0x74, 0x22, 0x3e, 0x31, 0x3c, 0x2f, - 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, - 0x3e, 0x3c, 0x2f, 0x70, 0x61, 0x63, 0x6b, 0x69, - 0x6e, 0x67, 0x3e, 0x3c, 0x2f, 0x63, 0x68, 0x69, - 0x6c, 0x64, 0x3e, 0x3c, 0x63, 0x68, 0x69, 0x6c, - 0x64, 0x3e, 0x3c, 0x6f, 0x62, 0x6a, 0x65, 0x63, - 0x74, 0x20, 0x63, 0x6c, 0x61, 0x73, 0x73, 0x3d, - 0x22, 0x47, 0x74, 0x6b, 0x4c, 0x61, 0x62, 0x65, - 0x6c, 0x22, 0x20, 0x69, 0x64, 0x3d, 0x22, 0x70, - 0x68, 0x6f, 0x74, 0x6f, 0x5f, 0x64, 0x70, 0x69, - 0x5f, 0x6c, 0x61, 0x62, 0x65, 0x6c, 0x22, 0x3e, - 0x3c, 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, - 0x79, 0x20, 0x6e, 0x61, 0x6d, 0x65, 0x3d, 0x22, - 0x76, 0x69, 0x73, 0x69, 0x62, 0x6c, 0x65, 0x22, - 0x3e, 0x54, 0x72, 0x75, 0x65, 0x3c, 0x2f, 0x70, - 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, 0x3e, - 0x3c, 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, - 0x79, 0x20, 0x6e, 0x61, 0x6d, 0x65, 0x3d, 0x22, - 0x63, 0x61, 0x6e, 0x5f, 0x66, 0x6f, 0x63, 0x75, - 0x73, 0x22, 0x3e, 0x46, 0x61, 0x6c, 0x73, 0x65, - 0x3c, 0x2f, 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, - 0x74, 0x79, 0x3e, 0x3c, 0x70, 0x72, 0x6f, 0x70, - 0x65, 0x72, 0x74, 0x79, 0x20, 0x6e, 0x61, 0x6d, - 0x65, 0x3d, 0x22, 0x78, 0x61, 0x6c, 0x69, 0x67, - 0x6e, 0x22, 0x3e, 0x30, 0x3c, 0x2f, 0x70, 0x72, - 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, 0x3e, 0x3c, - 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, - 0x20, 0x6e, 0x61, 0x6d, 0x65, 0x3d, 0x22, 0x6c, - 0x61, 0x62, 0x65, 0x6c, 0x22, 0x20, 0x74, 0x72, - 0x61, 0x6e, 0x73, 0x6c, 0x61, 0x74, 0x61, 0x62, - 0x6c, 0x65, 0x3d, 0x22, 0x79, 0x65, 0x73, 0x22, - 0x20, 0x63, 0x6f, 0x6d, 0x6d, 0x65, 0x6e, 0x74, - 0x73, 0x3d, 0x22, 0x4c, 0x61, 0x62, 0x65, 0x6c, - 0x20, 0x62, 0x65, 0x73, 0x69, 0x64, 0x65, 0x20, - 0x73, 0x63, 0x61, 0x6e, 0x20, 0x73, 0x6f, 0x75, - 0x72, 0x63, 0x65, 0x20, 0x63, 0x6f, 0x6d, 0x62, - 0x6f, 0x20, 0x62, 0x6f, 0x78, 0x22, 0x3e, 0x5f, - 0x50, 0x68, 0x6f, 0x74, 0x6f, 0x20, 0x52, 0x65, - 0x73, 0x6f, 0x6c, 0x75, 0x74, 0x69, 0x6f, 0x6e, - 0x3a, 0x3c, 0x2f, 0x70, 0x72, 0x6f, 0x70, 0x65, - 0x72, 0x74, 0x79, 0x3e, 0x3c, 0x70, 0x72, 0x6f, - 0x70, 0x65, 0x72, 0x74, 0x79, 0x20, 0x6e, 0x61, - 0x6d, 0x65, 0x3d, 0x22, 0x75, 0x73, 0x65, 0x5f, - 0x75, 0x6e, 0x64, 0x65, 0x72, 0x6c, 0x69, 0x6e, - 0x65, 0x22, 0x3e, 0x54, 0x72, 0x75, 0x65, 0x3c, - 0x2f, 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, - 0x79, 0x3e, 0x3c, 0x70, 0x72, 0x6f, 0x70, 0x65, - 0x72, 0x74, 0x79, 0x20, 0x6e, 0x61, 0x6d, 0x65, - 0x3d, 0x22, 0x6d, 0x6e, 0x65, 0x6d, 0x6f, 0x6e, - 0x69, 0x63, 0x5f, 0x77, 0x69, 0x64, 0x67, 0x65, - 0x74, 0x22, 0x3e, 0x70, 0x68, 0x6f, 0x74, 0x6f, - 0x5f, 0x64, 0x70, 0x69, 0x5f, 0x63, 0x6f, 0x6d, - 0x62, 0x6f, 0x3c, 0x2f, 0x70, 0x72, 0x6f, 0x70, - 0x65, 0x72, 0x74, 0x79, 0x3e, 0x3c, 0x2f, 0x6f, - 0x62, 0x6a, 0x65, 0x63, 0x74, 0x3e, 0x3c, 0x70, - 0x61, 0x63, 0x6b, 0x69, 0x6e, 0x67, 0x3e, 0x3c, - 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, - 0x20, 0x6e, 0x61, 0x6d, 0x65, 0x3d, 0x22, 0x6c, - 0x65, 0x66, 0x74, 0x5f, 0x61, 0x74, 0x74, 0x61, - 0x63, 0x68, 0x22, 0x3e, 0x30, 0x3c, 0x2f, 0x70, - 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, 0x3e, - 0x3c, 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, - 0x79, 0x20, 0x6e, 0x61, 0x6d, 0x65, 0x3d, 0x22, - 0x74, 0x6f, 0x70, 0x5f, 0x61, 0x74, 0x74, 0x61, - 0x63, 0x68, 0x22, 0x3e, 0x32, 0x3c, 0x2f, 0x70, - 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, 0x3e, - 0x3c, 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, - 0x79, 0x20, 0x6e, 0x61, 0x6d, 0x65, 0x3d, 0x22, - 0x77, 0x69, 0x64, 0x74, 0x68, 0x22, 0x3e, 0x31, - 0x3c, 0x2f, 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, - 0x74, 0x79, 0x3e, 0x3c, 0x70, 0x72, 0x6f, 0x70, - 0x65, 0x72, 0x74, 0x79, 0x20, 0x6e, 0x61, 0x6d, - 0x65, 0x3d, 0x22, 0x68, 0x65, 0x69, 0x67, 0x68, - 0x74, 0x22, 0x3e, 0x31, 0x3c, 0x2f, 0x70, 0x72, - 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, 0x3e, 0x3c, - 0x2f, 0x70, 0x61, 0x63, 0x6b, 0x69, 0x6e, 0x67, - 0x3e, 0x3c, 0x2f, 0x63, 0x68, 0x69, 0x6c, 0x64, - 0x3e, 0x3c, 0x63, 0x68, 0x69, 0x6c, 0x64, 0x3e, - 0x3c, 0x6f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x20, - 0x63, 0x6c, 0x61, 0x73, 0x73, 0x3d, 0x22, 0x47, - 0x74, 0x6b, 0x43, 0x6f, 0x6d, 0x62, 0x6f, 0x42, - 0x6f, 0x78, 0x22, 0x20, 0x69, 0x64, 0x3d, 0x22, - 0x74, 0x65, 0x78, 0x74, 0x5f, 0x64, 0x70, 0x69, - 0x5f, 0x63, 0x6f, 0x6d, 0x62, 0x6f, 0x22, 0x3e, - 0x3c, 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, - 0x79, 0x20, 0x6e, 0x61, 0x6d, 0x65, 0x3d, 0x22, - 0x76, 0x69, 0x73, 0x69, 0x62, 0x6c, 0x65, 0x22, - 0x3e, 0x54, 0x72, 0x75, 0x65, 0x3c, 0x2f, 0x70, - 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, 0x3e, - 0x3c, 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, - 0x79, 0x20, 0x6e, 0x61, 0x6d, 0x65, 0x3d, 0x22, - 0x63, 0x61, 0x6e, 0x5f, 0x66, 0x6f, 0x63, 0x75, - 0x73, 0x22, 0x3e, 0x46, 0x61, 0x6c, 0x73, 0x65, - 0x3c, 0x2f, 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, - 0x74, 0x79, 0x3e, 0x3c, 0x70, 0x72, 0x6f, 0x70, - 0x65, 0x72, 0x74, 0x79, 0x20, 0x6e, 0x61, 0x6d, - 0x65, 0x3d, 0x22, 0x68, 0x65, 0x78, 0x70, 0x61, - 0x6e, 0x64, 0x22, 0x3e, 0x54, 0x72, 0x75, 0x65, - 0x3c, 0x2f, 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, - 0x74, 0x79, 0x3e, 0x3c, 0x70, 0x72, 0x6f, 0x70, - 0x65, 0x72, 0x74, 0x79, 0x20, 0x6e, 0x61, 0x6d, - 0x65, 0x3d, 0x22, 0x6d, 0x6f, 0x64, 0x65, 0x6c, - 0x22, 0x3e, 0x74, 0x65, 0x78, 0x74, 0x5f, 0x64, - 0x70, 0x69, 0x5f, 0x6d, 0x6f, 0x64, 0x65, 0x6c, - 0x3c, 0x2f, 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, - 0x74, 0x79, 0x3e, 0x3c, 0x2f, 0x6f, 0x62, 0x6a, - 0x65, 0x63, 0x74, 0x3e, 0x3c, 0x70, 0x61, 0x63, - 0x6b, 0x69, 0x6e, 0x67, 0x3e, 0x3c, 0x70, 0x72, - 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, 0x20, 0x6e, - 0x61, 0x6d, 0x65, 0x3d, 0x22, 0x6c, 0x65, 0x66, - 0x74, 0x5f, 0x61, 0x74, 0x74, 0x61, 0x63, 0x68, - 0x22, 0x3e, 0x31, 0x3c, 0x2f, 0x70, 0x72, 0x6f, - 0x70, 0x65, 0x72, 0x74, 0x79, 0x3e, 0x3c, 0x70, - 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, 0x20, - 0x6e, 0x61, 0x6d, 0x65, 0x3d, 0x22, 0x74, 0x6f, - 0x70, 0x5f, 0x61, 0x74, 0x74, 0x61, 0x63, 0x68, - 0x22, 0x3e, 0x31, 0x3c, 0x2f, 0x70, 0x72, 0x6f, - 0x70, 0x65, 0x72, 0x74, 0x79, 0x3e, 0x3c, 0x70, - 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, 0x20, - 0x6e, 0x61, 0x6d, 0x65, 0x3d, 0x22, 0x77, 0x69, - 0x64, 0x74, 0x68, 0x22, 0x3e, 0x31, 0x3c, 0x2f, - 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, - 0x3e, 0x3c, 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, - 0x74, 0x79, 0x20, 0x6e, 0x61, 0x6d, 0x65, 0x3d, - 0x22, 0x68, 0x65, 0x69, 0x67, 0x68, 0x74, 0x22, - 0x3e, 0x31, 0x3c, 0x2f, 0x70, 0x72, 0x6f, 0x70, - 0x65, 0x72, 0x74, 0x79, 0x3e, 0x3c, 0x2f, 0x70, - 0x61, 0x63, 0x6b, 0x69, 0x6e, 0x67, 0x3e, 0x3c, - 0x2f, 0x63, 0x68, 0x69, 0x6c, 0x64, 0x3e, 0x3c, - 0x63, 0x68, 0x69, 0x6c, 0x64, 0x3e, 0x3c, 0x6f, - 0x62, 0x6a, 0x65, 0x63, 0x74, 0x20, 0x63, 0x6c, - 0x61, 0x73, 0x73, 0x3d, 0x22, 0x47, 0x74, 0x6b, - 0x43, 0x6f, 0x6d, 0x62, 0x6f, 0x42, 0x6f, 0x78, - 0x22, 0x20, 0x69, 0x64, 0x3d, 0x22, 0x70, 0x68, - 0x6f, 0x74, 0x6f, 0x5f, 0x64, 0x70, 0x69, 0x5f, - 0x63, 0x6f, 0x6d, 0x62, 0x6f, 0x22, 0x3e, 0x3c, - 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, - 0x20, 0x6e, 0x61, 0x6d, 0x65, 0x3d, 0x22, 0x76, - 0x69, 0x73, 0x69, 0x62, 0x6c, 0x65, 0x22, 0x3e, - 0x54, 0x72, 0x75, 0x65, 0x3c, 0x2f, 0x70, 0x72, - 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, 0x3e, 0x3c, - 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, - 0x20, 0x6e, 0x61, 0x6d, 0x65, 0x3d, 0x22, 0x63, - 0x61, 0x6e, 0x5f, 0x66, 0x6f, 0x63, 0x75, 0x73, - 0x22, 0x3e, 0x46, 0x61, 0x6c, 0x73, 0x65, 0x3c, - 0x2f, 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, - 0x79, 0x3e, 0x3c, 0x70, 0x72, 0x6f, 0x70, 0x65, - 0x72, 0x74, 0x79, 0x20, 0x6e, 0x61, 0x6d, 0x65, - 0x3d, 0x22, 0x68, 0x65, 0x78, 0x70, 0x61, 0x6e, - 0x64, 0x22, 0x3e, 0x54, 0x72, 0x75, 0x65, 0x3c, - 0x2f, 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, - 0x79, 0x3e, 0x3c, 0x70, 0x72, 0x6f, 0x70, 0x65, - 0x72, 0x74, 0x79, 0x20, 0x6e, 0x61, 0x6d, 0x65, - 0x3d, 0x22, 0x6d, 0x6f, 0x64, 0x65, 0x6c, 0x22, - 0x3e, 0x70, 0x68, 0x6f, 0x74, 0x6f, 0x5f, 0x64, - 0x70, 0x69, 0x5f, 0x6d, 0x6f, 0x64, 0x65, 0x6c, - 0x3c, 0x2f, 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, - 0x74, 0x79, 0x3e, 0x3c, 0x2f, 0x6f, 0x62, 0x6a, - 0x65, 0x63, 0x74, 0x3e, 0x3c, 0x70, 0x61, 0x63, - 0x6b, 0x69, 0x6e, 0x67, 0x3e, 0x3c, 0x70, 0x72, - 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, 0x20, 0x6e, - 0x61, 0x6d, 0x65, 0x3d, 0x22, 0x6c, 0x65, 0x66, - 0x74, 0x5f, 0x61, 0x74, 0x74, 0x61, 0x63, 0x68, - 0x22, 0x3e, 0x31, 0x3c, 0x2f, 0x70, 0x72, 0x6f, - 0x70, 0x65, 0x72, 0x74, 0x79, 0x3e, 0x3c, 0x70, - 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, 0x20, - 0x6e, 0x61, 0x6d, 0x65, 0x3d, 0x22, 0x74, 0x6f, - 0x70, 0x5f, 0x61, 0x74, 0x74, 0x61, 0x63, 0x68, - 0x22, 0x3e, 0x32, 0x3c, 0x2f, 0x70, 0x72, 0x6f, - 0x70, 0x65, 0x72, 0x74, 0x79, 0x3e, 0x3c, 0x70, - 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, 0x20, - 0x6e, 0x61, 0x6d, 0x65, 0x3d, 0x22, 0x77, 0x69, - 0x64, 0x74, 0x68, 0x22, 0x3e, 0x31, 0x3c, 0x2f, - 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, - 0x3e, 0x3c, 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, - 0x74, 0x79, 0x20, 0x6e, 0x61, 0x6d, 0x65, 0x3d, - 0x22, 0x68, 0x65, 0x69, 0x67, 0x68, 0x74, 0x22, - 0x3e, 0x31, 0x3c, 0x2f, 0x70, 0x72, 0x6f, 0x70, - 0x65, 0x72, 0x74, 0x79, 0x3e, 0x3c, 0x2f, 0x70, - 0x61, 0x63, 0x6b, 0x69, 0x6e, 0x67, 0x3e, 0x3c, - 0x2f, 0x63, 0x68, 0x69, 0x6c, 0x64, 0x3e, 0x3c, - 0x63, 0x68, 0x69, 0x6c, 0x64, 0x3e, 0x3c, 0x6f, - 0x62, 0x6a, 0x65, 0x63, 0x74, 0x20, 0x63, 0x6c, - 0x61, 0x73, 0x73, 0x3d, 0x22, 0x47, 0x74, 0x6b, - 0x4c, 0x61, 0x62, 0x65, 0x6c, 0x22, 0x20, 0x69, - 0x64, 0x3d, 0x22, 0x70, 0x61, 0x67, 0x65, 0x5f, - 0x73, 0x69, 0x64, 0x65, 0x5f, 0x6c, 0x61, 0x62, - 0x65, 0x6c, 0x22, 0x3e, 0x3c, 0x70, 0x72, 0x6f, - 0x70, 0x65, 0x72, 0x74, 0x79, 0x20, 0x6e, 0x61, - 0x6d, 0x65, 0x3d, 0x22, 0x76, 0x69, 0x73, 0x69, - 0x62, 0x6c, 0x65, 0x22, 0x3e, 0x54, 0x72, 0x75, - 0x65, 0x3c, 0x2f, 0x70, 0x72, 0x6f, 0x70, 0x65, - 0x72, 0x74, 0x79, 0x3e, 0x3c, 0x70, 0x72, 0x6f, - 0x70, 0x65, 0x72, 0x74, 0x79, 0x20, 0x6e, 0x61, - 0x6d, 0x65, 0x3d, 0x22, 0x63, 0x61, 0x6e, 0x5f, - 0x66, 0x6f, 0x63, 0x75, 0x73, 0x22, 0x3e, 0x46, - 0x61, 0x6c, 0x73, 0x65, 0x3c, 0x2f, 0x70, 0x72, - 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, 0x3e, 0x3c, - 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, - 0x20, 0x6e, 0x61, 0x6d, 0x65, 0x3d, 0x22, 0x78, - 0x61, 0x6c, 0x69, 0x67, 0x6e, 0x22, 0x3e, 0x30, - 0x3c, 0x2f, 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, - 0x74, 0x79, 0x3e, 0x3c, 0x70, 0x72, 0x6f, 0x70, - 0x65, 0x72, 0x74, 0x79, 0x20, 0x6e, 0x61, 0x6d, - 0x65, 0x3d, 0x22, 0x6c, 0x61, 0x62, 0x65, 0x6c, - 0x22, 0x20, 0x74, 0x72, 0x61, 0x6e, 0x73, 0x6c, - 0x61, 0x74, 0x61, 0x62, 0x6c, 0x65, 0x3d, 0x22, - 0x79, 0x65, 0x73, 0x22, 0x20, 0x63, 0x6f, 0x6d, - 0x6d, 0x65, 0x6e, 0x74, 0x73, 0x3d, 0x22, 0x4c, - 0x61, 0x62, 0x65, 0x6c, 0x20, 0x62, 0x65, 0x73, - 0x69, 0x64, 0x65, 0x20, 0x73, 0x63, 0x61, 0x6e, - 0x20, 0x73, 0x69, 0x64, 0x65, 0x20, 0x63, 0x6f, - 0x6d, 0x62, 0x6f, 0x20, 0x62, 0x6f, 0x78, 0x22, - 0x3e, 0x53, 0x63, 0x61, 0x6e, 0x20, 0x53, 0x69, - 0x64, 0x65, 0x3a, 0x3c, 0x2f, 0x70, 0x72, 0x6f, - 0x70, 0x65, 0x72, 0x74, 0x79, 0x3e, 0x3c, 0x70, - 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, 0x20, - 0x6e, 0x61, 0x6d, 0x65, 0x3d, 0x22, 0x75, 0x73, - 0x65, 0x5f, 0x75, 0x6e, 0x64, 0x65, 0x72, 0x6c, - 0x69, 0x6e, 0x65, 0x22, 0x3e, 0x54, 0x72, 0x75, - 0x65, 0x3c, 0x2f, 0x70, 0x72, 0x6f, 0x70, 0x65, - 0x72, 0x74, 0x79, 0x3e, 0x3c, 0x70, 0x72, 0x6f, - 0x70, 0x65, 0x72, 0x74, 0x79, 0x20, 0x6e, 0x61, - 0x6d, 0x65, 0x3d, 0x22, 0x6d, 0x6e, 0x65, 0x6d, - 0x6f, 0x6e, 0x69, 0x63, 0x5f, 0x77, 0x69, 0x64, - 0x67, 0x65, 0x74, 0x22, 0x3e, 0x70, 0x68, 0x6f, - 0x74, 0x6f, 0x5f, 0x64, 0x70, 0x69, 0x5f, 0x63, - 0x6f, 0x6d, 0x62, 0x6f, 0x3c, 0x2f, 0x70, 0x72, - 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, 0x3e, 0x3c, - 0x2f, 0x6f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x3e, - 0x3c, 0x70, 0x61, 0x63, 0x6b, 0x69, 0x6e, 0x67, - 0x3e, 0x3c, 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, - 0x74, 0x79, 0x20, 0x6e, 0x61, 0x6d, 0x65, 0x3d, - 0x22, 0x6c, 0x65, 0x66, 0x74, 0x5f, 0x61, 0x74, - 0x74, 0x61, 0x63, 0x68, 0x22, 0x3e, 0x30, 0x3c, - 0x2f, 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, - 0x79, 0x3e, 0x3c, 0x70, 0x72, 0x6f, 0x70, 0x65, - 0x72, 0x74, 0x79, 0x20, 0x6e, 0x61, 0x6d, 0x65, - 0x3d, 0x22, 0x74, 0x6f, 0x70, 0x5f, 0x61, 0x74, - 0x74, 0x61, 0x63, 0x68, 0x22, 0x3e, 0x33, 0x3c, - 0x2f, 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, - 0x79, 0x3e, 0x3c, 0x70, 0x72, 0x6f, 0x70, 0x65, - 0x72, 0x74, 0x79, 0x20, 0x6e, 0x61, 0x6d, 0x65, - 0x3d, 0x22, 0x77, 0x69, 0x64, 0x74, 0x68, 0x22, - 0x3e, 0x31, 0x3c, 0x2f, 0x70, 0x72, 0x6f, 0x70, - 0x65, 0x72, 0x74, 0x79, 0x3e, 0x3c, 0x70, 0x72, - 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, 0x20, 0x6e, - 0x61, 0x6d, 0x65, 0x3d, 0x22, 0x68, 0x65, 0x69, - 0x67, 0x68, 0x74, 0x22, 0x3e, 0x31, 0x3c, 0x2f, - 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, - 0x3e, 0x3c, 0x2f, 0x70, 0x61, 0x63, 0x6b, 0x69, - 0x6e, 0x67, 0x3e, 0x3c, 0x2f, 0x63, 0x68, 0x69, - 0x6c, 0x64, 0x3e, 0x3c, 0x63, 0x68, 0x69, 0x6c, - 0x64, 0x3e, 0x3c, 0x6f, 0x62, 0x6a, 0x65, 0x63, - 0x74, 0x20, 0x63, 0x6c, 0x61, 0x73, 0x73, 0x3d, - 0x22, 0x47, 0x74, 0x6b, 0x43, 0x6f, 0x6d, 0x62, - 0x6f, 0x42, 0x6f, 0x78, 0x22, 0x20, 0x69, 0x64, - 0x3d, 0x22, 0x70, 0x61, 0x67, 0x65, 0x5f, 0x73, - 0x69, 0x64, 0x65, 0x5f, 0x63, 0x6f, 0x6d, 0x62, - 0x6f, 0x22, 0x3e, 0x3c, 0x70, 0x72, 0x6f, 0x70, - 0x65, 0x72, 0x74, 0x79, 0x20, 0x6e, 0x61, 0x6d, - 0x65, 0x3d, 0x22, 0x76, 0x69, 0x73, 0x69, 0x62, - 0x6c, 0x65, 0x22, 0x3e, 0x54, 0x72, 0x75, 0x65, - 0x3c, 0x2f, 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, - 0x74, 0x79, 0x3e, 0x3c, 0x70, 0x72, 0x6f, 0x70, - 0x65, 0x72, 0x74, 0x79, 0x20, 0x6e, 0x61, 0x6d, - 0x65, 0x3d, 0x22, 0x63, 0x61, 0x6e, 0x5f, 0x66, - 0x6f, 0x63, 0x75, 0x73, 0x22, 0x3e, 0x46, 0x61, - 0x6c, 0x73, 0x65, 0x3c, 0x2f, 0x70, 0x72, 0x6f, - 0x70, 0x65, 0x72, 0x74, 0x79, 0x3e, 0x3c, 0x70, - 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, 0x20, - 0x6e, 0x61, 0x6d, 0x65, 0x3d, 0x22, 0x68, 0x65, - 0x78, 0x70, 0x61, 0x6e, 0x64, 0x22, 0x3e, 0x54, - 0x72, 0x75, 0x65, 0x3c, 0x2f, 0x70, 0x72, 0x6f, - 0x70, 0x65, 0x72, 0x74, 0x79, 0x3e, 0x3c, 0x70, - 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, 0x20, - 0x6e, 0x61, 0x6d, 0x65, 0x3d, 0x22, 0x6d, 0x6f, - 0x64, 0x65, 0x6c, 0x22, 0x3e, 0x70, 0x61, 0x67, - 0x65, 0x5f, 0x73, 0x69, 0x64, 0x65, 0x5f, 0x6d, - 0x6f, 0x64, 0x65, 0x6c, 0x3c, 0x2f, 0x70, 0x72, - 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, 0x3e, 0x3c, - 0x2f, 0x6f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x3e, - 0x3c, 0x70, 0x61, 0x63, 0x6b, 0x69, 0x6e, 0x67, - 0x3e, 0x3c, 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, - 0x74, 0x79, 0x20, 0x6e, 0x61, 0x6d, 0x65, 0x3d, - 0x22, 0x6c, 0x65, 0x66, 0x74, 0x5f, 0x61, 0x74, - 0x74, 0x61, 0x63, 0x68, 0x22, 0x3e, 0x31, 0x3c, - 0x2f, 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, - 0x79, 0x3e, 0x3c, 0x70, 0x72, 0x6f, 0x70, 0x65, - 0x72, 0x74, 0x79, 0x20, 0x6e, 0x61, 0x6d, 0x65, - 0x3d, 0x22, 0x74, 0x6f, 0x70, 0x5f, 0x61, 0x74, - 0x74, 0x61, 0x63, 0x68, 0x22, 0x3e, 0x33, 0x3c, - 0x2f, 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, - 0x79, 0x3e, 0x3c, 0x70, 0x72, 0x6f, 0x70, 0x65, - 0x72, 0x74, 0x79, 0x20, 0x6e, 0x61, 0x6d, 0x65, - 0x3d, 0x22, 0x77, 0x69, 0x64, 0x74, 0x68, 0x22, - 0x3e, 0x31, 0x3c, 0x2f, 0x70, 0x72, 0x6f, 0x70, - 0x65, 0x72, 0x74, 0x79, 0x3e, 0x3c, 0x70, 0x72, - 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, 0x20, 0x6e, - 0x61, 0x6d, 0x65, 0x3d, 0x22, 0x68, 0x65, 0x69, - 0x67, 0x68, 0x74, 0x22, 0x3e, 0x31, 0x3c, 0x2f, - 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, - 0x3e, 0x3c, 0x2f, 0x70, 0x61, 0x63, 0x6b, 0x69, - 0x6e, 0x67, 0x3e, 0x3c, 0x2f, 0x63, 0x68, 0x69, - 0x6c, 0x64, 0x3e, 0x3c, 0x63, 0x68, 0x69, 0x6c, - 0x64, 0x3e, 0x3c, 0x6f, 0x62, 0x6a, 0x65, 0x63, - 0x74, 0x20, 0x63, 0x6c, 0x61, 0x73, 0x73, 0x3d, - 0x22, 0x47, 0x74, 0x6b, 0x4c, 0x61, 0x62, 0x65, - 0x6c, 0x22, 0x20, 0x69, 0x64, 0x3d, 0x22, 0x70, - 0x61, 0x70, 0x65, 0x72, 0x5f, 0x73, 0x69, 0x7a, - 0x65, 0x5f, 0x6c, 0x61, 0x62, 0x65, 0x6c, 0x22, - 0x3e, 0x3c, 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, - 0x74, 0x79, 0x20, 0x6e, 0x61, 0x6d, 0x65, 0x3d, - 0x22, 0x76, 0x69, 0x73, 0x69, 0x62, 0x6c, 0x65, - 0x22, 0x3e, 0x54, 0x72, 0x75, 0x65, 0x3c, 0x2f, - 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, - 0x3e, 0x3c, 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, - 0x74, 0x79, 0x20, 0x6e, 0x61, 0x6d, 0x65, 0x3d, - 0x22, 0x63, 0x61, 0x6e, 0x5f, 0x66, 0x6f, 0x63, - 0x75, 0x73, 0x22, 0x3e, 0x46, 0x61, 0x6c, 0x73, - 0x65, 0x3c, 0x2f, 0x70, 0x72, 0x6f, 0x70, 0x65, - 0x72, 0x74, 0x79, 0x3e, 0x3c, 0x70, 0x72, 0x6f, - 0x70, 0x65, 0x72, 0x74, 0x79, 0x20, 0x6e, 0x61, - 0x6d, 0x65, 0x3d, 0x22, 0x78, 0x61, 0x6c, 0x69, - 0x67, 0x6e, 0x22, 0x3e, 0x30, 0x3c, 0x2f, 0x70, - 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, 0x3e, - 0x3c, 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, - 0x79, 0x20, 0x6e, 0x61, 0x6d, 0x65, 0x3d, 0x22, - 0x6c, 0x61, 0x62, 0x65, 0x6c, 0x22, 0x20, 0x74, - 0x72, 0x61, 0x6e, 0x73, 0x6c, 0x61, 0x74, 0x61, - 0x62, 0x6c, 0x65, 0x3d, 0x22, 0x79, 0x65, 0x73, - 0x22, 0x20, 0x63, 0x6f, 0x6d, 0x6d, 0x65, 0x6e, - 0x74, 0x73, 0x3d, 0x22, 0x4c, 0x61, 0x62, 0x65, - 0x6c, 0x20, 0x62, 0x65, 0x73, 0x69, 0x64, 0x65, - 0x20, 0x70, 0x61, 0x67, 0x65, 0x20, 0x73, 0x69, - 0x7a, 0x65, 0x20, 0x63, 0x6f, 0x6d, 0x62, 0x6f, - 0x20, 0x62, 0x6f, 0x78, 0x22, 0x3e, 0x50, 0x61, - 0x67, 0x65, 0x20, 0x53, 0x69, 0x7a, 0x65, 0x3a, - 0x3c, 0x2f, 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, - 0x74, 0x79, 0x3e, 0x3c, 0x70, 0x72, 0x6f, 0x70, - 0x65, 0x72, 0x74, 0x79, 0x20, 0x6e, 0x61, 0x6d, - 0x65, 0x3d, 0x22, 0x75, 0x73, 0x65, 0x5f, 0x75, - 0x6e, 0x64, 0x65, 0x72, 0x6c, 0x69, 0x6e, 0x65, - 0x22, 0x3e, 0x54, 0x72, 0x75, 0x65, 0x3c, 0x2f, - 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, - 0x3e, 0x3c, 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, - 0x74, 0x79, 0x20, 0x6e, 0x61, 0x6d, 0x65, 0x3d, - 0x22, 0x6d, 0x6e, 0x65, 0x6d, 0x6f, 0x6e, 0x69, - 0x63, 0x5f, 0x77, 0x69, 0x64, 0x67, 0x65, 0x74, - 0x22, 0x3e, 0x70, 0x68, 0x6f, 0x74, 0x6f, 0x5f, - 0x64, 0x70, 0x69, 0x5f, 0x63, 0x6f, 0x6d, 0x62, - 0x6f, 0x3c, 0x2f, 0x70, 0x72, 0x6f, 0x70, 0x65, - 0x72, 0x74, 0x79, 0x3e, 0x3c, 0x2f, 0x6f, 0x62, - 0x6a, 0x65, 0x63, 0x74, 0x3e, 0x3c, 0x70, 0x61, - 0x63, 0x6b, 0x69, 0x6e, 0x67, 0x3e, 0x3c, 0x70, - 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, 0x20, - 0x6e, 0x61, 0x6d, 0x65, 0x3d, 0x22, 0x6c, 0x65, - 0x66, 0x74, 0x5f, 0x61, 0x74, 0x74, 0x61, 0x63, - 0x68, 0x22, 0x3e, 0x30, 0x3c, 0x2f, 0x70, 0x72, - 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, 0x3e, 0x3c, - 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, - 0x20, 0x6e, 0x61, 0x6d, 0x65, 0x3d, 0x22, 0x74, - 0x6f, 0x70, 0x5f, 0x61, 0x74, 0x74, 0x61, 0x63, - 0x68, 0x22, 0x3e, 0x34, 0x3c, 0x2f, 0x70, 0x72, - 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, 0x3e, 0x3c, - 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, - 0x20, 0x6e, 0x61, 0x6d, 0x65, 0x3d, 0x22, 0x77, - 0x69, 0x64, 0x74, 0x68, 0x22, 0x3e, 0x31, 0x3c, - 0x2f, 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, - 0x79, 0x3e, 0x3c, 0x70, 0x72, 0x6f, 0x70, 0x65, - 0x72, 0x74, 0x79, 0x20, 0x6e, 0x61, 0x6d, 0x65, - 0x3d, 0x22, 0x68, 0x65, 0x69, 0x67, 0x68, 0x74, - 0x22, 0x3e, 0x31, 0x3c, 0x2f, 0x70, 0x72, 0x6f, - 0x70, 0x65, 0x72, 0x74, 0x79, 0x3e, 0x3c, 0x2f, - 0x70, 0x61, 0x63, 0x6b, 0x69, 0x6e, 0x67, 0x3e, - 0x3c, 0x2f, 0x63, 0x68, 0x69, 0x6c, 0x64, 0x3e, - 0x3c, 0x63, 0x68, 0x69, 0x6c, 0x64, 0x3e, 0x3c, - 0x6f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x20, 0x63, - 0x6c, 0x61, 0x73, 0x73, 0x3d, 0x22, 0x47, 0x74, - 0x6b, 0x43, 0x6f, 0x6d, 0x62, 0x6f, 0x42, 0x6f, - 0x78, 0x22, 0x20, 0x69, 0x64, 0x3d, 0x22, 0x70, - 0x61, 0x70, 0x65, 0x72, 0x5f, 0x73, 0x69, 0x7a, - 0x65, 0x5f, 0x63, 0x6f, 0x6d, 0x62, 0x6f, 0x22, - 0x3e, 0x3c, 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, - 0x74, 0x79, 0x20, 0x6e, 0x61, 0x6d, 0x65, 0x3d, - 0x22, 0x76, 0x69, 0x73, 0x69, 0x62, 0x6c, 0x65, - 0x22, 0x3e, 0x54, 0x72, 0x75, 0x65, 0x3c, 0x2f, - 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, - 0x3e, 0x3c, 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, - 0x74, 0x79, 0x20, 0x6e, 0x61, 0x6d, 0x65, 0x3d, - 0x22, 0x63, 0x61, 0x6e, 0x5f, 0x66, 0x6f, 0x63, - 0x75, 0x73, 0x22, 0x3e, 0x46, 0x61, 0x6c, 0x73, - 0x65, 0x3c, 0x2f, 0x70, 0x72, 0x6f, 0x70, 0x65, - 0x72, 0x74, 0x79, 0x3e, 0x3c, 0x70, 0x72, 0x6f, - 0x70, 0x65, 0x72, 0x74, 0x79, 0x20, 0x6e, 0x61, - 0x6d, 0x65, 0x3d, 0x22, 0x68, 0x65, 0x78, 0x70, - 0x61, 0x6e, 0x64, 0x22, 0x3e, 0x54, 0x72, 0x75, - 0x65, 0x3c, 0x2f, 0x70, 0x72, 0x6f, 0x70, 0x65, - 0x72, 0x74, 0x79, 0x3e, 0x3c, 0x70, 0x72, 0x6f, - 0x70, 0x65, 0x72, 0x74, 0x79, 0x20, 0x6e, 0x61, - 0x6d, 0x65, 0x3d, 0x22, 0x6d, 0x6f, 0x64, 0x65, - 0x6c, 0x22, 0x3e, 0x70, 0x61, 0x70, 0x65, 0x72, - 0x5f, 0x73, 0x69, 0x7a, 0x65, 0x5f, 0x6d, 0x6f, - 0x64, 0x65, 0x6c, 0x3c, 0x2f, 0x70, 0x72, 0x6f, - 0x70, 0x65, 0x72, 0x74, 0x79, 0x3e, 0x3c, 0x2f, - 0x6f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x3e, 0x3c, - 0x70, 0x61, 0x63, 0x6b, 0x69, 0x6e, 0x67, 0x3e, - 0x3c, 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, - 0x79, 0x20, 0x6e, 0x61, 0x6d, 0x65, 0x3d, 0x22, - 0x6c, 0x65, 0x66, 0x74, 0x5f, 0x61, 0x74, 0x74, - 0x61, 0x63, 0x68, 0x22, 0x3e, 0x31, 0x3c, 0x2f, - 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, - 0x3e, 0x3c, 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, - 0x74, 0x79, 0x20, 0x6e, 0x61, 0x6d, 0x65, 0x3d, - 0x22, 0x74, 0x6f, 0x70, 0x5f, 0x61, 0x74, 0x74, - 0x61, 0x63, 0x68, 0x22, 0x3e, 0x34, 0x3c, 0x2f, - 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, - 0x3e, 0x3c, 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, - 0x74, 0x79, 0x20, 0x6e, 0x61, 0x6d, 0x65, 0x3d, - 0x22, 0x77, 0x69, 0x64, 0x74, 0x68, 0x22, 0x3e, - 0x31, 0x3c, 0x2f, 0x70, 0x72, 0x6f, 0x70, 0x65, - 0x72, 0x74, 0x79, 0x3e, 0x3c, 0x70, 0x72, 0x6f, - 0x70, 0x65, 0x72, 0x74, 0x79, 0x20, 0x6e, 0x61, - 0x6d, 0x65, 0x3d, 0x22, 0x68, 0x65, 0x69, 0x67, - 0x68, 0x74, 0x22, 0x3e, 0x31, 0x3c, 0x2f, 0x70, - 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, 0x3e, - 0x3c, 0x2f, 0x70, 0x61, 0x63, 0x6b, 0x69, 0x6e, - 0x67, 0x3e, 0x3c, 0x2f, 0x63, 0x68, 0x69, 0x6c, - 0x64, 0x3e, 0x3c, 0x63, 0x68, 0x69, 0x6c, 0x64, - 0x3e, 0x3c, 0x6f, 0x62, 0x6a, 0x65, 0x63, 0x74, - 0x20, 0x63, 0x6c, 0x61, 0x73, 0x73, 0x3d, 0x22, - 0x47, 0x74, 0x6b, 0x4c, 0x61, 0x62, 0x65, 0x6c, - 0x22, 0x20, 0x69, 0x64, 0x3d, 0x22, 0x62, 0x72, - 0x69, 0x67, 0x68, 0x74, 0x6e, 0x65, 0x73, 0x73, - 0x5f, 0x6c, 0x61, 0x62, 0x65, 0x6c, 0x22, 0x3e, - 0x3c, 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, - 0x79, 0x20, 0x6e, 0x61, 0x6d, 0x65, 0x3d, 0x22, - 0x76, 0x69, 0x73, 0x69, 0x62, 0x6c, 0x65, 0x22, - 0x3e, 0x54, 0x72, 0x75, 0x65, 0x3c, 0x2f, 0x70, - 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, 0x3e, - 0x3c, 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, - 0x79, 0x20, 0x6e, 0x61, 0x6d, 0x65, 0x3d, 0x22, - 0x63, 0x61, 0x6e, 0x5f, 0x66, 0x6f, 0x63, 0x75, - 0x73, 0x22, 0x3e, 0x46, 0x61, 0x6c, 0x73, 0x65, - 0x3c, 0x2f, 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, - 0x74, 0x79, 0x3e, 0x3c, 0x70, 0x72, 0x6f, 0x70, - 0x65, 0x72, 0x74, 0x79, 0x20, 0x6e, 0x61, 0x6d, - 0x65, 0x3d, 0x22, 0x78, 0x61, 0x6c, 0x69, 0x67, - 0x6e, 0x22, 0x3e, 0x30, 0x3c, 0x2f, 0x70, 0x72, - 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, 0x3e, 0x3c, - 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, - 0x20, 0x6e, 0x61, 0x6d, 0x65, 0x3d, 0x22, 0x6c, - 0x61, 0x62, 0x65, 0x6c, 0x22, 0x20, 0x74, 0x72, - 0x61, 0x6e, 0x73, 0x6c, 0x61, 0x74, 0x61, 0x62, - 0x6c, 0x65, 0x3d, 0x22, 0x79, 0x65, 0x73, 0x22, - 0x20, 0x63, 0x6f, 0x6d, 0x6d, 0x65, 0x6e, 0x74, - 0x73, 0x3d, 0x22, 0x4c, 0x61, 0x62, 0x65, 0x6c, - 0x20, 0x62, 0x65, 0x73, 0x69, 0x64, 0x65, 0x20, - 0x62, 0x72, 0x69, 0x67, 0x68, 0x74, 0x6e, 0x65, - 0x73, 0x73, 0x20, 0x73, 0x63, 0x61, 0x6c, 0x65, - 0x22, 0x3e, 0x42, 0x72, 0x69, 0x67, 0x68, 0x74, - 0x6e, 0x65, 0x73, 0x73, 0x3a, 0x3c, 0x2f, 0x70, - 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, 0x3e, - 0x3c, 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, - 0x79, 0x20, 0x6e, 0x61, 0x6d, 0x65, 0x3d, 0x22, - 0x75, 0x73, 0x65, 0x5f, 0x75, 0x6e, 0x64, 0x65, - 0x72, 0x6c, 0x69, 0x6e, 0x65, 0x22, 0x3e, 0x54, - 0x72, 0x75, 0x65, 0x3c, 0x2f, 0x70, 0x72, 0x6f, - 0x70, 0x65, 0x72, 0x74, 0x79, 0x3e, 0x3c, 0x2f, - 0x6f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x3e, 0x3c, - 0x70, 0x61, 0x63, 0x6b, 0x69, 0x6e, 0x67, 0x3e, - 0x3c, 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, - 0x79, 0x20, 0x6e, 0x61, 0x6d, 0x65, 0x3d, 0x22, - 0x6c, 0x65, 0x66, 0x74, 0x5f, 0x61, 0x74, 0x74, - 0x61, 0x63, 0x68, 0x22, 0x3e, 0x30, 0x3c, 0x2f, - 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, - 0x3e, 0x3c, 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, - 0x74, 0x79, 0x20, 0x6e, 0x61, 0x6d, 0x65, 0x3d, - 0x22, 0x74, 0x6f, 0x70, 0x5f, 0x61, 0x74, 0x74, - 0x61, 0x63, 0x68, 0x22, 0x3e, 0x35, 0x3c, 0x2f, - 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, - 0x3e, 0x3c, 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, - 0x74, 0x79, 0x20, 0x6e, 0x61, 0x6d, 0x65, 0x3d, - 0x22, 0x77, 0x69, 0x64, 0x74, 0x68, 0x22, 0x3e, - 0x31, 0x3c, 0x2f, 0x70, 0x72, 0x6f, 0x70, 0x65, - 0x72, 0x74, 0x79, 0x3e, 0x3c, 0x70, 0x72, 0x6f, - 0x70, 0x65, 0x72, 0x74, 0x79, 0x20, 0x6e, 0x61, - 0x6d, 0x65, 0x3d, 0x22, 0x68, 0x65, 0x69, 0x67, - 0x68, 0x74, 0x22, 0x3e, 0x31, 0x3c, 0x2f, 0x70, - 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, 0x3e, - 0x3c, 0x2f, 0x70, 0x61, 0x63, 0x6b, 0x69, 0x6e, - 0x67, 0x3e, 0x3c, 0x2f, 0x63, 0x68, 0x69, 0x6c, - 0x64, 0x3e, 0x3c, 0x63, 0x68, 0x69, 0x6c, 0x64, - 0x3e, 0x3c, 0x6f, 0x62, 0x6a, 0x65, 0x63, 0x74, - 0x20, 0x63, 0x6c, 0x61, 0x73, 0x73, 0x3d, 0x22, - 0x47, 0x74, 0x6b, 0x53, 0x63, 0x61, 0x6c, 0x65, - 0x22, 0x20, 0x69, 0x64, 0x3d, 0x22, 0x62, 0x72, - 0x69, 0x67, 0x68, 0x74, 0x6e, 0x65, 0x73, 0x73, - 0x5f, 0x73, 0x63, 0x61, 0x6c, 0x65, 0x22, 0x3e, - 0x3c, 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, - 0x79, 0x20, 0x6e, 0x61, 0x6d, 0x65, 0x3d, 0x22, - 0x76, 0x69, 0x73, 0x69, 0x62, 0x6c, 0x65, 0x22, - 0x3e, 0x54, 0x72, 0x75, 0x65, 0x3c, 0x2f, 0x70, - 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, 0x3e, - 0x3c, 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, - 0x79, 0x20, 0x6e, 0x61, 0x6d, 0x65, 0x3d, 0x22, - 0x63, 0x61, 0x6e, 0x5f, 0x66, 0x6f, 0x63, 0x75, - 0x73, 0x22, 0x3e, 0x54, 0x72, 0x75, 0x65, 0x3c, - 0x2f, 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, - 0x79, 0x3e, 0x3c, 0x70, 0x72, 0x6f, 0x70, 0x65, - 0x72, 0x74, 0x79, 0x20, 0x6e, 0x61, 0x6d, 0x65, - 0x3d, 0x22, 0x68, 0x65, 0x78, 0x70, 0x61, 0x6e, - 0x64, 0x22, 0x3e, 0x54, 0x72, 0x75, 0x65, 0x3c, - 0x2f, 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, - 0x79, 0x3e, 0x3c, 0x70, 0x72, 0x6f, 0x70, 0x65, - 0x72, 0x74, 0x79, 0x20, 0x6e, 0x61, 0x6d, 0x65, - 0x3d, 0x22, 0x61, 0x64, 0x6a, 0x75, 0x73, 0x74, - 0x6d, 0x65, 0x6e, 0x74, 0x22, 0x3e, 0x62, 0x72, - 0x69, 0x67, 0x68, 0x74, 0x6e, 0x65, 0x73, 0x73, - 0x5f, 0x61, 0x64, 0x6a, 0x75, 0x73, 0x74, 0x6d, - 0x65, 0x6e, 0x74, 0x3c, 0x2f, 0x70, 0x72, 0x6f, - 0x70, 0x65, 0x72, 0x74, 0x79, 0x3e, 0x3c, 0x70, - 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, 0x20, - 0x6e, 0x61, 0x6d, 0x65, 0x3d, 0x22, 0x64, 0x72, - 0x61, 0x77, 0x5f, 0x76, 0x61, 0x6c, 0x75, 0x65, - 0x22, 0x3e, 0x46, 0x61, 0x6c, 0x73, 0x65, 0x3c, - 0x2f, 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, - 0x79, 0x3e, 0x3c, 0x2f, 0x6f, 0x62, 0x6a, 0x65, - 0x63, 0x74, 0x3e, 0x3c, 0x70, 0x61, 0x63, 0x6b, - 0x69, 0x6e, 0x67, 0x3e, 0x3c, 0x70, 0x72, 0x6f, - 0x70, 0x65, 0x72, 0x74, 0x79, 0x20, 0x6e, 0x61, - 0x6d, 0x65, 0x3d, 0x22, 0x6c, 0x65, 0x66, 0x74, - 0x5f, 0x61, 0x74, 0x74, 0x61, 0x63, 0x68, 0x22, - 0x3e, 0x31, 0x3c, 0x2f, 0x70, 0x72, 0x6f, 0x70, - 0x65, 0x72, 0x74, 0x79, 0x3e, 0x3c, 0x70, 0x72, - 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, 0x20, 0x6e, - 0x61, 0x6d, 0x65, 0x3d, 0x22, 0x74, 0x6f, 0x70, - 0x5f, 0x61, 0x74, 0x74, 0x61, 0x63, 0x68, 0x22, - 0x3e, 0x35, 0x3c, 0x2f, 0x70, 0x72, 0x6f, 0x70, - 0x65, 0x72, 0x74, 0x79, 0x3e, 0x3c, 0x70, 0x72, - 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, 0x20, 0x6e, - 0x61, 0x6d, 0x65, 0x3d, 0x22, 0x77, 0x69, 0x64, - 0x74, 0x68, 0x22, 0x3e, 0x31, 0x3c, 0x2f, 0x70, - 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, 0x3e, - 0x3c, 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, - 0x79, 0x20, 0x6e, 0x61, 0x6d, 0x65, 0x3d, 0x22, - 0x68, 0x65, 0x69, 0x67, 0x68, 0x74, 0x22, 0x3e, - 0x31, 0x3c, 0x2f, 0x70, 0x72, 0x6f, 0x70, 0x65, - 0x72, 0x74, 0x79, 0x3e, 0x3c, 0x2f, 0x70, 0x61, - 0x63, 0x6b, 0x69, 0x6e, 0x67, 0x3e, 0x3c, 0x2f, - 0x63, 0x68, 0x69, 0x6c, 0x64, 0x3e, 0x3c, 0x63, - 0x68, 0x69, 0x6c, 0x64, 0x3e, 0x3c, 0x6f, 0x62, - 0x6a, 0x65, 0x63, 0x74, 0x20, 0x63, 0x6c, 0x61, - 0x73, 0x73, 0x3d, 0x22, 0x47, 0x74, 0x6b, 0x4c, - 0x61, 0x62, 0x65, 0x6c, 0x22, 0x20, 0x69, 0x64, - 0x3d, 0x22, 0x63, 0x6f, 0x6e, 0x74, 0x72, 0x61, - 0x73, 0x74, 0x5f, 0x6c, 0x61, 0x62, 0x65, 0x6c, - 0x22, 0x3e, 0x3c, 0x70, 0x72, 0x6f, 0x70, 0x65, - 0x72, 0x74, 0x79, 0x20, 0x6e, 0x61, 0x6d, 0x65, - 0x3d, 0x22, 0x76, 0x69, 0x73, 0x69, 0x62, 0x6c, - 0x65, 0x22, 0x3e, 0x54, 0x72, 0x75, 0x65, 0x3c, - 0x2f, 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, - 0x79, 0x3e, 0x3c, 0x70, 0x72, 0x6f, 0x70, 0x65, - 0x72, 0x74, 0x79, 0x20, 0x6e, 0x61, 0x6d, 0x65, - 0x3d, 0x22, 0x63, 0x61, 0x6e, 0x5f, 0x66, 0x6f, - 0x63, 0x75, 0x73, 0x22, 0x3e, 0x46, 0x61, 0x6c, - 0x73, 0x65, 0x3c, 0x2f, 0x70, 0x72, 0x6f, 0x70, - 0x65, 0x72, 0x74, 0x79, 0x3e, 0x3c, 0x70, 0x72, - 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, 0x20, 0x6e, - 0x61, 0x6d, 0x65, 0x3d, 0x22, 0x78, 0x61, 0x6c, - 0x69, 0x67, 0x6e, 0x22, 0x3e, 0x30, 0x3c, 0x2f, - 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, - 0x3e, 0x3c, 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, - 0x74, 0x79, 0x20, 0x6e, 0x61, 0x6d, 0x65, 0x3d, - 0x22, 0x6c, 0x61, 0x62, 0x65, 0x6c, 0x22, 0x20, - 0x74, 0x72, 0x61, 0x6e, 0x73, 0x6c, 0x61, 0x74, - 0x61, 0x62, 0x6c, 0x65, 0x3d, 0x22, 0x79, 0x65, - 0x73, 0x22, 0x20, 0x63, 0x6f, 0x6d, 0x6d, 0x65, - 0x6e, 0x74, 0x73, 0x3d, 0x22, 0x4c, 0x61, 0x62, - 0x65, 0x6c, 0x20, 0x62, 0x65, 0x73, 0x69, 0x64, - 0x65, 0x20, 0x63, 0x6f, 0x6e, 0x74, 0x72, 0x61, - 0x73, 0x74, 0x20, 0x73, 0x63, 0x61, 0x6c, 0x65, - 0x22, 0x3e, 0x43, 0x6f, 0x6e, 0x74, 0x72, 0x61, - 0x73, 0x74, 0x3a, 0x3c, 0x2f, 0x70, 0x72, 0x6f, - 0x70, 0x65, 0x72, 0x74, 0x79, 0x3e, 0x3c, 0x70, - 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, 0x20, - 0x6e, 0x61, 0x6d, 0x65, 0x3d, 0x22, 0x75, 0x73, - 0x65, 0x5f, 0x75, 0x6e, 0x64, 0x65, 0x72, 0x6c, - 0x69, 0x6e, 0x65, 0x22, 0x3e, 0x54, 0x72, 0x75, - 0x65, 0x3c, 0x2f, 0x70, 0x72, 0x6f, 0x70, 0x65, - 0x72, 0x74, 0x79, 0x3e, 0x3c, 0x70, 0x72, 0x6f, - 0x70, 0x65, 0x72, 0x74, 0x79, 0x20, 0x6e, 0x61, - 0x6d, 0x65, 0x3d, 0x22, 0x6d, 0x6e, 0x65, 0x6d, - 0x6f, 0x6e, 0x69, 0x63, 0x5f, 0x77, 0x69, 0x64, - 0x67, 0x65, 0x74, 0x22, 0x3e, 0x63, 0x6f, 0x6e, - 0x74, 0x72, 0x61, 0x73, 0x74, 0x5f, 0x73, 0x63, - 0x61, 0x6c, 0x65, 0x3c, 0x2f, 0x70, 0x72, 0x6f, - 0x70, 0x65, 0x72, 0x74, 0x79, 0x3e, 0x3c, 0x2f, - 0x6f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x3e, 0x3c, - 0x70, 0x61, 0x63, 0x6b, 0x69, 0x6e, 0x67, 0x3e, - 0x3c, 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, - 0x79, 0x20, 0x6e, 0x61, 0x6d, 0x65, 0x3d, 0x22, - 0x6c, 0x65, 0x66, 0x74, 0x5f, 0x61, 0x74, 0x74, - 0x61, 0x63, 0x68, 0x22, 0x3e, 0x30, 0x3c, 0x2f, - 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, - 0x3e, 0x3c, 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, - 0x74, 0x79, 0x20, 0x6e, 0x61, 0x6d, 0x65, 0x3d, - 0x22, 0x74, 0x6f, 0x70, 0x5f, 0x61, 0x74, 0x74, - 0x61, 0x63, 0x68, 0x22, 0x3e, 0x36, 0x3c, 0x2f, - 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, - 0x3e, 0x3c, 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, - 0x74, 0x79, 0x20, 0x6e, 0x61, 0x6d, 0x65, 0x3d, - 0x22, 0x77, 0x69, 0x64, 0x74, 0x68, 0x22, 0x3e, - 0x31, 0x3c, 0x2f, 0x70, 0x72, 0x6f, 0x70, 0x65, - 0x72, 0x74, 0x79, 0x3e, 0x3c, 0x70, 0x72, 0x6f, - 0x70, 0x65, 0x72, 0x74, 0x79, 0x20, 0x6e, 0x61, - 0x6d, 0x65, 0x3d, 0x22, 0x68, 0x65, 0x69, 0x67, - 0x68, 0x74, 0x22, 0x3e, 0x31, 0x3c, 0x2f, 0x70, - 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, 0x3e, - 0x3c, 0x2f, 0x70, 0x61, 0x63, 0x6b, 0x69, 0x6e, - 0x67, 0x3e, 0x3c, 0x2f, 0x63, 0x68, 0x69, 0x6c, - 0x64, 0x3e, 0x3c, 0x63, 0x68, 0x69, 0x6c, 0x64, - 0x3e, 0x3c, 0x6f, 0x62, 0x6a, 0x65, 0x63, 0x74, - 0x20, 0x63, 0x6c, 0x61, 0x73, 0x73, 0x3d, 0x22, - 0x47, 0x74, 0x6b, 0x53, 0x63, 0x61, 0x6c, 0x65, - 0x22, 0x20, 0x69, 0x64, 0x3d, 0x22, 0x63, 0x6f, - 0x6e, 0x74, 0x72, 0x61, 0x73, 0x74, 0x5f, 0x73, - 0x63, 0x61, 0x6c, 0x65, 0x22, 0x3e, 0x3c, 0x70, - 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, 0x20, - 0x6e, 0x61, 0x6d, 0x65, 0x3d, 0x22, 0x76, 0x69, - 0x73, 0x69, 0x62, 0x6c, 0x65, 0x22, 0x3e, 0x54, - 0x72, 0x75, 0x65, 0x3c, 0x2f, 0x70, 0x72, 0x6f, - 0x70, 0x65, 0x72, 0x74, 0x79, 0x3e, 0x3c, 0x70, - 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, 0x20, - 0x6e, 0x61, 0x6d, 0x65, 0x3d, 0x22, 0x63, 0x61, - 0x6e, 0x5f, 0x66, 0x6f, 0x63, 0x75, 0x73, 0x22, - 0x3e, 0x54, 0x72, 0x75, 0x65, 0x3c, 0x2f, 0x70, - 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, 0x3e, - 0x3c, 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, - 0x79, 0x20, 0x6e, 0x61, 0x6d, 0x65, 0x3d, 0x22, - 0x68, 0x65, 0x78, 0x70, 0x61, 0x6e, 0x64, 0x22, - 0x3e, 0x54, 0x72, 0x75, 0x65, 0x3c, 0x2f, 0x70, - 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, 0x3e, - 0x3c, 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, - 0x79, 0x20, 0x6e, 0x61, 0x6d, 0x65, 0x3d, 0x22, - 0x61, 0x64, 0x6a, 0x75, 0x73, 0x74, 0x6d, 0x65, - 0x6e, 0x74, 0x22, 0x3e, 0x63, 0x6f, 0x6e, 0x74, - 0x72, 0x61, 0x73, 0x74, 0x5f, 0x61, 0x64, 0x6a, - 0x75, 0x73, 0x74, 0x6d, 0x65, 0x6e, 0x74, 0x3c, - 0x2f, 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, - 0x79, 0x3e, 0x3c, 0x70, 0x72, 0x6f, 0x70, 0x65, - 0x72, 0x74, 0x79, 0x20, 0x6e, 0x61, 0x6d, 0x65, - 0x3d, 0x22, 0x64, 0x72, 0x61, 0x77, 0x5f, 0x76, - 0x61, 0x6c, 0x75, 0x65, 0x22, 0x3e, 0x46, 0x61, - 0x6c, 0x73, 0x65, 0x3c, 0x2f, 0x70, 0x72, 0x6f, - 0x70, 0x65, 0x72, 0x74, 0x79, 0x3e, 0x3c, 0x2f, - 0x6f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x3e, 0x3c, - 0x70, 0x61, 0x63, 0x6b, 0x69, 0x6e, 0x67, 0x3e, - 0x3c, 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, - 0x79, 0x20, 0x6e, 0x61, 0x6d, 0x65, 0x3d, 0x22, - 0x6c, 0x65, 0x66, 0x74, 0x5f, 0x61, 0x74, 0x74, - 0x61, 0x63, 0x68, 0x22, 0x3e, 0x31, 0x3c, 0x2f, - 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, - 0x3e, 0x3c, 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, - 0x74, 0x79, 0x20, 0x6e, 0x61, 0x6d, 0x65, 0x3d, - 0x22, 0x74, 0x6f, 0x70, 0x5f, 0x61, 0x74, 0x74, - 0x61, 0x63, 0x68, 0x22, 0x3e, 0x36, 0x3c, 0x2f, - 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, - 0x3e, 0x3c, 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, - 0x74, 0x79, 0x20, 0x6e, 0x61, 0x6d, 0x65, 0x3d, - 0x22, 0x77, 0x69, 0x64, 0x74, 0x68, 0x22, 0x3e, - 0x31, 0x3c, 0x2f, 0x70, 0x72, 0x6f, 0x70, 0x65, - 0x72, 0x74, 0x79, 0x3e, 0x3c, 0x70, 0x72, 0x6f, - 0x70, 0x65, 0x72, 0x74, 0x79, 0x20, 0x6e, 0x61, - 0x6d, 0x65, 0x3d, 0x22, 0x68, 0x65, 0x69, 0x67, - 0x68, 0x74, 0x22, 0x3e, 0x31, 0x3c, 0x2f, 0x70, - 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, 0x3e, - 0x3c, 0x2f, 0x70, 0x61, 0x63, 0x6b, 0x69, 0x6e, - 0x67, 0x3e, 0x3c, 0x2f, 0x63, 0x68, 0x69, 0x6c, - 0x64, 0x3e, 0x3c, 0x63, 0x68, 0x69, 0x6c, 0x64, - 0x3e, 0x3c, 0x6f, 0x62, 0x6a, 0x65, 0x63, 0x74, - 0x20, 0x63, 0x6c, 0x61, 0x73, 0x73, 0x3d, 0x22, - 0x47, 0x74, 0x6b, 0x4c, 0x61, 0x62, 0x65, 0x6c, - 0x22, 0x20, 0x69, 0x64, 0x3d, 0x22, 0x71, 0x75, - 0x61, 0x6c, 0x69, 0x74, 0x79, 0x5f, 0x6c, 0x61, - 0x62, 0x65, 0x6c, 0x22, 0x3e, 0x3c, 0x70, 0x72, - 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, 0x20, 0x6e, - 0x61, 0x6d, 0x65, 0x3d, 0x22, 0x76, 0x69, 0x73, - 0x69, 0x62, 0x6c, 0x65, 0x22, 0x3e, 0x54, 0x72, - 0x75, 0x65, 0x3c, 0x2f, 0x70, 0x72, 0x6f, 0x70, - 0x65, 0x72, 0x74, 0x79, 0x3e, 0x3c, 0x70, 0x72, - 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, 0x20, 0x6e, - 0x61, 0x6d, 0x65, 0x3d, 0x22, 0x63, 0x61, 0x6e, - 0x5f, 0x66, 0x6f, 0x63, 0x75, 0x73, 0x22, 0x3e, - 0x46, 0x61, 0x6c, 0x73, 0x65, 0x3c, 0x2f, 0x70, - 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, 0x3e, - 0x3c, 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, - 0x79, 0x20, 0x6e, 0x61, 0x6d, 0x65, 0x3d, 0x22, - 0x78, 0x61, 0x6c, 0x69, 0x67, 0x6e, 0x22, 0x3e, - 0x30, 0x3c, 0x2f, 0x70, 0x72, 0x6f, 0x70, 0x65, - 0x72, 0x74, 0x79, 0x3e, 0x3c, 0x70, 0x72, 0x6f, - 0x70, 0x65, 0x72, 0x74, 0x79, 0x20, 0x6e, 0x61, - 0x6d, 0x65, 0x3d, 0x22, 0x6c, 0x61, 0x62, 0x65, - 0x6c, 0x22, 0x20, 0x74, 0x72, 0x61, 0x6e, 0x73, - 0x6c, 0x61, 0x74, 0x61, 0x62, 0x6c, 0x65, 0x3d, - 0x22, 0x79, 0x65, 0x73, 0x22, 0x20, 0x63, 0x6f, - 0x6d, 0x6d, 0x65, 0x6e, 0x74, 0x73, 0x3d, 0x22, - 0x4c, 0x61, 0x62, 0x65, 0x6c, 0x20, 0x62, 0x65, - 0x73, 0x69, 0x64, 0x65, 0x20, 0x71, 0x75, 0x61, - 0x6c, 0x69, 0x74, 0x79, 0x20, 0x73, 0x63, 0x61, - 0x6c, 0x65, 0x22, 0x3e, 0x51, 0x75, 0x61, 0x6c, - 0x69, 0x74, 0x79, 0x3a, 0x3c, 0x2f, 0x70, 0x72, - 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, 0x3e, 0x3c, - 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, - 0x20, 0x6e, 0x61, 0x6d, 0x65, 0x3d, 0x22, 0x75, - 0x73, 0x65, 0x5f, 0x75, 0x6e, 0x64, 0x65, 0x72, - 0x6c, 0x69, 0x6e, 0x65, 0x22, 0x3e, 0x54, 0x72, - 0x75, 0x65, 0x3c, 0x2f, 0x70, 0x72, 0x6f, 0x70, - 0x65, 0x72, 0x74, 0x79, 0x3e, 0x3c, 0x70, 0x72, - 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, 0x20, 0x6e, - 0x61, 0x6d, 0x65, 0x3d, 0x22, 0x6d, 0x6e, 0x65, - 0x6d, 0x6f, 0x6e, 0x69, 0x63, 0x5f, 0x77, 0x69, - 0x64, 0x67, 0x65, 0x74, 0x22, 0x3e, 0x71, 0x75, - 0x61, 0x6c, 0x69, 0x74, 0x79, 0x5f, 0x73, 0x63, - 0x61, 0x6c, 0x65, 0x3c, 0x2f, 0x70, 0x72, 0x6f, - 0x70, 0x65, 0x72, 0x74, 0x79, 0x3e, 0x3c, 0x2f, - 0x6f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x3e, 0x3c, - 0x70, 0x61, 0x63, 0x6b, 0x69, 0x6e, 0x67, 0x3e, - 0x3c, 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, - 0x79, 0x20, 0x6e, 0x61, 0x6d, 0x65, 0x3d, 0x22, - 0x6c, 0x65, 0x66, 0x74, 0x5f, 0x61, 0x74, 0x74, - 0x61, 0x63, 0x68, 0x22, 0x3e, 0x30, 0x3c, 0x2f, - 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, - 0x3e, 0x3c, 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, - 0x74, 0x79, 0x20, 0x6e, 0x61, 0x6d, 0x65, 0x3d, - 0x22, 0x74, 0x6f, 0x70, 0x5f, 0x61, 0x74, 0x74, - 0x61, 0x63, 0x68, 0x22, 0x3e, 0x37, 0x3c, 0x2f, - 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, - 0x3e, 0x3c, 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, - 0x74, 0x79, 0x20, 0x6e, 0x61, 0x6d, 0x65, 0x3d, - 0x22, 0x77, 0x69, 0x64, 0x74, 0x68, 0x22, 0x3e, - 0x31, 0x3c, 0x2f, 0x70, 0x72, 0x6f, 0x70, 0x65, - 0x72, 0x74, 0x79, 0x3e, 0x3c, 0x70, 0x72, 0x6f, - 0x70, 0x65, 0x72, 0x74, 0x79, 0x20, 0x6e, 0x61, - 0x6d, 0x65, 0x3d, 0x22, 0x68, 0x65, 0x69, 0x67, - 0x68, 0x74, 0x22, 0x3e, 0x31, 0x3c, 0x2f, 0x70, - 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, 0x3e, - 0x3c, 0x2f, 0x70, 0x61, 0x63, 0x6b, 0x69, 0x6e, - 0x67, 0x3e, 0x3c, 0x2f, 0x63, 0x68, 0x69, 0x6c, - 0x64, 0x3e, 0x3c, 0x63, 0x68, 0x69, 0x6c, 0x64, - 0x3e, 0x3c, 0x6f, 0x62, 0x6a, 0x65, 0x63, 0x74, - 0x20, 0x63, 0x6c, 0x61, 0x73, 0x73, 0x3d, 0x22, - 0x47, 0x74, 0x6b, 0x53, 0x63, 0x61, 0x6c, 0x65, - 0x22, 0x20, 0x69, 0x64, 0x3d, 0x22, 0x71, 0x75, - 0x61, 0x6c, 0x69, 0x74, 0x79, 0x5f, 0x73, 0x63, - 0x61, 0x6c, 0x65, 0x22, 0x3e, 0x3c, 0x70, 0x72, - 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, 0x20, 0x6e, - 0x61, 0x6d, 0x65, 0x3d, 0x22, 0x76, 0x69, 0x73, - 0x69, 0x62, 0x6c, 0x65, 0x22, 0x3e, 0x54, 0x72, - 0x75, 0x65, 0x3c, 0x2f, 0x70, 0x72, 0x6f, 0x70, - 0x65, 0x72, 0x74, 0x79, 0x3e, 0x3c, 0x70, 0x72, - 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, 0x20, 0x6e, - 0x61, 0x6d, 0x65, 0x3d, 0x22, 0x63, 0x61, 0x6e, - 0x5f, 0x66, 0x6f, 0x63, 0x75, 0x73, 0x22, 0x3e, - 0x54, 0x72, 0x75, 0x65, 0x3c, 0x2f, 0x70, 0x72, - 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, 0x3e, 0x3c, - 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, - 0x20, 0x6e, 0x61, 0x6d, 0x65, 0x3d, 0x22, 0x68, - 0x65, 0x78, 0x70, 0x61, 0x6e, 0x64, 0x22, 0x3e, - 0x54, 0x72, 0x75, 0x65, 0x3c, 0x2f, 0x70, 0x72, - 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, 0x3e, 0x3c, - 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, - 0x20, 0x6e, 0x61, 0x6d, 0x65, 0x3d, 0x22, 0x61, - 0x64, 0x6a, 0x75, 0x73, 0x74, 0x6d, 0x65, 0x6e, - 0x74, 0x22, 0x3e, 0x71, 0x75, 0x61, 0x6c, 0x69, - 0x74, 0x79, 0x5f, 0x61, 0x64, 0x6a, 0x75, 0x73, - 0x74, 0x6d, 0x65, 0x6e, 0x74, 0x3c, 0x2f, 0x70, - 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, 0x3e, - 0x3c, 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, - 0x79, 0x20, 0x6e, 0x61, 0x6d, 0x65, 0x3d, 0x22, - 0x64, 0x72, 0x61, 0x77, 0x5f, 0x76, 0x61, 0x6c, - 0x75, 0x65, 0x22, 0x3e, 0x46, 0x61, 0x6c, 0x73, - 0x65, 0x3c, 0x2f, 0x70, 0x72, 0x6f, 0x70, 0x65, - 0x72, 0x74, 0x79, 0x3e, 0x3c, 0x2f, 0x6f, 0x62, - 0x6a, 0x65, 0x63, 0x74, 0x3e, 0x3c, 0x70, 0x61, - 0x63, 0x6b, 0x69, 0x6e, 0x67, 0x3e, 0x3c, 0x70, - 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, 0x20, - 0x6e, 0x61, 0x6d, 0x65, 0x3d, 0x22, 0x6c, 0x65, - 0x66, 0x74, 0x5f, 0x61, 0x74, 0x74, 0x61, 0x63, - 0x68, 0x22, 0x3e, 0x31, 0x3c, 0x2f, 0x70, 0x72, - 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, 0x3e, 0x3c, - 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, - 0x20, 0x6e, 0x61, 0x6d, 0x65, 0x3d, 0x22, 0x74, - 0x6f, 0x70, 0x5f, 0x61, 0x74, 0x74, 0x61, 0x63, - 0x68, 0x22, 0x3e, 0x37, 0x3c, 0x2f, 0x70, 0x72, - 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, 0x3e, 0x3c, - 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, - 0x20, 0x6e, 0x61, 0x6d, 0x65, 0x3d, 0x22, 0x77, - 0x69, 0x64, 0x74, 0x68, 0x22, 0x3e, 0x31, 0x3c, - 0x2f, 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, - 0x79, 0x3e, 0x3c, 0x70, 0x72, 0x6f, 0x70, 0x65, - 0x72, 0x74, 0x79, 0x20, 0x6e, 0x61, 0x6d, 0x65, - 0x3d, 0x22, 0x68, 0x65, 0x69, 0x67, 0x68, 0x74, - 0x22, 0x3e, 0x31, 0x3c, 0x2f, 0x70, 0x72, 0x6f, - 0x70, 0x65, 0x72, 0x74, 0x79, 0x3e, 0x3c, 0x2f, - 0x70, 0x61, 0x63, 0x6b, 0x69, 0x6e, 0x67, 0x3e, - 0x3c, 0x2f, 0x63, 0x68, 0x69, 0x6c, 0x64, 0x3e, - 0x3c, 0x2f, 0x6f, 0x62, 0x6a, 0x65, 0x63, 0x74, - 0x3e, 0x3c, 0x70, 0x61, 0x63, 0x6b, 0x69, 0x6e, - 0x67, 0x3e, 0x3c, 0x70, 0x72, 0x6f, 0x70, 0x65, - 0x72, 0x74, 0x79, 0x20, 0x6e, 0x61, 0x6d, 0x65, - 0x3d, 0x22, 0x65, 0x78, 0x70, 0x61, 0x6e, 0x64, - 0x22, 0x3e, 0x46, 0x61, 0x6c, 0x73, 0x65, 0x3c, - 0x2f, 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, - 0x79, 0x3e, 0x3c, 0x70, 0x72, 0x6f, 0x70, 0x65, - 0x72, 0x74, 0x79, 0x20, 0x6e, 0x61, 0x6d, 0x65, - 0x3d, 0x22, 0x66, 0x69, 0x6c, 0x6c, 0x22, 0x3e, - 0x54, 0x72, 0x75, 0x65, 0x3c, 0x2f, 0x70, 0x72, - 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, 0x3e, 0x3c, - 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, - 0x20, 0x6e, 0x61, 0x6d, 0x65, 0x3d, 0x22, 0x70, - 0x6f, 0x73, 0x69, 0x74, 0x69, 0x6f, 0x6e, 0x22, - 0x3e, 0x31, 0x3c, 0x2f, 0x70, 0x72, 0x6f, 0x70, - 0x65, 0x72, 0x74, 0x79, 0x3e, 0x3c, 0x2f, 0x70, - 0x61, 0x63, 0x6b, 0x69, 0x6e, 0x67, 0x3e, 0x3c, - 0x2f, 0x63, 0x68, 0x69, 0x6c, 0x64, 0x3e, 0x3c, - 0x2f, 0x6f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x3e, - 0x3c, 0x2f, 0x63, 0x68, 0x69, 0x6c, 0x64, 0x3e, - 0x3c, 0x61, 0x63, 0x74, 0x69, 0x6f, 0x6e, 0x2d, - 0x77, 0x69, 0x64, 0x67, 0x65, 0x74, 0x73, 0x3e, - 0x3c, 0x61, 0x63, 0x74, 0x69, 0x6f, 0x6e, 0x2d, - 0x77, 0x69, 0x64, 0x67, 0x65, 0x74, 0x20, 0x72, - 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x3d, - 0x22, 0x31, 0x22, 0x3e, 0x70, 0x72, 0x65, 0x66, - 0x65, 0x72, 0x65, 0x6e, 0x63, 0x65, 0x73, 0x5f, - 0x63, 0x6c, 0x6f, 0x73, 0x65, 0x5f, 0x62, 0x75, - 0x74, 0x74, 0x6f, 0x6e, 0x3c, 0x2f, 0x61, 0x63, - 0x74, 0x69, 0x6f, 0x6e, 0x2d, 0x77, 0x69, 0x64, - 0x67, 0x65, 0x74, 0x3e, 0x3c, 0x2f, 0x61, 0x63, - 0x74, 0x69, 0x6f, 0x6e, 0x2d, 0x77, 0x69, 0x64, - 0x67, 0x65, 0x74, 0x73, 0x3e, 0x3c, 0x2f, 0x6f, - 0x62, 0x6a, 0x65, 0x63, 0x74, 0x3e, 0x3c, 0x6f, - 0x62, 0x6a, 0x65, 0x63, 0x74, 0x20, 0x63, 0x6c, - 0x61, 0x73, 0x73, 0x3d, 0x22, 0x47, 0x74, 0x6b, - 0x4d, 0x65, 0x6e, 0x75, 0x22, 0x20, 0x69, 0x64, - 0x3d, 0x22, 0x73, 0x63, 0x61, 0x6e, 0x5f, 0x62, - 0x75, 0x74, 0x74, 0x6f, 0x6e, 0x5f, 0x6d, 0x65, - 0x6e, 0x75, 0x22, 0x3e, 0x3c, 0x70, 0x72, 0x6f, - 0x70, 0x65, 0x72, 0x74, 0x79, 0x20, 0x6e, 0x61, - 0x6d, 0x65, 0x3d, 0x22, 0x76, 0x69, 0x73, 0x69, - 0x62, 0x6c, 0x65, 0x22, 0x3e, 0x54, 0x72, 0x75, - 0x65, 0x3c, 0x2f, 0x70, 0x72, 0x6f, 0x70, 0x65, - 0x72, 0x74, 0x79, 0x3e, 0x3c, 0x70, 0x72, 0x6f, - 0x70, 0x65, 0x72, 0x74, 0x79, 0x20, 0x6e, 0x61, - 0x6d, 0x65, 0x3d, 0x22, 0x63, 0x61, 0x6e, 0x5f, - 0x66, 0x6f, 0x63, 0x75, 0x73, 0x22, 0x3e, 0x46, - 0x61, 0x6c, 0x73, 0x65, 0x3c, 0x2f, 0x70, 0x72, - 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, 0x3e, 0x3c, - 0x63, 0x68, 0x69, 0x6c, 0x64, 0x3e, 0x3c, 0x6f, - 0x62, 0x6a, 0x65, 0x63, 0x74, 0x20, 0x63, 0x6c, - 0x61, 0x73, 0x73, 0x3d, 0x22, 0x47, 0x74, 0x6b, - 0x4d, 0x65, 0x6e, 0x75, 0x49, 0x74, 0x65, 0x6d, - 0x22, 0x20, 0x69, 0x64, 0x3d, 0x22, 0x73, 0x63, - 0x61, 0x6e, 0x5f, 0x73, 0x69, 0x6e, 0x67, 0x6c, - 0x65, 0x5f, 0x62, 0x75, 0x74, 0x74, 0x6f, 0x6e, - 0x5f, 0x6d, 0x65, 0x6e, 0x75, 0x69, 0x74, 0x65, - 0x6d, 0x22, 0x3e, 0x3c, 0x70, 0x72, 0x6f, 0x70, - 0x65, 0x72, 0x74, 0x79, 0x20, 0x6e, 0x61, 0x6d, - 0x65, 0x3d, 0x22, 0x76, 0x69, 0x73, 0x69, 0x62, - 0x6c, 0x65, 0x22, 0x3e, 0x54, 0x72, 0x75, 0x65, - 0x3c, 0x2f, 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, - 0x74, 0x79, 0x3e, 0x3c, 0x70, 0x72, 0x6f, 0x70, - 0x65, 0x72, 0x74, 0x79, 0x20, 0x6e, 0x61, 0x6d, - 0x65, 0x3d, 0x22, 0x63, 0x61, 0x6e, 0x5f, 0x66, - 0x6f, 0x63, 0x75, 0x73, 0x22, 0x3e, 0x46, 0x61, - 0x6c, 0x73, 0x65, 0x3c, 0x2f, 0x70, 0x72, 0x6f, - 0x70, 0x65, 0x72, 0x74, 0x79, 0x3e, 0x3c, 0x70, - 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, 0x20, - 0x6e, 0x61, 0x6d, 0x65, 0x3d, 0x22, 0x6c, 0x61, - 0x62, 0x65, 0x6c, 0x22, 0x20, 0x74, 0x72, 0x61, - 0x6e, 0x73, 0x6c, 0x61, 0x74, 0x61, 0x62, 0x6c, - 0x65, 0x3d, 0x22, 0x79, 0x65, 0x73, 0x22, 0x20, - 0x63, 0x6f, 0x6d, 0x6d, 0x65, 0x6e, 0x74, 0x73, - 0x3d, 0x22, 0x54, 0x6f, 0x6f, 0x6c, 0x62, 0x61, - 0x72, 0x20, 0x73, 0x63, 0x61, 0x6e, 0x20, 0x6d, - 0x65, 0x6e, 0x75, 0x20, 0x69, 0x74, 0x65, 0x6d, - 0x20, 0x74, 0x6f, 0x20, 0x73, 0x63, 0x61, 0x6e, - 0x20, 0x61, 0x20, 0x73, 0x69, 0x6e, 0x67, 0x6c, - 0x65, 0x20, 0x70, 0x61, 0x67, 0x65, 0x20, 0x66, - 0x72, 0x6f, 0x6d, 0x20, 0x74, 0x68, 0x65, 0x20, - 0x73, 0x63, 0x61, 0x6e, 0x6e, 0x65, 0x72, 0x22, - 0x3e, 0x53, 0x69, 0x6e, 0x67, 0x6c, 0x65, 0x20, - 0x5f, 0x50, 0x61, 0x67, 0x65, 0x3c, 0x2f, 0x70, - 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, 0x3e, - 0x3c, 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, - 0x79, 0x20, 0x6e, 0x61, 0x6d, 0x65, 0x3d, 0x22, - 0x75, 0x73, 0x65, 0x5f, 0x75, 0x6e, 0x64, 0x65, - 0x72, 0x6c, 0x69, 0x6e, 0x65, 0x22, 0x3e, 0x54, - 0x72, 0x75, 0x65, 0x3c, 0x2f, 0x70, 0x72, 0x6f, - 0x70, 0x65, 0x72, 0x74, 0x79, 0x3e, 0x3c, 0x73, - 0x69, 0x67, 0x6e, 0x61, 0x6c, 0x20, 0x6e, 0x61, - 0x6d, 0x65, 0x3d, 0x22, 0x61, 0x63, 0x74, 0x69, - 0x76, 0x61, 0x74, 0x65, 0x22, 0x20, 0x68, 0x61, - 0x6e, 0x64, 0x6c, 0x65, 0x72, 0x3d, 0x22, 0x73, - 0x63, 0x61, 0x6e, 0x5f, 0x62, 0x75, 0x74, 0x74, - 0x6f, 0x6e, 0x5f, 0x63, 0x6c, 0x69, 0x63, 0x6b, - 0x65, 0x64, 0x5f, 0x63, 0x62, 0x22, 0x20, 0x73, - 0x77, 0x61, 0x70, 0x70, 0x65, 0x64, 0x3d, 0x22, - 0x6e, 0x6f, 0x22, 0x2f, 0x3e, 0x3c, 0x2f, 0x6f, - 0x62, 0x6a, 0x65, 0x63, 0x74, 0x3e, 0x3c, 0x2f, - 0x63, 0x68, 0x69, 0x6c, 0x64, 0x3e, 0x3c, 0x63, - 0x68, 0x69, 0x6c, 0x64, 0x3e, 0x3c, 0x6f, 0x62, - 0x6a, 0x65, 0x63, 0x74, 0x20, 0x63, 0x6c, 0x61, - 0x73, 0x73, 0x3d, 0x22, 0x47, 0x74, 0x6b, 0x4d, - 0x65, 0x6e, 0x75, 0x49, 0x74, 0x65, 0x6d, 0x22, - 0x20, 0x69, 0x64, 0x3d, 0x22, 0x73, 0x63, 0x61, - 0x6e, 0x5f, 0x61, 0x6c, 0x6c, 0x5f, 0x62, 0x75, - 0x74, 0x74, 0x6f, 0x6e, 0x5f, 0x6d, 0x65, 0x6e, - 0x75, 0x69, 0x74, 0x65, 0x6d, 0x22, 0x3e, 0x3c, - 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, - 0x20, 0x6e, 0x61, 0x6d, 0x65, 0x3d, 0x22, 0x76, - 0x69, 0x73, 0x69, 0x62, 0x6c, 0x65, 0x22, 0x3e, - 0x54, 0x72, 0x75, 0x65, 0x3c, 0x2f, 0x70, 0x72, - 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, 0x3e, 0x3c, - 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, - 0x20, 0x6e, 0x61, 0x6d, 0x65, 0x3d, 0x22, 0x63, - 0x61, 0x6e, 0x5f, 0x66, 0x6f, 0x63, 0x75, 0x73, - 0x22, 0x3e, 0x46, 0x61, 0x6c, 0x73, 0x65, 0x3c, - 0x2f, 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, - 0x79, 0x3e, 0x3c, 0x70, 0x72, 0x6f, 0x70, 0x65, - 0x72, 0x74, 0x79, 0x20, 0x6e, 0x61, 0x6d, 0x65, - 0x3d, 0x22, 0x6c, 0x61, 0x62, 0x65, 0x6c, 0x22, - 0x20, 0x74, 0x72, 0x61, 0x6e, 0x73, 0x6c, 0x61, - 0x74, 0x61, 0x62, 0x6c, 0x65, 0x3d, 0x22, 0x79, - 0x65, 0x73, 0x22, 0x20, 0x63, 0x6f, 0x6d, 0x6d, - 0x65, 0x6e, 0x74, 0x73, 0x3d, 0x22, 0x54, 0x6f, - 0x6f, 0x6c, 0x62, 0x61, 0x72, 0x20, 0x73, 0x63, - 0x61, 0x6e, 0x20, 0x6d, 0x65, 0x6e, 0x75, 0x20, - 0x69, 0x74, 0x65, 0x6d, 0x20, 0x74, 0x6f, 0x20, - 0x73, 0x63, 0x61, 0x6e, 0x20, 0x61, 0x6c, 0x6c, - 0x20, 0x70, 0x61, 0x67, 0x65, 0x73, 0x20, 0x66, - 0x72, 0x6f, 0x6d, 0x20, 0x61, 0x20, 0x64, 0x6f, - 0x63, 0x75, 0x6d, 0x65, 0x6e, 0x74, 0x20, 0x66, - 0x65, 0x65, 0x64, 0x65, 0x72, 0x22, 0x3e, 0x41, - 0x6c, 0x6c, 0x20, 0x50, 0x61, 0x67, 0x65, 0x73, - 0x20, 0x46, 0x72, 0x6f, 0x6d, 0x20, 0x5f, 0x46, - 0x65, 0x65, 0x64, 0x65, 0x72, 0x3c, 0x2f, 0x70, - 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, 0x3e, - 0x3c, 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, - 0x79, 0x20, 0x6e, 0x61, 0x6d, 0x65, 0x3d, 0x22, - 0x75, 0x73, 0x65, 0x5f, 0x75, 0x6e, 0x64, 0x65, - 0x72, 0x6c, 0x69, 0x6e, 0x65, 0x22, 0x3e, 0x54, - 0x72, 0x75, 0x65, 0x3c, 0x2f, 0x70, 0x72, 0x6f, - 0x70, 0x65, 0x72, 0x74, 0x79, 0x3e, 0x3c, 0x73, - 0x69, 0x67, 0x6e, 0x61, 0x6c, 0x20, 0x6e, 0x61, - 0x6d, 0x65, 0x3d, 0x22, 0x61, 0x63, 0x74, 0x69, - 0x76, 0x61, 0x74, 0x65, 0x22, 0x20, 0x68, 0x61, - 0x6e, 0x64, 0x6c, 0x65, 0x72, 0x3d, 0x22, 0x63, - 0x6f, 0x6e, 0x74, 0x69, 0x6e, 0x75, 0x6f, 0x75, - 0x73, 0x5f, 0x73, 0x63, 0x61, 0x6e, 0x5f, 0x62, - 0x75, 0x74, 0x74, 0x6f, 0x6e, 0x5f, 0x63, 0x6c, - 0x69, 0x63, 0x6b, 0x65, 0x64, 0x5f, 0x63, 0x62, - 0x22, 0x20, 0x73, 0x77, 0x61, 0x70, 0x70, 0x65, - 0x64, 0x3d, 0x22, 0x6e, 0x6f, 0x22, 0x2f, 0x3e, - 0x3c, 0x2f, 0x6f, 0x62, 0x6a, 0x65, 0x63, 0x74, - 0x3e, 0x3c, 0x2f, 0x63, 0x68, 0x69, 0x6c, 0x64, - 0x3e, 0x3c, 0x63, 0x68, 0x69, 0x6c, 0x64, 0x3e, - 0x3c, 0x6f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x20, - 0x63, 0x6c, 0x61, 0x73, 0x73, 0x3d, 0x22, 0x47, - 0x74, 0x6b, 0x53, 0x65, 0x70, 0x61, 0x72, 0x61, - 0x74, 0x6f, 0x72, 0x4d, 0x65, 0x6e, 0x75, 0x49, - 0x74, 0x65, 0x6d, 0x22, 0x20, 0x69, 0x64, 0x3d, - 0x22, 0x6d, 0x65, 0x6e, 0x75, 0x69, 0x74, 0x65, - 0x6d, 0x31, 0x22, 0x3e, 0x3c, 0x70, 0x72, 0x6f, - 0x70, 0x65, 0x72, 0x74, 0x79, 0x20, 0x6e, 0x61, - 0x6d, 0x65, 0x3d, 0x22, 0x76, 0x69, 0x73, 0x69, - 0x62, 0x6c, 0x65, 0x22, 0x3e, 0x54, 0x72, 0x75, - 0x65, 0x3c, 0x2f, 0x70, 0x72, 0x6f, 0x70, 0x65, - 0x72, 0x74, 0x79, 0x3e, 0x3c, 0x70, 0x72, 0x6f, - 0x70, 0x65, 0x72, 0x74, 0x79, 0x20, 0x6e, 0x61, - 0x6d, 0x65, 0x3d, 0x22, 0x63, 0x61, 0x6e, 0x5f, - 0x66, 0x6f, 0x63, 0x75, 0x73, 0x22, 0x3e, 0x46, - 0x61, 0x6c, 0x73, 0x65, 0x3c, 0x2f, 0x70, 0x72, - 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, 0x3e, 0x3c, - 0x2f, 0x6f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x3e, - 0x3c, 0x2f, 0x63, 0x68, 0x69, 0x6c, 0x64, 0x3e, - 0x3c, 0x63, 0x68, 0x69, 0x6c, 0x64, 0x3e, 0x3c, - 0x6f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x20, 0x63, - 0x6c, 0x61, 0x73, 0x73, 0x3d, 0x22, 0x47, 0x74, - 0x6b, 0x52, 0x61, 0x64, 0x69, 0x6f, 0x4d, 0x65, - 0x6e, 0x75, 0x49, 0x74, 0x65, 0x6d, 0x22, 0x20, - 0x69, 0x64, 0x3d, 0x22, 0x74, 0x65, 0x78, 0x74, - 0x5f, 0x62, 0x75, 0x74, 0x74, 0x6f, 0x6e, 0x5f, - 0x6d, 0x65, 0x6e, 0x75, 0x69, 0x74, 0x65, 0x6d, - 0x22, 0x3e, 0x3c, 0x70, 0x72, 0x6f, 0x70, 0x65, - 0x72, 0x74, 0x79, 0x20, 0x6e, 0x61, 0x6d, 0x65, - 0x3d, 0x22, 0x76, 0x69, 0x73, 0x69, 0x62, 0x6c, - 0x65, 0x22, 0x3e, 0x54, 0x72, 0x75, 0x65, 0x3c, - 0x2f, 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, - 0x79, 0x3e, 0x3c, 0x70, 0x72, 0x6f, 0x70, 0x65, - 0x72, 0x74, 0x79, 0x20, 0x6e, 0x61, 0x6d, 0x65, - 0x3d, 0x22, 0x63, 0x61, 0x6e, 0x5f, 0x66, 0x6f, - 0x63, 0x75, 0x73, 0x22, 0x3e, 0x46, 0x61, 0x6c, - 0x73, 0x65, 0x3c, 0x2f, 0x70, 0x72, 0x6f, 0x70, - 0x65, 0x72, 0x74, 0x79, 0x3e, 0x3c, 0x70, 0x72, - 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, 0x20, 0x6e, - 0x61, 0x6d, 0x65, 0x3d, 0x22, 0x6c, 0x61, 0x62, - 0x65, 0x6c, 0x22, 0x20, 0x74, 0x72, 0x61, 0x6e, - 0x73, 0x6c, 0x61, 0x74, 0x61, 0x62, 0x6c, 0x65, - 0x3d, 0x22, 0x79, 0x65, 0x73, 0x22, 0x3e, 0x54, - 0x65, 0x78, 0x74, 0x3c, 0x2f, 0x70, 0x72, 0x6f, - 0x70, 0x65, 0x72, 0x74, 0x79, 0x3e, 0x3c, 0x70, - 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, 0x20, - 0x6e, 0x61, 0x6d, 0x65, 0x3d, 0x22, 0x75, 0x73, - 0x65, 0x5f, 0x75, 0x6e, 0x64, 0x65, 0x72, 0x6c, - 0x69, 0x6e, 0x65, 0x22, 0x3e, 0x54, 0x72, 0x75, - 0x65, 0x3c, 0x2f, 0x70, 0x72, 0x6f, 0x70, 0x65, - 0x72, 0x74, 0x79, 0x3e, 0x3c, 0x70, 0x72, 0x6f, - 0x70, 0x65, 0x72, 0x74, 0x79, 0x20, 0x6e, 0x61, - 0x6d, 0x65, 0x3d, 0x22, 0x64, 0x72, 0x61, 0x77, - 0x5f, 0x61, 0x73, 0x5f, 0x72, 0x61, 0x64, 0x69, - 0x6f, 0x22, 0x3e, 0x54, 0x72, 0x75, 0x65, 0x3c, - 0x2f, 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, - 0x79, 0x3e, 0x3c, 0x73, 0x69, 0x67, 0x6e, 0x61, - 0x6c, 0x20, 0x6e, 0x61, 0x6d, 0x65, 0x3d, 0x22, - 0x74, 0x6f, 0x67, 0x67, 0x6c, 0x65, 0x64, 0x22, - 0x20, 0x68, 0x61, 0x6e, 0x64, 0x6c, 0x65, 0x72, - 0x3d, 0x22, 0x74, 0x65, 0x78, 0x74, 0x5f, 0x6d, - 0x65, 0x6e, 0x75, 0x69, 0x74, 0x65, 0x6d, 0x5f, - 0x74, 0x6f, 0x67, 0x67, 0x6c, 0x65, 0x64, 0x5f, - 0x63, 0x62, 0x22, 0x20, 0x73, 0x77, 0x61, 0x70, - 0x70, 0x65, 0x64, 0x3d, 0x22, 0x6e, 0x6f, 0x22, - 0x2f, 0x3e, 0x3c, 0x2f, 0x6f, 0x62, 0x6a, 0x65, - 0x63, 0x74, 0x3e, 0x3c, 0x2f, 0x63, 0x68, 0x69, - 0x6c, 0x64, 0x3e, 0x3c, 0x63, 0x68, 0x69, 0x6c, - 0x64, 0x3e, 0x3c, 0x6f, 0x62, 0x6a, 0x65, 0x63, - 0x74, 0x20, 0x63, 0x6c, 0x61, 0x73, 0x73, 0x3d, - 0x22, 0x47, 0x74, 0x6b, 0x52, 0x61, 0x64, 0x69, - 0x6f, 0x4d, 0x65, 0x6e, 0x75, 0x49, 0x74, 0x65, - 0x6d, 0x22, 0x20, 0x69, 0x64, 0x3d, 0x22, 0x70, - 0x68, 0x6f, 0x74, 0x6f, 0x5f, 0x62, 0x75, 0x74, - 0x74, 0x6f, 0x6e, 0x5f, 0x6d, 0x65, 0x6e, 0x75, - 0x69, 0x74, 0x65, 0x6d, 0x22, 0x3e, 0x3c, 0x70, - 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, 0x20, - 0x6e, 0x61, 0x6d, 0x65, 0x3d, 0x22, 0x76, 0x69, - 0x73, 0x69, 0x62, 0x6c, 0x65, 0x22, 0x3e, 0x54, - 0x72, 0x75, 0x65, 0x3c, 0x2f, 0x70, 0x72, 0x6f, - 0x70, 0x65, 0x72, 0x74, 0x79, 0x3e, 0x3c, 0x70, - 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, 0x20, - 0x6e, 0x61, 0x6d, 0x65, 0x3d, 0x22, 0x63, 0x61, - 0x6e, 0x5f, 0x66, 0x6f, 0x63, 0x75, 0x73, 0x22, - 0x3e, 0x46, 0x61, 0x6c, 0x73, 0x65, 0x3c, 0x2f, - 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, - 0x3e, 0x3c, 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, - 0x74, 0x79, 0x20, 0x6e, 0x61, 0x6d, 0x65, 0x3d, - 0x22, 0x6c, 0x61, 0x62, 0x65, 0x6c, 0x22, 0x20, - 0x74, 0x72, 0x61, 0x6e, 0x73, 0x6c, 0x61, 0x74, - 0x61, 0x62, 0x6c, 0x65, 0x3d, 0x22, 0x79, 0x65, - 0x73, 0x22, 0x3e, 0x50, 0x68, 0x6f, 0x74, 0x6f, - 0x3c, 0x2f, 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, - 0x74, 0x79, 0x3e, 0x3c, 0x70, 0x72, 0x6f, 0x70, - 0x65, 0x72, 0x74, 0x79, 0x20, 0x6e, 0x61, 0x6d, - 0x65, 0x3d, 0x22, 0x75, 0x73, 0x65, 0x5f, 0x75, - 0x6e, 0x64, 0x65, 0x72, 0x6c, 0x69, 0x6e, 0x65, - 0x22, 0x3e, 0x54, 0x72, 0x75, 0x65, 0x3c, 0x2f, - 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, - 0x3e, 0x3c, 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, - 0x74, 0x79, 0x20, 0x6e, 0x61, 0x6d, 0x65, 0x3d, - 0x22, 0x61, 0x63, 0x74, 0x69, 0x76, 0x65, 0x22, - 0x3e, 0x54, 0x72, 0x75, 0x65, 0x3c, 0x2f, 0x70, - 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, 0x3e, - 0x3c, 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, - 0x79, 0x20, 0x6e, 0x61, 0x6d, 0x65, 0x3d, 0x22, - 0x64, 0x72, 0x61, 0x77, 0x5f, 0x61, 0x73, 0x5f, - 0x72, 0x61, 0x64, 0x69, 0x6f, 0x22, 0x3e, 0x54, - 0x72, 0x75, 0x65, 0x3c, 0x2f, 0x70, 0x72, 0x6f, - 0x70, 0x65, 0x72, 0x74, 0x79, 0x3e, 0x3c, 0x70, - 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, 0x20, - 0x6e, 0x61, 0x6d, 0x65, 0x3d, 0x22, 0x67, 0x72, - 0x6f, 0x75, 0x70, 0x22, 0x3e, 0x74, 0x65, 0x78, - 0x74, 0x5f, 0x62, 0x75, 0x74, 0x74, 0x6f, 0x6e, - 0x5f, 0x6d, 0x65, 0x6e, 0x75, 0x69, 0x74, 0x65, - 0x6d, 0x3c, 0x2f, 0x70, 0x72, 0x6f, 0x70, 0x65, - 0x72, 0x74, 0x79, 0x3e, 0x3c, 0x73, 0x69, 0x67, - 0x6e, 0x61, 0x6c, 0x20, 0x6e, 0x61, 0x6d, 0x65, - 0x3d, 0x22, 0x74, 0x6f, 0x67, 0x67, 0x6c, 0x65, - 0x64, 0x22, 0x20, 0x68, 0x61, 0x6e, 0x64, 0x6c, - 0x65, 0x72, 0x3d, 0x22, 0x70, 0x68, 0x6f, 0x74, - 0x6f, 0x5f, 0x6d, 0x65, 0x6e, 0x75, 0x69, 0x74, - 0x65, 0x6d, 0x5f, 0x74, 0x6f, 0x67, 0x67, 0x6c, - 0x65, 0x64, 0x5f, 0x63, 0x62, 0x22, 0x20, 0x73, - 0x77, 0x61, 0x70, 0x70, 0x65, 0x64, 0x3d, 0x22, - 0x6e, 0x6f, 0x22, 0x2f, 0x3e, 0x3c, 0x2f, 0x6f, - 0x62, 0x6a, 0x65, 0x63, 0x74, 0x3e, 0x3c, 0x2f, - 0x63, 0x68, 0x69, 0x6c, 0x64, 0x3e, 0x3c, 0x2f, - 0x6f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x3e, 0x3c, - 0x6f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x20, 0x63, - 0x6c, 0x61, 0x73, 0x73, 0x3d, 0x22, 0x47, 0x74, - 0x6b, 0x4d, 0x65, 0x6e, 0x75, 0x22, 0x20, 0x69, - 0x64, 0x3d, 0x22, 0x73, 0x63, 0x61, 0x6e, 0x5f, - 0x62, 0x75, 0x74, 0x74, 0x6f, 0x6e, 0x5f, 0x68, - 0x62, 0x5f, 0x6d, 0x65, 0x6e, 0x75, 0x22, 0x3e, - 0x3c, 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, - 0x79, 0x20, 0x6e, 0x61, 0x6d, 0x65, 0x3d, 0x22, - 0x76, 0x69, 0x73, 0x69, 0x62, 0x6c, 0x65, 0x22, - 0x3e, 0x54, 0x72, 0x75, 0x65, 0x3c, 0x2f, 0x70, - 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, 0x3e, - 0x3c, 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, - 0x79, 0x20, 0x6e, 0x61, 0x6d, 0x65, 0x3d, 0x22, - 0x63, 0x61, 0x6e, 0x5f, 0x66, 0x6f, 0x63, 0x75, - 0x73, 0x22, 0x3e, 0x46, 0x61, 0x6c, 0x73, 0x65, - 0x3c, 0x2f, 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, - 0x74, 0x79, 0x3e, 0x3c, 0x63, 0x68, 0x69, 0x6c, - 0x64, 0x3e, 0x3c, 0x6f, 0x62, 0x6a, 0x65, 0x63, - 0x74, 0x20, 0x63, 0x6c, 0x61, 0x73, 0x73, 0x3d, - 0x22, 0x47, 0x74, 0x6b, 0x4d, 0x65, 0x6e, 0x75, - 0x49, 0x74, 0x65, 0x6d, 0x22, 0x20, 0x69, 0x64, - 0x3d, 0x22, 0x73, 0x63, 0x61, 0x6e, 0x5f, 0x73, - 0x69, 0x6e, 0x67, 0x6c, 0x65, 0x5f, 0x62, 0x75, - 0x74, 0x74, 0x6f, 0x6e, 0x5f, 0x68, 0x62, 0x5f, - 0x6d, 0x65, 0x6e, 0x75, 0x69, 0x74, 0x65, 0x6d, - 0x22, 0x3e, 0x3c, 0x70, 0x72, 0x6f, 0x70, 0x65, - 0x72, 0x74, 0x79, 0x20, 0x6e, 0x61, 0x6d, 0x65, - 0x3d, 0x22, 0x76, 0x69, 0x73, 0x69, 0x62, 0x6c, - 0x65, 0x22, 0x3e, 0x54, 0x72, 0x75, 0x65, 0x3c, - 0x2f, 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, - 0x79, 0x3e, 0x3c, 0x70, 0x72, 0x6f, 0x70, 0x65, - 0x72, 0x74, 0x79, 0x20, 0x6e, 0x61, 0x6d, 0x65, - 0x3d, 0x22, 0x63, 0x61, 0x6e, 0x5f, 0x66, 0x6f, - 0x63, 0x75, 0x73, 0x22, 0x3e, 0x46, 0x61, 0x6c, - 0x73, 0x65, 0x3c, 0x2f, 0x70, 0x72, 0x6f, 0x70, - 0x65, 0x72, 0x74, 0x79, 0x3e, 0x3c, 0x70, 0x72, - 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, 0x20, 0x6e, - 0x61, 0x6d, 0x65, 0x3d, 0x22, 0x6c, 0x61, 0x62, - 0x65, 0x6c, 0x22, 0x20, 0x74, 0x72, 0x61, 0x6e, - 0x73, 0x6c, 0x61, 0x74, 0x61, 0x62, 0x6c, 0x65, - 0x3d, 0x22, 0x79, 0x65, 0x73, 0x22, 0x20, 0x63, - 0x6f, 0x6d, 0x6d, 0x65, 0x6e, 0x74, 0x73, 0x3d, - 0x22, 0x54, 0x6f, 0x6f, 0x6c, 0x62, 0x61, 0x72, - 0x20, 0x73, 0x63, 0x61, 0x6e, 0x20, 0x6d, 0x65, - 0x6e, 0x75, 0x20, 0x69, 0x74, 0x65, 0x6d, 0x20, - 0x74, 0x6f, 0x20, 0x73, 0x63, 0x61, 0x6e, 0x20, - 0x61, 0x20, 0x73, 0x69, 0x6e, 0x67, 0x6c, 0x65, - 0x20, 0x70, 0x61, 0x67, 0x65, 0x20, 0x66, 0x72, - 0x6f, 0x6d, 0x20, 0x74, 0x68, 0x65, 0x20, 0x73, - 0x63, 0x61, 0x6e, 0x6e, 0x65, 0x72, 0x22, 0x3e, - 0x53, 0x69, 0x6e, 0x67, 0x6c, 0x65, 0x20, 0x5f, - 0x50, 0x61, 0x67, 0x65, 0x3c, 0x2f, 0x70, 0x72, - 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, 0x3e, 0x3c, - 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, - 0x20, 0x6e, 0x61, 0x6d, 0x65, 0x3d, 0x22, 0x75, - 0x73, 0x65, 0x5f, 0x75, 0x6e, 0x64, 0x65, 0x72, - 0x6c, 0x69, 0x6e, 0x65, 0x22, 0x3e, 0x54, 0x72, - 0x75, 0x65, 0x3c, 0x2f, 0x70, 0x72, 0x6f, 0x70, - 0x65, 0x72, 0x74, 0x79, 0x3e, 0x3c, 0x73, 0x69, - 0x67, 0x6e, 0x61, 0x6c, 0x20, 0x6e, 0x61, 0x6d, - 0x65, 0x3d, 0x22, 0x61, 0x63, 0x74, 0x69, 0x76, - 0x61, 0x74, 0x65, 0x22, 0x20, 0x68, 0x61, 0x6e, - 0x64, 0x6c, 0x65, 0x72, 0x3d, 0x22, 0x73, 0x63, - 0x61, 0x6e, 0x5f, 0x62, 0x75, 0x74, 0x74, 0x6f, - 0x6e, 0x5f, 0x63, 0x6c, 0x69, 0x63, 0x6b, 0x65, - 0x64, 0x5f, 0x63, 0x62, 0x22, 0x20, 0x73, 0x77, - 0x61, 0x70, 0x70, 0x65, 0x64, 0x3d, 0x22, 0x6e, - 0x6f, 0x22, 0x2f, 0x3e, 0x3c, 0x2f, 0x6f, 0x62, - 0x6a, 0x65, 0x63, 0x74, 0x3e, 0x3c, 0x2f, 0x63, - 0x68, 0x69, 0x6c, 0x64, 0x3e, 0x3c, 0x63, 0x68, - 0x69, 0x6c, 0x64, 0x3e, 0x3c, 0x6f, 0x62, 0x6a, - 0x65, 0x63, 0x74, 0x20, 0x63, 0x6c, 0x61, 0x73, - 0x73, 0x3d, 0x22, 0x47, 0x74, 0x6b, 0x4d, 0x65, - 0x6e, 0x75, 0x49, 0x74, 0x65, 0x6d, 0x22, 0x20, - 0x69, 0x64, 0x3d, 0x22, 0x73, 0x63, 0x61, 0x6e, - 0x5f, 0x61, 0x6c, 0x6c, 0x5f, 0x62, 0x75, 0x74, - 0x74, 0x6f, 0x6e, 0x5f, 0x68, 0x62, 0x5f, 0x6d, - 0x65, 0x6e, 0x75, 0x69, 0x74, 0x65, 0x6d, 0x22, - 0x3e, 0x3c, 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, - 0x74, 0x79, 0x20, 0x6e, 0x61, 0x6d, 0x65, 0x3d, - 0x22, 0x76, 0x69, 0x73, 0x69, 0x62, 0x6c, 0x65, - 0x22, 0x3e, 0x54, 0x72, 0x75, 0x65, 0x3c, 0x2f, - 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, - 0x3e, 0x3c, 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, - 0x74, 0x79, 0x20, 0x6e, 0x61, 0x6d, 0x65, 0x3d, - 0x22, 0x63, 0x61, 0x6e, 0x5f, 0x66, 0x6f, 0x63, - 0x75, 0x73, 0x22, 0x3e, 0x46, 0x61, 0x6c, 0x73, - 0x65, 0x3c, 0x2f, 0x70, 0x72, 0x6f, 0x70, 0x65, - 0x72, 0x74, 0x79, 0x3e, 0x3c, 0x70, 0x72, 0x6f, - 0x70, 0x65, 0x72, 0x74, 0x79, 0x20, 0x6e, 0x61, - 0x6d, 0x65, 0x3d, 0x22, 0x6c, 0x61, 0x62, 0x65, - 0x6c, 0x22, 0x20, 0x74, 0x72, 0x61, 0x6e, 0x73, - 0x6c, 0x61, 0x74, 0x61, 0x62, 0x6c, 0x65, 0x3d, - 0x22, 0x79, 0x65, 0x73, 0x22, 0x20, 0x63, 0x6f, - 0x6d, 0x6d, 0x65, 0x6e, 0x74, 0x73, 0x3d, 0x22, - 0x54, 0x6f, 0x6f, 0x6c, 0x62, 0x61, 0x72, 0x20, - 0x73, 0x63, 0x61, 0x6e, 0x20, 0x6d, 0x65, 0x6e, - 0x75, 0x20, 0x69, 0x74, 0x65, 0x6d, 0x20, 0x74, - 0x6f, 0x20, 0x73, 0x63, 0x61, 0x6e, 0x20, 0x61, - 0x6c, 0x6c, 0x20, 0x70, 0x61, 0x67, 0x65, 0x73, - 0x20, 0x66, 0x72, 0x6f, 0x6d, 0x20, 0x61, 0x20, - 0x64, 0x6f, 0x63, 0x75, 0x6d, 0x65, 0x6e, 0x74, - 0x20, 0x66, 0x65, 0x65, 0x64, 0x65, 0x72, 0x22, - 0x3e, 0x41, 0x6c, 0x6c, 0x20, 0x50, 0x61, 0x67, - 0x65, 0x73, 0x20, 0x46, 0x72, 0x6f, 0x6d, 0x20, - 0x5f, 0x46, 0x65, 0x65, 0x64, 0x65, 0x72, 0x3c, - 0x2f, 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, - 0x79, 0x3e, 0x3c, 0x70, 0x72, 0x6f, 0x70, 0x65, - 0x72, 0x74, 0x79, 0x20, 0x6e, 0x61, 0x6d, 0x65, - 0x3d, 0x22, 0x75, 0x73, 0x65, 0x5f, 0x75, 0x6e, - 0x64, 0x65, 0x72, 0x6c, 0x69, 0x6e, 0x65, 0x22, - 0x3e, 0x54, 0x72, 0x75, 0x65, 0x3c, 0x2f, 0x70, - 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, 0x3e, - 0x3c, 0x73, 0x69, 0x67, 0x6e, 0x61, 0x6c, 0x20, - 0x6e, 0x61, 0x6d, 0x65, 0x3d, 0x22, 0x61, 0x63, - 0x74, 0x69, 0x76, 0x61, 0x74, 0x65, 0x22, 0x20, - 0x68, 0x61, 0x6e, 0x64, 0x6c, 0x65, 0x72, 0x3d, - 0x22, 0x63, 0x6f, 0x6e, 0x74, 0x69, 0x6e, 0x75, - 0x6f, 0x75, 0x73, 0x5f, 0x73, 0x63, 0x61, 0x6e, - 0x5f, 0x62, 0x75, 0x74, 0x74, 0x6f, 0x6e, 0x5f, - 0x63, 0x6c, 0x69, 0x63, 0x6b, 0x65, 0x64, 0x5f, - 0x63, 0x62, 0x22, 0x20, 0x73, 0x77, 0x61, 0x70, - 0x70, 0x65, 0x64, 0x3d, 0x22, 0x6e, 0x6f, 0x22, - 0x2f, 0x3e, 0x3c, 0x2f, 0x6f, 0x62, 0x6a, 0x65, - 0x63, 0x74, 0x3e, 0x3c, 0x2f, 0x63, 0x68, 0x69, - 0x6c, 0x64, 0x3e, 0x3c, 0x63, 0x68, 0x69, 0x6c, - 0x64, 0x3e, 0x3c, 0x6f, 0x62, 0x6a, 0x65, 0x63, - 0x74, 0x20, 0x63, 0x6c, 0x61, 0x73, 0x73, 0x3d, - 0x22, 0x47, 0x74, 0x6b, 0x53, 0x65, 0x70, 0x61, - 0x72, 0x61, 0x74, 0x6f, 0x72, 0x4d, 0x65, 0x6e, - 0x75, 0x49, 0x74, 0x65, 0x6d, 0x22, 0x20, 0x69, - 0x64, 0x3d, 0x22, 0x6d, 0x65, 0x6e, 0x75, 0x69, - 0x74, 0x65, 0x6d, 0x33, 0x22, 0x3e, 0x3c, 0x70, - 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, 0x20, - 0x6e, 0x61, 0x6d, 0x65, 0x3d, 0x22, 0x76, 0x69, - 0x73, 0x69, 0x62, 0x6c, 0x65, 0x22, 0x3e, 0x54, - 0x72, 0x75, 0x65, 0x3c, 0x2f, 0x70, 0x72, 0x6f, - 0x70, 0x65, 0x72, 0x74, 0x79, 0x3e, 0x3c, 0x70, - 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, 0x20, - 0x6e, 0x61, 0x6d, 0x65, 0x3d, 0x22, 0x63, 0x61, - 0x6e, 0x5f, 0x66, 0x6f, 0x63, 0x75, 0x73, 0x22, - 0x3e, 0x46, 0x61, 0x6c, 0x73, 0x65, 0x3c, 0x2f, - 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, - 0x3e, 0x3c, 0x2f, 0x6f, 0x62, 0x6a, 0x65, 0x63, - 0x74, 0x3e, 0x3c, 0x2f, 0x63, 0x68, 0x69, 0x6c, - 0x64, 0x3e, 0x3c, 0x63, 0x68, 0x69, 0x6c, 0x64, - 0x3e, 0x3c, 0x6f, 0x62, 0x6a, 0x65, 0x63, 0x74, - 0x20, 0x63, 0x6c, 0x61, 0x73, 0x73, 0x3d, 0x22, - 0x47, 0x74, 0x6b, 0x52, 0x61, 0x64, 0x69, 0x6f, - 0x4d, 0x65, 0x6e, 0x75, 0x49, 0x74, 0x65, 0x6d, - 0x22, 0x20, 0x69, 0x64, 0x3d, 0x22, 0x74, 0x65, - 0x78, 0x74, 0x5f, 0x62, 0x75, 0x74, 0x74, 0x6f, - 0x6e, 0x5f, 0x68, 0x62, 0x5f, 0x6d, 0x65, 0x6e, - 0x75, 0x69, 0x74, 0x65, 0x6d, 0x22, 0x3e, 0x3c, - 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, - 0x20, 0x6e, 0x61, 0x6d, 0x65, 0x3d, 0x22, 0x76, - 0x69, 0x73, 0x69, 0x62, 0x6c, 0x65, 0x22, 0x3e, - 0x54, 0x72, 0x75, 0x65, 0x3c, 0x2f, 0x70, 0x72, - 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, 0x3e, 0x3c, - 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, - 0x20, 0x6e, 0x61, 0x6d, 0x65, 0x3d, 0x22, 0x63, - 0x61, 0x6e, 0x5f, 0x66, 0x6f, 0x63, 0x75, 0x73, - 0x22, 0x3e, 0x46, 0x61, 0x6c, 0x73, 0x65, 0x3c, - 0x2f, 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, - 0x79, 0x3e, 0x3c, 0x70, 0x72, 0x6f, 0x70, 0x65, - 0x72, 0x74, 0x79, 0x20, 0x6e, 0x61, 0x6d, 0x65, - 0x3d, 0x22, 0x6c, 0x61, 0x62, 0x65, 0x6c, 0x22, - 0x20, 0x74, 0x72, 0x61, 0x6e, 0x73, 0x6c, 0x61, - 0x74, 0x61, 0x62, 0x6c, 0x65, 0x3d, 0x22, 0x79, - 0x65, 0x73, 0x22, 0x3e, 0x54, 0x65, 0x78, 0x74, - 0x3c, 0x2f, 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, - 0x74, 0x79, 0x3e, 0x3c, 0x70, 0x72, 0x6f, 0x70, - 0x65, 0x72, 0x74, 0x79, 0x20, 0x6e, 0x61, 0x6d, - 0x65, 0x3d, 0x22, 0x75, 0x73, 0x65, 0x5f, 0x75, - 0x6e, 0x64, 0x65, 0x72, 0x6c, 0x69, 0x6e, 0x65, - 0x22, 0x3e, 0x54, 0x72, 0x75, 0x65, 0x3c, 0x2f, - 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, - 0x3e, 0x3c, 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, - 0x74, 0x79, 0x20, 0x6e, 0x61, 0x6d, 0x65, 0x3d, - 0x22, 0x64, 0x72, 0x61, 0x77, 0x5f, 0x61, 0x73, - 0x5f, 0x72, 0x61, 0x64, 0x69, 0x6f, 0x22, 0x3e, - 0x54, 0x72, 0x75, 0x65, 0x3c, 0x2f, 0x70, 0x72, - 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, 0x3e, 0x3c, - 0x73, 0x69, 0x67, 0x6e, 0x61, 0x6c, 0x20, 0x6e, - 0x61, 0x6d, 0x65, 0x3d, 0x22, 0x74, 0x6f, 0x67, - 0x67, 0x6c, 0x65, 0x64, 0x22, 0x20, 0x68, 0x61, - 0x6e, 0x64, 0x6c, 0x65, 0x72, 0x3d, 0x22, 0x74, - 0x65, 0x78, 0x74, 0x5f, 0x6d, 0x65, 0x6e, 0x75, - 0x69, 0x74, 0x65, 0x6d, 0x5f, 0x74, 0x6f, 0x67, - 0x67, 0x6c, 0x65, 0x64, 0x5f, 0x63, 0x62, 0x22, - 0x20, 0x73, 0x77, 0x61, 0x70, 0x70, 0x65, 0x64, - 0x3d, 0x22, 0x6e, 0x6f, 0x22, 0x2f, 0x3e, 0x3c, - 0x2f, 0x6f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x3e, - 0x3c, 0x2f, 0x63, 0x68, 0x69, 0x6c, 0x64, 0x3e, - 0x3c, 0x63, 0x68, 0x69, 0x6c, 0x64, 0x3e, 0x3c, - 0x6f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x20, 0x63, - 0x6c, 0x61, 0x73, 0x73, 0x3d, 0x22, 0x47, 0x74, - 0x6b, 0x52, 0x61, 0x64, 0x69, 0x6f, 0x4d, 0x65, - 0x6e, 0x75, 0x49, 0x74, 0x65, 0x6d, 0x22, 0x20, - 0x69, 0x64, 0x3d, 0x22, 0x70, 0x68, 0x6f, 0x74, - 0x6f, 0x5f, 0x62, 0x75, 0x74, 0x74, 0x6f, 0x6e, - 0x5f, 0x68, 0x62, 0x5f, 0x6d, 0x65, 0x6e, 0x75, - 0x69, 0x74, 0x65, 0x6d, 0x22, 0x3e, 0x3c, 0x70, - 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, 0x20, - 0x6e, 0x61, 0x6d, 0x65, 0x3d, 0x22, 0x76, 0x69, - 0x73, 0x69, 0x62, 0x6c, 0x65, 0x22, 0x3e, 0x54, - 0x72, 0x75, 0x65, 0x3c, 0x2f, 0x70, 0x72, 0x6f, - 0x70, 0x65, 0x72, 0x74, 0x79, 0x3e, 0x3c, 0x70, - 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, 0x20, - 0x6e, 0x61, 0x6d, 0x65, 0x3d, 0x22, 0x63, 0x61, - 0x6e, 0x5f, 0x66, 0x6f, 0x63, 0x75, 0x73, 0x22, - 0x3e, 0x46, 0x61, 0x6c, 0x73, 0x65, 0x3c, 0x2f, - 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, - 0x3e, 0x3c, 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, - 0x74, 0x79, 0x20, 0x6e, 0x61, 0x6d, 0x65, 0x3d, - 0x22, 0x6c, 0x61, 0x62, 0x65, 0x6c, 0x22, 0x20, - 0x74, 0x72, 0x61, 0x6e, 0x73, 0x6c, 0x61, 0x74, - 0x61, 0x62, 0x6c, 0x65, 0x3d, 0x22, 0x79, 0x65, - 0x73, 0x22, 0x3e, 0x50, 0x68, 0x6f, 0x74, 0x6f, - 0x3c, 0x2f, 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, - 0x74, 0x79, 0x3e, 0x3c, 0x70, 0x72, 0x6f, 0x70, - 0x65, 0x72, 0x74, 0x79, 0x20, 0x6e, 0x61, 0x6d, - 0x65, 0x3d, 0x22, 0x75, 0x73, 0x65, 0x5f, 0x75, - 0x6e, 0x64, 0x65, 0x72, 0x6c, 0x69, 0x6e, 0x65, - 0x22, 0x3e, 0x54, 0x72, 0x75, 0x65, 0x3c, 0x2f, - 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, - 0x3e, 0x3c, 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, - 0x74, 0x79, 0x20, 0x6e, 0x61, 0x6d, 0x65, 0x3d, - 0x22, 0x61, 0x63, 0x74, 0x69, 0x76, 0x65, 0x22, - 0x3e, 0x54, 0x72, 0x75, 0x65, 0x3c, 0x2f, 0x70, - 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, 0x3e, - 0x3c, 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, - 0x79, 0x20, 0x6e, 0x61, 0x6d, 0x65, 0x3d, 0x22, - 0x64, 0x72, 0x61, 0x77, 0x5f, 0x61, 0x73, 0x5f, - 0x72, 0x61, 0x64, 0x69, 0x6f, 0x22, 0x3e, 0x54, - 0x72, 0x75, 0x65, 0x3c, 0x2f, 0x70, 0x72, 0x6f, - 0x70, 0x65, 0x72, 0x74, 0x79, 0x3e, 0x3c, 0x70, - 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, 0x20, - 0x6e, 0x61, 0x6d, 0x65, 0x3d, 0x22, 0x67, 0x72, - 0x6f, 0x75, 0x70, 0x22, 0x3e, 0x74, 0x65, 0x78, - 0x74, 0x5f, 0x62, 0x75, 0x74, 0x74, 0x6f, 0x6e, - 0x5f, 0x68, 0x62, 0x5f, 0x6d, 0x65, 0x6e, 0x75, - 0x69, 0x74, 0x65, 0x6d, 0x3c, 0x2f, 0x70, 0x72, - 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, 0x3e, 0x3c, - 0x73, 0x69, 0x67, 0x6e, 0x61, 0x6c, 0x20, 0x6e, - 0x61, 0x6d, 0x65, 0x3d, 0x22, 0x74, 0x6f, 0x67, - 0x67, 0x6c, 0x65, 0x64, 0x22, 0x20, 0x68, 0x61, - 0x6e, 0x64, 0x6c, 0x65, 0x72, 0x3d, 0x22, 0x70, - 0x68, 0x6f, 0x74, 0x6f, 0x5f, 0x6d, 0x65, 0x6e, - 0x75, 0x69, 0x74, 0x65, 0x6d, 0x5f, 0x74, 0x6f, - 0x67, 0x67, 0x6c, 0x65, 0x64, 0x5f, 0x63, 0x62, - 0x22, 0x20, 0x73, 0x77, 0x61, 0x70, 0x70, 0x65, - 0x64, 0x3d, 0x22, 0x6e, 0x6f, 0x22, 0x2f, 0x3e, - 0x3c, 0x2f, 0x6f, 0x62, 0x6a, 0x65, 0x63, 0x74, - 0x3e, 0x3c, 0x2f, 0x63, 0x68, 0x69, 0x6c, 0x64, - 0x3e, 0x3c, 0x2f, 0x6f, 0x62, 0x6a, 0x65, 0x63, - 0x74, 0x3e, 0x3c, 0x2f, 0x69, 0x6e, 0x74, 0x65, - 0x72, 0x66, 0x61, 0x63, 0x65, 0x3e, 0x0a, 0x00, - 0x00, 0x28, 0x75, 0x75, 0x61, 0x79, 0x29 -} }; - -static GStaticResource static_resource = { simple_scan_resource_data.data, sizeof (simple_scan_resource_data.data), NULL, NULL, NULL }; -extern GResource *simple_scan_get_resource (void); -GResource *simple_scan_get_resource (void) -{ - return g_static_resource_get_resource (&static_resource); -} -/* - If G_HAS_CONSTRUCTORS is true then the compiler support *both* constructors and - destructors, in a sane way, including e.g. on library unload. If not you're on - your own. - - Some compilers need #pragma to handle this, which does not work with macros, - so the way you need to use this is (for constructors): - - #ifdef G_DEFINE_CONSTRUCTOR_NEEDS_PRAGMA - #pragma G_DEFINE_CONSTRUCTOR_PRAGMA_ARGS(my_constructor) - #endif - G_DEFINE_CONSTRUCTOR(my_constructor) - static void my_constructor(void) { - ... - } - -*/ - -#ifndef __GTK_DOC_IGNORE__ - -#if __GNUC__ > 2 || (__GNUC__ == 2 && __GNUC_MINOR__ >= 7) - -#define G_HAS_CONSTRUCTORS 1 - -#define G_DEFINE_CONSTRUCTOR(_func) static void __attribute__((constructor)) _func (void); -#define G_DEFINE_DESTRUCTOR(_func) static void __attribute__((destructor)) _func (void); - -#elif defined (_MSC_VER) && (_MSC_VER >= 1500) -/* Visual studio 2008 and later has _Pragma */ - -#define G_HAS_CONSTRUCTORS 1 - -/* We do some weird things to avoid the constructors being optimized - * away on VS2015 if WholeProgramOptimization is enabled. First we - * make a reference to the array from the wrapper to make sure its - * references. Then we use a pragma to make sure the wrapper function - * symbol is always included at the link stage. Also, the symbols - * need to be extern (but not dllexport), even though they are not - * really used from another object file. - */ - -/* We need to account for differences between the mangling of symbols - * for Win32 (x86) and x64 programs, as symbols on Win32 are prefixed - * with an underscore but symbols on x64 are not. - */ -#ifdef _WIN64 -#define G_MSVC_SYMBOL_PREFIX "" -#else -#define G_MSVC_SYMBOL_PREFIX "_" -#endif - -#define G_DEFINE_CONSTRUCTOR(_func) G_MSVC_CTOR (_func, G_MSVC_SYMBOL_PREFIX) -#define G_DEFINE_DESTRUCTOR(_func) G_MSVC_DTOR (_func, G_MSVC_SYMBOL_PREFIX) - -#define G_MSVC_CTOR(_func,_sym_prefix) \ - static void _func(void); \ - extern int (* _array ## _func)(void); \ - int _func ## _wrapper(void) { _func(); g_slist_find (NULL, _array ## _func); return 0; } \ - __pragma(comment(linker,"/include:" _sym_prefix # _func "_wrapper")) \ - __pragma(section(".CRT$XCU",read)) \ - __declspec(allocate(".CRT$XCU")) int (* _array ## _func)(void) = _func ## _wrapper; - -#define G_MSVC_DTOR(_func,_sym_prefix) \ - static void _func(void); \ - extern int (* _array ## _func)(void); \ - int _func ## _constructor(void) { atexit (_func); g_slist_find (NULL, _array ## _func); return 0; } \ - __pragma(comment(linker,"/include:" _sym_prefix # _func "_constructor")) \ - __pragma(section(".CRT$XCU",read)) \ - __declspec(allocate(".CRT$XCU")) int (* _array ## _func)(void) = _func ## _constructor; - -#elif defined (_MSC_VER) - -#define G_HAS_CONSTRUCTORS 1 - -/* Pre Visual studio 2008 must use #pragma section */ -#define G_DEFINE_CONSTRUCTOR_NEEDS_PRAGMA 1 -#define G_DEFINE_DESTRUCTOR_NEEDS_PRAGMA 1 - -#define G_DEFINE_CONSTRUCTOR_PRAGMA_ARGS(_func) \ - section(".CRT$XCU",read) -#define G_DEFINE_CONSTRUCTOR(_func) \ - static void _func(void); \ - static int _func ## _wrapper(void) { _func(); return 0; } \ - __declspec(allocate(".CRT$XCU")) static int (*p)(void) = _func ## _wrapper; - -#define G_DEFINE_DESTRUCTOR_PRAGMA_ARGS(_func) \ - section(".CRT$XCU",read) -#define G_DEFINE_DESTRUCTOR(_func) \ - static void _func(void); \ - static int _func ## _constructor(void) { atexit (_func); return 0; } \ - __declspec(allocate(".CRT$XCU")) static int (* _array ## _func)(void) = _func ## _constructor; - -#elif defined(__SUNPRO_C) - -/* This is not tested, but i believe it should work, based on: - * http://opensource.apple.com/source/OpenSSL098/OpenSSL098-35/src/fips/fips_premain.c - */ - -#define G_HAS_CONSTRUCTORS 1 - -#define G_DEFINE_CONSTRUCTOR_NEEDS_PRAGMA 1 -#define G_DEFINE_DESTRUCTOR_NEEDS_PRAGMA 1 - -#define G_DEFINE_CONSTRUCTOR_PRAGMA_ARGS(_func) \ - init(_func) -#define G_DEFINE_CONSTRUCTOR(_func) \ - static void _func(void); - -#define G_DEFINE_DESTRUCTOR_PRAGMA_ARGS(_func) \ - fini(_func) -#define G_DEFINE_DESTRUCTOR(_func) \ - static void _func(void); - -#else - -/* constructors not supported for this compiler */ - -#endif - -#endif /* __GTK_DOC_IGNORE__ */ - -#ifdef G_HAS_CONSTRUCTORS - -#ifdef G_DEFINE_CONSTRUCTOR_NEEDS_PRAGMA -#pragma G_DEFINE_CONSTRUCTOR_PRAGMA_ARGS(resource_constructor) -#endif -G_DEFINE_CONSTRUCTOR(resource_constructor) -#ifdef G_DEFINE_DESTRUCTOR_NEEDS_PRAGMA -#pragma G_DEFINE_DESTRUCTOR_PRAGMA_ARGS(resource_destructor) -#endif -G_DEFINE_DESTRUCTOR(resource_destructor) - -#else -#warning "Constructor not supported on this compiler, linking in resources will not work" -#endif - -static void resource_constructor (void) -{ - g_static_resource_init (&static_resource); -} - -static void resource_destructor (void) -{ - g_static_resource_fini (&static_resource); -} diff --git a/src/sane-backends.vapi b/src/sane-backends.vapi new file mode 100644 index 0000000..f636dac --- /dev/null +++ b/src/sane-backends.vapi @@ -0,0 +1,754 @@ +[CCode (cprefix = "SANE_", lower_case_cprefix = "sane_", cheader_filename = "sane/sane.h")] +namespace Sane { + [SimpleType] + [BooleanType] + public struct Bool + { + } + + [SimpleType] + [IntegerType (rank = 9)] + public struct Int + { + } + + [SimpleType] + [IntegerType (rank = 9)] + public struct Fixed + { + } + + [SimpleType] + [IntegerType (rank = 9)] + public struct Word + { + } + + [CCode (ref_function = "", unref_function = "")] + public class Device + { + public string name; + public string vendor; + public string model; + public string type; + } + + public enum Status + { + GOOD, + UNSUPPORTED, + CANCELLED, + DEVICE_BUSY, + INVAL, + EOF, + JAMMED, + NO_DOCS, + COVER_OPEN, + IO_ERROR, + NO_MEM, + ACCESS_DENIED + } + + public static string status_to_string (Status status) + { + switch (status) + { + case Status.GOOD: + return "SANE_STATUS_GOOD"; + case Status.UNSUPPORTED: + return "SANE_STATUS_UNSUPPORTED"; + case Status.CANCELLED: + return "SANE_STATUS_CANCELLED"; + case Status.DEVICE_BUSY: + return "SANE_STATUS_DEVICE_BUSY"; + case Status.INVAL: + return "SANE_STATUS_INVAL"; + case Status.EOF: + return "SANE_STATUS_EOF"; + case Status.JAMMED: + return "SANE_STATUS_JAMMED"; + case Status.NO_DOCS: + return "SANE_STATUS_NO_DOCS"; + case Status.COVER_OPEN: + return "SANE_STATUS_COVER_OPEN"; + case Status.IO_ERROR: + return "SANE_STATUS_IO_ERROR"; + case Status.NO_MEM: + return "SANE_STATUS_NO_MEM"; + case Status.ACCESS_DENIED: + return "SANE_STATUS_ACCESS_DENIED"; + default: + return "SANE_STATUS(%d)".printf (status); + } + } + + public enum Action + { + GET_VALUE, + SET_VALUE, + SET_AUTO + } + + public enum Frame + { + GRAY, + RGB, + RED, + GREEN, + BLUE + } + + public static string frame_to_string (Frame frame) + { + switch (frame) + { + case Frame.GRAY: + return "SANE_FRAME_GRAY"; + case Frame.RGB: + return "SANE_FRAME_RGB"; + case Frame.RED: + return "SANE_FRAME_RED"; + case Frame.GREEN: + return "SANE_FRAME_GREEN"; + case Frame.BLUE: + return "SANE_FRAME_BLUE"; + default: + return "SANE_FRAME(%d)".printf (frame); + } + } + + public struct Parameters + { + Frame format; + bool last_frame; + int bytes_per_line; + int pixels_per_line; + int lines; + int depth; + } + + [CCode (cname = "SANE_MAX_USERNAME_LEN")] + public int MAX_USERNAME_LEN; + + [CCode (cname = "SANE_MAX_USERNAME_LEN")] + public int MAX_PASSWORD_LEN; + + [CCode (cname = "SANE_Value_Type", cprefix = "SANE_TYPE_")] + public enum ValueType + { + BOOL, + INT, + FIXED, + STRING, + BUTTON, + GROUP + } + + public enum Unit + { + NONE, + PIXEL, + BIT, + MM, + DPI, + PERCENT, + MICROSECOND + } + + [CCode (cname = "SANE_Constraint_Type", cprefix = "SANE_CONSTRAINT_")] + public enum ConstraintType + { + NONE, + RANGE, + WORD_LIST, + STRING_LIST + } + + public class Range + { + public Word min; + public Word max; + public Word quant; + } + + [CCode (cprefix = "SANE_CAP_")] + public enum Capability + { + SOFT_SELECT, + HARD_SELECT, + SOFT_DETECT, + EMULATED, + AUTOMATIC, + INACTIVE, + ADVANCED + } + + [CCode (cname = "SANE_Option_Descriptor", ref_function = "", unref_function = "")] + public class OptionDescriptor + { + public unowned string name; + public unowned string title; + public unowned string desc; + public ValueType type; + public Unit unit; + public Int size; + public Int cap; + + public ConstraintType constraint_type; + [CCode (cname = "constraint.string_list", array_length = false, array_null_terminated = true)] + public string[] string_list; + [CCode (cname = "constraint.word_list", array_length = false)] + public Word[] word_list; + [CCode (cname = "constraint.range")] + public Range range; + } + + [CCode (type = "Int", cprefix = "SANE_INFO_")] + public enum Info + { + INEXACT, + RELOAD_OPTIONS, + RELOAD_PARAMS + } + + [SimpleType] + public struct Handle + { + } + + [CCode (has_target = false)] + public delegate void AuthCallback (string resource, [CCode (array_length = false)] char[] username, [CCode (array_length = false)] char[] password); + + [CCode (cname = "SANE_VERSION_MAJOR")] + public int VERSION_MAJOR (Int code); + [CCode (cname = "SANE_VERSION_MINOR")] + public int VERSION_MINOR (Int code); + [CCode (cname = "SANE_VERSION_BUILD")] + public int VERSION_BUILD (Int code); + + [CCode (cname = "SANE_FIX")] + public Fixed FIX (double d); + [CCode (cname = "SANE_UNFIX")] + public double UNFIX (Fixed w); + + [CCode (cname = "SANE_I18N")] + public unowned string I18N (string value); + + public Status init (out Int version_code, AuthCallback callback); + public void exit (); + public Status get_devices ([CCode (array_length = false, null_terminated = true)] out unowned Device[] device_list, bool local_only); + public unowned string strstatus (Status status); + public Status open (string devicename, out Handle handle); + public void close (Handle handle); + public unowned OptionDescriptor? get_option_descriptor (Handle handle, Int option); + public Status control_option (Handle handle, Int option, Action action, void *value, out Info? info = null); + public Status get_parameters (Handle handle, out Parameters params); + public Status start (Handle handle); + public Status read (Handle handle, uint8* data, Int max_length, out Int length); + public void cancel (Handle handle); + public Status set_io_mode (Handle handle, bool non_blocking); + public Status get_select_fd (Handle handle, out int fd); + + [CCode (cname = "SANE_NAME_STANDARD", cheader_filename = "sane/saneopts.h")] + public static string NAME_STANDARD; + [CCode (cname = "SANE_NAME_GEOMETRY", cheader_filename = "sane/saneopts.h")] + public static string NAME_GEOMETRY; + [CCode (cname = "SANE_NAME_ENHANCEMENT", cheader_filename = "sane/saneopts.h")] + public static string NAME_ENHANCEMENT; + [CCode (cname = "SANE_NAME_ADVANCED", cheader_filename = "sane/saneopts.h")] + public static string NAME_ADVANCED; + [CCode (cname = "SANE_NAME_SENSORS", cheader_filename = "sane/saneopts.h")] + public static string NAME_SENSORS; + [CCode (cname = "SANE_NAME_PREVIEW", cheader_filename = "sane/saneopts.h")] + public static string NAME_PREVIEW; + [CCode (cname = "SANE_NAME_GRAY_PREVIEW", cheader_filename = "sane/saneopts.h")] + public static string NAME_GRAY_PREVIEW; + [CCode (cname = "SANE_NAME_BIT_DEPTH", cheader_filename = "sane/saneopts.h")] + public static string NAME_BIT_DEPTH; + [CCode (cname = "SANE_NAME_SCAN_MODE", cheader_filename = "sane/saneopts.h")] + public static string NAME_SCAN_MODE; + [CCode (cname = "SANE_NAME_SCAN_SPEED", cheader_filename = "sane/saneopts.h")] + public static string NAME_SCAN_SPEED; + [CCode (cname = "SANE_NAME_SCAN_SOURCE", cheader_filename = "sane/saneopts.h")] + public static string NAME_SCAN_SOURCE; + [CCode (cname = "SANE_NAME_BACKTRACK", cheader_filename = "sane/saneopts.h")] + public static string NAME_BACKTRACK; + [CCode (cname = "SANE_NAME_SCAN_TL_X", cheader_filename = "sane/saneopts.h")] + public static string NAME_SCAN_TL_X; + [CCode (cname = "SANE_NAME_SCAN_TL_Y", cheader_filename = "sane/saneopts.h")] + public static string NAME_SCAN_TL_Y; + [CCode (cname = "SANE_NAME_SCAN_BR_X", cheader_filename = "sane/saneopts.h")] + public static string NAME_SCAN_BR_X; + [CCode (cname = "SANE_NAME_SCAN_BR_Y", cheader_filename = "sane/saneopts.h")] + public static string NAME_SCAN_BR_Y; + [CCode (cname = "SANE_NAME_SCAN_RESOLUTION", cheader_filename = "sane/saneopts.h")] + public static string NAME_SCAN_RESOLUTION; + [CCode (cname = "SANE_NAME_SCAN_X_RESOLUTION", cheader_filename = "sane/saneopts.h")] + public static string NAME_SCAN_X_RESOLUTION; + [CCode (cname = "SANE_NAME_SCAN_Y_RESOLUTION", cheader_filename = "sane/saneopts.h")] + public static string NAME_SCAN_Y_RESOLUTION; + [CCode (cname = "SANE_NAME_PAGE_WIDTH", cheader_filename = "sane/saneopts.h")] + public static string NAME_PAGE_WIDTH; + [CCode (cname = "SANE_NAME_PAGE_HEIGHT", cheader_filename = "sane/saneopts.h")] + public static string NAME_PAGE_HEIGHT; + [CCode (cname = "SANE_NAME_CUSTOM_GAMMA", cheader_filename = "sane/saneopts.h")] + public static string NAME_CUSTOM_GAMMA; + [CCode (cname = "SANE_NAME_GAMMA_VECTOR", cheader_filename = "sane/saneopts.h")] + public static string NAME_GAMMA_VECTOR; + [CCode (cname = "SANE_NAME_GAMMA_VECTOR_R", cheader_filename = "sane/saneopts.h")] + public static string NAME_GAMMA_VECTOR_R; + [CCode (cname = "SANE_NAME_GAMMA_VECTOR_G", cheader_filename = "sane/saneopts.h")] + public static string NAME_GAMMA_VECTOR_G; + [CCode (cname = "SANE_NAME_GAMMA_VECTOR_B", cheader_filename = "sane/saneopts.h")] + public static string NAME_GAMMA_VECTOR_B; + [CCode (cname = "SANE_NAME_BRIGHTNESS", cheader_filename = "sane/saneopts.h")] + public static string NAME_BRIGHTNESS; + [CCode (cname = "SANE_NAME_CONTRAST", cheader_filename = "sane/saneopts.h")] + public static string NAME_CONTRAST; + [CCode (cname = "SANE_NAME_GRAIN_SIZE", cheader_filename = "sane/saneopts.h")] + public static string NAME_GRAIN_SIZE; + [CCode (cname = "SANE_NAME_HALFTONE", cheader_filename = "sane/saneopts.h")] + public static string NAME_HALFTONE; + [CCode (cname = "SANE_NAME_BLACK_LEVEL", cheader_filename = "sane/saneopts.h")] + public static string NAME_BLACK_LEVEL; + [CCode (cname = "SANE_NAME_WHITE_LEVEL", cheader_filename = "sane/saneopts.h")] + public static string NAME_WHITE_LEVEL; + [CCode (cname = "SANE_NAME_WHITE_LEVEL_R", cheader_filename = "sane/saneopts.h")] + public static string NAME_WHITE_LEVEL_R; + [CCode (cname = "SANE_NAME_WHITE_LEVEL_G", cheader_filename = "sane/saneopts.h")] + public static string NAME_WHITE_LEVEL_G; + [CCode (cname = "SANE_NAME_WHITE_LEVEL_B", cheader_filename = "sane/saneopts.h")] + public static string NAME_WHITE_LEVEL_B; + [CCode (cname = "SANE_NAME_SHADOW", cheader_filename = "sane/saneopts.h")] + public static string NAME_SHADOW; + [CCode (cname = "SANE_NAME_SHADOW_R", cheader_filename = "sane/saneopts.h")] + public static string NAME_SHADOW_R; + [CCode (cname = "SANE_NAME_SHADOW_G", cheader_filename = "sane/saneopts.h")] + public static string NAME_SHADOW_G; + [CCode (cname = "SANE_NAME_SHADOW_B", cheader_filename = "sane/saneopts.h")] + public static string NAME_SHADOW_B; + [CCode (cname = "SANE_NAME_HIGHLIGHT", cheader_filename = "sane/saneopts.h")] + public static string NAME_HIGHLIGHT; + [CCode (cname = "SANE_NAME_HIGHLIGHT_R", cheader_filename = "sane/saneopts.h")] + public static string NAME_HIGHLIGHT_R; + [CCode (cname = "SANE_NAME_HIGHLIGHT_G", cheader_filename = "sane/saneopts.h")] + public static string NAME_HIGHLIGHT_G; + [CCode (cname = "SANE_NAME_HIGHLIGHT_B", cheader_filename = "sane/saneopts.h")] + public static string NAME_HIGHLIGHT_B; + [CCode (cname = "SANE_NAME_HUE", cheader_filename = "sane/saneopts.h")] + public static string NAME_HUE; + [CCode (cname = "SANE_NAME_SATURATION", cheader_filename = "sane/saneopts.h")] + public static string NAME_SATURATION; + [CCode (cname = "SANE_NAME_FILE", cheader_filename = "sane/saneopts.h")] + public static string NAME_FILE; + [CCode (cname = "SANE_NAME_HALFTONE_DIMENSION", cheader_filename = "sane/saneopts.h")] + public static string NAME_HALFTONE_DIMENSION; + [CCode (cname = "SANE_NAME_HALFTONE_PATTERN", cheader_filename = "sane/saneopts.h")] + public static string NAME_HALFTONE_PATTERN; + [CCode (cname = "SANE_NAME_RESOLUTION_BIND", cheader_filename = "sane/saneopts.h")] + public static string NAME_RESOLUTION_BIND; + [CCode (cname = "SANE_NAME_NEGATIVE", cheader_filename = "sane/saneopts.h")] + public static string NAME_NEGATIVE; + [CCode (cname = "SANE_NAME_QUALITY_CAL", cheader_filename = "sane/saneopts.h")] + public static string NAME_QUALITY_CAL; + [CCode (cname = "SANE_NAME_DOR", cheader_filename = "sane/saneopts.h")] + public static string NAME_DOR; + [CCode (cname = "SANE_NAME_RGB_BIND", cheader_filename = "sane/saneopts.h")] + public static string NAME_RGB_BIND; + [CCode (cname = "SANE_NAME_THRESHOLD", cheader_filename = "sane/saneopts.h")] + public static string NAME_THRESHOLD; + [CCode (cname = "SANE_NAME_ANALOG_GAMMA", cheader_filename = "sane/saneopts.h")] + public static string NAME_ANALOG_GAMMA; + [CCode (cname = "SANE_NAME_ANALOG_GAMMA_R", cheader_filename = "sane/saneopts.h")] + public static string NAME_ANALOG_GAMMA_R; + [CCode (cname = "SANE_NAME_ANALOG_GAMMA_G", cheader_filename = "sane/saneopts.h")] + public static string NAME_ANALOG_GAMMA_G; + [CCode (cname = "SANE_NAME_ANALOG_GAMMA_B", cheader_filename = "sane/saneopts.h")] + public static string NAME_ANALOG_GAMMA_B; + [CCode (cname = "SANE_NAME_ANALOG_GAMMA_BIND", cheader_filename = "sane/saneopts.h")] + public static string NAME_ANALOG_GAMMA_BIND; + [CCode (cname = "SANE_NAME_WARMUP", cheader_filename = "sane/saneopts.h")] + public static string NAME_WARMUP; + [CCode (cname = "SANE_NAME_CAL_EXPOS_TIME", cheader_filename = "sane/saneopts.h")] + public static string NAME_CAL_EXPOS_TIME; + [CCode (cname = "SANE_NAME_CAL_EXPOS_TIME_R", cheader_filename = "sane/saneopts.h")] + public static string NAME_CAL_EXPOS_TIME_R; + [CCode (cname = "SANE_NAME_CAL_EXPOS_TIME_G", cheader_filename = "sane/saneopts.h")] + public static string NAME_CAL_EXPOS_TIME_G; + [CCode (cname = "SANE_NAME_CAL_EXPOS_TIME_B", cheader_filename = "sane/saneopts.h")] + public static string NAME_CAL_EXPOS_TIME_B; + [CCode (cname = "SANE_NAME_SCAN_EXPOS_TIME", cheader_filename = "sane/saneopts.h")] + public static string NAME_SCAN_EXPOS_TIME; + [CCode (cname = "SANE_NAME_SCAN_EXPOS_TIME_R", cheader_filename = "sane/saneopts.h")] + public static string NAME_SCAN_EXPOS_TIME_R; + [CCode (cname = "SANE_NAME_SCAN_EXPOS_TIME_G", cheader_filename = "sane/saneopts.h")] + public static string NAME_SCAN_EXPOS_TIME_G; + [CCode (cname = "SANE_NAME_SCAN_EXPOS_TIME_B", cheader_filename = "sane/saneopts.h")] + public static string NAME_SCAN_EXPOS_TIME_B; + [CCode (cname = "SANE_NAME_SELECT_EXPOSURE_TIME", cheader_filename = "sane/saneopts.h")] + public static string NAME_SELECT_EXPOSURE_TIME; + [CCode (cname = "SANE_NAME_CAL_LAMP_DEN", cheader_filename = "sane/saneopts.h")] + public static string NAME_CAL_LAMP_DEN; + [CCode (cname = "SANE_NAME_SCAN_LAMP_DEN", cheader_filename = "sane/saneopts.h")] + public static string NAME_SCAN_LAMP_DEN; + [CCode (cname = "SANE_NAME_SELECT_LAMP_DENSITY", cheader_filename = "sane/saneopts.h")] + public static string NAME_SELECT_LAMP_DENSITY; + [CCode (cname = "SANE_NAME_LAMP_OFF_AT_EXIT", cheader_filename = "sane/saneopts.h")] + public static string NAME_LAMP_OFF_AT_EXIT; + [CCode (cname = "SANE_NAME_SCAN", cheader_filename = "sane/saneopts.h")] + public static string NAME_SCAN; + [CCode (cname = "SANE_NAME_EMAIL", cheader_filename = "sane/saneopts.h")] + public static string NAME_EMAIL; + [CCode (cname = "SANE_NAME_FAX", cheader_filename = "sane/saneopts.h")] + public static string NAME_FAX; + [CCode (cname = "SANE_NAME_COPY", cheader_filename = "sane/saneopts.h")] + public static string NAME_COPY; + [CCode (cname = "SANE_NAME_PDF", cheader_filename = "sane/saneopts.h")] + public static string NAME_PDF; + [CCode (cname = "SANE_NAME_CANCEL", cheader_filename = "sane/saneopts.h")] + public static string NAME_CANCEL; + [CCode (cname = "SANE_NAME_PAGE_LOADED", cheader_filename = "sane/saneopts.h")] + public static string NAME_PAGE_LOADED; + [CCode (cname = "SANE_NAME_COVER_OPEN", cheader_filename = "sane/saneopts.h")] + public static string NAME_COVER_OPEN; + [CCode (cname = "SANE_TITLE_NUM_OPTIONS", cheader_filename = "sane/saneopts.h")] + public static string TITLE_NUM_OPTIONS; + [CCode (cname = "SANE_TITLE_STANDARD", cheader_filename = "sane/saneopts.h")] + public static string TITLE_STANDARD; + [CCode (cname = "SANE_TITLE_GEOMETRY", cheader_filename = "sane/saneopts.h")] + public static string TITLE_GEOMETRY; + [CCode (cname = "SANE_TITLE_ENHANCEMENT", cheader_filename = "sane/saneopts.h")] + public static string TITLE_ENHANCEMENT; + [CCode (cname = "SANE_TITLE_ADVANCED", cheader_filename = "sane/saneopts.h")] + public static string TITLE_ADVANCED; + [CCode (cname = "SANE_TITLE_SENSORS", cheader_filename = "sane/saneopts.h")] + public static string TITLE_SENSORS; + [CCode (cname = "SANE_TITLE_PREVIEW", cheader_filename = "sane/saneopts.h")] + public static string TITLE_PREVIEW; + [CCode (cname = "SANE_TITLE_GRAY_PREVIEW", cheader_filename = "sane/saneopts.h")] + public static string TITLE_GRAY_PREVIEW; + [CCode (cname = "SANE_TITLE_BIT_DEPTH", cheader_filename = "sane/saneopts.h")] + public static string TITLE_BIT_DEPTH; + [CCode (cname = "SANE_TITLE_SCAN_MODE", cheader_filename = "sane/saneopts.h")] + public static string TITLE_SCAN_MODE; + [CCode (cname = "SANE_TITLE_SCAN_SPEED", cheader_filename = "sane/saneopts.h")] + public static string TITLE_SCAN_SPEED; + [CCode (cname = "SANE_TITLE_SCAN_SOURCE", cheader_filename = "sane/saneopts.h")] + public static string TITLE_SCAN_SOURCE; + [CCode (cname = "SANE_TITLE_BACKTRACK", cheader_filename = "sane/saneopts.h")] + public static string TITLE_BACKTRACK; + [CCode (cname = "SANE_TITLE_SCAN_TL_X", cheader_filename = "sane/saneopts.h")] + public static string TITLE_SCAN_TL_X; + [CCode (cname = "SANE_TITLE_SCAN_TL_Y", cheader_filename = "sane/saneopts.h")] + public static string TITLE_SCAN_TL_Y; + [CCode (cname = "SANE_TITLE_SCAN_BR_X", cheader_filename = "sane/saneopts.h")] + public static string TITLE_SCAN_BR_X; + [CCode (cname = "SANE_TITLE_SCAN_BR_Y", cheader_filename = "sane/saneopts.h")] + public static string TITLE_SCAN_BR_Y; + [CCode (cname = "SANE_TITLE_SCAN_RESOLUTION", cheader_filename = "sane/saneopts.h")] + public static string TITLE_SCAN_RESOLUTION; + [CCode (cname = "SANE_TITLE_SCAN_X_RESOLUTION", cheader_filename = "sane/saneopts.h")] + public static string TITLE_SCAN_X_RESOLUTION; + [CCode (cname = "SANE_TITLE_SCAN_Y_RESOLUTION", cheader_filename = "sane/saneopts.h")] + public static string TITLE_SCAN_Y_RESOLUTION; + [CCode (cname = "SANE_TITLE_PAGE_WIDTH", cheader_filename = "sane/saneopts.h")] + public static string TITLE_PAGE_WIDTH; + [CCode (cname = "SANE_TITLE_PAGE_HEIGHT", cheader_filename = "sane/saneopts.h")] + public static string TITLE_PAGE_HEIGHT; + [CCode (cname = "SANE_TITLE_CUSTOM_GAMMA", cheader_filename = "sane/saneopts.h")] + public static string TITLE_CUSTOM_GAMMA; + [CCode (cname = "SANE_TITLE_GAMMA_VECTOR", cheader_filename = "sane/saneopts.h")] + public static string TITLE_GAMMA_VECTOR; + [CCode (cname = "SANE_TITLE_GAMMA_VECTOR_R", cheader_filename = "sane/saneopts.h")] + public static string TITLE_GAMMA_VECTOR_R; + [CCode (cname = "SANE_TITLE_GAMMA_VECTOR_G", cheader_filename = "sane/saneopts.h")] + public static string TITLE_GAMMA_VECTOR_G; + [CCode (cname = "SANE_TITLE_GAMMA_VECTOR_B", cheader_filename = "sane/saneopts.h")] + public static string TITLE_GAMMA_VECTOR_B; + [CCode (cname = "SANE_TITLE_BRIGHTNESS", cheader_filename = "sane/saneopts.h")] + public static string TITLE_BRIGHTNESS; + [CCode (cname = "SANE_TITLE_CONTRAST", cheader_filename = "sane/saneopts.h")] + public static string TITLE_CONTRAST; + [CCode (cname = "SANE_TITLE_GRAIN_SIZE", cheader_filename = "sane/saneopts.h")] + public static string TITLE_GRAIN_SIZE; + [CCode (cname = "SANE_TITLE_HALFTONE", cheader_filename = "sane/saneopts.h")] + public static string TITLE_HALFTONE; + [CCode (cname = "SANE_TITLE_BLACK_LEVEL", cheader_filename = "sane/saneopts.h")] + public static string TITLE_BLACK_LEVEL; + [CCode (cname = "SANE_TITLE_WHITE_LEVEL", cheader_filename = "sane/saneopts.h")] + public static string TITLE_WHITE_LEVEL; + [CCode (cname = "SANE_TITLE_WHITE_LEVEL_R", cheader_filename = "sane/saneopts.h")] + public static string TITLE_WHITE_LEVEL_R; + [CCode (cname = "SANE_TITLE_WHITE_LEVEL_G", cheader_filename = "sane/saneopts.h")] + public static string TITLE_WHITE_LEVEL_G; + [CCode (cname = "SANE_TITLE_WHITE_LEVEL_B", cheader_filename = "sane/saneopts.h")] + public static string TITLE_WHITE_LEVEL_B; + [CCode (cname = "SANE_TITLE_SHADOW", cheader_filename = "sane/saneopts.h")] + public static string TITLE_SHADOW; + [CCode (cname = "SANE_TITLE_SHADOW_R", cheader_filename = "sane/saneopts.h")] + public static string TITLE_SHADOW_R; + [CCode (cname = "SANE_TITLE_SHADOW_G", cheader_filename = "sane/saneopts.h")] + public static string TITLE_SHADOW_G; + [CCode (cname = "SANE_TITLE_SHADOW_B", cheader_filename = "sane/saneopts.h")] + public static string TITLE_SHADOW_B; + [CCode (cname = "SANE_TITLE_HIGHLIGHT", cheader_filename = "sane/saneopts.h")] + public static string TITLE_HIGHLIGHT; + [CCode (cname = "SANE_TITLE_HIGHLIGHT_R", cheader_filename = "sane/saneopts.h")] + public static string TITLE_HIGHLIGHT_R; + [CCode (cname = "SANE_TITLE_HIGHLIGHT_G", cheader_filename = "sane/saneopts.h")] + public static string TITLE_HIGHLIGHT_G; + [CCode (cname = "SANE_TITLE_HIGHLIGHT_B", cheader_filename = "sane/saneopts.h")] + public static string TITLE_HIGHLIGHT_B; + [CCode (cname = "SANE_TITLE_HUE", cheader_filename = "sane/saneopts.h")] + public static string TITLE_HUE; + [CCode (cname = "SANE_TITLE_SATURATION", cheader_filename = "sane/saneopts.h")] + public static string TITLE_SATURATION; + [CCode (cname = "SANE_TITLE_FILE", cheader_filename = "sane/saneopts.h")] + public static string TITLE_FILE; + [CCode (cname = "SANE_TITLE_HALFTONE_DIMENSION", cheader_filename = "sane/saneopts.h")] + public static string TITLE_HALFTONE_DIMENSION; + [CCode (cname = "SANE_TITLE_HALFTONE_PATTERN", cheader_filename = "sane/saneopts.h")] + public static string TITLE_HALFTONE_PATTERN; + [CCode (cname = "SANE_TITLE_RESOLUTION_BIND", cheader_filename = "sane/saneopts.h")] + public static string TITLE_RESOLUTION_BIND; + [CCode (cname = "SANE_TITLE_NEGATIVE", cheader_filename = "sane/saneopts.h")] + public static string TITLE_NEGATIVE; + [CCode (cname = "SANE_TITLE_QUALITY_CAL", cheader_filename = "sane/saneopts.h")] + public static string TITLE_QUALITY_CAL; + [CCode (cname = "SANE_TITLE_DOR", cheader_filename = "sane/saneopts.h")] + public static string TITLE_DOR; + [CCode (cname = "SANE_TITLE_RGB_BIND", cheader_filename = "sane/saneopts.h")] + public static string TITLE_RGB_BIND; + [CCode (cname = "SANE_TITLE_THRESHOLD", cheader_filename = "sane/saneopts.h")] + public static string TITLE_THRESHOLD; + [CCode (cname = "SANE_TITLE_ANALOG_GAMMA", cheader_filename = "sane/saneopts.h")] + public static string TITLE_ANALOG_GAMMA; + [CCode (cname = "SANE_TITLE_ANALOG_GAMMA_R", cheader_filename = "sane/saneopts.h")] + public static string TITLE_ANALOG_GAMMA_R; + [CCode (cname = "SANE_TITLE_ANALOG_GAMMA_G", cheader_filename = "sane/saneopts.h")] + public static string TITLE_ANALOG_GAMMA_G; + [CCode (cname = "SANE_TITLE_ANALOG_GAMMA_B", cheader_filename = "sane/saneopts.h")] + public static string TITLE_ANALOG_GAMMA_B; + [CCode (cname = "SANE_TITLE_ANALOG_GAMMA_BIND", cheader_filename = "sane/saneopts.h")] + public static string TITLE_ANALOG_GAMMA_BIND; + [CCode (cname = "SANE_TITLE_WARMUP", cheader_filename = "sane/saneopts.h")] + public static string TITLE_WARMUP; + [CCode (cname = "SANE_TITLE_CAL_EXPOS_TIME", cheader_filename = "sane/saneopts.h")] + public static string TITLE_CAL_EXPOS_TIME; + [CCode (cname = "SANE_TITLE_CAL_EXPOS_TIME_R", cheader_filename = "sane/saneopts.h")] + public static string TITLE_CAL_EXPOS_TIME_R; + [CCode (cname = "SANE_TITLE_CAL_EXPOS_TIME_G", cheader_filename = "sane/saneopts.h")] + public static string TITLE_CAL_EXPOS_TIME_G; + [CCode (cname = "SANE_TITLE_CAL_EXPOS_TIME_B", cheader_filename = "sane/saneopts.h")] + public static string TITLE_CAL_EXPOS_TIME_B; + [CCode (cname = "SANE_TITLE_SCAN_EXPOS_TIME", cheader_filename = "sane/saneopts.h")] + public static string TITLE_SCAN_EXPOS_TIME; + [CCode (cname = "SANE_TITLE_SCAN_EXPOS_TIME_R", cheader_filename = "sane/saneopts.h")] + public static string TITLE_SCAN_EXPOS_TIME_R; + [CCode (cname = "SANE_TITLE_SCAN_EXPOS_TIME_G", cheader_filename = "sane/saneopts.h")] + public static string TITLE_SCAN_EXPOS_TIME_G; + [CCode (cname = "SANE_TITLE_SCAN_EXPOS_TIME_B", cheader_filename = "sane/saneopts.h")] + public static string TITLE_SCAN_EXPOS_TIME_B; + [CCode (cname = "SANE_TITLE_SELECT_EXPOSURE_TIME", cheader_filename = "sane/saneopts.h")] + public static string TITLE_SELECT_EXPOSURE_TIME; + [CCode (cname = "SANE_TITLE_CAL_LAMP_DEN", cheader_filename = "sane/saneopts.h")] + public static string TITLE_CAL_LAMP_DEN; + [CCode (cname = "SANE_TITLE_SCAN_LAMP_DEN", cheader_filename = "sane/saneopts.h")] + public static string TITLE_SCAN_LAMP_DEN; + [CCode (cname = "SANE_TITLE_SELECT_LAMP_DENSITY", cheader_filename = "sane/saneopts.h")] + public static string TITLE_SELECT_LAMP_DENSITY; + [CCode (cname = "SANE_TITLE_LAMP_OFF_AT_EXIT", cheader_filename = "sane/saneopts.h")] + public static string TITLE_LAMP_OFF_AT_EXIT; + [CCode (cname = "SANE_TITLE_SCAN", cheader_filename = "sane/saneopts.h")] + public static string TITLE_SCAN; + [CCode (cname = "SANE_TITLE_EMAIL", cheader_filename = "sane/saneopts.h")] + public static string TITLE_EMAIL; + [CCode (cname = "SANE_TITLE_FAX", cheader_filename = "sane/saneopts.h")] + public static string TITLE_FAX; + [CCode (cname = "SANE_TITLE_COPY", cheader_filename = "sane/saneopts.h")] + public static string TITLE_COPY; + [CCode (cname = "SANE_TITLE_PDF", cheader_filename = "sane/saneopts.h")] + public static string TITLE_PDF; + [CCode (cname = "SANE_TITLE_CANCEL", cheader_filename = "sane/saneopts.h")] + public static string TITLE_CANCEL; + [CCode (cname = "SANE_TITLE_PAGE_LOADED", cheader_filename = "sane/saneopts.h")] + public static string TITLE_PAGE_LOADED; + [CCode (cname = "SANE_TITLE_COVER_OPEN", cheader_filename = "sane/saneopts.h")] + public static string TITLE_COVER_OPEN; + [CCode (cname = "SANE_DESC_NUM_OPTIONS", cheader_filename = "sane/saneopts.h")] + public static string DESC_NUM_OPTIONS; + [CCode (cname = "SANE_DESC_STANDARD", cheader_filename = "sane/saneopts.h")] + public static string DESC_STANDARD; + [CCode (cname = "SANE_DESC_GEOMETRY", cheader_filename = "sane/saneopts.h")] + public static string DESC_GEOMETRY; + [CCode (cname = "SANE_DESC_ENHANCEMENT", cheader_filename = "sane/saneopts.h")] + public static string DESC_ENHANCEMENT; + [CCode (cname = "SANE_DESC_ADVANCED", cheader_filename = "sane/saneopts.h")] + public static string DESC_ADVANCED; + [CCode (cname = "SANE_DESC_SENSORS", cheader_filename = "sane/saneopts.h")] + public static string DESC_SENSORS; + [CCode (cname = "SANE_DESC_PREVIEW", cheader_filename = "sane/saneopts.h")] + public static string DESC_PREVIEW; + [CCode (cname = "SANE_DESC_GRAY_PREVIEW", cheader_filename = "sane/saneopts.h")] + public static string DESC_GRAY_PREVIEW; + [CCode (cname = "SANE_DESC_BIT_DEPTH", cheader_filename = "sane/saneopts.h")] + public static string DESC_BIT_DEPTH; + [CCode (cname = "SANE_DESC_SCAN_MODE", cheader_filename = "sane/saneopts.h")] + public static string DESC_SCAN_MODE; + [CCode (cname = "SANE_DESC_SCAN_SPEED", cheader_filename = "sane/saneopts.h")] + public static string DESC_SCAN_SPEED; + [CCode (cname = "SANE_DESC_SCAN_SOURCE", cheader_filename = "sane/saneopts.h")] + public static string DESC_SCAN_SOURCE; + [CCode (cname = "SANE_DESC_BACKTRACK", cheader_filename = "sane/saneopts.h")] + public static string DESC_BACKTRACK; + [CCode (cname = "SANE_DESC_SCAN_TL_X", cheader_filename = "sane/saneopts.h")] + public static string DESC_SCAN_TL_X; + [CCode (cname = "SANE_DESC_SCAN_TL_Y", cheader_filename = "sane/saneopts.h")] + public static string DESC_SCAN_TL_Y; + [CCode (cname = "SANE_DESC_SCAN_BR_X", cheader_filename = "sane/saneopts.h")] + public static string DESC_SCAN_BR_X; + [CCode (cname = "SANE_DESC_SCAN_BR_Y", cheader_filename = "sane/saneopts.h")] + public static string DESC_SCAN_BR_Y; + [CCode (cname = "SANE_DESC_SCAN_RESOLUTION", cheader_filename = "sane/saneopts.h")] + public static string DESC_SCAN_RESOLUTION; + [CCode (cname = "SANE_DESC_SCAN_X_RESOLUTION", cheader_filename = "sane/saneopts.h")] + public static string DESC_SCAN_X_RESOLUTION; + [CCode (cname = "SANE_DESC_SCAN_Y_RESOLUTION", cheader_filename = "sane/saneopts.h")] + public static string DESC_SCAN_Y_RESOLUTION; + [CCode (cname = "SANE_DESC_PAGE_WIDTH", cheader_filename = "sane/saneopts.h")] + public static string DESC_PAGE_WIDTH; + [CCode (cname = "SANE_DESC_PAGE_HEIGHT", cheader_filename = "sane/saneopts.h")] + public static string DESC_PAGE_HEIGHT; + [CCode (cname = "SANE_DESC_CUSTOM_GAMMA", cheader_filename = "sane/saneopts.h")] + public static string DESC_CUSTOM_GAMMA; + [CCode (cname = "SANE_DESC_GAMMA_VECTOR", cheader_filename = "sane/saneopts.h")] + public static string DESC_GAMMA_VECTOR; + [CCode (cname = "SANE_DESC_GAMMA_VECTOR_R", cheader_filename = "sane/saneopts.h")] + public static string DESC_GAMMA_VECTOR_R; + [CCode (cname = "SANE_DESC_GAMMA_VECTOR_G", cheader_filename = "sane/saneopts.h")] + public static string DESC_GAMMA_VECTOR_G; + [CCode (cname = "SANE_DESC_GAMMA_VECTOR_B", cheader_filename = "sane/saneopts.h")] + public static string DESC_GAMMA_VECTOR_B; + [CCode (cname = "SANE_DESC_BRIGHTNESS", cheader_filename = "sane/saneopts.h")] + public static string DESC_BRIGHTNESS; + [CCode (cname = "SANE_DESC_CONTRAST", cheader_filename = "sane/saneopts.h")] + public static string DESC_CONTRAST; + [CCode (cname = "SANE_DESC_GRAIN_SIZE", cheader_filename = "sane/saneopts.h")] + public static string DESC_GRAIN_SIZE; + [CCode (cname = "SANE_DESC_HALFTONE", cheader_filename = "sane/saneopts.h")] + public static string DESC_HALFTONE; + [CCode (cname = "SANE_DESC_BLACK_LEVEL", cheader_filename = "sane/saneopts.h")] + public static string DESC_BLACK_LEVEL; + [CCode (cname = "SANE_DESC_WHITE_LEVEL", cheader_filename = "sane/saneopts.h")] + public static string DESC_WHITE_LEVEL; + [CCode (cname = "SANE_DESC_WHITE_LEVEL_R", cheader_filename = "sane/saneopts.h")] + public static string DESC_WHITE_LEVEL_R; + [CCode (cname = "SANE_DESC_WHITE_LEVEL_G", cheader_filename = "sane/saneopts.h")] + public static string DESC_WHITE_LEVEL_G; + [CCode (cname = "SANE_DESC_WHITE_LEVEL_B", cheader_filename = "sane/saneopts.h")] + public static string DESC_WHITE_LEVEL_B; + [CCode (cname = "SANE_DESC_SHADOW", cheader_filename = "sane/saneopts.h")] + public static string DESC_SHADOW; + [CCode (cname = "SANE_DESC_SHADOW_R", cheader_filename = "sane/saneopts.h")] + public static string DESC_SHADOW_R; + [CCode (cname = "SANE_DESC_SHADOW_G", cheader_filename = "sane/saneopts.h")] + public static string DESC_SHADOW_G; + [CCode (cname = "SANE_DESC_SHADOW_B", cheader_filename = "sane/saneopts.h")] + public static string DESC_SHADOW_B; + [CCode (cname = "SANE_DESC_HIGHLIGHT", cheader_filename = "sane/saneopts.h")] + public static string DESC_HIGHLIGHT; + [CCode (cname = "SANE_DESC_HIGHLIGHT_R", cheader_filename = "sane/saneopts.h")] + public static string DESC_HIGHLIGHT_R; + [CCode (cname = "SANE_DESC_HIGHLIGHT_G", cheader_filename = "sane/saneopts.h")] + public static string DESC_HIGHLIGHT_G; + [CCode (cname = "SANE_DESC_HIGHLIGHT_B", cheader_filename = "sane/saneopts.h")] + public static string DESC_HIGHLIGHT_B; + [CCode (cname = "SANE_DESC_HUE", cheader_filename = "sane/saneopts.h")] + public static string DESC_HUE; + [CCode (cname = "SANE_DESC_SATURATION", cheader_filename = "sane/saneopts.h")] + public static string DESC_SATURATION; + [CCode (cname = "SANE_DESC_FILE", cheader_filename = "sane/saneopts.h")] + public static string DESC_FILE; + [CCode (cname = "SANE_DESC_HALFTONE_DIMENSION", cheader_filename = "sane/saneopts.h")] + public static string DESC_HALFTONE_DIMENSION; + [CCode (cname = "SANE_DESC_HALFTONE_PATTERN", cheader_filename = "sane/saneopts.h")] + public static string DESC_HALFTONE_PATTERN; + [CCode (cname = "SANE_DESC_RESOLUTION_BIND", cheader_filename = "sane/saneopts.h")] + public static string DESC_RESOLUTION_BIND; + [CCode (cname = "SANE_DESC_NEGATIVE", cheader_filename = "sane/saneopts.h")] + public static string DESC_NEGATIVE; + [CCode (cname = "SANE_DESC_QUALITY_CAL", cheader_filename = "sane/saneopts.h")] + public static string DESC_QUALITY_CAL; + [CCode (cname = "SANE_DESC_DOR", cheader_filename = "sane/saneopts.h")] + public static string DESC_DOR; + [CCode (cname = "SANE_DESC_RGB_BIND", cheader_filename = "sane/saneopts.h")] + public static string DESC_RGB_BIND; + [CCode (cname = "SANE_DESC_THRESHOLD", cheader_filename = "sane/saneopts.h")] + public static string DESC_THRESHOLD; + [CCode (cname = "SANE_DESC_ANALOG_GAMMA", cheader_filename = "sane/saneopts.h")] + public static string DESC_ANALOG_GAMMA; + [CCode (cname = "SANE_DESC_ANALOG_GAMMA_R", cheader_filename = "sane/saneopts.h")] + public static string DESC_ANALOG_GAMMA_R; + [CCode (cname = "SANE_DESC_ANALOG_GAMMA_G", cheader_filename = "sane/saneopts.h")] + public static string DESC_ANALOG_GAMMA_G; + [CCode (cname = "SANE_DESC_ANALOG_GAMMA_B", cheader_filename = "sane/saneopts.h")] + public static string DESC_ANALOG_GAMMA_B; + [CCode (cname = "SANE_DESC_ANALOG_GAMMA_BIND", cheader_filename = "sane/saneopts.h")] + public static string DESC_ANALOG_GAMMA_BIND; + [CCode (cname = "SANE_DESC_WARMUP", cheader_filename = "sane/saneopts.h")] + public static string DESC_WARMUP; + [CCode (cname = "SANE_DESC_CAL_EXPOS_TIME", cheader_filename = "sane/saneopts.h")] + public static string DESC_CAL_EXPOS_TIME; + [CCode (cname = "SANE_DESC_CAL_EXPOS_TIME_R", cheader_filename = "sane/saneopts.h")] + public static string DESC_CAL_EXPOS_TIME_R; + [CCode (cname = "SANE_DESC_CAL_EXPOS_TIME_G", cheader_filename = "sane/saneopts.h")] + public static string DESC_CAL_EXPOS_TIME_G; + [CCode (cname = "SANE_DESC_CAL_EXPOS_TIME_B", cheader_filename = "sane/saneopts.h")] + public static string DESC_CAL_EXPOS_TIME_B; + [CCode (cname = "SANE_DESC_SCAN_EXPOS_TIME", cheader_filename = "sane/saneopts.h")] + public static string DESC_SCAN_EXPOS_TIME; + [CCode (cname = "SANE_DESC_SCAN_EXPOS_TIME_R", cheader_filename = "sane/saneopts.h")] + public static string DESC_SCAN_EXPOS_TIME_R; + [CCode (cname = "SANE_DESC_SCAN_EXPOS_TIME_G", cheader_filename = "sane/saneopts.h")] + public static string DESC_SCAN_EXPOS_TIME_G; + [CCode (cname = "SANE_DESC_SCAN_EXPOS_TIME_B", cheader_filename = "sane/saneopts.h")] + public static string DESC_SCAN_EXPOS_TIME_B; + [CCode (cname = "SANE_DESC_SELECT_EXPOSURE_TIME", cheader_filename = "sane/saneopts.h")] + public static string DESC_SELECT_EXPOSURE_TIME; + [CCode (cname = "SANE_DESC_CAL_LAMP_DEN", cheader_filename = "sane/saneopts.h")] + public static string DESC_CAL_LAMP_DEN; + [CCode (cname = "SANE_DESC_SCAN_LAMP_DEN", cheader_filename = "sane/saneopts.h")] + public static string DESC_SCAN_LAMP_DEN; + [CCode (cname = "SANE_DESC_SELECT_LAMP_DENSITY", cheader_filename = "sane/saneopts.h")] + public static string DESC_SELECT_LAMP_DENSITY; + [CCode (cname = "SANE_DESC_LAMP_OFF_AT_EXIT", cheader_filename = "sane/saneopts.h")] + public static string DESC_LAMP_OFF_AT_EXIT; + [CCode (cname = "SANE_DESC_SCAN", cheader_filename = "sane/saneopts.h")] + public static string DESC_SCAN; + [CCode (cname = "SANE_DESC_EMAIL", cheader_filename = "sane/saneopts.h")] + public static string DESC_EMAIL; + [CCode (cname = "SANE_DESC_FAX", cheader_filename = "sane/saneopts.h")] + public static string DESC_FAX; + [CCode (cname = "SANE_DESC_COPY", cheader_filename = "sane/saneopts.h")] + public static string DESC_COPY; + [CCode (cname = "SANE_DESC_PDF", cheader_filename = "sane/saneopts.h")] + public static string DESC_PDF; + [CCode (cname = "SANE_DESC_CANCEL", cheader_filename = "sane/saneopts.h")] + public static string DESC_CANCEL; + [CCode (cname = "SANE_DESC_PAGE_LOADED", cheader_filename = "sane/saneopts.h")] + public static string DESC_PAGE_LOADED; + [CCode (cname = "SANE_DESC_COVER_OPEN", cheader_filename = "sane/saneopts.h")] + public static string DESC_COVER_OPEN; + [CCode (cname = "SANE_VALUE_SCAN_MODE_COLOR", cheader_filename = "sane/saneopts.h")] + public static string VALUE_SCAN_MODE_COLOR; + [CCode (cname = "SANE_VALUE_SCAN_MODE_COLOR_LINEART", cheader_filename = "sane/saneopts.h")] + public static string VALUE_SCAN_MODE_COLOR_LINEART; + [CCode (cname = "SANE_VALUE_SCAN_MODE_COLOR_HALFTONE", cheader_filename = "sane/saneopts.h")] + public static string VALUE_SCAN_MODE_COLOR_HALFTONE; + [CCode (cname = "SANE_VALUE_SCAN_MODE_GRAY", cheader_filename = "sane/saneopts.h")] + public static string VALUE_SCAN_MODE_GRAY; + [CCode (cname = "SANE_VALUE_SCAN_MODE_HALFTONE", cheader_filename = "sane/saneopts.h")] + public static string VALUE_SCAN_MODE_HALFTONE; + [CCode (cname = "SANE_VALUE_SCAN_MODE_LINEART", cheader_filename = "sane/saneopts.h")] + public static string VALUE_SCAN_MODE_LINEART; +} diff --git a/src/sane.vapi b/src/sane.vapi deleted file mode 100644 index f636dac..0000000 --- a/src/sane.vapi +++ /dev/null @@ -1,754 +0,0 @@ -[CCode (cprefix = "SANE_", lower_case_cprefix = "sane_", cheader_filename = "sane/sane.h")] -namespace Sane { - [SimpleType] - [BooleanType] - public struct Bool - { - } - - [SimpleType] - [IntegerType (rank = 9)] - public struct Int - { - } - - [SimpleType] - [IntegerType (rank = 9)] - public struct Fixed - { - } - - [SimpleType] - [IntegerType (rank = 9)] - public struct Word - { - } - - [CCode (ref_function = "", unref_function = "")] - public class Device - { - public string name; - public string vendor; - public string model; - public string type; - } - - public enum Status - { - GOOD, - UNSUPPORTED, - CANCELLED, - DEVICE_BUSY, - INVAL, - EOF, - JAMMED, - NO_DOCS, - COVER_OPEN, - IO_ERROR, - NO_MEM, - ACCESS_DENIED - } - - public static string status_to_string (Status status) - { - switch (status) - { - case Status.GOOD: - return "SANE_STATUS_GOOD"; - case Status.UNSUPPORTED: - return "SANE_STATUS_UNSUPPORTED"; - case Status.CANCELLED: - return "SANE_STATUS_CANCELLED"; - case Status.DEVICE_BUSY: - return "SANE_STATUS_DEVICE_BUSY"; - case Status.INVAL: - return "SANE_STATUS_INVAL"; - case Status.EOF: - return "SANE_STATUS_EOF"; - case Status.JAMMED: - return "SANE_STATUS_JAMMED"; - case Status.NO_DOCS: - return "SANE_STATUS_NO_DOCS"; - case Status.COVER_OPEN: - return "SANE_STATUS_COVER_OPEN"; - case Status.IO_ERROR: - return "SANE_STATUS_IO_ERROR"; - case Status.NO_MEM: - return "SANE_STATUS_NO_MEM"; - case Status.ACCESS_DENIED: - return "SANE_STATUS_ACCESS_DENIED"; - default: - return "SANE_STATUS(%d)".printf (status); - } - } - - public enum Action - { - GET_VALUE, - SET_VALUE, - SET_AUTO - } - - public enum Frame - { - GRAY, - RGB, - RED, - GREEN, - BLUE - } - - public static string frame_to_string (Frame frame) - { - switch (frame) - { - case Frame.GRAY: - return "SANE_FRAME_GRAY"; - case Frame.RGB: - return "SANE_FRAME_RGB"; - case Frame.RED: - return "SANE_FRAME_RED"; - case Frame.GREEN: - return "SANE_FRAME_GREEN"; - case Frame.BLUE: - return "SANE_FRAME_BLUE"; - default: - return "SANE_FRAME(%d)".printf (frame); - } - } - - public struct Parameters - { - Frame format; - bool last_frame; - int bytes_per_line; - int pixels_per_line; - int lines; - int depth; - } - - [CCode (cname = "SANE_MAX_USERNAME_LEN")] - public int MAX_USERNAME_LEN; - - [CCode (cname = "SANE_MAX_USERNAME_LEN")] - public int MAX_PASSWORD_LEN; - - [CCode (cname = "SANE_Value_Type", cprefix = "SANE_TYPE_")] - public enum ValueType - { - BOOL, - INT, - FIXED, - STRING, - BUTTON, - GROUP - } - - public enum Unit - { - NONE, - PIXEL, - BIT, - MM, - DPI, - PERCENT, - MICROSECOND - } - - [CCode (cname = "SANE_Constraint_Type", cprefix = "SANE_CONSTRAINT_")] - public enum ConstraintType - { - NONE, - RANGE, - WORD_LIST, - STRING_LIST - } - - public class Range - { - public Word min; - public Word max; - public Word quant; - } - - [CCode (cprefix = "SANE_CAP_")] - public enum Capability - { - SOFT_SELECT, - HARD_SELECT, - SOFT_DETECT, - EMULATED, - AUTOMATIC, - INACTIVE, - ADVANCED - } - - [CCode (cname = "SANE_Option_Descriptor", ref_function = "", unref_function = "")] - public class OptionDescriptor - { - public unowned string name; - public unowned string title; - public unowned string desc; - public ValueType type; - public Unit unit; - public Int size; - public Int cap; - - public ConstraintType constraint_type; - [CCode (cname = "constraint.string_list", array_length = false, array_null_terminated = true)] - public string[] string_list; - [CCode (cname = "constraint.word_list", array_length = false)] - public Word[] word_list; - [CCode (cname = "constraint.range")] - public Range range; - } - - [CCode (type = "Int", cprefix = "SANE_INFO_")] - public enum Info - { - INEXACT, - RELOAD_OPTIONS, - RELOAD_PARAMS - } - - [SimpleType] - public struct Handle - { - } - - [CCode (has_target = false)] - public delegate void AuthCallback (string resource, [CCode (array_length = false)] char[] username, [CCode (array_length = false)] char[] password); - - [CCode (cname = "SANE_VERSION_MAJOR")] - public int VERSION_MAJOR (Int code); - [CCode (cname = "SANE_VERSION_MINOR")] - public int VERSION_MINOR (Int code); - [CCode (cname = "SANE_VERSION_BUILD")] - public int VERSION_BUILD (Int code); - - [CCode (cname = "SANE_FIX")] - public Fixed FIX (double d); - [CCode (cname = "SANE_UNFIX")] - public double UNFIX (Fixed w); - - [CCode (cname = "SANE_I18N")] - public unowned string I18N (string value); - - public Status init (out Int version_code, AuthCallback callback); - public void exit (); - public Status get_devices ([CCode (array_length = false, null_terminated = true)] out unowned Device[] device_list, bool local_only); - public unowned string strstatus (Status status); - public Status open (string devicename, out Handle handle); - public void close (Handle handle); - public unowned OptionDescriptor? get_option_descriptor (Handle handle, Int option); - public Status control_option (Handle handle, Int option, Action action, void *value, out Info? info = null); - public Status get_parameters (Handle handle, out Parameters params); - public Status start (Handle handle); - public Status read (Handle handle, uint8* data, Int max_length, out Int length); - public void cancel (Handle handle); - public Status set_io_mode (Handle handle, bool non_blocking); - public Status get_select_fd (Handle handle, out int fd); - - [CCode (cname = "SANE_NAME_STANDARD", cheader_filename = "sane/saneopts.h")] - public static string NAME_STANDARD; - [CCode (cname = "SANE_NAME_GEOMETRY", cheader_filename = "sane/saneopts.h")] - public static string NAME_GEOMETRY; - [CCode (cname = "SANE_NAME_ENHANCEMENT", cheader_filename = "sane/saneopts.h")] - public static string NAME_ENHANCEMENT; - [CCode (cname = "SANE_NAME_ADVANCED", cheader_filename = "sane/saneopts.h")] - public static string NAME_ADVANCED; - [CCode (cname = "SANE_NAME_SENSORS", cheader_filename = "sane/saneopts.h")] - public static string NAME_SENSORS; - [CCode (cname = "SANE_NAME_PREVIEW", cheader_filename = "sane/saneopts.h")] - public static string NAME_PREVIEW; - [CCode (cname = "SANE_NAME_GRAY_PREVIEW", cheader_filename = "sane/saneopts.h")] - public static string NAME_GRAY_PREVIEW; - [CCode (cname = "SANE_NAME_BIT_DEPTH", cheader_filename = "sane/saneopts.h")] - public static string NAME_BIT_DEPTH; - [CCode (cname = "SANE_NAME_SCAN_MODE", cheader_filename = "sane/saneopts.h")] - public static string NAME_SCAN_MODE; - [CCode (cname = "SANE_NAME_SCAN_SPEED", cheader_filename = "sane/saneopts.h")] - public static string NAME_SCAN_SPEED; - [CCode (cname = "SANE_NAME_SCAN_SOURCE", cheader_filename = "sane/saneopts.h")] - public static string NAME_SCAN_SOURCE; - [CCode (cname = "SANE_NAME_BACKTRACK", cheader_filename = "sane/saneopts.h")] - public static string NAME_BACKTRACK; - [CCode (cname = "SANE_NAME_SCAN_TL_X", cheader_filename = "sane/saneopts.h")] - public static string NAME_SCAN_TL_X; - [CCode (cname = "SANE_NAME_SCAN_TL_Y", cheader_filename = "sane/saneopts.h")] - public static string NAME_SCAN_TL_Y; - [CCode (cname = "SANE_NAME_SCAN_BR_X", cheader_filename = "sane/saneopts.h")] - public static string NAME_SCAN_BR_X; - [CCode (cname = "SANE_NAME_SCAN_BR_Y", cheader_filename = "sane/saneopts.h")] - public static string NAME_SCAN_BR_Y; - [CCode (cname = "SANE_NAME_SCAN_RESOLUTION", cheader_filename = "sane/saneopts.h")] - public static string NAME_SCAN_RESOLUTION; - [CCode (cname = "SANE_NAME_SCAN_X_RESOLUTION", cheader_filename = "sane/saneopts.h")] - public static string NAME_SCAN_X_RESOLUTION; - [CCode (cname = "SANE_NAME_SCAN_Y_RESOLUTION", cheader_filename = "sane/saneopts.h")] - public static string NAME_SCAN_Y_RESOLUTION; - [CCode (cname = "SANE_NAME_PAGE_WIDTH", cheader_filename = "sane/saneopts.h")] - public static string NAME_PAGE_WIDTH; - [CCode (cname = "SANE_NAME_PAGE_HEIGHT", cheader_filename = "sane/saneopts.h")] - public static string NAME_PAGE_HEIGHT; - [CCode (cname = "SANE_NAME_CUSTOM_GAMMA", cheader_filename = "sane/saneopts.h")] - public static string NAME_CUSTOM_GAMMA; - [CCode (cname = "SANE_NAME_GAMMA_VECTOR", cheader_filename = "sane/saneopts.h")] - public static string NAME_GAMMA_VECTOR; - [CCode (cname = "SANE_NAME_GAMMA_VECTOR_R", cheader_filename = "sane/saneopts.h")] - public static string NAME_GAMMA_VECTOR_R; - [CCode (cname = "SANE_NAME_GAMMA_VECTOR_G", cheader_filename = "sane/saneopts.h")] - public static string NAME_GAMMA_VECTOR_G; - [CCode (cname = "SANE_NAME_GAMMA_VECTOR_B", cheader_filename = "sane/saneopts.h")] - public static string NAME_GAMMA_VECTOR_B; - [CCode (cname = "SANE_NAME_BRIGHTNESS", cheader_filename = "sane/saneopts.h")] - public static string NAME_BRIGHTNESS; - [CCode (cname = "SANE_NAME_CONTRAST", cheader_filename = "sane/saneopts.h")] - public static string NAME_CONTRAST; - [CCode (cname = "SANE_NAME_GRAIN_SIZE", cheader_filename = "sane/saneopts.h")] - public static string NAME_GRAIN_SIZE; - [CCode (cname = "SANE_NAME_HALFTONE", cheader_filename = "sane/saneopts.h")] - public static string NAME_HALFTONE; - [CCode (cname = "SANE_NAME_BLACK_LEVEL", cheader_filename = "sane/saneopts.h")] - public static string NAME_BLACK_LEVEL; - [CCode (cname = "SANE_NAME_WHITE_LEVEL", cheader_filename = "sane/saneopts.h")] - public static string NAME_WHITE_LEVEL; - [CCode (cname = "SANE_NAME_WHITE_LEVEL_R", cheader_filename = "sane/saneopts.h")] - public static string NAME_WHITE_LEVEL_R; - [CCode (cname = "SANE_NAME_WHITE_LEVEL_G", cheader_filename = "sane/saneopts.h")] - public static string NAME_WHITE_LEVEL_G; - [CCode (cname = "SANE_NAME_WHITE_LEVEL_B", cheader_filename = "sane/saneopts.h")] - public static string NAME_WHITE_LEVEL_B; - [CCode (cname = "SANE_NAME_SHADOW", cheader_filename = "sane/saneopts.h")] - public static string NAME_SHADOW; - [CCode (cname = "SANE_NAME_SHADOW_R", cheader_filename = "sane/saneopts.h")] - public static string NAME_SHADOW_R; - [CCode (cname = "SANE_NAME_SHADOW_G", cheader_filename = "sane/saneopts.h")] - public static string NAME_SHADOW_G; - [CCode (cname = "SANE_NAME_SHADOW_B", cheader_filename = "sane/saneopts.h")] - public static string NAME_SHADOW_B; - [CCode (cname = "SANE_NAME_HIGHLIGHT", cheader_filename = "sane/saneopts.h")] - public static string NAME_HIGHLIGHT; - [CCode (cname = "SANE_NAME_HIGHLIGHT_R", cheader_filename = "sane/saneopts.h")] - public static string NAME_HIGHLIGHT_R; - [CCode (cname = "SANE_NAME_HIGHLIGHT_G", cheader_filename = "sane/saneopts.h")] - public static string NAME_HIGHLIGHT_G; - [CCode (cname = "SANE_NAME_HIGHLIGHT_B", cheader_filename = "sane/saneopts.h")] - public static string NAME_HIGHLIGHT_B; - [CCode (cname = "SANE_NAME_HUE", cheader_filename = "sane/saneopts.h")] - public static string NAME_HUE; - [CCode (cname = "SANE_NAME_SATURATION", cheader_filename = "sane/saneopts.h")] - public static string NAME_SATURATION; - [CCode (cname = "SANE_NAME_FILE", cheader_filename = "sane/saneopts.h")] - public static string NAME_FILE; - [CCode (cname = "SANE_NAME_HALFTONE_DIMENSION", cheader_filename = "sane/saneopts.h")] - public static string NAME_HALFTONE_DIMENSION; - [CCode (cname = "SANE_NAME_HALFTONE_PATTERN", cheader_filename = "sane/saneopts.h")] - public static string NAME_HALFTONE_PATTERN; - [CCode (cname = "SANE_NAME_RESOLUTION_BIND", cheader_filename = "sane/saneopts.h")] - public static string NAME_RESOLUTION_BIND; - [CCode (cname = "SANE_NAME_NEGATIVE", cheader_filename = "sane/saneopts.h")] - public static string NAME_NEGATIVE; - [CCode (cname = "SANE_NAME_QUALITY_CAL", cheader_filename = "sane/saneopts.h")] - public static string NAME_QUALITY_CAL; - [CCode (cname = "SANE_NAME_DOR", cheader_filename = "sane/saneopts.h")] - public static string NAME_DOR; - [CCode (cname = "SANE_NAME_RGB_BIND", cheader_filename = "sane/saneopts.h")] - public static string NAME_RGB_BIND; - [CCode (cname = "SANE_NAME_THRESHOLD", cheader_filename = "sane/saneopts.h")] - public static string NAME_THRESHOLD; - [CCode (cname = "SANE_NAME_ANALOG_GAMMA", cheader_filename = "sane/saneopts.h")] - public static string NAME_ANALOG_GAMMA; - [CCode (cname = "SANE_NAME_ANALOG_GAMMA_R", cheader_filename = "sane/saneopts.h")] - public static string NAME_ANALOG_GAMMA_R; - [CCode (cname = "SANE_NAME_ANALOG_GAMMA_G", cheader_filename = "sane/saneopts.h")] - public static string NAME_ANALOG_GAMMA_G; - [CCode (cname = "SANE_NAME_ANALOG_GAMMA_B", cheader_filename = "sane/saneopts.h")] - public static string NAME_ANALOG_GAMMA_B; - [CCode (cname = "SANE_NAME_ANALOG_GAMMA_BIND", cheader_filename = "sane/saneopts.h")] - public static string NAME_ANALOG_GAMMA_BIND; - [CCode (cname = "SANE_NAME_WARMUP", cheader_filename = "sane/saneopts.h")] - public static string NAME_WARMUP; - [CCode (cname = "SANE_NAME_CAL_EXPOS_TIME", cheader_filename = "sane/saneopts.h")] - public static string NAME_CAL_EXPOS_TIME; - [CCode (cname = "SANE_NAME_CAL_EXPOS_TIME_R", cheader_filename = "sane/saneopts.h")] - public static string NAME_CAL_EXPOS_TIME_R; - [CCode (cname = "SANE_NAME_CAL_EXPOS_TIME_G", cheader_filename = "sane/saneopts.h")] - public static string NAME_CAL_EXPOS_TIME_G; - [CCode (cname = "SANE_NAME_CAL_EXPOS_TIME_B", cheader_filename = "sane/saneopts.h")] - public static string NAME_CAL_EXPOS_TIME_B; - [CCode (cname = "SANE_NAME_SCAN_EXPOS_TIME", cheader_filename = "sane/saneopts.h")] - public static string NAME_SCAN_EXPOS_TIME; - [CCode (cname = "SANE_NAME_SCAN_EXPOS_TIME_R", cheader_filename = "sane/saneopts.h")] - public static string NAME_SCAN_EXPOS_TIME_R; - [CCode (cname = "SANE_NAME_SCAN_EXPOS_TIME_G", cheader_filename = "sane/saneopts.h")] - public static string NAME_SCAN_EXPOS_TIME_G; - [CCode (cname = "SANE_NAME_SCAN_EXPOS_TIME_B", cheader_filename = "sane/saneopts.h")] - public static string NAME_SCAN_EXPOS_TIME_B; - [CCode (cname = "SANE_NAME_SELECT_EXPOSURE_TIME", cheader_filename = "sane/saneopts.h")] - public static string NAME_SELECT_EXPOSURE_TIME; - [CCode (cname = "SANE_NAME_CAL_LAMP_DEN", cheader_filename = "sane/saneopts.h")] - public static string NAME_CAL_LAMP_DEN; - [CCode (cname = "SANE_NAME_SCAN_LAMP_DEN", cheader_filename = "sane/saneopts.h")] - public static string NAME_SCAN_LAMP_DEN; - [CCode (cname = "SANE_NAME_SELECT_LAMP_DENSITY", cheader_filename = "sane/saneopts.h")] - public static string NAME_SELECT_LAMP_DENSITY; - [CCode (cname = "SANE_NAME_LAMP_OFF_AT_EXIT", cheader_filename = "sane/saneopts.h")] - public static string NAME_LAMP_OFF_AT_EXIT; - [CCode (cname = "SANE_NAME_SCAN", cheader_filename = "sane/saneopts.h")] - public static string NAME_SCAN; - [CCode (cname = "SANE_NAME_EMAIL", cheader_filename = "sane/saneopts.h")] - public static string NAME_EMAIL; - [CCode (cname = "SANE_NAME_FAX", cheader_filename = "sane/saneopts.h")] - public static string NAME_FAX; - [CCode (cname = "SANE_NAME_COPY", cheader_filename = "sane/saneopts.h")] - public static string NAME_COPY; - [CCode (cname = "SANE_NAME_PDF", cheader_filename = "sane/saneopts.h")] - public static string NAME_PDF; - [CCode (cname = "SANE_NAME_CANCEL", cheader_filename = "sane/saneopts.h")] - public static string NAME_CANCEL; - [CCode (cname = "SANE_NAME_PAGE_LOADED", cheader_filename = "sane/saneopts.h")] - public static string NAME_PAGE_LOADED; - [CCode (cname = "SANE_NAME_COVER_OPEN", cheader_filename = "sane/saneopts.h")] - public static string NAME_COVER_OPEN; - [CCode (cname = "SANE_TITLE_NUM_OPTIONS", cheader_filename = "sane/saneopts.h")] - public static string TITLE_NUM_OPTIONS; - [CCode (cname = "SANE_TITLE_STANDARD", cheader_filename = "sane/saneopts.h")] - public static string TITLE_STANDARD; - [CCode (cname = "SANE_TITLE_GEOMETRY", cheader_filename = "sane/saneopts.h")] - public static string TITLE_GEOMETRY; - [CCode (cname = "SANE_TITLE_ENHANCEMENT", cheader_filename = "sane/saneopts.h")] - public static string TITLE_ENHANCEMENT; - [CCode (cname = "SANE_TITLE_ADVANCED", cheader_filename = "sane/saneopts.h")] - public static string TITLE_ADVANCED; - [CCode (cname = "SANE_TITLE_SENSORS", cheader_filename = "sane/saneopts.h")] - public static string TITLE_SENSORS; - [CCode (cname = "SANE_TITLE_PREVIEW", cheader_filename = "sane/saneopts.h")] - public static string TITLE_PREVIEW; - [CCode (cname = "SANE_TITLE_GRAY_PREVIEW", cheader_filename = "sane/saneopts.h")] - public static string TITLE_GRAY_PREVIEW; - [CCode (cname = "SANE_TITLE_BIT_DEPTH", cheader_filename = "sane/saneopts.h")] - public static string TITLE_BIT_DEPTH; - [CCode (cname = "SANE_TITLE_SCAN_MODE", cheader_filename = "sane/saneopts.h")] - public static string TITLE_SCAN_MODE; - [CCode (cname = "SANE_TITLE_SCAN_SPEED", cheader_filename = "sane/saneopts.h")] - public static string TITLE_SCAN_SPEED; - [CCode (cname = "SANE_TITLE_SCAN_SOURCE", cheader_filename = "sane/saneopts.h")] - public static string TITLE_SCAN_SOURCE; - [CCode (cname = "SANE_TITLE_BACKTRACK", cheader_filename = "sane/saneopts.h")] - public static string TITLE_BACKTRACK; - [CCode (cname = "SANE_TITLE_SCAN_TL_X", cheader_filename = "sane/saneopts.h")] - public static string TITLE_SCAN_TL_X; - [CCode (cname = "SANE_TITLE_SCAN_TL_Y", cheader_filename = "sane/saneopts.h")] - public static string TITLE_SCAN_TL_Y; - [CCode (cname = "SANE_TITLE_SCAN_BR_X", cheader_filename = "sane/saneopts.h")] - public static string TITLE_SCAN_BR_X; - [CCode (cname = "SANE_TITLE_SCAN_BR_Y", cheader_filename = "sane/saneopts.h")] - public static string TITLE_SCAN_BR_Y; - [CCode (cname = "SANE_TITLE_SCAN_RESOLUTION", cheader_filename = "sane/saneopts.h")] - public static string TITLE_SCAN_RESOLUTION; - [CCode (cname = "SANE_TITLE_SCAN_X_RESOLUTION", cheader_filename = "sane/saneopts.h")] - public static string TITLE_SCAN_X_RESOLUTION; - [CCode (cname = "SANE_TITLE_SCAN_Y_RESOLUTION", cheader_filename = "sane/saneopts.h")] - public static string TITLE_SCAN_Y_RESOLUTION; - [CCode (cname = "SANE_TITLE_PAGE_WIDTH", cheader_filename = "sane/saneopts.h")] - public static string TITLE_PAGE_WIDTH; - [CCode (cname = "SANE_TITLE_PAGE_HEIGHT", cheader_filename = "sane/saneopts.h")] - public static string TITLE_PAGE_HEIGHT; - [CCode (cname = "SANE_TITLE_CUSTOM_GAMMA", cheader_filename = "sane/saneopts.h")] - public static string TITLE_CUSTOM_GAMMA; - [CCode (cname = "SANE_TITLE_GAMMA_VECTOR", cheader_filename = "sane/saneopts.h")] - public static string TITLE_GAMMA_VECTOR; - [CCode (cname = "SANE_TITLE_GAMMA_VECTOR_R", cheader_filename = "sane/saneopts.h")] - public static string TITLE_GAMMA_VECTOR_R; - [CCode (cname = "SANE_TITLE_GAMMA_VECTOR_G", cheader_filename = "sane/saneopts.h")] - public static string TITLE_GAMMA_VECTOR_G; - [CCode (cname = "SANE_TITLE_GAMMA_VECTOR_B", cheader_filename = "sane/saneopts.h")] - public static string TITLE_GAMMA_VECTOR_B; - [CCode (cname = "SANE_TITLE_BRIGHTNESS", cheader_filename = "sane/saneopts.h")] - public static string TITLE_BRIGHTNESS; - [CCode (cname = "SANE_TITLE_CONTRAST", cheader_filename = "sane/saneopts.h")] - public static string TITLE_CONTRAST; - [CCode (cname = "SANE_TITLE_GRAIN_SIZE", cheader_filename = "sane/saneopts.h")] - public static string TITLE_GRAIN_SIZE; - [CCode (cname = "SANE_TITLE_HALFTONE", cheader_filename = "sane/saneopts.h")] - public static string TITLE_HALFTONE; - [CCode (cname = "SANE_TITLE_BLACK_LEVEL", cheader_filename = "sane/saneopts.h")] - public static string TITLE_BLACK_LEVEL; - [CCode (cname = "SANE_TITLE_WHITE_LEVEL", cheader_filename = "sane/saneopts.h")] - public static string TITLE_WHITE_LEVEL; - [CCode (cname = "SANE_TITLE_WHITE_LEVEL_R", cheader_filename = "sane/saneopts.h")] - public static string TITLE_WHITE_LEVEL_R; - [CCode (cname = "SANE_TITLE_WHITE_LEVEL_G", cheader_filename = "sane/saneopts.h")] - public static string TITLE_WHITE_LEVEL_G; - [CCode (cname = "SANE_TITLE_WHITE_LEVEL_B", cheader_filename = "sane/saneopts.h")] - public static string TITLE_WHITE_LEVEL_B; - [CCode (cname = "SANE_TITLE_SHADOW", cheader_filename = "sane/saneopts.h")] - public static string TITLE_SHADOW; - [CCode (cname = "SANE_TITLE_SHADOW_R", cheader_filename = "sane/saneopts.h")] - public static string TITLE_SHADOW_R; - [CCode (cname = "SANE_TITLE_SHADOW_G", cheader_filename = "sane/saneopts.h")] - public static string TITLE_SHADOW_G; - [CCode (cname = "SANE_TITLE_SHADOW_B", cheader_filename = "sane/saneopts.h")] - public static string TITLE_SHADOW_B; - [CCode (cname = "SANE_TITLE_HIGHLIGHT", cheader_filename = "sane/saneopts.h")] - public static string TITLE_HIGHLIGHT; - [CCode (cname = "SANE_TITLE_HIGHLIGHT_R", cheader_filename = "sane/saneopts.h")] - public static string TITLE_HIGHLIGHT_R; - [CCode (cname = "SANE_TITLE_HIGHLIGHT_G", cheader_filename = "sane/saneopts.h")] - public static string TITLE_HIGHLIGHT_G; - [CCode (cname = "SANE_TITLE_HIGHLIGHT_B", cheader_filename = "sane/saneopts.h")] - public static string TITLE_HIGHLIGHT_B; - [CCode (cname = "SANE_TITLE_HUE", cheader_filename = "sane/saneopts.h")] - public static string TITLE_HUE; - [CCode (cname = "SANE_TITLE_SATURATION", cheader_filename = "sane/saneopts.h")] - public static string TITLE_SATURATION; - [CCode (cname = "SANE_TITLE_FILE", cheader_filename = "sane/saneopts.h")] - public static string TITLE_FILE; - [CCode (cname = "SANE_TITLE_HALFTONE_DIMENSION", cheader_filename = "sane/saneopts.h")] - public static string TITLE_HALFTONE_DIMENSION; - [CCode (cname = "SANE_TITLE_HALFTONE_PATTERN", cheader_filename = "sane/saneopts.h")] - public static string TITLE_HALFTONE_PATTERN; - [CCode (cname = "SANE_TITLE_RESOLUTION_BIND", cheader_filename = "sane/saneopts.h")] - public static string TITLE_RESOLUTION_BIND; - [CCode (cname = "SANE_TITLE_NEGATIVE", cheader_filename = "sane/saneopts.h")] - public static string TITLE_NEGATIVE; - [CCode (cname = "SANE_TITLE_QUALITY_CAL", cheader_filename = "sane/saneopts.h")] - public static string TITLE_QUALITY_CAL; - [CCode (cname = "SANE_TITLE_DOR", cheader_filename = "sane/saneopts.h")] - public static string TITLE_DOR; - [CCode (cname = "SANE_TITLE_RGB_BIND", cheader_filename = "sane/saneopts.h")] - public static string TITLE_RGB_BIND; - [CCode (cname = "SANE_TITLE_THRESHOLD", cheader_filename = "sane/saneopts.h")] - public static string TITLE_THRESHOLD; - [CCode (cname = "SANE_TITLE_ANALOG_GAMMA", cheader_filename = "sane/saneopts.h")] - public static string TITLE_ANALOG_GAMMA; - [CCode (cname = "SANE_TITLE_ANALOG_GAMMA_R", cheader_filename = "sane/saneopts.h")] - public static string TITLE_ANALOG_GAMMA_R; - [CCode (cname = "SANE_TITLE_ANALOG_GAMMA_G", cheader_filename = "sane/saneopts.h")] - public static string TITLE_ANALOG_GAMMA_G; - [CCode (cname = "SANE_TITLE_ANALOG_GAMMA_B", cheader_filename = "sane/saneopts.h")] - public static string TITLE_ANALOG_GAMMA_B; - [CCode (cname = "SANE_TITLE_ANALOG_GAMMA_BIND", cheader_filename = "sane/saneopts.h")] - public static string TITLE_ANALOG_GAMMA_BIND; - [CCode (cname = "SANE_TITLE_WARMUP", cheader_filename = "sane/saneopts.h")] - public static string TITLE_WARMUP; - [CCode (cname = "SANE_TITLE_CAL_EXPOS_TIME", cheader_filename = "sane/saneopts.h")] - public static string TITLE_CAL_EXPOS_TIME; - [CCode (cname = "SANE_TITLE_CAL_EXPOS_TIME_R", cheader_filename = "sane/saneopts.h")] - public static string TITLE_CAL_EXPOS_TIME_R; - [CCode (cname = "SANE_TITLE_CAL_EXPOS_TIME_G", cheader_filename = "sane/saneopts.h")] - public static string TITLE_CAL_EXPOS_TIME_G; - [CCode (cname = "SANE_TITLE_CAL_EXPOS_TIME_B", cheader_filename = "sane/saneopts.h")] - public static string TITLE_CAL_EXPOS_TIME_B; - [CCode (cname = "SANE_TITLE_SCAN_EXPOS_TIME", cheader_filename = "sane/saneopts.h")] - public static string TITLE_SCAN_EXPOS_TIME; - [CCode (cname = "SANE_TITLE_SCAN_EXPOS_TIME_R", cheader_filename = "sane/saneopts.h")] - public static string TITLE_SCAN_EXPOS_TIME_R; - [CCode (cname = "SANE_TITLE_SCAN_EXPOS_TIME_G", cheader_filename = "sane/saneopts.h")] - public static string TITLE_SCAN_EXPOS_TIME_G; - [CCode (cname = "SANE_TITLE_SCAN_EXPOS_TIME_B", cheader_filename = "sane/saneopts.h")] - public static string TITLE_SCAN_EXPOS_TIME_B; - [CCode (cname = "SANE_TITLE_SELECT_EXPOSURE_TIME", cheader_filename = "sane/saneopts.h")] - public static string TITLE_SELECT_EXPOSURE_TIME; - [CCode (cname = "SANE_TITLE_CAL_LAMP_DEN", cheader_filename = "sane/saneopts.h")] - public static string TITLE_CAL_LAMP_DEN; - [CCode (cname = "SANE_TITLE_SCAN_LAMP_DEN", cheader_filename = "sane/saneopts.h")] - public static string TITLE_SCAN_LAMP_DEN; - [CCode (cname = "SANE_TITLE_SELECT_LAMP_DENSITY", cheader_filename = "sane/saneopts.h")] - public static string TITLE_SELECT_LAMP_DENSITY; - [CCode (cname = "SANE_TITLE_LAMP_OFF_AT_EXIT", cheader_filename = "sane/saneopts.h")] - public static string TITLE_LAMP_OFF_AT_EXIT; - [CCode (cname = "SANE_TITLE_SCAN", cheader_filename = "sane/saneopts.h")] - public static string TITLE_SCAN; - [CCode (cname = "SANE_TITLE_EMAIL", cheader_filename = "sane/saneopts.h")] - public static string TITLE_EMAIL; - [CCode (cname = "SANE_TITLE_FAX", cheader_filename = "sane/saneopts.h")] - public static string TITLE_FAX; - [CCode (cname = "SANE_TITLE_COPY", cheader_filename = "sane/saneopts.h")] - public static string TITLE_COPY; - [CCode (cname = "SANE_TITLE_PDF", cheader_filename = "sane/saneopts.h")] - public static string TITLE_PDF; - [CCode (cname = "SANE_TITLE_CANCEL", cheader_filename = "sane/saneopts.h")] - public static string TITLE_CANCEL; - [CCode (cname = "SANE_TITLE_PAGE_LOADED", cheader_filename = "sane/saneopts.h")] - public static string TITLE_PAGE_LOADED; - [CCode (cname = "SANE_TITLE_COVER_OPEN", cheader_filename = "sane/saneopts.h")] - public static string TITLE_COVER_OPEN; - [CCode (cname = "SANE_DESC_NUM_OPTIONS", cheader_filename = "sane/saneopts.h")] - public static string DESC_NUM_OPTIONS; - [CCode (cname = "SANE_DESC_STANDARD", cheader_filename = "sane/saneopts.h")] - public static string DESC_STANDARD; - [CCode (cname = "SANE_DESC_GEOMETRY", cheader_filename = "sane/saneopts.h")] - public static string DESC_GEOMETRY; - [CCode (cname = "SANE_DESC_ENHANCEMENT", cheader_filename = "sane/saneopts.h")] - public static string DESC_ENHANCEMENT; - [CCode (cname = "SANE_DESC_ADVANCED", cheader_filename = "sane/saneopts.h")] - public static string DESC_ADVANCED; - [CCode (cname = "SANE_DESC_SENSORS", cheader_filename = "sane/saneopts.h")] - public static string DESC_SENSORS; - [CCode (cname = "SANE_DESC_PREVIEW", cheader_filename = "sane/saneopts.h")] - public static string DESC_PREVIEW; - [CCode (cname = "SANE_DESC_GRAY_PREVIEW", cheader_filename = "sane/saneopts.h")] - public static string DESC_GRAY_PREVIEW; - [CCode (cname = "SANE_DESC_BIT_DEPTH", cheader_filename = "sane/saneopts.h")] - public static string DESC_BIT_DEPTH; - [CCode (cname = "SANE_DESC_SCAN_MODE", cheader_filename = "sane/saneopts.h")] - public static string DESC_SCAN_MODE; - [CCode (cname = "SANE_DESC_SCAN_SPEED", cheader_filename = "sane/saneopts.h")] - public static string DESC_SCAN_SPEED; - [CCode (cname = "SANE_DESC_SCAN_SOURCE", cheader_filename = "sane/saneopts.h")] - public static string DESC_SCAN_SOURCE; - [CCode (cname = "SANE_DESC_BACKTRACK", cheader_filename = "sane/saneopts.h")] - public static string DESC_BACKTRACK; - [CCode (cname = "SANE_DESC_SCAN_TL_X", cheader_filename = "sane/saneopts.h")] - public static string DESC_SCAN_TL_X; - [CCode (cname = "SANE_DESC_SCAN_TL_Y", cheader_filename = "sane/saneopts.h")] - public static string DESC_SCAN_TL_Y; - [CCode (cname = "SANE_DESC_SCAN_BR_X", cheader_filename = "sane/saneopts.h")] - public static string DESC_SCAN_BR_X; - [CCode (cname = "SANE_DESC_SCAN_BR_Y", cheader_filename = "sane/saneopts.h")] - public static string DESC_SCAN_BR_Y; - [CCode (cname = "SANE_DESC_SCAN_RESOLUTION", cheader_filename = "sane/saneopts.h")] - public static string DESC_SCAN_RESOLUTION; - [CCode (cname = "SANE_DESC_SCAN_X_RESOLUTION", cheader_filename = "sane/saneopts.h")] - public static string DESC_SCAN_X_RESOLUTION; - [CCode (cname = "SANE_DESC_SCAN_Y_RESOLUTION", cheader_filename = "sane/saneopts.h")] - public static string DESC_SCAN_Y_RESOLUTION; - [CCode (cname = "SANE_DESC_PAGE_WIDTH", cheader_filename = "sane/saneopts.h")] - public static string DESC_PAGE_WIDTH; - [CCode (cname = "SANE_DESC_PAGE_HEIGHT", cheader_filename = "sane/saneopts.h")] - public static string DESC_PAGE_HEIGHT; - [CCode (cname = "SANE_DESC_CUSTOM_GAMMA", cheader_filename = "sane/saneopts.h")] - public static string DESC_CUSTOM_GAMMA; - [CCode (cname = "SANE_DESC_GAMMA_VECTOR", cheader_filename = "sane/saneopts.h")] - public static string DESC_GAMMA_VECTOR; - [CCode (cname = "SANE_DESC_GAMMA_VECTOR_R", cheader_filename = "sane/saneopts.h")] - public static string DESC_GAMMA_VECTOR_R; - [CCode (cname = "SANE_DESC_GAMMA_VECTOR_G", cheader_filename = "sane/saneopts.h")] - public static string DESC_GAMMA_VECTOR_G; - [CCode (cname = "SANE_DESC_GAMMA_VECTOR_B", cheader_filename = "sane/saneopts.h")] - public static string DESC_GAMMA_VECTOR_B; - [CCode (cname = "SANE_DESC_BRIGHTNESS", cheader_filename = "sane/saneopts.h")] - public static string DESC_BRIGHTNESS; - [CCode (cname = "SANE_DESC_CONTRAST", cheader_filename = "sane/saneopts.h")] - public static string DESC_CONTRAST; - [CCode (cname = "SANE_DESC_GRAIN_SIZE", cheader_filename = "sane/saneopts.h")] - public static string DESC_GRAIN_SIZE; - [CCode (cname = "SANE_DESC_HALFTONE", cheader_filename = "sane/saneopts.h")] - public static string DESC_HALFTONE; - [CCode (cname = "SANE_DESC_BLACK_LEVEL", cheader_filename = "sane/saneopts.h")] - public static string DESC_BLACK_LEVEL; - [CCode (cname = "SANE_DESC_WHITE_LEVEL", cheader_filename = "sane/saneopts.h")] - public static string DESC_WHITE_LEVEL; - [CCode (cname = "SANE_DESC_WHITE_LEVEL_R", cheader_filename = "sane/saneopts.h")] - public static string DESC_WHITE_LEVEL_R; - [CCode (cname = "SANE_DESC_WHITE_LEVEL_G", cheader_filename = "sane/saneopts.h")] - public static string DESC_WHITE_LEVEL_G; - [CCode (cname = "SANE_DESC_WHITE_LEVEL_B", cheader_filename = "sane/saneopts.h")] - public static string DESC_WHITE_LEVEL_B; - [CCode (cname = "SANE_DESC_SHADOW", cheader_filename = "sane/saneopts.h")] - public static string DESC_SHADOW; - [CCode (cname = "SANE_DESC_SHADOW_R", cheader_filename = "sane/saneopts.h")] - public static string DESC_SHADOW_R; - [CCode (cname = "SANE_DESC_SHADOW_G", cheader_filename = "sane/saneopts.h")] - public static string DESC_SHADOW_G; - [CCode (cname = "SANE_DESC_SHADOW_B", cheader_filename = "sane/saneopts.h")] - public static string DESC_SHADOW_B; - [CCode (cname = "SANE_DESC_HIGHLIGHT", cheader_filename = "sane/saneopts.h")] - public static string DESC_HIGHLIGHT; - [CCode (cname = "SANE_DESC_HIGHLIGHT_R", cheader_filename = "sane/saneopts.h")] - public static string DESC_HIGHLIGHT_R; - [CCode (cname = "SANE_DESC_HIGHLIGHT_G", cheader_filename = "sane/saneopts.h")] - public static string DESC_HIGHLIGHT_G; - [CCode (cname = "SANE_DESC_HIGHLIGHT_B", cheader_filename = "sane/saneopts.h")] - public static string DESC_HIGHLIGHT_B; - [CCode (cname = "SANE_DESC_HUE", cheader_filename = "sane/saneopts.h")] - public static string DESC_HUE; - [CCode (cname = "SANE_DESC_SATURATION", cheader_filename = "sane/saneopts.h")] - public static string DESC_SATURATION; - [CCode (cname = "SANE_DESC_FILE", cheader_filename = "sane/saneopts.h")] - public static string DESC_FILE; - [CCode (cname = "SANE_DESC_HALFTONE_DIMENSION", cheader_filename = "sane/saneopts.h")] - public static string DESC_HALFTONE_DIMENSION; - [CCode (cname = "SANE_DESC_HALFTONE_PATTERN", cheader_filename = "sane/saneopts.h")] - public static string DESC_HALFTONE_PATTERN; - [CCode (cname = "SANE_DESC_RESOLUTION_BIND", cheader_filename = "sane/saneopts.h")] - public static string DESC_RESOLUTION_BIND; - [CCode (cname = "SANE_DESC_NEGATIVE", cheader_filename = "sane/saneopts.h")] - public static string DESC_NEGATIVE; - [CCode (cname = "SANE_DESC_QUALITY_CAL", cheader_filename = "sane/saneopts.h")] - public static string DESC_QUALITY_CAL; - [CCode (cname = "SANE_DESC_DOR", cheader_filename = "sane/saneopts.h")] - public static string DESC_DOR; - [CCode (cname = "SANE_DESC_RGB_BIND", cheader_filename = "sane/saneopts.h")] - public static string DESC_RGB_BIND; - [CCode (cname = "SANE_DESC_THRESHOLD", cheader_filename = "sane/saneopts.h")] - public static string DESC_THRESHOLD; - [CCode (cname = "SANE_DESC_ANALOG_GAMMA", cheader_filename = "sane/saneopts.h")] - public static string DESC_ANALOG_GAMMA; - [CCode (cname = "SANE_DESC_ANALOG_GAMMA_R", cheader_filename = "sane/saneopts.h")] - public static string DESC_ANALOG_GAMMA_R; - [CCode (cname = "SANE_DESC_ANALOG_GAMMA_G", cheader_filename = "sane/saneopts.h")] - public static string DESC_ANALOG_GAMMA_G; - [CCode (cname = "SANE_DESC_ANALOG_GAMMA_B", cheader_filename = "sane/saneopts.h")] - public static string DESC_ANALOG_GAMMA_B; - [CCode (cname = "SANE_DESC_ANALOG_GAMMA_BIND", cheader_filename = "sane/saneopts.h")] - public static string DESC_ANALOG_GAMMA_BIND; - [CCode (cname = "SANE_DESC_WARMUP", cheader_filename = "sane/saneopts.h")] - public static string DESC_WARMUP; - [CCode (cname = "SANE_DESC_CAL_EXPOS_TIME", cheader_filename = "sane/saneopts.h")] - public static string DESC_CAL_EXPOS_TIME; - [CCode (cname = "SANE_DESC_CAL_EXPOS_TIME_R", cheader_filename = "sane/saneopts.h")] - public static string DESC_CAL_EXPOS_TIME_R; - [CCode (cname = "SANE_DESC_CAL_EXPOS_TIME_G", cheader_filename = "sane/saneopts.h")] - public static string DESC_CAL_EXPOS_TIME_G; - [CCode (cname = "SANE_DESC_CAL_EXPOS_TIME_B", cheader_filename = "sane/saneopts.h")] - public static string DESC_CAL_EXPOS_TIME_B; - [CCode (cname = "SANE_DESC_SCAN_EXPOS_TIME", cheader_filename = "sane/saneopts.h")] - public static string DESC_SCAN_EXPOS_TIME; - [CCode (cname = "SANE_DESC_SCAN_EXPOS_TIME_R", cheader_filename = "sane/saneopts.h")] - public static string DESC_SCAN_EXPOS_TIME_R; - [CCode (cname = "SANE_DESC_SCAN_EXPOS_TIME_G", cheader_filename = "sane/saneopts.h")] - public static string DESC_SCAN_EXPOS_TIME_G; - [CCode (cname = "SANE_DESC_SCAN_EXPOS_TIME_B", cheader_filename = "sane/saneopts.h")] - public static string DESC_SCAN_EXPOS_TIME_B; - [CCode (cname = "SANE_DESC_SELECT_EXPOSURE_TIME", cheader_filename = "sane/saneopts.h")] - public static string DESC_SELECT_EXPOSURE_TIME; - [CCode (cname = "SANE_DESC_CAL_LAMP_DEN", cheader_filename = "sane/saneopts.h")] - public static string DESC_CAL_LAMP_DEN; - [CCode (cname = "SANE_DESC_SCAN_LAMP_DEN", cheader_filename = "sane/saneopts.h")] - public static string DESC_SCAN_LAMP_DEN; - [CCode (cname = "SANE_DESC_SELECT_LAMP_DENSITY", cheader_filename = "sane/saneopts.h")] - public static string DESC_SELECT_LAMP_DENSITY; - [CCode (cname = "SANE_DESC_LAMP_OFF_AT_EXIT", cheader_filename = "sane/saneopts.h")] - public static string DESC_LAMP_OFF_AT_EXIT; - [CCode (cname = "SANE_DESC_SCAN", cheader_filename = "sane/saneopts.h")] - public static string DESC_SCAN; - [CCode (cname = "SANE_DESC_EMAIL", cheader_filename = "sane/saneopts.h")] - public static string DESC_EMAIL; - [CCode (cname = "SANE_DESC_FAX", cheader_filename = "sane/saneopts.h")] - public static string DESC_FAX; - [CCode (cname = "SANE_DESC_COPY", cheader_filename = "sane/saneopts.h")] - public static string DESC_COPY; - [CCode (cname = "SANE_DESC_PDF", cheader_filename = "sane/saneopts.h")] - public static string DESC_PDF; - [CCode (cname = "SANE_DESC_CANCEL", cheader_filename = "sane/saneopts.h")] - public static string DESC_CANCEL; - [CCode (cname = "SANE_DESC_PAGE_LOADED", cheader_filename = "sane/saneopts.h")] - public static string DESC_PAGE_LOADED; - [CCode (cname = "SANE_DESC_COVER_OPEN", cheader_filename = "sane/saneopts.h")] - public static string DESC_COVER_OPEN; - [CCode (cname = "SANE_VALUE_SCAN_MODE_COLOR", cheader_filename = "sane/saneopts.h")] - public static string VALUE_SCAN_MODE_COLOR; - [CCode (cname = "SANE_VALUE_SCAN_MODE_COLOR_LINEART", cheader_filename = "sane/saneopts.h")] - public static string VALUE_SCAN_MODE_COLOR_LINEART; - [CCode (cname = "SANE_VALUE_SCAN_MODE_COLOR_HALFTONE", cheader_filename = "sane/saneopts.h")] - public static string VALUE_SCAN_MODE_COLOR_HALFTONE; - [CCode (cname = "SANE_VALUE_SCAN_MODE_GRAY", cheader_filename = "sane/saneopts.h")] - public static string VALUE_SCAN_MODE_GRAY; - [CCode (cname = "SANE_VALUE_SCAN_MODE_HALFTONE", cheader_filename = "sane/saneopts.h")] - public static string VALUE_SCAN_MODE_HALFTONE; - [CCode (cname = "SANE_VALUE_SCAN_MODE_LINEART", cheader_filename = "sane/saneopts.h")] - public static string VALUE_SCAN_MODE_LINEART; -} diff --git a/src/scanner.c b/src/scanner.c deleted file mode 100644 index 3500c4b..0000000 --- a/src/scanner.c +++ /dev/null @@ -1,13397 +0,0 @@ -/* scanner.c generated by valac 0.34.6, the Vala compiler - * generated from scanner.vala, do not modify */ - -/* - * Copyright (C) 2009-2015 Canonical Ltd. - * Author: Robert Ancell - * - * This program is free software: you can redistribute it and/or modify it under - * the terms of the GNU General Public License as published by the Free Software - * Foundation, either version 3 of the License, or (at your option) any later - * version. See http://www.gnu.org/copyleft/gpl.html the full text of the - * license. - */ -/* TODO: Could indicate the start of the next page immediately after the last page is received (i.e. before the sane_cancel()) */ - -#include -#include -#include -#include -#include -#include -#include "sane/sane.h" -#include -#include "sane/saneopts.h" -#include - - -#define TYPE_SCAN_DEVICE (scan_device_get_type ()) -#define SCAN_DEVICE(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), TYPE_SCAN_DEVICE, ScanDevice)) -#define SCAN_DEVICE_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST ((klass), TYPE_SCAN_DEVICE, ScanDeviceClass)) -#define IS_SCAN_DEVICE(obj) (G_TYPE_CHECK_INSTANCE_TYPE ((obj), TYPE_SCAN_DEVICE)) -#define IS_SCAN_DEVICE_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE ((klass), TYPE_SCAN_DEVICE)) -#define SCAN_DEVICE_GET_CLASS(obj) (G_TYPE_INSTANCE_GET_CLASS ((obj), TYPE_SCAN_DEVICE, ScanDeviceClass)) - -typedef struct _ScanDevice ScanDevice; -typedef struct _ScanDeviceClass ScanDeviceClass; -typedef struct _ScanDevicePrivate ScanDevicePrivate; -#define _g_free0(var) (var = (g_free (var), NULL)) -typedef struct _ParamSpecScanDevice ParamSpecScanDevice; - -#define TYPE_SCAN_PAGE_INFO (scan_page_info_get_type ()) -#define SCAN_PAGE_INFO(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), TYPE_SCAN_PAGE_INFO, ScanPageInfo)) -#define SCAN_PAGE_INFO_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST ((klass), TYPE_SCAN_PAGE_INFO, ScanPageInfoClass)) -#define IS_SCAN_PAGE_INFO(obj) (G_TYPE_CHECK_INSTANCE_TYPE ((obj), TYPE_SCAN_PAGE_INFO)) -#define IS_SCAN_PAGE_INFO_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE ((klass), TYPE_SCAN_PAGE_INFO)) -#define SCAN_PAGE_INFO_GET_CLASS(obj) (G_TYPE_INSTANCE_GET_CLASS ((obj), TYPE_SCAN_PAGE_INFO, ScanPageInfoClass)) - -typedef struct _ScanPageInfo ScanPageInfo; -typedef struct _ScanPageInfoClass ScanPageInfoClass; -typedef struct _ScanPageInfoPrivate ScanPageInfoPrivate; -typedef struct _ParamSpecScanPageInfo ParamSpecScanPageInfo; - -#define TYPE_SCAN_LINE (scan_line_get_type ()) -#define SCAN_LINE(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), TYPE_SCAN_LINE, ScanLine)) -#define SCAN_LINE_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST ((klass), TYPE_SCAN_LINE, ScanLineClass)) -#define IS_SCAN_LINE(obj) (G_TYPE_CHECK_INSTANCE_TYPE ((obj), TYPE_SCAN_LINE)) -#define IS_SCAN_LINE_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE ((klass), TYPE_SCAN_LINE)) -#define SCAN_LINE_GET_CLASS(obj) (G_TYPE_INSTANCE_GET_CLASS ((obj), TYPE_SCAN_LINE, ScanLineClass)) - -typedef struct _ScanLine ScanLine; -typedef struct _ScanLineClass ScanLineClass; -typedef struct _ScanLinePrivate ScanLinePrivate; -typedef struct _ParamSpecScanLine ParamSpecScanLine; - -#define TYPE_SCAN_MODE (scan_mode_get_type ()) - -#define TYPE_SCAN_TYPE (scan_type_get_type ()) - -#define TYPE_SCAN_OPTIONS (scan_options_get_type ()) -#define SCAN_OPTIONS(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), TYPE_SCAN_OPTIONS, ScanOptions)) -#define SCAN_OPTIONS_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST ((klass), TYPE_SCAN_OPTIONS, ScanOptionsClass)) -#define IS_SCAN_OPTIONS(obj) (G_TYPE_CHECK_INSTANCE_TYPE ((obj), TYPE_SCAN_OPTIONS)) -#define IS_SCAN_OPTIONS_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE ((klass), TYPE_SCAN_OPTIONS)) -#define SCAN_OPTIONS_GET_CLASS(obj) (G_TYPE_INSTANCE_GET_CLASS ((obj), TYPE_SCAN_OPTIONS, ScanOptionsClass)) - -typedef struct _ScanOptions ScanOptions; -typedef struct _ScanOptionsClass ScanOptionsClass; -typedef struct _ScanOptionsPrivate ScanOptionsPrivate; -typedef struct _ParamSpecScanOptions ParamSpecScanOptions; - -#define TYPE_SCAN_JOB (scan_job_get_type ()) -#define SCAN_JOB(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), TYPE_SCAN_JOB, ScanJob)) -#define SCAN_JOB_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST ((klass), TYPE_SCAN_JOB, ScanJobClass)) -#define IS_SCAN_JOB(obj) (G_TYPE_CHECK_INSTANCE_TYPE ((obj), TYPE_SCAN_JOB)) -#define IS_SCAN_JOB_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE ((klass), TYPE_SCAN_JOB)) -#define SCAN_JOB_GET_CLASS(obj) (G_TYPE_INSTANCE_GET_CLASS ((obj), TYPE_SCAN_JOB, ScanJobClass)) - -typedef struct _ScanJob ScanJob; -typedef struct _ScanJobClass ScanJobClass; -typedef struct _ScanJobPrivate ScanJobPrivate; -typedef struct _ParamSpecScanJob ParamSpecScanJob; - -#define TYPE_REQUEST (request_get_type ()) -#define REQUEST(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), TYPE_REQUEST, Request)) -#define REQUEST_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST ((klass), TYPE_REQUEST, RequestClass)) -#define IS_REQUEST(obj) (G_TYPE_CHECK_INSTANCE_TYPE ((obj), TYPE_REQUEST)) -#define IS_REQUEST_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE ((klass), TYPE_REQUEST)) -#define REQUEST_GET_CLASS(obj) (G_TYPE_INSTANCE_GET_CLASS ((obj), TYPE_REQUEST, RequestClass)) - -typedef struct _Request Request; -typedef struct _RequestClass RequestClass; -typedef struct _RequestPrivate RequestPrivate; -typedef struct _ParamSpecRequest ParamSpecRequest; - -#define TYPE_REQUEST_REDETECT (request_redetect_get_type ()) -#define REQUEST_REDETECT(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), TYPE_REQUEST_REDETECT, RequestRedetect)) -#define REQUEST_REDETECT_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST ((klass), TYPE_REQUEST_REDETECT, RequestRedetectClass)) -#define IS_REQUEST_REDETECT(obj) (G_TYPE_CHECK_INSTANCE_TYPE ((obj), TYPE_REQUEST_REDETECT)) -#define IS_REQUEST_REDETECT_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE ((klass), TYPE_REQUEST_REDETECT)) -#define REQUEST_REDETECT_GET_CLASS(obj) (G_TYPE_INSTANCE_GET_CLASS ((obj), TYPE_REQUEST_REDETECT, RequestRedetectClass)) - -typedef struct _RequestRedetect RequestRedetect; -typedef struct _RequestRedetectClass RequestRedetectClass; -typedef struct _RequestRedetectPrivate RequestRedetectPrivate; - -#define TYPE_REQUEST_CANCEL (request_cancel_get_type ()) -#define REQUEST_CANCEL(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), TYPE_REQUEST_CANCEL, RequestCancel)) -#define REQUEST_CANCEL_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST ((klass), TYPE_REQUEST_CANCEL, RequestCancelClass)) -#define IS_REQUEST_CANCEL(obj) (G_TYPE_CHECK_INSTANCE_TYPE ((obj), TYPE_REQUEST_CANCEL)) -#define IS_REQUEST_CANCEL_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE ((klass), TYPE_REQUEST_CANCEL)) -#define REQUEST_CANCEL_GET_CLASS(obj) (G_TYPE_INSTANCE_GET_CLASS ((obj), TYPE_REQUEST_CANCEL, RequestCancelClass)) - -typedef struct _RequestCancel RequestCancel; -typedef struct _RequestCancelClass RequestCancelClass; -typedef struct _RequestCancelPrivate RequestCancelPrivate; - -#define TYPE_REQUEST_START_SCAN (request_start_scan_get_type ()) -#define REQUEST_START_SCAN(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), TYPE_REQUEST_START_SCAN, RequestStartScan)) -#define REQUEST_START_SCAN_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST ((klass), TYPE_REQUEST_START_SCAN, RequestStartScanClass)) -#define IS_REQUEST_START_SCAN(obj) (G_TYPE_CHECK_INSTANCE_TYPE ((obj), TYPE_REQUEST_START_SCAN)) -#define IS_REQUEST_START_SCAN_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE ((klass), TYPE_REQUEST_START_SCAN)) -#define REQUEST_START_SCAN_GET_CLASS(obj) (G_TYPE_INSTANCE_GET_CLASS ((obj), TYPE_REQUEST_START_SCAN, RequestStartScanClass)) - -typedef struct _RequestStartScan RequestStartScan; -typedef struct _RequestStartScanClass RequestStartScanClass; -typedef struct _RequestStartScanPrivate RequestStartScanPrivate; -#define _scan_job_unref0(var) ((var == NULL) ? NULL : (var = (scan_job_unref (var), NULL))) - -#define TYPE_REQUEST_QUIT (request_quit_get_type ()) -#define REQUEST_QUIT(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), TYPE_REQUEST_QUIT, RequestQuit)) -#define REQUEST_QUIT_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST ((klass), TYPE_REQUEST_QUIT, RequestQuitClass)) -#define IS_REQUEST_QUIT(obj) (G_TYPE_CHECK_INSTANCE_TYPE ((obj), TYPE_REQUEST_QUIT)) -#define IS_REQUEST_QUIT_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE ((klass), TYPE_REQUEST_QUIT)) -#define REQUEST_QUIT_GET_CLASS(obj) (G_TYPE_INSTANCE_GET_CLASS ((obj), TYPE_REQUEST_QUIT, RequestQuitClass)) - -typedef struct _RequestQuit RequestQuit; -typedef struct _RequestQuitClass RequestQuitClass; -typedef struct _RequestQuitPrivate RequestQuitPrivate; - -#define TYPE_CREDENTIALS (credentials_get_type ()) -#define CREDENTIALS(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), TYPE_CREDENTIALS, Credentials)) -#define CREDENTIALS_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST ((klass), TYPE_CREDENTIALS, CredentialsClass)) -#define IS_CREDENTIALS(obj) (G_TYPE_CHECK_INSTANCE_TYPE ((obj), TYPE_CREDENTIALS)) -#define IS_CREDENTIALS_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE ((klass), TYPE_CREDENTIALS)) -#define CREDENTIALS_GET_CLASS(obj) (G_TYPE_INSTANCE_GET_CLASS ((obj), TYPE_CREDENTIALS, CredentialsClass)) - -typedef struct _Credentials Credentials; -typedef struct _CredentialsClass CredentialsClass; -typedef struct _CredentialsPrivate CredentialsPrivate; -typedef struct _ParamSpecCredentials ParamSpecCredentials; - -#define TYPE_SCAN_STATE (scan_state_get_type ()) - -#define TYPE_NOTIFY (notify_get_type ()) -#define NOTIFY(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), TYPE_NOTIFY, Notify)) -#define NOTIFY_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST ((klass), TYPE_NOTIFY, NotifyClass)) -#define IS_NOTIFY(obj) (G_TYPE_CHECK_INSTANCE_TYPE ((obj), TYPE_NOTIFY)) -#define IS_NOTIFY_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE ((klass), TYPE_NOTIFY)) -#define NOTIFY_GET_CLASS(obj) (G_TYPE_INSTANCE_GET_CLASS ((obj), TYPE_NOTIFY, NotifyClass)) - -typedef struct _Notify Notify; -typedef struct _NotifyClass NotifyClass; -typedef struct _NotifyPrivate NotifyPrivate; - -#define TYPE_SCANNER (scanner_get_type ()) -#define SCANNER(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), TYPE_SCANNER, Scanner)) -#define SCANNER_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST ((klass), TYPE_SCANNER, ScannerClass)) -#define IS_SCANNER(obj) (G_TYPE_CHECK_INSTANCE_TYPE ((obj), TYPE_SCANNER)) -#define IS_SCANNER_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE ((klass), TYPE_SCANNER)) -#define SCANNER_GET_CLASS(obj) (G_TYPE_INSTANCE_GET_CLASS ((obj), TYPE_SCANNER, ScannerClass)) - -typedef struct _Scanner Scanner; -typedef struct _ScannerClass ScannerClass; -typedef struct _ParamSpecNotify ParamSpecNotify; - -#define TYPE_NOTIFY_SCANNING_CHANGED (notify_scanning_changed_get_type ()) -#define NOTIFY_SCANNING_CHANGED(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), TYPE_NOTIFY_SCANNING_CHANGED, NotifyScanningChanged)) -#define NOTIFY_SCANNING_CHANGED_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST ((klass), TYPE_NOTIFY_SCANNING_CHANGED, NotifyScanningChangedClass)) -#define IS_NOTIFY_SCANNING_CHANGED(obj) (G_TYPE_CHECK_INSTANCE_TYPE ((obj), TYPE_NOTIFY_SCANNING_CHANGED)) -#define IS_NOTIFY_SCANNING_CHANGED_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE ((klass), TYPE_NOTIFY_SCANNING_CHANGED)) -#define NOTIFY_SCANNING_CHANGED_GET_CLASS(obj) (G_TYPE_INSTANCE_GET_CLASS ((obj), TYPE_NOTIFY_SCANNING_CHANGED, NotifyScanningChangedClass)) - -typedef struct _NotifyScanningChanged NotifyScanningChanged; -typedef struct _NotifyScanningChangedClass NotifyScanningChangedClass; -typedef struct _NotifyScanningChangedPrivate NotifyScanningChangedPrivate; - -#define TYPE_NOTIFY_UPDATE_DEVICES (notify_update_devices_get_type ()) -#define NOTIFY_UPDATE_DEVICES(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), TYPE_NOTIFY_UPDATE_DEVICES, NotifyUpdateDevices)) -#define NOTIFY_UPDATE_DEVICES_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST ((klass), TYPE_NOTIFY_UPDATE_DEVICES, NotifyUpdateDevicesClass)) -#define IS_NOTIFY_UPDATE_DEVICES(obj) (G_TYPE_CHECK_INSTANCE_TYPE ((obj), TYPE_NOTIFY_UPDATE_DEVICES)) -#define IS_NOTIFY_UPDATE_DEVICES_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE ((klass), TYPE_NOTIFY_UPDATE_DEVICES)) -#define NOTIFY_UPDATE_DEVICES_GET_CLASS(obj) (G_TYPE_INSTANCE_GET_CLASS ((obj), TYPE_NOTIFY_UPDATE_DEVICES, NotifyUpdateDevicesClass)) - -typedef struct _NotifyUpdateDevices NotifyUpdateDevices; -typedef struct _NotifyUpdateDevicesClass NotifyUpdateDevicesClass; -typedef struct _NotifyUpdateDevicesPrivate NotifyUpdateDevicesPrivate; -#define __g_list_free__scan_device_unref0_0(var) ((var == NULL) ? NULL : (var = (_g_list_free__scan_device_unref0_ (var), NULL))) - -#define TYPE_NOTIFY_REQUEST_AUTHORIZATION (notify_request_authorization_get_type ()) -#define NOTIFY_REQUEST_AUTHORIZATION(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), TYPE_NOTIFY_REQUEST_AUTHORIZATION, NotifyRequestAuthorization)) -#define NOTIFY_REQUEST_AUTHORIZATION_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST ((klass), TYPE_NOTIFY_REQUEST_AUTHORIZATION, NotifyRequestAuthorizationClass)) -#define IS_NOTIFY_REQUEST_AUTHORIZATION(obj) (G_TYPE_CHECK_INSTANCE_TYPE ((obj), TYPE_NOTIFY_REQUEST_AUTHORIZATION)) -#define IS_NOTIFY_REQUEST_AUTHORIZATION_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE ((klass), TYPE_NOTIFY_REQUEST_AUTHORIZATION)) -#define NOTIFY_REQUEST_AUTHORIZATION_GET_CLASS(obj) (G_TYPE_INSTANCE_GET_CLASS ((obj), TYPE_NOTIFY_REQUEST_AUTHORIZATION, NotifyRequestAuthorizationClass)) - -typedef struct _NotifyRequestAuthorization NotifyRequestAuthorization; -typedef struct _NotifyRequestAuthorizationClass NotifyRequestAuthorizationClass; -typedef struct _NotifyRequestAuthorizationPrivate NotifyRequestAuthorizationPrivate; - -#define TYPE_NOTIFY_SCAN_FAILED (notify_scan_failed_get_type ()) -#define NOTIFY_SCAN_FAILED(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), TYPE_NOTIFY_SCAN_FAILED, NotifyScanFailed)) -#define NOTIFY_SCAN_FAILED_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST ((klass), TYPE_NOTIFY_SCAN_FAILED, NotifyScanFailedClass)) -#define IS_NOTIFY_SCAN_FAILED(obj) (G_TYPE_CHECK_INSTANCE_TYPE ((obj), TYPE_NOTIFY_SCAN_FAILED)) -#define IS_NOTIFY_SCAN_FAILED_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE ((klass), TYPE_NOTIFY_SCAN_FAILED)) -#define NOTIFY_SCAN_FAILED_GET_CLASS(obj) (G_TYPE_INSTANCE_GET_CLASS ((obj), TYPE_NOTIFY_SCAN_FAILED, NotifyScanFailedClass)) - -typedef struct _NotifyScanFailed NotifyScanFailed; -typedef struct _NotifyScanFailedClass NotifyScanFailedClass; -typedef struct _NotifyScanFailedPrivate NotifyScanFailedPrivate; - -#define TYPE_NOTIFY_DOCUMENT_DONE (notify_document_done_get_type ()) -#define NOTIFY_DOCUMENT_DONE(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), TYPE_NOTIFY_DOCUMENT_DONE, NotifyDocumentDone)) -#define NOTIFY_DOCUMENT_DONE_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST ((klass), TYPE_NOTIFY_DOCUMENT_DONE, NotifyDocumentDoneClass)) -#define IS_NOTIFY_DOCUMENT_DONE(obj) (G_TYPE_CHECK_INSTANCE_TYPE ((obj), TYPE_NOTIFY_DOCUMENT_DONE)) -#define IS_NOTIFY_DOCUMENT_DONE_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE ((klass), TYPE_NOTIFY_DOCUMENT_DONE)) -#define NOTIFY_DOCUMENT_DONE_GET_CLASS(obj) (G_TYPE_INSTANCE_GET_CLASS ((obj), TYPE_NOTIFY_DOCUMENT_DONE, NotifyDocumentDoneClass)) - -typedef struct _NotifyDocumentDone NotifyDocumentDone; -typedef struct _NotifyDocumentDoneClass NotifyDocumentDoneClass; -typedef struct _NotifyDocumentDonePrivate NotifyDocumentDonePrivate; - -#define TYPE_NOTIFY_EXPECT_PAGE (notify_expect_page_get_type ()) -#define NOTIFY_EXPECT_PAGE(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), TYPE_NOTIFY_EXPECT_PAGE, NotifyExpectPage)) -#define NOTIFY_EXPECT_PAGE_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST ((klass), TYPE_NOTIFY_EXPECT_PAGE, NotifyExpectPageClass)) -#define IS_NOTIFY_EXPECT_PAGE(obj) (G_TYPE_CHECK_INSTANCE_TYPE ((obj), TYPE_NOTIFY_EXPECT_PAGE)) -#define IS_NOTIFY_EXPECT_PAGE_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE ((klass), TYPE_NOTIFY_EXPECT_PAGE)) -#define NOTIFY_EXPECT_PAGE_GET_CLASS(obj) (G_TYPE_INSTANCE_GET_CLASS ((obj), TYPE_NOTIFY_EXPECT_PAGE, NotifyExpectPageClass)) - -typedef struct _NotifyExpectPage NotifyExpectPage; -typedef struct _NotifyExpectPageClass NotifyExpectPageClass; -typedef struct _NotifyExpectPagePrivate NotifyExpectPagePrivate; - -#define TYPE_NOTIFY_GOT_PAGE_INFO (notify_got_page_info_get_type ()) -#define NOTIFY_GOT_PAGE_INFO(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), TYPE_NOTIFY_GOT_PAGE_INFO, NotifyGotPageInfo)) -#define NOTIFY_GOT_PAGE_INFO_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST ((klass), TYPE_NOTIFY_GOT_PAGE_INFO, NotifyGotPageInfoClass)) -#define IS_NOTIFY_GOT_PAGE_INFO(obj) (G_TYPE_CHECK_INSTANCE_TYPE ((obj), TYPE_NOTIFY_GOT_PAGE_INFO)) -#define IS_NOTIFY_GOT_PAGE_INFO_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE ((klass), TYPE_NOTIFY_GOT_PAGE_INFO)) -#define NOTIFY_GOT_PAGE_INFO_GET_CLASS(obj) (G_TYPE_INSTANCE_GET_CLASS ((obj), TYPE_NOTIFY_GOT_PAGE_INFO, NotifyGotPageInfoClass)) - -typedef struct _NotifyGotPageInfo NotifyGotPageInfo; -typedef struct _NotifyGotPageInfoClass NotifyGotPageInfoClass; -typedef struct _NotifyGotPageInfoPrivate NotifyGotPageInfoPrivate; -#define _scan_page_info_unref0(var) ((var == NULL) ? NULL : (var = (scan_page_info_unref (var), NULL))) -typedef struct _ScannerPrivate ScannerPrivate; - -#define TYPE_NOTIFY_PAGE_DONE (notify_page_done_get_type ()) -#define NOTIFY_PAGE_DONE(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), TYPE_NOTIFY_PAGE_DONE, NotifyPageDone)) -#define NOTIFY_PAGE_DONE_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST ((klass), TYPE_NOTIFY_PAGE_DONE, NotifyPageDoneClass)) -#define IS_NOTIFY_PAGE_DONE(obj) (G_TYPE_CHECK_INSTANCE_TYPE ((obj), TYPE_NOTIFY_PAGE_DONE)) -#define IS_NOTIFY_PAGE_DONE_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE ((klass), TYPE_NOTIFY_PAGE_DONE)) -#define NOTIFY_PAGE_DONE_GET_CLASS(obj) (G_TYPE_INSTANCE_GET_CLASS ((obj), TYPE_NOTIFY_PAGE_DONE, NotifyPageDoneClass)) - -typedef struct _NotifyPageDone NotifyPageDone; -typedef struct _NotifyPageDoneClass NotifyPageDoneClass; -typedef struct _NotifyPageDonePrivate NotifyPageDonePrivate; - -#define TYPE_NOTIFY_GOT_LINE (notify_got_line_get_type ()) -#define NOTIFY_GOT_LINE(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), TYPE_NOTIFY_GOT_LINE, NotifyGotLine)) -#define NOTIFY_GOT_LINE_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST ((klass), TYPE_NOTIFY_GOT_LINE, NotifyGotLineClass)) -#define IS_NOTIFY_GOT_LINE(obj) (G_TYPE_CHECK_INSTANCE_TYPE ((obj), TYPE_NOTIFY_GOT_LINE)) -#define IS_NOTIFY_GOT_LINE_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE ((klass), TYPE_NOTIFY_GOT_LINE)) -#define NOTIFY_GOT_LINE_GET_CLASS(obj) (G_TYPE_INSTANCE_GET_CLASS ((obj), TYPE_NOTIFY_GOT_LINE, NotifyGotLineClass)) - -typedef struct _NotifyGotLine NotifyGotLine; -typedef struct _NotifyGotLineClass NotifyGotLineClass; -typedef struct _NotifyGotLinePrivate NotifyGotLinePrivate; -#define _scan_line_unref0(var) ((var == NULL) ? NULL : (var = (scan_line_unref (var), NULL))) -#define _g_thread_unref0(var) ((var == NULL) ? NULL : (var = (g_thread_unref (var), NULL))) -#define _g_async_queue_unref0(var) ((var == NULL) ? NULL : (var = (g_async_queue_unref (var), NULL))) -#define __g_list_free__scan_job_unref0_0(var) ((var == NULL) ? NULL : (var = (_g_list_free__scan_job_unref0_ (var), NULL))) -#define _g_hash_table_unref0(var) ((var == NULL) ? NULL : (var = (g_hash_table_unref (var), NULL))) -#define _scanner_unref0(var) ((var == NULL) ? NULL : (var = (scanner_unref (var), NULL))) -#define _notify_unref0(var) ((var == NULL) ? NULL : (var = (notify_unref (var), NULL))) -#define _g_regex_unref0(var) ((var == NULL) ? NULL : (var = (g_regex_unref (var), NULL))) -#define _g_error_free0(var) ((var == NULL) ? NULL : (var = (g_error_free (var), NULL))) -#define _scan_device_unref0(var) ((var == NULL) ? NULL : (var = (scan_device_unref (var), NULL))) -#define _credentials_unref0(var) ((var == NULL) ? NULL : (var = (credentials_unref (var), NULL))) -#define _request_unref0(var) ((var == NULL) ? NULL : (var = (request_unref (var), NULL))) -typedef struct _ParamSpecScanner ParamSpecScanner; - -struct _ScanDevice { - GTypeInstance parent_instance; - volatile int ref_count; - ScanDevicePrivate * priv; - gchar* name; - gchar* label; -}; - -struct _ScanDeviceClass { - GTypeClass parent_class; - void (*finalize) (ScanDevice *self); -}; - -struct _ParamSpecScanDevice { - GParamSpec parent_instance; -}; - -struct _ScanPageInfo { - GTypeInstance parent_instance; - volatile int ref_count; - ScanPageInfoPrivate * priv; - gint width; - gint height; - gint depth; - gint n_channels; - gdouble dpi; - gchar* device; -}; - -struct _ScanPageInfoClass { - GTypeClass parent_class; - void (*finalize) (ScanPageInfo *self); -}; - -struct _ParamSpecScanPageInfo { - GParamSpec parent_instance; -}; - -struct _ScanLine { - GTypeInstance parent_instance; - volatile int ref_count; - ScanLinePrivate * priv; - gint number; - gint n_lines; - gint width; - gint depth; - gint channel; - guchar* data; - gint data_length1; - gint data_length; -}; - -struct _ScanLineClass { - GTypeClass parent_class; - void (*finalize) (ScanLine *self); -}; - -struct _ParamSpecScanLine { - GParamSpec parent_instance; -}; - -typedef enum { - SCAN_MODE_DEFAULT, - SCAN_MODE_COLOR, - SCAN_MODE_GRAY, - SCAN_MODE_LINEART -} ScanMode; - -typedef enum { - SCAN_TYPE_SINGLE, - SCAN_TYPE_ADF_FRONT, - SCAN_TYPE_ADF_BACK, - SCAN_TYPE_ADF_BOTH -} ScanType; - -struct _ScanOptions { - GTypeInstance parent_instance; - volatile int ref_count; - ScanOptionsPrivate * priv; - gint dpi; - ScanMode scan_mode; - gint depth; - ScanType type; - gint paper_width; - gint paper_height; - gint brightness; - gint contrast; -}; - -struct _ScanOptionsClass { - GTypeClass parent_class; - void (*finalize) (ScanOptions *self); -}; - -struct _ParamSpecScanOptions { - GParamSpec parent_instance; -}; - -struct _ScanJob { - GTypeInstance parent_instance; - volatile int ref_count; - ScanJobPrivate * priv; - gint id; - gchar* device; - gdouble dpi; - ScanMode scan_mode; - gint depth; - ScanType type; - gint page_width; - gint page_height; - gint brightness; - gint contrast; -}; - -struct _ScanJobClass { - GTypeClass parent_class; - void (*finalize) (ScanJob *self); -}; - -struct _ParamSpecScanJob { - GParamSpec parent_instance; -}; - -struct _Request { - GTypeInstance parent_instance; - volatile int ref_count; - RequestPrivate * priv; -}; - -struct _RequestClass { - GTypeClass parent_class; - void (*finalize) (Request *self); -}; - -struct _ParamSpecRequest { - GParamSpec parent_instance; -}; - -struct _RequestRedetect { - Request parent_instance; - RequestRedetectPrivate * priv; -}; - -struct _RequestRedetectClass { - RequestClass parent_class; -}; - -struct _RequestCancel { - Request parent_instance; - RequestCancelPrivate * priv; -}; - -struct _RequestCancelClass { - RequestClass parent_class; -}; - -struct _RequestStartScan { - Request parent_instance; - RequestStartScanPrivate * priv; - ScanJob* job; -}; - -struct _RequestStartScanClass { - RequestClass parent_class; -}; - -struct _RequestQuit { - Request parent_instance; - RequestQuitPrivate * priv; -}; - -struct _RequestQuitClass { - RequestClass parent_class; -}; - -struct _Credentials { - GTypeInstance parent_instance; - volatile int ref_count; - CredentialsPrivate * priv; - gchar* username; - gchar* password; -}; - -struct _CredentialsClass { - GTypeClass parent_class; - void (*finalize) (Credentials *self); -}; - -struct _ParamSpecCredentials { - GParamSpec parent_instance; -}; - -typedef enum { - SCAN_STATE_IDLE = 0, - SCAN_STATE_REDETECT, - SCAN_STATE_OPEN, - SCAN_STATE_GET_OPTION, - SCAN_STATE_START, - SCAN_STATE_GET_PARAMETERS, - SCAN_STATE_READ -} ScanState; - -struct _Notify { - GTypeInstance parent_instance; - volatile int ref_count; - NotifyPrivate * priv; -}; - -struct _NotifyClass { - GTypeClass parent_class; - void (*finalize) (Notify *self); - void (*run) (Notify* self, Scanner* scanner); -}; - -struct _ParamSpecNotify { - GParamSpec parent_instance; -}; - -struct _NotifyScanningChanged { - Notify parent_instance; - NotifyScanningChangedPrivate * priv; -}; - -struct _NotifyScanningChangedClass { - NotifyClass parent_class; -}; - -struct _NotifyUpdateDevices { - Notify parent_instance; - NotifyUpdateDevicesPrivate * priv; -}; - -struct _NotifyUpdateDevicesClass { - NotifyClass parent_class; -}; - -struct _NotifyUpdateDevicesPrivate { - GList* devices; -}; - -struct _NotifyRequestAuthorization { - Notify parent_instance; - NotifyRequestAuthorizationPrivate * priv; -}; - -struct _NotifyRequestAuthorizationClass { - NotifyClass parent_class; -}; - -struct _NotifyRequestAuthorizationPrivate { - gchar* resource; -}; - -struct _NotifyScanFailed { - Notify parent_instance; - NotifyScanFailedPrivate * priv; -}; - -struct _NotifyScanFailedClass { - NotifyClass parent_class; -}; - -struct _NotifyScanFailedPrivate { - gint error_code; - gchar* error_string; -}; - -struct _NotifyDocumentDone { - Notify parent_instance; - NotifyDocumentDonePrivate * priv; -}; - -struct _NotifyDocumentDoneClass { - NotifyClass parent_class; -}; - -struct _NotifyExpectPage { - Notify parent_instance; - NotifyExpectPagePrivate * priv; -}; - -struct _NotifyExpectPageClass { - NotifyClass parent_class; -}; - -struct _NotifyGotPageInfo { - Notify parent_instance; - NotifyGotPageInfoPrivate * priv; -}; - -struct _NotifyGotPageInfoClass { - NotifyClass parent_class; -}; - -struct _NotifyGotPageInfoPrivate { - gint job_id; - ScanPageInfo* info; -}; - -struct _Scanner { - GTypeInstance parent_instance; - volatile int ref_count; - ScannerPrivate * priv; - gint first_job_id; - gint job_id; -}; - -struct _ScannerClass { - GTypeClass parent_class; - void (*finalize) (Scanner *self); -}; - -struct _NotifyPageDone { - Notify parent_instance; - NotifyPageDonePrivate * priv; -}; - -struct _NotifyPageDoneClass { - NotifyClass parent_class; -}; - -struct _NotifyPageDonePrivate { - gint job_id; -}; - -struct _NotifyGotLine { - Notify parent_instance; - NotifyGotLinePrivate * priv; -}; - -struct _NotifyGotLineClass { - NotifyClass parent_class; -}; - -struct _NotifyGotLinePrivate { - gint job_id; - ScanLine* line; -}; - -struct _ScannerPrivate { - GThread* thread; - GAsyncQueue* request_queue; - GAsyncQueue* notify_queue; - GAsyncQueue* authorize_queue; - gchar* default_device; - ScanState state; - gboolean need_redetect; - GList* job_queue; - SANE_Handle handle; - gboolean have_handle; - gchar* current_device; - SANE_Parameters parameters; - SANE_Int option_index; - GHashTable* options; - guchar* buffer; - gint buffer_length1; - gint _buffer_size_; - gint n_used; - gint line_count; - gint pass_number; - gint page_number; - gint notified_page; - gboolean scanning; -}; - -struct _ParamSpecScanner { - GParamSpec parent_instance; -}; - - -static gpointer scan_device_parent_class = NULL; -static gpointer scan_page_info_parent_class = NULL; -static gpointer scan_line_parent_class = NULL; -static gpointer scan_options_parent_class = NULL; -static gpointer scan_job_parent_class = NULL; -static gpointer request_parent_class = NULL; -static gpointer request_redetect_parent_class = NULL; -static gpointer request_cancel_parent_class = NULL; -static gpointer request_start_scan_parent_class = NULL; -static gpointer request_quit_parent_class = NULL; -static gpointer credentials_parent_class = NULL; -static gpointer notify_parent_class = NULL; -static gpointer notify_scanning_changed_parent_class = NULL; -static gpointer notify_update_devices_parent_class = NULL; -static gpointer notify_request_authorization_parent_class = NULL; -static gpointer notify_scan_failed_parent_class = NULL; -static gpointer notify_document_done_parent_class = NULL; -static gpointer notify_expect_page_parent_class = NULL; -static gpointer notify_got_page_info_parent_class = NULL; -static gpointer notify_page_done_parent_class = NULL; -static gpointer notify_got_line_parent_class = NULL; -static gpointer scanner_parent_class = NULL; -static Scanner* scanner_scanner_object; -static Scanner* scanner_scanner_object = NULL; - -gpointer scan_device_ref (gpointer instance); -void scan_device_unref (gpointer instance); -GParamSpec* param_spec_scan_device (const gchar* name, const gchar* nick, const gchar* blurb, GType object_type, GParamFlags flags); -void value_set_scan_device (GValue* value, gpointer v_object); -void value_take_scan_device (GValue* value, gpointer v_object); -gpointer value_get_scan_device (const GValue* value); -GType scan_device_get_type (void) G_GNUC_CONST; -enum { - SCAN_DEVICE_DUMMY_PROPERTY -}; -ScanDevice* scan_device_new (void); -ScanDevice* scan_device_construct (GType object_type); -static void scan_device_finalize (ScanDevice* obj); -gpointer scan_page_info_ref (gpointer instance); -void scan_page_info_unref (gpointer instance); -GParamSpec* param_spec_scan_page_info (const gchar* name, const gchar* nick, const gchar* blurb, GType object_type, GParamFlags flags); -void value_set_scan_page_info (GValue* value, gpointer v_object); -void value_take_scan_page_info (GValue* value, gpointer v_object); -gpointer value_get_scan_page_info (const GValue* value); -GType scan_page_info_get_type (void) G_GNUC_CONST; -enum { - SCAN_PAGE_INFO_DUMMY_PROPERTY -}; -ScanPageInfo* scan_page_info_new (void); -ScanPageInfo* scan_page_info_construct (GType object_type); -static void scan_page_info_finalize (ScanPageInfo* obj); -gpointer scan_line_ref (gpointer instance); -void scan_line_unref (gpointer instance); -GParamSpec* param_spec_scan_line (const gchar* name, const gchar* nick, const gchar* blurb, GType object_type, GParamFlags flags); -void value_set_scan_line (GValue* value, gpointer v_object); -void value_take_scan_line (GValue* value, gpointer v_object); -gpointer value_get_scan_line (const GValue* value); -GType scan_line_get_type (void) G_GNUC_CONST; -enum { - SCAN_LINE_DUMMY_PROPERTY -}; -ScanLine* scan_line_new (void); -ScanLine* scan_line_construct (GType object_type); -static void scan_line_finalize (ScanLine* obj); -GType scan_mode_get_type (void) G_GNUC_CONST; -GType scan_type_get_type (void) G_GNUC_CONST; -gpointer scan_options_ref (gpointer instance); -void scan_options_unref (gpointer instance); -GParamSpec* param_spec_scan_options (const gchar* name, const gchar* nick, const gchar* blurb, GType object_type, GParamFlags flags); -void value_set_scan_options (GValue* value, gpointer v_object); -void value_take_scan_options (GValue* value, gpointer v_object); -gpointer value_get_scan_options (const GValue* value); -GType scan_options_get_type (void) G_GNUC_CONST; -enum { - SCAN_OPTIONS_DUMMY_PROPERTY -}; -ScanOptions* scan_options_new (void); -ScanOptions* scan_options_construct (GType object_type); -static void scan_options_finalize (ScanOptions* obj); -gpointer scan_job_ref (gpointer instance); -void scan_job_unref (gpointer instance); -GParamSpec* param_spec_scan_job (const gchar* name, const gchar* nick, const gchar* blurb, GType object_type, GParamFlags flags); -void value_set_scan_job (GValue* value, gpointer v_object); -void value_take_scan_job (GValue* value, gpointer v_object); -gpointer value_get_scan_job (const GValue* value); -GType scan_job_get_type (void) G_GNUC_CONST; -enum { - SCAN_JOB_DUMMY_PROPERTY -}; -ScanJob* scan_job_new (void); -ScanJob* scan_job_construct (GType object_type); -static void scan_job_finalize (ScanJob* obj); -gpointer request_ref (gpointer instance); -void request_unref (gpointer instance); -GParamSpec* param_spec_request (const gchar* name, const gchar* nick, const gchar* blurb, GType object_type, GParamFlags flags); -void value_set_request (GValue* value, gpointer v_object); -void value_take_request (GValue* value, gpointer v_object); -gpointer value_get_request (const GValue* value); -GType request_get_type (void) G_GNUC_CONST; -enum { - REQUEST_DUMMY_PROPERTY -}; -Request* request_new (void); -Request* request_construct (GType object_type); -static void request_finalize (Request* obj); -GType request_redetect_get_type (void) G_GNUC_CONST; -enum { - REQUEST_REDETECT_DUMMY_PROPERTY -}; -RequestRedetect* request_redetect_new (void); -RequestRedetect* request_redetect_construct (GType object_type); -GType request_cancel_get_type (void) G_GNUC_CONST; -enum { - REQUEST_CANCEL_DUMMY_PROPERTY -}; -RequestCancel* request_cancel_new (void); -RequestCancel* request_cancel_construct (GType object_type); -GType request_start_scan_get_type (void) G_GNUC_CONST; -enum { - REQUEST_START_SCAN_DUMMY_PROPERTY -}; -RequestStartScan* request_start_scan_new (void); -RequestStartScan* request_start_scan_construct (GType object_type); -static void request_start_scan_finalize (Request* obj); -GType request_quit_get_type (void) G_GNUC_CONST; -enum { - REQUEST_QUIT_DUMMY_PROPERTY -}; -RequestQuit* request_quit_new (void); -RequestQuit* request_quit_construct (GType object_type); -gpointer credentials_ref (gpointer instance); -void credentials_unref (gpointer instance); -GParamSpec* param_spec_credentials (const gchar* name, const gchar* nick, const gchar* blurb, GType object_type, GParamFlags flags); -void value_set_credentials (GValue* value, gpointer v_object); -void value_take_credentials (GValue* value, gpointer v_object); -gpointer value_get_credentials (const GValue* value); -GType credentials_get_type (void) G_GNUC_CONST; -enum { - CREDENTIALS_DUMMY_PROPERTY -}; -Credentials* credentials_new (void); -Credentials* credentials_construct (GType object_type); -static void credentials_finalize (Credentials* obj); -GType scan_state_get_type (void) G_GNUC_CONST; -gpointer notify_ref (gpointer instance); -void notify_unref (gpointer instance); -GParamSpec* param_spec_notify (const gchar* name, const gchar* nick, const gchar* blurb, GType object_type, GParamFlags flags); -void value_set_notify (GValue* value, gpointer v_object); -void value_take_notify (GValue* value, gpointer v_object); -gpointer value_get_notify (const GValue* value); -GType notify_get_type (void) G_GNUC_CONST; -gpointer scanner_ref (gpointer instance); -void scanner_unref (gpointer instance); -GParamSpec* param_spec_scanner (const gchar* name, const gchar* nick, const gchar* blurb, GType object_type, GParamFlags flags); -void value_set_scanner (GValue* value, gpointer v_object); -void value_take_scanner (GValue* value, gpointer v_object); -gpointer value_get_scanner (const GValue* value); -GType scanner_get_type (void) G_GNUC_CONST; -enum { - NOTIFY_DUMMY_PROPERTY -}; -void notify_run (Notify* self, Scanner* scanner); -static void notify_real_run (Notify* self, Scanner* scanner); -Notify* notify_new (void); -Notify* notify_construct (GType object_type); -static void notify_finalize (Notify* obj); -GType notify_scanning_changed_get_type (void) G_GNUC_CONST; -enum { - NOTIFY_SCANNING_CHANGED_DUMMY_PROPERTY -}; -static void notify_scanning_changed_real_run (Notify* base, Scanner* scanner); -NotifyScanningChanged* notify_scanning_changed_new (void); -NotifyScanningChanged* notify_scanning_changed_construct (GType object_type); -GType notify_update_devices_get_type (void) G_GNUC_CONST; -#define NOTIFY_UPDATE_DEVICES_GET_PRIVATE(o) (G_TYPE_INSTANCE_GET_PRIVATE ((o), TYPE_NOTIFY_UPDATE_DEVICES, NotifyUpdateDevicesPrivate)) -enum { - NOTIFY_UPDATE_DEVICES_DUMMY_PROPERTY -}; -static void _scan_device_unref0_ (gpointer var); -static void _g_list_free__scan_device_unref0_ (GList* self); -NotifyUpdateDevices* notify_update_devices_new (GList* devices); -NotifyUpdateDevices* notify_update_devices_construct (GType object_type, GList* devices); -static void notify_update_devices_real_run (Notify* base, Scanner* scanner); -static void notify_update_devices_finalize (Notify* obj); -GType notify_request_authorization_get_type (void) G_GNUC_CONST; -#define NOTIFY_REQUEST_AUTHORIZATION_GET_PRIVATE(o) (G_TYPE_INSTANCE_GET_PRIVATE ((o), TYPE_NOTIFY_REQUEST_AUTHORIZATION, NotifyRequestAuthorizationPrivate)) -enum { - NOTIFY_REQUEST_AUTHORIZATION_DUMMY_PROPERTY -}; -NotifyRequestAuthorization* notify_request_authorization_new (const gchar* resource); -NotifyRequestAuthorization* notify_request_authorization_construct (GType object_type, const gchar* resource); -static void notify_request_authorization_real_run (Notify* base, Scanner* scanner); -static void notify_request_authorization_finalize (Notify* obj); -GType notify_scan_failed_get_type (void) G_GNUC_CONST; -#define NOTIFY_SCAN_FAILED_GET_PRIVATE(o) (G_TYPE_INSTANCE_GET_PRIVATE ((o), TYPE_NOTIFY_SCAN_FAILED, NotifyScanFailedPrivate)) -enum { - NOTIFY_SCAN_FAILED_DUMMY_PROPERTY -}; -NotifyScanFailed* notify_scan_failed_new (gint error_code, const gchar* error_string); -NotifyScanFailed* notify_scan_failed_construct (GType object_type, gint error_code, const gchar* error_string); -static void notify_scan_failed_real_run (Notify* base, Scanner* scanner); -static void notify_scan_failed_finalize (Notify* obj); -GType notify_document_done_get_type (void) G_GNUC_CONST; -enum { - NOTIFY_DOCUMENT_DONE_DUMMY_PROPERTY -}; -static void notify_document_done_real_run (Notify* base, Scanner* scanner); -NotifyDocumentDone* notify_document_done_new (void); -NotifyDocumentDone* notify_document_done_construct (GType object_type); -GType notify_expect_page_get_type (void) G_GNUC_CONST; -enum { - NOTIFY_EXPECT_PAGE_DUMMY_PROPERTY -}; -static void notify_expect_page_real_run (Notify* base, Scanner* scanner); -NotifyExpectPage* notify_expect_page_new (void); -NotifyExpectPage* notify_expect_page_construct (GType object_type); -GType notify_got_page_info_get_type (void) G_GNUC_CONST; -#define NOTIFY_GOT_PAGE_INFO_GET_PRIVATE(o) (G_TYPE_INSTANCE_GET_PRIVATE ((o), TYPE_NOTIFY_GOT_PAGE_INFO, NotifyGotPageInfoPrivate)) -enum { - NOTIFY_GOT_PAGE_INFO_DUMMY_PROPERTY -}; -NotifyGotPageInfo* notify_got_page_info_new (gint job_id, ScanPageInfo* info); -NotifyGotPageInfo* notify_got_page_info_construct (GType object_type, gint job_id, ScanPageInfo* info); -static void notify_got_page_info_real_run (Notify* base, Scanner* scanner); -static void notify_got_page_info_finalize (Notify* obj); -GType notify_page_done_get_type (void) G_GNUC_CONST; -#define NOTIFY_PAGE_DONE_GET_PRIVATE(o) (G_TYPE_INSTANCE_GET_PRIVATE ((o), TYPE_NOTIFY_PAGE_DONE, NotifyPageDonePrivate)) -enum { - NOTIFY_PAGE_DONE_DUMMY_PROPERTY -}; -NotifyPageDone* notify_page_done_new (gint job_id); -NotifyPageDone* notify_page_done_construct (GType object_type, gint job_id); -static void notify_page_done_real_run (Notify* base, Scanner* scanner); -static void notify_page_done_finalize (Notify* obj); -GType notify_got_line_get_type (void) G_GNUC_CONST; -#define NOTIFY_GOT_LINE_GET_PRIVATE(o) (G_TYPE_INSTANCE_GET_PRIVATE ((o), TYPE_NOTIFY_GOT_LINE, NotifyGotLinePrivate)) -enum { - NOTIFY_GOT_LINE_DUMMY_PROPERTY -}; -NotifyGotLine* notify_got_line_new (gint job_id, ScanLine* line); -NotifyGotLine* notify_got_line_construct (GType object_type, gint job_id, ScanLine* line); -static void notify_got_line_real_run (Notify* base, Scanner* scanner); -static void notify_got_line_finalize (Notify* obj); -#define SCANNER_GET_PRIVATE(o) (G_TYPE_INSTANCE_GET_PRIVATE ((o), TYPE_SCANNER, ScannerPrivate)) -enum { - SCANNER_DUMMY_PROPERTY -}; -static void _scan_job_unref0_ (gpointer var); -static void _g_list_free__scan_job_unref0_ (GList* self); -static Scanner* scanner_new (void); -static Scanner* scanner_construct (GType object_type); -static void _request_unref0_ (gpointer var); -static void _notify_unref0_ (gpointer var); -static void _credentials_unref0_ (gpointer var); -Scanner* scanner_get_instance (void); -static gboolean scanner_notify_idle_cb (Scanner* self); -static void scanner_notify (Scanner* self, Notify* notification); -static gboolean _scanner_notify_idle_cb_gsource_func (gpointer self); -static void scanner_set_scanning (Scanner* self, gboolean is_scanning); -static gint scanner_get_device_weight (const gchar* device); -static gint scanner_compare_devices (ScanDevice* device1, ScanDevice* device2); -static void scanner_do_redetect (Scanner* self); -static gint _scanner_compare_devices_gcompare_func (gconstpointer a, gconstpointer b); -static gint scanner_scale_int (Scanner* self, gint source_min, gint source_max, SANE_Option_Descriptor* option, gint value); -static gboolean scanner_set_default_option (Scanner* self, SANE_Handle handle, SANE_Option_Descriptor* option, SANE_Int option_index); -static void scanner_set_bool_option (Scanner* self, SANE_Handle handle, SANE_Option_Descriptor* option, SANE_Int option_index, gboolean value, gboolean* _result_); -static void scanner_set_int_option (Scanner* self, SANE_Handle handle, SANE_Option_Descriptor* option, SANE_Int option_index, gint value, gint* _result_); -static void scanner_set_fixed_option (Scanner* self, SANE_Handle handle, SANE_Option_Descriptor* option, SANE_Int option_index, gdouble value, gdouble* _result_); -static void scanner_set_fixed_or_int_option (Scanner* self, SANE_Handle handle, SANE_Option_Descriptor* option, SANE_Int option_index, gdouble value, gdouble* _result_); -static void scanner_set_option_to_max (Scanner* self, SANE_Handle handle, SANE_Option_Descriptor* option, SANE_Int option_index); -static gboolean scanner_set_string_option (Scanner* self, SANE_Handle handle, SANE_Option_Descriptor* option, SANE_Int option_index, const gchar* value, gchar** _result_); -static gboolean scanner_set_constrained_string_option (Scanner* self, SANE_Handle handle, SANE_Option_Descriptor* option, SANE_Int option_index, gchar** values, int values_length1, gchar** _result_); -static void scanner_log_option (Scanner* self, SANE_Int index, SANE_Option_Descriptor* option); -static void scanner_authorization_cb (const gchar* resource, gchar* username, int username_length1, gchar* password, int password_length1); -void scanner_authorize (Scanner* self, const gchar* username, const gchar* password); -static void scanner_close_device (Scanner* self); -static void scanner_fail_scan (Scanner* self, gint error_code, const gchar* error_string); -static gboolean scanner_handle_requests (Scanner* self); -static void scanner_do_open (Scanner* self); -static void _g_free0_ (gpointer var); -static void scanner_do_get_option (Scanner* self); -static SANE_Option_Descriptor* scanner_get_option_by_name (Scanner* self, SANE_Handle handle, const gchar* name, gint* index); -static gdouble scanner_convert_page_size (Scanner* self, SANE_Option_Descriptor* option, gdouble size, gdouble dpi); -static void scanner_do_complete_document (Scanner* self); -static void scanner_do_start (Scanner* self); -static void scanner_do_get_parameters (Scanner* self); -static void scanner_do_complete_page (Scanner* self); -static void scanner_do_read (Scanner* self); -static void* scanner_scan_thread (Scanner* self); -static void _scanner_authorization_cb_sane_authcallback (const gchar* resource, gchar* username, gchar* password); -void scanner_redetect (Scanner* self); -void scanner_start (Scanner* self); -static gpointer _scanner_scan_thread_gthread_func (gpointer self); -gboolean scanner_is_scanning (Scanner* self); -static gchar* scanner_get_scan_mode_string (Scanner* self, ScanMode mode); -static gchar* scanner_get_scan_type_string (Scanner* self, ScanType type); -void scanner_scan (Scanner* self, const gchar* device, ScanOptions* options); -void scanner_cancel (Scanner* self); -void scanner_free (Scanner* self); -static void g_cclosure_user_marshal_VOID__SCAN_PAGE_INFO (GClosure * closure, GValue * return_value, guint n_param_values, const GValue * param_values, gpointer invocation_hint, gpointer marshal_data); -static void g_cclosure_user_marshal_VOID__SCAN_LINE (GClosure * closure, GValue * return_value, guint n_param_values, const GValue * param_values, gpointer invocation_hint, gpointer marshal_data); -static void g_cclosure_user_marshal_VOID__INT_STRING (GClosure * closure, GValue * return_value, guint n_param_values, const GValue * param_values, gpointer invocation_hint, gpointer marshal_data); -static void scanner_finalize (Scanner* obj); -static void _vala_array_destroy (gpointer array, gint array_length, GDestroyNotify destroy_func); -static void _vala_array_free (gpointer array, gint array_length, GDestroyNotify destroy_func); -static gint _vala_array_length (gpointer array); - - -ScanDevice* scan_device_construct (GType object_type) { - ScanDevice* self = NULL; -#line 14 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - self = (ScanDevice*) g_type_create_instance (object_type); -#line 14 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - return self; -#line 986 "scanner.c" -} - - -ScanDevice* scan_device_new (void) { -#line 14 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - return scan_device_construct (TYPE_SCAN_DEVICE); -#line 993 "scanner.c" -} - - -static void value_scan_device_init (GValue* value) { -#line 14 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - value->data[0].v_pointer = NULL; -#line 1000 "scanner.c" -} - - -static void value_scan_device_free_value (GValue* value) { -#line 14 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - if (value->data[0].v_pointer) { -#line 14 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - scan_device_unref (value->data[0].v_pointer); -#line 1009 "scanner.c" - } -} - - -static void value_scan_device_copy_value (const GValue* src_value, GValue* dest_value) { -#line 14 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - if (src_value->data[0].v_pointer) { -#line 14 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - dest_value->data[0].v_pointer = scan_device_ref (src_value->data[0].v_pointer); -#line 1019 "scanner.c" - } else { -#line 14 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - dest_value->data[0].v_pointer = NULL; -#line 1023 "scanner.c" - } -} - - -static gpointer value_scan_device_peek_pointer (const GValue* value) { -#line 14 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - return value->data[0].v_pointer; -#line 1031 "scanner.c" -} - - -static gchar* value_scan_device_collect_value (GValue* value, guint n_collect_values, GTypeCValue* collect_values, guint collect_flags) { -#line 14 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - if (collect_values[0].v_pointer) { -#line 1038 "scanner.c" - ScanDevice* object; - object = collect_values[0].v_pointer; -#line 14 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - if (object->parent_instance.g_class == NULL) { -#line 14 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - return g_strconcat ("invalid unclassed object pointer for value type `", G_VALUE_TYPE_NAME (value), "'", NULL); -#line 1045 "scanner.c" - } else if (!g_value_type_compatible (G_TYPE_FROM_INSTANCE (object), G_VALUE_TYPE (value))) { -#line 14 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - return g_strconcat ("invalid object type `", g_type_name (G_TYPE_FROM_INSTANCE (object)), "' for value type `", G_VALUE_TYPE_NAME (value), "'", NULL); -#line 1049 "scanner.c" - } -#line 14 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - value->data[0].v_pointer = scan_device_ref (object); -#line 1053 "scanner.c" - } else { -#line 14 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - value->data[0].v_pointer = NULL; -#line 1057 "scanner.c" - } -#line 14 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - return NULL; -#line 1061 "scanner.c" -} - - -static gchar* value_scan_device_lcopy_value (const GValue* value, guint n_collect_values, GTypeCValue* collect_values, guint collect_flags) { - ScanDevice** object_p; - object_p = collect_values[0].v_pointer; -#line 14 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - if (!object_p) { -#line 14 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - return g_strdup_printf ("value location for `%s' passed as NULL", G_VALUE_TYPE_NAME (value)); -#line 1072 "scanner.c" - } -#line 14 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - if (!value->data[0].v_pointer) { -#line 14 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - *object_p = NULL; -#line 1078 "scanner.c" - } else if (collect_flags & G_VALUE_NOCOPY_CONTENTS) { -#line 14 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - *object_p = value->data[0].v_pointer; -#line 1082 "scanner.c" - } else { -#line 14 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - *object_p = scan_device_ref (value->data[0].v_pointer); -#line 1086 "scanner.c" - } -#line 14 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - return NULL; -#line 1090 "scanner.c" -} - - -GParamSpec* param_spec_scan_device (const gchar* name, const gchar* nick, const gchar* blurb, GType object_type, GParamFlags flags) { - ParamSpecScanDevice* spec; -#line 14 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - g_return_val_if_fail (g_type_is_a (object_type, TYPE_SCAN_DEVICE), NULL); -#line 14 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - spec = g_param_spec_internal (G_TYPE_PARAM_OBJECT, name, nick, blurb, flags); -#line 14 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - G_PARAM_SPEC (spec)->value_type = object_type; -#line 14 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - return G_PARAM_SPEC (spec); -#line 1104 "scanner.c" -} - - -gpointer value_get_scan_device (const GValue* value) { -#line 14 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - g_return_val_if_fail (G_TYPE_CHECK_VALUE_TYPE (value, TYPE_SCAN_DEVICE), NULL); -#line 14 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - return value->data[0].v_pointer; -#line 1113 "scanner.c" -} - - -void value_set_scan_device (GValue* value, gpointer v_object) { - ScanDevice* old; -#line 14 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - g_return_if_fail (G_TYPE_CHECK_VALUE_TYPE (value, TYPE_SCAN_DEVICE)); -#line 14 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - old = value->data[0].v_pointer; -#line 14 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - if (v_object) { -#line 14 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - g_return_if_fail (G_TYPE_CHECK_INSTANCE_TYPE (v_object, TYPE_SCAN_DEVICE)); -#line 14 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - g_return_if_fail (g_value_type_compatible (G_TYPE_FROM_INSTANCE (v_object), G_VALUE_TYPE (value))); -#line 14 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - value->data[0].v_pointer = v_object; -#line 14 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - scan_device_ref (value->data[0].v_pointer); -#line 1133 "scanner.c" - } else { -#line 14 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - value->data[0].v_pointer = NULL; -#line 1137 "scanner.c" - } -#line 14 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - if (old) { -#line 14 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - scan_device_unref (old); -#line 1143 "scanner.c" - } -} - - -void value_take_scan_device (GValue* value, gpointer v_object) { - ScanDevice* old; -#line 14 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - g_return_if_fail (G_TYPE_CHECK_VALUE_TYPE (value, TYPE_SCAN_DEVICE)); -#line 14 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - old = value->data[0].v_pointer; -#line 14 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - if (v_object) { -#line 14 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - g_return_if_fail (G_TYPE_CHECK_INSTANCE_TYPE (v_object, TYPE_SCAN_DEVICE)); -#line 14 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - g_return_if_fail (g_value_type_compatible (G_TYPE_FROM_INSTANCE (v_object), G_VALUE_TYPE (value))); -#line 14 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - value->data[0].v_pointer = v_object; -#line 1162 "scanner.c" - } else { -#line 14 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - value->data[0].v_pointer = NULL; -#line 1166 "scanner.c" - } -#line 14 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - if (old) { -#line 14 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - scan_device_unref (old); -#line 1172 "scanner.c" - } -} - - -static void scan_device_class_init (ScanDeviceClass * klass) { -#line 14 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - scan_device_parent_class = g_type_class_peek_parent (klass); -#line 14 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - ((ScanDeviceClass *) klass)->finalize = scan_device_finalize; -#line 1182 "scanner.c" -} - - -static void scan_device_instance_init (ScanDevice * self) { -#line 14 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - self->ref_count = 1; -#line 1189 "scanner.c" -} - - -static void scan_device_finalize (ScanDevice* obj) { - ScanDevice * self; -#line 14 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - self = G_TYPE_CHECK_INSTANCE_CAST (obj, TYPE_SCAN_DEVICE, ScanDevice); -#line 14 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - g_signal_handlers_destroy (self); -#line 16 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _g_free0 (self->name); -#line 17 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _g_free0 (self->label); -#line 1203 "scanner.c" -} - - -GType scan_device_get_type (void) { - static volatile gsize scan_device_type_id__volatile = 0; - if (g_once_init_enter (&scan_device_type_id__volatile)) { - static const GTypeValueTable g_define_type_value_table = { value_scan_device_init, value_scan_device_free_value, value_scan_device_copy_value, value_scan_device_peek_pointer, "p", value_scan_device_collect_value, "p", value_scan_device_lcopy_value }; - static const GTypeInfo g_define_type_info = { sizeof (ScanDeviceClass), (GBaseInitFunc) NULL, (GBaseFinalizeFunc) NULL, (GClassInitFunc) scan_device_class_init, (GClassFinalizeFunc) NULL, NULL, sizeof (ScanDevice), 0, (GInstanceInitFunc) scan_device_instance_init, &g_define_type_value_table }; - static const GTypeFundamentalInfo g_define_type_fundamental_info = { (G_TYPE_FLAG_CLASSED | G_TYPE_FLAG_INSTANTIATABLE | G_TYPE_FLAG_DERIVABLE | G_TYPE_FLAG_DEEP_DERIVABLE) }; - GType scan_device_type_id; - scan_device_type_id = g_type_register_fundamental (g_type_fundamental_next (), "ScanDevice", &g_define_type_info, &g_define_type_fundamental_info, 0); - g_once_init_leave (&scan_device_type_id__volatile, scan_device_type_id); - } - return scan_device_type_id__volatile; -} - - -gpointer scan_device_ref (gpointer instance) { - ScanDevice* self; - self = instance; -#line 14 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - g_atomic_int_inc (&self->ref_count); -#line 14 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - return instance; -#line 1228 "scanner.c" -} - - -void scan_device_unref (gpointer instance) { - ScanDevice* self; - self = instance; -#line 14 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - if (g_atomic_int_dec_and_test (&self->ref_count)) { -#line 14 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - SCAN_DEVICE_GET_CLASS (self)->finalize (self); -#line 14 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - g_type_free_instance ((GTypeInstance *) self); -#line 1241 "scanner.c" - } -} - - -ScanPageInfo* scan_page_info_construct (GType object_type) { - ScanPageInfo* self = NULL; -#line 20 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - self = (ScanPageInfo*) g_type_create_instance (object_type); -#line 20 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - return self; -#line 1252 "scanner.c" -} - - -ScanPageInfo* scan_page_info_new (void) { -#line 20 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - return scan_page_info_construct (TYPE_SCAN_PAGE_INFO); -#line 1259 "scanner.c" -} - - -static void value_scan_page_info_init (GValue* value) { -#line 20 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - value->data[0].v_pointer = NULL; -#line 1266 "scanner.c" -} - - -static void value_scan_page_info_free_value (GValue* value) { -#line 20 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - if (value->data[0].v_pointer) { -#line 20 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - scan_page_info_unref (value->data[0].v_pointer); -#line 1275 "scanner.c" - } -} - - -static void value_scan_page_info_copy_value (const GValue* src_value, GValue* dest_value) { -#line 20 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - if (src_value->data[0].v_pointer) { -#line 20 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - dest_value->data[0].v_pointer = scan_page_info_ref (src_value->data[0].v_pointer); -#line 1285 "scanner.c" - } else { -#line 20 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - dest_value->data[0].v_pointer = NULL; -#line 1289 "scanner.c" - } -} - - -static gpointer value_scan_page_info_peek_pointer (const GValue* value) { -#line 20 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - return value->data[0].v_pointer; -#line 1297 "scanner.c" -} - - -static gchar* value_scan_page_info_collect_value (GValue* value, guint n_collect_values, GTypeCValue* collect_values, guint collect_flags) { -#line 20 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - if (collect_values[0].v_pointer) { -#line 1304 "scanner.c" - ScanPageInfo* object; - object = collect_values[0].v_pointer; -#line 20 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - if (object->parent_instance.g_class == NULL) { -#line 20 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - return g_strconcat ("invalid unclassed object pointer for value type `", G_VALUE_TYPE_NAME (value), "'", NULL); -#line 1311 "scanner.c" - } else if (!g_value_type_compatible (G_TYPE_FROM_INSTANCE (object), G_VALUE_TYPE (value))) { -#line 20 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - return g_strconcat ("invalid object type `", g_type_name (G_TYPE_FROM_INSTANCE (object)), "' for value type `", G_VALUE_TYPE_NAME (value), "'", NULL); -#line 1315 "scanner.c" - } -#line 20 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - value->data[0].v_pointer = scan_page_info_ref (object); -#line 1319 "scanner.c" - } else { -#line 20 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - value->data[0].v_pointer = NULL; -#line 1323 "scanner.c" - } -#line 20 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - return NULL; -#line 1327 "scanner.c" -} - - -static gchar* value_scan_page_info_lcopy_value (const GValue* value, guint n_collect_values, GTypeCValue* collect_values, guint collect_flags) { - ScanPageInfo** object_p; - object_p = collect_values[0].v_pointer; -#line 20 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - if (!object_p) { -#line 20 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - return g_strdup_printf ("value location for `%s' passed as NULL", G_VALUE_TYPE_NAME (value)); -#line 1338 "scanner.c" - } -#line 20 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - if (!value->data[0].v_pointer) { -#line 20 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - *object_p = NULL; -#line 1344 "scanner.c" - } else if (collect_flags & G_VALUE_NOCOPY_CONTENTS) { -#line 20 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - *object_p = value->data[0].v_pointer; -#line 1348 "scanner.c" - } else { -#line 20 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - *object_p = scan_page_info_ref (value->data[0].v_pointer); -#line 1352 "scanner.c" - } -#line 20 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - return NULL; -#line 1356 "scanner.c" -} - - -GParamSpec* param_spec_scan_page_info (const gchar* name, const gchar* nick, const gchar* blurb, GType object_type, GParamFlags flags) { - ParamSpecScanPageInfo* spec; -#line 20 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - g_return_val_if_fail (g_type_is_a (object_type, TYPE_SCAN_PAGE_INFO), NULL); -#line 20 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - spec = g_param_spec_internal (G_TYPE_PARAM_OBJECT, name, nick, blurb, flags); -#line 20 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - G_PARAM_SPEC (spec)->value_type = object_type; -#line 20 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - return G_PARAM_SPEC (spec); -#line 1370 "scanner.c" -} - - -gpointer value_get_scan_page_info (const GValue* value) { -#line 20 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - g_return_val_if_fail (G_TYPE_CHECK_VALUE_TYPE (value, TYPE_SCAN_PAGE_INFO), NULL); -#line 20 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - return value->data[0].v_pointer; -#line 1379 "scanner.c" -} - - -void value_set_scan_page_info (GValue* value, gpointer v_object) { - ScanPageInfo* old; -#line 20 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - g_return_if_fail (G_TYPE_CHECK_VALUE_TYPE (value, TYPE_SCAN_PAGE_INFO)); -#line 20 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - old = value->data[0].v_pointer; -#line 20 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - if (v_object) { -#line 20 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - g_return_if_fail (G_TYPE_CHECK_INSTANCE_TYPE (v_object, TYPE_SCAN_PAGE_INFO)); -#line 20 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - g_return_if_fail (g_value_type_compatible (G_TYPE_FROM_INSTANCE (v_object), G_VALUE_TYPE (value))); -#line 20 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - value->data[0].v_pointer = v_object; -#line 20 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - scan_page_info_ref (value->data[0].v_pointer); -#line 1399 "scanner.c" - } else { -#line 20 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - value->data[0].v_pointer = NULL; -#line 1403 "scanner.c" - } -#line 20 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - if (old) { -#line 20 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - scan_page_info_unref (old); -#line 1409 "scanner.c" - } -} - - -void value_take_scan_page_info (GValue* value, gpointer v_object) { - ScanPageInfo* old; -#line 20 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - g_return_if_fail (G_TYPE_CHECK_VALUE_TYPE (value, TYPE_SCAN_PAGE_INFO)); -#line 20 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - old = value->data[0].v_pointer; -#line 20 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - if (v_object) { -#line 20 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - g_return_if_fail (G_TYPE_CHECK_INSTANCE_TYPE (v_object, TYPE_SCAN_PAGE_INFO)); -#line 20 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - g_return_if_fail (g_value_type_compatible (G_TYPE_FROM_INSTANCE (v_object), G_VALUE_TYPE (value))); -#line 20 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - value->data[0].v_pointer = v_object; -#line 1428 "scanner.c" - } else { -#line 20 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - value->data[0].v_pointer = NULL; -#line 1432 "scanner.c" - } -#line 20 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - if (old) { -#line 20 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - scan_page_info_unref (old); -#line 1438 "scanner.c" - } -} - - -static void scan_page_info_class_init (ScanPageInfoClass * klass) { -#line 20 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - scan_page_info_parent_class = g_type_class_peek_parent (klass); -#line 20 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - ((ScanPageInfoClass *) klass)->finalize = scan_page_info_finalize; -#line 1448 "scanner.c" -} - - -static void scan_page_info_instance_init (ScanPageInfo * self) { -#line 20 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - self->ref_count = 1; -#line 1455 "scanner.c" -} - - -static void scan_page_info_finalize (ScanPageInfo* obj) { - ScanPageInfo * self; -#line 20 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - self = G_TYPE_CHECK_INSTANCE_CAST (obj, TYPE_SCAN_PAGE_INFO, ScanPageInfo); -#line 20 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - g_signal_handlers_destroy (self); -#line 36 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _g_free0 (self->device); -#line 1467 "scanner.c" -} - - -GType scan_page_info_get_type (void) { - static volatile gsize scan_page_info_type_id__volatile = 0; - if (g_once_init_enter (&scan_page_info_type_id__volatile)) { - static const GTypeValueTable g_define_type_value_table = { value_scan_page_info_init, value_scan_page_info_free_value, value_scan_page_info_copy_value, value_scan_page_info_peek_pointer, "p", value_scan_page_info_collect_value, "p", value_scan_page_info_lcopy_value }; - static const GTypeInfo g_define_type_info = { sizeof (ScanPageInfoClass), (GBaseInitFunc) NULL, (GBaseFinalizeFunc) NULL, (GClassInitFunc) scan_page_info_class_init, (GClassFinalizeFunc) NULL, NULL, sizeof (ScanPageInfo), 0, (GInstanceInitFunc) scan_page_info_instance_init, &g_define_type_value_table }; - static const GTypeFundamentalInfo g_define_type_fundamental_info = { (G_TYPE_FLAG_CLASSED | G_TYPE_FLAG_INSTANTIATABLE | G_TYPE_FLAG_DERIVABLE | G_TYPE_FLAG_DEEP_DERIVABLE) }; - GType scan_page_info_type_id; - scan_page_info_type_id = g_type_register_fundamental (g_type_fundamental_next (), "ScanPageInfo", &g_define_type_info, &g_define_type_fundamental_info, 0); - g_once_init_leave (&scan_page_info_type_id__volatile, scan_page_info_type_id); - } - return scan_page_info_type_id__volatile; -} - - -gpointer scan_page_info_ref (gpointer instance) { - ScanPageInfo* self; - self = instance; -#line 20 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - g_atomic_int_inc (&self->ref_count); -#line 20 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - return instance; -#line 1492 "scanner.c" -} - - -void scan_page_info_unref (gpointer instance) { - ScanPageInfo* self; - self = instance; -#line 20 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - if (g_atomic_int_dec_and_test (&self->ref_count)) { -#line 20 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - SCAN_PAGE_INFO_GET_CLASS (self)->finalize (self); -#line 20 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - g_type_free_instance ((GTypeInstance *) self); -#line 1505 "scanner.c" - } -} - - -ScanLine* scan_line_construct (GType object_type) { - ScanLine* self = NULL; -#line 39 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - self = (ScanLine*) g_type_create_instance (object_type); -#line 39 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - return self; -#line 1516 "scanner.c" -} - - -ScanLine* scan_line_new (void) { -#line 39 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - return scan_line_construct (TYPE_SCAN_LINE); -#line 1523 "scanner.c" -} - - -static void value_scan_line_init (GValue* value) { -#line 39 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - value->data[0].v_pointer = NULL; -#line 1530 "scanner.c" -} - - -static void value_scan_line_free_value (GValue* value) { -#line 39 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - if (value->data[0].v_pointer) { -#line 39 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - scan_line_unref (value->data[0].v_pointer); -#line 1539 "scanner.c" - } -} - - -static void value_scan_line_copy_value (const GValue* src_value, GValue* dest_value) { -#line 39 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - if (src_value->data[0].v_pointer) { -#line 39 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - dest_value->data[0].v_pointer = scan_line_ref (src_value->data[0].v_pointer); -#line 1549 "scanner.c" - } else { -#line 39 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - dest_value->data[0].v_pointer = NULL; -#line 1553 "scanner.c" - } -} - - -static gpointer value_scan_line_peek_pointer (const GValue* value) { -#line 39 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - return value->data[0].v_pointer; -#line 1561 "scanner.c" -} - - -static gchar* value_scan_line_collect_value (GValue* value, guint n_collect_values, GTypeCValue* collect_values, guint collect_flags) { -#line 39 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - if (collect_values[0].v_pointer) { -#line 1568 "scanner.c" - ScanLine* object; - object = collect_values[0].v_pointer; -#line 39 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - if (object->parent_instance.g_class == NULL) { -#line 39 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - return g_strconcat ("invalid unclassed object pointer for value type `", G_VALUE_TYPE_NAME (value), "'", NULL); -#line 1575 "scanner.c" - } else if (!g_value_type_compatible (G_TYPE_FROM_INSTANCE (object), G_VALUE_TYPE (value))) { -#line 39 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - return g_strconcat ("invalid object type `", g_type_name (G_TYPE_FROM_INSTANCE (object)), "' for value type `", G_VALUE_TYPE_NAME (value), "'", NULL); -#line 1579 "scanner.c" - } -#line 39 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - value->data[0].v_pointer = scan_line_ref (object); -#line 1583 "scanner.c" - } else { -#line 39 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - value->data[0].v_pointer = NULL; -#line 1587 "scanner.c" - } -#line 39 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - return NULL; -#line 1591 "scanner.c" -} - - -static gchar* value_scan_line_lcopy_value (const GValue* value, guint n_collect_values, GTypeCValue* collect_values, guint collect_flags) { - ScanLine** object_p; - object_p = collect_values[0].v_pointer; -#line 39 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - if (!object_p) { -#line 39 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - return g_strdup_printf ("value location for `%s' passed as NULL", G_VALUE_TYPE_NAME (value)); -#line 1602 "scanner.c" - } -#line 39 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - if (!value->data[0].v_pointer) { -#line 39 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - *object_p = NULL; -#line 1608 "scanner.c" - } else if (collect_flags & G_VALUE_NOCOPY_CONTENTS) { -#line 39 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - *object_p = value->data[0].v_pointer; -#line 1612 "scanner.c" - } else { -#line 39 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - *object_p = scan_line_ref (value->data[0].v_pointer); -#line 1616 "scanner.c" - } -#line 39 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - return NULL; -#line 1620 "scanner.c" -} - - -GParamSpec* param_spec_scan_line (const gchar* name, const gchar* nick, const gchar* blurb, GType object_type, GParamFlags flags) { - ParamSpecScanLine* spec; -#line 39 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - g_return_val_if_fail (g_type_is_a (object_type, TYPE_SCAN_LINE), NULL); -#line 39 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - spec = g_param_spec_internal (G_TYPE_PARAM_OBJECT, name, nick, blurb, flags); -#line 39 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - G_PARAM_SPEC (spec)->value_type = object_type; -#line 39 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - return G_PARAM_SPEC (spec); -#line 1634 "scanner.c" -} - - -gpointer value_get_scan_line (const GValue* value) { -#line 39 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - g_return_val_if_fail (G_TYPE_CHECK_VALUE_TYPE (value, TYPE_SCAN_LINE), NULL); -#line 39 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - return value->data[0].v_pointer; -#line 1643 "scanner.c" -} - - -void value_set_scan_line (GValue* value, gpointer v_object) { - ScanLine* old; -#line 39 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - g_return_if_fail (G_TYPE_CHECK_VALUE_TYPE (value, TYPE_SCAN_LINE)); -#line 39 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - old = value->data[0].v_pointer; -#line 39 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - if (v_object) { -#line 39 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - g_return_if_fail (G_TYPE_CHECK_INSTANCE_TYPE (v_object, TYPE_SCAN_LINE)); -#line 39 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - g_return_if_fail (g_value_type_compatible (G_TYPE_FROM_INSTANCE (v_object), G_VALUE_TYPE (value))); -#line 39 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - value->data[0].v_pointer = v_object; -#line 39 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - scan_line_ref (value->data[0].v_pointer); -#line 1663 "scanner.c" - } else { -#line 39 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - value->data[0].v_pointer = NULL; -#line 1667 "scanner.c" - } -#line 39 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - if (old) { -#line 39 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - scan_line_unref (old); -#line 1673 "scanner.c" - } -} - - -void value_take_scan_line (GValue* value, gpointer v_object) { - ScanLine* old; -#line 39 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - g_return_if_fail (G_TYPE_CHECK_VALUE_TYPE (value, TYPE_SCAN_LINE)); -#line 39 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - old = value->data[0].v_pointer; -#line 39 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - if (v_object) { -#line 39 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - g_return_if_fail (G_TYPE_CHECK_INSTANCE_TYPE (v_object, TYPE_SCAN_LINE)); -#line 39 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - g_return_if_fail (g_value_type_compatible (G_TYPE_FROM_INSTANCE (v_object), G_VALUE_TYPE (value))); -#line 39 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - value->data[0].v_pointer = v_object; -#line 1692 "scanner.c" - } else { -#line 39 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - value->data[0].v_pointer = NULL; -#line 1696 "scanner.c" - } -#line 39 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - if (old) { -#line 39 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - scan_line_unref (old); -#line 1702 "scanner.c" - } -} - - -static void scan_line_class_init (ScanLineClass * klass) { -#line 39 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - scan_line_parent_class = g_type_class_peek_parent (klass); -#line 39 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - ((ScanLineClass *) klass)->finalize = scan_line_finalize; -#line 1712 "scanner.c" -} - - -static void scan_line_instance_init (ScanLine * self) { -#line 39 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - self->ref_count = 1; -#line 1719 "scanner.c" -} - - -static void scan_line_finalize (ScanLine* obj) { - ScanLine * self; -#line 39 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - self = G_TYPE_CHECK_INSTANCE_CAST (obj, TYPE_SCAN_LINE, ScanLine); -#line 39 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - g_signal_handlers_destroy (self); -#line 55 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - self->data = (g_free (self->data), NULL); -#line 1731 "scanner.c" -} - - -GType scan_line_get_type (void) { - static volatile gsize scan_line_type_id__volatile = 0; - if (g_once_init_enter (&scan_line_type_id__volatile)) { - static const GTypeValueTable g_define_type_value_table = { value_scan_line_init, value_scan_line_free_value, value_scan_line_copy_value, value_scan_line_peek_pointer, "p", value_scan_line_collect_value, "p", value_scan_line_lcopy_value }; - static const GTypeInfo g_define_type_info = { sizeof (ScanLineClass), (GBaseInitFunc) NULL, (GBaseFinalizeFunc) NULL, (GClassInitFunc) scan_line_class_init, (GClassFinalizeFunc) NULL, NULL, sizeof (ScanLine), 0, (GInstanceInitFunc) scan_line_instance_init, &g_define_type_value_table }; - static const GTypeFundamentalInfo g_define_type_fundamental_info = { (G_TYPE_FLAG_CLASSED | G_TYPE_FLAG_INSTANTIATABLE | G_TYPE_FLAG_DERIVABLE | G_TYPE_FLAG_DEEP_DERIVABLE) }; - GType scan_line_type_id; - scan_line_type_id = g_type_register_fundamental (g_type_fundamental_next (), "ScanLine", &g_define_type_info, &g_define_type_fundamental_info, 0); - g_once_init_leave (&scan_line_type_id__volatile, scan_line_type_id); - } - return scan_line_type_id__volatile; -} - - -gpointer scan_line_ref (gpointer instance) { - ScanLine* self; - self = instance; -#line 39 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - g_atomic_int_inc (&self->ref_count); -#line 39 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - return instance; -#line 1756 "scanner.c" -} - - -void scan_line_unref (gpointer instance) { - ScanLine* self; - self = instance; -#line 39 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - if (g_atomic_int_dec_and_test (&self->ref_count)) { -#line 39 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - SCAN_LINE_GET_CLASS (self)->finalize (self); -#line 39 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - g_type_free_instance ((GTypeInstance *) self); -#line 1769 "scanner.c" - } -} - - -GType scan_mode_get_type (void) { - static volatile gsize scan_mode_type_id__volatile = 0; - if (g_once_init_enter (&scan_mode_type_id__volatile)) { - static const GEnumValue values[] = {{SCAN_MODE_DEFAULT, "SCAN_MODE_DEFAULT", "default"}, {SCAN_MODE_COLOR, "SCAN_MODE_COLOR", "color"}, {SCAN_MODE_GRAY, "SCAN_MODE_GRAY", "gray"}, {SCAN_MODE_LINEART, "SCAN_MODE_LINEART", "lineart"}, {0, NULL, NULL}}; - GType scan_mode_type_id; - scan_mode_type_id = g_enum_register_static ("ScanMode", values); - g_once_init_leave (&scan_mode_type_id__volatile, scan_mode_type_id); - } - return scan_mode_type_id__volatile; -} - - -GType scan_type_get_type (void) { - static volatile gsize scan_type_type_id__volatile = 0; - if (g_once_init_enter (&scan_type_type_id__volatile)) { - static const GEnumValue values[] = {{SCAN_TYPE_SINGLE, "SCAN_TYPE_SINGLE", "single"}, {SCAN_TYPE_ADF_FRONT, "SCAN_TYPE_ADF_FRONT", "adf-front"}, {SCAN_TYPE_ADF_BACK, "SCAN_TYPE_ADF_BACK", "adf-back"}, {SCAN_TYPE_ADF_BOTH, "SCAN_TYPE_ADF_BOTH", "adf-both"}, {0, NULL, NULL}}; - GType scan_type_type_id; - scan_type_type_id = g_enum_register_static ("ScanType", values); - g_once_init_leave (&scan_type_type_id__volatile, scan_type_type_id); - } - return scan_type_type_id__volatile; -} - - -ScanOptions* scan_options_construct (GType object_type) { - ScanOptions* self = NULL; -#line 75 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - self = (ScanOptions*) g_type_create_instance (object_type); -#line 75 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - return self; -#line 1804 "scanner.c" -} - - -ScanOptions* scan_options_new (void) { -#line 75 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - return scan_options_construct (TYPE_SCAN_OPTIONS); -#line 1811 "scanner.c" -} - - -static void value_scan_options_init (GValue* value) { -#line 75 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - value->data[0].v_pointer = NULL; -#line 1818 "scanner.c" -} - - -static void value_scan_options_free_value (GValue* value) { -#line 75 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - if (value->data[0].v_pointer) { -#line 75 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - scan_options_unref (value->data[0].v_pointer); -#line 1827 "scanner.c" - } -} - - -static void value_scan_options_copy_value (const GValue* src_value, GValue* dest_value) { -#line 75 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - if (src_value->data[0].v_pointer) { -#line 75 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - dest_value->data[0].v_pointer = scan_options_ref (src_value->data[0].v_pointer); -#line 1837 "scanner.c" - } else { -#line 75 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - dest_value->data[0].v_pointer = NULL; -#line 1841 "scanner.c" - } -} - - -static gpointer value_scan_options_peek_pointer (const GValue* value) { -#line 75 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - return value->data[0].v_pointer; -#line 1849 "scanner.c" -} - - -static gchar* value_scan_options_collect_value (GValue* value, guint n_collect_values, GTypeCValue* collect_values, guint collect_flags) { -#line 75 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - if (collect_values[0].v_pointer) { -#line 1856 "scanner.c" - ScanOptions* object; - object = collect_values[0].v_pointer; -#line 75 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - if (object->parent_instance.g_class == NULL) { -#line 75 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - return g_strconcat ("invalid unclassed object pointer for value type `", G_VALUE_TYPE_NAME (value), "'", NULL); -#line 1863 "scanner.c" - } else if (!g_value_type_compatible (G_TYPE_FROM_INSTANCE (object), G_VALUE_TYPE (value))) { -#line 75 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - return g_strconcat ("invalid object type `", g_type_name (G_TYPE_FROM_INSTANCE (object)), "' for value type `", G_VALUE_TYPE_NAME (value), "'", NULL); -#line 1867 "scanner.c" - } -#line 75 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - value->data[0].v_pointer = scan_options_ref (object); -#line 1871 "scanner.c" - } else { -#line 75 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - value->data[0].v_pointer = NULL; -#line 1875 "scanner.c" - } -#line 75 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - return NULL; -#line 1879 "scanner.c" -} - - -static gchar* value_scan_options_lcopy_value (const GValue* value, guint n_collect_values, GTypeCValue* collect_values, guint collect_flags) { - ScanOptions** object_p; - object_p = collect_values[0].v_pointer; -#line 75 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - if (!object_p) { -#line 75 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - return g_strdup_printf ("value location for `%s' passed as NULL", G_VALUE_TYPE_NAME (value)); -#line 1890 "scanner.c" - } -#line 75 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - if (!value->data[0].v_pointer) { -#line 75 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - *object_p = NULL; -#line 1896 "scanner.c" - } else if (collect_flags & G_VALUE_NOCOPY_CONTENTS) { -#line 75 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - *object_p = value->data[0].v_pointer; -#line 1900 "scanner.c" - } else { -#line 75 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - *object_p = scan_options_ref (value->data[0].v_pointer); -#line 1904 "scanner.c" - } -#line 75 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - return NULL; -#line 1908 "scanner.c" -} - - -GParamSpec* param_spec_scan_options (const gchar* name, const gchar* nick, const gchar* blurb, GType object_type, GParamFlags flags) { - ParamSpecScanOptions* spec; -#line 75 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - g_return_val_if_fail (g_type_is_a (object_type, TYPE_SCAN_OPTIONS), NULL); -#line 75 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - spec = g_param_spec_internal (G_TYPE_PARAM_OBJECT, name, nick, blurb, flags); -#line 75 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - G_PARAM_SPEC (spec)->value_type = object_type; -#line 75 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - return G_PARAM_SPEC (spec); -#line 1922 "scanner.c" -} - - -gpointer value_get_scan_options (const GValue* value) { -#line 75 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - g_return_val_if_fail (G_TYPE_CHECK_VALUE_TYPE (value, TYPE_SCAN_OPTIONS), NULL); -#line 75 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - return value->data[0].v_pointer; -#line 1931 "scanner.c" -} - - -void value_set_scan_options (GValue* value, gpointer v_object) { - ScanOptions* old; -#line 75 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - g_return_if_fail (G_TYPE_CHECK_VALUE_TYPE (value, TYPE_SCAN_OPTIONS)); -#line 75 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - old = value->data[0].v_pointer; -#line 75 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - if (v_object) { -#line 75 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - g_return_if_fail (G_TYPE_CHECK_INSTANCE_TYPE (v_object, TYPE_SCAN_OPTIONS)); -#line 75 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - g_return_if_fail (g_value_type_compatible (G_TYPE_FROM_INSTANCE (v_object), G_VALUE_TYPE (value))); -#line 75 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - value->data[0].v_pointer = v_object; -#line 75 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - scan_options_ref (value->data[0].v_pointer); -#line 1951 "scanner.c" - } else { -#line 75 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - value->data[0].v_pointer = NULL; -#line 1955 "scanner.c" - } -#line 75 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - if (old) { -#line 75 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - scan_options_unref (old); -#line 1961 "scanner.c" - } -} - - -void value_take_scan_options (GValue* value, gpointer v_object) { - ScanOptions* old; -#line 75 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - g_return_if_fail (G_TYPE_CHECK_VALUE_TYPE (value, TYPE_SCAN_OPTIONS)); -#line 75 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - old = value->data[0].v_pointer; -#line 75 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - if (v_object) { -#line 75 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - g_return_if_fail (G_TYPE_CHECK_INSTANCE_TYPE (v_object, TYPE_SCAN_OPTIONS)); -#line 75 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - g_return_if_fail (g_value_type_compatible (G_TYPE_FROM_INSTANCE (v_object), G_VALUE_TYPE (value))); -#line 75 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - value->data[0].v_pointer = v_object; -#line 1980 "scanner.c" - } else { -#line 75 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - value->data[0].v_pointer = NULL; -#line 1984 "scanner.c" - } -#line 75 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - if (old) { -#line 75 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - scan_options_unref (old); -#line 1990 "scanner.c" - } -} - - -static void scan_options_class_init (ScanOptionsClass * klass) { -#line 75 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - scan_options_parent_class = g_type_class_peek_parent (klass); -#line 75 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - ((ScanOptionsClass *) klass)->finalize = scan_options_finalize; -#line 2000 "scanner.c" -} - - -static void scan_options_instance_init (ScanOptions * self) { -#line 75 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - self->ref_count = 1; -#line 2007 "scanner.c" -} - - -static void scan_options_finalize (ScanOptions* obj) { - ScanOptions * self; -#line 75 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - self = G_TYPE_CHECK_INSTANCE_CAST (obj, TYPE_SCAN_OPTIONS, ScanOptions); -#line 75 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - g_signal_handlers_destroy (self); -#line 2017 "scanner.c" -} - - -GType scan_options_get_type (void) { - static volatile gsize scan_options_type_id__volatile = 0; - if (g_once_init_enter (&scan_options_type_id__volatile)) { - static const GTypeValueTable g_define_type_value_table = { value_scan_options_init, value_scan_options_free_value, value_scan_options_copy_value, value_scan_options_peek_pointer, "p", value_scan_options_collect_value, "p", value_scan_options_lcopy_value }; - static const GTypeInfo g_define_type_info = { sizeof (ScanOptionsClass), (GBaseInitFunc) NULL, (GBaseFinalizeFunc) NULL, (GClassInitFunc) scan_options_class_init, (GClassFinalizeFunc) NULL, NULL, sizeof (ScanOptions), 0, (GInstanceInitFunc) scan_options_instance_init, &g_define_type_value_table }; - static const GTypeFundamentalInfo g_define_type_fundamental_info = { (G_TYPE_FLAG_CLASSED | G_TYPE_FLAG_INSTANTIATABLE | G_TYPE_FLAG_DERIVABLE | G_TYPE_FLAG_DEEP_DERIVABLE) }; - GType scan_options_type_id; - scan_options_type_id = g_type_register_fundamental (g_type_fundamental_next (), "ScanOptions", &g_define_type_info, &g_define_type_fundamental_info, 0); - g_once_init_leave (&scan_options_type_id__volatile, scan_options_type_id); - } - return scan_options_type_id__volatile; -} - - -gpointer scan_options_ref (gpointer instance) { - ScanOptions* self; - self = instance; -#line 75 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - g_atomic_int_inc (&self->ref_count); -#line 75 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - return instance; -#line 2042 "scanner.c" -} - - -void scan_options_unref (gpointer instance) { - ScanOptions* self; - self = instance; -#line 75 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - if (g_atomic_int_dec_and_test (&self->ref_count)) { -#line 75 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - SCAN_OPTIONS_GET_CLASS (self)->finalize (self); -#line 75 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - g_type_free_instance ((GTypeInstance *) self); -#line 2055 "scanner.c" - } -} - - -ScanJob* scan_job_construct (GType object_type) { - ScanJob* self = NULL; -#line 87 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - self = (ScanJob*) g_type_create_instance (object_type); -#line 87 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - return self; -#line 2066 "scanner.c" -} - - -ScanJob* scan_job_new (void) { -#line 87 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - return scan_job_construct (TYPE_SCAN_JOB); -#line 2073 "scanner.c" -} - - -static void value_scan_job_init (GValue* value) { -#line 87 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - value->data[0].v_pointer = NULL; -#line 2080 "scanner.c" -} - - -static void value_scan_job_free_value (GValue* value) { -#line 87 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - if (value->data[0].v_pointer) { -#line 87 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - scan_job_unref (value->data[0].v_pointer); -#line 2089 "scanner.c" - } -} - - -static void value_scan_job_copy_value (const GValue* src_value, GValue* dest_value) { -#line 87 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - if (src_value->data[0].v_pointer) { -#line 87 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - dest_value->data[0].v_pointer = scan_job_ref (src_value->data[0].v_pointer); -#line 2099 "scanner.c" - } else { -#line 87 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - dest_value->data[0].v_pointer = NULL; -#line 2103 "scanner.c" - } -} - - -static gpointer value_scan_job_peek_pointer (const GValue* value) { -#line 87 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - return value->data[0].v_pointer; -#line 2111 "scanner.c" -} - - -static gchar* value_scan_job_collect_value (GValue* value, guint n_collect_values, GTypeCValue* collect_values, guint collect_flags) { -#line 87 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - if (collect_values[0].v_pointer) { -#line 2118 "scanner.c" - ScanJob* object; - object = collect_values[0].v_pointer; -#line 87 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - if (object->parent_instance.g_class == NULL) { -#line 87 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - return g_strconcat ("invalid unclassed object pointer for value type `", G_VALUE_TYPE_NAME (value), "'", NULL); -#line 2125 "scanner.c" - } else if (!g_value_type_compatible (G_TYPE_FROM_INSTANCE (object), G_VALUE_TYPE (value))) { -#line 87 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - return g_strconcat ("invalid object type `", g_type_name (G_TYPE_FROM_INSTANCE (object)), "' for value type `", G_VALUE_TYPE_NAME (value), "'", NULL); -#line 2129 "scanner.c" - } -#line 87 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - value->data[0].v_pointer = scan_job_ref (object); -#line 2133 "scanner.c" - } else { -#line 87 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - value->data[0].v_pointer = NULL; -#line 2137 "scanner.c" - } -#line 87 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - return NULL; -#line 2141 "scanner.c" -} - - -static gchar* value_scan_job_lcopy_value (const GValue* value, guint n_collect_values, GTypeCValue* collect_values, guint collect_flags) { - ScanJob** object_p; - object_p = collect_values[0].v_pointer; -#line 87 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - if (!object_p) { -#line 87 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - return g_strdup_printf ("value location for `%s' passed as NULL", G_VALUE_TYPE_NAME (value)); -#line 2152 "scanner.c" - } -#line 87 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - if (!value->data[0].v_pointer) { -#line 87 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - *object_p = NULL; -#line 2158 "scanner.c" - } else if (collect_flags & G_VALUE_NOCOPY_CONTENTS) { -#line 87 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - *object_p = value->data[0].v_pointer; -#line 2162 "scanner.c" - } else { -#line 87 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - *object_p = scan_job_ref (value->data[0].v_pointer); -#line 2166 "scanner.c" - } -#line 87 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - return NULL; -#line 2170 "scanner.c" -} - - -GParamSpec* param_spec_scan_job (const gchar* name, const gchar* nick, const gchar* blurb, GType object_type, GParamFlags flags) { - ParamSpecScanJob* spec; -#line 87 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - g_return_val_if_fail (g_type_is_a (object_type, TYPE_SCAN_JOB), NULL); -#line 87 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - spec = g_param_spec_internal (G_TYPE_PARAM_OBJECT, name, nick, blurb, flags); -#line 87 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - G_PARAM_SPEC (spec)->value_type = object_type; -#line 87 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - return G_PARAM_SPEC (spec); -#line 2184 "scanner.c" -} - - -gpointer value_get_scan_job (const GValue* value) { -#line 87 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - g_return_val_if_fail (G_TYPE_CHECK_VALUE_TYPE (value, TYPE_SCAN_JOB), NULL); -#line 87 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - return value->data[0].v_pointer; -#line 2193 "scanner.c" -} - - -void value_set_scan_job (GValue* value, gpointer v_object) { - ScanJob* old; -#line 87 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - g_return_if_fail (G_TYPE_CHECK_VALUE_TYPE (value, TYPE_SCAN_JOB)); -#line 87 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - old = value->data[0].v_pointer; -#line 87 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - if (v_object) { -#line 87 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - g_return_if_fail (G_TYPE_CHECK_INSTANCE_TYPE (v_object, TYPE_SCAN_JOB)); -#line 87 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - g_return_if_fail (g_value_type_compatible (G_TYPE_FROM_INSTANCE (v_object), G_VALUE_TYPE (value))); -#line 87 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - value->data[0].v_pointer = v_object; -#line 87 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - scan_job_ref (value->data[0].v_pointer); -#line 2213 "scanner.c" - } else { -#line 87 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - value->data[0].v_pointer = NULL; -#line 2217 "scanner.c" - } -#line 87 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - if (old) { -#line 87 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - scan_job_unref (old); -#line 2223 "scanner.c" - } -} - - -void value_take_scan_job (GValue* value, gpointer v_object) { - ScanJob* old; -#line 87 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - g_return_if_fail (G_TYPE_CHECK_VALUE_TYPE (value, TYPE_SCAN_JOB)); -#line 87 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - old = value->data[0].v_pointer; -#line 87 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - if (v_object) { -#line 87 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - g_return_if_fail (G_TYPE_CHECK_INSTANCE_TYPE (v_object, TYPE_SCAN_JOB)); -#line 87 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - g_return_if_fail (g_value_type_compatible (G_TYPE_FROM_INSTANCE (v_object), G_VALUE_TYPE (value))); -#line 87 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - value->data[0].v_pointer = v_object; -#line 2242 "scanner.c" - } else { -#line 87 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - value->data[0].v_pointer = NULL; -#line 2246 "scanner.c" - } -#line 87 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - if (old) { -#line 87 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - scan_job_unref (old); -#line 2252 "scanner.c" - } -} - - -static void scan_job_class_init (ScanJobClass * klass) { -#line 87 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - scan_job_parent_class = g_type_class_peek_parent (klass); -#line 87 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - ((ScanJobClass *) klass)->finalize = scan_job_finalize; -#line 2262 "scanner.c" -} - - -static void scan_job_instance_init (ScanJob * self) { -#line 87 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - self->ref_count = 1; -#line 2269 "scanner.c" -} - - -static void scan_job_finalize (ScanJob* obj) { - ScanJob * self; -#line 87 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - self = G_TYPE_CHECK_INSTANCE_CAST (obj, TYPE_SCAN_JOB, ScanJob); -#line 87 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - g_signal_handlers_destroy (self); -#line 90 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _g_free0 (self->device); -#line 2281 "scanner.c" -} - - -GType scan_job_get_type (void) { - static volatile gsize scan_job_type_id__volatile = 0; - if (g_once_init_enter (&scan_job_type_id__volatile)) { - static const GTypeValueTable g_define_type_value_table = { value_scan_job_init, value_scan_job_free_value, value_scan_job_copy_value, value_scan_job_peek_pointer, "p", value_scan_job_collect_value, "p", value_scan_job_lcopy_value }; - static const GTypeInfo g_define_type_info = { sizeof (ScanJobClass), (GBaseInitFunc) NULL, (GBaseFinalizeFunc) NULL, (GClassInitFunc) scan_job_class_init, (GClassFinalizeFunc) NULL, NULL, sizeof (ScanJob), 0, (GInstanceInitFunc) scan_job_instance_init, &g_define_type_value_table }; - static const GTypeFundamentalInfo g_define_type_fundamental_info = { (G_TYPE_FLAG_CLASSED | G_TYPE_FLAG_INSTANTIATABLE | G_TYPE_FLAG_DERIVABLE | G_TYPE_FLAG_DEEP_DERIVABLE) }; - GType scan_job_type_id; - scan_job_type_id = g_type_register_fundamental (g_type_fundamental_next (), "ScanJob", &g_define_type_info, &g_define_type_fundamental_info, 0); - g_once_init_leave (&scan_job_type_id__volatile, scan_job_type_id); - } - return scan_job_type_id__volatile; -} - - -gpointer scan_job_ref (gpointer instance) { - ScanJob* self; - self = instance; -#line 87 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - g_atomic_int_inc (&self->ref_count); -#line 87 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - return instance; -#line 2306 "scanner.c" -} - - -void scan_job_unref (gpointer instance) { - ScanJob* self; - self = instance; -#line 87 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - if (g_atomic_int_dec_and_test (&self->ref_count)) { -#line 87 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - SCAN_JOB_GET_CLASS (self)->finalize (self); -#line 87 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - g_type_free_instance ((GTypeInstance *) self); -#line 2319 "scanner.c" - } -} - - -Request* request_construct (GType object_type) { - Request* self = NULL; -#line 101 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - self = (Request*) g_type_create_instance (object_type); -#line 101 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - return self; -#line 2330 "scanner.c" -} - - -Request* request_new (void) { -#line 101 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - return request_construct (TYPE_REQUEST); -#line 2337 "scanner.c" -} - - -static void value_request_init (GValue* value) { -#line 101 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - value->data[0].v_pointer = NULL; -#line 2344 "scanner.c" -} - - -static void value_request_free_value (GValue* value) { -#line 101 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - if (value->data[0].v_pointer) { -#line 101 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - request_unref (value->data[0].v_pointer); -#line 2353 "scanner.c" - } -} - - -static void value_request_copy_value (const GValue* src_value, GValue* dest_value) { -#line 101 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - if (src_value->data[0].v_pointer) { -#line 101 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - dest_value->data[0].v_pointer = request_ref (src_value->data[0].v_pointer); -#line 2363 "scanner.c" - } else { -#line 101 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - dest_value->data[0].v_pointer = NULL; -#line 2367 "scanner.c" - } -} - - -static gpointer value_request_peek_pointer (const GValue* value) { -#line 101 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - return value->data[0].v_pointer; -#line 2375 "scanner.c" -} - - -static gchar* value_request_collect_value (GValue* value, guint n_collect_values, GTypeCValue* collect_values, guint collect_flags) { -#line 101 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - if (collect_values[0].v_pointer) { -#line 2382 "scanner.c" - Request* object; - object = collect_values[0].v_pointer; -#line 101 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - if (object->parent_instance.g_class == NULL) { -#line 101 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - return g_strconcat ("invalid unclassed object pointer for value type `", G_VALUE_TYPE_NAME (value), "'", NULL); -#line 2389 "scanner.c" - } else if (!g_value_type_compatible (G_TYPE_FROM_INSTANCE (object), G_VALUE_TYPE (value))) { -#line 101 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - return g_strconcat ("invalid object type `", g_type_name (G_TYPE_FROM_INSTANCE (object)), "' for value type `", G_VALUE_TYPE_NAME (value), "'", NULL); -#line 2393 "scanner.c" - } -#line 101 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - value->data[0].v_pointer = request_ref (object); -#line 2397 "scanner.c" - } else { -#line 101 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - value->data[0].v_pointer = NULL; -#line 2401 "scanner.c" - } -#line 101 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - return NULL; -#line 2405 "scanner.c" -} - - -static gchar* value_request_lcopy_value (const GValue* value, guint n_collect_values, GTypeCValue* collect_values, guint collect_flags) { - Request** object_p; - object_p = collect_values[0].v_pointer; -#line 101 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - if (!object_p) { -#line 101 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - return g_strdup_printf ("value location for `%s' passed as NULL", G_VALUE_TYPE_NAME (value)); -#line 2416 "scanner.c" - } -#line 101 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - if (!value->data[0].v_pointer) { -#line 101 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - *object_p = NULL; -#line 2422 "scanner.c" - } else if (collect_flags & G_VALUE_NOCOPY_CONTENTS) { -#line 101 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - *object_p = value->data[0].v_pointer; -#line 2426 "scanner.c" - } else { -#line 101 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - *object_p = request_ref (value->data[0].v_pointer); -#line 2430 "scanner.c" - } -#line 101 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - return NULL; -#line 2434 "scanner.c" -} - - -GParamSpec* param_spec_request (const gchar* name, const gchar* nick, const gchar* blurb, GType object_type, GParamFlags flags) { - ParamSpecRequest* spec; -#line 101 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - g_return_val_if_fail (g_type_is_a (object_type, TYPE_REQUEST), NULL); -#line 101 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - spec = g_param_spec_internal (G_TYPE_PARAM_OBJECT, name, nick, blurb, flags); -#line 101 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - G_PARAM_SPEC (spec)->value_type = object_type; -#line 101 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - return G_PARAM_SPEC (spec); -#line 2448 "scanner.c" -} - - -gpointer value_get_request (const GValue* value) { -#line 101 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - g_return_val_if_fail (G_TYPE_CHECK_VALUE_TYPE (value, TYPE_REQUEST), NULL); -#line 101 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - return value->data[0].v_pointer; -#line 2457 "scanner.c" -} - - -void value_set_request (GValue* value, gpointer v_object) { - Request* old; -#line 101 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - g_return_if_fail (G_TYPE_CHECK_VALUE_TYPE (value, TYPE_REQUEST)); -#line 101 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - old = value->data[0].v_pointer; -#line 101 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - if (v_object) { -#line 101 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - g_return_if_fail (G_TYPE_CHECK_INSTANCE_TYPE (v_object, TYPE_REQUEST)); -#line 101 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - g_return_if_fail (g_value_type_compatible (G_TYPE_FROM_INSTANCE (v_object), G_VALUE_TYPE (value))); -#line 101 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - value->data[0].v_pointer = v_object; -#line 101 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - request_ref (value->data[0].v_pointer); -#line 2477 "scanner.c" - } else { -#line 101 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - value->data[0].v_pointer = NULL; -#line 2481 "scanner.c" - } -#line 101 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - if (old) { -#line 101 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - request_unref (old); -#line 2487 "scanner.c" - } -} - - -void value_take_request (GValue* value, gpointer v_object) { - Request* old; -#line 101 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - g_return_if_fail (G_TYPE_CHECK_VALUE_TYPE (value, TYPE_REQUEST)); -#line 101 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - old = value->data[0].v_pointer; -#line 101 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - if (v_object) { -#line 101 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - g_return_if_fail (G_TYPE_CHECK_INSTANCE_TYPE (v_object, TYPE_REQUEST)); -#line 101 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - g_return_if_fail (g_value_type_compatible (G_TYPE_FROM_INSTANCE (v_object), G_VALUE_TYPE (value))); -#line 101 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - value->data[0].v_pointer = v_object; -#line 2506 "scanner.c" - } else { -#line 101 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - value->data[0].v_pointer = NULL; -#line 2510 "scanner.c" - } -#line 101 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - if (old) { -#line 101 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - request_unref (old); -#line 2516 "scanner.c" - } -} - - -static void request_class_init (RequestClass * klass) { -#line 101 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - request_parent_class = g_type_class_peek_parent (klass); -#line 101 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - ((RequestClass *) klass)->finalize = request_finalize; -#line 2526 "scanner.c" -} - - -static void request_instance_init (Request * self) { -#line 101 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - self->ref_count = 1; -#line 2533 "scanner.c" -} - - -static void request_finalize (Request* obj) { - Request * self; -#line 101 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - self = G_TYPE_CHECK_INSTANCE_CAST (obj, TYPE_REQUEST, Request); -#line 101 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - g_signal_handlers_destroy (self); -#line 2543 "scanner.c" -} - - -GType request_get_type (void) { - static volatile gsize request_type_id__volatile = 0; - if (g_once_init_enter (&request_type_id__volatile)) { - static const GTypeValueTable g_define_type_value_table = { value_request_init, value_request_free_value, value_request_copy_value, value_request_peek_pointer, "p", value_request_collect_value, "p", value_request_lcopy_value }; - static const GTypeInfo g_define_type_info = { sizeof (RequestClass), (GBaseInitFunc) NULL, (GBaseFinalizeFunc) NULL, (GClassInitFunc) request_class_init, (GClassFinalizeFunc) NULL, NULL, sizeof (Request), 0, (GInstanceInitFunc) request_instance_init, &g_define_type_value_table }; - static const GTypeFundamentalInfo g_define_type_fundamental_info = { (G_TYPE_FLAG_CLASSED | G_TYPE_FLAG_INSTANTIATABLE | G_TYPE_FLAG_DERIVABLE | G_TYPE_FLAG_DEEP_DERIVABLE) }; - GType request_type_id; - request_type_id = g_type_register_fundamental (g_type_fundamental_next (), "Request", &g_define_type_info, &g_define_type_fundamental_info, 0); - g_once_init_leave (&request_type_id__volatile, request_type_id); - } - return request_type_id__volatile; -} - - -gpointer request_ref (gpointer instance) { - Request* self; - self = instance; -#line 101 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - g_atomic_int_inc (&self->ref_count); -#line 101 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - return instance; -#line 2568 "scanner.c" -} - - -void request_unref (gpointer instance) { - Request* self; - self = instance; -#line 101 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - if (g_atomic_int_dec_and_test (&self->ref_count)) { -#line 101 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - REQUEST_GET_CLASS (self)->finalize (self); -#line 101 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - g_type_free_instance ((GTypeInstance *) self); -#line 2581 "scanner.c" - } -} - - -RequestRedetect* request_redetect_construct (GType object_type) { - RequestRedetect* self = NULL; -#line 103 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - self = (RequestRedetect*) request_construct (object_type); -#line 103 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - return self; -#line 2592 "scanner.c" -} - - -RequestRedetect* request_redetect_new (void) { -#line 103 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - return request_redetect_construct (TYPE_REQUEST_REDETECT); -#line 2599 "scanner.c" -} - - -static void request_redetect_class_init (RequestRedetectClass * klass) { -#line 103 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - request_redetect_parent_class = g_type_class_peek_parent (klass); -#line 2606 "scanner.c" -} - - -static void request_redetect_instance_init (RequestRedetect * self) { -} - - -GType request_redetect_get_type (void) { - static volatile gsize request_redetect_type_id__volatile = 0; - if (g_once_init_enter (&request_redetect_type_id__volatile)) { - static const GTypeInfo g_define_type_info = { sizeof (RequestRedetectClass), (GBaseInitFunc) NULL, (GBaseFinalizeFunc) NULL, (GClassInitFunc) request_redetect_class_init, (GClassFinalizeFunc) NULL, NULL, sizeof (RequestRedetect), 0, (GInstanceInitFunc) request_redetect_instance_init, NULL }; - GType request_redetect_type_id; - request_redetect_type_id = g_type_register_static (TYPE_REQUEST, "RequestRedetect", &g_define_type_info, 0); - g_once_init_leave (&request_redetect_type_id__volatile, request_redetect_type_id); - } - return request_redetect_type_id__volatile; -} - - -RequestCancel* request_cancel_construct (GType object_type) { - RequestCancel* self = NULL; -#line 105 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - self = (RequestCancel*) request_construct (object_type); -#line 105 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - return self; -#line 2632 "scanner.c" -} - - -RequestCancel* request_cancel_new (void) { -#line 105 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - return request_cancel_construct (TYPE_REQUEST_CANCEL); -#line 2639 "scanner.c" -} - - -static void request_cancel_class_init (RequestCancelClass * klass) { -#line 105 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - request_cancel_parent_class = g_type_class_peek_parent (klass); -#line 2646 "scanner.c" -} - - -static void request_cancel_instance_init (RequestCancel * self) { -} - - -GType request_cancel_get_type (void) { - static volatile gsize request_cancel_type_id__volatile = 0; - if (g_once_init_enter (&request_cancel_type_id__volatile)) { - static const GTypeInfo g_define_type_info = { sizeof (RequestCancelClass), (GBaseInitFunc) NULL, (GBaseFinalizeFunc) NULL, (GClassInitFunc) request_cancel_class_init, (GClassFinalizeFunc) NULL, NULL, sizeof (RequestCancel), 0, (GInstanceInitFunc) request_cancel_instance_init, NULL }; - GType request_cancel_type_id; - request_cancel_type_id = g_type_register_static (TYPE_REQUEST, "RequestCancel", &g_define_type_info, 0); - g_once_init_leave (&request_cancel_type_id__volatile, request_cancel_type_id); - } - return request_cancel_type_id__volatile; -} - - -RequestStartScan* request_start_scan_construct (GType object_type) { - RequestStartScan* self = NULL; -#line 107 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - self = (RequestStartScan*) request_construct (object_type); -#line 107 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - return self; -#line 2672 "scanner.c" -} - - -RequestStartScan* request_start_scan_new (void) { -#line 107 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - return request_start_scan_construct (TYPE_REQUEST_START_SCAN); -#line 2679 "scanner.c" -} - - -static void request_start_scan_class_init (RequestStartScanClass * klass) { -#line 107 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - request_start_scan_parent_class = g_type_class_peek_parent (klass); -#line 107 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - ((RequestClass *) klass)->finalize = request_start_scan_finalize; -#line 2688 "scanner.c" -} - - -static void request_start_scan_instance_init (RequestStartScan * self) { -} - - -static void request_start_scan_finalize (Request* obj) { - RequestStartScan * self; -#line 107 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - self = G_TYPE_CHECK_INSTANCE_CAST (obj, TYPE_REQUEST_START_SCAN, RequestStartScan); -#line 109 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _scan_job_unref0 (self->job); -#line 107 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - REQUEST_CLASS (request_start_scan_parent_class)->finalize (obj); -#line 2704 "scanner.c" -} - - -GType request_start_scan_get_type (void) { - static volatile gsize request_start_scan_type_id__volatile = 0; - if (g_once_init_enter (&request_start_scan_type_id__volatile)) { - static const GTypeInfo g_define_type_info = { sizeof (RequestStartScanClass), (GBaseInitFunc) NULL, (GBaseFinalizeFunc) NULL, (GClassInitFunc) request_start_scan_class_init, (GClassFinalizeFunc) NULL, NULL, sizeof (RequestStartScan), 0, (GInstanceInitFunc) request_start_scan_instance_init, NULL }; - GType request_start_scan_type_id; - request_start_scan_type_id = g_type_register_static (TYPE_REQUEST, "RequestStartScan", &g_define_type_info, 0); - g_once_init_leave (&request_start_scan_type_id__volatile, request_start_scan_type_id); - } - return request_start_scan_type_id__volatile; -} - - -RequestQuit* request_quit_construct (GType object_type) { - RequestQuit* self = NULL; -#line 112 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - self = (RequestQuit*) request_construct (object_type); -#line 112 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - return self; -#line 2726 "scanner.c" -} - - -RequestQuit* request_quit_new (void) { -#line 112 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - return request_quit_construct (TYPE_REQUEST_QUIT); -#line 2733 "scanner.c" -} - - -static void request_quit_class_init (RequestQuitClass * klass) { -#line 112 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - request_quit_parent_class = g_type_class_peek_parent (klass); -#line 2740 "scanner.c" -} - - -static void request_quit_instance_init (RequestQuit * self) { -} - - -GType request_quit_get_type (void) { - static volatile gsize request_quit_type_id__volatile = 0; - if (g_once_init_enter (&request_quit_type_id__volatile)) { - static const GTypeInfo g_define_type_info = { sizeof (RequestQuitClass), (GBaseInitFunc) NULL, (GBaseFinalizeFunc) NULL, (GClassInitFunc) request_quit_class_init, (GClassFinalizeFunc) NULL, NULL, sizeof (RequestQuit), 0, (GInstanceInitFunc) request_quit_instance_init, NULL }; - GType request_quit_type_id; - request_quit_type_id = g_type_register_static (TYPE_REQUEST, "RequestQuit", &g_define_type_info, 0); - g_once_init_leave (&request_quit_type_id__volatile, request_quit_type_id); - } - return request_quit_type_id__volatile; -} - - -Credentials* credentials_construct (GType object_type) { - Credentials* self = NULL; -#line 114 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - self = (Credentials*) g_type_create_instance (object_type); -#line 114 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - return self; -#line 2766 "scanner.c" -} - - -Credentials* credentials_new (void) { -#line 114 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - return credentials_construct (TYPE_CREDENTIALS); -#line 2773 "scanner.c" -} - - -static void value_credentials_init (GValue* value) { -#line 114 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - value->data[0].v_pointer = NULL; -#line 2780 "scanner.c" -} - - -static void value_credentials_free_value (GValue* value) { -#line 114 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - if (value->data[0].v_pointer) { -#line 114 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - credentials_unref (value->data[0].v_pointer); -#line 2789 "scanner.c" - } -} - - -static void value_credentials_copy_value (const GValue* src_value, GValue* dest_value) { -#line 114 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - if (src_value->data[0].v_pointer) { -#line 114 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - dest_value->data[0].v_pointer = credentials_ref (src_value->data[0].v_pointer); -#line 2799 "scanner.c" - } else { -#line 114 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - dest_value->data[0].v_pointer = NULL; -#line 2803 "scanner.c" - } -} - - -static gpointer value_credentials_peek_pointer (const GValue* value) { -#line 114 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - return value->data[0].v_pointer; -#line 2811 "scanner.c" -} - - -static gchar* value_credentials_collect_value (GValue* value, guint n_collect_values, GTypeCValue* collect_values, guint collect_flags) { -#line 114 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - if (collect_values[0].v_pointer) { -#line 2818 "scanner.c" - Credentials* object; - object = collect_values[0].v_pointer; -#line 114 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - if (object->parent_instance.g_class == NULL) { -#line 114 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - return g_strconcat ("invalid unclassed object pointer for value type `", G_VALUE_TYPE_NAME (value), "'", NULL); -#line 2825 "scanner.c" - } else if (!g_value_type_compatible (G_TYPE_FROM_INSTANCE (object), G_VALUE_TYPE (value))) { -#line 114 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - return g_strconcat ("invalid object type `", g_type_name (G_TYPE_FROM_INSTANCE (object)), "' for value type `", G_VALUE_TYPE_NAME (value), "'", NULL); -#line 2829 "scanner.c" - } -#line 114 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - value->data[0].v_pointer = credentials_ref (object); -#line 2833 "scanner.c" - } else { -#line 114 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - value->data[0].v_pointer = NULL; -#line 2837 "scanner.c" - } -#line 114 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - return NULL; -#line 2841 "scanner.c" -} - - -static gchar* value_credentials_lcopy_value (const GValue* value, guint n_collect_values, GTypeCValue* collect_values, guint collect_flags) { - Credentials** object_p; - object_p = collect_values[0].v_pointer; -#line 114 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - if (!object_p) { -#line 114 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - return g_strdup_printf ("value location for `%s' passed as NULL", G_VALUE_TYPE_NAME (value)); -#line 2852 "scanner.c" - } -#line 114 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - if (!value->data[0].v_pointer) { -#line 114 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - *object_p = NULL; -#line 2858 "scanner.c" - } else if (collect_flags & G_VALUE_NOCOPY_CONTENTS) { -#line 114 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - *object_p = value->data[0].v_pointer; -#line 2862 "scanner.c" - } else { -#line 114 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - *object_p = credentials_ref (value->data[0].v_pointer); -#line 2866 "scanner.c" - } -#line 114 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - return NULL; -#line 2870 "scanner.c" -} - - -GParamSpec* param_spec_credentials (const gchar* name, const gchar* nick, const gchar* blurb, GType object_type, GParamFlags flags) { - ParamSpecCredentials* spec; -#line 114 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - g_return_val_if_fail (g_type_is_a (object_type, TYPE_CREDENTIALS), NULL); -#line 114 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - spec = g_param_spec_internal (G_TYPE_PARAM_OBJECT, name, nick, blurb, flags); -#line 114 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - G_PARAM_SPEC (spec)->value_type = object_type; -#line 114 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - return G_PARAM_SPEC (spec); -#line 2884 "scanner.c" -} - - -gpointer value_get_credentials (const GValue* value) { -#line 114 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - g_return_val_if_fail (G_TYPE_CHECK_VALUE_TYPE (value, TYPE_CREDENTIALS), NULL); -#line 114 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - return value->data[0].v_pointer; -#line 2893 "scanner.c" -} - - -void value_set_credentials (GValue* value, gpointer v_object) { - Credentials* old; -#line 114 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - g_return_if_fail (G_TYPE_CHECK_VALUE_TYPE (value, TYPE_CREDENTIALS)); -#line 114 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - old = value->data[0].v_pointer; -#line 114 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - if (v_object) { -#line 114 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - g_return_if_fail (G_TYPE_CHECK_INSTANCE_TYPE (v_object, TYPE_CREDENTIALS)); -#line 114 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - g_return_if_fail (g_value_type_compatible (G_TYPE_FROM_INSTANCE (v_object), G_VALUE_TYPE (value))); -#line 114 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - value->data[0].v_pointer = v_object; -#line 114 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - credentials_ref (value->data[0].v_pointer); -#line 2913 "scanner.c" - } else { -#line 114 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - value->data[0].v_pointer = NULL; -#line 2917 "scanner.c" - } -#line 114 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - if (old) { -#line 114 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - credentials_unref (old); -#line 2923 "scanner.c" - } -} - - -void value_take_credentials (GValue* value, gpointer v_object) { - Credentials* old; -#line 114 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - g_return_if_fail (G_TYPE_CHECK_VALUE_TYPE (value, TYPE_CREDENTIALS)); -#line 114 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - old = value->data[0].v_pointer; -#line 114 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - if (v_object) { -#line 114 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - g_return_if_fail (G_TYPE_CHECK_INSTANCE_TYPE (v_object, TYPE_CREDENTIALS)); -#line 114 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - g_return_if_fail (g_value_type_compatible (G_TYPE_FROM_INSTANCE (v_object), G_VALUE_TYPE (value))); -#line 114 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - value->data[0].v_pointer = v_object; -#line 2942 "scanner.c" - } else { -#line 114 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - value->data[0].v_pointer = NULL; -#line 2946 "scanner.c" - } -#line 114 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - if (old) { -#line 114 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - credentials_unref (old); -#line 2952 "scanner.c" - } -} - - -static void credentials_class_init (CredentialsClass * klass) { -#line 114 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - credentials_parent_class = g_type_class_peek_parent (klass); -#line 114 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - ((CredentialsClass *) klass)->finalize = credentials_finalize; -#line 2962 "scanner.c" -} - - -static void credentials_instance_init (Credentials * self) { -#line 114 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - self->ref_count = 1; -#line 2969 "scanner.c" -} - - -static void credentials_finalize (Credentials* obj) { - Credentials * self; -#line 114 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - self = G_TYPE_CHECK_INSTANCE_CAST (obj, TYPE_CREDENTIALS, Credentials); -#line 114 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - g_signal_handlers_destroy (self); -#line 116 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _g_free0 (self->username); -#line 117 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _g_free0 (self->password); -#line 2983 "scanner.c" -} - - -GType credentials_get_type (void) { - static volatile gsize credentials_type_id__volatile = 0; - if (g_once_init_enter (&credentials_type_id__volatile)) { - static const GTypeValueTable g_define_type_value_table = { value_credentials_init, value_credentials_free_value, value_credentials_copy_value, value_credentials_peek_pointer, "p", value_credentials_collect_value, "p", value_credentials_lcopy_value }; - static const GTypeInfo g_define_type_info = { sizeof (CredentialsClass), (GBaseInitFunc) NULL, (GBaseFinalizeFunc) NULL, (GClassInitFunc) credentials_class_init, (GClassFinalizeFunc) NULL, NULL, sizeof (Credentials), 0, (GInstanceInitFunc) credentials_instance_init, &g_define_type_value_table }; - static const GTypeFundamentalInfo g_define_type_fundamental_info = { (G_TYPE_FLAG_CLASSED | G_TYPE_FLAG_INSTANTIATABLE | G_TYPE_FLAG_DERIVABLE | G_TYPE_FLAG_DEEP_DERIVABLE) }; - GType credentials_type_id; - credentials_type_id = g_type_register_fundamental (g_type_fundamental_next (), "Credentials", &g_define_type_info, &g_define_type_fundamental_info, 0); - g_once_init_leave (&credentials_type_id__volatile, credentials_type_id); - } - return credentials_type_id__volatile; -} - - -gpointer credentials_ref (gpointer instance) { - Credentials* self; - self = instance; -#line 114 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - g_atomic_int_inc (&self->ref_count); -#line 114 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - return instance; -#line 3008 "scanner.c" -} - - -void credentials_unref (gpointer instance) { - Credentials* self; - self = instance; -#line 114 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - if (g_atomic_int_dec_and_test (&self->ref_count)) { -#line 114 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - CREDENTIALS_GET_CLASS (self)->finalize (self); -#line 114 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - g_type_free_instance ((GTypeInstance *) self); -#line 3021 "scanner.c" - } -} - - -GType scan_state_get_type (void) { - static volatile gsize scan_state_type_id__volatile = 0; - if (g_once_init_enter (&scan_state_type_id__volatile)) { - static const GEnumValue values[] = {{SCAN_STATE_IDLE, "SCAN_STATE_IDLE", "idle"}, {SCAN_STATE_REDETECT, "SCAN_STATE_REDETECT", "redetect"}, {SCAN_STATE_OPEN, "SCAN_STATE_OPEN", "open"}, {SCAN_STATE_GET_OPTION, "SCAN_STATE_GET_OPTION", "get-option"}, {SCAN_STATE_START, "SCAN_STATE_START", "start"}, {SCAN_STATE_GET_PARAMETERS, "SCAN_STATE_GET_PARAMETERS", "get-parameters"}, {SCAN_STATE_READ, "SCAN_STATE_READ", "read"}, {0, NULL, NULL}}; - GType scan_state_type_id; - scan_state_type_id = g_enum_register_static ("ScanState", values); - g_once_init_leave (&scan_state_type_id__volatile, scan_state_type_id); - } - return scan_state_type_id__volatile; -} - - -static void notify_real_run (Notify* self, Scanner* scanner) { -#line 133 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - g_return_if_fail (scanner != NULL); -#line 3041 "scanner.c" -} - - -void notify_run (Notify* self, Scanner* scanner) { -#line 133 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - g_return_if_fail (self != NULL); -#line 133 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - NOTIFY_GET_CLASS (self)->run (self, scanner); -#line 3050 "scanner.c" -} - - -Notify* notify_construct (GType object_type) { - Notify* self = NULL; -#line 131 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - self = (Notify*) g_type_create_instance (object_type); -#line 131 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - return self; -#line 3060 "scanner.c" -} - - -Notify* notify_new (void) { -#line 131 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - return notify_construct (TYPE_NOTIFY); -#line 3067 "scanner.c" -} - - -static void value_notify_init (GValue* value) { -#line 131 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - value->data[0].v_pointer = NULL; -#line 3074 "scanner.c" -} - - -static void value_notify_free_value (GValue* value) { -#line 131 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - if (value->data[0].v_pointer) { -#line 131 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - notify_unref (value->data[0].v_pointer); -#line 3083 "scanner.c" - } -} - - -static void value_notify_copy_value (const GValue* src_value, GValue* dest_value) { -#line 131 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - if (src_value->data[0].v_pointer) { -#line 131 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - dest_value->data[0].v_pointer = notify_ref (src_value->data[0].v_pointer); -#line 3093 "scanner.c" - } else { -#line 131 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - dest_value->data[0].v_pointer = NULL; -#line 3097 "scanner.c" - } -} - - -static gpointer value_notify_peek_pointer (const GValue* value) { -#line 131 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - return value->data[0].v_pointer; -#line 3105 "scanner.c" -} - - -static gchar* value_notify_collect_value (GValue* value, guint n_collect_values, GTypeCValue* collect_values, guint collect_flags) { -#line 131 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - if (collect_values[0].v_pointer) { -#line 3112 "scanner.c" - Notify* object; - object = collect_values[0].v_pointer; -#line 131 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - if (object->parent_instance.g_class == NULL) { -#line 131 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - return g_strconcat ("invalid unclassed object pointer for value type `", G_VALUE_TYPE_NAME (value), "'", NULL); -#line 3119 "scanner.c" - } else if (!g_value_type_compatible (G_TYPE_FROM_INSTANCE (object), G_VALUE_TYPE (value))) { -#line 131 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - return g_strconcat ("invalid object type `", g_type_name (G_TYPE_FROM_INSTANCE (object)), "' for value type `", G_VALUE_TYPE_NAME (value), "'", NULL); -#line 3123 "scanner.c" - } -#line 131 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - value->data[0].v_pointer = notify_ref (object); -#line 3127 "scanner.c" - } else { -#line 131 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - value->data[0].v_pointer = NULL; -#line 3131 "scanner.c" - } -#line 131 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - return NULL; -#line 3135 "scanner.c" -} - - -static gchar* value_notify_lcopy_value (const GValue* value, guint n_collect_values, GTypeCValue* collect_values, guint collect_flags) { - Notify** object_p; - object_p = collect_values[0].v_pointer; -#line 131 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - if (!object_p) { -#line 131 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - return g_strdup_printf ("value location for `%s' passed as NULL", G_VALUE_TYPE_NAME (value)); -#line 3146 "scanner.c" - } -#line 131 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - if (!value->data[0].v_pointer) { -#line 131 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - *object_p = NULL; -#line 3152 "scanner.c" - } else if (collect_flags & G_VALUE_NOCOPY_CONTENTS) { -#line 131 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - *object_p = value->data[0].v_pointer; -#line 3156 "scanner.c" - } else { -#line 131 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - *object_p = notify_ref (value->data[0].v_pointer); -#line 3160 "scanner.c" - } -#line 131 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - return NULL; -#line 3164 "scanner.c" -} - - -GParamSpec* param_spec_notify (const gchar* name, const gchar* nick, const gchar* blurb, GType object_type, GParamFlags flags) { - ParamSpecNotify* spec; -#line 131 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - g_return_val_if_fail (g_type_is_a (object_type, TYPE_NOTIFY), NULL); -#line 131 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - spec = g_param_spec_internal (G_TYPE_PARAM_OBJECT, name, nick, blurb, flags); -#line 131 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - G_PARAM_SPEC (spec)->value_type = object_type; -#line 131 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - return G_PARAM_SPEC (spec); -#line 3178 "scanner.c" -} - - -gpointer value_get_notify (const GValue* value) { -#line 131 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - g_return_val_if_fail (G_TYPE_CHECK_VALUE_TYPE (value, TYPE_NOTIFY), NULL); -#line 131 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - return value->data[0].v_pointer; -#line 3187 "scanner.c" -} - - -void value_set_notify (GValue* value, gpointer v_object) { - Notify* old; -#line 131 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - g_return_if_fail (G_TYPE_CHECK_VALUE_TYPE (value, TYPE_NOTIFY)); -#line 131 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - old = value->data[0].v_pointer; -#line 131 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - if (v_object) { -#line 131 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - g_return_if_fail (G_TYPE_CHECK_INSTANCE_TYPE (v_object, TYPE_NOTIFY)); -#line 131 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - g_return_if_fail (g_value_type_compatible (G_TYPE_FROM_INSTANCE (v_object), G_VALUE_TYPE (value))); -#line 131 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - value->data[0].v_pointer = v_object; -#line 131 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - notify_ref (value->data[0].v_pointer); -#line 3207 "scanner.c" - } else { -#line 131 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - value->data[0].v_pointer = NULL; -#line 3211 "scanner.c" - } -#line 131 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - if (old) { -#line 131 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - notify_unref (old); -#line 3217 "scanner.c" - } -} - - -void value_take_notify (GValue* value, gpointer v_object) { - Notify* old; -#line 131 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - g_return_if_fail (G_TYPE_CHECK_VALUE_TYPE (value, TYPE_NOTIFY)); -#line 131 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - old = value->data[0].v_pointer; -#line 131 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - if (v_object) { -#line 131 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - g_return_if_fail (G_TYPE_CHECK_INSTANCE_TYPE (v_object, TYPE_NOTIFY)); -#line 131 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - g_return_if_fail (g_value_type_compatible (G_TYPE_FROM_INSTANCE (v_object), G_VALUE_TYPE (value))); -#line 131 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - value->data[0].v_pointer = v_object; -#line 3236 "scanner.c" - } else { -#line 131 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - value->data[0].v_pointer = NULL; -#line 3240 "scanner.c" - } -#line 131 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - if (old) { -#line 131 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - notify_unref (old); -#line 3246 "scanner.c" - } -} - - -static void notify_class_init (NotifyClass * klass) { -#line 131 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - notify_parent_class = g_type_class_peek_parent (klass); -#line 131 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - ((NotifyClass *) klass)->finalize = notify_finalize; -#line 131 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - ((NotifyClass *) klass)->run = (void (*)(Notify*, Scanner*)) notify_real_run; -#line 3258 "scanner.c" -} - - -static void notify_instance_init (Notify * self) { -#line 131 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - self->ref_count = 1; -#line 3265 "scanner.c" -} - - -static void notify_finalize (Notify* obj) { - Notify * self; -#line 131 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - self = G_TYPE_CHECK_INSTANCE_CAST (obj, TYPE_NOTIFY, Notify); -#line 131 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - g_signal_handlers_destroy (self); -#line 3275 "scanner.c" -} - - -GType notify_get_type (void) { - static volatile gsize notify_type_id__volatile = 0; - if (g_once_init_enter (¬ify_type_id__volatile)) { - static const GTypeValueTable g_define_type_value_table = { value_notify_init, value_notify_free_value, value_notify_copy_value, value_notify_peek_pointer, "p", value_notify_collect_value, "p", value_notify_lcopy_value }; - static const GTypeInfo g_define_type_info = { sizeof (NotifyClass), (GBaseInitFunc) NULL, (GBaseFinalizeFunc) NULL, (GClassInitFunc) notify_class_init, (GClassFinalizeFunc) NULL, NULL, sizeof (Notify), 0, (GInstanceInitFunc) notify_instance_init, &g_define_type_value_table }; - static const GTypeFundamentalInfo g_define_type_fundamental_info = { (G_TYPE_FLAG_CLASSED | G_TYPE_FLAG_INSTANTIATABLE | G_TYPE_FLAG_DERIVABLE | G_TYPE_FLAG_DEEP_DERIVABLE) }; - GType notify_type_id; - notify_type_id = g_type_register_fundamental (g_type_fundamental_next (), "Notify", &g_define_type_info, &g_define_type_fundamental_info, 0); - g_once_init_leave (¬ify_type_id__volatile, notify_type_id); - } - return notify_type_id__volatile; -} - - -gpointer notify_ref (gpointer instance) { - Notify* self; - self = instance; -#line 131 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - g_atomic_int_inc (&self->ref_count); -#line 131 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - return instance; -#line 3300 "scanner.c" -} - - -void notify_unref (gpointer instance) { - Notify* self; - self = instance; -#line 131 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - if (g_atomic_int_dec_and_test (&self->ref_count)) { -#line 131 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - NOTIFY_GET_CLASS (self)->finalize (self); -#line 131 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - g_type_free_instance ((GTypeInstance *) self); -#line 3313 "scanner.c" - } -} - - -static void notify_scanning_changed_real_run (Notify* base, Scanner* scanner) { - NotifyScanningChanged * self; - Scanner* _tmp0_ = NULL; -#line 138 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - self = (NotifyScanningChanged*) base; -#line 138 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - g_return_if_fail (scanner != NULL); -#line 138 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp0_ = scanner; -#line 138 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - g_signal_emit_by_name (_tmp0_, "scanning-changed"); -#line 3329 "scanner.c" -} - - -NotifyScanningChanged* notify_scanning_changed_construct (GType object_type) { - NotifyScanningChanged* self = NULL; -#line 136 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - self = (NotifyScanningChanged*) notify_construct (object_type); -#line 136 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - return self; -#line 3339 "scanner.c" -} - - -NotifyScanningChanged* notify_scanning_changed_new (void) { -#line 136 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - return notify_scanning_changed_construct (TYPE_NOTIFY_SCANNING_CHANGED); -#line 3346 "scanner.c" -} - - -static void notify_scanning_changed_class_init (NotifyScanningChangedClass * klass) { -#line 136 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - notify_scanning_changed_parent_class = g_type_class_peek_parent (klass); -#line 136 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - ((NotifyClass *) klass)->run = (void (*)(Notify*, Scanner*)) notify_scanning_changed_real_run; -#line 3355 "scanner.c" -} - - -static void notify_scanning_changed_instance_init (NotifyScanningChanged * self) { -} - - -GType notify_scanning_changed_get_type (void) { - static volatile gsize notify_scanning_changed_type_id__volatile = 0; - if (g_once_init_enter (¬ify_scanning_changed_type_id__volatile)) { - static const GTypeInfo g_define_type_info = { sizeof (NotifyScanningChangedClass), (GBaseInitFunc) NULL, (GBaseFinalizeFunc) NULL, (GClassInitFunc) notify_scanning_changed_class_init, (GClassFinalizeFunc) NULL, NULL, sizeof (NotifyScanningChanged), 0, (GInstanceInitFunc) notify_scanning_changed_instance_init, NULL }; - GType notify_scanning_changed_type_id; - notify_scanning_changed_type_id = g_type_register_static (TYPE_NOTIFY, "NotifyScanningChanged", &g_define_type_info, 0); - g_once_init_leave (¬ify_scanning_changed_type_id__volatile, notify_scanning_changed_type_id); - } - return notify_scanning_changed_type_id__volatile; -} - - -static void _scan_device_unref0_ (gpointer var) { -#line 144 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - (var == NULL) ? NULL : (var = (scan_device_unref (var), NULL)); -#line 3378 "scanner.c" -} - - -static void _g_list_free__scan_device_unref0_ (GList* self) { -#line 144 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - g_list_foreach (self, (GFunc) _scan_device_unref0_, NULL); -#line 144 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - g_list_free (self); -#line 3387 "scanner.c" -} - - -NotifyUpdateDevices* notify_update_devices_construct (GType object_type, GList* devices) { - NotifyUpdateDevices* self = NULL; - GList* _tmp0_ = NULL; -#line 143 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - self = (NotifyUpdateDevices*) notify_construct (object_type); -#line 143 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp0_ = devices; -#line 143 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - devices = NULL; -#line 143 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - __g_list_free__scan_device_unref0_0 (self->priv->devices); -#line 143 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - self->priv->devices = _tmp0_; -#line 143 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - __g_list_free__scan_device_unref0_0 (devices); -#line 143 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - return self; -#line 3408 "scanner.c" -} - - -NotifyUpdateDevices* notify_update_devices_new (GList* devices) { -#line 143 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - return notify_update_devices_construct (TYPE_NOTIFY_UPDATE_DEVICES, devices); -#line 3415 "scanner.c" -} - - -static void notify_update_devices_real_run (Notify* base, Scanner* scanner) { - NotifyUpdateDevices * self; - Scanner* _tmp0_ = NULL; - GList* _tmp1_ = NULL; -#line 145 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - self = (NotifyUpdateDevices*) base; -#line 145 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - g_return_if_fail (scanner != NULL); -#line 145 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp0_ = scanner; -#line 145 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp1_ = self->priv->devices; -#line 145 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - g_signal_emit_by_name (_tmp0_, "update-devices", _tmp1_); -#line 3433 "scanner.c" -} - - -static void notify_update_devices_class_init (NotifyUpdateDevicesClass * klass) { -#line 141 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - notify_update_devices_parent_class = g_type_class_peek_parent (klass); -#line 141 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - ((NotifyClass *) klass)->finalize = notify_update_devices_finalize; -#line 141 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - g_type_class_add_private (klass, sizeof (NotifyUpdateDevicesPrivate)); -#line 141 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - ((NotifyClass *) klass)->run = (void (*)(Notify*, Scanner*)) notify_update_devices_real_run; -#line 3446 "scanner.c" -} - - -static void notify_update_devices_instance_init (NotifyUpdateDevices * self) { -#line 141 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - self->priv = NOTIFY_UPDATE_DEVICES_GET_PRIVATE (self); -#line 3453 "scanner.c" -} - - -static void notify_update_devices_finalize (Notify* obj) { - NotifyUpdateDevices * self; -#line 141 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - self = G_TYPE_CHECK_INSTANCE_CAST (obj, TYPE_NOTIFY_UPDATE_DEVICES, NotifyUpdateDevices); -#line 144 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - __g_list_free__scan_device_unref0_0 (self->priv->devices); -#line 141 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - NOTIFY_CLASS (notify_update_devices_parent_class)->finalize (obj); -#line 3465 "scanner.c" -} - - -GType notify_update_devices_get_type (void) { - static volatile gsize notify_update_devices_type_id__volatile = 0; - if (g_once_init_enter (¬ify_update_devices_type_id__volatile)) { - static const GTypeInfo g_define_type_info = { sizeof (NotifyUpdateDevicesClass), (GBaseInitFunc) NULL, (GBaseFinalizeFunc) NULL, (GClassInitFunc) notify_update_devices_class_init, (GClassFinalizeFunc) NULL, NULL, sizeof (NotifyUpdateDevices), 0, (GInstanceInitFunc) notify_update_devices_instance_init, NULL }; - GType notify_update_devices_type_id; - notify_update_devices_type_id = g_type_register_static (TYPE_NOTIFY, "NotifyUpdateDevices", &g_define_type_info, 0); - g_once_init_leave (¬ify_update_devices_type_id__volatile, notify_update_devices_type_id); - } - return notify_update_devices_type_id__volatile; -} - - -NotifyRequestAuthorization* notify_request_authorization_construct (GType object_type, const gchar* resource) { - NotifyRequestAuthorization* self = NULL; - const gchar* _tmp0_ = NULL; - gchar* _tmp1_ = NULL; -#line 150 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - g_return_val_if_fail (resource != NULL, NULL); -#line 150 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - self = (NotifyRequestAuthorization*) notify_construct (object_type); -#line 150 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp0_ = resource; -#line 150 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp1_ = g_strdup (_tmp0_); -#line 150 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _g_free0 (self->priv->resource); -#line 150 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - self->priv->resource = _tmp1_; -#line 150 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - return self; -#line 3499 "scanner.c" -} - - -NotifyRequestAuthorization* notify_request_authorization_new (const gchar* resource) { -#line 150 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - return notify_request_authorization_construct (TYPE_NOTIFY_REQUEST_AUTHORIZATION, resource); -#line 3506 "scanner.c" -} - - -static void notify_request_authorization_real_run (Notify* base, Scanner* scanner) { - NotifyRequestAuthorization * self; - Scanner* _tmp0_ = NULL; - const gchar* _tmp1_ = NULL; -#line 152 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - self = (NotifyRequestAuthorization*) base; -#line 152 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - g_return_if_fail (scanner != NULL); -#line 152 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp0_ = scanner; -#line 152 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp1_ = self->priv->resource; -#line 152 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - g_signal_emit_by_name (_tmp0_, "request-authorization", _tmp1_); -#line 3524 "scanner.c" -} - - -static void notify_request_authorization_class_init (NotifyRequestAuthorizationClass * klass) { -#line 148 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - notify_request_authorization_parent_class = g_type_class_peek_parent (klass); -#line 148 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - ((NotifyClass *) klass)->finalize = notify_request_authorization_finalize; -#line 148 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - g_type_class_add_private (klass, sizeof (NotifyRequestAuthorizationPrivate)); -#line 148 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - ((NotifyClass *) klass)->run = (void (*)(Notify*, Scanner*)) notify_request_authorization_real_run; -#line 3537 "scanner.c" -} - - -static void notify_request_authorization_instance_init (NotifyRequestAuthorization * self) { -#line 148 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - self->priv = NOTIFY_REQUEST_AUTHORIZATION_GET_PRIVATE (self); -#line 3544 "scanner.c" -} - - -static void notify_request_authorization_finalize (Notify* obj) { - NotifyRequestAuthorization * self; -#line 148 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - self = G_TYPE_CHECK_INSTANCE_CAST (obj, TYPE_NOTIFY_REQUEST_AUTHORIZATION, NotifyRequestAuthorization); -#line 151 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _g_free0 (self->priv->resource); -#line 148 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - NOTIFY_CLASS (notify_request_authorization_parent_class)->finalize (obj); -#line 3556 "scanner.c" -} - - -GType notify_request_authorization_get_type (void) { - static volatile gsize notify_request_authorization_type_id__volatile = 0; - if (g_once_init_enter (¬ify_request_authorization_type_id__volatile)) { - static const GTypeInfo g_define_type_info = { sizeof (NotifyRequestAuthorizationClass), (GBaseInitFunc) NULL, (GBaseFinalizeFunc) NULL, (GClassInitFunc) notify_request_authorization_class_init, (GClassFinalizeFunc) NULL, NULL, sizeof (NotifyRequestAuthorization), 0, (GInstanceInitFunc) notify_request_authorization_instance_init, NULL }; - GType notify_request_authorization_type_id; - notify_request_authorization_type_id = g_type_register_static (TYPE_NOTIFY, "NotifyRequestAuthorization", &g_define_type_info, 0); - g_once_init_leave (¬ify_request_authorization_type_id__volatile, notify_request_authorization_type_id); - } - return notify_request_authorization_type_id__volatile; -} - - -NotifyScanFailed* notify_scan_failed_construct (GType object_type, gint error_code, const gchar* error_string) { - NotifyScanFailed* self = NULL; - gint _tmp0_ = 0; - const gchar* _tmp1_ = NULL; - gchar* _tmp2_ = NULL; -#line 157 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - g_return_val_if_fail (error_string != NULL, NULL); -#line 157 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - self = (NotifyScanFailed*) notify_construct (object_type); -#line 157 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp0_ = error_code; -#line 157 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - self->priv->error_code = _tmp0_; -#line 157 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp1_ = error_string; -#line 157 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp2_ = g_strdup (_tmp1_); -#line 157 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _g_free0 (self->priv->error_string); -#line 157 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - self->priv->error_string = _tmp2_; -#line 157 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - return self; -#line 3595 "scanner.c" -} - - -NotifyScanFailed* notify_scan_failed_new (gint error_code, const gchar* error_string) { -#line 157 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - return notify_scan_failed_construct (TYPE_NOTIFY_SCAN_FAILED, error_code, error_string); -#line 3602 "scanner.c" -} - - -static void notify_scan_failed_real_run (Notify* base, Scanner* scanner) { - NotifyScanFailed * self; - Scanner* _tmp0_ = NULL; - gint _tmp1_ = 0; - const gchar* _tmp2_ = NULL; -#line 160 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - self = (NotifyScanFailed*) base; -#line 160 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - g_return_if_fail (scanner != NULL); -#line 160 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp0_ = scanner; -#line 160 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp1_ = self->priv->error_code; -#line 160 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp2_ = self->priv->error_string; -#line 160 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - g_signal_emit_by_name (_tmp0_, "scan-failed", _tmp1_, _tmp2_); -#line 3623 "scanner.c" -} - - -static void notify_scan_failed_class_init (NotifyScanFailedClass * klass) { -#line 155 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - notify_scan_failed_parent_class = g_type_class_peek_parent (klass); -#line 155 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - ((NotifyClass *) klass)->finalize = notify_scan_failed_finalize; -#line 155 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - g_type_class_add_private (klass, sizeof (NotifyScanFailedPrivate)); -#line 155 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - ((NotifyClass *) klass)->run = (void (*)(Notify*, Scanner*)) notify_scan_failed_real_run; -#line 3636 "scanner.c" -} - - -static void notify_scan_failed_instance_init (NotifyScanFailed * self) { -#line 155 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - self->priv = NOTIFY_SCAN_FAILED_GET_PRIVATE (self); -#line 3643 "scanner.c" -} - - -static void notify_scan_failed_finalize (Notify* obj) { - NotifyScanFailed * self; -#line 155 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - self = G_TYPE_CHECK_INSTANCE_CAST (obj, TYPE_NOTIFY_SCAN_FAILED, NotifyScanFailed); -#line 159 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _g_free0 (self->priv->error_string); -#line 155 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - NOTIFY_CLASS (notify_scan_failed_parent_class)->finalize (obj); -#line 3655 "scanner.c" -} - - -GType notify_scan_failed_get_type (void) { - static volatile gsize notify_scan_failed_type_id__volatile = 0; - if (g_once_init_enter (¬ify_scan_failed_type_id__volatile)) { - static const GTypeInfo g_define_type_info = { sizeof (NotifyScanFailedClass), (GBaseInitFunc) NULL, (GBaseFinalizeFunc) NULL, (GClassInitFunc) notify_scan_failed_class_init, (GClassFinalizeFunc) NULL, NULL, sizeof (NotifyScanFailed), 0, (GInstanceInitFunc) notify_scan_failed_instance_init, NULL }; - GType notify_scan_failed_type_id; - notify_scan_failed_type_id = g_type_register_static (TYPE_NOTIFY, "NotifyScanFailed", &g_define_type_info, 0); - g_once_init_leave (¬ify_scan_failed_type_id__volatile, notify_scan_failed_type_id); - } - return notify_scan_failed_type_id__volatile; -} - - -static void notify_document_done_real_run (Notify* base, Scanner* scanner) { - NotifyDocumentDone * self; - Scanner* _tmp0_ = NULL; -#line 165 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - self = (NotifyDocumentDone*) base; -#line 165 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - g_return_if_fail (scanner != NULL); -#line 165 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp0_ = scanner; -#line 165 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - g_signal_emit_by_name (_tmp0_, "document-done"); -#line 3682 "scanner.c" -} - - -NotifyDocumentDone* notify_document_done_construct (GType object_type) { - NotifyDocumentDone* self = NULL; -#line 163 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - self = (NotifyDocumentDone*) notify_construct (object_type); -#line 163 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - return self; -#line 3692 "scanner.c" -} - - -NotifyDocumentDone* notify_document_done_new (void) { -#line 163 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - return notify_document_done_construct (TYPE_NOTIFY_DOCUMENT_DONE); -#line 3699 "scanner.c" -} - - -static void notify_document_done_class_init (NotifyDocumentDoneClass * klass) { -#line 163 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - notify_document_done_parent_class = g_type_class_peek_parent (klass); -#line 163 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - ((NotifyClass *) klass)->run = (void (*)(Notify*, Scanner*)) notify_document_done_real_run; -#line 3708 "scanner.c" -} - - -static void notify_document_done_instance_init (NotifyDocumentDone * self) { -} - - -GType notify_document_done_get_type (void) { - static volatile gsize notify_document_done_type_id__volatile = 0; - if (g_once_init_enter (¬ify_document_done_type_id__volatile)) { - static const GTypeInfo g_define_type_info = { sizeof (NotifyDocumentDoneClass), (GBaseInitFunc) NULL, (GBaseFinalizeFunc) NULL, (GClassInitFunc) notify_document_done_class_init, (GClassFinalizeFunc) NULL, NULL, sizeof (NotifyDocumentDone), 0, (GInstanceInitFunc) notify_document_done_instance_init, NULL }; - GType notify_document_done_type_id; - notify_document_done_type_id = g_type_register_static (TYPE_NOTIFY, "NotifyDocumentDone", &g_define_type_info, 0); - g_once_init_leave (¬ify_document_done_type_id__volatile, notify_document_done_type_id); - } - return notify_document_done_type_id__volatile; -} - - -static void notify_expect_page_real_run (Notify* base, Scanner* scanner) { - NotifyExpectPage * self; - Scanner* _tmp0_ = NULL; -#line 170 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - self = (NotifyExpectPage*) base; -#line 170 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - g_return_if_fail (scanner != NULL); -#line 170 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp0_ = scanner; -#line 170 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - g_signal_emit_by_name (_tmp0_, "expect-page"); -#line 3739 "scanner.c" -} - - -NotifyExpectPage* notify_expect_page_construct (GType object_type) { - NotifyExpectPage* self = NULL; -#line 168 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - self = (NotifyExpectPage*) notify_construct (object_type); -#line 168 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - return self; -#line 3749 "scanner.c" -} - - -NotifyExpectPage* notify_expect_page_new (void) { -#line 168 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - return notify_expect_page_construct (TYPE_NOTIFY_EXPECT_PAGE); -#line 3756 "scanner.c" -} - - -static void notify_expect_page_class_init (NotifyExpectPageClass * klass) { -#line 168 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - notify_expect_page_parent_class = g_type_class_peek_parent (klass); -#line 168 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - ((NotifyClass *) klass)->run = (void (*)(Notify*, Scanner*)) notify_expect_page_real_run; -#line 3765 "scanner.c" -} - - -static void notify_expect_page_instance_init (NotifyExpectPage * self) { -} - - -GType notify_expect_page_get_type (void) { - static volatile gsize notify_expect_page_type_id__volatile = 0; - if (g_once_init_enter (¬ify_expect_page_type_id__volatile)) { - static const GTypeInfo g_define_type_info = { sizeof (NotifyExpectPageClass), (GBaseInitFunc) NULL, (GBaseFinalizeFunc) NULL, (GClassInitFunc) notify_expect_page_class_init, (GClassFinalizeFunc) NULL, NULL, sizeof (NotifyExpectPage), 0, (GInstanceInitFunc) notify_expect_page_instance_init, NULL }; - GType notify_expect_page_type_id; - notify_expect_page_type_id = g_type_register_static (TYPE_NOTIFY, "NotifyExpectPage", &g_define_type_info, 0); - g_once_init_leave (¬ify_expect_page_type_id__volatile, notify_expect_page_type_id); - } - return notify_expect_page_type_id__volatile; -} - - -static gpointer _scan_page_info_ref0 (gpointer self) { -#line 175 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - return self ? scan_page_info_ref (self) : NULL; -#line 3788 "scanner.c" -} - - -NotifyGotPageInfo* notify_got_page_info_construct (GType object_type, gint job_id, ScanPageInfo* info) { - NotifyGotPageInfo* self = NULL; - gint _tmp0_ = 0; - ScanPageInfo* _tmp1_ = NULL; - ScanPageInfo* _tmp2_ = NULL; -#line 175 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - g_return_val_if_fail (info != NULL, NULL); -#line 175 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - self = (NotifyGotPageInfo*) notify_construct (object_type); -#line 175 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp0_ = job_id; -#line 175 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - self->priv->job_id = _tmp0_; -#line 175 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp1_ = info; -#line 175 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp2_ = _scan_page_info_ref0 (_tmp1_); -#line 175 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _scan_page_info_unref0 (self->priv->info); -#line 175 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - self->priv->info = _tmp2_; -#line 175 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - return self; -#line 3815 "scanner.c" -} - - -NotifyGotPageInfo* notify_got_page_info_new (gint job_id, ScanPageInfo* info) { -#line 175 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - return notify_got_page_info_construct (TYPE_NOTIFY_GOT_PAGE_INFO, job_id, info); -#line 3822 "scanner.c" -} - - -static void notify_got_page_info_real_run (Notify* base, Scanner* scanner) { - NotifyGotPageInfo * self; - gboolean _tmp0_ = FALSE; - gint _tmp1_ = 0; - Scanner* _tmp2_ = NULL; - gint _tmp3_ = 0; -#line 178 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - self = (NotifyGotPageInfo*) base; -#line 178 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - g_return_if_fail (scanner != NULL); -#line 180 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp1_ = self->priv->job_id; -#line 180 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp2_ = scanner; -#line 180 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp3_ = _tmp2_->first_job_id; -#line 180 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - if (_tmp1_ >= _tmp3_) { -#line 3844 "scanner.c" - gint _tmp4_ = 0; - Scanner* _tmp5_ = NULL; - gint _tmp6_ = 0; -#line 180 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp4_ = self->priv->job_id; -#line 180 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp5_ = scanner; -#line 180 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp6_ = _tmp5_->job_id; -#line 180 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp0_ = _tmp4_ < _tmp6_; -#line 3856 "scanner.c" - } else { -#line 180 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp0_ = FALSE; -#line 3860 "scanner.c" - } -#line 180 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - if (_tmp0_) { -#line 3864 "scanner.c" - Scanner* _tmp7_ = NULL; - ScanPageInfo* _tmp8_ = NULL; -#line 181 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp7_ = scanner; -#line 181 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp8_ = self->priv->info; -#line 181 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - g_signal_emit_by_name (_tmp7_, "got-page-info", _tmp8_); -#line 3873 "scanner.c" - } -} - - -static void notify_got_page_info_class_init (NotifyGotPageInfoClass * klass) { -#line 173 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - notify_got_page_info_parent_class = g_type_class_peek_parent (klass); -#line 173 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - ((NotifyClass *) klass)->finalize = notify_got_page_info_finalize; -#line 173 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - g_type_class_add_private (klass, sizeof (NotifyGotPageInfoPrivate)); -#line 173 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - ((NotifyClass *) klass)->run = (void (*)(Notify*, Scanner*)) notify_got_page_info_real_run; -#line 3887 "scanner.c" -} - - -static void notify_got_page_info_instance_init (NotifyGotPageInfo * self) { -#line 173 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - self->priv = NOTIFY_GOT_PAGE_INFO_GET_PRIVATE (self); -#line 3894 "scanner.c" -} - - -static void notify_got_page_info_finalize (Notify* obj) { - NotifyGotPageInfo * self; -#line 173 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - self = G_TYPE_CHECK_INSTANCE_CAST (obj, TYPE_NOTIFY_GOT_PAGE_INFO, NotifyGotPageInfo); -#line 177 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _scan_page_info_unref0 (self->priv->info); -#line 173 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - NOTIFY_CLASS (notify_got_page_info_parent_class)->finalize (obj); -#line 3906 "scanner.c" -} - - -GType notify_got_page_info_get_type (void) { - static volatile gsize notify_got_page_info_type_id__volatile = 0; - if (g_once_init_enter (¬ify_got_page_info_type_id__volatile)) { - static const GTypeInfo g_define_type_info = { sizeof (NotifyGotPageInfoClass), (GBaseInitFunc) NULL, (GBaseFinalizeFunc) NULL, (GClassInitFunc) notify_got_page_info_class_init, (GClassFinalizeFunc) NULL, NULL, sizeof (NotifyGotPageInfo), 0, (GInstanceInitFunc) notify_got_page_info_instance_init, NULL }; - GType notify_got_page_info_type_id; - notify_got_page_info_type_id = g_type_register_static (TYPE_NOTIFY, "NotifyGotPageInfo", &g_define_type_info, 0); - g_once_init_leave (¬ify_got_page_info_type_id__volatile, notify_got_page_info_type_id); - } - return notify_got_page_info_type_id__volatile; -} - - -NotifyPageDone* notify_page_done_construct (GType object_type, gint job_id) { - NotifyPageDone* self = NULL; - gint _tmp0_ = 0; -#line 187 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - self = (NotifyPageDone*) notify_construct (object_type); -#line 187 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp0_ = job_id; -#line 187 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - self->priv->job_id = _tmp0_; -#line 187 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - return self; -#line 3933 "scanner.c" -} - - -NotifyPageDone* notify_page_done_new (gint job_id) { -#line 187 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - return notify_page_done_construct (TYPE_NOTIFY_PAGE_DONE, job_id); -#line 3940 "scanner.c" -} - - -static void notify_page_done_real_run (Notify* base, Scanner* scanner) { - NotifyPageDone * self; - gboolean _tmp0_ = FALSE; - gint _tmp1_ = 0; - Scanner* _tmp2_ = NULL; - gint _tmp3_ = 0; -#line 189 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - self = (NotifyPageDone*) base; -#line 189 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - g_return_if_fail (scanner != NULL); -#line 191 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp1_ = self->priv->job_id; -#line 191 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp2_ = scanner; -#line 191 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp3_ = _tmp2_->first_job_id; -#line 191 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - if (_tmp1_ >= _tmp3_) { -#line 3962 "scanner.c" - gint _tmp4_ = 0; - Scanner* _tmp5_ = NULL; - gint _tmp6_ = 0; -#line 191 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp4_ = self->priv->job_id; -#line 191 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp5_ = scanner; -#line 191 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp6_ = _tmp5_->job_id; -#line 191 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp0_ = _tmp4_ < _tmp6_; -#line 3974 "scanner.c" - } else { -#line 191 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp0_ = FALSE; -#line 3978 "scanner.c" - } -#line 191 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - if (_tmp0_) { -#line 3982 "scanner.c" - Scanner* _tmp7_ = NULL; -#line 192 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp7_ = scanner; -#line 192 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - g_signal_emit_by_name (_tmp7_, "page-done"); -#line 3988 "scanner.c" - } -} - - -static void notify_page_done_class_init (NotifyPageDoneClass * klass) { -#line 185 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - notify_page_done_parent_class = g_type_class_peek_parent (klass); -#line 185 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - ((NotifyClass *) klass)->finalize = notify_page_done_finalize; -#line 185 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - g_type_class_add_private (klass, sizeof (NotifyPageDonePrivate)); -#line 185 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - ((NotifyClass *) klass)->run = (void (*)(Notify*, Scanner*)) notify_page_done_real_run; -#line 4002 "scanner.c" -} - - -static void notify_page_done_instance_init (NotifyPageDone * self) { -#line 185 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - self->priv = NOTIFY_PAGE_DONE_GET_PRIVATE (self); -#line 4009 "scanner.c" -} - - -static void notify_page_done_finalize (Notify* obj) { - NotifyPageDone * self; -#line 185 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - self = G_TYPE_CHECK_INSTANCE_CAST (obj, TYPE_NOTIFY_PAGE_DONE, NotifyPageDone); -#line 185 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - NOTIFY_CLASS (notify_page_done_parent_class)->finalize (obj); -#line 4019 "scanner.c" -} - - -GType notify_page_done_get_type (void) { - static volatile gsize notify_page_done_type_id__volatile = 0; - if (g_once_init_enter (¬ify_page_done_type_id__volatile)) { - static const GTypeInfo g_define_type_info = { sizeof (NotifyPageDoneClass), (GBaseInitFunc) NULL, (GBaseFinalizeFunc) NULL, (GClassInitFunc) notify_page_done_class_init, (GClassFinalizeFunc) NULL, NULL, sizeof (NotifyPageDone), 0, (GInstanceInitFunc) notify_page_done_instance_init, NULL }; - GType notify_page_done_type_id; - notify_page_done_type_id = g_type_register_static (TYPE_NOTIFY, "NotifyPageDone", &g_define_type_info, 0); - g_once_init_leave (¬ify_page_done_type_id__volatile, notify_page_done_type_id); - } - return notify_page_done_type_id__volatile; -} - - -static gpointer _scan_line_ref0 (gpointer self) { -#line 198 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - return self ? scan_line_ref (self) : NULL; -#line 4038 "scanner.c" -} - - -NotifyGotLine* notify_got_line_construct (GType object_type, gint job_id, ScanLine* line) { - NotifyGotLine* self = NULL; - gint _tmp0_ = 0; - ScanLine* _tmp1_ = NULL; - ScanLine* _tmp2_ = NULL; -#line 198 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - g_return_val_if_fail (line != NULL, NULL); -#line 198 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - self = (NotifyGotLine*) notify_construct (object_type); -#line 198 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp0_ = job_id; -#line 198 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - self->priv->job_id = _tmp0_; -#line 198 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp1_ = line; -#line 198 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp2_ = _scan_line_ref0 (_tmp1_); -#line 198 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _scan_line_unref0 (self->priv->line); -#line 198 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - self->priv->line = _tmp2_; -#line 198 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - return self; -#line 4065 "scanner.c" -} - - -NotifyGotLine* notify_got_line_new (gint job_id, ScanLine* line) { -#line 198 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - return notify_got_line_construct (TYPE_NOTIFY_GOT_LINE, job_id, line); -#line 4072 "scanner.c" -} - - -static void notify_got_line_real_run (Notify* base, Scanner* scanner) { - NotifyGotLine * self; - gboolean _tmp0_ = FALSE; - gint _tmp1_ = 0; - Scanner* _tmp2_ = NULL; - gint _tmp3_ = 0; -#line 201 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - self = (NotifyGotLine*) base; -#line 201 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - g_return_if_fail (scanner != NULL); -#line 203 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp1_ = self->priv->job_id; -#line 203 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp2_ = scanner; -#line 203 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp3_ = _tmp2_->first_job_id; -#line 203 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - if (_tmp1_ >= _tmp3_) { -#line 4094 "scanner.c" - gint _tmp4_ = 0; - Scanner* _tmp5_ = NULL; - gint _tmp6_ = 0; -#line 203 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp4_ = self->priv->job_id; -#line 203 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp5_ = scanner; -#line 203 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp6_ = _tmp5_->job_id; -#line 203 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp0_ = _tmp4_ < _tmp6_; -#line 4106 "scanner.c" - } else { -#line 203 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp0_ = FALSE; -#line 4110 "scanner.c" - } -#line 203 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - if (_tmp0_) { -#line 4114 "scanner.c" - Scanner* _tmp7_ = NULL; - ScanLine* _tmp8_ = NULL; -#line 204 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp7_ = scanner; -#line 204 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp8_ = self->priv->line; -#line 204 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - g_signal_emit_by_name (_tmp7_, "got-line", _tmp8_); -#line 4123 "scanner.c" - } -} - - -static void notify_got_line_class_init (NotifyGotLineClass * klass) { -#line 196 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - notify_got_line_parent_class = g_type_class_peek_parent (klass); -#line 196 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - ((NotifyClass *) klass)->finalize = notify_got_line_finalize; -#line 196 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - g_type_class_add_private (klass, sizeof (NotifyGotLinePrivate)); -#line 196 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - ((NotifyClass *) klass)->run = (void (*)(Notify*, Scanner*)) notify_got_line_real_run; -#line 4137 "scanner.c" -} - - -static void notify_got_line_instance_init (NotifyGotLine * self) { -#line 196 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - self->priv = NOTIFY_GOT_LINE_GET_PRIVATE (self); -#line 4144 "scanner.c" -} - - -static void notify_got_line_finalize (Notify* obj) { - NotifyGotLine * self; -#line 196 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - self = G_TYPE_CHECK_INSTANCE_CAST (obj, TYPE_NOTIFY_GOT_LINE, NotifyGotLine); -#line 200 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _scan_line_unref0 (self->priv->line); -#line 196 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - NOTIFY_CLASS (notify_got_line_parent_class)->finalize (obj); -#line 4156 "scanner.c" -} - - -GType notify_got_line_get_type (void) { - static volatile gsize notify_got_line_type_id__volatile = 0; - if (g_once_init_enter (¬ify_got_line_type_id__volatile)) { - static const GTypeInfo g_define_type_info = { sizeof (NotifyGotLineClass), (GBaseInitFunc) NULL, (GBaseFinalizeFunc) NULL, (GClassInitFunc) notify_got_line_class_init, (GClassFinalizeFunc) NULL, NULL, sizeof (NotifyGotLine), 0, (GInstanceInitFunc) notify_got_line_instance_init, NULL }; - GType notify_got_line_type_id; - notify_got_line_type_id = g_type_register_static (TYPE_NOTIFY, "NotifyGotLine", &g_define_type_info, 0); - g_once_init_leave (¬ify_got_line_type_id__volatile, notify_got_line_type_id); - } - return notify_got_line_type_id__volatile; -} - - -static void _scan_job_unref0_ (gpointer var) { -#line 234 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - (var == NULL) ? NULL : (var = (scan_job_unref (var), NULL)); -#line 4175 "scanner.c" -} - - -static void _g_list_free__scan_job_unref0_ (GList* self) { -#line 234 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - g_list_foreach (self, (GFunc) _scan_job_unref0_, NULL); -#line 234 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - g_list_free (self); -#line 4184 "scanner.c" -} - - -static void _request_unref0_ (gpointer var) { -#line 273 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - (var == NULL) ? NULL : (var = (request_unref (var), NULL)); -#line 4191 "scanner.c" -} - - -static void _notify_unref0_ (gpointer var) { -#line 274 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - (var == NULL) ? NULL : (var = (notify_unref (var), NULL)); -#line 4198 "scanner.c" -} - - -static void _credentials_unref0_ (gpointer var) { -#line 275 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - (var == NULL) ? NULL : (var = (credentials_unref (var), NULL)); -#line 4205 "scanner.c" -} - - -static Scanner* scanner_construct (GType object_type) { - Scanner* self = NULL; - GAsyncQueue* _tmp0_ = NULL; - GAsyncQueue* _tmp1_ = NULL; - GAsyncQueue* _tmp2_ = NULL; -#line 271 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - self = (Scanner*) g_type_create_instance (object_type); -#line 273 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp0_ = g_async_queue_new_full (_request_unref0_); -#line 273 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _g_async_queue_unref0 (self->priv->request_queue); -#line 273 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - self->priv->request_queue = _tmp0_; -#line 274 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp1_ = g_async_queue_new_full (_notify_unref0_); -#line 274 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _g_async_queue_unref0 (self->priv->notify_queue); -#line 274 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - self->priv->notify_queue = _tmp1_; -#line 275 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp2_ = g_async_queue_new_full (_credentials_unref0_); -#line 275 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _g_async_queue_unref0 (self->priv->authorize_queue); -#line 275 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - self->priv->authorize_queue = _tmp2_; -#line 271 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - return self; -#line 4236 "scanner.c" -} - - -static Scanner* scanner_new (void) { -#line 271 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - return scanner_construct (TYPE_SCANNER); -#line 4243 "scanner.c" -} - - -static gpointer _scanner_ref0 (gpointer self) { -#line 282 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - return self ? scanner_ref (self) : NULL; -#line 4250 "scanner.c" -} - - -Scanner* scanner_get_instance (void) { - Scanner* result = NULL; - Scanner* _tmp0_ = NULL; - Scanner* _tmp2_ = NULL; - Scanner* _tmp3_ = NULL; -#line 280 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp0_ = scanner_scanner_object; -#line 280 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - if (_tmp0_ == NULL) { -#line 4263 "scanner.c" - Scanner* _tmp1_ = NULL; -#line 281 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp1_ = scanner_new (); -#line 281 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _scanner_unref0 (scanner_scanner_object); -#line 281 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - scanner_scanner_object = _tmp1_; -#line 4271 "scanner.c" - } -#line 282 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp2_ = scanner_scanner_object; -#line 282 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp3_ = _scanner_ref0 (_tmp2_); -#line 282 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - result = _tmp3_; -#line 282 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - return result; -#line 4281 "scanner.c" -} - - -static gboolean scanner_notify_idle_cb (Scanner* self) { - gboolean result = FALSE; - Notify* notification = NULL; - GAsyncQueue* _tmp0_ = NULL; - gpointer _tmp1_ = NULL; -#line 285 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - g_return_val_if_fail (self != NULL, FALSE); -#line 287 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp0_ = self->priv->notify_queue; -#line 287 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp1_ = g_async_queue_pop (_tmp0_); -#line 287 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - notification = (Notify*) _tmp1_; -#line 288 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - notify_run (notification, self); -#line 289 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - result = FALSE; -#line 289 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _notify_unref0 (notification); -#line 289 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - return result; -#line 4306 "scanner.c" -} - - -static gpointer _notify_ref0 (gpointer self) { -#line 294 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - return self ? notify_ref (self) : NULL; -#line 4313 "scanner.c" -} - - -static gboolean _scanner_notify_idle_cb_gsource_func (gpointer self) { - gboolean result; - result = scanner_notify_idle_cb ((Scanner*) self); -#line 295 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - return result; -#line 4322 "scanner.c" -} - - -static void scanner_notify (Scanner* self, Notify* notification) { - GAsyncQueue* _tmp0_ = NULL; - Notify* _tmp1_ = NULL; - Notify* _tmp2_ = NULL; -#line 292 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - g_return_if_fail (self != NULL); -#line 292 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - g_return_if_fail (notification != NULL); -#line 294 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp0_ = self->priv->notify_queue; -#line 294 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp1_ = notification; -#line 294 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp2_ = _notify_ref0 (_tmp1_); -#line 294 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - g_async_queue_push (_tmp0_, _tmp2_); -#line 295 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - g_idle_add_full (G_PRIORITY_DEFAULT_IDLE, _scanner_notify_idle_cb_gsource_func, scanner_ref (self), scanner_unref); -#line 4344 "scanner.c" -} - - -static void scanner_set_scanning (Scanner* self, gboolean is_scanning) { - gboolean _tmp0_ = FALSE; - gboolean _tmp1_ = FALSE; - gboolean _tmp2_ = FALSE; -#line 298 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - g_return_if_fail (self != NULL); -#line 300 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp2_ = self->priv->scanning; -#line 300 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - if (_tmp2_) { -#line 4358 "scanner.c" - gboolean _tmp3_ = FALSE; -#line 300 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp3_ = is_scanning; -#line 300 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp1_ = !_tmp3_; -#line 4364 "scanner.c" - } else { -#line 300 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp1_ = FALSE; -#line 4368 "scanner.c" - } -#line 300 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - if (_tmp1_) { -#line 300 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp0_ = TRUE; -#line 4374 "scanner.c" - } else { - gboolean _tmp4_ = FALSE; - gboolean _tmp5_ = FALSE; -#line 300 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp5_ = self->priv->scanning; -#line 300 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - if (!_tmp5_) { -#line 4382 "scanner.c" - gboolean _tmp6_ = FALSE; -#line 300 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp6_ = is_scanning; -#line 300 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp4_ = _tmp6_; -#line 4388 "scanner.c" - } else { -#line 300 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp4_ = FALSE; -#line 4392 "scanner.c" - } -#line 300 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp0_ = _tmp4_; -#line 4396 "scanner.c" - } -#line 300 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - if (_tmp0_) { -#line 4400 "scanner.c" - gboolean _tmp7_ = FALSE; - NotifyScanningChanged* _tmp8_ = NULL; - NotifyScanningChanged* _tmp9_ = NULL; -#line 302 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp7_ = is_scanning; -#line 302 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - self->priv->scanning = _tmp7_; -#line 303 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp8_ = notify_scanning_changed_new (); -#line 303 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp9_ = _tmp8_; -#line 303 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - scanner_notify (self, (Notify*) _tmp9_); -#line 303 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _notify_unref0 (_tmp9_); -#line 4416 "scanner.c" - } -} - - -static gboolean string_contains (const gchar* self, const gchar* needle) { - gboolean result = FALSE; - const gchar* _tmp0_ = NULL; - gchar* _tmp1_ = NULL; -#line 1376 "/usr/share/vala-0.34/vapi/glib-2.0.vapi" - g_return_val_if_fail (self != NULL, FALSE); -#line 1376 "/usr/share/vala-0.34/vapi/glib-2.0.vapi" - g_return_val_if_fail (needle != NULL, FALSE); -#line 1377 "/usr/share/vala-0.34/vapi/glib-2.0.vapi" - _tmp0_ = needle; -#line 1377 "/usr/share/vala-0.34/vapi/glib-2.0.vapi" - _tmp1_ = strstr ((gchar*) self, (gchar*) _tmp0_); -#line 1377 "/usr/share/vala-0.34/vapi/glib-2.0.vapi" - result = _tmp1_ != NULL; -#line 1377 "/usr/share/vala-0.34/vapi/glib-2.0.vapi" - return result; -#line 4437 "scanner.c" -} - - -static gint scanner_get_device_weight (const gchar* device) { - gint result = 0; - const gchar* _tmp0_ = NULL; - gboolean _tmp1_ = FALSE; - const gchar* _tmp2_ = NULL; - gboolean _tmp3_ = FALSE; -#line 307 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - g_return_val_if_fail (device != NULL, 0); -#line 312 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp0_ = device; -#line 312 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp1_ = g_str_has_prefix (_tmp0_, "vfl:"); -#line 312 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - if (_tmp1_) { -#line 313 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - result = 2; -#line 313 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - return result; -#line 4459 "scanner.c" - } -#line 316 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp2_ = device; -#line 316 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp3_ = string_contains (_tmp2_, "usb"); -#line 316 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - if (_tmp3_) { -#line 317 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - result = 0; -#line 317 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - return result; -#line 4471 "scanner.c" - } -#line 319 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - result = 1; -#line 319 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - return result; -#line 4477 "scanner.c" -} - - -static gint scanner_compare_devices (ScanDevice* device1, ScanDevice* device2) { - gint result = 0; - gint weight1 = 0; - ScanDevice* _tmp0_ = NULL; - const gchar* _tmp1_ = NULL; - gint _tmp2_ = 0; - gint weight2 = 0; - ScanDevice* _tmp3_ = NULL; - const gchar* _tmp4_ = NULL; - gint _tmp5_ = 0; - gint _tmp6_ = 0; - gint _tmp7_ = 0; - GCompareFunc _tmp10_ = NULL; - ScanDevice* _tmp11_ = NULL; - const gchar* _tmp12_ = NULL; - ScanDevice* _tmp13_ = NULL; - const gchar* _tmp14_ = NULL; - gint _tmp15_ = 0; -#line 322 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - g_return_val_if_fail (device1 != NULL, 0); -#line 322 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - g_return_val_if_fail (device2 != NULL, 0); -#line 326 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp0_ = device1; -#line 326 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp1_ = _tmp0_->name; -#line 326 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp2_ = scanner_get_device_weight (_tmp1_); -#line 326 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - weight1 = _tmp2_; -#line 327 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp3_ = device2; -#line 327 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp4_ = _tmp3_->name; -#line 327 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp5_ = scanner_get_device_weight (_tmp4_); -#line 327 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - weight2 = _tmp5_; -#line 328 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp6_ = weight1; -#line 328 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp7_ = weight2; -#line 328 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - if (_tmp6_ != _tmp7_) { -#line 4525 "scanner.c" - gint _tmp8_ = 0; - gint _tmp9_ = 0; -#line 329 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp8_ = weight1; -#line 329 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp9_ = weight2; -#line 329 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - result = _tmp8_ - _tmp9_; -#line 329 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - return result; -#line 4536 "scanner.c" - } -#line 331 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp10_ = g_strcmp0; -#line 331 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp11_ = device1; -#line 331 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp12_ = _tmp11_->label; -#line 331 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp13_ = device2; -#line 331 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp14_ = _tmp13_->label; -#line 331 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp15_ = _tmp10_ (_tmp12_, _tmp14_); -#line 331 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - result = _tmp15_; -#line 331 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - return result; -#line 4554 "scanner.c" -} - - -static gchar* sane_status_to_string (SANE_Status status) { - gchar* result = NULL; - SANE_Status _tmp0_ = 0; -#line 54 "/home/bob/bzr/simple-scan/trunk/src/sane.vapi" - _tmp0_ = status; -#line 54 "/home/bob/bzr/simple-scan/trunk/src/sane.vapi" - switch (_tmp0_) { -#line 54 "/home/bob/bzr/simple-scan/trunk/src/sane.vapi" - case SANE_STATUS_GOOD: -#line 4567 "scanner.c" - { - gchar* _tmp1_ = NULL; -#line 57 "/home/bob/bzr/simple-scan/trunk/src/sane.vapi" - _tmp1_ = g_strdup ("SANE_STATUS_GOOD"); -#line 57 "/home/bob/bzr/simple-scan/trunk/src/sane.vapi" - result = _tmp1_; -#line 57 "/home/bob/bzr/simple-scan/trunk/src/sane.vapi" - return result; -#line 4576 "scanner.c" - } -#line 54 "/home/bob/bzr/simple-scan/trunk/src/sane.vapi" - case SANE_STATUS_UNSUPPORTED: -#line 4580 "scanner.c" - { - gchar* _tmp2_ = NULL; -#line 59 "/home/bob/bzr/simple-scan/trunk/src/sane.vapi" - _tmp2_ = g_strdup ("SANE_STATUS_UNSUPPORTED"); -#line 59 "/home/bob/bzr/simple-scan/trunk/src/sane.vapi" - result = _tmp2_; -#line 59 "/home/bob/bzr/simple-scan/trunk/src/sane.vapi" - return result; -#line 4589 "scanner.c" - } -#line 54 "/home/bob/bzr/simple-scan/trunk/src/sane.vapi" - case SANE_STATUS_CANCELLED: -#line 4593 "scanner.c" - { - gchar* _tmp3_ = NULL; -#line 61 "/home/bob/bzr/simple-scan/trunk/src/sane.vapi" - _tmp3_ = g_strdup ("SANE_STATUS_CANCELLED"); -#line 61 "/home/bob/bzr/simple-scan/trunk/src/sane.vapi" - result = _tmp3_; -#line 61 "/home/bob/bzr/simple-scan/trunk/src/sane.vapi" - return result; -#line 4602 "scanner.c" - } -#line 54 "/home/bob/bzr/simple-scan/trunk/src/sane.vapi" - case SANE_STATUS_DEVICE_BUSY: -#line 4606 "scanner.c" - { - gchar* _tmp4_ = NULL; -#line 63 "/home/bob/bzr/simple-scan/trunk/src/sane.vapi" - _tmp4_ = g_strdup ("SANE_STATUS_DEVICE_BUSY"); -#line 63 "/home/bob/bzr/simple-scan/trunk/src/sane.vapi" - result = _tmp4_; -#line 63 "/home/bob/bzr/simple-scan/trunk/src/sane.vapi" - return result; -#line 4615 "scanner.c" - } -#line 54 "/home/bob/bzr/simple-scan/trunk/src/sane.vapi" - case SANE_STATUS_INVAL: -#line 4619 "scanner.c" - { - gchar* _tmp5_ = NULL; -#line 65 "/home/bob/bzr/simple-scan/trunk/src/sane.vapi" - _tmp5_ = g_strdup ("SANE_STATUS_INVAL"); -#line 65 "/home/bob/bzr/simple-scan/trunk/src/sane.vapi" - result = _tmp5_; -#line 65 "/home/bob/bzr/simple-scan/trunk/src/sane.vapi" - return result; -#line 4628 "scanner.c" - } -#line 54 "/home/bob/bzr/simple-scan/trunk/src/sane.vapi" - case SANE_STATUS_EOF: -#line 4632 "scanner.c" - { - gchar* _tmp6_ = NULL; -#line 67 "/home/bob/bzr/simple-scan/trunk/src/sane.vapi" - _tmp6_ = g_strdup ("SANE_STATUS_EOF"); -#line 67 "/home/bob/bzr/simple-scan/trunk/src/sane.vapi" - result = _tmp6_; -#line 67 "/home/bob/bzr/simple-scan/trunk/src/sane.vapi" - return result; -#line 4641 "scanner.c" - } -#line 54 "/home/bob/bzr/simple-scan/trunk/src/sane.vapi" - case SANE_STATUS_JAMMED: -#line 4645 "scanner.c" - { - gchar* _tmp7_ = NULL; -#line 69 "/home/bob/bzr/simple-scan/trunk/src/sane.vapi" - _tmp7_ = g_strdup ("SANE_STATUS_JAMMED"); -#line 69 "/home/bob/bzr/simple-scan/trunk/src/sane.vapi" - result = _tmp7_; -#line 69 "/home/bob/bzr/simple-scan/trunk/src/sane.vapi" - return result; -#line 4654 "scanner.c" - } -#line 54 "/home/bob/bzr/simple-scan/trunk/src/sane.vapi" - case SANE_STATUS_NO_DOCS: -#line 4658 "scanner.c" - { - gchar* _tmp8_ = NULL; -#line 71 "/home/bob/bzr/simple-scan/trunk/src/sane.vapi" - _tmp8_ = g_strdup ("SANE_STATUS_NO_DOCS"); -#line 71 "/home/bob/bzr/simple-scan/trunk/src/sane.vapi" - result = _tmp8_; -#line 71 "/home/bob/bzr/simple-scan/trunk/src/sane.vapi" - return result; -#line 4667 "scanner.c" - } -#line 54 "/home/bob/bzr/simple-scan/trunk/src/sane.vapi" - case SANE_STATUS_COVER_OPEN: -#line 4671 "scanner.c" - { - gchar* _tmp9_ = NULL; -#line 73 "/home/bob/bzr/simple-scan/trunk/src/sane.vapi" - _tmp9_ = g_strdup ("SANE_STATUS_COVER_OPEN"); -#line 73 "/home/bob/bzr/simple-scan/trunk/src/sane.vapi" - result = _tmp9_; -#line 73 "/home/bob/bzr/simple-scan/trunk/src/sane.vapi" - return result; -#line 4680 "scanner.c" - } -#line 54 "/home/bob/bzr/simple-scan/trunk/src/sane.vapi" - case SANE_STATUS_IO_ERROR: -#line 4684 "scanner.c" - { - gchar* _tmp10_ = NULL; -#line 75 "/home/bob/bzr/simple-scan/trunk/src/sane.vapi" - _tmp10_ = g_strdup ("SANE_STATUS_IO_ERROR"); -#line 75 "/home/bob/bzr/simple-scan/trunk/src/sane.vapi" - result = _tmp10_; -#line 75 "/home/bob/bzr/simple-scan/trunk/src/sane.vapi" - return result; -#line 4693 "scanner.c" - } -#line 54 "/home/bob/bzr/simple-scan/trunk/src/sane.vapi" - case SANE_STATUS_NO_MEM: -#line 4697 "scanner.c" - { - gchar* _tmp11_ = NULL; -#line 77 "/home/bob/bzr/simple-scan/trunk/src/sane.vapi" - _tmp11_ = g_strdup ("SANE_STATUS_NO_MEM"); -#line 77 "/home/bob/bzr/simple-scan/trunk/src/sane.vapi" - result = _tmp11_; -#line 77 "/home/bob/bzr/simple-scan/trunk/src/sane.vapi" - return result; -#line 4706 "scanner.c" - } -#line 54 "/home/bob/bzr/simple-scan/trunk/src/sane.vapi" - case SANE_STATUS_ACCESS_DENIED: -#line 4710 "scanner.c" - { - gchar* _tmp12_ = NULL; -#line 79 "/home/bob/bzr/simple-scan/trunk/src/sane.vapi" - _tmp12_ = g_strdup ("SANE_STATUS_ACCESS_DENIED"); -#line 79 "/home/bob/bzr/simple-scan/trunk/src/sane.vapi" - result = _tmp12_; -#line 79 "/home/bob/bzr/simple-scan/trunk/src/sane.vapi" - return result; -#line 4719 "scanner.c" - } - default: - { - SANE_Status _tmp13_ = 0; - gchar* _tmp14_ = NULL; -#line 81 "/home/bob/bzr/simple-scan/trunk/src/sane.vapi" - _tmp13_ = status; -#line 81 "/home/bob/bzr/simple-scan/trunk/src/sane.vapi" - _tmp14_ = g_strdup_printf ("SANE_STATUS(%d)", (gint) _tmp13_); -#line 81 "/home/bob/bzr/simple-scan/trunk/src/sane.vapi" - result = _tmp14_; -#line 81 "/home/bob/bzr/simple-scan/trunk/src/sane.vapi" - return result; -#line 4733 "scanner.c" - } - } -} - - -static gchar* string_replace (const gchar* self, const gchar* old, const gchar* replacement) { - gchar* result = NULL; - GError * _inner_error_ = NULL; -#line 1380 "/usr/share/vala-0.34/vapi/glib-2.0.vapi" - g_return_val_if_fail (self != NULL, NULL); -#line 1380 "/usr/share/vala-0.34/vapi/glib-2.0.vapi" - g_return_val_if_fail (old != NULL, NULL); -#line 1380 "/usr/share/vala-0.34/vapi/glib-2.0.vapi" - g_return_val_if_fail (replacement != NULL, NULL); -#line 4748 "scanner.c" - { - GRegex* regex = NULL; - const gchar* _tmp0_ = NULL; - gchar* _tmp1_ = NULL; - gchar* _tmp2_ = NULL; - GRegex* _tmp3_ = NULL; - GRegex* _tmp4_ = NULL; - gchar* _tmp5_ = NULL; - GRegex* _tmp6_ = NULL; - const gchar* _tmp7_ = NULL; - gchar* _tmp8_ = NULL; - gchar* _tmp9_ = NULL; -#line 1382 "/usr/share/vala-0.34/vapi/glib-2.0.vapi" - _tmp0_ = old; -#line 1382 "/usr/share/vala-0.34/vapi/glib-2.0.vapi" - _tmp1_ = g_regex_escape_string (_tmp0_, -1); -#line 1382 "/usr/share/vala-0.34/vapi/glib-2.0.vapi" - _tmp2_ = _tmp1_; -#line 1382 "/usr/share/vala-0.34/vapi/glib-2.0.vapi" - _tmp3_ = g_regex_new (_tmp2_, 0, 0, &_inner_error_); -#line 1382 "/usr/share/vala-0.34/vapi/glib-2.0.vapi" - _tmp4_ = _tmp3_; -#line 1382 "/usr/share/vala-0.34/vapi/glib-2.0.vapi" - _g_free0 (_tmp2_); -#line 1382 "/usr/share/vala-0.34/vapi/glib-2.0.vapi" - regex = _tmp4_; -#line 1382 "/usr/share/vala-0.34/vapi/glib-2.0.vapi" - if (G_UNLIKELY (_inner_error_ != NULL)) { -#line 1382 "/usr/share/vala-0.34/vapi/glib-2.0.vapi" - if (_inner_error_->domain == G_REGEX_ERROR) { -#line 4779 "scanner.c" - goto __catch15_g_regex_error; - } -#line 1382 "/usr/share/vala-0.34/vapi/glib-2.0.vapi" - g_critical ("file %s: line %d: unexpected error: %s (%s, %d)", __FILE__, __LINE__, _inner_error_->message, g_quark_to_string (_inner_error_->domain), _inner_error_->code); -#line 1382 "/usr/share/vala-0.34/vapi/glib-2.0.vapi" - g_clear_error (&_inner_error_); -#line 1382 "/usr/share/vala-0.34/vapi/glib-2.0.vapi" - return NULL; -#line 4788 "scanner.c" - } -#line 1383 "/usr/share/vala-0.34/vapi/glib-2.0.vapi" - _tmp6_ = regex; -#line 1383 "/usr/share/vala-0.34/vapi/glib-2.0.vapi" - _tmp7_ = replacement; -#line 1383 "/usr/share/vala-0.34/vapi/glib-2.0.vapi" - _tmp8_ = g_regex_replace_literal (_tmp6_, self, (gssize) -1, 0, _tmp7_, 0, &_inner_error_); -#line 1383 "/usr/share/vala-0.34/vapi/glib-2.0.vapi" - _tmp5_ = _tmp8_; -#line 1383 "/usr/share/vala-0.34/vapi/glib-2.0.vapi" - if (G_UNLIKELY (_inner_error_ != NULL)) { -#line 1383 "/usr/share/vala-0.34/vapi/glib-2.0.vapi" - _g_regex_unref0 (regex); -#line 1383 "/usr/share/vala-0.34/vapi/glib-2.0.vapi" - if (_inner_error_->domain == G_REGEX_ERROR) { -#line 4804 "scanner.c" - goto __catch15_g_regex_error; - } -#line 1383 "/usr/share/vala-0.34/vapi/glib-2.0.vapi" - _g_regex_unref0 (regex); -#line 1383 "/usr/share/vala-0.34/vapi/glib-2.0.vapi" - g_critical ("file %s: line %d: unexpected error: %s (%s, %d)", __FILE__, __LINE__, _inner_error_->message, g_quark_to_string (_inner_error_->domain), _inner_error_->code); -#line 1383 "/usr/share/vala-0.34/vapi/glib-2.0.vapi" - g_clear_error (&_inner_error_); -#line 1383 "/usr/share/vala-0.34/vapi/glib-2.0.vapi" - return NULL; -#line 4815 "scanner.c" - } -#line 1383 "/usr/share/vala-0.34/vapi/glib-2.0.vapi" - _tmp9_ = _tmp5_; -#line 1383 "/usr/share/vala-0.34/vapi/glib-2.0.vapi" - _tmp5_ = NULL; -#line 1383 "/usr/share/vala-0.34/vapi/glib-2.0.vapi" - result = _tmp9_; -#line 1383 "/usr/share/vala-0.34/vapi/glib-2.0.vapi" - _g_free0 (_tmp5_); -#line 1383 "/usr/share/vala-0.34/vapi/glib-2.0.vapi" - _g_regex_unref0 (regex); -#line 1383 "/usr/share/vala-0.34/vapi/glib-2.0.vapi" - return result; -#line 4829 "scanner.c" - } - goto __finally15; - __catch15_g_regex_error: - { - GError* e = NULL; -#line 1381 "/usr/share/vala-0.34/vapi/glib-2.0.vapi" - e = _inner_error_; -#line 1381 "/usr/share/vala-0.34/vapi/glib-2.0.vapi" - _inner_error_ = NULL; -#line 1385 "/usr/share/vala-0.34/vapi/glib-2.0.vapi" - g_assert_not_reached (); -#line 1381 "/usr/share/vala-0.34/vapi/glib-2.0.vapi" - _g_error_free0 (e); -#line 4843 "scanner.c" - } - __finally15: -#line 1381 "/usr/share/vala-0.34/vapi/glib-2.0.vapi" - if (G_UNLIKELY (_inner_error_ != NULL)) { -#line 1381 "/usr/share/vala-0.34/vapi/glib-2.0.vapi" - g_critical ("file %s: line %d: uncaught error: %s (%s, %d)", __FILE__, __LINE__, _inner_error_->message, g_quark_to_string (_inner_error_->domain), _inner_error_->code); -#line 1381 "/usr/share/vala-0.34/vapi/glib-2.0.vapi" - g_clear_error (&_inner_error_); -#line 1381 "/usr/share/vala-0.34/vapi/glib-2.0.vapi" - return NULL; -#line 4854 "scanner.c" - } -} - - -static gpointer _scan_device_ref0 (gpointer self) { -#line 365 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - return self ? scan_device_ref (self) : NULL; -#line 4862 "scanner.c" -} - - -static gint _scanner_compare_devices_gcompare_func (gconstpointer a, gconstpointer b) { - gint result; - result = scanner_compare_devices ((ScanDevice*) a, (ScanDevice*) b); -#line 369 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - return result; -#line 4871 "scanner.c" -} - - -static void scanner_do_redetect (Scanner* self) { - SANE_Device** device_list = NULL; - gint device_list_length1 = 0; - gint _device_list_size_ = 0; - SANE_Status status = 0; - SANE_Device** _tmp0_ = NULL; - SANE_Status _tmp1_ = 0; - SANE_Status _tmp2_ = 0; - gchar* _tmp3_ = NULL; - gchar* _tmp4_ = NULL; - SANE_Status _tmp5_ = 0; - GList* devices = NULL; - GList* _tmp56_ = NULL; - GList* _tmp63_ = NULL; - NotifyUpdateDevices* _tmp64_ = NULL; - NotifyUpdateDevices* _tmp65_ = NULL; -#line 334 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - g_return_if_fail (self != NULL); -#line 336 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - device_list = NULL; -#line 336 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - device_list_length1 = 0; -#line 336 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _device_list_size_ = device_list_length1; -#line 337 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp1_ = sane_get_devices (&_tmp0_, FALSE); -#line 337 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - device_list = _tmp0_; -#line 337 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - device_list_length1 = -1; -#line 337 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _device_list_size_ = device_list_length1; -#line 337 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - status = _tmp1_; -#line 338 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp2_ = status; -#line 338 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp3_ = sane_status_to_string (_tmp2_); -#line 338 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp4_ = _tmp3_; -#line 338 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - g_debug ("scanner.vala:338: sane_get_devices () -> %s", _tmp4_); -#line 338 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _g_free0 (_tmp4_); -#line 339 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp5_ = status; -#line 339 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - if (_tmp5_ != SANE_STATUS_GOOD) { -#line 4923 "scanner.c" - SANE_Status _tmp6_ = 0; - const gchar* _tmp7_ = NULL; -#line 341 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp6_ = status; -#line 341 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp7_ = sane_strstatus (_tmp6_); -#line 341 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - g_warning ("scanner.vala:341: Unable to get SANE devices: %s", _tmp7_); -#line 342 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - self->priv->need_redetect = FALSE; -#line 343 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - self->priv->state = SCAN_STATE_IDLE; -#line 344 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - return; -#line 4938 "scanner.c" - } -#line 347 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - devices = NULL; -#line 4942 "scanner.c" - { - gint i = 0; -#line 348 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - i = 0; -#line 4947 "scanner.c" - { - gboolean _tmp8_ = FALSE; -#line 348 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp8_ = TRUE; -#line 348 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - while (TRUE) { -#line 4954 "scanner.c" - SANE_Device** _tmp10_ = NULL; - gint _tmp10__length1 = 0; - gint _tmp11_ = 0; - SANE_Device* _tmp12_ = NULL; - SANE_Device** _tmp13_ = NULL; - gint _tmp13__length1 = 0; - gint _tmp14_ = 0; - SANE_Device* _tmp15_ = NULL; - const gchar* _tmp16_ = NULL; - SANE_Device** _tmp17_ = NULL; - gint _tmp17__length1 = 0; - gint _tmp18_ = 0; - SANE_Device* _tmp19_ = NULL; - const gchar* _tmp20_ = NULL; - SANE_Device** _tmp21_ = NULL; - gint _tmp21__length1 = 0; - gint _tmp22_ = 0; - SANE_Device* _tmp23_ = NULL; - const gchar* _tmp24_ = NULL; - SANE_Device** _tmp25_ = NULL; - gint _tmp25__length1 = 0; - gint _tmp26_ = 0; - SANE_Device* _tmp27_ = NULL; - const gchar* _tmp28_ = NULL; - ScanDevice* scan_device = NULL; - ScanDevice* _tmp29_ = NULL; - ScanDevice* _tmp30_ = NULL; - SANE_Device** _tmp31_ = NULL; - gint _tmp31__length1 = 0; - gint _tmp32_ = 0; - SANE_Device* _tmp33_ = NULL; - const gchar* _tmp34_ = NULL; - gchar* _tmp35_ = NULL; - gchar* vendor = NULL; - SANE_Device** _tmp36_ = NULL; - gint _tmp36__length1 = 0; - gint _tmp37_ = 0; - SANE_Device* _tmp38_ = NULL; - const gchar* _tmp39_ = NULL; - gchar* _tmp40_ = NULL; - const gchar* _tmp41_ = NULL; - ScanDevice* _tmp43_ = NULL; - const gchar* _tmp44_ = NULL; - SANE_Device** _tmp45_ = NULL; - gint _tmp45__length1 = 0; - gint _tmp46_ = 0; - SANE_Device* _tmp47_ = NULL; - const gchar* _tmp48_ = NULL; - gchar* _tmp49_ = NULL; - ScanDevice* _tmp50_ = NULL; - const gchar* _tmp51_ = NULL; - gchar* _tmp52_ = NULL; - gchar* _tmp53_ = NULL; - ScanDevice* _tmp54_ = NULL; - ScanDevice* _tmp55_ = NULL; -#line 348 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - if (!_tmp8_) { -#line 5012 "scanner.c" - gint _tmp9_ = 0; -#line 348 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp9_ = i; -#line 348 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - i = _tmp9_ + 1; -#line 5018 "scanner.c" - } -#line 348 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp8_ = FALSE; -#line 348 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp10_ = device_list; -#line 348 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp10__length1 = device_list_length1; -#line 348 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp11_ = i; -#line 348 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp12_ = _tmp10_[_tmp11_]; -#line 348 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - if (!(_tmp12_ != NULL)) { -#line 348 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - break; -#line 5034 "scanner.c" - } -#line 350 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp13_ = device_list; -#line 350 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp13__length1 = device_list_length1; -#line 350 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp14_ = i; -#line 350 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp15_ = _tmp13_[_tmp14_]; -#line 350 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp16_ = _tmp15_->name; -#line 350 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp17_ = device_list; -#line 350 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp17__length1 = device_list_length1; -#line 350 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp18_ = i; -#line 350 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp19_ = _tmp17_[_tmp18_]; -#line 350 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp20_ = _tmp19_->vendor; -#line 350 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp21_ = device_list; -#line 350 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp21__length1 = device_list_length1; -#line 350 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp22_ = i; -#line 350 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp23_ = _tmp21_[_tmp22_]; -#line 350 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp24_ = _tmp23_->model; -#line 350 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp25_ = device_list; -#line 350 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp25__length1 = device_list_length1; -#line 350 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp26_ = i; -#line 350 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp27_ = _tmp25_[_tmp26_]; -#line 350 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp28_ = _tmp27_->type; -#line 350 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - g_debug ("scanner.vala:350: Device: name=\"%s\" vendor=\"%s\" model=\"%s\" type=" \ -"\"%s\"", _tmp16_, _tmp20_, _tmp24_, _tmp28_); -#line 353 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp29_ = scan_device_new (); -#line 353 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - scan_device = _tmp29_; -#line 354 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp30_ = scan_device; -#line 354 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp31_ = device_list; -#line 354 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp31__length1 = device_list_length1; -#line 354 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp32_ = i; -#line 354 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp33_ = _tmp31_[_tmp32_]; -#line 354 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp34_ = _tmp33_->name; -#line 354 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp35_ = g_strdup (_tmp34_); -#line 354 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _g_free0 (_tmp30_->name); -#line 354 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp30_->name = _tmp35_; -#line 357 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp36_ = device_list; -#line 357 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp36__length1 = device_list_length1; -#line 357 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp37_ = i; -#line 357 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp38_ = _tmp36_[_tmp37_]; -#line 357 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp39_ = _tmp38_->vendor; -#line 357 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp40_ = g_strdup (_tmp39_); -#line 357 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - vendor = _tmp40_; -#line 358 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp41_ = vendor; -#line 358 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - if (g_strcmp0 (_tmp41_, "Hewlett-Packard") == 0) { -#line 5118 "scanner.c" - gchar* _tmp42_ = NULL; -#line 359 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp42_ = g_strdup ("HP"); -#line 359 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _g_free0 (vendor); -#line 359 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - vendor = _tmp42_; -#line 5126 "scanner.c" - } -#line 361 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp43_ = scan_device; -#line 361 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp44_ = vendor; -#line 361 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp45_ = device_list; -#line 361 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp45__length1 = device_list_length1; -#line 361 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp46_ = i; -#line 361 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp47_ = _tmp45_[_tmp46_]; -#line 361 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp48_ = _tmp47_->model; -#line 361 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp49_ = g_strdup_printf ("%s %s", _tmp44_, _tmp48_); -#line 361 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _g_free0 (_tmp43_->label); -#line 361 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp43_->label = _tmp49_; -#line 363 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp50_ = scan_device; -#line 363 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp51_ = _tmp50_->label; -#line 363 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp52_ = string_replace (_tmp51_, "_", " "); -#line 363 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp53_ = _tmp52_; -#line 363 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _g_free0 (_tmp53_); -#line 365 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp54_ = scan_device; -#line 365 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp55_ = _scan_device_ref0 (_tmp54_); -#line 365 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - devices = g_list_append (devices, _tmp55_); -#line 348 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _g_free0 (vendor); -#line 348 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _scan_device_unref0 (scan_device); -#line 5168 "scanner.c" - } - } - } -#line 369 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - devices = g_list_sort (devices, _scanner_compare_devices_gcompare_func); -#line 371 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - self->priv->need_redetect = FALSE; -#line 372 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - self->priv->state = SCAN_STATE_IDLE; -#line 374 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp56_ = devices; -#line 374 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - if (_tmp56_ != NULL) { -#line 5182 "scanner.c" - ScanDevice* device = NULL; - GList* _tmp57_ = NULL; - gconstpointer _tmp58_ = NULL; - ScanDevice* _tmp59_ = NULL; - ScanDevice* _tmp60_ = NULL; - const gchar* _tmp61_ = NULL; - gchar* _tmp62_ = NULL; -#line 376 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp57_ = devices; -#line 376 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp58_ = g_list_nth_data (_tmp57_, (guint) 0); -#line 376 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp59_ = _scan_device_ref0 ((ScanDevice*) _tmp58_); -#line 376 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - device = _tmp59_; -#line 377 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp60_ = device; -#line 377 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp61_ = _tmp60_->name; -#line 377 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp62_ = g_strdup (_tmp61_); -#line 377 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _g_free0 (self->priv->default_device); -#line 377 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - self->priv->default_device = _tmp62_; -#line 374 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _scan_device_unref0 (device); -#line 5210 "scanner.c" - } else { -#line 380 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _g_free0 (self->priv->default_device); -#line 380 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - self->priv->default_device = NULL; -#line 5216 "scanner.c" - } -#line 382 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp63_ = devices; -#line 382 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - devices = NULL; -#line 382 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp64_ = notify_update_devices_new (_tmp63_); -#line 382 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp65_ = _tmp64_; -#line 382 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - scanner_notify (self, (Notify*) _tmp65_); -#line 382 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _notify_unref0 (_tmp65_); -#line 334 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - __g_list_free__scan_device_unref0_0 (devices); -#line 5232 "scanner.c" -} - - -static gint scanner_scale_int (Scanner* self, gint source_min, gint source_max, SANE_Option_Descriptor* option, gint value) { - gint result = 0; - gint v = 0; - gint _tmp0_ = 0; - SANE_Option_Descriptor* _tmp1_ = NULL; - SANE_Value_Type _tmp2_ = 0; - gint _tmp3_ = 0; - gboolean _tmp4_ = FALSE; - SANE_Option_Descriptor* _tmp5_ = NULL; - SANE_Constraint_Type _tmp6_ = 0; -#line 385 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - g_return_val_if_fail (self != NULL, 0); -#line 385 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - g_return_val_if_fail (option != NULL, 0); -#line 387 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp0_ = value; -#line 387 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - v = _tmp0_; -#line 389 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp1_ = option; -#line 389 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp2_ = _tmp1_->type; -#line 389 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp3_ = value; -#line 389 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - g_return_val_if_fail (_tmp2_ == SANE_TYPE_INT, _tmp3_); -#line 391 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp5_ = option; -#line 391 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp6_ = _tmp5_->constraint_type; -#line 391 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - if (_tmp6_ == SANE_CONSTRAINT_RANGE) { -#line 5268 "scanner.c" - SANE_Option_Descriptor* _tmp7_ = NULL; - SANE_Range* _tmp8_ = NULL; - SANE_Word _tmp9_ = {0}; - SANE_Option_Descriptor* _tmp10_ = NULL; - SANE_Range* _tmp11_ = NULL; - SANE_Word _tmp12_ = {0}; -#line 391 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp7_ = option; -#line 391 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp8_ = _tmp7_->constraint.range; -#line 391 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp9_ = _tmp8_->max; -#line 391 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp10_ = option; -#line 391 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp11_ = _tmp10_->constraint.range; -#line 391 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp12_ = _tmp11_->min; -#line 391 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp4_ = _tmp9_ != _tmp12_; -#line 5289 "scanner.c" - } else { -#line 391 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp4_ = FALSE; -#line 5293 "scanner.c" - } -#line 391 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - if (_tmp4_) { -#line 5297 "scanner.c" - gint _tmp13_ = 0; - gint _tmp14_ = 0; - gint _tmp15_ = 0; - SANE_Option_Descriptor* _tmp16_ = NULL; - SANE_Range* _tmp17_ = NULL; - SANE_Word _tmp18_ = {0}; - SANE_Option_Descriptor* _tmp19_ = NULL; - SANE_Range* _tmp20_ = NULL; - SANE_Word _tmp21_ = {0}; - gint _tmp22_ = 0; - gint _tmp23_ = 0; - gint _tmp24_ = 0; - gint _tmp25_ = 0; - SANE_Option_Descriptor* _tmp26_ = NULL; - SANE_Range* _tmp27_ = NULL; - SANE_Word _tmp28_ = {0}; - gint _tmp29_ = 0; - gint _tmp30_ = 0; - gint _tmp31_ = 0; - gint _tmp32_ = 0; - SANE_Option_Descriptor* _tmp33_ = NULL; - SANE_Range* _tmp34_ = NULL; - SANE_Word _tmp35_ = {0}; - SANE_Option_Descriptor* _tmp36_ = NULL; - SANE_Range* _tmp37_ = NULL; - SANE_Word _tmp38_ = {0}; -#line 393 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp13_ = v; -#line 393 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp14_ = source_min; -#line 393 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - v = _tmp13_ - _tmp14_; -#line 394 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp15_ = v; -#line 394 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp16_ = option; -#line 394 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp17_ = _tmp16_->constraint.range; -#line 394 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp18_ = _tmp17_->max; -#line 394 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp19_ = option; -#line 394 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp20_ = _tmp19_->constraint.range; -#line 394 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp21_ = _tmp20_->min; -#line 394 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - v = _tmp15_ * ((gint) (_tmp18_ - _tmp21_)); -#line 395 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp22_ = v; -#line 395 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp23_ = source_max; -#line 395 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp24_ = source_min; -#line 395 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - v = _tmp22_ / (_tmp23_ - _tmp24_); -#line 396 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp25_ = v; -#line 396 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp26_ = option; -#line 396 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp27_ = _tmp26_->constraint.range; -#line 396 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp28_ = _tmp27_->min; -#line 396 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - v = _tmp25_ + ((gint) _tmp28_); -#line 397 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp29_ = value; -#line 397 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp30_ = source_min; -#line 397 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp31_ = source_max; -#line 397 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp32_ = v; -#line 397 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp33_ = option; -#line 397 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp34_ = _tmp33_->constraint.range; -#line 397 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp35_ = _tmp34_->min; -#line 397 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp36_ = option; -#line 397 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp37_ = _tmp36_->constraint.range; -#line 397 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp38_ = _tmp37_->max; -#line 397 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - g_debug ("scanner.vala:397: scale_int: scaling %d [min: %d, max: %d] to %d [min:" \ -" %d, max: %d]", _tmp29_, _tmp30_, _tmp31_, _tmp32_, (gint) _tmp35_, (gint) _tmp38_); -#line 5386 "scanner.c" - } -#line 401 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - result = v; -#line 401 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - return result; -#line 5392 "scanner.c" -} - - -static gboolean scanner_set_default_option (Scanner* self, SANE_Handle handle, SANE_Option_Descriptor* option, SANE_Int option_index) { - gboolean result = FALSE; - SANE_Option_Descriptor* _tmp0_ = NULL; - SANE_Int _tmp1_ = {0}; - SANE_Status status = 0; - SANE_Handle _tmp2_ = {0}; - SANE_Int _tmp3_ = {0}; - SANE_Status _tmp4_ = 0; - SANE_Int _tmp5_ = {0}; - SANE_Status _tmp6_ = 0; - gchar* _tmp7_ = NULL; - gchar* _tmp8_ = NULL; - SANE_Status _tmp9_ = 0; - SANE_Status _tmp14_ = 0; -#line 404 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - g_return_val_if_fail (self != NULL, FALSE); -#line 404 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - g_return_val_if_fail (option != NULL, FALSE); -#line 407 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp0_ = option; -#line 407 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp1_ = _tmp0_->cap; -#line 407 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - if ((_tmp1_ & SANE_CAP_AUTOMATIC) == ((SANE_Int) 0)) { -#line 408 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - result = FALSE; -#line 408 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - return result; -#line 5424 "scanner.c" - } -#line 410 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp2_ = handle; -#line 410 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp3_ = option_index; -#line 410 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp4_ = sane_control_option (_tmp2_, _tmp3_, SANE_ACTION_SET_AUTO, NULL, NULL); -#line 410 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - status = _tmp4_; -#line 411 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp5_ = option_index; -#line 411 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp6_ = status; -#line 411 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp7_ = sane_status_to_string (_tmp6_); -#line 411 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp8_ = _tmp7_; -#line 411 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - g_debug ("scanner.vala:411: sane_control_option (%d, SANE_ACTION_SET_AUTO) -> %s", (gint) _tmp5_, _tmp8_); -#line 411 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _g_free0 (_tmp8_); -#line 412 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp9_ = status; -#line 412 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - if (_tmp9_ != SANE_STATUS_GOOD) { -#line 5450 "scanner.c" - SANE_Option_Descriptor* _tmp10_ = NULL; - const gchar* _tmp11_ = NULL; - SANE_Status _tmp12_ = 0; - const gchar* _tmp13_ = NULL; -#line 413 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp10_ = option; -#line 413 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp11_ = _tmp10_->name; -#line 413 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp12_ = status; -#line 413 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp13_ = sane_strstatus (_tmp12_); -#line 413 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - g_warning ("scanner.vala:413: Error setting default option %s: %s", _tmp11_, _tmp13_); -#line 5465 "scanner.c" - } -#line 415 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp14_ = status; -#line 415 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - result = _tmp14_ == SANE_STATUS_GOOD; -#line 415 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - return result; -#line 5473 "scanner.c" -} - - -static void scanner_set_bool_option (Scanner* self, SANE_Handle handle, SANE_Option_Descriptor* option, SANE_Int option_index, gboolean value, gboolean* _result_) { - gboolean _vala_result = FALSE; - SANE_Option_Descriptor* _tmp0_ = NULL; - SANE_Value_Type _tmp1_ = 0; - SANE_Bool v = {0}; - gboolean _tmp2_ = FALSE; - SANE_Status status = 0; - SANE_Handle _tmp3_ = {0}; - SANE_Int _tmp4_ = {0}; - SANE_Status _tmp5_ = 0; - SANE_Bool _tmp6_ = {0}; - const gchar* _tmp7_ = NULL; - gboolean _tmp8_ = FALSE; - const gchar* _tmp9_ = NULL; - gboolean _tmp10_ = FALSE; - SANE_Int _tmp11_ = {0}; - SANE_Status _tmp12_ = 0; - gchar* _tmp13_ = NULL; - gchar* _tmp14_ = NULL; -#line 418 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - g_return_if_fail (self != NULL); -#line 418 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - g_return_if_fail (option != NULL); -#line 420 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp0_ = option; -#line 420 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp1_ = _tmp0_->type; -#line 420 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - g_return_if_fail (_tmp1_ == SANE_TYPE_BOOL); -#line 422 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp2_ = value; -#line 422 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - v = (SANE_Bool) _tmp2_; -#line 423 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp3_ = handle; -#line 423 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp4_ = option_index; -#line 423 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp5_ = sane_control_option (_tmp3_, _tmp4_, SANE_ACTION_SET_VALUE, &v, NULL); -#line 423 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - status = _tmp5_; -#line 424 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp6_ = v; -#line 424 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _vala_result = (gboolean) _tmp6_; -#line 425 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp8_ = value; -#line 425 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - if (_tmp8_) { -#line 425 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp7_ = "SANE_TRUE"; -#line 5528 "scanner.c" - } else { -#line 425 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp7_ = "SANE_FALSE"; -#line 5532 "scanner.c" - } -#line 425 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp10_ = _vala_result; -#line 425 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - if (_tmp10_) { -#line 425 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp9_ = "SANE_TRUE"; -#line 5540 "scanner.c" - } else { -#line 425 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp9_ = "SANE_FALSE"; -#line 5544 "scanner.c" - } -#line 425 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp11_ = option_index; -#line 425 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp12_ = status; -#line 425 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp13_ = sane_status_to_string (_tmp12_); -#line 425 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp14_ = _tmp13_; -#line 425 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - g_debug ("scanner.vala:425: sane_control_option (%d, SANE_ACTION_SET_VALUE, %s) " \ -"-> (%s, %s)", (gint) _tmp11_, _tmp7_, _tmp14_, _tmp9_); -#line 425 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _g_free0 (_tmp14_); -#line 418 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - if (_result_) { -#line 418 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - *_result_ = _vala_result; -#line 5562 "scanner.c" - } -} - - -static void scanner_set_int_option (Scanner* self, SANE_Handle handle, SANE_Option_Descriptor* option, SANE_Int option_index, gint value, gint* _result_) { - gint _vala_result = 0; - SANE_Option_Descriptor* _tmp0_ = NULL; - SANE_Value_Type _tmp1_ = 0; - SANE_Int v = {0}; - gint _tmp2_ = 0; - SANE_Option_Descriptor* _tmp3_ = NULL; - SANE_Constraint_Type _tmp4_ = 0; - SANE_Status status = 0; - SANE_Handle _tmp47_ = {0}; - SANE_Int _tmp48_ = {0}; - SANE_Status _tmp49_ = 0; - SANE_Int _tmp50_ = {0}; - gint _tmp51_ = 0; - gchar* _tmp52_ = NULL; - gchar* _tmp53_ = NULL; - SANE_Int _tmp54_ = {0}; - SANE_Int _tmp55_ = {0}; -#line 428 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - g_return_if_fail (self != NULL); -#line 428 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - g_return_if_fail (option != NULL); -#line 430 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp0_ = option; -#line 430 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp1_ = _tmp0_->type; -#line 430 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - g_return_if_fail (_tmp1_ == SANE_TYPE_INT); -#line 432 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp2_ = value; -#line 432 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - v = (SANE_Int) _tmp2_; -#line 433 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp3_ = option; -#line 433 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp4_ = _tmp3_->constraint_type; -#line 433 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - if (_tmp4_ == SANE_CONSTRAINT_RANGE) { -#line 5605 "scanner.c" - SANE_Option_Descriptor* _tmp5_ = NULL; - SANE_Range* _tmp6_ = NULL; - SANE_Word _tmp7_ = {0}; - SANE_Int _tmp12_ = {0}; - SANE_Option_Descriptor* _tmp13_ = NULL; - SANE_Range* _tmp14_ = NULL; - SANE_Word _tmp15_ = {0}; - SANE_Int _tmp19_ = {0}; - SANE_Option_Descriptor* _tmp20_ = NULL; - SANE_Range* _tmp21_ = NULL; - SANE_Word _tmp22_ = {0}; -#line 435 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp5_ = option; -#line 435 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp6_ = _tmp5_->constraint.range; -#line 435 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp7_ = _tmp6_->quant; -#line 435 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - if (_tmp7_ != ((SANE_Word) 0)) { -#line 5625 "scanner.c" - SANE_Int _tmp8_ = {0}; - SANE_Option_Descriptor* _tmp9_ = NULL; - SANE_Range* _tmp10_ = NULL; - SANE_Word _tmp11_ = {0}; -#line 436 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp8_ = v; -#line 436 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp9_ = option; -#line 436 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp10_ = _tmp9_->constraint.range; -#line 436 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp11_ = _tmp10_->quant; -#line 436 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - v = _tmp8_ * _tmp11_; -#line 5640 "scanner.c" - } -#line 437 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp12_ = v; -#line 437 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp13_ = option; -#line 437 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp14_ = _tmp13_->constraint.range; -#line 437 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp15_ = _tmp14_->min; -#line 437 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - if (_tmp12_ < ((SANE_Int) _tmp15_)) { -#line 5652 "scanner.c" - SANE_Option_Descriptor* _tmp16_ = NULL; - SANE_Range* _tmp17_ = NULL; - SANE_Word _tmp18_ = {0}; -#line 438 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp16_ = option; -#line 438 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp17_ = _tmp16_->constraint.range; -#line 438 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp18_ = _tmp17_->min; -#line 438 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - v = (SANE_Int) _tmp18_; -#line 5664 "scanner.c" - } -#line 439 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp19_ = v; -#line 439 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp20_ = option; -#line 439 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp21_ = _tmp20_->constraint.range; -#line 439 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp22_ = _tmp21_->max; -#line 439 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - if (_tmp19_ > ((SANE_Int) _tmp22_)) { -#line 5676 "scanner.c" - SANE_Option_Descriptor* _tmp23_ = NULL; - SANE_Range* _tmp24_ = NULL; - SANE_Word _tmp25_ = {0}; -#line 440 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp23_ = option; -#line 440 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp24_ = _tmp23_->constraint.range; -#line 440 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp25_ = _tmp24_->max; -#line 440 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - v = (SANE_Int) _tmp25_; -#line 5688 "scanner.c" - } - } else { - SANE_Option_Descriptor* _tmp26_ = NULL; - SANE_Constraint_Type _tmp27_ = 0; -#line 442 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp26_ = option; -#line 442 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp27_ = _tmp26_->constraint_type; -#line 442 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - if (_tmp27_ == SANE_CONSTRAINT_WORD_LIST) { -#line 5699 "scanner.c" - gint distance = 0; - gint nearest = 0; - gint _tmp46_ = 0; -#line 444 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - distance = G_MAXINT; -#line 444 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - nearest = 0; -#line 5707 "scanner.c" - { - gint i = 0; -#line 447 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - i = 0; -#line 5712 "scanner.c" - { - gboolean _tmp28_ = FALSE; -#line 447 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp28_ = TRUE; -#line 447 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - while (TRUE) { -#line 5719 "scanner.c" - gint _tmp30_ = 0; - SANE_Option_Descriptor* _tmp31_ = NULL; - SANE_Word* _tmp32_ = NULL; - gint _tmp32__length1 = 0; - SANE_Word _tmp33_ = {0}; - gint x = 0; - SANE_Option_Descriptor* _tmp34_ = NULL; - SANE_Word* _tmp35_ = NULL; - gint _tmp35__length1 = 0; - gint _tmp36_ = 0; - SANE_Word _tmp37_ = {0}; - gint d = 0; - gint _tmp38_ = 0; - SANE_Int _tmp39_ = {0}; - gint _tmp40_ = 0; - gint _tmp41_ = 0; - gint _tmp42_ = 0; - gint _tmp43_ = 0; -#line 447 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - if (!_tmp28_) { -#line 5740 "scanner.c" - gint _tmp29_ = 0; -#line 447 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp29_ = i; -#line 447 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - i = _tmp29_ + 1; -#line 5746 "scanner.c" - } -#line 447 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp28_ = FALSE; -#line 447 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp30_ = i; -#line 447 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp31_ = option; -#line 447 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp32_ = _tmp31_->constraint.word_list; -#line 447 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp32__length1 = -1; -#line 447 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp33_ = _tmp32_[0]; -#line 447 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - if (!(((SANE_Word) _tmp30_) < _tmp33_)) { -#line 447 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - break; -#line 5764 "scanner.c" - } -#line 449 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp34_ = option; -#line 449 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp35_ = _tmp34_->constraint.word_list; -#line 449 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp35__length1 = -1; -#line 449 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp36_ = i; -#line 449 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp37_ = _tmp35_[_tmp36_ + 1]; -#line 449 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - x = (gint) _tmp37_; -#line 450 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp38_ = x; -#line 450 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp39_ = v; -#line 450 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - d = (gint) (_tmp38_ - _tmp39_); -#line 451 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp40_ = d; -#line 451 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp41_ = abs (_tmp40_); -#line 451 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - d = _tmp41_; -#line 452 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp42_ = d; -#line 452 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp43_ = distance; -#line 452 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - if (_tmp42_ < _tmp43_) { -#line 5796 "scanner.c" - gint _tmp44_ = 0; - gint _tmp45_ = 0; -#line 454 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp44_ = d; -#line 454 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - distance = _tmp44_; -#line 455 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp45_ = x; -#line 455 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - nearest = _tmp45_; -#line 5807 "scanner.c" - } - } - } - } -#line 458 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp46_ = nearest; -#line 458 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - v = (SANE_Int) _tmp46_; -#line 5816 "scanner.c" - } - } -#line 461 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp47_ = handle; -#line 461 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp48_ = option_index; -#line 461 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp49_ = sane_control_option (_tmp47_, _tmp48_, SANE_ACTION_SET_VALUE, &v, NULL); -#line 461 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - status = _tmp49_; -#line 462 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp50_ = option_index; -#line 462 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp51_ = value; -#line 462 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp52_ = sane_status_to_string (status); -#line 462 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp53_ = _tmp52_; -#line 462 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp54_ = v; -#line 462 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - g_debug ("scanner.vala:462: sane_control_option (%d, SANE_ACTION_SET_VALUE, %d) " \ -"-> (%s, %d)", (gint) _tmp50_, _tmp51_, _tmp53_, (gint) _tmp54_); -#line 462 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _g_free0 (_tmp53_); -#line 463 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp55_ = v; -#line 463 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _vala_result = (gint) _tmp55_; -#line 428 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - if (_result_) { -#line 428 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - *_result_ = _vala_result; -#line 5849 "scanner.c" - } -} - - -static void scanner_set_fixed_option (Scanner* self, SANE_Handle handle, SANE_Option_Descriptor* option, SANE_Int option_index, gdouble value, gdouble* _result_) { - gdouble _vala_result = 0.0; - gdouble v = 0.0; - gdouble _tmp0_ = 0.0; - SANE_Fixed v_fixed = {0}; - SANE_Option_Descriptor* _tmp1_ = NULL; - SANE_Value_Type _tmp2_ = 0; - SANE_Option_Descriptor* _tmp3_ = NULL; - SANE_Constraint_Type _tmp4_ = 0; - gdouble _tmp41_ = 0.0; - SANE_Fixed _tmp42_ = {0}; - SANE_Status status = 0; - SANE_Handle _tmp43_ = {0}; - SANE_Int _tmp44_ = {0}; - SANE_Status _tmp45_ = 0; - SANE_Int _tmp46_ = {0}; - gdouble _tmp47_ = 0.0; - gchar* _tmp48_ = NULL; - gchar* _tmp49_ = NULL; - gdouble _tmp50_ = 0.0; - gdouble _tmp51_ = 0.0; -#line 466 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - g_return_if_fail (self != NULL); -#line 466 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - g_return_if_fail (option != NULL); -#line 468 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp0_ = value; -#line 468 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - v = _tmp0_; -#line 471 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp1_ = option; -#line 471 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp2_ = _tmp1_->type; -#line 471 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - g_return_if_fail (_tmp2_ == SANE_TYPE_FIXED); -#line 473 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp3_ = option; -#line 473 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp4_ = _tmp3_->constraint_type; -#line 473 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - if (_tmp4_ == SANE_CONSTRAINT_RANGE) { -#line 5895 "scanner.c" - gdouble min = 0.0; - SANE_Option_Descriptor* _tmp5_ = NULL; - SANE_Range* _tmp6_ = NULL; - SANE_Word _tmp7_ = {0}; - gdouble _tmp8_ = 0.0; - gdouble max = 0.0; - SANE_Option_Descriptor* _tmp9_ = NULL; - SANE_Range* _tmp10_ = NULL; - SANE_Word _tmp11_ = {0}; - gdouble _tmp12_ = 0.0; - gdouble _tmp13_ = 0.0; - gdouble _tmp14_ = 0.0; - gdouble _tmp16_ = 0.0; - gdouble _tmp17_ = 0.0; -#line 475 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp5_ = option; -#line 475 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp6_ = _tmp5_->constraint.range; -#line 475 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp7_ = _tmp6_->min; -#line 475 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp8_ = SANE_UNFIX ((SANE_Fixed) _tmp7_); -#line 475 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - min = _tmp8_; -#line 476 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp9_ = option; -#line 476 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp10_ = _tmp9_->constraint.range; -#line 476 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp11_ = _tmp10_->max; -#line 476 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp12_ = SANE_UNFIX ((SANE_Fixed) _tmp11_); -#line 476 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - max = _tmp12_; -#line 478 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp13_ = v; -#line 478 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp14_ = min; -#line 478 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - if (_tmp13_ < _tmp14_) { -#line 5936 "scanner.c" - gdouble _tmp15_ = 0.0; -#line 479 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp15_ = min; -#line 479 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - v = _tmp15_; -#line 5942 "scanner.c" - } -#line 480 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp16_ = v; -#line 480 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp17_ = max; -#line 480 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - if (_tmp16_ > _tmp17_) { -#line 5950 "scanner.c" - gdouble _tmp18_ = 0.0; -#line 481 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp18_ = max; -#line 481 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - v = _tmp18_; -#line 5956 "scanner.c" - } - } else { - SANE_Option_Descriptor* _tmp19_ = NULL; - SANE_Constraint_Type _tmp20_ = 0; -#line 483 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp19_ = option; -#line 483 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp20_ = _tmp19_->constraint_type; -#line 483 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - if (_tmp20_ == SANE_CONSTRAINT_WORD_LIST) { -#line 5967 "scanner.c" - gdouble distance = 0.0; - gdouble nearest = 0.0; - gdouble _tmp40_ = 0.0; -#line 485 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - distance = DBL_MAX; -#line 485 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - nearest = 0.0; -#line 5975 "scanner.c" - { - gint i = 0; -#line 488 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - i = 0; -#line 5980 "scanner.c" - { - gboolean _tmp21_ = FALSE; -#line 488 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp21_ = TRUE; -#line 488 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - while (TRUE) { -#line 5987 "scanner.c" - gint _tmp23_ = 0; - SANE_Option_Descriptor* _tmp24_ = NULL; - SANE_Word* _tmp25_ = NULL; - gint _tmp25__length1 = 0; - SANE_Word _tmp26_ = {0}; - gdouble x = 0.0; - SANE_Option_Descriptor* _tmp27_ = NULL; - SANE_Word* _tmp28_ = NULL; - gint _tmp28__length1 = 0; - gint _tmp29_ = 0; - SANE_Word _tmp30_ = {0}; - gdouble _tmp31_ = 0.0; - gdouble _tmp32_ = 0.0; - gdouble _tmp33_ = 0.0; - gdouble _tmp34_ = 0.0; - gdouble _tmp35_ = 0.0; -#line 488 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - if (!_tmp21_) { -#line 6006 "scanner.c" - gint _tmp22_ = 0; -#line 488 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp22_ = i; -#line 488 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - i = _tmp22_ + 1; -#line 6012 "scanner.c" - } -#line 488 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp21_ = FALSE; -#line 488 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp23_ = i; -#line 488 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp24_ = option; -#line 488 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp25_ = _tmp24_->constraint.word_list; -#line 488 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp25__length1 = -1; -#line 488 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp26_ = _tmp25_[0]; -#line 488 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - if (!(((SANE_Word) _tmp23_) < _tmp26_)) { -#line 488 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - break; -#line 6030 "scanner.c" - } -#line 490 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp27_ = option; -#line 490 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp28_ = _tmp27_->constraint.word_list; -#line 490 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp28__length1 = -1; -#line 490 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp29_ = i; -#line 490 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp30_ = _tmp28_[_tmp29_ + 1]; -#line 490 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp31_ = SANE_UNFIX ((SANE_Fixed) _tmp30_); -#line 490 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - x = _tmp31_; -#line 491 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp32_ = x; -#line 491 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp33_ = v; -#line 491 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp34_ = fabs (_tmp32_ - _tmp33_); -#line 491 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp35_ = distance; -#line 491 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - if (_tmp34_ < _tmp35_) { -#line 6056 "scanner.c" - gdouble _tmp36_ = 0.0; - gdouble _tmp37_ = 0.0; - gdouble _tmp38_ = 0.0; - gdouble _tmp39_ = 0.0; -#line 493 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp36_ = x; -#line 493 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp37_ = v; -#line 493 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp38_ = fabs (_tmp36_ - _tmp37_); -#line 493 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - distance = _tmp38_; -#line 494 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp39_ = x; -#line 494 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - nearest = _tmp39_; -#line 6073 "scanner.c" - } - } - } - } -#line 497 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp40_ = nearest; -#line 497 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - v = _tmp40_; -#line 6082 "scanner.c" - } - } -#line 500 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp41_ = v; -#line 500 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp42_ = SANE_FIX (_tmp41_); -#line 500 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - v_fixed = _tmp42_; -#line 501 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp43_ = handle; -#line 501 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp44_ = option_index; -#line 501 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp45_ = sane_control_option (_tmp43_, _tmp44_, SANE_ACTION_SET_VALUE, &v_fixed, NULL); -#line 501 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - status = _tmp45_; -#line 502 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp46_ = option_index; -#line 502 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp47_ = value; -#line 502 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp48_ = sane_status_to_string (status); -#line 502 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp49_ = _tmp48_; -#line 502 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp50_ = SANE_UNFIX (v_fixed); -#line 502 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - g_debug ("scanner.vala:502: sane_control_option (%d, SANE_ACTION_SET_VALUE, %f) " \ -"-> (%s, %f)", (gint) _tmp46_, _tmp47_, _tmp49_, _tmp50_); -#line 502 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _g_free0 (_tmp49_); -#line 504 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp51_ = SANE_UNFIX (v_fixed); -#line 504 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _vala_result = _tmp51_; -#line 466 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - if (_result_) { -#line 466 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - *_result_ = _vala_result; -#line 6121 "scanner.c" - } -} - - -static void scanner_set_fixed_or_int_option (Scanner* self, SANE_Handle handle, SANE_Option_Descriptor* option, SANE_Int option_index, gdouble value, gdouble* _result_) { - gdouble _vala_result = 0.0; - SANE_Option_Descriptor* _tmp0_ = NULL; - SANE_Value_Type _tmp1_ = 0; -#line 507 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - g_return_if_fail (self != NULL); -#line 507 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - g_return_if_fail (option != NULL); -#line 509 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp0_ = option; -#line 509 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp1_ = _tmp0_->type; -#line 509 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - if (_tmp1_ == SANE_TYPE_FIXED) { -#line 6140 "scanner.c" - SANE_Handle _tmp2_ = {0}; - SANE_Option_Descriptor* _tmp3_ = NULL; - SANE_Int _tmp4_ = {0}; - gdouble _tmp5_ = 0.0; - gdouble _tmp6_ = 0.0; -#line 510 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp2_ = handle; -#line 510 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp3_ = option; -#line 510 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp4_ = option_index; -#line 510 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp5_ = value; -#line 510 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - scanner_set_fixed_option (self, _tmp2_, _tmp3_, _tmp4_, _tmp5_, &_tmp6_); -#line 510 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _vala_result = _tmp6_; -#line 6158 "scanner.c" - } else { - SANE_Option_Descriptor* _tmp7_ = NULL; - SANE_Value_Type _tmp8_ = 0; -#line 511 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp7_ = option; -#line 511 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp8_ = _tmp7_->type; -#line 511 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - if (_tmp8_ == SANE_TYPE_INT) { -#line 6168 "scanner.c" - gint r = 0; - SANE_Handle _tmp9_ = {0}; - SANE_Option_Descriptor* _tmp10_ = NULL; - SANE_Int _tmp11_ = {0}; - gdouble _tmp12_ = 0.0; - gdouble _tmp13_ = 0.0; - gint _tmp14_ = 0; - gint _tmp15_ = 0; -#line 514 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp9_ = handle; -#line 514 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp10_ = option; -#line 514 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp11_ = option_index; -#line 514 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp12_ = value; -#line 514 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp13_ = round (_tmp12_); -#line 514 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - scanner_set_int_option (self, _tmp9_, _tmp10_, _tmp11_, (gint) _tmp13_, &_tmp14_); -#line 514 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - r = _tmp14_; -#line 515 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp15_ = r; -#line 515 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _vala_result = (gdouble) _tmp15_; -#line 6195 "scanner.c" - } else { -#line 519 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _vala_result = 0.0; -#line 520 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - g_warning ("scanner.vala:520: Unable to set unsupported option type"); -#line 6201 "scanner.c" - } - } -#line 507 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - if (_result_) { -#line 507 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - *_result_ = _vala_result; -#line 6208 "scanner.c" - } -} - - -static void scanner_set_option_to_max (Scanner* self, SANE_Handle handle, SANE_Option_Descriptor* option, SANE_Int option_index) { - SANE_Option_Descriptor* _tmp0_ = NULL; - SANE_Constraint_Type _tmp1_ = 0; - SANE_Status status = 0; - SANE_Handle _tmp2_ = {0}; - SANE_Int _tmp3_ = {0}; - SANE_Option_Descriptor* _tmp4_ = NULL; - SANE_Range* _tmp5_ = NULL; - SANE_Status _tmp6_ = 0; - SANE_Int _tmp7_ = {0}; - SANE_Status _tmp8_ = 0; - gchar* _tmp9_ = NULL; - gchar* _tmp10_ = NULL; -#line 524 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - g_return_if_fail (self != NULL); -#line 524 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - g_return_if_fail (option != NULL); -#line 526 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp0_ = option; -#line 526 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp1_ = _tmp0_->constraint_type; -#line 526 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - if (_tmp1_ != SANE_CONSTRAINT_RANGE) { -#line 527 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - return; -#line 6238 "scanner.c" - } -#line 529 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp2_ = handle; -#line 529 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp3_ = option_index; -#line 529 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp4_ = option; -#line 529 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp5_ = _tmp4_->constraint.range; -#line 529 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp6_ = sane_control_option (_tmp2_, _tmp3_, SANE_ACTION_SET_VALUE, &_tmp5_->max, NULL); -#line 529 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - status = _tmp6_; -#line 530 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp7_ = option_index; -#line 530 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp8_ = status; -#line 530 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp9_ = sane_status_to_string (_tmp8_); -#line 530 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp10_ = _tmp9_; -#line 530 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - g_debug ("scanner.vala:530: sane_control_option (%d, SANE_ACTION_SET_VALUE, opti" \ -"on.range.max) -> (%s)", (gint) _tmp7_, _tmp10_); -#line 530 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _g_free0 (_tmp10_); -#line 6264 "scanner.c" -} - - -static gchar string_get (const gchar* self, glong index) { - gchar result = '\0'; - glong _tmp0_ = 0L; - gchar _tmp1_ = '\0'; -#line 1086 "/usr/share/vala-0.34/vapi/glib-2.0.vapi" - g_return_val_if_fail (self != NULL, '\0'); -#line 1087 "/usr/share/vala-0.34/vapi/glib-2.0.vapi" - _tmp0_ = index; -#line 1087 "/usr/share/vala-0.34/vapi/glib-2.0.vapi" - _tmp1_ = ((gchar*) self)[_tmp0_]; -#line 1087 "/usr/share/vala-0.34/vapi/glib-2.0.vapi" - result = _tmp1_; -#line 1087 "/usr/share/vala-0.34/vapi/glib-2.0.vapi" - return result; -#line 6282 "scanner.c" -} - - -static gboolean scanner_set_string_option (Scanner* self, SANE_Handle handle, SANE_Option_Descriptor* option, SANE_Int option_index, const gchar* value, gchar** _result_) { - gchar* _vala_result = NULL; - gboolean result = FALSE; - gchar* _tmp0_ = NULL; - SANE_Option_Descriptor* _tmp1_ = NULL; - SANE_Value_Type _tmp2_ = 0; - gchar* s = NULL; - SANE_Option_Descriptor* _tmp3_ = NULL; - SANE_Int _tmp4_ = {0}; - gchar* _tmp5_ = NULL; - gint s_length1 = 0; - gint _s_size_ = 0; - gint i = 0; - gchar* _tmp21_ = NULL; - gint _tmp21__length1 = 0; - gint _tmp22_ = 0; - gchar _tmp23_ = '\0'; - SANE_Status status = 0; - SANE_Handle _tmp24_ = {0}; - SANE_Int _tmp25_ = {0}; - gchar* _tmp26_ = NULL; - gint _tmp26__length1 = 0; - SANE_Status _tmp27_ = 0; - gchar* _tmp28_ = NULL; - gint _tmp28__length1 = 0; - gchar* _tmp29_ = NULL; - SANE_Int _tmp30_ = {0}; - const gchar* _tmp31_ = NULL; - gchar* _tmp32_ = NULL; - gchar* _tmp33_ = NULL; - const gchar* _tmp34_ = NULL; -#line 533 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - g_return_val_if_fail (self != NULL, FALSE); -#line 533 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - g_return_val_if_fail (option != NULL, FALSE); -#line 533 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - g_return_val_if_fail (value != NULL, FALSE); -#line 535 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp0_ = g_strdup (""); -#line 535 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _g_free0 (_vala_result); -#line 535 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _vala_result = _tmp0_; -#line 537 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp1_ = option; -#line 537 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp2_ = _tmp1_->type; -#line 537 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - g_return_val_if_fail (_tmp2_ == SANE_TYPE_STRING, FALSE); -#line 539 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp3_ = option; -#line 539 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp4_ = _tmp3_->size; -#line 539 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp5_ = g_new0 (gchar, _tmp4_); -#line 539 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - s = _tmp5_; -#line 539 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - s_length1 = _tmp4_; -#line 539 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _s_size_ = s_length1; -#line 540 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - i = 0; -#line 6349 "scanner.c" - { - gboolean _tmp6_ = FALSE; -#line 541 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp6_ = TRUE; -#line 541 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - while (TRUE) { -#line 6356 "scanner.c" - gboolean _tmp8_ = FALSE; - gint _tmp9_ = 0; - SANE_Option_Descriptor* _tmp10_ = NULL; - SANE_Int _tmp11_ = {0}; - gchar* _tmp15_ = NULL; - gint _tmp15__length1 = 0; - gint _tmp16_ = 0; - const gchar* _tmp17_ = NULL; - gint _tmp18_ = 0; - gchar _tmp19_ = '\0'; - gchar _tmp20_ = '\0'; -#line 541 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - if (!_tmp6_) { -#line 6370 "scanner.c" - gint _tmp7_ = 0; -#line 541 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp7_ = i; -#line 541 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - i = _tmp7_ + 1; -#line 6376 "scanner.c" - } -#line 541 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp6_ = FALSE; -#line 541 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp9_ = i; -#line 541 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp10_ = option; -#line 541 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp11_ = _tmp10_->size; -#line 541 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - if (((SANE_Int) _tmp9_) < (_tmp11_ - 1)) { -#line 6388 "scanner.c" - const gchar* _tmp12_ = NULL; - gint _tmp13_ = 0; - gchar _tmp14_ = '\0'; -#line 541 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp12_ = value; -#line 541 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp13_ = i; -#line 541 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp14_ = string_get (_tmp12_, (glong) _tmp13_); -#line 541 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp8_ = _tmp14_ != '\0'; -#line 6400 "scanner.c" - } else { -#line 541 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp8_ = FALSE; -#line 6404 "scanner.c" - } -#line 541 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - if (!_tmp8_) { -#line 541 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - break; -#line 6410 "scanner.c" - } -#line 542 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp15_ = s; -#line 542 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp15__length1 = s_length1; -#line 542 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp16_ = i; -#line 542 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp17_ = value; -#line 542 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp18_ = i; -#line 542 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp19_ = string_get (_tmp17_, (glong) _tmp18_); -#line 542 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp15_[_tmp16_] = _tmp19_; -#line 542 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp20_ = _tmp15_[_tmp16_]; -#line 6428 "scanner.c" - } - } -#line 543 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp21_ = s; -#line 543 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp21__length1 = s_length1; -#line 543 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp22_ = i; -#line 543 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp21_[_tmp22_] = '\0'; -#line 543 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp23_ = _tmp21_[_tmp22_]; -#line 544 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp24_ = handle; -#line 544 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp25_ = option_index; -#line 544 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp26_ = s; -#line 544 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp26__length1 = s_length1; -#line 544 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp27_ = sane_control_option (_tmp24_, _tmp25_, SANE_ACTION_SET_VALUE, _tmp26_, NULL); -#line 544 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - status = _tmp27_; -#line 545 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp28_ = s; -#line 545 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp28__length1 = s_length1; -#line 545 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp29_ = g_strdup ((const gchar*) _tmp28_); -#line 545 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _g_free0 (_vala_result); -#line 545 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _vala_result = _tmp29_; -#line 546 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp30_ = option_index; -#line 546 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp31_ = value; -#line 546 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp32_ = sane_status_to_string (status); -#line 546 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp33_ = _tmp32_; -#line 546 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp34_ = _vala_result; -#line 546 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - g_debug ("scanner.vala:546: sane_control_option (%d, SANE_ACTION_SET_VALUE, \"%s" \ -"\") -> (%s, \"%s\")", (gint) _tmp30_, _tmp31_, _tmp33_, _tmp34_); -#line 546 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _g_free0 (_tmp33_); -#line 548 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - result = status == SANE_STATUS_GOOD; -#line 548 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - s = (g_free (s), NULL); -#line 548 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - if (_result_) { -#line 548 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - *_result_ = _vala_result; -#line 6485 "scanner.c" - } else { -#line 548 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _g_free0 (_vala_result); -#line 6489 "scanner.c" - } -#line 548 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - return result; -#line 6493 "scanner.c" -} - - -static gboolean scanner_set_constrained_string_option (Scanner* self, SANE_Handle handle, SANE_Option_Descriptor* option, SANE_Int option_index, gchar** values, int values_length1, gchar** _result_) { - gchar* _vala_result = NULL; - gboolean result = FALSE; - SANE_Option_Descriptor* _tmp0_ = NULL; - SANE_Value_Type _tmp1_ = 0; - SANE_Option_Descriptor* _tmp2_ = NULL; - SANE_Constraint_Type _tmp3_ = 0; - gchar* _tmp34_ = NULL; -#line 551 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - g_return_val_if_fail (self != NULL, FALSE); -#line 551 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - g_return_val_if_fail (option != NULL, FALSE); -#line 553 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp0_ = option; -#line 553 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp1_ = _tmp0_->type; -#line 553 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - g_return_val_if_fail (_tmp1_ == SANE_TYPE_STRING, FALSE); -#line 554 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp2_ = option; -#line 554 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp3_ = _tmp2_->constraint_type; -#line 554 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - g_return_val_if_fail (_tmp3_ == SANE_CONSTRAINT_STRING_LIST, FALSE); -#line 6521 "scanner.c" - { - gint i = 0; -#line 556 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - i = 0; -#line 6526 "scanner.c" - { - gboolean _tmp4_ = FALSE; -#line 556 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp4_ = TRUE; -#line 556 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - while (TRUE) { -#line 6533 "scanner.c" - gchar** _tmp6_ = NULL; - gint _tmp6__length1 = 0; - gint _tmp7_ = 0; - const gchar* _tmp8_ = NULL; - gint j = 0; - SANE_Option_Descriptor* _tmp22_ = NULL; - gchar** _tmp23_ = NULL; - gint _tmp23__length1 = 0; - gint _tmp24_ = 0; - const gchar* _tmp25_ = NULL; -#line 556 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - if (!_tmp4_) { -#line 6546 "scanner.c" - gint _tmp5_ = 0; -#line 556 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp5_ = i; -#line 556 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - i = _tmp5_ + 1; -#line 6552 "scanner.c" - } -#line 556 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp4_ = FALSE; -#line 556 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp6_ = values; -#line 556 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp6__length1 = values_length1; -#line 556 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp7_ = i; -#line 556 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp8_ = _tmp6_[_tmp7_]; -#line 556 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - if (!(_tmp8_ != NULL)) { -#line 556 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - break; -#line 6568 "scanner.c" - } -#line 558 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - j = 0; -#line 6572 "scanner.c" - { - gboolean _tmp9_ = FALSE; -#line 559 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp9_ = TRUE; -#line 559 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - while (TRUE) { -#line 6579 "scanner.c" - SANE_Option_Descriptor* _tmp11_ = NULL; - gchar** _tmp12_ = NULL; - gint _tmp12__length1 = 0; - gint _tmp13_ = 0; - const gchar* _tmp14_ = NULL; - gchar** _tmp15_ = NULL; - gint _tmp15__length1 = 0; - gint _tmp16_ = 0; - const gchar* _tmp17_ = NULL; - SANE_Option_Descriptor* _tmp18_ = NULL; - gchar** _tmp19_ = NULL; - gint _tmp19__length1 = 0; - gint _tmp20_ = 0; - const gchar* _tmp21_ = NULL; -#line 559 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - if (!_tmp9_) { -#line 6596 "scanner.c" - gint _tmp10_ = 0; -#line 559 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp10_ = j; -#line 559 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - j = _tmp10_ + 1; -#line 6602 "scanner.c" - } -#line 559 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp9_ = FALSE; -#line 559 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp11_ = option; -#line 559 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp12_ = _tmp11_->constraint.string_list; -#line 559 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp12__length1 = _vala_array_length (_tmp11_->constraint.string_list); -#line 559 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp13_ = j; -#line 559 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp14_ = _tmp12_[_tmp13_]; -#line 559 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - if (!(_tmp14_ != NULL)) { -#line 559 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - break; -#line 6620 "scanner.c" - } -#line 561 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp15_ = values; -#line 561 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp15__length1 = values_length1; -#line 561 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp16_ = i; -#line 561 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp17_ = _tmp15_[_tmp16_]; -#line 561 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp18_ = option; -#line 561 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp19_ = _tmp18_->constraint.string_list; -#line 561 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp19__length1 = _vala_array_length (_tmp18_->constraint.string_list); -#line 561 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp20_ = j; -#line 561 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp21_ = _tmp19_[_tmp20_]; -#line 561 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - if (g_strcmp0 (_tmp17_, _tmp21_) == 0) { -#line 562 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - break; -#line 6644 "scanner.c" - } - } - } -#line 565 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp22_ = option; -#line 565 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp23_ = _tmp22_->constraint.string_list; -#line 565 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp23__length1 = _vala_array_length (_tmp22_->constraint.string_list); -#line 565 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp24_ = j; -#line 565 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp25_ = _tmp23_[_tmp24_]; -#line 565 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - if (_tmp25_ != NULL) { -#line 6660 "scanner.c" - SANE_Handle _tmp26_ = {0}; - SANE_Option_Descriptor* _tmp27_ = NULL; - SANE_Int _tmp28_ = {0}; - gchar** _tmp29_ = NULL; - gint _tmp29__length1 = 0; - gint _tmp30_ = 0; - const gchar* _tmp31_ = NULL; - gchar* _tmp32_ = NULL; - gboolean _tmp33_ = FALSE; -#line 566 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp26_ = handle; -#line 566 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp27_ = option; -#line 566 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp28_ = option_index; -#line 566 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp29_ = values; -#line 566 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp29__length1 = values_length1; -#line 566 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp30_ = i; -#line 566 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp31_ = _tmp29_[_tmp30_]; -#line 566 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp33_ = scanner_set_string_option (self, _tmp26_, _tmp27_, _tmp28_, _tmp31_, &_tmp32_); -#line 566 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _g_free0 (_vala_result); -#line 566 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _vala_result = _tmp32_; -#line 566 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - result = _tmp33_; -#line 566 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - if (_result_) { -#line 566 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - *_result_ = _vala_result; -#line 6696 "scanner.c" - } else { -#line 566 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _g_free0 (_vala_result); -#line 6700 "scanner.c" - } -#line 566 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - return result; -#line 6704 "scanner.c" - } - } - } - } -#line 569 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp34_ = g_strdup (""); -#line 569 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _g_free0 (_vala_result); -#line 569 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _vala_result = _tmp34_; -#line 570 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - result = FALSE; -#line 570 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - if (_result_) { -#line 570 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - *_result_ = _vala_result; -#line 6721 "scanner.c" - } else { -#line 570 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _g_free0 (_vala_result); -#line 6725 "scanner.c" - } -#line 570 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - return result; -#line 6729 "scanner.c" -} - - -static void scanner_log_option (Scanner* self, SANE_Int index, SANE_Option_Descriptor* option) { - gchar* s = NULL; - SANE_Int _tmp0_ = {0}; - gchar* _tmp1_ = NULL; - SANE_Option_Descriptor* _tmp2_ = NULL; - const gchar* _tmp3_ = NULL; - SANE_Option_Descriptor* _tmp10_ = NULL; - const gchar* _tmp11_ = NULL; - SANE_Option_Descriptor* _tmp18_ = NULL; - SANE_Value_Type _tmp19_ = 0; - const gchar* _tmp38_ = NULL; - SANE_Option_Descriptor* _tmp39_ = NULL; - SANE_Int _tmp40_ = {0}; - gchar* _tmp41_ = NULL; - gchar* _tmp42_ = NULL; - gchar* _tmp43_ = NULL; - SANE_Option_Descriptor* _tmp44_ = NULL; - SANE_Unit _tmp45_ = 0; - SANE_Option_Descriptor* _tmp64_ = NULL; - SANE_Constraint_Type _tmp65_ = 0; - SANE_Int cap = {0}; - SANE_Option_Descriptor* _tmp149_ = NULL; - SANE_Int _tmp150_ = {0}; - SANE_Int _tmp151_ = {0}; - const gchar* _tmp216_ = NULL; - SANE_Option_Descriptor* _tmp217_ = NULL; - const gchar* _tmp218_ = NULL; -#line 573 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - g_return_if_fail (self != NULL); -#line 573 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - g_return_if_fail (option != NULL); -#line 575 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp0_ = index; -#line 575 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp1_ = g_strdup_printf ("Option %d:", (gint) _tmp0_); -#line 575 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - s = _tmp1_; -#line 577 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp2_ = option; -#line 577 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp3_ = _tmp2_->name; -#line 577 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - if (g_strcmp0 (_tmp3_, "") != 0) { -#line 6776 "scanner.c" - const gchar* _tmp4_ = NULL; - SANE_Option_Descriptor* _tmp5_ = NULL; - const gchar* _tmp6_ = NULL; - gchar* _tmp7_ = NULL; - gchar* _tmp8_ = NULL; - gchar* _tmp9_ = NULL; -#line 578 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp4_ = s; -#line 578 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp5_ = option; -#line 578 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp6_ = _tmp5_->name; -#line 578 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp7_ = g_strdup_printf (" name='%s'", _tmp6_); -#line 578 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp8_ = _tmp7_; -#line 578 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp9_ = g_strconcat (_tmp4_, _tmp8_, NULL); -#line 578 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _g_free0 (s); -#line 578 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - s = _tmp9_; -#line 578 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _g_free0 (_tmp8_); -#line 6801 "scanner.c" - } -#line 580 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp10_ = option; -#line 580 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp11_ = _tmp10_->title; -#line 580 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - if (g_strcmp0 (_tmp11_, "") != 0) { -#line 6809 "scanner.c" - const gchar* _tmp12_ = NULL; - SANE_Option_Descriptor* _tmp13_ = NULL; - const gchar* _tmp14_ = NULL; - gchar* _tmp15_ = NULL; - gchar* _tmp16_ = NULL; - gchar* _tmp17_ = NULL; -#line 581 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp12_ = s; -#line 581 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp13_ = option; -#line 581 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp14_ = _tmp13_->title; -#line 581 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp15_ = g_strdup_printf (" title='%s'", _tmp14_); -#line 581 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp16_ = _tmp15_; -#line 581 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp17_ = g_strconcat (_tmp12_, _tmp16_, NULL); -#line 581 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _g_free0 (s); -#line 581 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - s = _tmp17_; -#line 581 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _g_free0 (_tmp16_); -#line 6834 "scanner.c" - } -#line 583 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp18_ = option; -#line 583 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp19_ = _tmp18_->type; -#line 583 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - switch (_tmp19_) { -#line 583 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - case SANE_TYPE_BOOL: -#line 6844 "scanner.c" - { - const gchar* _tmp20_ = NULL; - gchar* _tmp21_ = NULL; -#line 586 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp20_ = s; -#line 586 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp21_ = g_strconcat (_tmp20_, " type=bool", NULL); -#line 586 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _g_free0 (s); -#line 586 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - s = _tmp21_; -#line 587 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - break; -#line 6858 "scanner.c" - } -#line 583 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - case SANE_TYPE_INT: -#line 6862 "scanner.c" - { - const gchar* _tmp22_ = NULL; - gchar* _tmp23_ = NULL; -#line 589 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp22_ = s; -#line 589 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp23_ = g_strconcat (_tmp22_, " type=int", NULL); -#line 589 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _g_free0 (s); -#line 589 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - s = _tmp23_; -#line 590 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - break; -#line 6876 "scanner.c" - } -#line 583 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - case SANE_TYPE_FIXED: -#line 6880 "scanner.c" - { - const gchar* _tmp24_ = NULL; - gchar* _tmp25_ = NULL; -#line 592 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp24_ = s; -#line 592 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp25_ = g_strconcat (_tmp24_, " type=fixed", NULL); -#line 592 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _g_free0 (s); -#line 592 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - s = _tmp25_; -#line 593 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - break; -#line 6894 "scanner.c" - } -#line 583 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - case SANE_TYPE_STRING: -#line 6898 "scanner.c" - { - const gchar* _tmp26_ = NULL; - gchar* _tmp27_ = NULL; -#line 595 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp26_ = s; -#line 595 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp27_ = g_strconcat (_tmp26_, " type=string", NULL); -#line 595 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _g_free0 (s); -#line 595 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - s = _tmp27_; -#line 596 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - break; -#line 6912 "scanner.c" - } -#line 583 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - case SANE_TYPE_BUTTON: -#line 6916 "scanner.c" - { - const gchar* _tmp28_ = NULL; - gchar* _tmp29_ = NULL; -#line 598 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp28_ = s; -#line 598 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp29_ = g_strconcat (_tmp28_, " type=button", NULL); -#line 598 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _g_free0 (s); -#line 598 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - s = _tmp29_; -#line 599 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - break; -#line 6930 "scanner.c" - } -#line 583 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - case SANE_TYPE_GROUP: -#line 6934 "scanner.c" - { - const gchar* _tmp30_ = NULL; - gchar* _tmp31_ = NULL; -#line 601 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp30_ = s; -#line 601 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp31_ = g_strconcat (_tmp30_, " type=group", NULL); -#line 601 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _g_free0 (s); -#line 601 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - s = _tmp31_; -#line 602 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - break; -#line 6948 "scanner.c" - } - default: - { - const gchar* _tmp32_ = NULL; - SANE_Option_Descriptor* _tmp33_ = NULL; - SANE_Value_Type _tmp34_ = 0; - gchar* _tmp35_ = NULL; - gchar* _tmp36_ = NULL; - gchar* _tmp37_ = NULL; -#line 604 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp32_ = s; -#line 604 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp33_ = option; -#line 604 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp34_ = _tmp33_->type; -#line 604 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp35_ = g_strdup_printf (" type=%d", (gint) _tmp34_); -#line 604 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp36_ = _tmp35_; -#line 604 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp37_ = g_strconcat (_tmp32_, _tmp36_, NULL); -#line 604 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _g_free0 (s); -#line 604 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - s = _tmp37_; -#line 604 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _g_free0 (_tmp36_); -#line 605 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - break; -#line 6978 "scanner.c" - } - } -#line 608 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp38_ = s; -#line 608 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp39_ = option; -#line 608 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp40_ = _tmp39_->size; -#line 608 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp41_ = g_strdup_printf (" size=%d", (gint) _tmp40_); -#line 608 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp42_ = _tmp41_; -#line 608 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp43_ = g_strconcat (_tmp38_, _tmp42_, NULL); -#line 608 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _g_free0 (s); -#line 608 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - s = _tmp43_; -#line 608 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _g_free0 (_tmp42_); -#line 610 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp44_ = option; -#line 610 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp45_ = _tmp44_->unit; -#line 610 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - switch (_tmp45_) { -#line 610 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - case SANE_UNIT_NONE: -#line 7007 "scanner.c" - { -#line 613 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - break; -#line 7011 "scanner.c" - } -#line 610 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - case SANE_UNIT_PIXEL: -#line 7015 "scanner.c" - { - const gchar* _tmp46_ = NULL; - gchar* _tmp47_ = NULL; -#line 615 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp46_ = s; -#line 615 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp47_ = g_strconcat (_tmp46_, " unit=pixels", NULL); -#line 615 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _g_free0 (s); -#line 615 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - s = _tmp47_; -#line 616 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - break; -#line 7029 "scanner.c" - } -#line 610 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - case SANE_UNIT_BIT: -#line 7033 "scanner.c" - { - const gchar* _tmp48_ = NULL; - gchar* _tmp49_ = NULL; -#line 618 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp48_ = s; -#line 618 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp49_ = g_strconcat (_tmp48_, " unit=bits", NULL); -#line 618 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _g_free0 (s); -#line 618 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - s = _tmp49_; -#line 619 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - break; -#line 7047 "scanner.c" - } -#line 610 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - case SANE_UNIT_MM: -#line 7051 "scanner.c" - { - const gchar* _tmp50_ = NULL; - gchar* _tmp51_ = NULL; -#line 621 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp50_ = s; -#line 621 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp51_ = g_strconcat (_tmp50_, " unit=mm", NULL); -#line 621 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _g_free0 (s); -#line 621 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - s = _tmp51_; -#line 622 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - break; -#line 7065 "scanner.c" - } -#line 610 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - case SANE_UNIT_DPI: -#line 7069 "scanner.c" - { - const gchar* _tmp52_ = NULL; - gchar* _tmp53_ = NULL; -#line 624 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp52_ = s; -#line 624 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp53_ = g_strconcat (_tmp52_, " unit=dpi", NULL); -#line 624 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _g_free0 (s); -#line 624 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - s = _tmp53_; -#line 625 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - break; -#line 7083 "scanner.c" - } -#line 610 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - case SANE_UNIT_PERCENT: -#line 7087 "scanner.c" - { - const gchar* _tmp54_ = NULL; - gchar* _tmp55_ = NULL; -#line 627 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp54_ = s; -#line 627 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp55_ = g_strconcat (_tmp54_, " unit=percent", NULL); -#line 627 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _g_free0 (s); -#line 627 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - s = _tmp55_; -#line 628 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - break; -#line 7101 "scanner.c" - } -#line 610 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - case SANE_UNIT_MICROSECOND: -#line 7105 "scanner.c" - { - const gchar* _tmp56_ = NULL; - gchar* _tmp57_ = NULL; -#line 630 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp56_ = s; -#line 630 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp57_ = g_strconcat (_tmp56_, " unit=microseconds", NULL); -#line 630 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _g_free0 (s); -#line 630 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - s = _tmp57_; -#line 631 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - break; -#line 7119 "scanner.c" - } - default: - { - const gchar* _tmp58_ = NULL; - SANE_Option_Descriptor* _tmp59_ = NULL; - SANE_Unit _tmp60_ = 0; - gchar* _tmp61_ = NULL; - gchar* _tmp62_ = NULL; - gchar* _tmp63_ = NULL; -#line 633 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp58_ = s; -#line 633 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp59_ = option; -#line 633 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp60_ = _tmp59_->unit; -#line 633 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp61_ = g_strdup_printf (" unit=%d", (gint) _tmp60_); -#line 633 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp62_ = _tmp61_; -#line 633 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp63_ = g_strconcat (_tmp58_, _tmp62_, NULL); -#line 633 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _g_free0 (s); -#line 633 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - s = _tmp63_; -#line 633 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _g_free0 (_tmp62_); -#line 634 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - break; -#line 7149 "scanner.c" - } - } -#line 637 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp64_ = option; -#line 637 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp65_ = _tmp64_->constraint_type; -#line 637 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - switch (_tmp65_) { -#line 637 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - case SANE_CONSTRAINT_RANGE: -#line 7160 "scanner.c" - { - SANE_Option_Descriptor* _tmp66_ = NULL; - SANE_Value_Type _tmp67_ = 0; -#line 640 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp66_ = option; -#line 640 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp67_ = _tmp66_->type; -#line 640 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - if (_tmp67_ == SANE_TYPE_FIXED) { -#line 7170 "scanner.c" - const gchar* _tmp68_ = NULL; - SANE_Option_Descriptor* _tmp69_ = NULL; - SANE_Range* _tmp70_ = NULL; - SANE_Word _tmp71_ = {0}; - gdouble _tmp72_ = 0.0; - SANE_Option_Descriptor* _tmp73_ = NULL; - SANE_Range* _tmp74_ = NULL; - SANE_Word _tmp75_ = {0}; - gdouble _tmp76_ = 0.0; - SANE_Option_Descriptor* _tmp77_ = NULL; - SANE_Range* _tmp78_ = NULL; - SANE_Word _tmp79_ = {0}; - gchar* _tmp80_ = NULL; - gchar* _tmp81_ = NULL; - gchar* _tmp82_ = NULL; -#line 641 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp68_ = s; -#line 641 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp69_ = option; -#line 641 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp70_ = _tmp69_->constraint.range; -#line 641 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp71_ = _tmp70_->min; -#line 641 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp72_ = SANE_UNFIX ((SANE_Fixed) _tmp71_); -#line 641 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp73_ = option; -#line 641 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp74_ = _tmp73_->constraint.range; -#line 641 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp75_ = _tmp74_->max; -#line 641 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp76_ = SANE_UNFIX ((SANE_Fixed) _tmp75_); -#line 641 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp77_ = option; -#line 641 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp78_ = _tmp77_->constraint.range; -#line 641 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp79_ = _tmp78_->quant; -#line 641 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp80_ = g_strdup_printf (" min=%f, max=%f, quant=%d", _tmp72_, _tmp76_, (gint) _tmp79_); -#line 641 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp81_ = _tmp80_; -#line 641 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp82_ = g_strconcat (_tmp68_, _tmp81_, NULL); -#line 641 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _g_free0 (s); -#line 641 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - s = _tmp82_; -#line 641 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _g_free0 (_tmp81_); -#line 7222 "scanner.c" - } else { - const gchar* _tmp83_ = NULL; - SANE_Option_Descriptor* _tmp84_ = NULL; - SANE_Range* _tmp85_ = NULL; - SANE_Word _tmp86_ = {0}; - SANE_Option_Descriptor* _tmp87_ = NULL; - SANE_Range* _tmp88_ = NULL; - SANE_Word _tmp89_ = {0}; - SANE_Option_Descriptor* _tmp90_ = NULL; - SANE_Range* _tmp91_ = NULL; - SANE_Word _tmp92_ = {0}; - gchar* _tmp93_ = NULL; - gchar* _tmp94_ = NULL; - gchar* _tmp95_ = NULL; -#line 643 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp83_ = s; -#line 643 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp84_ = option; -#line 643 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp85_ = _tmp84_->constraint.range; -#line 643 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp86_ = _tmp85_->min; -#line 643 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp87_ = option; -#line 643 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp88_ = _tmp87_->constraint.range; -#line 643 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp89_ = _tmp88_->max; -#line 643 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp90_ = option; -#line 643 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp91_ = _tmp90_->constraint.range; -#line 643 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp92_ = _tmp91_->quant; -#line 643 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp93_ = g_strdup_printf (" min=%d, max=%d, quant=%d", (gint) _tmp86_, (gint) _tmp89_, (gint) _tmp92_); -#line 643 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp94_ = _tmp93_; -#line 643 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp95_ = g_strconcat (_tmp83_, _tmp94_, NULL); -#line 643 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _g_free0 (s); -#line 643 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - s = _tmp95_; -#line 643 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _g_free0 (_tmp94_); -#line 7269 "scanner.c" - } -#line 644 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - break; -#line 7273 "scanner.c" - } -#line 637 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - case SANE_CONSTRAINT_WORD_LIST: -#line 7277 "scanner.c" - { - const gchar* _tmp96_ = NULL; - gchar* _tmp97_ = NULL; - const gchar* _tmp126_ = NULL; - gchar* _tmp127_ = NULL; -#line 646 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp96_ = s; -#line 646 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp97_ = g_strconcat (_tmp96_, " values=[", NULL); -#line 646 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _g_free0 (s); -#line 646 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - s = _tmp97_; -#line 7291 "scanner.c" - { - gint i = 0; -#line 647 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - i = 0; -#line 7296 "scanner.c" - { - gboolean _tmp98_ = FALSE; -#line 647 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp98_ = TRUE; -#line 647 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - while (TRUE) { -#line 7303 "scanner.c" - gint _tmp100_ = 0; - SANE_Option_Descriptor* _tmp101_ = NULL; - SANE_Word* _tmp102_ = NULL; - gint _tmp102__length1 = 0; - SANE_Word _tmp103_ = {0}; - gint _tmp104_ = 0; - SANE_Option_Descriptor* _tmp107_ = NULL; - SANE_Value_Type _tmp108_ = 0; -#line 647 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - if (!_tmp98_) { -#line 7314 "scanner.c" - gint _tmp99_ = 0; -#line 647 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp99_ = i; -#line 647 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - i = _tmp99_ + 1; -#line 7320 "scanner.c" - } -#line 647 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp98_ = FALSE; -#line 647 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp100_ = i; -#line 647 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp101_ = option; -#line 647 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp102_ = _tmp101_->constraint.word_list; -#line 647 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp102__length1 = -1; -#line 647 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp103_ = _tmp102_[0]; -#line 647 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - if (!(((SANE_Word) _tmp100_) < _tmp103_)) { -#line 647 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - break; -#line 7338 "scanner.c" - } -#line 649 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp104_ = i; -#line 649 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - if (_tmp104_ != 0) { -#line 7344 "scanner.c" - const gchar* _tmp105_ = NULL; - gchar* _tmp106_ = NULL; -#line 650 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp105_ = s; -#line 650 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp106_ = g_strconcat (_tmp105_, ", ", NULL); -#line 650 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _g_free0 (s); -#line 650 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - s = _tmp106_; -#line 7355 "scanner.c" - } -#line 651 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp107_ = option; -#line 651 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp108_ = _tmp107_->type; -#line 651 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - if (_tmp108_ == SANE_TYPE_INT) { -#line 7363 "scanner.c" - const gchar* _tmp109_ = NULL; - SANE_Option_Descriptor* _tmp110_ = NULL; - SANE_Word* _tmp111_ = NULL; - gint _tmp111__length1 = 0; - gint _tmp112_ = 0; - SANE_Word _tmp113_ = {0}; - gchar* _tmp114_ = NULL; - gchar* _tmp115_ = NULL; - gchar* _tmp116_ = NULL; -#line 652 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp109_ = s; -#line 652 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp110_ = option; -#line 652 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp111_ = _tmp110_->constraint.word_list; -#line 652 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp111__length1 = -1; -#line 652 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp112_ = i; -#line 652 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp113_ = _tmp111_[_tmp112_ + 1]; -#line 652 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp114_ = g_strdup_printf ("%d", (gint) _tmp113_); -#line 652 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp115_ = _tmp114_; -#line 652 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp116_ = g_strconcat (_tmp109_, _tmp115_, NULL); -#line 652 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _g_free0 (s); -#line 652 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - s = _tmp116_; -#line 652 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _g_free0 (_tmp115_); -#line 7397 "scanner.c" - } else { - const gchar* _tmp117_ = NULL; - SANE_Option_Descriptor* _tmp118_ = NULL; - SANE_Word* _tmp119_ = NULL; - gint _tmp119__length1 = 0; - gint _tmp120_ = 0; - SANE_Word _tmp121_ = {0}; - gdouble _tmp122_ = 0.0; - gchar* _tmp123_ = NULL; - gchar* _tmp124_ = NULL; - gchar* _tmp125_ = NULL; -#line 654 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp117_ = s; -#line 654 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp118_ = option; -#line 654 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp119_ = _tmp118_->constraint.word_list; -#line 654 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp119__length1 = -1; -#line 654 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp120_ = i; -#line 654 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp121_ = _tmp119_[_tmp120_ + 1]; -#line 654 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp122_ = SANE_UNFIX ((SANE_Fixed) _tmp121_); -#line 654 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp123_ = g_strdup_printf ("%f", _tmp122_); -#line 654 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp124_ = _tmp123_; -#line 654 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp125_ = g_strconcat (_tmp117_, _tmp124_, NULL); -#line 654 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _g_free0 (s); -#line 654 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - s = _tmp125_; -#line 654 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _g_free0 (_tmp124_); -#line 7435 "scanner.c" - } - } - } - } -#line 656 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp126_ = s; -#line 656 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp127_ = g_strconcat (_tmp126_, "]", NULL); -#line 656 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _g_free0 (s); -#line 656 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - s = _tmp127_; -#line 657 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - break; -#line 7450 "scanner.c" - } -#line 637 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - case SANE_CONSTRAINT_STRING_LIST: -#line 7454 "scanner.c" - { - const gchar* _tmp128_ = NULL; - gchar* _tmp129_ = NULL; - const gchar* _tmp147_ = NULL; - gchar* _tmp148_ = NULL; -#line 659 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp128_ = s; -#line 659 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp129_ = g_strconcat (_tmp128_, " values=[", NULL); -#line 659 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _g_free0 (s); -#line 659 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - s = _tmp129_; -#line 7468 "scanner.c" - { - gint i = 0; -#line 660 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - i = 0; -#line 7473 "scanner.c" - { - gboolean _tmp130_ = FALSE; -#line 660 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp130_ = TRUE; -#line 660 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - while (TRUE) { -#line 7480 "scanner.c" - SANE_Option_Descriptor* _tmp132_ = NULL; - gchar** _tmp133_ = NULL; - gint _tmp133__length1 = 0; - gint _tmp134_ = 0; - const gchar* _tmp135_ = NULL; - gint _tmp136_ = 0; - const gchar* _tmp139_ = NULL; - SANE_Option_Descriptor* _tmp140_ = NULL; - gchar** _tmp141_ = NULL; - gint _tmp141__length1 = 0; - gint _tmp142_ = 0; - const gchar* _tmp143_ = NULL; - gchar* _tmp144_ = NULL; - gchar* _tmp145_ = NULL; - gchar* _tmp146_ = NULL; -#line 660 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - if (!_tmp130_) { -#line 7498 "scanner.c" - gint _tmp131_ = 0; -#line 660 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp131_ = i; -#line 660 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - i = _tmp131_ + 1; -#line 7504 "scanner.c" - } -#line 660 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp130_ = FALSE; -#line 660 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp132_ = option; -#line 660 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp133_ = _tmp132_->constraint.string_list; -#line 660 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp133__length1 = _vala_array_length (_tmp132_->constraint.string_list); -#line 660 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp134_ = i; -#line 660 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp135_ = _tmp133_[_tmp134_]; -#line 660 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - if (!(_tmp135_ != NULL)) { -#line 660 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - break; -#line 7522 "scanner.c" - } -#line 662 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp136_ = i; -#line 662 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - if (_tmp136_ != 0) { -#line 7528 "scanner.c" - const gchar* _tmp137_ = NULL; - gchar* _tmp138_ = NULL; -#line 663 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp137_ = s; -#line 663 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp138_ = g_strconcat (_tmp137_, ", ", NULL); -#line 663 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _g_free0 (s); -#line 663 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - s = _tmp138_; -#line 7539 "scanner.c" - } -#line 664 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp139_ = s; -#line 664 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp140_ = option; -#line 664 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp141_ = _tmp140_->constraint.string_list; -#line 664 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp141__length1 = _vala_array_length (_tmp140_->constraint.string_list); -#line 664 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp142_ = i; -#line 664 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp143_ = _tmp141_[_tmp142_]; -#line 664 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp144_ = g_strdup_printf ("\"%s\"", _tmp143_); -#line 664 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp145_ = _tmp144_; -#line 664 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp146_ = g_strconcat (_tmp139_, _tmp145_, NULL); -#line 664 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _g_free0 (s); -#line 664 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - s = _tmp146_; -#line 664 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _g_free0 (_tmp145_); -#line 7565 "scanner.c" - } - } - } -#line 666 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp147_ = s; -#line 666 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp148_ = g_strconcat (_tmp147_, "]", NULL); -#line 666 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _g_free0 (s); -#line 666 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - s = _tmp148_; -#line 667 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - break; -#line 7579 "scanner.c" - } - default: - { -#line 669 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - break; -#line 7585 "scanner.c" - } - } -#line 672 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp149_ = option; -#line 672 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp150_ = _tmp149_->cap; -#line 672 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - cap = _tmp150_; -#line 673 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp151_ = cap; -#line 673 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - if (_tmp151_ != ((SANE_Int) 0)) { -#line 7598 "scanner.c" - gchar* caps = NULL; - gchar* _tmp152_ = NULL; - SANE_Int _tmp153_ = {0}; - SANE_Int _tmp160_ = {0}; - SANE_Int _tmp167_ = {0}; - SANE_Int _tmp174_ = {0}; - SANE_Int _tmp181_ = {0}; - SANE_Int _tmp188_ = {0}; - SANE_Int _tmp195_ = {0}; - SANE_Int _tmp202_ = {0}; - const gchar* _tmp211_ = NULL; - const gchar* _tmp212_ = NULL; - gchar* _tmp213_ = NULL; - gchar* _tmp214_ = NULL; - gchar* _tmp215_ = NULL; -#line 675 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp152_ = g_strdup (""); -#line 675 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - caps = _tmp152_; -#line 676 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp153_ = cap; -#line 676 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - if ((_tmp153_ & SANE_CAP_SOFT_SELECT) != ((SANE_Int) 0)) { -#line 7622 "scanner.c" - const gchar* _tmp154_ = NULL; - const gchar* _tmp157_ = NULL; - gchar* _tmp158_ = NULL; - SANE_Int _tmp159_ = {0}; -#line 678 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp154_ = caps; -#line 678 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - if (g_strcmp0 (_tmp154_, "") != 0) { -#line 7631 "scanner.c" - const gchar* _tmp155_ = NULL; - gchar* _tmp156_ = NULL; -#line 679 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp155_ = caps; -#line 679 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp156_ = g_strconcat (_tmp155_, ",", NULL); -#line 679 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _g_free0 (caps); -#line 679 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - caps = _tmp156_; -#line 7642 "scanner.c" - } -#line 680 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp157_ = caps; -#line 680 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp158_ = g_strconcat (_tmp157_, "soft-select", NULL); -#line 680 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _g_free0 (caps); -#line 680 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - caps = _tmp158_; -#line 681 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp159_ = cap; -#line 681 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - cap = _tmp159_ & (~SANE_CAP_SOFT_SELECT); -#line 7656 "scanner.c" - } -#line 683 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp160_ = cap; -#line 683 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - if ((_tmp160_ & SANE_CAP_HARD_SELECT) != ((SANE_Int) 0)) { -#line 7662 "scanner.c" - const gchar* _tmp161_ = NULL; - const gchar* _tmp164_ = NULL; - gchar* _tmp165_ = NULL; - SANE_Int _tmp166_ = {0}; -#line 685 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp161_ = caps; -#line 685 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - if (g_strcmp0 (_tmp161_, "") != 0) { -#line 7671 "scanner.c" - const gchar* _tmp162_ = NULL; - gchar* _tmp163_ = NULL; -#line 686 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp162_ = caps; -#line 686 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp163_ = g_strconcat (_tmp162_, ",", NULL); -#line 686 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _g_free0 (caps); -#line 686 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - caps = _tmp163_; -#line 7682 "scanner.c" - } -#line 687 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp164_ = caps; -#line 687 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp165_ = g_strconcat (_tmp164_, "hard-select", NULL); -#line 687 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _g_free0 (caps); -#line 687 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - caps = _tmp165_; -#line 688 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp166_ = cap; -#line 688 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - cap = _tmp166_ & (~SANE_CAP_HARD_SELECT); -#line 7696 "scanner.c" - } -#line 690 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp167_ = cap; -#line 690 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - if ((_tmp167_ & SANE_CAP_SOFT_DETECT) != ((SANE_Int) 0)) { -#line 7702 "scanner.c" - const gchar* _tmp168_ = NULL; - const gchar* _tmp171_ = NULL; - gchar* _tmp172_ = NULL; - SANE_Int _tmp173_ = {0}; -#line 692 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp168_ = caps; -#line 692 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - if (g_strcmp0 (_tmp168_, "") != 0) { -#line 7711 "scanner.c" - const gchar* _tmp169_ = NULL; - gchar* _tmp170_ = NULL; -#line 693 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp169_ = caps; -#line 693 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp170_ = g_strconcat (_tmp169_, ",", NULL); -#line 693 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _g_free0 (caps); -#line 693 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - caps = _tmp170_; -#line 7722 "scanner.c" - } -#line 694 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp171_ = caps; -#line 694 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp172_ = g_strconcat (_tmp171_, "soft-detect", NULL); -#line 694 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _g_free0 (caps); -#line 694 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - caps = _tmp172_; -#line 695 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp173_ = cap; -#line 695 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - cap = _tmp173_ & (~SANE_CAP_SOFT_DETECT); -#line 7736 "scanner.c" - } -#line 697 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp174_ = cap; -#line 697 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - if ((_tmp174_ & SANE_CAP_EMULATED) != ((SANE_Int) 0)) { -#line 7742 "scanner.c" - const gchar* _tmp175_ = NULL; - const gchar* _tmp178_ = NULL; - gchar* _tmp179_ = NULL; - SANE_Int _tmp180_ = {0}; -#line 699 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp175_ = caps; -#line 699 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - if (g_strcmp0 (_tmp175_, "") != 0) { -#line 7751 "scanner.c" - const gchar* _tmp176_ = NULL; - gchar* _tmp177_ = NULL; -#line 700 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp176_ = caps; -#line 700 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp177_ = g_strconcat (_tmp176_, ",", NULL); -#line 700 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _g_free0 (caps); -#line 700 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - caps = _tmp177_; -#line 7762 "scanner.c" - } -#line 701 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp178_ = caps; -#line 701 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp179_ = g_strconcat (_tmp178_, "emulated", NULL); -#line 701 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _g_free0 (caps); -#line 701 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - caps = _tmp179_; -#line 702 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp180_ = cap; -#line 702 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - cap = _tmp180_ & (~SANE_CAP_EMULATED); -#line 7776 "scanner.c" - } -#line 704 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp181_ = cap; -#line 704 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - if ((_tmp181_ & SANE_CAP_AUTOMATIC) != ((SANE_Int) 0)) { -#line 7782 "scanner.c" - const gchar* _tmp182_ = NULL; - const gchar* _tmp185_ = NULL; - gchar* _tmp186_ = NULL; - SANE_Int _tmp187_ = {0}; -#line 706 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp182_ = caps; -#line 706 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - if (g_strcmp0 (_tmp182_, "") != 0) { -#line 7791 "scanner.c" - const gchar* _tmp183_ = NULL; - gchar* _tmp184_ = NULL; -#line 707 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp183_ = caps; -#line 707 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp184_ = g_strconcat (_tmp183_, ",", NULL); -#line 707 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _g_free0 (caps); -#line 707 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - caps = _tmp184_; -#line 7802 "scanner.c" - } -#line 708 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp185_ = caps; -#line 708 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp186_ = g_strconcat (_tmp185_, "automatic", NULL); -#line 708 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _g_free0 (caps); -#line 708 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - caps = _tmp186_; -#line 709 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp187_ = cap; -#line 709 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - cap = _tmp187_ & (~SANE_CAP_AUTOMATIC); -#line 7816 "scanner.c" - } -#line 711 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp188_ = cap; -#line 711 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - if ((_tmp188_ & SANE_CAP_INACTIVE) != ((SANE_Int) 0)) { -#line 7822 "scanner.c" - const gchar* _tmp189_ = NULL; - const gchar* _tmp192_ = NULL; - gchar* _tmp193_ = NULL; - SANE_Int _tmp194_ = {0}; -#line 713 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp189_ = caps; -#line 713 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - if (g_strcmp0 (_tmp189_, "") != 0) { -#line 7831 "scanner.c" - const gchar* _tmp190_ = NULL; - gchar* _tmp191_ = NULL; -#line 714 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp190_ = caps; -#line 714 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp191_ = g_strconcat (_tmp190_, ",", NULL); -#line 714 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _g_free0 (caps); -#line 714 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - caps = _tmp191_; -#line 7842 "scanner.c" - } -#line 715 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp192_ = caps; -#line 715 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp193_ = g_strconcat (_tmp192_, "inactive", NULL); -#line 715 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _g_free0 (caps); -#line 715 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - caps = _tmp193_; -#line 716 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp194_ = cap; -#line 716 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - cap = _tmp194_ & (~SANE_CAP_INACTIVE); -#line 7856 "scanner.c" - } -#line 718 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp195_ = cap; -#line 718 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - if ((_tmp195_ & SANE_CAP_ADVANCED) != ((SANE_Int) 0)) { -#line 7862 "scanner.c" - const gchar* _tmp196_ = NULL; - const gchar* _tmp199_ = NULL; - gchar* _tmp200_ = NULL; - SANE_Int _tmp201_ = {0}; -#line 720 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp196_ = caps; -#line 720 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - if (g_strcmp0 (_tmp196_, "") != 0) { -#line 7871 "scanner.c" - const gchar* _tmp197_ = NULL; - gchar* _tmp198_ = NULL; -#line 721 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp197_ = caps; -#line 721 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp198_ = g_strconcat (_tmp197_, ",", NULL); -#line 721 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _g_free0 (caps); -#line 721 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - caps = _tmp198_; -#line 7882 "scanner.c" - } -#line 722 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp199_ = caps; -#line 722 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp200_ = g_strconcat (_tmp199_, "advanced", NULL); -#line 722 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _g_free0 (caps); -#line 722 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - caps = _tmp200_; -#line 723 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp201_ = cap; -#line 723 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - cap = _tmp201_ & (~SANE_CAP_ADVANCED); -#line 7896 "scanner.c" - } -#line 726 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp202_ = cap; -#line 726 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - if (_tmp202_ != ((SANE_Int) 0)) { -#line 7902 "scanner.c" - const gchar* _tmp203_ = NULL; - const gchar* _tmp206_ = NULL; - SANE_Int _tmp207_ = {0}; - gchar* _tmp208_ = NULL; - gchar* _tmp209_ = NULL; - gchar* _tmp210_ = NULL; -#line 728 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp203_ = caps; -#line 728 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - if (g_strcmp0 (_tmp203_, "") != 0) { -#line 7913 "scanner.c" - const gchar* _tmp204_ = NULL; - gchar* _tmp205_ = NULL; -#line 729 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp204_ = caps; -#line 729 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp205_ = g_strconcat (_tmp204_, ",", NULL); -#line 729 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _g_free0 (caps); -#line 729 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - caps = _tmp205_; -#line 7924 "scanner.c" - } -#line 730 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp206_ = caps; -#line 730 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp207_ = cap; -#line 730 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp208_ = g_strdup_printf ("%x", (guint) ((gint) _tmp207_)); -#line 730 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp209_ = _tmp208_; -#line 730 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp210_ = g_strconcat (_tmp206_, _tmp209_, NULL); -#line 730 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _g_free0 (caps); -#line 730 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - caps = _tmp210_; -#line 730 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _g_free0 (_tmp209_); -#line 7942 "scanner.c" - } -#line 732 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp211_ = s; -#line 732 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp212_ = caps; -#line 732 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp213_ = g_strconcat (" cap=", _tmp212_, NULL); -#line 732 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp214_ = _tmp213_; -#line 732 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp215_ = g_strconcat (_tmp211_, _tmp214_, NULL); -#line 732 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _g_free0 (s); -#line 732 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - s = _tmp215_; -#line 732 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _g_free0 (_tmp214_); -#line 673 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _g_free0 (caps); -#line 7962 "scanner.c" - } -#line 735 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp216_ = s; -#line 735 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - g_debug ("scanner.vala:735: %s", _tmp216_); -#line 737 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp217_ = option; -#line 737 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp218_ = _tmp217_->desc; -#line 737 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - if (_tmp218_ != NULL) { -#line 7974 "scanner.c" - SANE_Option_Descriptor* _tmp219_ = NULL; - const gchar* _tmp220_ = NULL; -#line 738 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp219_ = option; -#line 738 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp220_ = _tmp219_->desc; -#line 738 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - g_debug ("scanner.vala:738: Description: %s", _tmp220_); -#line 7983 "scanner.c" - } -#line 573 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _g_free0 (s); -#line 7987 "scanner.c" -} - - -static void scanner_authorization_cb (const gchar* resource, gchar* username, int username_length1, gchar* password, int password_length1) { - Scanner* _tmp0_ = NULL; - const gchar* _tmp1_ = NULL; - NotifyRequestAuthorization* _tmp2_ = NULL; - NotifyRequestAuthorization* _tmp3_ = NULL; - Credentials* credentials = NULL; - Scanner* _tmp4_ = NULL; - GAsyncQueue* _tmp5_ = NULL; - gpointer _tmp6_ = NULL; -#line 741 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - g_return_if_fail (resource != NULL); -#line 743 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp0_ = scanner_scanner_object; -#line 743 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp1_ = resource; -#line 743 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp2_ = notify_request_authorization_new (_tmp1_); -#line 743 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp3_ = _tmp2_; -#line 743 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - scanner_notify (_tmp0_, (Notify*) _tmp3_); -#line 743 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _notify_unref0 (_tmp3_); -#line 745 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp4_ = scanner_scanner_object; -#line 745 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp5_ = _tmp4_->priv->authorize_queue; -#line 745 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp6_ = g_async_queue_pop (_tmp5_); -#line 745 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - credentials = (Credentials*) _tmp6_; -#line 8022 "scanner.c" - { - gint i = 0; -#line 746 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - i = 0; -#line 8027 "scanner.c" - { - gboolean _tmp7_ = FALSE; -#line 746 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp7_ = TRUE; -#line 746 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - while (TRUE) { -#line 8034 "scanner.c" - gboolean _tmp9_ = FALSE; - Credentials* _tmp10_ = NULL; - const gchar* _tmp11_ = NULL; - gint _tmp12_ = 0; - gchar _tmp13_ = '\0'; - gchar* _tmp16_ = NULL; - gint _tmp16__length1 = 0; - gint _tmp17_ = 0; - Credentials* _tmp18_ = NULL; - const gchar* _tmp19_ = NULL; - gint _tmp20_ = 0; - gchar _tmp21_ = '\0'; - gchar _tmp22_ = '\0'; -#line 746 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - if (!_tmp7_) { -#line 8050 "scanner.c" - gint _tmp8_ = 0; -#line 746 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp8_ = i; -#line 746 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - i = _tmp8_ + 1; -#line 8056 "scanner.c" - } -#line 746 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp7_ = FALSE; -#line 746 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp10_ = credentials; -#line 746 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp11_ = _tmp10_->username; -#line 746 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp12_ = i; -#line 746 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp13_ = string_get (_tmp11_, (glong) _tmp12_); -#line 746 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - if (_tmp13_ != '\0') { -#line 8070 "scanner.c" - gint _tmp14_ = 0; - gint _tmp15_ = 0; -#line 746 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp14_ = i; -#line 746 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp15_ = SANE_MAX_USERNAME_LEN; -#line 746 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp9_ = _tmp14_ < _tmp15_; -#line 8079 "scanner.c" - } else { -#line 746 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp9_ = FALSE; -#line 8083 "scanner.c" - } -#line 746 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - if (!_tmp9_) { -#line 746 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - break; -#line 8089 "scanner.c" - } -#line 747 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp16_ = username; -#line 747 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp16__length1 = username_length1; -#line 747 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp17_ = i; -#line 747 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp18_ = credentials; -#line 747 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp19_ = _tmp18_->username; -#line 747 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp20_ = i; -#line 747 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp21_ = string_get (_tmp19_, (glong) _tmp20_); -#line 747 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp16_[_tmp17_] = _tmp21_; -#line 747 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp22_ = _tmp16_[_tmp17_]; -#line 8109 "scanner.c" - } - } - } - { - gint i = 0; -#line 748 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - i = 0; -#line 8117 "scanner.c" - { - gboolean _tmp23_ = FALSE; -#line 748 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp23_ = TRUE; -#line 748 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - while (TRUE) { -#line 8124 "scanner.c" - gboolean _tmp25_ = FALSE; - Credentials* _tmp26_ = NULL; - const gchar* _tmp27_ = NULL; - gint _tmp28_ = 0; - gchar _tmp29_ = '\0'; - gchar* _tmp32_ = NULL; - gint _tmp32__length1 = 0; - gint _tmp33_ = 0; - Credentials* _tmp34_ = NULL; - const gchar* _tmp35_ = NULL; - gint _tmp36_ = 0; - gchar _tmp37_ = '\0'; - gchar _tmp38_ = '\0'; -#line 748 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - if (!_tmp23_) { -#line 8140 "scanner.c" - gint _tmp24_ = 0; -#line 748 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp24_ = i; -#line 748 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - i = _tmp24_ + 1; -#line 8146 "scanner.c" - } -#line 748 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp23_ = FALSE; -#line 748 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp26_ = credentials; -#line 748 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp27_ = _tmp26_->password; -#line 748 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp28_ = i; -#line 748 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp29_ = string_get (_tmp27_, (glong) _tmp28_); -#line 748 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - if (_tmp29_ != '\0') { -#line 8160 "scanner.c" - gint _tmp30_ = 0; - gint _tmp31_ = 0; -#line 748 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp30_ = i; -#line 748 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp31_ = SANE_MAX_USERNAME_LEN; -#line 748 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp25_ = _tmp30_ < _tmp31_; -#line 8169 "scanner.c" - } else { -#line 748 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp25_ = FALSE; -#line 8173 "scanner.c" - } -#line 748 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - if (!_tmp25_) { -#line 748 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - break; -#line 8179 "scanner.c" - } -#line 749 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp32_ = password; -#line 749 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp32__length1 = password_length1; -#line 749 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp33_ = i; -#line 749 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp34_ = credentials; -#line 749 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp35_ = _tmp34_->password; -#line 749 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp36_ = i; -#line 749 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp37_ = string_get (_tmp35_, (glong) _tmp36_); -#line 749 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp32_[_tmp33_] = _tmp37_; -#line 749 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp38_ = _tmp32_[_tmp33_]; -#line 8199 "scanner.c" - } - } - } -#line 741 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _credentials_unref0 (credentials); -#line 8205 "scanner.c" -} - - -static gpointer _credentials_ref0 (gpointer self) { -#line 757 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - return self ? credentials_ref (self) : NULL; -#line 8212 "scanner.c" -} - - -void scanner_authorize (Scanner* self, const gchar* username, const gchar* password) { - Credentials* credentials = NULL; - Credentials* _tmp0_ = NULL; - const gchar* _tmp1_ = NULL; - gchar* _tmp2_ = NULL; - const gchar* _tmp3_ = NULL; - gchar* _tmp4_ = NULL; - GAsyncQueue* _tmp5_ = NULL; - Credentials* _tmp6_ = NULL; -#line 752 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - g_return_if_fail (self != NULL); -#line 752 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - g_return_if_fail (username != NULL); -#line 752 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - g_return_if_fail (password != NULL); -#line 754 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp0_ = credentials_new (); -#line 754 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - credentials = _tmp0_; -#line 755 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp1_ = username; -#line 755 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp2_ = g_strdup (_tmp1_); -#line 755 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _g_free0 (credentials->username); -#line 755 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - credentials->username = _tmp2_; -#line 756 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp3_ = password; -#line 756 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp4_ = g_strdup (_tmp3_); -#line 756 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _g_free0 (credentials->password); -#line 756 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - credentials->password = _tmp4_; -#line 757 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp5_ = self->priv->authorize_queue; -#line 757 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp6_ = _credentials_ref0 (credentials); -#line 757 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - g_async_queue_push (_tmp5_, _tmp6_); -#line 752 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _credentials_unref0 (credentials); -#line 8259 "scanner.c" -} - - -static void scanner_close_device (Scanner* self) { - gboolean _tmp0_ = FALSE; -#line 760 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - g_return_if_fail (self != NULL); -#line 762 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp0_ = self->priv->have_handle; -#line 762 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - if (_tmp0_) { -#line 8271 "scanner.c" - SANE_Handle _tmp1_ = {0}; - SANE_Handle _tmp2_ = {0}; -#line 764 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp1_ = self->priv->handle; -#line 764 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - sane_cancel (_tmp1_); -#line 765 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - g_debug ("scanner.vala:765: sane_cancel ()"); -#line 767 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp2_ = self->priv->handle; -#line 767 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - sane_close (_tmp2_); -#line 768 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - g_debug ("scanner.vala:768: sane_close ()"); -#line 769 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - self->priv->have_handle = FALSE; -#line 770 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _g_hash_table_unref0 (self->priv->options); -#line 770 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - self->priv->options = NULL; -#line 8292 "scanner.c" - } -#line 773 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - self->priv->buffer = (g_free (self->priv->buffer), NULL); -#line 773 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - self->priv->buffer = NULL; -#line 773 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - self->priv->buffer_length1 = 0; -#line 773 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - self->priv->_buffer_size_ = self->priv->buffer_length1; -#line 774 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - __g_list_free__scan_job_unref0_0 (self->priv->job_queue); -#line 774 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - self->priv->job_queue = NULL; -#line 776 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - scanner_set_scanning (self, FALSE); -#line 8308 "scanner.c" -} - - -static void scanner_fail_scan (Scanner* self, gint error_code, const gchar* error_string) { - gint _tmp0_ = 0; - const gchar* _tmp1_ = NULL; - NotifyScanFailed* _tmp2_ = NULL; - NotifyScanFailed* _tmp3_ = NULL; -#line 779 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - g_return_if_fail (self != NULL); -#line 779 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - g_return_if_fail (error_string != NULL); -#line 781 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - scanner_close_device (self); -#line 782 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - self->priv->state = SCAN_STATE_IDLE; -#line 783 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp0_ = error_code; -#line 783 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp1_ = error_string; -#line 783 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp2_ = notify_scan_failed_new (_tmp0_, _tmp1_); -#line 783 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp3_ = _tmp2_; -#line 783 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - scanner_notify (self, (Notify*) _tmp3_); -#line 783 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _notify_unref0 (_tmp3_); -#line 8337 "scanner.c" -} - - -static gpointer _request_ref0 (gpointer self) { -#line 808 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - return self ? request_ref (self) : NULL; -#line 8344 "scanner.c" -} - - -static gpointer _scan_job_ref0 (gpointer self) { -#line 809 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - return self ? scan_job_ref (self) : NULL; -#line 8351 "scanner.c" -} - - -static gboolean scanner_handle_requests (Scanner* self) { - gboolean result = FALSE; - gboolean _tmp0_ = FALSE; - ScanState _tmp1_ = 0; - gint request_count = 0; -#line 786 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - g_return_val_if_fail (self != NULL, FALSE); -#line 789 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp1_ = self->priv->state; -#line 789 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - if (_tmp1_ == SCAN_STATE_IDLE) { -#line 8366 "scanner.c" - gboolean _tmp2_ = FALSE; -#line 789 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp2_ = self->priv->need_redetect; -#line 789 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp0_ = _tmp2_; -#line 8372 "scanner.c" - } else { -#line 789 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp0_ = FALSE; -#line 8376 "scanner.c" - } -#line 789 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - if (_tmp0_) { -#line 790 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - self->priv->state = SCAN_STATE_REDETECT; -#line 8382 "scanner.c" - } -#line 793 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - request_count = 0; -#line 794 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - while (TRUE) { -#line 8388 "scanner.c" - Request* request = NULL; - gboolean _tmp3_ = FALSE; - gboolean _tmp4_ = FALSE; - ScanState _tmp5_ = 0; - gint _tmp11_ = 0; - Request* _tmp12_ = NULL; -#line 797 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp5_ = self->priv->state; -#line 797 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - if (_tmp5_ == SCAN_STATE_IDLE) { -#line 8399 "scanner.c" - gint _tmp6_ = 0; -#line 797 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp6_ = request_count; -#line 797 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp4_ = _tmp6_ == 0; -#line 8405 "scanner.c" - } else { -#line 797 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp4_ = FALSE; -#line 8409 "scanner.c" - } -#line 797 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - if (_tmp4_) { -#line 797 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp3_ = TRUE; -#line 8415 "scanner.c" - } else { - GAsyncQueue* _tmp7_ = NULL; - gint _tmp8_ = 0; -#line 798 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp7_ = self->priv->request_queue; -#line 798 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp8_ = g_async_queue_length (_tmp7_); -#line 798 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp3_ = _tmp8_ > 0; -#line 8425 "scanner.c" - } -#line 797 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - if (_tmp3_) { -#line 8429 "scanner.c" - GAsyncQueue* _tmp9_ = NULL; - gpointer _tmp10_ = NULL; -#line 799 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp9_ = self->priv->request_queue; -#line 799 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp10_ = g_async_queue_pop (_tmp9_); -#line 799 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _request_unref0 (request); -#line 799 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - request = (Request*) _tmp10_; -#line 8440 "scanner.c" - } else { -#line 801 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - result = TRUE; -#line 801 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _request_unref0 (request); -#line 801 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - return result; -#line 8448 "scanner.c" - } -#line 803 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - g_debug ("scanner.vala:803: Processing request"); -#line 804 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp11_ = request_count; -#line 804 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - request_count = _tmp11_ + 1; -#line 806 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp12_ = request; -#line 806 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - if (G_TYPE_CHECK_INSTANCE_TYPE (_tmp12_, TYPE_REQUEST_START_SCAN)) { -#line 8460 "scanner.c" - RequestStartScan* r = NULL; - Request* _tmp13_ = NULL; - RequestStartScan* _tmp14_ = NULL; - RequestStartScan* _tmp15_ = NULL; - ScanJob* _tmp16_ = NULL; - ScanJob* _tmp17_ = NULL; -#line 808 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp13_ = request; -#line 808 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp14_ = _request_ref0 (G_TYPE_CHECK_INSTANCE_CAST (_tmp13_, TYPE_REQUEST_START_SCAN, RequestStartScan)); -#line 808 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - r = _tmp14_; -#line 809 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp15_ = r; -#line 809 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp16_ = _tmp15_->job; -#line 809 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp17_ = _scan_job_ref0 (_tmp16_); -#line 809 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - self->priv->job_queue = g_list_append (self->priv->job_queue, _tmp17_); -#line 806 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _request_unref0 (r); -#line 8483 "scanner.c" - } else { - Request* _tmp18_ = NULL; -#line 811 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp18_ = request; -#line 811 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - if (G_TYPE_CHECK_INSTANCE_TYPE (_tmp18_, TYPE_REQUEST_CANCEL)) { -#line 813 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - scanner_fail_scan (self, (gint) SANE_STATUS_CANCELLED, "Scan cancelled - do not report this error"); -#line 8492 "scanner.c" - } else { - Request* _tmp19_ = NULL; -#line 815 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp19_ = request; -#line 815 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - if (G_TYPE_CHECK_INSTANCE_TYPE (_tmp19_, TYPE_REQUEST_QUIT)) { -#line 817 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - scanner_close_device (self); -#line 818 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - result = FALSE; -#line 818 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _request_unref0 (request); -#line 818 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - return result; -#line 8507 "scanner.c" - } - } - } -#line 794 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _request_unref0 (request); -#line 8513 "scanner.c" - } -} - - -static void _g_free0_ (gpointer var) { -#line 862 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - var = (g_free (var), NULL); -#line 8521 "scanner.c" -} - - -static void scanner_do_open (Scanner* self) { - ScanJob* job = NULL; - GList* _tmp0_ = NULL; - gconstpointer _tmp1_ = NULL; - ScanJob* _tmp2_ = NULL; - gboolean _tmp3_ = FALSE; - ScanJob* _tmp4_ = NULL; - const gchar* _tmp5_ = NULL; - ScanJob* _tmp10_ = NULL; - const gchar* _tmp11_ = NULL; - gboolean _tmp13_ = FALSE; - GHashFunc _tmp18_ = NULL; - GEqualFunc _tmp19_ = NULL; - GHashTable* _tmp20_ = NULL; - SANE_Status status = 0; - ScanJob* _tmp21_ = NULL; - const gchar* _tmp22_ = NULL; - SANE_Handle _tmp23_ = {0}; - SANE_Status _tmp24_ = 0; - ScanJob* _tmp25_ = NULL; - const gchar* _tmp26_ = NULL; - SANE_Status _tmp27_ = 0; - gchar* _tmp28_ = NULL; - gchar* _tmp29_ = NULL; - SANE_Status _tmp30_ = 0; - ScanJob* _tmp35_ = NULL; - const gchar* _tmp36_ = NULL; - gchar* _tmp37_ = NULL; -#line 823 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - g_return_if_fail (self != NULL); -#line 825 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp0_ = self->priv->job_queue; -#line 825 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp1_ = _tmp0_->data; -#line 825 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp2_ = _scan_job_ref0 (G_TYPE_CHECK_INSTANCE_CAST ((ScanJob*) _tmp1_, TYPE_SCAN_JOB, ScanJob)); -#line 825 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - job = _tmp2_; -#line 827 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - self->priv->line_count = 0; -#line 828 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - self->priv->pass_number = 0; -#line 829 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - self->priv->page_number = 0; -#line 830 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - self->priv->notified_page = -1; -#line 831 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - self->priv->option_index = (SANE_Int) 0; -#line 833 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp4_ = job; -#line 833 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp5_ = _tmp4_->device; -#line 833 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - if (_tmp5_ == NULL) { -#line 8579 "scanner.c" - const gchar* _tmp6_ = NULL; -#line 833 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp6_ = self->priv->default_device; -#line 833 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp3_ = _tmp6_ != NULL; -#line 8585 "scanner.c" - } else { -#line 833 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp3_ = FALSE; -#line 8589 "scanner.c" - } -#line 833 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - if (_tmp3_) { -#line 8593 "scanner.c" - ScanJob* _tmp7_ = NULL; - const gchar* _tmp8_ = NULL; - gchar* _tmp9_ = NULL; -#line 834 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp7_ = job; -#line 834 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp8_ = self->priv->default_device; -#line 834 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp9_ = g_strdup (_tmp8_); -#line 834 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _g_free0 (_tmp7_->device); -#line 834 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp7_->device = _tmp9_; -#line 8607 "scanner.c" - } -#line 836 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp10_ = job; -#line 836 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp11_ = _tmp10_->device; -#line 836 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - if (_tmp11_ == NULL) { -#line 8615 "scanner.c" - const gchar* _tmp12_ = NULL; -#line 838 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - g_warning ("scanner.vala:838: No scan device available"); -#line 839 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp12_ = _ ("No scanners available. Please connect a scanner."); -#line 839 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - scanner_fail_scan (self, 0, _tmp12_); -#line 842 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _scan_job_unref0 (job); -#line 842 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - return; -#line 8627 "scanner.c" - } -#line 846 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp13_ = self->priv->have_handle; -#line 846 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - if (_tmp13_) { -#line 8633 "scanner.c" - const gchar* _tmp14_ = NULL; - ScanJob* _tmp15_ = NULL; - const gchar* _tmp16_ = NULL; - SANE_Handle _tmp17_ = {0}; -#line 848 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp14_ = self->priv->current_device; -#line 848 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp15_ = job; -#line 848 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp16_ = _tmp15_->device; -#line 848 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - if (g_strcmp0 (_tmp14_, _tmp16_) == 0) { -#line 850 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - self->priv->state = SCAN_STATE_GET_OPTION; -#line 851 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _scan_job_unref0 (job); -#line 851 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - return; -#line 8652 "scanner.c" - } -#line 854 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp17_ = self->priv->handle; -#line 854 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - sane_close (_tmp17_); -#line 855 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - g_debug ("scanner.vala:855: sane_close ()"); -#line 856 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - self->priv->have_handle = FALSE; -#line 8662 "scanner.c" - } -#line 859 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _g_free0 (self->priv->current_device); -#line 859 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - self->priv->current_device = NULL; -#line 861 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - self->priv->have_handle = FALSE; -#line 862 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp18_ = g_str_hash; -#line 862 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp19_ = g_str_equal; -#line 862 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp20_ = g_hash_table_new_full (_tmp18_, _tmp19_, _g_free0_, NULL); -#line 862 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _g_hash_table_unref0 (self->priv->options); -#line 862 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - self->priv->options = _tmp20_; -#line 863 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp21_ = job; -#line 863 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp22_ = _tmp21_->device; -#line 863 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp24_ = sane_open (_tmp22_, &_tmp23_); -#line 863 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - self->priv->handle = _tmp23_; -#line 863 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - status = _tmp24_; -#line 864 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp25_ = job; -#line 864 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp26_ = _tmp25_->device; -#line 864 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp27_ = status; -#line 864 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp28_ = sane_status_to_string (_tmp27_); -#line 864 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp29_ = _tmp28_; -#line 864 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - g_debug ("scanner.vala:864: sane_open (\"%s\") -> %s", _tmp26_, _tmp29_); -#line 864 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _g_free0 (_tmp29_); -#line 866 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp30_ = status; -#line 866 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - if (_tmp30_ != SANE_STATUS_GOOD) { -#line 8708 "scanner.c" - SANE_Status _tmp31_ = 0; - const gchar* _tmp32_ = NULL; - SANE_Status _tmp33_ = 0; - const gchar* _tmp34_ = NULL; -#line 868 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp31_ = status; -#line 868 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp32_ = sane_strstatus (_tmp31_); -#line 868 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - g_warning ("scanner.vala:868: Unable to get open device: %s", _tmp32_); -#line 869 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp33_ = status; -#line 869 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp34_ = _ ("Unable to connect to scanner"); -#line 869 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - scanner_fail_scan (self, (gint) _tmp33_, _tmp34_); -#line 872 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _scan_job_unref0 (job); -#line 872 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - return; -#line 8729 "scanner.c" - } -#line 874 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - self->priv->have_handle = TRUE; -#line 876 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp35_ = job; -#line 876 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp36_ = _tmp35_->device; -#line 876 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp37_ = g_strdup (_tmp36_); -#line 876 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _g_free0 (self->priv->current_device); -#line 876 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - self->priv->current_device = _tmp37_; -#line 877 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - self->priv->state = SCAN_STATE_GET_OPTION; -#line 823 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _scan_job_unref0 (job); -#line 8747 "scanner.c" -} - - -static void scanner_do_get_option (Scanner* self) { - ScanJob* job = NULL; - GList* _tmp0_ = NULL; - gconstpointer _tmp1_ = NULL; - ScanJob* _tmp2_ = NULL; - SANE_Option_Descriptor* option = NULL; - SANE_Handle _tmp3_ = {0}; - SANE_Int _tmp4_ = {0}; - SANE_Option_Descriptor* _tmp5_ = NULL; - SANE_Int _tmp6_ = {0}; - SANE_Int index = {0}; - SANE_Int _tmp7_ = {0}; - SANE_Int _tmp8_ = {0}; - SANE_Option_Descriptor* _tmp9_ = NULL; - SANE_Int _tmp356_ = {0}; - SANE_Option_Descriptor* _tmp357_ = NULL; - SANE_Option_Descriptor* _tmp358_ = NULL; - SANE_Value_Type _tmp359_ = 0; - SANE_Option_Descriptor* _tmp360_ = NULL; - SANE_Int _tmp361_ = {0}; - SANE_Option_Descriptor* _tmp362_ = NULL; - const gchar* _tmp363_ = NULL; - GHashTable* _tmp364_ = NULL; - SANE_Option_Descriptor* _tmp365_ = NULL; - const gchar* _tmp366_ = NULL; - gchar* _tmp367_ = NULL; - SANE_Int _tmp368_ = {0}; -#line 880 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - g_return_if_fail (self != NULL); -#line 882 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp0_ = self->priv->job_queue; -#line 882 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp1_ = _tmp0_->data; -#line 882 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp2_ = _scan_job_ref0 (G_TYPE_CHECK_INSTANCE_CAST ((ScanJob*) _tmp1_, TYPE_SCAN_JOB, ScanJob)); -#line 882 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - job = _tmp2_; -#line 884 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp3_ = self->priv->handle; -#line 884 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp4_ = self->priv->option_index; -#line 884 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp5_ = sane_get_option_descriptor (_tmp3_, _tmp4_); -#line 884 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - option = _tmp5_; -#line 885 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp6_ = self->priv->option_index; -#line 885 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - g_debug ("scanner.vala:885: sane_get_option_descriptor (%d)", (gint) _tmp6_); -#line 886 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp7_ = self->priv->option_index; -#line 886 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - index = _tmp7_; -#line 887 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp8_ = self->priv->option_index; -#line 887 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - self->priv->option_index = _tmp8_ + 1; -#line 890 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp9_ = option; -#line 890 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - if (_tmp9_ == NULL) { -#line 8812 "scanner.c" - SANE_Handle _tmp10_ = {0}; - const gchar* _tmp11_ = NULL; - gint _tmp12_ = 0; - SANE_Option_Descriptor* _tmp13_ = NULL; - SANE_Option_Descriptor* _tmp14_ = NULL; - SANE_Option_Descriptor* _tmp18_ = NULL; - SANE_Handle _tmp96_ = {0}; - const gchar* _tmp97_ = NULL; - gint _tmp98_ = 0; - SANE_Option_Descriptor* _tmp99_ = NULL; - SANE_Option_Descriptor* _tmp100_ = NULL; - SANE_Handle _tmp156_ = {0}; - gint _tmp157_ = 0; - SANE_Option_Descriptor* _tmp158_ = NULL; - SANE_Option_Descriptor* _tmp159_ = NULL; - SANE_Handle _tmp167_ = {0}; - gint _tmp168_ = 0; - SANE_Option_Descriptor* _tmp169_ = NULL; - SANE_Option_Descriptor* _tmp170_ = NULL; - SANE_Handle _tmp178_ = {0}; - gint _tmp179_ = 0; - SANE_Option_Descriptor* _tmp180_ = NULL; - SANE_Option_Descriptor* _tmp181_ = NULL; - SANE_Handle _tmp194_ = {0}; - const gchar* _tmp195_ = NULL; - gint _tmp196_ = 0; - SANE_Option_Descriptor* _tmp197_ = NULL; - SANE_Option_Descriptor* _tmp198_ = NULL; - SANE_Handle _tmp218_ = {0}; - const gchar* _tmp219_ = NULL; - gint _tmp220_ = 0; - SANE_Option_Descriptor* _tmp221_ = NULL; - SANE_Option_Descriptor* _tmp222_ = NULL; - SANE_Handle _tmp237_ = {0}; - const gchar* _tmp238_ = NULL; - gint _tmp239_ = 0; - SANE_Option_Descriptor* _tmp240_ = NULL; - SANE_Option_Descriptor* _tmp241_ = NULL; - SANE_Handle _tmp256_ = {0}; - const gchar* _tmp257_ = NULL; - gint _tmp258_ = 0; - SANE_Option_Descriptor* _tmp259_ = NULL; - gboolean _tmp260_ = FALSE; - SANE_Option_Descriptor* _tmp261_ = NULL; - SANE_Handle _tmp273_ = {0}; - const gchar* _tmp274_ = NULL; - gint _tmp275_ = 0; - SANE_Option_Descriptor* _tmp276_ = NULL; - gboolean _tmp277_ = FALSE; - SANE_Option_Descriptor* _tmp278_ = NULL; - SANE_Handle _tmp290_ = {0}; - const gchar* _tmp291_ = NULL; - gint _tmp292_ = 0; - SANE_Option_Descriptor* _tmp293_ = NULL; - SANE_Option_Descriptor* _tmp294_ = NULL; - SANE_Handle _tmp305_ = {0}; - const gchar* _tmp306_ = NULL; - gint _tmp307_ = 0; - SANE_Option_Descriptor* _tmp308_ = NULL; - SANE_Option_Descriptor* _tmp309_ = NULL; - const gchar* _tmp320_ = NULL; -#line 893 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp10_ = self->priv->handle; -#line 893 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp11_ = SANE_NAME_SCAN_SOURCE; -#line 893 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp13_ = scanner_get_option_by_name (self, _tmp10_, _tmp11_, &_tmp12_); -#line 893 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - index = (SANE_Int) _tmp12_; -#line 893 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - option = _tmp13_; -#line 894 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp14_ = option; -#line 894 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - if (_tmp14_ == NULL) { -#line 8888 "scanner.c" - SANE_Handle _tmp15_ = {0}; - gint _tmp16_ = 0; - SANE_Option_Descriptor* _tmp17_ = NULL; -#line 896 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - g_debug ("scanner.vala:896: SCAN_SOURCE not available, trying alternative \"doc-" \ -"source\""); -#line 897 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp15_ = self->priv->handle; -#line 897 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp17_ = scanner_get_option_by_name (self, _tmp15_, "doc-source", &_tmp16_); -#line 897 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - index = (SANE_Int) _tmp16_; -#line 897 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - option = _tmp17_; -#line 8902 "scanner.c" - } -#line 899 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp18_ = option; -#line 899 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - if (_tmp18_ != NULL) { -#line 8908 "scanner.c" - gchar** flatbed_sources = NULL; - gchar* _tmp19_ = NULL; - const gchar* _tmp20_ = NULL; - gchar* _tmp21_ = NULL; - gchar* _tmp22_ = NULL; - const gchar* _tmp23_ = NULL; - gchar* _tmp24_ = NULL; - gchar* _tmp25_ = NULL; - gchar* _tmp26_ = NULL; - const gchar* _tmp27_ = NULL; - gchar* _tmp28_ = NULL; - gchar** _tmp29_ = NULL; - gint flatbed_sources_length1 = 0; - gint _flatbed_sources_size_ = 0; - gchar** adf_sources = NULL; - gchar* _tmp30_ = NULL; - const gchar* _tmp31_ = NULL; - gchar* _tmp32_ = NULL; - gchar* _tmp33_ = NULL; - gchar* _tmp34_ = NULL; - gchar* _tmp35_ = NULL; - gchar* _tmp36_ = NULL; - gchar** _tmp37_ = NULL; - gint adf_sources_length1 = 0; - gint _adf_sources_size_ = 0; - gchar** adf_front_sources = NULL; - gchar* _tmp38_ = NULL; - const gchar* _tmp39_ = NULL; - gchar* _tmp40_ = NULL; - gchar** _tmp41_ = NULL; - gint adf_front_sources_length1 = 0; - gint _adf_front_sources_size_ = 0; - gchar** adf_back_sources = NULL; - gchar* _tmp42_ = NULL; - const gchar* _tmp43_ = NULL; - gchar* _tmp44_ = NULL; - gchar** _tmp45_ = NULL; - gint adf_back_sources_length1 = 0; - gint _adf_back_sources_size_ = 0; - gchar** adf_duplex_sources = NULL; - gchar* _tmp46_ = NULL; - const gchar* _tmp47_ = NULL; - gchar* _tmp48_ = NULL; - gchar* _tmp49_ = NULL; - gchar* _tmp50_ = NULL; - gchar* _tmp51_ = NULL; - gchar* _tmp52_ = NULL; - gchar* _tmp53_ = NULL; - gchar** _tmp54_ = NULL; - gint adf_duplex_sources_length1 = 0; - gint _adf_duplex_sources_size_ = 0; - ScanJob* _tmp55_ = NULL; - ScanType _tmp56_ = 0; -#line 901 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp19_ = g_strdup ("Auto"); -#line 901 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp20_ = SANE_I18N ("Auto"); -#line 901 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp21_ = g_strdup (_tmp20_); -#line 901 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp22_ = g_strdup ("Flatbed"); -#line 901 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp23_ = SANE_I18N ("Flatbed"); -#line 901 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp24_ = g_strdup (_tmp23_); -#line 901 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp25_ = g_strdup ("FlatBed"); -#line 901 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp26_ = g_strdup ("Normal"); -#line 901 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp27_ = SANE_I18N ("Normal"); -#line 901 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp28_ = g_strdup (_tmp27_); -#line 901 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp29_ = g_new0 (gchar*, 7 + 1); -#line 901 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp29_[0] = _tmp19_; -#line 901 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp29_[1] = _tmp21_; -#line 901 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp29_[2] = _tmp22_; -#line 901 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp29_[3] = _tmp24_; -#line 901 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp29_[4] = _tmp25_; -#line 901 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp29_[5] = _tmp26_; -#line 901 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp29_[6] = _tmp28_; -#line 901 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - flatbed_sources = _tmp29_; -#line 901 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - flatbed_sources_length1 = 7; -#line 901 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _flatbed_sources_size_ = flatbed_sources_length1; -#line 912 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp30_ = g_strdup ("Automatic Document Feeder"); -#line 912 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp31_ = SANE_I18N ("Automatic Document Feeder"); -#line 912 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp32_ = g_strdup (_tmp31_); -#line 912 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp33_ = g_strdup ("ADF"); -#line 912 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp34_ = g_strdup ("Automatic Document Feeder(left aligned)"); -#line 912 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp35_ = g_strdup ("Automatic Document Feeder(centrally aligned)"); -#line 912 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp36_ = g_strdup ("ADF Simplex"); -#line 912 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp37_ = g_new0 (gchar*, 6 + 1); -#line 912 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp37_[0] = _tmp30_; -#line 912 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp37_[1] = _tmp32_; -#line 912 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp37_[2] = _tmp33_; -#line 912 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp37_[3] = _tmp34_; -#line 912 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp37_[4] = _tmp35_; -#line 912 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp37_[5] = _tmp36_; -#line 912 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - adf_sources = _tmp37_; -#line 912 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - adf_sources_length1 = 6; -#line 912 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _adf_sources_size_ = adf_sources_length1; -#line 922 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp38_ = g_strdup ("ADF Front"); -#line 922 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp39_ = SANE_I18N ("ADF Front"); -#line 922 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp40_ = g_strdup (_tmp39_); -#line 922 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp41_ = g_new0 (gchar*, 2 + 1); -#line 922 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp41_[0] = _tmp38_; -#line 922 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp41_[1] = _tmp40_; -#line 922 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - adf_front_sources = _tmp41_; -#line 922 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - adf_front_sources_length1 = 2; -#line 922 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _adf_front_sources_size_ = adf_front_sources_length1; -#line 928 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp42_ = g_strdup ("ADF Back"); -#line 928 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp43_ = SANE_I18N ("ADF Back"); -#line 928 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp44_ = g_strdup (_tmp43_); -#line 928 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp45_ = g_new0 (gchar*, 2 + 1); -#line 928 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp45_[0] = _tmp42_; -#line 928 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp45_[1] = _tmp44_; -#line 928 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - adf_back_sources = _tmp45_; -#line 928 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - adf_back_sources_length1 = 2; -#line 928 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _adf_back_sources_size_ = adf_back_sources_length1; -#line 934 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp46_ = g_strdup ("ADF Duplex"); -#line 934 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp47_ = SANE_I18N ("ADF Duplex"); -#line 934 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp48_ = g_strdup (_tmp47_); -#line 934 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp49_ = g_strdup ("ADF Duplex - Long-Edge Binding"); -#line 934 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp50_ = g_strdup ("ADF Duplex - Short-Edge Binding"); -#line 934 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp51_ = g_strdup ("Duplex"); -#line 934 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp52_ = g_strdup ("Automatic Document Feeder(centrally aligned,Duplex)"); -#line 934 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp53_ = g_strdup ("Automatic Document Feeder(left aligned,Duplex)"); -#line 934 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp54_ = g_new0 (gchar*, 7 + 1); -#line 934 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp54_[0] = _tmp46_; -#line 934 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp54_[1] = _tmp48_; -#line 934 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp54_[2] = _tmp49_; -#line 934 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp54_[3] = _tmp50_; -#line 934 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp54_[4] = _tmp51_; -#line 934 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp54_[5] = _tmp52_; -#line 934 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp54_[6] = _tmp53_; -#line 934 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - adf_duplex_sources = _tmp54_; -#line 934 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - adf_duplex_sources_length1 = 7; -#line 934 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _adf_duplex_sources_size_ = adf_duplex_sources_length1; -#line 945 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp55_ = job; -#line 945 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp56_ = _tmp55_->type; -#line 945 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - switch (_tmp56_) { -#line 945 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - case SCAN_TYPE_SINGLE: -#line 9120 "scanner.c" - { - SANE_Handle _tmp57_ = {0}; - SANE_Option_Descriptor* _tmp58_ = NULL; - SANE_Int _tmp59_ = {0}; - gboolean _tmp60_ = FALSE; -#line 948 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp57_ = self->priv->handle; -#line 948 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp58_ = option; -#line 948 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp59_ = index; -#line 948 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp60_ = scanner_set_default_option (self, _tmp57_, _tmp58_, _tmp59_); -#line 948 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - if (!_tmp60_) { -#line 9136 "scanner.c" - SANE_Handle _tmp61_ = {0}; - SANE_Option_Descriptor* _tmp62_ = NULL; - SANE_Int _tmp63_ = {0}; - gchar** _tmp64_ = NULL; - gint _tmp64__length1 = 0; - gboolean _tmp65_ = FALSE; -#line 949 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp61_ = self->priv->handle; -#line 949 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp62_ = option; -#line 949 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp63_ = index; -#line 949 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp64_ = flatbed_sources; -#line 949 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp64__length1 = flatbed_sources_length1; -#line 949 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp65_ = scanner_set_constrained_string_option (self, _tmp61_, _tmp62_, _tmp63_, _tmp64_, _tmp64__length1, NULL); -#line 949 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - if (!_tmp65_) { -#line 950 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - g_warning ("scanner.vala:950: Unable to set single page source, please file a bug"); -#line 9159 "scanner.c" - } - } -#line 951 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - break; -#line 9164 "scanner.c" - } -#line 945 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - case SCAN_TYPE_ADF_FRONT: -#line 9168 "scanner.c" - { - SANE_Handle _tmp66_ = {0}; - SANE_Option_Descriptor* _tmp67_ = NULL; - SANE_Int _tmp68_ = {0}; - gchar** _tmp69_ = NULL; - gint _tmp69__length1 = 0; - gboolean _tmp70_ = FALSE; -#line 953 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp66_ = self->priv->handle; -#line 953 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp67_ = option; -#line 953 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp68_ = index; -#line 953 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp69_ = adf_front_sources; -#line 953 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp69__length1 = adf_front_sources_length1; -#line 953 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp70_ = scanner_set_constrained_string_option (self, _tmp66_, _tmp67_, _tmp68_, _tmp69_, _tmp69__length1, NULL); -#line 953 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - if (!_tmp70_) { -#line 9190 "scanner.c" - SANE_Handle _tmp71_ = {0}; - SANE_Option_Descriptor* _tmp72_ = NULL; - SANE_Int _tmp73_ = {0}; - gchar** _tmp74_ = NULL; - gint _tmp74__length1 = 0; - gboolean _tmp75_ = FALSE; -#line 954 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp71_ = self->priv->handle; -#line 954 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp72_ = option; -#line 954 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp73_ = index; -#line 954 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp74_ = adf_sources; -#line 954 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp74__length1 = adf_sources_length1; -#line 954 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp75_ = scanner_set_constrained_string_option (self, _tmp71_, _tmp72_, _tmp73_, _tmp74_, _tmp74__length1, NULL); -#line 954 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - if (!_tmp75_) { -#line 955 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - g_warning ("scanner.vala:955: Unable to set front ADF source, please file a bug"); -#line 9213 "scanner.c" - } - } -#line 956 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - break; -#line 9218 "scanner.c" - } -#line 945 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - case SCAN_TYPE_ADF_BACK: -#line 9222 "scanner.c" - { - SANE_Handle _tmp76_ = {0}; - SANE_Option_Descriptor* _tmp77_ = NULL; - SANE_Int _tmp78_ = {0}; - gchar** _tmp79_ = NULL; - gint _tmp79__length1 = 0; - gboolean _tmp80_ = FALSE; -#line 958 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp76_ = self->priv->handle; -#line 958 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp77_ = option; -#line 958 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp78_ = index; -#line 958 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp79_ = adf_back_sources; -#line 958 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp79__length1 = adf_back_sources_length1; -#line 958 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp80_ = scanner_set_constrained_string_option (self, _tmp76_, _tmp77_, _tmp78_, _tmp79_, _tmp79__length1, NULL); -#line 958 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - if (!_tmp80_) { -#line 9244 "scanner.c" - SANE_Handle _tmp81_ = {0}; - SANE_Option_Descriptor* _tmp82_ = NULL; - SANE_Int _tmp83_ = {0}; - gchar** _tmp84_ = NULL; - gint _tmp84__length1 = 0; - gboolean _tmp85_ = FALSE; -#line 959 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp81_ = self->priv->handle; -#line 959 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp82_ = option; -#line 959 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp83_ = index; -#line 959 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp84_ = adf_sources; -#line 959 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp84__length1 = adf_sources_length1; -#line 959 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp85_ = scanner_set_constrained_string_option (self, _tmp81_, _tmp82_, _tmp83_, _tmp84_, _tmp84__length1, NULL); -#line 959 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - if (!_tmp85_) { -#line 960 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - g_warning ("scanner.vala:960: Unable to set back ADF source, please file a bug"); -#line 9267 "scanner.c" - } - } -#line 961 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - break; -#line 9272 "scanner.c" - } -#line 945 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - case SCAN_TYPE_ADF_BOTH: -#line 9276 "scanner.c" - { - SANE_Handle _tmp86_ = {0}; - SANE_Option_Descriptor* _tmp87_ = NULL; - SANE_Int _tmp88_ = {0}; - gchar** _tmp89_ = NULL; - gint _tmp89__length1 = 0; - gboolean _tmp90_ = FALSE; -#line 963 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp86_ = self->priv->handle; -#line 963 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp87_ = option; -#line 963 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp88_ = index; -#line 963 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp89_ = adf_duplex_sources; -#line 963 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp89__length1 = adf_duplex_sources_length1; -#line 963 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp90_ = scanner_set_constrained_string_option (self, _tmp86_, _tmp87_, _tmp88_, _tmp89_, _tmp89__length1, NULL); -#line 963 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - if (!_tmp90_) { -#line 9298 "scanner.c" - SANE_Handle _tmp91_ = {0}; - SANE_Option_Descriptor* _tmp92_ = NULL; - SANE_Int _tmp93_ = {0}; - gchar** _tmp94_ = NULL; - gint _tmp94__length1 = 0; - gboolean _tmp95_ = FALSE; -#line 964 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp91_ = self->priv->handle; -#line 964 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp92_ = option; -#line 964 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp93_ = index; -#line 964 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp94_ = adf_sources; -#line 964 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp94__length1 = adf_sources_length1; -#line 964 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp95_ = scanner_set_constrained_string_option (self, _tmp91_, _tmp92_, _tmp93_, _tmp94_, _tmp94__length1, NULL); -#line 964 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - if (!_tmp95_) { -#line 965 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - g_warning ("scanner.vala:965: Unable to set duplex ADF source, please file a bug"); -#line 9321 "scanner.c" - } - } -#line 966 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - break; -#line 9326 "scanner.c" - } - default: -#line 945 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - break; -#line 9331 "scanner.c" - } -#line 899 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - adf_duplex_sources = (_vala_array_free (adf_duplex_sources, adf_duplex_sources_length1, (GDestroyNotify) g_free), NULL); -#line 899 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - adf_back_sources = (_vala_array_free (adf_back_sources, adf_back_sources_length1, (GDestroyNotify) g_free), NULL); -#line 899 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - adf_front_sources = (_vala_array_free (adf_front_sources, adf_front_sources_length1, (GDestroyNotify) g_free), NULL); -#line 899 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - adf_sources = (_vala_array_free (adf_sources, adf_sources_length1, (GDestroyNotify) g_free), NULL); -#line 899 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - flatbed_sources = (_vala_array_free (flatbed_sources, flatbed_sources_length1, (GDestroyNotify) g_free), NULL); -#line 9343 "scanner.c" - } -#line 971 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp96_ = self->priv->handle; -#line 971 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp97_ = SANE_NAME_SCAN_MODE; -#line 971 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp99_ = scanner_get_option_by_name (self, _tmp96_, _tmp97_, &_tmp98_); -#line 971 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - index = (SANE_Int) _tmp98_; -#line 971 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - option = _tmp99_; -#line 972 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp100_ = option; -#line 972 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - if (_tmp100_ != NULL) { -#line 9359 "scanner.c" - gchar** color_scan_modes = NULL; - const gchar* _tmp101_ = NULL; - gchar* _tmp102_ = NULL; - gchar* _tmp103_ = NULL; - gchar* _tmp104_ = NULL; - gchar* _tmp105_ = NULL; - gchar** _tmp106_ = NULL; - gint color_scan_modes_length1 = 0; - gint _color_scan_modes_size_ = 0; - gchar** gray_scan_modes = NULL; - const gchar* _tmp107_ = NULL; - gchar* _tmp108_ = NULL; - gchar* _tmp109_ = NULL; - gchar* _tmp110_ = NULL; - const gchar* _tmp111_ = NULL; - gchar* _tmp112_ = NULL; - gchar* _tmp113_ = NULL; - gchar* _tmp114_ = NULL; - gchar** _tmp115_ = NULL; - gint gray_scan_modes_length1 = 0; - gint _gray_scan_modes_size_ = 0; - gchar** lineart_scan_modes = NULL; - const gchar* _tmp116_ = NULL; - gchar* _tmp117_ = NULL; - gchar* _tmp118_ = NULL; - gchar* _tmp119_ = NULL; - const gchar* _tmp120_ = NULL; - gchar* _tmp121_ = NULL; - gchar* _tmp122_ = NULL; - const gchar* _tmp123_ = NULL; - gchar* _tmp124_ = NULL; - gchar* _tmp125_ = NULL; - const gchar* _tmp126_ = NULL; - gchar* _tmp127_ = NULL; - gchar* _tmp128_ = NULL; - const gchar* _tmp129_ = NULL; - gchar* _tmp130_ = NULL; - gchar* _tmp131_ = NULL; - gchar* _tmp132_ = NULL; - const gchar* _tmp133_ = NULL; - gchar* _tmp134_ = NULL; - gchar* _tmp135_ = NULL; - gchar* _tmp136_ = NULL; - gchar* _tmp137_ = NULL; - gchar** _tmp138_ = NULL; - gint lineart_scan_modes_length1 = 0; - gint _lineart_scan_modes_size_ = 0; - ScanJob* _tmp139_ = NULL; - ScanMode _tmp140_ = 0; -#line 975 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp101_ = SANE_VALUE_SCAN_MODE_COLOR; -#line 975 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp102_ = g_strdup (_tmp101_); -#line 975 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp103_ = g_strdup ("Color"); -#line 975 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp104_ = g_strdup ("24bit Color"); -#line 975 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp105_ = g_strdup ("Color - 16 Million Colors"); -#line 975 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp106_ = g_new0 (gchar*, 4 + 1); -#line 975 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp106_[0] = _tmp102_; -#line 975 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp106_[1] = _tmp103_; -#line 975 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp106_[2] = _tmp104_; -#line 975 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp106_[3] = _tmp105_; -#line 975 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - color_scan_modes = _tmp106_; -#line 975 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - color_scan_modes_length1 = 4; -#line 975 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _color_scan_modes_size_ = color_scan_modes_length1; -#line 982 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp107_ = SANE_VALUE_SCAN_MODE_GRAY; -#line 982 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp108_ = g_strdup (_tmp107_); -#line 982 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp109_ = g_strdup ("Gray"); -#line 982 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp110_ = g_strdup ("Grayscale"); -#line 982 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp111_ = SANE_I18N ("Grayscale"); -#line 982 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp112_ = g_strdup (_tmp111_); -#line 982 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp113_ = g_strdup ("True Gray"); -#line 982 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp114_ = g_strdup ("Grayscale - 256 Levels"); -#line 982 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp115_ = g_new0 (gchar*, 6 + 1); -#line 982 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp115_[0] = _tmp108_; -#line 982 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp115_[1] = _tmp109_; -#line 982 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp115_[2] = _tmp110_; -#line 982 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp115_[3] = _tmp112_; -#line 982 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp115_[4] = _tmp113_; -#line 982 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp115_[5] = _tmp114_; -#line 982 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - gray_scan_modes = _tmp115_; -#line 982 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - gray_scan_modes_length1 = 6; -#line 982 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _gray_scan_modes_size_ = gray_scan_modes_length1; -#line 991 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp116_ = SANE_VALUE_SCAN_MODE_LINEART; -#line 991 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp117_ = g_strdup (_tmp116_); -#line 991 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp118_ = g_strdup ("Lineart"); -#line 991 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp119_ = g_strdup ("LineArt"); -#line 991 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp120_ = SANE_I18N ("LineArt"); -#line 991 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp121_ = g_strdup (_tmp120_); -#line 991 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp122_ = g_strdup ("Black & White"); -#line 991 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp123_ = SANE_I18N ("Black & White"); -#line 991 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp124_ = g_strdup (_tmp123_); -#line 991 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp125_ = g_strdup ("Binary"); -#line 991 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp126_ = SANE_I18N ("Binary"); -#line 991 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp127_ = g_strdup (_tmp126_); -#line 991 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp128_ = g_strdup ("Thresholded"); -#line 991 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp129_ = SANE_VALUE_SCAN_MODE_GRAY; -#line 991 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp130_ = g_strdup (_tmp129_); -#line 991 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp131_ = g_strdup ("Gray"); -#line 991 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp132_ = g_strdup ("Grayscale"); -#line 991 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp133_ = SANE_I18N ("Grayscale"); -#line 991 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp134_ = g_strdup (_tmp133_); -#line 991 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp135_ = g_strdup ("True Gray"); -#line 991 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp136_ = g_strdup ("Black and White - Line Art"); -#line 991 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp137_ = g_strdup ("Black and White - Halftone"); -#line 991 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp138_ = g_new0 (gchar*, 16 + 1); -#line 991 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp138_[0] = _tmp117_; -#line 991 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp138_[1] = _tmp118_; -#line 991 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp138_[2] = _tmp119_; -#line 991 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp138_[3] = _tmp121_; -#line 991 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp138_[4] = _tmp122_; -#line 991 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp138_[5] = _tmp124_; -#line 991 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp138_[6] = _tmp125_; -#line 991 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp138_[7] = _tmp127_; -#line 991 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp138_[8] = _tmp128_; -#line 991 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp138_[9] = _tmp130_; -#line 991 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp138_[10] = _tmp131_; -#line 991 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp138_[11] = _tmp132_; -#line 991 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp138_[12] = _tmp134_; -#line 991 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp138_[13] = _tmp135_; -#line 991 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp138_[14] = _tmp136_; -#line 991 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp138_[15] = _tmp137_; -#line 991 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - lineart_scan_modes = _tmp138_; -#line 991 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - lineart_scan_modes_length1 = 16; -#line 991 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _lineart_scan_modes_size_ = lineart_scan_modes_length1; -#line 1011 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp139_ = job; -#line 1011 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp140_ = _tmp139_->scan_mode; -#line 1011 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - switch (_tmp140_) { -#line 1011 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - case SCAN_MODE_COLOR: -#line 9563 "scanner.c" - { - SANE_Handle _tmp141_ = {0}; - SANE_Option_Descriptor* _tmp142_ = NULL; - SANE_Int _tmp143_ = {0}; - gchar** _tmp144_ = NULL; - gint _tmp144__length1 = 0; - gboolean _tmp145_ = FALSE; -#line 1014 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp141_ = self->priv->handle; -#line 1014 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp142_ = option; -#line 1014 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp143_ = index; -#line 1014 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp144_ = color_scan_modes; -#line 1014 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp144__length1 = color_scan_modes_length1; -#line 1014 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp145_ = scanner_set_constrained_string_option (self, _tmp141_, _tmp142_, _tmp143_, _tmp144_, _tmp144__length1, NULL); -#line 1014 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - if (!_tmp145_) { -#line 1015 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - g_warning ("scanner.vala:1015: Unable to set Color mode, please file a bug"); -#line 9587 "scanner.c" - } -#line 1016 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - break; -#line 9591 "scanner.c" - } -#line 1011 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - case SCAN_MODE_GRAY: -#line 9595 "scanner.c" - { - SANE_Handle _tmp146_ = {0}; - SANE_Option_Descriptor* _tmp147_ = NULL; - SANE_Int _tmp148_ = {0}; - gchar** _tmp149_ = NULL; - gint _tmp149__length1 = 0; - gboolean _tmp150_ = FALSE; -#line 1018 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp146_ = self->priv->handle; -#line 1018 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp147_ = option; -#line 1018 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp148_ = index; -#line 1018 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp149_ = gray_scan_modes; -#line 1018 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp149__length1 = gray_scan_modes_length1; -#line 1018 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp150_ = scanner_set_constrained_string_option (self, _tmp146_, _tmp147_, _tmp148_, _tmp149_, _tmp149__length1, NULL); -#line 1018 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - if (!_tmp150_) { -#line 1019 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - g_warning ("scanner.vala:1019: Unable to set Gray mode, please file a bug"); -#line 9619 "scanner.c" - } -#line 1020 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - break; -#line 9623 "scanner.c" - } -#line 1011 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - case SCAN_MODE_LINEART: -#line 9627 "scanner.c" - { - SANE_Handle _tmp151_ = {0}; - SANE_Option_Descriptor* _tmp152_ = NULL; - SANE_Int _tmp153_ = {0}; - gchar** _tmp154_ = NULL; - gint _tmp154__length1 = 0; - gboolean _tmp155_ = FALSE; -#line 1022 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp151_ = self->priv->handle; -#line 1022 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp152_ = option; -#line 1022 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp153_ = index; -#line 1022 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp154_ = lineart_scan_modes; -#line 1022 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp154__length1 = lineart_scan_modes_length1; -#line 1022 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp155_ = scanner_set_constrained_string_option (self, _tmp151_, _tmp152_, _tmp153_, _tmp154_, _tmp154__length1, NULL); -#line 1022 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - if (!_tmp155_) { -#line 1023 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - g_warning ("scanner.vala:1023: Unable to set Lineart mode, please file a bug"); -#line 9651 "scanner.c" - } -#line 1024 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - break; -#line 9655 "scanner.c" - } - default: - { -#line 1026 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - break; -#line 9661 "scanner.c" - } - } -#line 972 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - lineart_scan_modes = (_vala_array_free (lineart_scan_modes, lineart_scan_modes_length1, (GDestroyNotify) g_free), NULL); -#line 972 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - gray_scan_modes = (_vala_array_free (gray_scan_modes, gray_scan_modes_length1, (GDestroyNotify) g_free), NULL); -#line 972 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - color_scan_modes = (_vala_array_free (color_scan_modes, color_scan_modes_length1, (GDestroyNotify) g_free), NULL); -#line 9670 "scanner.c" - } -#line 1031 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp156_ = self->priv->handle; -#line 1031 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp158_ = scanner_get_option_by_name (self, _tmp156_, "duplex", &_tmp157_); -#line 1031 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - index = (SANE_Int) _tmp157_; -#line 1031 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - option = _tmp158_; -#line 1032 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp159_ = option; -#line 1032 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - if (_tmp159_ != NULL) { -#line 9684 "scanner.c" - SANE_Option_Descriptor* _tmp160_ = NULL; - SANE_Value_Type _tmp161_ = 0; -#line 1034 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp160_ = option; -#line 1034 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp161_ = _tmp160_->type; -#line 1034 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - if (_tmp161_ == SANE_TYPE_BOOL) { -#line 9693 "scanner.c" - SANE_Handle _tmp162_ = {0}; - SANE_Option_Descriptor* _tmp163_ = NULL; - SANE_Int _tmp164_ = {0}; - ScanJob* _tmp165_ = NULL; - ScanType _tmp166_ = 0; -#line 1035 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp162_ = self->priv->handle; -#line 1035 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp163_ = option; -#line 1035 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp164_ = index; -#line 1035 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp165_ = job; -#line 1035 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp166_ = _tmp165_->type; -#line 1035 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - scanner_set_bool_option (self, _tmp162_, _tmp163_, _tmp164_, _tmp166_ == SCAN_TYPE_ADF_BOTH, NULL); -#line 9711 "scanner.c" - } - } -#line 1039 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp167_ = self->priv->handle; -#line 1039 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp169_ = scanner_get_option_by_name (self, _tmp167_, "batch-scan", &_tmp168_); -#line 1039 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - index = (SANE_Int) _tmp168_; -#line 1039 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - option = _tmp169_; -#line 1040 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp170_ = option; -#line 1040 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - if (_tmp170_ != NULL) { -#line 9726 "scanner.c" - SANE_Option_Descriptor* _tmp171_ = NULL; - SANE_Value_Type _tmp172_ = 0; -#line 1042 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp171_ = option; -#line 1042 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp172_ = _tmp171_->type; -#line 1042 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - if (_tmp172_ == SANE_TYPE_BOOL) { -#line 9735 "scanner.c" - SANE_Handle _tmp173_ = {0}; - SANE_Option_Descriptor* _tmp174_ = NULL; - SANE_Int _tmp175_ = {0}; - ScanJob* _tmp176_ = NULL; - ScanType _tmp177_ = 0; -#line 1043 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp173_ = self->priv->handle; -#line 1043 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp174_ = option; -#line 1043 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp175_ = index; -#line 1043 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp176_ = job; -#line 1043 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp177_ = _tmp176_->type; -#line 1043 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - scanner_set_bool_option (self, _tmp173_, _tmp174_, _tmp175_, _tmp177_ != SCAN_TYPE_SINGLE, NULL); -#line 9753 "scanner.c" - } - } -#line 1047 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp178_ = self->priv->handle; -#line 1047 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp180_ = scanner_get_option_by_name (self, _tmp178_, "compression", &_tmp179_); -#line 1047 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - index = (SANE_Int) _tmp179_; -#line 1047 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - option = _tmp180_; -#line 1048 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp181_ = option; -#line 1048 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - if (_tmp181_ != NULL) { -#line 9768 "scanner.c" - gchar** disable_compression_names = NULL; - const gchar* _tmp182_ = NULL; - gchar* _tmp183_ = NULL; - const gchar* _tmp184_ = NULL; - gchar* _tmp185_ = NULL; - gchar* _tmp186_ = NULL; - gchar* _tmp187_ = NULL; - gchar** _tmp188_ = NULL; - gint disable_compression_names_length1 = 0; - gint _disable_compression_names_size_ = 0; - SANE_Handle _tmp189_ = {0}; - SANE_Option_Descriptor* _tmp190_ = NULL; - SANE_Int _tmp191_ = {0}; - gchar** _tmp192_ = NULL; - gint _tmp192__length1 = 0; - gboolean _tmp193_ = FALSE; -#line 1050 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp182_ = SANE_I18N ("None"); -#line 1050 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp183_ = g_strdup (_tmp182_); -#line 1050 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp184_ = SANE_I18N ("none"); -#line 1050 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp185_ = g_strdup (_tmp184_); -#line 1050 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp186_ = g_strdup ("None"); -#line 1050 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp187_ = g_strdup ("none"); -#line 1050 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp188_ = g_new0 (gchar*, 4 + 1); -#line 1050 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp188_[0] = _tmp183_; -#line 1050 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp188_[1] = _tmp185_; -#line 1050 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp188_[2] = _tmp186_; -#line 1050 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp188_[3] = _tmp187_; -#line 1050 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - disable_compression_names = _tmp188_; -#line 1050 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - disable_compression_names_length1 = 4; -#line 1050 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _disable_compression_names_size_ = disable_compression_names_length1; -#line 1058 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp189_ = self->priv->handle; -#line 1058 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp190_ = option; -#line 1058 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp191_ = index; -#line 1058 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp192_ = disable_compression_names; -#line 1058 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp192__length1 = disable_compression_names_length1; -#line 1058 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp193_ = scanner_set_constrained_string_option (self, _tmp189_, _tmp190_, _tmp191_, _tmp192_, _tmp192__length1, NULL); -#line 1058 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - if (!_tmp193_) { -#line 1059 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - g_warning ("scanner.vala:1059: Unable to disable compression, please file a bug"); -#line 9829 "scanner.c" - } -#line 1048 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - disable_compression_names = (_vala_array_free (disable_compression_names, disable_compression_names_length1, (GDestroyNotify) g_free), NULL); -#line 9833 "scanner.c" - } -#line 1063 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp194_ = self->priv->handle; -#line 1063 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp195_ = SANE_NAME_SCAN_RESOLUTION; -#line 1063 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp197_ = scanner_get_option_by_name (self, _tmp194_, _tmp195_, &_tmp196_); -#line 1063 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - index = (SANE_Int) _tmp196_; -#line 1063 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - option = _tmp197_; -#line 1064 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp198_ = option; -#line 1064 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - if (_tmp198_ != NULL) { -#line 9849 "scanner.c" - SANE_Handle _tmp199_ = {0}; - SANE_Option_Descriptor* _tmp200_ = NULL; - SANE_Int _tmp201_ = {0}; - ScanJob* _tmp202_ = NULL; - gdouble _tmp203_ = 0.0; - ScanJob* _tmp204_ = NULL; - gdouble _tmp205_ = 0.0; - SANE_Handle _tmp206_ = {0}; - const gchar* _tmp207_ = NULL; - gint _tmp208_ = 0; - SANE_Option_Descriptor* _tmp209_ = NULL; - SANE_Option_Descriptor* _tmp210_ = NULL; -#line 1066 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp199_ = self->priv->handle; -#line 1066 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp200_ = option; -#line 1066 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp201_ = index; -#line 1066 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp202_ = job; -#line 1066 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp203_ = _tmp202_->dpi; -#line 1066 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp204_ = job; -#line 1066 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - scanner_set_fixed_or_int_option (self, _tmp199_, _tmp200_, _tmp201_, _tmp203_, &_tmp205_); -#line 1066 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp204_->dpi = _tmp205_; -#line 1067 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp206_ = self->priv->handle; -#line 1067 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp207_ = SANE_NAME_BIT_DEPTH; -#line 1067 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp209_ = scanner_get_option_by_name (self, _tmp206_, _tmp207_, &_tmp208_); -#line 1067 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - index = (SANE_Int) _tmp208_; -#line 1067 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - option = _tmp209_; -#line 1068 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp210_ = option; -#line 1068 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - if (_tmp210_ != NULL) { -#line 9892 "scanner.c" - ScanJob* _tmp211_ = NULL; - gint _tmp212_ = 0; -#line 1070 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp211_ = job; -#line 1070 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp212_ = _tmp211_->depth; -#line 1070 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - if (_tmp212_ > 0) { -#line 9901 "scanner.c" - SANE_Handle _tmp213_ = {0}; - SANE_Option_Descriptor* _tmp214_ = NULL; - SANE_Int _tmp215_ = {0}; - ScanJob* _tmp216_ = NULL; - gint _tmp217_ = 0; -#line 1071 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp213_ = self->priv->handle; -#line 1071 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp214_ = option; -#line 1071 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp215_ = index; -#line 1071 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp216_ = job; -#line 1071 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp217_ = _tmp216_->depth; -#line 1071 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - scanner_set_int_option (self, _tmp213_, _tmp214_, _tmp215_, _tmp217_, NULL); -#line 9919 "scanner.c" - } - } - } -#line 1076 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp218_ = self->priv->handle; -#line 1076 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp219_ = SANE_NAME_SCAN_BR_X; -#line 1076 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp221_ = scanner_get_option_by_name (self, _tmp218_, _tmp219_, &_tmp220_); -#line 1076 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - index = (SANE_Int) _tmp220_; -#line 1076 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - option = _tmp221_; -#line 1077 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp222_ = option; -#line 1077 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - if (_tmp222_ != NULL) { -#line 9937 "scanner.c" - ScanJob* _tmp223_ = NULL; - gint _tmp224_ = 0; -#line 1079 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp223_ = job; -#line 1079 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp224_ = _tmp223_->page_width; -#line 1079 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - if (_tmp224_ > 0) { -#line 9946 "scanner.c" - SANE_Handle _tmp225_ = {0}; - SANE_Option_Descriptor* _tmp226_ = NULL; - SANE_Int _tmp227_ = {0}; - SANE_Option_Descriptor* _tmp228_ = NULL; - ScanJob* _tmp229_ = NULL; - gint _tmp230_ = 0; - ScanJob* _tmp231_ = NULL; - gdouble _tmp232_ = 0.0; - gdouble _tmp233_ = 0.0; -#line 1080 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp225_ = self->priv->handle; -#line 1080 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp226_ = option; -#line 1080 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp227_ = index; -#line 1080 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp228_ = option; -#line 1080 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp229_ = job; -#line 1080 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp230_ = _tmp229_->page_width; -#line 1080 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp231_ = job; -#line 1080 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp232_ = _tmp231_->dpi; -#line 1080 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp233_ = scanner_convert_page_size (self, _tmp228_, (gdouble) _tmp230_, _tmp232_); -#line 1080 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - scanner_set_fixed_or_int_option (self, _tmp225_, _tmp226_, _tmp227_, _tmp233_, NULL); -#line 9976 "scanner.c" - } else { - SANE_Handle _tmp234_ = {0}; - SANE_Option_Descriptor* _tmp235_ = NULL; - SANE_Int _tmp236_ = {0}; -#line 1082 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp234_ = self->priv->handle; -#line 1082 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp235_ = option; -#line 1082 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp236_ = index; -#line 1082 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - scanner_set_option_to_max (self, _tmp234_, _tmp235_, _tmp236_); -#line 9989 "scanner.c" - } - } -#line 1084 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp237_ = self->priv->handle; -#line 1084 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp238_ = SANE_NAME_SCAN_BR_Y; -#line 1084 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp240_ = scanner_get_option_by_name (self, _tmp237_, _tmp238_, &_tmp239_); -#line 1084 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - index = (SANE_Int) _tmp239_; -#line 1084 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - option = _tmp240_; -#line 1085 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp241_ = option; -#line 1085 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - if (_tmp241_ != NULL) { -#line 10006 "scanner.c" - ScanJob* _tmp242_ = NULL; - gint _tmp243_ = 0; -#line 1087 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp242_ = job; -#line 1087 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp243_ = _tmp242_->page_height; -#line 1087 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - if (_tmp243_ > 0) { -#line 10015 "scanner.c" - SANE_Handle _tmp244_ = {0}; - SANE_Option_Descriptor* _tmp245_ = NULL; - SANE_Int _tmp246_ = {0}; - SANE_Option_Descriptor* _tmp247_ = NULL; - ScanJob* _tmp248_ = NULL; - gint _tmp249_ = 0; - ScanJob* _tmp250_ = NULL; - gdouble _tmp251_ = 0.0; - gdouble _tmp252_ = 0.0; -#line 1088 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp244_ = self->priv->handle; -#line 1088 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp245_ = option; -#line 1088 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp246_ = index; -#line 1088 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp247_ = option; -#line 1088 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp248_ = job; -#line 1088 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp249_ = _tmp248_->page_height; -#line 1088 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp250_ = job; -#line 1088 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp251_ = _tmp250_->dpi; -#line 1088 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp252_ = scanner_convert_page_size (self, _tmp247_, (gdouble) _tmp249_, _tmp251_); -#line 1088 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - scanner_set_fixed_or_int_option (self, _tmp244_, _tmp245_, _tmp246_, _tmp252_, NULL); -#line 10045 "scanner.c" - } else { - SANE_Handle _tmp253_ = {0}; - SANE_Option_Descriptor* _tmp254_ = NULL; - SANE_Int _tmp255_ = {0}; -#line 1090 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp253_ = self->priv->handle; -#line 1090 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp254_ = option; -#line 1090 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp255_ = index; -#line 1090 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - scanner_set_option_to_max (self, _tmp253_, _tmp254_, _tmp255_); -#line 10058 "scanner.c" - } - } -#line 1094 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp256_ = self->priv->handle; -#line 1094 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp257_ = SANE_NAME_PAGE_WIDTH; -#line 1094 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp259_ = scanner_get_option_by_name (self, _tmp256_, _tmp257_, &_tmp258_); -#line 1094 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - index = (SANE_Int) _tmp258_; -#line 1094 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - option = _tmp259_; -#line 1095 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp261_ = option; -#line 1095 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - if (_tmp261_ != NULL) { -#line 10075 "scanner.c" - ScanJob* _tmp262_ = NULL; - gint _tmp263_ = 0; -#line 1095 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp262_ = job; -#line 1095 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp263_ = _tmp262_->page_width; -#line 1095 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp260_ = ((gdouble) _tmp263_) > 0.0; -#line 10084 "scanner.c" - } else { -#line 1095 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp260_ = FALSE; -#line 10088 "scanner.c" - } -#line 1095 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - if (_tmp260_) { -#line 10092 "scanner.c" - SANE_Handle _tmp264_ = {0}; - SANE_Option_Descriptor* _tmp265_ = NULL; - SANE_Int _tmp266_ = {0}; - SANE_Option_Descriptor* _tmp267_ = NULL; - ScanJob* _tmp268_ = NULL; - gint _tmp269_ = 0; - ScanJob* _tmp270_ = NULL; - gdouble _tmp271_ = 0.0; - gdouble _tmp272_ = 0.0; -#line 1096 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp264_ = self->priv->handle; -#line 1096 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp265_ = option; -#line 1096 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp266_ = index; -#line 1096 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp267_ = option; -#line 1096 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp268_ = job; -#line 1096 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp269_ = _tmp268_->page_width; -#line 1096 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp270_ = job; -#line 1096 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp271_ = _tmp270_->dpi; -#line 1096 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp272_ = scanner_convert_page_size (self, _tmp267_, (gdouble) _tmp269_, _tmp271_); -#line 1096 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - scanner_set_fixed_or_int_option (self, _tmp264_, _tmp265_, _tmp266_, _tmp272_, NULL); -#line 10122 "scanner.c" - } -#line 1097 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp273_ = self->priv->handle; -#line 1097 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp274_ = SANE_NAME_PAGE_HEIGHT; -#line 1097 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp276_ = scanner_get_option_by_name (self, _tmp273_, _tmp274_, &_tmp275_); -#line 1097 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - index = (SANE_Int) _tmp275_; -#line 1097 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - option = _tmp276_; -#line 1098 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp278_ = option; -#line 1098 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - if (_tmp278_ != NULL) { -#line 10138 "scanner.c" - ScanJob* _tmp279_ = NULL; - gint _tmp280_ = 0; -#line 1098 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp279_ = job; -#line 1098 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp280_ = _tmp279_->page_height; -#line 1098 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp277_ = ((gdouble) _tmp280_) > 0.0; -#line 10147 "scanner.c" - } else { -#line 1098 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp277_ = FALSE; -#line 10151 "scanner.c" - } -#line 1098 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - if (_tmp277_) { -#line 10155 "scanner.c" - SANE_Handle _tmp281_ = {0}; - SANE_Option_Descriptor* _tmp282_ = NULL; - SANE_Int _tmp283_ = {0}; - SANE_Option_Descriptor* _tmp284_ = NULL; - ScanJob* _tmp285_ = NULL; - gint _tmp286_ = 0; - ScanJob* _tmp287_ = NULL; - gdouble _tmp288_ = 0.0; - gdouble _tmp289_ = 0.0; -#line 1099 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp281_ = self->priv->handle; -#line 1099 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp282_ = option; -#line 1099 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp283_ = index; -#line 1099 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp284_ = option; -#line 1099 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp285_ = job; -#line 1099 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp286_ = _tmp285_->page_height; -#line 1099 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp287_ = job; -#line 1099 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp288_ = _tmp287_->dpi; -#line 1099 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp289_ = scanner_convert_page_size (self, _tmp284_, (gdouble) _tmp286_, _tmp288_); -#line 1099 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - scanner_set_fixed_or_int_option (self, _tmp281_, _tmp282_, _tmp283_, _tmp289_, NULL); -#line 10185 "scanner.c" - } -#line 1101 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp290_ = self->priv->handle; -#line 1101 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp291_ = SANE_NAME_BRIGHTNESS; -#line 1101 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp293_ = scanner_get_option_by_name (self, _tmp290_, _tmp291_, &_tmp292_); -#line 1101 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - index = (SANE_Int) _tmp292_; -#line 1101 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - option = _tmp293_; -#line 1102 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp294_ = option; -#line 1102 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - if (_tmp294_ != NULL) { -#line 10201 "scanner.c" - ScanJob* _tmp295_ = NULL; - gint _tmp296_ = 0; -#line 1104 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp295_ = job; -#line 1104 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp296_ = _tmp295_->brightness; -#line 1104 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - if (_tmp296_ != 0) { -#line 10210 "scanner.c" - gint brightness = 0; - SANE_Option_Descriptor* _tmp297_ = NULL; - ScanJob* _tmp298_ = NULL; - gint _tmp299_ = 0; - gint _tmp300_ = 0; - SANE_Handle _tmp301_ = {0}; - SANE_Option_Descriptor* _tmp302_ = NULL; - SANE_Int _tmp303_ = {0}; - gint _tmp304_ = 0; -#line 1106 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp297_ = option; -#line 1106 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp298_ = job; -#line 1106 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp299_ = _tmp298_->brightness; -#line 1106 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp300_ = scanner_scale_int (self, -100, 100, _tmp297_, _tmp299_); -#line 1106 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - brightness = _tmp300_; -#line 1107 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp301_ = self->priv->handle; -#line 1107 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp302_ = option; -#line 1107 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp303_ = index; -#line 1107 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp304_ = brightness; -#line 1107 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - scanner_set_int_option (self, _tmp301_, _tmp302_, _tmp303_, _tmp304_, NULL); -#line 10240 "scanner.c" - } - } -#line 1110 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp305_ = self->priv->handle; -#line 1110 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp306_ = SANE_NAME_CONTRAST; -#line 1110 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp308_ = scanner_get_option_by_name (self, _tmp305_, _tmp306_, &_tmp307_); -#line 1110 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - index = (SANE_Int) _tmp307_; -#line 1110 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - option = _tmp308_; -#line 1111 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp309_ = option; -#line 1111 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - if (_tmp309_ != NULL) { -#line 10257 "scanner.c" - ScanJob* _tmp310_ = NULL; - gint _tmp311_ = 0; -#line 1113 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp310_ = job; -#line 1113 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp311_ = _tmp310_->contrast; -#line 1113 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - if (_tmp311_ != 0) { -#line 10266 "scanner.c" - gint contrast = 0; - SANE_Option_Descriptor* _tmp312_ = NULL; - ScanJob* _tmp313_ = NULL; - gint _tmp314_ = 0; - gint _tmp315_ = 0; - SANE_Handle _tmp316_ = {0}; - SANE_Option_Descriptor* _tmp317_ = NULL; - SANE_Int _tmp318_ = {0}; - gint _tmp319_ = 0; -#line 1115 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp312_ = option; -#line 1115 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp313_ = job; -#line 1115 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp314_ = _tmp313_->contrast; -#line 1115 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp315_ = scanner_scale_int (self, -100, 100, _tmp312_, _tmp314_); -#line 1115 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - contrast = _tmp315_; -#line 1116 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp316_ = self->priv->handle; -#line 1116 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp317_ = option; -#line 1116 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp318_ = index; -#line 1116 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp319_ = contrast; -#line 1116 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - scanner_set_int_option (self, _tmp316_, _tmp317_, _tmp318_, _tmp319_, NULL); -#line 10296 "scanner.c" - } - } -#line 1121 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp320_ = self->priv->current_device; -#line 1121 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - if (g_strcmp0 (_tmp320_, "test") == 0) { -#line 10303 "scanner.c" - SANE_Handle _tmp321_ = {0}; - gint _tmp322_ = 0; - SANE_Option_Descriptor* _tmp323_ = NULL; - SANE_Option_Descriptor* _tmp324_ = NULL; - SANE_Handle _tmp328_ = {0}; - gint _tmp329_ = 0; - SANE_Option_Descriptor* _tmp330_ = NULL; - SANE_Option_Descriptor* _tmp331_ = NULL; - SANE_Handle _tmp335_ = {0}; - gint _tmp336_ = 0; - SANE_Option_Descriptor* _tmp337_ = NULL; - SANE_Option_Descriptor* _tmp338_ = NULL; - SANE_Handle _tmp342_ = {0}; - gint _tmp343_ = 0; - SANE_Option_Descriptor* _tmp344_ = NULL; - SANE_Option_Descriptor* _tmp345_ = NULL; - SANE_Handle _tmp349_ = {0}; - gint _tmp350_ = 0; - SANE_Option_Descriptor* _tmp351_ = NULL; - SANE_Option_Descriptor* _tmp352_ = NULL; -#line 1123 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp321_ = self->priv->handle; -#line 1123 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp323_ = scanner_get_option_by_name (self, _tmp321_, "hand-scanner", &_tmp322_); -#line 1123 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - index = (SANE_Int) _tmp322_; -#line 1123 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - option = _tmp323_; -#line 1124 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp324_ = option; -#line 1124 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - if (_tmp324_ != NULL) { -#line 10336 "scanner.c" - SANE_Handle _tmp325_ = {0}; - SANE_Option_Descriptor* _tmp326_ = NULL; - SANE_Int _tmp327_ = {0}; -#line 1125 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp325_ = self->priv->handle; -#line 1125 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp326_ = option; -#line 1125 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp327_ = index; -#line 1125 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - scanner_set_bool_option (self, _tmp325_, _tmp326_, _tmp327_, FALSE, NULL); -#line 10348 "scanner.c" - } -#line 1126 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp328_ = self->priv->handle; -#line 1126 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp330_ = scanner_get_option_by_name (self, _tmp328_, "three-pass", &_tmp329_); -#line 1126 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - index = (SANE_Int) _tmp329_; -#line 1126 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - option = _tmp330_; -#line 1127 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp331_ = option; -#line 1127 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - if (_tmp331_ != NULL) { -#line 10362 "scanner.c" - SANE_Handle _tmp332_ = {0}; - SANE_Option_Descriptor* _tmp333_ = NULL; - SANE_Int _tmp334_ = {0}; -#line 1128 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp332_ = self->priv->handle; -#line 1128 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp333_ = option; -#line 1128 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp334_ = index; -#line 1128 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - scanner_set_bool_option (self, _tmp332_, _tmp333_, _tmp334_, FALSE, NULL); -#line 10374 "scanner.c" - } -#line 1129 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp335_ = self->priv->handle; -#line 1129 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp337_ = scanner_get_option_by_name (self, _tmp335_, "test-picture", &_tmp336_); -#line 1129 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - index = (SANE_Int) _tmp336_; -#line 1129 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - option = _tmp337_; -#line 1130 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp338_ = option; -#line 1130 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - if (_tmp338_ != NULL) { -#line 10388 "scanner.c" - SANE_Handle _tmp339_ = {0}; - SANE_Option_Descriptor* _tmp340_ = NULL; - SANE_Int _tmp341_ = {0}; -#line 1131 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp339_ = self->priv->handle; -#line 1131 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp340_ = option; -#line 1131 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp341_ = index; -#line 1131 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - scanner_set_string_option (self, _tmp339_, _tmp340_, _tmp341_, "Color pattern", NULL); -#line 10400 "scanner.c" - } -#line 1132 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp342_ = self->priv->handle; -#line 1132 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp344_ = scanner_get_option_by_name (self, _tmp342_, "read-delay", &_tmp343_); -#line 1132 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - index = (SANE_Int) _tmp343_; -#line 1132 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - option = _tmp344_; -#line 1133 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp345_ = option; -#line 1133 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - if (_tmp345_ != NULL) { -#line 10414 "scanner.c" - SANE_Handle _tmp346_ = {0}; - SANE_Option_Descriptor* _tmp347_ = NULL; - SANE_Int _tmp348_ = {0}; -#line 1134 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp346_ = self->priv->handle; -#line 1134 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp347_ = option; -#line 1134 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp348_ = index; -#line 1134 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - scanner_set_bool_option (self, _tmp346_, _tmp347_, _tmp348_, TRUE, NULL); -#line 10426 "scanner.c" - } -#line 1135 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp349_ = self->priv->handle; -#line 1135 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp351_ = scanner_get_option_by_name (self, _tmp349_, "read-delay-duration", &_tmp350_); -#line 1135 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - index = (SANE_Int) _tmp350_; -#line 1135 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - option = _tmp351_; -#line 1136 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp352_ = option; -#line 1136 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - if (_tmp352_ != NULL) { -#line 10440 "scanner.c" - SANE_Handle _tmp353_ = {0}; - SANE_Option_Descriptor* _tmp354_ = NULL; - SANE_Int _tmp355_ = {0}; -#line 1137 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp353_ = self->priv->handle; -#line 1137 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp354_ = option; -#line 1137 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp355_ = index; -#line 1137 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - scanner_set_int_option (self, _tmp353_, _tmp354_, _tmp355_, 200000, NULL); -#line 10452 "scanner.c" - } - } -#line 1140 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - self->priv->state = SCAN_STATE_START; -#line 1141 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _scan_job_unref0 (job); -#line 1141 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - return; -#line 10461 "scanner.c" - } -#line 1144 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp356_ = index; -#line 1144 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp357_ = option; -#line 1144 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - scanner_log_option (self, _tmp356_, _tmp357_); -#line 1147 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp358_ = option; -#line 1147 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp359_ = _tmp358_->type; -#line 1147 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - if (_tmp359_ == SANE_TYPE_GROUP) { -#line 1148 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _scan_job_unref0 (job); -#line 1148 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - return; -#line 10479 "scanner.c" - } -#line 1151 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp360_ = option; -#line 1151 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp361_ = _tmp360_->cap; -#line 1151 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - if ((_tmp361_ & SANE_CAP_INACTIVE) != ((SANE_Int) 0)) { -#line 1152 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _scan_job_unref0 (job); -#line 1152 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - return; -#line 10491 "scanner.c" - } -#line 1155 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp362_ = option; -#line 1155 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp363_ = _tmp362_->name; -#line 1155 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - if (_tmp363_ == NULL) { -#line 1156 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _scan_job_unref0 (job); -#line 1156 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - return; -#line 10503 "scanner.c" - } -#line 1158 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp364_ = self->priv->options; -#line 1158 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp365_ = option; -#line 1158 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp366_ = _tmp365_->name; -#line 1158 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp367_ = g_strdup (_tmp366_); -#line 1158 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp368_ = index; -#line 1158 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - g_hash_table_insert (_tmp364_, _tmp367_, (gpointer) ((gintptr) ((gint) _tmp368_))); -#line 880 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _scan_job_unref0 (job); -#line 10519 "scanner.c" -} - - -static gdouble scanner_convert_page_size (Scanner* self, SANE_Option_Descriptor* option, gdouble size, gdouble dpi) { - gdouble result = 0.0; - SANE_Option_Descriptor* _tmp0_ = NULL; - SANE_Unit _tmp1_ = 0; -#line 1161 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - g_return_val_if_fail (self != NULL, 0.0); -#line 1161 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - g_return_val_if_fail (option != NULL, 0.0); -#line 1163 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp0_ = option; -#line 1163 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp1_ = _tmp0_->unit; -#line 1163 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - if (_tmp1_ == SANE_UNIT_PIXEL) { -#line 10537 "scanner.c" - gdouble _tmp2_ = 0.0; - gdouble _tmp3_ = 0.0; -#line 1164 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp2_ = dpi; -#line 1164 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp3_ = size; -#line 1164 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - result = (_tmp2_ * _tmp3_) / 254.0; -#line 1164 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - return result; -#line 10548 "scanner.c" - } else { - SANE_Option_Descriptor* _tmp4_ = NULL; - SANE_Unit _tmp5_ = 0; -#line 1165 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp4_ = option; -#line 1165 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp5_ = _tmp4_->unit; -#line 1165 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - if (_tmp5_ == SANE_UNIT_MM) { -#line 10558 "scanner.c" - gdouble _tmp6_ = 0.0; -#line 1166 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp6_ = size; -#line 1166 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - result = _tmp6_ / 10.0; -#line 1166 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - return result; -#line 10566 "scanner.c" - } else { -#line 1169 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - g_warning ("scanner.vala:1169: Unable to set unsupported unit type"); -#line 1170 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - result = (gdouble) 0.0f; -#line 1170 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - return result; -#line 10574 "scanner.c" - } - } -} - - -static SANE_Option_Descriptor* scanner_get_option_by_name (Scanner* self, SANE_Handle handle, const gchar* name, gint* index) { - gint _vala_index = 0; - SANE_Option_Descriptor* result = NULL; - GHashTable* _tmp0_ = NULL; - const gchar* _tmp1_ = NULL; - gconstpointer _tmp2_ = NULL; - gint _tmp3_ = 0; - SANE_Handle _tmp4_ = {0}; - gint _tmp5_ = 0; - SANE_Option_Descriptor* _tmp6_ = NULL; -#line 1174 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - g_return_val_if_fail (self != NULL, NULL); -#line 1174 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - g_return_val_if_fail (name != NULL, NULL); -#line 1176 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp0_ = self->priv->options; -#line 1176 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp1_ = name; -#line 1176 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp2_ = g_hash_table_lookup (_tmp0_, _tmp1_); -#line 1176 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _vala_index = (gint) ((gintptr) _tmp2_); -#line 1177 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp3_ = _vala_index; -#line 1177 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - if (_tmp3_ == 0) { -#line 1178 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - result = NULL; -#line 1178 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - if (index) { -#line 1178 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - *index = _vala_index; -#line 10612 "scanner.c" - } -#line 1178 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - return result; -#line 10616 "scanner.c" - } -#line 1180 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp4_ = handle; -#line 1180 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp5_ = _vala_index; -#line 1180 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp6_ = sane_get_option_descriptor (_tmp4_, (SANE_Int) _tmp5_); -#line 1180 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - result = _tmp6_; -#line 1180 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - if (index) { -#line 1180 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - *index = _vala_index; -#line 10630 "scanner.c" - } -#line 1180 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - return result; -#line 10634 "scanner.c" -} - - -static void scanner_do_complete_document (Scanner* self) { - SANE_Handle _tmp0_ = {0}; - GList* _tmp1_ = NULL; - GList* _tmp2_ = NULL; - NotifyDocumentDone* _tmp3_ = NULL; - NotifyDocumentDone* _tmp4_ = NULL; -#line 1183 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - g_return_if_fail (self != NULL); -#line 1185 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp0_ = self->priv->handle; -#line 1185 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - sane_cancel (_tmp0_); -#line 1186 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - g_debug ("scanner.vala:1186: sane_cancel ()"); -#line 1188 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp1_ = self->priv->job_queue; -#line 1188 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - self->priv->job_queue = g_list_remove_link (self->priv->job_queue, _tmp1_); -#line 1190 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - self->priv->state = SCAN_STATE_IDLE; -#line 1193 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp2_ = self->priv->job_queue; -#line 1193 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - if (_tmp2_ != NULL) { -#line 1195 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - self->priv->state = SCAN_STATE_OPEN; -#line 1196 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - return; -#line 10666 "scanner.c" - } -#line 1202 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp3_ = notify_document_done_new (); -#line 1202 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp4_ = _tmp3_; -#line 1202 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - scanner_notify (self, (Notify*) _tmp4_); -#line 1202 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _notify_unref0 (_tmp4_); -#line 1203 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - scanner_set_scanning (self, FALSE); -#line 10678 "scanner.c" -} - - -static void scanner_do_start (Scanner* self) { - SANE_Status status = 0; - NotifyExpectPage* _tmp0_ = NULL; - NotifyExpectPage* _tmp1_ = NULL; - SANE_Handle _tmp2_ = {0}; - SANE_Status _tmp3_ = 0; - gint _tmp4_ = 0; - gint _tmp5_ = 0; - SANE_Status _tmp6_ = 0; - gchar* _tmp7_ = NULL; - gchar* _tmp8_ = NULL; - SANE_Status _tmp9_ = 0; -#line 1206 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - g_return_if_fail (self != NULL); -#line 1210 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp0_ = notify_expect_page_new (); -#line 1210 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp1_ = _tmp0_; -#line 1210 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - scanner_notify (self, (Notify*) _tmp1_); -#line 1210 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _notify_unref0 (_tmp1_); -#line 1212 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp2_ = self->priv->handle; -#line 1212 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp3_ = sane_start (_tmp2_); -#line 1212 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - status = _tmp3_; -#line 1213 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp4_ = self->priv->page_number; -#line 1213 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp5_ = self->priv->pass_number; -#line 1213 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp6_ = status; -#line 1213 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp7_ = sane_status_to_string (_tmp6_); -#line 1213 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp8_ = _tmp7_; -#line 1213 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - g_debug ("scanner.vala:1213: sane_start (page=%d, pass=%d) -> %s", _tmp4_, _tmp5_, _tmp8_); -#line 1213 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _g_free0 (_tmp8_); -#line 1214 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp9_ = status; -#line 1214 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - if (_tmp9_ == SANE_STATUS_GOOD) { -#line 1215 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - self->priv->state = SCAN_STATE_GET_PARAMETERS; -#line 10730 "scanner.c" - } else { - SANE_Status _tmp10_ = 0; -#line 1216 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp10_ = status; -#line 1216 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - if (_tmp10_ == SANE_STATUS_NO_DOCS) { -#line 1217 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - scanner_do_complete_document (self); -#line 10739 "scanner.c" - } else { - SANE_Status _tmp11_ = 0; - const gchar* _tmp12_ = NULL; - SANE_Status _tmp13_ = 0; - const gchar* _tmp14_ = NULL; -#line 1220 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp11_ = status; -#line 1220 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp12_ = sane_strstatus (_tmp11_); -#line 1220 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - g_warning ("scanner.vala:1220: Unable to start device: %s", _tmp12_); -#line 1221 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp13_ = status; -#line 1221 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp14_ = _ ("Unable to start scan"); -#line 1221 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - scanner_fail_scan (self, (gint) _tmp13_, _tmp14_); -#line 10757 "scanner.c" - } - } -} - - -static gchar* sane_frame_to_string (SANE_Frame frame) { - gchar* result = NULL; - SANE_Frame _tmp0_ = 0; -#line 103 "/home/bob/bzr/simple-scan/trunk/src/sane.vapi" - _tmp0_ = frame; -#line 103 "/home/bob/bzr/simple-scan/trunk/src/sane.vapi" - switch (_tmp0_) { -#line 103 "/home/bob/bzr/simple-scan/trunk/src/sane.vapi" - case SANE_FRAME_GRAY: -#line 10772 "scanner.c" - { - gchar* _tmp1_ = NULL; -#line 106 "/home/bob/bzr/simple-scan/trunk/src/sane.vapi" - _tmp1_ = g_strdup ("SANE_FRAME_GRAY"); -#line 106 "/home/bob/bzr/simple-scan/trunk/src/sane.vapi" - result = _tmp1_; -#line 106 "/home/bob/bzr/simple-scan/trunk/src/sane.vapi" - return result; -#line 10781 "scanner.c" - } -#line 103 "/home/bob/bzr/simple-scan/trunk/src/sane.vapi" - case SANE_FRAME_RGB: -#line 10785 "scanner.c" - { - gchar* _tmp2_ = NULL; -#line 108 "/home/bob/bzr/simple-scan/trunk/src/sane.vapi" - _tmp2_ = g_strdup ("SANE_FRAME_RGB"); -#line 108 "/home/bob/bzr/simple-scan/trunk/src/sane.vapi" - result = _tmp2_; -#line 108 "/home/bob/bzr/simple-scan/trunk/src/sane.vapi" - return result; -#line 10794 "scanner.c" - } -#line 103 "/home/bob/bzr/simple-scan/trunk/src/sane.vapi" - case SANE_FRAME_RED: -#line 10798 "scanner.c" - { - gchar* _tmp3_ = NULL; -#line 110 "/home/bob/bzr/simple-scan/trunk/src/sane.vapi" - _tmp3_ = g_strdup ("SANE_FRAME_RED"); -#line 110 "/home/bob/bzr/simple-scan/trunk/src/sane.vapi" - result = _tmp3_; -#line 110 "/home/bob/bzr/simple-scan/trunk/src/sane.vapi" - return result; -#line 10807 "scanner.c" - } -#line 103 "/home/bob/bzr/simple-scan/trunk/src/sane.vapi" - case SANE_FRAME_GREEN: -#line 10811 "scanner.c" - { - gchar* _tmp4_ = NULL; -#line 112 "/home/bob/bzr/simple-scan/trunk/src/sane.vapi" - _tmp4_ = g_strdup ("SANE_FRAME_GREEN"); -#line 112 "/home/bob/bzr/simple-scan/trunk/src/sane.vapi" - result = _tmp4_; -#line 112 "/home/bob/bzr/simple-scan/trunk/src/sane.vapi" - return result; -#line 10820 "scanner.c" - } -#line 103 "/home/bob/bzr/simple-scan/trunk/src/sane.vapi" - case SANE_FRAME_BLUE: -#line 10824 "scanner.c" - { - gchar* _tmp5_ = NULL; -#line 114 "/home/bob/bzr/simple-scan/trunk/src/sane.vapi" - _tmp5_ = g_strdup ("SANE_FRAME_BLUE"); -#line 114 "/home/bob/bzr/simple-scan/trunk/src/sane.vapi" - result = _tmp5_; -#line 114 "/home/bob/bzr/simple-scan/trunk/src/sane.vapi" - return result; -#line 10833 "scanner.c" - } - default: - { - SANE_Frame _tmp6_ = 0; - gchar* _tmp7_ = NULL; -#line 116 "/home/bob/bzr/simple-scan/trunk/src/sane.vapi" - _tmp6_ = frame; -#line 116 "/home/bob/bzr/simple-scan/trunk/src/sane.vapi" - _tmp7_ = g_strdup_printf ("SANE_FRAME(%d)", (gint) _tmp6_); -#line 116 "/home/bob/bzr/simple-scan/trunk/src/sane.vapi" - result = _tmp7_; -#line 116 "/home/bob/bzr/simple-scan/trunk/src/sane.vapi" - return result; -#line 10847 "scanner.c" - } - } -} - - -static void scanner_do_get_parameters (Scanner* self) { - SANE_Status status = 0; - SANE_Handle _tmp0_ = {0}; - SANE_Parameters _tmp1_ = {0}; - SANE_Status _tmp2_ = 0; - SANE_Status _tmp3_ = 0; - gchar* _tmp4_ = NULL; - gchar* _tmp5_ = NULL; - SANE_Status _tmp6_ = 0; - ScanJob* job = NULL; - GList* _tmp11_ = NULL; - gconstpointer _tmp12_ = NULL; - ScanJob* _tmp13_ = NULL; - const gchar* _tmp14_ = NULL; - SANE_Parameters _tmp15_ = {0}; - gboolean _tmp16_ = FALSE; - SANE_Parameters _tmp17_ = {0}; - SANE_Frame _tmp18_ = 0; - gchar* _tmp19_ = NULL; - gchar* _tmp20_ = NULL; - SANE_Parameters _tmp21_ = {0}; - gint _tmp22_ = 0; - SANE_Parameters _tmp23_ = {0}; - gint _tmp24_ = 0; - SANE_Parameters _tmp25_ = {0}; - gint _tmp26_ = 0; - SANE_Parameters _tmp27_ = {0}; - gint _tmp28_ = 0; - ScanPageInfo* info = NULL; - ScanPageInfo* _tmp29_ = NULL; - ScanPageInfo* _tmp30_ = NULL; - SANE_Parameters _tmp31_ = {0}; - gint _tmp32_ = 0; - ScanPageInfo* _tmp33_ = NULL; - SANE_Parameters _tmp34_ = {0}; - gint _tmp35_ = 0; - ScanPageInfo* _tmp36_ = NULL; - SANE_Parameters _tmp37_ = {0}; - gint _tmp38_ = 0; - gboolean _tmp39_ = FALSE; - gboolean _tmp40_ = FALSE; - gboolean _tmp41_ = FALSE; - SANE_Parameters _tmp42_ = {0}; - gint _tmp43_ = 0; - gint _tmp53_ = 0; - SANE_Parameters _tmp54_ = {0}; - SANE_Frame _tmp55_ = 0; - ScanPageInfo* _tmp56_ = NULL; - ScanPageInfo* _tmp57_ = NULL; - ScanJob* _tmp58_ = NULL; - gdouble _tmp59_ = 0.0; - ScanPageInfo* _tmp60_ = NULL; - const gchar* _tmp61_ = NULL; - gchar* _tmp62_ = NULL; - gint _tmp63_ = 0; - gint _tmp64_ = 0; - gint buffer_size = 0; - SANE_Parameters _tmp71_ = {0}; - gint _tmp72_ = 0; - gint _tmp73_ = 0; - guchar* _tmp74_ = NULL; -#line 1227 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - g_return_if_fail (self != NULL); -#line 1229 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp0_ = self->priv->handle; -#line 1229 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp2_ = sane_get_parameters (_tmp0_, &_tmp1_); -#line 1229 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - self->priv->parameters = _tmp1_; -#line 1229 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - status = _tmp2_; -#line 1230 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp3_ = status; -#line 1230 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp4_ = sane_status_to_string (_tmp3_); -#line 1230 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp5_ = _tmp4_; -#line 1230 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - g_debug ("scanner.vala:1230: sane_get_parameters () -> %s", _tmp5_); -#line 1230 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _g_free0 (_tmp5_); -#line 1231 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp6_ = status; -#line 1231 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - if (_tmp6_ != SANE_STATUS_GOOD) { -#line 10938 "scanner.c" - SANE_Status _tmp7_ = 0; - const gchar* _tmp8_ = NULL; - SANE_Status _tmp9_ = 0; - const gchar* _tmp10_ = NULL; -#line 1233 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp7_ = status; -#line 1233 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp8_ = sane_strstatus (_tmp7_); -#line 1233 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - g_warning ("scanner.vala:1233: Unable to get device parameters: %s", _tmp8_); -#line 1234 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp9_ = status; -#line 1234 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp10_ = _ ("Error communicating with scanner"); -#line 1234 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - scanner_fail_scan (self, (gint) _tmp9_, _tmp10_); -#line 1237 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - return; -#line 10957 "scanner.c" - } -#line 1240 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp11_ = self->priv->job_queue; -#line 1240 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp12_ = _tmp11_->data; -#line 1240 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp13_ = _scan_job_ref0 (G_TYPE_CHECK_INSTANCE_CAST ((ScanJob*) _tmp12_, TYPE_SCAN_JOB, ScanJob)); -#line 1240 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - job = _tmp13_; -#line 1244 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp15_ = self->priv->parameters; -#line 1244 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp16_ = _tmp15_.last_frame; -#line 1244 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - if (_tmp16_) { -#line 1244 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp14_ = "SANE_TRUE"; -#line 10975 "scanner.c" - } else { -#line 1244 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp14_ = "SANE_FALSE"; -#line 10979 "scanner.c" - } -#line 1242 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp17_ = self->priv->parameters; -#line 1242 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp18_ = _tmp17_.format; -#line 1242 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp19_ = sane_frame_to_string (_tmp18_); -#line 1242 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp20_ = _tmp19_; -#line 1242 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp21_ = self->priv->parameters; -#line 1242 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp22_ = _tmp21_.bytes_per_line; -#line 1242 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp23_ = self->priv->parameters; -#line 1242 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp24_ = _tmp23_.pixels_per_line; -#line 1242 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp25_ = self->priv->parameters; -#line 1242 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp26_ = _tmp25_.lines; -#line 1242 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp27_ = self->priv->parameters; -#line 1242 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp28_ = _tmp27_.depth; -#line 1242 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - g_debug ("scanner.vala:1242: Parameters: format=%s last_frame=%s bytes_per_line=" \ -"%d pixels_per_line=%d lines=%d depth=%d", _tmp20_, _tmp14_, _tmp22_, _tmp24_, _tmp26_, _tmp28_); -#line 1242 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _g_free0 (_tmp20_); -#line 1250 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp29_ = scan_page_info_new (); -#line 1250 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - info = _tmp29_; -#line 1251 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp30_ = info; -#line 1251 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp31_ = self->priv->parameters; -#line 1251 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp32_ = _tmp31_.pixels_per_line; -#line 1251 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp30_->width = _tmp32_; -#line 1252 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp33_ = info; -#line 1252 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp34_ = self->priv->parameters; -#line 1252 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp35_ = _tmp34_.lines; -#line 1252 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp33_->height = _tmp35_; -#line 1253 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp36_ = info; -#line 1253 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp37_ = self->priv->parameters; -#line 1253 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp38_ = _tmp37_.depth; -#line 1253 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp36_->depth = _tmp38_; -#line 1256 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp42_ = self->priv->parameters; -#line 1256 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp43_ = _tmp42_.depth; -#line 1256 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - if (_tmp43_ == 8) { -#line 11043 "scanner.c" - SANE_Parameters _tmp44_ = {0}; - SANE_Frame _tmp45_ = 0; -#line 1256 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp44_ = self->priv->parameters; -#line 1256 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp45_ = _tmp44_.format; -#line 1256 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp41_ = _tmp45_ == SANE_FRAME_GRAY; -#line 11052 "scanner.c" - } else { -#line 1256 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp41_ = FALSE; -#line 11056 "scanner.c" - } -#line 1256 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - if (_tmp41_) { -#line 11060 "scanner.c" - ScanJob* _tmp46_ = NULL; - gint _tmp47_ = 0; -#line 1256 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp46_ = job; -#line 1256 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp47_ = _tmp46_->depth; -#line 1256 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp40_ = _tmp47_ == 2; -#line 11069 "scanner.c" - } else { -#line 1256 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp40_ = FALSE; -#line 11073 "scanner.c" - } -#line 1256 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - if (_tmp40_) { -#line 11077 "scanner.c" - ScanJob* _tmp48_ = NULL; - ScanMode _tmp49_ = 0; -#line 1256 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp48_ = job; -#line 1256 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp49_ = _tmp48_->scan_mode; -#line 1256 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp39_ = _tmp49_ == SCAN_MODE_GRAY; -#line 11086 "scanner.c" - } else { -#line 1256 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp39_ = FALSE; -#line 11090 "scanner.c" - } -#line 1256 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - if (_tmp39_) { -#line 11094 "scanner.c" - ScanPageInfo* _tmp50_ = NULL; - ScanJob* _tmp51_ = NULL; - gint _tmp52_ = 0; -#line 1257 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp50_ = info; -#line 1257 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp51_ = job; -#line 1257 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp52_ = _tmp51_->depth; -#line 1257 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp50_->depth = _tmp52_; -#line 11106 "scanner.c" - } -#line 1258 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp54_ = self->priv->parameters; -#line 1258 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp55_ = _tmp54_.format; -#line 1258 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - if (_tmp55_ == SANE_FRAME_GRAY) { -#line 1258 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp53_ = 1; -#line 11116 "scanner.c" - } else { -#line 1258 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp53_ = 3; -#line 11120 "scanner.c" - } -#line 1258 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp56_ = info; -#line 1258 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp56_->n_channels = _tmp53_; -#line 1259 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp57_ = info; -#line 1259 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp58_ = job; -#line 1259 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp59_ = _tmp58_->dpi; -#line 1259 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp57_->dpi = _tmp59_; -#line 1260 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp60_ = info; -#line 1260 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp61_ = self->priv->current_device; -#line 1260 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp62_ = g_strdup (_tmp61_); -#line 1260 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _g_free0 (_tmp60_->device); -#line 1260 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp60_->device = _tmp62_; -#line 1262 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp63_ = self->priv->page_number; -#line 1262 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp64_ = self->priv->notified_page; -#line 1262 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - if (_tmp63_ != _tmp64_) { -#line 11150 "scanner.c" - ScanJob* _tmp65_ = NULL; - gint _tmp66_ = 0; - ScanPageInfo* _tmp67_ = NULL; - NotifyGotPageInfo* _tmp68_ = NULL; - NotifyGotPageInfo* _tmp69_ = NULL; - gint _tmp70_ = 0; -#line 1264 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp65_ = job; -#line 1264 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp66_ = _tmp65_->id; -#line 1264 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp67_ = info; -#line 1264 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp68_ = notify_got_page_info_new (_tmp66_, _tmp67_); -#line 1264 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp69_ = _tmp68_; -#line 1264 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - scanner_notify (self, (Notify*) _tmp69_); -#line 1264 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _notify_unref0 (_tmp69_); -#line 1265 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp70_ = self->priv->page_number; -#line 1265 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - self->priv->notified_page = _tmp70_; -#line 11175 "scanner.c" - } -#line 1269 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp71_ = self->priv->parameters; -#line 1269 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp72_ = _tmp71_.bytes_per_line; -#line 1269 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - buffer_size = _tmp72_ + 1; -#line 1270 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp73_ = buffer_size; -#line 1270 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp74_ = g_new0 (guchar, _tmp73_); -#line 1270 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - self->priv->buffer = (g_free (self->priv->buffer), NULL); -#line 1270 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - self->priv->buffer = _tmp74_; -#line 1270 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - self->priv->buffer_length1 = _tmp73_; -#line 1270 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - self->priv->_buffer_size_ = self->priv->buffer_length1; -#line 1271 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - self->priv->n_used = 0; -#line 1272 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - self->priv->line_count = 0; -#line 1273 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - self->priv->pass_number = 0; -#line 1274 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - self->priv->state = SCAN_STATE_READ; -#line 1227 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _scan_page_info_unref0 (info); -#line 1227 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _scan_job_unref0 (job); -#line 11207 "scanner.c" -} - - -static void scanner_do_complete_page (Scanner* self) { - ScanJob* job = NULL; - GList* _tmp0_ = NULL; - gconstpointer _tmp1_ = NULL; - ScanJob* _tmp2_ = NULL; - ScanJob* _tmp3_ = NULL; - gint _tmp4_ = 0; - NotifyPageDone* _tmp5_ = NULL; - NotifyPageDone* _tmp6_ = NULL; - SANE_Parameters _tmp7_ = {0}; - gboolean _tmp8_ = FALSE; - ScanJob* _tmp10_ = NULL; - ScanType _tmp11_ = 0; -#line 1277 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - g_return_if_fail (self != NULL); -#line 1279 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp0_ = self->priv->job_queue; -#line 1279 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp1_ = _tmp0_->data; -#line 1279 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp2_ = _scan_job_ref0 (G_TYPE_CHECK_INSTANCE_CAST ((ScanJob*) _tmp1_, TYPE_SCAN_JOB, ScanJob)); -#line 1279 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - job = _tmp2_; -#line 1281 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp3_ = job; -#line 1281 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp4_ = _tmp3_->id; -#line 1281 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp5_ = notify_page_done_new (_tmp4_); -#line 1281 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp6_ = _tmp5_; -#line 1281 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - scanner_notify (self, (Notify*) _tmp6_); -#line 1281 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _notify_unref0 (_tmp6_); -#line 1284 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp7_ = self->priv->parameters; -#line 1284 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp8_ = _tmp7_.last_frame; -#line 1284 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - if (!_tmp8_) { -#line 11252 "scanner.c" - gint _tmp9_ = 0; -#line 1286 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp9_ = self->priv->pass_number; -#line 1286 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - self->priv->pass_number = _tmp9_ + 1; -#line 1287 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - self->priv->state = SCAN_STATE_START; -#line 1288 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _scan_job_unref0 (job); -#line 1288 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - return; -#line 11264 "scanner.c" - } -#line 1292 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp10_ = job; -#line 1292 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp11_ = _tmp10_->type; -#line 1292 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - if (_tmp11_ != SCAN_TYPE_SINGLE) { -#line 11272 "scanner.c" - gint _tmp12_ = 0; - ScanJob* _tmp13_ = NULL; - gint _tmp14_ = 0; - NotifyPageDone* _tmp15_ = NULL; - NotifyPageDone* _tmp16_ = NULL; -#line 1294 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp12_ = self->priv->page_number; -#line 1294 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - self->priv->page_number = _tmp12_ + 1; -#line 1295 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - self->priv->pass_number = 0; -#line 1296 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp13_ = job; -#line 1296 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp14_ = _tmp13_->id; -#line 1296 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp15_ = notify_page_done_new (_tmp14_); -#line 1296 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp16_ = _tmp15_; -#line 1296 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - scanner_notify (self, (Notify*) _tmp16_); -#line 1296 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _notify_unref0 (_tmp16_); -#line 1297 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - self->priv->state = SCAN_STATE_START; -#line 1298 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _scan_job_unref0 (job); -#line 1298 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - return; -#line 11302 "scanner.c" - } -#line 1301 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - scanner_do_complete_document (self); -#line 1277 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _scan_job_unref0 (job); -#line 11308 "scanner.c" -} - - -static void scanner_do_read (Scanner* self) { - ScanJob* job = NULL; - GList* _tmp0_ = NULL; - gconstpointer _tmp1_ = NULL; - ScanJob* _tmp2_ = NULL; - gint n_to_read = 0; - guchar* _tmp3_ = NULL; - gint _tmp3__length1 = 0; - gint _tmp4_ = 0; - SANE_Int n_read = {0}; - guchar* b = NULL; - guchar* _tmp5_ = NULL; - gint _tmp5__length1 = 0; - SANE_Status status = 0; - SANE_Handle _tmp6_ = {0}; - guchar* _tmp7_ = NULL; - gint _tmp8_ = 0; - gint _tmp9_ = 0; - SANE_Int _tmp10_ = {0}; - SANE_Status _tmp11_ = 0; - gint _tmp12_ = 0; - SANE_Status _tmp13_ = 0; - gchar* _tmp14_ = NULL; - gchar* _tmp15_ = NULL; - SANE_Int _tmp16_ = {0}; - SANE_Status _tmp17_ = 0; - SANE_Status _tmp29_ = 0; - gboolean full_read = FALSE; - gboolean _tmp34_ = FALSE; - gint _tmp35_ = 0; - gint _tmp38_ = 0; - SANE_Int _tmp39_ = {0}; - gint _tmp40_ = 0; - SANE_Parameters _tmp41_ = {0}; - gint _tmp42_ = 0; -#line 1304 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - g_return_if_fail (self != NULL); -#line 1306 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp0_ = self->priv->job_queue; -#line 1306 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp1_ = _tmp0_->data; -#line 1306 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp2_ = _scan_job_ref0 (G_TYPE_CHECK_INSTANCE_CAST ((ScanJob*) _tmp1_, TYPE_SCAN_JOB, ScanJob)); -#line 1306 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - job = _tmp2_; -#line 1309 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp3_ = self->priv->buffer; -#line 1309 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp3__length1 = self->priv->buffer_length1; -#line 1309 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp4_ = self->priv->n_used; -#line 1309 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - n_to_read = _tmp3__length1 - _tmp4_; -#line 1312 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp5_ = self->priv->buffer; -#line 1312 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp5__length1 = self->priv->buffer_length1; -#line 1312 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - b = (guchar*) _tmp5_; -#line 1313 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp6_ = self->priv->handle; -#line 1313 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp7_ = b; -#line 1313 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp8_ = self->priv->n_used; -#line 1313 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp9_ = n_to_read; -#line 1313 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp11_ = sane_read (_tmp6_, (guint8*) (_tmp7_ + _tmp8_), (SANE_Int) _tmp9_, &_tmp10_); -#line 1313 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - n_read = _tmp10_; -#line 1313 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - status = _tmp11_; -#line 1314 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp12_ = n_to_read; -#line 1314 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp13_ = status; -#line 1314 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp14_ = sane_status_to_string (_tmp13_); -#line 1314 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp15_ = _tmp14_; -#line 1314 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp16_ = n_read; -#line 1314 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - g_debug ("scanner.vala:1314: sane_read (%d) -> (%s, %d)", _tmp12_, _tmp15_, (gint) _tmp16_); -#line 1314 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _g_free0 (_tmp15_); -#line 1317 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp17_ = status; -#line 1317 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - if (_tmp17_ == SANE_STATUS_EOF) { -#line 11403 "scanner.c" - gboolean _tmp18_ = FALSE; - SANE_Parameters _tmp19_ = {0}; - gint _tmp20_ = 0; - gint _tmp27_ = 0; -#line 1319 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp19_ = self->priv->parameters; -#line 1319 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp20_ = _tmp19_.lines; -#line 1319 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - if (_tmp20_ > 0) { -#line 11414 "scanner.c" - gint _tmp21_ = 0; - SANE_Parameters _tmp22_ = {0}; - gint _tmp23_ = 0; -#line 1319 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp21_ = self->priv->line_count; -#line 1319 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp22_ = self->priv->parameters; -#line 1319 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp23_ = _tmp22_.lines; -#line 1319 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp18_ = _tmp21_ != _tmp23_; -#line 11426 "scanner.c" - } else { -#line 1319 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp18_ = FALSE; -#line 11430 "scanner.c" - } -#line 1319 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - if (_tmp18_) { -#line 11434 "scanner.c" - gint _tmp24_ = 0; - SANE_Parameters _tmp25_ = {0}; - gint _tmp26_ = 0; -#line 1320 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp24_ = self->priv->line_count; -#line 1320 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp25_ = self->priv->parameters; -#line 1320 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp26_ = _tmp25_.lines; -#line 1320 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - g_warning ("scanner.vala:1320: Scan completed with %d lines, expected %d lines", _tmp24_, _tmp26_); -#line 11446 "scanner.c" - } -#line 1321 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp27_ = self->priv->n_used; -#line 1321 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - if (_tmp27_ > 0) { -#line 11452 "scanner.c" - gint _tmp28_ = 0; -#line 1322 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp28_ = self->priv->n_used; -#line 1322 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - g_warning ("scanner.vala:1322: Scan complete with %d bytes of unused data", _tmp28_); -#line 11458 "scanner.c" - } -#line 1323 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - scanner_do_complete_page (self); -#line 1324 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _scan_job_unref0 (job); -#line 1324 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - return; -#line 11466 "scanner.c" - } -#line 1328 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp29_ = status; -#line 1328 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - if (_tmp29_ != SANE_STATUS_GOOD) { -#line 11472 "scanner.c" - SANE_Status _tmp30_ = 0; - const gchar* _tmp31_ = NULL; - SANE_Status _tmp32_ = 0; - const gchar* _tmp33_ = NULL; -#line 1330 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp30_ = status; -#line 1330 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp31_ = sane_strstatus (_tmp30_); -#line 1330 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - g_warning ("scanner.vala:1330: Unable to read frame from device: %s", _tmp31_); -#line 1331 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp32_ = status; -#line 1331 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp33_ = _ ("Error communicating with scanner"); -#line 1331 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - scanner_fail_scan (self, (gint) _tmp32_, _tmp33_); -#line 1334 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _scan_job_unref0 (job); -#line 1334 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - return; -#line 11493 "scanner.c" - } -#line 1337 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - full_read = FALSE; -#line 1338 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp35_ = self->priv->n_used; -#line 1338 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - if (_tmp35_ == 0) { -#line 11501 "scanner.c" - SANE_Int _tmp36_ = {0}; - guchar* _tmp37_ = NULL; - gint _tmp37__length1 = 0; -#line 1338 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp36_ = n_read; -#line 1338 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp37_ = self->priv->buffer; -#line 1338 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp37__length1 = self->priv->buffer_length1; -#line 1338 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp34_ = _tmp36_ == ((SANE_Int) _tmp37__length1); -#line 11513 "scanner.c" - } else { -#line 1338 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp34_ = FALSE; -#line 11517 "scanner.c" - } -#line 1338 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - if (_tmp34_) { -#line 1339 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - full_read = TRUE; -#line 11523 "scanner.c" - } -#line 1340 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp38_ = self->priv->n_used; -#line 1340 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp39_ = n_read; -#line 1340 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - self->priv->n_used = _tmp38_ + ((gint) _tmp39_); -#line 1343 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp40_ = self->priv->n_used; -#line 1343 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp41_ = self->priv->parameters; -#line 1343 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp42_ = _tmp41_.bytes_per_line; -#line 1343 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - if (_tmp40_ >= _tmp42_) { -#line 11539 "scanner.c" - ScanLine* line = NULL; - ScanLine* _tmp43_ = NULL; - SANE_Parameters _tmp44_ = {0}; - SANE_Frame _tmp45_ = 0; - ScanLine* _tmp51_ = NULL; - SANE_Parameters _tmp52_ = {0}; - gint _tmp53_ = 0; - ScanLine* _tmp54_ = NULL; - SANE_Parameters _tmp55_ = {0}; - gint _tmp56_ = 0; - ScanLine* _tmp57_ = NULL; - guchar* _tmp58_ = NULL; - gint _tmp58__length1 = 0; - ScanLine* _tmp59_ = NULL; - SANE_Parameters _tmp60_ = {0}; - gint _tmp61_ = 0; - ScanLine* _tmp62_ = NULL; - gint _tmp63_ = 0; - ScanLine* _tmp64_ = NULL; - gint _tmp65_ = 0; - ScanLine* _tmp66_ = NULL; - gint _tmp67_ = 0; - gint _tmp68_ = 0; - ScanLine* _tmp69_ = NULL; - gint _tmp70_ = 0; - gint buffer_size = 0; - ScanLine* _tmp71_ = NULL; - guchar* _tmp72_ = NULL; - gint _tmp72__length1 = 0; - gboolean _tmp73_ = FALSE; - gint _tmp77_ = 0; - guchar* _tmp78_ = NULL; - gint n_remaining = 0; - gint _tmp79_ = 0; - ScanLine* _tmp80_ = NULL; - gint _tmp81_ = 0; - ScanLine* _tmp82_ = NULL; - gint _tmp83_ = 0; - gboolean _tmp100_ = FALSE; - gboolean _tmp101_ = FALSE; - gboolean _tmp102_ = FALSE; - SANE_Parameters _tmp103_ = {0}; - gint _tmp104_ = 0; - ScanJob* _tmp153_ = NULL; - gint _tmp154_ = 0; - ScanLine* _tmp155_ = NULL; - NotifyGotLine* _tmp156_ = NULL; - NotifyGotLine* _tmp157_ = NULL; -#line 1345 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp43_ = scan_line_new (); -#line 1345 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - line = _tmp43_; -#line 1346 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp44_ = self->priv->parameters; -#line 1346 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp45_ = _tmp44_.format; -#line 1346 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - switch (_tmp45_) { -#line 1346 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - case SANE_FRAME_GRAY: -#line 11600 "scanner.c" - { - ScanLine* _tmp46_ = NULL; -#line 1349 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp46_ = line; -#line 1349 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp46_->channel = 0; -#line 1350 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - break; -#line 11609 "scanner.c" - } -#line 1346 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - case SANE_FRAME_RGB: -#line 11613 "scanner.c" - { - ScanLine* _tmp47_ = NULL; -#line 1352 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp47_ = line; -#line 1352 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp47_->channel = -1; -#line 1353 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - break; -#line 11622 "scanner.c" - } -#line 1346 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - case SANE_FRAME_RED: -#line 11626 "scanner.c" - { - ScanLine* _tmp48_ = NULL; -#line 1355 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp48_ = line; -#line 1355 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp48_->channel = 0; -#line 1356 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - break; -#line 11635 "scanner.c" - } -#line 1346 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - case SANE_FRAME_GREEN: -#line 11639 "scanner.c" - { - ScanLine* _tmp49_ = NULL; -#line 1358 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp49_ = line; -#line 1358 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp49_->channel = 1; -#line 1359 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - break; -#line 11648 "scanner.c" - } -#line 1346 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - case SANE_FRAME_BLUE: -#line 11652 "scanner.c" - { - ScanLine* _tmp50_ = NULL; -#line 1361 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp50_ = line; -#line 1361 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp50_->channel = 2; -#line 1362 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - break; -#line 11661 "scanner.c" - } - default: -#line 1346 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - break; -#line 11666 "scanner.c" - } -#line 1364 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp51_ = line; -#line 1364 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp52_ = self->priv->parameters; -#line 1364 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp53_ = _tmp52_.pixels_per_line; -#line 1364 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp51_->width = _tmp53_; -#line 1365 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp54_ = line; -#line 1365 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp55_ = self->priv->parameters; -#line 1365 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp56_ = _tmp55_.depth; -#line 1365 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp54_->depth = _tmp56_; -#line 1366 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp57_ = line; -#line 1366 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp58_ = self->priv->buffer; -#line 1366 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp58__length1 = self->priv->buffer_length1; -#line 1366 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - self->priv->buffer = NULL; -#line 1366 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - self->priv->buffer_length1 = 0; -#line 1366 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp57_->data = (g_free (_tmp57_->data), NULL); -#line 1366 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp57_->data = _tmp58_; -#line 1366 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp57_->data_length1 = _tmp58__length1; -#line 1367 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp59_ = line; -#line 1367 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp60_ = self->priv->parameters; -#line 1367 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp61_ = _tmp60_.bytes_per_line; -#line 1367 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp59_->data_length = _tmp61_; -#line 1368 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp62_ = line; -#line 1368 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp63_ = self->priv->line_count; -#line 1368 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp62_->number = _tmp63_; -#line 1369 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp64_ = line; -#line 1369 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp65_ = self->priv->n_used; -#line 1369 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp66_ = line; -#line 1369 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp67_ = _tmp66_->data_length; -#line 1369 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp64_->n_lines = _tmp65_ / _tmp67_; -#line 1371 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp68_ = self->priv->line_count; -#line 1371 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp69_ = line; -#line 1371 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp70_ = _tmp69_->n_lines; -#line 1371 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - self->priv->line_count = _tmp68_ + _tmp70_; -#line 1374 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp71_ = line; -#line 1374 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp72_ = _tmp71_->data; -#line 1374 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp72__length1 = _tmp71_->data_length1; -#line 1374 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - buffer_size = _tmp72__length1; -#line 1375 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp73_ = full_read; -#line 1375 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - if (_tmp73_) { -#line 11744 "scanner.c" - gint _tmp74_ = 0; - SANE_Parameters _tmp75_ = {0}; - gint _tmp76_ = 0; -#line 1376 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp74_ = buffer_size; -#line 1376 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp75_ = self->priv->parameters; -#line 1376 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp76_ = _tmp75_.bytes_per_line; -#line 1376 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - buffer_size = _tmp74_ + _tmp76_; -#line 11756 "scanner.c" - } -#line 1378 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp77_ = buffer_size; -#line 1378 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp78_ = g_new0 (guchar, _tmp77_); -#line 1378 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - self->priv->buffer = (g_free (self->priv->buffer), NULL); -#line 1378 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - self->priv->buffer = _tmp78_; -#line 1378 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - self->priv->buffer_length1 = _tmp77_; -#line 1378 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - self->priv->_buffer_size_ = self->priv->buffer_length1; -#line 1379 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp79_ = self->priv->n_used; -#line 1379 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp80_ = line; -#line 1379 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp81_ = _tmp80_->n_lines; -#line 1379 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp82_ = line; -#line 1379 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp83_ = _tmp82_->data_length; -#line 1379 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - n_remaining = _tmp79_ - (_tmp81_ * _tmp83_); -#line 1380 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - self->priv->n_used = 0; -#line 11784 "scanner.c" - { - gint i = 0; -#line 1381 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - i = 0; -#line 11789 "scanner.c" - { - gboolean _tmp84_ = FALSE; -#line 1381 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp84_ = TRUE; -#line 1381 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - while (TRUE) { -#line 11796 "scanner.c" - gint _tmp86_ = 0; - gint _tmp87_ = 0; - guchar* _tmp88_ = NULL; - gint _tmp88__length1 = 0; - gint _tmp89_ = 0; - ScanLine* _tmp90_ = NULL; - guchar* _tmp91_ = NULL; - gint _tmp91__length1 = 0; - gint _tmp92_ = 0; - ScanLine* _tmp93_ = NULL; - gint _tmp94_ = 0; - ScanLine* _tmp95_ = NULL; - gint _tmp96_ = 0; - guchar _tmp97_ = '\0'; - guchar _tmp98_ = '\0'; - gint _tmp99_ = 0; -#line 1381 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - if (!_tmp84_) { -#line 11815 "scanner.c" - gint _tmp85_ = 0; -#line 1381 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp85_ = i; -#line 1381 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - i = _tmp85_ + 1; -#line 11821 "scanner.c" - } -#line 1381 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp84_ = FALSE; -#line 1381 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp86_ = i; -#line 1381 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp87_ = n_remaining; -#line 1381 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - if (!(_tmp86_ < _tmp87_)) { -#line 1381 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - break; -#line 11833 "scanner.c" - } -#line 1383 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp88_ = self->priv->buffer; -#line 1383 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp88__length1 = self->priv->buffer_length1; -#line 1383 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp89_ = i; -#line 1383 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp90_ = line; -#line 1383 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp91_ = _tmp90_->data; -#line 1383 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp91__length1 = _tmp90_->data_length1; -#line 1383 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp92_ = i; -#line 1383 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp93_ = line; -#line 1383 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp94_ = _tmp93_->n_lines; -#line 1383 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp95_ = line; -#line 1383 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp96_ = _tmp95_->data_length; -#line 1383 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp97_ = _tmp91_[_tmp92_ + (_tmp94_ * _tmp96_)]; -#line 1383 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp88_[_tmp89_] = _tmp97_; -#line 1383 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp98_ = _tmp88_[_tmp89_]; -#line 1384 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp99_ = self->priv->n_used; -#line 1384 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - self->priv->n_used = _tmp99_ + 1; -#line 11867 "scanner.c" - } - } - } -#line 1389 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp103_ = self->priv->parameters; -#line 1389 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp104_ = _tmp103_.depth; -#line 1389 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - if (_tmp104_ == 8) { -#line 11877 "scanner.c" - SANE_Parameters _tmp105_ = {0}; - SANE_Frame _tmp106_ = 0; -#line 1389 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp105_ = self->priv->parameters; -#line 1389 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp106_ = _tmp105_.format; -#line 1389 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp102_ = _tmp106_ == SANE_FRAME_GRAY; -#line 11886 "scanner.c" - } else { -#line 1389 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp102_ = FALSE; -#line 11890 "scanner.c" - } -#line 1389 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - if (_tmp102_) { -#line 11894 "scanner.c" - ScanJob* _tmp107_ = NULL; - gint _tmp108_ = 0; -#line 1390 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp107_ = job; -#line 1390 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp108_ = _tmp107_->depth; -#line 1390 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp101_ = _tmp108_ == 2; -#line 11903 "scanner.c" - } else { -#line 1389 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp101_ = FALSE; -#line 11907 "scanner.c" - } -#line 1389 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - if (_tmp101_) { -#line 11911 "scanner.c" - ScanJob* _tmp109_ = NULL; - ScanMode _tmp110_ = 0; -#line 1390 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp109_ = job; -#line 1390 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp110_ = _tmp109_->scan_mode; -#line 1390 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp100_ = _tmp110_ == SCAN_MODE_GRAY; -#line 11920 "scanner.c" - } else { -#line 1389 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp100_ = FALSE; -#line 11924 "scanner.c" - } -#line 1389 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - if (_tmp100_) { -#line 11928 "scanner.c" - guchar block = '\0'; - gint write_offset = 0; - gint block_shift = 0; - ScanLine* _tmp150_ = NULL; - ScanLine* _tmp151_ = NULL; - gint _tmp152_ = 0; -#line 1392 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - block = (guchar) 0; -#line 1393 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - write_offset = 0; -#line 1394 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - block_shift = 6; -#line 11941 "scanner.c" - { - gint i = 0; -#line 1395 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - i = 0; -#line 11946 "scanner.c" - { - gboolean _tmp111_ = FALSE; -#line 1395 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp111_ = TRUE; -#line 1395 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - while (TRUE) { -#line 11953 "scanner.c" - gint _tmp113_ = 0; - ScanLine* _tmp114_ = NULL; - gint _tmp115_ = 0; - gint offset = 0; - gint _tmp116_ = 0; - ScanLine* _tmp117_ = NULL; - gint _tmp118_ = 0; - gint _tmp143_ = 0; -#line 1395 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - if (!_tmp111_) { -#line 11964 "scanner.c" - gint _tmp112_ = 0; -#line 1395 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp112_ = i; -#line 1395 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - i = _tmp112_ + 1; -#line 11970 "scanner.c" - } -#line 1395 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp111_ = FALSE; -#line 1395 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp113_ = i; -#line 1395 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp114_ = line; -#line 1395 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp115_ = _tmp114_->n_lines; -#line 1395 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - if (!(_tmp113_ < _tmp115_)) { -#line 1395 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - break; -#line 11984 "scanner.c" - } -#line 1397 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp116_ = i; -#line 1397 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp117_ = line; -#line 1397 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp118_ = _tmp117_->data_length; -#line 1397 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - offset = _tmp116_ * _tmp118_; -#line 11994 "scanner.c" - { - gint x = 0; -#line 1398 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - x = 0; -#line 11999 "scanner.c" - { - gboolean _tmp119_ = FALSE; -#line 1398 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp119_ = TRUE; -#line 1398 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - while (TRUE) { -#line 12006 "scanner.c" - gint _tmp121_ = 0; - ScanLine* _tmp122_ = NULL; - gint _tmp123_ = 0; - guchar p = '\0'; - ScanLine* _tmp124_ = NULL; - guchar* _tmp125_ = NULL; - gint _tmp125__length1 = 0; - gint _tmp126_ = 0; - gint _tmp127_ = 0; - guchar _tmp128_ = '\0'; - guchar sample = '\0'; - guchar _tmp129_ = '\0'; - guchar _tmp132_ = '\0'; - guchar _tmp133_ = '\0'; - gint _tmp134_ = 0; - gint _tmp135_ = 0; -#line 1398 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - if (!_tmp119_) { -#line 12025 "scanner.c" - gint _tmp120_ = 0; -#line 1398 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp120_ = x; -#line 1398 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - x = _tmp120_ + 1; -#line 12031 "scanner.c" - } -#line 1398 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp119_ = FALSE; -#line 1398 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp121_ = x; -#line 1398 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp122_ = line; -#line 1398 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp123_ = _tmp122_->width; -#line 1398 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - if (!(_tmp121_ < _tmp123_)) { -#line 1398 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - break; -#line 12045 "scanner.c" - } -#line 1400 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp124_ = line; -#line 1400 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp125_ = _tmp124_->data; -#line 1400 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp125__length1 = _tmp124_->data_length1; -#line 1400 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp126_ = offset; -#line 1400 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp127_ = x; -#line 1400 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp128_ = _tmp125_[_tmp126_ + _tmp127_]; -#line 1400 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - p = _tmp128_; -#line 1403 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp129_ = p; -#line 1403 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - if (((gint) _tmp129_) >= 192) { -#line 1404 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - sample = (guchar) 3; -#line 12067 "scanner.c" - } else { - guchar _tmp130_ = '\0'; -#line 1405 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp130_ = p; -#line 1405 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - if (((gint) _tmp130_) >= 128) { -#line 1406 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - sample = (guchar) 2; -#line 12076 "scanner.c" - } else { - guchar _tmp131_ = '\0'; -#line 1407 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp131_ = p; -#line 1407 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - if (((gint) _tmp131_) >= 64) { -#line 1408 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - sample = (guchar) 1; -#line 12085 "scanner.c" - } else { -#line 1410 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - sample = (guchar) 0; -#line 12089 "scanner.c" - } - } - } -#line 1412 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp132_ = block; -#line 1412 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp133_ = sample; -#line 1412 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp134_ = block_shift; -#line 1412 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - block = _tmp132_ | (_tmp133_ << _tmp134_); -#line 1413 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp135_ = block_shift; -#line 1413 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - if (_tmp135_ == 0) { -#line 12105 "scanner.c" - ScanLine* _tmp136_ = NULL; - guchar* _tmp137_ = NULL; - gint _tmp137__length1 = 0; - gint _tmp138_ = 0; - guchar _tmp139_ = '\0'; - guchar _tmp140_ = '\0'; - gint _tmp141_ = 0; -#line 1415 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp136_ = line; -#line 1415 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp137_ = _tmp136_->data; -#line 1415 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp137__length1 = _tmp136_->data_length1; -#line 1415 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp138_ = write_offset; -#line 1415 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp139_ = block; -#line 1415 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp137_[_tmp138_] = _tmp139_; -#line 1415 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp140_ = _tmp137_[_tmp138_]; -#line 1416 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp141_ = write_offset; -#line 1416 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - write_offset = _tmp141_ + 1; -#line 1417 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - block = (guchar) 0; -#line 1418 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - block_shift = 6; -#line 12135 "scanner.c" - } else { - gint _tmp142_ = 0; -#line 1421 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp142_ = block_shift; -#line 1421 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - block_shift = _tmp142_ - 2; -#line 12142 "scanner.c" - } - } - } - } -#line 1425 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp143_ = block_shift; -#line 1425 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - if (_tmp143_ != 6) { -#line 12151 "scanner.c" - ScanLine* _tmp144_ = NULL; - guchar* _tmp145_ = NULL; - gint _tmp145__length1 = 0; - gint _tmp146_ = 0; - guchar _tmp147_ = '\0'; - guchar _tmp148_ = '\0'; - gint _tmp149_ = 0; -#line 1427 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp144_ = line; -#line 1427 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp145_ = _tmp144_->data; -#line 1427 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp145__length1 = _tmp144_->data_length1; -#line 1427 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp146_ = write_offset; -#line 1427 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp147_ = block; -#line 1427 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp145_[_tmp146_] = _tmp147_; -#line 1427 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp148_ = _tmp145_[_tmp146_]; -#line 1428 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp149_ = write_offset; -#line 1428 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - write_offset = _tmp149_ + 1; -#line 1429 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - block = (guchar) 0; -#line 1430 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - block_shift = 6; -#line 12181 "scanner.c" - } - } - } - } -#line 1434 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp150_ = line; -#line 1434 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp151_ = line; -#line 1434 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp152_ = _tmp151_->width; -#line 1434 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp150_->data_length = ((_tmp152_ * 2) + 7) / 8; -#line 12194 "scanner.c" - } -#line 1437 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp153_ = job; -#line 1437 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp154_ = _tmp153_->id; -#line 1437 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp155_ = line; -#line 1437 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp156_ = notify_got_line_new (_tmp154_, _tmp155_); -#line 1437 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp157_ = _tmp156_; -#line 1437 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - scanner_notify (self, (Notify*) _tmp157_); -#line 1437 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _notify_unref0 (_tmp157_); -#line 1343 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _scan_line_unref0 (line); -#line 12212 "scanner.c" - } -#line 1304 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _scan_job_unref0 (job); -#line 12216 "scanner.c" -} - - -static void _scanner_authorization_cb_sane_authcallback (const gchar* resource, gchar* username, gchar* password) { -#line 1446 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - scanner_authorization_cb (resource, username, -1, password, -1); -#line 12223 "scanner.c" -} - - -static void* scanner_scan_thread (Scanner* self) { - void* result = NULL; - SANE_Int version_code = {0}; - SANE_Status status = 0; - SANE_Int _tmp0_ = {0}; - SANE_Status _tmp1_ = 0; - SANE_Status _tmp2_ = 0; - gchar* _tmp3_ = NULL; - gchar* _tmp4_ = NULL; - SANE_Status _tmp5_ = 0; - SANE_Int _tmp8_ = {0}; - gint _tmp9_ = 0; - SANE_Int _tmp10_ = {0}; - gint _tmp11_ = 0; - SANE_Int _tmp12_ = {0}; - gint _tmp13_ = 0; -#line 1441 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - g_return_val_if_fail (self != NULL, NULL); -#line 1443 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - self->priv->state = SCAN_STATE_IDLE; -#line 1446 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp1_ = sane_init (&_tmp0_, _scanner_authorization_cb_sane_authcallback); -#line 1446 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - version_code = _tmp0_; -#line 1446 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - status = _tmp1_; -#line 1447 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp2_ = status; -#line 1447 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp3_ = sane_status_to_string (_tmp2_); -#line 1447 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp4_ = _tmp3_; -#line 1447 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - g_debug ("scanner.vala:1447: sane_init () -> %s", _tmp4_); -#line 1447 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _g_free0 (_tmp4_); -#line 1448 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp5_ = status; -#line 1448 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - if (_tmp5_ != SANE_STATUS_GOOD) { -#line 12267 "scanner.c" - SANE_Status _tmp6_ = 0; - const gchar* _tmp7_ = NULL; -#line 1450 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp6_ = status; -#line 1450 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp7_ = sane_strstatus (_tmp6_); -#line 1450 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - g_warning ("scanner.vala:1450: Unable to initialize SANE backend: %s", _tmp7_); -#line 1451 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - result = NULL; -#line 1451 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - return result; -#line 12280 "scanner.c" - } -#line 1453 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp8_ = version_code; -#line 1453 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp9_ = SANE_VERSION_MAJOR (_tmp8_); -#line 1453 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp10_ = version_code; -#line 1453 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp11_ = SANE_VERSION_MINOR (_tmp10_); -#line 1453 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp12_ = version_code; -#line 1453 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp13_ = SANE_VERSION_BUILD (_tmp12_); -#line 1453 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - g_debug ("scanner.vala:1453: SANE version %d.%d.%d", _tmp9_, _tmp11_, _tmp13_); -#line 1459 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - scanner_redetect (self); -#line 1461 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - while (TRUE) { -#line 12300 "scanner.c" - gboolean _tmp14_ = FALSE; - ScanState _tmp15_ = 0; -#line 1461 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp14_ = scanner_handle_requests (self); -#line 1461 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - if (!_tmp14_) { -#line 1461 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - break; -#line 12309 "scanner.c" - } -#line 1463 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp15_ = self->priv->state; -#line 1463 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - switch (_tmp15_) { -#line 1463 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - case SCAN_STATE_IDLE: -#line 12317 "scanner.c" - { - GList* _tmp16_ = NULL; -#line 1466 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp16_ = self->priv->job_queue; -#line 1466 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - if (_tmp16_ != NULL) { -#line 1468 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - scanner_set_scanning (self, TRUE); -#line 1469 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - self->priv->state = SCAN_STATE_OPEN; -#line 12328 "scanner.c" - } -#line 1471 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - break; -#line 12332 "scanner.c" - } -#line 1463 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - case SCAN_STATE_REDETECT: -#line 12336 "scanner.c" - { -#line 1473 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - scanner_do_redetect (self); -#line 1474 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - break; -#line 12342 "scanner.c" - } -#line 1463 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - case SCAN_STATE_OPEN: -#line 12346 "scanner.c" - { -#line 1476 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - scanner_do_open (self); -#line 1477 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - break; -#line 12352 "scanner.c" - } -#line 1463 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - case SCAN_STATE_GET_OPTION: -#line 12356 "scanner.c" - { -#line 1479 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - scanner_do_get_option (self); -#line 1480 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - break; -#line 12362 "scanner.c" - } -#line 1463 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - case SCAN_STATE_START: -#line 12366 "scanner.c" - { -#line 1482 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - scanner_do_start (self); -#line 1483 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - break; -#line 12372 "scanner.c" - } -#line 1463 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - case SCAN_STATE_GET_PARAMETERS: -#line 12376 "scanner.c" - { -#line 1485 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - scanner_do_get_parameters (self); -#line 1486 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - break; -#line 12382 "scanner.c" - } -#line 1463 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - case SCAN_STATE_READ: -#line 12386 "scanner.c" - { -#line 1488 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - scanner_do_read (self); -#line 1489 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - break; -#line 12392 "scanner.c" - } - default: -#line 1463 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - break; -#line 12397 "scanner.c" - } - } -#line 1493 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - result = NULL; -#line 1493 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - return result; -#line 12404 "scanner.c" -} - - -static gpointer _scanner_scan_thread_gthread_func (gpointer self) { - gpointer result; - result = scanner_scan_thread ((Scanner*) self); -#line 1500 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - scanner_unref (self); -#line 1500 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - return result; -#line 12415 "scanner.c" -} - - -void scanner_start (Scanner* self) { - GError * _inner_error_ = NULL; -#line 1496 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - g_return_if_fail (self != NULL); -#line 12423 "scanner.c" - { - GThread* _tmp0_ = NULL; - GThread* _tmp1_ = NULL; - GThread* _tmp2_ = NULL; -#line 1500 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp1_ = g_thread_try_new ("scan-thread", _scanner_scan_thread_gthread_func, scanner_ref (self), &_inner_error_); -#line 1500 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp0_ = _tmp1_; -#line 1500 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - if (G_UNLIKELY (_inner_error_ != NULL)) { -#line 12434 "scanner.c" - goto __catch16_g_error; - } -#line 1500 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp2_ = _tmp0_; -#line 1500 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp0_ = NULL; -#line 1500 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _g_thread_unref0 (self->priv->thread); -#line 1500 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - self->priv->thread = _tmp2_; -#line 1498 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _g_thread_unref0 (_tmp0_); -#line 12447 "scanner.c" - } - goto __finally16; - __catch16_g_error: - { - GError* e = NULL; - GError* _tmp3_ = NULL; - const gchar* _tmp4_ = NULL; -#line 1498 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - e = _inner_error_; -#line 1498 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _inner_error_ = NULL; -#line 1504 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp3_ = e; -#line 1504 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp4_ = _tmp3_->message; -#line 1504 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - g_critical ("scanner.vala:1504: Unable to create thread: %s", _tmp4_); -#line 1498 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _g_error_free0 (e); -#line 12467 "scanner.c" - } - __finally16: -#line 1498 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - if (G_UNLIKELY (_inner_error_ != NULL)) { -#line 1498 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - g_critical ("file %s: line %d: uncaught error: %s (%s, %d)", __FILE__, __LINE__, _inner_error_->message, g_quark_to_string (_inner_error_->domain), _inner_error_->code); -#line 1498 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - g_clear_error (&_inner_error_); -#line 1498 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - return; -#line 12478 "scanner.c" - } -} - - -void scanner_redetect (Scanner* self) { - gboolean _tmp0_ = FALSE; - GAsyncQueue* _tmp1_ = NULL; - RequestRedetect* _tmp2_ = NULL; -#line 1508 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - g_return_if_fail (self != NULL); -#line 1510 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp0_ = self->priv->need_redetect; -#line 1510 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - if (_tmp0_) { -#line 1511 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - return; -#line 12495 "scanner.c" - } -#line 1512 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - self->priv->need_redetect = TRUE; -#line 1514 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - g_debug ("scanner.vala:1514: Requesting redetection of scan devices"); -#line 1516 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp1_ = self->priv->request_queue; -#line 1516 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp2_ = request_redetect_new (); -#line 1516 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - g_async_queue_push (_tmp1_, (Request*) _tmp2_); -#line 12507 "scanner.c" -} - - -gboolean scanner_is_scanning (Scanner* self) { - gboolean result = FALSE; - gboolean _tmp0_ = FALSE; -#line 1519 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - g_return_val_if_fail (self != NULL, FALSE); -#line 1521 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp0_ = self->priv->scanning; -#line 1521 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - result = _tmp0_; -#line 1521 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - return result; -#line 12522 "scanner.c" -} - - -static gchar* scanner_get_scan_mode_string (Scanner* self, ScanMode mode) { - gchar* result = NULL; - ScanMode _tmp0_ = 0; -#line 1524 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - g_return_val_if_fail (self != NULL, NULL); -#line 1526 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp0_ = mode; -#line 1526 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - switch (_tmp0_) { -#line 1526 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - case SCAN_MODE_DEFAULT: -#line 12537 "scanner.c" - { - gchar* _tmp1_ = NULL; -#line 1529 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp1_ = g_strdup ("ScanMode.DEFAULT"); -#line 1529 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - result = _tmp1_; -#line 1529 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - return result; -#line 12546 "scanner.c" - } -#line 1526 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - case SCAN_MODE_COLOR: -#line 12550 "scanner.c" - { - gchar* _tmp2_ = NULL; -#line 1531 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp2_ = g_strdup ("ScanMode.COLOR"); -#line 1531 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - result = _tmp2_; -#line 1531 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - return result; -#line 12559 "scanner.c" - } -#line 1526 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - case SCAN_MODE_GRAY: -#line 12563 "scanner.c" - { - gchar* _tmp3_ = NULL; -#line 1533 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp3_ = g_strdup ("ScanMode.GRAY"); -#line 1533 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - result = _tmp3_; -#line 1533 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - return result; -#line 12572 "scanner.c" - } -#line 1526 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - case SCAN_MODE_LINEART: -#line 12576 "scanner.c" - { - gchar* _tmp4_ = NULL; -#line 1535 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp4_ = g_strdup ("ScanMode.LINEART"); -#line 1535 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - result = _tmp4_; -#line 1535 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - return result; -#line 12585 "scanner.c" - } - default: - { - ScanMode _tmp5_ = 0; - gchar* _tmp6_ = NULL; -#line 1537 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp5_ = mode; -#line 1537 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp6_ = g_strdup_printf ("%d", (gint) _tmp5_); -#line 1537 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - result = _tmp6_; -#line 1537 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - return result; -#line 12599 "scanner.c" - } - } -} - - -static gchar* scanner_get_scan_type_string (Scanner* self, ScanType type) { - gchar* result = NULL; - ScanType _tmp0_ = 0; -#line 1541 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - g_return_val_if_fail (self != NULL, NULL); -#line 1543 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp0_ = type; -#line 1543 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - switch (_tmp0_) { -#line 1543 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - case SCAN_TYPE_SINGLE: -#line 12616 "scanner.c" - { - gchar* _tmp1_ = NULL; -#line 1546 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp1_ = g_strdup ("ScanType.SINGLE"); -#line 1546 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - result = _tmp1_; -#line 1546 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - return result; -#line 12625 "scanner.c" - } -#line 1543 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - case SCAN_TYPE_ADF_FRONT: -#line 12629 "scanner.c" - { - gchar* _tmp2_ = NULL; -#line 1548 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp2_ = g_strdup ("ScanType.ADF_FRONT"); -#line 1548 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - result = _tmp2_; -#line 1548 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - return result; -#line 12638 "scanner.c" - } -#line 1543 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - case SCAN_TYPE_ADF_BACK: -#line 12642 "scanner.c" - { - gchar* _tmp3_ = NULL; -#line 1550 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp3_ = g_strdup ("ScanType.ADF_BACK"); -#line 1550 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - result = _tmp3_; -#line 1550 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - return result; -#line 12651 "scanner.c" - } -#line 1543 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - case SCAN_TYPE_ADF_BOTH: -#line 12655 "scanner.c" - { - gchar* _tmp4_ = NULL; -#line 1552 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp4_ = g_strdup ("ScanType.ADF_BOTH"); -#line 1552 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - result = _tmp4_; -#line 1552 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - return result; -#line 12664 "scanner.c" - } - default: - { - ScanType _tmp5_ = 0; - gchar* _tmp6_ = NULL; -#line 1554 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp5_ = type; -#line 1554 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp6_ = g_strdup_printf ("%d", (gint) _tmp5_); -#line 1554 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - result = _tmp6_; -#line 1554 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - return result; -#line 12678 "scanner.c" - } - } -} - - -void scanner_scan (Scanner* self, const gchar* device, ScanOptions* options) { - const gchar* _tmp0_ = NULL; - const gchar* _tmp1_ = NULL; - ScanOptions* _tmp3_ = NULL; - gint _tmp4_ = 0; - ScanOptions* _tmp5_ = NULL; - ScanMode _tmp6_ = 0; - gchar* _tmp7_ = NULL; - gchar* _tmp8_ = NULL; - ScanOptions* _tmp9_ = NULL; - gint _tmp10_ = 0; - ScanOptions* _tmp11_ = NULL; - ScanType _tmp12_ = 0; - gchar* _tmp13_ = NULL; - gchar* _tmp14_ = NULL; - ScanOptions* _tmp15_ = NULL; - gint _tmp16_ = 0; - ScanOptions* _tmp17_ = NULL; - gint _tmp18_ = 0; - ScanOptions* _tmp19_ = NULL; - gint _tmp20_ = 0; - ScanOptions* _tmp21_ = NULL; - gint _tmp22_ = 0; - RequestStartScan* request = NULL; - RequestStartScan* _tmp23_ = NULL; - ScanJob* _tmp24_ = NULL; - ScanJob* _tmp25_ = NULL; - gint _tmp26_ = 0; - ScanJob* _tmp27_ = NULL; - const gchar* _tmp28_ = NULL; - gchar* _tmp29_ = NULL; - ScanJob* _tmp30_ = NULL; - ScanOptions* _tmp31_ = NULL; - gint _tmp32_ = 0; - ScanJob* _tmp33_ = NULL; - ScanOptions* _tmp34_ = NULL; - ScanMode _tmp35_ = 0; - ScanJob* _tmp36_ = NULL; - ScanOptions* _tmp37_ = NULL; - gint _tmp38_ = 0; - ScanJob* _tmp39_ = NULL; - ScanOptions* _tmp40_ = NULL; - ScanType _tmp41_ = 0; - ScanJob* _tmp42_ = NULL; - ScanOptions* _tmp43_ = NULL; - gint _tmp44_ = 0; - ScanJob* _tmp45_ = NULL; - ScanOptions* _tmp46_ = NULL; - gint _tmp47_ = 0; - ScanJob* _tmp48_ = NULL; - ScanOptions* _tmp49_ = NULL; - gint _tmp50_ = 0; - ScanJob* _tmp51_ = NULL; - ScanOptions* _tmp52_ = NULL; - gint _tmp53_ = 0; - GAsyncQueue* _tmp54_ = NULL; - Request* _tmp55_ = NULL; -#line 1558 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - g_return_if_fail (self != NULL); -#line 1558 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - g_return_if_fail (options != NULL); -#line 1561 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp1_ = device; -#line 1561 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - if (_tmp1_ != NULL) { -#line 12749 "scanner.c" - const gchar* _tmp2_ = NULL; -#line 1561 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp2_ = device; -#line 1561 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp0_ = _tmp2_; -#line 12755 "scanner.c" - } else { -#line 1561 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp0_ = "(null)"; -#line 12759 "scanner.c" - } -#line 1560 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp3_ = options; -#line 1560 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp4_ = _tmp3_->dpi; -#line 1560 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp5_ = options; -#line 1560 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp6_ = _tmp5_->scan_mode; -#line 1560 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp7_ = scanner_get_scan_mode_string (self, _tmp6_); -#line 1560 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp8_ = _tmp7_; -#line 1560 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp9_ = options; -#line 1560 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp10_ = _tmp9_->depth; -#line 1560 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp11_ = options; -#line 1560 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp12_ = _tmp11_->type; -#line 1560 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp13_ = scanner_get_scan_type_string (self, _tmp12_); -#line 1560 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp14_ = _tmp13_; -#line 1560 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp15_ = options; -#line 1560 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp16_ = _tmp15_->paper_width; -#line 1560 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp17_ = options; -#line 1560 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp18_ = _tmp17_->paper_height; -#line 1560 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp19_ = options; -#line 1560 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp20_ = _tmp19_->brightness; -#line 1560 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp21_ = options; -#line 1560 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp22_ = _tmp21_->contrast; -#line 1560 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - g_debug ("scanner.vala:1560: Scanner.scan (\"%s\", dpi=%d, scan_mode=%s, depth=%" \ -"d, type=%s, paper_width=%d, paper_height=%d, brightness=%d, contrast=%" \ -"d)", _tmp0_, _tmp4_, _tmp8_, _tmp10_, _tmp14_, _tmp16_, _tmp18_, _tmp20_, _tmp22_); -#line 1560 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _g_free0 (_tmp14_); -#line 1560 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _g_free0 (_tmp8_); -#line 1564 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp23_ = request_start_scan_new (); -#line 1564 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - request = _tmp23_; -#line 1565 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp24_ = scan_job_new (); -#line 1565 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _scan_job_unref0 (request->job); -#line 1565 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - request->job = _tmp24_; -#line 1566 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp25_ = request->job; -#line 1566 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp26_ = self->job_id; -#line 1566 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - self->job_id = _tmp26_ + 1; -#line 1566 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp25_->id = _tmp26_; -#line 1567 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp27_ = request->job; -#line 1567 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp28_ = device; -#line 1567 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp29_ = g_strdup (_tmp28_); -#line 1567 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _g_free0 (_tmp27_->device); -#line 1567 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp27_->device = _tmp29_; -#line 1568 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp30_ = request->job; -#line 1568 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp31_ = options; -#line 1568 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp32_ = _tmp31_->dpi; -#line 1568 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp30_->dpi = (gdouble) _tmp32_; -#line 1569 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp33_ = request->job; -#line 1569 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp34_ = options; -#line 1569 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp35_ = _tmp34_->scan_mode; -#line 1569 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp33_->scan_mode = _tmp35_; -#line 1570 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp36_ = request->job; -#line 1570 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp37_ = options; -#line 1570 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp38_ = _tmp37_->depth; -#line 1570 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp36_->depth = _tmp38_; -#line 1571 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp39_ = request->job; -#line 1571 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp40_ = options; -#line 1571 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp41_ = _tmp40_->type; -#line 1571 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp39_->type = _tmp41_; -#line 1572 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp42_ = request->job; -#line 1572 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp43_ = options; -#line 1572 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp44_ = _tmp43_->paper_width; -#line 1572 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp42_->page_width = _tmp44_; -#line 1573 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp45_ = request->job; -#line 1573 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp46_ = options; -#line 1573 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp47_ = _tmp46_->paper_height; -#line 1573 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp45_->page_height = _tmp47_; -#line 1574 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp48_ = request->job; -#line 1574 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp49_ = options; -#line 1574 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp50_ = _tmp49_->brightness; -#line 1574 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp48_->brightness = _tmp50_; -#line 1575 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp51_ = request->job; -#line 1575 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp52_ = options; -#line 1575 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp53_ = _tmp52_->contrast; -#line 1575 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp51_->contrast = _tmp53_; -#line 1576 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp54_ = self->priv->request_queue; -#line 1576 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp55_ = _request_ref0 ((Request*) request); -#line 1576 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - g_async_queue_push (_tmp54_, _tmp55_); -#line 1558 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _request_unref0 (request); -#line 12907 "scanner.c" -} - - -void scanner_cancel (Scanner* self) { - gint _tmp0_ = 0; - GAsyncQueue* _tmp1_ = NULL; - RequestCancel* _tmp2_ = NULL; -#line 1579 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - g_return_if_fail (self != NULL); -#line 1581 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp0_ = self->job_id; -#line 1581 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - self->first_job_id = _tmp0_; -#line 1582 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp1_ = self->priv->request_queue; -#line 1582 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp2_ = request_cancel_new (); -#line 1582 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - g_async_queue_push (_tmp1_, (Request*) _tmp2_); -#line 12927 "scanner.c" -} - - -static gpointer _g_thread_ref0 (gpointer self) { -#line 1593 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - return self ? g_thread_ref (self) : NULL; -#line 12934 "scanner.c" -} - - -void scanner_free (Scanner* self) { - GAsyncQueue* _tmp0_ = NULL; - RequestQuit* _tmp1_ = NULL; - GThread* _tmp2_ = NULL; -#line 1585 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - g_return_if_fail (self != NULL); -#line 1587 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - g_debug ("scanner.vala:1587: Stopping scan thread"); -#line 1589 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp0_ = self->priv->request_queue; -#line 1589 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp1_ = request_quit_new (); -#line 1589 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - g_async_queue_push (_tmp0_, (Request*) _tmp1_); -#line 1591 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp2_ = self->priv->thread; -#line 1591 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - if (_tmp2_ != NULL) { -#line 12956 "scanner.c" - GThread* _tmp3_ = NULL; - GThread* _tmp4_ = NULL; -#line 1593 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp3_ = self->priv->thread; -#line 1593 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _tmp4_ = _g_thread_ref0 (_tmp3_); -#line 1593 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - g_thread_join (_tmp4_); -#line 1594 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _g_thread_unref0 (self->priv->thread); -#line 1594 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - self->priv->thread = NULL; -#line 12969 "scanner.c" - } -#line 1597 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - sane_exit (); -#line 1598 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - g_debug ("scanner.vala:1598: sane_exit ()"); -#line 12975 "scanner.c" -} - - -static void g_cclosure_user_marshal_VOID__SCAN_PAGE_INFO (GClosure * closure, GValue * return_value, guint n_param_values, const GValue * param_values, gpointer invocation_hint, gpointer marshal_data) { - typedef void (*GMarshalFunc_VOID__SCAN_PAGE_INFO) (gpointer data1, gpointer arg_1, gpointer data2); - register GMarshalFunc_VOID__SCAN_PAGE_INFO callback; - register GCClosure * cc; - register gpointer data1; - register gpointer data2; - cc = (GCClosure *) closure; -#line 208 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - g_return_if_fail (n_param_values == 2); -#line 208 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - if (G_CCLOSURE_SWAP_DATA (closure)) { -#line 208 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - data1 = closure->data; -#line 208 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - data2 = param_values->data[0].v_pointer; -#line 12994 "scanner.c" - } else { -#line 208 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - data1 = param_values->data[0].v_pointer; -#line 208 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - data2 = closure->data; -#line 13000 "scanner.c" - } -#line 208 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - callback = (GMarshalFunc_VOID__SCAN_PAGE_INFO) (marshal_data ? marshal_data : cc->callback); -#line 208 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - callback (data1, value_get_scan_page_info (param_values + 1), data2); -#line 13006 "scanner.c" -} - - -static void g_cclosure_user_marshal_VOID__SCAN_LINE (GClosure * closure, GValue * return_value, guint n_param_values, const GValue * param_values, gpointer invocation_hint, gpointer marshal_data) { - typedef void (*GMarshalFunc_VOID__SCAN_LINE) (gpointer data1, gpointer arg_1, gpointer data2); - register GMarshalFunc_VOID__SCAN_LINE callback; - register GCClosure * cc; - register gpointer data1; - register gpointer data2; - cc = (GCClosure *) closure; -#line 208 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - g_return_if_fail (n_param_values == 2); -#line 208 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - if (G_CCLOSURE_SWAP_DATA (closure)) { -#line 208 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - data1 = closure->data; -#line 208 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - data2 = param_values->data[0].v_pointer; -#line 13025 "scanner.c" - } else { -#line 208 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - data1 = param_values->data[0].v_pointer; -#line 208 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - data2 = closure->data; -#line 13031 "scanner.c" - } -#line 208 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - callback = (GMarshalFunc_VOID__SCAN_LINE) (marshal_data ? marshal_data : cc->callback); -#line 208 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - callback (data1, value_get_scan_line (param_values + 1), data2); -#line 13037 "scanner.c" -} - - -static void g_cclosure_user_marshal_VOID__INT_STRING (GClosure * closure, GValue * return_value, guint n_param_values, const GValue * param_values, gpointer invocation_hint, gpointer marshal_data) { - typedef void (*GMarshalFunc_VOID__INT_STRING) (gpointer data1, gint arg_1, const char* arg_2, gpointer data2); - register GMarshalFunc_VOID__INT_STRING callback; - register GCClosure * cc; - register gpointer data1; - register gpointer data2; - cc = (GCClosure *) closure; -#line 208 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - g_return_if_fail (n_param_values == 3); -#line 208 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - if (G_CCLOSURE_SWAP_DATA (closure)) { -#line 208 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - data1 = closure->data; -#line 208 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - data2 = param_values->data[0].v_pointer; -#line 13056 "scanner.c" - } else { -#line 208 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - data1 = param_values->data[0].v_pointer; -#line 208 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - data2 = closure->data; -#line 13062 "scanner.c" - } -#line 208 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - callback = (GMarshalFunc_VOID__INT_STRING) (marshal_data ? marshal_data : cc->callback); -#line 208 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - callback (data1, g_value_get_int (param_values + 1), g_value_get_string (param_values + 2), data2); -#line 13068 "scanner.c" -} - - -static void value_scanner_init (GValue* value) { -#line 208 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - value->data[0].v_pointer = NULL; -#line 13075 "scanner.c" -} - - -static void value_scanner_free_value (GValue* value) { -#line 208 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - if (value->data[0].v_pointer) { -#line 208 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - scanner_unref (value->data[0].v_pointer); -#line 13084 "scanner.c" - } -} - - -static void value_scanner_copy_value (const GValue* src_value, GValue* dest_value) { -#line 208 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - if (src_value->data[0].v_pointer) { -#line 208 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - dest_value->data[0].v_pointer = scanner_ref (src_value->data[0].v_pointer); -#line 13094 "scanner.c" - } else { -#line 208 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - dest_value->data[0].v_pointer = NULL; -#line 13098 "scanner.c" - } -} - - -static gpointer value_scanner_peek_pointer (const GValue* value) { -#line 208 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - return value->data[0].v_pointer; -#line 13106 "scanner.c" -} - - -static gchar* value_scanner_collect_value (GValue* value, guint n_collect_values, GTypeCValue* collect_values, guint collect_flags) { -#line 208 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - if (collect_values[0].v_pointer) { -#line 13113 "scanner.c" - Scanner* object; - object = collect_values[0].v_pointer; -#line 208 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - if (object->parent_instance.g_class == NULL) { -#line 208 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - return g_strconcat ("invalid unclassed object pointer for value type `", G_VALUE_TYPE_NAME (value), "'", NULL); -#line 13120 "scanner.c" - } else if (!g_value_type_compatible (G_TYPE_FROM_INSTANCE (object), G_VALUE_TYPE (value))) { -#line 208 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - return g_strconcat ("invalid object type `", g_type_name (G_TYPE_FROM_INSTANCE (object)), "' for value type `", G_VALUE_TYPE_NAME (value), "'", NULL); -#line 13124 "scanner.c" - } -#line 208 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - value->data[0].v_pointer = scanner_ref (object); -#line 13128 "scanner.c" - } else { -#line 208 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - value->data[0].v_pointer = NULL; -#line 13132 "scanner.c" - } -#line 208 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - return NULL; -#line 13136 "scanner.c" -} - - -static gchar* value_scanner_lcopy_value (const GValue* value, guint n_collect_values, GTypeCValue* collect_values, guint collect_flags) { - Scanner** object_p; - object_p = collect_values[0].v_pointer; -#line 208 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - if (!object_p) { -#line 208 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - return g_strdup_printf ("value location for `%s' passed as NULL", G_VALUE_TYPE_NAME (value)); -#line 13147 "scanner.c" - } -#line 208 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - if (!value->data[0].v_pointer) { -#line 208 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - *object_p = NULL; -#line 13153 "scanner.c" - } else if (collect_flags & G_VALUE_NOCOPY_CONTENTS) { -#line 208 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - *object_p = value->data[0].v_pointer; -#line 13157 "scanner.c" - } else { -#line 208 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - *object_p = scanner_ref (value->data[0].v_pointer); -#line 13161 "scanner.c" - } -#line 208 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - return NULL; -#line 13165 "scanner.c" -} - - -GParamSpec* param_spec_scanner (const gchar* name, const gchar* nick, const gchar* blurb, GType object_type, GParamFlags flags) { - ParamSpecScanner* spec; -#line 208 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - g_return_val_if_fail (g_type_is_a (object_type, TYPE_SCANNER), NULL); -#line 208 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - spec = g_param_spec_internal (G_TYPE_PARAM_OBJECT, name, nick, blurb, flags); -#line 208 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - G_PARAM_SPEC (spec)->value_type = object_type; -#line 208 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - return G_PARAM_SPEC (spec); -#line 13179 "scanner.c" -} - - -gpointer value_get_scanner (const GValue* value) { -#line 208 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - g_return_val_if_fail (G_TYPE_CHECK_VALUE_TYPE (value, TYPE_SCANNER), NULL); -#line 208 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - return value->data[0].v_pointer; -#line 13188 "scanner.c" -} - - -void value_set_scanner (GValue* value, gpointer v_object) { - Scanner* old; -#line 208 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - g_return_if_fail (G_TYPE_CHECK_VALUE_TYPE (value, TYPE_SCANNER)); -#line 208 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - old = value->data[0].v_pointer; -#line 208 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - if (v_object) { -#line 208 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - g_return_if_fail (G_TYPE_CHECK_INSTANCE_TYPE (v_object, TYPE_SCANNER)); -#line 208 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - g_return_if_fail (g_value_type_compatible (G_TYPE_FROM_INSTANCE (v_object), G_VALUE_TYPE (value))); -#line 208 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - value->data[0].v_pointer = v_object; -#line 208 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - scanner_ref (value->data[0].v_pointer); -#line 13208 "scanner.c" - } else { -#line 208 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - value->data[0].v_pointer = NULL; -#line 13212 "scanner.c" - } -#line 208 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - if (old) { -#line 208 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - scanner_unref (old); -#line 13218 "scanner.c" - } -} - - -void value_take_scanner (GValue* value, gpointer v_object) { - Scanner* old; -#line 208 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - g_return_if_fail (G_TYPE_CHECK_VALUE_TYPE (value, TYPE_SCANNER)); -#line 208 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - old = value->data[0].v_pointer; -#line 208 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - if (v_object) { -#line 208 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - g_return_if_fail (G_TYPE_CHECK_INSTANCE_TYPE (v_object, TYPE_SCANNER)); -#line 208 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - g_return_if_fail (g_value_type_compatible (G_TYPE_FROM_INSTANCE (v_object), G_VALUE_TYPE (value))); -#line 208 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - value->data[0].v_pointer = v_object; -#line 13237 "scanner.c" - } else { -#line 208 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - value->data[0].v_pointer = NULL; -#line 13241 "scanner.c" - } -#line 208 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - if (old) { -#line 208 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - scanner_unref (old); -#line 13247 "scanner.c" - } -} - - -static void scanner_class_init (ScannerClass * klass) { -#line 208 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - scanner_parent_class = g_type_class_peek_parent (klass); -#line 208 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - ((ScannerClass *) klass)->finalize = scanner_finalize; -#line 208 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - g_type_class_add_private (klass, sizeof (ScannerPrivate)); -#line 208 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - g_signal_new ("update_devices", TYPE_SCANNER, G_SIGNAL_RUN_LAST, 0, NULL, NULL, g_cclosure_marshal_VOID__POINTER, G_TYPE_NONE, 1, G_TYPE_POINTER); -#line 208 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - g_signal_new ("request_authorization", TYPE_SCANNER, G_SIGNAL_RUN_LAST, 0, NULL, NULL, g_cclosure_marshal_VOID__STRING, G_TYPE_NONE, 1, G_TYPE_STRING); -#line 208 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - g_signal_new ("expect_page", TYPE_SCANNER, G_SIGNAL_RUN_LAST, 0, NULL, NULL, g_cclosure_marshal_VOID__VOID, G_TYPE_NONE, 0); -#line 208 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - g_signal_new ("got_page_info", TYPE_SCANNER, G_SIGNAL_RUN_LAST, 0, NULL, NULL, g_cclosure_user_marshal_VOID__SCAN_PAGE_INFO, G_TYPE_NONE, 1, TYPE_SCAN_PAGE_INFO); -#line 208 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - g_signal_new ("got_line", TYPE_SCANNER, G_SIGNAL_RUN_LAST, 0, NULL, NULL, g_cclosure_user_marshal_VOID__SCAN_LINE, G_TYPE_NONE, 1, TYPE_SCAN_LINE); -#line 208 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - g_signal_new ("scan_failed", TYPE_SCANNER, G_SIGNAL_RUN_LAST, 0, NULL, NULL, g_cclosure_user_marshal_VOID__INT_STRING, G_TYPE_NONE, 2, G_TYPE_INT, G_TYPE_STRING); -#line 208 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - g_signal_new ("page_done", TYPE_SCANNER, G_SIGNAL_RUN_LAST, 0, NULL, NULL, g_cclosure_marshal_VOID__VOID, G_TYPE_NONE, 0); -#line 208 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - g_signal_new ("document_done", TYPE_SCANNER, G_SIGNAL_RUN_LAST, 0, NULL, NULL, g_cclosure_marshal_VOID__VOID, G_TYPE_NONE, 0); -#line 208 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - g_signal_new ("scanning_changed", TYPE_SCANNER, G_SIGNAL_RUN_LAST, 0, NULL, NULL, g_cclosure_marshal_VOID__VOID, G_TYPE_NONE, 0); -#line 13277 "scanner.c" -} - - -static void scanner_instance_init (Scanner * self) { -#line 208 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - self->priv = SCANNER_GET_PRIVATE (self); -#line 208 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - self->ref_count = 1; -#line 13286 "scanner.c" -} - - -static void scanner_finalize (Scanner* obj) { - Scanner * self; -#line 208 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - self = G_TYPE_CHECK_INSTANCE_CAST (obj, TYPE_SCANNER, Scanner); -#line 208 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - g_signal_handlers_destroy (self); -#line 214 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _g_thread_unref0 (self->priv->thread); -#line 217 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _g_async_queue_unref0 (self->priv->request_queue); -#line 220 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _g_async_queue_unref0 (self->priv->notify_queue); -#line 223 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _g_async_queue_unref0 (self->priv->authorize_queue); -#line 229 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _g_free0 (self->priv->default_device); -#line 234 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - __g_list_free__scan_job_unref0_0 (self->priv->job_queue); -#line 239 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _g_free0 (self->priv->current_device); -#line 247 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - _g_hash_table_unref0 (self->priv->options); -#line 250 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - self->priv->buffer = (g_free (self->priv->buffer), NULL); -#line 13314 "scanner.c" -} - - -GType scanner_get_type (void) { - static volatile gsize scanner_type_id__volatile = 0; - if (g_once_init_enter (&scanner_type_id__volatile)) { - static const GTypeValueTable g_define_type_value_table = { value_scanner_init, value_scanner_free_value, value_scanner_copy_value, value_scanner_peek_pointer, "p", value_scanner_collect_value, "p", value_scanner_lcopy_value }; - static const GTypeInfo g_define_type_info = { sizeof (ScannerClass), (GBaseInitFunc) NULL, (GBaseFinalizeFunc) NULL, (GClassInitFunc) scanner_class_init, (GClassFinalizeFunc) NULL, NULL, sizeof (Scanner), 0, (GInstanceInitFunc) scanner_instance_init, &g_define_type_value_table }; - static const GTypeFundamentalInfo g_define_type_fundamental_info = { (G_TYPE_FLAG_CLASSED | G_TYPE_FLAG_INSTANTIATABLE | G_TYPE_FLAG_DERIVABLE | G_TYPE_FLAG_DEEP_DERIVABLE) }; - GType scanner_type_id; - scanner_type_id = g_type_register_fundamental (g_type_fundamental_next (), "Scanner", &g_define_type_info, &g_define_type_fundamental_info, 0); - g_once_init_leave (&scanner_type_id__volatile, scanner_type_id); - } - return scanner_type_id__volatile; -} - - -gpointer scanner_ref (gpointer instance) { - Scanner* self; - self = instance; -#line 208 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - g_atomic_int_inc (&self->ref_count); -#line 208 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - return instance; -#line 13339 "scanner.c" -} - - -void scanner_unref (gpointer instance) { - Scanner* self; - self = instance; -#line 208 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - if (g_atomic_int_dec_and_test (&self->ref_count)) { -#line 208 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - SCANNER_GET_CLASS (self)->finalize (self); -#line 208 "/home/bob/bzr/simple-scan/trunk/src/scanner.vala" - g_type_free_instance ((GTypeInstance *) self); -#line 13352 "scanner.c" - } -} - - -static void _vala_array_destroy (gpointer array, gint array_length, GDestroyNotify destroy_func) { - if ((array != NULL) && (destroy_func != NULL)) { - int i; - for (i = 0; i < array_length; i = i + 1) { - if (((gpointer*) array)[i] != NULL) { - destroy_func (((gpointer*) array)[i]); - } - } - } -} - - -static void _vala_array_free (gpointer array, gint array_length, GDestroyNotify destroy_func) { - _vala_array_destroy (array, array_length, destroy_func); - g_free (array); -} - - -static gint _vala_array_length (gpointer array) { - int length; - length = 0; - if (array) { - while (((gpointer*) array)[length]) { - length++; - } - } - return length; -} - - - diff --git a/src/scanner.vala b/src/scanner.vala index 16f33cf..f98b4b6 100644 --- a/src/scanner.vala +++ b/src/scanner.vala @@ -69,7 +69,8 @@ public enum ScanType SINGLE, ADF_FRONT, ADF_BACK, - ADF_BOTH + ADF_BOTH, + BATCH } public class ScanOptions @@ -82,6 +83,7 @@ public class ScanOptions public int paper_height; public int brightness; public int contrast; + public int page_delay; } private class ScanJob @@ -96,6 +98,7 @@ private class ScanJob public int page_height; public int brightness; public int contrast; + public int page_delay; } private class Request {} @@ -945,6 +948,7 @@ public class Scanner switch (job.type) { case ScanType.SINGLE: + case ScanType.BATCH: if (!set_default_option (handle, option, index)) if (!set_constrained_string_option (handle, option, index, flatbed_sources, null)) warning ("Unable to set single page source, please file a bug"); @@ -1040,7 +1044,7 @@ public class Scanner if (option != null) { if (option.type == Sane.ValueType.BOOL) - set_bool_option (handle, option, index, job.type != ScanType.SINGLE, null); + set_bool_option (handle, option, index, (job.type != ScanType.SINGLE) && (job.type != ScanType.BATCH), null); } /* Disable compression, we will compress after scanning */ @@ -1291,6 +1295,9 @@ public class Scanner /* Go back for another page */ if (job.type != ScanType.SINGLE) { + if (job.type == ScanType.BATCH) + Thread.usleep (job.page_delay * 1000); + page_number++; pass_number = 0; notify (new NotifyPageDone (job.id)); @@ -1550,6 +1557,8 @@ public class Scanner return "ScanType.ADF_BACK"; case ScanType.ADF_BOTH: return "ScanType.ADF_BOTH"; + case ScanType.BATCH: + return "ScanType.BATCH"; default: return "%d".printf (type); } @@ -1557,10 +1566,10 @@ public class Scanner public void scan (string? device, ScanOptions options) { - debug ("Scanner.scan (\"%s\", dpi=%d, scan_mode=%s, depth=%d, type=%s, paper_width=%d, paper_height=%d, brightness=%d, contrast=%d)", + debug ("Scanner.scan (\"%s\", dpi=%d, scan_mode=%s, depth=%d, type=%s, paper_width=%d, paper_height=%d, brightness=%d, contrast=%d, delay=%dms)", device != null ? device : "(null)", options.dpi, get_scan_mode_string (options.scan_mode), options.depth, get_scan_type_string (options.type), options.paper_width, options.paper_height, - options.brightness, options.contrast); + options.brightness, options.contrast, options.page_delay); var request = new RequestStartScan (); request.job = new ScanJob (); request.job.id = job_id++; @@ -1573,6 +1582,7 @@ public class Scanner request.job.page_height = options.paper_height; request.job.brightness = options.brightness; request.job.contrast = options.contrast; + request.job.page_delay = options.page_delay; request_queue.push (request); } diff --git a/src/simple-scan.c b/src/simple-scan.c deleted file mode 100644 index 9b84313..0000000 --- a/src/simple-scan.c +++ /dev/null @@ -1,4276 +0,0 @@ -/* simple-scan.c generated by valac 0.34.6, the Vala compiler - * generated from simple-scan.vala, do not modify */ - -/* - * Copyright (C) 2009-2015 Canonical Ltd. - * Author: Robert Ancell - * - * This program is free software: you can redistribute it and/or modify it under - * the terms of the GNU General Public License as published by the Free Software - * Foundation, either version 3 of the License, or (at your option) any later - * version. See http://www.gnu.org/copyleft/gpl.html the full text of the - * license. - */ - -#include -#include -#include -#include -#include -#include -#include -#include -#include "colord.h" -#include -#include -#include "sane/sane.h" -#include -#include -#include -#include - - -#define TYPE_SIMPLE_SCAN (simple_scan_get_type ()) -#define SIMPLE_SCAN(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), TYPE_SIMPLE_SCAN, SimpleScan)) -#define SIMPLE_SCAN_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST ((klass), TYPE_SIMPLE_SCAN, SimpleScanClass)) -#define IS_SIMPLE_SCAN(obj) (G_TYPE_CHECK_INSTANCE_TYPE ((obj), TYPE_SIMPLE_SCAN)) -#define IS_SIMPLE_SCAN_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE ((klass), TYPE_SIMPLE_SCAN)) -#define SIMPLE_SCAN_GET_CLASS(obj) (G_TYPE_INSTANCE_GET_CLASS ((obj), TYPE_SIMPLE_SCAN, SimpleScanClass)) - -typedef struct _SimpleScan SimpleScan; -typedef struct _SimpleScanClass SimpleScanClass; -typedef struct _SimpleScanPrivate SimpleScanPrivate; - -#define TYPE_SCAN_DEVICE (scan_device_get_type ()) -#define SCAN_DEVICE(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), TYPE_SCAN_DEVICE, ScanDevice)) -#define SCAN_DEVICE_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST ((klass), TYPE_SCAN_DEVICE, ScanDeviceClass)) -#define IS_SCAN_DEVICE(obj) (G_TYPE_CHECK_INSTANCE_TYPE ((obj), TYPE_SCAN_DEVICE)) -#define IS_SCAN_DEVICE_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE ((klass), TYPE_SCAN_DEVICE)) -#define SCAN_DEVICE_GET_CLASS(obj) (G_TYPE_INSTANCE_GET_CLASS ((obj), TYPE_SCAN_DEVICE, ScanDeviceClass)) - -typedef struct _ScanDevice ScanDevice; -typedef struct _ScanDeviceClass ScanDeviceClass; - -#define TYPE_USER_INTERFACE (user_interface_get_type ()) -#define USER_INTERFACE(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), TYPE_USER_INTERFACE, UserInterface)) -#define USER_INTERFACE_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST ((klass), TYPE_USER_INTERFACE, UserInterfaceClass)) -#define IS_USER_INTERFACE(obj) (G_TYPE_CHECK_INSTANCE_TYPE ((obj), TYPE_USER_INTERFACE)) -#define IS_USER_INTERFACE_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE ((klass), TYPE_USER_INTERFACE)) -#define USER_INTERFACE_GET_CLASS(obj) (G_TYPE_INSTANCE_GET_CLASS ((obj), TYPE_USER_INTERFACE, UserInterfaceClass)) - -typedef struct _UserInterface UserInterface; -typedef struct _UserInterfaceClass UserInterfaceClass; - -#define TYPE_SCANNER (scanner_get_type ()) -#define SCANNER(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), TYPE_SCANNER, Scanner)) -#define SCANNER_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST ((klass), TYPE_SCANNER, ScannerClass)) -#define IS_SCANNER(obj) (G_TYPE_CHECK_INSTANCE_TYPE ((obj), TYPE_SCANNER)) -#define IS_SCANNER_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE ((klass), TYPE_SCANNER)) -#define SCANNER_GET_CLASS(obj) (G_TYPE_INSTANCE_GET_CLASS ((obj), TYPE_SCANNER, ScannerClass)) - -typedef struct _Scanner Scanner; -typedef struct _ScannerClass ScannerClass; - -#define TYPE_BOOK (book_get_type ()) -#define BOOK(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), TYPE_BOOK, Book)) -#define BOOK_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST ((klass), TYPE_BOOK, BookClass)) -#define IS_BOOK(obj) (G_TYPE_CHECK_INSTANCE_TYPE ((obj), TYPE_BOOK)) -#define IS_BOOK_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE ((klass), TYPE_BOOK)) -#define BOOK_GET_CLASS(obj) (G_TYPE_INSTANCE_GET_CLASS ((obj), TYPE_BOOK, BookClass)) - -typedef struct _Book Book; -typedef struct _BookClass BookClass; -#define _scan_device_unref0(var) ((var == NULL) ? NULL : (var = (scan_device_unref (var), NULL))) -#define _g_object_unref0(var) ((var == NULL) ? NULL : (var = (g_object_unref (var), NULL))) -#define _scanner_unref0(var) ((var == NULL) ? NULL : (var = (scanner_unref (var), NULL))) -#define _book_unref0(var) ((var == NULL) ? NULL : (var = (book_unref (var), NULL))) - -#define TYPE_SCAN_OPTIONS (scan_options_get_type ()) -#define SCAN_OPTIONS(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), TYPE_SCAN_OPTIONS, ScanOptions)) -#define SCAN_OPTIONS_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST ((klass), TYPE_SCAN_OPTIONS, ScanOptionsClass)) -#define IS_SCAN_OPTIONS(obj) (G_TYPE_CHECK_INSTANCE_TYPE ((obj), TYPE_SCAN_OPTIONS)) -#define IS_SCAN_OPTIONS_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE ((klass), TYPE_SCAN_OPTIONS)) -#define SCAN_OPTIONS_GET_CLASS(obj) (G_TYPE_INSTANCE_GET_CLASS ((obj), TYPE_SCAN_OPTIONS, ScanOptionsClass)) - -typedef struct _ScanOptions ScanOptions; -typedef struct _ScanOptionsClass ScanOptionsClass; - -#define TYPE_SCAN_PAGE_INFO (scan_page_info_get_type ()) -#define SCAN_PAGE_INFO(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), TYPE_SCAN_PAGE_INFO, ScanPageInfo)) -#define SCAN_PAGE_INFO_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST ((klass), TYPE_SCAN_PAGE_INFO, ScanPageInfoClass)) -#define IS_SCAN_PAGE_INFO(obj) (G_TYPE_CHECK_INSTANCE_TYPE ((obj), TYPE_SCAN_PAGE_INFO)) -#define IS_SCAN_PAGE_INFO_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE ((klass), TYPE_SCAN_PAGE_INFO)) -#define SCAN_PAGE_INFO_GET_CLASS(obj) (G_TYPE_INSTANCE_GET_CLASS ((obj), TYPE_SCAN_PAGE_INFO, ScanPageInfoClass)) - -typedef struct _ScanPageInfo ScanPageInfo; -typedef struct _ScanPageInfoClass ScanPageInfoClass; - -#define TYPE_SCAN_LINE (scan_line_get_type ()) -#define SCAN_LINE(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), TYPE_SCAN_LINE, ScanLine)) -#define SCAN_LINE_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST ((klass), TYPE_SCAN_LINE, ScanLineClass)) -#define IS_SCAN_LINE(obj) (G_TYPE_CHECK_INSTANCE_TYPE ((obj), TYPE_SCAN_LINE)) -#define IS_SCAN_LINE_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE ((klass), TYPE_SCAN_LINE)) -#define SCAN_LINE_GET_CLASS(obj) (G_TYPE_INSTANCE_GET_CLASS ((obj), TYPE_SCAN_LINE, ScanLineClass)) - -typedef struct _ScanLine ScanLine; -typedef struct _ScanLineClass ScanLineClass; -#define _g_error_free0(var) ((var == NULL) ? NULL : (var = (g_error_free (var), NULL))) -typedef struct _ScanDevicePrivate ScanDevicePrivate; -#define __g_list_free__scan_device_unref0_0(var) ((var == NULL) ? NULL : (var = (_g_list_free__scan_device_unref0_ (var), NULL))) -#define _g_free0(var) (var = (g_free (var), NULL)) -#define _g_list_free0(var) ((var == NULL) ? NULL : (var = (g_list_free (var), NULL))) -#define _g_ptr_array_unref0(var) ((var == NULL) ? NULL : (var = (g_ptr_array_unref (var), NULL))) -#define _g_hash_table_unref0(var) ((var == NULL) ? NULL : (var = (g_hash_table_unref (var), NULL))) - -#define TYPE_PAGE (page_get_type ()) -#define PAGE(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), TYPE_PAGE, Page)) -#define PAGE_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST ((klass), TYPE_PAGE, PageClass)) -#define IS_PAGE(obj) (G_TYPE_CHECK_INSTANCE_TYPE ((obj), TYPE_PAGE)) -#define IS_PAGE_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE ((klass), TYPE_PAGE)) -#define PAGE_GET_CLASS(obj) (G_TYPE_INSTANCE_GET_CLASS ((obj), TYPE_PAGE, PageClass)) - -typedef struct _Page Page; -typedef struct _PageClass PageClass; - -#define TYPE_SCAN_DIRECTION (scan_direction_get_type ()) -#define _page_unref0(var) ((var == NULL) ? NULL : (var = (page_unref (var), NULL))) -typedef struct _ScanPageInfoPrivate ScanPageInfoPrivate; -typedef struct _ScanOptionsPrivate ScanOptionsPrivate; - -#define TYPE_SCAN_MODE (scan_mode_get_type ()) - -#define TYPE_SCAN_TYPE (scan_type_get_type ()) -#define _g_string_free0(var) ((var == NULL) ? NULL : (var = (g_string_free (var, TRUE), NULL))) -#define _fclose0(var) ((var == NULL) ? NULL : (var = (fclose (var), NULL))) -#define _g_option_context_free0(var) ((var == NULL) ? NULL : (var = (g_option_context_free (var), NULL))) -#define _g_timer_destroy0(var) ((var == NULL) ? NULL : (var = (g_timer_destroy (var), NULL))) - -struct _SimpleScan { - GtkApplication parent_instance; - SimpleScanPrivate * priv; -}; - -struct _SimpleScanClass { - GtkApplicationClass parent_class; -}; - -struct _SimpleScanPrivate { - ScanDevice* default_device; - gboolean have_devices; - GUsbContext* usb_context; - UserInterface* ui; - Scanner* scanner; - Book* book; -}; - -struct _ScanDevice { - GTypeInstance parent_instance; - volatile int ref_count; - ScanDevicePrivate * priv; - gchar* name; - gchar* label; -}; - -struct _ScanDeviceClass { - GTypeClass parent_class; - void (*finalize) (ScanDevice *self); -}; - -typedef enum { - SCAN_DIRECTION_TOP_TO_BOTTOM, - SCAN_DIRECTION_LEFT_TO_RIGHT, - SCAN_DIRECTION_BOTTOM_TO_TOP, - SCAN_DIRECTION_RIGHT_TO_LEFT -} ScanDirection; - -struct _ScanPageInfo { - GTypeInstance parent_instance; - volatile int ref_count; - ScanPageInfoPrivate * priv; - gint width; - gint height; - gint depth; - gint n_channels; - gdouble dpi; - gchar* device; -}; - -struct _ScanPageInfoClass { - GTypeClass parent_class; - void (*finalize) (ScanPageInfo *self); -}; - -typedef enum { - SCAN_MODE_DEFAULT, - SCAN_MODE_COLOR, - SCAN_MODE_GRAY, - SCAN_MODE_LINEART -} ScanMode; - -typedef enum { - SCAN_TYPE_SINGLE, - SCAN_TYPE_ADF_FRONT, - SCAN_TYPE_ADF_BACK, - SCAN_TYPE_ADF_BOTH -} ScanType; - -struct _ScanOptions { - GTypeInstance parent_instance; - volatile int ref_count; - ScanOptionsPrivate * priv; - gint dpi; - ScanMode scan_mode; - gint depth; - ScanType type; - gint paper_width; - gint paper_height; - gint brightness; - gint contrast; -}; - -struct _ScanOptionsClass { - GTypeClass parent_class; - void (*finalize) (ScanOptions *self); -}; - - -static gpointer simple_scan_parent_class = NULL; -static gboolean simple_scan_show_version; -static gboolean simple_scan_show_version = FALSE; -static gboolean simple_scan_debug_enabled; -static gboolean simple_scan_debug_enabled = FALSE; -static gchar* simple_scan_fix_pdf_filename; -static gchar* simple_scan_fix_pdf_filename = NULL; -static GTimer* simple_scan_log_timer; -static GTimer* simple_scan_log_timer = NULL; -static FILE* simple_scan_log_file; -static FILE* simple_scan_log_file = NULL; - -GType simple_scan_get_type (void) G_GNUC_CONST; -gpointer scan_device_ref (gpointer instance); -void scan_device_unref (gpointer instance); -GParamSpec* param_spec_scan_device (const gchar* name, const gchar* nick, const gchar* blurb, GType object_type, GParamFlags flags); -void value_set_scan_device (GValue* value, gpointer v_object); -void value_take_scan_device (GValue* value, gpointer v_object); -gpointer value_get_scan_device (const GValue* value); -GType scan_device_get_type (void) G_GNUC_CONST; -GType user_interface_get_type (void) G_GNUC_CONST; -gpointer scanner_ref (gpointer instance); -void scanner_unref (gpointer instance); -GParamSpec* param_spec_scanner (const gchar* name, const gchar* nick, const gchar* blurb, GType object_type, GParamFlags flags); -void value_set_scanner (GValue* value, gpointer v_object); -void value_take_scanner (GValue* value, gpointer v_object); -gpointer value_get_scanner (const GValue* value); -GType scanner_get_type (void) G_GNUC_CONST; -gpointer book_ref (gpointer instance); -void book_unref (gpointer instance); -GParamSpec* param_spec_book (const gchar* name, const gchar* nick, const gchar* blurb, GType object_type, GParamFlags flags); -void value_set_book (GValue* value, gpointer v_object); -void value_take_book (GValue* value, gpointer v_object); -gpointer value_get_book (const GValue* value); -GType book_get_type (void) G_GNUC_CONST; -#define SIMPLE_SCAN_GET_PRIVATE(o) (G_TYPE_INSTANCE_GET_PRIVATE ((o), TYPE_SIMPLE_SCAN, SimpleScanPrivate)) -enum { - SIMPLE_SCAN_DUMMY_PROPERTY -}; -SimpleScan* simple_scan_new (ScanDevice* device); -SimpleScan* simple_scan_construct (GType object_type, ScanDevice* device); -static void simple_scan_real_startup (GApplication* base); -UserInterface* user_interface_new (void); -UserInterface* user_interface_construct (GType object_type); -Book* user_interface_get_book (UserInterface* self); -gpointer scan_options_ref (gpointer instance); -void scan_options_unref (gpointer instance); -GParamSpec* param_spec_scan_options (const gchar* name, const gchar* nick, const gchar* blurb, GType object_type, GParamFlags flags); -void value_set_scan_options (GValue* value, gpointer v_object); -void value_take_scan_options (GValue* value, gpointer v_object); -gpointer value_get_scan_options (const GValue* value); -GType scan_options_get_type (void) G_GNUC_CONST; -static void simple_scan_scan_cb (SimpleScan* self, UserInterface* ui, const gchar* device, ScanOptions* options); -static void _simple_scan_scan_cb_user_interface_start_scan (UserInterface* _sender, const gchar* device, ScanOptions* options, gpointer self); -static void simple_scan_cancel_cb (SimpleScan* self, UserInterface* ui); -static void _simple_scan_cancel_cb_user_interface_stop_scan (UserInterface* _sender, gpointer self); -static void simple_scan_email_cb (SimpleScan* self, UserInterface* ui, const gchar* profile, gint quality); -static void _simple_scan_email_cb_user_interface_email (UserInterface* _sender, const gchar* profile, gint quality, gpointer self); -Scanner* scanner_get_instance (void); -static void simple_scan_update_scan_devices_cb (SimpleScan* self, Scanner* scanner, GList* devices); -static void _simple_scan_update_scan_devices_cb_scanner_update_devices (Scanner* _sender, GList* devices, gpointer self); -static void simple_scan_authorize_cb (SimpleScan* self, Scanner* scanner, const gchar* resource); -static void _simple_scan_authorize_cb_scanner_request_authorization (Scanner* _sender, const gchar* resource, gpointer self); -static void simple_scan_scanner_new_page_cb (SimpleScan* self, Scanner* scanner); -static void _simple_scan_scanner_new_page_cb_scanner_expect_page (Scanner* _sender, gpointer self); -gpointer scan_page_info_ref (gpointer instance); -void scan_page_info_unref (gpointer instance); -GParamSpec* param_spec_scan_page_info (const gchar* name, const gchar* nick, const gchar* blurb, GType object_type, GParamFlags flags); -void value_set_scan_page_info (GValue* value, gpointer v_object); -void value_take_scan_page_info (GValue* value, gpointer v_object); -gpointer value_get_scan_page_info (const GValue* value); -GType scan_page_info_get_type (void) G_GNUC_CONST; -static void simple_scan_scanner_page_info_cb (SimpleScan* self, Scanner* scanner, ScanPageInfo* info); -static void _simple_scan_scanner_page_info_cb_scanner_got_page_info (Scanner* _sender, ScanPageInfo* info, gpointer self); -gpointer scan_line_ref (gpointer instance); -void scan_line_unref (gpointer instance); -GParamSpec* param_spec_scan_line (const gchar* name, const gchar* nick, const gchar* blurb, GType object_type, GParamFlags flags); -void value_set_scan_line (GValue* value, gpointer v_object); -void value_take_scan_line (GValue* value, gpointer v_object); -gpointer value_get_scan_line (const GValue* value); -GType scan_line_get_type (void) G_GNUC_CONST; -static void simple_scan_scanner_line_cb (SimpleScan* self, Scanner* scanner, ScanLine* line); -static void _simple_scan_scanner_line_cb_scanner_got_line (Scanner* _sender, ScanLine* line, gpointer self); -static void simple_scan_scanner_page_done_cb (SimpleScan* self, Scanner* scanner); -static void _simple_scan_scanner_page_done_cb_scanner_page_done (Scanner* _sender, gpointer self); -static void simple_scan_scanner_document_done_cb (SimpleScan* self, Scanner* scanner); -static void _simple_scan_scanner_document_done_cb_scanner_document_done (Scanner* _sender, gpointer self); -static void simple_scan_scanner_failed_cb (SimpleScan* self, Scanner* scanner, gint error_code, const gchar* error_string); -static void _simple_scan_scanner_failed_cb_scanner_scan_failed (Scanner* _sender, gint error_code, const gchar* error_string, gpointer self); -static void simple_scan_scanner_scanning_changed_cb (SimpleScan* self, Scanner* scanner); -static void _simple_scan_scanner_scanning_changed_cb_scanner_scanning_changed (Scanner* _sender, gpointer self); -static void ___lambda22_ (SimpleScan* self); -void scanner_redetect (Scanner* self); -static void ____lambda22__g_usb_context_device_added (GUsbContext* _sender, GUsbDevice* device, gpointer self); -static void ___lambda23_ (SimpleScan* self); -static void ____lambda23__g_usb_context_device_removed (GUsbContext* _sender, GUsbDevice* device, gpointer self); -void user_interface_set_scan_devices (UserInterface* self, GList* devices, const gchar* missing_driver); -void user_interface_set_selected_device (UserInterface* self, const gchar* value); -static void _scan_device_unref0_ (gpointer var); -static void _g_list_free__scan_device_unref0_ (GList* self); -static void simple_scan_real_activate (GApplication* base); -void user_interface_start (UserInterface* self); -void scanner_start (Scanner* self); -static void simple_scan_real_shutdown (GApplication* base); -void scanner_free (Scanner* self); -gchar* simple_scan_suggest_driver (SimpleScan* self); -static void _g_free0_ (gpointer var); -static void simple_scan_add_devices (SimpleScan* self, GHashTable* map, guint32* devices, int devices_length1, const gchar* driver); -void user_interface_authorize (UserInterface* self, const gchar* resource, gchar** username, gchar** password); -void scanner_authorize (Scanner* self, const gchar* username, const gchar* password); -gpointer page_ref (gpointer instance); -void page_unref (gpointer instance); -GParamSpec* param_spec_page (const gchar* name, const gchar* nick, const gchar* blurb, GType object_type, GParamFlags flags); -void value_set_page (GValue* value, gpointer v_object); -void value_take_page (GValue* value, gpointer v_object); -gpointer value_get_page (const GValue* value); -GType page_get_type (void) G_GNUC_CONST; -static Page* simple_scan_append_page (SimpleScan* self); -Page* book_get_page (Book* self, gint page_number); -gboolean page_get_has_data (Page* self); -void user_interface_set_selected_page (UserInterface* self, Page* value); -void page_start (Page* self); -GType scan_direction_get_type (void) G_GNUC_CONST; -ScanDirection page_get_scan_direction (Page* self); -gint page_get_width (Page* self); -gint page_get_height (Page* self); -gint page_get_dpi (Page* self); -gboolean page_get_has_crop (Page* self); -const gchar* page_get_crop_name (Page* self); -gint page_get_crop_x (Page* self); -gint page_get_crop_y (Page* self); -gint page_get_crop_width (Page* self); -gint page_get_crop_height (Page* self); -Page* page_new (gint width, gint height, gint dpi, ScanDirection scan_direction); -Page* page_construct (GType object_type, gint width, gint height, gint dpi, ScanDirection scan_direction); -void book_append_page (Book* self, Page* page); -void page_set_named_crop (Page* self, const gchar* name); -void page_set_custom_crop (Page* self, gint width, gint height); -void page_move_crop (Page* self, gint x, gint y); -static gchar* simple_scan_get_profile_for_device (SimpleScan* self, const gchar* device_name); -void page_set_page_info (Page* self, ScanPageInfo* info); -void page_set_color_profile (Page* self, const gchar* value); -guint book_get_n_pages (Book* self); -void page_parse_scan_line (Page* self, ScanLine* line); -void page_finish (Page* self); -static void simple_scan_remove_empty_page (SimpleScan* self); -void book_delete_page (Book* self, Page* page); -void user_interface_show_error (UserInterface* self, const gchar* error_title, const gchar* error_text, gboolean change_scanner_hint); -gboolean scanner_is_scanning (Scanner* self); -void user_interface_set_scanning (UserInterface* self, gboolean value); -GType scan_mode_get_type (void) G_GNUC_CONST; -GType scan_type_get_type (void) G_GNUC_CONST; -void scanner_scan (Scanner* self, const gchar* device, ScanOptions* options); -void scanner_cancel (Scanner* self); -static gchar* simple_scan_get_temporary_filename (SimpleScan* self, const gchar* prefix, const gchar* extension); -void user_interface_show_progress_dialog (UserInterface* self); -void book_save (Book* self, const gchar* type, gint quality, GFile* file, GError** error); -void user_interface_hide_progress_dialog (UserInterface* self); -void page_save (Page* self, const gchar* type, gint quality, GFile* file, GError** error); -static void simple_scan_log_cb (const gchar* log_domain, GLogLevelFlags log_level, const gchar* message); -static void simple_scan_fix_pdf (const gchar* filename, GError** error); -gint simple_scan_main (gchar** args, int args_length1); -ScanDevice* scan_device_new (void); -ScanDevice* scan_device_construct (GType object_type); -static void _simple_scan_log_cb_glog_func (const gchar* log_domain, GLogLevelFlags log_levels, const gchar* message, gpointer self); -static void simple_scan_finalize (GObject* obj); - -const GOptionEntry SIMPLE_SCAN_options[4] = {{"version", 'v', 0, G_OPTION_ARG_NONE, &simple_scan_show_version, "Show release version", NULL}, {"debug", 'd', 0, G_OPTION_ARG_NONE, &simple_scan_debug_enabled, "Print debugging messages", NULL}, {"fix-pdf", (gchar) 0, 0, G_OPTION_ARG_STRING, &simple_scan_fix_pdf_filename, "Fix PDF files generated with older versions of Simple Scan", "FILENAME..."}, {NULL}}; -static const guint32 SIMPLE_SCAN_brscan_devices[56] = {(guint32) 0x04f90110, (guint32) 0x04f90111, (guint32) 0x04f90112, (guint32) 0x04f9011d, (guint32) 0x04f9011e, (guint32) 0x04f9011f, (guint32) 0x04f9012b, (guint32) 0x04f90124, (guint32) 0x04f90153, (guint32) 0x04f90125, (guint32) 0x04f90113, (guint32) 0x04f90114, (guint32) 0x04f90115, (guint32) 0x04f90116, (guint32) 0x04f90119, (guint32) 0x04f9011a, (guint32) 0x04f9011b, (guint32) 0x04f9011c, (guint32) 0x04f9012e, (guint32) 0x04f9012f, (guint32) 0x04f90130, (guint32) 0x04f90128, (guint32) 0x04f90127, (guint32) 0x04f90142, (guint32) 0x04f90143, (guint32) 0x04f90140, (guint32) 0x04f90141, (guint32) 0x04f9014e, (guint32) 0x04f9014f, (guint32) 0x04f90150, (guint32) 0x04f90151, (guint32) 0x04f9010e, (guint32) 0x04f9013a, (guint32) 0x04f90120, (guint32) 0x04f9010f, (guint32) 0x04f90121, (guint32) 0x04f90122, (guint32) 0x04f90132, (guint32) 0x04f9013d, (guint32) 0x04f9013c, (guint32) 0x04f90136, (guint32) 0x04f90135, (guint32) 0x04f9013e, (guint32) 0x04f9013f, (guint32) 0x04f90144, (guint32) 0x04f90146, (guint32) 0x04f90148, (guint32) 0x04f9014a, (guint32) 0x04f9014b, (guint32) 0x04f9014c, (guint32) 0x04f90157, (guint32) 0x04f90158, (guint32) 0x04f9015d, (guint32) 0x04f9015e, (guint32) 0x04f9015f, (guint32) 0x04f90160}; -static const guint32 SIMPLE_SCAN_brscan2_devices[31] = {(guint32) 0x04f901c9, (guint32) 0x04f901ca, (guint32) 0x04f901cb, (guint32) 0x04f901cc, (guint32) 0x04f901ec, (guint32) 0x04f901e4, (guint32) 0x04f901e3, (guint32) 0x04f901e2, (guint32) 0x04f901e1, (guint32) 0x04f901e0, (guint32) 0x04f901df, (guint32) 0x04f901de, (guint32) 0x04f901dd, (guint32) 0x04f901dc, (guint32) 0x04f901db, (guint32) 0x04f901da, (guint32) 0x04f901d9, (guint32) 0x04f901d8, (guint32) 0x04f901d7, (guint32) 0x04f901d6, (guint32) 0x04f901d5, (guint32) 0x04f901d4, (guint32) 0x04f901d3, (guint32) 0x04f901d2, (guint32) 0x04f901d1, (guint32) 0x04f901d0, (guint32) 0x04f901cf, (guint32) 0x04f901ce, (guint32) 0x04f9020d, (guint32) 0x04f9020c, (guint32) 0x04f9020a}; -static const guint32 SIMPLE_SCAN_brscan3_devices[58] = {(guint32) 0x04f90222, (guint32) 0x04f90223, (guint32) 0x04f90224, (guint32) 0x04f90225, (guint32) 0x04f90229, (guint32) 0x04f9022a, (guint32) 0x04f9022c, (guint32) 0x04f90228, (guint32) 0x04f90236, (guint32) 0x04f90227, (guint32) 0x04f9022b, (guint32) 0x04f9022d, (guint32) 0x04f9022e, (guint32) 0x04f9022f, (guint32) 0x04f90230, (guint32) 0x04f9021b, (guint32) 0x04f9021a, (guint32) 0x04f90219, (guint32) 0x04f9023f, (guint32) 0x04f90216, (guint32) 0x04f9021d, (guint32) 0x04f9021c, (guint32) 0x04f90220, (guint32) 0x04f9021e, (guint32) 0x04f9023e, (guint32) 0x04f90235, (guint32) 0x04f9023a, (guint32) 0x04f901c9, (guint32) 0x04f901ca, (guint32) 0x04f901cb, (guint32) 0x04f901cc, (guint32) 0x04f901ec, (guint32) 0x04f9020d, (guint32) 0x04f9020c, (guint32) 0x04f90257, (guint32) 0x04f9025d, (guint32) 0x04f90254, (guint32) 0x04f9025b, (guint32) 0x04f9026b, (guint32) 0x04f90258, (guint32) 0x04f9025e, (guint32) 0x04f90256, (guint32) 0x04f90240, (guint32) 0x04f9025f, (guint32) 0x04f90260, (guint32) 0x04f90261, (guint32) 0x04f90278, (guint32) 0x04f9026f, (guint32) 0x04f9026e, (guint32) 0x04f9026d, (guint32) 0x04f90234, (guint32) 0x04f90239, (guint32) 0x04f90253, (guint32) 0x04f90255, (guint32) 0x04f90259, (guint32) 0x04f9025a, (guint32) 0x04f9025c, (guint32) 0x04f90276}; -static const guint32 SIMPLE_SCAN_brscan4_devices[224] = {(guint32) 0x04f90314, (guint32) 0x04f90313, (guint32) 0x04f90312, (guint32) 0x04f90311, (guint32) 0x04f90310, (guint32) 0x04f9030f, (guint32) 0x04f90366, (guint32) 0x04f90365, (guint32) 0x04f90364, (guint32) 0x04f90350, (guint32) 0x04f9034f, (guint32) 0x04f9034e, (guint32) 0x04f9034b, (guint32) 0x04f90349, (guint32) 0x04f90347, (guint32) 0x04f90346, (guint32) 0x04f90343, (guint32) 0x04f90342, (guint32) 0x04f90341, (guint32) 0x04f90340, (guint32) 0x04f9033d, (guint32) 0x04f9033c, (guint32) 0x04f9033a, (guint32) 0x04f90339, (guint32) 0x04f90392, (guint32) 0x04f90373, (guint32) 0x04f9036e, (guint32) 0x04f9036d, (guint32) 0x04f9036c, (guint32) 0x04f9036b, (guint32) 0x04f9036a, (guint32) 0x04f90369, (guint32) 0x04f90368, (guint32) 0x04f90367, (guint32) 0x04f90338, (guint32) 0x04f90337, (guint32) 0x04f90335, (guint32) 0x04f90331, (guint32) 0x04f90330, (guint32) 0x04f90329, (guint32) 0x04f90328, (guint32) 0x04f90326, (guint32) 0x04f90324, (guint32) 0x04f90322, (guint32) 0x04f90321, (guint32) 0x04f90320, (guint32) 0x04f90372, (guint32) 0x04f90371, (guint32) 0x04f90370, (guint32) 0x04f9036f, (guint32) 0x04f90361, (guint32) 0x04f90360, (guint32) 0x04f9035e, (guint32) 0x04f9035d, (guint32) 0x04f9035c, (guint32) 0x04f9035b, (guint32) 0x04f90379, (guint32) 0x04f90378, (guint32) 0x04f90376, (guint32) 0x04f9037a, (guint32) 0x04f9037b, (guint32) 0x04f90377, (guint32) 0x04f9037f, (guint32) 0x04f9037e, (guint32) 0x04f9037d, (guint32) 0x04f9037c, (guint32) 0x04f9035a, (guint32) 0x04f90359, (guint32) 0x04f90358, (guint32) 0x04f90357, (guint32) 0x04f90356, (guint32) 0x04f90355, (guint32) 0x04f90354, (guint32) 0x04f90353, (guint32) 0x04f90351, (guint32) 0x04f90390, (guint32) 0x04f903b3, (guint32) 0x04f90396, (guint32) 0x04f90395, (guint32) 0x04f90394, (guint32) 0x04f90393, (guint32) 0x04f90380, (guint32) 0x04f90381, (guint32) 0x04f903bd, (guint32) 0x04f90383, (guint32) 0x04f90397, (guint32) 0x04f90386, (guint32) 0x04f90384, (guint32) 0x04f90385, (guint32) 0x04f90388, (guint32) 0x04f90389, (guint32) 0x04f9038b, (guint32) 0x04f9038a, (guint32) 0x04f9038c, (guint32) 0x04f9038e, (guint32) 0x04f9038f, (guint32) 0x04f9038d, (guint32) 0x04f903bc, (guint32) 0x04f903bb, (guint32) 0x04f903b6, (guint32) 0x04f903b5, (guint32) 0x04f903b4, (guint32) 0x04f90290, (guint32) 0x04f9028f, (guint32) 0x04f9028d, (guint32) 0x04f9028a, (guint32) 0x04f90284, (guint32) 0x04f90283, (guint32) 0x04f90282, (guint32) 0x04f90281, (guint32) 0x04f9027e, (guint32) 0x04f9027d, (guint32) 0x04f9027c, (guint32) 0x04f9027b, (guint32) 0x04f90280, (guint32) 0x04f9027a, (guint32) 0x04f90279, (guint32) 0x04f9027f, (guint32) 0x04f90285, (guint32) 0x04f9029a, (guint32) 0x04f9029f, (guint32) 0x04f9029e, (guint32) 0x04f90289, (guint32) 0x04f90288, (guint32) 0x04f960a0, (guint32) 0x04f960a1, (guint32) 0x04f90293, (guint32) 0x04f902b7, (guint32) 0x04f90294, (guint32) 0x04f90296, (guint32) 0x04f90298, (guint32) 0x04f902ba, (guint32) 0x04f90299, (guint32) 0x04f902bb, (guint32) 0x04f902d4, (guint32) 0x04f90291, (guint32) 0x04f902ac, (guint32) 0x04f902b5, (guint32) 0x04f90292, (guint32) 0x04f902b6, (guint32) 0x04f90295, (guint32) 0x04f902b8, (guint32) 0x04f9029c, (guint32) 0x04f902cb, (guint32) 0x04f902ca, (guint32) 0x04f902a6, (guint32) 0x04f902a7, (guint32) 0x04f902ab, (guint32) 0x04f902a5, (guint32) 0x04f902a8, (guint32) 0x04f902a0, (guint32) 0x04f902c1, (guint32) 0x04f902c0, (guint32) 0x04f902bf, (guint32) 0x04f902be, (guint32) 0x04f902bd, (guint32) 0x04f902bc, (guint32) 0x04f902b2, (guint32) 0x04f90287, (guint32) 0x04f902cf, (guint32) 0x04f902ce, (guint32) 0x04f902cd, (guint32) 0x04f902c7, (guint32) 0x04f902c6, (guint32) 0x04f902c5, (guint32) 0x04f902c4, (guint32) 0x04f902b4, (guint32) 0x04f902b3, (guint32) 0x04f902c2, (guint32) 0x04f960a4, (guint32) 0x04f960a5, (guint32) 0x04f902cc, (guint32) 0x04f902c8, (guint32) 0x04f902c3, (guint32) 0x04f902d3, (guint32) 0x04f902b1, (guint32) 0x04f902b0, (guint32) 0x04f902af, (guint32) 0x04f902ae, (guint32) 0x04f902ad, (guint32) 0x04f902d1, (guint32) 0x04f902d0, (guint32) 0x04f902fb, (guint32) 0x04f902f1, (guint32) 0x04f902f0, (guint32) 0x04f902ef, (guint32) 0x04f902ed, (guint32) 0x04f902ec, (guint32) 0x04f902ee, (guint32) 0x04f902eb, (guint32) 0x04f902e9, (guint32) 0x04f902e8, (guint32) 0x04f902fa, (guint32) 0x04f902ea, (guint32) 0x04f902e6, (guint32) 0x04f902e5, (guint32) 0x04f902e4, (guint32) 0x04f902e3, (guint32) 0x04f902e2, (guint32) 0x04f902f9, (guint32) 0x04f902de, (guint32) 0x04f902e0, (guint32) 0x04f902df, (guint32) 0x04f902e1, (guint32) 0x04f902e7, (guint32) 0x04f902fc, (guint32) 0x04f902fd, (guint32) 0x04f902fe, (guint32) 0x04f902dd, (guint32) 0x04f902c9, (guint32) 0x04f902ff, (guint32) 0x04f90300, (guint32) 0x04f902f2, (guint32) 0x04f902f3, (guint32) 0x04f902f4, (guint32) 0x04f902f8, (guint32) 0x04f902f5, (guint32) 0x04f902f6, (guint32) 0x04f902f7, (guint32) 0x04f90318, (guint32) 0x04f960a6, (guint32) 0x04f960a7, (guint32) 0x04f960a8, (guint32) 0x04f960a9}; -static const guint32 SIMPLE_SCAN_samsung_devices[69] = {(guint32) 0x04e83425, (guint32) 0x04e8341c, (guint32) 0x04e8342a, (guint32) 0x04e8343d, (guint32) 0x04e83456, (guint32) 0x04e8345a, (guint32) 0x04e83427, (guint32) 0x04e8343a, (guint32) 0x04e83428, (guint32) 0x04e8343b, (guint32) 0x04e83455, (guint32) 0x04e83421, (guint32) 0x04e83439, (guint32) 0x04e83444, (guint32) 0x04e8343f, (guint32) 0x04e8344e, (guint32) 0x04e83431, (guint32) 0x04e8345c, (guint32) 0x04e8344d, (guint32) 0x04e83462, (guint32) 0x04e83464, (guint32) 0x04e83461, (guint32) 0x04e83460, (guint32) 0x04e8340e, (guint32) 0x04e83435, (guint32) 0x04e8340f, (guint32) 0x04e83441, (guint32) 0x04e8344f, (guint32) 0x04e83413, (guint32) 0x04e8341b, (guint32) 0x04e8342e, (guint32) 0x04e83426, (guint32) 0x04e8342b, (guint32) 0x04e83433, (guint32) 0x04e83440, (guint32) 0x04e83434, (guint32) 0x04e8345b, (guint32) 0x04e83457, (guint32) 0x04e8341f, (guint32) 0x04e83453, (guint32) 0x04e8344b, (guint32) 0x04e83409, (guint32) 0x04e83412, (guint32) 0x04e83419, (guint32) 0x04e8342c, (guint32) 0x04e8343c, (guint32) 0x04e83432, (guint32) 0x04e8342d, (guint32) 0x04e83430, (guint32) 0x04e8342f, (guint32) 0x04e83446, (guint32) 0x04e8341a, (guint32) 0x04e83437, (guint32) 0x04e83442, (guint32) 0x04e83466, (guint32) 0x04e8340d, (guint32) 0x04e8341d, (guint32) 0x04e83420, (guint32) 0x04e83429, (guint32) 0x04e83443, (guint32) 0x04e83438, (guint32) 0x04e8344c, (guint32) 0x04e8345d, (guint32) 0x04e83463, (guint32) 0x04e83465, (guint32) 0x04e83450, (guint32) 0x04e83468, (guint32) 0x04e83469, (guint32) 0x04e83471}; -static const guint32 SIMPLE_SCAN_hpaio_devices[520] = {(guint32) 0x03f02311, (guint32) 0x03f09711, (guint32) 0x03f01311, (guint32) 0x03f01011, (guint32) 0x03f00f11, (guint32) 0x03f01911, (guint32) 0x03f00011, (guint32) 0x03f00111, (guint32) 0x03f00611, (guint32) 0x03f00511, (guint32) 0x03f00811, (guint32) 0x03f00711, (guint32) 0x03f00211, (guint32) 0x03f00311, (guint32) 0x03f00411, (guint32) 0x03f0062a, (guint32) 0x03f04912, (guint32) 0x03f09911, (guint32) 0x03f03802, (guint32) 0x03f07a11, (guint32) 0x03f08311, (guint32) 0x03f07b11, (guint32) 0x03f0a711, (guint32) 0x03f08d11, (guint32) 0x03f08a11, (guint32) 0x03f0bb11, (guint32) 0x03f0222a, (guint32) 0x03f0322a, (guint32) 0x03f03902, (guint32) 0x03f01002, (guint32) 0x03f0242a, (guint32) 0x03f0332a, (guint32) 0x03f0122a, (guint32) 0x03f00c2a, (guint32) 0x03f0132a, (guint32) 0x03f02c2a, (guint32) 0x03f07e11, (guint32) 0x03f07811, (guint32) 0x03f08e11, (guint32) 0x03f02d2a, (guint32) 0x03f03502, (guint32) 0x03f01102, (guint32) 0x03f06112, (guint32) 0x03f06212, (guint32) 0x03f05511, (guint32) 0x03f00f2a, (guint32) 0x03f0082a, (guint32) 0x03f07311, (guint32) 0x03f07c11, (guint32) 0x03f07d11, (guint32) 0x03f01d02, (guint32) 0x03f01202, (guint32) 0x03f01e02, (guint32) 0x03f01602, (guint32) 0x03f01302, (guint32) 0x03f01702, (guint32) 0x03f0152a, (guint32) 0x03f0142a, (guint32) 0x03f09611, (guint32) 0x03f01502, (guint32) 0x03f01902, (guint32) 0x03f01f02, (guint32) 0x03f00512, (guint32) 0x03f0aa11, (guint32) 0x03f0a311, (guint32) 0x03f01312, (guint32) 0x03f01802, (guint32) 0x03f02812, (guint32) 0x03f0bf11, (guint32) 0x03f0c011, (guint32) 0x03f0342a, (guint32) 0x03f09e17, (guint32) 0x03f09f17, (guint32) 0x03f0252a, (guint32) 0x03f0a417, (guint32) 0x03f01a02, (guint32) 0x03f09e11, (guint32) 0x03f09011, (guint32) 0x03f02602, (guint32) 0x03f0272a, (guint32) 0x03f02b02, (guint32) 0x03f01812, (guint32) 0x03f0b211, (guint32) 0x03f0352a, (guint32) 0x03f02b2a, (guint32) 0x03f0362a, (guint32) 0x03f0a517, (guint32) 0x03f01b02, (guint32) 0x03f02702, (guint32) 0x03f02c02, (guint32) 0x03f0282a, (guint32) 0x03f02104, (guint32) 0x03f0432a, (guint32) 0x03f02004, (guint32) 0x03f01a2a, (guint32) 0x03f02304, (guint32) 0x03f01b2a, (guint32) 0x03f0442a, (guint32) 0x03f08904, (guint32) 0x03f0a617, (guint32) 0x03f09a17, (guint32) 0x03f0312a, (guint32) 0x03f0452a, (guint32) 0x03f01c02, (guint32) 0x03f01811, (guint32) 0x03f09d17, (guint32) 0x03f02804, (guint32) 0x03f02904, (guint32) 0x03f01511, (guint32) 0x03f01411, (guint32) 0x03f0372a, (guint32) 0x03f00d14, (guint32) 0x03f01611, (guint32) 0x03f01711, (guint32) 0x03f00f14, (guint32) 0x03f01f2a, (guint32) 0x03f00304, (guint32) 0x03f00204, (guint32) 0x03f00804, (guint32) 0x03f02902, (guint32) 0x03f00704, (guint32) 0x03f01e2a, (guint32) 0x03f00404, (guint32) 0x03f00604, (guint32) 0x03f00904, (guint32) 0x03f01512, (guint32) 0x03f01c2a, (guint32) 0x03f00104, (guint32) 0x03f01d2a, (guint32) 0x03f00004, (guint32) 0x03f02604, (guint32) 0x03f02704, (guint32) 0x03f01804, (guint32) 0x03f01504, (guint32) 0x03f01f11, (guint32) 0x03f01204, (guint32) 0x03f01604, (guint32) 0x03f01704, (guint32) 0x03f01104, (guint32) 0x03f01e11, (guint32) 0x03f01304, (guint32) 0x03f01404, (guint32) 0x03f03104, (guint32) 0x03f01004, (guint32) 0x03f03004, (guint32) 0x03f03304, (guint32) 0x03f05004, (guint32) 0x03f01712, (guint32) 0x03f02e11, (guint32) 0x03f00517, (guint32) 0x03f08811, (guint32) 0x03f01317, (guint32) 0x03f04117, (guint32) 0x03f03217, (guint32) 0x03f03e17, (guint32) 0x03f00c17, (guint32) 0x03f0b511, (guint32) 0x03f04217, (guint32) 0x03f04317, (guint32) 0x03f02b17, (guint32) 0x03f03017, (guint32) 0x03f02d17, (guint32) 0x03f02c17, (guint32) 0x03f00b2a, (guint32) 0x03f0112a, (guint32) 0x03f08911, (guint32) 0x03f07c04, (guint32) 0x03f00912, (guint32) 0x03f03011, (guint32) 0x03f0032a, (guint32) 0x03f0002a, (guint32) 0x03f0102a, (guint32) 0x03f03402, (guint32) 0x03f05617, (guint32) 0x03f05717, (guint32) 0x03f0042a, (guint32) 0x03f00f17, (guint32) 0x03f04004, (guint32) 0x03f01017, (guint32) 0x03f01e17, (guint32) 0x03f00317, (guint32) 0x03f00f12, (guint32) 0x03f02f11, (guint32) 0x03f0052a, (guint32) 0x03f04717, (guint32) 0x03f03202, (guint32) 0x03f00e2a, (guint32) 0x03f0262a, (guint32) 0x03f03302, (guint32) 0x03f00417, (guint32) 0x03f00212, (guint32) 0x03f01412, (guint32) 0x03f07804, (guint32) 0x03f03b11, (guint32) 0x03f01117, (guint32) 0x03f03f11, (guint32) 0x03f04f17, (guint32) 0x03f04e17, (guint32) 0x03f03602, (guint32) 0x03f05817, (guint32) 0x03f01d17, (guint32) 0x03f03c11, (guint32) 0x03f07904, (guint32) 0x03f04d11, (guint32) 0x03f0072a, (guint32) 0x03f01417, (guint32) 0x03f04c11, (guint32) 0x03f0c111, (guint32) 0x03f04417, (guint32) 0x03f05017, (guint32) 0x03f0022a, (guint32) 0x03f0012a, (guint32) 0x03f0092a, (guint32) 0x03f07f11, (guint32) 0x03f04811, (guint32) 0x03f03a17, (guint32) 0x03f00a2a, (guint32) 0x03f00312, (guint32) 0x03f09411, (guint32) 0x03f09b11, (guint32) 0x03f03917, (guint32) 0x03f04a17, (guint32) 0x03f03817, (guint32) 0x03f0b911, (guint32) 0x03f05417, (guint32) 0x03f05217, (guint32) 0x03f05317, (guint32) 0x03f05d17, (guint32) 0x03f08711, (guint32) 0x03f05c17, (guint32) 0x03f09a11, (guint32) 0x03f02811, (guint32) 0x03f07d04, (guint32) 0x03f02a11, (guint32) 0x03f02b11, (guint32) 0x03f00217, (guint32) 0x03f02911, (guint32) 0x03f02404, (guint32) 0x03f03511, (guint32) 0x03f00812, (guint32) 0x03f00b17, (guint32) 0x03f0c302, (guint32) 0x03f05917, (guint32) 0x03f05a17, (guint32) 0x03f05b17, (guint32) 0x03f04911, (guint32) 0x03f03611, (guint32) 0x03f07611, (guint32) 0x03f07a04, (guint32) 0x03f02517, (guint32) 0x03f02917, (guint32) 0x03f02a17, (guint32) 0x03f01e04, (guint32) 0x03f00717, (guint32) 0x03f02504, (guint32) 0x03f03711, (guint32) 0x03f0ac11, (guint32) 0x03f0be11, (guint32) 0x03f0c211, (guint32) 0x03f01c17, (guint32) 0x03f04e11, (guint32) 0x03f02e17, (guint32) 0x03f04511, (guint32) 0x03f08011, (guint32) 0x03f00412, (guint32) 0x03f03617, (guint32) 0x03f02f17, (guint32) 0x03f03117, (guint32) 0x03f0c911, (guint32) 0x03f0ca11, (guint32) 0x03f04611, (guint32) 0x03f03c17, (guint32) 0x03f03717, (guint32) 0x03f02617, (guint32) 0x03f01112, (guint32) 0x03f00612, (guint32) 0x03f06717, (guint32) 0x03f09511, (guint32) 0x03f07617, (guint32) 0x03f07317, (guint32) 0x03f08d17, (guint32) 0x03f01617, (guint32) 0x03f07a17, (guint32) 0x03f07517, (guint32) 0x03f09311, (guint32) 0x03f0a011, (guint32) 0x03f03317, (guint32) 0x03f03417, (guint32) 0x03f0a211, (guint32) 0x03f05611, (guint32) 0x03f05011, (guint32) 0x03f00117, (guint32) 0x03f05111, (guint32) 0x03f00817, (guint32) 0x03f05211, (guint32) 0x03f07004, (guint32) 0x03f00917, (guint32) 0x03f01917, (guint32) 0x03f03517, (guint32) 0x03f07104, (guint32) 0x03f01517, (guint32) 0x03f03112, (guint32) 0x03f07817, (guint32) 0x03f0ad11, (guint32) 0x03f0b011, (guint32) 0x03f08517, (guint32) 0x03f08a17, (guint32) 0x03f0c711, (guint32) 0x03f06117, (guint32) 0x03f06917, (guint32) 0x03f06812, (guint32) 0x03f06d12, (guint32) 0x03f07204, (guint32) 0x03f00a17, (guint32) 0x03f07404, (guint32) 0x03f06817, (guint32) 0x03f01b04, (guint32) 0x03f01a04, (guint32) 0x03f01c04, (guint32) 0x03f01904, (guint32) 0x03f07504, (guint32) 0x03f07604, (guint32) 0x03f00714, (guint32) 0x03f09c11, (guint32) 0x03f07b17, (guint32) 0x03f08817, (guint32) 0x03f05711, (guint32) 0x03f07704, (guint32) 0x03f07e04, (guint32) 0x03f03111, (guint32) 0x03f06017, (guint32) 0x03f03d11, (guint32) 0x03f05c11, (guint32) 0x03f07b04, (guint32) 0x03f06a17, (guint32) 0x03f02417, (guint32) 0x03f05411, (guint32) 0x03f01f04, (guint32) 0x03f06711, (guint32) 0x03f07417, (guint32) 0x03f09717, (guint32) 0x03f02317, (guint32) 0x03f06611, (guint32) 0x03f06c11, (guint32) 0x03f09d11, (guint32) 0x03f07711, (guint32) 0x03f04712, (guint32) 0x03f08c11, (guint32) 0x03f05712, (guint32) 0x03f02a12, (guint32) 0x03f06b11, (guint32) 0x03f0c511, (guint32) 0x03f02e12, (guint32) 0x03f0c411, (guint32) 0x03f09917, (guint32) 0x03f09c17, (guint32) 0x03f07411, (guint32) 0x03f06c17, (guint32) 0x03f05812, (guint32) 0x03f06512, (guint32) 0x03f06612, (guint32) 0x03f06412, (guint32) 0x03f0c611, (guint32) 0x03f0c811, (guint32) 0x03f01a17, (guint32) 0x03f02b12, (guint32) 0x03f02c12, (guint32) 0x03f07511, (guint32) 0x03f06217, (guint32) 0x03f07d17, (guint32) 0x03f06317, (guint32) 0x03f07917, (guint32) 0x03f07217, (guint32) 0x03f0a117, (guint32) 0x03f0c802, (guint32) 0x03f05811, (guint32) 0x03f0c402, (guint32) 0x03f02411, (guint32) 0x03f05d11, (guint32) 0x03f06417, (guint32) 0x03f06617, (guint32) 0x03f08917, (guint32) 0x03f05117, (guint32) 0x03f07111, (guint32) 0x03f01f12, (guint32) 0x03f06811, (guint32) 0x03f02012, (guint32) 0x03f08604, (guint32) 0x03f06d11, (guint32) 0x03f03a11, (guint32) 0x03f03012, (guint32) 0x03f08211, (guint32) 0x03f07211, (guint32) 0x03f0a111, (guint32) 0x03f0b411, (guint32) 0x03f09b17, (guint32) 0x03f0b111, (guint32) 0x03f0b611, (guint32) 0x03f0c311, (guint32) 0x03f01f17, (guint32) 0x03f06004, (guint32) 0x03f04f11, (guint32) 0x03f0cc11, (guint32) 0x03f06104, (guint32) 0x03f05b11, (guint32) 0x03f08104, (guint32) 0x03f0cd11, (guint32) 0x03f0a004, (guint32) 0x03f08704, (guint32) 0x03f04312, (guint32) 0x03f04212, (guint32) 0x03f06f17, (guint32) 0x03f07c17, (guint32) 0x03f09517, (guint32) 0x03f05911, (guint32) 0x03f05e12, (guint32) 0x03f00b14, (guint32) 0x03f0c502, (guint32) 0x03f02d11, (guint32) 0x03f03404, (guint32) 0x03f04b11, (guint32) 0x03f01014, (guint32) 0x03f06a11, (guint32) 0x03f07312, (guint32) 0x03f07011, (guint32) 0x03f05311, (guint32) 0x03f03312, (guint32) 0x03f04412, (guint32) 0x03f05412, (guint32) 0x03f05512, (guint32) 0x03f04512, (guint32) 0x03f08204, (guint32) 0x03f0a511, (guint32) 0x03f0af11, (guint32) 0x03f0ba11, (guint32) 0x03f08504, (guint32) 0x03f05d12, (guint32) 0x03f05c12, (guint32) 0x03f08404, (guint32) 0x03f07412, (guint32) 0x03f07212, (guint32) 0x03f08804, (guint32) 0x03f04612, (guint32) 0x03f02611, (guint32) 0x03f05a11, (guint32) 0x03f02612, (guint32) 0x03f0c602, (guint32) 0x03f06012, (guint32) 0x03f03a02, (guint32) 0x03f06911, (guint32) 0x03f0b002, (guint32) 0x03f04111, (guint32) 0x03f06511, (guint32) 0x03f04211, (guint32) 0x03f02512, (guint32) 0x03f0c702, (guint32) 0x03f02002, (guint32) 0x03f03c02, (guint32) 0x03f04311, (guint32) 0x03f0b802, (guint32) 0x03f05e11, (guint32) 0x03f03412, (guint32) 0x03f02112, (guint32) 0x03f04812, (guint32) 0x03f06f11, (guint32) 0x03f0a611, (guint32) 0x03f0bc11, (guint32) 0x03f03e02, (guint32) 0x03f02212, (guint32) 0x03f0b202, (guint32) 0x03f06e12, (guint32) 0x03f0dc11, (guint32) 0x03f02312, (guint32) 0x03f0b402, (guint32) 0x03f0c002, (guint32) 0x03f0b602, (guint32) 0x03f05612, (guint32) 0x03f03612, (guint32) 0x03f0c102, (guint32) 0x03f0de11, (guint32) 0x03f07717, (guint32) 0x03f07117, (guint32) 0x03f05b12, (guint32) 0x03f06411, (guint32) 0x03f0ba02, (guint32) 0x03f0c202, (guint32) 0x03f0be02, (guint32) 0x03f0bb02, (guint32) 0x03f03812, (guint32) 0x03f04012, (guint32) 0x03f03912, (guint32) 0x03f0d102, (guint32) 0x03f05312, (guint32) 0x03f02712, (guint32) 0x03f05912, (guint32) 0x03f07112, (guint32) 0x03f07012, (guint32) 0x03f06f12, (guint32) 0x03f07712, (guint32) 0x03f07612, (guint32) 0x03f0bc02, (guint32) 0x03f0d002, (guint32) 0x03f08417, (guint32) 0x03f02017, (guint32) 0x03f02117, (guint32) 0x03f08317, (guint32) 0x03f09617, (guint32) 0x03f00d12, (guint32) 0x03f0bd02, (guint32) 0x03f02217, (guint32) 0x03f00b12, (guint32) 0x03f01212, (guint32) 0x03f03c2a, (guint32) 0x03f0382a, (guint32) 0x03f0582a, (guint32) 0x03f0552a, (guint32) 0x03f03e2a, (guint32) 0x03f03f2a, (guint32) 0x03f0e311, (guint32) 0x03f0e111}; -static const guint32 SIMPLE_SCAN_epkowa_devices[201] = {(guint32) 0x04b80101, (guint32) 0x04b80102, (guint32) 0x04b80103, (guint32) 0x04b80104, (guint32) 0x04b80105, (guint32) 0x04b80106, (guint32) 0x04b80107, (guint32) 0x04b80108, (guint32) 0x04b80109, (guint32) 0x04b8010a, (guint32) 0x04b8010b, (guint32) 0x04b8010c, (guint32) 0x04b8010d, (guint32) 0x04b8010e, (guint32) 0x04b8010f, (guint32) 0x04b80110, (guint32) 0x04b80112, (guint32) 0x04b80114, (guint32) 0x04b80116, (guint32) 0x04b80118, (guint32) 0x04b80119, (guint32) 0x04b8011a, (guint32) 0x04b8011b, (guint32) 0x04b8011c, (guint32) 0x04b8011d, (guint32) 0x04b8011e, (guint32) 0x04b8011f, (guint32) 0x04b80120, (guint32) 0x04b80121, (guint32) 0x04b80122, (guint32) 0x04b80126, (guint32) 0x04b80128, (guint32) 0x04b80129, (guint32) 0x04b8012a, (guint32) 0x04b8012b, (guint32) 0x04b8012c, (guint32) 0x04b8012d, (guint32) 0x04b8012e, (guint32) 0x04b8012f, (guint32) 0x04b80130, (guint32) 0x04b80131, (guint32) 0x04b80133, (guint32) 0x04b80135, (guint32) 0x04b80136, (guint32) 0x04b80137, (guint32) 0x04b80138, (guint32) 0x04b8013a, (guint32) 0x04b8013b, (guint32) 0x04b8013c, (guint32) 0x04b8013d, (guint32) 0x04b80142, (guint32) 0x04b80143, (guint32) 0x04b80144, (guint32) 0x04b80147, (guint32) 0x04b8014a, (guint32) 0x04b8014b, (guint32) 0x04b80151, (guint32) 0x04b80153, (guint32) 0x04b80801, (guint32) 0x04b80802, (guint32) 0x04b80805, (guint32) 0x04b80806, (guint32) 0x04b80807, (guint32) 0x04b80808, (guint32) 0x04b8080a, (guint32) 0x04b8080c, (guint32) 0x04b8080d, (guint32) 0x04b8080e, (guint32) 0x04b8080f, (guint32) 0x04b80810, (guint32) 0x04b80811, (guint32) 0x04b80813, (guint32) 0x04b80814, (guint32) 0x04b80815, (guint32) 0x04b80817, (guint32) 0x04b80818, (guint32) 0x04b80819, (guint32) 0x04b8081a, (guint32) 0x04b8081c, (guint32) 0x04b8081d, (guint32) 0x04b8081f, (guint32) 0x04b80820, (guint32) 0x04b80821, (guint32) 0x04b80827, (guint32) 0x04b80828, (guint32) 0x04b80829, (guint32) 0x04b8082a, (guint32) 0x04b8082b, (guint32) 0x04b8082e, (guint32) 0x04b8082f, (guint32) 0x04b80830, (guint32) 0x04b80831, (guint32) 0x04b80833, (guint32) 0x04b80834, (guint32) 0x04b80835, (guint32) 0x04b80836, (guint32) 0x04b80837, (guint32) 0x04b80838, (guint32) 0x04b80839, (guint32) 0x04b8083a, (guint32) 0x04b8083c, (guint32) 0x04b8083f, (guint32) 0x04b80841, (guint32) 0x04b80843, (guint32) 0x04b80844, (guint32) 0x04b80846, (guint32) 0x04b80847, (guint32) 0x04b80848, (guint32) 0x04b80849, (guint32) 0x04b8084a, (guint32) 0x04b8084c, (guint32) 0x04b8084d, (guint32) 0x04b8084f, (guint32) 0x04b80850, (guint32) 0x04b80851, (guint32) 0x04b80852, (guint32) 0x04b80853, (guint32) 0x04b80854, (guint32) 0x04b80855, (guint32) 0x04b80856, (guint32) 0x04b8085c, (guint32) 0x04b8085d, (guint32) 0x04b8085e, (guint32) 0x04b8085f, (guint32) 0x04b80860, (guint32) 0x04b80861, (guint32) 0x04b80862, (guint32) 0x04b80863, (guint32) 0x04b80864, (guint32) 0x04b80865, (guint32) 0x04b80866, (guint32) 0x04b80869, (guint32) 0x04b8086a, (guint32) 0x04b80870, (guint32) 0x04b80871, (guint32) 0x04b80872, (guint32) 0x04b80873, (guint32) 0x04b80878, (guint32) 0x04b80879, (guint32) 0x04b8087b, (guint32) 0x04b8087c, (guint32) 0x04b8087d, (guint32) 0x04b8087e, (guint32) 0x04b8087f, (guint32) 0x04b80880, (guint32) 0x04b80881, (guint32) 0x04b80883, (guint32) 0x04b80884, (guint32) 0x04b80885, (guint32) 0x04b8088f, (guint32) 0x04b80890, (guint32) 0x04b80891, (guint32) 0x04b80892, (guint32) 0x04b80893, (guint32) 0x04b80894, (guint32) 0x04b80895, (guint32) 0x04b80896, (guint32) 0x04b80897, (guint32) 0x04b80898, (guint32) 0x04b80899, (guint32) 0x04b8089a, (guint32) 0x04b8089b, (guint32) 0x04b8089c, (guint32) 0x04b8089d, (guint32) 0x04b8089e, (guint32) 0x04b8089f, (guint32) 0x04b808a0, (guint32) 0x04b808a1, (guint32) 0x04b808a5, (guint32) 0x04b808a6, (guint32) 0x04b808a8, (guint32) 0x04b808a9, (guint32) 0x04b808aa, (guint32) 0x04b808ab, (guint32) 0x04b808ac, (guint32) 0x04b808ad, (guint32) 0x04b808ae, (guint32) 0x04b808af, (guint32) 0x04b808b0, (guint32) 0x04b808b3, (guint32) 0x04b808b4, (guint32) 0x04b808b5, (guint32) 0x04b808b6, (guint32) 0x04b808b7, (guint32) 0x04b808b8, (guint32) 0x04b808b9, (guint32) 0x04b808bd, (guint32) 0x04b808be, (guint32) 0x04b808bf, (guint32) 0x04b808c0, (guint32) 0x04b808c1, (guint32) 0x04b808c3, (guint32) 0x04b808c4, (guint32) 0x04b808c5, (guint32) 0x04b808c6, (guint32) 0x04b808c7, (guint32) 0x04b808c8, (guint32) 0x04b808c9, (guint32) 0x04b808ca, (guint32) 0x04b808cd, (guint32) 0x04b808d0}; - -static gpointer _scan_device_ref0 (gpointer self) { -#line 41 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - return self ? scan_device_ref (self) : NULL; -#line 417 "simple-scan.c" -} - - -SimpleScan* simple_scan_construct (GType object_type, ScanDevice* device) { - SimpleScan * self = NULL; - ScanDevice* _tmp0_ = NULL; - ScanDevice* _tmp1_ = NULL; -#line 39 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - self = (SimpleScan*) g_object_new (object_type, NULL); -#line 41 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp0_ = device; -#line 41 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp1_ = _scan_device_ref0 (_tmp0_); -#line 41 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _scan_device_unref0 (self->priv->default_device); -#line 41 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - self->priv->default_device = _tmp1_; -#line 39 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - return self; -#line 437 "simple-scan.c" -} - - -SimpleScan* simple_scan_new (ScanDevice* device) { -#line 39 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - return simple_scan_construct (TYPE_SIMPLE_SCAN, device); -#line 444 "simple-scan.c" -} - - -static gpointer _book_ref0 (gpointer self) { -#line 49 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - return self ? book_ref (self) : NULL; -#line 451 "simple-scan.c" -} - - -static void _simple_scan_scan_cb_user_interface_start_scan (UserInterface* _sender, const gchar* device, ScanOptions* options, gpointer self) { -#line 50 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - simple_scan_scan_cb ((SimpleScan*) self, _sender, device, options); -#line 458 "simple-scan.c" -} - - -static void _simple_scan_cancel_cb_user_interface_stop_scan (UserInterface* _sender, gpointer self) { -#line 51 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - simple_scan_cancel_cb ((SimpleScan*) self, _sender); -#line 465 "simple-scan.c" -} - - -static void _simple_scan_email_cb_user_interface_email (UserInterface* _sender, const gchar* profile, gint quality, gpointer self) { -#line 52 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - simple_scan_email_cb ((SimpleScan*) self, _sender, profile, quality); -#line 472 "simple-scan.c" -} - - -static void _simple_scan_update_scan_devices_cb_scanner_update_devices (Scanner* _sender, GList* devices, gpointer self) { -#line 55 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - simple_scan_update_scan_devices_cb ((SimpleScan*) self, _sender, devices); -#line 479 "simple-scan.c" -} - - -static void _simple_scan_authorize_cb_scanner_request_authorization (Scanner* _sender, const gchar* resource, gpointer self) { -#line 56 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - simple_scan_authorize_cb ((SimpleScan*) self, _sender, resource); -#line 486 "simple-scan.c" -} - - -static void _simple_scan_scanner_new_page_cb_scanner_expect_page (Scanner* _sender, gpointer self) { -#line 57 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - simple_scan_scanner_new_page_cb ((SimpleScan*) self, _sender); -#line 493 "simple-scan.c" -} - - -static void _simple_scan_scanner_page_info_cb_scanner_got_page_info (Scanner* _sender, ScanPageInfo* info, gpointer self) { -#line 58 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - simple_scan_scanner_page_info_cb ((SimpleScan*) self, _sender, info); -#line 500 "simple-scan.c" -} - - -static void _simple_scan_scanner_line_cb_scanner_got_line (Scanner* _sender, ScanLine* line, gpointer self) { -#line 59 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - simple_scan_scanner_line_cb ((SimpleScan*) self, _sender, line); -#line 507 "simple-scan.c" -} - - -static void _simple_scan_scanner_page_done_cb_scanner_page_done (Scanner* _sender, gpointer self) { -#line 60 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - simple_scan_scanner_page_done_cb ((SimpleScan*) self, _sender); -#line 514 "simple-scan.c" -} - - -static void _simple_scan_scanner_document_done_cb_scanner_document_done (Scanner* _sender, gpointer self) { -#line 61 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - simple_scan_scanner_document_done_cb ((SimpleScan*) self, _sender); -#line 521 "simple-scan.c" -} - - -static void _simple_scan_scanner_failed_cb_scanner_scan_failed (Scanner* _sender, gint error_code, const gchar* error_string, gpointer self) { -#line 62 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - simple_scan_scanner_failed_cb ((SimpleScan*) self, _sender, error_code, error_string); -#line 528 "simple-scan.c" -} - - -static void _simple_scan_scanner_scanning_changed_cb_scanner_scanning_changed (Scanner* _sender, gpointer self) { -#line 63 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - simple_scan_scanner_scanning_changed_cb ((SimpleScan*) self, _sender); -#line 535 "simple-scan.c" -} - - -static void ___lambda22_ (SimpleScan* self) { - Scanner* _tmp0_ = NULL; -#line 68 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp0_ = self->priv->scanner; -#line 68 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - scanner_redetect (_tmp0_); -#line 545 "simple-scan.c" -} - - -static void ____lambda22__g_usb_context_device_added (GUsbContext* _sender, GUsbDevice* device, gpointer self) { -#line 68 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - ___lambda22_ ((SimpleScan*) self); -#line 552 "simple-scan.c" -} - - -static void ___lambda23_ (SimpleScan* self) { - Scanner* _tmp0_ = NULL; -#line 69 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp0_ = self->priv->scanner; -#line 69 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - scanner_redetect (_tmp0_); -#line 562 "simple-scan.c" -} - - -static void ____lambda23__g_usb_context_device_removed (GUsbContext* _sender, GUsbDevice* device, gpointer self) { -#line 69 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - ___lambda23_ ((SimpleScan*) self); -#line 569 "simple-scan.c" -} - - -static void _scan_device_unref0_ (gpointer var) { -#line 76 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - (var == NULL) ? NULL : (var = (scan_device_unref (var), NULL)); -#line 576 "simple-scan.c" -} - - -static void _g_list_free__scan_device_unref0_ (GList* self) { -#line 76 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - g_list_foreach (self, (GFunc) _scan_device_unref0_, NULL); -#line 76 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - g_list_free (self); -#line 585 "simple-scan.c" -} - - -static void simple_scan_real_startup (GApplication* base) { - SimpleScan * self; - UserInterface* _tmp0_ = NULL; - UserInterface* _tmp1_ = NULL; - Book* _tmp2_ = NULL; - Book* _tmp3_ = NULL; - Book* _tmp4_ = NULL; - UserInterface* _tmp5_ = NULL; - UserInterface* _tmp6_ = NULL; - UserInterface* _tmp7_ = NULL; - Scanner* _tmp8_ = NULL; - Scanner* _tmp9_ = NULL; - Scanner* _tmp10_ = NULL; - Scanner* _tmp11_ = NULL; - Scanner* _tmp12_ = NULL; - Scanner* _tmp13_ = NULL; - Scanner* _tmp14_ = NULL; - Scanner* _tmp15_ = NULL; - Scanner* _tmp16_ = NULL; - Scanner* _tmp17_ = NULL; - ScanDevice* _tmp25_ = NULL; - GError * _inner_error_ = NULL; -#line 44 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - self = (SimpleScan*) base; -#line 46 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - G_APPLICATION_CLASS (simple_scan_parent_class)->startup ((GApplication*) G_TYPE_CHECK_INSTANCE_CAST (self, gtk_application_get_type (), GtkApplication)); -#line 48 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp0_ = user_interface_new (); -#line 48 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - g_object_ref_sink (_tmp0_); -#line 48 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _g_object_unref0 (self->priv->ui); -#line 48 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - self->priv->ui = _tmp0_; -#line 49 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp1_ = self->priv->ui; -#line 49 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp2_ = user_interface_get_book (_tmp1_); -#line 49 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp3_ = _tmp2_; -#line 49 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp4_ = _book_ref0 (_tmp3_); -#line 49 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _book_unref0 (self->priv->book); -#line 49 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - self->priv->book = _tmp4_; -#line 50 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp5_ = self->priv->ui; -#line 50 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - g_signal_connect_object (_tmp5_, "start-scan", (GCallback) _simple_scan_scan_cb_user_interface_start_scan, self, 0); -#line 51 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp6_ = self->priv->ui; -#line 51 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - g_signal_connect_object (_tmp6_, "stop-scan", (GCallback) _simple_scan_cancel_cb_user_interface_stop_scan, self, 0); -#line 52 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp7_ = self->priv->ui; -#line 52 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - g_signal_connect_object (_tmp7_, "email", (GCallback) _simple_scan_email_cb_user_interface_email, self, 0); -#line 54 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp8_ = scanner_get_instance (); -#line 54 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _scanner_unref0 (self->priv->scanner); -#line 54 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - self->priv->scanner = _tmp8_; -#line 55 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp9_ = self->priv->scanner; -#line 55 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - g_signal_connect_object (_tmp9_, "update-devices", (GCallback) _simple_scan_update_scan_devices_cb_scanner_update_devices, self, 0); -#line 56 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp10_ = self->priv->scanner; -#line 56 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - g_signal_connect_object (_tmp10_, "request-authorization", (GCallback) _simple_scan_authorize_cb_scanner_request_authorization, self, 0); -#line 57 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp11_ = self->priv->scanner; -#line 57 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - g_signal_connect_object (_tmp11_, "expect-page", (GCallback) _simple_scan_scanner_new_page_cb_scanner_expect_page, self, 0); -#line 58 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp12_ = self->priv->scanner; -#line 58 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - g_signal_connect_object (_tmp12_, "got-page-info", (GCallback) _simple_scan_scanner_page_info_cb_scanner_got_page_info, self, 0); -#line 59 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp13_ = self->priv->scanner; -#line 59 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - g_signal_connect_object (_tmp13_, "got-line", (GCallback) _simple_scan_scanner_line_cb_scanner_got_line, self, 0); -#line 60 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp14_ = self->priv->scanner; -#line 60 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - g_signal_connect_object (_tmp14_, "page-done", (GCallback) _simple_scan_scanner_page_done_cb_scanner_page_done, self, 0); -#line 61 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp15_ = self->priv->scanner; -#line 61 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - g_signal_connect_object (_tmp15_, "document-done", (GCallback) _simple_scan_scanner_document_done_cb_scanner_document_done, self, 0); -#line 62 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp16_ = self->priv->scanner; -#line 62 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - g_signal_connect_object (_tmp16_, "scan-failed", (GCallback) _simple_scan_scanner_failed_cb_scanner_scan_failed, self, 0); -#line 63 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp17_ = self->priv->scanner; -#line 63 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - g_signal_connect_object (_tmp17_, "scanning-changed", (GCallback) _simple_scan_scanner_scanning_changed_cb_scanner_scanning_changed, self, 0); -#line 689 "simple-scan.c" - { - GUsbContext* _tmp18_ = NULL; - GUsbContext* _tmp19_ = NULL; - GUsbContext* _tmp20_ = NULL; - GUsbContext* _tmp21_ = NULL; - GUsbContext* _tmp22_ = NULL; -#line 67 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp19_ = g_usb_context_new (&_inner_error_); -#line 67 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp18_ = _tmp19_; -#line 67 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - if (G_UNLIKELY (_inner_error_ != NULL)) { -#line 702 "simple-scan.c" - goto __catch4_g_error; - } -#line 67 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp20_ = _tmp18_; -#line 67 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp18_ = NULL; -#line 67 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _g_object_unref0 (self->priv->usb_context); -#line 67 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - self->priv->usb_context = _tmp20_; -#line 68 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp21_ = self->priv->usb_context; -#line 68 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - g_signal_connect_object (_tmp21_, "device-added", (GCallback) ____lambda22__g_usb_context_device_added, self, 0); -#line 69 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp22_ = self->priv->usb_context; -#line 69 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - g_signal_connect_object (_tmp22_, "device-removed", (GCallback) ____lambda23__g_usb_context_device_removed, self, 0); -#line 65 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _g_object_unref0 (_tmp18_); -#line 723 "simple-scan.c" - } - goto __finally4; - __catch4_g_error: - { - GError* e = NULL; - GError* _tmp23_ = NULL; - const gchar* _tmp24_ = NULL; -#line 65 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - e = _inner_error_; -#line 65 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _inner_error_ = NULL; -#line 73 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp23_ = e; -#line 73 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp24_ = _tmp23_->message; -#line 73 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - g_warning ("simple-scan.vala:73: Failed to create USB context: %s\n", _tmp24_); -#line 65 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _g_error_free0 (e); -#line 743 "simple-scan.c" - } - __finally4: -#line 65 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - if (G_UNLIKELY (_inner_error_ != NULL)) { -#line 65 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - g_critical ("file %s: line %d: uncaught error: %s (%s, %d)", __FILE__, __LINE__, _inner_error_->message, g_quark_to_string (_inner_error_->domain), _inner_error_->code); -#line 65 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - g_clear_error (&_inner_error_); -#line 65 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - return; -#line 754 "simple-scan.c" - } -#line 76 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp25_ = self->priv->default_device; -#line 76 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - if (_tmp25_ != NULL) { -#line 760 "simple-scan.c" - GList* device_list = NULL; - ScanDevice* _tmp26_ = NULL; - ScanDevice* _tmp27_ = NULL; - UserInterface* _tmp28_ = NULL; - GList* _tmp29_ = NULL; - UserInterface* _tmp30_ = NULL; - ScanDevice* _tmp31_ = NULL; - const gchar* _tmp32_ = NULL; -#line 78 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - device_list = NULL; -#line 80 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp26_ = self->priv->default_device; -#line 80 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp27_ = _scan_device_ref0 (_tmp26_); -#line 80 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - device_list = g_list_append (device_list, _tmp27_); -#line 81 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp28_ = self->priv->ui; -#line 81 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp29_ = device_list; -#line 81 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - user_interface_set_scan_devices (_tmp28_, _tmp29_, NULL); -#line 82 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp30_ = self->priv->ui; -#line 82 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp31_ = self->priv->default_device; -#line 82 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp32_ = _tmp31_->name; -#line 82 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - user_interface_set_selected_device (_tmp30_, _tmp32_); -#line 76 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - __g_list_free__scan_device_unref0_0 (device_list); -#line 793 "simple-scan.c" - } -} - - -static void simple_scan_real_activate (GApplication* base) { - SimpleScan * self; - UserInterface* _tmp0_ = NULL; - Scanner* _tmp1_ = NULL; -#line 86 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - self = (SimpleScan*) base; -#line 88 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - G_APPLICATION_CLASS (simple_scan_parent_class)->activate ((GApplication*) G_TYPE_CHECK_INSTANCE_CAST (self, gtk_application_get_type (), GtkApplication)); -#line 89 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp0_ = self->priv->ui; -#line 89 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - user_interface_start (_tmp0_); -#line 90 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp1_ = self->priv->scanner; -#line 90 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - scanner_start (_tmp1_); -#line 814 "simple-scan.c" -} - - -static void simple_scan_real_shutdown (GApplication* base) { - SimpleScan * self; - Scanner* _tmp0_ = NULL; -#line 93 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - self = (SimpleScan*) base; -#line 95 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - G_APPLICATION_CLASS (simple_scan_parent_class)->shutdown ((GApplication*) G_TYPE_CHECK_INSTANCE_CAST (self, gtk_application_get_type (), GtkApplication)); -#line 96 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _book_unref0 (self->priv->book); -#line 96 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - self->priv->book = NULL; -#line 97 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _g_object_unref0 (self->priv->ui); -#line 97 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - self->priv->ui = NULL; -#line 98 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _g_object_unref0 (self->priv->usb_context); -#line 98 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - self->priv->usb_context = NULL; -#line 99 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp0_ = self->priv->scanner; -#line 99 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - scanner_free (_tmp0_); -#line 841 "simple-scan.c" -} - - -static void simple_scan_update_scan_devices_cb (SimpleScan* self, Scanner* scanner, GList* devices) { - GList* devices_copy = NULL; - GList* _tmp0_ = NULL; - GList* _tmp1_ = NULL; - ScanDevice* _tmp2_ = NULL; - GList* _tmp10_ = NULL; - guint _tmp11_ = 0U; - gchar* missing_driver = NULL; - gboolean _tmp12_ = FALSE; - UserInterface* _tmp14_ = NULL; - GList* _tmp15_ = NULL; - const gchar* _tmp16_ = NULL; -#line 102 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - g_return_if_fail (self != NULL); -#line 102 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - g_return_if_fail (scanner != NULL); -#line 104 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp0_ = devices; -#line 104 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp1_ = g_list_copy (_tmp0_); -#line 104 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - devices_copy = _tmp1_; -#line 107 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp2_ = self->priv->default_device; -#line 107 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - if (_tmp2_ != NULL) { -#line 871 "simple-scan.c" - gboolean default_in_list = FALSE; - GList* _tmp3_ = NULL; - gboolean _tmp8_ = FALSE; -#line 109 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - default_in_list = FALSE; -#line 110 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp3_ = devices_copy; -#line 879 "simple-scan.c" - { - GList* device_collection = NULL; - GList* device_it = NULL; -#line 110 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - device_collection = _tmp3_; -#line 110 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - for (device_it = device_collection; device_it != NULL; device_it = device_it->next) { -#line 887 "simple-scan.c" - ScanDevice* device = NULL; -#line 110 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - device = (ScanDevice*) device_it->data; -#line 891 "simple-scan.c" - { - ScanDevice* _tmp4_ = NULL; - const gchar* _tmp5_ = NULL; - ScanDevice* _tmp6_ = NULL; - const gchar* _tmp7_ = NULL; -#line 112 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp4_ = device; -#line 112 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp5_ = _tmp4_->name; -#line 112 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp6_ = self->priv->default_device; -#line 112 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp7_ = _tmp6_->name; -#line 112 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - if (g_strcmp0 (_tmp5_, _tmp7_) == 0) { -#line 114 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - default_in_list = TRUE; -#line 115 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - break; -#line 911 "simple-scan.c" - } - } - } - } -#line 119 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp8_ = default_in_list; -#line 119 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - if (!_tmp8_) { -#line 920 "simple-scan.c" - ScanDevice* _tmp9_ = NULL; -#line 120 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp9_ = self->priv->default_device; -#line 120 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - devices_copy = g_list_prepend (devices_copy, _tmp9_); -#line 926 "simple-scan.c" - } - } -#line 123 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp10_ = devices_copy; -#line 123 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp11_ = g_list_length (_tmp10_); -#line 123 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - self->priv->have_devices = _tmp11_ > ((guint) 0); -#line 126 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - missing_driver = NULL; -#line 127 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp12_ = self->priv->have_devices; -#line 127 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - if (!_tmp12_) { -#line 941 "simple-scan.c" - gchar* _tmp13_ = NULL; -#line 128 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp13_ = simple_scan_suggest_driver (self); -#line 128 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _g_free0 (missing_driver); -#line 128 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - missing_driver = _tmp13_; -#line 949 "simple-scan.c" - } -#line 130 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp14_ = self->priv->ui; -#line 130 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp15_ = devices_copy; -#line 130 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp16_ = missing_driver; -#line 130 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - user_interface_set_scan_devices (_tmp14_, _tmp15_, _tmp16_); -#line 102 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _g_free0 (missing_driver); -#line 102 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _g_list_free0 (devices_copy); -#line 963 "simple-scan.c" -} - - -static void _g_free0_ (gpointer var) { -#line 186 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - var = (g_free (var), NULL); -#line 970 "simple-scan.c" -} - - -static gint g_ptr_array_get_length (GPtrArray* self) { - gint result; - guint _tmp0_ = 0U; -#line 4858 "/usr/share/vala-0.34/vapi/glib-2.0.vapi" - g_return_val_if_fail (self != NULL, 0); -#line 4858 "/usr/share/vala-0.34/vapi/glib-2.0.vapi" - _tmp0_ = self->len; -#line 4858 "/usr/share/vala-0.34/vapi/glib-2.0.vapi" - result = (gint) _tmp0_; -#line 4858 "/usr/share/vala-0.34/vapi/glib-2.0.vapi" - return result; -#line 985 "simple-scan.c" -} - - -static void g_ptr_array_set_length (GPtrArray* self, gint value) { - gint _tmp0_ = 0; -#line 4859 "/usr/share/vala-0.34/vapi/glib-2.0.vapi" - g_return_if_fail (self != NULL); -#line 4859 "/usr/share/vala-0.34/vapi/glib-2.0.vapi" - _tmp0_ = value; -#line 4859 "/usr/share/vala-0.34/vapi/glib-2.0.vapi" - g_ptr_array_set_size (self, _tmp0_); -#line 997 "simple-scan.c" -} - - -static gpointer _g_object_ref0 (gpointer self) { -#line 199 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - return self ? g_object_ref (self) : NULL; -#line 1004 "simple-scan.c" -} - - -gchar* simple_scan_suggest_driver (SimpleScan* self) { - gchar* result = NULL; - GUsbContext* _tmp0_ = NULL; - GHashTable* driver_map = NULL; - GHashFunc _tmp1_ = NULL; - GEqualFunc _tmp2_ = NULL; - GHashTable* _tmp3_ = NULL; - GHashTable* _tmp4_ = NULL; - GHashTable* _tmp5_ = NULL; - GHashTable* _tmp6_ = NULL; - GHashTable* _tmp7_ = NULL; - GHashTable* _tmp8_ = NULL; - GHashTable* _tmp9_ = NULL; - GHashTable* _tmp10_ = NULL; - GPtrArray* devices = NULL; - GUsbContext* _tmp11_ = NULL; - GPtrArray* _tmp12_ = NULL; -#line 181 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - g_return_val_if_fail (self != NULL, NULL); -#line 183 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp0_ = self->priv->usb_context; -#line 183 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - if (_tmp0_ == NULL) { -#line 184 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - result = NULL; -#line 184 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - return result; -#line 1035 "simple-scan.c" - } -#line 186 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp1_ = g_direct_hash; -#line 186 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp2_ = g_direct_equal; -#line 186 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp3_ = g_hash_table_new_full (_tmp1_, _tmp2_, NULL, _g_free0_); -#line 186 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - driver_map = _tmp3_; -#line 187 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp4_ = driver_map; -#line 187 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - simple_scan_add_devices (self, _tmp4_, SIMPLE_SCAN_brscan_devices, G_N_ELEMENTS (SIMPLE_SCAN_brscan_devices), "brscan"); -#line 188 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp5_ = driver_map; -#line 188 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - simple_scan_add_devices (self, _tmp5_, SIMPLE_SCAN_brscan2_devices, G_N_ELEMENTS (SIMPLE_SCAN_brscan2_devices), "brscan2"); -#line 189 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp6_ = driver_map; -#line 189 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - simple_scan_add_devices (self, _tmp6_, SIMPLE_SCAN_brscan3_devices, G_N_ELEMENTS (SIMPLE_SCAN_brscan3_devices), "brscan3"); -#line 190 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp7_ = driver_map; -#line 190 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - simple_scan_add_devices (self, _tmp7_, SIMPLE_SCAN_brscan4_devices, G_N_ELEMENTS (SIMPLE_SCAN_brscan4_devices), "brscan4"); -#line 191 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp8_ = driver_map; -#line 191 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - simple_scan_add_devices (self, _tmp8_, SIMPLE_SCAN_samsung_devices, G_N_ELEMENTS (SIMPLE_SCAN_samsung_devices), "samsung"); -#line 192 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp9_ = driver_map; -#line 192 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - simple_scan_add_devices (self, _tmp9_, SIMPLE_SCAN_hpaio_devices, G_N_ELEMENTS (SIMPLE_SCAN_hpaio_devices), "hpaio"); -#line 193 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp10_ = driver_map; -#line 193 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - simple_scan_add_devices (self, _tmp10_, SIMPLE_SCAN_epkowa_devices, G_N_ELEMENTS (SIMPLE_SCAN_epkowa_devices), "epkowa"); -#line 194 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp11_ = self->priv->usb_context; -#line 194 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp12_ = g_usb_context_get_devices (_tmp11_); -#line 194 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - devices = _tmp12_; -#line 1079 "simple-scan.c" - { - gint i = 0; -#line 197 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - i = 0; -#line 1084 "simple-scan.c" - { - gboolean _tmp13_ = FALSE; -#line 197 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp13_ = TRUE; -#line 197 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - while (TRUE) { -#line 1091 "simple-scan.c" - gint _tmp15_ = 0; - GPtrArray* _tmp16_ = NULL; - gint _tmp17_ = 0; - gint _tmp18_ = 0; - GUsbDevice* device = NULL; - GPtrArray* _tmp19_ = NULL; - gpointer* _tmp20_ = NULL; - gint _tmp20__length1 = 0; - gint _tmp21_ = 0; - GUsbDevice* _tmp22_ = NULL; - GUsbDevice* _tmp23_ = NULL; - gchar* driver = NULL; - GHashTable* _tmp24_ = NULL; - GUsbDevice* _tmp25_ = NULL; - guint16 _tmp26_ = 0U; - GUsbDevice* _tmp27_ = NULL; - guint16 _tmp28_ = 0U; - gconstpointer _tmp29_ = NULL; - gchar* _tmp30_ = NULL; - const gchar* _tmp31_ = NULL; -#line 197 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - if (!_tmp13_) { -#line 1114 "simple-scan.c" - gint _tmp14_ = 0; -#line 197 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp14_ = i; -#line 197 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - i = _tmp14_ + 1; -#line 1120 "simple-scan.c" - } -#line 197 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp13_ = FALSE; -#line 197 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp15_ = i; -#line 197 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp16_ = devices; -#line 197 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp17_ = g_ptr_array_get_length (_tmp16_); -#line 197 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp18_ = _tmp17_; -#line 197 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - if (!(_tmp15_ < _tmp18_)) { -#line 197 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - break; -#line 1136 "simple-scan.c" - } -#line 199 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp19_ = devices; -#line 199 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp20_ = _tmp19_->pdata; -#line 199 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp20__length1 = (gint) _tmp19_->len; -#line 199 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp21_ = i; -#line 199 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp22_ = _tmp20_[_tmp21_]; -#line 199 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp23_ = _g_object_ref0 (_tmp22_); -#line 199 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - device = _tmp23_; -#line 200 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp24_ = driver_map; -#line 200 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp25_ = device; -#line 200 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp26_ = g_usb_device_get_vid (_tmp25_); -#line 200 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp27_ = device; -#line 200 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp28_ = g_usb_device_get_pid (_tmp27_); -#line 200 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp29_ = g_hash_table_lookup (_tmp24_, (gpointer) ((guintptr) ((guint32) ((_tmp26_ << 16) | _tmp28_)))); -#line 200 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp30_ = g_strdup ((const gchar*) _tmp29_); -#line 200 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - driver = _tmp30_; -#line 201 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp31_ = driver; -#line 201 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - if (_tmp31_ != NULL) { -#line 202 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - result = driver; -#line 202 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _g_object_unref0 (device); -#line 202 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _g_ptr_array_unref0 (devices); -#line 202 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _g_hash_table_unref0 (driver_map); -#line 202 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - return result; -#line 1182 "simple-scan.c" - } -#line 197 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _g_free0 (driver); -#line 197 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _g_object_unref0 (device); -#line 1188 "simple-scan.c" - } - } - } -#line 205 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - result = NULL; -#line 205 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _g_ptr_array_unref0 (devices); -#line 205 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _g_hash_table_unref0 (driver_map); -#line 205 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - return result; -#line 1200 "simple-scan.c" -} - - -static void simple_scan_add_devices (SimpleScan* self, GHashTable* map, guint32* devices, int devices_length1, const gchar* driver) { -#line 208 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - g_return_if_fail (self != NULL); -#line 208 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - g_return_if_fail (map != NULL); -#line 208 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - g_return_if_fail (driver != NULL); -#line 1211 "simple-scan.c" - { - gint i = 0; -#line 210 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - i = 0; -#line 1216 "simple-scan.c" - { - gboolean _tmp0_ = FALSE; -#line 210 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp0_ = TRUE; -#line 210 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - while (TRUE) { -#line 1223 "simple-scan.c" - gint _tmp2_ = 0; - guint32* _tmp3_ = NULL; - gint _tmp3__length1 = 0; - GHashTable* _tmp4_ = NULL; - guint32* _tmp5_ = NULL; - gint _tmp5__length1 = 0; - gint _tmp6_ = 0; - guint32 _tmp7_ = 0U; - const gchar* _tmp8_ = NULL; - gchar* _tmp9_ = NULL; -#line 210 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - if (!_tmp0_) { -#line 1236 "simple-scan.c" - gint _tmp1_ = 0; -#line 210 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp1_ = i; -#line 210 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - i = _tmp1_ + 1; -#line 1242 "simple-scan.c" - } -#line 210 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp0_ = FALSE; -#line 210 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp2_ = i; -#line 210 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp3_ = devices; -#line 210 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp3__length1 = devices_length1; -#line 210 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - if (!(_tmp2_ < _tmp3__length1)) { -#line 210 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - break; -#line 1256 "simple-scan.c" - } -#line 211 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp4_ = map; -#line 211 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp5_ = devices; -#line 211 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp5__length1 = devices_length1; -#line 211 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp6_ = i; -#line 211 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp7_ = _tmp5_[_tmp6_]; -#line 211 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp8_ = driver; -#line 211 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp9_ = g_strdup (_tmp8_); -#line 211 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - g_hash_table_insert (_tmp4_, (gpointer) ((guintptr) _tmp7_), _tmp9_); -#line 1274 "simple-scan.c" - } - } - } -} - - -static void simple_scan_authorize_cb (SimpleScan* self, Scanner* scanner, const gchar* resource) { - gchar* username = NULL; - gchar* password = NULL; - UserInterface* _tmp0_ = NULL; - const gchar* _tmp1_ = NULL; - gchar* _tmp2_ = NULL; - gchar* _tmp3_ = NULL; - Scanner* _tmp4_ = NULL; -#line 214 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - g_return_if_fail (self != NULL); -#line 214 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - g_return_if_fail (scanner != NULL); -#line 214 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - g_return_if_fail (resource != NULL); -#line 217 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp0_ = self->priv->ui; -#line 217 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp1_ = resource; -#line 217 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - user_interface_authorize (_tmp0_, _tmp1_, &_tmp2_, &_tmp3_); -#line 217 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _g_free0 (username); -#line 217 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - username = _tmp2_; -#line 217 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _g_free0 (password); -#line 217 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - password = _tmp3_; -#line 218 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp4_ = scanner; -#line 218 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - scanner_authorize (_tmp4_, username, password); -#line 214 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _g_free0 (password); -#line 214 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _g_free0 (username); -#line 1317 "simple-scan.c" -} - - -static Page* simple_scan_append_page (SimpleScan* self) { - Page* result = NULL; - Page* page = NULL; - Book* _tmp0_ = NULL; - Page* _tmp1_ = NULL; - gboolean _tmp2_ = FALSE; - Page* _tmp3_ = NULL; - ScanDirection scan_direction = 0; - gboolean do_crop = FALSE; - gchar* named_crop = NULL; - gint width = 0; - gint height = 0; - gint dpi = 0; - gint cx = 0; - gint cy = 0; - gint cw = 0; - gint ch = 0; - Page* _tmp10_ = NULL; - gint _tmp43_ = 0; - gint _tmp44_ = 0; - gint _tmp45_ = 0; - ScanDirection _tmp46_ = 0; - Page* _tmp47_ = NULL; - Book* _tmp48_ = NULL; - Page* _tmp49_ = NULL; - gboolean _tmp50_ = FALSE; - UserInterface* _tmp60_ = NULL; - Page* _tmp61_ = NULL; - Page* _tmp62_ = NULL; -#line 221 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - g_return_val_if_fail (self != NULL, NULL); -#line 224 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp0_ = self->priv->book; -#line 224 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp1_ = book_get_page (_tmp0_, -1); -#line 224 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - page = _tmp1_; -#line 225 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp3_ = page; -#line 225 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - if (_tmp3_ != NULL) { -#line 1362 "simple-scan.c" - Page* _tmp4_ = NULL; - gboolean _tmp5_ = FALSE; - gboolean _tmp6_ = FALSE; -#line 225 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp4_ = page; -#line 225 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp5_ = page_get_has_data (_tmp4_); -#line 225 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp6_ = _tmp5_; -#line 225 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp2_ = !_tmp6_; -#line 1374 "simple-scan.c" - } else { -#line 225 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp2_ = FALSE; -#line 1378 "simple-scan.c" - } -#line 225 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - if (_tmp2_) { -#line 1382 "simple-scan.c" - UserInterface* _tmp7_ = NULL; - Page* _tmp8_ = NULL; - Page* _tmp9_ = NULL; -#line 227 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp7_ = self->priv->ui; -#line 227 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp8_ = page; -#line 227 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - user_interface_set_selected_page (_tmp7_, _tmp8_); -#line 228 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp9_ = page; -#line 228 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - page_start (_tmp9_); -#line 229 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - result = page; -#line 229 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - return result; -#line 1400 "simple-scan.c" - } -#line 233 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - scan_direction = SCAN_DIRECTION_TOP_TO_BOTTOM; -#line 234 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - do_crop = FALSE; -#line 235 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - named_crop = NULL; -#line 236 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - width = 100; -#line 236 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - height = 100; -#line 236 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - dpi = 100; -#line 236 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - cx = 0; -#line 236 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - cy = 0; -#line 236 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - cw = 0; -#line 236 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - ch = 0; -#line 237 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp10_ = page; -#line 237 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - if (_tmp10_ != NULL) { -#line 1426 "simple-scan.c" - Page* _tmp11_ = NULL; - ScanDirection _tmp12_ = 0; - ScanDirection _tmp13_ = 0; - Page* _tmp14_ = NULL; - gint _tmp15_ = 0; - gint _tmp16_ = 0; - Page* _tmp17_ = NULL; - gint _tmp18_ = 0; - gint _tmp19_ = 0; - Page* _tmp20_ = NULL; - gint _tmp21_ = 0; - gint _tmp22_ = 0; - Page* _tmp23_ = NULL; - gboolean _tmp24_ = FALSE; - gboolean _tmp25_ = FALSE; - gboolean _tmp26_ = FALSE; -#line 239 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp11_ = page; -#line 239 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp12_ = page_get_scan_direction (_tmp11_); -#line 239 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp13_ = _tmp12_; -#line 239 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - scan_direction = _tmp13_; -#line 240 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp14_ = page; -#line 240 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp15_ = page_get_width (_tmp14_); -#line 240 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp16_ = _tmp15_; -#line 240 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - width = _tmp16_; -#line 241 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp17_ = page; -#line 241 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp18_ = page_get_height (_tmp17_); -#line 241 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp19_ = _tmp18_; -#line 241 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - height = _tmp19_; -#line 242 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp20_ = page; -#line 242 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp21_ = page_get_dpi (_tmp20_); -#line 242 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp22_ = _tmp21_; -#line 242 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - dpi = _tmp22_; -#line 244 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp23_ = page; -#line 244 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp24_ = page_get_has_crop (_tmp23_); -#line 244 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp25_ = _tmp24_; -#line 244 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - do_crop = _tmp25_; -#line 245 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp26_ = do_crop; -#line 245 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - if (_tmp26_) { -#line 1487 "simple-scan.c" - Page* _tmp27_ = NULL; - const gchar* _tmp28_ = NULL; - const gchar* _tmp29_ = NULL; - gchar* _tmp30_ = NULL; - Page* _tmp31_ = NULL; - gint _tmp32_ = 0; - gint _tmp33_ = 0; - Page* _tmp34_ = NULL; - gint _tmp35_ = 0; - gint _tmp36_ = 0; - Page* _tmp37_ = NULL; - gint _tmp38_ = 0; - gint _tmp39_ = 0; - Page* _tmp40_ = NULL; - gint _tmp41_ = 0; - gint _tmp42_ = 0; -#line 247 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp27_ = page; -#line 247 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp28_ = page_get_crop_name (_tmp27_); -#line 247 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp29_ = _tmp28_; -#line 247 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp30_ = g_strdup (_tmp29_); -#line 247 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _g_free0 (named_crop); -#line 247 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - named_crop = _tmp30_; -#line 248 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp31_ = page; -#line 248 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp32_ = page_get_crop_x (_tmp31_); -#line 248 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp33_ = _tmp32_; -#line 248 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - cx = _tmp33_; -#line 249 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp34_ = page; -#line 249 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp35_ = page_get_crop_y (_tmp34_); -#line 249 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp36_ = _tmp35_; -#line 249 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - cy = _tmp36_; -#line 250 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp37_ = page; -#line 250 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp38_ = page_get_crop_width (_tmp37_); -#line 250 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp39_ = _tmp38_; -#line 250 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - cw = _tmp39_; -#line 251 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp40_ = page; -#line 251 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp41_ = page_get_crop_height (_tmp40_); -#line 251 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp42_ = _tmp41_; -#line 251 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - ch = _tmp42_; -#line 1548 "simple-scan.c" - } - } -#line 255 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp43_ = width; -#line 255 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp44_ = height; -#line 255 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp45_ = dpi; -#line 255 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp46_ = scan_direction; -#line 255 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp47_ = page_new (_tmp43_, _tmp44_, _tmp45_, _tmp46_); -#line 255 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _page_unref0 (page); -#line 255 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - page = _tmp47_; -#line 256 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp48_ = self->priv->book; -#line 256 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp49_ = page; -#line 256 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - book_append_page (_tmp48_, _tmp49_); -#line 257 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp50_ = do_crop; -#line 257 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - if (_tmp50_) { -#line 1575 "simple-scan.c" - const gchar* _tmp51_ = NULL; - Page* _tmp57_ = NULL; - gint _tmp58_ = 0; - gint _tmp59_ = 0; -#line 259 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp51_ = named_crop; -#line 259 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - if (_tmp51_ != NULL) { -#line 1584 "simple-scan.c" - Page* _tmp52_ = NULL; - const gchar* _tmp53_ = NULL; -#line 261 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp52_ = page; -#line 261 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp53_ = named_crop; -#line 261 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - page_set_named_crop (_tmp52_, _tmp53_); -#line 1593 "simple-scan.c" - } else { - Page* _tmp54_ = NULL; - gint _tmp55_ = 0; - gint _tmp56_ = 0; -#line 264 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp54_ = page; -#line 264 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp55_ = cw; -#line 264 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp56_ = ch; -#line 264 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - page_set_custom_crop (_tmp54_, _tmp55_, _tmp56_); -#line 1606 "simple-scan.c" - } -#line 265 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp57_ = page; -#line 265 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp58_ = cx; -#line 265 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp59_ = cy; -#line 265 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - page_move_crop (_tmp57_, _tmp58_, _tmp59_); -#line 1616 "simple-scan.c" - } -#line 267 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp60_ = self->priv->ui; -#line 267 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp61_ = page; -#line 267 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - user_interface_set_selected_page (_tmp60_, _tmp61_); -#line 268 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp62_ = page; -#line 268 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - page_start (_tmp62_); -#line 270 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - result = page; -#line 270 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _g_free0 (named_crop); -#line 270 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - return result; -#line 1634 "simple-scan.c" -} - - -static void simple_scan_scanner_new_page_cb (SimpleScan* self, Scanner* scanner) { - Page* _tmp0_ = NULL; - Page* _tmp1_ = NULL; -#line 273 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - g_return_if_fail (self != NULL); -#line 273 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - g_return_if_fail (scanner != NULL); -#line 275 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp0_ = simple_scan_append_page (self); -#line 275 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp1_ = _tmp0_; -#line 275 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _page_unref0 (_tmp1_); -#line 1651 "simple-scan.c" -} - - -static gchar* simple_scan_get_profile_for_device (SimpleScan* self, const gchar* device_name) { - gchar* result = NULL; - gchar* device_id = NULL; - const gchar* _tmp0_ = NULL; - gchar* _tmp1_ = NULL; - const gchar* _tmp2_ = NULL; - CdClient* client = NULL; - CdClient* _tmp3_ = NULL; - CdDevice* device = NULL; - CdProfile* profile = NULL; - CdDevice* _tmp19_ = NULL; - CdProfile* _tmp20_ = NULL; - CdProfile* _tmp21_ = NULL; - CdProfile* _tmp27_ = NULL; - const gchar* _tmp28_ = NULL; - const gchar* _tmp29_ = NULL; - CdProfile* _tmp31_ = NULL; - const gchar* _tmp32_ = NULL; - const gchar* _tmp33_ = NULL; - const gchar* _tmp34_ = NULL; - CdProfile* _tmp35_ = NULL; - const gchar* _tmp36_ = NULL; - const gchar* _tmp37_ = NULL; - gchar* _tmp38_ = NULL; - GError * _inner_error_ = NULL; -#line 278 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - g_return_val_if_fail (self != NULL, NULL); -#line 278 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - g_return_val_if_fail (device_name != NULL, NULL); -#line 281 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp0_ = device_name; -#line 281 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp1_ = g_strdup_printf ("sane:%s", _tmp0_); -#line 281 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - device_id = _tmp1_; -#line 282 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp2_ = device_name; -#line 282 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - g_debug ("simple-scan.vala:282: Getting color profile for device %s", _tmp2_); -#line 284 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp3_ = cd_client_new (); -#line 284 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - client = _tmp3_; -#line 1698 "simple-scan.c" - { - CdClient* _tmp4_ = NULL; -#line 287 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp4_ = client; -#line 287 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - cd_client_connect_sync (_tmp4_, NULL, &_inner_error_); -#line 287 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - if (G_UNLIKELY (_inner_error_ != NULL)) { -#line 1707 "simple-scan.c" - goto __catch5_g_error; - } - } - goto __finally5; - __catch5_g_error: - { - GError* e = NULL; - GError* _tmp5_ = NULL; - const gchar* _tmp6_ = NULL; -#line 285 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - e = _inner_error_; -#line 285 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _inner_error_ = NULL; -#line 291 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp5_ = e; -#line 291 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp6_ = _tmp5_->message; -#line 291 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - g_debug ("simple-scan.vala:291: Failed to connect to colord: %s", _tmp6_); -#line 292 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - result = NULL; -#line 292 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _g_error_free0 (e); -#line 292 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _g_object_unref0 (client); -#line 292 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _g_free0 (device_id); -#line 292 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - return result; -#line 1737 "simple-scan.c" - } - __finally5: -#line 285 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - if (G_UNLIKELY (_inner_error_ != NULL)) { -#line 285 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _g_object_unref0 (client); -#line 285 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _g_free0 (device_id); -#line 285 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - g_critical ("file %s: line %d: uncaught error: %s (%s, %d)", __FILE__, __LINE__, _inner_error_->message, g_quark_to_string (_inner_error_->domain), _inner_error_->code); -#line 285 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - g_clear_error (&_inner_error_); -#line 285 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - return NULL; -#line 1752 "simple-scan.c" - } - { - CdDevice* _tmp7_ = NULL; - CdClient* _tmp8_ = NULL; - const gchar* _tmp9_ = NULL; - CdDevice* _tmp10_ = NULL; - CdDevice* _tmp11_ = NULL; -#line 298 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp8_ = client; -#line 298 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp9_ = device_id; -#line 298 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp10_ = cd_client_find_device_by_property_sync (_tmp8_, CD_DEVICE_PROPERTY_SERIAL, _tmp9_, NULL, &_inner_error_); -#line 298 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp7_ = _tmp10_; -#line 298 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - if (G_UNLIKELY (_inner_error_ != NULL)) { -#line 1770 "simple-scan.c" - goto __catch6_g_error; - } -#line 298 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp11_ = _tmp7_; -#line 298 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp7_ = NULL; -#line 298 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _g_object_unref0 (device); -#line 298 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - device = _tmp11_; -#line 296 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _g_object_unref0 (_tmp7_); -#line 1783 "simple-scan.c" - } - goto __finally6; - __catch6_g_error: - { - GError* e = NULL; - const gchar* _tmp12_ = NULL; - GError* _tmp13_ = NULL; - const gchar* _tmp14_ = NULL; -#line 296 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - e = _inner_error_; -#line 296 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _inner_error_ = NULL; -#line 302 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp12_ = device_name; -#line 302 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp13_ = e; -#line 302 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp14_ = _tmp13_->message; -#line 302 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - g_debug ("simple-scan.vala:302: Unable to find colord device %s: %s", _tmp12_, _tmp14_); -#line 303 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - result = NULL; -#line 303 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _g_error_free0 (e); -#line 303 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _g_object_unref0 (device); -#line 303 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _g_object_unref0 (client); -#line 303 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _g_free0 (device_id); -#line 303 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - return result; -#line 1816 "simple-scan.c" - } - __finally6: -#line 296 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - if (G_UNLIKELY (_inner_error_ != NULL)) { -#line 296 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _g_object_unref0 (device); -#line 296 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _g_object_unref0 (client); -#line 296 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _g_free0 (device_id); -#line 296 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - g_critical ("file %s: line %d: uncaught error: %s (%s, %d)", __FILE__, __LINE__, _inner_error_->message, g_quark_to_string (_inner_error_->domain), _inner_error_->code); -#line 296 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - g_clear_error (&_inner_error_); -#line 296 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - return NULL; -#line 1833 "simple-scan.c" - } - { - CdDevice* _tmp15_ = NULL; -#line 308 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp15_ = device; -#line 308 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - cd_device_connect_sync (_tmp15_, NULL, &_inner_error_); -#line 308 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - if (G_UNLIKELY (_inner_error_ != NULL)) { -#line 1843 "simple-scan.c" - goto __catch7_g_error; - } - } - goto __finally7; - __catch7_g_error: - { - GError* e = NULL; - const gchar* _tmp16_ = NULL; - GError* _tmp17_ = NULL; - const gchar* _tmp18_ = NULL; -#line 306 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - e = _inner_error_; -#line 306 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _inner_error_ = NULL; -#line 312 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp16_ = device_name; -#line 312 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp17_ = e; -#line 312 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp18_ = _tmp17_->message; -#line 312 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - g_debug ("simple-scan.vala:312: Failed to get properties from the device %s: %s", _tmp16_, _tmp18_); -#line 313 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - result = NULL; -#line 313 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _g_error_free0 (e); -#line 313 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _g_object_unref0 (device); -#line 313 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _g_object_unref0 (client); -#line 313 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _g_free0 (device_id); -#line 313 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - return result; -#line 1878 "simple-scan.c" - } - __finally7: -#line 306 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - if (G_UNLIKELY (_inner_error_ != NULL)) { -#line 306 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _g_object_unref0 (device); -#line 306 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _g_object_unref0 (client); -#line 306 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _g_free0 (device_id); -#line 306 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - g_critical ("file %s: line %d: uncaught error: %s (%s, %d)", __FILE__, __LINE__, _inner_error_->message, g_quark_to_string (_inner_error_->domain), _inner_error_->code); -#line 306 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - g_clear_error (&_inner_error_); -#line 306 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - return NULL; -#line 1895 "simple-scan.c" - } -#line 316 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp19_ = device; -#line 316 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp20_ = cd_device_get_default_profile (_tmp19_); -#line 316 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - profile = _tmp20_; -#line 317 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp21_ = profile; -#line 317 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - if (_tmp21_ == NULL) { -#line 1907 "simple-scan.c" - const gchar* _tmp22_ = NULL; -#line 319 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp22_ = device_name; -#line 319 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - g_debug ("simple-scan.vala:319: No default color profile for device: %s", _tmp22_); -#line 320 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - result = NULL; -#line 320 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _g_object_unref0 (profile); -#line 320 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _g_object_unref0 (device); -#line 320 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _g_object_unref0 (client); -#line 320 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _g_free0 (device_id); -#line 320 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - return result; -#line 1925 "simple-scan.c" - } - { - CdProfile* _tmp23_ = NULL; -#line 325 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp23_ = profile; -#line 325 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - cd_profile_connect_sync (_tmp23_, NULL, &_inner_error_); -#line 325 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - if (G_UNLIKELY (_inner_error_ != NULL)) { -#line 1935 "simple-scan.c" - goto __catch8_g_error; - } - } - goto __finally8; - __catch8_g_error: - { - GError* e = NULL; - const gchar* _tmp24_ = NULL; - GError* _tmp25_ = NULL; - const gchar* _tmp26_ = NULL; -#line 323 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - e = _inner_error_; -#line 323 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _inner_error_ = NULL; -#line 329 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp24_ = device_name; -#line 329 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp25_ = e; -#line 329 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp26_ = _tmp25_->message; -#line 329 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - g_debug ("simple-scan.vala:329: Failed to get properties from the profile %s: %s", _tmp24_, _tmp26_); -#line 330 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - result = NULL; -#line 330 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _g_error_free0 (e); -#line 330 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _g_object_unref0 (profile); -#line 330 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _g_object_unref0 (device); -#line 330 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _g_object_unref0 (client); -#line 330 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _g_free0 (device_id); -#line 330 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - return result; -#line 1972 "simple-scan.c" - } - __finally8: -#line 323 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - if (G_UNLIKELY (_inner_error_ != NULL)) { -#line 323 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _g_object_unref0 (profile); -#line 323 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _g_object_unref0 (device); -#line 323 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _g_object_unref0 (client); -#line 323 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _g_free0 (device_id); -#line 323 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - g_critical ("file %s: line %d: uncaught error: %s (%s, %d)", __FILE__, __LINE__, _inner_error_->message, g_quark_to_string (_inner_error_->domain), _inner_error_->code); -#line 323 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - g_clear_error (&_inner_error_); -#line 323 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - return NULL; -#line 1991 "simple-scan.c" - } -#line 333 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp27_ = profile; -#line 333 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp28_ = cd_profile_get_filename (_tmp27_); -#line 333 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp29_ = _tmp28_; -#line 333 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - if (_tmp29_ == NULL) { -#line 2001 "simple-scan.c" - const gchar* _tmp30_ = NULL; -#line 335 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp30_ = device_name; -#line 335 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - g_debug ("simple-scan.vala:335: No icc color profile for the device %s", _tmp30_); -#line 336 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - result = NULL; -#line 336 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _g_object_unref0 (profile); -#line 336 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _g_object_unref0 (device); -#line 336 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _g_object_unref0 (client); -#line 336 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _g_free0 (device_id); -#line 336 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - return result; -#line 2019 "simple-scan.c" - } -#line 339 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp31_ = profile; -#line 339 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp32_ = cd_profile_get_filename (_tmp31_); -#line 339 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp33_ = _tmp32_; -#line 339 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp34_ = device_name; -#line 339 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - g_debug ("simple-scan.vala:339: Using color profile %s for device %s", _tmp33_, _tmp34_); -#line 340 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp35_ = profile; -#line 340 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp36_ = cd_profile_get_filename (_tmp35_); -#line 340 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp37_ = _tmp36_; -#line 340 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp38_ = g_strdup (_tmp37_); -#line 340 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - result = _tmp38_; -#line 340 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _g_object_unref0 (profile); -#line 340 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _g_object_unref0 (device); -#line 340 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _g_object_unref0 (client); -#line 340 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _g_free0 (device_id); -#line 340 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - return result; -#line 2051 "simple-scan.c" -} - - -static void simple_scan_scanner_page_info_cb (SimpleScan* self, Scanner* scanner, ScanPageInfo* info) { - ScanPageInfo* _tmp0_ = NULL; - gint _tmp1_ = 0; - ScanPageInfo* _tmp2_ = NULL; - gint _tmp3_ = 0; - ScanPageInfo* _tmp4_ = NULL; - gint _tmp5_ = 0; - Page* page = NULL; - Page* _tmp6_ = NULL; - ScanPageInfo* _tmp7_ = NULL; - ScanPageInfo* _tmp8_ = NULL; - const gchar* _tmp9_ = NULL; - gchar* _tmp10_ = NULL; - gchar* _tmp11_ = NULL; -#line 346 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - g_return_if_fail (self != NULL); -#line 346 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - g_return_if_fail (scanner != NULL); -#line 346 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - g_return_if_fail (info != NULL); -#line 348 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp0_ = info; -#line 348 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp1_ = _tmp0_->width; -#line 348 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp2_ = info; -#line 348 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp3_ = _tmp2_->height; -#line 348 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp4_ = info; -#line 348 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp5_ = _tmp4_->depth; -#line 348 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - g_debug ("simple-scan.vala:348: Page is %d pixels wide, %d pixels high, %d bits " \ -"per pixel", _tmp1_, _tmp3_, _tmp5_); -#line 352 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp6_ = simple_scan_append_page (self); -#line 352 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - page = _tmp6_; -#line 353 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp7_ = info; -#line 353 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - page_set_page_info (page, _tmp7_); -#line 358 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp8_ = info; -#line 358 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp9_ = _tmp8_->device; -#line 358 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp10_ = simple_scan_get_profile_for_device (self, _tmp9_); -#line 358 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp11_ = _tmp10_; -#line 358 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - page_set_color_profile (page, _tmp11_); -#line 358 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _g_free0 (_tmp11_); -#line 346 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _page_unref0 (page); -#line 2111 "simple-scan.c" -} - - -static void simple_scan_scanner_line_cb (SimpleScan* self, Scanner* scanner, ScanLine* line) { - Page* page = NULL; - Book* _tmp0_ = NULL; - Book* _tmp1_ = NULL; - guint _tmp2_ = 0U; - guint _tmp3_ = 0U; - Page* _tmp4_ = NULL; - ScanLine* _tmp5_ = NULL; -#line 361 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - g_return_if_fail (self != NULL); -#line 361 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - g_return_if_fail (scanner != NULL); -#line 361 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - g_return_if_fail (line != NULL); -#line 363 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp0_ = self->priv->book; -#line 363 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp1_ = self->priv->book; -#line 363 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp2_ = book_get_n_pages (_tmp1_); -#line 363 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp3_ = _tmp2_; -#line 363 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp4_ = book_get_page (_tmp0_, ((gint) _tmp3_) - 1); -#line 363 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - page = _tmp4_; -#line 364 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp5_ = line; -#line 364 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - page_parse_scan_line (page, _tmp5_); -#line 361 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _page_unref0 (page); -#line 2147 "simple-scan.c" -} - - -static void simple_scan_scanner_page_done_cb (SimpleScan* self, Scanner* scanner) { - Page* page = NULL; - Book* _tmp0_ = NULL; - Book* _tmp1_ = NULL; - guint _tmp2_ = 0U; - guint _tmp3_ = 0U; - Page* _tmp4_ = NULL; -#line 367 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - g_return_if_fail (self != NULL); -#line 367 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - g_return_if_fail (scanner != NULL); -#line 369 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp0_ = self->priv->book; -#line 369 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp1_ = self->priv->book; -#line 369 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp2_ = book_get_n_pages (_tmp1_); -#line 369 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp3_ = _tmp2_; -#line 369 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp4_ = book_get_page (_tmp0_, ((gint) _tmp3_) - 1); -#line 369 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - page = _tmp4_; -#line 370 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - page_finish (page); -#line 367 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _page_unref0 (page); -#line 2178 "simple-scan.c" -} - - -static void simple_scan_remove_empty_page (SimpleScan* self) { - Page* page = NULL; - Book* _tmp0_ = NULL; - Book* _tmp1_ = NULL; - guint _tmp2_ = 0U; - guint _tmp3_ = 0U; - Page* _tmp4_ = NULL; - Page* _tmp5_ = NULL; - gboolean _tmp6_ = FALSE; - gboolean _tmp7_ = FALSE; -#line 373 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - g_return_if_fail (self != NULL); -#line 375 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp0_ = self->priv->book; -#line 375 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp1_ = self->priv->book; -#line 375 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp2_ = book_get_n_pages (_tmp1_); -#line 375 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp3_ = _tmp2_; -#line 375 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp4_ = book_get_page (_tmp0_, ((gint) _tmp3_) - 1); -#line 375 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - page = _tmp4_; -#line 376 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp5_ = page; -#line 376 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp6_ = page_get_has_data (_tmp5_); -#line 376 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp7_ = _tmp6_; -#line 376 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - if (!_tmp7_) { -#line 2214 "simple-scan.c" - Book* _tmp8_ = NULL; - Page* _tmp9_ = NULL; -#line 377 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp8_ = self->priv->book; -#line 377 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp9_ = page; -#line 377 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - book_delete_page (_tmp8_, _tmp9_); -#line 2223 "simple-scan.c" - } -#line 373 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _page_unref0 (page); -#line 2227 "simple-scan.c" -} - - -static void simple_scan_scanner_document_done_cb (SimpleScan* self, Scanner* scanner) { -#line 380 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - g_return_if_fail (self != NULL); -#line 380 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - g_return_if_fail (scanner != NULL); -#line 382 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - simple_scan_remove_empty_page (self); -#line 2238 "simple-scan.c" -} - - -static void simple_scan_scanner_failed_cb (SimpleScan* self, Scanner* scanner, gint error_code, const gchar* error_string) { - gint _tmp0_ = 0; -#line 385 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - g_return_if_fail (self != NULL); -#line 385 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - g_return_if_fail (scanner != NULL); -#line 385 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - g_return_if_fail (error_string != NULL); -#line 387 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - simple_scan_remove_empty_page (self); -#line 388 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp0_ = error_code; -#line 388 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - if (_tmp0_ != ((gint) SANE_STATUS_CANCELLED)) { -#line 2256 "simple-scan.c" - UserInterface* _tmp1_ = NULL; - const gchar* _tmp2_ = NULL; - const gchar* _tmp3_ = NULL; - gboolean _tmp4_ = FALSE; -#line 390 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp1_ = self->priv->ui; -#line 390 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp2_ = _ ("Failed to scan"); -#line 390 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp3_ = error_string; -#line 390 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp4_ = self->priv->have_devices; -#line 390 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - user_interface_show_error (_tmp1_, _tmp2_, _tmp3_, _tmp4_); -#line 2271 "simple-scan.c" - } -} - - -static void simple_scan_scanner_scanning_changed_cb (SimpleScan* self, Scanner* scanner) { - UserInterface* _tmp0_ = NULL; - Scanner* _tmp1_ = NULL; - gboolean _tmp2_ = FALSE; -#line 397 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - g_return_if_fail (self != NULL); -#line 397 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - g_return_if_fail (scanner != NULL); -#line 399 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp0_ = self->priv->ui; -#line 399 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp1_ = scanner; -#line 399 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp2_ = scanner_is_scanning (_tmp1_); -#line 399 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - user_interface_set_scanning (_tmp0_, _tmp2_); -#line 2292 "simple-scan.c" -} - - -static void simple_scan_scan_cb (SimpleScan* self, UserInterface* ui, const gchar* device, ScanOptions* options) { - ScanOptions* _tmp0_ = NULL; - gint _tmp1_ = 0; - const gchar* _tmp2_ = NULL; - Scanner* _tmp3_ = NULL; - gboolean _tmp4_ = FALSE; - Scanner* _tmp7_ = NULL; - const gchar* _tmp8_ = NULL; - ScanOptions* _tmp9_ = NULL; -#line 402 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - g_return_if_fail (self != NULL); -#line 402 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - g_return_if_fail (ui != NULL); -#line 402 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - g_return_if_fail (options != NULL); -#line 404 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp0_ = options; -#line 404 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp1_ = _tmp0_->dpi; -#line 404 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp2_ = device; -#line 404 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - g_debug ("simple-scan.vala:404: Requesting scan at %d dpi from device '%s'", _tmp1_, _tmp2_); -#line 406 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp3_ = self->priv->scanner; -#line 406 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp4_ = scanner_is_scanning (_tmp3_); -#line 406 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - if (!_tmp4_) { -#line 2325 "simple-scan.c" - Page* _tmp5_ = NULL; - Page* _tmp6_ = NULL; -#line 407 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp5_ = simple_scan_append_page (self); -#line 407 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp6_ = _tmp5_; -#line 407 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _page_unref0 (_tmp6_); -#line 2334 "simple-scan.c" - } -#line 409 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp7_ = self->priv->scanner; -#line 409 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp8_ = device; -#line 409 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp9_ = options; -#line 409 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - scanner_scan (_tmp7_, _tmp8_, _tmp9_); -#line 2344 "simple-scan.c" -} - - -static void simple_scan_cancel_cb (SimpleScan* self, UserInterface* ui) { - Scanner* _tmp0_ = NULL; -#line 412 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - g_return_if_fail (self != NULL); -#line 412 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - g_return_if_fail (ui != NULL); -#line 414 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp0_ = self->priv->scanner; -#line 414 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - scanner_cancel (_tmp0_); -#line 2358 "simple-scan.c" -} - - -static gchar* simple_scan_get_temporary_filename (SimpleScan* self, const gchar* prefix, const gchar* extension) { - gchar* result = NULL; - gchar* filename = NULL; - const gchar* _tmp0_ = NULL; - const gchar* _tmp1_ = NULL; - gchar* _tmp2_ = NULL; - gchar* path = NULL; - GError * _inner_error_ = NULL; -#line 417 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - g_return_val_if_fail (self != NULL, NULL); -#line 417 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - g_return_val_if_fail (prefix != NULL, NULL); -#line 417 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - g_return_val_if_fail (extension != NULL, NULL); -#line 422 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp0_ = prefix; -#line 422 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp1_ = extension; -#line 422 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp2_ = g_strdup_printf ("%sXXXXXX.%s", _tmp0_, _tmp1_); -#line 422 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - filename = _tmp2_; -#line 2384 "simple-scan.c" - { - gint fd = 0; - const gchar* _tmp3_ = NULL; - gchar* _tmp4_ = NULL; - gint _tmp5_ = 0; - gint _tmp6_ = 0; -#line 426 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp3_ = filename; -#line 426 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp5_ = g_file_open_tmp (_tmp3_, &_tmp4_, &_inner_error_); -#line 426 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _g_free0 (path); -#line 426 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - path = _tmp4_; -#line 426 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - fd = _tmp5_; -#line 426 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - if (G_UNLIKELY (_inner_error_ != NULL)) { -#line 2403 "simple-scan.c" - goto __catch9_g_error; - } -#line 427 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp6_ = fd; -#line 427 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - close (_tmp6_); -#line 2410 "simple-scan.c" - } - goto __finally9; - __catch9_g_error: - { - GError* e = NULL; - GError* _tmp7_ = NULL; - const gchar* _tmp8_ = NULL; -#line 424 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - e = _inner_error_; -#line 424 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _inner_error_ = NULL; -#line 431 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp7_ = e; -#line 431 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp8_ = _tmp7_->message; -#line 431 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - g_warning ("simple-scan.vala:431: Error saving email attachment: %s", _tmp8_); -#line 432 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - result = NULL; -#line 432 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _g_error_free0 (e); -#line 432 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _g_free0 (path); -#line 432 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _g_free0 (filename); -#line 432 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - return result; -#line 2438 "simple-scan.c" - } - __finally9: -#line 424 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - if (G_UNLIKELY (_inner_error_ != NULL)) { -#line 424 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _g_free0 (path); -#line 424 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _g_free0 (filename); -#line 424 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - g_critical ("file %s: line %d: uncaught error: %s (%s, %d)", __FILE__, __LINE__, _inner_error_->message, g_quark_to_string (_inner_error_->domain), _inner_error_->code); -#line 424 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - g_clear_error (&_inner_error_); -#line 424 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - return NULL; -#line 2453 "simple-scan.c" - } -#line 435 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - result = path; -#line 435 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _g_free0 (filename); -#line 435 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - return result; -#line 2461 "simple-scan.c" -} - - -static void simple_scan_email_cb (SimpleScan* self, UserInterface* ui, const gchar* profile, gint quality) { - gboolean saved = FALSE; - gchar* command_line = NULL; - gchar* _tmp0_ = NULL; - const gchar* _tmp1_ = NULL; - const gchar* _tmp42_ = NULL; - GError * _inner_error_ = NULL; -#line 438 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - g_return_if_fail (self != NULL); -#line 438 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - g_return_if_fail (ui != NULL); -#line 438 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - g_return_if_fail (profile != NULL); -#line 440 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - saved = FALSE; -#line 441 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp0_ = g_strdup ("xdg-email"); -#line 441 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - command_line = _tmp0_; -#line 444 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp1_ = profile; -#line 444 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - if (g_strcmp0 (_tmp1_, "text") == 0) { -#line 2488 "simple-scan.c" - gchar* path = NULL; - gchar* _tmp2_ = NULL; - const gchar* _tmp3_ = NULL; -#line 447 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp2_ = simple_scan_get_temporary_filename (self, "scan", "pdf"); -#line 447 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - path = _tmp2_; -#line 448 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp3_ = path; -#line 448 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - if (_tmp3_ != NULL) { -#line 2500 "simple-scan.c" - GFile* file = NULL; - const gchar* _tmp4_ = NULL; - GFile* _tmp5_ = NULL; - UserInterface* _tmp6_ = NULL; - const gchar* _tmp13_ = NULL; - const gchar* _tmp14_ = NULL; - gchar* _tmp15_ = NULL; - gchar* _tmp16_ = NULL; - gchar* _tmp17_ = NULL; -#line 450 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp4_ = path; -#line 450 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp5_ = g_file_new_for_path (_tmp4_); -#line 450 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - file = _tmp5_; -#line 451 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp6_ = ui; -#line 451 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - user_interface_show_progress_dialog (_tmp6_); -#line 2520 "simple-scan.c" - { - Book* _tmp7_ = NULL; - gint _tmp8_ = 0; - GFile* _tmp9_ = NULL; -#line 454 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp7_ = self->priv->book; -#line 454 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp8_ = quality; -#line 454 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp9_ = file; -#line 454 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - book_save (_tmp7_, "pdf", _tmp8_, _tmp9_, &_inner_error_); -#line 454 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - if (G_UNLIKELY (_inner_error_ != NULL)) { -#line 2535 "simple-scan.c" - goto __catch10_g_error; - } - } - goto __finally10; - __catch10_g_error: - { - GError* e = NULL; - UserInterface* _tmp10_ = NULL; - GError* _tmp11_ = NULL; - const gchar* _tmp12_ = NULL; -#line 452 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - e = _inner_error_; -#line 452 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _inner_error_ = NULL; -#line 458 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp10_ = ui; -#line 458 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - user_interface_hide_progress_dialog (_tmp10_); -#line 459 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp11_ = e; -#line 459 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp12_ = _tmp11_->message; -#line 459 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - g_warning ("simple-scan.vala:459: Unable to save email file: %s", _tmp12_); -#line 460 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _g_error_free0 (e); -#line 460 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _g_object_unref0 (file); -#line 460 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _g_free0 (path); -#line 460 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _g_free0 (command_line); -#line 460 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - return; -#line 2570 "simple-scan.c" - } - __finally10: -#line 452 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - if (G_UNLIKELY (_inner_error_ != NULL)) { -#line 452 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _g_object_unref0 (file); -#line 452 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _g_free0 (path); -#line 452 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _g_free0 (command_line); -#line 452 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - g_critical ("file %s: line %d: uncaught error: %s (%s, %d)", __FILE__, __LINE__, _inner_error_->message, g_quark_to_string (_inner_error_->domain), _inner_error_->code); -#line 452 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - g_clear_error (&_inner_error_); -#line 452 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - return; -#line 2587 "simple-scan.c" - } -#line 462 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp13_ = command_line; -#line 462 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp14_ = path; -#line 462 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp15_ = g_strdup_printf (" --attach %s", _tmp14_); -#line 462 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp16_ = _tmp15_; -#line 462 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp17_ = g_strconcat (_tmp13_, _tmp16_, NULL); -#line 462 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _g_free0 (command_line); -#line 462 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - command_line = _tmp17_; -#line 462 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _g_free0 (_tmp16_); -#line 448 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _g_object_unref0 (file); -#line 2607 "simple-scan.c" - } -#line 444 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _g_free0 (path); -#line 2611 "simple-scan.c" - } else { - { - gint i = 0; -#line 467 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - i = 0; -#line 2617 "simple-scan.c" - { - gboolean _tmp18_ = FALSE; -#line 467 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp18_ = TRUE; -#line 467 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - while (TRUE) { -#line 2624 "simple-scan.c" - gint _tmp20_ = 0; - Book* _tmp21_ = NULL; - guint _tmp22_ = 0U; - guint _tmp23_ = 0U; - gchar* path = NULL; - gchar* _tmp24_ = NULL; - const gchar* _tmp25_ = NULL; - GFile* file = NULL; - const gchar* _tmp26_ = NULL; - GFile* _tmp27_ = NULL; - const gchar* _tmp36_ = NULL; - const gchar* _tmp37_ = NULL; - gchar* _tmp38_ = NULL; - gchar* _tmp39_ = NULL; - gchar* _tmp40_ = NULL; - gboolean _tmp41_ = FALSE; -#line 467 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - if (!_tmp18_) { -#line 2643 "simple-scan.c" - gint _tmp19_ = 0; -#line 467 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp19_ = i; -#line 467 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - i = _tmp19_ + 1; -#line 2649 "simple-scan.c" - } -#line 467 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp18_ = FALSE; -#line 467 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp20_ = i; -#line 467 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp21_ = self->priv->book; -#line 467 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp22_ = book_get_n_pages (_tmp21_); -#line 467 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp23_ = _tmp22_; -#line 467 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - if (!(((guint) _tmp20_) < _tmp23_)) { -#line 467 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - break; -#line 2665 "simple-scan.c" - } -#line 469 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp24_ = simple_scan_get_temporary_filename (self, "scan", "jpg"); -#line 469 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - path = _tmp24_; -#line 470 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp25_ = path; -#line 470 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - if (_tmp25_ == NULL) { -#line 472 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - saved = FALSE; -#line 473 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _g_free0 (path); -#line 473 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - break; -#line 2681 "simple-scan.c" - } -#line 476 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp26_ = path; -#line 476 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp27_ = g_file_new_for_path (_tmp26_); -#line 476 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - file = _tmp27_; -#line 2689 "simple-scan.c" - { - Book* _tmp28_ = NULL; - gint _tmp29_ = 0; - Page* _tmp30_ = NULL; - Page* _tmp31_ = NULL; - gint _tmp32_ = 0; - GFile* _tmp33_ = NULL; -#line 479 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp28_ = self->priv->book; -#line 479 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp29_ = i; -#line 479 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp30_ = book_get_page (_tmp28_, _tmp29_); -#line 479 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp31_ = _tmp30_; -#line 479 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp32_ = quality; -#line 479 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp33_ = file; -#line 479 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - page_save (_tmp31_, "jpeg", _tmp32_, _tmp33_, &_inner_error_); -#line 479 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _page_unref0 (_tmp31_); -#line 479 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - if (G_UNLIKELY (_inner_error_ != NULL)) { -#line 2715 "simple-scan.c" - goto __catch11_g_error; - } - } - goto __finally11; - __catch11_g_error: - { - GError* e = NULL; - GError* _tmp34_ = NULL; - const gchar* _tmp35_ = NULL; -#line 477 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - e = _inner_error_; -#line 477 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _inner_error_ = NULL; -#line 483 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp34_ = e; -#line 483 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp35_ = _tmp34_->message; -#line 483 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - g_warning ("simple-scan.vala:483: Unable to save email file: %s", _tmp35_); -#line 484 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _g_error_free0 (e); -#line 484 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _g_object_unref0 (file); -#line 484 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _g_free0 (path); -#line 484 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _g_free0 (command_line); -#line 484 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - return; -#line 2745 "simple-scan.c" - } - __finally11: -#line 477 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - if (G_UNLIKELY (_inner_error_ != NULL)) { -#line 477 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _g_object_unref0 (file); -#line 477 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _g_free0 (path); -#line 477 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _g_free0 (command_line); -#line 477 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - g_critical ("file %s: line %d: uncaught error: %s (%s, %d)", __FILE__, __LINE__, _inner_error_->message, g_quark_to_string (_inner_error_->domain), _inner_error_->code); -#line 477 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - g_clear_error (&_inner_error_); -#line 477 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - return; -#line 2762 "simple-scan.c" - } -#line 486 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp36_ = command_line; -#line 486 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp37_ = path; -#line 486 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp38_ = g_strdup_printf (" --attach %s", _tmp37_); -#line 486 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp39_ = _tmp38_; -#line 486 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp40_ = g_strconcat (_tmp36_, _tmp39_, NULL); -#line 486 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _g_free0 (command_line); -#line 486 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - command_line = _tmp40_; -#line 486 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _g_free0 (_tmp39_); -#line 488 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp41_ = saved; -#line 488 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - if (!_tmp41_) { -#line 489 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _g_object_unref0 (file); -#line 489 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _g_free0 (path); -#line 489 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - break; -#line 2790 "simple-scan.c" - } -#line 467 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _g_object_unref0 (file); -#line 467 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _g_free0 (path); -#line 2796 "simple-scan.c" - } - } - } - } -#line 493 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp42_ = command_line; -#line 493 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - g_debug ("simple-scan.vala:493: Launching email client: %s", _tmp42_); -#line 2805 "simple-scan.c" - { - const gchar* _tmp43_ = NULL; -#line 496 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp43_ = command_line; -#line 496 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - g_spawn_command_line_async (_tmp43_, &_inner_error_); -#line 496 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - if (G_UNLIKELY (_inner_error_ != NULL)) { -#line 2814 "simple-scan.c" - goto __catch12_g_error; - } - } - goto __finally12; - __catch12_g_error: - { - GError* e = NULL; - GError* _tmp44_ = NULL; - const gchar* _tmp45_ = NULL; -#line 494 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - e = _inner_error_; -#line 494 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _inner_error_ = NULL; -#line 500 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp44_ = e; -#line 500 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp45_ = _tmp44_->message; -#line 500 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - g_warning ("simple-scan.vala:500: Unable to start email: %s", _tmp45_); -#line 494 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _g_error_free0 (e); -#line 2836 "simple-scan.c" - } - __finally12: -#line 494 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - if (G_UNLIKELY (_inner_error_ != NULL)) { -#line 494 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _g_free0 (command_line); -#line 494 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - g_critical ("file %s: line %d: uncaught error: %s (%s, %d)", __FILE__, __LINE__, _inner_error_->message, g_quark_to_string (_inner_error_->domain), _inner_error_->code); -#line 494 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - g_clear_error (&_inner_error_); -#line 494 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - return; -#line 2849 "simple-scan.c" - } -#line 438 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _g_free0 (command_line); -#line 2853 "simple-scan.c" -} - - -static void simple_scan_log_cb (const gchar* log_domain, GLogLevelFlags log_level, const gchar* message) { - gchar* prefix = NULL; - GLogLevelFlags _tmp0_ = 0; - FILE* _tmp8_ = NULL; - GTimer* _tmp9_ = NULL; - gdouble _tmp10_ = 0.0; - const gchar* _tmp11_ = NULL; - const gchar* _tmp12_ = NULL; - gboolean _tmp13_ = FALSE; -#line 504 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - g_return_if_fail (message != NULL); -#line 508 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp0_ = log_level; -#line 508 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - switch (_tmp0_ & G_LOG_LEVEL_MASK) { -#line 508 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - case G_LOG_LEVEL_ERROR: -#line 2874 "simple-scan.c" - { - gchar* _tmp1_ = NULL; -#line 511 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp1_ = g_strdup ("ERROR:"); -#line 511 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _g_free0 (prefix); -#line 511 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - prefix = _tmp1_; -#line 512 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - break; -#line 2885 "simple-scan.c" - } -#line 508 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - case G_LOG_LEVEL_CRITICAL: -#line 2889 "simple-scan.c" - { - gchar* _tmp2_ = NULL; -#line 514 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp2_ = g_strdup ("CRITICAL:"); -#line 514 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _g_free0 (prefix); -#line 514 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - prefix = _tmp2_; -#line 515 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - break; -#line 2900 "simple-scan.c" - } -#line 508 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - case G_LOG_LEVEL_WARNING: -#line 2904 "simple-scan.c" - { - gchar* _tmp3_ = NULL; -#line 517 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp3_ = g_strdup ("WARNING:"); -#line 517 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _g_free0 (prefix); -#line 517 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - prefix = _tmp3_; -#line 518 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - break; -#line 2915 "simple-scan.c" - } -#line 508 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - case G_LOG_LEVEL_MESSAGE: -#line 2919 "simple-scan.c" - { - gchar* _tmp4_ = NULL; -#line 520 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp4_ = g_strdup ("MESSAGE:"); -#line 520 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _g_free0 (prefix); -#line 520 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - prefix = _tmp4_; -#line 521 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - break; -#line 2930 "simple-scan.c" - } -#line 508 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - case G_LOG_LEVEL_INFO: -#line 2934 "simple-scan.c" - { - gchar* _tmp5_ = NULL; -#line 523 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp5_ = g_strdup ("INFO:"); -#line 523 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _g_free0 (prefix); -#line 523 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - prefix = _tmp5_; -#line 524 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - break; -#line 2945 "simple-scan.c" - } -#line 508 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - case G_LOG_LEVEL_DEBUG: -#line 2949 "simple-scan.c" - { - gchar* _tmp6_ = NULL; -#line 526 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp6_ = g_strdup ("DEBUG:"); -#line 526 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _g_free0 (prefix); -#line 526 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - prefix = _tmp6_; -#line 527 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - break; -#line 2960 "simple-scan.c" - } - default: - { - gchar* _tmp7_ = NULL; -#line 529 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp7_ = g_strdup ("LOG:"); -#line 529 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _g_free0 (prefix); -#line 529 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - prefix = _tmp7_; -#line 530 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - break; -#line 2973 "simple-scan.c" - } - } -#line 533 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp8_ = simple_scan_log_file; -#line 533 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp9_ = simple_scan_log_timer; -#line 533 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp10_ = g_timer_elapsed (_tmp9_, NULL); -#line 533 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp11_ = prefix; -#line 533 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp12_ = message; -#line 533 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - fprintf (_tmp8_, "[%+.2fs] %s %s\n", _tmp10_, _tmp11_, _tmp12_); -#line 534 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp13_ = simple_scan_debug_enabled; -#line 534 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - if (_tmp13_) { -#line 2992 "simple-scan.c" - FILE* _tmp14_ = NULL; - GTimer* _tmp15_ = NULL; - gdouble _tmp16_ = 0.0; - const gchar* _tmp17_ = NULL; - const gchar* _tmp18_ = NULL; -#line 535 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp14_ = stderr; -#line 535 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp15_ = simple_scan_log_timer; -#line 535 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp16_ = g_timer_elapsed (_tmp15_, NULL); -#line 535 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp17_ = prefix; -#line 535 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp18_ = message; -#line 535 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - fprintf (_tmp14_, "[%+.2fs] %s %s\n", _tmp16_, _tmp17_, _tmp18_); -#line 3010 "simple-scan.c" - } -#line 504 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _g_free0 (prefix); -#line 3014 "simple-scan.c" -} - - -static glong string_strnlen (gchar* str, glong maxlen) { - glong result = 0L; - gchar* end = NULL; - gchar* _tmp0_ = NULL; - glong _tmp1_ = 0L; - gchar* _tmp2_ = NULL; - gchar* _tmp3_ = NULL; -#line 1295 "/usr/share/vala-0.34/vapi/glib-2.0.vapi" - _tmp0_ = str; -#line 1295 "/usr/share/vala-0.34/vapi/glib-2.0.vapi" - _tmp1_ = maxlen; -#line 1295 "/usr/share/vala-0.34/vapi/glib-2.0.vapi" - _tmp2_ = memchr (_tmp0_, 0, (gsize) _tmp1_); -#line 1295 "/usr/share/vala-0.34/vapi/glib-2.0.vapi" - end = _tmp2_; -#line 1296 "/usr/share/vala-0.34/vapi/glib-2.0.vapi" - _tmp3_ = end; -#line 1296 "/usr/share/vala-0.34/vapi/glib-2.0.vapi" - if (_tmp3_ == NULL) { -#line 3037 "simple-scan.c" - glong _tmp4_ = 0L; -#line 1297 "/usr/share/vala-0.34/vapi/glib-2.0.vapi" - _tmp4_ = maxlen; -#line 1297 "/usr/share/vala-0.34/vapi/glib-2.0.vapi" - result = _tmp4_; -#line 1297 "/usr/share/vala-0.34/vapi/glib-2.0.vapi" - return result; -#line 3045 "simple-scan.c" - } else { - gchar* _tmp5_ = NULL; - gchar* _tmp6_ = NULL; -#line 1299 "/usr/share/vala-0.34/vapi/glib-2.0.vapi" - _tmp5_ = end; -#line 1299 "/usr/share/vala-0.34/vapi/glib-2.0.vapi" - _tmp6_ = str; -#line 1299 "/usr/share/vala-0.34/vapi/glib-2.0.vapi" - result = (glong) (_tmp5_ - _tmp6_); -#line 1299 "/usr/share/vala-0.34/vapi/glib-2.0.vapi" - return result; -#line 3057 "simple-scan.c" - } -} - - -static gchar* string_substring (const gchar* self, glong offset, glong len) { - gchar* result = NULL; - glong string_length = 0L; - gboolean _tmp0_ = FALSE; - glong _tmp1_ = 0L; - glong _tmp8_ = 0L; - glong _tmp14_ = 0L; - glong _tmp17_ = 0L; - glong _tmp18_ = 0L; - glong _tmp19_ = 0L; - glong _tmp20_ = 0L; - glong _tmp21_ = 0L; - gchar* _tmp22_ = NULL; -#line 1306 "/usr/share/vala-0.34/vapi/glib-2.0.vapi" - g_return_val_if_fail (self != NULL, NULL); -#line 1308 "/usr/share/vala-0.34/vapi/glib-2.0.vapi" - _tmp1_ = offset; -#line 1308 "/usr/share/vala-0.34/vapi/glib-2.0.vapi" - if (_tmp1_ >= ((glong) 0)) { -#line 3081 "simple-scan.c" - glong _tmp2_ = 0L; -#line 1308 "/usr/share/vala-0.34/vapi/glib-2.0.vapi" - _tmp2_ = len; -#line 1308 "/usr/share/vala-0.34/vapi/glib-2.0.vapi" - _tmp0_ = _tmp2_ >= ((glong) 0); -#line 3087 "simple-scan.c" - } else { -#line 1308 "/usr/share/vala-0.34/vapi/glib-2.0.vapi" - _tmp0_ = FALSE; -#line 3091 "simple-scan.c" - } -#line 1308 "/usr/share/vala-0.34/vapi/glib-2.0.vapi" - if (_tmp0_) { -#line 3095 "simple-scan.c" - glong _tmp3_ = 0L; - glong _tmp4_ = 0L; - glong _tmp5_ = 0L; -#line 1310 "/usr/share/vala-0.34/vapi/glib-2.0.vapi" - _tmp3_ = offset; -#line 1310 "/usr/share/vala-0.34/vapi/glib-2.0.vapi" - _tmp4_ = len; -#line 1310 "/usr/share/vala-0.34/vapi/glib-2.0.vapi" - _tmp5_ = string_strnlen ((gchar*) self, _tmp3_ + _tmp4_); -#line 1310 "/usr/share/vala-0.34/vapi/glib-2.0.vapi" - string_length = _tmp5_; -#line 3107 "simple-scan.c" - } else { - gint _tmp6_ = 0; - gint _tmp7_ = 0; -#line 1312 "/usr/share/vala-0.34/vapi/glib-2.0.vapi" - _tmp6_ = strlen (self); -#line 1312 "/usr/share/vala-0.34/vapi/glib-2.0.vapi" - _tmp7_ = _tmp6_; -#line 1312 "/usr/share/vala-0.34/vapi/glib-2.0.vapi" - string_length = (glong) _tmp7_; -#line 3117 "simple-scan.c" - } -#line 1315 "/usr/share/vala-0.34/vapi/glib-2.0.vapi" - _tmp8_ = offset; -#line 1315 "/usr/share/vala-0.34/vapi/glib-2.0.vapi" - if (_tmp8_ < ((glong) 0)) { -#line 3123 "simple-scan.c" - glong _tmp9_ = 0L; - glong _tmp10_ = 0L; - glong _tmp11_ = 0L; -#line 1316 "/usr/share/vala-0.34/vapi/glib-2.0.vapi" - _tmp9_ = string_length; -#line 1316 "/usr/share/vala-0.34/vapi/glib-2.0.vapi" - _tmp10_ = offset; -#line 1316 "/usr/share/vala-0.34/vapi/glib-2.0.vapi" - offset = _tmp9_ + _tmp10_; -#line 1317 "/usr/share/vala-0.34/vapi/glib-2.0.vapi" - _tmp11_ = offset; -#line 1317 "/usr/share/vala-0.34/vapi/glib-2.0.vapi" - g_return_val_if_fail (_tmp11_ >= ((glong) 0), NULL); -#line 3137 "simple-scan.c" - } else { - glong _tmp12_ = 0L; - glong _tmp13_ = 0L; -#line 1319 "/usr/share/vala-0.34/vapi/glib-2.0.vapi" - _tmp12_ = offset; -#line 1319 "/usr/share/vala-0.34/vapi/glib-2.0.vapi" - _tmp13_ = string_length; -#line 1319 "/usr/share/vala-0.34/vapi/glib-2.0.vapi" - g_return_val_if_fail (_tmp12_ <= _tmp13_, NULL); -#line 3147 "simple-scan.c" - } -#line 1321 "/usr/share/vala-0.34/vapi/glib-2.0.vapi" - _tmp14_ = len; -#line 1321 "/usr/share/vala-0.34/vapi/glib-2.0.vapi" - if (_tmp14_ < ((glong) 0)) { -#line 3153 "simple-scan.c" - glong _tmp15_ = 0L; - glong _tmp16_ = 0L; -#line 1322 "/usr/share/vala-0.34/vapi/glib-2.0.vapi" - _tmp15_ = string_length; -#line 1322 "/usr/share/vala-0.34/vapi/glib-2.0.vapi" - _tmp16_ = offset; -#line 1322 "/usr/share/vala-0.34/vapi/glib-2.0.vapi" - len = _tmp15_ - _tmp16_; -#line 3162 "simple-scan.c" - } -#line 1324 "/usr/share/vala-0.34/vapi/glib-2.0.vapi" - _tmp17_ = offset; -#line 1324 "/usr/share/vala-0.34/vapi/glib-2.0.vapi" - _tmp18_ = len; -#line 1324 "/usr/share/vala-0.34/vapi/glib-2.0.vapi" - _tmp19_ = string_length; -#line 1324 "/usr/share/vala-0.34/vapi/glib-2.0.vapi" - g_return_val_if_fail ((_tmp17_ + _tmp18_) <= _tmp19_, NULL); -#line 1325 "/usr/share/vala-0.34/vapi/glib-2.0.vapi" - _tmp20_ = offset; -#line 1325 "/usr/share/vala-0.34/vapi/glib-2.0.vapi" - _tmp21_ = len; -#line 1325 "/usr/share/vala-0.34/vapi/glib-2.0.vapi" - _tmp22_ = g_strndup (((gchar*) self) + _tmp20_, (gsize) _tmp21_); -#line 1325 "/usr/share/vala-0.34/vapi/glib-2.0.vapi" - result = _tmp22_; -#line 1325 "/usr/share/vala-0.34/vapi/glib-2.0.vapi" - return result; -#line 3182 "simple-scan.c" -} - - -static void simple_scan_fix_pdf (const gchar* filename, GError** error) { - guint8* data = NULL; - gint data_length1 = 0; - gint _data_size_ = 0; - const gchar* _tmp0_ = NULL; - guint8* _tmp1_ = NULL; - size_t _tmp2_; - FILE* fixed_file = NULL; - const gchar* _tmp3_ = NULL; - gchar* _tmp4_ = NULL; - gchar* _tmp5_ = NULL; - FILE* _tmp6_ = NULL; - FILE* _tmp7_ = NULL; - gint offset = 0; - gint line_number = 0; - gint xref_offset = 0; - gint xref_line = 0; - gint startxref_line = 0; - gint fixed_size = 0; - GString* line = NULL; - GString* _tmp8_ = NULL; - const gchar* _tmp102_ = NULL; - const gchar* _tmp103_ = NULL; - gchar* _tmp104_ = NULL; - gchar* _tmp105_ = NULL; - gint _tmp106_ = 0; - gboolean _tmp107_ = FALSE; - GError * _inner_error_ = NULL; -#line 538 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - g_return_if_fail (filename != NULL); -#line 541 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp0_ = filename; -#line 541 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - g_file_get_contents (_tmp0_, (gchar**) (&_tmp1_), &_tmp2_, &_inner_error_); -#line 541 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - data = (g_free (data), NULL); -#line 541 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - data = _tmp1_; -#line 541 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - data_length1 = _tmp2_; -#line 541 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _data_size_ = data_length1; -#line 541 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - if (G_UNLIKELY (_inner_error_ != NULL)) { -#line 541 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - g_propagate_error (error, _inner_error_); -#line 541 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - data = (g_free (data), NULL); -#line 541 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - return; -#line 3236 "simple-scan.c" - } -#line 543 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp3_ = filename; -#line 543 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp4_ = g_strconcat (_tmp3_, ".fixed", NULL); -#line 543 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp5_ = _tmp4_; -#line 543 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp6_ = g_fopen (_tmp5_, "w"); -#line 543 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp7_ = _tmp6_; -#line 543 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _g_free0 (_tmp5_); -#line 543 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - fixed_file = _tmp7_; -#line 545 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - offset = 0; -#line 546 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - line_number = 0; -#line 547 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - xref_offset = 0; -#line 548 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - xref_line = -1; -#line 549 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - startxref_line = -1; -#line 550 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - fixed_size = -1; -#line 551 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp8_ = g_string_new (""); -#line 551 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - line = _tmp8_; -#line 552 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - while (TRUE) { -#line 3270 "simple-scan.c" - gint _tmp9_ = 0; - gint end_offset = 0; - gint _tmp10_ = 0; - GString* _tmp11_ = NULL; - GString* _tmp19_ = NULL; - const gchar* _tmp20_ = NULL; - GString* _tmp22_ = NULL; - const gchar* _tmp23_ = NULL; - gboolean _tmp25_ = FALSE; - gint _tmp26_ = 0; - gint _tmp100_ = 0; - gint _tmp101_ = 0; -#line 552 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp9_ = offset; -#line 552 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - if (!(_tmp9_ < data_length1)) { -#line 552 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - break; -#line 3289 "simple-scan.c" - } -#line 554 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp10_ = offset; -#line 554 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - end_offset = _tmp10_; -#line 555 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp11_ = line; -#line 555 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - g_string_assign (_tmp11_, ""); -#line 556 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - while (TRUE) { -#line 3301 "simple-scan.c" - gint _tmp12_ = 0; - guint8 c = 0U; - gint _tmp13_ = 0; - guint8 _tmp14_ = 0U; - GString* _tmp15_ = NULL; - guint8 _tmp16_ = 0U; - gint _tmp17_ = 0; - guint8 _tmp18_ = 0U; -#line 556 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp12_ = end_offset; -#line 556 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - if (!(_tmp12_ < data_length1)) { -#line 556 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - break; -#line 3316 "simple-scan.c" - } -#line 558 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp13_ = end_offset; -#line 558 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp14_ = data[_tmp13_]; -#line 558 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - c = _tmp14_; -#line 559 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp15_ = line; -#line 559 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp16_ = c; -#line 559 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - g_string_append_c (_tmp15_, (gchar) _tmp16_); -#line 560 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp17_ = end_offset; -#line 560 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - end_offset = _tmp17_ + 1; -#line 561 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp18_ = c; -#line 561 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - if (_tmp18_ == ((guint8) '\n')) { -#line 562 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - break; -#line 3340 "simple-scan.c" - } - } -#line 565 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp19_ = line; -#line 565 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp20_ = _tmp19_->str; -#line 565 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - if (g_strcmp0 (_tmp20_, "startxref\n") == 0) { -#line 3349 "simple-scan.c" - gint _tmp21_ = 0; -#line 566 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp21_ = line_number; -#line 566 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - startxref_line = _tmp21_; -#line 3355 "simple-scan.c" - } -#line 568 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp22_ = line; -#line 568 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp23_ = _tmp22_->str; -#line 568 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - if (g_strcmp0 (_tmp23_, "xref\n") == 0) { -#line 3363 "simple-scan.c" - gint _tmp24_ = 0; -#line 569 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp24_ = line_number; -#line 569 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - xref_line = _tmp24_; -#line 3369 "simple-scan.c" - } -#line 572 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp26_ = line_number; -#line 572 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - if (_tmp26_ < 2) { -#line 3375 "simple-scan.c" - GString* _tmp27_ = NULL; - const gchar* _tmp28_ = NULL; - gboolean _tmp29_ = FALSE; -#line 572 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp27_ = line; -#line 572 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp28_ = _tmp27_->str; -#line 572 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp29_ = g_str_has_prefix (_tmp28_, "%%"); -#line 572 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp25_ = _tmp29_; -#line 3387 "simple-scan.c" - } else { -#line 572 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp25_ = FALSE; -#line 3391 "simple-scan.c" - } -#line 572 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - if (_tmp25_) { -#line 3395 "simple-scan.c" - gint _tmp30_ = 0; - FILE* _tmp31_ = NULL; - GString* _tmp32_ = NULL; - const gchar* _tmp33_ = NULL; - gchar* _tmp34_ = NULL; - gchar* _tmp35_ = NULL; -#line 574 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp30_ = xref_offset; -#line 574 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - xref_offset = _tmp30_ - 1; -#line 575 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp31_ = fixed_file; -#line 575 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp32_ = line; -#line 575 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp33_ = _tmp32_->str; -#line 575 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp34_ = string_substring (_tmp33_, (glong) 1, (glong) -1); -#line 575 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp35_ = _tmp34_; -#line 575 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - fprintf (_tmp31_, "%s", _tmp35_); -#line 575 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _g_free0 (_tmp35_); -#line 3420 "simple-scan.c" - } else { - gboolean _tmp36_ = FALSE; - gint _tmp37_ = 0; - gint _tmp38_ = 0; -#line 579 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp37_ = line_number; -#line 579 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp38_ = xref_line; -#line 579 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - if (_tmp37_ == (_tmp38_ + 1)) { -#line 3431 "simple-scan.c" - GString* _tmp39_ = NULL; - const gchar* _tmp40_ = NULL; - gboolean _tmp41_ = FALSE; -#line 579 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp39_ = line; -#line 579 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp40_ = _tmp39_->str; -#line 579 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp41_ = g_str_has_prefix (_tmp40_, "1 "); -#line 579 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp36_ = _tmp41_; -#line 3443 "simple-scan.c" - } else { -#line 579 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp36_ = FALSE; -#line 3447 "simple-scan.c" - } -#line 579 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - if (_tmp36_) { -#line 3451 "simple-scan.c" - GString* _tmp42_ = NULL; - const gchar* _tmp43_ = NULL; - gchar* _tmp44_ = NULL; - gchar* _tmp45_ = NULL; - gint _tmp46_ = 0; - FILE* _tmp47_ = NULL; - gint _tmp48_ = 0; - FILE* _tmp49_ = NULL; -#line 581 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp42_ = line; -#line 581 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp43_ = _tmp42_->str; -#line 581 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp44_ = string_substring (_tmp43_, (glong) 2, (glong) -1); -#line 581 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp45_ = _tmp44_; -#line 581 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp46_ = atoi (_tmp45_); -#line 581 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - fixed_size = _tmp46_ + 1; -#line 581 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _g_free0 (_tmp45_); -#line 582 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp47_ = fixed_file; -#line 582 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp48_ = fixed_size; -#line 582 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - fprintf (_tmp47_, "0 %d\n", _tmp48_); -#line 583 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp49_ = fixed_file; -#line 583 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - fprintf (_tmp49_, "0000000000 65535 f \n"); -#line 3484 "simple-scan.c" - } else { - gboolean _tmp50_ = FALSE; - gint _tmp51_ = 0; - gint _tmp52_ = 0; -#line 587 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp51_ = line_number; -#line 587 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp52_ = xref_line; -#line 587 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - if (_tmp51_ > _tmp52_) { -#line 3495 "simple-scan.c" - GString* _tmp53_ = NULL; - const gchar* _tmp54_ = NULL; - gboolean _tmp55_ = FALSE; -#line 587 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp53_ = line; -#line 587 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp54_ = _tmp53_->str; -#line 587 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp55_ = g_str_has_suffix (_tmp54_, " 0000 n\n"); -#line 587 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp50_ = _tmp55_; -#line 3507 "simple-scan.c" - } else { -#line 587 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp50_ = FALSE; -#line 3511 "simple-scan.c" - } -#line 587 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - if (_tmp50_) { -#line 3515 "simple-scan.c" - FILE* _tmp56_ = NULL; - GString* _tmp57_ = NULL; - const gchar* _tmp58_ = NULL; - gint _tmp59_ = 0; - gint _tmp60_ = 0; -#line 588 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp56_ = fixed_file; -#line 588 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp57_ = line; -#line 588 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp58_ = _tmp57_->str; -#line 588 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp59_ = atoi (_tmp58_); -#line 588 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp60_ = xref_offset; -#line 588 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - fprintf (_tmp56_, "%010d 00000 n \n", _tmp59_ + _tmp60_); -#line 3533 "simple-scan.c" - } else { - gboolean _tmp61_ = FALSE; - gint _tmp62_ = 0; -#line 591 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp62_ = startxref_line; -#line 591 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - if (_tmp62_ > 0) { -#line 3541 "simple-scan.c" - gint _tmp63_ = 0; - gint _tmp64_ = 0; -#line 591 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp63_ = line_number; -#line 591 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp64_ = startxref_line; -#line 591 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp61_ = _tmp63_ == (_tmp64_ + 1); -#line 3550 "simple-scan.c" - } else { -#line 591 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp61_ = FALSE; -#line 3554 "simple-scan.c" - } -#line 591 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - if (_tmp61_) { -#line 3558 "simple-scan.c" - FILE* _tmp65_ = NULL; - GString* _tmp66_ = NULL; - const gchar* _tmp67_ = NULL; - gint _tmp68_ = 0; - gint _tmp69_ = 0; - gchar* _tmp70_ = NULL; - gchar* _tmp71_ = NULL; -#line 592 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp65_ = fixed_file; -#line 592 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp66_ = line; -#line 592 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp67_ = _tmp66_->str; -#line 592 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp68_ = atoi (_tmp67_); -#line 592 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp69_ = xref_offset; -#line 592 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp70_ = g_strdup_printf ("%d\n", _tmp68_ + _tmp69_); -#line 592 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp71_ = _tmp70_; -#line 592 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - fprintf (_tmp65_, "%s", _tmp71_); -#line 592 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _g_free0 (_tmp71_); -#line 3584 "simple-scan.c" - } else { - gboolean _tmp72_ = FALSE; - gint _tmp73_ = 0; -#line 594 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp73_ = fixed_size; -#line 594 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - if (_tmp73_ > 0) { -#line 3592 "simple-scan.c" - GString* _tmp74_ = NULL; - const gchar* _tmp75_ = NULL; - gboolean _tmp76_ = FALSE; -#line 594 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp74_ = line; -#line 594 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp75_ = _tmp74_->str; -#line 594 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp76_ = g_str_has_prefix (_tmp75_, "/Size "); -#line 594 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp72_ = _tmp76_; -#line 3604 "simple-scan.c" - } else { -#line 594 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp72_ = FALSE; -#line 3608 "simple-scan.c" - } -#line 594 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - if (_tmp72_) { -#line 3612 "simple-scan.c" - FILE* _tmp77_ = NULL; - gint _tmp78_ = 0; - gchar* _tmp79_ = NULL; - gchar* _tmp80_ = NULL; -#line 595 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp77_ = fixed_file; -#line 595 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp78_ = fixed_size; -#line 595 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp79_ = g_strdup_printf ("/Size %d\n", _tmp78_); -#line 595 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp80_ = _tmp79_; -#line 595 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - fprintf (_tmp77_, "%s", _tmp80_); -#line 595 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _g_free0 (_tmp80_); -#line 3629 "simple-scan.c" - } else { - gboolean _tmp81_ = FALSE; - gint _tmp82_ = 0; - gint _tmp83_ = 0; -#line 598 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp82_ = line_number; -#line 598 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp83_ = startxref_line; -#line 598 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - if (_tmp82_ == (_tmp83_ + 2)) { -#line 3640 "simple-scan.c" - GString* _tmp84_ = NULL; - const gchar* _tmp85_ = NULL; - gboolean _tmp86_ = FALSE; -#line 598 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp84_ = line; -#line 598 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp85_ = _tmp84_->str; -#line 598 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp86_ = g_str_has_prefix (_tmp85_, "%%%%"); -#line 598 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp81_ = _tmp86_; -#line 3652 "simple-scan.c" - } else { -#line 598 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp81_ = FALSE; -#line 3656 "simple-scan.c" - } -#line 598 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - if (_tmp81_) { -#line 3660 "simple-scan.c" - FILE* _tmp87_ = NULL; - GString* _tmp88_ = NULL; - const gchar* _tmp89_ = NULL; - gchar* _tmp90_ = NULL; - gchar* _tmp91_ = NULL; -#line 599 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp87_ = fixed_file; -#line 599 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp88_ = line; -#line 599 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp89_ = _tmp88_->str; -#line 599 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp90_ = string_substring (_tmp89_, (glong) 2, (glong) -1); -#line 599 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp91_ = _tmp90_; -#line 599 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - fprintf (_tmp87_, "%s", _tmp91_); -#line 599 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _g_free0 (_tmp91_); -#line 3680 "simple-scan.c" - } else { - { - gint i = 0; - gint _tmp92_ = 0; -#line 602 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp92_ = offset; -#line 602 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - i = _tmp92_; -#line 3689 "simple-scan.c" - { - gboolean _tmp93_ = FALSE; -#line 602 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp93_ = TRUE; -#line 602 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - while (TRUE) { -#line 3696 "simple-scan.c" - gint _tmp95_ = 0; - gint _tmp96_ = 0; - FILE* _tmp97_ = NULL; - gint _tmp98_ = 0; - guint8 _tmp99_ = 0U; -#line 602 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - if (!_tmp93_) { -#line 3704 "simple-scan.c" - gint _tmp94_ = 0; -#line 602 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp94_ = i; -#line 602 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - i = _tmp94_ + 1; -#line 3710 "simple-scan.c" - } -#line 602 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp93_ = FALSE; -#line 602 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp95_ = i; -#line 602 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp96_ = end_offset; -#line 602 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - if (!(_tmp95_ < _tmp96_)) { -#line 602 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - break; -#line 3722 "simple-scan.c" - } -#line 603 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp97_ = fixed_file; -#line 603 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp98_ = i; -#line 603 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp99_ = data[_tmp98_]; -#line 603 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - fputc ((gchar) _tmp99_, _tmp97_); -#line 3732 "simple-scan.c" - } - } - } - } - } - } - } - } - } -#line 605 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp100_ = line_number; -#line 605 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - line_number = _tmp100_ + 1; -#line 606 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp101_ = end_offset; -#line 606 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - offset = _tmp101_; -#line 3750 "simple-scan.c" - } -#line 609 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp102_ = filename; -#line 609 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp103_ = filename; -#line 609 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp104_ = g_strconcat (_tmp103_, "~", NULL); -#line 609 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp105_ = _tmp104_; -#line 609 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp106_ = g_rename (_tmp102_, _tmp105_); -#line 609 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp107_ = _tmp106_ >= 0; -#line 609 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _g_free0 (_tmp105_); -#line 609 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - if (_tmp107_) { -#line 3768 "simple-scan.c" - const gchar* _tmp108_ = NULL; - gchar* _tmp109_ = NULL; - gchar* _tmp110_ = NULL; - const gchar* _tmp111_ = NULL; -#line 610 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp108_ = filename; -#line 610 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp109_ = g_strconcat (_tmp108_, ".fixed", NULL); -#line 610 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp110_ = _tmp109_; -#line 610 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp111_ = filename; -#line 610 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - g_rename (_tmp110_, _tmp111_); -#line 610 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _g_free0 (_tmp110_); -#line 3785 "simple-scan.c" - } -#line 538 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _g_string_free0 (line); -#line 538 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _fclose0 (fixed_file); -#line 538 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - data = (g_free (data), NULL); -#line 3793 "simple-scan.c" -} - - -static void _simple_scan_log_cb_glog_func (const gchar* log_domain, GLogLevelFlags log_levels, const gchar* message, gpointer self) { -#line 672 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - simple_scan_log_cb (log_domain, log_levels, message); -#line 3800 "simple-scan.c" -} - - -gint simple_scan_main (gchar** args, int args_length1) { - gint result = 0; - GOptionContext* c = NULL; - const gchar* _tmp0_ = NULL; - GOptionContext* _tmp1_ = NULL; - GOptionContext* _tmp2_ = NULL; - GOptionContext* _tmp3_ = NULL; - GOptionGroup* _tmp4_ = NULL; - gboolean _tmp15_ = FALSE; - const gchar* _tmp17_ = NULL; - ScanDevice* device = NULL; - gchar** _tmp30_ = NULL; - gint _tmp30__length1 = 0; - GTimer* _tmp40_ = NULL; - gchar* path = NULL; - const gchar* _tmp41_ = NULL; - gchar* _tmp42_ = NULL; - const gchar* _tmp43_ = NULL; - const gchar* _tmp44_ = NULL; - gchar* _tmp45_ = NULL; - const gchar* _tmp46_ = NULL; - FILE* _tmp47_ = NULL; - pid_t _tmp48_ = 0; - SimpleScan* app = NULL; - ScanDevice* _tmp49_ = NULL; - SimpleScan* _tmp50_ = NULL; - SimpleScan* _tmp51_ = NULL; - gint _tmp52_ = 0; - GError * _inner_error_ = NULL; -#line 615 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - setlocale (LC_ALL, ""); -#line 616 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - bindtextdomain (GETTEXT_PACKAGE, LOCALE_DIR); -#line 617 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - bind_textdomain_codeset (GETTEXT_PACKAGE, "UTF-8"); -#line 618 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - textdomain (GETTEXT_PACKAGE); -#line 620 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp0_ = _ ("[DEVICE...] - Scanning utility"); -#line 620 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp1_ = g_option_context_new (_tmp0_); -#line 620 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - c = _tmp1_; -#line 622 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp2_ = c; -#line 622 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - g_option_context_add_main_entries (_tmp2_, SIMPLE_SCAN_options, GETTEXT_PACKAGE); -#line 623 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp3_ = c; -#line 623 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp4_ = gtk_get_option_group (TRUE); -#line 623 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - g_option_context_add_group (_tmp3_, _tmp4_); -#line 3857 "simple-scan.c" - { - GOptionContext* _tmp5_ = NULL; -#line 626 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp5_ = c; -#line 626 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - g_option_context_parse (_tmp5_, &args_length1, &args, &_inner_error_); -#line 626 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - if (G_UNLIKELY (_inner_error_ != NULL)) { -#line 3866 "simple-scan.c" - goto __catch13_g_error; - } - } - goto __finally13; - __catch13_g_error: - { - GError* e = NULL; - FILE* _tmp6_ = NULL; - GError* _tmp7_ = NULL; - const gchar* _tmp8_ = NULL; - FILE* _tmp9_ = NULL; - const gchar* _tmp10_ = NULL; - gchar** _tmp11_ = NULL; - gint _tmp11__length1 = 0; - const gchar* _tmp12_ = NULL; - FILE* _tmp13_ = NULL; -#line 624 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - e = _inner_error_; -#line 624 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _inner_error_ = NULL; -#line 630 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp6_ = stderr; -#line 630 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp7_ = e; -#line 630 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp8_ = _tmp7_->message; -#line 630 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - fprintf (_tmp6_, "%s\n", _tmp8_); -#line 631 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp9_ = stderr; -#line 631 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp10_ = _ ("Run '%s --help' to see a full list of available command line options."); -#line 631 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp11_ = args; -#line 631 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp11__length1 = args_length1; -#line 631 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp12_ = _tmp11_[0]; -#line 631 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - fprintf (_tmp9_, _tmp10_, _tmp12_); -#line 633 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp13_ = stderr; -#line 633 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - fprintf (_tmp13_, "\n"); -#line 634 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - result = EXIT_FAILURE; -#line 634 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _g_error_free0 (e); -#line 634 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _g_option_context_free0 (c); -#line 634 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - return result; -#line 3919 "simple-scan.c" - } - __finally13: -#line 624 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - if (G_UNLIKELY (_inner_error_ != NULL)) { -#line 3924 "simple-scan.c" - gint _tmp14_ = 0; -#line 624 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _g_option_context_free0 (c); -#line 624 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - g_critical ("file %s: line %d: uncaught error: %s (%s, %d)", __FILE__, __LINE__, _inner_error_->message, g_quark_to_string (_inner_error_->domain), _inner_error_->code); -#line 624 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - g_clear_error (&_inner_error_); -#line 624 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - return _tmp14_; -#line 3934 "simple-scan.c" - } -#line 636 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp15_ = simple_scan_show_version; -#line 636 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - if (_tmp15_) { -#line 3940 "simple-scan.c" - FILE* _tmp16_ = NULL; -#line 639 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp16_ = stderr; -#line 639 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - fprintf (_tmp16_, "simple-scan %s\n", VERSION); -#line 640 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - result = EXIT_SUCCESS; -#line 640 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _g_option_context_free0 (c); -#line 640 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - return result; -#line 3952 "simple-scan.c" - } -#line 642 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp17_ = simple_scan_fix_pdf_filename; -#line 642 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - if (_tmp17_ != NULL) { -#line 3958 "simple-scan.c" - { - const gchar* _tmp18_ = NULL; -#line 646 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp18_ = simple_scan_fix_pdf_filename; -#line 646 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - simple_scan_fix_pdf (_tmp18_, &_inner_error_); -#line 646 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - if (G_UNLIKELY (_inner_error_ != NULL)) { -#line 3967 "simple-scan.c" - goto __catch14_g_error; - } - { - gint i = 0; -#line 647 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - i = 1; -#line 3974 "simple-scan.c" - { - gboolean _tmp19_ = FALSE; -#line 647 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp19_ = TRUE; -#line 647 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - while (TRUE) { -#line 3981 "simple-scan.c" - gint _tmp21_ = 0; - gchar** _tmp22_ = NULL; - gint _tmp22__length1 = 0; - gchar** _tmp23_ = NULL; - gint _tmp23__length1 = 0; - gint _tmp24_ = 0; - const gchar* _tmp25_ = NULL; -#line 647 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - if (!_tmp19_) { -#line 3991 "simple-scan.c" - gint _tmp20_ = 0; -#line 647 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp20_ = i; -#line 647 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - i = _tmp20_ + 1; -#line 3997 "simple-scan.c" - } -#line 647 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp19_ = FALSE; -#line 647 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp21_ = i; -#line 647 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp22_ = args; -#line 647 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp22__length1 = args_length1; -#line 647 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - if (!(_tmp21_ < _tmp22__length1)) { -#line 647 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - break; -#line 4011 "simple-scan.c" - } -#line 648 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp23_ = args; -#line 648 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp23__length1 = args_length1; -#line 648 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp24_ = i; -#line 648 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp25_ = _tmp23_[_tmp24_]; -#line 648 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - simple_scan_fix_pdf (_tmp25_, &_inner_error_); -#line 648 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - if (G_UNLIKELY (_inner_error_ != NULL)) { -#line 4025 "simple-scan.c" - goto __catch14_g_error; - } - } - } - } - } - goto __finally14; - __catch14_g_error: - { - GError* e = NULL; - FILE* _tmp26_ = NULL; - GError* _tmp27_ = NULL; - const gchar* _tmp28_ = NULL; -#line 644 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - e = _inner_error_; -#line 644 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _inner_error_ = NULL; -#line 652 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp26_ = stderr; -#line 652 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp27_ = e; -#line 652 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp28_ = _tmp27_->message; -#line 652 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - fprintf (_tmp26_, "Error fixing PDF file: %s", _tmp28_); -#line 653 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - result = EXIT_FAILURE; -#line 653 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _g_error_free0 (e); -#line 653 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _g_option_context_free0 (c); -#line 653 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - return result; -#line 4059 "simple-scan.c" - } - __finally14: -#line 644 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - if (G_UNLIKELY (_inner_error_ != NULL)) { -#line 4064 "simple-scan.c" - gint _tmp29_ = 0; -#line 644 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _g_option_context_free0 (c); -#line 644 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - g_critical ("file %s: line %d: uncaught error: %s (%s, %d)", __FILE__, __LINE__, _inner_error_->message, g_quark_to_string (_inner_error_->domain), _inner_error_->code); -#line 644 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - g_clear_error (&_inner_error_); -#line 644 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - return _tmp29_; -#line 4074 "simple-scan.c" - } -#line 655 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - result = EXIT_SUCCESS; -#line 655 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _g_option_context_free0 (c); -#line 655 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - return result; -#line 4082 "simple-scan.c" - } -#line 658 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - device = NULL; -#line 659 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp30_ = args; -#line 659 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp30__length1 = args_length1; -#line 659 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - if (_tmp30__length1 > 1) { -#line 4092 "simple-scan.c" - ScanDevice* _tmp31_ = NULL; - ScanDevice* _tmp32_ = NULL; - gchar** _tmp33_ = NULL; - gint _tmp33__length1 = 0; - const gchar* _tmp34_ = NULL; - gchar* _tmp35_ = NULL; - ScanDevice* _tmp36_ = NULL; - gchar** _tmp37_ = NULL; - gint _tmp37__length1 = 0; - const gchar* _tmp38_ = NULL; - gchar* _tmp39_ = NULL; -#line 661 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp31_ = scan_device_new (); -#line 661 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _scan_device_unref0 (device); -#line 661 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - device = _tmp31_; -#line 662 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp32_ = device; -#line 662 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp33_ = args; -#line 662 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp33__length1 = args_length1; -#line 662 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp34_ = _tmp33_[1]; -#line 662 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp35_ = g_strdup (_tmp34_); -#line 662 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _g_free0 (_tmp32_->name); -#line 662 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp32_->name = _tmp35_; -#line 663 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp36_ = device; -#line 663 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp37_ = args; -#line 663 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp37__length1 = args_length1; -#line 663 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp38_ = _tmp37_[1]; -#line 663 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp39_ = g_strdup (_tmp38_); -#line 663 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _g_free0 (_tmp36_->label); -#line 663 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp36_->label = _tmp39_; -#line 4138 "simple-scan.c" - } -#line 667 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp40_ = g_timer_new (); -#line 667 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _g_timer_destroy0 (simple_scan_log_timer); -#line 667 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - simple_scan_log_timer = _tmp40_; -#line 668 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp41_ = g_get_user_cache_dir (); -#line 668 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp42_ = g_build_filename (_tmp41_, "simple-scan", NULL, NULL); -#line 668 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - path = _tmp42_; -#line 669 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp43_ = path; -#line 669 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - g_mkdir_with_parents (_tmp43_, 0700); -#line 670 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp44_ = g_get_user_cache_dir (); -#line 670 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp45_ = g_build_filename (_tmp44_, "simple-scan", "simple-scan.log", NULL, NULL); -#line 670 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _g_free0 (path); -#line 670 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - path = _tmp45_; -#line 671 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp46_ = path; -#line 671 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp47_ = g_fopen (_tmp46_, "w"); -#line 671 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _fclose0 (simple_scan_log_file); -#line 671 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - simple_scan_log_file = _tmp47_; -#line 672 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - g_log_set_default_handler (_simple_scan_log_cb_glog_func, NULL); -#line 674 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp48_ = getpid (); -#line 674 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - g_debug ("simple-scan.vala:674: Starting Simple Scan %s, PID=%i", VERSION, (gint) _tmp48_); -#line 676 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - gtk_init (&args_length1, &args); -#line 678 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp49_ = device; -#line 678 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp50_ = simple_scan_new (_tmp49_); -#line 678 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - app = _tmp50_; -#line 679 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp51_ = app; -#line 679 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _tmp52_ = g_application_run ((GApplication*) _tmp51_, 0, NULL); -#line 679 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - result = _tmp52_; -#line 679 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _g_object_unref0 (app); -#line 679 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _g_free0 (path); -#line 679 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _scan_device_unref0 (device); -#line 679 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _g_option_context_free0 (c); -#line 679 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - return result; -#line 4202 "simple-scan.c" -} - - -int main (int argc, char ** argv) { -#if !GLIB_CHECK_VERSION (2,35,0) - g_type_init (); -#endif -#line 613 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - return simple_scan_main (argv, argc); -#line 4212 "simple-scan.c" -} - - -static void simple_scan_class_init (SimpleScanClass * klass) { -#line 12 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - simple_scan_parent_class = g_type_class_peek_parent (klass); -#line 12 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - g_type_class_add_private (klass, sizeof (SimpleScanPrivate)); -#line 12 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - ((GApplicationClass *) klass)->startup = (void (*)(GApplication*)) simple_scan_real_startup; -#line 12 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - ((GApplicationClass *) klass)->activate = (void (*)(GApplication*)) simple_scan_real_activate; -#line 12 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - ((GApplicationClass *) klass)->shutdown = (void (*)(GApplication*)) simple_scan_real_shutdown; -#line 12 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - G_OBJECT_CLASS (klass)->finalize = simple_scan_finalize; -#line 4229 "simple-scan.c" -} - - -static void simple_scan_instance_init (SimpleScan * self) { -#line 12 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - self->priv = SIMPLE_SCAN_GET_PRIVATE (self); -#line 32 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - self->priv->default_device = NULL; -#line 33 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - self->priv->have_devices = FALSE; -#line 4240 "simple-scan.c" -} - - -static void simple_scan_finalize (GObject* obj) { - SimpleScan * self; -#line 12 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - self = G_TYPE_CHECK_INSTANCE_CAST (obj, TYPE_SIMPLE_SCAN, SimpleScan); -#line 32 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _scan_device_unref0 (self->priv->default_device); -#line 34 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _g_object_unref0 (self->priv->usb_context); -#line 35 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _g_object_unref0 (self->priv->ui); -#line 36 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _scanner_unref0 (self->priv->scanner); -#line 37 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - _book_unref0 (self->priv->book); -#line 12 "/home/bob/bzr/simple-scan/trunk/src/simple-scan.vala" - G_OBJECT_CLASS (simple_scan_parent_class)->finalize (obj); -#line 4260 "simple-scan.c" -} - - -GType simple_scan_get_type (void) { - static volatile gsize simple_scan_type_id__volatile = 0; - if (g_once_init_enter (&simple_scan_type_id__volatile)) { - static const GTypeInfo g_define_type_info = { sizeof (SimpleScanClass), (GBaseInitFunc) NULL, (GBaseFinalizeFunc) NULL, (GClassInitFunc) simple_scan_class_init, (GClassFinalizeFunc) NULL, NULL, sizeof (SimpleScan), 0, (GInstanceInitFunc) simple_scan_instance_init, NULL }; - GType simple_scan_type_id; - simple_scan_type_id = g_type_register_static (gtk_application_get_type (), "SimpleScan", &g_define_type_info, 0); - g_once_init_leave (&simple_scan_type_id__volatile, simple_scan_type_id); - } - return simple_scan_type_id__volatile; -} - - - diff --git a/src/simple-scan.gresource.xml b/src/simple-scan.gresource.xml new file mode 100644 index 0000000..b6fe6a6 --- /dev/null +++ b/src/simple-scan.gresource.xml @@ -0,0 +1,6 @@ + + + + simple-scan.ui + + diff --git a/src/simple-scan.ui b/src/simple-scan.ui new file mode 100644 index 0000000..6e1d15a --- /dev/null +++ b/src/simple-scan.ui @@ -0,0 +1,1454 @@ + + + + + False + 12 + False + True + normal + True + + + True + False + vertical + 12 + + + True + False + end + + + _Authorize + True + True + True + True + + + False + False + 0 + + + + + False + True + end + 0 + + + + + True + False + 5 + vertical + 12 + + + True + False + To connect to ? you need to authorize + + + True + True + 0 + + + + + True + False + 6 + 6 + + + True + True + True + + + + 1 + 0 + 1 + 1 + + + + + True + True + True + False + + + + 1 + 1 + 1 + 1 + + + + + True + False + _Username for resource: + True + username_entry + + + 0 + 0 + 1 + 1 + + + + + True + False + _Password: + True + password_entry + + + 0 + 1 + 1 + 1 + + + + + False + True + 1 + + + + + False + True + 1 + + + + + + authorize_button + + + + -100 + 100 + 1 + 10 + + + -100 + 100 + 1 + 10 + + + + + + + + + + + True + False + mail-send + + + True + False + gtk-help + + + + + + + + + + + 3 + Front and Back + + + 1 + Front + + + 2 + Back + + + + + + + + + + + + + + + + + + + + + + + 100 + 1 + 10 + + + 0 + 10000 + 100 + 1000 + + + + + + + + + + + + False + 7 + Preferences + False + scanner + normal + + + + + True + False + vertical + 2 + + + True + False + end + + + gtk-close + True + True + True + True + + + False + False + 0 + + + + + False + True + end + 0 + + + + + True + False + 5 + 6 + 6 + + + True + False + 0 + Scan S_ource: + True + device_combo + + + 0 + 0 + 1 + 1 + + + + + True + False + True + device_model + + + + 1 + 0 + 1 + 1 + + + + + True + False + 0 + _Text Resolution: + True + text_dpi_combo + + + 0 + 1 + 1 + 1 + + + + + True + False + 0 + _Photo Resolution: + True + photo_dpi_combo + + + 0 + 2 + 1 + 1 + + + + + True + False + True + text_dpi_model + + + 1 + 1 + 1 + 1 + + + + + True + False + True + photo_dpi_model + + + 1 + 2 + 1 + 1 + + + + + True + False + 0 + Scan Side: + True + photo_dpi_combo + + + 0 + 3 + 1 + 1 + + + + + True + False + True + page_side_model + + + 1 + 3 + 1 + 1 + + + + + True + False + 0 + Page Size: + True + photo_dpi_combo + + + 0 + 4 + 1 + 1 + + + + + True + False + True + paper_size_model + + + 1 + 4 + 1 + 1 + + + + + True + False + 0 + Brightness: + True + + + 0 + 5 + 1 + 1 + + + + + True + True + True + brightness_adjustment + False + + + 1 + 5 + 1 + 1 + + + + + True + False + 0 + Contrast: + True + contrast_scale + + + 0 + 6 + 1 + 1 + + + + + True + True + True + contrast_adjustment + False + + + 1 + 6 + 1 + 1 + + + + + True + False + 0 + Quality: + True + quality_scale + + + 0 + 7 + 1 + 1 + + + + + True + True + True + quality_adjustment + False + + + 1 + 7 + 1 + 1 + + + + + True + False + 0 + Delay between pages: + True + page_delay_scale + + + 0 + 8 + 1 + 1 + + + + + True + True + True + page_delay_adjustment + True + + + 1 + 8 + 1 + 1 + + + + + False + True + 1 + + + + + + preferences_close_button + + + + True + False + + + True + False + Single _Page + True + + + + + + True + False + All Pages From _Feeder + True + + + + + + True + False + _Multiple Pages From Flatbed + True + + + + + + True + False + + + + + True + False + Text + True + True + + + + + + True + False + Photo + True + True + True + text_button_menuitem + + + + + + True + False + + + True + False + Single _Page + True + + + + + + True + False + All Pages From _Feeder + True + + + + + + True + False + _Multiple Pages From Flatbed + True + + + + + + True + False + + + + + True + False + Text + True + True + + + + + + True + False + Photo + True + True + True + text_button_hb_menuitem + + + + + diff --git a/src/simple-scan.vala b/src/simple-scan.vala index 9d1b9fd..2ab83f0 100644 --- a/src/simple-scan.vala +++ b/src/simple-scan.vala @@ -191,9 +191,7 @@ public class SimpleScan : Gtk.Application add_devices (driver_map, samsung_devices, "samsung"); add_devices (driver_map, hpaio_devices, "hpaio"); add_devices (driver_map, epkowa_devices, "epkowa"); - var devices = GUsb.context_get_devices (usb_context); - /* Fixed in GUsb 0.2.7: https://github.com/hughsie/libgusb/commit/83a6b1a20653c1a17f0a909f08652b5e1df44075 */ - /*var devices = GUSB.context_get_devices (context);*/ + var devices = usb_context.get_devices (); for (var i = 0; i < devices.length; i++) { var device = devices.data[i]; @@ -281,7 +279,7 @@ public class SimpleScan : Gtk.Application var device_id = "sane:%s".printf (device_name); debug ("Getting color profile for device %s", device_name); - var client = new Colord.Client (); + var client = new Cd.Client (); try { client.connect_sync (); @@ -292,10 +290,10 @@ public class SimpleScan : Gtk.Application return null; } - Colord.Device device; + Cd.Device device; try { - device = client.find_device_by_property_sync (Colord.DEVICE_PROPERTY_SERIAL, device_id); + device = client.find_device_by_property_sync (Cd.DEVICE_PROPERTY_SERIAL, device_id); } catch (Error e) { diff --git a/src/simple_scan_vala.stamp b/src/simple_scan_vala.stamp deleted file mode 100644 index 859afb1..0000000 --- a/src/simple_scan_vala.stamp +++ /dev/null @@ -1 +0,0 @@ -stamp diff --git a/src/ui.c b/src/ui.c deleted file mode 100644 index 3d687d9..0000000 --- a/src/ui.c +++ /dev/null @@ -1,13000 +0,0 @@ -/* ui.c generated by valac 0.34.6, the Vala compiler - * generated from ui.vala, do not modify */ - -/* - * Copyright (C) 2009-2015 Canonical Ltd. - * Author: Robert Ancell , - * Eduard Gotwig - * - * This program is free software: you can redistribute it and/or modify it under - * the terms of the GNU General Public License as published by the Free Software - * Foundation, either version 3 of the License, or (at your option) any later - * version. See http://www.gnu.org/copyleft/gpl.html the full text of the - * license. - */ - -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include "packagekit-glib2/packagekit.h" -#include -#include - - -#define TYPE_USER_INTERFACE (user_interface_get_type ()) -#define USER_INTERFACE(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), TYPE_USER_INTERFACE, UserInterface)) -#define USER_INTERFACE_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST ((klass), TYPE_USER_INTERFACE, UserInterfaceClass)) -#define IS_USER_INTERFACE(obj) (G_TYPE_CHECK_INSTANCE_TYPE ((obj), TYPE_USER_INTERFACE)) -#define IS_USER_INTERFACE_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE ((klass), TYPE_USER_INTERFACE)) -#define USER_INTERFACE_GET_CLASS(obj) (G_TYPE_INSTANCE_GET_CLASS ((obj), TYPE_USER_INTERFACE, UserInterfaceClass)) - -typedef struct _UserInterface UserInterface; -typedef struct _UserInterfaceClass UserInterfaceClass; -typedef struct _UserInterfacePrivate UserInterfacePrivate; - -#define TYPE_PROGRESS_BAR_DIALOG (progress_bar_dialog_get_type ()) -#define PROGRESS_BAR_DIALOG(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), TYPE_PROGRESS_BAR_DIALOG, ProgressBarDialog)) -#define PROGRESS_BAR_DIALOG_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST ((klass), TYPE_PROGRESS_BAR_DIALOG, ProgressBarDialogClass)) -#define IS_PROGRESS_BAR_DIALOG(obj) (G_TYPE_CHECK_INSTANCE_TYPE ((obj), TYPE_PROGRESS_BAR_DIALOG)) -#define IS_PROGRESS_BAR_DIALOG_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE ((klass), TYPE_PROGRESS_BAR_DIALOG)) -#define PROGRESS_BAR_DIALOG_GET_CLASS(obj) (G_TYPE_INSTANCE_GET_CLASS ((obj), TYPE_PROGRESS_BAR_DIALOG, ProgressBarDialogClass)) - -typedef struct _ProgressBarDialog ProgressBarDialog; -typedef struct _ProgressBarDialogClass ProgressBarDialogClass; - -#define TYPE_BOOK (book_get_type ()) -#define BOOK(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), TYPE_BOOK, Book)) -#define BOOK_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST ((klass), TYPE_BOOK, BookClass)) -#define IS_BOOK(obj) (G_TYPE_CHECK_INSTANCE_TYPE ((obj), TYPE_BOOK)) -#define IS_BOOK_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE ((klass), TYPE_BOOK)) -#define BOOK_GET_CLASS(obj) (G_TYPE_INSTANCE_GET_CLASS ((obj), TYPE_BOOK, BookClass)) - -typedef struct _Book Book; -typedef struct _BookClass BookClass; - -#define TYPE_AUTOSAVE_MANAGER (autosave_manager_get_type ()) -#define AUTOSAVE_MANAGER(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), TYPE_AUTOSAVE_MANAGER, AutosaveManager)) -#define AUTOSAVE_MANAGER_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST ((klass), TYPE_AUTOSAVE_MANAGER, AutosaveManagerClass)) -#define IS_AUTOSAVE_MANAGER(obj) (G_TYPE_CHECK_INSTANCE_TYPE ((obj), TYPE_AUTOSAVE_MANAGER)) -#define IS_AUTOSAVE_MANAGER_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE ((klass), TYPE_AUTOSAVE_MANAGER)) -#define AUTOSAVE_MANAGER_GET_CLASS(obj) (G_TYPE_INSTANCE_GET_CLASS ((obj), TYPE_AUTOSAVE_MANAGER, AutosaveManagerClass)) - -typedef struct _AutosaveManager AutosaveManager; -typedef struct _AutosaveManagerClass AutosaveManagerClass; - -#define TYPE_BOOK_VIEW (book_view_get_type ()) -#define BOOK_VIEW(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), TYPE_BOOK_VIEW, BookView)) -#define BOOK_VIEW_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST ((klass), TYPE_BOOK_VIEW, BookViewClass)) -#define IS_BOOK_VIEW(obj) (G_TYPE_CHECK_INSTANCE_TYPE ((obj), TYPE_BOOK_VIEW)) -#define IS_BOOK_VIEW_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE ((klass), TYPE_BOOK_VIEW)) -#define BOOK_VIEW_GET_CLASS(obj) (G_TYPE_INSTANCE_GET_CLASS ((obj), TYPE_BOOK_VIEW, BookViewClass)) - -typedef struct _BookView BookView; -typedef struct _BookViewClass BookViewClass; - -#define TYPE_SCAN_DIRECTION (scan_direction_get_type ()) - -#define TYPE_PAGE (page_get_type ()) -#define PAGE(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), TYPE_PAGE, Page)) -#define PAGE_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST ((klass), TYPE_PAGE, PageClass)) -#define IS_PAGE(obj) (G_TYPE_CHECK_INSTANCE_TYPE ((obj), TYPE_PAGE)) -#define IS_PAGE_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE ((klass), TYPE_PAGE)) -#define PAGE_GET_CLASS(obj) (G_TYPE_INSTANCE_GET_CLASS ((obj), TYPE_PAGE, PageClass)) - -typedef struct _Page Page; -typedef struct _PageClass PageClass; -#define _g_object_unref0(var) ((var == NULL) ? NULL : (var = (g_object_unref (var), NULL))) -#define _g_free0(var) (var = (g_free (var), NULL)) -#define _book_unref0(var) ((var == NULL) ? NULL : (var = (book_unref (var), NULL))) -#define _autosave_manager_unref0(var) ((var == NULL) ? NULL : (var = (autosave_manager_unref (var), NULL))) -#define _page_unref0(var) ((var == NULL) ? NULL : (var = (page_unref (var), NULL))) - -#define TYPE_SCAN_DEVICE (scan_device_get_type ()) -#define SCAN_DEVICE(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), TYPE_SCAN_DEVICE, ScanDevice)) -#define SCAN_DEVICE_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST ((klass), TYPE_SCAN_DEVICE, ScanDeviceClass)) -#define IS_SCAN_DEVICE(obj) (G_TYPE_CHECK_INSTANCE_TYPE ((obj), TYPE_SCAN_DEVICE)) -#define IS_SCAN_DEVICE_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE ((klass), TYPE_SCAN_DEVICE)) -#define SCAN_DEVICE_GET_CLASS(obj) (G_TYPE_INSTANCE_GET_CLASS ((obj), TYPE_SCAN_DEVICE, ScanDeviceClass)) - -typedef struct _ScanDevice ScanDevice; -typedef struct _ScanDeviceClass ScanDeviceClass; -typedef struct _ScanDevicePrivate ScanDevicePrivate; -#define _scan_device_unref0(var) ((var == NULL) ? NULL : (var = (scan_device_unref (var), NULL))) -typedef struct _Block1Data Block1Data; -#define _g_error_free0(var) ((var == NULL) ? NULL : (var = (g_error_free (var), NULL))) - -#define TYPE_SCAN_TYPE (scan_type_get_type ()) - -#define TYPE_SCAN_OPTIONS (scan_options_get_type ()) -#define SCAN_OPTIONS(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), TYPE_SCAN_OPTIONS, ScanOptions)) -#define SCAN_OPTIONS_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST ((klass), TYPE_SCAN_OPTIONS, ScanOptionsClass)) -#define IS_SCAN_OPTIONS(obj) (G_TYPE_CHECK_INSTANCE_TYPE ((obj), TYPE_SCAN_OPTIONS)) -#define IS_SCAN_OPTIONS_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE ((klass), TYPE_SCAN_OPTIONS)) -#define SCAN_OPTIONS_GET_CLASS(obj) (G_TYPE_INSTANCE_GET_CLASS ((obj), TYPE_SCAN_OPTIONS, ScanOptionsClass)) - -typedef struct _ScanOptions ScanOptions; -typedef struct _ScanOptionsClass ScanOptionsClass; - -#define TYPE_SCAN_MODE (scan_mode_get_type ()) -typedef struct _ScanOptionsPrivate ScanOptionsPrivate; -#define _scan_options_unref0(var) ((var == NULL) ? NULL : (var = (scan_options_unref (var), NULL))) -typedef struct _Block2Data Block2Data; - -#define TYPE_PAGE_ICON (page_icon_get_type ()) -#define PAGE_ICON(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), TYPE_PAGE_ICON, PageIcon)) -#define PAGE_ICON_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST ((klass), TYPE_PAGE_ICON, PageIconClass)) -#define IS_PAGE_ICON(obj) (G_TYPE_CHECK_INSTANCE_TYPE ((obj), TYPE_PAGE_ICON)) -#define IS_PAGE_ICON_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE ((klass), TYPE_PAGE_ICON)) -#define PAGE_ICON_GET_CLASS(obj) (G_TYPE_INSTANCE_GET_CLASS ((obj), TYPE_PAGE_ICON, PageIconClass)) - -typedef struct _PageIcon PageIcon; -typedef struct _PageIconClass PageIconClass; -#define _cairo_destroy0(var) ((var == NULL) ? NULL : (var = (cairo_destroy (var), NULL))) -typedef struct _Block3Data Block3Data; -#define _g_ptr_array_unref0(var) ((var == NULL) ? NULL : (var = (g_ptr_array_unref (var), NULL))) -typedef struct _UserInterfaceInstallPackagesData UserInterfaceInstallPackagesData; -#define _g_key_file_unref0(var) ((var == NULL) ? NULL : (var = (g_key_file_unref (var), NULL))) -typedef struct _ProgressBarDialogPrivate ProgressBarDialogPrivate; -typedef struct _PageIconPrivate PageIconPrivate; - -struct _UserInterface { - GtkApplicationWindow parent_instance; - UserInterfacePrivate * priv; -}; - -struct _UserInterfaceClass { - GtkApplicationWindowClass parent_class; -}; - -typedef enum { - SCAN_DIRECTION_TOP_TO_BOTTOM, - SCAN_DIRECTION_LEFT_TO_RIGHT, - SCAN_DIRECTION_BOTTOM_TO_TOP, - SCAN_DIRECTION_RIGHT_TO_LEFT -} ScanDirection; - -struct _UserInterfacePrivate { - GSettings* settings; - GtkMenuBar* menubar; - GtkToolbar* toolbar; - GtkMenu* page_menu; - GtkBox* main_vbox; - GtkInfoBar* info_bar; - GtkImage* info_bar_image; - GtkLabel* info_bar_label; - GtkButton* info_bar_close_button; - GtkButton* info_bar_change_scanner_button; - GtkButton* info_bar_install_button; - GtkRadioMenuItem* custom_crop_menuitem; - GtkRadioMenuItem* a4_menuitem; - GtkRadioMenuItem* a5_menuitem; - GtkRadioMenuItem* a6_menuitem; - GtkRadioMenuItem* letter_menuitem; - GtkRadioMenuItem* legal_menuitem; - GtkRadioMenuItem* four_by_six_menuitem; - GtkRadioMenuItem* no_crop_menuitem; - GtkMenuItem* page_move_left_menuitem; - GtkMenuItem* page_move_right_menuitem; - GtkMenuItem* page_delete_menuitem; - GtkMenuItem* crop_rotate_menuitem; - GtkMenuItem* save_menuitem; - GtkMenuItem* save_as_menuitem; - GtkMenuItem* copy_to_clipboard_menuitem; - GtkButton* save_button; - GtkToolButton* save_toolbutton; - GtkMenuItem* stop_scan_menuitem; - GtkToolButton* stop_toolbutton; - GtkToggleButton* crop_button; - GtkToggleToolButton* crop_toolbutton; - GtkButton* stop_button; - GtkButton* scan_button; - GtkRadioMenuItem* text_button_menuitem; - GtkRadioMenuItem* text_button_hb_menuitem; - GtkRadioMenuItem* text_menuitem; - GtkRadioMenuItem* photo_button_menuitem; - GtkRadioMenuItem* photo_button_hb_menuitem; - GtkRadioMenuItem* photo_menuitem; - GtkDialog* authorize_dialog; - GtkLabel* authorize_label; - GtkEntry* username_entry; - GtkEntry* password_entry; - GtkDialog* preferences_dialog; - GtkComboBox* device_combo; - GtkComboBox* text_dpi_combo; - GtkComboBox* photo_dpi_combo; - GtkComboBox* page_side_combo; - GtkComboBox* paper_size_combo; - GtkScale* brightness_scale; - GtkScale* contrast_scale; - GtkScale* quality_scale; - GtkListStore* device_model; - GtkListStore* text_dpi_model; - GtkListStore* photo_dpi_model; - GtkListStore* page_side_model; - GtkListStore* paper_size_model; - GtkAdjustment* brightness_adjustment; - GtkAdjustment* contrast_adjustment; - GtkAdjustment* quality_adjustment; - gboolean setting_devices; - gchar* missing_driver; - gboolean user_selected_device; - GtkFileChooserDialog* save_dialog; - ProgressBarDialog* progress_dialog; - gboolean have_error; - gchar* error_title; - gchar* error_text; - gboolean error_change_scanner_hint; - Book* _book; - gchar* book_uri; - AutosaveManager* autosave_manager; - BookView* book_view; - gboolean updating_page_menu; - gint default_page_width; - gint default_page_height; - gint default_page_dpi; - ScanDirection default_page_scan_direction; - gchar* document_hint; - gboolean scanning_; - gint window_width; - gint window_height; - gboolean window_is_maximized; - gboolean window_is_fullscreen; - guint save_state_timeout; -}; - -struct _ScanDevice { - GTypeInstance parent_instance; - volatile int ref_count; - ScanDevicePrivate * priv; - gchar* name; - gchar* label; -}; - -struct _ScanDeviceClass { - GTypeClass parent_class; - void (*finalize) (ScanDevice *self); -}; - -struct _Block1Data { - int _ref_count_; - UserInterface* self; - GtkListStore* file_type_store; - GtkComboBox* file_type_combo; -}; - -typedef enum { - SCAN_TYPE_SINGLE, - SCAN_TYPE_ADF_FRONT, - SCAN_TYPE_ADF_BACK, - SCAN_TYPE_ADF_BOTH -} ScanType; - -typedef enum { - SCAN_MODE_DEFAULT, - SCAN_MODE_COLOR, - SCAN_MODE_GRAY, - SCAN_MODE_LINEART -} ScanMode; - -struct _ScanOptions { - GTypeInstance parent_instance; - volatile int ref_count; - ScanOptionsPrivate * priv; - gint dpi; - ScanMode scan_mode; - gint depth; - ScanType type; - gint paper_width; - gint paper_height; - gint brightness; - gint contrast; -}; - -struct _ScanOptionsClass { - GTypeClass parent_class; - void (*finalize) (ScanOptions *self); -}; - -struct _Block2Data { - int _ref_count_; - UserInterface* self; - GtkWindow* dialog; -}; - -struct _Block3Data { - int _ref_count_; - UserInterface* self; - GtkStack* stack; - GtkSpinner* spinner; - GtkLabel* status_label; - GtkLabel* instructions_label; -}; - -struct _UserInterfaceInstallPackagesData { - int _state_; - GObject* _source_object_; - GAsyncResult* _res_; - GSimpleAsyncResult* _async_result; - UserInterface* self; - gchar** packages; - gint packages_length1; - PkProgressCallback progress_callback; - gpointer progress_callback_target; - PkResults* result; - PkTask* task; - PkTask* _tmp0_; - PkResults* results; - PkResults* _tmp1_; - PkTask* _tmp2_; - gchar** _tmp3_; - gint _tmp3__length1; - PkProgressCallback _tmp4_; - void* _tmp4__target; - PkResults* _tmp5_; - PkResults* _tmp6_; - gboolean _tmp7_; - PkResults* _tmp8_; - PkResults* _tmp9_; - PkError* _tmp10_; - PkError* _tmp11_; - GPtrArray* package_array; - PkResults* _tmp12_; - GPtrArray* _tmp13_; - gchar** package_ids; - GPtrArray* _tmp14_; - gint _tmp15_; - gint _tmp16_; - gchar** _tmp17_; - gint package_ids_length1; - gint _package_ids_size_; - gchar** _tmp18_; - gint _tmp18__length1; - GPtrArray* _tmp19_; - gint _tmp20_; - gint _tmp21_; - gchar* _tmp22_; - gint i; - gboolean _tmp23_; - gint _tmp24_; - gint _tmp25_; - GPtrArray* _tmp26_; - gint _tmp27_; - gint _tmp28_; - gchar** _tmp29_; - gint _tmp29__length1; - gint _tmp30_; - GPtrArray* _tmp31_; - gpointer* _tmp32_; - gint _tmp32__length1; - gint _tmp33_; - PkPackage* _tmp34_; - const gchar* _tmp35_; - gchar* _tmp36_; - gchar* _tmp37_; - PkResults* _tmp38_; - PkTask* _tmp39_; - gchar** _tmp40_; - gint _tmp40__length1; - PkProgressCallback _tmp41_; - void* _tmp41__target; - PkResults* _tmp42_; - PkResults* _tmp43_; - GError * _inner_error_; -}; - -struct _ProgressBarDialog { - GtkWindow parent_instance; - ProgressBarDialogPrivate * priv; -}; - -struct _ProgressBarDialogClass { - GtkWindowClass parent_class; -}; - -struct _ProgressBarDialogPrivate { - GtkProgressBar* bar; -}; - -struct _PageIcon { - GtkDrawingArea parent_instance; - PageIconPrivate * priv; -}; - -struct _PageIconClass { - GtkDrawingAreaClass parent_class; -}; - -struct _PageIconPrivate { - gchar* text; - gdouble r; - gdouble g; - gdouble b; -}; - - -static gpointer user_interface_parent_class = NULL; -static gpointer progress_bar_dialog_parent_class = NULL; -static gpointer page_icon_parent_class = NULL; - -GType user_interface_get_type (void) G_GNUC_CONST; -GType progress_bar_dialog_get_type (void) G_GNUC_CONST; -gpointer book_ref (gpointer instance); -void book_unref (gpointer instance); -GParamSpec* param_spec_book (const gchar* name, const gchar* nick, const gchar* blurb, GType object_type, GParamFlags flags); -void value_set_book (GValue* value, gpointer v_object); -void value_take_book (GValue* value, gpointer v_object); -gpointer value_get_book (const GValue* value); -GType book_get_type (void) G_GNUC_CONST; -gpointer autosave_manager_ref (gpointer instance); -void autosave_manager_unref (gpointer instance); -GParamSpec* param_spec_autosave_manager (const gchar* name, const gchar* nick, const gchar* blurb, GType object_type, GParamFlags flags); -void value_set_autosave_manager (GValue* value, gpointer v_object); -void value_take_autosave_manager (GValue* value, gpointer v_object); -gpointer value_get_autosave_manager (const GValue* value); -GType autosave_manager_get_type (void) G_GNUC_CONST; -GType book_view_get_type (void) G_GNUC_CONST; -GType scan_direction_get_type (void) G_GNUC_CONST; -#define USER_INTERFACE_GET_PRIVATE(o) (G_TYPE_INSTANCE_GET_PRIVATE ((o), TYPE_USER_INTERFACE, UserInterfacePrivate)) -enum { - USER_INTERFACE_DUMMY_PROPERTY, - USER_INTERFACE_BOOK, - USER_INTERFACE_SELECTED_PAGE, - USER_INTERFACE_SCANNING, - USER_INTERFACE_BRIGHTNESS, - USER_INTERFACE_CONTRAST, - USER_INTERFACE_QUALITY, - USER_INTERFACE_SELECTED_DEVICE -}; -Book* user_interface_get_book (UserInterface* self); -gpointer page_ref (gpointer instance); -void page_unref (gpointer instance); -GParamSpec* param_spec_page (const gchar* name, const gchar* nick, const gchar* blurb, GType object_type, GParamFlags flags); -void value_set_page (GValue* value, gpointer v_object); -void value_take_page (GValue* value, gpointer v_object); -gpointer value_get_page (const GValue* value); -GType page_get_type (void) G_GNUC_CONST; -static void user_interface_page_added_cb (UserInterface* self, Book* book, Page* page); -static void _user_interface_page_added_cb_book_page_added (Book* _sender, Page* page, gpointer self); -static void user_interface_reordered_cb (UserInterface* self, Book* book); -static void _user_interface_reordered_cb_book_reordered (Book* _sender, gpointer self); -static void user_interface_page_removed_cb (UserInterface* self, Book* book, Page* page); -static void _user_interface_page_removed_cb_book_page_removed (Book* _sender, Page* page, gpointer self); -#define USER_INTERFACE_DEFAULT_TEXT_DPI 150 -#define USER_INTERFACE_DEFAULT_PHOTO_DPI 300 -void user_interface_new_document_activate_cb (UserInterface* self); -static void _user_interface_new_document_activate_cb_gsimple_action_activate_callback (GSimpleAction* action, GVariant* parameter, gpointer self); -void user_interface_reorder_document_activate_cb (UserInterface* self); -static void _user_interface_reorder_document_activate_cb_gsimple_action_activate_callback (GSimpleAction* action, GVariant* parameter, gpointer self); -void user_interface_save_document_activate_cb (UserInterface* self); -static void _user_interface_save_document_activate_cb_gsimple_action_activate_callback (GSimpleAction* action, GVariant* parameter, gpointer self); -void user_interface_save_as_document_activate_cb (UserInterface* self); -static void _user_interface_save_as_document_activate_cb_gsimple_action_activate_callback (GSimpleAction* action, GVariant* parameter, gpointer self); -void user_interface_email_document_activate_cb (UserInterface* self); -static void _user_interface_email_document_activate_cb_gsimple_action_activate_callback (GSimpleAction* action, GVariant* parameter, gpointer self); -void user_interface_print_document_activate_cb (UserInterface* self); -static void _user_interface_print_document_activate_cb_gsimple_action_activate_callback (GSimpleAction* action, GVariant* parameter, gpointer self); -void user_interface_preferences_activate_cb (UserInterface* self); -static void _user_interface_preferences_activate_cb_gsimple_action_activate_callback (GSimpleAction* action, GVariant* parameter, gpointer self); -void user_interface_help_contents_activate_cb (UserInterface* self); -static void _user_interface_help_contents_activate_cb_gsimple_action_activate_callback (GSimpleAction* action, GVariant* parameter, gpointer self); -void user_interface_about_activate_cb (UserInterface* self); -static void _user_interface_about_activate_cb_gsimple_action_activate_callback (GSimpleAction* action, GVariant* parameter, gpointer self); -void user_interface_quit_activate_cb (UserInterface* self); -static void _user_interface_quit_activate_cb_gsimple_action_activate_callback (GSimpleAction* action, GVariant* parameter, gpointer self); -UserInterface* user_interface_new (void); -UserInterface* user_interface_construct (GType object_type); -Book* book_new (void); -Book* book_construct (GType object_type); -static void user_interface_set_book (UserInterface* self, Book* value); -static void user_interface_needs_saving_cb (UserInterface* self, Book* book); -static void _user_interface_needs_saving_cb_book_needs_saving_changed (Book* _sender, gpointer self); -static void user_interface_load (UserInterface* self); -AutosaveManager* autosave_manager_new (void); -AutosaveManager* autosave_manager_construct (GType object_type); -void autosave_manager_set_book (AutosaveManager* self, Book* value); -void autosave_manager_load (AutosaveManager* self); -guint book_get_n_pages (Book* self); -static void user_interface_add_default_page (UserInterface* self); -void book_set_needs_saving (Book* self, gboolean value); -Page* book_get_page (Book* self, gint page_number); -void book_view_set_selected_page (BookView* self, Page* value); -static gboolean user_interface_find_scan_device (UserInterface* self, const gchar* device, GtkTreeIter* iter); -static void user_interface_show_error_dialog (UserInterface* self, const gchar* error_title, const gchar* error_text); -void user_interface_authorize (UserInterface* self, const gchar* resource, gchar** username, gchar** password); -static void user_interface_device_combo_changed_cb (UserInterface* self, GtkWidget* widget); -gchar* user_interface_get_selected_device (UserInterface* self); -static void _user_interface_device_combo_changed_cb_gtk_combo_box_changed (GtkComboBox* _sender, gpointer self); -static void user_interface_update_info_bar (UserInterface* self); -gpointer scan_device_ref (gpointer instance); -void scan_device_unref (gpointer instance); -GParamSpec* param_spec_scan_device (const gchar* name, const gchar* nick, const gchar* blurb, GType object_type, GParamFlags flags); -void value_set_scan_device (GValue* value, gpointer v_object); -void value_take_scan_device (GValue* value, gpointer v_object); -gpointer value_get_scan_device (const GValue* value); -GType scan_device_get_type (void) G_GNUC_CONST; -void user_interface_set_scan_devices (UserInterface* self, GList* devices, const gchar* missing_driver); -Page* page_new (gint width, gint height, gint dpi, ScanDirection scan_direction); -Page* page_construct (GType object_type, gint width, gint height, gint dpi, ScanDirection scan_direction); -void book_append_page (Book* self, Page* page); -static gchar* user_interface_choose_file_location (UserInterface* self); -static Block1Data* block1_data_ref (Block1Data* _data1_); -static void block1_data_unref (void * _userdata_); -static void __lambda5_ (Block1Data* _data1_); -static void ___lambda5__gtk_combo_box_changed (GtkComboBox* _sender, gpointer self); -static gboolean user_interface_save_document (UserInterface* self, gboolean force_choose_location); -void user_interface_show_progress_dialog (UserInterface* self); -void book_save (Book* self, const gchar* type, gint quality, GFile* file, GError** error); -gint user_interface_get_quality (UserInterface* self); -void user_interface_hide_progress_dialog (UserInterface* self); -void user_interface_show_error (UserInterface* self, const gchar* error_title, const gchar* error_text, gboolean change_scanner_hint); -static gboolean user_interface_prompt_to_save (UserInterface* self, const gchar* title, const gchar* discard_label); -gboolean book_get_needs_saving (Book* self); -static void user_interface_clear_document (UserInterface* self); -void book_clear (Book* self); -static void user_interface_new_document (UserInterface* self); -gboolean user_interface_get_scanning (UserInterface* self); -static void user_interface_new_button_clicked_cb (UserInterface* self, GtkWidget* widget); -static void _user_interface_new_button_clicked_cb_gtk_button_clicked (GtkButton* _sender, gpointer self); -static void user_interface_set_document_hint (UserInterface* self, const gchar* document_hint, gboolean save); -static void user_interface_text_menuitem_toggled_cb (UserInterface* self, GtkCheckMenuItem* widget); -static void _user_interface_text_menuitem_toggled_cb_gtk_check_menu_item_toggled (GtkCheckMenuItem* _sender, gpointer self); -static void user_interface_photo_menuitem_toggled_cb (UserInterface* self, GtkCheckMenuItem* widget); -static void _user_interface_photo_menuitem_toggled_cb_gtk_check_menu_item_toggled (GtkCheckMenuItem* _sender, gpointer self); -GType scan_type_get_type (void) G_GNUC_CONST; -static void user_interface_set_page_side (UserInterface* self, ScanType page_side); -static void user_interface_set_paper_size (UserInterface* self, gint width, gint height); -static gint user_interface_get_text_dpi (UserInterface* self); -static gint user_interface_get_photo_dpi (UserInterface* self); -static ScanType user_interface_get_page_side (UserInterface* self); -static gboolean user_interface_get_paper_size (UserInterface* self, gint* width, gint* height); -gpointer scan_options_ref (gpointer instance); -void scan_options_unref (gpointer instance); -GParamSpec* param_spec_scan_options (const gchar* name, const gchar* nick, const gchar* blurb, GType object_type, GParamFlags flags); -void value_set_scan_options (GValue* value, gpointer v_object); -void value_take_scan_options (GValue* value, gpointer v_object); -gpointer value_get_scan_options (const GValue* value); -GType scan_options_get_type (void) G_GNUC_CONST; -static ScanOptions* user_interface_make_scan_options (UserInterface* self); -ScanOptions* scan_options_new (void); -ScanOptions* scan_options_construct (GType object_type); -GType scan_mode_get_type (void) G_GNUC_CONST; -gint user_interface_get_brightness (UserInterface* self); -gint user_interface_get_contrast (UserInterface* self); -static void user_interface_scan_button_clicked_cb (UserInterface* self, GtkWidget* widget); -static void _user_interface_scan_button_clicked_cb_gtk_menu_item_activate (GtkMenuItem* _sender, gpointer self); -static void user_interface_stop_scan_button_clicked_cb (UserInterface* self, GtkWidget* widget); -static void _user_interface_stop_scan_button_clicked_cb_gtk_button_clicked (GtkButton* _sender, gpointer self); -static void user_interface_continuous_scan_button_clicked_cb (UserInterface* self, GtkWidget* widget); -static void _user_interface_continuous_scan_button_clicked_cb_gtk_menu_item_activate (GtkMenuItem* _sender, gpointer self); -static void user_interface_preferences_button_clicked_cb (UserInterface* self, GtkWidget* widget); -static void _user_interface_preferences_button_clicked_cb_gtk_menu_item_activate (GtkMenuItem* _sender, gpointer self); -static gboolean user_interface_preferences_dialog_delete_event_cb (UserInterface* self, GtkWidget* widget, GdkEventAny* event); -static gboolean _user_interface_preferences_dialog_delete_event_cb_gtk_widget_delete_event (GtkWidget* _sender, GdkEventAny* event, gpointer self); -static void user_interface_preferences_dialog_response_cb (UserInterface* self, GtkWidget* widget, gint response_id); -static void _user_interface_preferences_dialog_response_cb_gtk_dialog_response (GtkDialog* _sender, gint response_id, gpointer self); -static void user_interface_update_page_menu (UserInterface* self); -Page* book_view_get_selected_page (BookView* self); -guint book_get_page_index (Book* self, Page* page); -static void user_interface_page_selected_cb (UserInterface* self, BookView* view, Page* page); -gboolean page_get_has_crop (Page* self); -const gchar* page_get_crop_name (Page* self); -static void user_interface_show_page_cb (UserInterface* self, BookView* view, Page* page); -gchar* get_temporary_filename (const gchar* prefix, const gchar* extension); -void page_save (Page* self, const gchar* type, gint quality, GFile* file, GError** error); -static void user_interface_show_page_menu_cb (UserInterface* self, BookView* view); -static void user_interface_rotate_left_button_clicked_cb (UserInterface* self, GtkWidget* widget); -void page_rotate_left (Page* self); -static void _user_interface_rotate_left_button_clicked_cb_gtk_button_clicked (GtkButton* _sender, gpointer self); -static void user_interface_rotate_right_button_clicked_cb (UserInterface* self, GtkWidget* widget); -void page_rotate_right (Page* self); -static void _user_interface_rotate_right_button_clicked_cb_gtk_button_clicked (GtkButton* _sender, gpointer self); -static void user_interface_set_crop (UserInterface* self, const gchar* crop_name); -void page_set_no_crop (Page* self); -gint page_get_width (Page* self); -gint page_get_height (Page* self); -void page_set_custom_crop (Page* self, gint width, gint height); -void page_move_crop (Page* self, gint x, gint y); -void page_set_named_crop (Page* self, const gchar* name); -static void user_interface_no_crop_menuitem_toggled_cb (UserInterface* self, GtkCheckMenuItem* widget); -static void _user_interface_no_crop_menuitem_toggled_cb_gtk_check_menu_item_toggled (GtkCheckMenuItem* _sender, gpointer self); -static void user_interface_custom_crop_menuitem_toggled_cb (UserInterface* self, GtkCheckMenuItem* widget); -static void _user_interface_custom_crop_menuitem_toggled_cb_gtk_check_menu_item_toggled (GtkCheckMenuItem* _sender, gpointer self); -static void user_interface_crop_button_toggled_cb (UserInterface* self, GtkToggleButton* widget); -static void _user_interface_crop_button_toggled_cb_gtk_toggle_button_toggled (GtkToggleButton* _sender, gpointer self); -static void user_interface_crop_toolbutton_toggled_cb (UserInterface* self, GtkToggleToolButton* widget); -static void _user_interface_crop_toolbutton_toggled_cb_gtk_toggle_tool_button_toggled (GtkToggleToolButton* _sender, gpointer self); -static void user_interface_four_by_six_menuitem_toggled_cb (UserInterface* self, GtkCheckMenuItem* widget); -static void _user_interface_four_by_six_menuitem_toggled_cb_gtk_check_menu_item_toggled (GtkCheckMenuItem* _sender, gpointer self); -static void user_interface_legal_menuitem_toggled_cb (UserInterface* self, GtkCheckMenuItem* widget); -static void _user_interface_legal_menuitem_toggled_cb_gtk_check_menu_item_toggled (GtkCheckMenuItem* _sender, gpointer self); -static void user_interface_letter_menuitem_toggled_cb (UserInterface* self, GtkCheckMenuItem* widget); -static void _user_interface_letter_menuitem_toggled_cb_gtk_check_menu_item_toggled (GtkCheckMenuItem* _sender, gpointer self); -static void user_interface_a6_menuitem_toggled_cb (UserInterface* self, GtkCheckMenuItem* widget); -static void _user_interface_a6_menuitem_toggled_cb_gtk_check_menu_item_toggled (GtkCheckMenuItem* _sender, gpointer self); -static void user_interface_a5_menuitem_toggled_cb (UserInterface* self, GtkCheckMenuItem* widget); -static void _user_interface_a5_menuitem_toggled_cb_gtk_check_menu_item_toggled (GtkCheckMenuItem* _sender, gpointer self); -static void user_interface_a4_menuitem_toggled_cb (UserInterface* self, GtkCheckMenuItem* widget); -static void _user_interface_a4_menuitem_toggled_cb_gtk_check_menu_item_toggled (GtkCheckMenuItem* _sender, gpointer self); -static void user_interface_crop_rotate_menuitem_activate_cb (UserInterface* self, GtkWidget* widget); -void page_rotate_crop (Page* self); -static void _user_interface_crop_rotate_menuitem_activate_cb_gtk_menu_item_activate (GtkMenuItem* _sender, gpointer self); -static void user_interface_page_move_left_menuitem_activate_cb (UserInterface* self, GtkWidget* widget); -void book_move_page (Book* self, Page* page, guint location); -static void _user_interface_page_move_left_menuitem_activate_cb_gtk_menu_item_activate (GtkMenuItem* _sender, gpointer self); -static void user_interface_page_move_right_menuitem_activate_cb (UserInterface* self, GtkWidget* widget); -static void _user_interface_page_move_right_menuitem_activate_cb_gtk_menu_item_activate (GtkMenuItem* _sender, gpointer self); -static void user_interface_page_delete_menuitem_activate_cb (UserInterface* self, GtkWidget* widget); -Book* book_view_get_book (BookView* self); -void book_delete_page (Book* self, Page* page); -static void _user_interface_page_delete_menuitem_activate_cb_gtk_menu_item_activate (GtkMenuItem* _sender, gpointer self); -static void user_interface_reorder_document (UserInterface* self); -static Block2Data* block2_data_ref (Block2Data* _data2_); -static void block2_data_unref (void * _userdata_); -static gboolean __lambda6_ (Block2Data* _data2_, GdkEventKey* e); -static gboolean ___lambda6__gtk_widget_key_press_event (GtkWidget* _sender, GdkEventKey* event, gpointer self); -static GtkButton* user_interface_make_reorder_button (UserInterface* self, const gchar* text, const gchar* items); -static void __lambda7_ (Block2Data* _data2_); -void book_combine_sides (Book* self); -static void ___lambda7__gtk_button_clicked (GtkButton* _sender, gpointer self); -static void __lambda8_ (Block2Data* _data2_); -void book_combine_sides_reverse (Book* self); -static void ___lambda8__gtk_button_clicked (GtkButton* _sender, gpointer self); -static void __lambda9_ (Block2Data* _data2_); -void book_reverse (Book* self); -static void ___lambda9__gtk_button_clicked (GtkButton* _sender, gpointer self); -static void __lambda10_ (Block2Data* _data2_); -static void ___lambda10__gtk_button_clicked (GtkButton* _sender, gpointer self); -static void user_interface_reorder_menuitem_activate_cb (UserInterface* self, GtkWidget* widget); -static void _user_interface_reorder_menuitem_activate_cb_gtk_menu_item_activate (GtkMenuItem* _sender, gpointer self); -static GtkBox* user_interface_make_reorder_box (UserInterface* self, const gchar* items); -GType page_icon_get_type (void) G_GNUC_CONST; -PageIcon* page_icon_new (const gchar* text, gdouble r, gdouble g, gdouble b); -PageIcon* page_icon_construct (GType object_type, const gchar* text, gdouble r, gdouble g, gdouble b); -static void user_interface_save_file_button_clicked_cb (UserInterface* self, GtkWidget* widget); -static void _user_interface_save_file_button_clicked_cb_gtk_button_clicked (GtkButton* _sender, gpointer self); -static void user_interface_copy_to_clipboard_button_clicked_cb (UserInterface* self, GtkWidget* widget); -void page_copy_to_clipboard (Page* self, GtkWindow* window); -static void _user_interface_copy_to_clipboard_button_clicked_cb_gtk_menu_item_activate (GtkMenuItem* _sender, gpointer self); -static void user_interface_save_as_file_button_clicked_cb (UserInterface* self, GtkWidget* widget); -static void _user_interface_save_as_file_button_clicked_cb_gtk_menu_item_activate (GtkMenuItem* _sender, gpointer self); -static void user_interface_draw_page (UserInterface* self, GtkPrintOperation* operation, GtkPrintContext* print_context, gint page_number); -gboolean page_get_is_landscape (Page* self); -gint page_get_dpi (Page* self); -GdkPixbuf* page_get_image (Page* self, gboolean apply_crop); -static void user_interface_email_button_clicked_cb (UserInterface* self, GtkWidget* widget); -static void _user_interface_email_button_clicked_cb_gtk_menu_item_activate (GtkMenuItem* _sender, gpointer self); -static void user_interface_print_document (UserInterface* self); -static void _user_interface_draw_page_gtk_print_operation_draw_page (GtkPrintOperation* _sender, GtkPrintContext* context, gint page_nr, gpointer self); -static void user_interface_print_button_clicked_cb (UserInterface* self, GtkWidget* widget); -static void _user_interface_print_button_clicked_cb_gtk_menu_item_activate (GtkMenuItem* _sender, gpointer self); -static void user_interface_launch_help (UserInterface* self); -static void user_interface_help_contents_menuitem_activate_cb (UserInterface* self, GtkWidget* widget); -static void _user_interface_help_contents_menuitem_activate_cb_gtk_menu_item_activate (GtkMenuItem* _sender, gpointer self); -static void user_interface_show_about (UserInterface* self); -static void user_interface_about_menuitem_activate_cb (UserInterface* self, GtkWidget* widget); -static void _user_interface_about_menuitem_activate_cb_gtk_menu_item_activate (GtkMenuItem* _sender, gpointer self); -static gboolean user_interface_on_quit (UserInterface* self); -static void user_interface_save_state (UserInterface* self, gboolean force); -void autosave_manager_cleanup (AutosaveManager* self); -static void user_interface_quit_menuitem_activate_cb (UserInterface* self, GtkWidget* widget); -static void _user_interface_quit_menuitem_activate_cb_gtk_menu_item_activate (GtkMenuItem* _sender, gpointer self); -static void user_interface_real_size_allocate (GtkWidget* base, GtkAllocation* allocation); -static void user_interface_info_bar_response_cb (UserInterface* self, GtkInfoBar* widget, gint response_id); -static void user_interface_install_drivers (UserInterface* self); -static Block3Data* block3_data_ref (Block3Data* _data3_); -static void block3_data_unref (void * _userdata_); -static void user_interface_install_packages (UserInterface* self, gchar** packages, int packages_length1, PkProgressCallback progress_callback, void* progress_callback_target, GAsyncReadyCallback _callback_, gpointer _user_data_); -static PkResults* user_interface_install_packages_finish (UserInterface* self, GAsyncResult* _res_, GError** error); -static void ___lambda12_ (UserInterface* self); -static void ____lambda12__pk_progress_callback (PkProgress* progress, PkProgressType type, gpointer self); -static void ___lambda13_ (Block3Data* _data3_, GObject* object, GAsyncResult* _result_); -static void ____lambda13__gasync_ready_callback (GObject* source_object, GAsyncResult* res, gpointer self); -static void user_interface_install_packages_data_free (gpointer _data); -static gboolean user_interface_install_packages_co (UserInterfaceInstallPackagesData* _data_); -static void user_interface_install_packages_ready (GObject* source_object, GAsyncResult* _res_, gpointer _user_data_); -static gboolean user_interface_real_window_state_event (GtkWidget* base, GdkEventWindowState* event); -static gboolean user_interface_window_delete_event_cb (UserInterface* self, GtkWidget* widget, GdkEventAny* event); -static gboolean _user_interface_window_delete_event_cb_gtk_widget_delete_event (GtkWidget* _sender, GdkEventAny* event, gpointer self); -static void user_interface_page_size_changed_cb (UserInterface* self, Page* page); -static void user_interface_page_scan_direction_changed_cb (UserInterface* self, Page* page); -ScanDirection page_get_scan_direction (Page* self); -static void _user_interface_page_size_changed_cb_page_size_changed (Page* _sender, gpointer self); -static void _user_interface_page_scan_direction_changed_cb_page_scan_direction_changed (Page* _sender, gpointer self); -static void user_interface_set_dpi_combo (UserInterface* self, GtkComboBox* combo, gint default_dpi, gint current_dpi); -static gboolean user_interface_is_traditional_desktop (UserInterface* self); -static void _user_interface_info_bar_response_cb_gtk_info_bar_response (GtkInfoBar* _sender, gint response_id, gpointer self); -static void __lambda14_ (UserInterface* self); -static void ___lambda14__gtk_combo_box_changed (GtkComboBox* _sender, gpointer self); -static void __lambda15_ (UserInterface* self); -static void ___lambda15__gtk_combo_box_changed (GtkComboBox* _sender, gpointer self); -static void __lambda16_ (UserInterface* self); -static void ___lambda16__gtk_combo_box_changed (GtkComboBox* _sender, gpointer self); -static void __lambda17_ (UserInterface* self); -static void ___lambda17__gtk_combo_box_changed (GtkComboBox* _sender, gpointer self); -void user_interface_set_brightness (UserInterface* self, gint value); -static void __lambda18_ (UserInterface* self); -static void ___lambda18__gtk_adjustment_value_changed (GtkAdjustment* _sender, gpointer self); -void user_interface_set_contrast (UserInterface* self, gint value); -static void __lambda19_ (UserInterface* self); -static void ___lambda19__gtk_adjustment_value_changed (GtkAdjustment* _sender, gpointer self); -void user_interface_set_quality (UserInterface* self, gint value); -static void __lambda20_ (UserInterface* self); -static void ___lambda20__gtk_adjustment_value_changed (GtkAdjustment* _sender, gpointer self); -BookView* book_view_new (Book* book); -BookView* book_view_construct (GType object_type, Book* book); -static void _user_interface_page_selected_cb_book_view_page_selected (BookView* _sender, Page* page, gpointer self); -static void _user_interface_show_page_cb_book_view_show_page (BookView* _sender, Page* page, gpointer self); -static void _user_interface_show_page_menu_cb_book_view_show_menu (BookView* _sender, gpointer self); -static void user_interface_load_state (UserInterface* self); -ProgressBarDialog* progress_bar_dialog_new (GtkApplicationWindow* parent, const gchar* title); -ProgressBarDialog* progress_bar_dialog_construct (GType object_type, GtkApplicationWindow* parent, const gchar* title); -static void user_interface_book_saving_cb (UserInterface* self, gint page_number); -static void _user_interface_book_saving_cb_book_saving (Book* _sender, gint i, gpointer self); -static gboolean user_interface_is_desktop (UserInterface* self, const gchar* name); -static gchar* user_interface_get_state_filename (UserInterface* self); -static gint user_interface_state_get_integer (UserInterface* self, GKeyFile* f, const gchar* group_name, const gchar* key, gint _default_); -static gboolean user_interface_state_get_boolean (UserInterface* self, GKeyFile* f, const gchar* group_name, const gchar* key, gboolean _default_); -static gchar* user_interface_state_get_string (UserInterface* self, GKeyFile* f, const gchar* group_name, const gchar* key, const gchar* _default_); -static gboolean ___lambda11_ (UserInterface* self); -static gboolean ____lambda11__gsource_func (gpointer self); -static gboolean ___lambda21_ (UserInterface* self); -static gboolean ____lambda21__gsource_func (gpointer self); -void progress_bar_dialog_set_fraction (ProgressBarDialog* self, gdouble value); -void progress_bar_dialog_set_message (ProgressBarDialog* self, const gchar* value); -void user_interface_start (UserInterface* self); -Page* user_interface_get_selected_page (UserInterface* self); -void user_interface_set_selected_page (UserInterface* self, Page* value); -void user_interface_set_scanning (UserInterface* self, gboolean value); -void user_interface_set_selected_device (UserInterface* self, const gchar* value); -static void g_cclosure_user_marshal_VOID__STRING_SCAN_OPTIONS (GClosure * closure, GValue * return_value, guint n_param_values, const GValue * param_values, gpointer invocation_hint, gpointer marshal_data); -static void g_cclosure_user_marshal_VOID__STRING_INT (GClosure * closure, GValue * return_value, guint n_param_values, const GValue * param_values, gpointer invocation_hint, gpointer marshal_data); -static void user_interface_finalize (GObject* obj); -static void _vala_user_interface_get_property (GObject * object, guint property_id, GValue * value, GParamSpec * pspec); -static void _vala_user_interface_set_property (GObject * object, guint property_id, const GValue * value, GParamSpec * pspec); -#define PROGRESS_BAR_DIALOG_GET_PRIVATE(o) (G_TYPE_INSTANCE_GET_PRIVATE ((o), TYPE_PROGRESS_BAR_DIALOG, ProgressBarDialogPrivate)) -enum { - PROGRESS_BAR_DIALOG_DUMMY_PROPERTY, - PROGRESS_BAR_DIALOG_FRACTION, - PROGRESS_BAR_DIALOG_MESSAGE -}; -gdouble progress_bar_dialog_get_fraction (ProgressBarDialog* self); -const gchar* progress_bar_dialog_get_message (ProgressBarDialog* self); -static void progress_bar_dialog_finalize (GObject* obj); -static void _vala_progress_bar_dialog_get_property (GObject * object, guint property_id, GValue * value, GParamSpec * pspec); -static void _vala_progress_bar_dialog_set_property (GObject * object, guint property_id, const GValue * value, GParamSpec * pspec); -#define PAGE_ICON_GET_PRIVATE(o) (G_TYPE_INSTANCE_GET_PRIVATE ((o), TYPE_PAGE_ICON, PageIconPrivate)) -enum { - PAGE_ICON_DUMMY_PROPERTY -}; -#define PAGE_ICON_MINIMUM_WIDTH 20 -static void page_icon_real_get_preferred_width (GtkWidget* base, gint* minimum_width, gint* natural_width); -static void page_icon_real_get_preferred_height (GtkWidget* base, gint* minimum_height, gint* natural_height); -static void page_icon_real_get_preferred_height_for_width (GtkWidget* base, gint width, gint* minimum_height, gint* natural_height); -static void page_icon_real_get_preferred_width_for_height (GtkWidget* base, gint height, gint* minimum_width, gint* natural_width); -static gboolean page_icon_real_draw (GtkWidget* base, cairo_t* c); -static void page_icon_finalize (GObject* obj); -static void _vala_array_destroy (gpointer array, gint array_length, GDestroyNotify destroy_func); -static void _vala_array_free (gpointer array, gint array_length, GDestroyNotify destroy_func); -static gint _vala_array_length (gpointer array); - -static const GActionEntry USER_INTERFACE_action_entries[10] = {{"new_document", _user_interface_new_document_activate_cb_gsimple_action_activate_callback}, {"reorder", _user_interface_reorder_document_activate_cb_gsimple_action_activate_callback}, {"save", _user_interface_save_document_activate_cb_gsimple_action_activate_callback}, {"save_as", _user_interface_save_as_document_activate_cb_gsimple_action_activate_callback}, {"email", _user_interface_email_document_activate_cb_gsimple_action_activate_callback}, {"print", _user_interface_print_document_activate_cb_gsimple_action_activate_callback}, {"preferences", _user_interface_preferences_activate_cb_gsimple_action_activate_callback}, {"help", _user_interface_help_contents_activate_cb_gsimple_action_activate_callback}, {"about", _user_interface_about_activate_cb_gsimple_action_activate_callback}, {"quit", _user_interface_quit_activate_cb_gsimple_action_activate_callback}}; - -static void _user_interface_page_added_cb_book_page_added (Book* _sender, Page* page, gpointer self) { -#line 288 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - user_interface_page_added_cb ((UserInterface*) self, _sender, page); -#line 795 "ui.c" -} - - -static void _user_interface_reordered_cb_book_reordered (Book* _sender, gpointer self) { -#line 289 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - user_interface_reordered_cb ((UserInterface*) self, _sender); -#line 802 "ui.c" -} - - -static void _user_interface_page_removed_cb_book_page_removed (Book* _sender, Page* page, gpointer self) { -#line 290 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - user_interface_page_removed_cb ((UserInterface*) self, _sender, page); -#line 809 "ui.c" -} - - -static void _user_interface_new_document_activate_cb_gsimple_action_activate_callback (GSimpleAction* action, GVariant* parameter, gpointer self) { -#line 19 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - user_interface_new_document_activate_cb ((UserInterface*) self); -#line 816 "ui.c" -} - - -static void _user_interface_reorder_document_activate_cb_gsimple_action_activate_callback (GSimpleAction* action, GVariant* parameter, gpointer self) { -#line 19 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - user_interface_reorder_document_activate_cb ((UserInterface*) self); -#line 823 "ui.c" -} - - -static void _user_interface_save_document_activate_cb_gsimple_action_activate_callback (GSimpleAction* action, GVariant* parameter, gpointer self) { -#line 19 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - user_interface_save_document_activate_cb ((UserInterface*) self); -#line 830 "ui.c" -} - - -static void _user_interface_save_as_document_activate_cb_gsimple_action_activate_callback (GSimpleAction* action, GVariant* parameter, gpointer self) { -#line 19 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - user_interface_save_as_document_activate_cb ((UserInterface*) self); -#line 837 "ui.c" -} - - -static void _user_interface_email_document_activate_cb_gsimple_action_activate_callback (GSimpleAction* action, GVariant* parameter, gpointer self) { -#line 19 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - user_interface_email_document_activate_cb ((UserInterface*) self); -#line 844 "ui.c" -} - - -static void _user_interface_print_document_activate_cb_gsimple_action_activate_callback (GSimpleAction* action, GVariant* parameter, gpointer self) { -#line 19 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - user_interface_print_document_activate_cb ((UserInterface*) self); -#line 851 "ui.c" -} - - -static void _user_interface_preferences_activate_cb_gsimple_action_activate_callback (GSimpleAction* action, GVariant* parameter, gpointer self) { -#line 19 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - user_interface_preferences_activate_cb ((UserInterface*) self); -#line 858 "ui.c" -} - - -static void _user_interface_help_contents_activate_cb_gsimple_action_activate_callback (GSimpleAction* action, GVariant* parameter, gpointer self) { -#line 19 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - user_interface_help_contents_activate_cb ((UserInterface*) self); -#line 865 "ui.c" -} - - -static void _user_interface_about_activate_cb_gsimple_action_activate_callback (GSimpleAction* action, GVariant* parameter, gpointer self) { -#line 19 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - user_interface_about_activate_cb ((UserInterface*) self); -#line 872 "ui.c" -} - - -static void _user_interface_quit_activate_cb_gsimple_action_activate_callback (GSimpleAction* action, GVariant* parameter, gpointer self) { -#line 19 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - user_interface_quit_activate_cb ((UserInterface*) self); -#line 879 "ui.c" -} - - -static void _user_interface_needs_saving_cb_book_needs_saving_changed (Book* _sender, gpointer self) { -#line 269 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - user_interface_needs_saving_cb ((UserInterface*) self, _sender); -#line 886 "ui.c" -} - - -UserInterface* user_interface_construct (GType object_type) { - UserInterface * self = NULL; - GSettings* _tmp0_ = NULL; - Book* _tmp1_ = NULL; - Book* _tmp2_ = NULL; - Book* _tmp3_ = NULL; - Book* _tmp4_ = NULL; - Book* _tmp5_ = NULL; - Book* _tmp6_ = NULL; - AutosaveManager* _tmp7_ = NULL; - AutosaveManager* _tmp8_ = NULL; - Book* _tmp9_ = NULL; - AutosaveManager* _tmp10_ = NULL; - Book* _tmp11_ = NULL; - guint _tmp12_ = 0U; - guint _tmp13_ = 0U; -#line 261 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - self = (UserInterface*) g_object_new (object_type, NULL); -#line 263 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp0_ = g_settings_new ("org.gnome.SimpleScan"); -#line 263 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _g_object_unref0 (self->priv->settings); -#line 263 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - self->priv->settings = _tmp0_; -#line 265 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp1_ = book_new (); -#line 265 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp2_ = _tmp1_; -#line 265 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - user_interface_set_book (self, _tmp2_); -#line 265 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _book_unref0 (_tmp2_); -#line 266 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp3_ = self->priv->_book; -#line 266 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - g_signal_connect_object (_tmp3_, "page-added", (GCallback) _user_interface_page_added_cb_book_page_added, self, 0); -#line 267 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp4_ = self->priv->_book; -#line 267 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - g_signal_connect_object (_tmp4_, "reordered", (GCallback) _user_interface_reordered_cb_book_reordered, self, 0); -#line 268 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp5_ = self->priv->_book; -#line 268 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - g_signal_connect_object (_tmp5_, "page-removed", (GCallback) _user_interface_page_removed_cb_book_page_removed, self, 0); -#line 269 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp6_ = self->priv->_book; -#line 269 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - g_signal_connect_object (_tmp6_, "needs-saving-changed", (GCallback) _user_interface_needs_saving_cb_book_needs_saving_changed, self, 0); -#line 271 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - user_interface_load (self); -#line 273 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp7_ = autosave_manager_new (); -#line 273 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _autosave_manager_unref0 (self->priv->autosave_manager); -#line 273 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - self->priv->autosave_manager = _tmp7_; -#line 274 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp8_ = self->priv->autosave_manager; -#line 274 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp9_ = self->priv->_book; -#line 274 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - autosave_manager_set_book (_tmp8_, _tmp9_); -#line 275 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp10_ = self->priv->autosave_manager; -#line 275 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - autosave_manager_load (_tmp10_); -#line 277 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp11_ = self->priv->_book; -#line 277 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp12_ = book_get_n_pages (_tmp11_); -#line 277 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp13_ = _tmp12_; -#line 277 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - if (_tmp13_ == ((guint) 0)) { -#line 964 "ui.c" - Book* _tmp14_ = NULL; -#line 279 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - user_interface_add_default_page (self); -#line 280 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp14_ = self->priv->_book; -#line 280 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - book_set_needs_saving (_tmp14_, FALSE); -#line 972 "ui.c" - } else { - BookView* _tmp15_ = NULL; - Book* _tmp16_ = NULL; - Page* _tmp17_ = NULL; - Page* _tmp18_ = NULL; -#line 283 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp15_ = self->priv->book_view; -#line 283 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp16_ = self->priv->_book; -#line 283 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp17_ = book_get_page (_tmp16_, 0); -#line 283 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp18_ = _tmp17_; -#line 283 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - book_view_set_selected_page (_tmp15_, _tmp18_); -#line 283 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _page_unref0 (_tmp18_); -#line 990 "ui.c" - } -#line 261 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - return self; -#line 994 "ui.c" -} - - -UserInterface* user_interface_new (void) { -#line 261 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - return user_interface_construct (TYPE_USER_INTERFACE); -#line 1001 "ui.c" -} - - -static gboolean user_interface_find_scan_device (UserInterface* self, const gchar* device, GtkTreeIter* iter) { - GtkTreeIter _vala_iter = {0}; - gboolean result = FALSE; - gboolean have_iter = FALSE; - GtkListStore* _tmp0_ = NULL; - GtkTreeIter _tmp1_ = {0}; - gboolean _tmp2_ = FALSE; -#line 293 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - g_return_val_if_fail (self != NULL, FALSE); -#line 293 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - g_return_val_if_fail (device != NULL, FALSE); -#line 295 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - have_iter = FALSE; -#line 297 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp0_ = self->priv->device_model; -#line 297 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp2_ = gtk_tree_model_get_iter_first ((GtkTreeModel*) _tmp0_, &_tmp1_); -#line 297 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _vala_iter = _tmp1_; -#line 297 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - if (_tmp2_) { -#line 1026 "ui.c" - { - gboolean _tmp3_ = FALSE; -#line 299 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp3_ = TRUE; -#line 299 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - while (TRUE) { -#line 1033 "ui.c" - gchar* d = NULL; - GtkListStore* _tmp8_ = NULL; - GtkTreeIter _tmp9_ = {0}; - const gchar* _tmp10_ = NULL; - const gchar* _tmp11_ = NULL; -#line 299 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - if (!_tmp3_) { -#line 1041 "ui.c" - gboolean _tmp4_ = FALSE; - gboolean _tmp5_ = FALSE; -#line 305 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp5_ = have_iter; -#line 305 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - if (!_tmp5_) { -#line 1048 "ui.c" - GtkListStore* _tmp6_ = NULL; - gboolean _tmp7_ = FALSE; -#line 305 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp6_ = self->priv->device_model; -#line 305 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp7_ = gtk_tree_model_iter_next ((GtkTreeModel*) _tmp6_, &_vala_iter); -#line 305 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp4_ = _tmp7_; -#line 1057 "ui.c" - } else { -#line 305 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp4_ = FALSE; -#line 1061 "ui.c" - } -#line 305 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - if (!_tmp4_) { -#line 305 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - break; -#line 1067 "ui.c" - } - } -#line 299 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp3_ = FALSE; -#line 302 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp8_ = self->priv->device_model; -#line 302 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp9_ = _vala_iter; -#line 302 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - gtk_tree_model_get ((GtkTreeModel*) _tmp8_, &_tmp9_, 0, &d, -1, -1); -#line 303 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp10_ = d; -#line 303 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp11_ = device; -#line 303 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - if (g_strcmp0 (_tmp10_, _tmp11_) == 0) { -#line 304 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - have_iter = TRUE; -#line 1086 "ui.c" - } -#line 299 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _g_free0 (d); -#line 1090 "ui.c" - } - } - } -#line 308 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - result = have_iter; -#line 308 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - if (iter) { -#line 308 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - *iter = _vala_iter; -#line 1100 "ui.c" - } -#line 308 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - return result; -#line 1104 "ui.c" -} - - -static void user_interface_show_error_dialog (UserInterface* self, const gchar* error_title, const gchar* error_text) { - GtkMessageDialog* dialog = NULL; - const gchar* _tmp0_ = NULL; - GtkMessageDialog* _tmp1_ = NULL; - const gchar* _tmp2_ = NULL; - const gchar* _tmp3_ = NULL; -#line 311 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - g_return_if_fail (self != NULL); -#line 311 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - g_return_if_fail (error_title != NULL); -#line 311 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - g_return_if_fail (error_text != NULL); -#line 313 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp0_ = error_title; -#line 313 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp1_ = (GtkMessageDialog*) gtk_message_dialog_new ((GtkWindow*) self, GTK_DIALOG_MODAL, GTK_MESSAGE_WARNING, GTK_BUTTONS_NONE, "%s", _tmp0_); -#line 313 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - g_object_ref_sink (_tmp1_); -#line 313 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - dialog = _tmp1_; -#line 318 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp2_ = _ ("_Close"); -#line 318 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - gtk_dialog_add_button ((GtkDialog*) dialog, _tmp2_, 0); -#line 319 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp3_ = error_text; -#line 319 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - gtk_message_dialog_format_secondary_text (dialog, "%s", _tmp3_); -#line 320 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - gtk_dialog_run ((GtkDialog*) dialog); -#line 321 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - gtk_widget_destroy ((GtkWidget*) dialog); -#line 311 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _g_object_unref0 (dialog); -#line 1142 "ui.c" -} - - -void user_interface_authorize (UserInterface* self, const gchar* resource, gchar** username, gchar** password) { - gchar* _vala_username = NULL; - gchar* _vala_password = NULL; - gchar* description = NULL; - const gchar* _tmp0_ = NULL; - const gchar* _tmp1_ = NULL; - gchar* _tmp2_ = NULL; - GtkEntry* _tmp3_ = NULL; - GtkEntry* _tmp4_ = NULL; - GtkLabel* _tmp5_ = NULL; - GtkDialog* _tmp6_ = NULL; - GtkDialog* _tmp7_ = NULL; - GtkDialog* _tmp8_ = NULL; - GtkEntry* _tmp9_ = NULL; - const gchar* _tmp10_ = NULL; - const gchar* _tmp11_ = NULL; - gchar* _tmp12_ = NULL; - GtkEntry* _tmp13_ = NULL; - const gchar* _tmp14_ = NULL; - const gchar* _tmp15_ = NULL; - gchar* _tmp16_ = NULL; -#line 324 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - g_return_if_fail (self != NULL); -#line 324 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - g_return_if_fail (resource != NULL); -#line 327 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp0_ = _ ("Username and password required to access '%s'"); -#line 327 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp1_ = resource; -#line 327 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp2_ = g_strdup_printf (_tmp0_, _tmp1_); -#line 327 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - description = _tmp2_; -#line 329 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp3_ = self->priv->username_entry; -#line 329 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - gtk_entry_set_text (_tmp3_, ""); -#line 330 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp4_ = self->priv->password_entry; -#line 330 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - gtk_entry_set_text (_tmp4_, ""); -#line 331 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp5_ = self->priv->authorize_label; -#line 331 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - gtk_label_set_text (_tmp5_, description); -#line 333 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp6_ = self->priv->authorize_dialog; -#line 333 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - gtk_widget_set_visible ((GtkWidget*) _tmp6_, TRUE); -#line 334 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp7_ = self->priv->authorize_dialog; -#line 334 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - gtk_dialog_run (_tmp7_); -#line 335 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp8_ = self->priv->authorize_dialog; -#line 335 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - gtk_widget_set_visible ((GtkWidget*) _tmp8_, FALSE); -#line 337 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp9_ = self->priv->username_entry; -#line 337 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp10_ = gtk_entry_get_text (_tmp9_); -#line 337 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp11_ = _tmp10_; -#line 337 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp12_ = g_strdup (_tmp11_); -#line 337 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _g_free0 (_vala_username); -#line 337 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _vala_username = _tmp12_; -#line 338 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp13_ = self->priv->password_entry; -#line 338 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp14_ = gtk_entry_get_text (_tmp13_); -#line 338 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp15_ = _tmp14_; -#line 338 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp16_ = g_strdup (_tmp15_); -#line 338 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _g_free0 (_vala_password); -#line 338 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _vala_password = _tmp16_; -#line 324 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _g_free0 (description); -#line 324 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - if (username) { -#line 324 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - *username = _vala_username; -#line 1233 "ui.c" - } else { -#line 324 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _g_free0 (_vala_username); -#line 1237 "ui.c" - } -#line 324 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - if (password) { -#line 324 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - *password = _vala_password; -#line 1243 "ui.c" - } else { -#line 324 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _g_free0 (_vala_password); -#line 1247 "ui.c" - } -} - - -static void user_interface_device_combo_changed_cb (UserInterface* self, GtkWidget* widget) { - gboolean _tmp0_ = FALSE; - gchar* _tmp1_ = NULL; - gchar* _tmp2_ = NULL; - gchar* _tmp3_ = NULL; - gboolean _tmp4_ = FALSE; -#line 342 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - g_return_if_fail (self != NULL); -#line 342 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - g_return_if_fail (widget != NULL); -#line 344 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp0_ = self->priv->setting_devices; -#line 344 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - if (_tmp0_) { -#line 345 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - return; -#line 1268 "ui.c" - } -#line 346 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - self->priv->user_selected_device = TRUE; -#line 347 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp1_ = user_interface_get_selected_device (self); -#line 347 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp2_ = _tmp1_; -#line 347 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp3_ = _tmp2_; -#line 347 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp4_ = _tmp3_ != NULL; -#line 347 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _g_free0 (_tmp3_); -#line 347 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - if (_tmp4_) { -#line 1284 "ui.c" - GSettings* _tmp5_ = NULL; - gchar* _tmp6_ = NULL; - gchar* _tmp7_ = NULL; - gchar* _tmp8_ = NULL; -#line 348 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp5_ = self->priv->settings; -#line 348 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp6_ = user_interface_get_selected_device (self); -#line 348 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp7_ = _tmp6_; -#line 348 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp8_ = _tmp7_; -#line 348 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - g_settings_set_string (_tmp5_, "selected-device", _tmp8_); -#line 348 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _g_free0 (_tmp8_); -#line 1301 "ui.c" - } -} - - -static void _user_interface_device_combo_changed_cb_gtk_combo_box_changed (GtkComboBox* _sender, gpointer self) { -#line 14 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - user_interface_device_combo_changed_cb ((UserInterface*) self, _sender); -#line 1309 "ui.c" -} - - -static void user_interface_update_info_bar (UserInterface* self) { - GtkMessageType type = 0; - gchar* title = NULL; - gchar* text = NULL; - gchar* image_id = NULL; - gboolean show_close_button = FALSE; - gboolean show_install_button = FALSE; - gboolean show_change_scanner_button = FALSE; - gboolean _tmp0_ = FALSE; - GtkInfoBar* _tmp20_ = NULL; - GtkMessageType _tmp21_ = 0; - GtkImage* _tmp22_ = NULL; - const gchar* _tmp23_ = NULL; - gchar* message = NULL; - const gchar* _tmp24_ = NULL; - const gchar* _tmp25_ = NULL; - gchar* _tmp26_ = NULL; - GtkLabel* _tmp27_ = NULL; - const gchar* _tmp28_ = NULL; - GtkButton* _tmp29_ = NULL; - gboolean _tmp30_ = FALSE; - GtkButton* _tmp31_ = NULL; - gboolean _tmp32_ = FALSE; - GtkButton* _tmp33_ = NULL; - gboolean _tmp34_ = FALSE; - GtkInfoBar* _tmp35_ = NULL; -#line 351 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - g_return_if_fail (self != NULL); -#line 355 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - show_close_button = FALSE; -#line 356 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - show_install_button = FALSE; -#line 357 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - show_change_scanner_button = FALSE; -#line 359 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp0_ = self->priv->have_error; -#line 359 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - if (_tmp0_) { -#line 1351 "ui.c" - gchar* _tmp1_ = NULL; - const gchar* _tmp2_ = NULL; - gchar* _tmp3_ = NULL; - const gchar* _tmp4_ = NULL; - gchar* _tmp5_ = NULL; - gboolean _tmp6_ = FALSE; -#line 361 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - type = GTK_MESSAGE_ERROR; -#line 362 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp1_ = g_strdup ("dialog-error"); -#line 362 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _g_free0 (image_id); -#line 362 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - image_id = _tmp1_; -#line 363 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp2_ = self->priv->error_title; -#line 363 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp3_ = g_strdup (_tmp2_); -#line 363 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _g_free0 (title); -#line 363 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - title = _tmp3_; -#line 364 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp4_ = self->priv->error_text; -#line 364 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp5_ = g_strdup (_tmp4_); -#line 364 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _g_free0 (text); -#line 364 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - text = _tmp5_; -#line 365 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - show_close_button = TRUE; -#line 366 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp6_ = self->priv->error_change_scanner_hint; -#line 366 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - show_change_scanner_button = _tmp6_; -#line 1388 "ui.c" - } else { - GtkListStore* _tmp7_ = NULL; - gint _tmp8_ = 0; -#line 368 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp7_ = self->priv->device_model; -#line 368 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp8_ = gtk_tree_model_iter_n_children ((GtkTreeModel*) _tmp7_, NULL); -#line 368 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - if (_tmp8_ == 0) { -#line 1398 "ui.c" - gchar* _tmp9_ = NULL; - const gchar* _tmp10_ = NULL; -#line 370 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - type = GTK_MESSAGE_WARNING; -#line 371 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp9_ = g_strdup ("dialog-warning"); -#line 371 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _g_free0 (image_id); -#line 371 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - image_id = _tmp9_; -#line 372 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp10_ = self->priv->missing_driver; -#line 372 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - if (_tmp10_ == NULL) { -#line 1413 "ui.c" - const gchar* _tmp11_ = NULL; - gchar* _tmp12_ = NULL; - const gchar* _tmp13_ = NULL; - gchar* _tmp14_ = NULL; -#line 375 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp11_ = _ ("No scanners detected"); -#line 375 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp12_ = g_strdup (_tmp11_); -#line 375 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _g_free0 (title); -#line 375 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - title = _tmp12_; -#line 377 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp13_ = _ ("Please check your scanner is connected and powered on"); -#line 377 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp14_ = g_strdup (_tmp13_); -#line 377 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _g_free0 (text); -#line 377 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - text = _tmp14_; -#line 1434 "ui.c" - } else { - const gchar* _tmp15_ = NULL; - gchar* _tmp16_ = NULL; - const gchar* _tmp17_ = NULL; - gchar* _tmp18_ = NULL; -#line 382 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp15_ = _ ("Additional software needed"); -#line 382 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp16_ = g_strdup (_tmp15_); -#line 382 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _g_free0 (title); -#line 382 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - title = _tmp16_; -#line 384 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp17_ = _ ("You need to install driver software for your scanner."); -#line 384 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp18_ = g_strdup (_tmp17_); -#line 384 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _g_free0 (text); -#line 384 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - text = _tmp18_; -#line 385 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - show_install_button = TRUE; -#line 1458 "ui.c" - } - } else { - GtkInfoBar* _tmp19_ = NULL; -#line 390 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp19_ = self->priv->info_bar; -#line 390 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - gtk_widget_set_visible ((GtkWidget*) _tmp19_, FALSE); -#line 391 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _g_free0 (image_id); -#line 391 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _g_free0 (text); -#line 391 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _g_free0 (title); -#line 391 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - return; -#line 1474 "ui.c" - } - } -#line 394 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp20_ = self->priv->info_bar; -#line 394 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp21_ = type; -#line 394 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - gtk_info_bar_set_message_type (_tmp20_, _tmp21_); -#line 395 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp22_ = self->priv->info_bar_image; -#line 395 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp23_ = image_id; -#line 395 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - gtk_image_set_from_icon_name (_tmp22_, _tmp23_, GTK_ICON_SIZE_DIALOG); -#line 396 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp24_ = title; -#line 396 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp25_ = text; -#line 396 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp26_ = g_strdup_printf ("%s\n\n%s", _tmp24_, _tmp25_); -#line 396 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - message = _tmp26_; -#line 397 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp27_ = self->priv->info_bar_label; -#line 397 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp28_ = message; -#line 397 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - gtk_label_set_markup (_tmp27_, _tmp28_); -#line 398 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp29_ = self->priv->info_bar_close_button; -#line 398 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp30_ = show_close_button; -#line 398 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - gtk_widget_set_visible ((GtkWidget*) _tmp29_, _tmp30_); -#line 399 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp31_ = self->priv->info_bar_change_scanner_button; -#line 399 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp32_ = show_change_scanner_button; -#line 399 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - gtk_widget_set_visible ((GtkWidget*) _tmp31_, _tmp32_); -#line 400 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp33_ = self->priv->info_bar_install_button; -#line 400 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp34_ = show_install_button; -#line 400 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - gtk_widget_set_visible ((GtkWidget*) _tmp33_, _tmp34_); -#line 401 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp35_ = self->priv->info_bar; -#line 401 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - gtk_widget_set_visible ((GtkWidget*) _tmp35_, TRUE); -#line 351 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _g_free0 (message); -#line 351 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _g_free0 (image_id); -#line 351 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _g_free0 (text); -#line 351 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _g_free0 (title); -#line 1533 "ui.c" -} - - -static gpointer _scan_device_ref0 (gpointer self) { -#line 420 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - return self ? scan_device_ref (self) : NULL; -#line 1540 "ui.c" -} - - -void user_interface_set_scan_devices (UserInterface* self, GList* devices, const gchar* missing_driver) { - gboolean have_selection = FALSE; - gint index = 0; - GtkTreeIter iter = {0}; - const gchar* _tmp0_ = NULL; - gchar* _tmp1_ = NULL; - gboolean _tmp2_ = FALSE; - GList* _tmp6_ = NULL; - gboolean _tmp53_ = FALSE; -#line 404 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - g_return_if_fail (self != NULL); -#line 406 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - have_selection = FALSE; -#line 410 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - self->priv->setting_devices = TRUE; -#line 412 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp0_ = missing_driver; -#line 412 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp1_ = g_strdup (_tmp0_); -#line 412 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _g_free0 (self->priv->missing_driver); -#line 412 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - self->priv->missing_driver = _tmp1_; -#line 415 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp2_ = self->priv->user_selected_device; -#line 415 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - if (_tmp2_) { -#line 1571 "ui.c" - GtkComboBox* _tmp3_ = NULL; - gint _tmp4_ = 0; - gint _tmp5_ = 0; -#line 416 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp3_ = self->priv->device_combo; -#line 416 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp4_ = gtk_combo_box_get_active (_tmp3_); -#line 416 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp5_ = _tmp4_; -#line 416 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - have_selection = _tmp5_ >= 0; -#line 1583 "ui.c" - } -#line 419 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - index = 0; -#line 420 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp6_ = devices; -#line 1589 "ui.c" - { - GList* device_collection = NULL; - GList* device_it = NULL; -#line 420 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - device_collection = _tmp6_; -#line 420 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - for (device_it = device_collection; device_it != NULL; device_it = device_it->next) { -#line 1597 "ui.c" - ScanDevice* _tmp7_ = NULL; - ScanDevice* device = NULL; -#line 420 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp7_ = _scan_device_ref0 ((ScanDevice*) device_it->data); -#line 420 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - device = _tmp7_; -#line 1604 "ui.c" - { - gint n_delete = 0; - GtkListStore* _tmp8_ = NULL; - gint _tmp9_ = 0; - GtkTreeIter _tmp10_ = {0}; - gboolean _tmp11_ = FALSE; - gint _tmp23_ = 0; - gint _tmp46_ = 0; -#line 422 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - n_delete = -1; -#line 425 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp8_ = self->priv->device_model; -#line 425 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp9_ = index; -#line 425 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp11_ = gtk_tree_model_iter_nth_child ((GtkTreeModel*) _tmp8_, &_tmp10_, NULL, _tmp9_); -#line 425 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - iter = _tmp10_; -#line 425 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - if (_tmp11_) { -#line 1625 "ui.c" - gint i = 0; -#line 427 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - i = 0; -#line 1629 "ui.c" - { - gboolean _tmp12_ = FALSE; -#line 428 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp12_ = TRUE; -#line 428 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - while (TRUE) { -#line 1636 "ui.c" - gchar* name = NULL; - gboolean matched = FALSE; - GtkListStore* _tmp15_ = NULL; - GtkTreeIter _tmp16_ = {0}; - const gchar* _tmp17_ = NULL; - ScanDevice* _tmp18_ = NULL; - const gchar* _tmp19_ = NULL; - gboolean _tmp20_ = FALSE; - gint _tmp22_ = 0; -#line 428 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - if (!_tmp12_) { -#line 1648 "ui.c" - GtkListStore* _tmp13_ = NULL; - gboolean _tmp14_ = FALSE; -#line 442 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp13_ = self->priv->device_model; -#line 442 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp14_ = gtk_tree_model_iter_next ((GtkTreeModel*) _tmp13_, &iter); -#line 442 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - if (!_tmp14_) { -#line 442 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - break; -#line 1659 "ui.c" - } - } -#line 428 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp12_ = FALSE; -#line 433 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp15_ = self->priv->device_model; -#line 433 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp16_ = iter; -#line 433 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - gtk_tree_model_get ((GtkTreeModel*) _tmp15_, &_tmp16_, 0, &name, -1, -1); -#line 434 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp17_ = name; -#line 434 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp18_ = device; -#line 434 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp19_ = _tmp18_->name; -#line 434 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - matched = g_strcmp0 (_tmp17_, _tmp19_) == 0; -#line 436 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp20_ = matched; -#line 436 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - if (_tmp20_) { -#line 1682 "ui.c" - gint _tmp21_ = 0; -#line 438 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp21_ = i; -#line 438 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - n_delete = _tmp21_; -#line 439 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _g_free0 (name); -#line 439 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - break; -#line 1692 "ui.c" - } -#line 441 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp22_ = i; -#line 441 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - i = _tmp22_ + 1; -#line 428 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _g_free0 (name); -#line 1700 "ui.c" - } - } - } -#line 446 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp23_ = n_delete; -#line 446 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - if (_tmp23_ >= 0) { -#line 1708 "ui.c" - gint i = 0; - GtkListStore* _tmp24_ = NULL; - GtkTreeIter _tmp25_ = {0}; - ScanDevice* _tmp26_ = NULL; - const gchar* _tmp27_ = NULL; -#line 451 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp24_ = self->priv->device_model; -#line 451 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp25_ = iter; -#line 451 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp26_ = device; -#line 451 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp27_ = _tmp26_->label; -#line 451 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - gtk_list_store_set (_tmp24_, &_tmp25_, 1, _tmp27_, -1, -1); -#line 1724 "ui.c" - { - gboolean _tmp28_ = FALSE; -#line 453 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - i = 0; -#line 453 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp28_ = TRUE; -#line 453 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - while (TRUE) { -#line 1733 "ui.c" - gint _tmp30_ = 0; - gint _tmp31_ = 0; - GtkListStore* _tmp32_ = NULL; - gint _tmp33_ = 0; - GtkTreeIter _tmp34_ = {0}; - GtkListStore* _tmp35_ = NULL; - GtkTreeIter _tmp36_ = {0}; -#line 453 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - if (!_tmp28_) { -#line 1743 "ui.c" - gint _tmp29_ = 0; -#line 453 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp29_ = i; -#line 453 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - i = _tmp29_ + 1; -#line 1749 "ui.c" - } -#line 453 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp28_ = FALSE; -#line 453 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp30_ = i; -#line 453 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp31_ = n_delete; -#line 453 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - if (!(_tmp30_ < _tmp31_)) { -#line 453 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - break; -#line 1761 "ui.c" - } -#line 455 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp32_ = self->priv->device_model; -#line 455 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp33_ = index; -#line 455 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - gtk_tree_model_iter_nth_child ((GtkTreeModel*) _tmp32_, &_tmp34_, NULL, _tmp33_); -#line 455 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - iter = _tmp34_; -#line 456 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp35_ = self->priv->device_model; -#line 456 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp36_ = iter; -#line 456 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - gtk_list_store_remove (_tmp35_, &_tmp36_); -#line 1777 "ui.c" - } - } - } else { - GtkListStore* _tmp37_ = NULL; - gint _tmp38_ = 0; - GtkTreeIter _tmp39_ = {0}; - GtkListStore* _tmp40_ = NULL; - GtkTreeIter _tmp41_ = {0}; - ScanDevice* _tmp42_ = NULL; - const gchar* _tmp43_ = NULL; - ScanDevice* _tmp44_ = NULL; - const gchar* _tmp45_ = NULL; -#line 461 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp37_ = self->priv->device_model; -#line 461 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp38_ = index; -#line 461 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - gtk_list_store_insert (_tmp37_, &_tmp39_, _tmp38_); -#line 461 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - iter = _tmp39_; -#line 462 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp40_ = self->priv->device_model; -#line 462 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp41_ = iter; -#line 462 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp42_ = device; -#line 462 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp43_ = _tmp42_->name; -#line 462 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp44_ = device; -#line 462 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp45_ = _tmp44_->label; -#line 462 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - gtk_list_store_set (_tmp40_, &_tmp41_, 0, _tmp43_, 1, _tmp45_, -1, -1); -#line 1812 "ui.c" - } -#line 464 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp46_ = index; -#line 464 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - index = _tmp46_ + 1; -#line 420 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _scan_device_unref0 (device); -#line 1820 "ui.c" - } - } - } -#line 468 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - while (TRUE) { -#line 1826 "ui.c" - GtkListStore* _tmp47_ = NULL; - gint _tmp48_ = 0; - GtkTreeIter _tmp49_ = {0}; - gboolean _tmp50_ = FALSE; - GtkListStore* _tmp51_ = NULL; - GtkTreeIter _tmp52_ = {0}; -#line 468 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp47_ = self->priv->device_model; -#line 468 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp48_ = index; -#line 468 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp50_ = gtk_tree_model_iter_nth_child ((GtkTreeModel*) _tmp47_, &_tmp49_, NULL, _tmp48_); -#line 468 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - iter = _tmp49_; -#line 468 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - if (!_tmp50_) { -#line 468 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - break; -#line 1845 "ui.c" - } -#line 469 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp51_ = self->priv->device_model; -#line 469 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp52_ = iter; -#line 469 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - gtk_list_store_remove (_tmp51_, &_tmp52_); -#line 1853 "ui.c" - } -#line 472 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp53_ = have_selection; -#line 472 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - if (!_tmp53_) { -#line 1859 "ui.c" - gchar* device = NULL; - GSettings* _tmp54_ = NULL; - gchar* _tmp55_ = NULL; - gboolean _tmp56_ = FALSE; - const gchar* _tmp57_ = NULL; -#line 474 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp54_ = self->priv->settings; -#line 474 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp55_ = g_settings_get_string (_tmp54_, "selected-device"); -#line 474 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - device = _tmp55_; -#line 475 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp57_ = device; -#line 475 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - if (_tmp57_ != NULL) { -#line 1875 "ui.c" - const gchar* _tmp58_ = NULL; - GtkTreeIter _tmp59_ = {0}; - gboolean _tmp60_ = FALSE; -#line 475 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp58_ = device; -#line 475 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp60_ = user_interface_find_scan_device (self, _tmp58_, &_tmp59_); -#line 475 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - iter = _tmp59_; -#line 475 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp56_ = _tmp60_; -#line 1887 "ui.c" - } else { -#line 475 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp56_ = FALSE; -#line 1891 "ui.c" - } -#line 475 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - if (_tmp56_) { -#line 1895 "ui.c" - GtkComboBox* _tmp61_ = NULL; - GtkTreeIter _tmp62_ = {0}; -#line 476 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp61_ = self->priv->device_combo; -#line 476 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp62_ = iter; -#line 476 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - gtk_combo_box_set_active_iter (_tmp61_, &_tmp62_); -#line 1904 "ui.c" - } else { - GtkComboBox* _tmp63_ = NULL; -#line 478 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp63_ = self->priv->device_combo; -#line 478 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - gtk_combo_box_set_active (_tmp63_, 0); -#line 1911 "ui.c" - } -#line 472 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _g_free0 (device); -#line 1915 "ui.c" - } -#line 481 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - self->priv->setting_devices = FALSE; -#line 483 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - user_interface_update_info_bar (self); -#line 1921 "ui.c" -} - - -static void user_interface_add_default_page (UserInterface* self) { - Page* page = NULL; - gint _tmp0_ = 0; - gint _tmp1_ = 0; - gint _tmp2_ = 0; - ScanDirection _tmp3_ = 0; - Page* _tmp4_ = NULL; - Book* _tmp5_ = NULL; - BookView* _tmp6_ = NULL; -#line 486 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - g_return_if_fail (self != NULL); -#line 488 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp0_ = self->priv->default_page_width; -#line 488 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp1_ = self->priv->default_page_height; -#line 488 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp2_ = self->priv->default_page_dpi; -#line 488 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp3_ = self->priv->default_page_scan_direction; -#line 488 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp4_ = page_new (_tmp0_, _tmp1_, _tmp2_, _tmp3_); -#line 488 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - page = _tmp4_; -#line 492 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp5_ = self->priv->_book; -#line 492 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - book_append_page (_tmp5_, page); -#line 493 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp6_ = self->priv->book_view; -#line 493 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - book_view_set_selected_page (_tmp6_, page); -#line 486 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _page_unref0 (page); -#line 1958 "ui.c" -} - - -static Block1Data* block1_data_ref (Block1Data* _data1_) { -#line 496 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - g_atomic_int_inc (&_data1_->_ref_count_); -#line 496 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - return _data1_; -#line 1967 "ui.c" -} - - -static void block1_data_unref (void * _userdata_) { - Block1Data* _data1_; - _data1_ = (Block1Data*) _userdata_; -#line 496 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - if (g_atomic_int_dec_and_test (&_data1_->_ref_count_)) { -#line 1976 "ui.c" - UserInterface* self; -#line 496 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - self = _data1_->self; -#line 496 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _g_object_unref0 (_data1_->file_type_combo); -#line 496 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _g_object_unref0 (_data1_->file_type_store); -#line 496 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _g_object_unref0 (self); -#line 496 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - g_slice_free (Block1Data, _data1_); -#line 1988 "ui.c" - } -} - - -static gpointer _g_object_ref0 (gpointer self) { -#line 524 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - return self ? g_object_ref (self) : NULL; -#line 1996 "ui.c" -} - - -static gint string_last_index_of_char (const gchar* self, gunichar c, gint start_index) { - gint result = 0; - gchar* _result_ = NULL; - gint _tmp0_ = 0; - gunichar _tmp1_ = 0U; - gchar* _tmp2_ = NULL; - gchar* _tmp3_ = NULL; -#line 1017 "/usr/share/vala-0.34/vapi/glib-2.0.vapi" - g_return_val_if_fail (self != NULL, 0); -#line 1018 "/usr/share/vala-0.34/vapi/glib-2.0.vapi" - _tmp0_ = start_index; -#line 1018 "/usr/share/vala-0.34/vapi/glib-2.0.vapi" - _tmp1_ = c; -#line 1018 "/usr/share/vala-0.34/vapi/glib-2.0.vapi" - _tmp2_ = g_utf8_strrchr (((gchar*) self) + _tmp0_, (gssize) -1, _tmp1_); -#line 1018 "/usr/share/vala-0.34/vapi/glib-2.0.vapi" - _result_ = _tmp2_; -#line 1020 "/usr/share/vala-0.34/vapi/glib-2.0.vapi" - _tmp3_ = _result_; -#line 1020 "/usr/share/vala-0.34/vapi/glib-2.0.vapi" - if (_tmp3_ != NULL) { -#line 2021 "ui.c" - gchar* _tmp4_ = NULL; -#line 1021 "/usr/share/vala-0.34/vapi/glib-2.0.vapi" - _tmp4_ = _result_; -#line 1021 "/usr/share/vala-0.34/vapi/glib-2.0.vapi" - result = (gint) (_tmp4_ - ((gchar*) self)); -#line 1021 "/usr/share/vala-0.34/vapi/glib-2.0.vapi" - return result; -#line 2029 "ui.c" - } else { -#line 1023 "/usr/share/vala-0.34/vapi/glib-2.0.vapi" - result = -1; -#line 1023 "/usr/share/vala-0.34/vapi/glib-2.0.vapi" - return result; -#line 2035 "ui.c" - } -} - - -static gchar* string_slice (const gchar* self, glong start, glong end) { - gchar* result = NULL; - glong string_length = 0L; - gint _tmp0_ = 0; - gint _tmp1_ = 0; - glong _tmp2_ = 0L; - glong _tmp5_ = 0L; - gboolean _tmp8_ = FALSE; - glong _tmp9_ = 0L; - gboolean _tmp12_ = FALSE; - glong _tmp13_ = 0L; - glong _tmp16_ = 0L; - glong _tmp17_ = 0L; - glong _tmp18_ = 0L; - glong _tmp19_ = 0L; - glong _tmp20_ = 0L; - gchar* _tmp21_ = NULL; -#line 1328 "/usr/share/vala-0.34/vapi/glib-2.0.vapi" - g_return_val_if_fail (self != NULL, NULL); -#line 1329 "/usr/share/vala-0.34/vapi/glib-2.0.vapi" - _tmp0_ = strlen (self); -#line 1329 "/usr/share/vala-0.34/vapi/glib-2.0.vapi" - _tmp1_ = _tmp0_; -#line 1329 "/usr/share/vala-0.34/vapi/glib-2.0.vapi" - string_length = (glong) _tmp1_; -#line 1330 "/usr/share/vala-0.34/vapi/glib-2.0.vapi" - _tmp2_ = start; -#line 1330 "/usr/share/vala-0.34/vapi/glib-2.0.vapi" - if (_tmp2_ < ((glong) 0)) { -#line 2069 "ui.c" - glong _tmp3_ = 0L; - glong _tmp4_ = 0L; -#line 1331 "/usr/share/vala-0.34/vapi/glib-2.0.vapi" - _tmp3_ = string_length; -#line 1331 "/usr/share/vala-0.34/vapi/glib-2.0.vapi" - _tmp4_ = start; -#line 1331 "/usr/share/vala-0.34/vapi/glib-2.0.vapi" - start = _tmp3_ + _tmp4_; -#line 2078 "ui.c" - } -#line 1333 "/usr/share/vala-0.34/vapi/glib-2.0.vapi" - _tmp5_ = end; -#line 1333 "/usr/share/vala-0.34/vapi/glib-2.0.vapi" - if (_tmp5_ < ((glong) 0)) { -#line 2084 "ui.c" - glong _tmp6_ = 0L; - glong _tmp7_ = 0L; -#line 1334 "/usr/share/vala-0.34/vapi/glib-2.0.vapi" - _tmp6_ = string_length; -#line 1334 "/usr/share/vala-0.34/vapi/glib-2.0.vapi" - _tmp7_ = end; -#line 1334 "/usr/share/vala-0.34/vapi/glib-2.0.vapi" - end = _tmp6_ + _tmp7_; -#line 2093 "ui.c" - } -#line 1336 "/usr/share/vala-0.34/vapi/glib-2.0.vapi" - _tmp9_ = start; -#line 1336 "/usr/share/vala-0.34/vapi/glib-2.0.vapi" - if (_tmp9_ >= ((glong) 0)) { -#line 2099 "ui.c" - glong _tmp10_ = 0L; - glong _tmp11_ = 0L; -#line 1336 "/usr/share/vala-0.34/vapi/glib-2.0.vapi" - _tmp10_ = start; -#line 1336 "/usr/share/vala-0.34/vapi/glib-2.0.vapi" - _tmp11_ = string_length; -#line 1336 "/usr/share/vala-0.34/vapi/glib-2.0.vapi" - _tmp8_ = _tmp10_ <= _tmp11_; -#line 2108 "ui.c" - } else { -#line 1336 "/usr/share/vala-0.34/vapi/glib-2.0.vapi" - _tmp8_ = FALSE; -#line 2112 "ui.c" - } -#line 1336 "/usr/share/vala-0.34/vapi/glib-2.0.vapi" - g_return_val_if_fail (_tmp8_, NULL); -#line 1337 "/usr/share/vala-0.34/vapi/glib-2.0.vapi" - _tmp13_ = end; -#line 1337 "/usr/share/vala-0.34/vapi/glib-2.0.vapi" - if (_tmp13_ >= ((glong) 0)) { -#line 2120 "ui.c" - glong _tmp14_ = 0L; - glong _tmp15_ = 0L; -#line 1337 "/usr/share/vala-0.34/vapi/glib-2.0.vapi" - _tmp14_ = end; -#line 1337 "/usr/share/vala-0.34/vapi/glib-2.0.vapi" - _tmp15_ = string_length; -#line 1337 "/usr/share/vala-0.34/vapi/glib-2.0.vapi" - _tmp12_ = _tmp14_ <= _tmp15_; -#line 2129 "ui.c" - } else { -#line 1337 "/usr/share/vala-0.34/vapi/glib-2.0.vapi" - _tmp12_ = FALSE; -#line 2133 "ui.c" - } -#line 1337 "/usr/share/vala-0.34/vapi/glib-2.0.vapi" - g_return_val_if_fail (_tmp12_, NULL); -#line 1338 "/usr/share/vala-0.34/vapi/glib-2.0.vapi" - _tmp16_ = start; -#line 1338 "/usr/share/vala-0.34/vapi/glib-2.0.vapi" - _tmp17_ = end; -#line 1338 "/usr/share/vala-0.34/vapi/glib-2.0.vapi" - g_return_val_if_fail (_tmp16_ <= _tmp17_, NULL); -#line 1339 "/usr/share/vala-0.34/vapi/glib-2.0.vapi" - _tmp18_ = start; -#line 1339 "/usr/share/vala-0.34/vapi/glib-2.0.vapi" - _tmp19_ = end; -#line 1339 "/usr/share/vala-0.34/vapi/glib-2.0.vapi" - _tmp20_ = start; -#line 1339 "/usr/share/vala-0.34/vapi/glib-2.0.vapi" - _tmp21_ = g_strndup (((gchar*) self) + _tmp18_, (gsize) (_tmp19_ - _tmp20_)); -#line 1339 "/usr/share/vala-0.34/vapi/glib-2.0.vapi" - result = _tmp21_; -#line 1339 "/usr/share/vala-0.34/vapi/glib-2.0.vapi" - return result; -#line 2155 "ui.c" -} - - -static void __lambda5_ (Block1Data* _data1_) { - UserInterface* self; - gchar* extension = NULL; - gchar* _tmp0_ = NULL; - GtkTreeIter i = {0}; - GtkComboBox* _tmp1_ = NULL; - GtkTreeIter _tmp2_ = {0}; - gboolean _tmp3_ = FALSE; - gchar* path = NULL; - GtkFileChooserDialog* _tmp6_ = NULL; - gchar* _tmp7_ = NULL; - gchar* filename = NULL; - const gchar* _tmp8_ = NULL; - gchar* _tmp9_ = NULL; - gint extension_index = 0; - const gchar* _tmp10_ = NULL; - gint _tmp11_ = 0; - gint _tmp12_ = 0; - const gchar* _tmp16_ = NULL; - const gchar* _tmp17_ = NULL; - gchar* _tmp18_ = NULL; - GtkFileChooserDialog* _tmp19_ = NULL; - const gchar* _tmp20_ = NULL; -#line 568 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - self = _data1_->self; -#line 570 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp0_ = g_strdup (""); -#line 570 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - extension = _tmp0_; -#line 572 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp1_ = _data1_->file_type_combo; -#line 572 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp3_ = gtk_combo_box_get_active_iter (_tmp1_, &_tmp2_); -#line 572 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - i = _tmp2_; -#line 572 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - if (_tmp3_) { -#line 2196 "ui.c" - GtkListStore* _tmp4_ = NULL; - GtkTreeIter _tmp5_ = {0}; -#line 573 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp4_ = _data1_->file_type_store; -#line 573 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp5_ = i; -#line 573 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - gtk_tree_model_get ((GtkTreeModel*) _tmp4_, &_tmp5_, 1, &extension, -1, -1); -#line 2205 "ui.c" - } -#line 575 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp6_ = self->priv->save_dialog; -#line 575 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp7_ = gtk_file_chooser_get_filename ((GtkFileChooser*) _tmp6_); -#line 575 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - path = _tmp7_; -#line 576 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp8_ = path; -#line 576 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp9_ = g_path_get_basename (_tmp8_); -#line 576 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - filename = _tmp9_; -#line 579 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp10_ = filename; -#line 579 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp11_ = string_last_index_of_char (_tmp10_, (gunichar) '.', 0); -#line 579 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - extension_index = _tmp11_; -#line 580 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp12_ = extension_index; -#line 580 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - if (_tmp12_ >= 0) { -#line 2229 "ui.c" - const gchar* _tmp13_ = NULL; - gint _tmp14_ = 0; - gchar* _tmp15_ = NULL; -#line 581 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp13_ = filename; -#line 581 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp14_ = extension_index; -#line 581 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp15_ = string_slice (_tmp13_, (glong) 0, (glong) _tmp14_); -#line 581 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _g_free0 (filename); -#line 581 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - filename = _tmp15_; -#line 2243 "ui.c" - } -#line 582 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp16_ = filename; -#line 582 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp17_ = extension; -#line 582 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp18_ = g_strconcat (_tmp16_, _tmp17_, NULL); -#line 582 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _g_free0 (filename); -#line 582 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - filename = _tmp18_; -#line 583 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp19_ = self->priv->save_dialog; -#line 583 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp20_ = filename; -#line 583 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - gtk_file_chooser_set_current_name ((GtkFileChooser*) _tmp19_, _tmp20_); -#line 568 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _g_free0 (filename); -#line 568 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _g_free0 (path); -#line 568 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _g_free0 (extension); -#line 2267 "ui.c" -} - - -static void ___lambda5__gtk_combo_box_changed (GtkComboBox* _sender, gpointer self) { -#line 568 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - __lambda5_ (self); -#line 2274 "ui.c" -} - - -static gchar* user_interface_choose_file_location (UserInterface* self) { - gchar* result = NULL; - Block1Data* _data1_; - gchar* directory = NULL; - GSettings* _tmp0_ = NULL; - gchar* _tmp1_ = NULL; - gboolean _tmp2_ = FALSE; - const gchar* _tmp3_ = NULL; - const gchar* _tmp7_ = NULL; - const gchar* _tmp8_ = NULL; - const gchar* _tmp9_ = NULL; - GtkFileChooserDialog* _tmp10_ = NULL; - GtkFileChooserDialog* _tmp11_ = NULL; - GtkFileChooserDialog* _tmp12_ = NULL; - GtkFileChooserDialog* _tmp13_ = NULL; - const gchar* _tmp14_ = NULL; - GtkFileChooserDialog* _tmp15_ = NULL; - const gchar* _tmp16_ = NULL; - GtkFileFilter* filter = NULL; - GtkFileFilter* _tmp17_ = NULL; - GtkFileFilter* _tmp18_ = NULL; - const gchar* _tmp19_ = NULL; - GtkFileFilter* _tmp20_ = NULL; - GtkFileFilter* _tmp21_ = NULL; - GtkFileChooserDialog* _tmp22_ = NULL; - GtkFileFilter* _tmp23_ = NULL; - GtkFileFilter* _tmp24_ = NULL; - GtkFileFilter* _tmp25_ = NULL; - GtkFileFilter* _tmp26_ = NULL; - const gchar* _tmp27_ = NULL; - GtkFileFilter* _tmp28_ = NULL; - GtkFileChooserDialog* _tmp29_ = NULL; - GtkFileFilter* _tmp30_ = NULL; - GtkFileFilter* _tmp31_ = NULL; - GtkListStore* _tmp32_ = NULL; - GtkTreeIter iter = {0}; - GtkListStore* _tmp33_ = NULL; - GtkTreeIter _tmp34_ = {0}; - GtkListStore* _tmp35_ = NULL; - GtkTreeIter _tmp36_ = {0}; - const gchar* _tmp37_ = NULL; - GtkListStore* _tmp38_ = NULL; - GtkTreeIter _tmp39_ = {0}; - GtkListStore* _tmp40_ = NULL; - GtkTreeIter _tmp41_ = {0}; - const gchar* _tmp42_ = NULL; - GtkListStore* _tmp43_ = NULL; - GtkTreeIter _tmp44_ = {0}; - GtkListStore* _tmp45_ = NULL; - GtkTreeIter _tmp46_ = {0}; - const gchar* _tmp47_ = NULL; - GtkBox* box = NULL; - GtkBox* _tmp48_ = NULL; - GtkBox* _tmp49_ = NULL; - GtkFileChooserDialog* _tmp50_ = NULL; - GtkBox* _tmp51_ = NULL; - GtkLabel* label = NULL; - const gchar* _tmp52_ = NULL; - GtkLabel* _tmp53_ = NULL; - GtkLabel* _tmp54_ = NULL; - GtkBox* _tmp55_ = NULL; - GtkLabel* _tmp56_ = NULL; - GtkListStore* _tmp57_ = NULL; - GtkComboBox* _tmp58_ = NULL; - GtkComboBox* _tmp59_ = NULL; - GtkCellRendererText* renderer = NULL; - GtkCellRendererText* _tmp60_ = NULL; - GtkComboBox* _tmp61_ = NULL; - GtkCellRendererText* _tmp62_ = NULL; - GtkComboBox* _tmp63_ = NULL; - GtkCellRendererText* _tmp64_ = NULL; - GtkComboBox* _tmp65_ = NULL; - GtkComboBox* _tmp66_ = NULL; - GtkBox* _tmp67_ = NULL; - GtkComboBox* _tmp68_ = NULL; - gint response = 0; - GtkFileChooserDialog* _tmp69_ = NULL; - gint _tmp70_ = 0; - gchar* uri = NULL; - gint _tmp71_ = 0; - GSettings* _tmp92_ = NULL; - GtkFileChooserDialog* _tmp93_ = NULL; - gchar* _tmp94_ = NULL; - gchar* _tmp95_ = NULL; - GtkFileChooserDialog* _tmp96_ = NULL; -#line 496 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - g_return_val_if_fail (self != NULL, NULL); -#line 496 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _data1_ = g_slice_new0 (Block1Data); -#line 496 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _data1_->_ref_count_ = 1; -#line 496 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _data1_->self = g_object_ref (self); -#line 499 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - directory = NULL; -#line 500 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp0_ = self->priv->settings; -#line 500 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp1_ = g_settings_get_string (_tmp0_, "save-directory"); -#line 500 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _g_free0 (directory); -#line 500 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - directory = _tmp1_; -#line 502 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp3_ = directory; -#line 502 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - if (_tmp3_ == NULL) { -#line 502 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp2_ = TRUE; -#line 2387 "ui.c" - } else { - const gchar* _tmp4_ = NULL; -#line 502 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp4_ = directory; -#line 502 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp2_ = g_strcmp0 (_tmp4_, "") == 0; -#line 2394 "ui.c" - } -#line 502 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - if (_tmp2_) { -#line 2398 "ui.c" - const gchar* _tmp5_ = NULL; - gchar* _tmp6_ = NULL; -#line 503 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp5_ = g_get_user_special_dir (G_USER_DIRECTORY_DOCUMENTS); -#line 503 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp6_ = g_strdup (_tmp5_); -#line 503 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _g_free0 (directory); -#line 503 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - directory = _tmp6_; -#line 2409 "ui.c" - } -#line 505 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp7_ = _ ("Save As..."); -#line 505 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp8_ = _ ("_Cancel"); -#line 505 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp9_ = _ ("_Save"); -#line 505 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp10_ = (GtkFileChooserDialog*) gtk_file_chooser_dialog_new (_tmp7_, (GtkWindow*) self, GTK_FILE_CHOOSER_ACTION_SAVE, _tmp8_, GTK_RESPONSE_CANCEL, _tmp9_, GTK_RESPONSE_ACCEPT, NULL, NULL); -#line 505 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - g_object_ref_sink (_tmp10_); -#line 505 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _g_object_unref0 (self->priv->save_dialog); -#line 505 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - self->priv->save_dialog = _tmp10_; -#line 512 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp11_ = self->priv->save_dialog; -#line 512 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - gtk_file_chooser_set_do_overwrite_confirmation ((GtkFileChooser*) _tmp11_, TRUE); -#line 513 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp12_ = self->priv->save_dialog; -#line 513 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - gtk_file_chooser_set_local_only ((GtkFileChooser*) _tmp12_, FALSE); -#line 514 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp13_ = self->priv->save_dialog; -#line 514 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp14_ = directory; -#line 514 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - gtk_file_chooser_set_current_folder ((GtkFileChooser*) _tmp13_, _tmp14_); -#line 516 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp15_ = self->priv->save_dialog; -#line 516 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp16_ = _ ("Scanned Document.pdf"); -#line 516 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - gtk_file_chooser_set_current_name ((GtkFileChooser*) _tmp15_, _tmp16_); -#line 519 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp17_ = gtk_file_filter_new (); -#line 519 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - g_object_ref_sink (_tmp17_); -#line 519 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - filter = _tmp17_; -#line 520 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp18_ = filter; -#line 520 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp19_ = _ ("Image Files"); -#line 520 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - gtk_file_filter_set_name (_tmp18_, _tmp19_); -#line 522 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp20_ = filter; -#line 522 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - gtk_file_filter_add_pixbuf_formats (_tmp20_); -#line 523 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp21_ = filter; -#line 523 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - gtk_file_filter_add_mime_type (_tmp21_, "application/pdf"); -#line 524 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp22_ = self->priv->save_dialog; -#line 524 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp23_ = filter; -#line 524 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp24_ = _g_object_ref0 (_tmp23_); -#line 524 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - gtk_file_chooser_add_filter ((GtkFileChooser*) _tmp22_, _tmp24_); -#line 525 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp25_ = gtk_file_filter_new (); -#line 525 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - g_object_ref_sink (_tmp25_); -#line 525 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _g_object_unref0 (filter); -#line 525 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - filter = _tmp25_; -#line 526 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp26_ = filter; -#line 526 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp27_ = _ ("All Files"); -#line 526 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - gtk_file_filter_set_name (_tmp26_, _tmp27_); -#line 528 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp28_ = filter; -#line 528 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - gtk_file_filter_add_pattern (_tmp28_, "*"); -#line 529 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp29_ = self->priv->save_dialog; -#line 529 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp30_ = filter; -#line 529 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp31_ = _g_object_ref0 (_tmp30_); -#line 529 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - gtk_file_chooser_add_filter ((GtkFileChooser*) _tmp29_, _tmp31_); -#line 531 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp32_ = gtk_list_store_new (2, G_TYPE_STRING, G_TYPE_STRING, -1); -#line 531 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _data1_->file_type_store = _tmp32_; -#line 533 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp33_ = _data1_->file_type_store; -#line 533 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - gtk_list_store_append (_tmp33_, &_tmp34_); -#line 533 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - iter = _tmp34_; -#line 534 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp35_ = _data1_->file_type_store; -#line 534 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp36_ = iter; -#line 534 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp37_ = _ ("PDF (multi-page document)"); -#line 534 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - gtk_list_store_set (_tmp35_, &_tmp36_, 0, _tmp37_, 1, ".pdf", -1, -1); -#line 539 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp38_ = _data1_->file_type_store; -#line 539 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - gtk_list_store_append (_tmp38_, &_tmp39_); -#line 539 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - iter = _tmp39_; -#line 540 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp40_ = _data1_->file_type_store; -#line 540 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp41_ = iter; -#line 540 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp42_ = _ ("JPEG (compressed)"); -#line 540 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - gtk_list_store_set (_tmp40_, &_tmp41_, 0, _tmp42_, 1, ".jpg", -1, -1); -#line 545 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp43_ = _data1_->file_type_store; -#line 545 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - gtk_list_store_append (_tmp43_, &_tmp44_); -#line 545 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - iter = _tmp44_; -#line 546 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp45_ = _data1_->file_type_store; -#line 546 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp46_ = iter; -#line 546 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp47_ = _ ("PNG (lossless)"); -#line 546 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - gtk_list_store_set (_tmp45_, &_tmp46_, 0, _tmp47_, 1, ".png", -1, -1); -#line 552 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp48_ = (GtkBox*) gtk_box_new (GTK_ORIENTATION_HORIZONTAL, 6); -#line 552 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - g_object_ref_sink (_tmp48_); -#line 552 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - box = _tmp48_; -#line 553 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp49_ = box; -#line 553 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - gtk_widget_set_visible ((GtkWidget*) _tmp49_, TRUE); -#line 554 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp50_ = self->priv->save_dialog; -#line 554 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp51_ = box; -#line 554 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - gtk_file_chooser_set_extra_widget ((GtkFileChooser*) _tmp50_, (GtkWidget*) _tmp51_); -#line 557 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp52_ = _ ("File format:"); -#line 557 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp53_ = (GtkLabel*) gtk_label_new (_tmp52_); -#line 557 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - g_object_ref_sink (_tmp53_); -#line 557 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - label = _tmp53_; -#line 558 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp54_ = label; -#line 558 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - gtk_widget_set_visible ((GtkWidget*) _tmp54_, TRUE); -#line 559 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp55_ = box; -#line 559 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp56_ = label; -#line 559 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - gtk_box_pack_start (_tmp55_, (GtkWidget*) _tmp56_, FALSE, FALSE, (guint) 0); -#line 561 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp57_ = _data1_->file_type_store; -#line 561 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp58_ = (GtkComboBox*) gtk_combo_box_new_with_model ((GtkTreeModel*) _tmp57_); -#line 561 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - g_object_ref_sink (_tmp58_); -#line 561 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _data1_->file_type_combo = _tmp58_; -#line 562 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp59_ = _data1_->file_type_combo; -#line 562 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - gtk_widget_set_visible ((GtkWidget*) _tmp59_, TRUE); -#line 563 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp60_ = (GtkCellRendererText*) gtk_cell_renderer_text_new (); -#line 563 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - g_object_ref_sink (_tmp60_); -#line 563 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - renderer = _tmp60_; -#line 564 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp61_ = _data1_->file_type_combo; -#line 564 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp62_ = renderer; -#line 564 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - gtk_cell_layout_pack_start ((GtkCellLayout*) _tmp61_, (GtkCellRenderer*) _tmp62_, TRUE); -#line 565 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp63_ = _data1_->file_type_combo; -#line 565 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp64_ = renderer; -#line 565 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - gtk_cell_layout_add_attribute ((GtkCellLayout*) _tmp63_, (GtkCellRenderer*) _tmp64_, "text", 0); -#line 567 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp65_ = _data1_->file_type_combo; -#line 567 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - gtk_combo_box_set_active (_tmp65_, 0); -#line 568 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp66_ = _data1_->file_type_combo; -#line 568 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - g_signal_connect_data (_tmp66_, "changed", (GCallback) ___lambda5__gtk_combo_box_changed, block1_data_ref (_data1_), (GClosureNotify) block1_data_unref, 0); -#line 585 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp67_ = box; -#line 585 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp68_ = _data1_->file_type_combo; -#line 585 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - gtk_box_pack_start (_tmp67_, (GtkWidget*) _tmp68_, FALSE, FALSE, (guint) 0); -#line 587 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp69_ = self->priv->save_dialog; -#line 587 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp70_ = gtk_dialog_run ((GtkDialog*) _tmp69_); -#line 587 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - response = _tmp70_; -#line 589 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - uri = NULL; -#line 590 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp71_ = response; -#line 590 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - if (_tmp71_ == ((gint) GTK_RESPONSE_ACCEPT)) { -#line 2635 "ui.c" - gchar* extension = NULL; - gchar* _tmp72_ = NULL; - GtkTreeIter i = {0}; - GtkComboBox* _tmp73_ = NULL; - GtkTreeIter _tmp74_ = {0}; - gboolean _tmp75_ = FALSE; - gchar* path = NULL; - GtkFileChooserDialog* _tmp78_ = NULL; - gchar* _tmp79_ = NULL; - gchar* filename = NULL; - const gchar* _tmp80_ = NULL; - gchar* _tmp81_ = NULL; - gint extension_index = 0; - const gchar* _tmp82_ = NULL; - gint _tmp83_ = 0; - gint _tmp84_ = 0; - const gchar* _tmp88_ = NULL; - GFile* _tmp89_ = NULL; - GFile* _tmp90_ = NULL; - gchar* _tmp91_ = NULL; -#line 592 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp72_ = g_strdup (""); -#line 592 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - extension = _tmp72_; -#line 594 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp73_ = _data1_->file_type_combo; -#line 594 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp75_ = gtk_combo_box_get_active_iter (_tmp73_, &_tmp74_); -#line 594 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - i = _tmp74_; -#line 594 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - if (_tmp75_) { -#line 2668 "ui.c" - GtkListStore* _tmp76_ = NULL; - GtkTreeIter _tmp77_ = {0}; -#line 595 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp76_ = _data1_->file_type_store; -#line 595 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp77_ = i; -#line 595 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - gtk_tree_model_get ((GtkTreeModel*) _tmp76_, &_tmp77_, 1, &extension, -1, -1); -#line 2677 "ui.c" - } -#line 597 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp78_ = self->priv->save_dialog; -#line 597 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp79_ = gtk_file_chooser_get_filename ((GtkFileChooser*) _tmp78_); -#line 597 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - path = _tmp79_; -#line 598 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp80_ = path; -#line 598 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp81_ = g_path_get_basename (_tmp80_); -#line 598 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - filename = _tmp81_; -#line 600 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp82_ = filename; -#line 600 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp83_ = string_last_index_of_char (_tmp82_, (gunichar) '.', 0); -#line 600 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - extension_index = _tmp83_; -#line 601 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp84_ = extension_index; -#line 601 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - if (_tmp84_ < 0) { -#line 2701 "ui.c" - const gchar* _tmp85_ = NULL; - const gchar* _tmp86_ = NULL; - gchar* _tmp87_ = NULL; -#line 602 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp85_ = path; -#line 602 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp86_ = extension; -#line 602 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp87_ = g_strconcat (_tmp85_, _tmp86_, NULL); -#line 602 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _g_free0 (path); -#line 602 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - path = _tmp87_; -#line 2715 "ui.c" - } -#line 604 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp88_ = path; -#line 604 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp89_ = g_file_new_for_path (_tmp88_); -#line 604 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp90_ = _tmp89_; -#line 604 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp91_ = g_file_get_uri (_tmp90_); -#line 604 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _g_free0 (uri); -#line 604 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - uri = _tmp91_; -#line 604 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _g_object_unref0 (_tmp90_); -#line 590 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _g_free0 (filename); -#line 590 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _g_free0 (path); -#line 590 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _g_free0 (extension); -#line 2737 "ui.c" - } -#line 607 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp92_ = self->priv->settings; -#line 607 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp93_ = self->priv->save_dialog; -#line 607 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp94_ = gtk_file_chooser_get_current_folder ((GtkFileChooser*) _tmp93_); -#line 607 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp95_ = _tmp94_; -#line 607 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - g_settings_set_string (_tmp92_, "save-directory", _tmp95_); -#line 607 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _g_free0 (_tmp95_); -#line 609 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp96_ = self->priv->save_dialog; -#line 609 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - gtk_widget_destroy ((GtkWidget*) _tmp96_); -#line 610 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _g_object_unref0 (self->priv->save_dialog); -#line 610 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - self->priv->save_dialog = NULL; -#line 612 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - result = uri; -#line 612 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _g_object_unref0 (renderer); -#line 612 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _g_object_unref0 (label); -#line 612 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _g_object_unref0 (box); -#line 612 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _g_object_unref0 (filter); -#line 612 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _g_free0 (directory); -#line 612 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - block1_data_unref (_data1_); -#line 612 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _data1_ = NULL; -#line 612 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - return result; -#line 2777 "ui.c" -} - - -static gboolean user_interface_save_document (UserInterface* self, gboolean force_choose_location) { - gboolean result = FALSE; - gchar* uri = NULL; - gboolean _tmp0_ = FALSE; - const gchar* _tmp1_ = NULL; - const gchar* _tmp6_ = NULL; - GFile* file = NULL; - const gchar* _tmp7_ = NULL; - GFile* _tmp8_ = NULL; - const gchar* _tmp9_ = NULL; - gchar* uri_lower = NULL; - const gchar* _tmp10_ = NULL; - gchar* _tmp11_ = NULL; - gchar* format = NULL; - gchar* _tmp12_ = NULL; - const gchar* _tmp13_ = NULL; - gboolean _tmp14_ = FALSE; - const gchar* _tmp39_ = NULL; - gchar* _tmp40_ = NULL; - Book* _tmp41_ = NULL; - GError * _inner_error_ = NULL; -#line 615 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - g_return_val_if_fail (self != NULL, FALSE); -#line 618 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp1_ = self->priv->book_uri; -#line 618 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - if (_tmp1_ != NULL) { -#line 2808 "ui.c" - gboolean _tmp2_ = FALSE; -#line 618 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp2_ = force_choose_location; -#line 618 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp0_ = !_tmp2_; -#line 2814 "ui.c" - } else { -#line 618 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp0_ = FALSE; -#line 2818 "ui.c" - } -#line 618 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - if (_tmp0_) { -#line 2822 "ui.c" - const gchar* _tmp3_ = NULL; - gchar* _tmp4_ = NULL; -#line 619 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp3_ = self->priv->book_uri; -#line 619 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp4_ = g_strdup (_tmp3_); -#line 619 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _g_free0 (uri); -#line 619 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - uri = _tmp4_; -#line 2833 "ui.c" - } else { - gchar* _tmp5_ = NULL; -#line 621 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp5_ = user_interface_choose_file_location (self); -#line 621 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _g_free0 (uri); -#line 621 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - uri = _tmp5_; -#line 2842 "ui.c" - } -#line 622 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp6_ = uri; -#line 622 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - if (_tmp6_ == NULL) { -#line 623 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - result = FALSE; -#line 623 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _g_free0 (uri); -#line 623 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - return result; -#line 2854 "ui.c" - } -#line 625 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp7_ = uri; -#line 625 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp8_ = g_file_new_for_uri (_tmp7_); -#line 625 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - file = _tmp8_; -#line 627 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp9_ = uri; -#line 627 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - g_debug ("ui.vala:627: Saving to '%s'", _tmp9_); -#line 629 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp10_ = uri; -#line 629 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp11_ = g_utf8_strdown (_tmp10_, (gssize) -1); -#line 629 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - uri_lower = _tmp11_; -#line 630 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp12_ = g_strdup ("jpeg"); -#line 630 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - format = _tmp12_; -#line 631 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp13_ = uri_lower; -#line 631 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp14_ = g_str_has_suffix (_tmp13_, ".pdf"); -#line 631 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - if (_tmp14_) { -#line 2882 "ui.c" - gchar* _tmp15_ = NULL; -#line 632 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp15_ = g_strdup ("pdf"); -#line 632 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _g_free0 (format); -#line 632 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - format = _tmp15_; -#line 2890 "ui.c" - } else { - const gchar* _tmp16_ = NULL; - gboolean _tmp17_ = FALSE; -#line 633 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp16_ = uri_lower; -#line 633 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp17_ = g_str_has_suffix (_tmp16_, ".ps"); -#line 633 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - if (_tmp17_) { -#line 2900 "ui.c" - gchar* _tmp18_ = NULL; -#line 634 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp18_ = g_strdup ("ps"); -#line 634 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _g_free0 (format); -#line 634 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - format = _tmp18_; -#line 2908 "ui.c" - } else { - const gchar* _tmp19_ = NULL; - gboolean _tmp20_ = FALSE; -#line 635 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp19_ = uri_lower; -#line 635 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp20_ = g_str_has_suffix (_tmp19_, ".png"); -#line 635 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - if (_tmp20_) { -#line 2918 "ui.c" - gchar* _tmp21_ = NULL; -#line 636 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp21_ = g_strdup ("png"); -#line 636 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _g_free0 (format); -#line 636 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - format = _tmp21_; -#line 2926 "ui.c" - } else { - gboolean _tmp22_ = FALSE; - const gchar* _tmp23_ = NULL; - gboolean _tmp24_ = FALSE; -#line 637 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp23_ = uri_lower; -#line 637 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp24_ = g_str_has_suffix (_tmp23_, ".tif"); -#line 637 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - if (_tmp24_) { -#line 637 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp22_ = TRUE; -#line 2939 "ui.c" - } else { - const gchar* _tmp25_ = NULL; - gboolean _tmp26_ = FALSE; -#line 637 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp25_ = uri_lower; -#line 637 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp26_ = g_str_has_suffix (_tmp25_, ".tiff"); -#line 637 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp22_ = _tmp26_; -#line 2949 "ui.c" - } -#line 637 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - if (_tmp22_) { -#line 2953 "ui.c" - gchar* _tmp27_ = NULL; -#line 638 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp27_ = g_strdup ("tiff"); -#line 638 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _g_free0 (format); -#line 638 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - format = _tmp27_; -#line 2961 "ui.c" - } - } - } - } -#line 640 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - user_interface_show_progress_dialog (self); -#line 2968 "ui.c" - { - Book* _tmp28_ = NULL; - const gchar* _tmp29_ = NULL; - gint _tmp30_ = 0; - gint _tmp31_ = 0; - GFile* _tmp32_ = NULL; -#line 643 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp28_ = self->priv->_book; -#line 643 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp29_ = format; -#line 643 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp30_ = user_interface_get_quality (self); -#line 643 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp31_ = _tmp30_; -#line 643 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp32_ = file; -#line 643 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - book_save (_tmp28_, _tmp29_, _tmp31_, _tmp32_, &_inner_error_); -#line 643 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - if (G_UNLIKELY (_inner_error_ != NULL)) { -#line 2989 "ui.c" - goto __catch17_g_error; - } - } - goto __finally17; - __catch17_g_error: - { - GError* e = NULL; - GError* _tmp33_ = NULL; - const gchar* _tmp34_ = NULL; - const gchar* _tmp35_ = NULL; - GError* _tmp36_ = NULL; - const gchar* _tmp37_ = NULL; -#line 641 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - e = _inner_error_; -#line 641 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _inner_error_ = NULL; -#line 647 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - user_interface_hide_progress_dialog (self); -#line 648 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp33_ = e; -#line 648 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp34_ = _tmp33_->message; -#line 648 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - g_warning ("ui.vala:648: Error saving file: %s", _tmp34_); -#line 649 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp35_ = _ ("Failed to save file"); -#line 649 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp36_ = e; -#line 649 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp37_ = _tmp36_->message; -#line 649 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - user_interface_show_error (self, _tmp35_, _tmp37_, FALSE); -#line 653 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - result = FALSE; -#line 653 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _g_error_free0 (e); -#line 653 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _g_free0 (format); -#line 653 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _g_free0 (uri_lower); -#line 653 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _g_object_unref0 (file); -#line 653 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _g_free0 (uri); -#line 653 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - return result; -#line 3036 "ui.c" - } - __finally17: -#line 641 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - if (G_UNLIKELY (_inner_error_ != NULL)) { -#line 3041 "ui.c" - gboolean _tmp38_ = FALSE; -#line 641 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _g_free0 (format); -#line 641 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _g_free0 (uri_lower); -#line 641 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _g_object_unref0 (file); -#line 641 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _g_free0 (uri); -#line 641 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - g_critical ("file %s: line %d: uncaught error: %s (%s, %d)", __FILE__, __LINE__, _inner_error_->message, g_quark_to_string (_inner_error_->domain), _inner_error_->code); -#line 641 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - g_clear_error (&_inner_error_); -#line 641 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - return _tmp38_; -#line 3057 "ui.c" - } -#line 656 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp39_ = uri; -#line 656 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp40_ = g_strdup (_tmp39_); -#line 656 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _g_free0 (self->priv->book_uri); -#line 656 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - self->priv->book_uri = _tmp40_; -#line 657 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp41_ = self->priv->_book; -#line 657 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - book_set_needs_saving (_tmp41_, FALSE); -#line 658 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - result = TRUE; -#line 658 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _g_free0 (format); -#line 658 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _g_free0 (uri_lower); -#line 658 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _g_object_unref0 (file); -#line 658 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _g_free0 (uri); -#line 658 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - return result; -#line 3083 "ui.c" -} - - -static gboolean user_interface_prompt_to_save (UserInterface* self, const gchar* title, const gchar* discard_label) { - gboolean result = FALSE; - Book* _tmp0_ = NULL; - gboolean _tmp1_ = FALSE; - gboolean _tmp2_ = FALSE; - GtkMessageDialog* dialog = NULL; - const gchar* _tmp3_ = NULL; - GtkMessageDialog* _tmp4_ = NULL; - GtkMessageDialog* _tmp5_ = NULL; - const gchar* _tmp6_ = NULL; - GtkMessageDialog* _tmp7_ = NULL; - const gchar* _tmp8_ = NULL; - GtkMessageDialog* _tmp9_ = NULL; - const gchar* _tmp10_ = NULL; - GtkMessageDialog* _tmp11_ = NULL; - const gchar* _tmp12_ = NULL; - gint response = 0; - GtkMessageDialog* _tmp13_ = NULL; - gint _tmp14_ = 0; - GtkMessageDialog* _tmp15_ = NULL; - gint _tmp16_ = 0; -#line 661 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - g_return_val_if_fail (self != NULL, FALSE); -#line 661 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - g_return_val_if_fail (title != NULL, FALSE); -#line 661 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - g_return_val_if_fail (discard_label != NULL, FALSE); -#line 663 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp0_ = self->priv->_book; -#line 663 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp1_ = book_get_needs_saving (_tmp0_); -#line 663 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp2_ = _tmp1_; -#line 663 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - if (!_tmp2_) { -#line 664 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - result = TRUE; -#line 664 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - return result; -#line 3126 "ui.c" - } -#line 666 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp3_ = title; -#line 666 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp4_ = (GtkMessageDialog*) gtk_message_dialog_new ((GtkWindow*) self, GTK_DIALOG_MODAL, GTK_MESSAGE_WARNING, GTK_BUTTONS_NONE, "%s", _tmp3_); -#line 666 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - g_object_ref_sink (_tmp4_); -#line 666 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - dialog = _tmp4_; -#line 671 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp5_ = dialog; -#line 671 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp6_ = _ ("If you don't save, changes will be permanently lost."); -#line 671 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - gtk_message_dialog_format_secondary_text (_tmp5_, "%s", _tmp6_); -#line 674 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp7_ = dialog; -#line 674 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp8_ = discard_label; -#line 674 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - gtk_dialog_add_button ((GtkDialog*) _tmp7_, _tmp8_, (gint) GTK_RESPONSE_NO); -#line 675 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp9_ = dialog; -#line 675 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp10_ = _ ("_Cancel"); -#line 675 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - gtk_dialog_add_button ((GtkDialog*) _tmp9_, _tmp10_, (gint) GTK_RESPONSE_CANCEL); -#line 676 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp11_ = dialog; -#line 676 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp12_ = _ ("_Save"); -#line 676 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - gtk_dialog_add_button ((GtkDialog*) _tmp11_, _tmp12_, (gint) GTK_RESPONSE_YES); -#line 678 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp13_ = dialog; -#line 678 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp14_ = gtk_dialog_run ((GtkDialog*) _tmp13_); -#line 678 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - response = _tmp14_; -#line 679 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp15_ = dialog; -#line 679 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - gtk_widget_destroy ((GtkWidget*) _tmp15_); -#line 681 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp16_ = response; -#line 681 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - switch (_tmp16_) { -#line 681 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - case GTK_RESPONSE_YES: -#line 3176 "ui.c" - { - gboolean _tmp17_ = FALSE; -#line 684 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp17_ = user_interface_save_document (self, FALSE); -#line 684 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - if (_tmp17_) { -#line 685 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - result = TRUE; -#line 685 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _g_object_unref0 (dialog); -#line 685 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - return result; -#line 3189 "ui.c" - } else { -#line 687 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - result = FALSE; -#line 687 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _g_object_unref0 (dialog); -#line 687 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - return result; -#line 3197 "ui.c" - } - } -#line 681 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - case GTK_RESPONSE_NO: -#line 3202 "ui.c" - { -#line 689 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - result = TRUE; -#line 689 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _g_object_unref0 (dialog); -#line 689 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - return result; -#line 3210 "ui.c" - } - default: - { -#line 691 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - result = FALSE; -#line 691 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _g_object_unref0 (dialog); -#line 691 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - return result; -#line 3220 "ui.c" - } - } -#line 661 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _g_object_unref0 (dialog); -#line 3225 "ui.c" -} - - -static void user_interface_clear_document (UserInterface* self) { - Book* _tmp0_ = NULL; - Book* _tmp1_ = NULL; - GtkMenuItem* _tmp2_ = NULL; - GtkMenuItem* _tmp3_ = NULL; -#line 695 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - g_return_if_fail (self != NULL); -#line 697 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp0_ = self->priv->_book; -#line 697 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - book_clear (_tmp0_); -#line 698 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - user_interface_add_default_page (self); -#line 699 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _g_free0 (self->priv->book_uri); -#line 699 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - self->priv->book_uri = NULL; -#line 700 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp1_ = self->priv->_book; -#line 700 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - book_set_needs_saving (_tmp1_, FALSE); -#line 701 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp2_ = self->priv->save_as_menuitem; -#line 701 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - gtk_widget_set_sensitive ((GtkWidget*) _tmp2_, FALSE); -#line 702 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp3_ = self->priv->copy_to_clipboard_menuitem; -#line 702 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - gtk_widget_set_sensitive ((GtkWidget*) _tmp3_, FALSE); -#line 3258 "ui.c" -} - - -static void user_interface_new_document (UserInterface* self) { - const gchar* _tmp0_ = NULL; - const gchar* _tmp1_ = NULL; - gboolean _tmp2_ = FALSE; - gboolean _tmp3_ = FALSE; - gboolean _tmp4_ = FALSE; -#line 705 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - g_return_if_fail (self != NULL); -#line 707 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp0_ = _ ("Save current document?"); -#line 707 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp1_ = _ ("Discard Changes"); -#line 707 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp2_ = user_interface_prompt_to_save (self, _tmp0_, _tmp1_); -#line 707 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - if (!_tmp2_) { -#line 711 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - return; -#line 3280 "ui.c" - } -#line 713 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp3_ = user_interface_get_scanning (self); -#line 713 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp4_ = _tmp3_; -#line 713 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - if (_tmp4_) { -#line 714 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - g_signal_emit_by_name (self, "stop-scan"); -#line 3290 "ui.c" - } -#line 715 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - user_interface_clear_document (self); -#line 3294 "ui.c" -} - - -static void user_interface_new_button_clicked_cb (UserInterface* self, GtkWidget* widget) { -#line 719 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - g_return_if_fail (self != NULL); -#line 719 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - g_return_if_fail (widget != NULL); -#line 721 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - user_interface_new_document (self); -#line 3305 "ui.c" -} - - -static void _user_interface_new_button_clicked_cb_gtk_button_clicked (GtkButton* _sender, gpointer self) { -#line 14 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - user_interface_new_button_clicked_cb ((UserInterface*) self, _sender); -#line 3312 "ui.c" -} - - -void user_interface_new_document_activate_cb (UserInterface* self) { -#line 724 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - g_return_if_fail (self != NULL); -#line 726 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - user_interface_new_document (self); -#line 3321 "ui.c" -} - - -static void user_interface_set_document_hint (UserInterface* self, const gchar* document_hint, gboolean save) { - const gchar* _tmp0_ = NULL; - gchar* _tmp1_ = NULL; - const gchar* _tmp2_ = NULL; - gboolean _tmp10_ = FALSE; -#line 729 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - g_return_if_fail (self != NULL); -#line 729 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - g_return_if_fail (document_hint != NULL); -#line 731 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp0_ = document_hint; -#line 731 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp1_ = g_strdup (_tmp0_); -#line 731 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _g_free0 (self->priv->document_hint); -#line 731 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - self->priv->document_hint = _tmp1_; -#line 733 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp2_ = document_hint; -#line 733 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - if (g_strcmp0 (_tmp2_, "text") == 0) { -#line 3346 "ui.c" - GtkRadioMenuItem* _tmp3_ = NULL; - GtkRadioMenuItem* _tmp4_ = NULL; - GtkRadioMenuItem* _tmp5_ = NULL; -#line 735 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp3_ = self->priv->text_button_menuitem; -#line 735 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - gtk_check_menu_item_set_active ((GtkCheckMenuItem*) _tmp3_, TRUE); -#line 736 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp4_ = self->priv->text_button_hb_menuitem; -#line 736 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - gtk_check_menu_item_set_active ((GtkCheckMenuItem*) _tmp4_, TRUE); -#line 737 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp5_ = self->priv->text_menuitem; -#line 737 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - gtk_check_menu_item_set_active ((GtkCheckMenuItem*) _tmp5_, TRUE); -#line 3362 "ui.c" - } else { - const gchar* _tmp6_ = NULL; -#line 739 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp6_ = document_hint; -#line 739 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - if (g_strcmp0 (_tmp6_, "photo") == 0) { -#line 3369 "ui.c" - GtkRadioMenuItem* _tmp7_ = NULL; - GtkRadioMenuItem* _tmp8_ = NULL; - GtkRadioMenuItem* _tmp9_ = NULL; -#line 741 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp7_ = self->priv->photo_button_menuitem; -#line 741 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - gtk_check_menu_item_set_active ((GtkCheckMenuItem*) _tmp7_, TRUE); -#line 742 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp8_ = self->priv->photo_button_hb_menuitem; -#line 742 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - gtk_check_menu_item_set_active ((GtkCheckMenuItem*) _tmp8_, TRUE); -#line 743 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp9_ = self->priv->photo_menuitem; -#line 743 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - gtk_check_menu_item_set_active ((GtkCheckMenuItem*) _tmp9_, TRUE); -#line 3385 "ui.c" - } - } -#line 746 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp10_ = save; -#line 746 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - if (_tmp10_) { -#line 3392 "ui.c" - GSettings* _tmp11_ = NULL; - const gchar* _tmp12_ = NULL; -#line 747 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp11_ = self->priv->settings; -#line 747 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp12_ = document_hint; -#line 747 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - g_settings_set_string (_tmp11_, "document-type", _tmp12_); -#line 3401 "ui.c" - } -} - - -static void user_interface_text_menuitem_toggled_cb (UserInterface* self, GtkCheckMenuItem* widget) { - GtkCheckMenuItem* _tmp0_ = NULL; - gboolean _tmp1_ = FALSE; - gboolean _tmp2_ = FALSE; -#line 751 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - g_return_if_fail (self != NULL); -#line 751 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - g_return_if_fail (widget != NULL); -#line 753 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp0_ = widget; -#line 753 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp1_ = gtk_check_menu_item_get_active (_tmp0_); -#line 753 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp2_ = _tmp1_; -#line 753 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - if (_tmp2_) { -#line 754 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - user_interface_set_document_hint (self, "text", TRUE); -#line 3424 "ui.c" - } -} - - -static void _user_interface_text_menuitem_toggled_cb_gtk_check_menu_item_toggled (GtkCheckMenuItem* _sender, gpointer self) { -#line 14 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - user_interface_text_menuitem_toggled_cb ((UserInterface*) self, _sender); -#line 3432 "ui.c" -} - - -static void user_interface_photo_menuitem_toggled_cb (UserInterface* self, GtkCheckMenuItem* widget) { - GtkCheckMenuItem* _tmp0_ = NULL; - gboolean _tmp1_ = FALSE; - gboolean _tmp2_ = FALSE; -#line 758 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - g_return_if_fail (self != NULL); -#line 758 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - g_return_if_fail (widget != NULL); -#line 760 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp0_ = widget; -#line 760 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp1_ = gtk_check_menu_item_get_active (_tmp0_); -#line 760 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp2_ = _tmp1_; -#line 760 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - if (_tmp2_) { -#line 761 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - user_interface_set_document_hint (self, "photo", TRUE); -#line 3454 "ui.c" - } -} - - -static void _user_interface_photo_menuitem_toggled_cb_gtk_check_menu_item_toggled (GtkCheckMenuItem* _sender, gpointer self) { -#line 14 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - user_interface_photo_menuitem_toggled_cb ((UserInterface*) self, _sender); -#line 3462 "ui.c" -} - - -static void user_interface_set_page_side (UserInterface* self, ScanType page_side) { - GtkTreeIter iter = {0}; - GtkListStore* _tmp0_ = NULL; - GtkTreeIter _tmp1_ = {0}; - gboolean _tmp2_ = FALSE; -#line 764 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - g_return_if_fail (self != NULL); -#line 768 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp0_ = self->priv->page_side_model; -#line 768 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp2_ = gtk_tree_model_get_iter_first ((GtkTreeModel*) _tmp0_, &_tmp1_); -#line 768 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - iter = _tmp1_; -#line 768 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - if (_tmp2_) { -#line 3481 "ui.c" - { - gboolean _tmp3_ = FALSE; -#line 770 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp3_ = TRUE; -#line 770 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - while (TRUE) { -#line 3488 "ui.c" - gint s = 0; - GtkListStore* _tmp6_ = NULL; - GtkTreeIter _tmp7_ = {0}; - gint _tmp8_ = 0; - ScanType _tmp9_ = 0; -#line 770 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - if (!_tmp3_) { -#line 3496 "ui.c" - GtkListStore* _tmp4_ = NULL; - gboolean _tmp5_ = FALSE; -#line 779 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp4_ = self->priv->page_side_model; -#line 779 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp5_ = gtk_tree_model_iter_next ((GtkTreeModel*) _tmp4_, &iter); -#line 779 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - if (!_tmp5_) { -#line 779 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - break; -#line 3507 "ui.c" - } - } -#line 770 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp3_ = FALSE; -#line 773 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp6_ = self->priv->page_side_model; -#line 773 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp7_ = iter; -#line 773 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - gtk_tree_model_get ((GtkTreeModel*) _tmp6_, &_tmp7_, 0, &s, -1, -1); -#line 774 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp8_ = s; -#line 774 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp9_ = page_side; -#line 774 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - if (_tmp8_ == ((gint) _tmp9_)) { -#line 3524 "ui.c" - GtkComboBox* _tmp10_ = NULL; - GtkTreeIter _tmp11_ = {0}; -#line 776 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp10_ = self->priv->page_side_combo; -#line 776 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp11_ = iter; -#line 776 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - gtk_combo_box_set_active_iter (_tmp10_, &_tmp11_); -#line 777 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - return; -#line 3535 "ui.c" - } - } - } - } -} - - -static void user_interface_set_paper_size (UserInterface* self, gint width, gint height) { - GtkTreeIter iter = {0}; - gboolean have_iter = FALSE; - gboolean _tmp14_ = FALSE; - gboolean _tmp18_ = FALSE; -#line 783 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - g_return_if_fail (self != NULL); -#line 3550 "ui.c" - { - GtkListStore* _tmp0_ = NULL; - GtkTreeIter _tmp1_ = {0}; - gboolean _tmp2_ = FALSE; - gboolean _tmp3_ = FALSE; -#line 788 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp0_ = self->priv->paper_size_model; -#line 788 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp2_ = gtk_tree_model_get_iter_first ((GtkTreeModel*) _tmp0_, &_tmp1_); -#line 788 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - iter = _tmp1_; -#line 788 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - have_iter = _tmp2_; -#line 788 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp3_ = TRUE; -#line 788 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - while (TRUE) { -#line 3568 "ui.c" - gboolean _tmp6_ = FALSE; - gint w = 0; - gint h = 0; - GtkListStore* _tmp7_ = NULL; - GtkTreeIter _tmp8_ = {0}; - gboolean _tmp9_ = FALSE; - gint _tmp10_ = 0; - gint _tmp11_ = 0; -#line 788 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - if (!_tmp3_) { -#line 3579 "ui.c" - GtkListStore* _tmp4_ = NULL; - gboolean _tmp5_ = FALSE; -#line 790 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp4_ = self->priv->paper_size_model; -#line 790 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp5_ = gtk_tree_model_iter_next ((GtkTreeModel*) _tmp4_, &iter); -#line 790 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - have_iter = _tmp5_; -#line 3588 "ui.c" - } -#line 788 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp3_ = FALSE; -#line 789 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp6_ = have_iter; -#line 789 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - if (!_tmp6_) { -#line 789 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - break; -#line 3598 "ui.c" - } -#line 793 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp7_ = self->priv->paper_size_model; -#line 793 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp8_ = iter; -#line 793 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - gtk_tree_model_get ((GtkTreeModel*) _tmp7_, &_tmp8_, 0, &w, 1, &h, -1, -1); -#line 794 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp10_ = w; -#line 794 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp11_ = width; -#line 794 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - if (_tmp10_ == _tmp11_) { -#line 3612 "ui.c" - gint _tmp12_ = 0; - gint _tmp13_ = 0; -#line 794 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp12_ = h; -#line 794 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp13_ = height; -#line 794 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp9_ = _tmp12_ == _tmp13_; -#line 3621 "ui.c" - } else { -#line 794 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp9_ = FALSE; -#line 3625 "ui.c" - } -#line 794 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - if (_tmp9_) { -#line 795 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - break; -#line 3631 "ui.c" - } - } - } -#line 798 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp14_ = have_iter; -#line 798 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - if (!_tmp14_) { -#line 3639 "ui.c" - GtkListStore* _tmp15_ = NULL; - GtkTreeIter _tmp16_ = {0}; - gboolean _tmp17_ = FALSE; -#line 799 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp15_ = self->priv->paper_size_model; -#line 799 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp17_ = gtk_tree_model_get_iter_first ((GtkTreeModel*) _tmp15_, &_tmp16_); -#line 799 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - iter = _tmp16_; -#line 799 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - have_iter = _tmp17_; -#line 3651 "ui.c" - } -#line 800 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp18_ = have_iter; -#line 800 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - if (_tmp18_) { -#line 3657 "ui.c" - GtkComboBox* _tmp19_ = NULL; - GtkTreeIter _tmp20_ = {0}; -#line 801 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp19_ = self->priv->paper_size_combo; -#line 801 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp20_ = iter; -#line 801 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - gtk_combo_box_set_active_iter (_tmp19_, &_tmp20_); -#line 3666 "ui.c" - } -} - - -static gint user_interface_get_text_dpi (UserInterface* self) { - gint result = 0; - GtkTreeIter iter = {0}; - gint dpi = 0; - GtkComboBox* _tmp0_ = NULL; - GtkTreeIter _tmp1_ = {0}; - gboolean _tmp2_ = FALSE; -#line 804 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - g_return_val_if_fail (self != NULL, 0); -#line 807 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - dpi = USER_INTERFACE_DEFAULT_TEXT_DPI; -#line 809 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp0_ = self->priv->text_dpi_combo; -#line 809 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp2_ = gtk_combo_box_get_active_iter (_tmp0_, &_tmp1_); -#line 809 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - iter = _tmp1_; -#line 809 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - if (_tmp2_) { -#line 3690 "ui.c" - GtkListStore* _tmp3_ = NULL; - GtkTreeIter _tmp4_ = {0}; -#line 810 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp3_ = self->priv->text_dpi_model; -#line 810 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp4_ = iter; -#line 810 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - gtk_tree_model_get ((GtkTreeModel*) _tmp3_, &_tmp4_, 0, &dpi, -1, -1); -#line 3699 "ui.c" - } -#line 812 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - result = dpi; -#line 812 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - return result; -#line 3705 "ui.c" -} - - -static gint user_interface_get_photo_dpi (UserInterface* self) { - gint result = 0; - GtkTreeIter iter = {0}; - gint dpi = 0; - GtkComboBox* _tmp0_ = NULL; - GtkTreeIter _tmp1_ = {0}; - gboolean _tmp2_ = FALSE; -#line 815 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - g_return_val_if_fail (self != NULL, 0); -#line 818 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - dpi = USER_INTERFACE_DEFAULT_PHOTO_DPI; -#line 820 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp0_ = self->priv->photo_dpi_combo; -#line 820 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp2_ = gtk_combo_box_get_active_iter (_tmp0_, &_tmp1_); -#line 820 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - iter = _tmp1_; -#line 820 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - if (_tmp2_) { -#line 3728 "ui.c" - GtkListStore* _tmp3_ = NULL; - GtkTreeIter _tmp4_ = {0}; -#line 821 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp3_ = self->priv->photo_dpi_model; -#line 821 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp4_ = iter; -#line 821 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - gtk_tree_model_get ((GtkTreeModel*) _tmp3_, &_tmp4_, 0, &dpi, -1, -1); -#line 3737 "ui.c" - } -#line 823 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - result = dpi; -#line 823 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - return result; -#line 3743 "ui.c" -} - - -static ScanType user_interface_get_page_side (UserInterface* self) { - ScanType result = 0; - GtkTreeIter iter = {0}; - gint page_side = 0; - GtkComboBox* _tmp0_ = NULL; - GtkTreeIter _tmp1_ = {0}; - gboolean _tmp2_ = FALSE; - gint _tmp5_ = 0; -#line 826 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - g_return_val_if_fail (self != NULL, 0); -#line 829 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - page_side = (gint) SCAN_TYPE_ADF_BOTH; -#line 831 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp0_ = self->priv->page_side_combo; -#line 831 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp2_ = gtk_combo_box_get_active_iter (_tmp0_, &_tmp1_); -#line 831 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - iter = _tmp1_; -#line 831 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - if (_tmp2_) { -#line 3767 "ui.c" - GtkListStore* _tmp3_ = NULL; - GtkTreeIter _tmp4_ = {0}; -#line 832 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp3_ = self->priv->page_side_model; -#line 832 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp4_ = iter; -#line 832 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - gtk_tree_model_get ((GtkTreeModel*) _tmp3_, &_tmp4_, 0, &page_side, -1, -1); -#line 3776 "ui.c" - } -#line 834 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp5_ = page_side; -#line 834 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - result = (ScanType) _tmp5_; -#line 834 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - return result; -#line 3784 "ui.c" -} - - -static gboolean user_interface_get_paper_size (UserInterface* self, gint* width, gint* height) { - gint _vala_width = 0; - gint _vala_height = 0; - gboolean result = FALSE; - GtkTreeIter iter = {0}; - gint _tmp0_ = 0; - GtkComboBox* _tmp1_ = NULL; - GtkTreeIter _tmp2_ = {0}; - gboolean _tmp3_ = FALSE; -#line 837 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - g_return_val_if_fail (self != NULL, FALSE); -#line 841 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _vala_height = 0; -#line 841 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp0_ = _vala_height; -#line 841 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _vala_width = _tmp0_; -#line 842 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp1_ = self->priv->paper_size_combo; -#line 842 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp3_ = gtk_combo_box_get_active_iter (_tmp1_, &_tmp2_); -#line 842 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - iter = _tmp2_; -#line 842 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - if (_tmp3_) { -#line 3813 "ui.c" - GtkListStore* _tmp4_ = NULL; - GtkTreeIter _tmp5_ = {0}; -#line 844 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp4_ = self->priv->paper_size_model; -#line 844 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp5_ = iter; -#line 844 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - gtk_tree_model_get ((GtkTreeModel*) _tmp4_, &_tmp5_, 0, &_vala_width, 1, &_vala_height, -1, -1); -#line 845 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - result = TRUE; -#line 845 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - if (width) { -#line 845 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - *width = _vala_width; -#line 3828 "ui.c" - } -#line 845 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - if (height) { -#line 845 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - *height = _vala_height; -#line 3834 "ui.c" - } -#line 845 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - return result; -#line 3838 "ui.c" - } -#line 848 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - result = FALSE; -#line 848 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - if (width) { -#line 848 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - *width = _vala_width; -#line 3846 "ui.c" - } -#line 848 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - if (height) { -#line 848 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - *height = _vala_height; -#line 3852 "ui.c" - } -#line 848 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - return result; -#line 3856 "ui.c" -} - - -static ScanOptions* user_interface_make_scan_options (UserInterface* self) { - ScanOptions* result = NULL; - ScanOptions* options = NULL; - ScanOptions* _tmp0_ = NULL; - const gchar* _tmp1_ = NULL; - ScanOptions* _tmp10_ = NULL; - ScanOptions* _tmp11_ = NULL; - gint _tmp12_ = 0; - gint _tmp13_ = 0; - ScanOptions* _tmp14_ = NULL; - gint _tmp15_ = 0; - gint _tmp16_ = 0; - ScanOptions* _tmp17_ = NULL; - gint _tmp18_ = 0; - gint _tmp19_ = 0; -#line 851 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - g_return_val_if_fail (self != NULL, NULL); -#line 853 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp0_ = scan_options_new (); -#line 853 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - options = _tmp0_; -#line 854 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp1_ = self->priv->document_hint; -#line 854 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - if (g_strcmp0 (_tmp1_, "text") == 0) { -#line 3885 "ui.c" - ScanOptions* _tmp2_ = NULL; - ScanOptions* _tmp3_ = NULL; - gint _tmp4_ = 0; - ScanOptions* _tmp5_ = NULL; -#line 856 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp2_ = options; -#line 856 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp2_->scan_mode = SCAN_MODE_GRAY; -#line 857 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp3_ = options; -#line 857 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp4_ = user_interface_get_text_dpi (self); -#line 857 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp3_->dpi = _tmp4_; -#line 858 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp5_ = options; -#line 858 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp5_->depth = 2; -#line 3904 "ui.c" - } else { - ScanOptions* _tmp6_ = NULL; - ScanOptions* _tmp7_ = NULL; - gint _tmp8_ = 0; - ScanOptions* _tmp9_ = NULL; -#line 862 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp6_ = options; -#line 862 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp6_->scan_mode = SCAN_MODE_COLOR; -#line 863 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp7_ = options; -#line 863 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp8_ = user_interface_get_photo_dpi (self); -#line 863 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp7_->dpi = _tmp8_; -#line 864 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp9_ = options; -#line 864 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp9_->depth = 8; -#line 3924 "ui.c" - } -#line 866 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp10_ = options; -#line 866 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp11_ = options; -#line 866 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - user_interface_get_paper_size (self, &_tmp12_, &_tmp13_); -#line 866 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp10_->paper_width = _tmp12_; -#line 866 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp11_->paper_height = _tmp13_; -#line 867 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp14_ = options; -#line 867 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp15_ = user_interface_get_brightness (self); -#line 867 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp16_ = _tmp15_; -#line 867 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp14_->brightness = _tmp16_; -#line 868 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp17_ = options; -#line 868 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp18_ = user_interface_get_contrast (self); -#line 868 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp19_ = _tmp18_; -#line 868 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp17_->contrast = _tmp19_; -#line 870 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - result = options; -#line 870 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - return result; -#line 3956 "ui.c" -} - - -static void user_interface_scan_button_clicked_cb (UserInterface* self, GtkWidget* widget) { - ScanOptions* options = NULL; - ScanOptions* _tmp0_ = NULL; - gchar* _tmp1_ = NULL; - gchar* _tmp2_ = NULL; - gchar* _tmp3_ = NULL; -#line 874 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - g_return_if_fail (self != NULL); -#line 874 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - g_return_if_fail (widget != NULL); -#line 876 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp0_ = user_interface_make_scan_options (self); -#line 876 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - options = _tmp0_; -#line 877 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - options->type = SCAN_TYPE_SINGLE; -#line 878 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp1_ = user_interface_get_selected_device (self); -#line 878 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp2_ = _tmp1_; -#line 878 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp3_ = _tmp2_; -#line 878 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - g_signal_emit_by_name (self, "start-scan", _tmp3_, options); -#line 878 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _g_free0 (_tmp3_); -#line 874 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _scan_options_unref0 (options); -#line 3988 "ui.c" -} - - -static void _user_interface_scan_button_clicked_cb_gtk_menu_item_activate (GtkMenuItem* _sender, gpointer self) { -#line 14 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - user_interface_scan_button_clicked_cb ((UserInterface*) self, _sender); -#line 3995 "ui.c" -} - - -static void user_interface_stop_scan_button_clicked_cb (UserInterface* self, GtkWidget* widget) { -#line 882 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - g_return_if_fail (self != NULL); -#line 882 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - g_return_if_fail (widget != NULL); -#line 884 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - g_signal_emit_by_name (self, "stop-scan"); -#line 4006 "ui.c" -} - - -static void _user_interface_stop_scan_button_clicked_cb_gtk_button_clicked (GtkButton* _sender, gpointer self) { -#line 14 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - user_interface_stop_scan_button_clicked_cb ((UserInterface*) self, _sender); -#line 4013 "ui.c" -} - - -static void user_interface_continuous_scan_button_clicked_cb (UserInterface* self, GtkWidget* widget) { - gboolean _tmp0_ = FALSE; - gboolean _tmp1_ = FALSE; -#line 888 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - g_return_if_fail (self != NULL); -#line 888 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - g_return_if_fail (widget != NULL); -#line 890 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp0_ = user_interface_get_scanning (self); -#line 890 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp1_ = _tmp0_; -#line 890 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - if (_tmp1_) { -#line 891 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - g_signal_emit_by_name (self, "stop-scan"); -#line 4032 "ui.c" - } else { - ScanOptions* options = NULL; - ScanOptions* _tmp2_ = NULL; - ScanOptions* _tmp3_ = NULL; - ScanType _tmp4_ = 0; - gchar* _tmp5_ = NULL; - gchar* _tmp6_ = NULL; - gchar* _tmp7_ = NULL; - ScanOptions* _tmp8_ = NULL; -#line 894 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp2_ = user_interface_make_scan_options (self); -#line 894 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - options = _tmp2_; -#line 895 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp3_ = options; -#line 895 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp4_ = user_interface_get_page_side (self); -#line 895 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp3_->type = _tmp4_; -#line 896 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp5_ = user_interface_get_selected_device (self); -#line 896 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp6_ = _tmp5_; -#line 896 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp7_ = _tmp6_; -#line 896 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp8_ = options; -#line 896 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - g_signal_emit_by_name (self, "start-scan", _tmp7_, _tmp8_); -#line 896 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _g_free0 (_tmp7_); -#line 890 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _scan_options_unref0 (options); -#line 4066 "ui.c" - } -} - - -static void _user_interface_continuous_scan_button_clicked_cb_gtk_menu_item_activate (GtkMenuItem* _sender, gpointer self) { -#line 14 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - user_interface_continuous_scan_button_clicked_cb ((UserInterface*) self, _sender); -#line 4074 "ui.c" -} - - -static void user_interface_preferences_button_clicked_cb (UserInterface* self, GtkWidget* widget) { - GtkDialog* _tmp0_ = NULL; -#line 901 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - g_return_if_fail (self != NULL); -#line 901 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - g_return_if_fail (widget != NULL); -#line 903 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp0_ = self->priv->preferences_dialog; -#line 903 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - gtk_window_present ((GtkWindow*) _tmp0_); -#line 4088 "ui.c" -} - - -static void _user_interface_preferences_button_clicked_cb_gtk_menu_item_activate (GtkMenuItem* _sender, gpointer self) { -#line 14 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - user_interface_preferences_button_clicked_cb ((UserInterface*) self, _sender); -#line 4095 "ui.c" -} - - -void user_interface_preferences_activate_cb (UserInterface* self) { - GtkDialog* _tmp0_ = NULL; -#line 906 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - g_return_if_fail (self != NULL); -#line 908 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp0_ = self->priv->preferences_dialog; -#line 908 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - gtk_window_present ((GtkWindow*) _tmp0_); -#line 4107 "ui.c" -} - - -static gboolean user_interface_preferences_dialog_delete_event_cb (UserInterface* self, GtkWidget* widget, GdkEventAny* event) { - gboolean result = FALSE; -#line 912 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - g_return_val_if_fail (self != NULL, FALSE); -#line 912 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - g_return_val_if_fail (widget != NULL, FALSE); -#line 912 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - g_return_val_if_fail (event != NULL, FALSE); -#line 914 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - result = TRUE; -#line 914 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - return result; -#line 4123 "ui.c" -} - - -static gboolean _user_interface_preferences_dialog_delete_event_cb_gtk_widget_delete_event (GtkWidget* _sender, GdkEventAny* event, gpointer self) { - gboolean result; - result = user_interface_preferences_dialog_delete_event_cb ((UserInterface*) self, _sender, event); -#line 14 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - return result; -#line 4132 "ui.c" -} - - -static void user_interface_preferences_dialog_response_cb (UserInterface* self, GtkWidget* widget, gint response_id) { - GtkDialog* _tmp0_ = NULL; -#line 918 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - g_return_if_fail (self != NULL); -#line 918 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - g_return_if_fail (widget != NULL); -#line 920 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp0_ = self->priv->preferences_dialog; -#line 920 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - gtk_widget_set_visible ((GtkWidget*) _tmp0_, FALSE); -#line 4146 "ui.c" -} - - -static void _user_interface_preferences_dialog_response_cb_gtk_dialog_response (GtkDialog* _sender, gint response_id, gpointer self) { -#line 14 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - user_interface_preferences_dialog_response_cb ((UserInterface*) self, _sender, response_id); -#line 4153 "ui.c" -} - - -static gpointer _page_ref0 (gpointer self) { -#line 925 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - return self ? page_ref (self) : NULL; -#line 4160 "ui.c" -} - - -static void user_interface_update_page_menu (UserInterface* self) { - Page* page = NULL; - BookView* _tmp0_ = NULL; - Page* _tmp1_ = NULL; - Page* _tmp2_ = NULL; - Page* _tmp3_ = NULL; - Page* _tmp4_ = NULL; -#line 923 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - g_return_if_fail (self != NULL); -#line 925 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp0_ = self->priv->book_view; -#line 925 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp1_ = book_view_get_selected_page (_tmp0_); -#line 925 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp2_ = _tmp1_; -#line 925 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp3_ = _page_ref0 (_tmp2_); -#line 925 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - page = _tmp3_; -#line 926 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp4_ = page; -#line 926 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - if (_tmp4_ == NULL) { -#line 4187 "ui.c" - GtkMenuItem* _tmp5_ = NULL; - GtkMenuItem* _tmp6_ = NULL; -#line 928 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp5_ = self->priv->page_move_left_menuitem; -#line 928 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - gtk_widget_set_sensitive ((GtkWidget*) _tmp5_, FALSE); -#line 929 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp6_ = self->priv->page_move_right_menuitem; -#line 929 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - gtk_widget_set_sensitive ((GtkWidget*) _tmp6_, FALSE); -#line 4198 "ui.c" - } else { - guint index = 0U; - Book* _tmp7_ = NULL; - Page* _tmp8_ = NULL; - guint _tmp9_ = 0U; - GtkMenuItem* _tmp10_ = NULL; - guint _tmp11_ = 0U; - GtkMenuItem* _tmp12_ = NULL; - guint _tmp13_ = 0U; - Book* _tmp14_ = NULL; - guint _tmp15_ = 0U; - guint _tmp16_ = 0U; -#line 933 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp7_ = self->priv->_book; -#line 933 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp8_ = page; -#line 933 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp9_ = book_get_page_index (_tmp7_, _tmp8_); -#line 933 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - index = _tmp9_; -#line 934 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp10_ = self->priv->page_move_left_menuitem; -#line 934 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp11_ = index; -#line 934 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - gtk_widget_set_sensitive ((GtkWidget*) _tmp10_, _tmp11_ > ((guint) 0)); -#line 935 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp12_ = self->priv->page_move_right_menuitem; -#line 935 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp13_ = index; -#line 935 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp14_ = self->priv->_book; -#line 935 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp15_ = book_get_n_pages (_tmp14_); -#line 935 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp16_ = _tmp15_; -#line 935 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - gtk_widget_set_sensitive ((GtkWidget*) _tmp12_, _tmp13_ < (_tmp16_ - 1)); -#line 4237 "ui.c" - } -#line 923 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _page_unref0 (page); -#line 4241 "ui.c" -} - - -static void user_interface_page_selected_cb (UserInterface* self, BookView* view, Page* page) { - Page* _tmp0_ = NULL; - GtkRadioMenuItem* menuitem = NULL; - GtkRadioMenuItem* _tmp1_ = NULL; - GtkRadioMenuItem* _tmp2_ = NULL; - Page* _tmp3_ = NULL; - gboolean _tmp4_ = FALSE; - gboolean _tmp5_ = FALSE; - GtkRadioMenuItem* _tmp31_ = NULL; - GtkToggleButton* _tmp32_ = NULL; - Page* _tmp33_ = NULL; - gboolean _tmp34_ = FALSE; - gboolean _tmp35_ = FALSE; - GtkToggleToolButton* _tmp36_ = NULL; - Page* _tmp37_ = NULL; - gboolean _tmp38_ = FALSE; - gboolean _tmp39_ = FALSE; -#line 939 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - g_return_if_fail (self != NULL); -#line 939 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - g_return_if_fail (view != NULL); -#line 941 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp0_ = page; -#line 941 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - if (_tmp0_ == NULL) { -#line 942 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - return; -#line 4272 "ui.c" - } -#line 944 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - self->priv->updating_page_menu = TRUE; -#line 946 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - user_interface_update_page_menu (self); -#line 948 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp1_ = self->priv->no_crop_menuitem; -#line 948 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp2_ = _g_object_ref0 (_tmp1_); -#line 948 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - menuitem = _tmp2_; -#line 949 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp3_ = page; -#line 949 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp4_ = page_get_has_crop (_tmp3_); -#line 949 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp5_ = _tmp4_; -#line 949 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - if (_tmp5_) { -#line 4292 "ui.c" - gchar* crop_name = NULL; - Page* _tmp6_ = NULL; - const gchar* _tmp7_ = NULL; - const gchar* _tmp8_ = NULL; - gchar* _tmp9_ = NULL; - const gchar* _tmp10_ = NULL; -#line 951 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp6_ = page; -#line 951 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp7_ = page_get_crop_name (_tmp6_); -#line 951 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp8_ = _tmp7_; -#line 951 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp9_ = g_strdup (_tmp8_); -#line 951 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - crop_name = _tmp9_; -#line 952 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp10_ = crop_name; -#line 952 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - if (_tmp10_ != NULL) { -#line 4313 "ui.c" - const gchar* _tmp11_ = NULL; -#line 954 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp11_ = crop_name; -#line 954 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - if (g_strcmp0 (_tmp11_, "A4") == 0) { -#line 4319 "ui.c" - GtkRadioMenuItem* _tmp12_ = NULL; - GtkRadioMenuItem* _tmp13_ = NULL; -#line 955 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp12_ = self->priv->a4_menuitem; -#line 955 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp13_ = _g_object_ref0 (_tmp12_); -#line 955 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _g_object_unref0 (menuitem); -#line 955 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - menuitem = _tmp13_; -#line 4330 "ui.c" - } else { - const gchar* _tmp14_ = NULL; -#line 956 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp14_ = crop_name; -#line 956 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - if (g_strcmp0 (_tmp14_, "A5") == 0) { -#line 4337 "ui.c" - GtkRadioMenuItem* _tmp15_ = NULL; - GtkRadioMenuItem* _tmp16_ = NULL; -#line 957 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp15_ = self->priv->a5_menuitem; -#line 957 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp16_ = _g_object_ref0 (_tmp15_); -#line 957 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _g_object_unref0 (menuitem); -#line 957 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - menuitem = _tmp16_; -#line 4348 "ui.c" - } else { - const gchar* _tmp17_ = NULL; -#line 958 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp17_ = crop_name; -#line 958 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - if (g_strcmp0 (_tmp17_, "A6") == 0) { -#line 4355 "ui.c" - GtkRadioMenuItem* _tmp18_ = NULL; - GtkRadioMenuItem* _tmp19_ = NULL; -#line 959 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp18_ = self->priv->a6_menuitem; -#line 959 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp19_ = _g_object_ref0 (_tmp18_); -#line 959 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _g_object_unref0 (menuitem); -#line 959 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - menuitem = _tmp19_; -#line 4366 "ui.c" - } else { - const gchar* _tmp20_ = NULL; -#line 960 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp20_ = crop_name; -#line 960 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - if (g_strcmp0 (_tmp20_, "letter") == 0) { -#line 4373 "ui.c" - GtkRadioMenuItem* _tmp21_ = NULL; - GtkRadioMenuItem* _tmp22_ = NULL; -#line 961 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp21_ = self->priv->letter_menuitem; -#line 961 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp22_ = _g_object_ref0 (_tmp21_); -#line 961 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _g_object_unref0 (menuitem); -#line 961 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - menuitem = _tmp22_; -#line 4384 "ui.c" - } else { - const gchar* _tmp23_ = NULL; -#line 962 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp23_ = crop_name; -#line 962 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - if (g_strcmp0 (_tmp23_, "legal") == 0) { -#line 4391 "ui.c" - GtkRadioMenuItem* _tmp24_ = NULL; - GtkRadioMenuItem* _tmp25_ = NULL; -#line 963 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp24_ = self->priv->legal_menuitem; -#line 963 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp25_ = _g_object_ref0 (_tmp24_); -#line 963 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _g_object_unref0 (menuitem); -#line 963 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - menuitem = _tmp25_; -#line 4402 "ui.c" - } else { - const gchar* _tmp26_ = NULL; -#line 964 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp26_ = crop_name; -#line 964 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - if (g_strcmp0 (_tmp26_, "4x6") == 0) { -#line 4409 "ui.c" - GtkRadioMenuItem* _tmp27_ = NULL; - GtkRadioMenuItem* _tmp28_ = NULL; -#line 965 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp27_ = self->priv->four_by_six_menuitem; -#line 965 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp28_ = _g_object_ref0 (_tmp27_); -#line 965 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _g_object_unref0 (menuitem); -#line 965 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - menuitem = _tmp28_; -#line 4420 "ui.c" - } - } - } - } - } - } - } else { - GtkRadioMenuItem* _tmp29_ = NULL; - GtkRadioMenuItem* _tmp30_ = NULL; -#line 968 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp29_ = self->priv->custom_crop_menuitem; -#line 968 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp30_ = _g_object_ref0 (_tmp29_); -#line 968 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _g_object_unref0 (menuitem); -#line 968 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - menuitem = _tmp30_; -#line 4438 "ui.c" - } -#line 949 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _g_free0 (crop_name); -#line 4442 "ui.c" - } -#line 971 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp31_ = menuitem; -#line 971 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - gtk_check_menu_item_set_active ((GtkCheckMenuItem*) _tmp31_, TRUE); -#line 972 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp32_ = self->priv->crop_button; -#line 972 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp33_ = page; -#line 972 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp34_ = page_get_has_crop (_tmp33_); -#line 972 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp35_ = _tmp34_; -#line 972 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - gtk_toggle_button_set_active (_tmp32_, _tmp35_); -#line 973 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp36_ = self->priv->crop_toolbutton; -#line 973 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp37_ = page; -#line 973 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp38_ = page_get_has_crop (_tmp37_); -#line 973 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp39_ = _tmp38_; -#line 973 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - gtk_toggle_tool_button_set_active (_tmp36_, _tmp39_); -#line 975 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - self->priv->updating_page_menu = FALSE; -#line 939 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _g_object_unref0 (menuitem); -#line 4472 "ui.c" -} - - -static void user_interface_show_page_cb (UserInterface* self, BookView* view, Page* page) { - gchar* path = NULL; - gchar* _tmp0_ = NULL; - const gchar* _tmp1_ = NULL; - GFile* file = NULL; - const gchar* _tmp2_ = NULL; - GFile* _tmp3_ = NULL; - GError * _inner_error_ = NULL; -#line 978 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - g_return_if_fail (self != NULL); -#line 978 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - g_return_if_fail (view != NULL); -#line 978 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - g_return_if_fail (page != NULL); -#line 980 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp0_ = get_temporary_filename ("scanned-page", "tiff"); -#line 980 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - path = _tmp0_; -#line 981 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp1_ = path; -#line 981 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - if (_tmp1_ == NULL) { -#line 982 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _g_free0 (path); -#line 982 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - return; -#line 4502 "ui.c" - } -#line 983 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp2_ = path; -#line 983 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp3_ = g_file_new_for_path (_tmp2_); -#line 983 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - file = _tmp3_; -#line 4510 "ui.c" - { - Page* _tmp4_ = NULL; - gint _tmp5_ = 0; - gint _tmp6_ = 0; - GFile* _tmp7_ = NULL; -#line 987 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp4_ = page; -#line 987 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp5_ = user_interface_get_quality (self); -#line 987 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp6_ = _tmp5_; -#line 987 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp7_ = file; -#line 987 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - page_save (_tmp4_, "tiff", _tmp6_, _tmp7_, &_inner_error_); -#line 987 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - if (G_UNLIKELY (_inner_error_ != NULL)) { -#line 4528 "ui.c" - goto __catch18_g_error; - } - } - goto __finally18; - __catch18_g_error: - { - GError* e = NULL; - const gchar* _tmp8_ = NULL; - GError* _tmp9_ = NULL; - const gchar* _tmp10_ = NULL; -#line 985 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - e = _inner_error_; -#line 985 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _inner_error_ = NULL; -#line 991 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp8_ = _ ("Unable to save image for preview"); -#line 991 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp9_ = e; -#line 991 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp10_ = _tmp9_->message; -#line 991 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - user_interface_show_error_dialog (self, _tmp8_, _tmp10_); -#line 994 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _g_error_free0 (e); -#line 994 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _g_object_unref0 (file); -#line 994 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _g_free0 (path); -#line 994 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - return; -#line 4559 "ui.c" - } - __finally18: -#line 985 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - if (G_UNLIKELY (_inner_error_ != NULL)) { -#line 985 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _g_object_unref0 (file); -#line 985 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _g_free0 (path); -#line 985 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - g_critical ("file %s: line %d: uncaught error: %s (%s, %d)", __FILE__, __LINE__, _inner_error_->message, g_quark_to_string (_inner_error_->domain), _inner_error_->code); -#line 985 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - g_clear_error (&_inner_error_); -#line 985 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - return; -#line 4574 "ui.c" - } - { - GdkScreen* _tmp11_ = NULL; - GdkScreen* _tmp12_ = NULL; - GFile* _tmp13_ = NULL; - gchar* _tmp14_ = NULL; - gchar* _tmp15_ = NULL; - guint32 _tmp16_ = 0U; -#line 999 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp11_ = gtk_window_get_screen ((GtkWindow*) self); -#line 999 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp12_ = _tmp11_; -#line 999 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp13_ = file; -#line 999 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp14_ = g_file_get_uri (_tmp13_); -#line 999 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp15_ = _tmp14_; -#line 999 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp16_ = gtk_get_current_event_time (); -#line 999 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - gtk_show_uri (_tmp12_, _tmp15_, _tmp16_, &_inner_error_); -#line 999 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _g_free0 (_tmp15_); -#line 999 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - if (G_UNLIKELY (_inner_error_ != NULL)) { -#line 4601 "ui.c" - goto __catch19_g_error; - } - } - goto __finally19; - __catch19_g_error: - { - GError* e = NULL; - const gchar* _tmp17_ = NULL; - GError* _tmp18_ = NULL; - const gchar* _tmp19_ = NULL; -#line 997 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - e = _inner_error_; -#line 997 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _inner_error_ = NULL; -#line 1003 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp17_ = _ ("Unable to open image preview application"); -#line 1003 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp18_ = e; -#line 1003 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp19_ = _tmp18_->message; -#line 1003 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - user_interface_show_error_dialog (self, _tmp17_, _tmp19_); -#line 997 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _g_error_free0 (e); -#line 4626 "ui.c" - } - __finally19: -#line 997 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - if (G_UNLIKELY (_inner_error_ != NULL)) { -#line 997 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _g_object_unref0 (file); -#line 997 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _g_free0 (path); -#line 997 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - g_critical ("file %s: line %d: uncaught error: %s (%s, %d)", __FILE__, __LINE__, _inner_error_->message, g_quark_to_string (_inner_error_->domain), _inner_error_->code); -#line 997 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - g_clear_error (&_inner_error_); -#line 997 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - return; -#line 4641 "ui.c" - } -#line 978 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _g_object_unref0 (file); -#line 978 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _g_free0 (path); -#line 4647 "ui.c" -} - - -static void user_interface_show_page_menu_cb (UserInterface* self, BookView* view) { - GtkMenu* _tmp0_ = NULL; - guint32 _tmp1_ = 0U; -#line 1009 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - g_return_if_fail (self != NULL); -#line 1009 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - g_return_if_fail (view != NULL); -#line 1011 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp0_ = self->priv->page_menu; -#line 1011 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp1_ = gtk_get_current_event_time (); -#line 1011 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - gtk_menu_popup (_tmp0_, NULL, NULL, NULL, NULL, (guint) 3, _tmp1_); -#line 4664 "ui.c" -} - - -static void user_interface_rotate_left_button_clicked_cb (UserInterface* self, GtkWidget* widget) { - gboolean _tmp0_ = FALSE; - Page* page = NULL; - BookView* _tmp1_ = NULL; - Page* _tmp2_ = NULL; - Page* _tmp3_ = NULL; - Page* _tmp4_ = NULL; - Page* _tmp5_ = NULL; -#line 1015 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - g_return_if_fail (self != NULL); -#line 1015 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - g_return_if_fail (widget != NULL); -#line 1017 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp0_ = self->priv->updating_page_menu; -#line 1017 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - if (_tmp0_) { -#line 1018 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - return; -#line 4686 "ui.c" - } -#line 1019 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp1_ = self->priv->book_view; -#line 1019 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp2_ = book_view_get_selected_page (_tmp1_); -#line 1019 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp3_ = _tmp2_; -#line 1019 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp4_ = _page_ref0 (_tmp3_); -#line 1019 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - page = _tmp4_; -#line 1020 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp5_ = page; -#line 1020 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - if (_tmp5_ != NULL) { -#line 4702 "ui.c" - Page* _tmp6_ = NULL; -#line 1021 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp6_ = page; -#line 1021 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - page_rotate_left (_tmp6_); -#line 4708 "ui.c" - } -#line 1015 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _page_unref0 (page); -#line 4712 "ui.c" -} - - -static void _user_interface_rotate_left_button_clicked_cb_gtk_button_clicked (GtkButton* _sender, gpointer self) { -#line 14 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - user_interface_rotate_left_button_clicked_cb ((UserInterface*) self, _sender); -#line 4719 "ui.c" -} - - -static void user_interface_rotate_right_button_clicked_cb (UserInterface* self, GtkWidget* widget) { - gboolean _tmp0_ = FALSE; - Page* page = NULL; - BookView* _tmp1_ = NULL; - Page* _tmp2_ = NULL; - Page* _tmp3_ = NULL; - Page* _tmp4_ = NULL; - Page* _tmp5_ = NULL; -#line 1025 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - g_return_if_fail (self != NULL); -#line 1025 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - g_return_if_fail (widget != NULL); -#line 1027 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp0_ = self->priv->updating_page_menu; -#line 1027 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - if (_tmp0_) { -#line 1028 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - return; -#line 4741 "ui.c" - } -#line 1029 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp1_ = self->priv->book_view; -#line 1029 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp2_ = book_view_get_selected_page (_tmp1_); -#line 1029 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp3_ = _tmp2_; -#line 1029 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp4_ = _page_ref0 (_tmp3_); -#line 1029 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - page = _tmp4_; -#line 1030 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp5_ = page; -#line 1030 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - if (_tmp5_ != NULL) { -#line 4757 "ui.c" - Page* _tmp6_ = NULL; -#line 1031 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp6_ = page; -#line 1031 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - page_rotate_right (_tmp6_); -#line 4763 "ui.c" - } -#line 1025 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _page_unref0 (page); -#line 4767 "ui.c" -} - - -static void _user_interface_rotate_right_button_clicked_cb_gtk_button_clicked (GtkButton* _sender, gpointer self) { -#line 14 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - user_interface_rotate_right_button_clicked_cb ((UserInterface*) self, _sender); -#line 4774 "ui.c" -} - - -static void user_interface_set_crop (UserInterface* self, const gchar* crop_name) { - GtkMenuItem* _tmp0_ = NULL; - const gchar* _tmp1_ = NULL; - gboolean _tmp2_ = FALSE; - Page* page = NULL; - BookView* _tmp3_ = NULL; - Page* _tmp4_ = NULL; - Page* _tmp5_ = NULL; - Page* _tmp6_ = NULL; - Page* _tmp7_ = NULL; - const gchar* _tmp8_ = NULL; -#line 1034 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - g_return_if_fail (self != NULL); -#line 1036 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp0_ = self->priv->crop_rotate_menuitem; -#line 1036 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp1_ = crop_name; -#line 1036 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - gtk_widget_set_sensitive ((GtkWidget*) _tmp0_, _tmp1_ != NULL); -#line 1038 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp2_ = self->priv->updating_page_menu; -#line 1038 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - if (_tmp2_) { -#line 1039 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - return; -#line 4803 "ui.c" - } -#line 1041 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp3_ = self->priv->book_view; -#line 1041 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp4_ = book_view_get_selected_page (_tmp3_); -#line 1041 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp5_ = _tmp4_; -#line 1041 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp6_ = _page_ref0 (_tmp5_); -#line 1041 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - page = _tmp6_; -#line 1042 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp7_ = page; -#line 1042 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - if (_tmp7_ == NULL) { -#line 1044 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - g_warning ("ui.vala:1044: Trying to set crop but no selected page"); -#line 1045 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _page_unref0 (page); -#line 1045 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - return; -#line 4825 "ui.c" - } -#line 1048 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp8_ = crop_name; -#line 1048 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - if (_tmp8_ == NULL) { -#line 4831 "ui.c" - Page* _tmp9_ = NULL; -#line 1049 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp9_ = page; -#line 1049 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - page_set_no_crop (_tmp9_); -#line 4837 "ui.c" - } else { - const gchar* _tmp10_ = NULL; -#line 1050 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp10_ = crop_name; -#line 1050 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - if (g_strcmp0 (_tmp10_, "custom") == 0) { -#line 4844 "ui.c" - gint width = 0; - Page* _tmp11_ = NULL; - gint _tmp12_ = 0; - gint _tmp13_ = 0; - gint height = 0; - Page* _tmp14_ = NULL; - gint _tmp15_ = 0; - gint _tmp16_ = 0; - gint crop_width = 0; - gint _tmp17_ = 0; - gint crop_height = 0; - gint _tmp18_ = 0; - Page* _tmp19_ = NULL; - gint _tmp20_ = 0; - gint _tmp21_ = 0; - Page* _tmp22_ = NULL; - gint _tmp23_ = 0; - gint _tmp24_ = 0; - gint _tmp25_ = 0; - gint _tmp26_ = 0; -#line 1052 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp11_ = page; -#line 1052 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp12_ = page_get_width (_tmp11_); -#line 1052 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp13_ = _tmp12_; -#line 1052 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - width = _tmp13_; -#line 1053 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp14_ = page; -#line 1053 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp15_ = page_get_height (_tmp14_); -#line 1053 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp16_ = _tmp15_; -#line 1053 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - height = _tmp16_; -#line 1054 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp17_ = width; -#line 1054 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - crop_width = (gint) ((_tmp17_ * 0.8) + 0.5); -#line 1055 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp18_ = height; -#line 1055 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - crop_height = (gint) ((_tmp18_ * 0.8) + 0.5); -#line 1056 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp19_ = page; -#line 1056 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp20_ = crop_width; -#line 1056 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp21_ = crop_height; -#line 1056 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - page_set_custom_crop (_tmp19_, _tmp20_, _tmp21_); -#line 1057 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp22_ = page; -#line 1057 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp23_ = width; -#line 1057 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp24_ = crop_width; -#line 1057 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp25_ = height; -#line 1057 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp26_ = crop_height; -#line 1057 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - page_move_crop (_tmp22_, (_tmp23_ - _tmp24_) / 2, (_tmp25_ - _tmp26_) / 2); -#line 4909 "ui.c" - } else { - Page* _tmp27_ = NULL; - const gchar* _tmp28_ = NULL; -#line 1060 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp27_ = page; -#line 1060 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp28_ = crop_name; -#line 1060 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - page_set_named_crop (_tmp27_, _tmp28_); -#line 4919 "ui.c" - } - } -#line 1034 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _page_unref0 (page); -#line 4924 "ui.c" -} - - -static void user_interface_no_crop_menuitem_toggled_cb (UserInterface* self, GtkCheckMenuItem* widget) { - GtkCheckMenuItem* _tmp0_ = NULL; - gboolean _tmp1_ = FALSE; - gboolean _tmp2_ = FALSE; -#line 1064 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - g_return_if_fail (self != NULL); -#line 1064 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - g_return_if_fail (widget != NULL); -#line 1066 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp0_ = widget; -#line 1066 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp1_ = gtk_check_menu_item_get_active (_tmp0_); -#line 1066 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp2_ = _tmp1_; -#line 1066 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - if (_tmp2_) { -#line 1067 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - user_interface_set_crop (self, NULL); -#line 4946 "ui.c" - } -} - - -static void _user_interface_no_crop_menuitem_toggled_cb_gtk_check_menu_item_toggled (GtkCheckMenuItem* _sender, gpointer self) { -#line 14 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - user_interface_no_crop_menuitem_toggled_cb ((UserInterface*) self, _sender); -#line 4954 "ui.c" -} - - -static void user_interface_custom_crop_menuitem_toggled_cb (UserInterface* self, GtkCheckMenuItem* widget) { - GtkCheckMenuItem* _tmp0_ = NULL; - gboolean _tmp1_ = FALSE; - gboolean _tmp2_ = FALSE; -#line 1071 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - g_return_if_fail (self != NULL); -#line 1071 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - g_return_if_fail (widget != NULL); -#line 1073 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp0_ = widget; -#line 1073 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp1_ = gtk_check_menu_item_get_active (_tmp0_); -#line 1073 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp2_ = _tmp1_; -#line 1073 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - if (_tmp2_) { -#line 1074 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - user_interface_set_crop (self, "custom"); -#line 4976 "ui.c" - } -} - - -static void _user_interface_custom_crop_menuitem_toggled_cb_gtk_check_menu_item_toggled (GtkCheckMenuItem* _sender, gpointer self) { -#line 14 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - user_interface_custom_crop_menuitem_toggled_cb ((UserInterface*) self, _sender); -#line 4984 "ui.c" -} - - -static void user_interface_crop_button_toggled_cb (UserInterface* self, GtkToggleButton* widget) { - gboolean _tmp0_ = FALSE; - GtkToggleButton* _tmp1_ = NULL; - gboolean _tmp2_ = FALSE; - gboolean _tmp3_ = FALSE; -#line 1078 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - g_return_if_fail (self != NULL); -#line 1078 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - g_return_if_fail (widget != NULL); -#line 1080 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp0_ = self->priv->updating_page_menu; -#line 1080 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - if (_tmp0_) { -#line 1081 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - return; -#line 5003 "ui.c" - } -#line 1083 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp1_ = widget; -#line 1083 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp2_ = gtk_toggle_button_get_active (_tmp1_); -#line 1083 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp3_ = _tmp2_; -#line 1083 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - if (_tmp3_) { -#line 5013 "ui.c" - GtkRadioMenuItem* _tmp4_ = NULL; -#line 1084 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp4_ = self->priv->custom_crop_menuitem; -#line 1084 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - gtk_check_menu_item_set_active ((GtkCheckMenuItem*) _tmp4_, TRUE); -#line 5019 "ui.c" - } else { - GtkRadioMenuItem* _tmp5_ = NULL; -#line 1086 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp5_ = self->priv->no_crop_menuitem; -#line 1086 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - gtk_check_menu_item_set_active ((GtkCheckMenuItem*) _tmp5_, TRUE); -#line 5026 "ui.c" - } -} - - -static void _user_interface_crop_button_toggled_cb_gtk_toggle_button_toggled (GtkToggleButton* _sender, gpointer self) { -#line 14 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - user_interface_crop_button_toggled_cb ((UserInterface*) self, _sender); -#line 5034 "ui.c" -} - - -static void user_interface_crop_toolbutton_toggled_cb (UserInterface* self, GtkToggleToolButton* widget) { - gboolean _tmp0_ = FALSE; - GtkToggleToolButton* _tmp1_ = NULL; - gboolean _tmp2_ = FALSE; - gboolean _tmp3_ = FALSE; -#line 1090 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - g_return_if_fail (self != NULL); -#line 1090 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - g_return_if_fail (widget != NULL); -#line 1092 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp0_ = self->priv->updating_page_menu; -#line 1092 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - if (_tmp0_) { -#line 1093 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - return; -#line 5053 "ui.c" - } -#line 1095 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp1_ = widget; -#line 1095 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp2_ = gtk_toggle_tool_button_get_active (_tmp1_); -#line 1095 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp3_ = _tmp2_; -#line 1095 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - if (_tmp3_) { -#line 5063 "ui.c" - GtkRadioMenuItem* _tmp4_ = NULL; -#line 1096 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp4_ = self->priv->custom_crop_menuitem; -#line 1096 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - gtk_check_menu_item_set_active ((GtkCheckMenuItem*) _tmp4_, TRUE); -#line 5069 "ui.c" - } else { - GtkRadioMenuItem* _tmp5_ = NULL; -#line 1098 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp5_ = self->priv->no_crop_menuitem; -#line 1098 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - gtk_check_menu_item_set_active ((GtkCheckMenuItem*) _tmp5_, TRUE); -#line 5076 "ui.c" - } -} - - -static void _user_interface_crop_toolbutton_toggled_cb_gtk_toggle_tool_button_toggled (GtkToggleToolButton* _sender, gpointer self) { -#line 14 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - user_interface_crop_toolbutton_toggled_cb ((UserInterface*) self, _sender); -#line 5084 "ui.c" -} - - -static void user_interface_four_by_six_menuitem_toggled_cb (UserInterface* self, GtkCheckMenuItem* widget) { - GtkCheckMenuItem* _tmp0_ = NULL; - gboolean _tmp1_ = FALSE; - gboolean _tmp2_ = FALSE; -#line 1102 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - g_return_if_fail (self != NULL); -#line 1102 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - g_return_if_fail (widget != NULL); -#line 1104 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp0_ = widget; -#line 1104 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp1_ = gtk_check_menu_item_get_active (_tmp0_); -#line 1104 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp2_ = _tmp1_; -#line 1104 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - if (_tmp2_) { -#line 1105 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - user_interface_set_crop (self, "4x6"); -#line 5106 "ui.c" - } -} - - -static void _user_interface_four_by_six_menuitem_toggled_cb_gtk_check_menu_item_toggled (GtkCheckMenuItem* _sender, gpointer self) { -#line 14 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - user_interface_four_by_six_menuitem_toggled_cb ((UserInterface*) self, _sender); -#line 5114 "ui.c" -} - - -static void user_interface_legal_menuitem_toggled_cb (UserInterface* self, GtkCheckMenuItem* widget) { - GtkCheckMenuItem* _tmp0_ = NULL; - gboolean _tmp1_ = FALSE; - gboolean _tmp2_ = FALSE; -#line 1109 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - g_return_if_fail (self != NULL); -#line 1109 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - g_return_if_fail (widget != NULL); -#line 1111 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp0_ = widget; -#line 1111 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp1_ = gtk_check_menu_item_get_active (_tmp0_); -#line 1111 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp2_ = _tmp1_; -#line 1111 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - if (_tmp2_) { -#line 1112 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - user_interface_set_crop (self, "legal"); -#line 5136 "ui.c" - } -} - - -static void _user_interface_legal_menuitem_toggled_cb_gtk_check_menu_item_toggled (GtkCheckMenuItem* _sender, gpointer self) { -#line 14 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - user_interface_legal_menuitem_toggled_cb ((UserInterface*) self, _sender); -#line 5144 "ui.c" -} - - -static void user_interface_letter_menuitem_toggled_cb (UserInterface* self, GtkCheckMenuItem* widget) { - GtkCheckMenuItem* _tmp0_ = NULL; - gboolean _tmp1_ = FALSE; - gboolean _tmp2_ = FALSE; -#line 1116 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - g_return_if_fail (self != NULL); -#line 1116 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - g_return_if_fail (widget != NULL); -#line 1118 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp0_ = widget; -#line 1118 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp1_ = gtk_check_menu_item_get_active (_tmp0_); -#line 1118 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp2_ = _tmp1_; -#line 1118 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - if (_tmp2_) { -#line 1119 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - user_interface_set_crop (self, "letter"); -#line 5166 "ui.c" - } -} - - -static void _user_interface_letter_menuitem_toggled_cb_gtk_check_menu_item_toggled (GtkCheckMenuItem* _sender, gpointer self) { -#line 14 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - user_interface_letter_menuitem_toggled_cb ((UserInterface*) self, _sender); -#line 5174 "ui.c" -} - - -static void user_interface_a6_menuitem_toggled_cb (UserInterface* self, GtkCheckMenuItem* widget) { - GtkCheckMenuItem* _tmp0_ = NULL; - gboolean _tmp1_ = FALSE; - gboolean _tmp2_ = FALSE; -#line 1123 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - g_return_if_fail (self != NULL); -#line 1123 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - g_return_if_fail (widget != NULL); -#line 1125 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp0_ = widget; -#line 1125 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp1_ = gtk_check_menu_item_get_active (_tmp0_); -#line 1125 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp2_ = _tmp1_; -#line 1125 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - if (_tmp2_) { -#line 1126 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - user_interface_set_crop (self, "A6"); -#line 5196 "ui.c" - } -} - - -static void _user_interface_a6_menuitem_toggled_cb_gtk_check_menu_item_toggled (GtkCheckMenuItem* _sender, gpointer self) { -#line 14 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - user_interface_a6_menuitem_toggled_cb ((UserInterface*) self, _sender); -#line 5204 "ui.c" -} - - -static void user_interface_a5_menuitem_toggled_cb (UserInterface* self, GtkCheckMenuItem* widget) { - GtkCheckMenuItem* _tmp0_ = NULL; - gboolean _tmp1_ = FALSE; - gboolean _tmp2_ = FALSE; -#line 1130 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - g_return_if_fail (self != NULL); -#line 1130 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - g_return_if_fail (widget != NULL); -#line 1132 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp0_ = widget; -#line 1132 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp1_ = gtk_check_menu_item_get_active (_tmp0_); -#line 1132 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp2_ = _tmp1_; -#line 1132 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - if (_tmp2_) { -#line 1133 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - user_interface_set_crop (self, "A5"); -#line 5226 "ui.c" - } -} - - -static void _user_interface_a5_menuitem_toggled_cb_gtk_check_menu_item_toggled (GtkCheckMenuItem* _sender, gpointer self) { -#line 14 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - user_interface_a5_menuitem_toggled_cb ((UserInterface*) self, _sender); -#line 5234 "ui.c" -} - - -static void user_interface_a4_menuitem_toggled_cb (UserInterface* self, GtkCheckMenuItem* widget) { - GtkCheckMenuItem* _tmp0_ = NULL; - gboolean _tmp1_ = FALSE; - gboolean _tmp2_ = FALSE; -#line 1137 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - g_return_if_fail (self != NULL); -#line 1137 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - g_return_if_fail (widget != NULL); -#line 1139 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp0_ = widget; -#line 1139 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp1_ = gtk_check_menu_item_get_active (_tmp0_); -#line 1139 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp2_ = _tmp1_; -#line 1139 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - if (_tmp2_) { -#line 1140 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - user_interface_set_crop (self, "A4"); -#line 5256 "ui.c" - } -} - - -static void _user_interface_a4_menuitem_toggled_cb_gtk_check_menu_item_toggled (GtkCheckMenuItem* _sender, gpointer self) { -#line 14 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - user_interface_a4_menuitem_toggled_cb ((UserInterface*) self, _sender); -#line 5264 "ui.c" -} - - -static void user_interface_crop_rotate_menuitem_activate_cb (UserInterface* self, GtkWidget* widget) { - Page* page = NULL; - BookView* _tmp0_ = NULL; - Page* _tmp1_ = NULL; - Page* _tmp2_ = NULL; - Page* _tmp3_ = NULL; - Page* _tmp4_ = NULL; - Page* _tmp5_ = NULL; -#line 1144 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - g_return_if_fail (self != NULL); -#line 1144 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - g_return_if_fail (widget != NULL); -#line 1146 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp0_ = self->priv->book_view; -#line 1146 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp1_ = book_view_get_selected_page (_tmp0_); -#line 1146 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp2_ = _tmp1_; -#line 1146 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp3_ = _page_ref0 (_tmp2_); -#line 1146 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - page = _tmp3_; -#line 1147 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp4_ = page; -#line 1147 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - if (_tmp4_ == NULL) { -#line 1148 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _page_unref0 (page); -#line 1148 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - return; -#line 5298 "ui.c" - } -#line 1149 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp5_ = page; -#line 1149 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - page_rotate_crop (_tmp5_); -#line 1144 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _page_unref0 (page); -#line 5306 "ui.c" -} - - -static void _user_interface_crop_rotate_menuitem_activate_cb_gtk_menu_item_activate (GtkMenuItem* _sender, gpointer self) { -#line 14 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - user_interface_crop_rotate_menuitem_activate_cb ((UserInterface*) self, _sender); -#line 5313 "ui.c" -} - - -static void user_interface_page_move_left_menuitem_activate_cb (UserInterface* self, GtkWidget* widget) { - Page* page = NULL; - BookView* _tmp0_ = NULL; - Page* _tmp1_ = NULL; - Page* _tmp2_ = NULL; - Page* _tmp3_ = NULL; - guint index = 0U; - Book* _tmp4_ = NULL; - Page* _tmp5_ = NULL; - guint _tmp6_ = 0U; - guint _tmp7_ = 0U; -#line 1153 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - g_return_if_fail (self != NULL); -#line 1153 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - g_return_if_fail (widget != NULL); -#line 1155 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp0_ = self->priv->book_view; -#line 1155 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp1_ = book_view_get_selected_page (_tmp0_); -#line 1155 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp2_ = _tmp1_; -#line 1155 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp3_ = _page_ref0 (_tmp2_); -#line 1155 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - page = _tmp3_; -#line 1156 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp4_ = self->priv->_book; -#line 1156 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp5_ = page; -#line 1156 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp6_ = book_get_page_index (_tmp4_, _tmp5_); -#line 1156 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - index = _tmp6_; -#line 1157 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp7_ = index; -#line 1157 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - if (_tmp7_ > ((guint) 0)) { -#line 5354 "ui.c" - Book* _tmp8_ = NULL; - Page* _tmp9_ = NULL; - guint _tmp10_ = 0U; -#line 1158 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp8_ = self->priv->_book; -#line 1158 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp9_ = page; -#line 1158 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp10_ = index; -#line 1158 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - book_move_page (_tmp8_, _tmp9_, _tmp10_ - 1); -#line 5366 "ui.c" - } -#line 1153 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _page_unref0 (page); -#line 5370 "ui.c" -} - - -static void _user_interface_page_move_left_menuitem_activate_cb_gtk_menu_item_activate (GtkMenuItem* _sender, gpointer self) { -#line 14 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - user_interface_page_move_left_menuitem_activate_cb ((UserInterface*) self, _sender); -#line 5377 "ui.c" -} - - -static void user_interface_page_move_right_menuitem_activate_cb (UserInterface* self, GtkWidget* widget) { - Page* page = NULL; - BookView* _tmp0_ = NULL; - Page* _tmp1_ = NULL; - Page* _tmp2_ = NULL; - Page* _tmp3_ = NULL; - guint index = 0U; - Book* _tmp4_ = NULL; - Page* _tmp5_ = NULL; - guint _tmp6_ = 0U; - guint _tmp7_ = 0U; - Book* _tmp8_ = NULL; - guint _tmp9_ = 0U; - guint _tmp10_ = 0U; -#line 1162 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - g_return_if_fail (self != NULL); -#line 1162 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - g_return_if_fail (widget != NULL); -#line 1164 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp0_ = self->priv->book_view; -#line 1164 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp1_ = book_view_get_selected_page (_tmp0_); -#line 1164 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp2_ = _tmp1_; -#line 1164 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp3_ = _page_ref0 (_tmp2_); -#line 1164 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - page = _tmp3_; -#line 1165 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp4_ = self->priv->_book; -#line 1165 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp5_ = page; -#line 1165 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp6_ = book_get_page_index (_tmp4_, _tmp5_); -#line 1165 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - index = _tmp6_; -#line 1166 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp7_ = index; -#line 1166 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp8_ = self->priv->_book; -#line 1166 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp9_ = book_get_n_pages (_tmp8_); -#line 1166 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp10_ = _tmp9_; -#line 1166 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - if (_tmp7_ < (_tmp10_ - 1)) { -#line 5427 "ui.c" - Book* _tmp11_ = NULL; - Page* _tmp12_ = NULL; - Book* _tmp13_ = NULL; - Page* _tmp14_ = NULL; - guint _tmp15_ = 0U; -#line 1167 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp11_ = self->priv->_book; -#line 1167 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp12_ = page; -#line 1167 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp13_ = self->priv->_book; -#line 1167 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp14_ = page; -#line 1167 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp15_ = book_get_page_index (_tmp13_, _tmp14_); -#line 1167 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - book_move_page (_tmp11_, _tmp12_, _tmp15_ + 1); -#line 5445 "ui.c" - } -#line 1162 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _page_unref0 (page); -#line 5449 "ui.c" -} - - -static void _user_interface_page_move_right_menuitem_activate_cb_gtk_menu_item_activate (GtkMenuItem* _sender, gpointer self) { -#line 14 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - user_interface_page_move_right_menuitem_activate_cb ((UserInterface*) self, _sender); -#line 5456 "ui.c" -} - - -static void user_interface_page_delete_menuitem_activate_cb (UserInterface* self, GtkWidget* widget) { - BookView* _tmp0_ = NULL; - Book* _tmp1_ = NULL; - Book* _tmp2_ = NULL; - BookView* _tmp3_ = NULL; - Page* _tmp4_ = NULL; - Page* _tmp5_ = NULL; -#line 1171 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - g_return_if_fail (self != NULL); -#line 1171 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - g_return_if_fail (widget != NULL); -#line 1173 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp0_ = self->priv->book_view; -#line 1173 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp1_ = book_view_get_book (_tmp0_); -#line 1173 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp2_ = _tmp1_; -#line 1173 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp3_ = self->priv->book_view; -#line 1173 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp4_ = book_view_get_selected_page (_tmp3_); -#line 1173 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp5_ = _tmp4_; -#line 1173 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - book_delete_page (_tmp2_, _tmp5_); -#line 5485 "ui.c" -} - - -static void _user_interface_page_delete_menuitem_activate_cb_gtk_menu_item_activate (GtkMenuItem* _sender, gpointer self) { -#line 14 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - user_interface_page_delete_menuitem_activate_cb ((UserInterface*) self, _sender); -#line 5492 "ui.c" -} - - -static Block2Data* block2_data_ref (Block2Data* _data2_) { -#line 1176 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - g_atomic_int_inc (&_data2_->_ref_count_); -#line 1176 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - return _data2_; -#line 5501 "ui.c" -} - - -static void block2_data_unref (void * _userdata_) { - Block2Data* _data2_; - _data2_ = (Block2Data*) _userdata_; -#line 1176 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - if (g_atomic_int_dec_and_test (&_data2_->_ref_count_)) { -#line 5510 "ui.c" - UserInterface* self; -#line 1176 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - self = _data2_->self; -#line 1176 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _g_object_unref0 (_data2_->dialog); -#line 1176 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _g_object_unref0 (self); -#line 1176 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - g_slice_free (Block2Data, _data2_); -#line 5520 "ui.c" - } -} - - -static gboolean __lambda6_ (Block2Data* _data2_, GdkEventKey* e) { - UserInterface* self; - gboolean result = FALSE; - gboolean _tmp0_ = FALSE; - GdkEventKey* _tmp1_ = NULL; - GdkModifierType _tmp2_ = 0; -#line 1185 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - self = _data2_->self; -#line 1185 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - g_return_val_if_fail (e != NULL, FALSE); -#line 1187 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp1_ = e; -#line 1187 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp2_ = _tmp1_->state; -#line 1187 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - if (_tmp2_ == 0) { -#line 5541 "ui.c" - GdkEventKey* _tmp3_ = NULL; - guint _tmp4_ = 0U; -#line 1187 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp3_ = e; -#line 1187 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp4_ = _tmp3_->keyval; -#line 1187 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp0_ = _tmp4_ == ((guint) GDK_KEY_Escape); -#line 5550 "ui.c" - } else { -#line 1187 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp0_ = FALSE; -#line 5554 "ui.c" - } -#line 1187 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - if (_tmp0_) { -#line 1189 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - gtk_widget_destroy ((GtkWidget*) _data2_->dialog); -#line 1190 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - result = TRUE; -#line 1190 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - return result; -#line 5564 "ui.c" - } -#line 1193 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - result = FALSE; -#line 1193 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - return result; -#line 5570 "ui.c" -} - - -static gboolean ___lambda6__gtk_widget_key_press_event (GtkWidget* _sender, GdkEventKey* event, gpointer self) { - gboolean result; - result = __lambda6_ (self, event); -#line 1185 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - return result; -#line 5579 "ui.c" -} - - -static void __lambda7_ (Block2Data* _data2_) { - UserInterface* self; - Book* _tmp0_ = NULL; -#line 1207 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - self = _data2_->self; -#line 1209 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp0_ = self->priv->_book; -#line 1209 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - book_combine_sides (_tmp0_); -#line 1210 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - gtk_widget_destroy ((GtkWidget*) _data2_->dialog); -#line 5594 "ui.c" -} - - -static void ___lambda7__gtk_button_clicked (GtkButton* _sender, gpointer self) { -#line 1207 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - __lambda7_ (self); -#line 5601 "ui.c" -} - - -static void __lambda8_ (Block2Data* _data2_) { - UserInterface* self; - Book* _tmp0_ = NULL; -#line 1217 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - self = _data2_->self; -#line 1219 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp0_ = self->priv->_book; -#line 1219 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - book_combine_sides_reverse (_tmp0_); -#line 1220 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - gtk_widget_destroy ((GtkWidget*) _data2_->dialog); -#line 5616 "ui.c" -} - - -static void ___lambda8__gtk_button_clicked (GtkButton* _sender, gpointer self) { -#line 1217 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - __lambda8_ (self); -#line 5623 "ui.c" -} - - -static void __lambda9_ (Block2Data* _data2_) { - UserInterface* self; - Book* _tmp0_ = NULL; -#line 1227 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - self = _data2_->self; -#line 1229 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp0_ = self->priv->_book; -#line 1229 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - book_reverse (_tmp0_); -#line 1230 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - gtk_widget_destroy ((GtkWidget*) _data2_->dialog); -#line 5638 "ui.c" -} - - -static void ___lambda9__gtk_button_clicked (GtkButton* _sender, gpointer self) { -#line 1227 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - __lambda9_ (self); -#line 5645 "ui.c" -} - - -static void __lambda10_ (Block2Data* _data2_) { - UserInterface* self; -#line 1237 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - self = _data2_->self; -#line 1239 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - gtk_widget_destroy ((GtkWidget*) _data2_->dialog); -#line 5655 "ui.c" -} - - -static void ___lambda10__gtk_button_clicked (GtkButton* _sender, gpointer self) { -#line 1237 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - __lambda10_ (self); -#line 5662 "ui.c" -} - - -static void user_interface_reorder_document (UserInterface* self) { - Block2Data* _data2_; - GtkWindow* _tmp0_ = NULL; - const gchar* _tmp1_ = NULL; - GtkGrid* g = NULL; - GtkGrid* _tmp2_ = NULL; - GtkButton* b = NULL; - const gchar* _tmp3_ = NULL; - GtkButton* _tmp4_ = NULL; - GtkButton* _tmp5_ = NULL; - GtkButton* _tmp6_ = NULL; - GtkButton* _tmp7_ = NULL; - const gchar* _tmp8_ = NULL; - GtkButton* _tmp9_ = NULL; - GtkButton* _tmp10_ = NULL; - GtkButton* _tmp11_ = NULL; - GtkButton* _tmp12_ = NULL; - const gchar* _tmp13_ = NULL; - GtkButton* _tmp14_ = NULL; - GtkButton* _tmp15_ = NULL; - GtkButton* _tmp16_ = NULL; - GtkButton* _tmp17_ = NULL; - const gchar* _tmp18_ = NULL; - GtkButton* _tmp19_ = NULL; - GtkButton* _tmp20_ = NULL; - GtkButton* _tmp21_ = NULL; - GtkButton* _tmp22_ = NULL; -#line 1176 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - g_return_if_fail (self != NULL); -#line 1176 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _data2_ = g_slice_new0 (Block2Data); -#line 1176 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _data2_->_ref_count_ = 1; -#line 1176 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _data2_->self = g_object_ref (self); -#line 1178 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp0_ = (GtkWindow*) gtk_window_new (GTK_WINDOW_TOPLEVEL); -#line 1178 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - g_object_ref_sink (_tmp0_); -#line 1178 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _data2_->dialog = _tmp0_; -#line 1179 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - gtk_window_set_type_hint (_data2_->dialog, GDK_WINDOW_TYPE_HINT_DIALOG); -#line 1180 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - gtk_window_set_modal (_data2_->dialog, TRUE); -#line 1181 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - gtk_container_set_border_width ((GtkContainer*) _data2_->dialog, (guint) 12); -#line 1183 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp1_ = _ ("Reorder Pages"); -#line 1183 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - gtk_window_set_title (_data2_->dialog, _tmp1_); -#line 1184 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - gtk_window_set_transient_for (_data2_->dialog, (GtkWindow*) self); -#line 1185 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - g_signal_connect_data ((GtkWidget*) _data2_->dialog, "key-press-event", (GCallback) ___lambda6__gtk_widget_key_press_event, block2_data_ref (_data2_), (GClosureNotify) block2_data_unref, 0); -#line 1195 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - gtk_widget_set_visible ((GtkWidget*) _data2_->dialog, TRUE); -#line 1197 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp2_ = (GtkGrid*) gtk_grid_new (); -#line 1197 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - g_object_ref_sink (_tmp2_); -#line 1197 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - g = _tmp2_; -#line 1198 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - gtk_grid_set_row_homogeneous (g, TRUE); -#line 1199 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - gtk_grid_set_row_spacing (g, 6); -#line 1200 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - gtk_grid_set_column_homogeneous (g, TRUE); -#line 1201 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - gtk_grid_set_column_spacing (g, 6); -#line 1202 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - gtk_widget_set_visible ((GtkWidget*) g, TRUE); -#line 1203 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - gtk_container_add ((GtkContainer*) _data2_->dialog, (GtkWidget*) g); -#line 1206 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp3_ = _ ("Combine sides"); -#line 1206 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp4_ = user_interface_make_reorder_button (self, _tmp3_, "F1F2F3B1B2B3-F1B1F2B2F3B3"); -#line 1206 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - b = _tmp4_; -#line 1207 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp5_ = b; -#line 1207 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - g_signal_connect_data (_tmp5_, "clicked", (GCallback) ___lambda7__gtk_button_clicked, block2_data_ref (_data2_), (GClosureNotify) block2_data_unref, 0); -#line 1212 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp6_ = b; -#line 1212 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - gtk_widget_set_visible ((GtkWidget*) _tmp6_, TRUE); -#line 1213 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp7_ = b; -#line 1213 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - gtk_grid_attach (g, (GtkWidget*) _tmp7_, 0, 0, 1, 1); -#line 1216 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp8_ = _ ("Combine sides (reverse)"); -#line 1216 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp9_ = user_interface_make_reorder_button (self, _tmp8_, "F1F2F3B3B2B1-F1B1F2B2F3B3"); -#line 1216 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _g_object_unref0 (b); -#line 1216 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - b = _tmp9_; -#line 1217 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp10_ = b; -#line 1217 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - g_signal_connect_data (_tmp10_, "clicked", (GCallback) ___lambda8__gtk_button_clicked, block2_data_ref (_data2_), (GClosureNotify) block2_data_unref, 0); -#line 1222 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp11_ = b; -#line 1222 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - gtk_widget_set_visible ((GtkWidget*) _tmp11_, TRUE); -#line 1223 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp12_ = b; -#line 1223 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - gtk_grid_attach (g, (GtkWidget*) _tmp12_, 1, 0, 1, 1); -#line 1226 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp13_ = _ ("Reverse"); -#line 1226 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp14_ = user_interface_make_reorder_button (self, _tmp13_, "C1C2C3C4C5C6-C6C5C4C3C2C1"); -#line 1226 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _g_object_unref0 (b); -#line 1226 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - b = _tmp14_; -#line 1227 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp15_ = b; -#line 1227 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - g_signal_connect_data (_tmp15_, "clicked", (GCallback) ___lambda9__gtk_button_clicked, block2_data_ref (_data2_), (GClosureNotify) block2_data_unref, 0); -#line 1232 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp16_ = b; -#line 1232 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - gtk_widget_set_visible ((GtkWidget*) _tmp16_, TRUE); -#line 1233 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp17_ = b; -#line 1233 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - gtk_grid_attach (g, (GtkWidget*) _tmp17_, 0, 2, 1, 1); -#line 1236 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp18_ = _ ("Keep unchanged"); -#line 1236 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp19_ = user_interface_make_reorder_button (self, _tmp18_, "C1C2C3C4C5C6-C1C2C3C4C5C6"); -#line 1236 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _g_object_unref0 (b); -#line 1236 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - b = _tmp19_; -#line 1237 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp20_ = b; -#line 1237 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - g_signal_connect_data (_tmp20_, "clicked", (GCallback) ___lambda10__gtk_button_clicked, block2_data_ref (_data2_), (GClosureNotify) block2_data_unref, 0); -#line 1241 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp21_ = b; -#line 1241 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - gtk_widget_set_visible ((GtkWidget*) _tmp21_, TRUE); -#line 1242 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp22_ = b; -#line 1242 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - gtk_grid_attach (g, (GtkWidget*) _tmp22_, 1, 2, 1, 1); -#line 1244 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - gtk_window_present (_data2_->dialog); -#line 1176 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _g_object_unref0 (b); -#line 1176 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _g_object_unref0 (g); -#line 1176 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - block2_data_unref (_data2_); -#line 1176 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _data2_ = NULL; -#line 5829 "ui.c" -} - - -void user_interface_reorder_document_activate_cb (UserInterface* self) { -#line 1247 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - g_return_if_fail (self != NULL); -#line 1249 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - user_interface_reorder_document (self); -#line 5838 "ui.c" -} - - -static void user_interface_reorder_menuitem_activate_cb (UserInterface* self, GtkWidget* widget) { -#line 1253 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - g_return_if_fail (self != NULL); -#line 1253 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - g_return_if_fail (widget != NULL); -#line 1255 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - user_interface_reorder_document (self); -#line 5849 "ui.c" -} - - -static void _user_interface_reorder_menuitem_activate_cb_gtk_menu_item_activate (GtkMenuItem* _sender, gpointer self) { -#line 14 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - user_interface_reorder_menuitem_activate_cb ((UserInterface*) self, _sender); -#line 5856 "ui.c" -} - - -static GtkButton* user_interface_make_reorder_button (UserInterface* self, const gchar* text, const gchar* items) { - GtkButton* result = NULL; - GtkButton* b = NULL; - GtkButton* _tmp0_ = NULL; - GtkBox* vbox = NULL; - GtkBox* _tmp1_ = NULL; - GtkLabel* label = NULL; - const gchar* _tmp2_ = NULL; - GtkLabel* _tmp3_ = NULL; - GtkBox* rb = NULL; - const gchar* _tmp4_ = NULL; - GtkBox* _tmp5_ = NULL; -#line 1258 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - g_return_val_if_fail (self != NULL, NULL); -#line 1258 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - g_return_val_if_fail (text != NULL, NULL); -#line 1258 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - g_return_val_if_fail (items != NULL, NULL); -#line 1260 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp0_ = (GtkButton*) gtk_button_new (); -#line 1260 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - g_object_ref_sink (_tmp0_); -#line 1260 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - b = _tmp0_; -#line 1262 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp1_ = (GtkBox*) gtk_box_new (GTK_ORIENTATION_VERTICAL, 6); -#line 1262 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - g_object_ref_sink (_tmp1_); -#line 1262 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - vbox = _tmp1_; -#line 1263 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - gtk_widget_set_visible ((GtkWidget*) vbox, TRUE); -#line 1264 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - gtk_container_add ((GtkContainer*) b, (GtkWidget*) vbox); -#line 1266 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp2_ = text; -#line 1266 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp3_ = (GtkLabel*) gtk_label_new (_tmp2_); -#line 1266 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - g_object_ref_sink (_tmp3_); -#line 1266 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - label = _tmp3_; -#line 1267 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - gtk_widget_set_visible ((GtkWidget*) label, TRUE); -#line 1268 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - gtk_box_pack_start (vbox, (GtkWidget*) label, TRUE, TRUE, (guint) 0); -#line 1270 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp4_ = items; -#line 1270 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp5_ = user_interface_make_reorder_box (self, _tmp4_); -#line 1270 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - rb = _tmp5_; -#line 1271 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - gtk_widget_set_visible ((GtkWidget*) rb, TRUE); -#line 1272 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - gtk_box_pack_start (vbox, (GtkWidget*) rb, TRUE, TRUE, (guint) 0); -#line 1274 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - result = b; -#line 1274 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _g_object_unref0 (rb); -#line 1274 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _g_object_unref0 (label); -#line 1274 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _g_object_unref0 (vbox); -#line 1274 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - return result; -#line 5926 "ui.c" -} - - -static gchar string_get (const gchar* self, glong index) { - gchar result = '\0'; - glong _tmp0_ = 0L; - gchar _tmp1_ = '\0'; -#line 1086 "/usr/share/vala-0.34/vapi/glib-2.0.vapi" - g_return_val_if_fail (self != NULL, '\0'); -#line 1087 "/usr/share/vala-0.34/vapi/glib-2.0.vapi" - _tmp0_ = index; -#line 1087 "/usr/share/vala-0.34/vapi/glib-2.0.vapi" - _tmp1_ = ((gchar*) self)[_tmp0_]; -#line 1087 "/usr/share/vala-0.34/vapi/glib-2.0.vapi" - result = _tmp1_; -#line 1087 "/usr/share/vala-0.34/vapi/glib-2.0.vapi" - return result; -#line 5944 "ui.c" -} - - -static GtkBox* user_interface_make_reorder_box (UserInterface* self, const gchar* items) { - GtkBox* result = NULL; - GtkBox* box = NULL; - GtkBox* _tmp0_ = NULL; - GtkBox* _tmp1_ = NULL; - GtkBox* page_box = NULL; -#line 1277 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - g_return_val_if_fail (self != NULL, NULL); -#line 1277 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - g_return_val_if_fail (items != NULL, NULL); -#line 1279 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp0_ = (GtkBox*) gtk_box_new (GTK_ORIENTATION_HORIZONTAL, 6); -#line 1279 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - g_object_ref_sink (_tmp0_); -#line 1279 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - box = _tmp0_; -#line 1280 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp1_ = box; -#line 1280 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - gtk_widget_set_visible ((GtkWidget*) _tmp1_, TRUE); -#line 1282 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - page_box = NULL; -#line 5970 "ui.c" - { - gint i = 0; -#line 1283 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - i = 0; -#line 5975 "ui.c" - { - gboolean _tmp2_ = FALSE; -#line 1283 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp2_ = TRUE; -#line 1283 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - while (TRUE) { -#line 5982 "ui.c" - const gchar* _tmp4_ = NULL; - gint _tmp5_ = 0; - gchar _tmp6_ = '\0'; - const gchar* _tmp7_ = NULL; - gint _tmp8_ = 0; - gchar _tmp9_ = '\0'; - gchar side = '\0'; - const gchar* _tmp14_ = NULL; - gint _tmp15_ = 0; - gchar _tmp16_ = '\0'; - gint _tmp17_ = 0; - const gchar* _tmp18_ = NULL; - gint _tmp19_ = 0; - gchar _tmp20_ = '\0'; - GtkBox* _tmp21_ = NULL; - gdouble r = 0.0; - gdouble g = 0.0; - gdouble b = 0.0; - gchar _tmp26_ = '\0'; - gdouble _tmp33_ = 0.0; - gdouble _tmp34_ = 0.0; - gdouble _tmp35_ = 0.0; - gdouble _tmp36_ = 0.0; - gdouble _tmp37_ = 0.0; - gdouble _tmp38_ = 0.0; - PageIcon* icon = NULL; - const gchar* _tmp39_ = NULL; - gint _tmp40_ = 0; - gchar _tmp41_ = '\0'; - gchar* _tmp42_ = NULL; - gchar* _tmp43_ = NULL; - gdouble _tmp44_ = 0.0; - gdouble _tmp45_ = 0.0; - gdouble _tmp46_ = 0.0; - PageIcon* _tmp47_ = NULL; - PageIcon* _tmp48_ = NULL; - PageIcon* _tmp49_ = NULL; - GtkBox* _tmp50_ = NULL; - PageIcon* _tmp51_ = NULL; -#line 1283 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - if (!_tmp2_) { -#line 6024 "ui.c" - gint _tmp3_ = 0; -#line 1283 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp3_ = i; -#line 1283 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - i = _tmp3_ + 1; -#line 6030 "ui.c" - } -#line 1283 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp2_ = FALSE; -#line 1283 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp4_ = items; -#line 1283 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp5_ = i; -#line 1283 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp6_ = string_get (_tmp4_, (glong) _tmp5_); -#line 1283 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - if (!(_tmp6_ != '\0')) { -#line 1283 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - break; -#line 6044 "ui.c" - } -#line 1285 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp7_ = items; -#line 1285 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp8_ = i; -#line 1285 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp9_ = string_get (_tmp7_, (glong) _tmp8_); -#line 1285 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - if (_tmp9_ == '-') { -#line 6054 "ui.c" - GtkArrow* a = NULL; - GtkArrow* _tmp10_ = NULL; - GtkArrow* _tmp11_ = NULL; - GtkBox* _tmp12_ = NULL; - GtkArrow* _tmp13_ = NULL; -#line 1287 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp10_ = (GtkArrow*) gtk_arrow_new (GTK_ARROW_RIGHT, GTK_SHADOW_NONE); -#line 1287 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - g_object_ref_sink (_tmp10_); -#line 1287 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - a = _tmp10_; -#line 1288 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp11_ = a; -#line 1288 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - gtk_widget_set_visible ((GtkWidget*) _tmp11_, TRUE); -#line 1289 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp12_ = box; -#line 1289 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp13_ = a; -#line 1289 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - gtk_box_pack_start (_tmp12_, (GtkWidget*) _tmp13_, FALSE, FALSE, (guint) 0); -#line 1290 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _g_object_unref0 (page_box); -#line 1290 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - page_box = NULL; -#line 1291 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _g_object_unref0 (a); -#line 1291 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - continue; -#line 6084 "ui.c" - } -#line 1295 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp14_ = items; -#line 1295 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp15_ = i; -#line 1295 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp16_ = string_get (_tmp14_, (glong) _tmp15_); -#line 1295 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - side = _tmp16_; -#line 1296 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp17_ = i; -#line 1296 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - i = _tmp17_ + 1; -#line 1297 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp18_ = items; -#line 1297 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp19_ = i; -#line 1297 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp20_ = string_get (_tmp18_, (glong) _tmp19_); -#line 1297 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - if (_tmp20_ == '\0') { -#line 1298 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - break; -#line 6108 "ui.c" - } -#line 1300 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp21_ = page_box; -#line 1300 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - if (_tmp21_ == NULL) { -#line 6114 "ui.c" - GtkBox* _tmp22_ = NULL; - GtkBox* _tmp23_ = NULL; - GtkBox* _tmp24_ = NULL; - GtkBox* _tmp25_ = NULL; -#line 1302 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp22_ = (GtkBox*) gtk_box_new (GTK_ORIENTATION_HORIZONTAL, 3); -#line 1302 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - g_object_ref_sink (_tmp22_); -#line 1302 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _g_object_unref0 (page_box); -#line 1302 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - page_box = _tmp22_; -#line 1303 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp23_ = page_box; -#line 1303 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - gtk_widget_set_visible ((GtkWidget*) _tmp23_, TRUE); -#line 1304 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp24_ = box; -#line 1304 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp25_ = page_box; -#line 1304 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - gtk_box_pack_start (_tmp24_, (GtkWidget*) _tmp25_, FALSE, FALSE, (guint) 0); -#line 6137 "ui.c" - } -#line 1308 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - r = 1.0; -#line 1309 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - g = 1.0; -#line 1310 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - b = 1.0; -#line 1311 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp26_ = side; -#line 1311 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - switch (_tmp26_) { -#line 1311 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - case 'F': -#line 6151 "ui.c" - { -#line 1315 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - r = 0x75 / 255.0; -#line 1316 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - g = 0x50 / 255.0; -#line 1317 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - b = 0x7B / 255.0; -#line 1318 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - break; -#line 6161 "ui.c" - } -#line 1311 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - case 'B': -#line 6165 "ui.c" - { -#line 1321 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - r = 0xF5 / 255.0; -#line 1322 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - g = 0x79 / 255.0; -#line 1323 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - b = 0.0; -#line 1324 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - break; -#line 6175 "ui.c" - } -#line 1311 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - case 'C': -#line 6179 "ui.c" - { - gdouble p = 0.0; - const gchar* _tmp27_ = NULL; - gint _tmp28_ = 0; - gchar _tmp29_ = '\0'; - gdouble _tmp30_ = 0.0; - gdouble _tmp31_ = 0.0; - gdouble _tmp32_ = 0.0; -#line 1327 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp27_ = items; -#line 1327 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp28_ = i; -#line 1327 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp29_ = string_get (_tmp27_, (glong) _tmp28_); -#line 1327 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - p = (_tmp29_ - '1') / 5.0; -#line 1328 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp30_ = p; -#line 1328 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp31_ = p; -#line 1328 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - r = ((0xED / 255.0) * (1 - _tmp30_)) + (0xCC * _tmp31_); -#line 1329 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp32_ = p; -#line 1329 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - g = (0xD4 / 255.0) * (1 - _tmp32_); -#line 1330 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - b = (gdouble) 0; -#line 1331 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - break; -#line 6210 "ui.c" - } - default: -#line 1311 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - break; -#line 6215 "ui.c" - } -#line 1335 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp33_ = r; -#line 1335 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp34_ = r; -#line 1335 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - r = _tmp33_ + ((1.0 - _tmp34_) * 0.7); -#line 1336 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp35_ = g; -#line 1336 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp36_ = g; -#line 1336 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - g = _tmp35_ + ((1.0 - _tmp36_) * 0.7); -#line 1337 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp37_ = b; -#line 1337 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp38_ = b; -#line 1337 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - b = _tmp37_ + ((1.0 - _tmp38_) * 0.7); -#line 1339 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp39_ = items; -#line 1339 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp40_ = i; -#line 1339 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp41_ = string_get (_tmp39_, (glong) _tmp40_); -#line 1339 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp42_ = g_strdup_printf ("%c", (gint) _tmp41_); -#line 1339 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp43_ = _tmp42_; -#line 1339 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp44_ = r; -#line 1339 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp45_ = g; -#line 1339 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp46_ = b; -#line 1339 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp47_ = page_icon_new (_tmp43_, _tmp44_, _tmp45_, _tmp46_); -#line 1339 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - g_object_ref_sink (_tmp47_); -#line 1339 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp48_ = _tmp47_; -#line 1339 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _g_free0 (_tmp43_); -#line 1339 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - icon = _tmp48_; -#line 1340 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp49_ = icon; -#line 1340 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - gtk_widget_set_visible ((GtkWidget*) _tmp49_, TRUE); -#line 1341 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp50_ = page_box; -#line 1341 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp51_ = icon; -#line 1341 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - gtk_box_pack_start (_tmp50_, (GtkWidget*) _tmp51_, FALSE, FALSE, (guint) 0); -#line 1283 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _g_object_unref0 (icon); -#line 6273 "ui.c" - } - } - } -#line 1344 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - result = box; -#line 1344 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _g_object_unref0 (page_box); -#line 1344 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - return result; -#line 6283 "ui.c" -} - - -static void user_interface_save_file_button_clicked_cb (UserInterface* self, GtkWidget* widget) { -#line 1348 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - g_return_if_fail (self != NULL); -#line 1348 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - g_return_if_fail (widget != NULL); -#line 1350 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - user_interface_save_document (self, FALSE); -#line 6294 "ui.c" -} - - -static void _user_interface_save_file_button_clicked_cb_gtk_button_clicked (GtkButton* _sender, gpointer self) { -#line 14 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - user_interface_save_file_button_clicked_cb ((UserInterface*) self, _sender); -#line 6301 "ui.c" -} - - -void user_interface_save_document_activate_cb (UserInterface* self) { -#line 1353 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - g_return_if_fail (self != NULL); -#line 1355 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - user_interface_save_document (self, FALSE); -#line 6310 "ui.c" -} - - -static void user_interface_copy_to_clipboard_button_clicked_cb (UserInterface* self, GtkWidget* widget) { - Page* page = NULL; - BookView* _tmp0_ = NULL; - Page* _tmp1_ = NULL; - Page* _tmp2_ = NULL; - Page* _tmp3_ = NULL; - Page* _tmp4_ = NULL; -#line 1359 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - g_return_if_fail (self != NULL); -#line 1359 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - g_return_if_fail (widget != NULL); -#line 1361 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp0_ = self->priv->book_view; -#line 1361 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp1_ = book_view_get_selected_page (_tmp0_); -#line 1361 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp2_ = _tmp1_; -#line 1361 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp3_ = _page_ref0 (_tmp2_); -#line 1361 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - page = _tmp3_; -#line 1362 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp4_ = page; -#line 1362 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - if (_tmp4_ != NULL) { -#line 6339 "ui.c" - Page* _tmp5_ = NULL; -#line 1363 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp5_ = page; -#line 1363 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - page_copy_to_clipboard (_tmp5_, (GtkWindow*) self); -#line 6345 "ui.c" - } -#line 1359 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _page_unref0 (page); -#line 6349 "ui.c" -} - - -static void _user_interface_copy_to_clipboard_button_clicked_cb_gtk_menu_item_activate (GtkMenuItem* _sender, gpointer self) { -#line 14 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - user_interface_copy_to_clipboard_button_clicked_cb ((UserInterface*) self, _sender); -#line 6356 "ui.c" -} - - -static void user_interface_save_as_file_button_clicked_cb (UserInterface* self, GtkWidget* widget) { -#line 1367 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - g_return_if_fail (self != NULL); -#line 1367 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - g_return_if_fail (widget != NULL); -#line 1369 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - user_interface_save_document (self, TRUE); -#line 6367 "ui.c" -} - - -static void _user_interface_save_as_file_button_clicked_cb_gtk_menu_item_activate (GtkMenuItem* _sender, gpointer self) { -#line 14 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - user_interface_save_as_file_button_clicked_cb ((UserInterface*) self, _sender); -#line 6374 "ui.c" -} - - -void user_interface_save_as_document_activate_cb (UserInterface* self) { -#line 1372 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - g_return_if_fail (self != NULL); -#line 1374 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - user_interface_save_document (self, TRUE); -#line 6383 "ui.c" -} - - -static gpointer _cairo_reference0 (gpointer self) { -#line 1381 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - return self ? cairo_reference (self) : NULL; -#line 6390 "ui.c" -} - - -static void user_interface_draw_page (UserInterface* self, GtkPrintOperation* operation, GtkPrintContext* print_context, gint page_number) { - cairo_t* context = NULL; - GtkPrintContext* _tmp0_ = NULL; - cairo_t* _tmp1_ = NULL; - cairo_t* _tmp2_ = NULL; - Page* page = NULL; - Book* _tmp3_ = NULL; - gint _tmp4_ = 0; - Page* _tmp5_ = NULL; - gboolean is_landscape = FALSE; - GtkPrintContext* _tmp6_ = NULL; - gdouble _tmp7_ = 0.0; - GtkPrintContext* _tmp8_ = NULL; - gdouble _tmp9_ = 0.0; - Page* _tmp10_ = NULL; - gboolean _tmp11_ = FALSE; - gboolean _tmp12_ = FALSE; - gboolean _tmp13_ = FALSE; - cairo_t* _tmp18_ = NULL; - GtkPrintContext* _tmp19_ = NULL; - gdouble _tmp20_ = 0.0; - Page* _tmp21_ = NULL; - gint _tmp22_ = 0; - gint _tmp23_ = 0; - GtkPrintContext* _tmp24_ = NULL; - gdouble _tmp25_ = 0.0; - Page* _tmp26_ = NULL; - gint _tmp27_ = 0; - gint _tmp28_ = 0; - GdkPixbuf* image = NULL; - Page* _tmp29_ = NULL; - GdkPixbuf* _tmp30_ = NULL; - cairo_t* _tmp31_ = NULL; - cairo_t* _tmp32_ = NULL; -#line 1377 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - g_return_if_fail (self != NULL); -#line 1377 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - g_return_if_fail (operation != NULL); -#line 1377 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - g_return_if_fail (print_context != NULL); -#line 1381 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp0_ = print_context; -#line 1381 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp1_ = gtk_print_context_get_cairo_context (_tmp0_); -#line 1381 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp2_ = _cairo_reference0 (_tmp1_); -#line 1381 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - context = _tmp2_; -#line 1382 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp3_ = self->priv->_book; -#line 1382 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp4_ = page_number; -#line 1382 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp5_ = book_get_page (_tmp3_, _tmp4_); -#line 1382 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - page = _tmp5_; -#line 1385 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - is_landscape = FALSE; -#line 1386 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp6_ = print_context; -#line 1386 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp7_ = gtk_print_context_get_width (_tmp6_); -#line 1386 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp8_ = print_context; -#line 1386 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp9_ = gtk_print_context_get_height (_tmp8_); -#line 1386 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - if (_tmp7_ > _tmp9_) { -#line 1387 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - is_landscape = TRUE; -#line 6464 "ui.c" - } -#line 1388 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp10_ = page; -#line 1388 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp11_ = page_get_is_landscape (_tmp10_); -#line 1388 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp12_ = _tmp11_; -#line 1388 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp13_ = is_landscape; -#line 1388 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - if (_tmp12_ != _tmp13_) { -#line 6476 "ui.c" - cairo_t* _tmp14_ = NULL; - GtkPrintContext* _tmp15_ = NULL; - gdouble _tmp16_ = 0.0; - cairo_t* _tmp17_ = NULL; -#line 1390 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp14_ = context; -#line 1390 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp15_ = print_context; -#line 1390 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp16_ = gtk_print_context_get_width (_tmp15_); -#line 1390 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - cairo_translate (_tmp14_, _tmp16_, (gdouble) 0); -#line 1391 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp17_ = context; -#line 1391 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - cairo_rotate (_tmp17_, G_PI_2); -#line 6493 "ui.c" - } -#line 1394 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp18_ = context; -#line 1394 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp19_ = print_context; -#line 1394 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp20_ = gtk_print_context_get_dpi_x (_tmp19_); -#line 1394 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp21_ = page; -#line 1394 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp22_ = page_get_dpi (_tmp21_); -#line 1394 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp23_ = _tmp22_; -#line 1394 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp24_ = print_context; -#line 1394 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp25_ = gtk_print_context_get_dpi_y (_tmp24_); -#line 1394 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp26_ = page; -#line 1394 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp27_ = page_get_dpi (_tmp26_); -#line 1394 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp28_ = _tmp27_; -#line 1394 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - cairo_scale (_tmp18_, _tmp20_ / _tmp23_, _tmp25_ / _tmp28_); -#line 1397 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp29_ = page; -#line 1397 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp30_ = page_get_image (_tmp29_, TRUE); -#line 1397 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - image = _tmp30_; -#line 1398 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp31_ = context; -#line 1398 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - gdk_cairo_set_source_pixbuf (_tmp31_, image, (gdouble) 0, (gdouble) 0); -#line 1399 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp32_ = context; -#line 1399 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - cairo_paint (_tmp32_); -#line 1377 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _g_object_unref0 (image); -#line 1377 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _page_unref0 (page); -#line 1377 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _cairo_destroy0 (context); -#line 6539 "ui.c" -} - - -static void user_interface_email_button_clicked_cb (UserInterface* self, GtkWidget* widget) { - const gchar* _tmp0_ = NULL; - gint _tmp1_ = 0; - gint _tmp2_ = 0; -#line 1403 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - g_return_if_fail (self != NULL); -#line 1403 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - g_return_if_fail (widget != NULL); -#line 1405 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp0_ = self->priv->document_hint; -#line 1405 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp1_ = user_interface_get_quality (self); -#line 1405 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp2_ = _tmp1_; -#line 1405 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - g_signal_emit_by_name (self, "email", _tmp0_, _tmp2_); -#line 6559 "ui.c" -} - - -static void _user_interface_email_button_clicked_cb_gtk_menu_item_activate (GtkMenuItem* _sender, gpointer self) { -#line 14 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - user_interface_email_button_clicked_cb ((UserInterface*) self, _sender); -#line 6566 "ui.c" -} - - -void user_interface_email_document_activate_cb (UserInterface* self) { - const gchar* _tmp0_ = NULL; - gint _tmp1_ = 0; - gint _tmp2_ = 0; -#line 1408 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - g_return_if_fail (self != NULL); -#line 1410 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp0_ = self->priv->document_hint; -#line 1410 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp1_ = user_interface_get_quality (self); -#line 1410 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp2_ = _tmp1_; -#line 1410 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - g_signal_emit_by_name (self, "email", _tmp0_, _tmp2_); -#line 6584 "ui.c" -} - - -static void _user_interface_draw_page_gtk_print_operation_draw_page (GtkPrintOperation* _sender, GtkPrintContext* context, gint page_nr, gpointer self) { -#line 1417 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - user_interface_draw_page ((UserInterface*) self, _sender, context, page_nr); -#line 6591 "ui.c" -} - - -static void user_interface_print_document (UserInterface* self) { - GtkPrintOperation* print = NULL; - GtkPrintOperation* _tmp0_ = NULL; - Book* _tmp1_ = NULL; - guint _tmp2_ = 0U; - guint _tmp3_ = 0U; - guint _tmp6_ = 0U; - GError * _inner_error_ = NULL; -#line 1413 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - g_return_if_fail (self != NULL); -#line 1415 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp0_ = gtk_print_operation_new (); -#line 1415 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - print = _tmp0_; -#line 1416 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp1_ = self->priv->_book; -#line 1416 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp2_ = book_get_n_pages (_tmp1_); -#line 1416 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp3_ = _tmp2_; -#line 1416 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - g_object_set (print, "n-pages", (gint) _tmp3_, NULL); -#line 1417 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - g_signal_connect_object (print, "draw-page", (GCallback) _user_interface_draw_page_gtk_print_operation_draw_page, self, 0); -#line 6619 "ui.c" - { -#line 1421 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - gtk_print_operation_run (print, GTK_PRINT_OPERATION_ACTION_PRINT_DIALOG, (GtkWindow*) self, &_inner_error_); -#line 1421 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - if (G_UNLIKELY (_inner_error_ != NULL)) { -#line 6625 "ui.c" - goto __catch20_g_error; - } - } - goto __finally20; - __catch20_g_error: - { - GError* e = NULL; - GError* _tmp4_ = NULL; - const gchar* _tmp5_ = NULL; -#line 1419 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - e = _inner_error_; -#line 1419 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _inner_error_ = NULL; -#line 1425 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp4_ = e; -#line 1425 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp5_ = _tmp4_->message; -#line 1425 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - g_warning ("ui.vala:1425: Error printing: %s", _tmp5_); -#line 1419 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _g_error_free0 (e); -#line 6647 "ui.c" - } - __finally20: -#line 1419 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - if (G_UNLIKELY (_inner_error_ != NULL)) { -#line 1419 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _g_object_unref0 (print); -#line 1419 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - g_critical ("file %s: line %d: uncaught error: %s (%s, %d)", __FILE__, __LINE__, _inner_error_->message, g_quark_to_string (_inner_error_->domain), _inner_error_->code); -#line 1419 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - g_clear_error (&_inner_error_); -#line 1419 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - return; -#line 6660 "ui.c" - } -#line 1428 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - g_signal_parse_name ("draw-page", gtk_print_operation_get_type (), &_tmp6_, NULL, FALSE); -#line 1428 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - g_signal_handlers_disconnect_matched (print, G_SIGNAL_MATCH_ID | G_SIGNAL_MATCH_FUNC | G_SIGNAL_MATCH_DATA, _tmp6_, 0, NULL, (GCallback) _user_interface_draw_page_gtk_print_operation_draw_page, self); -#line 1413 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _g_object_unref0 (print); -#line 6668 "ui.c" -} - - -static void user_interface_print_button_clicked_cb (UserInterface* self, GtkWidget* widget) { -#line 1432 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - g_return_if_fail (self != NULL); -#line 1432 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - g_return_if_fail (widget != NULL); -#line 1434 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - user_interface_print_document (self); -#line 6679 "ui.c" -} - - -static void _user_interface_print_button_clicked_cb_gtk_menu_item_activate (GtkMenuItem* _sender, gpointer self) { -#line 14 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - user_interface_print_button_clicked_cb ((UserInterface*) self, _sender); -#line 6686 "ui.c" -} - - -void user_interface_print_document_activate_cb (UserInterface* self) { -#line 1437 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - g_return_if_fail (self != NULL); -#line 1439 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - user_interface_print_document (self); -#line 6695 "ui.c" -} - - -static void user_interface_launch_help (UserInterface* self) { - GError * _inner_error_ = NULL; -#line 1442 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - g_return_if_fail (self != NULL); -#line 6703 "ui.c" - { - GdkScreen* _tmp0_ = NULL; - GdkScreen* _tmp1_ = NULL; - guint32 _tmp2_ = 0U; -#line 1446 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp0_ = gtk_window_get_screen ((GtkWindow*) self); -#line 1446 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp1_ = _tmp0_; -#line 1446 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp2_ = gtk_get_current_event_time (); -#line 1446 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - gtk_show_uri (_tmp1_, "help:simple-scan", _tmp2_, &_inner_error_); -#line 1446 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - if (G_UNLIKELY (_inner_error_ != NULL)) { -#line 6718 "ui.c" - goto __catch21_g_error; - } - } - goto __finally21; - __catch21_g_error: - { - GError* e = NULL; - const gchar* _tmp3_ = NULL; - GError* _tmp4_ = NULL; - const gchar* _tmp5_ = NULL; -#line 1444 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - e = _inner_error_; -#line 1444 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _inner_error_ = NULL; -#line 1450 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp3_ = _ ("Unable to open help file"); -#line 1450 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp4_ = e; -#line 1450 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp5_ = _tmp4_->message; -#line 1450 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - user_interface_show_error_dialog (self, _tmp3_, _tmp5_); -#line 1444 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _g_error_free0 (e); -#line 6743 "ui.c" - } - __finally21: -#line 1444 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - if (G_UNLIKELY (_inner_error_ != NULL)) { -#line 1444 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - g_critical ("file %s: line %d: uncaught error: %s (%s, %d)", __FILE__, __LINE__, _inner_error_->message, g_quark_to_string (_inner_error_->domain), _inner_error_->code); -#line 1444 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - g_clear_error (&_inner_error_); -#line 1444 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - return; -#line 6754 "ui.c" - } -} - - -static void user_interface_help_contents_menuitem_activate_cb (UserInterface* self, GtkWidget* widget) { -#line 1457 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - g_return_if_fail (self != NULL); -#line 1457 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - g_return_if_fail (widget != NULL); -#line 1459 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - user_interface_launch_help (self); -#line 6766 "ui.c" -} - - -static void _user_interface_help_contents_menuitem_activate_cb_gtk_menu_item_activate (GtkMenuItem* _sender, gpointer self) { -#line 14 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - user_interface_help_contents_menuitem_activate_cb ((UserInterface*) self, _sender); -#line 6773 "ui.c" -} - - -void user_interface_help_contents_activate_cb (UserInterface* self) { -#line 1462 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - g_return_if_fail (self != NULL); -#line 1464 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - user_interface_launch_help (self); -#line 6782 "ui.c" -} - - -static void user_interface_show_about (UserInterface* self) { - gchar** authors = NULL; - gchar* _tmp0_ = NULL; - gchar** _tmp1_ = NULL; - gint authors_length1 = 0; - gint _authors_size_ = 0; - gchar* license = NULL; - const gchar* _tmp2_ = NULL; - gchar* _tmp3_ = NULL; - gchar* title = NULL; - const gchar* _tmp4_ = NULL; - gchar* _tmp5_ = NULL; - gchar* description = NULL; - const gchar* _tmp6_ = NULL; - gchar* _tmp7_ = NULL; - const gchar* _tmp8_ = NULL; -#line 1467 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - g_return_if_fail (self != NULL); -#line 1469 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp0_ = g_strdup ("Robert Ancell "); -#line 1469 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp1_ = g_new0 (gchar*, 1 + 1); -#line 1469 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp1_[0] = _tmp0_; -#line 1469 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - authors = _tmp1_; -#line 1469 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - authors_length1 = 1; -#line 1469 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _authors_size_ = authors_length1; -#line 1472 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp2_ = _ ("This program is free software: you can redistribute it and/or modify\n" \ -"it under the terms of the GNU General Public License as published by\n" \ -"the Free Software Foundation, either version 3 of the License, or\n" \ -"(at your option) any later version.\n" \ -"\n" \ -"This program is distributed in the hope that it will be useful,\n" \ -"but WITHOUT ANY WARRANTY; without even the implied warranty of\n" \ -"MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the\n" \ -"GNU General Public License for more details.\n" \ -"\n" \ -"You should have received a copy of the GNU General Public License\n" \ -"along with this program. If not, see ."); -#line 1472 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp3_ = g_strdup (_tmp2_); -#line 1472 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - license = _tmp3_; -#line 1475 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp4_ = _ ("About Simple Scan"); -#line 1475 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp5_ = g_strdup (_tmp4_); -#line 1475 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - title = _tmp5_; -#line 1478 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp6_ = _ ("Simple document scanning tool"); -#line 1478 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp7_ = g_strdup (_tmp6_); -#line 1478 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - description = _tmp7_; -#line 1480 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp8_ = _ ("translator-credits"); -#line 1480 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - gtk_show_about_dialog ((GtkWindow*) self, "title", title, "program-name", "Simple Scan", "version", VERSION, "comments", description, "logo-icon-name", "scanner", "authors", authors, "translator-credits", _tmp8_, "website", "https://launchpad.net/simple-scan", "copyright", "Copyright © 2009-2015 Canonical Ltd.", "license", license, "wrap-license", TRUE, NULL, NULL); -#line 1467 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _g_free0 (description); -#line 1467 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _g_free0 (title); -#line 1467 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _g_free0 (license); -#line 1467 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - authors = (_vala_array_free (authors, authors_length1, (GDestroyNotify) g_free), NULL); -#line 6846 "ui.c" -} - - -static void user_interface_about_menuitem_activate_cb (UserInterface* self, GtkWidget* widget) { -#line 1496 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - g_return_if_fail (self != NULL); -#line 1496 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - g_return_if_fail (widget != NULL); -#line 1498 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - user_interface_show_about (self); -#line 6857 "ui.c" -} - - -static void _user_interface_about_menuitem_activate_cb_gtk_menu_item_activate (GtkMenuItem* _sender, gpointer self) { -#line 14 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - user_interface_about_menuitem_activate_cb ((UserInterface*) self, _sender); -#line 6864 "ui.c" -} - - -void user_interface_about_activate_cb (UserInterface* self) { -#line 1501 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - g_return_if_fail (self != NULL); -#line 1503 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - user_interface_show_about (self); -#line 6873 "ui.c" -} - - -static gboolean user_interface_on_quit (UserInterface* self) { - gboolean result = FALSE; - const gchar* _tmp0_ = NULL; - const gchar* _tmp1_ = NULL; - gboolean _tmp2_ = FALSE; - guint _tmp3_ = 0U; - AutosaveManager* _tmp4_ = NULL; -#line 1506 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - g_return_val_if_fail (self != NULL, FALSE); -#line 1508 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp0_ = _ ("Save document before quitting?"); -#line 1508 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp1_ = _ ("Quit without Saving"); -#line 1508 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp2_ = user_interface_prompt_to_save (self, _tmp0_, _tmp1_); -#line 1508 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - if (!_tmp2_) { -#line 1512 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - result = FALSE; -#line 1512 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - return result; -#line 6898 "ui.c" - } -#line 1514 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - gtk_widget_destroy ((GtkWidget*) self); -#line 1516 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp3_ = self->priv->save_state_timeout; -#line 1516 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - if (_tmp3_ != ((guint) 0)) { -#line 1517 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - user_interface_save_state (self, TRUE); -#line 6908 "ui.c" - } -#line 1519 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp4_ = self->priv->autosave_manager; -#line 1519 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - autosave_manager_cleanup (_tmp4_); -#line 1521 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - result = TRUE; -#line 1521 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - return result; -#line 6918 "ui.c" -} - - -static void user_interface_quit_menuitem_activate_cb (UserInterface* self, GtkWidget* widget) { -#line 1525 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - g_return_if_fail (self != NULL); -#line 1525 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - g_return_if_fail (widget != NULL); -#line 1527 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - user_interface_on_quit (self); -#line 6929 "ui.c" -} - - -static void _user_interface_quit_menuitem_activate_cb_gtk_menu_item_activate (GtkMenuItem* _sender, gpointer self) { -#line 14 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - user_interface_quit_menuitem_activate_cb ((UserInterface*) self, _sender); -#line 6936 "ui.c" -} - - -void user_interface_quit_activate_cb (UserInterface* self) { -#line 1530 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - g_return_if_fail (self != NULL); -#line 1532 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - user_interface_on_quit (self); -#line 6945 "ui.c" -} - - -static void user_interface_real_size_allocate (GtkWidget* base, GtkAllocation* allocation) { - UserInterface * self; - GtkAllocation _tmp0_ = {0}; - gboolean _tmp1_ = FALSE; - gboolean _tmp2_ = FALSE; -#line 1535 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - self = (UserInterface*) base; -#line 1535 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - g_return_if_fail (allocation != NULL); -#line 1537 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp0_ = *allocation; -#line 1537 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - GTK_WIDGET_CLASS (user_interface_parent_class)->size_allocate ((GtkWidget*) G_TYPE_CHECK_INSTANCE_CAST (self, gtk_application_window_get_type (), GtkApplicationWindow), &_tmp0_); -#line 1539 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp2_ = self->priv->window_is_maximized; -#line 1539 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - if (!_tmp2_) { -#line 6966 "ui.c" - gboolean _tmp3_ = FALSE; -#line 1539 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp3_ = self->priv->window_is_fullscreen; -#line 1539 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp1_ = !_tmp3_; -#line 6972 "ui.c" - } else { -#line 1539 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp1_ = FALSE; -#line 6976 "ui.c" - } -#line 1539 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - if (_tmp1_) { -#line 6980 "ui.c" - gint _tmp4_ = 0; - gint _tmp5_ = 0; -#line 1541 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - gtk_window_get_size ((GtkWindow*) self, &_tmp4_, &_tmp5_); -#line 1541 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - self->priv->window_width = _tmp4_; -#line 1541 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - self->priv->window_height = _tmp5_; -#line 1542 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - user_interface_save_state (self, FALSE); -#line 6991 "ui.c" - } -} - - -static void user_interface_info_bar_response_cb (UserInterface* self, GtkInfoBar* widget, gint response_id) { - gint _tmp0_ = 0; -#line 1546 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - g_return_if_fail (self != NULL); -#line 1546 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - g_return_if_fail (widget != NULL); -#line 1548 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp0_ = response_id; -#line 1548 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - switch (_tmp0_) { -#line 1548 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - case 1: -#line 7008 "ui.c" - { - GtkComboBox* _tmp1_ = NULL; - GtkDialog* _tmp2_ = NULL; -#line 1552 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp1_ = self->priv->device_combo; -#line 1552 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - gtk_widget_grab_focus ((GtkWidget*) _tmp1_); -#line 1553 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp2_ = self->priv->preferences_dialog; -#line 1553 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - gtk_window_present ((GtkWindow*) _tmp2_); -#line 1554 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - break; -#line 7022 "ui.c" - } -#line 1548 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - case 2: -#line 7026 "ui.c" - { -#line 1557 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - user_interface_install_drivers (self); -#line 1558 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - break; -#line 7032 "ui.c" - } - default: - { -#line 1560 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - self->priv->have_error = FALSE; -#line 1561 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _g_free0 (self->priv->error_title); -#line 1561 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - self->priv->error_title = NULL; -#line 1562 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _g_free0 (self->priv->error_text); -#line 1562 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - self->priv->error_text = NULL; -#line 1563 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - user_interface_update_info_bar (self); -#line 1564 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - break; -#line 7050 "ui.c" - } - } -} - - -static Block3Data* block3_data_ref (Block3Data* _data3_) { -#line 1568 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - g_atomic_int_inc (&_data3_->_ref_count_); -#line 1568 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - return _data3_; -#line 7061 "ui.c" -} - - -static void block3_data_unref (void * _userdata_) { - Block3Data* _data3_; - _data3_ = (Block3Data*) _userdata_; -#line 1568 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - if (g_atomic_int_dec_and_test (&_data3_->_ref_count_)) { -#line 7070 "ui.c" - UserInterface* self; -#line 1568 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - self = _data3_->self; -#line 1568 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _g_object_unref0 (_data3_->instructions_label); -#line 1568 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _g_object_unref0 (_data3_->status_label); -#line 1568 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _g_object_unref0 (_data3_->spinner); -#line 1568 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _g_object_unref0 (_data3_->stack); -#line 1568 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _g_object_unref0 (self); -#line 1568 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - g_slice_free (Block3Data, _data3_); -#line 7086 "ui.c" - } -} - - -static void ___lambda12_ (UserInterface* self) { -} - - -static void ____lambda12__pk_progress_callback (PkProgress* progress, PkProgressType type, gpointer self) { -#line 1646 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - ___lambda12_ ((UserInterface*) self); -#line 7098 "ui.c" -} - - -static void ___lambda13_ (Block3Data* _data3_, GObject* object, GAsyncResult* _result_) { - UserInterface* self; - GtkLabel* _tmp0_ = NULL; - GtkSpinner* _tmp1_ = NULL; - GtkLabel* _tmp2_ = NULL; - GtkStack* _tmp3_ = NULL; - GtkLabel* _tmp4_ = NULL; - gchar* result_text = NULL; - const gchar* _tmp5_ = NULL; - gchar* _tmp6_ = NULL; - GtkLabel* _tmp23_ = NULL; - const gchar* _tmp24_ = NULL; - GError * _inner_error_ = NULL; -#line 1646 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - self = _data3_->self; -#line 1646 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - g_return_if_fail (_result_ != NULL); -#line 1648 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp0_ = _data3_->status_label; -#line 1648 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - gtk_widget_set_visible ((GtkWidget*) _tmp0_, TRUE); -#line 1649 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp1_ = _data3_->spinner; -#line 1649 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - g_object_set (_tmp1_, "active", FALSE, NULL); -#line 1650 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp2_ = _data3_->status_label; -#line 1650 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - gtk_label_set_text (_tmp2_, "☒"); -#line 1651 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp3_ = _data3_->stack; -#line 1651 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp4_ = _data3_->status_label; -#line 1651 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - gtk_stack_set_visible_child (_tmp3_, (GtkWidget*) _tmp4_); -#line 1653 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp5_ = _ ("Drivers installed successfully!"); -#line 1653 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp6_ = g_strdup (_tmp5_); -#line 1653 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - result_text = _tmp6_; -#line 7143 "ui.c" - { - PkResults* results = NULL; - GAsyncResult* _tmp7_ = NULL; - PkResults* _tmp8_ = NULL; - PkError* _tmp9_ = NULL; - PkError* _tmp10_ = NULL; - gboolean _tmp11_ = FALSE; -#line 1656 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp7_ = _result_; -#line 1656 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp8_ = user_interface_install_packages_finish (self, _tmp7_, &_inner_error_); -#line 1656 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - results = _tmp8_; -#line 1656 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - if (G_UNLIKELY (_inner_error_ != NULL)) { -#line 7159 "ui.c" - goto __catch22_g_error; - } -#line 1657 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp9_ = pk_results_get_error_code (results); -#line 1657 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp10_ = _tmp9_; -#line 1657 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp11_ = _tmp10_ == NULL; -#line 1657 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _g_object_unref0 (_tmp10_); -#line 1657 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - if (_tmp11_) { -#line 7172 "ui.c" - GtkLabel* _tmp12_ = NULL; -#line 1658 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp12_ = _data3_->status_label; -#line 1658 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - gtk_label_set_text (_tmp12_, "☑"); -#line 7178 "ui.c" - } else { - PkError* e = NULL; - PkError* _tmp13_ = NULL; - const gchar* _tmp14_ = NULL; - PkError* _tmp15_ = NULL; - PkErrorEnum _tmp16_ = 0; - PkErrorEnum _tmp17_ = 0; - gchar* _tmp18_ = NULL; -#line 1661 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp13_ = pk_results_get_error_code (results); -#line 1661 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - e = _tmp13_; -#line 1663 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp14_ = _ ("Failed to install drivers (error code %d)."); -#line 1663 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp15_ = e; -#line 1663 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - g_object_get (_tmp15_, "code", &_tmp16_, NULL); -#line 1663 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp17_ = _tmp16_; -#line 1663 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp18_ = g_strdup_printf (_tmp14_, _tmp17_); -#line 1663 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _g_free0 (result_text); -#line 1663 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - result_text = _tmp18_; -#line 1657 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _g_object_unref0 (e); -#line 7207 "ui.c" - } -#line 1654 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _g_object_unref0 (results); -#line 7211 "ui.c" - } - goto __finally22; - __catch22_g_error: - { - GError* e = NULL; - const gchar* _tmp19_ = NULL; - gchar* _tmp20_ = NULL; - GError* _tmp21_ = NULL; - const gchar* _tmp22_ = NULL; -#line 1654 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - e = _inner_error_; -#line 1654 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _inner_error_ = NULL; -#line 1669 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp19_ = _ ("Failed to install drivers."); -#line 1669 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp20_ = g_strdup (_tmp19_); -#line 1669 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _g_free0 (result_text); -#line 1669 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - result_text = _tmp20_; -#line 1670 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp21_ = e; -#line 1670 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp22_ = _tmp21_->message; -#line 1670 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - g_warning ("ui.vala:1670: Failed to install drivers: %s", _tmp22_); -#line 1654 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _g_error_free0 (e); -#line 7241 "ui.c" - } - __finally22: -#line 1654 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - if (G_UNLIKELY (_inner_error_ != NULL)) { -#line 1654 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _g_free0 (result_text); -#line 1654 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - g_critical ("file %s: line %d: uncaught error: %s (%s, %d)", __FILE__, __LINE__, _inner_error_->message, g_quark_to_string (_inner_error_->domain), _inner_error_->code); -#line 1654 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - g_clear_error (&_inner_error_); -#line 1654 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - return; -#line 7254 "ui.c" - } -#line 1672 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp23_ = _data3_->instructions_label; -#line 1672 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp24_ = result_text; -#line 1672 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - gtk_label_set_text (_tmp23_, _tmp24_); -#line 1646 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _g_free0 (result_text); -#line 7264 "ui.c" -} - - -static void ____lambda13__gasync_ready_callback (GObject* source_object, GAsyncResult* res, gpointer self) { -#line 1646 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - ___lambda13_ (self, source_object, res); -#line 1646 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - block3_data_unref (self); -#line 7273 "ui.c" -} - - -static void user_interface_install_drivers (UserInterface* self) { - Block3Data* _data3_; - gchar* message = NULL; - gchar* _tmp0_ = NULL; - gchar* instructions = NULL; - gchar* _tmp1_ = NULL; - gchar** packages_to_install = NULL; - gchar** _tmp2_ = NULL; - gint packages_to_install_length1 = 0; - gint _packages_to_install_size_ = 0; - const gchar* _tmp3_ = NULL; - const gchar* _tmp4_ = NULL; - GQuark _tmp6_ = 0U; -#line 1572 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - static GQuark _tmp5_label0 = 0; -#line 1572 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - static GQuark _tmp5_label1 = 0; -#line 1572 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - static GQuark _tmp5_label2 = 0; -#line 1572 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - static GQuark _tmp5_label3 = 0; -#line 1572 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - static GQuark _tmp5_label4 = 0; -#line 1572 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - static GQuark _tmp5_label5 = 0; -#line 1572 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - static GQuark _tmp5_label6 = 0; -#line 7304 "ui.c" - GtkDialog* dialog = NULL; - const gchar* _tmp23_ = NULL; - const gchar* _tmp24_ = NULL; - GtkDialog* _tmp25_ = NULL; - GtkDialog* _tmp26_ = NULL; - GtkBox* _tmp27_ = NULL; - GtkDialog* _tmp28_ = NULL; - GtkBox* _tmp29_ = NULL; - GtkLabel* label = NULL; - const gchar* _tmp30_ = NULL; - GtkLabel* _tmp31_ = NULL; - GtkLabel* _tmp32_ = NULL; - GtkLabel* _tmp33_ = NULL; - GtkDialog* _tmp34_ = NULL; - GtkBox* _tmp35_ = NULL; - GtkLabel* _tmp36_ = NULL; - GtkBox* instructions_box = NULL; - GtkBox* _tmp37_ = NULL; - GtkBox* _tmp38_ = NULL; - GtkDialog* _tmp39_ = NULL; - GtkBox* _tmp40_ = NULL; - GtkBox* _tmp41_ = NULL; - GtkStack* _tmp42_ = NULL; - GtkBox* _tmp43_ = NULL; - GtkStack* _tmp44_ = NULL; - GtkSpinner* _tmp45_ = NULL; - GtkSpinner* _tmp46_ = NULL; - GtkStack* _tmp47_ = NULL; - GtkSpinner* _tmp48_ = NULL; - GtkLabel* _tmp49_ = NULL; - GtkLabel* _tmp50_ = NULL; - GtkStack* _tmp51_ = NULL; - GtkLabel* _tmp52_ = NULL; - const gchar* _tmp53_ = NULL; - GtkLabel* _tmp54_ = NULL; - GtkLabel* _tmp55_ = NULL; - GtkLabel* _tmp56_ = NULL; - GtkLabel* _tmp57_ = NULL; - GtkBox* _tmp58_ = NULL; - GtkLabel* _tmp59_ = NULL; - const gchar* _tmp60_ = NULL; - GtkLabel* _tmp61_ = NULL; - GtkLabel* _tmp62_ = NULL; - GtkLabel* _tmp63_ = NULL; - GtkDialog* _tmp64_ = NULL; - GtkBox* _tmp65_ = NULL; - GtkDialog* _tmp66_ = NULL; - GtkBox* _tmp67_ = NULL; - GtkLabel* _tmp68_ = NULL; - gchar** _tmp69_ = NULL; - gint _tmp69__length1 = 0; - GtkDialog* _tmp75_ = NULL; - GtkDialog* _tmp76_ = NULL; -#line 1568 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - g_return_if_fail (self != NULL); -#line 1568 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _data3_ = g_slice_new0 (Block3Data); -#line 1568 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _data3_->_ref_count_ = 1; -#line 1568 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _data3_->self = g_object_ref (self); -#line 1570 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp0_ = g_strdup (""); -#line 1570 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - message = _tmp0_; -#line 1570 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp1_ = g_strdup (""); -#line 1570 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - instructions = _tmp1_; -#line 1571 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp2_ = g_new0 (gchar*, 0 + 1); -#line 1571 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - packages_to_install = _tmp2_; -#line 1571 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - packages_to_install_length1 = 0; -#line 1571 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _packages_to_install_size_ = packages_to_install_length1; -#line 1572 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp3_ = self->priv->missing_driver; -#line 1572 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp4_ = _tmp3_; -#line 1572 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp6_ = (NULL == _tmp4_) ? 0 : g_quark_from_string (_tmp4_); -#line 1572 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - if ((((_tmp6_ == ((0 != _tmp5_label0) ? _tmp5_label0 : (_tmp5_label0 = g_quark_from_static_string ("brscan")))) || (_tmp6_ == ((0 != _tmp5_label1) ? _tmp5_label1 : (_tmp5_label1 = g_quark_from_static_string ("brscan2"))))) || (_tmp6_ == ((0 != _tmp5_label2) ? _tmp5_label2 : (_tmp5_label2 = g_quark_from_static_string ("brscan3"))))) || (_tmp6_ == ((0 != _tmp5_label3) ? _tmp5_label3 : (_tmp5_label3 = g_quark_from_static_string ("brscan4"))))) { -#line 1572 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - switch (0) { -#line 7392 "ui.c" - default: - { - const gchar* _tmp7_ = NULL; - gchar* _tmp8_ = NULL; - const gchar* _tmp9_ = NULL; - gchar* _tmp10_ = NULL; -#line 1579 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp7_ = _ ("You appear to have a Brother scanner."); -#line 1579 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp8_ = g_strdup (_tmp7_); -#line 1579 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _g_free0 (message); -#line 1579 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - message = _tmp8_; -#line 1581 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp9_ = _ ("Drivers for this are available on the Brother website."); -#line 1581 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp10_ = g_strdup (_tmp9_); -#line 1581 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _g_free0 (instructions); -#line 1581 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - instructions = _tmp10_; -#line 1582 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - break; -#line 7417 "ui.c" - } - } - } else if (_tmp6_ == ((0 != _tmp5_label4) ? _tmp5_label4 : (_tmp5_label4 = g_quark_from_static_string ("samsung")))) { -#line 1572 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - switch (0) { -#line 7423 "ui.c" - default: - { - const gchar* _tmp11_ = NULL; - gchar* _tmp12_ = NULL; - const gchar* _tmp13_ = NULL; - gchar* _tmp14_ = NULL; -#line 1585 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp11_ = _ ("You appear to have a Samsung scanner."); -#line 1585 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp12_ = g_strdup (_tmp11_); -#line 1585 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _g_free0 (message); -#line 1585 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - message = _tmp12_; -#line 1587 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp13_ = _ ("Drivers for this are available on the Samsung website."); -#line 1587 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp14_ = g_strdup (_tmp13_); -#line 1587 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _g_free0 (instructions); -#line 1587 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - instructions = _tmp14_; -#line 1588 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - break; -#line 7448 "ui.c" - } - } - } else if (_tmp6_ == ((0 != _tmp5_label5) ? _tmp5_label5 : (_tmp5_label5 = g_quark_from_static_string ("hpaio")))) { -#line 1572 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - switch (0) { -#line 7454 "ui.c" - default: - { - const gchar* _tmp15_ = NULL; - gchar* _tmp16_ = NULL; - gchar* _tmp17_ = NULL; - gchar** _tmp18_ = NULL; -#line 1591 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp15_ = _ ("You appear to have an HP scanner."); -#line 1591 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp16_ = g_strdup (_tmp15_); -#line 1591 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _g_free0 (message); -#line 1591 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - message = _tmp16_; -#line 1592 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp17_ = g_strdup ("libsane-hpaio"); -#line 1592 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp18_ = g_new0 (gchar*, 1 + 1); -#line 1592 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp18_[0] = _tmp17_; -#line 1592 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - packages_to_install = (_vala_array_free (packages_to_install, packages_to_install_length1, (GDestroyNotify) g_free), NULL); -#line 1592 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - packages_to_install = _tmp18_; -#line 1592 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - packages_to_install_length1 = 1; -#line 1592 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _packages_to_install_size_ = packages_to_install_length1; -#line 1593 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - break; -#line 7485 "ui.c" - } - } - } else if (_tmp6_ == ((0 != _tmp5_label6) ? _tmp5_label6 : (_tmp5_label6 = g_quark_from_static_string ("epkowa")))) { -#line 1572 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - switch (0) { -#line 7491 "ui.c" - default: - { - const gchar* _tmp19_ = NULL; - gchar* _tmp20_ = NULL; - const gchar* _tmp21_ = NULL; - gchar* _tmp22_ = NULL; -#line 1596 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp19_ = _ ("You appear to have an Epson scanner."); -#line 1596 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp20_ = g_strdup (_tmp19_); -#line 1596 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _g_free0 (message); -#line 1596 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - message = _tmp20_; -#line 1598 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp21_ = _ ("Drivers for this are available on the Epson website."); -#line 1598 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp22_ = g_strdup (_tmp21_); -#line 1598 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _g_free0 (instructions); -#line 1598 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - instructions = _tmp22_; -#line 1599 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - break; -#line 7516 "ui.c" - } - } - } -#line 1601 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp23_ = _ ("Install drivers"); -#line 1601 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp24_ = _ ("_Close"); -#line 1601 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp25_ = (GtkDialog*) gtk_dialog_new_with_buttons (_tmp23_, (GtkWindow*) self, GTK_DIALOG_MODAL, _tmp24_, GTK_RESPONSE_CLOSE, NULL); -#line 1601 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - g_object_ref_sink (_tmp25_); -#line 1601 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - dialog = _tmp25_; -#line 1603 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp26_ = dialog; -#line 1603 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp27_ = (GtkBox*) gtk_dialog_get_content_area (_tmp26_); -#line 1603 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - gtk_container_set_border_width ((GtkContainer*) _tmp27_, (guint) 12); -#line 1604 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp28_ = dialog; -#line 1604 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp29_ = (GtkBox*) gtk_dialog_get_content_area (_tmp28_); -#line 1604 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - gtk_box_set_spacing (_tmp29_, 6); -#line 1606 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp30_ = message; -#line 1606 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp31_ = (GtkLabel*) gtk_label_new (_tmp30_); -#line 1606 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - g_object_ref_sink (_tmp31_); -#line 1606 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - label = _tmp31_; -#line 1607 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp32_ = label; -#line 1607 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - gtk_widget_set_visible ((GtkWidget*) _tmp32_, TRUE); -#line 1608 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp33_ = label; -#line 1608 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - gtk_label_set_xalign (_tmp33_, 0.f); -#line 1609 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp34_ = dialog; -#line 1609 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp35_ = (GtkBox*) gtk_dialog_get_content_area (_tmp34_); -#line 1609 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp36_ = label; -#line 1609 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - gtk_box_pack_start (_tmp35_, (GtkWidget*) _tmp36_, TRUE, TRUE, (guint) 0); -#line 1611 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp37_ = (GtkBox*) gtk_box_new (GTK_ORIENTATION_HORIZONTAL, 6); -#line 1611 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - g_object_ref_sink (_tmp37_); -#line 1611 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - instructions_box = _tmp37_; -#line 1612 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp38_ = instructions_box; -#line 1612 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - gtk_widget_set_visible ((GtkWidget*) _tmp38_, TRUE); -#line 1613 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp39_ = dialog; -#line 1613 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp40_ = (GtkBox*) gtk_dialog_get_content_area (_tmp39_); -#line 1613 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp41_ = instructions_box; -#line 1613 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - gtk_box_pack_start (_tmp40_, (GtkWidget*) _tmp41_, TRUE, TRUE, (guint) 0); -#line 1615 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp42_ = (GtkStack*) gtk_stack_new (); -#line 1615 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - g_object_ref_sink (_tmp42_); -#line 1615 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _data3_->stack = _tmp42_; -#line 1616 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp43_ = instructions_box; -#line 1616 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp44_ = _data3_->stack; -#line 1616 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - gtk_box_pack_start (_tmp43_, (GtkWidget*) _tmp44_, FALSE, FALSE, (guint) 0); -#line 1618 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp45_ = (GtkSpinner*) gtk_spinner_new (); -#line 1618 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - g_object_ref_sink (_tmp45_); -#line 1618 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _data3_->spinner = _tmp45_; -#line 1619 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp46_ = _data3_->spinner; -#line 1619 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - gtk_widget_set_visible ((GtkWidget*) _tmp46_, TRUE); -#line 1620 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp47_ = _data3_->stack; -#line 1620 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp48_ = _data3_->spinner; -#line 1620 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - gtk_container_add ((GtkContainer*) _tmp47_, (GtkWidget*) _tmp48_); -#line 1622 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp49_ = (GtkLabel*) gtk_label_new (""); -#line 1622 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - g_object_ref_sink (_tmp49_); -#line 1622 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _data3_->status_label = _tmp49_; -#line 1623 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp50_ = _data3_->status_label; -#line 1623 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - gtk_widget_set_visible ((GtkWidget*) _tmp50_, TRUE); -#line 1624 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp51_ = _data3_->stack; -#line 1624 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp52_ = _data3_->status_label; -#line 1624 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - gtk_container_add ((GtkContainer*) _tmp51_, (GtkWidget*) _tmp52_); -#line 1626 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp53_ = instructions; -#line 1626 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp54_ = (GtkLabel*) gtk_label_new (_tmp53_); -#line 1626 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - g_object_ref_sink (_tmp54_); -#line 1626 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _data3_->instructions_label = _tmp54_; -#line 1627 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp55_ = _data3_->instructions_label; -#line 1627 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - gtk_widget_set_visible ((GtkWidget*) _tmp55_, TRUE); -#line 1628 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp56_ = _data3_->instructions_label; -#line 1628 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - gtk_label_set_xalign (_tmp56_, 0.f); -#line 1629 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp57_ = _data3_->instructions_label; -#line 1629 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - gtk_label_set_use_markup (_tmp57_, TRUE); -#line 1630 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp58_ = instructions_box; -#line 1630 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp59_ = _data3_->instructions_label; -#line 1630 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - gtk_box_pack_start (_tmp58_, (GtkWidget*) _tmp59_, FALSE, FALSE, (guint) 0); -#line 1632 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp60_ = _ ("Once installed you will need to restart Simple Scan."); -#line 1632 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp61_ = (GtkLabel*) gtk_label_new (_tmp60_); -#line 1632 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - g_object_ref_sink (_tmp61_); -#line 1632 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _g_object_unref0 (label); -#line 1632 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - label = _tmp61_; -#line 1634 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp62_ = label; -#line 1634 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - gtk_widget_set_visible ((GtkWidget*) _tmp62_, TRUE); -#line 1635 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp63_ = label; -#line 1635 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - gtk_label_set_xalign (_tmp63_, 0.f); -#line 1636 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp64_ = dialog; -#line 1636 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp65_ = (GtkBox*) gtk_dialog_get_content_area (_tmp64_); -#line 1636 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - gtk_container_set_border_width ((GtkContainer*) _tmp65_, (guint) 12); -#line 1637 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp66_ = dialog; -#line 1637 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp67_ = (GtkBox*) gtk_dialog_get_content_area (_tmp66_); -#line 1637 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp68_ = label; -#line 1637 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - gtk_box_pack_start (_tmp67_, (GtkWidget*) _tmp68_, TRUE, TRUE, (guint) 0); -#line 1639 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp69_ = packages_to_install; -#line 1639 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp69__length1 = packages_to_install_length1; -#line 1639 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - if (_tmp69__length1 > 0) { -#line 7692 "ui.c" - GtkStack* _tmp70_ = NULL; - GtkSpinner* _tmp71_ = NULL; - GtkLabel* _tmp72_ = NULL; - const gchar* _tmp73_ = NULL; - gchar** _tmp74_ = NULL; - gint _tmp74__length1 = 0; -#line 1642 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp70_ = _data3_->stack; -#line 1642 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - gtk_widget_set_visible ((GtkWidget*) _tmp70_, TRUE); -#line 1643 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp71_ = _data3_->spinner; -#line 1643 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - g_object_set (_tmp71_, "active", TRUE, NULL); -#line 1644 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp72_ = _data3_->instructions_label; -#line 1644 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp73_ = _ ("Installing drivers..."); -#line 1644 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - gtk_label_set_text (_tmp72_, _tmp73_); -#line 1646 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp74_ = packages_to_install; -#line 1646 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp74__length1 = packages_to_install_length1; -#line 1646 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - user_interface_install_packages (self, _tmp74_, _tmp74__length1, ____lambda12__pk_progress_callback, self, ____lambda13__gasync_ready_callback, block3_data_ref (_data3_)); -#line 7719 "ui.c" - } -#line 1680 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp75_ = dialog; -#line 1680 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - gtk_dialog_run (_tmp75_); -#line 1681 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp76_ = dialog; -#line 1681 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - gtk_widget_destroy ((GtkWidget*) _tmp76_); -#line 1568 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _g_object_unref0 (instructions_box); -#line 1568 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _g_object_unref0 (label); -#line 1568 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _g_object_unref0 (dialog); -#line 1568 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - packages_to_install = (_vala_array_free (packages_to_install, packages_to_install_length1, (GDestroyNotify) g_free), NULL); -#line 1568 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _g_free0 (instructions); -#line 1568 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _g_free0 (message); -#line 1568 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - block3_data_unref (_data3_); -#line 1568 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _data3_ = NULL; -#line 7745 "ui.c" -} - - -static void user_interface_install_packages_data_free (gpointer _data) { - UserInterfaceInstallPackagesData* _data_; - _data_ = _data; -#line 14 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _g_object_unref0 (_data_->result); -#line 14 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _g_object_unref0 (_data_->self); -#line 14 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - g_slice_free (UserInterfaceInstallPackagesData, _data_); -#line 7758 "ui.c" -} - - -static void user_interface_install_packages (UserInterface* self, gchar** packages, int packages_length1, PkProgressCallback progress_callback, void* progress_callback_target, GAsyncReadyCallback _callback_, gpointer _user_data_) { - UserInterfaceInstallPackagesData* _data_; - UserInterface* _tmp0_ = NULL; - gchar** _tmp1_ = NULL; - gint _tmp1__length1 = 0; - PkProgressCallback _tmp2_ = NULL; - void* _tmp2__target = NULL; -#line 14 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _data_ = g_slice_new0 (UserInterfaceInstallPackagesData); -#line 14 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _data_->_async_result = g_simple_async_result_new (G_OBJECT (self), _callback_, _user_data_, user_interface_install_packages); -#line 14 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - g_simple_async_result_set_op_res_gpointer (_data_->_async_result, _data_, user_interface_install_packages_data_free); -#line 14 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp0_ = _g_object_ref0 (self); -#line 14 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _data_->self = _tmp0_; -#line 14 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp1_ = packages; -#line 14 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp1__length1 = packages_length1; -#line 14 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _data_->packages = _tmp1_; -#line 14 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _data_->packages_length1 = _tmp1__length1; -#line 14 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp2_ = progress_callback; -#line 14 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp2__target = progress_callback_target; -#line 14 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _data_->progress_callback = _tmp2_; -#line 14 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _data_->progress_callback_target = _tmp2__target; -#line 14 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - user_interface_install_packages_co (_data_); -#line 7797 "ui.c" -} - - -static PkResults* user_interface_install_packages_finish (UserInterface* self, GAsyncResult* _res_, GError** error) { - PkResults* result; - UserInterfaceInstallPackagesData* _data_; -#line 14 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - if (g_simple_async_result_propagate_error (G_SIMPLE_ASYNC_RESULT (_res_), error)) { -#line 14 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - return NULL; -#line 7808 "ui.c" - } -#line 14 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _data_ = g_simple_async_result_get_op_res_gpointer (G_SIMPLE_ASYNC_RESULT (_res_)); -#line 14 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - result = _data_->result; -#line 14 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _data_->result = NULL; -#line 14 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - return result; -#line 7818 "ui.c" -} - - -static void user_interface_install_packages_ready (GObject* source_object, GAsyncResult* _res_, gpointer _user_data_) { - UserInterfaceInstallPackagesData* _data_; -#line 1689 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _data_ = _user_data_; -#line 1689 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _data_->_source_object_ = source_object; -#line 1689 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _data_->_res_ = _res_; -#line 1689 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - user_interface_install_packages_co (_data_); -#line 7832 "ui.c" -} - - -static gint g_ptr_array_get_length (GPtrArray* self) { - gint result; - guint _tmp0_ = 0U; -#line 4858 "/usr/share/vala-0.34/vapi/glib-2.0.vapi" - g_return_val_if_fail (self != NULL, 0); -#line 4858 "/usr/share/vala-0.34/vapi/glib-2.0.vapi" - _tmp0_ = self->len; -#line 4858 "/usr/share/vala-0.34/vapi/glib-2.0.vapi" - result = (gint) _tmp0_; -#line 4858 "/usr/share/vala-0.34/vapi/glib-2.0.vapi" - return result; -#line 7847 "ui.c" -} - - -static void g_ptr_array_set_length (GPtrArray* self, gint value) { - gint _tmp0_ = 0; -#line 4859 "/usr/share/vala-0.34/vapi/glib-2.0.vapi" - g_return_if_fail (self != NULL); -#line 4859 "/usr/share/vala-0.34/vapi/glib-2.0.vapi" - _tmp0_ = value; -#line 4859 "/usr/share/vala-0.34/vapi/glib-2.0.vapi" - g_ptr_array_set_size (self, _tmp0_); -#line 7859 "ui.c" -} - - -static gboolean user_interface_install_packages_co (UserInterfaceInstallPackagesData* _data_) { -#line 1685 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - switch (_data_->_state_) { -#line 1685 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - case 0: -#line 7868 "ui.c" - goto _state_0; -#line 1685 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - case 1: -#line 7872 "ui.c" - goto _state_1; -#line 1685 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - case 2: -#line 7876 "ui.c" - goto _state_2; - default: -#line 1685 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - g_assert_not_reached (); -#line 7881 "ui.c" - } - _state_0: -#line 1687 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _data_->_tmp0_ = NULL; -#line 1687 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _data_->_tmp0_ = pk_task_new (); -#line 1687 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _data_->task = _data_->_tmp0_; -#line 1689 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _data_->_tmp2_ = NULL; -#line 1689 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _data_->_tmp2_ = _data_->task; -#line 1689 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _data_->_tmp3_ = NULL; -#line 1689 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _data_->_tmp3__length1 = 0; -#line 1689 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _data_->_tmp3_ = _data_->packages; -#line 1689 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _data_->_tmp3__length1 = _data_->packages_length1; -#line 1689 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _data_->_tmp4_ = NULL; -#line 1689 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _data_->_tmp4__target = NULL; -#line 1689 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _data_->_tmp4_ = _data_->progress_callback; -#line 1689 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _data_->_tmp4__target = _data_->progress_callback_target; -#line 1689 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _data_->_state_ = 1; -#line 1689 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - pk_task_resolve_async (_data_->_tmp2_, (PkBitfield) PK_FILTER_ENUM_NOT_INSTALLED, _data_->_tmp3_, NULL, _data_->_tmp4_, _data_->_tmp4__target, user_interface_install_packages_ready, _data_); -#line 1689 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - return FALSE; -#line 7916 "ui.c" - _state_1: -#line 1689 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _data_->_tmp5_ = NULL; -#line 1689 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _data_->_tmp5_ = pk_task_generic_finish (_data_->_tmp2_, _data_->_res_, &_data_->_inner_error_); -#line 1689 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _data_->_tmp1_ = _data_->_tmp5_; -#line 1689 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - if (G_UNLIKELY (_data_->_inner_error_ != NULL)) { -#line 1689 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - g_simple_async_result_set_from_error (_data_->_async_result, _data_->_inner_error_); -#line 1689 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - g_error_free (_data_->_inner_error_); -#line 1689 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _g_object_unref0 (_data_->results); -#line 1689 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _g_object_unref0 (_data_->task); -#line 1689 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - if (_data_->_state_ == 0) { -#line 1689 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - g_simple_async_result_complete_in_idle (_data_->_async_result); -#line 7938 "ui.c" - } else { -#line 1689 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - g_simple_async_result_complete (_data_->_async_result); -#line 7942 "ui.c" - } -#line 1689 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - g_object_unref (_data_->_async_result); -#line 1689 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - return FALSE; -#line 7948 "ui.c" - } -#line 1689 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _data_->_tmp6_ = NULL; -#line 1689 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _data_->_tmp6_ = _data_->_tmp1_; -#line 1689 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _data_->_tmp1_ = NULL; -#line 1689 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _g_object_unref0 (_data_->results); -#line 1689 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _data_->results = _data_->_tmp6_; -#line 1690 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _data_->_tmp8_ = NULL; -#line 1690 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _data_->_tmp8_ = _data_->results; -#line 1690 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - if (_data_->_tmp8_ == NULL) { -#line 1690 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _data_->_tmp7_ = TRUE; -#line 7968 "ui.c" - } else { -#line 1690 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _data_->_tmp9_ = NULL; -#line 1690 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _data_->_tmp9_ = _data_->results; -#line 1690 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _data_->_tmp10_ = NULL; -#line 1690 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _data_->_tmp10_ = pk_results_get_error_code (_data_->_tmp9_); -#line 1690 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _data_->_tmp11_ = NULL; -#line 1690 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _data_->_tmp11_ = _data_->_tmp10_; -#line 1690 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _data_->_tmp7_ = _data_->_tmp11_ != NULL; -#line 1690 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _g_object_unref0 (_data_->_tmp11_); -#line 7986 "ui.c" - } -#line 1690 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - if (_data_->_tmp7_) { -#line 1691 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _data_->result = _data_->results; -#line 1691 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _g_object_unref0 (_data_->_tmp1_); -#line 1691 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _g_object_unref0 (_data_->task); -#line 1691 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - if (_data_->_state_ == 0) { -#line 1691 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - g_simple_async_result_complete_in_idle (_data_->_async_result); -#line 8000 "ui.c" - } else { -#line 1691 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - g_simple_async_result_complete (_data_->_async_result); -#line 8004 "ui.c" - } -#line 1691 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - g_object_unref (_data_->_async_result); -#line 1691 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - return FALSE; -#line 8010 "ui.c" - } -#line 1693 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _data_->_tmp12_ = NULL; -#line 1693 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _data_->_tmp12_ = _data_->results; -#line 1693 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _data_->_tmp13_ = NULL; -#line 1693 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _data_->_tmp13_ = pk_results_get_package_array (_data_->_tmp12_); -#line 1693 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _data_->package_array = _data_->_tmp13_; -#line 1694 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _data_->_tmp14_ = NULL; -#line 1694 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _data_->_tmp14_ = _data_->package_array; -#line 1694 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _data_->_tmp15_ = 0; -#line 1694 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _data_->_tmp15_ = g_ptr_array_get_length (_data_->_tmp14_); -#line 1694 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _data_->_tmp16_ = 0; -#line 1694 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _data_->_tmp16_ = _data_->_tmp15_; -#line 1694 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _data_->_tmp17_ = NULL; -#line 1694 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _data_->_tmp17_ = g_new0 (gchar*, (_data_->_tmp16_ + 1) + 1); -#line 1694 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _data_->package_ids_length1 = 0; -#line 1694 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _data_->_package_ids_size_ = 0; -#line 1694 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _data_->package_ids = _data_->_tmp17_; -#line 1694 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _data_->package_ids_length1 = _data_->_tmp16_ + 1; -#line 1694 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _data_->_package_ids_size_ = _data_->package_ids_length1; -#line 1695 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _data_->_tmp18_ = NULL; -#line 1695 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _data_->_tmp18__length1 = 0; -#line 1695 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _data_->_tmp18_ = _data_->package_ids; -#line 1695 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _data_->_tmp18__length1 = _data_->package_ids_length1; -#line 1695 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _data_->_tmp19_ = NULL; -#line 1695 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _data_->_tmp19_ = _data_->package_array; -#line 1695 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _data_->_tmp20_ = 0; -#line 1695 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _data_->_tmp20_ = g_ptr_array_get_length (_data_->_tmp19_); -#line 1695 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _data_->_tmp21_ = 0; -#line 1695 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _data_->_tmp21_ = _data_->_tmp20_; -#line 1695 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _g_free0 (_data_->_tmp18_[_data_->_tmp21_]); -#line 1695 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _data_->_tmp18_[_data_->_tmp21_] = NULL; -#line 1695 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _data_->_tmp22_ = NULL; -#line 1695 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _data_->_tmp22_ = _data_->_tmp18_[_data_->_tmp21_]; -#line 8076 "ui.c" - { -#line 1696 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _data_->i = 0; -#line 8080 "ui.c" - { -#line 1696 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _data_->_tmp23_ = TRUE; -#line 1696 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - while (TRUE) { -#line 1696 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - if (!_data_->_tmp23_) { -#line 1696 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _data_->_tmp24_ = 0; -#line 1696 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _data_->_tmp24_ = _data_->i; -#line 1696 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _data_->i = _data_->_tmp24_ + 1; -#line 8094 "ui.c" - } -#line 1696 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _data_->_tmp23_ = FALSE; -#line 1696 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _data_->_tmp25_ = 0; -#line 1696 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _data_->_tmp25_ = _data_->i; -#line 1696 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _data_->_tmp26_ = NULL; -#line 1696 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _data_->_tmp26_ = _data_->package_array; -#line 1696 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _data_->_tmp27_ = 0; -#line 1696 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _data_->_tmp27_ = g_ptr_array_get_length (_data_->_tmp26_); -#line 1696 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _data_->_tmp28_ = 0; -#line 1696 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _data_->_tmp28_ = _data_->_tmp27_; -#line 1696 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - if (!(_data_->_tmp25_ < _data_->_tmp28_)) { -#line 1696 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - break; -#line 8118 "ui.c" - } -#line 1697 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _data_->_tmp29_ = NULL; -#line 1697 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _data_->_tmp29__length1 = 0; -#line 1697 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _data_->_tmp29_ = _data_->package_ids; -#line 1697 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _data_->_tmp29__length1 = _data_->package_ids_length1; -#line 1697 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _data_->_tmp30_ = 0; -#line 1697 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _data_->_tmp30_ = _data_->i; -#line 1697 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _data_->_tmp31_ = NULL; -#line 1697 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _data_->_tmp31_ = _data_->package_array; -#line 1697 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _data_->_tmp32_ = NULL; -#line 1697 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _data_->_tmp32__length1 = 0; -#line 1697 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _data_->_tmp32_ = _data_->_tmp31_->pdata; -#line 1697 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _data_->_tmp32__length1 = (gint) _data_->_tmp31_->len; -#line 1697 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _data_->_tmp33_ = 0; -#line 1697 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _data_->_tmp33_ = _data_->i; -#line 1697 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _data_->_tmp34_ = NULL; -#line 1697 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _data_->_tmp34_ = _data_->_tmp32_[_data_->_tmp33_]; -#line 1697 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _data_->_tmp35_ = NULL; -#line 1697 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _data_->_tmp35_ = pk_package_get_id (_data_->_tmp34_); -#line 1697 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _data_->_tmp36_ = NULL; -#line 1697 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _data_->_tmp36_ = g_strdup (_data_->_tmp35_); -#line 1697 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _g_free0 (_data_->_tmp29_[_data_->_tmp30_]); -#line 1697 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _data_->_tmp29_[_data_->_tmp30_] = _data_->_tmp36_; -#line 1697 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _data_->_tmp37_ = NULL; -#line 1697 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _data_->_tmp37_ = _data_->_tmp29_[_data_->_tmp30_]; -#line 8168 "ui.c" - } - } - } -#line 1699 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _data_->_tmp39_ = NULL; -#line 1699 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _data_->_tmp39_ = _data_->task; -#line 1699 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _data_->_tmp40_ = NULL; -#line 1699 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _data_->_tmp40__length1 = 0; -#line 1699 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _data_->_tmp40_ = _data_->package_ids; -#line 1699 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _data_->_tmp40__length1 = _data_->package_ids_length1; -#line 1699 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _data_->_tmp41_ = NULL; -#line 1699 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _data_->_tmp41__target = NULL; -#line 1699 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _data_->_tmp41_ = _data_->progress_callback; -#line 1699 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _data_->_tmp41__target = _data_->progress_callback_target; -#line 1699 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _data_->_state_ = 2; -#line 1699 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - pk_task_install_packages_async (_data_->_tmp39_, _data_->_tmp40_, NULL, _data_->_tmp41_, _data_->_tmp41__target, user_interface_install_packages_ready, _data_); -#line 1699 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - return FALSE; -#line 8198 "ui.c" - _state_2: -#line 1699 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _data_->_tmp42_ = NULL; -#line 1699 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _data_->_tmp42_ = pk_task_generic_finish (_data_->_tmp39_, _data_->_res_, &_data_->_inner_error_); -#line 1699 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _data_->_tmp38_ = _data_->_tmp42_; -#line 1699 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - if (G_UNLIKELY (_data_->_inner_error_ != NULL)) { -#line 1699 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - g_simple_async_result_set_from_error (_data_->_async_result, _data_->_inner_error_); -#line 1699 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - g_error_free (_data_->_inner_error_); -#line 1699 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _data_->package_ids = (_vala_array_free (_data_->package_ids, _data_->package_ids_length1, (GDestroyNotify) g_free), NULL); -#line 1699 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _g_ptr_array_unref0 (_data_->package_array); -#line 1699 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _g_object_unref0 (_data_->_tmp1_); -#line 1699 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _g_object_unref0 (_data_->results); -#line 1699 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _g_object_unref0 (_data_->task); -#line 1699 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - if (_data_->_state_ == 0) { -#line 1699 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - g_simple_async_result_complete_in_idle (_data_->_async_result); -#line 8226 "ui.c" - } else { -#line 1699 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - g_simple_async_result_complete (_data_->_async_result); -#line 8230 "ui.c" - } -#line 1699 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - g_object_unref (_data_->_async_result); -#line 1699 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - return FALSE; -#line 8236 "ui.c" - } -#line 1699 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _data_->_tmp43_ = NULL; -#line 1699 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _data_->_tmp43_ = _data_->_tmp38_; -#line 1699 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _data_->_tmp38_ = NULL; -#line 1699 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _data_->result = _data_->_tmp43_; -#line 1699 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _g_object_unref0 (_data_->_tmp38_); -#line 1699 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _data_->package_ids = (_vala_array_free (_data_->package_ids, _data_->package_ids_length1, (GDestroyNotify) g_free), NULL); -#line 1699 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _g_ptr_array_unref0 (_data_->package_array); -#line 1699 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _g_object_unref0 (_data_->_tmp1_); -#line 1699 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _g_object_unref0 (_data_->results); -#line 1699 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _g_object_unref0 (_data_->task); -#line 1699 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - if (_data_->_state_ == 0) { -#line 1699 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - g_simple_async_result_complete_in_idle (_data_->_async_result); -#line 8262 "ui.c" - } else { -#line 1699 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - g_simple_async_result_complete (_data_->_async_result); -#line 8266 "ui.c" - } -#line 1699 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - g_object_unref (_data_->_async_result); -#line 1699 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - return FALSE; -#line 1685 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _g_object_unref0 (_data_->_tmp38_); -#line 1685 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _data_->package_ids = (_vala_array_free (_data_->package_ids, _data_->package_ids_length1, (GDestroyNotify) g_free), NULL); -#line 1685 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _g_ptr_array_unref0 (_data_->package_array); -#line 1685 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _g_object_unref0 (_data_->_tmp1_); -#line 1685 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _g_object_unref0 (_data_->results); -#line 1685 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _g_object_unref0 (_data_->task); -#line 1685 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - if (_data_->_state_ == 0) { -#line 1685 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - g_simple_async_result_complete_in_idle (_data_->_async_result); -#line 8288 "ui.c" - } else { -#line 1685 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - g_simple_async_result_complete (_data_->_async_result); -#line 8292 "ui.c" - } -#line 1685 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - g_object_unref (_data_->_async_result); -#line 1685 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - return FALSE; -#line 8298 "ui.c" -} - - -static gboolean user_interface_real_window_state_event (GtkWidget* base, GdkEventWindowState* event) { - UserInterface * self; - gboolean result = FALSE; - gboolean _result_ = FALSE; - GdkEventWindowState* _tmp2_ = NULL; - GdkWindowState _tmp3_ = 0; - GdkEventWindowState* _tmp6_ = NULL; - GdkWindowState _tmp7_ = 0; -#line 1703 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - self = (UserInterface*) base; -#line 1703 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - g_return_val_if_fail (event != NULL, FALSE); -#line 1705 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _result_ = GDK_EVENT_PROPAGATE; -#line 1707 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - if (GTK_WIDGET_CLASS (user_interface_parent_class)->window_state_event != NULL) { -#line 8318 "ui.c" - GdkEventWindowState* _tmp0_ = NULL; - gboolean _tmp1_ = FALSE; -#line 1708 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp0_ = event; -#line 1708 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp1_ = GTK_WIDGET_CLASS (user_interface_parent_class)->window_state_event ((GtkWidget*) G_TYPE_CHECK_INSTANCE_CAST (self, gtk_application_window_get_type (), GtkApplicationWindow), _tmp0_); -#line 1708 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _result_ = _tmp1_; -#line 8327 "ui.c" - } -#line 1710 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp2_ = event; -#line 1710 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp3_ = _tmp2_->changed_mask; -#line 1710 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - if ((_tmp3_ & GDK_WINDOW_STATE_MAXIMIZED) != 0) { -#line 8335 "ui.c" - GdkEventWindowState* _tmp4_ = NULL; - GdkWindowState _tmp5_ = 0; -#line 1712 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp4_ = event; -#line 1712 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp5_ = _tmp4_->new_window_state; -#line 1712 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - self->priv->window_is_maximized = (_tmp5_ & GDK_WINDOW_STATE_MAXIMIZED) != 0; -#line 1713 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - user_interface_save_state (self, FALSE); -#line 8346 "ui.c" - } -#line 1715 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp6_ = event; -#line 1715 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp7_ = _tmp6_->changed_mask; -#line 1715 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - if ((_tmp7_ & GDK_WINDOW_STATE_FULLSCREEN) != 0) { -#line 8354 "ui.c" - GdkEventWindowState* _tmp8_ = NULL; - GdkWindowState _tmp9_ = 0; -#line 1717 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp8_ = event; -#line 1717 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp9_ = _tmp8_->new_window_state; -#line 1717 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - self->priv->window_is_fullscreen = (_tmp9_ & GDK_WINDOW_STATE_FULLSCREEN) != 0; -#line 1718 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - user_interface_save_state (self, FALSE); -#line 8365 "ui.c" - } -#line 1721 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - result = _result_; -#line 1721 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - return result; -#line 8371 "ui.c" -} - - -static gboolean user_interface_window_delete_event_cb (UserInterface* self, GtkWidget* widget, GdkEventAny* event) { - gboolean result = FALSE; - gboolean _tmp0_ = FALSE; -#line 1725 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - g_return_val_if_fail (self != NULL, FALSE); -#line 1725 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - g_return_val_if_fail (widget != NULL, FALSE); -#line 1725 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - g_return_val_if_fail (event != NULL, FALSE); -#line 1727 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp0_ = user_interface_on_quit (self); -#line 1727 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - result = !_tmp0_; -#line 1727 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - return result; -#line 8390 "ui.c" -} - - -static gboolean _user_interface_window_delete_event_cb_gtk_widget_delete_event (GtkWidget* _sender, GdkEventAny* event, gpointer self) { - gboolean result; - result = user_interface_window_delete_event_cb ((UserInterface*) self, _sender, event); -#line 14 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - return result; -#line 8399 "ui.c" -} - - -static void user_interface_page_size_changed_cb (UserInterface* self, Page* page) { - Page* _tmp0_ = NULL; - gint _tmp1_ = 0; - gint _tmp2_ = 0; - Page* _tmp3_ = NULL; - gint _tmp4_ = 0; - gint _tmp5_ = 0; - Page* _tmp6_ = NULL; - gint _tmp7_ = 0; - gint _tmp8_ = 0; -#line 1730 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - g_return_if_fail (self != NULL); -#line 1730 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - g_return_if_fail (page != NULL); -#line 1732 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp0_ = page; -#line 1732 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp1_ = page_get_width (_tmp0_); -#line 1732 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp2_ = _tmp1_; -#line 1732 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - self->priv->default_page_width = _tmp2_; -#line 1733 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp3_ = page; -#line 1733 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp4_ = page_get_height (_tmp3_); -#line 1733 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp5_ = _tmp4_; -#line 1733 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - self->priv->default_page_height = _tmp5_; -#line 1734 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp6_ = page; -#line 1734 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp7_ = page_get_dpi (_tmp6_); -#line 1734 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp8_ = _tmp7_; -#line 1734 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - self->priv->default_page_dpi = _tmp8_; -#line 1735 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - user_interface_save_state (self, FALSE); -#line 8443 "ui.c" -} - - -static void user_interface_page_scan_direction_changed_cb (UserInterface* self, Page* page) { - Page* _tmp0_ = NULL; - ScanDirection _tmp1_ = 0; - ScanDirection _tmp2_ = 0; -#line 1738 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - g_return_if_fail (self != NULL); -#line 1738 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - g_return_if_fail (page != NULL); -#line 1740 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp0_ = page; -#line 1740 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp1_ = page_get_scan_direction (_tmp0_); -#line 1740 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp2_ = _tmp1_; -#line 1740 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - self->priv->default_page_scan_direction = _tmp2_; -#line 1741 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - user_interface_save_state (self, FALSE); -#line 8465 "ui.c" -} - - -static void _user_interface_page_size_changed_cb_page_size_changed (Page* _sender, gpointer self) { -#line 1748 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - user_interface_page_size_changed_cb ((UserInterface*) self, _sender); -#line 8472 "ui.c" -} - - -static void _user_interface_page_scan_direction_changed_cb_page_scan_direction_changed (Page* _sender, gpointer self) { -#line 1749 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - user_interface_page_scan_direction_changed_cb ((UserInterface*) self, _sender); -#line 8479 "ui.c" -} - - -static void user_interface_page_added_cb (UserInterface* self, Book* book, Page* page) { - Page* _tmp0_ = NULL; - Page* _tmp1_ = NULL; - ScanDirection _tmp2_ = 0; - ScanDirection _tmp3_ = 0; - Page* _tmp4_ = NULL; - Page* _tmp5_ = NULL; -#line 1744 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - g_return_if_fail (self != NULL); -#line 1744 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - g_return_if_fail (book != NULL); -#line 1744 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - g_return_if_fail (page != NULL); -#line 1746 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp0_ = page; -#line 1746 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - user_interface_page_size_changed_cb (self, _tmp0_); -#line 1747 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp1_ = page; -#line 1747 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp2_ = page_get_scan_direction (_tmp1_); -#line 1747 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp3_ = _tmp2_; -#line 1747 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - self->priv->default_page_scan_direction = _tmp3_; -#line 1748 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp4_ = page; -#line 1748 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - g_signal_connect_object (_tmp4_, "size-changed", (GCallback) _user_interface_page_size_changed_cb_page_size_changed, self, 0); -#line 1749 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp5_ = page; -#line 1749 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - g_signal_connect_object (_tmp5_, "scan-direction-changed", (GCallback) _user_interface_page_scan_direction_changed_cb_page_scan_direction_changed, self, 0); -#line 1751 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - user_interface_update_page_menu (self); -#line 8518 "ui.c" -} - - -static void user_interface_reordered_cb (UserInterface* self, Book* book) { -#line 1754 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - g_return_if_fail (self != NULL); -#line 1754 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - g_return_if_fail (book != NULL); -#line 1756 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - user_interface_update_page_menu (self); -#line 8529 "ui.c" -} - - -static void user_interface_page_removed_cb (UserInterface* self, Book* book, Page* page) { - Page* _tmp0_ = NULL; - guint _tmp1_ = 0U; - Page* _tmp2_ = NULL; - guint _tmp3_ = 0U; - Book* _tmp4_ = NULL; - guint _tmp5_ = 0U; - guint _tmp6_ = 0U; -#line 1759 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - g_return_if_fail (self != NULL); -#line 1759 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - g_return_if_fail (book != NULL); -#line 1759 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - g_return_if_fail (page != NULL); -#line 1761 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp0_ = page; -#line 1761 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - g_signal_parse_name ("size-changed", TYPE_PAGE, &_tmp1_, NULL, FALSE); -#line 1761 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - g_signal_handlers_disconnect_matched (_tmp0_, G_SIGNAL_MATCH_ID | G_SIGNAL_MATCH_FUNC | G_SIGNAL_MATCH_DATA, _tmp1_, 0, NULL, (GCallback) _user_interface_page_size_changed_cb_page_size_changed, self); -#line 1762 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp2_ = page; -#line 1762 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - g_signal_parse_name ("scan-direction-changed", TYPE_PAGE, &_tmp3_, NULL, FALSE); -#line 1762 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - g_signal_handlers_disconnect_matched (_tmp2_, G_SIGNAL_MATCH_ID | G_SIGNAL_MATCH_FUNC | G_SIGNAL_MATCH_DATA, _tmp3_, 0, NULL, (GCallback) _user_interface_page_scan_direction_changed_cb_page_scan_direction_changed, self); -#line 1765 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp4_ = book; -#line 1765 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp5_ = book_get_n_pages (_tmp4_); -#line 1765 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp6_ = _tmp5_; -#line 1765 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - if (_tmp6_ == ((guint) 0)) { -#line 1766 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - user_interface_add_default_page (self); -#line 8569 "ui.c" - } -#line 1768 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - user_interface_update_page_menu (self); -#line 8573 "ui.c" -} - - -static void user_interface_set_dpi_combo (UserInterface* self, GtkComboBox* combo, gint default_dpi, gint current_dpi) { - GtkCellRendererText* renderer = NULL; - GtkCellRendererText* _tmp0_ = NULL; - GtkComboBox* _tmp1_ = NULL; - GtkCellRendererText* _tmp2_ = NULL; - GtkComboBox* _tmp3_ = NULL; - GtkCellRendererText* _tmp4_ = NULL; - GtkListStore* model = NULL; - GtkComboBox* _tmp5_ = NULL; - GtkTreeModel* _tmp6_ = NULL; - GtkTreeModel* _tmp7_ = NULL; - GtkListStore* _tmp8_ = NULL; - gint* scan_resolutions = NULL; - gint* _tmp9_ = NULL; - gint scan_resolutions_length1 = 0; - gint _scan_resolutions_size_ = 0; - gint* _tmp10_ = NULL; - gint _tmp10__length1 = 0; -#line 1771 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - g_return_if_fail (self != NULL); -#line 1771 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - g_return_if_fail (combo != NULL); -#line 1773 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp0_ = (GtkCellRendererText*) gtk_cell_renderer_text_new (); -#line 1773 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - g_object_ref_sink (_tmp0_); -#line 1773 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - renderer = _tmp0_; -#line 1774 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp1_ = combo; -#line 1774 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp2_ = renderer; -#line 1774 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - gtk_cell_layout_pack_start ((GtkCellLayout*) _tmp1_, (GtkCellRenderer*) _tmp2_, TRUE); -#line 1775 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp3_ = combo; -#line 1775 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp4_ = renderer; -#line 1775 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - gtk_cell_layout_add_attribute ((GtkCellLayout*) _tmp3_, (GtkCellRenderer*) _tmp4_, "text", 1); -#line 1777 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp5_ = combo; -#line 1777 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp6_ = gtk_combo_box_get_model (_tmp5_); -#line 1777 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp7_ = _tmp6_; -#line 1777 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp8_ = _g_object_ref0 (G_TYPE_CHECK_INSTANCE_TYPE (_tmp7_, gtk_list_store_get_type ()) ? ((GtkListStore*) _tmp7_) : NULL); -#line 1777 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - model = _tmp8_; -#line 1778 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp9_ = g_new0 (gint, 6); -#line 1778 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp9_[0] = 75; -#line 1778 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp9_[1] = 150; -#line 1778 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp9_[2] = 300; -#line 1778 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp9_[3] = 600; -#line 1778 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp9_[4] = 1200; -#line 1778 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp9_[5] = 2400; -#line 1778 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - scan_resolutions = _tmp9_; -#line 1778 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - scan_resolutions_length1 = 6; -#line 1778 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _scan_resolutions_size_ = scan_resolutions_length1; -#line 1779 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp10_ = scan_resolutions; -#line 1779 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp10__length1 = scan_resolutions_length1; -#line 8651 "ui.c" - { - gint* dpi_collection = NULL; - gint dpi_collection_length1 = 0; - gint _dpi_collection_size_ = 0; - gint dpi_it = 0; -#line 1779 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - dpi_collection = _tmp10_; -#line 1779 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - dpi_collection_length1 = _tmp10__length1; -#line 1779 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - for (dpi_it = 0; dpi_it < _tmp10__length1; dpi_it = dpi_it + 1) { -#line 8663 "ui.c" - gint dpi = 0; -#line 1779 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - dpi = dpi_collection[dpi_it]; -#line 8667 "ui.c" - { - gchar* label = NULL; - gint _tmp11_ = 0; - gint _tmp12_ = 0; - GtkTreeIter iter = {0}; - GtkListStore* _tmp27_ = NULL; - GtkTreeIter _tmp28_ = {0}; - GtkListStore* _tmp29_ = NULL; - GtkTreeIter _tmp30_ = {0}; - gint _tmp31_ = 0; - const gchar* _tmp32_ = NULL; - gint _tmp33_ = 0; - gint _tmp34_ = 0; -#line 1782 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp11_ = dpi; -#line 1782 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp12_ = default_dpi; -#line 1782 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - if (_tmp11_ == _tmp12_) { -#line 8687 "ui.c" - const gchar* _tmp13_ = NULL; - gint _tmp14_ = 0; - gchar* _tmp15_ = NULL; -#line 1784 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp13_ = _ ("%d dpi (default)"); -#line 1784 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp14_ = dpi; -#line 1784 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp15_ = g_strdup_printf (_tmp13_, _tmp14_); -#line 1784 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _g_free0 (label); -#line 1784 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - label = _tmp15_; -#line 8701 "ui.c" - } else { - gint _tmp16_ = 0; -#line 1785 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp16_ = dpi; -#line 1785 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - if (_tmp16_ == 75) { -#line 8708 "ui.c" - const gchar* _tmp17_ = NULL; - gint _tmp18_ = 0; - gchar* _tmp19_ = NULL; -#line 1787 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp17_ = _ ("%d dpi (draft)"); -#line 1787 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp18_ = dpi; -#line 1787 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp19_ = g_strdup_printf (_tmp17_, _tmp18_); -#line 1787 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _g_free0 (label); -#line 1787 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - label = _tmp19_; -#line 8722 "ui.c" - } else { - gint _tmp20_ = 0; -#line 1788 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp20_ = dpi; -#line 1788 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - if (_tmp20_ == 1200) { -#line 8729 "ui.c" - const gchar* _tmp21_ = NULL; - gint _tmp22_ = 0; - gchar* _tmp23_ = NULL; -#line 1790 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp21_ = _ ("%d dpi (high resolution)"); -#line 1790 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp22_ = dpi; -#line 1790 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp23_ = g_strdup_printf (_tmp21_, _tmp22_); -#line 1790 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _g_free0 (label); -#line 1790 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - label = _tmp23_; -#line 8743 "ui.c" - } else { - const gchar* _tmp24_ = NULL; - gint _tmp25_ = 0; - gchar* _tmp26_ = NULL; -#line 1793 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp24_ = _ ("%d dpi"); -#line 1793 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp25_ = dpi; -#line 1793 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp26_ = g_strdup_printf (_tmp24_, _tmp25_); -#line 1793 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _g_free0 (label); -#line 1793 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - label = _tmp26_; -#line 8758 "ui.c" - } - } - } -#line 1796 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp27_ = model; -#line 1796 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - gtk_list_store_append (_tmp27_, &_tmp28_); -#line 1796 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - iter = _tmp28_; -#line 1797 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp29_ = model; -#line 1797 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp30_ = iter; -#line 1797 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp31_ = dpi; -#line 1797 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp32_ = label; -#line 1797 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - gtk_list_store_set (_tmp29_, &_tmp30_, 0, _tmp31_, 1, _tmp32_, -1, -1); -#line 1799 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp33_ = dpi; -#line 1799 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp34_ = current_dpi; -#line 1799 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - if (_tmp33_ == _tmp34_) { -#line 8784 "ui.c" - GtkComboBox* _tmp35_ = NULL; - GtkTreeIter _tmp36_ = {0}; -#line 1800 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp35_ = combo; -#line 1800 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp36_ = iter; -#line 1800 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - gtk_combo_box_set_active_iter (_tmp35_, &_tmp36_); -#line 8793 "ui.c" - } -#line 1779 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _g_free0 (label); -#line 8797 "ui.c" - } - } - } -#line 1771 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - scan_resolutions = (g_free (scan_resolutions), NULL); -#line 1771 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _g_object_unref0 (model); -#line 1771 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _g_object_unref0 (renderer); -#line 8807 "ui.c" -} - - -static void user_interface_needs_saving_cb (UserInterface* self, Book* book) { - GtkMenuItem* _tmp0_ = NULL; - Book* _tmp1_ = NULL; - gboolean _tmp2_ = FALSE; - gboolean _tmp3_ = FALSE; - GtkButton* _tmp4_ = NULL; - Book* _tmp5_ = NULL; - gboolean _tmp6_ = FALSE; - gboolean _tmp7_ = FALSE; - GtkToolButton* _tmp8_ = NULL; - Book* _tmp9_ = NULL; - gboolean _tmp10_ = FALSE; - gboolean _tmp11_ = FALSE; - Book* _tmp12_ = NULL; - gboolean _tmp13_ = FALSE; - gboolean _tmp14_ = FALSE; - GtkMenuItem* _tmp16_ = NULL; -#line 1804 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - g_return_if_fail (self != NULL); -#line 1804 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - g_return_if_fail (book != NULL); -#line 1806 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp0_ = self->priv->save_menuitem; -#line 1806 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp1_ = book; -#line 1806 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp2_ = book_get_needs_saving (_tmp1_); -#line 1806 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp3_ = _tmp2_; -#line 1806 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - gtk_widget_set_sensitive ((GtkWidget*) _tmp0_, _tmp3_); -#line 1807 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp4_ = self->priv->save_button; -#line 1807 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp5_ = book; -#line 1807 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp6_ = book_get_needs_saving (_tmp5_); -#line 1807 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp7_ = _tmp6_; -#line 1807 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - gtk_widget_set_sensitive ((GtkWidget*) _tmp4_, _tmp7_); -#line 1808 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp8_ = self->priv->save_toolbutton; -#line 1808 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp9_ = book; -#line 1808 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp10_ = book_get_needs_saving (_tmp9_); -#line 1808 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp11_ = _tmp10_; -#line 1808 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - gtk_widget_set_sensitive ((GtkWidget*) _tmp8_, _tmp11_); -#line 1809 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp12_ = book; -#line 1809 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp13_ = book_get_needs_saving (_tmp12_); -#line 1809 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp14_ = _tmp13_; -#line 1809 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - if (_tmp14_) { -#line 8870 "ui.c" - GtkMenuItem* _tmp15_ = NULL; -#line 1810 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp15_ = self->priv->save_as_menuitem; -#line 1810 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - gtk_widget_set_sensitive ((GtkWidget*) _tmp15_, TRUE); -#line 8876 "ui.c" - } -#line 1811 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp16_ = self->priv->copy_to_clipboard_menuitem; -#line 1811 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - gtk_widget_set_sensitive ((GtkWidget*) _tmp16_, TRUE); -#line 8882 "ui.c" -} - - -static void _user_interface_info_bar_response_cb_gtk_info_bar_response (GtkInfoBar* _sender, gint response_id, gpointer self) { -#line 1871 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - user_interface_info_bar_response_cb ((UserInterface*) self, _sender, response_id); -#line 8889 "ui.c" -} - - -static void __lambda14_ (UserInterface* self) { - GSettings* _tmp0_ = NULL; - gint _tmp1_ = 0; -#line 1915 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp0_ = self->priv->settings; -#line 1915 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp1_ = user_interface_get_text_dpi (self); -#line 1915 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - g_settings_set_int (_tmp0_, "text-dpi", _tmp1_); -#line 8902 "ui.c" -} - - -static void ___lambda14__gtk_combo_box_changed (GtkComboBox* _sender, gpointer self) { -#line 1915 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - __lambda14_ ((UserInterface*) self); -#line 8909 "ui.c" -} - - -static void __lambda15_ (UserInterface* self) { - GSettings* _tmp0_ = NULL; - gint _tmp1_ = 0; -#line 1920 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp0_ = self->priv->settings; -#line 1920 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp1_ = user_interface_get_photo_dpi (self); -#line 1920 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - g_settings_set_int (_tmp0_, "photo-dpi", _tmp1_); -#line 8922 "ui.c" -} - - -static void ___lambda15__gtk_combo_box_changed (GtkComboBox* _sender, gpointer self) { -#line 1920 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - __lambda15_ ((UserInterface*) self); -#line 8929 "ui.c" -} - - -static void __lambda16_ (UserInterface* self) { - GSettings* _tmp0_ = NULL; - ScanType _tmp1_ = 0; -#line 1930 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp0_ = self->priv->settings; -#line 1930 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp1_ = user_interface_get_page_side (self); -#line 1930 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - g_settings_set_enum (_tmp0_, "page-side", (gint) _tmp1_); -#line 8942 "ui.c" -} - - -static void ___lambda16__gtk_combo_box_changed (GtkComboBox* _sender, gpointer self) { -#line 1930 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - __lambda16_ ((UserInterface*) self); -#line 8949 "ui.c" -} - - -static void __lambda17_ (UserInterface* self) { - gint w = 0; - gint h = 0; - gint _tmp0_ = 0; - gint _tmp1_ = 0; - GSettings* _tmp2_ = NULL; - GSettings* _tmp3_ = NULL; -#line 1941 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - user_interface_get_paper_size (self, &_tmp0_, &_tmp1_); -#line 1941 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - w = _tmp0_; -#line 1941 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - h = _tmp1_; -#line 1942 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp2_ = self->priv->settings; -#line 1942 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - g_settings_set_int (_tmp2_, "paper-width", w); -#line 1943 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp3_ = self->priv->settings; -#line 1943 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - g_settings_set_int (_tmp3_, "paper-height", h); -#line 8974 "ui.c" -} - - -static void ___lambda17__gtk_combo_box_changed (GtkComboBox* _sender, gpointer self) { -#line 1938 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - __lambda17_ ((UserInterface*) self); -#line 8981 "ui.c" -} - - -static void __lambda18_ (UserInterface* self) { - GSettings* _tmp0_ = NULL; - gint _tmp1_ = 0; - gint _tmp2_ = 0; -#line 1954 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp0_ = self->priv->settings; -#line 1954 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp1_ = user_interface_get_brightness (self); -#line 1954 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp2_ = _tmp1_; -#line 1954 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - g_settings_set_int (_tmp0_, "brightness", _tmp2_); -#line 8997 "ui.c" -} - - -static void ___lambda18__gtk_adjustment_value_changed (GtkAdjustment* _sender, gpointer self) { -#line 1954 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - __lambda18_ ((UserInterface*) self); -#line 9004 "ui.c" -} - - -static void __lambda19_ (UserInterface* self) { - GSettings* _tmp0_ = NULL; - gint _tmp1_ = 0; - gint _tmp2_ = 0; -#line 1964 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp0_ = self->priv->settings; -#line 1964 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp1_ = user_interface_get_contrast (self); -#line 1964 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp2_ = _tmp1_; -#line 1964 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - g_settings_set_int (_tmp0_, "contrast", _tmp2_); -#line 9020 "ui.c" -} - - -static void ___lambda19__gtk_adjustment_value_changed (GtkAdjustment* _sender, gpointer self) { -#line 1964 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - __lambda19_ ((UserInterface*) self); -#line 9027 "ui.c" -} - - -static void __lambda20_ (UserInterface* self) { - GSettings* _tmp0_ = NULL; - gint _tmp1_ = 0; - gint _tmp2_ = 0; -#line 1974 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp0_ = self->priv->settings; -#line 1974 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp1_ = user_interface_get_quality (self); -#line 1974 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp2_ = _tmp1_; -#line 1974 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - g_settings_set_int (_tmp0_, "jpeg-quality", _tmp2_); -#line 9043 "ui.c" -} - - -static void ___lambda20__gtk_adjustment_value_changed (GtkAdjustment* _sender, gpointer self) { -#line 1974 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - __lambda20_ ((UserInterface*) self); -#line 9050 "ui.c" -} - - -static void _user_interface_page_selected_cb_book_view_page_selected (BookView* _sender, Page* page, gpointer self) { -#line 1983 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - user_interface_page_selected_cb ((UserInterface*) self, _sender, page); -#line 9057 "ui.c" -} - - -static void _user_interface_show_page_cb_book_view_show_page (BookView* _sender, Page* page, gpointer self) { -#line 1984 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - user_interface_show_page_cb ((UserInterface*) self, _sender, page); -#line 9064 "ui.c" -} - - -static void _user_interface_show_page_menu_cb_book_view_show_menu (BookView* _sender, gpointer self) { -#line 1985 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - user_interface_show_page_menu_cb ((UserInterface*) self, _sender); -#line 9071 "ui.c" -} - - -static void _user_interface_book_saving_cb_book_saving (Book* _sender, gint i, gpointer self) { -#line 2009 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - user_interface_book_saving_cb ((UserInterface*) self, i); -#line 9078 "ui.c" -} - - -static void user_interface_load (UserInterface* self) { - GtkIconTheme* _tmp0_ = NULL; - GtkApplication* app = NULL; - GApplication* _tmp1_ = NULL; - GtkApplication* _tmp2_ = NULL; - gboolean _tmp3_ = FALSE; - GtkApplication* _tmp53_ = NULL; - GtkInfoBar* _tmp54_ = NULL; - GtkInfoBar* _tmp55_ = NULL; - GtkBox* _tmp56_ = NULL; - GtkInfoBar* _tmp57_ = NULL; - GtkBox* hbox = NULL; - GtkBox* _tmp58_ = NULL; - GtkContainer* content_area = NULL; - GtkInfoBar* _tmp59_ = NULL; - GtkContainer* _tmp60_ = NULL; - GtkContainer* _tmp61_ = NULL; - GtkContainer* _tmp62_ = NULL; - GtkBox* _tmp63_ = NULL; - GtkBox* _tmp64_ = NULL; - GtkImage* _tmp65_ = NULL; - GtkBox* _tmp66_ = NULL; - GtkImage* _tmp67_ = NULL; - GtkImage* _tmp68_ = NULL; - GtkLabel* _tmp69_ = NULL; - GtkLabel* _tmp70_ = NULL; - GtkBox* _tmp71_ = NULL; - GtkLabel* _tmp72_ = NULL; - GtkLabel* _tmp73_ = NULL; - GtkInfoBar* _tmp74_ = NULL; - const gchar* _tmp75_ = NULL; - GtkButton* _tmp76_ = NULL; - GtkButton* _tmp77_ = NULL; - GtkInfoBar* _tmp78_ = NULL; - const gchar* _tmp79_ = NULL; - GtkButton* _tmp80_ = NULL; - GtkButton* _tmp81_ = NULL; - GtkInfoBar* _tmp82_ = NULL; - const gchar* _tmp83_ = NULL; - GtkButton* _tmp84_ = NULL; - GtkButton* _tmp85_ = NULL; - GtkTreeIter iter = {0}; - GtkListStore* _tmp86_ = NULL; - GtkTreeIter _tmp87_ = {0}; - GtkListStore* _tmp88_ = NULL; - GtkTreeIter _tmp89_ = {0}; - const gchar* _tmp90_ = NULL; - GtkListStore* _tmp91_ = NULL; - GtkTreeIter _tmp92_ = {0}; - GtkListStore* _tmp93_ = NULL; - GtkTreeIter _tmp94_ = {0}; - GtkListStore* _tmp95_ = NULL; - GtkTreeIter _tmp96_ = {0}; - GtkListStore* _tmp97_ = NULL; - GtkTreeIter _tmp98_ = {0}; - GtkListStore* _tmp99_ = NULL; - GtkTreeIter _tmp100_ = {0}; - GtkListStore* _tmp101_ = NULL; - GtkTreeIter _tmp102_ = {0}; - GtkListStore* _tmp103_ = NULL; - GtkTreeIter _tmp104_ = {0}; - GtkListStore* _tmp105_ = NULL; - GtkTreeIter _tmp106_ = {0}; - GtkListStore* _tmp107_ = NULL; - GtkTreeIter _tmp108_ = {0}; - GtkListStore* _tmp109_ = NULL; - GtkTreeIter _tmp110_ = {0}; - GtkListStore* _tmp111_ = NULL; - GtkTreeIter _tmp112_ = {0}; - GtkListStore* _tmp113_ = NULL; - GtkTreeIter _tmp114_ = {0}; - gint dpi = 0; - GSettings* _tmp115_ = NULL; - gint _tmp116_ = 0; - gint _tmp117_ = 0; - GtkComboBox* _tmp118_ = NULL; - gint _tmp119_ = 0; - GtkComboBox* _tmp120_ = NULL; - GSettings* _tmp121_ = NULL; - gint _tmp122_ = 0; - gint _tmp123_ = 0; - GtkComboBox* _tmp124_ = NULL; - gint _tmp125_ = 0; - GtkComboBox* _tmp126_ = NULL; - GtkCellRendererText* renderer = NULL; - GtkCellRendererText* _tmp127_ = NULL; - GtkComboBox* _tmp128_ = NULL; - GtkCellRendererText* _tmp129_ = NULL; - GtkComboBox* _tmp130_ = NULL; - GtkCellRendererText* _tmp131_ = NULL; - GtkCellRendererText* _tmp132_ = NULL; - GtkComboBox* _tmp133_ = NULL; - GtkCellRendererText* _tmp134_ = NULL; - GtkComboBox* _tmp135_ = NULL; - GtkCellRendererText* _tmp136_ = NULL; - GSettings* _tmp137_ = NULL; - gint _tmp138_ = 0; - GtkComboBox* _tmp139_ = NULL; - GtkCellRendererText* _tmp140_ = NULL; - GtkComboBox* _tmp141_ = NULL; - GtkCellRendererText* _tmp142_ = NULL; - GtkComboBox* _tmp143_ = NULL; - GtkCellRendererText* _tmp144_ = NULL; - gint paper_width = 0; - GSettings* _tmp145_ = NULL; - gint _tmp146_ = 0; - gint paper_height = 0; - GSettings* _tmp147_ = NULL; - gint _tmp148_ = 0; - gint _tmp149_ = 0; - gint _tmp150_ = 0; - GtkComboBox* _tmp151_ = NULL; - gdouble lower = 0.0; - GtkAdjustment* _tmp152_ = NULL; - gdouble _tmp153_ = 0.0; - gdouble _tmp154_ = 0.0; - gchar* darker_label = NULL; - const gchar* _tmp155_ = NULL; - gchar* _tmp156_ = NULL; - gdouble upper = 0.0; - GtkAdjustment* _tmp157_ = NULL; - gdouble _tmp158_ = 0.0; - gdouble _tmp159_ = 0.0; - gchar* lighter_label = NULL; - const gchar* _tmp160_ = NULL; - gchar* _tmp161_ = NULL; - GtkScale* _tmp162_ = NULL; - gdouble _tmp163_ = 0.0; - const gchar* _tmp164_ = NULL; - GtkScale* _tmp165_ = NULL; - GtkScale* _tmp166_ = NULL; - gdouble _tmp167_ = 0.0; - const gchar* _tmp168_ = NULL; - GSettings* _tmp169_ = NULL; - gint _tmp170_ = 0; - GtkAdjustment* _tmp171_ = NULL; - GtkAdjustment* _tmp172_ = NULL; - gdouble _tmp173_ = 0.0; - gdouble _tmp174_ = 0.0; - gchar* less_label = NULL; - const gchar* _tmp175_ = NULL; - gchar* _tmp176_ = NULL; - GtkAdjustment* _tmp177_ = NULL; - gdouble _tmp178_ = 0.0; - gdouble _tmp179_ = 0.0; - gchar* more_label = NULL; - const gchar* _tmp180_ = NULL; - gchar* _tmp181_ = NULL; - GtkScale* _tmp182_ = NULL; - gdouble _tmp183_ = 0.0; - const gchar* _tmp184_ = NULL; - GtkScale* _tmp185_ = NULL; - GtkScale* _tmp186_ = NULL; - gdouble _tmp187_ = 0.0; - const gchar* _tmp188_ = NULL; - GSettings* _tmp189_ = NULL; - gint _tmp190_ = 0; - GtkAdjustment* _tmp191_ = NULL; - GtkAdjustment* _tmp192_ = NULL; - gdouble _tmp193_ = 0.0; - gdouble _tmp194_ = 0.0; - gchar* minimum_label = NULL; - const gchar* _tmp195_ = NULL; - gchar* _tmp196_ = NULL; - GtkAdjustment* _tmp197_ = NULL; - gdouble _tmp198_ = 0.0; - gdouble _tmp199_ = 0.0; - gchar* maximum_label = NULL; - const gchar* _tmp200_ = NULL; - gchar* _tmp201_ = NULL; - GtkScale* _tmp202_ = NULL; - gdouble _tmp203_ = 0.0; - const gchar* _tmp204_ = NULL; - GtkScale* _tmp205_ = NULL; - GtkScale* _tmp206_ = NULL; - gdouble _tmp207_ = 0.0; - const gchar* _tmp208_ = NULL; - GSettings* _tmp209_ = NULL; - gint _tmp210_ = 0; - GtkAdjustment* _tmp211_ = NULL; - gchar* document_type = NULL; - GSettings* _tmp212_ = NULL; - gchar* _tmp213_ = NULL; - const gchar* _tmp214_ = NULL; - Book* _tmp216_ = NULL; - BookView* _tmp217_ = NULL; - BookView* _tmp218_ = NULL; - GtkBox* _tmp219_ = NULL; - BookView* _tmp220_ = NULL; - BookView* _tmp221_ = NULL; - BookView* _tmp222_ = NULL; - BookView* _tmp223_ = NULL; - BookView* _tmp224_ = NULL; - GtkDialog* _tmp225_ = NULL; - GtkDialog* _tmp226_ = NULL; - gint _tmp227_ = 0; - gint _tmp228_ = 0; - gint _tmp229_ = 0; - gint _tmp230_ = 0; - gboolean _tmp231_ = FALSE; - gboolean _tmp232_ = FALSE; - const gchar* _tmp233_ = NULL; - ProgressBarDialog* _tmp234_ = NULL; - Book* _tmp235_ = NULL; -#line 1814 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - g_return_if_fail (self != NULL); -#line 1816 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp0_ = gtk_icon_theme_get_default (); -#line 1816 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - gtk_icon_theme_append_search_path (_tmp0_, ICON_DIR); -#line 1818 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - gtk_window_set_default_icon_name ("scanner"); -#line 1820 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp1_ = g_application_get_default (); -#line 1820 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp2_ = _g_object_ref0 (G_TYPE_CHECK_INSTANCE_TYPE (_tmp1_, gtk_application_get_type ()) ? ((GtkApplication*) _tmp1_) : NULL); -#line 1820 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - app = _tmp2_; -#line 1822 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp3_ = user_interface_is_traditional_desktop (self); -#line 1822 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - if (_tmp3_) { -#line 9304 "ui.c" - GtkMenuBar* _tmp4_ = NULL; - GtkToolbar* _tmp5_ = NULL; -#line 1824 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - gtk_window_set_titlebar ((GtkWindow*) self, NULL); -#line 1825 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp4_ = self->priv->menubar; -#line 1825 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - gtk_widget_set_visible ((GtkWidget*) _tmp4_, TRUE); -#line 1826 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp5_ = self->priv->toolbar; -#line 1826 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - gtk_widget_set_visible ((GtkWidget*) _tmp5_, TRUE); -#line 9317 "ui.c" - } else { - GtkApplication* _tmp6_ = NULL; - GMenu* appmenu = NULL; - GMenu* _tmp7_ = NULL; - GMenu* section = NULL; - GMenu* _tmp8_ = NULL; - GMenu* _tmp9_ = NULL; - GMenu* _tmp10_ = NULL; - GMenu* _tmp11_ = NULL; - const gchar* _tmp12_ = NULL; - GMenu* _tmp13_ = NULL; - GMenu* _tmp14_ = NULL; - GMenu* _tmp15_ = NULL; - GMenu* menu = NULL; - GMenu* _tmp16_ = NULL; - GMenu* _tmp17_ = NULL; - const gchar* _tmp18_ = NULL; - GMenu* _tmp19_ = NULL; - GMenu* _tmp20_ = NULL; - const gchar* _tmp21_ = NULL; - GMenu* _tmp22_ = NULL; - const gchar* _tmp23_ = NULL; - GMenu* _tmp24_ = NULL; - const gchar* _tmp25_ = NULL; - GMenu* _tmp26_ = NULL; - const gchar* _tmp27_ = NULL; - GMenu* _tmp28_ = NULL; - const gchar* _tmp29_ = NULL; - GMenu* _tmp30_ = NULL; - GMenu* _tmp31_ = NULL; - GMenu* _tmp32_ = NULL; - GMenu* _tmp33_ = NULL; - const gchar* _tmp34_ = NULL; - GMenu* _tmp35_ = NULL; - GMenu* _tmp36_ = NULL; - GMenu* _tmp37_ = NULL; - GMenu* _tmp38_ = NULL; - const gchar* _tmp39_ = NULL; - GMenu* _tmp40_ = NULL; - const gchar* _tmp41_ = NULL; - GMenu* _tmp42_ = NULL; - const gchar* _tmp43_ = NULL; - GtkApplication* _tmp44_ = NULL; - GMenu* _tmp45_ = NULL; - GtkApplication* _tmp46_ = NULL; - GtkApplication* _tmp47_ = NULL; - GtkApplication* _tmp48_ = NULL; - GtkApplication* _tmp49_ = NULL; - GtkApplication* _tmp50_ = NULL; - GtkApplication* _tmp51_ = NULL; - GtkApplication* _tmp52_ = NULL; -#line 1830 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp6_ = app; -#line 1830 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - g_action_map_add_action_entries ((GActionMap*) _tmp6_, USER_INTERFACE_action_entries, G_N_ELEMENTS (USER_INTERFACE_action_entries), self); -#line 1832 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp7_ = g_menu_new (); -#line 1832 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - appmenu = _tmp7_; -#line 1833 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp8_ = g_menu_new (); -#line 1833 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - section = _tmp8_; -#line 1834 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp9_ = appmenu; -#line 1834 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp10_ = section; -#line 1834 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - g_menu_append_section (_tmp9_, NULL, (GMenuModel*) _tmp10_); -#line 1835 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp11_ = section; -#line 1835 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp12_ = _ ("New Document"); -#line 1835 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - g_menu_append (_tmp11_, _tmp12_, "app.new_document"); -#line 1837 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp13_ = g_menu_new (); -#line 1837 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _g_object_unref0 (section); -#line 1837 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - section = _tmp13_; -#line 1838 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp14_ = appmenu; -#line 1838 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp15_ = section; -#line 1838 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - g_menu_append_section (_tmp14_, NULL, (GMenuModel*) _tmp15_); -#line 1839 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp16_ = g_menu_new (); -#line 1839 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - menu = _tmp16_; -#line 1840 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp17_ = section; -#line 1840 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp18_ = _ ("Document"); -#line 1840 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp19_ = menu; -#line 1840 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - g_menu_append_submenu (_tmp17_, _tmp18_, (GMenuModel*) _tmp19_); -#line 1841 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp20_ = menu; -#line 1841 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp21_ = _ ("Reorder Pages"); -#line 1841 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - g_menu_append (_tmp20_, _tmp21_, "app.reorder"); -#line 1842 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp22_ = menu; -#line 1842 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp23_ = _ ("Save"); -#line 1842 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - g_menu_append (_tmp22_, _tmp23_, "app.save"); -#line 1843 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp24_ = menu; -#line 1843 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp25_ = _ ("Save As..."); -#line 1843 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - g_menu_append (_tmp24_, _tmp25_, "app.save_as"); -#line 1844 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp26_ = menu; -#line 1844 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp27_ = _ ("Email..."); -#line 1844 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - g_menu_append (_tmp26_, _tmp27_, "app.email"); -#line 1845 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp28_ = menu; -#line 1845 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp29_ = _ ("Print..."); -#line 1845 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - g_menu_append (_tmp28_, _tmp29_, "app.print"); -#line 1847 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp30_ = g_menu_new (); -#line 1847 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _g_object_unref0 (section); -#line 1847 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - section = _tmp30_; -#line 1848 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp31_ = appmenu; -#line 1848 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp32_ = section; -#line 1848 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - g_menu_append_section (_tmp31_, NULL, (GMenuModel*) _tmp32_); -#line 1849 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp33_ = section; -#line 1849 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp34_ = _ ("Preferences"); -#line 1849 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - g_menu_append (_tmp33_, _tmp34_, "app.preferences"); -#line 1851 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp35_ = g_menu_new (); -#line 1851 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _g_object_unref0 (section); -#line 1851 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - section = _tmp35_; -#line 1852 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp36_ = appmenu; -#line 1852 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp37_ = section; -#line 1852 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - g_menu_append_section (_tmp36_, NULL, (GMenuModel*) _tmp37_); -#line 1853 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp38_ = section; -#line 1853 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp39_ = _ ("Help"); -#line 1853 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - g_menu_append (_tmp38_, _tmp39_, "app.help"); -#line 1854 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp40_ = section; -#line 1854 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp41_ = _ ("About"); -#line 1854 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - g_menu_append (_tmp40_, _tmp41_, "app.about"); -#line 1855 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp42_ = section; -#line 1855 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp43_ = _ ("Quit"); -#line 1855 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - g_menu_append (_tmp42_, _tmp43_, "app.quit"); -#line 1857 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp44_ = app; -#line 1857 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp45_ = appmenu; -#line 1857 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - gtk_application_set_app_menu (_tmp44_, (GMenuModel*) _tmp45_); -#line 1859 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp46_ = app; -#line 1859 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - gtk_application_add_accelerator (_tmp46_, "N", "app.new_document", NULL); -#line 1860 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp47_ = app; -#line 1860 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - gtk_application_add_accelerator (_tmp47_, "S", "app.save", NULL); -#line 1861 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp48_ = app; -#line 1861 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - gtk_application_add_accelerator (_tmp48_, "S", "app.save_as", NULL); -#line 1862 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp49_ = app; -#line 1862 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - gtk_application_add_accelerator (_tmp49_, "E", "app.email", NULL); -#line 1863 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp50_ = app; -#line 1863 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - gtk_application_add_accelerator (_tmp50_, "P", "app.print", NULL); -#line 1864 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp51_ = app; -#line 1864 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - gtk_application_add_accelerator (_tmp51_, "F1", "app.help", NULL); -#line 1865 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp52_ = app; -#line 1865 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - gtk_application_add_accelerator (_tmp52_, "Q", "app.quit", NULL); -#line 1822 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _g_object_unref0 (menu); -#line 1822 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _g_object_unref0 (section); -#line 1822 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _g_object_unref0 (appmenu); -#line 9535 "ui.c" - } -#line 1867 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp53_ = app; -#line 1867 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - gtk_application_add_window (_tmp53_, (GtkWindow*) self); -#line 1870 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp54_ = (GtkInfoBar*) gtk_info_bar_new (); -#line 1870 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - g_object_ref_sink (_tmp54_); -#line 1870 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _g_object_unref0 (self->priv->info_bar); -#line 1870 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - self->priv->info_bar = _tmp54_; -#line 1871 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp55_ = self->priv->info_bar; -#line 1871 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - g_signal_connect_object (_tmp55_, "response", (GCallback) _user_interface_info_bar_response_cb_gtk_info_bar_response, self, 0); -#line 1872 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp56_ = self->priv->main_vbox; -#line 1872 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp57_ = self->priv->info_bar; -#line 1872 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - gtk_box_pack_start (_tmp56_, (GtkWidget*) _tmp57_, FALSE, TRUE, (guint) 0); -#line 1873 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp58_ = (GtkBox*) gtk_box_new (GTK_ORIENTATION_HORIZONTAL, 12); -#line 1873 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - g_object_ref_sink (_tmp58_); -#line 1873 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - hbox = _tmp58_; -#line 1874 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp59_ = self->priv->info_bar; -#line 1874 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp60_ = gtk_info_bar_get_content_area (_tmp59_); -#line 1874 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp61_ = _g_object_ref0 (G_TYPE_CHECK_INSTANCE_TYPE (_tmp60_, gtk_container_get_type ()) ? ((GtkContainer*) _tmp60_) : NULL); -#line 1874 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - content_area = _tmp61_; -#line 1875 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp62_ = content_area; -#line 1875 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp63_ = hbox; -#line 1875 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - gtk_container_add (_tmp62_, (GtkWidget*) _tmp63_); -#line 1876 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp64_ = hbox; -#line 1876 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - gtk_widget_set_visible ((GtkWidget*) _tmp64_, TRUE); -#line 1878 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp65_ = (GtkImage*) gtk_image_new_from_icon_name ("dialog-warning", GTK_ICON_SIZE_DIALOG); -#line 1878 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - g_object_ref_sink (_tmp65_); -#line 1878 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _g_object_unref0 (self->priv->info_bar_image); -#line 1878 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - self->priv->info_bar_image = _tmp65_; -#line 1879 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp66_ = hbox; -#line 1879 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp67_ = self->priv->info_bar_image; -#line 1879 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - gtk_box_pack_start (_tmp66_, (GtkWidget*) _tmp67_, FALSE, TRUE, (guint) 0); -#line 1880 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp68_ = self->priv->info_bar_image; -#line 1880 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - gtk_widget_set_visible ((GtkWidget*) _tmp68_, TRUE); -#line 1882 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp69_ = (GtkLabel*) gtk_label_new (NULL); -#line 1882 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - g_object_ref_sink (_tmp69_); -#line 1882 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _g_object_unref0 (self->priv->info_bar_label); -#line 1882 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - self->priv->info_bar_label = _tmp69_; -#line 1883 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp70_ = self->priv->info_bar_label; -#line 1883 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - gtk_misc_set_alignment ((GtkMisc*) _tmp70_, 0.0f, 0.5f); -#line 1884 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp71_ = hbox; -#line 1884 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp72_ = self->priv->info_bar_label; -#line 1884 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - gtk_box_pack_start (_tmp71_, (GtkWidget*) _tmp72_, TRUE, TRUE, (guint) 0); -#line 1885 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp73_ = self->priv->info_bar_label; -#line 1885 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - gtk_widget_set_visible ((GtkWidget*) _tmp73_, TRUE); -#line 1887 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp74_ = self->priv->info_bar; -#line 1887 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp75_ = _ ("_Close"); -#line 1887 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp76_ = gtk_info_bar_add_button (_tmp74_, _tmp75_, (gint) GTK_RESPONSE_CLOSE); -#line 1887 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp77_ = _g_object_ref0 (G_TYPE_CHECK_INSTANCE_TYPE (_tmp76_, gtk_button_get_type ()) ? ((GtkButton*) _tmp76_) : NULL); -#line 1887 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _g_object_unref0 (self->priv->info_bar_close_button); -#line 1887 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - self->priv->info_bar_close_button = _tmp77_; -#line 1888 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp78_ = self->priv->info_bar; -#line 1888 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp79_ = _ ("Change _Scanner"); -#line 1888 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp80_ = gtk_info_bar_add_button (_tmp78_, _tmp79_, 1); -#line 1888 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp81_ = _g_object_ref0 (G_TYPE_CHECK_INSTANCE_TYPE (_tmp80_, gtk_button_get_type ()) ? ((GtkButton*) _tmp80_) : NULL); -#line 1888 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _g_object_unref0 (self->priv->info_bar_change_scanner_button); -#line 1888 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - self->priv->info_bar_change_scanner_button = _tmp81_; -#line 1890 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp82_ = self->priv->info_bar; -#line 1890 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp83_ = _ ("_Install Drivers"); -#line 1890 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp84_ = gtk_info_bar_add_button (_tmp82_, _tmp83_, 2); -#line 1890 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp85_ = _g_object_ref0 (G_TYPE_CHECK_INSTANCE_TYPE (_tmp84_, gtk_button_get_type ()) ? ((GtkButton*) _tmp84_) : NULL); -#line 1890 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _g_object_unref0 (self->priv->info_bar_install_button); -#line 1890 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - self->priv->info_bar_install_button = _tmp85_; -#line 1894 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp86_ = self->priv->paper_size_model; -#line 1894 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - gtk_list_store_append (_tmp86_, &_tmp87_); -#line 1894 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - iter = _tmp87_; -#line 1895 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp88_ = self->priv->paper_size_model; -#line 1895 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp89_ = iter; -#line 1895 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp90_ = _ ("Automatic"); -#line 1895 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - gtk_list_store_set (_tmp88_, &_tmp89_, 0, 0, 1, 0, 2, _tmp90_, -1, -1); -#line 1898 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp91_ = self->priv->paper_size_model; -#line 1898 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - gtk_list_store_append (_tmp91_, &_tmp92_); -#line 1898 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - iter = _tmp92_; -#line 1899 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp93_ = self->priv->paper_size_model; -#line 1899 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp94_ = iter; -#line 1899 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - gtk_list_store_set (_tmp93_, &_tmp94_, 0, 1050, 1, 1480, 2, "A6", -1, -1); -#line 1900 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp95_ = self->priv->paper_size_model; -#line 1900 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - gtk_list_store_append (_tmp95_, &_tmp96_); -#line 1900 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - iter = _tmp96_; -#line 1901 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp97_ = self->priv->paper_size_model; -#line 1901 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp98_ = iter; -#line 1901 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - gtk_list_store_set (_tmp97_, &_tmp98_, 0, 1480, 1, 2100, 2, "A5", -1, -1); -#line 1902 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp99_ = self->priv->paper_size_model; -#line 1902 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - gtk_list_store_append (_tmp99_, &_tmp100_); -#line 1902 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - iter = _tmp100_; -#line 1903 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp101_ = self->priv->paper_size_model; -#line 1903 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp102_ = iter; -#line 1903 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - gtk_list_store_set (_tmp101_, &_tmp102_, 0, 2100, 1, 2970, 2, "A4", -1, -1); -#line 1904 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp103_ = self->priv->paper_size_model; -#line 1904 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - gtk_list_store_append (_tmp103_, &_tmp104_); -#line 1904 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - iter = _tmp104_; -#line 1905 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp105_ = self->priv->paper_size_model; -#line 1905 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp106_ = iter; -#line 1905 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - gtk_list_store_set (_tmp105_, &_tmp106_, 0, 2159, 1, 2794, 2, "Letter", -1, -1); -#line 1906 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp107_ = self->priv->paper_size_model; -#line 1906 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - gtk_list_store_append (_tmp107_, &_tmp108_); -#line 1906 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - iter = _tmp108_; -#line 1907 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp109_ = self->priv->paper_size_model; -#line 1907 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp110_ = iter; -#line 1907 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - gtk_list_store_set (_tmp109_, &_tmp110_, 0, 2159, 1, 3556, 2, "Legal", -1, -1); -#line 1908 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp111_ = self->priv->paper_size_model; -#line 1908 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - gtk_list_store_append (_tmp111_, &_tmp112_); -#line 1908 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - iter = _tmp112_; -#line 1909 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp113_ = self->priv->paper_size_model; -#line 1909 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp114_ = iter; -#line 1909 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - gtk_list_store_set (_tmp113_, &_tmp114_, 0, 1016, 1, 1524, 2, "4×6", -1, -1); -#line 1911 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp115_ = self->priv->settings; -#line 1911 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp116_ = g_settings_get_int (_tmp115_, "text-dpi"); -#line 1911 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - dpi = _tmp116_; -#line 1912 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp117_ = dpi; -#line 1912 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - if (_tmp117_ <= 0) { -#line 1913 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - dpi = USER_INTERFACE_DEFAULT_TEXT_DPI; -#line 9757 "ui.c" - } -#line 1914 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp118_ = self->priv->text_dpi_combo; -#line 1914 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp119_ = dpi; -#line 1914 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - user_interface_set_dpi_combo (self, _tmp118_, USER_INTERFACE_DEFAULT_TEXT_DPI, _tmp119_); -#line 1915 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp120_ = self->priv->text_dpi_combo; -#line 1915 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - g_signal_connect_object (_tmp120_, "changed", (GCallback) ___lambda14__gtk_combo_box_changed, self, 0); -#line 1916 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp121_ = self->priv->settings; -#line 1916 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp122_ = g_settings_get_int (_tmp121_, "photo-dpi"); -#line 1916 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - dpi = _tmp122_; -#line 1917 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp123_ = dpi; -#line 1917 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - if (_tmp123_ <= 0) { -#line 1918 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - dpi = USER_INTERFACE_DEFAULT_PHOTO_DPI; -#line 9781 "ui.c" - } -#line 1919 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp124_ = self->priv->photo_dpi_combo; -#line 1919 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp125_ = dpi; -#line 1919 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - user_interface_set_dpi_combo (self, _tmp124_, USER_INTERFACE_DEFAULT_PHOTO_DPI, _tmp125_); -#line 1920 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp126_ = self->priv->photo_dpi_combo; -#line 1920 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - g_signal_connect_object (_tmp126_, "changed", (GCallback) ___lambda15__gtk_combo_box_changed, self, 0); -#line 1922 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp127_ = (GtkCellRendererText*) gtk_cell_renderer_text_new (); -#line 1922 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - g_object_ref_sink (_tmp127_); -#line 1922 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - renderer = _tmp127_; -#line 1923 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp128_ = self->priv->device_combo; -#line 1923 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp129_ = renderer; -#line 1923 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - gtk_cell_layout_pack_start ((GtkCellLayout*) _tmp128_, (GtkCellRenderer*) _tmp129_, TRUE); -#line 1924 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp130_ = self->priv->device_combo; -#line 1924 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp131_ = renderer; -#line 1924 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - gtk_cell_layout_add_attribute ((GtkCellLayout*) _tmp130_, (GtkCellRenderer*) _tmp131_, "text", 1); -#line 1926 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp132_ = (GtkCellRendererText*) gtk_cell_renderer_text_new (); -#line 1926 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - g_object_ref_sink (_tmp132_); -#line 1926 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _g_object_unref0 (renderer); -#line 1926 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - renderer = _tmp132_; -#line 1927 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp133_ = self->priv->page_side_combo; -#line 1927 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp134_ = renderer; -#line 1927 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - gtk_cell_layout_pack_start ((GtkCellLayout*) _tmp133_, (GtkCellRenderer*) _tmp134_, TRUE); -#line 1928 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp135_ = self->priv->page_side_combo; -#line 1928 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp136_ = renderer; -#line 1928 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - gtk_cell_layout_add_attribute ((GtkCellLayout*) _tmp135_, (GtkCellRenderer*) _tmp136_, "text", 1); -#line 1929 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp137_ = self->priv->settings; -#line 1929 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp138_ = g_settings_get_enum (_tmp137_, "page-side"); -#line 1929 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - user_interface_set_page_side (self, (ScanType) _tmp138_); -#line 1930 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp139_ = self->priv->page_side_combo; -#line 1930 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - g_signal_connect_object (_tmp139_, "changed", (GCallback) ___lambda16__gtk_combo_box_changed, self, 0); -#line 1932 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp140_ = (GtkCellRendererText*) gtk_cell_renderer_text_new (); -#line 1932 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - g_object_ref_sink (_tmp140_); -#line 1932 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _g_object_unref0 (renderer); -#line 1932 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - renderer = _tmp140_; -#line 1933 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp141_ = self->priv->paper_size_combo; -#line 1933 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp142_ = renderer; -#line 1933 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - gtk_cell_layout_pack_start ((GtkCellLayout*) _tmp141_, (GtkCellRenderer*) _tmp142_, TRUE); -#line 1934 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp143_ = self->priv->paper_size_combo; -#line 1934 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp144_ = renderer; -#line 1934 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - gtk_cell_layout_add_attribute ((GtkCellLayout*) _tmp143_, (GtkCellRenderer*) _tmp144_, "text", 2); -#line 1935 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp145_ = self->priv->settings; -#line 1935 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp146_ = g_settings_get_int (_tmp145_, "paper-width"); -#line 1935 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - paper_width = _tmp146_; -#line 1936 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp147_ = self->priv->settings; -#line 1936 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp148_ = g_settings_get_int (_tmp147_, "paper-height"); -#line 1936 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - paper_height = _tmp148_; -#line 1937 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp149_ = paper_width; -#line 1937 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp150_ = paper_height; -#line 1937 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - user_interface_set_paper_size (self, _tmp149_, _tmp150_); -#line 1938 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp151_ = self->priv->paper_size_combo; -#line 1938 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - g_signal_connect_object (_tmp151_, "changed", (GCallback) ___lambda17__gtk_combo_box_changed, self, 0); -#line 1946 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp152_ = self->priv->brightness_adjustment; -#line 1946 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp153_ = gtk_adjustment_get_lower (_tmp152_); -#line 1946 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp154_ = _tmp153_; -#line 1946 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - lower = _tmp154_; -#line 1947 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp155_ = _ ("Darker"); -#line 1947 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp156_ = g_strdup_printf ("%s", _tmp155_); -#line 1947 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - darker_label = _tmp156_; -#line 1948 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp157_ = self->priv->brightness_adjustment; -#line 1948 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp158_ = gtk_adjustment_get_upper (_tmp157_); -#line 1948 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp159_ = _tmp158_; -#line 1948 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - upper = _tmp159_; -#line 1949 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp160_ = _ ("Lighter"); -#line 1949 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp161_ = g_strdup_printf ("%s", _tmp160_); -#line 1949 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - lighter_label = _tmp161_; -#line 1950 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp162_ = self->priv->brightness_scale; -#line 1950 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp163_ = lower; -#line 1950 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp164_ = darker_label; -#line 1950 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - gtk_scale_add_mark (_tmp162_, _tmp163_, GTK_POS_BOTTOM, _tmp164_); -#line 1951 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp165_ = self->priv->brightness_scale; -#line 1951 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - gtk_scale_add_mark (_tmp165_, (gdouble) 0, GTK_POS_BOTTOM, NULL); -#line 1952 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp166_ = self->priv->brightness_scale; -#line 1952 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp167_ = upper; -#line 1952 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp168_ = lighter_label; -#line 1952 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - gtk_scale_add_mark (_tmp166_, _tmp167_, GTK_POS_BOTTOM, _tmp168_); -#line 1953 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp169_ = self->priv->settings; -#line 1953 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp170_ = g_settings_get_int (_tmp169_, "brightness"); -#line 1953 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - user_interface_set_brightness (self, _tmp170_); -#line 1954 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp171_ = self->priv->brightness_adjustment; -#line 1954 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - g_signal_connect_object (_tmp171_, "value-changed", (GCallback) ___lambda18__gtk_adjustment_value_changed, self, 0); -#line 1956 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp172_ = self->priv->contrast_adjustment; -#line 1956 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp173_ = gtk_adjustment_get_lower (_tmp172_); -#line 1956 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp174_ = _tmp173_; -#line 1956 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - lower = _tmp174_; -#line 1957 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp175_ = _ ("Less"); -#line 1957 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp176_ = g_strdup_printf ("%s", _tmp175_); -#line 1957 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - less_label = _tmp176_; -#line 1958 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp177_ = self->priv->contrast_adjustment; -#line 1958 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp178_ = gtk_adjustment_get_upper (_tmp177_); -#line 1958 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp179_ = _tmp178_; -#line 1958 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - upper = _tmp179_; -#line 1959 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp180_ = _ ("More"); -#line 1959 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp181_ = g_strdup_printf ("%s", _tmp180_); -#line 1959 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - more_label = _tmp181_; -#line 1960 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp182_ = self->priv->contrast_scale; -#line 1960 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp183_ = lower; -#line 1960 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp184_ = less_label; -#line 1960 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - gtk_scale_add_mark (_tmp182_, _tmp183_, GTK_POS_BOTTOM, _tmp184_); -#line 1961 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp185_ = self->priv->contrast_scale; -#line 1961 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - gtk_scale_add_mark (_tmp185_, (gdouble) 0, GTK_POS_BOTTOM, NULL); -#line 1962 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp186_ = self->priv->contrast_scale; -#line 1962 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp187_ = upper; -#line 1962 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp188_ = more_label; -#line 1962 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - gtk_scale_add_mark (_tmp186_, _tmp187_, GTK_POS_BOTTOM, _tmp188_); -#line 1963 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp189_ = self->priv->settings; -#line 1963 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp190_ = g_settings_get_int (_tmp189_, "contrast"); -#line 1963 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - user_interface_set_contrast (self, _tmp190_); -#line 1964 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp191_ = self->priv->contrast_adjustment; -#line 1964 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - g_signal_connect_object (_tmp191_, "value-changed", (GCallback) ___lambda19__gtk_adjustment_value_changed, self, 0); -#line 1966 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp192_ = self->priv->quality_adjustment; -#line 1966 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp193_ = gtk_adjustment_get_lower (_tmp192_); -#line 1966 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp194_ = _tmp193_; -#line 1966 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - lower = _tmp194_; -#line 1967 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp195_ = _ ("Minimum"); -#line 1967 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp196_ = g_strdup_printf ("%s", _tmp195_); -#line 1967 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - minimum_label = _tmp196_; -#line 1968 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp197_ = self->priv->quality_adjustment; -#line 1968 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp198_ = gtk_adjustment_get_upper (_tmp197_); -#line 1968 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp199_ = _tmp198_; -#line 1968 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - upper = _tmp199_; -#line 1969 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp200_ = _ ("Maximum"); -#line 1969 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp201_ = g_strdup_printf ("%s", _tmp200_); -#line 1969 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - maximum_label = _tmp201_; -#line 1970 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp202_ = self->priv->quality_scale; -#line 1970 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp203_ = lower; -#line 1970 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp204_ = minimum_label; -#line 1970 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - gtk_scale_add_mark (_tmp202_, _tmp203_, GTK_POS_BOTTOM, _tmp204_); -#line 1971 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp205_ = self->priv->quality_scale; -#line 1971 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - gtk_scale_add_mark (_tmp205_, (gdouble) 75, GTK_POS_BOTTOM, NULL); -#line 1972 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp206_ = self->priv->quality_scale; -#line 1972 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp207_ = upper; -#line 1972 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp208_ = maximum_label; -#line 1972 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - gtk_scale_add_mark (_tmp206_, _tmp207_, GTK_POS_BOTTOM, _tmp208_); -#line 1973 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp209_ = self->priv->settings; -#line 1973 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp210_ = g_settings_get_int (_tmp209_, "jpeg-quality"); -#line 1973 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - user_interface_set_quality (self, _tmp210_); -#line 1974 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp211_ = self->priv->quality_adjustment; -#line 1974 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - g_signal_connect_object (_tmp211_, "value-changed", (GCallback) ___lambda20__gtk_adjustment_value_changed, self, 0); -#line 1976 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp212_ = self->priv->settings; -#line 1976 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp213_ = g_settings_get_string (_tmp212_, "document-type"); -#line 1976 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - document_type = _tmp213_; -#line 1977 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp214_ = document_type; -#line 1977 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - if (_tmp214_ != NULL) { -#line 10067 "ui.c" - const gchar* _tmp215_ = NULL; -#line 1978 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp215_ = document_type; -#line 1978 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - user_interface_set_document_hint (self, _tmp215_, FALSE); -#line 10073 "ui.c" - } -#line 1980 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp216_ = self->priv->_book; -#line 1980 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp217_ = book_view_new (_tmp216_); -#line 1980 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - g_object_ref_sink (_tmp217_); -#line 1980 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _g_object_unref0 (self->priv->book_view); -#line 1980 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - self->priv->book_view = _tmp217_; -#line 1981 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp218_ = self->priv->book_view; -#line 1981 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - gtk_container_set_border_width ((GtkContainer*) _tmp218_, (guint) 18); -#line 1982 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp219_ = self->priv->main_vbox; -#line 1982 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp220_ = self->priv->book_view; -#line 1982 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - gtk_box_pack_end (_tmp219_, (GtkWidget*) _tmp220_, TRUE, TRUE, (guint) 0); -#line 1983 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp221_ = self->priv->book_view; -#line 1983 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - g_signal_connect_object (_tmp221_, "page-selected", (GCallback) _user_interface_page_selected_cb_book_view_page_selected, self, 0); -#line 1984 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp222_ = self->priv->book_view; -#line 1984 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - g_signal_connect_object (_tmp222_, "show-page", (GCallback) _user_interface_show_page_cb_book_view_show_page, self, 0); -#line 1985 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp223_ = self->priv->book_view; -#line 1985 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - g_signal_connect_object (_tmp223_, "show-menu", (GCallback) _user_interface_show_page_menu_cb_book_view_show_menu, self, 0); -#line 1986 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp224_ = self->priv->book_view; -#line 1986 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - gtk_widget_set_visible ((GtkWidget*) _tmp224_, TRUE); -#line 1988 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp225_ = self->priv->authorize_dialog; -#line 1988 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - gtk_window_set_transient_for ((GtkWindow*) _tmp225_, (GtkWindow*) self); -#line 1989 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp226_ = self->priv->preferences_dialog; -#line 1989 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - gtk_window_set_transient_for ((GtkWindow*) _tmp226_, (GtkWindow*) self); -#line 1992 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - user_interface_load_state (self); -#line 1995 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp227_ = self->priv->window_width; -#line 1995 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp228_ = self->priv->window_height; -#line 1995 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - g_debug ("ui.vala:1995: Restoring window to %dx%d pixels", _tmp227_, _tmp228_); -#line 1996 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp229_ = self->priv->window_width; -#line 1996 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp230_ = self->priv->window_height; -#line 1996 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - gtk_window_set_default_size ((GtkWindow*) self, _tmp229_, _tmp230_); -#line 1997 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp231_ = self->priv->window_is_maximized; -#line 1997 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - if (_tmp231_) { -#line 1999 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - g_debug ("ui.vala:1999: Restoring window to maximized"); -#line 2000 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - gtk_window_maximize ((GtkWindow*) self); -#line 10141 "ui.c" - } -#line 2002 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp232_ = self->priv->window_is_fullscreen; -#line 2002 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - if (_tmp232_) { -#line 2004 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - g_debug ("ui.vala:2004: Restoring window to fullscreen"); -#line 2005 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - gtk_window_fullscreen ((GtkWindow*) self); -#line 10151 "ui.c" - } -#line 2008 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp233_ = _ ("Saving document..."); -#line 2008 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp234_ = progress_bar_dialog_new ((GtkApplicationWindow*) self, _tmp233_); -#line 2008 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - g_object_ref_sink (_tmp234_); -#line 2008 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _g_object_unref0 (self->priv->progress_dialog); -#line 2008 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - self->priv->progress_dialog = _tmp234_; -#line 2009 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp235_ = self->priv->_book; -#line 2009 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - g_signal_connect_object (_tmp235_, "saving", (GCallback) _user_interface_book_saving_cb_book_saving, self, 0); -#line 1814 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _g_free0 (document_type); -#line 1814 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _g_free0 (maximum_label); -#line 1814 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _g_free0 (minimum_label); -#line 1814 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _g_free0 (more_label); -#line 1814 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _g_free0 (less_label); -#line 1814 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _g_free0 (lighter_label); -#line 1814 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _g_free0 (darker_label); -#line 1814 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _g_object_unref0 (renderer); -#line 1814 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _g_object_unref0 (content_area); -#line 1814 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _g_object_unref0 (hbox); -#line 1814 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _g_object_unref0 (app); -#line 10189 "ui.c" -} - - -static gboolean user_interface_is_desktop (UserInterface* self, const gchar* name) { - gboolean result = FALSE; - gchar* desktop_name_list = NULL; - const gchar* _tmp0_ = NULL; - gchar* _tmp1_ = NULL; - const gchar* _tmp2_ = NULL; - const gchar* _tmp3_ = NULL; - gchar** _tmp4_ = NULL; - gchar** _tmp5_ = NULL; -#line 2012 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - g_return_val_if_fail (self != NULL, FALSE); -#line 2012 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - g_return_val_if_fail (name != NULL, FALSE); -#line 2014 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp0_ = g_getenv ("XDG_CURRENT_DESKTOP"); -#line 2014 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp1_ = g_strdup (_tmp0_); -#line 2014 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - desktop_name_list = _tmp1_; -#line 2015 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp2_ = desktop_name_list; -#line 2015 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - if (_tmp2_ == NULL) { -#line 2016 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - result = FALSE; -#line 2016 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _g_free0 (desktop_name_list); -#line 2016 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - return result; -#line 10222 "ui.c" - } -#line 2018 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp3_ = desktop_name_list; -#line 2018 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp5_ = _tmp4_ = g_strsplit (_tmp3_, ":", 0); -#line 10228 "ui.c" - { - gchar** n_collection = NULL; - gint n_collection_length1 = 0; - gint _n_collection_size_ = 0; - gint n_it = 0; -#line 2018 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - n_collection = _tmp5_; -#line 2018 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - n_collection_length1 = _vala_array_length (_tmp4_); -#line 2018 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - for (n_it = 0; n_it < _vala_array_length (_tmp4_); n_it = n_it + 1) { -#line 10240 "ui.c" - gchar* _tmp6_ = NULL; - gchar* n = NULL; -#line 2018 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp6_ = g_strdup (n_collection[n_it]); -#line 2018 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - n = _tmp6_; -#line 10247 "ui.c" - { - const gchar* _tmp7_ = NULL; - const gchar* _tmp8_ = NULL; -#line 2019 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp7_ = n; -#line 2019 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp8_ = name; -#line 2019 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - if (g_strcmp0 (_tmp7_, _tmp8_) == 0) { -#line 2020 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - result = TRUE; -#line 2020 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _g_free0 (n); -#line 2020 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - n_collection = (_vala_array_free (n_collection, n_collection_length1, (GDestroyNotify) g_free), NULL); -#line 2020 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _g_free0 (desktop_name_list); -#line 2020 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - return result; -#line 10267 "ui.c" - } -#line 2018 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _g_free0 (n); -#line 10271 "ui.c" - } - } -#line 2018 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - n_collection = (_vala_array_free (n_collection, n_collection_length1, (GDestroyNotify) g_free), NULL); -#line 10276 "ui.c" - } -#line 2022 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - result = FALSE; -#line 2022 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _g_free0 (desktop_name_list); -#line 2022 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - return result; -#line 10284 "ui.c" -} - - -static gboolean user_interface_is_traditional_desktop (UserInterface* self) { - gboolean result = FALSE; -#line 2027 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - static const gchar* traditional_desktops[] = {"Unity", "XFCE", "MATE", "LXDE", "Cinnamon", "X-Cinnamon"}; -#line 2025 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - g_return_val_if_fail (self != NULL, FALSE); -#line 10294 "ui.c" - { - const gchar** name_collection = NULL; - gint name_collection_length1 = 0; - gint _name_collection_size_ = 0; - gint name_it = 0; -#line 2028 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - name_collection = traditional_desktops; -#line 2028 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - name_collection_length1 = G_N_ELEMENTS (traditional_desktops); -#line 2028 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - for (name_it = 0; name_it < G_N_ELEMENTS (traditional_desktops); name_it = name_it + 1) { -#line 10306 "ui.c" - const gchar* name = NULL; -#line 2028 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - name = name_collection[name_it]; -#line 10310 "ui.c" - { - const gchar* _tmp0_ = NULL; - gboolean _tmp1_ = FALSE; -#line 2029 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp0_ = name; -#line 2029 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp1_ = user_interface_is_desktop (self, _tmp0_); -#line 2029 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - if (_tmp1_) { -#line 2030 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - result = TRUE; -#line 2030 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - return result; -#line 10324 "ui.c" - } - } - } - } -#line 2031 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - result = FALSE; -#line 2031 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - return result; -#line 10333 "ui.c" -} - - -static void user_interface_load_state (UserInterface* self) { - gchar* _tmp0_ = NULL; - gchar* _tmp1_ = NULL; - gchar* _tmp2_ = NULL; - GKeyFile* f = NULL; - GKeyFile* _tmp3_ = NULL; - GKeyFile* _tmp11_ = NULL; - gint _tmp12_ = 0; - gint _tmp13_ = 0; - GKeyFile* _tmp14_ = NULL; - gint _tmp15_ = 0; - gint _tmp16_ = 0; - GKeyFile* _tmp17_ = NULL; - gboolean _tmp18_ = FALSE; - GKeyFile* _tmp19_ = NULL; - gboolean _tmp20_ = FALSE; - GKeyFile* _tmp21_ = NULL; - gint _tmp22_ = 0; - GKeyFile* _tmp23_ = NULL; - gint _tmp24_ = 0; - GKeyFile* _tmp25_ = NULL; - gint _tmp26_ = 0; - GKeyFile* _tmp27_ = NULL; - gchar* _tmp28_ = NULL; - gchar* _tmp29_ = NULL; - GQuark _tmp31_ = 0U; -#line 2064 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - static GQuark _tmp30_label0 = 0; -#line 2064 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - static GQuark _tmp30_label1 = 0; -#line 2064 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - static GQuark _tmp30_label2 = 0; -#line 10369 "ui.c" - GError * _inner_error_ = NULL; -#line 2039 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - g_return_if_fail (self != NULL); -#line 2041 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp0_ = user_interface_get_state_filename (self); -#line 2041 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp1_ = _tmp0_; -#line 2041 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp2_ = _tmp1_; -#line 2041 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - g_debug ("ui.vala:2041: Loading state from %s", _tmp2_); -#line 2041 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _g_free0 (_tmp2_); -#line 2043 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp3_ = g_key_file_new (); -#line 2043 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - f = _tmp3_; -#line 10387 "ui.c" - { - GKeyFile* _tmp4_ = NULL; - gchar* _tmp5_ = NULL; - gchar* _tmp6_ = NULL; - gchar* _tmp7_ = NULL; -#line 2046 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp4_ = f; -#line 2046 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp5_ = user_interface_get_state_filename (self); -#line 2046 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp6_ = _tmp5_; -#line 2046 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp7_ = _tmp6_; -#line 2046 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - g_key_file_load_from_file (_tmp4_, _tmp7_, G_KEY_FILE_NONE, &_inner_error_); -#line 2046 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _g_free0 (_tmp7_); -#line 2046 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - if (G_UNLIKELY (_inner_error_ != NULL)) { -#line 10407 "ui.c" - goto __catch23_g_error; - } - } - goto __finally23; - __catch23_g_error: - { - GError* e = NULL; - GError* _tmp8_ = NULL; -#line 2044 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - e = _inner_error_; -#line 2044 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _inner_error_ = NULL; -#line 2050 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp8_ = e; -#line 2050 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - if (!g_error_matches (_tmp8_, G_FILE_ERROR, G_FILE_ERROR_NOENT)) { -#line 10424 "ui.c" - GError* _tmp9_ = NULL; - const gchar* _tmp10_ = NULL; -#line 2051 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp9_ = e; -#line 2051 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp10_ = _tmp9_->message; -#line 2051 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - g_warning ("ui.vala:2051: Failed to load state: %s", _tmp10_); -#line 10433 "ui.c" - } -#line 2044 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _g_error_free0 (e); -#line 10437 "ui.c" - } - __finally23: -#line 2044 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - if (G_UNLIKELY (_inner_error_ != NULL)) { -#line 2044 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _g_key_file_unref0 (f); -#line 2044 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - g_critical ("file %s: line %d: uncaught error: %s (%s, %d)", __FILE__, __LINE__, _inner_error_->message, g_quark_to_string (_inner_error_->domain), _inner_error_->code); -#line 2044 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - g_clear_error (&_inner_error_); -#line 2044 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - return; -#line 10450 "ui.c" - } -#line 2053 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp11_ = f; -#line 2053 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp12_ = user_interface_state_get_integer (self, _tmp11_, "window", "width", 600); -#line 2053 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - self->priv->window_width = _tmp12_; -#line 2054 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp13_ = self->priv->window_width; -#line 2054 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - if (_tmp13_ <= 0) { -#line 2055 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - self->priv->window_width = 600; -#line 10464 "ui.c" - } -#line 2056 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp14_ = f; -#line 2056 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp15_ = user_interface_state_get_integer (self, _tmp14_, "window", "height", 400); -#line 2056 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - self->priv->window_height = _tmp15_; -#line 2057 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp16_ = self->priv->window_height; -#line 2057 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - if (_tmp16_ <= 0) { -#line 2058 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - self->priv->window_height = 400; -#line 10478 "ui.c" - } -#line 2059 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp17_ = f; -#line 2059 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp18_ = user_interface_state_get_boolean (self, _tmp17_, "window", "is-maximized", FALSE); -#line 2059 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - self->priv->window_is_maximized = _tmp18_; -#line 2060 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp19_ = f; -#line 2060 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp20_ = user_interface_state_get_boolean (self, _tmp19_, "window", "is-fullscreen", FALSE); -#line 2060 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - self->priv->window_is_fullscreen = _tmp20_; -#line 2061 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp21_ = f; -#line 2061 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp22_ = user_interface_state_get_integer (self, _tmp21_, "last-page", "width", 595); -#line 2061 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - self->priv->default_page_width = _tmp22_; -#line 2062 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp23_ = f; -#line 2062 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp24_ = user_interface_state_get_integer (self, _tmp23_, "last-page", "height", 842); -#line 2062 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - self->priv->default_page_height = _tmp24_; -#line 2063 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp25_ = f; -#line 2063 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp26_ = user_interface_state_get_integer (self, _tmp25_, "last-page", "dpi", 72); -#line 2063 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - self->priv->default_page_dpi = _tmp26_; -#line 2064 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp27_ = f; -#line 2064 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp28_ = user_interface_state_get_string (self, _tmp27_, "last-page", "scan-direction", "top-to-bottom"); -#line 2064 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp29_ = _tmp28_; -#line 2064 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp31_ = (NULL == _tmp29_) ? 0 : g_quark_from_string (_tmp29_); -#line 2064 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - g_free (_tmp29_); -#line 2064 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - if (_tmp31_ == ((0 != _tmp30_label0) ? _tmp30_label0 : (_tmp30_label0 = g_quark_from_static_string ("bottom-to-top")))) { -#line 2064 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - switch (0) { -#line 10524 "ui.c" - default: - { -#line 2071 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - self->priv->default_page_scan_direction = SCAN_DIRECTION_BOTTOM_TO_TOP; -#line 2072 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - break; -#line 10531 "ui.c" - } - } - } else if (_tmp31_ == ((0 != _tmp30_label1) ? _tmp30_label1 : (_tmp30_label1 = g_quark_from_static_string ("left-to-right")))) { -#line 2064 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - switch (0) { -#line 10537 "ui.c" - default: - { -#line 2074 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - self->priv->default_page_scan_direction = SCAN_DIRECTION_LEFT_TO_RIGHT; -#line 2075 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - break; -#line 10544 "ui.c" - } - } - } else if (_tmp31_ == ((0 != _tmp30_label2) ? _tmp30_label2 : (_tmp30_label2 = g_quark_from_static_string ("right-to-left")))) { -#line 2064 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - switch (0) { -#line 10550 "ui.c" - default: - { -#line 2077 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - self->priv->default_page_scan_direction = SCAN_DIRECTION_RIGHT_TO_LEFT; -#line 2078 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - break; -#line 10557 "ui.c" - } - } - } else { -#line 2064 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - switch (0) { -#line 10563 "ui.c" - default: - { -#line 2068 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - self->priv->default_page_scan_direction = SCAN_DIRECTION_TOP_TO_BOTTOM; -#line 2069 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - break; -#line 10570 "ui.c" - } - } - } -#line 2039 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _g_key_file_unref0 (f); -#line 10576 "ui.c" -} - - -static gint user_interface_state_get_integer (UserInterface* self, GKeyFile* f, const gchar* group_name, const gchar* key, gint _default_) { - gint result = 0; - gint _tmp6_ = 0; - GError * _inner_error_ = NULL; -#line 2082 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - g_return_val_if_fail (self != NULL, 0); -#line 2082 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - g_return_val_if_fail (f != NULL, 0); -#line 2082 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - g_return_val_if_fail (group_name != NULL, 0); -#line 2082 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - g_return_val_if_fail (key != NULL, 0); -#line 10592 "ui.c" - { - gint _tmp0_ = 0; - GKeyFile* _tmp1_ = NULL; - const gchar* _tmp2_ = NULL; - const gchar* _tmp3_ = NULL; - gint _tmp4_ = 0; -#line 2086 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp1_ = f; -#line 2086 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp2_ = group_name; -#line 2086 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp3_ = key; -#line 2086 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp4_ = g_key_file_get_integer (_tmp1_, _tmp2_, _tmp3_, &_inner_error_); -#line 2086 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp0_ = _tmp4_; -#line 2086 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - if (G_UNLIKELY (_inner_error_ != NULL)) { -#line 10611 "ui.c" - goto __catch24_g_error; - } -#line 2086 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - result = _tmp0_; -#line 2086 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - return result; -#line 10618 "ui.c" - } - goto __finally24; - __catch24_g_error: - { - gint _tmp5_ = 0; -#line 2084 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - g_clear_error (&_inner_error_); -#line 2084 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _inner_error_ = NULL; -#line 2090 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp5_ = _default_; -#line 2090 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - result = _tmp5_; -#line 2090 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - return result; -#line 10634 "ui.c" - } - __finally24: -#line 2084 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - g_critical ("file %s: line %d: uncaught error: %s (%s, %d)", __FILE__, __LINE__, _inner_error_->message, g_quark_to_string (_inner_error_->domain), _inner_error_->code); -#line 2084 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - g_clear_error (&_inner_error_); -#line 2084 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - return _tmp6_; -#line 10643 "ui.c" -} - - -static gboolean user_interface_state_get_boolean (UserInterface* self, GKeyFile* f, const gchar* group_name, const gchar* key, gboolean _default_) { - gboolean result = FALSE; - gboolean _tmp6_ = FALSE; - GError * _inner_error_ = NULL; -#line 2094 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - g_return_val_if_fail (self != NULL, FALSE); -#line 2094 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - g_return_val_if_fail (f != NULL, FALSE); -#line 2094 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - g_return_val_if_fail (group_name != NULL, FALSE); -#line 2094 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - g_return_val_if_fail (key != NULL, FALSE); -#line 10659 "ui.c" - { - gboolean _tmp0_ = FALSE; - GKeyFile* _tmp1_ = NULL; - const gchar* _tmp2_ = NULL; - const gchar* _tmp3_ = NULL; - gboolean _tmp4_ = FALSE; -#line 2098 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp1_ = f; -#line 2098 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp2_ = group_name; -#line 2098 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp3_ = key; -#line 2098 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp4_ = g_key_file_get_boolean (_tmp1_, _tmp2_, _tmp3_, &_inner_error_); -#line 2098 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp0_ = _tmp4_; -#line 2098 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - if (G_UNLIKELY (_inner_error_ != NULL)) { -#line 10678 "ui.c" - goto __catch25_g_error; - } -#line 2098 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - result = _tmp0_; -#line 2098 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - return result; -#line 10685 "ui.c" - } - goto __finally25; - __catch25_g_error: - { - gboolean _tmp5_ = FALSE; -#line 2096 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - g_clear_error (&_inner_error_); -#line 2096 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _inner_error_ = NULL; -#line 2102 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp5_ = _default_; -#line 2102 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - result = _tmp5_; -#line 2102 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - return result; -#line 10701 "ui.c" - } - __finally25: -#line 2096 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - g_critical ("file %s: line %d: uncaught error: %s (%s, %d)", __FILE__, __LINE__, _inner_error_->message, g_quark_to_string (_inner_error_->domain), _inner_error_->code); -#line 2096 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - g_clear_error (&_inner_error_); -#line 2096 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - return _tmp6_; -#line 10710 "ui.c" -} - - -static gchar* user_interface_state_get_string (UserInterface* self, GKeyFile* f, const gchar* group_name, const gchar* key, const gchar* _default_) { - gchar* result = NULL; - GError * _inner_error_ = NULL; -#line 2106 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - g_return_val_if_fail (self != NULL, NULL); -#line 2106 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - g_return_val_if_fail (f != NULL, NULL); -#line 2106 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - g_return_val_if_fail (group_name != NULL, NULL); -#line 2106 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - g_return_val_if_fail (key != NULL, NULL); -#line 2106 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - g_return_val_if_fail (_default_ != NULL, NULL); -#line 10727 "ui.c" - { - gchar* _tmp0_ = NULL; - GKeyFile* _tmp1_ = NULL; - const gchar* _tmp2_ = NULL; - const gchar* _tmp3_ = NULL; - gchar* _tmp4_ = NULL; - gchar* _tmp5_ = NULL; -#line 2110 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp1_ = f; -#line 2110 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp2_ = group_name; -#line 2110 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp3_ = key; -#line 2110 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp4_ = g_key_file_get_string (_tmp1_, _tmp2_, _tmp3_, &_inner_error_); -#line 2110 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp0_ = _tmp4_; -#line 2110 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - if (G_UNLIKELY (_inner_error_ != NULL)) { -#line 10747 "ui.c" - goto __catch26_g_error; - } -#line 2110 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp5_ = _tmp0_; -#line 2110 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp0_ = NULL; -#line 2110 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - result = _tmp5_; -#line 2110 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _g_free0 (_tmp0_); -#line 2110 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - return result; -#line 10760 "ui.c" - } - goto __finally26; - __catch26_g_error: - { - const gchar* _tmp6_ = NULL; - gchar* _tmp7_ = NULL; -#line 2108 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - g_clear_error (&_inner_error_); -#line 2108 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _inner_error_ = NULL; -#line 2114 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp6_ = _default_; -#line 2114 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp7_ = g_strdup (_tmp6_); -#line 2114 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - result = _tmp7_; -#line 2114 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - return result; -#line 10779 "ui.c" - } - __finally26: -#line 2108 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - g_critical ("file %s: line %d: uncaught error: %s (%s, %d)", __FILE__, __LINE__, _inner_error_->message, g_quark_to_string (_inner_error_->domain), _inner_error_->code); -#line 2108 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - g_clear_error (&_inner_error_); -#line 2108 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - return NULL; -#line 10788 "ui.c" -} - - -static gboolean ___lambda11_ (UserInterface* self) { - gboolean result = FALSE; -#line 2126 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - user_interface_save_state (self, TRUE); -#line 2127 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - self->priv->save_state_timeout = (guint) 0; -#line 2128 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - result = FALSE; -#line 2128 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - return result; -#line 10802 "ui.c" -} - - -static gboolean ____lambda11__gsource_func (gpointer self) { - gboolean result; - result = ___lambda11_ ((UserInterface*) self); -#line 2124 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - return result; -#line 10811 "ui.c" -} - - -static void user_interface_save_state (UserInterface* self, gboolean force) { - gboolean _tmp0_ = FALSE; - gchar* _tmp4_ = NULL; - gchar* _tmp5_ = NULL; - gchar* _tmp6_ = NULL; - GKeyFile* f = NULL; - GKeyFile* _tmp7_ = NULL; - GKeyFile* _tmp8_ = NULL; - gint _tmp9_ = 0; - GKeyFile* _tmp10_ = NULL; - gint _tmp11_ = 0; - GKeyFile* _tmp12_ = NULL; - gboolean _tmp13_ = FALSE; - GKeyFile* _tmp14_ = NULL; - gboolean _tmp15_ = FALSE; - GKeyFile* _tmp16_ = NULL; - gint _tmp17_ = 0; - GKeyFile* _tmp18_ = NULL; - gint _tmp19_ = 0; - GKeyFile* _tmp20_ = NULL; - gint _tmp21_ = 0; - ScanDirection _tmp22_ = 0; - GError * _inner_error_ = NULL; -#line 2118 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - g_return_if_fail (self != NULL); -#line 2120 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp0_ = force; -#line 2120 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - if (!_tmp0_) { -#line 10844 "ui.c" - guint _tmp1_ = 0U; - guint _tmp3_ = 0U; -#line 2122 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp1_ = self->priv->save_state_timeout; -#line 2122 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - if (_tmp1_ != ((guint) 0)) { -#line 10851 "ui.c" - guint _tmp2_ = 0U; -#line 2123 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp2_ = self->priv->save_state_timeout; -#line 2123 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - g_source_remove (_tmp2_); -#line 10857 "ui.c" - } -#line 2124 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp3_ = g_timeout_add_full (G_PRIORITY_DEFAULT, (guint) 100, ____lambda11__gsource_func, g_object_ref (self), g_object_unref); -#line 2124 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - self->priv->save_state_timeout = _tmp3_; -#line 2130 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - return; -#line 10865 "ui.c" - } -#line 2133 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp4_ = user_interface_get_state_filename (self); -#line 2133 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp5_ = _tmp4_; -#line 2133 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp6_ = _tmp5_; -#line 2133 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - g_debug ("ui.vala:2133: Saving state to %s", _tmp6_); -#line 2133 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _g_free0 (_tmp6_); -#line 2135 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp7_ = g_key_file_new (); -#line 2135 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - f = _tmp7_; -#line 2136 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp8_ = f; -#line 2136 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp9_ = self->priv->window_width; -#line 2136 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - g_key_file_set_integer (_tmp8_, "window", "width", _tmp9_); -#line 2137 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp10_ = f; -#line 2137 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp11_ = self->priv->window_height; -#line 2137 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - g_key_file_set_integer (_tmp10_, "window", "height", _tmp11_); -#line 2138 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp12_ = f; -#line 2138 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp13_ = self->priv->window_is_maximized; -#line 2138 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - g_key_file_set_boolean (_tmp12_, "window", "is-maximized", _tmp13_); -#line 2139 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp14_ = f; -#line 2139 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp15_ = self->priv->window_is_fullscreen; -#line 2139 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - g_key_file_set_boolean (_tmp14_, "window", "is-fullscreen", _tmp15_); -#line 2140 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp16_ = f; -#line 2140 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp17_ = self->priv->default_page_width; -#line 2140 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - g_key_file_set_integer (_tmp16_, "last-page", "width", _tmp17_); -#line 2141 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp18_ = f; -#line 2141 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp19_ = self->priv->default_page_height; -#line 2141 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - g_key_file_set_integer (_tmp18_, "last-page", "height", _tmp19_); -#line 2142 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp20_ = f; -#line 2142 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp21_ = self->priv->default_page_dpi; -#line 2142 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - g_key_file_set_integer (_tmp20_, "last-page", "dpi", _tmp21_); -#line 2143 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp22_ = self->priv->default_page_scan_direction; -#line 2143 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - switch (_tmp22_) { -#line 2143 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - case SCAN_DIRECTION_TOP_TO_BOTTOM: -#line 10929 "ui.c" - { - GKeyFile* _tmp23_ = NULL; -#line 2146 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp23_ = f; -#line 2146 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - g_key_file_set_value (_tmp23_, "last-page", "scan-direction", "top-to-bottom"); -#line 2147 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - break; -#line 10938 "ui.c" - } -#line 2143 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - case SCAN_DIRECTION_BOTTOM_TO_TOP: -#line 10942 "ui.c" - { - GKeyFile* _tmp24_ = NULL; -#line 2149 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp24_ = f; -#line 2149 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - g_key_file_set_value (_tmp24_, "last-page", "scan-direction", "bottom-to-top"); -#line 2150 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - break; -#line 10951 "ui.c" - } -#line 2143 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - case SCAN_DIRECTION_LEFT_TO_RIGHT: -#line 10955 "ui.c" - { - GKeyFile* _tmp25_ = NULL; -#line 2152 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp25_ = f; -#line 2152 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - g_key_file_set_value (_tmp25_, "last-page", "scan-direction", "left-to-right"); -#line 2153 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - break; -#line 10964 "ui.c" - } -#line 2143 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - case SCAN_DIRECTION_RIGHT_TO_LEFT: -#line 10968 "ui.c" - { - GKeyFile* _tmp26_ = NULL; -#line 2155 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp26_ = f; -#line 2155 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - g_key_file_set_value (_tmp26_, "last-page", "scan-direction", "right-to-left"); -#line 2156 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - break; -#line 10977 "ui.c" - } - default: -#line 2143 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - break; -#line 10982 "ui.c" - } - { - gchar* _tmp27_ = NULL; - gchar* _tmp28_ = NULL; - gchar* _tmp29_ = NULL; - GKeyFile* _tmp30_ = NULL; - gchar* _tmp31_ = NULL; - gchar* _tmp32_ = NULL; -#line 2160 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp27_ = user_interface_get_state_filename (self); -#line 2160 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp28_ = _tmp27_; -#line 2160 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp29_ = _tmp28_; -#line 2160 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp30_ = f; -#line 2160 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp31_ = g_key_file_to_data (_tmp30_, NULL, NULL); -#line 2160 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp32_ = _tmp31_; -#line 2160 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - g_file_set_contents (_tmp29_, _tmp32_, (gssize) -1, &_inner_error_); -#line 2160 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _g_free0 (_tmp32_); -#line 2160 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _g_free0 (_tmp29_); -#line 2160 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - if (G_UNLIKELY (_inner_error_ != NULL)) { -#line 11011 "ui.c" - goto __catch27_g_error; - } - } - goto __finally27; - __catch27_g_error: - { - GError* e = NULL; - GError* _tmp33_ = NULL; - const gchar* _tmp34_ = NULL; -#line 2158 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - e = _inner_error_; -#line 2158 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _inner_error_ = NULL; -#line 2164 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp33_ = e; -#line 2164 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp34_ = _tmp33_->message; -#line 2164 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - g_warning ("ui.vala:2164: Failed to write state: %s", _tmp34_); -#line 2158 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _g_error_free0 (e); -#line 11033 "ui.c" - } - __finally27: -#line 2158 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - if (G_UNLIKELY (_inner_error_ != NULL)) { -#line 2158 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _g_key_file_unref0 (f); -#line 2158 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - g_critical ("file %s: line %d: uncaught error: %s (%s, %d)", __FILE__, __LINE__, _inner_error_->message, g_quark_to_string (_inner_error_->domain), _inner_error_->code); -#line 2158 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - g_clear_error (&_inner_error_); -#line 2158 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - return; -#line 11046 "ui.c" - } -#line 2118 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _g_key_file_unref0 (f); -#line 11050 "ui.c" -} - - -static gboolean ___lambda21_ (UserInterface* self) { - gboolean result = FALSE; - ProgressBarDialog* _tmp0_ = NULL; -#line 2179 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp0_ = self->priv->progress_dialog; -#line 2179 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - gtk_widget_set_visible ((GtkWidget*) _tmp0_, FALSE); -#line 2180 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - result = FALSE; -#line 2180 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - return result; -#line 11065 "ui.c" -} - - -static gboolean ____lambda21__gsource_func (gpointer self) { - gboolean result; - result = ___lambda21_ ((UserInterface*) self); -#line 2178 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - return result; -#line 11074 "ui.c" -} - - -static void user_interface_book_saving_cb (UserInterface* self, gint page_number) { - gint total = 0; - Book* _tmp1_ = NULL; - guint _tmp2_ = 0U; - guint _tmp3_ = 0U; - gdouble fraction = 0.0; - gint _tmp4_ = 0; - gint _tmp5_ = 0; - gboolean complete = FALSE; - gdouble _tmp6_ = 0.0; - gboolean _tmp7_ = FALSE; - gchar* message = NULL; - const gchar* _tmp8_ = NULL; - gint _tmp9_ = 0; - gint _tmp10_ = 0; - gchar* _tmp11_ = NULL; - ProgressBarDialog* _tmp12_ = NULL; - gdouble _tmp13_ = 0.0; - ProgressBarDialog* _tmp14_ = NULL; -#line 2168 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - g_return_if_fail (self != NULL); -#line 2171 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - while (TRUE) { -#line 11101 "ui.c" - gboolean _tmp0_ = FALSE; -#line 2171 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp0_ = gtk_events_pending (); -#line 2171 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - if (!_tmp0_) { -#line 2171 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - break; -#line 11109 "ui.c" - } -#line 2172 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - gtk_main_iteration (); -#line 11113 "ui.c" - } -#line 2174 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp1_ = self->priv->_book; -#line 2174 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp2_ = book_get_n_pages (_tmp1_); -#line 2174 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp3_ = _tmp2_; -#line 2174 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - total = (gint) _tmp3_; -#line 2175 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp4_ = page_number; -#line 2175 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp5_ = total; -#line 2175 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - fraction = (_tmp4_ + 1.0) / _tmp5_; -#line 2176 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp6_ = fraction; -#line 2176 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - complete = _tmp6_ == 1.0; -#line 2177 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp7_ = complete; -#line 2177 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - if (_tmp7_) { -#line 2178 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - g_timeout_add_full (G_PRIORITY_DEFAULT, (guint) 500, ____lambda21__gsource_func, g_object_ref (self), g_object_unref); -#line 11139 "ui.c" - } -#line 2182 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp8_ = _ ("Saving page %d out of %d"); -#line 2182 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp9_ = page_number; -#line 2182 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp10_ = total; -#line 2182 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp11_ = g_strdup_printf (_tmp8_, _tmp9_ + 1, _tmp10_); -#line 2182 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - message = _tmp11_; -#line 2184 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp12_ = self->priv->progress_dialog; -#line 2184 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp13_ = fraction; -#line 2184 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - progress_bar_dialog_set_fraction (_tmp12_, _tmp13_); -#line 2185 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp14_ = self->priv->progress_dialog; -#line 2185 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - progress_bar_dialog_set_message (_tmp14_, message); -#line 2168 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _g_free0 (message); -#line 11163 "ui.c" -} - - -void user_interface_show_progress_dialog (UserInterface* self) { - ProgressBarDialog* _tmp0_ = NULL; -#line 2188 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - g_return_if_fail (self != NULL); -#line 2190 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp0_ = self->priv->progress_dialog; -#line 2190 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - gtk_widget_set_visible ((GtkWidget*) _tmp0_, TRUE); -#line 11175 "ui.c" -} - - -void user_interface_hide_progress_dialog (UserInterface* self) { - ProgressBarDialog* _tmp0_ = NULL; -#line 2193 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - g_return_if_fail (self != NULL); -#line 2195 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp0_ = self->priv->progress_dialog; -#line 2195 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - gtk_widget_set_visible ((GtkWidget*) _tmp0_, FALSE); -#line 11187 "ui.c" -} - - -void user_interface_show_error (UserInterface* self, const gchar* error_title, const gchar* error_text, gboolean change_scanner_hint) { - const gchar* _tmp0_ = NULL; - gchar* _tmp1_ = NULL; - const gchar* _tmp2_ = NULL; - gchar* _tmp3_ = NULL; - gboolean _tmp4_ = FALSE; -#line 2198 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - g_return_if_fail (self != NULL); -#line 2198 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - g_return_if_fail (error_title != NULL); -#line 2198 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - g_return_if_fail (error_text != NULL); -#line 2200 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - self->priv->have_error = TRUE; -#line 2201 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp0_ = error_title; -#line 2201 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp1_ = g_strdup (_tmp0_); -#line 2201 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _g_free0 (self->priv->error_title); -#line 2201 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - self->priv->error_title = _tmp1_; -#line 2202 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp2_ = error_text; -#line 2202 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp3_ = g_strdup (_tmp2_); -#line 2202 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _g_free0 (self->priv->error_text); -#line 2202 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - self->priv->error_text = _tmp3_; -#line 2203 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp4_ = change_scanner_hint; -#line 2203 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - self->priv->error_change_scanner_hint = _tmp4_; -#line 2204 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - user_interface_update_info_bar (self); -#line 11227 "ui.c" -} - - -void user_interface_start (UserInterface* self) { -#line 2207 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - g_return_if_fail (self != NULL); -#line 2209 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - gtk_widget_set_visible ((GtkWidget*) self, TRUE); -#line 11236 "ui.c" -} - - -Book* user_interface_get_book (UserInterface* self) { - Book* result; - Book* _tmp0_ = NULL; -#line 164 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - g_return_val_if_fail (self != NULL, NULL); -#line 164 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp0_ = self->priv->_book; -#line 164 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - result = _tmp0_; -#line 164 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - return result; -#line 11251 "ui.c" -} - - -static gpointer _book_ref0 (gpointer self) { -#line 164 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - return self ? book_ref (self) : NULL; -#line 11258 "ui.c" -} - - -static void user_interface_set_book (UserInterface* self, Book* value) { - Book* _tmp0_ = NULL; - Book* _tmp1_ = NULL; -#line 164 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - g_return_if_fail (self != NULL); -#line 164 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp0_ = value; -#line 164 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp1_ = _book_ref0 (_tmp0_); -#line 164 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _book_unref0 (self->priv->_book); -#line 164 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - self->priv->_book = _tmp1_; -#line 164 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - g_object_notify ((GObject *) self, "book"); -#line 11277 "ui.c" -} - - -Page* user_interface_get_selected_page (UserInterface* self) { - Page* result; - BookView* _tmp0_ = NULL; - Page* _tmp1_ = NULL; - Page* _tmp2_ = NULL; -#line 169 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - g_return_val_if_fail (self != NULL, NULL); -#line 171 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp0_ = self->priv->book_view; -#line 171 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp1_ = book_view_get_selected_page (_tmp0_); -#line 171 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp2_ = _tmp1_; -#line 171 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - result = _tmp2_; -#line 171 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - return result; -#line 11298 "ui.c" -} - - -void user_interface_set_selected_page (UserInterface* self, Page* value) { - BookView* _tmp0_ = NULL; - Page* _tmp1_ = NULL; -#line 173 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - g_return_if_fail (self != NULL); -#line 175 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp0_ = self->priv->book_view; -#line 175 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp1_ = value; -#line 175 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - book_view_set_selected_page (_tmp0_, _tmp1_); -#line 173 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - g_object_notify ((GObject *) self, "selected-page"); -#line 11315 "ui.c" -} - - -gboolean user_interface_get_scanning (UserInterface* self) { - gboolean result; - gboolean _tmp0_ = FALSE; -#line 193 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - g_return_val_if_fail (self != NULL, FALSE); -#line 193 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp0_ = self->priv->scanning_; -#line 193 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - result = _tmp0_; -#line 193 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - return result; -#line 11330 "ui.c" -} - - -void user_interface_set_scanning (UserInterface* self, gboolean value) { - gboolean _tmp0_ = FALSE; - GtkMenuItem* _tmp1_ = NULL; - gboolean _tmp2_ = FALSE; - GtkMenuItem* _tmp3_ = NULL; - gboolean _tmp4_ = FALSE; - GtkToolButton* _tmp5_ = NULL; - gboolean _tmp6_ = FALSE; - GtkButton* _tmp7_ = NULL; - gboolean _tmp8_ = FALSE; - GtkButton* _tmp9_ = NULL; - gboolean _tmp10_ = FALSE; -#line 194 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - g_return_if_fail (self != NULL); -#line 196 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp0_ = value; -#line 196 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - self->priv->scanning_ = _tmp0_; -#line 197 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp1_ = self->priv->page_delete_menuitem; -#line 197 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp2_ = value; -#line 197 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - gtk_widget_set_sensitive ((GtkWidget*) _tmp1_, !_tmp2_); -#line 198 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp3_ = self->priv->stop_scan_menuitem; -#line 198 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp4_ = value; -#line 198 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - gtk_widget_set_sensitive ((GtkWidget*) _tmp3_, _tmp4_); -#line 199 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp5_ = self->priv->stop_toolbutton; -#line 199 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp6_ = value; -#line 199 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - gtk_widget_set_sensitive ((GtkWidget*) _tmp5_, _tmp6_); -#line 200 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp7_ = self->priv->scan_button; -#line 200 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp8_ = value; -#line 200 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - gtk_widget_set_visible ((GtkWidget*) _tmp7_, !_tmp8_); -#line 201 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp9_ = self->priv->stop_button; -#line 201 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp10_ = value; -#line 201 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - gtk_widget_set_visible ((GtkWidget*) _tmp9_, _tmp10_); -#line 194 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - g_object_notify ((GObject *) self, "scanning"); -#line 11384 "ui.c" -} - - -gint user_interface_get_brightness (UserInterface* self) { - gint result; - GtkAdjustment* _tmp0_ = NULL; - gdouble _tmp1_ = 0.0; - gdouble _tmp2_ = 0.0; -#line 214 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - g_return_val_if_fail (self != NULL, 0); -#line 214 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp0_ = self->priv->brightness_adjustment; -#line 214 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp1_ = gtk_adjustment_get_value (_tmp0_); -#line 214 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp2_ = _tmp1_; -#line 214 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - result = (gint) _tmp2_; -#line 214 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - return result; -#line 11405 "ui.c" -} - - -void user_interface_set_brightness (UserInterface* self, gint value) { - GtkAdjustment* _tmp0_ = NULL; - gint _tmp1_ = 0; -#line 215 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - g_return_if_fail (self != NULL); -#line 215 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp0_ = self->priv->brightness_adjustment; -#line 215 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp1_ = value; -#line 215 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - gtk_adjustment_set_value (_tmp0_, (gdouble) _tmp1_); -#line 215 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - g_object_notify ((GObject *) self, "brightness"); -#line 11422 "ui.c" -} - - -gint user_interface_get_contrast (UserInterface* self) { - gint result; - GtkAdjustment* _tmp0_ = NULL; - gdouble _tmp1_ = 0.0; - gdouble _tmp2_ = 0.0; -#line 220 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - g_return_val_if_fail (self != NULL, 0); -#line 220 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp0_ = self->priv->contrast_adjustment; -#line 220 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp1_ = gtk_adjustment_get_value (_tmp0_); -#line 220 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp2_ = _tmp1_; -#line 220 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - result = (gint) _tmp2_; -#line 220 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - return result; -#line 11443 "ui.c" -} - - -void user_interface_set_contrast (UserInterface* self, gint value) { - GtkAdjustment* _tmp0_ = NULL; - gint _tmp1_ = 0; -#line 221 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - g_return_if_fail (self != NULL); -#line 221 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp0_ = self->priv->contrast_adjustment; -#line 221 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp1_ = value; -#line 221 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - gtk_adjustment_set_value (_tmp0_, (gdouble) _tmp1_); -#line 221 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - g_object_notify ((GObject *) self, "contrast"); -#line 11460 "ui.c" -} - - -gint user_interface_get_quality (UserInterface* self) { - gint result; - GtkAdjustment* _tmp0_ = NULL; - gdouble _tmp1_ = 0.0; - gdouble _tmp2_ = 0.0; -#line 226 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - g_return_val_if_fail (self != NULL, 0); -#line 226 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp0_ = self->priv->quality_adjustment; -#line 226 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp1_ = gtk_adjustment_get_value (_tmp0_); -#line 226 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp2_ = _tmp1_; -#line 226 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - result = (gint) _tmp2_; -#line 226 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - return result; -#line 11481 "ui.c" -} - - -void user_interface_set_quality (UserInterface* self, gint value) { - GtkAdjustment* _tmp0_ = NULL; - gint _tmp1_ = 0; -#line 227 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - g_return_if_fail (self != NULL); -#line 227 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp0_ = self->priv->quality_adjustment; -#line 227 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp1_ = value; -#line 227 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - gtk_adjustment_set_value (_tmp0_, (gdouble) _tmp1_); -#line 227 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - g_object_notify ((GObject *) self, "quality"); -#line 11498 "ui.c" -} - - -gchar* user_interface_get_selected_device (UserInterface* self) { - gchar* result; - GtkTreeIter iter = {0}; - GtkComboBox* _tmp0_ = NULL; - GtkTreeIter _tmp1_ = {0}; - gboolean _tmp2_ = FALSE; -#line 232 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - g_return_val_if_fail (self != NULL, NULL); -#line 236 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp0_ = self->priv->device_combo; -#line 236 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp2_ = gtk_combo_box_get_active_iter (_tmp0_, &_tmp1_); -#line 236 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - iter = _tmp1_; -#line 236 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - if (_tmp2_) { -#line 11518 "ui.c" - gchar* device = NULL; - GtkListStore* _tmp3_ = NULL; - GtkTreeIter _tmp4_ = {0}; -#line 239 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp3_ = self->priv->device_model; -#line 239 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp4_ = iter; -#line 239 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - gtk_tree_model_get ((GtkTreeModel*) _tmp3_, &_tmp4_, 0, &device, -1, -1); -#line 240 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - result = device; -#line 240 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - return result; -#line 11532 "ui.c" - } -#line 243 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - result = NULL; -#line 243 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - return result; -#line 11538 "ui.c" -} - - -void user_interface_set_selected_device (UserInterface* self, const gchar* value) { - GtkTreeIter iter = {0}; - const gchar* _tmp0_ = NULL; - GtkTreeIter _tmp1_ = {0}; - gboolean _tmp2_ = FALSE; - GtkComboBox* _tmp3_ = NULL; - GtkTreeIter _tmp4_ = {0}; -#line 246 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - g_return_if_fail (self != NULL); -#line 249 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp0_ = value; -#line 249 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp2_ = user_interface_find_scan_device (self, _tmp0_, &_tmp1_); -#line 249 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - iter = _tmp1_; -#line 249 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - if (!_tmp2_) { -#line 250 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - return; -#line 11561 "ui.c" - } -#line 252 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp3_ = self->priv->device_combo; -#line 252 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp4_ = iter; -#line 252 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - gtk_combo_box_set_active_iter (_tmp3_, &_tmp4_); -#line 253 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - self->priv->user_selected_device = TRUE; -#line 246 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - g_object_notify ((GObject *) self, "selected-device"); -#line 11573 "ui.c" -} - - -static gchar* user_interface_get_state_filename (UserInterface* self) { - gchar* result; - const gchar* _tmp0_ = NULL; - gchar* _tmp1_ = NULL; -#line 2036 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - g_return_val_if_fail (self != NULL, NULL); -#line 2036 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp0_ = g_get_user_cache_dir (); -#line 2036 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp1_ = g_build_filename (_tmp0_, "simple-scan", "state", NULL); -#line 2036 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - result = _tmp1_; -#line 2036 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - return result; -#line 11591 "ui.c" -} - - -static void g_cclosure_user_marshal_VOID__STRING_SCAN_OPTIONS (GClosure * closure, GValue * return_value, guint n_param_values, const GValue * param_values, gpointer invocation_hint, gpointer marshal_data) { - typedef void (*GMarshalFunc_VOID__STRING_SCAN_OPTIONS) (gpointer data1, const char* arg_1, gpointer arg_2, gpointer data2); - register GMarshalFunc_VOID__STRING_SCAN_OPTIONS callback; - register GCClosure * cc; - register gpointer data1; - register gpointer data2; - cc = (GCClosure *) closure; -#line 14 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - g_return_if_fail (n_param_values == 3); -#line 14 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - if (G_CCLOSURE_SWAP_DATA (closure)) { -#line 14 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - data1 = closure->data; -#line 14 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - data2 = param_values->data[0].v_pointer; -#line 11610 "ui.c" - } else { -#line 14 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - data1 = param_values->data[0].v_pointer; -#line 14 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - data2 = closure->data; -#line 11616 "ui.c" - } -#line 14 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - callback = (GMarshalFunc_VOID__STRING_SCAN_OPTIONS) (marshal_data ? marshal_data : cc->callback); -#line 14 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - callback (data1, g_value_get_string (param_values + 1), value_get_scan_options (param_values + 2), data2); -#line 11622 "ui.c" -} - - -static void g_cclosure_user_marshal_VOID__STRING_INT (GClosure * closure, GValue * return_value, guint n_param_values, const GValue * param_values, gpointer invocation_hint, gpointer marshal_data) { - typedef void (*GMarshalFunc_VOID__STRING_INT) (gpointer data1, const char* arg_1, gint arg_2, gpointer data2); - register GMarshalFunc_VOID__STRING_INT callback; - register GCClosure * cc; - register gpointer data1; - register gpointer data2; - cc = (GCClosure *) closure; -#line 14 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - g_return_if_fail (n_param_values == 3); -#line 14 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - if (G_CCLOSURE_SWAP_DATA (closure)) { -#line 14 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - data1 = closure->data; -#line 14 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - data2 = param_values->data[0].v_pointer; -#line 11641 "ui.c" - } else { -#line 14 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - data1 = param_values->data[0].v_pointer; -#line 14 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - data2 = closure->data; -#line 11647 "ui.c" - } -#line 14 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - callback = (GMarshalFunc_VOID__STRING_INT) (marshal_data ? marshal_data : cc->callback); -#line 14 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - callback (data1, g_value_get_string (param_values + 1), g_value_get_int (param_values + 2), data2); -#line 11653 "ui.c" -} - - -static void user_interface_class_init (UserInterfaceClass * klass) { - gint UserInterface_private_offset; -#line 14 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - user_interface_parent_class = g_type_class_peek_parent (klass); -#line 14 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - g_type_class_add_private (klass, sizeof (UserInterfacePrivate)); -#line 14 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - ((GtkWidgetClass *) klass)->size_allocate = (void (*)(GtkWidget*, GtkAllocation*)) user_interface_real_size_allocate; -#line 14 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - ((GtkWidgetClass *) klass)->window_state_event = (gboolean (*)(GtkWidget*, GdkEventWindowState*)) user_interface_real_window_state_event; -#line 14 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - G_OBJECT_CLASS (klass)->get_property = _vala_user_interface_get_property; -#line 14 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - G_OBJECT_CLASS (klass)->set_property = _vala_user_interface_set_property; -#line 14 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - G_OBJECT_CLASS (klass)->finalize = user_interface_finalize; -#line 14 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - g_object_class_install_property (G_OBJECT_CLASS (klass), USER_INTERFACE_BOOK, param_spec_book ("book", "book", "book", TYPE_BOOK, G_PARAM_STATIC_NAME | G_PARAM_STATIC_NICK | G_PARAM_STATIC_BLURB | G_PARAM_READABLE)); -#line 14 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - g_object_class_install_property (G_OBJECT_CLASS (klass), USER_INTERFACE_SELECTED_PAGE, param_spec_page ("selected-page", "selected-page", "selected-page", TYPE_PAGE, G_PARAM_STATIC_NAME | G_PARAM_STATIC_NICK | G_PARAM_STATIC_BLURB | G_PARAM_READABLE | G_PARAM_WRITABLE)); -#line 14 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - g_object_class_install_property (G_OBJECT_CLASS (klass), USER_INTERFACE_SCANNING, g_param_spec_boolean ("scanning", "scanning", "scanning", FALSE, G_PARAM_STATIC_NAME | G_PARAM_STATIC_NICK | G_PARAM_STATIC_BLURB | G_PARAM_READABLE | G_PARAM_WRITABLE)); -#line 14 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - g_object_class_install_property (G_OBJECT_CLASS (klass), USER_INTERFACE_BRIGHTNESS, g_param_spec_int ("brightness", "brightness", "brightness", G_MININT, G_MAXINT, 0, G_PARAM_STATIC_NAME | G_PARAM_STATIC_NICK | G_PARAM_STATIC_BLURB | G_PARAM_READABLE | G_PARAM_WRITABLE)); -#line 14 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - g_object_class_install_property (G_OBJECT_CLASS (klass), USER_INTERFACE_CONTRAST, g_param_spec_int ("contrast", "contrast", "contrast", G_MININT, G_MAXINT, 0, G_PARAM_STATIC_NAME | G_PARAM_STATIC_NICK | G_PARAM_STATIC_BLURB | G_PARAM_READABLE | G_PARAM_WRITABLE)); -#line 14 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - g_object_class_install_property (G_OBJECT_CLASS (klass), USER_INTERFACE_QUALITY, g_param_spec_int ("quality", "quality", "quality", G_MININT, G_MAXINT, 0, G_PARAM_STATIC_NAME | G_PARAM_STATIC_NICK | G_PARAM_STATIC_BLURB | G_PARAM_READABLE | G_PARAM_WRITABLE)); -#line 14 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - g_object_class_install_property (G_OBJECT_CLASS (klass), USER_INTERFACE_SELECTED_DEVICE, g_param_spec_string ("selected-device", "selected-device", "selected-device", NULL, G_PARAM_STATIC_NAME | G_PARAM_STATIC_NICK | G_PARAM_STATIC_BLURB | G_PARAM_READABLE | G_PARAM_WRITABLE)); -#line 14 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - UserInterface_private_offset = g_type_class_get_instance_private_offset (klass); -#line 14 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - gtk_widget_class_set_template_from_resource (GTK_WIDGET_CLASS (klass), "/org/gnome/SimpleScan/simple-scan.ui"); -#line 14 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - g_signal_new ("start_scan", TYPE_USER_INTERFACE, G_SIGNAL_RUN_LAST, 0, NULL, NULL, g_cclosure_user_marshal_VOID__STRING_SCAN_OPTIONS, G_TYPE_NONE, 2, G_TYPE_STRING, TYPE_SCAN_OPTIONS); -#line 14 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - g_signal_new ("stop_scan", TYPE_USER_INTERFACE, G_SIGNAL_RUN_LAST, 0, NULL, NULL, g_cclosure_marshal_VOID__VOID, G_TYPE_NONE, 0); -#line 14 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - g_signal_new ("email", TYPE_USER_INTERFACE, G_SIGNAL_RUN_LAST, 0, NULL, NULL, g_cclosure_user_marshal_VOID__STRING_INT, G_TYPE_NONE, 2, G_TYPE_STRING, G_TYPE_INT); -#line 14 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - gtk_widget_class_bind_template_child_full (GTK_WIDGET_CLASS (klass), "menubar", FALSE, UserInterface_private_offset + G_STRUCT_OFFSET (UserInterfacePrivate, menubar)); -#line 14 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - gtk_widget_class_bind_template_child_full (GTK_WIDGET_CLASS (klass), "toolbar", FALSE, UserInterface_private_offset + G_STRUCT_OFFSET (UserInterfacePrivate, toolbar)); -#line 14 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - gtk_widget_class_bind_template_child_full (GTK_WIDGET_CLASS (klass), "page_menu", FALSE, UserInterface_private_offset + G_STRUCT_OFFSET (UserInterfacePrivate, page_menu)); -#line 14 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - gtk_widget_class_bind_template_child_full (GTK_WIDGET_CLASS (klass), "main_vbox", FALSE, UserInterface_private_offset + G_STRUCT_OFFSET (UserInterfacePrivate, main_vbox)); -#line 14 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - gtk_widget_class_bind_template_child_full (GTK_WIDGET_CLASS (klass), "custom_crop_menuitem", FALSE, UserInterface_private_offset + G_STRUCT_OFFSET (UserInterfacePrivate, custom_crop_menuitem)); -#line 14 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - gtk_widget_class_bind_template_child_full (GTK_WIDGET_CLASS (klass), "a4_menuitem", FALSE, UserInterface_private_offset + G_STRUCT_OFFSET (UserInterfacePrivate, a4_menuitem)); -#line 14 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - gtk_widget_class_bind_template_child_full (GTK_WIDGET_CLASS (klass), "a5_menuitem", FALSE, UserInterface_private_offset + G_STRUCT_OFFSET (UserInterfacePrivate, a5_menuitem)); -#line 14 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - gtk_widget_class_bind_template_child_full (GTK_WIDGET_CLASS (klass), "a6_menuitem", FALSE, UserInterface_private_offset + G_STRUCT_OFFSET (UserInterfacePrivate, a6_menuitem)); -#line 14 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - gtk_widget_class_bind_template_child_full (GTK_WIDGET_CLASS (klass), "letter_menuitem", FALSE, UserInterface_private_offset + G_STRUCT_OFFSET (UserInterfacePrivate, letter_menuitem)); -#line 14 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - gtk_widget_class_bind_template_child_full (GTK_WIDGET_CLASS (klass), "legal_menuitem", FALSE, UserInterface_private_offset + G_STRUCT_OFFSET (UserInterfacePrivate, legal_menuitem)); -#line 14 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - gtk_widget_class_bind_template_child_full (GTK_WIDGET_CLASS (klass), "four_by_six_menuitem", FALSE, UserInterface_private_offset + G_STRUCT_OFFSET (UserInterfacePrivate, four_by_six_menuitem)); -#line 14 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - gtk_widget_class_bind_template_child_full (GTK_WIDGET_CLASS (klass), "no_crop_menuitem", FALSE, UserInterface_private_offset + G_STRUCT_OFFSET (UserInterfacePrivate, no_crop_menuitem)); -#line 14 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - gtk_widget_class_bind_template_child_full (GTK_WIDGET_CLASS (klass), "page_move_left_menuitem", FALSE, UserInterface_private_offset + G_STRUCT_OFFSET (UserInterfacePrivate, page_move_left_menuitem)); -#line 14 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - gtk_widget_class_bind_template_child_full (GTK_WIDGET_CLASS (klass), "page_move_right_menuitem", FALSE, UserInterface_private_offset + G_STRUCT_OFFSET (UserInterfacePrivate, page_move_right_menuitem)); -#line 14 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - gtk_widget_class_bind_template_child_full (GTK_WIDGET_CLASS (klass), "page_delete_menuitem", FALSE, UserInterface_private_offset + G_STRUCT_OFFSET (UserInterfacePrivate, page_delete_menuitem)); -#line 14 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - gtk_widget_class_bind_template_child_full (GTK_WIDGET_CLASS (klass), "crop_rotate_menuitem", FALSE, UserInterface_private_offset + G_STRUCT_OFFSET (UserInterfacePrivate, crop_rotate_menuitem)); -#line 14 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - gtk_widget_class_bind_template_child_full (GTK_WIDGET_CLASS (klass), "save_menuitem", FALSE, UserInterface_private_offset + G_STRUCT_OFFSET (UserInterfacePrivate, save_menuitem)); -#line 14 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - gtk_widget_class_bind_template_child_full (GTK_WIDGET_CLASS (klass), "save_as_menuitem", FALSE, UserInterface_private_offset + G_STRUCT_OFFSET (UserInterfacePrivate, save_as_menuitem)); -#line 14 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - gtk_widget_class_bind_template_child_full (GTK_WIDGET_CLASS (klass), "copy_to_clipboard_menuitem", FALSE, UserInterface_private_offset + G_STRUCT_OFFSET (UserInterfacePrivate, copy_to_clipboard_menuitem)); -#line 14 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - gtk_widget_class_bind_template_child_full (GTK_WIDGET_CLASS (klass), "save_button", FALSE, UserInterface_private_offset + G_STRUCT_OFFSET (UserInterfacePrivate, save_button)); -#line 14 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - gtk_widget_class_bind_template_child_full (GTK_WIDGET_CLASS (klass), "save_toolbutton", FALSE, UserInterface_private_offset + G_STRUCT_OFFSET (UserInterfacePrivate, save_toolbutton)); -#line 14 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - gtk_widget_class_bind_template_child_full (GTK_WIDGET_CLASS (klass), "stop_scan_menuitem", FALSE, UserInterface_private_offset + G_STRUCT_OFFSET (UserInterfacePrivate, stop_scan_menuitem)); -#line 14 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - gtk_widget_class_bind_template_child_full (GTK_WIDGET_CLASS (klass), "stop_toolbutton", FALSE, UserInterface_private_offset + G_STRUCT_OFFSET (UserInterfacePrivate, stop_toolbutton)); -#line 14 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - gtk_widget_class_bind_template_child_full (GTK_WIDGET_CLASS (klass), "crop_button", FALSE, UserInterface_private_offset + G_STRUCT_OFFSET (UserInterfacePrivate, crop_button)); -#line 14 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - gtk_widget_class_bind_template_child_full (GTK_WIDGET_CLASS (klass), "crop_toolbutton", FALSE, UserInterface_private_offset + G_STRUCT_OFFSET (UserInterfacePrivate, crop_toolbutton)); -#line 14 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - gtk_widget_class_bind_template_child_full (GTK_WIDGET_CLASS (klass), "stop_button", FALSE, UserInterface_private_offset + G_STRUCT_OFFSET (UserInterfacePrivate, stop_button)); -#line 14 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - gtk_widget_class_bind_template_child_full (GTK_WIDGET_CLASS (klass), "scan_button", FALSE, UserInterface_private_offset + G_STRUCT_OFFSET (UserInterfacePrivate, scan_button)); -#line 14 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - gtk_widget_class_bind_template_child_full (GTK_WIDGET_CLASS (klass), "text_button_menuitem", FALSE, UserInterface_private_offset + G_STRUCT_OFFSET (UserInterfacePrivate, text_button_menuitem)); -#line 14 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - gtk_widget_class_bind_template_child_full (GTK_WIDGET_CLASS (klass), "text_button_hb_menuitem", FALSE, UserInterface_private_offset + G_STRUCT_OFFSET (UserInterfacePrivate, text_button_hb_menuitem)); -#line 14 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - gtk_widget_class_bind_template_child_full (GTK_WIDGET_CLASS (klass), "text_menuitem", FALSE, UserInterface_private_offset + G_STRUCT_OFFSET (UserInterfacePrivate, text_menuitem)); -#line 14 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - gtk_widget_class_bind_template_child_full (GTK_WIDGET_CLASS (klass), "photo_button_menuitem", FALSE, UserInterface_private_offset + G_STRUCT_OFFSET (UserInterfacePrivate, photo_button_menuitem)); -#line 14 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - gtk_widget_class_bind_template_child_full (GTK_WIDGET_CLASS (klass), "photo_button_hb_menuitem", FALSE, UserInterface_private_offset + G_STRUCT_OFFSET (UserInterfacePrivate, photo_button_hb_menuitem)); -#line 14 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - gtk_widget_class_bind_template_child_full (GTK_WIDGET_CLASS (klass), "photo_menuitem", FALSE, UserInterface_private_offset + G_STRUCT_OFFSET (UserInterfacePrivate, photo_menuitem)); -#line 14 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - gtk_widget_class_bind_template_child_full (GTK_WIDGET_CLASS (klass), "authorize_dialog", FALSE, UserInterface_private_offset + G_STRUCT_OFFSET (UserInterfacePrivate, authorize_dialog)); -#line 14 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - gtk_widget_class_bind_template_child_full (GTK_WIDGET_CLASS (klass), "authorize_label", FALSE, UserInterface_private_offset + G_STRUCT_OFFSET (UserInterfacePrivate, authorize_label)); -#line 14 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - gtk_widget_class_bind_template_child_full (GTK_WIDGET_CLASS (klass), "username_entry", FALSE, UserInterface_private_offset + G_STRUCT_OFFSET (UserInterfacePrivate, username_entry)); -#line 14 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - gtk_widget_class_bind_template_child_full (GTK_WIDGET_CLASS (klass), "password_entry", FALSE, UserInterface_private_offset + G_STRUCT_OFFSET (UserInterfacePrivate, password_entry)); -#line 14 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - gtk_widget_class_bind_template_child_full (GTK_WIDGET_CLASS (klass), "preferences_dialog", FALSE, UserInterface_private_offset + G_STRUCT_OFFSET (UserInterfacePrivate, preferences_dialog)); -#line 14 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - gtk_widget_class_bind_template_child_full (GTK_WIDGET_CLASS (klass), "device_combo", FALSE, UserInterface_private_offset + G_STRUCT_OFFSET (UserInterfacePrivate, device_combo)); -#line 14 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - gtk_widget_class_bind_template_child_full (GTK_WIDGET_CLASS (klass), "text_dpi_combo", FALSE, UserInterface_private_offset + G_STRUCT_OFFSET (UserInterfacePrivate, text_dpi_combo)); -#line 14 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - gtk_widget_class_bind_template_child_full (GTK_WIDGET_CLASS (klass), "photo_dpi_combo", FALSE, UserInterface_private_offset + G_STRUCT_OFFSET (UserInterfacePrivate, photo_dpi_combo)); -#line 14 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - gtk_widget_class_bind_template_child_full (GTK_WIDGET_CLASS (klass), "page_side_combo", FALSE, UserInterface_private_offset + G_STRUCT_OFFSET (UserInterfacePrivate, page_side_combo)); -#line 14 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - gtk_widget_class_bind_template_child_full (GTK_WIDGET_CLASS (klass), "paper_size_combo", FALSE, UserInterface_private_offset + G_STRUCT_OFFSET (UserInterfacePrivate, paper_size_combo)); -#line 14 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - gtk_widget_class_bind_template_child_full (GTK_WIDGET_CLASS (klass), "brightness_scale", FALSE, UserInterface_private_offset + G_STRUCT_OFFSET (UserInterfacePrivate, brightness_scale)); -#line 14 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - gtk_widget_class_bind_template_child_full (GTK_WIDGET_CLASS (klass), "contrast_scale", FALSE, UserInterface_private_offset + G_STRUCT_OFFSET (UserInterfacePrivate, contrast_scale)); -#line 14 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - gtk_widget_class_bind_template_child_full (GTK_WIDGET_CLASS (klass), "quality_scale", FALSE, UserInterface_private_offset + G_STRUCT_OFFSET (UserInterfacePrivate, quality_scale)); -#line 14 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - gtk_widget_class_bind_template_child_full (GTK_WIDGET_CLASS (klass), "device_model", FALSE, UserInterface_private_offset + G_STRUCT_OFFSET (UserInterfacePrivate, device_model)); -#line 14 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - gtk_widget_class_bind_template_child_full (GTK_WIDGET_CLASS (klass), "text_dpi_model", FALSE, UserInterface_private_offset + G_STRUCT_OFFSET (UserInterfacePrivate, text_dpi_model)); -#line 14 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - gtk_widget_class_bind_template_child_full (GTK_WIDGET_CLASS (klass), "photo_dpi_model", FALSE, UserInterface_private_offset + G_STRUCT_OFFSET (UserInterfacePrivate, photo_dpi_model)); -#line 14 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - gtk_widget_class_bind_template_child_full (GTK_WIDGET_CLASS (klass), "page_side_model", FALSE, UserInterface_private_offset + G_STRUCT_OFFSET (UserInterfacePrivate, page_side_model)); -#line 14 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - gtk_widget_class_bind_template_child_full (GTK_WIDGET_CLASS (klass), "paper_size_model", FALSE, UserInterface_private_offset + G_STRUCT_OFFSET (UserInterfacePrivate, paper_size_model)); -#line 14 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - gtk_widget_class_bind_template_child_full (GTK_WIDGET_CLASS (klass), "brightness_adjustment", FALSE, UserInterface_private_offset + G_STRUCT_OFFSET (UserInterfacePrivate, brightness_adjustment)); -#line 14 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - gtk_widget_class_bind_template_child_full (GTK_WIDGET_CLASS (klass), "contrast_adjustment", FALSE, UserInterface_private_offset + G_STRUCT_OFFSET (UserInterfacePrivate, contrast_adjustment)); -#line 14 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - gtk_widget_class_bind_template_child_full (GTK_WIDGET_CLASS (klass), "quality_adjustment", FALSE, UserInterface_private_offset + G_STRUCT_OFFSET (UserInterfacePrivate, quality_adjustment)); -#line 14 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - gtk_widget_class_bind_template_callback_full (GTK_WIDGET_CLASS (klass), "device_combo_changed_cb", G_CALLBACK(_user_interface_device_combo_changed_cb_gtk_combo_box_changed)); -#line 14 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - gtk_widget_class_bind_template_callback_full (GTK_WIDGET_CLASS (klass), "new_button_clicked_cb", G_CALLBACK(_user_interface_new_button_clicked_cb_gtk_button_clicked)); -#line 14 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - gtk_widget_class_bind_template_callback_full (GTK_WIDGET_CLASS (klass), "text_menuitem_toggled_cb", G_CALLBACK(_user_interface_text_menuitem_toggled_cb_gtk_check_menu_item_toggled)); -#line 14 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - gtk_widget_class_bind_template_callback_full (GTK_WIDGET_CLASS (klass), "photo_menuitem_toggled_cb", G_CALLBACK(_user_interface_photo_menuitem_toggled_cb_gtk_check_menu_item_toggled)); -#line 14 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - gtk_widget_class_bind_template_callback_full (GTK_WIDGET_CLASS (klass), "scan_button_clicked_cb", G_CALLBACK(_user_interface_scan_button_clicked_cb_gtk_menu_item_activate)); -#line 14 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - gtk_widget_class_bind_template_callback_full (GTK_WIDGET_CLASS (klass), "stop_scan_button_clicked_cb", G_CALLBACK(_user_interface_stop_scan_button_clicked_cb_gtk_button_clicked)); -#line 14 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - gtk_widget_class_bind_template_callback_full (GTK_WIDGET_CLASS (klass), "continuous_scan_button_clicked_cb", G_CALLBACK(_user_interface_continuous_scan_button_clicked_cb_gtk_menu_item_activate)); -#line 14 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - gtk_widget_class_bind_template_callback_full (GTK_WIDGET_CLASS (klass), "preferences_button_clicked_cb", G_CALLBACK(_user_interface_preferences_button_clicked_cb_gtk_menu_item_activate)); -#line 14 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - gtk_widget_class_bind_template_callback_full (GTK_WIDGET_CLASS (klass), "preferences_dialog_delete_event_cb", G_CALLBACK(_user_interface_preferences_dialog_delete_event_cb_gtk_widget_delete_event)); -#line 14 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - gtk_widget_class_bind_template_callback_full (GTK_WIDGET_CLASS (klass), "preferences_dialog_response_cb", G_CALLBACK(_user_interface_preferences_dialog_response_cb_gtk_dialog_response)); -#line 14 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - gtk_widget_class_bind_template_callback_full (GTK_WIDGET_CLASS (klass), "rotate_left_button_clicked_cb", G_CALLBACK(_user_interface_rotate_left_button_clicked_cb_gtk_button_clicked)); -#line 14 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - gtk_widget_class_bind_template_callback_full (GTK_WIDGET_CLASS (klass), "rotate_right_button_clicked_cb", G_CALLBACK(_user_interface_rotate_right_button_clicked_cb_gtk_button_clicked)); -#line 14 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - gtk_widget_class_bind_template_callback_full (GTK_WIDGET_CLASS (klass), "no_crop_menuitem_toggled_cb", G_CALLBACK(_user_interface_no_crop_menuitem_toggled_cb_gtk_check_menu_item_toggled)); -#line 14 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - gtk_widget_class_bind_template_callback_full (GTK_WIDGET_CLASS (klass), "custom_crop_menuitem_toggled_cb", G_CALLBACK(_user_interface_custom_crop_menuitem_toggled_cb_gtk_check_menu_item_toggled)); -#line 14 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - gtk_widget_class_bind_template_callback_full (GTK_WIDGET_CLASS (klass), "crop_button_toggled_cb", G_CALLBACK(_user_interface_crop_button_toggled_cb_gtk_toggle_button_toggled)); -#line 14 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - gtk_widget_class_bind_template_callback_full (GTK_WIDGET_CLASS (klass), "crop_toolbutton_toggled_cb", G_CALLBACK(_user_interface_crop_toolbutton_toggled_cb_gtk_toggle_tool_button_toggled)); -#line 14 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - gtk_widget_class_bind_template_callback_full (GTK_WIDGET_CLASS (klass), "four_by_six_menuitem_toggled_cb", G_CALLBACK(_user_interface_four_by_six_menuitem_toggled_cb_gtk_check_menu_item_toggled)); -#line 14 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - gtk_widget_class_bind_template_callback_full (GTK_WIDGET_CLASS (klass), "legal_menuitem_toggled_cb", G_CALLBACK(_user_interface_legal_menuitem_toggled_cb_gtk_check_menu_item_toggled)); -#line 14 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - gtk_widget_class_bind_template_callback_full (GTK_WIDGET_CLASS (klass), "letter_menuitem_toggled_cb", G_CALLBACK(_user_interface_letter_menuitem_toggled_cb_gtk_check_menu_item_toggled)); -#line 14 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - gtk_widget_class_bind_template_callback_full (GTK_WIDGET_CLASS (klass), "a6_menuitem_toggled_cb", G_CALLBACK(_user_interface_a6_menuitem_toggled_cb_gtk_check_menu_item_toggled)); -#line 14 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - gtk_widget_class_bind_template_callback_full (GTK_WIDGET_CLASS (klass), "a5_menuitem_toggled_cb", G_CALLBACK(_user_interface_a5_menuitem_toggled_cb_gtk_check_menu_item_toggled)); -#line 14 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - gtk_widget_class_bind_template_callback_full (GTK_WIDGET_CLASS (klass), "a4_menuitem_toggled_cb", G_CALLBACK(_user_interface_a4_menuitem_toggled_cb_gtk_check_menu_item_toggled)); -#line 14 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - gtk_widget_class_bind_template_callback_full (GTK_WIDGET_CLASS (klass), "crop_rotate_menuitem_activate_cb", G_CALLBACK(_user_interface_crop_rotate_menuitem_activate_cb_gtk_menu_item_activate)); -#line 14 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - gtk_widget_class_bind_template_callback_full (GTK_WIDGET_CLASS (klass), "page_move_left_menuitem_activate_cb", G_CALLBACK(_user_interface_page_move_left_menuitem_activate_cb_gtk_menu_item_activate)); -#line 14 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - gtk_widget_class_bind_template_callback_full (GTK_WIDGET_CLASS (klass), "page_move_right_menuitem_activate_cb", G_CALLBACK(_user_interface_page_move_right_menuitem_activate_cb_gtk_menu_item_activate)); -#line 14 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - gtk_widget_class_bind_template_callback_full (GTK_WIDGET_CLASS (klass), "page_delete_menuitem_activate_cb", G_CALLBACK(_user_interface_page_delete_menuitem_activate_cb_gtk_menu_item_activate)); -#line 14 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - gtk_widget_class_bind_template_callback_full (GTK_WIDGET_CLASS (klass), "reorder_menuitem_activate_cb", G_CALLBACK(_user_interface_reorder_menuitem_activate_cb_gtk_menu_item_activate)); -#line 14 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - gtk_widget_class_bind_template_callback_full (GTK_WIDGET_CLASS (klass), "save_file_button_clicked_cb", G_CALLBACK(_user_interface_save_file_button_clicked_cb_gtk_button_clicked)); -#line 14 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - gtk_widget_class_bind_template_callback_full (GTK_WIDGET_CLASS (klass), "copy_to_clipboard_button_clicked_cb", G_CALLBACK(_user_interface_copy_to_clipboard_button_clicked_cb_gtk_menu_item_activate)); -#line 14 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - gtk_widget_class_bind_template_callback_full (GTK_WIDGET_CLASS (klass), "save_as_file_button_clicked_cb", G_CALLBACK(_user_interface_save_as_file_button_clicked_cb_gtk_menu_item_activate)); -#line 14 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - gtk_widget_class_bind_template_callback_full (GTK_WIDGET_CLASS (klass), "email_button_clicked_cb", G_CALLBACK(_user_interface_email_button_clicked_cb_gtk_menu_item_activate)); -#line 14 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - gtk_widget_class_bind_template_callback_full (GTK_WIDGET_CLASS (klass), "print_button_clicked_cb", G_CALLBACK(_user_interface_print_button_clicked_cb_gtk_menu_item_activate)); -#line 14 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - gtk_widget_class_bind_template_callback_full (GTK_WIDGET_CLASS (klass), "help_contents_menuitem_activate_cb", G_CALLBACK(_user_interface_help_contents_menuitem_activate_cb_gtk_menu_item_activate)); -#line 14 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - gtk_widget_class_bind_template_callback_full (GTK_WIDGET_CLASS (klass), "about_menuitem_activate_cb", G_CALLBACK(_user_interface_about_menuitem_activate_cb_gtk_menu_item_activate)); -#line 14 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - gtk_widget_class_bind_template_callback_full (GTK_WIDGET_CLASS (klass), "quit_menuitem_activate_cb", G_CALLBACK(_user_interface_quit_menuitem_activate_cb_gtk_menu_item_activate)); -#line 14 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - gtk_widget_class_bind_template_callback_full (GTK_WIDGET_CLASS (klass), "window_delete_event_cb", G_CALLBACK(_user_interface_window_delete_event_cb_gtk_widget_delete_event)); -#line 11877 "ui.c" -} - - -static void user_interface_instance_init (UserInterface * self) { - gchar* _tmp0_ = NULL; -#line 14 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - self->priv = USER_INTERFACE_GET_PRIVATE (self); -#line 153 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - self->priv->missing_driver = NULL; -#line 165 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - self->priv->book_uri = NULL; -#line 188 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp0_ = g_strdup ("photo"); -#line 188 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - self->priv->document_hint = _tmp0_; -#line 190 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - self->priv->scanning_ = FALSE; -#line 14 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - gtk_widget_init_template (GTK_WIDGET (self)); -#line 11897 "ui.c" -} - - -static void user_interface_finalize (GObject* obj) { - UserInterface * self; - Book* _tmp0_ = NULL; - guint _tmp1_ = 0U; - Book* _tmp2_ = NULL; - guint _tmp3_ = 0U; - Book* _tmp4_ = NULL; - guint _tmp5_ = 0U; -#line 14 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - self = G_TYPE_CHECK_INSTANCE_CAST (obj, TYPE_USER_INTERFACE, UserInterface); -#line 288 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp0_ = self->priv->_book; -#line 288 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - g_signal_parse_name ("page-added", TYPE_BOOK, &_tmp1_, NULL, FALSE); -#line 288 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - g_signal_handlers_disconnect_matched (_tmp0_, G_SIGNAL_MATCH_ID | G_SIGNAL_MATCH_FUNC | G_SIGNAL_MATCH_DATA, _tmp1_, 0, NULL, (GCallback) _user_interface_page_added_cb_book_page_added, self); -#line 289 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp2_ = self->priv->_book; -#line 289 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - g_signal_parse_name ("reordered", TYPE_BOOK, &_tmp3_, NULL, FALSE); -#line 289 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - g_signal_handlers_disconnect_matched (_tmp2_, G_SIGNAL_MATCH_ID | G_SIGNAL_MATCH_FUNC | G_SIGNAL_MATCH_DATA, _tmp3_, 0, NULL, (GCallback) _user_interface_reordered_cb_book_reordered, self); -#line 290 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp4_ = self->priv->_book; -#line 290 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - g_signal_parse_name ("page-removed", TYPE_BOOK, &_tmp5_, NULL, FALSE); -#line 290 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - g_signal_handlers_disconnect_matched (_tmp4_, G_SIGNAL_MATCH_ID | G_SIGNAL_MATCH_FUNC | G_SIGNAL_MATCH_DATA, _tmp5_, 0, NULL, (GCallback) _user_interface_page_removed_cb_book_page_removed, self); -#line 33 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _g_object_unref0 (self->priv->settings); -#line 36 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _g_object_unref0 (self->priv->menubar); -#line 38 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _g_object_unref0 (self->priv->toolbar); -#line 40 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _g_object_unref0 (self->priv->page_menu); -#line 42 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _g_object_unref0 (self->priv->main_vbox); -#line 43 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _g_object_unref0 (self->priv->info_bar); -#line 44 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _g_object_unref0 (self->priv->info_bar_image); -#line 45 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _g_object_unref0 (self->priv->info_bar_label); -#line 46 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _g_object_unref0 (self->priv->info_bar_close_button); -#line 47 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _g_object_unref0 (self->priv->info_bar_change_scanner_button); -#line 48 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _g_object_unref0 (self->priv->info_bar_install_button); -#line 50 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _g_object_unref0 (self->priv->custom_crop_menuitem); -#line 52 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _g_object_unref0 (self->priv->a4_menuitem); -#line 54 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _g_object_unref0 (self->priv->a5_menuitem); -#line 56 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _g_object_unref0 (self->priv->a6_menuitem); -#line 58 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _g_object_unref0 (self->priv->letter_menuitem); -#line 60 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _g_object_unref0 (self->priv->legal_menuitem); -#line 62 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _g_object_unref0 (self->priv->four_by_six_menuitem); -#line 64 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _g_object_unref0 (self->priv->no_crop_menuitem); -#line 66 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _g_object_unref0 (self->priv->page_move_left_menuitem); -#line 68 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _g_object_unref0 (self->priv->page_move_right_menuitem); -#line 70 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _g_object_unref0 (self->priv->page_delete_menuitem); -#line 72 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _g_object_unref0 (self->priv->crop_rotate_menuitem); -#line 74 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _g_object_unref0 (self->priv->save_menuitem); -#line 76 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _g_object_unref0 (self->priv->save_as_menuitem); -#line 78 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _g_object_unref0 (self->priv->copy_to_clipboard_menuitem); -#line 80 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _g_object_unref0 (self->priv->save_button); -#line 82 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _g_object_unref0 (self->priv->save_toolbutton); -#line 84 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _g_object_unref0 (self->priv->stop_scan_menuitem); -#line 86 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _g_object_unref0 (self->priv->stop_toolbutton); -#line 88 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _g_object_unref0 (self->priv->crop_button); -#line 90 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _g_object_unref0 (self->priv->crop_toolbutton); -#line 92 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _g_object_unref0 (self->priv->stop_button); -#line 94 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _g_object_unref0 (self->priv->scan_button); -#line 97 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _g_object_unref0 (self->priv->text_button_menuitem); -#line 99 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _g_object_unref0 (self->priv->text_button_hb_menuitem); -#line 101 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _g_object_unref0 (self->priv->text_menuitem); -#line 103 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _g_object_unref0 (self->priv->photo_button_menuitem); -#line 105 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _g_object_unref0 (self->priv->photo_button_hb_menuitem); -#line 107 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _g_object_unref0 (self->priv->photo_menuitem); -#line 110 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _g_object_unref0 (self->priv->authorize_dialog); -#line 112 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _g_object_unref0 (self->priv->authorize_label); -#line 114 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _g_object_unref0 (self->priv->username_entry); -#line 116 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _g_object_unref0 (self->priv->password_entry); -#line 119 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _g_object_unref0 (self->priv->preferences_dialog); -#line 121 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _g_object_unref0 (self->priv->device_combo); -#line 123 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _g_object_unref0 (self->priv->text_dpi_combo); -#line 125 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _g_object_unref0 (self->priv->photo_dpi_combo); -#line 127 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _g_object_unref0 (self->priv->page_side_combo); -#line 129 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _g_object_unref0 (self->priv->paper_size_combo); -#line 131 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _g_object_unref0 (self->priv->brightness_scale); -#line 133 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _g_object_unref0 (self->priv->contrast_scale); -#line 135 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _g_object_unref0 (self->priv->quality_scale); -#line 137 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _g_object_unref0 (self->priv->device_model); -#line 139 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _g_object_unref0 (self->priv->text_dpi_model); -#line 141 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _g_object_unref0 (self->priv->photo_dpi_model); -#line 143 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _g_object_unref0 (self->priv->page_side_model); -#line 145 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _g_object_unref0 (self->priv->paper_size_model); -#line 147 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _g_object_unref0 (self->priv->brightness_adjustment); -#line 149 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _g_object_unref0 (self->priv->contrast_adjustment); -#line 151 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _g_object_unref0 (self->priv->quality_adjustment); -#line 153 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _g_free0 (self->priv->missing_driver); -#line 156 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _g_object_unref0 (self->priv->save_dialog); -#line 157 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _g_object_unref0 (self->priv->progress_dialog); -#line 160 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _g_free0 (self->priv->error_title); -#line 161 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _g_free0 (self->priv->error_text); -#line 164 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _book_unref0 (self->priv->_book); -#line 165 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _g_free0 (self->priv->book_uri); -#line 179 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _autosave_manager_unref0 (self->priv->autosave_manager); -#line 181 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _g_object_unref0 (self->priv->book_view); -#line 188 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _g_free0 (self->priv->document_hint); -#line 14 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - G_OBJECT_CLASS (user_interface_parent_class)->finalize (obj); -#line 12073 "ui.c" -} - - -GType user_interface_get_type (void) { - static volatile gsize user_interface_type_id__volatile = 0; - if (g_once_init_enter (&user_interface_type_id__volatile)) { - static const GTypeInfo g_define_type_info = { sizeof (UserInterfaceClass), (GBaseInitFunc) NULL, (GBaseFinalizeFunc) NULL, (GClassInitFunc) user_interface_class_init, (GClassFinalizeFunc) NULL, NULL, sizeof (UserInterface), 0, (GInstanceInitFunc) user_interface_instance_init, NULL }; - GType user_interface_type_id; - user_interface_type_id = g_type_register_static (gtk_application_window_get_type (), "UserInterface", &g_define_type_info, 0); - g_once_init_leave (&user_interface_type_id__volatile, user_interface_type_id); - } - return user_interface_type_id__volatile; -} - - -static void _vala_user_interface_get_property (GObject * object, guint property_id, GValue * value, GParamSpec * pspec) { - UserInterface * self; - self = G_TYPE_CHECK_INSTANCE_CAST (object, TYPE_USER_INTERFACE, UserInterface); -#line 14 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - switch (property_id) { -#line 14 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - case USER_INTERFACE_BOOK: -#line 14 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - value_set_book (value, user_interface_get_book (self)); -#line 14 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - break; -#line 14 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - case USER_INTERFACE_SELECTED_PAGE: -#line 14 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - value_set_page (value, user_interface_get_selected_page (self)); -#line 14 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - break; -#line 14 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - case USER_INTERFACE_SCANNING: -#line 14 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - g_value_set_boolean (value, user_interface_get_scanning (self)); -#line 14 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - break; -#line 14 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - case USER_INTERFACE_BRIGHTNESS: -#line 14 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - g_value_set_int (value, user_interface_get_brightness (self)); -#line 14 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - break; -#line 14 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - case USER_INTERFACE_CONTRAST: -#line 14 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - g_value_set_int (value, user_interface_get_contrast (self)); -#line 14 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - break; -#line 14 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - case USER_INTERFACE_QUALITY: -#line 14 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - g_value_set_int (value, user_interface_get_quality (self)); -#line 14 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - break; -#line 14 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - case USER_INTERFACE_SELECTED_DEVICE: -#line 14 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - g_value_take_string (value, user_interface_get_selected_device (self)); -#line 14 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - break; -#line 12136 "ui.c" - default: -#line 14 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - G_OBJECT_WARN_INVALID_PROPERTY_ID (object, property_id, pspec); -#line 14 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - break; -#line 12142 "ui.c" - } -} - - -static void _vala_user_interface_set_property (GObject * object, guint property_id, const GValue * value, GParamSpec * pspec) { - UserInterface * self; - self = G_TYPE_CHECK_INSTANCE_CAST (object, TYPE_USER_INTERFACE, UserInterface); -#line 14 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - switch (property_id) { -#line 14 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - case USER_INTERFACE_BOOK: -#line 14 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - user_interface_set_book (self, value_get_book (value)); -#line 14 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - break; -#line 14 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - case USER_INTERFACE_SELECTED_PAGE: -#line 14 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - user_interface_set_selected_page (self, value_get_page (value)); -#line 14 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - break; -#line 14 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - case USER_INTERFACE_SCANNING: -#line 14 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - user_interface_set_scanning (self, g_value_get_boolean (value)); -#line 14 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - break; -#line 14 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - case USER_INTERFACE_BRIGHTNESS: -#line 14 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - user_interface_set_brightness (self, g_value_get_int (value)); -#line 14 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - break; -#line 14 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - case USER_INTERFACE_CONTRAST: -#line 14 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - user_interface_set_contrast (self, g_value_get_int (value)); -#line 14 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - break; -#line 14 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - case USER_INTERFACE_QUALITY: -#line 14 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - user_interface_set_quality (self, g_value_get_int (value)); -#line 14 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - break; -#line 14 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - case USER_INTERFACE_SELECTED_DEVICE: -#line 14 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - user_interface_set_selected_device (self, g_value_get_string (value)); -#line 14 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - break; -#line 12194 "ui.c" - default: -#line 14 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - G_OBJECT_WARN_INVALID_PROPERTY_ID (object, property_id, pspec); -#line 14 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - break; -#line 12200 "ui.c" - } -} - - -ProgressBarDialog* progress_bar_dialog_construct (GType object_type, GtkApplicationWindow* parent, const gchar* title) { - ProgressBarDialog * self = NULL; - GtkProgressBar* _tmp0_ = NULL; - GtkBox* hbox = NULL; - GtkBox* _tmp1_ = NULL; - GtkBox* vbox = NULL; - GtkBox* _tmp2_ = NULL; - GtkProgressBar* _tmp3_ = NULL; - GtkProgressBar* _tmp4_ = NULL; - GtkProgressBar* _tmp5_ = NULL; - GtkProgressBar* _tmp6_ = NULL; - const gchar* _tmp7_ = NULL; - GtkApplicationWindow* _tmp8_ = NULL; - GtkProgressBar* _tmp9_ = NULL; -#line 2229 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - g_return_val_if_fail (parent != NULL, NULL); -#line 2229 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - g_return_val_if_fail (title != NULL, NULL); -#line 2229 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - self = (ProgressBarDialog*) g_object_new (object_type, NULL); -#line 2231 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp0_ = (GtkProgressBar*) gtk_progress_bar_new (); -#line 2231 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - g_object_ref_sink (_tmp0_); -#line 2231 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _g_object_unref0 (self->priv->bar); -#line 2231 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - self->priv->bar = _tmp0_; -#line 2232 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp1_ = (GtkBox*) gtk_box_new (GTK_ORIENTATION_HORIZONTAL, 5); -#line 2232 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - g_object_ref_sink (_tmp1_); -#line 2232 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - hbox = _tmp1_; -#line 2233 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp2_ = (GtkBox*) gtk_box_new (GTK_ORIENTATION_VERTICAL, 5); -#line 2233 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - g_object_ref_sink (_tmp2_); -#line 2233 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - vbox = _tmp2_; -#line 2234 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - gtk_widget_set_hexpand ((GtkWidget*) hbox, TRUE); -#line 2236 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp3_ = self->priv->bar; -#line 2236 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - gtk_progress_bar_set_text (_tmp3_, ""); -#line 2237 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp4_ = self->priv->bar; -#line 2237 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - gtk_progress_bar_set_show_text (_tmp4_, TRUE); -#line 2238 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp5_ = self->priv->bar; -#line 2238 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - gtk_widget_set_size_request ((GtkWidget*) _tmp5_, 225, 25); -#line 2239 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - gtk_widget_set_size_request ((GtkWidget*) self, 250, 50); -#line 2241 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp6_ = self->priv->bar; -#line 2241 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - gtk_box_pack_start (vbox, (GtkWidget*) _tmp6_, TRUE, FALSE, (guint) 0); -#line 2242 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - gtk_box_pack_start (hbox, (GtkWidget*) vbox, TRUE, FALSE, (guint) 0); -#line 2243 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - gtk_container_add ((GtkContainer*) self, (GtkWidget*) hbox); -#line 2244 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp7_ = title; -#line 2244 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - gtk_window_set_title ((GtkWindow*) self, _tmp7_); -#line 2246 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp8_ = parent; -#line 2246 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - gtk_window_set_transient_for ((GtkWindow*) self, (GtkWindow*) _tmp8_); -#line 2247 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - gtk_window_set_position ((GtkWindow*) self, GTK_WIN_POS_CENTER_ON_PARENT); -#line 2248 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - gtk_window_set_modal ((GtkWindow*) self, TRUE); -#line 2249 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - gtk_window_set_resizable ((GtkWindow*) self, FALSE); -#line 2251 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - gtk_widget_set_visible ((GtkWidget*) hbox, TRUE); -#line 2252 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - gtk_widget_set_visible ((GtkWidget*) vbox, TRUE); -#line 2253 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp9_ = self->priv->bar; -#line 2253 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - gtk_widget_set_visible ((GtkWidget*) _tmp9_, TRUE); -#line 2229 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _g_object_unref0 (vbox); -#line 2229 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _g_object_unref0 (hbox); -#line 2229 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - return self; -#line 12297 "ui.c" -} - - -ProgressBarDialog* progress_bar_dialog_new (GtkApplicationWindow* parent, const gchar* title) { -#line 2229 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - return progress_bar_dialog_construct (TYPE_PROGRESS_BAR_DIALOG, parent, title); -#line 12304 "ui.c" -} - - -gdouble progress_bar_dialog_get_fraction (ProgressBarDialog* self) { - gdouble result; - GtkProgressBar* _tmp0_ = NULL; - gdouble _tmp1_ = 0.0; - gdouble _tmp2_ = 0.0; -#line 2219 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - g_return_val_if_fail (self != NULL, 0.0); -#line 2219 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp0_ = self->priv->bar; -#line 2219 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp1_ = gtk_progress_bar_get_fraction (_tmp0_); -#line 2219 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp2_ = _tmp1_; -#line 2219 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - result = _tmp2_; -#line 2219 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - return result; -#line 12325 "ui.c" -} - - -void progress_bar_dialog_set_fraction (ProgressBarDialog* self, gdouble value) { - GtkProgressBar* _tmp0_ = NULL; - gdouble _tmp1_ = 0.0; -#line 2220 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - g_return_if_fail (self != NULL); -#line 2220 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp0_ = self->priv->bar; -#line 2220 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp1_ = value; -#line 2220 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - gtk_progress_bar_set_fraction (_tmp0_, _tmp1_); -#line 2220 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - g_object_notify ((GObject *) self, "fraction"); -#line 12342 "ui.c" -} - - -const gchar* progress_bar_dialog_get_message (ProgressBarDialog* self) { - const gchar* result; - GtkProgressBar* _tmp0_ = NULL; - const gchar* _tmp1_ = NULL; - const gchar* _tmp2_ = NULL; -#line 2225 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - g_return_val_if_fail (self != NULL, NULL); -#line 2225 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp0_ = self->priv->bar; -#line 2225 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp1_ = gtk_progress_bar_get_text (_tmp0_); -#line 2225 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp2_ = _tmp1_; -#line 2225 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - result = _tmp2_; -#line 2225 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - return result; -#line 12363 "ui.c" -} - - -void progress_bar_dialog_set_message (ProgressBarDialog* self, const gchar* value) { - GtkProgressBar* _tmp0_ = NULL; - const gchar* _tmp1_ = NULL; -#line 2226 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - g_return_if_fail (self != NULL); -#line 2226 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp0_ = self->priv->bar; -#line 2226 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp1_ = value; -#line 2226 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - gtk_progress_bar_set_text (_tmp0_, _tmp1_); -#line 2226 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - g_object_notify ((GObject *) self, "message"); -#line 12380 "ui.c" -} - - -static void progress_bar_dialog_class_init (ProgressBarDialogClass * klass) { -#line 2213 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - progress_bar_dialog_parent_class = g_type_class_peek_parent (klass); -#line 2213 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - g_type_class_add_private (klass, sizeof (ProgressBarDialogPrivate)); -#line 2213 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - G_OBJECT_CLASS (klass)->get_property = _vala_progress_bar_dialog_get_property; -#line 2213 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - G_OBJECT_CLASS (klass)->set_property = _vala_progress_bar_dialog_set_property; -#line 2213 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - G_OBJECT_CLASS (klass)->finalize = progress_bar_dialog_finalize; -#line 2213 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - g_object_class_install_property (G_OBJECT_CLASS (klass), PROGRESS_BAR_DIALOG_FRACTION, g_param_spec_double ("fraction", "fraction", "fraction", -G_MAXDOUBLE, G_MAXDOUBLE, 0.0, G_PARAM_STATIC_NAME | G_PARAM_STATIC_NICK | G_PARAM_STATIC_BLURB | G_PARAM_READABLE | G_PARAM_WRITABLE)); -#line 2213 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - g_object_class_install_property (G_OBJECT_CLASS (klass), PROGRESS_BAR_DIALOG_MESSAGE, g_param_spec_string ("message", "message", "message", NULL, G_PARAM_STATIC_NAME | G_PARAM_STATIC_NICK | G_PARAM_STATIC_BLURB | G_PARAM_READABLE | G_PARAM_WRITABLE)); -#line 12399 "ui.c" -} - - -static void progress_bar_dialog_instance_init (ProgressBarDialog * self) { -#line 2213 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - self->priv = PROGRESS_BAR_DIALOG_GET_PRIVATE (self); -#line 12406 "ui.c" -} - - -static void progress_bar_dialog_finalize (GObject* obj) { - ProgressBarDialog * self; -#line 2213 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - self = G_TYPE_CHECK_INSTANCE_CAST (obj, TYPE_PROGRESS_BAR_DIALOG, ProgressBarDialog); -#line 2215 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _g_object_unref0 (self->priv->bar); -#line 2213 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - G_OBJECT_CLASS (progress_bar_dialog_parent_class)->finalize (obj); -#line 12418 "ui.c" -} - - -GType progress_bar_dialog_get_type (void) { - static volatile gsize progress_bar_dialog_type_id__volatile = 0; - if (g_once_init_enter (&progress_bar_dialog_type_id__volatile)) { - static const GTypeInfo g_define_type_info = { sizeof (ProgressBarDialogClass), (GBaseInitFunc) NULL, (GBaseFinalizeFunc) NULL, (GClassInitFunc) progress_bar_dialog_class_init, (GClassFinalizeFunc) NULL, NULL, sizeof (ProgressBarDialog), 0, (GInstanceInitFunc) progress_bar_dialog_instance_init, NULL }; - GType progress_bar_dialog_type_id; - progress_bar_dialog_type_id = g_type_register_static (gtk_window_get_type (), "ProgressBarDialog", &g_define_type_info, 0); - g_once_init_leave (&progress_bar_dialog_type_id__volatile, progress_bar_dialog_type_id); - } - return progress_bar_dialog_type_id__volatile; -} - - -static void _vala_progress_bar_dialog_get_property (GObject * object, guint property_id, GValue * value, GParamSpec * pspec) { - ProgressBarDialog * self; - self = G_TYPE_CHECK_INSTANCE_CAST (object, TYPE_PROGRESS_BAR_DIALOG, ProgressBarDialog); -#line 2213 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - switch (property_id) { -#line 2213 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - case PROGRESS_BAR_DIALOG_FRACTION: -#line 2213 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - g_value_set_double (value, progress_bar_dialog_get_fraction (self)); -#line 2213 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - break; -#line 2213 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - case PROGRESS_BAR_DIALOG_MESSAGE: -#line 2213 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - g_value_set_string (value, progress_bar_dialog_get_message (self)); -#line 2213 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - break; -#line 12451 "ui.c" - default: -#line 2213 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - G_OBJECT_WARN_INVALID_PROPERTY_ID (object, property_id, pspec); -#line 2213 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - break; -#line 12457 "ui.c" - } -} - - -static void _vala_progress_bar_dialog_set_property (GObject * object, guint property_id, const GValue * value, GParamSpec * pspec) { - ProgressBarDialog * self; - self = G_TYPE_CHECK_INSTANCE_CAST (object, TYPE_PROGRESS_BAR_DIALOG, ProgressBarDialog); -#line 2213 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - switch (property_id) { -#line 2213 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - case PROGRESS_BAR_DIALOG_FRACTION: -#line 2213 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - progress_bar_dialog_set_fraction (self, g_value_get_double (value)); -#line 2213 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - break; -#line 2213 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - case PROGRESS_BAR_DIALOG_MESSAGE: -#line 2213 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - progress_bar_dialog_set_message (self, g_value_get_string (value)); -#line 2213 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - break; -#line 12479 "ui.c" - default: -#line 2213 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - G_OBJECT_WARN_INVALID_PROPERTY_ID (object, property_id, pspec); -#line 2213 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - break; -#line 12485 "ui.c" - } -} - - -gchar* get_temporary_filename (const gchar* prefix, const gchar* extension) { - gchar* result = NULL; - gchar* filename = NULL; - const gchar* _tmp0_ = NULL; - const gchar* _tmp1_ = NULL; - gchar* _tmp2_ = NULL; - gchar* path = NULL; - GError * _inner_error_ = NULL; -#line 2258 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - g_return_val_if_fail (prefix != NULL, NULL); -#line 2258 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - g_return_val_if_fail (extension != NULL, NULL); -#line 2263 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp0_ = prefix; -#line 2263 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp1_ = extension; -#line 2263 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp2_ = g_strdup_printf ("%sXXXXXX.%s", _tmp0_, _tmp1_); -#line 2263 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - filename = _tmp2_; -#line 12510 "ui.c" - { - gint fd = 0; - const gchar* _tmp3_ = NULL; - gchar* _tmp4_ = NULL; - gint _tmp5_ = 0; - gint _tmp6_ = 0; -#line 2267 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp3_ = filename; -#line 2267 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp5_ = g_file_open_tmp (_tmp3_, &_tmp4_, &_inner_error_); -#line 2267 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _g_free0 (path); -#line 2267 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - path = _tmp4_; -#line 2267 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - fd = _tmp5_; -#line 2267 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - if (G_UNLIKELY (_inner_error_ != NULL)) { -#line 12529 "ui.c" - goto __catch28_g_error; - } -#line 2268 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp6_ = fd; -#line 2268 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - close (_tmp6_); -#line 12536 "ui.c" - } - goto __finally28; - __catch28_g_error: - { - GError* e = NULL; - GError* _tmp7_ = NULL; - const gchar* _tmp8_ = NULL; -#line 2265 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - e = _inner_error_; -#line 2265 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _inner_error_ = NULL; -#line 2272 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp7_ = e; -#line 2272 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp8_ = _tmp7_->message; -#line 2272 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - g_warning ("ui.vala:2272: Error saving email attachment: %s", _tmp8_); -#line 2273 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - result = NULL; -#line 2273 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _g_error_free0 (e); -#line 2273 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _g_free0 (path); -#line 2273 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _g_free0 (filename); -#line 2273 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - return result; -#line 12564 "ui.c" - } - __finally28: -#line 2265 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - if (G_UNLIKELY (_inner_error_ != NULL)) { -#line 2265 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _g_free0 (path); -#line 2265 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _g_free0 (filename); -#line 2265 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - g_critical ("file %s: line %d: uncaught error: %s (%s, %d)", __FILE__, __LINE__, _inner_error_->message, g_quark_to_string (_inner_error_->domain), _inner_error_->code); -#line 2265 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - g_clear_error (&_inner_error_); -#line 2265 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - return NULL; -#line 12579 "ui.c" - } -#line 2276 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - result = path; -#line 2276 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _g_free0 (filename); -#line 2276 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - return result; -#line 12587 "ui.c" -} - - -PageIcon* page_icon_construct (GType object_type, const gchar* text, gdouble r, gdouble g, gdouble b) { - PageIcon * self = NULL; - const gchar* _tmp0_ = NULL; - gchar* _tmp1_ = NULL; - gdouble _tmp2_ = 0.0; - gdouble _tmp3_ = 0.0; - gdouble _tmp4_ = 0.0; -#line 2287 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - g_return_val_if_fail (text != NULL, NULL); -#line 2287 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - self = (PageIcon*) g_object_new (object_type, NULL); -#line 2289 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp0_ = text; -#line 2289 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp1_ = g_strdup (_tmp0_); -#line 2289 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _g_free0 (self->priv->text); -#line 2289 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - self->priv->text = _tmp1_; -#line 2290 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp2_ = r; -#line 2290 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - self->priv->r = _tmp2_; -#line 2291 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp3_ = g; -#line 2291 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - self->priv->g = _tmp3_; -#line 2292 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp4_ = b; -#line 2292 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - self->priv->b = _tmp4_; -#line 2287 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - return self; -#line 12624 "ui.c" -} - - -PageIcon* page_icon_new (const gchar* text, gdouble r, gdouble g, gdouble b) { -#line 2287 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - return page_icon_construct (TYPE_PAGE_ICON, text, r, g, b); -#line 12631 "ui.c" -} - - -static void page_icon_real_get_preferred_width (GtkWidget* base, gint* minimum_width, gint* natural_width) { - PageIcon * self; - gint _vala_minimum_width = 0; - gint _vala_natural_width = 0; -#line 2295 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - self = (PageIcon*) base; -#line 2297 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _vala_natural_width = PAGE_ICON_MINIMUM_WIDTH; -#line 2297 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _vala_minimum_width = _vala_natural_width; -#line 2295 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - if (minimum_width) { -#line 2295 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - *minimum_width = _vala_minimum_width; -#line 12649 "ui.c" - } -#line 2295 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - if (natural_width) { -#line 2295 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - *natural_width = _vala_natural_width; -#line 12655 "ui.c" - } -} - - -static void page_icon_real_get_preferred_height (GtkWidget* base, gint* minimum_height, gint* natural_height) { - PageIcon * self; - gint _vala_minimum_height = 0; - gint _vala_natural_height = 0; - gdouble _tmp0_ = 0.0; -#line 2300 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - self = (PageIcon*) base; -#line 2302 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp0_ = round (PAGE_ICON_MINIMUM_WIDTH * G_SQRT2); -#line 2302 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _vala_natural_height = (gint) _tmp0_; -#line 2302 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _vala_minimum_height = _vala_natural_height; -#line 2300 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - if (minimum_height) { -#line 2300 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - *minimum_height = _vala_minimum_height; -#line 12677 "ui.c" - } -#line 2300 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - if (natural_height) { -#line 2300 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - *natural_height = _vala_natural_height; -#line 12683 "ui.c" - } -} - - -static void page_icon_real_get_preferred_height_for_width (GtkWidget* base, gint width, gint* minimum_height, gint* natural_height) { - PageIcon * self; - gint _vala_minimum_height = 0; - gint _vala_natural_height = 0; - gint _tmp0_ = 0; -#line 2305 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - self = (PageIcon*) base; -#line 2307 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp0_ = width; -#line 2307 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _vala_natural_height = (gint) (_tmp0_ * G_SQRT2); -#line 2307 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _vala_minimum_height = _vala_natural_height; -#line 2305 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - if (minimum_height) { -#line 2305 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - *minimum_height = _vala_minimum_height; -#line 12705 "ui.c" - } -#line 2305 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - if (natural_height) { -#line 2305 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - *natural_height = _vala_natural_height; -#line 12711 "ui.c" - } -} - - -static void page_icon_real_get_preferred_width_for_height (GtkWidget* base, gint height, gint* minimum_width, gint* natural_width) { - PageIcon * self; - gint _vala_minimum_width = 0; - gint _vala_natural_width = 0; - gint _tmp0_ = 0; -#line 2310 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - self = (PageIcon*) base; -#line 2312 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp0_ = height; -#line 2312 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _vala_natural_width = (gint) (_tmp0_ / G_SQRT2); -#line 2312 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _vala_minimum_width = _vala_natural_width; -#line 2310 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - if (minimum_width) { -#line 2310 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - *minimum_width = _vala_minimum_width; -#line 12733 "ui.c" - } -#line 2310 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - if (natural_width) { -#line 2310 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - *natural_width = _vala_natural_width; -#line 12739 "ui.c" - } -} - - -static gboolean page_icon_real_draw (GtkWidget* base, cairo_t* c) { - PageIcon * self; - gboolean result = FALSE; - gint w = 0; - gint _tmp0_ = 0; - gint h = 0; - gint _tmp1_ = 0; - gint _tmp2_ = 0; - gint _tmp3_ = 0; - cairo_t* _tmp8_ = NULL; - gint _tmp9_ = 0; - gint _tmp10_ = 0; - gint _tmp11_ = 0; - gint _tmp12_ = 0; - cairo_t* _tmp13_ = NULL; - gint _tmp14_ = 0; - gint _tmp15_ = 0; - cairo_t* _tmp16_ = NULL; - gdouble _tmp17_ = 0.0; - gdouble _tmp18_ = 0.0; - gdouble _tmp19_ = 0.0; - cairo_t* _tmp20_ = NULL; - cairo_t* _tmp21_ = NULL; - cairo_t* _tmp22_ = NULL; - cairo_t* _tmp23_ = NULL; - cairo_text_extents_t extents = {0}; - cairo_t* _tmp24_ = NULL; - const gchar* _tmp25_ = NULL; - cairo_text_extents_t _tmp26_ = {0}; - cairo_t* _tmp27_ = NULL; - gint _tmp28_ = 0; - cairo_text_extents_t _tmp29_ = {0}; - gdouble _tmp30_ = 0.0; - gint _tmp31_ = 0; - cairo_text_extents_t _tmp32_ = {0}; - gdouble _tmp33_ = 0.0; - cairo_t* _tmp34_ = NULL; - const gchar* _tmp35_ = NULL; -#line 2315 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - self = (PageIcon*) base; -#line 2315 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - g_return_val_if_fail (c != NULL, FALSE); -#line 2317 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp0_ = gtk_widget_get_allocated_width ((GtkWidget*) self); -#line 2317 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - w = _tmp0_; -#line 2318 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp1_ = gtk_widget_get_allocated_height ((GtkWidget*) self); -#line 2318 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - h = _tmp1_; -#line 2319 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp2_ = w; -#line 2319 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp3_ = h; -#line 2319 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - if ((_tmp2_ * G_SQRT2) > ((gdouble) _tmp3_)) { -#line 12800 "ui.c" - gint _tmp4_ = 0; - gdouble _tmp5_ = 0.0; -#line 2320 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp4_ = h; -#line 2320 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp5_ = round (_tmp4_ / G_SQRT2); -#line 2320 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - w = (gint) _tmp5_; -#line 12809 "ui.c" - } else { - gint _tmp6_ = 0; - gdouble _tmp7_ = 0.0; -#line 2322 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp6_ = w; -#line 2322 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp7_ = round (_tmp6_ * G_SQRT2); -#line 2322 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - h = (gint) _tmp7_; -#line 12819 "ui.c" - } -#line 2324 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp8_ = c; -#line 2324 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp9_ = gtk_widget_get_allocated_width ((GtkWidget*) self); -#line 2324 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp10_ = w; -#line 2324 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp11_ = gtk_widget_get_allocated_height ((GtkWidget*) self); -#line 2324 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp12_ = h; -#line 2324 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - cairo_translate (_tmp8_, (gdouble) ((_tmp9_ - _tmp10_) / 2), (gdouble) ((_tmp11_ - _tmp12_) / 2)); -#line 2326 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp13_ = c; -#line 2326 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp14_ = w; -#line 2326 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp15_ = h; -#line 2326 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - cairo_rectangle (_tmp13_, 0.5, 0.5, (gdouble) (_tmp14_ - 1), (gdouble) (_tmp15_ - 1)); -#line 2328 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp16_ = c; -#line 2328 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp17_ = self->priv->r; -#line 2328 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp18_ = self->priv->g; -#line 2328 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp19_ = self->priv->b; -#line 2328 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - cairo_set_source_rgb (_tmp16_, _tmp17_, _tmp18_, _tmp19_); -#line 2329 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp20_ = c; -#line 2329 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - cairo_fill_preserve (_tmp20_); -#line 2331 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp21_ = c; -#line 2331 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - cairo_set_line_width (_tmp21_, 1.0); -#line 2332 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp22_ = c; -#line 2332 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - cairo_set_source_rgb (_tmp22_, 0.0, 0.0, 0.0); -#line 2333 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp23_ = c; -#line 2333 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - cairo_stroke (_tmp23_); -#line 2336 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp24_ = c; -#line 2336 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp25_ = self->priv->text; -#line 2336 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - cairo_text_extents (_tmp24_, _tmp25_, &_tmp26_); -#line 2336 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - extents = _tmp26_; -#line 2337 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp27_ = c; -#line 2337 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp28_ = w; -#line 2337 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp29_ = extents; -#line 2337 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp30_ = _tmp29_.width; -#line 2337 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp31_ = h; -#line 2337 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp32_ = extents; -#line 2337 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp33_ = _tmp32_.height; -#line 2337 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - cairo_translate (_tmp27_, ((_tmp28_ - _tmp30_) * 0.5) - 0.5, ((_tmp31_ + _tmp33_) * 0.5) - 0.5); -#line 2338 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp34_ = c; -#line 2338 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _tmp35_ = self->priv->text; -#line 2338 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - cairo_show_text (_tmp34_, _tmp35_); -#line 2340 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - result = TRUE; -#line 2340 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - return result; -#line 12901 "ui.c" -} - - -static void page_icon_class_init (PageIconClass * klass) { -#line 2279 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - page_icon_parent_class = g_type_class_peek_parent (klass); -#line 2279 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - g_type_class_add_private (klass, sizeof (PageIconPrivate)); -#line 2279 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - ((GtkWidgetClass *) klass)->get_preferred_width = (void (*)(GtkWidget*, gint*, gint*)) page_icon_real_get_preferred_width; -#line 2279 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - ((GtkWidgetClass *) klass)->get_preferred_height = (void (*)(GtkWidget*, gint*, gint*)) page_icon_real_get_preferred_height; -#line 2279 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - ((GtkWidgetClass *) klass)->get_preferred_height_for_width = (void (*)(GtkWidget*, gint, gint*, gint*)) page_icon_real_get_preferred_height_for_width; -#line 2279 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - ((GtkWidgetClass *) klass)->get_preferred_width_for_height = (void (*)(GtkWidget*, gint, gint*, gint*)) page_icon_real_get_preferred_width_for_height; -#line 2279 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - ((GtkWidgetClass *) klass)->draw = (gboolean (*)(GtkWidget*, cairo_t*)) page_icon_real_draw; -#line 2279 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - G_OBJECT_CLASS (klass)->finalize = page_icon_finalize; -#line 12922 "ui.c" -} - - -static void page_icon_instance_init (PageIcon * self) { -#line 2279 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - self->priv = PAGE_ICON_GET_PRIVATE (self); -#line 12929 "ui.c" -} - - -static void page_icon_finalize (GObject* obj) { - PageIcon * self; -#line 2279 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - self = G_TYPE_CHECK_INSTANCE_CAST (obj, TYPE_PAGE_ICON, PageIcon); -#line 2281 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - _g_free0 (self->priv->text); -#line 2279 "/home/bob/bzr/simple-scan/trunk/src/ui.vala" - G_OBJECT_CLASS (page_icon_parent_class)->finalize (obj); -#line 12941 "ui.c" -} - - -GType page_icon_get_type (void) { - static volatile gsize page_icon_type_id__volatile = 0; - if (g_once_init_enter (&page_icon_type_id__volatile)) { - static const GTypeInfo g_define_type_info = { sizeof (PageIconClass), (GBaseInitFunc) NULL, (GBaseFinalizeFunc) NULL, (GClassInitFunc) page_icon_class_init, (GClassFinalizeFunc) NULL, NULL, sizeof (PageIcon), 0, (GInstanceInitFunc) page_icon_instance_init, NULL }; - GType page_icon_type_id; - page_icon_type_id = g_type_register_static (gtk_drawing_area_get_type (), "PageIcon", &g_define_type_info, 0); - g_once_init_leave (&page_icon_type_id__volatile, page_icon_type_id); - } - return page_icon_type_id__volatile; -} - - -static void _vala_array_destroy (gpointer array, gint array_length, GDestroyNotify destroy_func) { - if ((array != NULL) && (destroy_func != NULL)) { - int i; - for (i = 0; i < array_length; i = i + 1) { - if (((gpointer*) array)[i] != NULL) { - destroy_func (((gpointer*) array)[i]); - } - } - } -} - - -static void _vala_array_free (gpointer array, gint array_length, GDestroyNotify destroy_func) { - _vala_array_destroy (array, array_length, destroy_func); - g_free (array); -} - - -static gint _vala_array_length (gpointer array) { - int length; - length = 0; - if (array) { - while (((gpointer*) array)[length]) { - length++; - } - } - return length; -} - - - diff --git a/src/ui.vala b/src/ui.vala index 5e375c4..554b161 100644 --- a/src/ui.vala +++ b/src/ui.vala @@ -21,7 +21,6 @@ public class UserInterface : Gtk.ApplicationWindow { "new_document", new_document_activate_cb }, { "reorder", reorder_document_activate_cb }, { "save", save_document_activate_cb }, - { "save_as", save_as_document_activate_cb }, { "email", email_document_activate_cb }, { "print", print_document_activate_cb }, { "preferences", preferences_activate_cb }, @@ -73,7 +72,9 @@ public class UserInterface : Gtk.ApplicationWindow [GtkChild] private Gtk.MenuItem save_menuitem; [GtkChild] - private Gtk.MenuItem save_as_menuitem; + private Gtk.MenuItem email_menuitem; + [GtkChild] + private Gtk.MenuItem print_menuitem; [GtkChild] private Gtk.MenuItem copy_to_clipboard_menuitem; [GtkChild] @@ -134,6 +135,8 @@ public class UserInterface : Gtk.ApplicationWindow [GtkChild] private Gtk.Scale quality_scale; [GtkChild] + private Gtk.Scale page_delay_scale; + [GtkChild] private Gtk.ListStore device_model; [GtkChild] private Gtk.ListStore text_dpi_model; @@ -149,6 +152,8 @@ public class UserInterface : Gtk.ApplicationWindow private Gtk.Adjustment contrast_adjustment; [GtkChild] private Gtk.Adjustment quality_adjustment; + [GtkChild] + private Gtk.Adjustment page_delay_adjustment; private bool setting_devices; private string? missing_driver = null; private bool user_selected_device; @@ -162,6 +167,7 @@ public class UserInterface : Gtk.ApplicationWindow private bool error_change_scanner_hint; public Book book { get; private set; } + private bool book_needs_saving; private string? book_uri = null; public Page selected_page @@ -227,6 +233,12 @@ public class UserInterface : Gtk.ApplicationWindow set { quality_adjustment.value = value; } } + public int page_delay + { + get { return (int) page_delay_adjustment.value; } + set { page_delay_adjustment.value = value; } + } + public string? selected_device { owned get @@ -266,21 +278,23 @@ public class UserInterface : Gtk.ApplicationWindow book.page_added.connect (page_added_cb); book.reordered.connect (reordered_cb); book.page_removed.connect (page_removed_cb); - book.needs_saving_changed.connect (needs_saving_cb); + book.changed.connect (book_changed_cb); load (); + clear_document (); autosave_manager = new AutosaveManager (); autosave_manager.book = book; autosave_manager.load (); if (book.n_pages == 0) - { - add_default_page (); - book.needs_saving = false; - } + book_needs_saving = false; else + { book_view.selected_page = book.get_page (0); + book_needs_saving = true; + book_changed_cb (book); + } } ~UserInterface () @@ -483,16 +497,6 @@ public class UserInterface : Gtk.ApplicationWindow update_info_bar (); } - private void add_default_page () - { - var page = new Page (default_page_width, - default_page_height, - default_page_dpi, - default_page_scan_direction); - book.append_page (page); - book_view.selected_page = page; - } - private string choose_file_location () { /* Get directory to save to */ @@ -508,12 +512,15 @@ public class UserInterface : Gtk.ApplicationWindow Gtk.FileChooserAction.SAVE, _("_Cancel"), Gtk.ResponseType.CANCEL, _("_Save"), Gtk.ResponseType.ACCEPT, - null); - save_dialog.do_overwrite_confirmation = true; + null); save_dialog.local_only = false; - save_dialog.set_current_folder (directory); - /* Default filename to use when saving document */ - save_dialog.set_current_name (_("Scanned Document.pdf")); + if (book_uri != null) + save_dialog.set_uri (book_uri); + else { + save_dialog.set_current_folder (directory); + /* Default filename to use when saving document */ + save_dialog.set_current_name (_("Scanned Document.pdf")); + } /* Filter to only show images by default */ var filter = new Gtk.FileFilter (); @@ -584,11 +591,13 @@ public class UserInterface : Gtk.ApplicationWindow }); box.pack_start (file_type_combo, false, false, 0); - var response = save_dialog.run (); - string? uri = null; - if (response == Gtk.ResponseType.ACCEPT) + while (true) { + var response = save_dialog.run (); + if (response != Gtk.ResponseType.ACCEPT) + break; + var extension = ""; Gtk.TreeIter i; if (file_type_combo.get_active_iter (out i)) @@ -602,6 +611,20 @@ public class UserInterface : Gtk.ApplicationWindow path += extension; uri = File.new_for_path (path).get_uri (); + + /* Check the file(s) don't already exist */ + var files = new List (); + var format = uri_to_format (uri); + if (format == "jpeg" || format == "png") + { + for (var j = 0; j < book.n_pages; j++) + files.append (book.make_indexed_file (uri, j)); + } + else + files.append (File.new_for_uri (uri)); + + if (check_overwrite (save_dialog, files)) + break; } settings.set_string ("save-directory", save_dialog.get_current_folder ()); @@ -612,13 +635,43 @@ public class UserInterface : Gtk.ApplicationWindow return uri; } - private bool save_document (bool force_choose_location) + private bool check_overwrite (Gtk.Window parent, List files) + { + foreach (var file in files) + { + if (!file.query_exists ()) + continue; + + var dialog = new Gtk.MessageDialog (parent, Gtk.DialogFlags.MODAL | Gtk.DialogFlags.DESTROY_WITH_PARENT, Gtk.MessageType.QUESTION, Gtk.ButtonsType.NONE, + /* Contents of dialog that shows if saving would overwrite and existing file. %s is replaced with the name of the file. */ + _("A file named “%s” already exists. Do you want to replace it?"), file.get_basename ()); + dialog.add_button (_("_Cancel"), Gtk.ResponseType.CANCEL); + dialog.add_button (/* Button in dialog that shows if saving would overwrite and existing file. Clicking the button allows simple-scan to overwrite the file. */ + _("_Replace"), Gtk.ResponseType.ACCEPT); + var response = dialog.run (); + dialog.destroy (); + + if (response != Gtk.ResponseType.ACCEPT) + return false; + } + + return true; + } + + private string uri_to_format (string uri) { - string? uri; - if (book_uri != null && !force_choose_location) - uri = book_uri; + var uri_lower = uri.down (); + if (uri_lower.has_suffix (".pdf")) + return "pdf"; + else if (uri_lower.has_suffix (".png")) + return "png"; else - uri = choose_file_location (); + return "jpeg"; + } + + private bool save_document () + { + var uri = choose_file_location (); if (uri == null) return false; @@ -626,16 +679,7 @@ public class UserInterface : Gtk.ApplicationWindow debug ("Saving to '%s'", uri); - var uri_lower = uri.down (); - string format = "jpeg"; - if (uri_lower.has_suffix (".pdf")) - format = "pdf"; - else if (uri_lower.has_suffix (".ps")) - format = "ps"; - else if (uri_lower.has_suffix (".png")) - format = "png"; - else if (uri_lower.has_suffix (".tif") || uri_lower.has_suffix (".tiff")) - format = "tiff"; + var format = uri_to_format (uri); show_progress_dialog (); try @@ -653,14 +697,14 @@ public class UserInterface : Gtk.ApplicationWindow return false; } + book_needs_saving = false; book_uri = uri; - book.needs_saving = false; return true; } private bool prompt_to_save (string title, string discard_label) { - if (!book.needs_saving) + if (!book_needs_saving) return true; var dialog = new Gtk.MessageDialog (this, @@ -681,7 +725,7 @@ public class UserInterface : Gtk.ApplicationWindow switch (response) { case Gtk.ResponseType.YES: - if (save_document (false)) + if (save_document ()) return true; else return false; @@ -694,11 +738,18 @@ public class UserInterface : Gtk.ApplicationWindow private void clear_document () { + book_view.default_page = new Page (default_page_width, + default_page_height, + default_page_dpi, + default_page_scan_direction); book.clear (); - add_default_page (); + book_needs_saving = false; book_uri = null; - book.needs_saving = false; - save_as_menuitem.sensitive = false; + save_menuitem.sensitive = false; + email_menuitem.sensitive = false; + print_menuitem.sensitive = false; + save_button.sensitive = false; + save_toolbutton.sensitive = false; copy_to_clipboard_menuitem.sensitive = false; } @@ -866,6 +917,7 @@ public class UserInterface : Gtk.ApplicationWindow get_paper_size (out options.paper_width, out options.paper_height); options.brightness = brightness; options.contrast = contrast; + options.page_delay = page_delay; return options; } @@ -897,6 +949,14 @@ public class UserInterface : Gtk.ApplicationWindow } } + [GtkCallback] + private void batch_button_clicked_cb (Gtk.Widget widget) + { + var options = make_scan_options (); + options.type = ScanType.BATCH; + start_scan (selected_device, options); + } + [GtkCallback] private void preferences_button_clicked_cb (Gtk.Widget widget) { @@ -977,14 +1037,14 @@ public class UserInterface : Gtk.ApplicationWindow private void show_page_cb (BookView view, Page page) { - var path = get_temporary_filename ("scanned-page", "tiff"); + var path = get_temporary_filename ("scanned-page", "png"); if (path == null) return; var file = File.new_for_path (path); try { - page.save ("tiff", quality, file); + page.save ("png", quality, file); } catch (Error e) { @@ -1347,12 +1407,12 @@ public class UserInterface : Gtk.ApplicationWindow [GtkCallback] private void save_file_button_clicked_cb (Gtk.Widget widget) { - save_document (false); + save_document (); } public void save_document_activate_cb () { - save_document (false); + save_document (); } [GtkCallback] @@ -1363,17 +1423,6 @@ public class UserInterface : Gtk.ApplicationWindow page.copy_to_clipboard (this); } - [GtkCallback] - private void save_as_file_button_clicked_cb (Gtk.Widget widget) - { - save_document (true); - } - - public void save_as_document_activate_cb () - { - save_document (true); - } - private void draw_page (Gtk.PrintOperation operation, Gtk.PrintContext print_context, int page_number) @@ -1761,10 +1810,6 @@ public class UserInterface : Gtk.ApplicationWindow page.size_changed.disconnect (page_size_changed_cb); page.scan_direction_changed.disconnect (page_scan_direction_changed_cb); - /* If this is the last page add a new blank one */ - if (book.n_pages == 0) - add_default_page (); - update_page_menu (); } @@ -1801,13 +1846,14 @@ public class UserInterface : Gtk.ApplicationWindow } } - private void needs_saving_cb (Book book) + private void book_changed_cb (Book book) { - save_menuitem.sensitive = book.needs_saving; - save_button.sensitive = book.needs_saving; - save_toolbutton.sensitive = book.needs_saving; - if (book.needs_saving) - save_as_menuitem.sensitive = true; + save_menuitem.sensitive = true; + email_menuitem.sensitive = true; + print_menuitem.sensitive = true; + save_button.sensitive = true; + save_toolbutton.sensitive = true; + book_needs_saving = true; copy_to_clipboard_menuitem.sensitive = true; } @@ -1840,7 +1886,6 @@ public class UserInterface : Gtk.ApplicationWindow section.append_submenu (_("Document"), menu); menu.append (_("Reorder Pages"), "app.reorder"); menu.append (_("Save"), "app.save"); - menu.append (_("Save As..."), "app.save_as"); menu.append (_("Email..."), "app.email"); menu.append (_("Print..."), "app.print"); @@ -1858,7 +1903,6 @@ public class UserInterface : Gtk.ApplicationWindow app.add_accelerator ("N", "app.new_document", null); app.add_accelerator ("S", "app.save", null); - app.add_accelerator ("S", "app.save_as", null); app.add_accelerator ("E", "app.email", null); app.add_accelerator ("P", "app.print", null); app.add_accelerator ("F1", "app.help", null); @@ -1973,6 +2017,18 @@ public class UserInterface : Gtk.ApplicationWindow quality = settings.get_int ("jpeg-quality"); quality_adjustment.value_changed.connect (() => { settings.set_int ("jpeg-quality", quality); }); + page_delay_scale.add_mark (0, Gtk.PositionType.BOTTOM, null); + page_delay_scale.add_mark (500, Gtk.PositionType.BOTTOM, null); + page_delay_scale.add_mark (1000, Gtk.PositionType.BOTTOM, null); + page_delay_scale.add_mark (2000, Gtk.PositionType.BOTTOM, null); + page_delay_scale.add_mark (4000, Gtk.PositionType.BOTTOM, null); + page_delay_scale.add_mark (6000, Gtk.PositionType.BOTTOM, null); + page_delay_scale.add_mark (8000, Gtk.PositionType.BOTTOM, null); + page_delay_scale.add_mark (10000, Gtk.PositionType.BOTTOM, null); + page_delay = settings.get_int ("page-delay"); + page_delay_scale.format_value.connect ((value) => { return "%.1fs".printf (value / 1000.0); }); + page_delay_adjustment.value_changed.connect (() => { settings.set_int ("page-delay", page_delay); }); + var document_type = settings.get_string ("document-type"); if (document_type != null) set_document_hint (document_type); -- cgit v1.2.3 From ab6556e393162fff0e0e0c80a9fff689b4e2ca05 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?J=C3=B6rg=20Frings-F=C3=BCrst?= Date: Sat, 11 Nov 2017 18:47:31 +0100 Subject: New upstream version 3.26.2 --- src/app-window.ui | 872 +++++++++++++++ src/app-window.vala | 1840 +++++++++++++++++++++++++++++++ src/authorize-dialog.ui | 141 +++ src/authorize-dialog.vala | 37 + src/book-view.vala | 38 +- src/book.vala | 781 +++++++++----- src/help-overlay.ui | 128 +++ src/libwebp.vapi | 55 + src/libwebpmux.vapi | 128 +++ src/meson.build | 9 +- src/page.vala | 63 +- src/preferences-dialog.ui | 608 +++++++++++ src/preferences-dialog.vala | 534 +++++++++ src/screensaver.vala | 25 + src/simple-scan.gresource.xml | 7 +- src/simple-scan.ui | 1454 ------------------------- src/simple-scan.vala | 175 ++- src/ui.vala | 2398 ----------------------------------------- 18 files changed, 5013 insertions(+), 4280 deletions(-) create mode 100644 src/app-window.ui create mode 100644 src/app-window.vala create mode 100644 src/authorize-dialog.ui create mode 100644 src/authorize-dialog.vala create mode 100644 src/help-overlay.ui create mode 100644 src/libwebp.vapi create mode 100644 src/libwebpmux.vapi create mode 100644 src/preferences-dialog.ui create mode 100644 src/preferences-dialog.vala create mode 100644 src/screensaver.vala delete mode 100644 src/simple-scan.ui delete mode 100644 src/ui.vala (limited to 'src') diff --git a/src/app-window.ui b/src/app-window.ui new file mode 100644 index 0000000..bbdf1c7 --- /dev/null +++ b/src/app-window.ui @@ -0,0 +1,872 @@ + + + + + + True + False + mail-send + + + True + False + gtk-help + + + True + False + + + True + False + Single _Page + True + + + + + + True + False + All Pages From _Feeder + True + + + + + + True + False + _Multiple Pages From Flatbed + True + + + + + + True + False + + + + + True + False + Text + True + True + + + + + + True + False + Photo + True + True + True + text_button_hb_menuitem + + + + + + + True + False + + + True + False + Single _Page + True + + + + + + True + False + All Pages From _Feeder + True + + + + + + True + False + _Multiple Pages From Flatbed + True + + + + + + True + False + + + + + True + False + Text + True + True + + + + + + True + False + Photo + True + True + True + text_button_menuitem + + + + + diff --git a/src/app-window.vala b/src/app-window.vala new file mode 100644 index 0000000..2cd75ee --- /dev/null +++ b/src/app-window.vala @@ -0,0 +1,1840 @@ +/* + * Copyright (C) 2009-2015 Canonical Ltd. + * Author: Robert Ancell , + * Eduard Gotwig + * + * This program is free software: you can redistribute it and/or modify it under + * the terms of the GNU General Public License as published by the Free Software + * Foundation, either version 3 of the License, or (at your option) any later + * version. See http://www.gnu.org/copyleft/gpl.html the full text of the + * license. + */ + +private const int DEFAULT_TEXT_DPI = 150; +private const int DEFAULT_PHOTO_DPI = 300; + +[GtkTemplate (ui = "/org/gnome/SimpleScan/app-window.ui")] +public class AppWindow : Gtk.ApplicationWindow +{ + private const GLib.ActionEntry[] action_entries = + { + { "new_document", new_document_activate_cb }, + { "reorder", reorder_document_activate_cb }, + { "save", save_document_activate_cb }, + { "email", email_document_activate_cb }, + { "print", print_document_activate_cb }, + { "preferences", preferences_activate_cb }, + { "help", help_contents_activate_cb }, + { "about", about_activate_cb }, + { "quit", quit_activate_cb } + }; + + private Settings settings; + + private PreferencesDialog preferences_dialog; + + [GtkChild] + private Gtk.HeaderBar header_bar; + [GtkChild] + private Gtk.MenuBar menubar; + [GtkChild] + private Gtk.Toolbar toolbar; + [GtkChild] + private Gtk.Menu page_menu; + [GtkChild] + private Gtk.Stack stack; + [GtkChild] + private Gtk.Label status_primary_label; + [GtkChild] + private Gtk.Label status_secondary_label; + [GtkChild] + private Gtk.Box main_vbox; + [GtkChild] + private Gtk.RadioMenuItem custom_crop_menuitem; + [GtkChild] + private Gtk.RadioMenuItem a4_menuitem; + [GtkChild] + private Gtk.RadioMenuItem a5_menuitem; + [GtkChild] + private Gtk.RadioMenuItem a6_menuitem; + [GtkChild] + private Gtk.RadioMenuItem letter_menuitem; + [GtkChild] + private Gtk.RadioMenuItem legal_menuitem; + [GtkChild] + private Gtk.RadioMenuItem four_by_six_menuitem; + [GtkChild] + private Gtk.RadioMenuItem no_crop_menuitem; + [GtkChild] + private Gtk.MenuItem page_move_left_menuitem; + [GtkChild] + private Gtk.MenuItem page_move_right_menuitem; + [GtkChild] + private Gtk.MenuItem page_delete_menuitem; + [GtkChild] + private Gtk.MenuItem crop_rotate_menuitem; + [GtkChild] + private Gtk.MenuItem save_menuitem; + [GtkChild] + private Gtk.MenuItem email_menuitem; + [GtkChild] + private Gtk.MenuItem print_menuitem; + [GtkChild] + private Gtk.MenuItem copy_to_clipboard_menuitem; + [GtkChild] + private Gtk.Button save_button; + [GtkChild] + private Gtk.ToolButton save_toolbutton; + [GtkChild] + private Gtk.MenuItem stop_scan_menuitem; + [GtkChild] + private Gtk.ToolButton stop_toolbutton; + [GtkChild] + private Gtk.Button stop_button; + [GtkChild] + private Gtk.Button scan_button; + [GtkChild] + private Gtk.ActionBar action_bar; + private Gtk.ToggleButton crop_button; + private Gtk.Button delete_button; + + [GtkChild] + private Gtk.RadioMenuItem text_button_menuitem; + [GtkChild] + private Gtk.RadioMenuItem text_button_hb_menuitem; + [GtkChild] + private Gtk.RadioMenuItem text_menuitem; + [GtkChild] + private Gtk.RadioMenuItem photo_button_menuitem; + [GtkChild] + private Gtk.RadioMenuItem photo_button_hb_menuitem; + [GtkChild] + private Gtk.RadioMenuItem photo_menuitem; + + [GtkChild] + private Gtk.MenuButton menu_button; + + private string? missing_driver = null; + + private Gtk.FileChooserDialog? save_dialog; + + public Book book { get; private set; } + private bool book_needs_saving; + private string? book_uri = null; + + public Page selected_page + { + get + { + return book_view.selected_page; + } + set + { + book_view.selected_page = value; + } + } + + private AutosaveManager autosave_manager; + + private BookView book_view; + private bool updating_page_menu; + + private string document_hint = "photo"; + + private bool scanning_ = false; + public bool scanning + { + get { return scanning_; } + set + { + scanning_ = value; + stack.set_visible_child_name ("document"); + page_delete_menuitem.sensitive = !value; + delete_button.sensitive = !value; + stop_scan_menuitem.sensitive = value; + stop_toolbutton.sensitive = value; + scan_button.visible = !value; + stop_button.visible = value; + } + } + + private int window_width; + private int window_height; + private bool window_is_maximized; + private bool window_is_fullscreen; + + private uint save_state_timeout; + + public int brightness + { + get { return preferences_dialog.get_brightness (); } + set { preferences_dialog.set_brightness (value); } + } + + public int contrast + { + get { return preferences_dialog.get_contrast (); } + set { preferences_dialog.set_contrast (value); } + } + + public int page_delay + { + get { return preferences_dialog.get_page_delay (); } + set { preferences_dialog.set_page_delay (value); } + } + + public string? selected_device + { + owned get { return preferences_dialog.get_selected_device (); } + set { preferences_dialog.set_selected_device (value); } + } + + public signal void start_scan (string? device, ScanOptions options); + public signal void stop_scan (); + + public AppWindow () + { + settings = new Settings ("org.gnome.SimpleScan"); + + book = new Book (); + book.page_added.connect (page_added_cb); + book.reordered.connect (reordered_cb); + book.page_removed.connect (page_removed_cb); + book.changed.connect (book_changed_cb); + + load (); + + clear_document (); + autosave_manager = new AutosaveManager (); + autosave_manager.book = book; + autosave_manager.load (); + + if (book.n_pages == 0) + book_needs_saving = false; + else + { + stack.set_visible_child_name ("document"); + book_view.selected_page = book.get_page (0); + book_needs_saving = true; + book_changed_cb (book); + } + } + + ~AppWindow () + { + book.page_added.disconnect (page_added_cb); + book.reordered.disconnect (reordered_cb); + book.page_removed.disconnect (page_removed_cb); + } + + public void show_error_dialog (string error_title, string error_text) + { + var dialog = new Gtk.MessageDialog (this, + Gtk.DialogFlags.MODAL, + Gtk.MessageType.WARNING, + Gtk.ButtonsType.NONE, + "%s", error_title); + dialog.add_button (_("_Close"), 0); + dialog.format_secondary_text ("%s", error_text); + dialog.run (); + dialog.destroy (); + } + + public void authorize (string resource, out string username, out string password) + { + /* Label in authorization dialog. “%s” is replaced with the name of the resource requesting authorization */ + var description = _("Username and password required to access “%s”").printf (resource); + var authorize_dialog = new AuthorizeDialog (description); + authorize_dialog.visible = true; + authorize_dialog.transient_for = this; + authorize_dialog.run (); + authorize_dialog.destroy (); + + username = authorize_dialog.get_username (); + password = authorize_dialog.get_password (); + } + + public void set_scan_devices (List devices, string? missing_driver = null) + { + this.missing_driver = missing_driver; + + preferences_dialog.set_scan_devices (devices); + + if (devices != null) + { + status_primary_label.set_text (/* Label shown when detected a scanner */ + _("Ready to Scan")); + status_secondary_label.set_text (preferences_dialog.get_selected_device_label ()); + status_secondary_label.visible = true; + } + else if (missing_driver != null) + { + status_primary_label.set_text (/* Warning displayed when no drivers are installed but a compatible scanner is detected */ + _("Additional software needed")); + /* Instructions to install driver software */ + status_secondary_label.set_markup (_("You need to install driver software for your scanner.")); + status_secondary_label.visible = true; + } + else + { + /* Warning displayed when no scanners are detected */ + status_primary_label.set_text (_("No scanners detected")); + /* Hint to user on why there are no scanners detected */ + status_secondary_label.set_text (_("Please check your scanner is connected and powered on")); + status_secondary_label.visible = true; + } + } + + private string choose_file_location () + { + /* Get directory to save to */ + string? directory = null; + directory = settings.get_string ("save-directory"); + + if (directory == null || directory == "") + directory = Environment.get_user_special_dir (UserDirectory.DOCUMENTS); + + save_dialog = new Gtk.FileChooserDialog (/* Save dialog: Dialog title */ + _("Save As…"), + this, + Gtk.FileChooserAction.SAVE, + _("_Cancel"), Gtk.ResponseType.CANCEL, + _("_Save"), Gtk.ResponseType.ACCEPT, + null); + save_dialog.local_only = false; + if (book_uri != null) + save_dialog.set_uri (book_uri); + else { + save_dialog.set_current_folder (directory); + /* Default filename to use when saving document */ + save_dialog.set_current_name (_("Scanned Document.pdf")); + } + + /* Filter to only show images by default */ + var filter = new Gtk.FileFilter (); + filter.set_filter_name (/* Save dialog: Filter name to show only supported image files */ + _("Image Files")); + filter.add_mime_type ("image/jpeg"); + filter.add_mime_type ("image/png"); +#if HAVE_WEBP + filter.add_mime_type ("image/webp"); +#endif + filter.add_mime_type ("application/pdf"); + save_dialog.add_filter (filter); + filter = new Gtk.FileFilter (); + filter.set_filter_name (/* Save dialog: Filter name to show all files */ + _("All Files")); + filter.add_pattern ("*"); + save_dialog.add_filter (filter); + + var file_type_store = new Gtk.ListStore (2, typeof (string), typeof (string)); + Gtk.TreeIter iter; + file_type_store.append (out iter); + file_type_store.set (iter, + /* Save dialog: Label for saving in PDF format */ + 0, _("PDF (multi-page document)"), + 1, ".pdf", + -1); + file_type_store.append (out iter); + file_type_store.set (iter, + /* Save dialog: Label for saving in JPEG format */ + 0, _("JPEG (compressed)"), + 1, ".jpg", + -1); + file_type_store.append (out iter); + file_type_store.set (iter, + /* Save dialog: Label for saving in PNG format */ + 0, _("PNG (lossless)"), + 1, ".png", + -1); +#if HAVE_WEBP + file_type_store.append (out iter); + file_type_store.set (iter, + /* Save dialog: Label for sabing in WEBP format */ + 0, _("WebP (compressed)"), + 1, ".webp", + -1); +#endif + + var box = new Gtk.Box (Gtk.Orientation.HORIZONTAL, 6); + box.visible = true; + save_dialog.set_extra_widget (box); + + /* Label in save dialog beside combo box to choose file format (PDF, JPEG, PNG, WEBP) */ + var label = new Gtk.Label (_("File format:")); + label.visible = true; + box.pack_start (label, false, false, 0); + + var file_type_combo = new Gtk.ComboBox.with_model (file_type_store); + file_type_combo.visible = true; + var renderer = new Gtk.CellRendererText (); + file_type_combo.pack_start (renderer, true); + file_type_combo.add_attribute (renderer, "text", 0); + box.pack_start (file_type_combo, false, true, 0); + + /* Label in save dialog beside compression slider */ + var quality_label = new Gtk.Label (_("Compression:")); + box.pack_start (quality_label, false, false, 0); + + var quality_adjustment = new Gtk.Adjustment (75, 0, 100, 1, 10, 0); + var quality_scale = new Gtk.Scale (Gtk.Orientation.HORIZONTAL, quality_adjustment); + quality_scale.width_request = 200; + quality_scale.draw_value = false; + quality_scale.add_mark (0, Gtk.PositionType.BOTTOM, null); + quality_scale.add_mark (75, Gtk.PositionType.BOTTOM, null); + quality_scale.add_mark (90, Gtk.PositionType.BOTTOM, null); + quality_scale.add_mark (100, Gtk.PositionType.BOTTOM, null); + quality_adjustment.value = settings.get_int ("jpeg-quality"); + quality_adjustment.value_changed.connect (() => { settings.set_int ("jpeg-quality", (int) quality_adjustment.value); }); + box.pack_start (quality_scale, false, false, 0); + + file_type_combo.set_active (0); + file_type_combo.changed.connect (() => + { + var extension = ""; + Gtk.TreeIter i; + if (file_type_combo.get_active_iter (out i)) + file_type_store.get (i, 1, out extension, -1); + + var path = save_dialog.get_filename (); + var filename = Path.get_basename (path); + + /* Replace extension */ + var extension_index = filename.last_index_of_char ('.'); + if (extension_index >= 0) + filename = filename.slice (0, extension_index); + filename = filename + extension; + save_dialog.set_current_name (filename); + + /* Quality not applicable to PNG */ + quality_scale.visible = quality_label.visible = (extension != ".png"); + }); + + string? uri = null; + while (true) + { + var response = save_dialog.run (); + if (response != Gtk.ResponseType.ACCEPT) + break; + + var extension = ""; + Gtk.TreeIter i; + if (file_type_combo.get_active_iter (out i)) + file_type_store.get (i, 1, out extension, -1); + + var path = save_dialog.get_filename (); + var filename = Path.get_basename (path); + + var extension_index = filename.last_index_of_char ('.'); + if (extension_index < 0) + path += extension; + + uri = File.new_for_path (path).get_uri (); + + /* Check the file(s) don't already exist */ + var files = new List (); + var format = uri_to_format (uri); +#if HAVE_WEBP + if (format == "jpeg" || format == "png" || format == "webp") +#else + if (format == "jpeg" || format == "png") +#endif + { + for (var j = 0; j < book.n_pages; j++) + files.append (make_indexed_file (uri, j, book.n_pages)); + } + else + files.append (File.new_for_uri (uri)); + + if (check_overwrite (save_dialog, files)) + break; + } + + settings.set_string ("save-directory", save_dialog.get_current_folder ()); + + save_dialog.destroy (); + save_dialog = null; + + return uri; + } + + private bool check_overwrite (Gtk.Window parent, List files) + { + foreach (var file in files) + { + if (!file.query_exists ()) + continue; + + var dialog = new Gtk.MessageDialog (parent, Gtk.DialogFlags.MODAL | Gtk.DialogFlags.DESTROY_WITH_PARENT, Gtk.MessageType.QUESTION, Gtk.ButtonsType.NONE, + /* Contents of dialog that shows if saving would overwrite and existing file. %s is replaced with the name of the file. */ + _("A file named “%s” already exists. Do you want to replace it?"), file.get_basename ()); + dialog.add_button (_("_Cancel"), Gtk.ResponseType.CANCEL); + dialog.add_button (/* Button in dialog that shows if saving would overwrite and existing file. Clicking the button allows simple-scan to overwrite the file. */ + _("_Replace"), Gtk.ResponseType.ACCEPT); + var response = dialog.run (); + dialog.destroy (); + + if (response != Gtk.ResponseType.ACCEPT) + return false; + } + + return true; + } + + private string uri_to_format (string uri) + { + var uri_lower = uri.down (); + if (uri_lower.has_suffix (".pdf")) + return "pdf"; + else if (uri_lower.has_suffix (".png")) + return "png"; +#if HAVE_WEBP + else if (uri_lower.has_suffix (".webp")) + return "webp"; +#endif + else + return "jpeg"; + } + + private async bool save_document_async () + { + var uri = choose_file_location (); + if (uri == null) + return false; + + var file = File.new_for_uri (uri); + + debug ("Saving to '%s'", uri); + + var format = uri_to_format (uri); + + var cancellable = new Cancellable (); + var progress_bar = new CancellableProgressBar (_("Saving"), cancellable); + action_bar.pack_end (progress_bar); + progress_bar.visible = true; + try + { + yield book.save_async (format, settings.get_int ("jpeg-quality"), file, (fraction) => + { + progress_bar.set_fraction (fraction); + }, cancellable); + } + catch (Error e) + { + progress_bar.destroy (); + warning ("Error saving file: %s", e.message); + show_error_dialog (/* Title of error dialog when save failed */ + _("Failed to save file"), + e.message); + return false; + } + progress_bar.destroy_with_delay (500); + + book_needs_saving = false; + book_uri = uri; + return true; + } + + private async bool prompt_to_save_async (string title, string discard_label) + { + if (!book_needs_saving) + return true; + + var dialog = new Gtk.MessageDialog (this, + Gtk.DialogFlags.MODAL, + Gtk.MessageType.WARNING, + Gtk.ButtonsType.NONE, + "%s", title); + dialog.format_secondary_text ("%s", + /* Text in dialog warning when a document is about to be lost*/ + _("If you don’t save, changes will be permanently lost.")); + dialog.add_button (discard_label, Gtk.ResponseType.NO); + dialog.add_button (_("_Cancel"), Gtk.ResponseType.CANCEL); + dialog.add_button (_("_Save"), Gtk.ResponseType.YES); + + var response = dialog.run (); + dialog.destroy (); + + switch (response) + { + case Gtk.ResponseType.YES: + if (yield save_document_async ()) + return true; + else + return false; + case Gtk.ResponseType.NO: + return true; + default: + return false; + } + } + + private void clear_document () + { + book.clear (); + book_needs_saving = false; + book_uri = null; + save_menuitem.sensitive = false; + email_menuitem.sensitive = false; + print_menuitem.sensitive = false; + save_button.sensitive = false; + save_toolbutton.sensitive = false; + copy_to_clipboard_menuitem.sensitive = false; + status_primary_label.set_text (/* Label shown when detected a scanner */ + _("Ready to Scan")); + stack.set_visible_child_name ("startup"); + } + + private void new_document () + { + prompt_to_save_async.begin (/* Text in dialog warning when a document is about to be lost */ + _("Save current document?"), + /* Button in dialog to create new document and discard unsaved document */ + _("Discard Changes"), (obj, res) => + { + if (!prompt_to_save_async.end(res)) + return; + + if (scanning) + stop_scan (); + + clear_document (); + }); + } + + [GtkCallback] + private bool status_label_activate_link_cb (Gtk.Label label, string uri) + { + if (uri == "install-firmware") + { + install_drivers (); + return true; + } + + return false; + } + + [GtkCallback] + private void new_button_clicked_cb (Gtk.Widget widget) + { + new_document(); + } + + public void new_document_activate_cb () + { + new_document(); + } + + private void set_document_hint (string document_hint, bool save = false) + { + this.document_hint = document_hint; + + if (document_hint == "text") + { + text_button_menuitem.active = true; + text_button_hb_menuitem.active = true; + text_menuitem.active = true; + } + else if (document_hint == "photo") + { + photo_button_menuitem.active = true; + photo_button_hb_menuitem.active = true; + photo_menuitem.active = true; + } + + if (save) + settings.set_string ("document-type", document_hint); + } + + [GtkCallback] + private void text_menuitem_toggled_cb (Gtk.CheckMenuItem widget) + { + if (widget.active) + set_document_hint ("text", true); + } + + [GtkCallback] + private void photo_menuitem_toggled_cb (Gtk.CheckMenuItem widget) + { + if (widget.active) + set_document_hint ("photo", true); + } + + private ScanOptions make_scan_options () + { + var options = new ScanOptions (); + if (document_hint == "text") + { + options.scan_mode = ScanMode.GRAY; + options.dpi = preferences_dialog.get_text_dpi (); + options.depth = 2; + } + else + { + options.scan_mode = ScanMode.COLOR; + options.dpi = preferences_dialog.get_photo_dpi (); + options.depth = 8; + } + preferences_dialog.get_paper_size (out options.paper_width, out options.paper_height); + options.brightness = brightness; + options.contrast = contrast; + options.page_delay = page_delay; + + return options; + } + + [GtkCallback] + private void scan_button_clicked_cb (Gtk.Widget widget) + { + var options = make_scan_options (); + options.type = ScanType.SINGLE; + status_primary_label.set_text (/* Label shown when scan started */ + _("Contacting scanner…")); + start_scan (selected_device, options); + } + + [GtkCallback] + private void stop_scan_button_clicked_cb (Gtk.Widget widget) + { + stop_scan (); + } + + [GtkCallback] + private void continuous_scan_button_clicked_cb (Gtk.Widget widget) + { + if (scanning) + stop_scan (); + else + { + var options = make_scan_options (); + options.type = preferences_dialog.get_page_side (); + start_scan (selected_device, options); + } + } + + [GtkCallback] + private void batch_button_clicked_cb (Gtk.Widget widget) + { + var options = make_scan_options (); + options.type = ScanType.BATCH; + start_scan (selected_device, options); + } + + [GtkCallback] + private void preferences_button_clicked_cb (Gtk.Widget widget) + { + preferences_dialog.present (); + } + + public void preferences_activate_cb () + { + preferences_dialog.present (); + } + + private void update_page_menu () + { + var page = book_view.selected_page; + if (page == null) + { + page_move_left_menuitem.sensitive = false; + page_move_right_menuitem.sensitive = false; + } + else + { + var index = book.get_page_index (page); + page_move_left_menuitem.sensitive = index > 0; + page_move_right_menuitem.sensitive = index < book.n_pages - 1; + } + } + + private void page_selected_cb (BookView view, Page? page) + { + if (page == null) + return; + + updating_page_menu = true; + + update_page_menu (); + + var menuitem = no_crop_menuitem; + if (page.has_crop) + { + var crop_name = page.crop_name; + if (crop_name != null) + { + if (crop_name == "A4") + menuitem = a4_menuitem; + else if (crop_name == "A5") + menuitem = a5_menuitem; + else if (crop_name == "A6") + menuitem = a6_menuitem; + else if (crop_name == "letter") + menuitem = letter_menuitem; + else if (crop_name == "legal") + menuitem = legal_menuitem; + else if (crop_name == "4x6") + menuitem = four_by_six_menuitem; + } + else + menuitem = custom_crop_menuitem; + } + + menuitem.active = true; + crop_button.active = page.has_crop; + + updating_page_menu = false; + } + + private void show_page_cb (BookView view, Page page) + { + File file; + try + { + var dir = DirUtils.make_tmp ("simple-scan-XXXXXX"); + file = File.new_for_path (Path.build_filename (dir, "scan.png")); + page.save_png (file); + } + catch (Error e) + { + show_error_dialog (/* Error message display when unable to save image for preview */ + _("Unable to save image for preview"), + e.message); + return; + } + + try + { + Gtk.show_uri (screen, file.get_uri (), Gtk.get_current_event_time ()); + } + catch (Error e) + { + show_error_dialog (/* Error message display when unable to preview image */ + _("Unable to open image preview application"), + e.message); + } + } + + private void show_page_menu_cb (BookView view) + { + page_menu.popup (null, null, null, 3, Gtk.get_current_event_time ()); + } + + [GtkCallback] + private void rotate_left_button_clicked_cb (Gtk.Widget widget) + { + if (updating_page_menu) + return; + var page = book_view.selected_page; + if (page != null) + page.rotate_left (); + } + + [GtkCallback] + private void rotate_right_button_clicked_cb (Gtk.Widget widget) + { + if (updating_page_menu) + return; + var page = book_view.selected_page; + if (page != null) + page.rotate_right (); + } + + private void set_crop (string? crop_name) + { + crop_rotate_menuitem.sensitive = crop_name != null; + + if (updating_page_menu) + return; + + var page = book_view.selected_page; + if (page == null) + { + warning ("Trying to set crop but no selected page"); + return; + } + + if (crop_name == null) + page.set_no_crop (); + else if (crop_name == "custom") + { + var width = page.width; + var height = page.height; + var crop_width = (int) (width * 0.8 + 0.5); + var crop_height = (int) (height * 0.8 + 0.5); + page.set_custom_crop (crop_width, crop_height); + page.move_crop ((width - crop_width) / 2, (height - crop_height) / 2); + } + else + page.set_named_crop (crop_name); + } + + [GtkCallback] + private void no_crop_menuitem_toggled_cb (Gtk.CheckMenuItem widget) + { + if (widget.active) + set_crop (null); + } + + [GtkCallback] + private void custom_crop_menuitem_toggled_cb (Gtk.CheckMenuItem widget) + { + if (widget.active) + set_crop ("custom"); + } + + [GtkCallback] + private void four_by_six_menuitem_toggled_cb (Gtk.CheckMenuItem widget) + { + if (widget.active) + set_crop ("4x6"); + } + + [GtkCallback] + private void legal_menuitem_toggled_cb (Gtk.CheckMenuItem widget) + { + if (widget.active) + set_crop ("legal"); + } + + [GtkCallback] + private void letter_menuitem_toggled_cb (Gtk.CheckMenuItem widget) + { + if (widget.active) + set_crop ("letter"); + } + + [GtkCallback] + private void a6_menuitem_toggled_cb (Gtk.CheckMenuItem widget) + { + if (widget.active) + set_crop ("A6"); + } + + [GtkCallback] + private void a5_menuitem_toggled_cb (Gtk.CheckMenuItem widget) + { + if (widget.active) + set_crop ("A5"); + } + + [GtkCallback] + private void a4_menuitem_toggled_cb (Gtk.CheckMenuItem widget) + { + if (widget.active) + set_crop ("A4"); + } + + [GtkCallback] + private void crop_rotate_menuitem_activate_cb (Gtk.Widget widget) + { + var page = book_view.selected_page; + if (page == null) + return; + page.rotate_crop (); + } + + [GtkCallback] + private void page_move_left_menuitem_activate_cb (Gtk.Widget widget) + { + var page = book_view.selected_page; + var index = book.get_page_index (page); + if (index > 0) + book.move_page (page, index - 1); + } + + [GtkCallback] + private void page_move_right_menuitem_activate_cb (Gtk.Widget widget) + { + var page = book_view.selected_page; + var index = book.get_page_index (page); + if (index < book.n_pages - 1) + book.move_page (page, book.get_page_index (page) + 1); + } + + [GtkCallback] + private void page_delete_menuitem_activate_cb (Gtk.Widget widget) + { + book_view.book.delete_page (book_view.selected_page); + } + + private void reorder_document () + { + var dialog = new Gtk.Window (); + dialog.type_hint = Gdk.WindowTypeHint.DIALOG; + dialog.modal = true; + dialog.border_width = 12; + /* Title of dialog to reorder pages */ + dialog.title = _("Reorder Pages"); + dialog.set_transient_for (this); + dialog.key_press_event.connect ((e) => + { + if (e.state == 0 && e.keyval == Gdk.Key.Escape) + { + dialog.destroy (); + return true; + } + + return false; + }); + dialog.visible = true; + + var g = new Gtk.Grid (); + g.row_homogeneous = true; + g.row_spacing = 6; + g.column_homogeneous = true; + g.column_spacing = 6; + g.visible = true; + dialog.add (g); + + /* Label on button for combining sides in reordering dialog */ + var b = make_reorder_button (_("Combine sides"), "F1F2F3B1B2B3-F1B1F2B2F3B3"); + b.clicked.connect (() => + { + book.combine_sides (); + dialog.destroy (); + }); + b.visible = true; + g.attach (b, 0, 0, 1, 1); + + /* Label on button for combining sides in reverse order in reordering dialog */ + b = make_reorder_button (_("Combine sides (reverse)"), "F1F2F3B3B2B1-F1B1F2B2F3B3"); + b.clicked.connect (() => + { + book.combine_sides_reverse (); + dialog.destroy (); + }); + b.visible = true; + g.attach (b, 1, 0, 1, 1); + + /* Label on button for reversing in reordering dialog */ + b = make_reorder_button (_("Reverse"), "C1C2C3C4C5C6-C6C5C4C3C2C1"); + b.clicked.connect (() => + { + book.reverse (); + dialog.destroy (); + }); + b.visible = true; + g.attach (b, 0, 2, 1, 1); + + /* Label on button for cancelling page reordering dialog */ + b = make_reorder_button (_("Keep unchanged"), "C1C2C3C4C5C6-C1C2C3C4C5C6"); + b.clicked.connect (() => + { + dialog.destroy (); + }); + b.visible = true; + g.attach (b, 1, 2, 1, 1); + + dialog.present (); + } + + public void reorder_document_activate_cb () + { + reorder_document (); + } + + [GtkCallback] + private void reorder_menuitem_activate_cb (Gtk.Widget widget) + { + reorder_document (); + } + + private Gtk.Button make_reorder_button (string text, string items) + { + var b = new Gtk.Button (); + + var vbox = new Gtk.Box (Gtk.Orientation.VERTICAL, 6); + vbox.visible = true; + b.add (vbox); + + var label = new Gtk.Label (text); + label.visible = true; + vbox.pack_start (label, true, true, 0); + + var rb = make_reorder_box (items); + rb.visible = true; + vbox.pack_start (rb, true, true, 0); + + return b; + } + + private Gtk.Box make_reorder_box (string items) + { + var box = new Gtk.Box (Gtk.Orientation.HORIZONTAL, 6); + box.visible = true; + + Gtk.Box? page_box = null; + for (var i = 0; items[i] != '\0'; i++) + { + if (items[i] == '-') + { + var a = new Gtk.Arrow (Gtk.ArrowType.RIGHT, Gtk.ShadowType.NONE); + a.visible = true; + box.pack_start (a, false, false, 0); + page_box = null; + continue; + } + + /* First character describes side */ + var side = items[i]; + i++; + if (items[i] == '\0') + break; + + if (page_box == null) + { + page_box = new Gtk.Box (Gtk.Orientation.HORIZONTAL, 3); + page_box.visible = true; + box.pack_start (page_box, false, false, 0); + } + + /* Get colours for each page (from Tango palette) */ + var r = 1.0; + var g = 1.0; + var b = 1.0; + switch (side) + { + case 'F': + /* Plum */ + r = 0x75 / 255.0; + g = 0x50 / 255.0; + b = 0x7B / 255.0; + break; + case 'B': + /* Orange */ + r = 0xF5 / 255.0; + g = 0x79 / 255.0; + b = 0.0; + break; + case 'C': + /* Butter to Scarlet Red */ + var p = (items[i] - '1') / 5.0; + r = (0xED / 255.0) * (1 - p) + 0xCC * p; + g = (0xD4 / 255.0) * (1 - p); + b = 0; + break; + } + + /* Mix with white to look more paper like */ + r = r + (1.0 - r) * 0.7; + g = g + (1.0 - g) * 0.7; + b = b + (1.0 - b) * 0.7; + + var icon = new PageIcon ("%c".printf (items[i]), r, g, b); + icon.visible = true; + page_box.pack_start (icon, false, false, 0); + } + + return box; + } + + [GtkCallback] + private void save_file_button_clicked_cb (Gtk.Widget widget) + { + save_document_async.begin (); + } + + public void save_document_activate_cb () + { + save_document_async.begin (); + } + + [GtkCallback] + private void copy_to_clipboard_button_clicked_cb (Gtk.Widget widget) + { + var page = book_view.selected_page; + if (page != null) + page.copy_to_clipboard (this); + } + + private void draw_page (Gtk.PrintOperation operation, + Gtk.PrintContext print_context, + int page_number) + { + var context = print_context.get_cairo_context (); + var page = book.get_page (page_number); + + /* Rotate to same aspect */ + bool is_landscape = false; + if (print_context.get_width () > print_context.get_height ()) + is_landscape = true; + if (page.is_landscape != is_landscape) + { + context.translate (print_context.get_width (), 0); + context.rotate (Math.PI_2); + } + + context.scale (print_context.get_dpi_x () / page.dpi, + print_context.get_dpi_y () / page.dpi); + + var image = page.get_image (true); + Gdk.cairo_set_source_pixbuf (context, image, 0, 0); + context.paint (); + } + + [GtkCallback] + private void email_button_clicked_cb (Gtk.Widget widget) + { + email_document_async.begin (); + } + + public void email_document_activate_cb () + { + email_document_async.begin (); + } + + private async void email_document_async () + { + try + { + var dir = DirUtils.make_tmp ("simple-scan-XXXXXX"); + var type = document_hint == "text" ? "pdf" : "jpeg"; + var file = File.new_for_path (Path.build_filename (dir, "scan." + type)); + yield book.save_async (type, settings.get_int ("jpeg-quality"), file, null, null); + var command_line = "xdg-email"; + if (type == "pdf") + command_line += "--attach %s".printf (file.get_path ()); + else + { + for (var i = 0; i < book.n_pages; i++) { + var indexed_file = make_indexed_file (file.get_uri (), i, book.n_pages); + command_line += " --attach %s".printf (indexed_file.get_path ()); + } + } + Process.spawn_command_line_async (command_line); + } + catch (Error e) + { + warning ("Unable to email document: %s", e.message); + } + } + + private void print_document () + { + var print = new Gtk.PrintOperation (); + print.n_pages = (int) book.n_pages; + print.draw_page.connect (draw_page); + + try + { + print.run (Gtk.PrintOperationAction.PRINT_DIALOG, this); + } + catch (Error e) + { + warning ("Error printing: %s", e.message); + } + + print.draw_page.disconnect (draw_page); + } + + [GtkCallback] + private void print_button_clicked_cb (Gtk.Widget widget) + { + print_document (); + } + + public void print_document_activate_cb () + { + print_document (); + } + + private void launch_help () + { + try + { + Gtk.show_uri (screen, "help:simple-scan", Gtk.get_current_event_time ()); + } + catch (Error e) + { + show_error_dialog (/* Error message displayed when unable to launch help browser */ + _("Unable to open help file"), + e.message); + } + } + + [GtkCallback] + private void help_contents_menuitem_activate_cb (Gtk.Widget widget) + { + launch_help (); + } + + public void help_contents_activate_cb () + { + launch_help (); + } + + private void show_about () + { + string[] authors = { "Robert Ancell " }; + + /* The license this software is under (GPL3+) */ + string license = _("This program is free software: you can redistribute it and/or modify\nit under the terms of the GNU General Public License as published by\nthe Free Software Foundation, either version 3 of the License, or\n(at your option) any later version.\n\nThis program is distributed in the hope that it will be useful,\nbut WITHOUT ANY WARRANTY; without even the implied warranty of\nMERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the\nGNU General Public License for more details.\n\nYou should have received a copy of the GNU General Public License\nalong with this program. If not, see ."); + + /* Title of about dialog */ + string title = _("About Simple Scan"); + + /* Description of program */ + string description = _("Simple document scanning tool"); + + Gtk.show_about_dialog (this, + "title", title, + "program-name", "Simple Scan", + "version", VERSION, + "comments", description, + "logo-icon-name", "scanner", + "authors", authors, + "translator-credits", _("translator-credits"), + "website", "https://launchpad.net/simple-scan", + "copyright", "Copyright © 2009-2015 Canonical Ltd.", + "license", license, + "wrap-license", true, + null); + } + + [GtkCallback] + private void about_menuitem_activate_cb (Gtk.Widget widget) + { + show_about (); + } + + public void about_activate_cb () + { + show_about (); + } + + private void on_quit () + { + prompt_to_save_async.begin (/* Text in dialog warning when a document is about to be lost */ + _("Save document before quitting?"), + /* Text in dialog warning when a document is about to be lost */ + _("Quit without Saving"), (obj, res) => + { + if (!prompt_to_save_async.end(res)) + return; + + destroy (); + + if (save_state_timeout != 0) + save_state (true); + + autosave_manager.cleanup (); + }); + } + + [GtkCallback] + private void quit_menuitem_activate_cb (Gtk.Widget widget) + { + on_quit (); + } + + public void quit_activate_cb () + { + on_quit (); + } + + public override void size_allocate (Gtk.Allocation allocation) + { + base.size_allocate (allocation); + + if (!window_is_maximized && !window_is_fullscreen) + { + get_size (out window_width, out window_height); + save_state (); + } + } + + private void install_drivers () + { + var message = "", instructions = ""; + string[] packages_to_install = {}; + switch (missing_driver) + { + case "brscan": + case "brscan2": + case "brscan3": + case "brscan4": + /* Message to indicate a Brother scanner has been detected */ + message = _("You appear to have a Brother scanner."); + /* Instructions on how to install Brother scanner drivers */ + instructions = _("Drivers for this are available on the Brother website."); + break; + case "samsung": + /* Message to indicate a Samsung scanner has been detected */ + message = _("You appear to have a Samsung scanner."); + /* Instructions on how to install Samsung scanner drivers */ + instructions = _("Drivers for this are available on the Samsung website."); + break; + case "hpaio": + /* Message to indicate a HP scanner has been detected */ + message = _("You appear to have an HP scanner."); + packages_to_install = { "libsane-hpaio" }; + break; + case "epkowa": + /* Message to indicate an Epson scanner has been detected */ + message = _("You appear to have an Epson scanner."); + /* Instructions on how to install Epson scanner drivers */ + instructions = _("Drivers for this are available on the Epson website."); + break; + } + var dialog = new Gtk.Dialog.with_buttons (/* Title of dialog giving instructions on how to install drivers */ + _("Install drivers"), this, Gtk.DialogFlags.MODAL, _("_Close"), Gtk.ResponseType.CLOSE); + dialog.get_content_area ().border_width = 12; + dialog.get_content_area ().spacing = 6; + + var label = new Gtk.Label (message); + label.visible = true; + label.xalign = 0f; + dialog.get_content_area ().pack_start (label, true, true, 0); + + var instructions_box = new Gtk.Box (Gtk.Orientation.HORIZONTAL, 6); + instructions_box.visible = true; + dialog.get_content_area ().pack_start (instructions_box, true, true, 0); + + var stack = new Gtk.Stack (); + instructions_box.pack_start (stack, false, false, 0); + + var spinner = new Gtk.Spinner (); + spinner.visible = true; + stack.add (spinner); + + var status_label = new Gtk.Label (""); + status_label.visible = true; + stack.add (status_label); + + var instructions_label = new Gtk.Label (instructions); + instructions_label.visible = true; + instructions_label.xalign = 0f; + instructions_label.use_markup = true; + instructions_box.pack_start (instructions_label, false, false, 0); + + label = new Gtk.Label (/* Message in driver install dialog */ + _("Once installed you will need to restart Simple Scan.")); + label.visible = true; + label.xalign = 0f; + dialog.get_content_area ().border_width = 12; + dialog.get_content_area ().pack_start (label, true, true, 0); + + if (packages_to_install.length > 0) + { +#if HAVE_PACKAGEKIT + stack.visible = true; + spinner.active = true; + instructions_label.set_text (/* Label shown while installing drivers */ + _("Installing drivers…")); + install_packages.begin (packages_to_install, () => {}, (object, result) => + { + status_label.visible = true; + spinner.active = false; + status_label.set_text ("☒"); + stack.visible_child = status_label; + /* Label shown once drivers successfully installed */ + var result_text = _("Drivers installed successfully!"); + try + { + var results = install_packages.end (result); + if (results.get_error_code () == null) + status_label.set_text ("☑"); + else + { + var e = results.get_error_code (); + /* Label shown if failed to install drivers */ + result_text = _("Failed to install drivers (error code %d).").printf (e.code); + } + } + catch (Error e) + { + /* Label shown if failed to install drivers */ + result_text = _("Failed to install drivers."); + warning ("Failed to install drivers: %s", e.message); + } + instructions_label.set_text (result_text); + }); +#else + instructions_label.set_text (/* Label shown to prompt user to install packages (when PackageKit not available) */ + ngettext ("You need to install the %s package.", "You need to install the %s packages.", packages_to_install.length).printf (string.joinv (", ", packages_to_install))); +#endif + } + + dialog.run (); + dialog.destroy (); + } + +#if HAVE_PACKAGEKIT + private async Pk.Results? install_packages (string[] packages, Pk.ProgressCallback progress_callback) throws GLib.Error + { + var task = new Pk.Task (); + Pk.Results results; + results = yield task.resolve_async (Pk.Filter.NOT_INSTALLED, packages, null, progress_callback); + if (results == null || results.get_error_code () != null) + return results; + + var package_array = results.get_package_array (); + var package_ids = new string[package_array.length + 1]; + package_ids[package_array.length] = null; + for (var i = 0; i < package_array.length; i++) + package_ids[i] = package_array.data[i].get_id (); + + return yield task.install_packages_async (package_ids, null, progress_callback); + } +#endif + + public override bool window_state_event (Gdk.EventWindowState event) + { + var result = Gdk.EVENT_PROPAGATE; + + if (base.window_state_event != null) + result = base.window_state_event (event); + + if ((event.changed_mask & Gdk.WindowState.MAXIMIZED) != 0) + { + window_is_maximized = (event.new_window_state & Gdk.WindowState.MAXIMIZED) != 0; + save_state (); + } + if ((event.changed_mask & Gdk.WindowState.FULLSCREEN) != 0) + { + window_is_fullscreen = (event.new_window_state & Gdk.WindowState.FULLSCREEN) != 0; + save_state (); + } + + return result; + } + + [GtkCallback] + private bool window_delete_event_cb (Gtk.Widget widget, Gdk.EventAny event) + { + on_quit (); + return true; /* Let us quit on our own terms */ + } + + private void page_added_cb (Book book, Page page) + { + update_page_menu (); + } + + private void reordered_cb (Book book) + { + update_page_menu (); + } + + private void page_removed_cb (Book book, Page page) + { + update_page_menu (); + } + + private void book_changed_cb (Book book) + { + save_menuitem.sensitive = true; + email_menuitem.sensitive = true; + print_menuitem.sensitive = true; + save_button.sensitive = true; + save_toolbutton.sensitive = true; + book_needs_saving = true; + copy_to_clipboard_menuitem.sensitive = true; + } + + private void load () + { + var use_header_bar = !is_traditional_desktop (); + + preferences_dialog = new PreferencesDialog (settings, use_header_bar); + preferences_dialog.delete_event.connect (() => { return true; }); + preferences_dialog.response.connect (() => { preferences_dialog.visible = false; }); + + Gtk.IconTheme.get_default ().append_search_path (ICON_DIR); + + Gtk.Window.set_default_icon_name ("scanner"); + + var app = Application.get_default () as Gtk.Application; + + if (!use_header_bar) + { + set_titlebar (null); + menubar.visible = true; + toolbar.visible = true; + } + else + { + /* Set HeaderBar title here because Glade doesn't keep it translated */ + /* https://bugzilla.gnome.org/show_bug.cgi?id=782753 */ + /* Title of scan window */ + header_bar.title = _("Simple Scan"); + + app.add_action_entries (action_entries, this); + + var appmenu = new Menu (); + + var section = new Menu (); + appmenu.append_section (null, section); + section.append (_("Preferences"), "app.preferences"); + + section = new Menu (); + appmenu.append_section (null, section); + section.append (_("Keyboard Shortcuts"), "win.show-help-overlay"); + section.append (_("Help"), "app.help"); + section.append (_("About"), "app.about"); + section.append (_("Quit"), "app.quit"); + + app.app_menu = appmenu; + + app.add_accelerator ("N", "app.new_document", null); + app.add_accelerator ("S", "app.save", null); + app.add_accelerator ("E", "app.email", null); + app.add_accelerator ("P", "app.print", null); + app.add_accelerator ("F1", "app.help", null); + app.add_accelerator ("Q", "app.quit", null); + + var gear_menu = new Menu (); + section = new Menu (); + gear_menu.append_section (null, section); + section.append (_("Email"), "app.email"); + section.append (_("Reorder Pages"), "app.reorder"); + section.append (_("Preferences"), "app.preferences"); + menu_button.set_menu_model (gear_menu); + } + app.add_window (this); + + /* Populate ActionBar (not supported in Glade) */ + /* https://bugzilla.gnome.org/show_bug.cgi?id=769966 */ + var button = new Gtk.Button.with_label (/* Label on new document button */ + _("Start Again…")); + button.visible = true; + button.clicked.connect (new_button_clicked_cb); + action_bar.pack_start (button); + + var box = new Gtk.Box (Gtk.Orientation.HORIZONTAL, 10); + box.visible = true; + action_bar.set_center_widget (box); + + var rotate_box = new Gtk.Box (Gtk.Orientation.HORIZONTAL, 0); + rotate_box.get_style_context ().add_class (Gtk.STYLE_CLASS_LINKED); + rotate_box.visible = true; + box.pack_start (rotate_box, false, true, 0); + + button = new Gtk.Button.from_icon_name ("object-rotate-left-symbolic"); + button.visible = true; + /* Tooltip for rotate left (counter-clockwise) button */ + button.tooltip_text = _("Rotate the page to the left (counter-clockwise)"); + button.clicked.connect (rotate_left_button_clicked_cb); + rotate_box.pack_start (button, false, true, 0); + + button = new Gtk.Button.from_icon_name ("object-rotate-right-symbolic"); + button.visible = true; + /* Tooltip for rotate right (clockwise) button */ + button.tooltip_text = _("Rotate the page to the right (clockwise)"); + button.clicked.connect (rotate_right_button_clicked_cb); + rotate_box.pack_start (button, false, true, 0); + + crop_button = new Gtk.ToggleButton (); + crop_button.visible = true; + var image = new Gtk.Image.from_icon_name ("edit-cut-symbolic", Gtk.IconSize.BUTTON); + image.visible = true; + crop_button.add (image); + /* Tooltip for crop button */ + crop_button.tooltip_text = _("Crop the selected page"); + crop_button.toggled.connect ((widget) => + { + if (updating_page_menu) + return; + + if (widget.active) + custom_crop_menuitem.active = true; + else + no_crop_menuitem.active = true; + }); + box.pack_start (crop_button, false, true, 0); + + delete_button = new Gtk.Button.from_icon_name ("user-trash-symbolic"); + delete_button.visible = true; + /* Tooltip for delete button */ + delete_button.tooltip_text = _("Delete the selected page"); + delete_button.clicked.connect (() => { book_view.book.delete_page (book_view.selected_page); }); + box.pack_start (delete_button, false, true, 0); + + var document_type = settings.get_string ("document-type"); + if (document_type != null) + set_document_hint (document_type); + + book_view = new BookView (book); + book_view.border_width = 18; + main_vbox.pack_start (book_view, true, true, 0); + book_view.page_selected.connect (page_selected_cb); + book_view.show_page.connect (show_page_cb); + book_view.show_menu.connect (show_page_menu_cb); + book_view.visible = true; + + preferences_dialog.transient_for = this; + + /* Load previous state */ + load_state (); + + /* Restore window size */ + debug ("Restoring window to %dx%d pixels", window_width, window_height); + set_default_size (window_width, window_height); + if (window_is_maximized) + { + debug ("Restoring window to maximized"); + maximize (); + } + if (window_is_fullscreen) + { + debug ("Restoring window to fullscreen"); + fullscreen (); + } + } + + private bool is_desktop (string name) + { + var desktop_name_list = Environment.get_variable ("XDG_CURRENT_DESKTOP"); + if (desktop_name_list == null) + return false; + + foreach (var n in desktop_name_list.split (":")) + if (n == name) + return true; + + return false; + } + + private bool is_traditional_desktop () + { + const string[] traditional_desktops = { "Unity", "XFCE", "MATE", "LXDE", "Cinnamon", "X-Cinnamon", "i3" }; + foreach (var name in traditional_desktops) + if (is_desktop (name)) + return true; + return false; + } + + private string state_filename + { + owned get { return Path.build_filename (Environment.get_user_cache_dir (), "simple-scan", "state"); } + } + + private void load_state () + { + debug ("Loading state from %s", state_filename); + + var f = new KeyFile (); + try + { + f.load_from_file (state_filename, KeyFileFlags.NONE); + } + catch (Error e) + { + if (!(e is FileError.NOENT)) + warning ("Failed to load state: %s", e.message); + } + window_width = state_get_integer (f, "window", "width", 600); + if (window_width <= 0) + window_width = 600; + window_height = state_get_integer (f, "window", "height", 400); + if (window_height <= 0) + window_height = 400; + window_is_maximized = state_get_boolean (f, "window", "is-maximized"); + window_is_fullscreen = state_get_boolean (f, "window", "is-fullscreen"); + } + + private int state_get_integer (KeyFile f, string group_name, string key, int default = 0) + { + try + { + return f.get_integer (group_name, key); + } + catch + { + return default; + } + } + + private bool state_get_boolean (KeyFile f, string group_name, string key, bool default = false) + { + try + { + return f.get_boolean (group_name, key); + } + catch + { + return default; + } + } + + private void save_state (bool force = false) + { + if (!force) + { + if (save_state_timeout != 0) + Source.remove (save_state_timeout); + save_state_timeout = Timeout.add (100, () => + { + save_state (true); + save_state_timeout = 0; + return false; + }); + return; + } + + debug ("Saving state to %s", state_filename); + + var f = new KeyFile (); + f.set_integer ("window", "width", window_width); + f.set_integer ("window", "height", window_height); + f.set_boolean ("window", "is-maximized", window_is_maximized); + f.set_boolean ("window", "is-fullscreen", window_is_fullscreen); + try + { + FileUtils.set_contents (state_filename, f.to_data ()); + } + catch (Error e) + { + warning ("Failed to write state: %s", e.message); + } + } + + public void start () + { + visible = true; + } +} + +private class CancellableProgressBar : Gtk.HBox +{ + private Gtk.ProgressBar bar; + private Gtk.Button? button; + + public CancellableProgressBar (string? text, Cancellable? cancellable) + { + bar = new Gtk.ProgressBar (); + bar.visible = true; + bar.set_text (text); + bar.set_show_text (true); + pack_start (bar); + + if (cancellable != null) + { + button = new Gtk.Button.with_label (/* Text of button for cancelling save */ + _("Cancel")); + button.visible = true; + button.clicked.connect (() => + { + set_visible (false); + cancellable.cancel (); + }); + pack_start (button); + } + } + + public void set_fraction (double fraction) + { + bar.set_fraction (fraction); + } + + public void destroy_with_delay (uint delay) + { + button.set_sensitive (false); + + Timeout.add (delay, () => + { + this.destroy (); + return false; + }); + } +} diff --git a/src/authorize-dialog.ui b/src/authorize-dialog.ui new file mode 100644 index 0000000..c099563 --- /dev/null +++ b/src/authorize-dialog.ui @@ -0,0 +1,141 @@ + + + + + + diff --git a/src/authorize-dialog.vala b/src/authorize-dialog.vala new file mode 100644 index 0000000..a6e5ab0 --- /dev/null +++ b/src/authorize-dialog.vala @@ -0,0 +1,37 @@ +/* + * Copyright (C) 2009-2017 Canonical Ltd. + * Author: Robert Ancell , + * Eduard Gotwig + * + * This program is free software: you can redistribute it and/or modify it under + * the terms of the GNU General Public License as published by the Free Software + * Foundation, either version 3 of the License, or (at your option) any later + * version. See http://www.gnu.org/copyleft/gpl.html the full text of the + * license. + */ + +[GtkTemplate (ui = "/org/gnome/SimpleScan/authorize-dialog.ui")] +private class AuthorizeDialog : Gtk.Dialog +{ + [GtkChild] + private Gtk.Label authorize_label; + [GtkChild] + private Gtk.Entry username_entry; + [GtkChild] + private Gtk.Entry password_entry; + + public AuthorizeDialog (string title) + { + authorize_label.set_text (title); + } + + public string get_username () + { + return username_entry.text; + } + + public string get_password () + { + return password_entry.text; + } +} diff --git a/src/book-view.vala b/src/book-view.vala index 182edc7..9a9c9bb 100644 --- a/src/book-view.vala +++ b/src/book-view.vala @@ -23,20 +23,6 @@ public class BookView : Gtk.Box private bool laying_out; private bool show_selected_page; - /* Page to show when book empty */ - private PageView? default_page_view = null; - public Page default_page - { - set - { - if (value == null) - default_page_view = null; - else - default_page_view = new PageView (value); - need_layout = true; - } - } - /* Currently selected page */ private PageView? selected_page_view = null; public Page? selected_page @@ -310,16 +296,8 @@ public class BookView : Gtk.Box private void layout_into (int width, int height, out int book_width, out int book_height) { var pages = new List (); - if (book.n_pages == 0) - { - if (default_page_view != null) - pages.append (default_page_view); - } - else - { - for (var i = 0; i < book.n_pages; i++) - pages.append (get_nth_page (i)); - } + for (var i = 0; i < book.n_pages; i++) + pages.append (get_nth_page (i)); /* Get maximum page resolution */ int max_dpi = 0; @@ -461,16 +439,8 @@ public class BookView : Gtk.Box context.clip_extents (out left, out top, out right, out bottom); var pages = new List (); - if (book.n_pages == 0) - { - if (default_page_view != null) - pages.append (default_page_view); - } - else - { - for (var i = 0; i < book.n_pages; i++) - pages.append (get_nth_page (i)); - } + for (var i = 0; i < book.n_pages; i++) + pages.append (get_nth_page (i)); /* Render each page */ foreach (var page in pages) diff --git a/src/book.vala b/src/book.vala index a843981..d53b31a 100644 --- a/src/book.vala +++ b/src/book.vala @@ -9,6 +9,8 @@ * license. */ +public delegate void ProgressionCallback (double fraction); + public class Book { private List pages; @@ -20,7 +22,6 @@ public class Book public signal void reordered (); public signal void cleared (); public signal void changed (); - public signal void saving (int i); public Book () { @@ -135,92 +136,440 @@ public class Book return pages.index (page); } - public File make_indexed_file (string uri, int i) + public async void save_async (string t, int q, File f, ProgressionCallback? p, Cancellable? c) throws Error { - if (n_pages == 1) - return File.new_for_uri (uri); - - /* Insert index before extension */ - var basename = Path.get_basename (uri); - string prefix = uri, suffix = ""; - var extension_index = basename.last_index_of_char ('.'); - if (extension_index >= 0) - { - suffix = basename.slice (extension_index, basename.length); - prefix = uri.slice (0, uri.length - suffix.length); - } - var width = n_pages.to_string().length; - var number_format = "%%0%dd".printf (width); - var filename = prefix + "-" + number_format.printf (i + 1) + suffix; - return File.new_for_uri (filename); + var book_saver = new BookSaver (); + yield book_saver.save_async (this, t, q, f, p, c); } +} - private void save_multi_file (string type, int quality, File file) throws Error +private class BookSaver +{ + private uint n_pages; + private int quality; + private File file; + private unowned ProgressionCallback progression_callback; + private double progression; + private Mutex progression_mutex; + private Cancellable? cancellable; + private AsyncQueue write_queue; + private ThreadPool encoder; + private SourceFunc save_async_callback; + + /* save_async get called in the main thread to start saving. It + * distributes all encode tasks to other threads then yield so + * the ui can continue operating. The method then return once saving + * is completed, cancelled, or failed */ + public async void save_async (Book book, string type, int quality, File file, ProgressionCallback? progression_callback, Cancellable? cancellable) throws Error { + var timer = new Timer (); + + this.n_pages = book.n_pages; + this.quality = quality; + this.file = file; + this.cancellable = cancellable; + this.save_async_callback = save_async.callback; + this.write_queue = new AsyncQueue (); + this.progression = 0; + this.progression_mutex = Mutex (); + + /* Configure a callback that monitor saving progression */ + if (progression_callback == null) + this.progression_callback = (fraction) => + { + debug ("Save progression: %f%%", fraction*100.0); + }; + else + this.progression_callback = progression_callback; + + /* Configure an encoder */ + ThreadPoolFunc? encode_delegate = null; + switch (type) + { + case "jpeg": + encode_delegate = encode_jpeg; + break; + case "png": + encode_delegate = encode_png; + break; +#if HAVE_WEBP + case "webp": + encode_delegate = encode_webp; + break; +#endif + case "pdf": + encode_delegate = encode_pdf; + break; + } + encoder = new ThreadPool.with_owned_data (encode_delegate, (int) get_num_processors (), false); + + /* Configure a writer */ + ThreadFunc? write_delegate = null; + switch (type) + { + case "jpeg": + case "png": +#if HAVE_WEBP + case "webp": +#endif + write_delegate = write_multifile; + break; + case "pdf": + write_delegate = write_pdf; + break; + } + var writer = new Thread (null, write_delegate); + + /* Issue encode tasks */ for (var i = 0; i < n_pages; i++) { - var page = get_page (i); - page.save (type, quality, make_indexed_file (file.get_uri (), i)); - saving (i); + var encode_task = new EncodeTask (); + encode_task.number = i; + encode_task.page = book.get_page(i); + encoder.add ((owned) encode_task); } + + /* Waiting for saving to finish */ + yield; + + /* Any error from any thread ends up here */ + var error = writer.join (); + if (error != null) + throw error; + + timer.stop (); + debug ("Save time: %f seconds", timer.elapsed (null)); } - private uint8[]? compress_zlib (uint8[] data) + /* Those methods are run in the encoder threads pool. It process + * one encode_task issued by save_async and reissue the result with + * a write_task */ + + private void encode_png (owned EncodeTask encode_task) { - var stream = ZLib.DeflateStream (ZLib.Level.BEST_COMPRESSION); - var out_data = new uint8[data.length]; + var page = encode_task.page; + var icc_data = page.get_icc_data_encoded (); + var write_task = new WriteTask (); + var image = page.get_image (true); - stream.next_in = data; - stream.next_out = out_data; - while (stream.avail_in > 0) + string[] keys = { "x-dpi", "y-dpi", "icc-profile", null }; + string[] values = { "%d".printf (page.dpi), "%d".printf (page.dpi), icc_data, null }; + if (icc_data == null) + keys[2] = null; + + try { - if (stream.deflate (ZLib.Flush.FINISH) == ZLib.Status.STREAM_ERROR) - break; + image.save_to_bufferv (out write_task.data, "png", keys, values); } + catch (Error error) + { + write_task.error = error; + } + write_task.number = encode_task.number; + write_queue.push ((owned) write_task); - if (stream.avail_in > 0) - return null; + update_progression (); + } - var n_written = data.length - stream.avail_out; - out_data.resize ((int) n_written); + private void encode_jpeg (owned EncodeTask encode_task) + { + var page = encode_task.page; + var icc_data = page.get_icc_data_encoded (); + var write_task = new WriteTask (); + var image = page.get_image (true); - return out_data; + string[] keys = { "x-dpi", "y-dpi", "quality", "icc-profile", null }; + string[] values = { "%d".printf (page.dpi), "%d".printf (page.dpi), "%d".printf (quality), icc_data, null }; + if (icc_data == null) + keys[3] = null; + + try + { + image.save_to_bufferv (out write_task.data, "jpeg", keys, values); + } + catch (Error error) + { + write_task.error = error; + } + write_task.number = encode_task.number; + write_queue.push ((owned) write_task); + + update_progression (); } - private ByteArray jpeg_data; +#if HAVE_WEBP + private void encode_webp (owned EncodeTask encode_task) + { + var page = encode_task.page; + var icc_data = page.get_icc_data_encoded (); + var write_task = new WriteTask (); + var image = page.get_image (true); + var webp_data = WebP.encode_rgb (image.get_pixels (), + image.get_width (), + image.get_height (), + image.get_rowstride (), + (float) quality); +#if HAVE_COLORD + WebP.MuxError mux_error; + var mux = WebP.Mux.new_mux (); + uint8[] output; + + mux_error = mux.set_image (webp_data, false); + debug ("mux.set_image: %s", mux_error.to_string ()); + + if (icc_data != null) + { + mux_error = mux.set_chunk ("ICCP", icc_data.data, false); + debug ("mux.set_chunk: %s", mux_error.to_string ()); + if (mux_error != WebP.MuxError.OK) + warning ("icc profile data not saved with page %i", encode_task.number); + } + + mux_error = mux.assemble (out output); + debug ("mux.assemble: %s", mux_error.to_string ()); + if (mux_error != WebP.MuxError.OK) + write_task.error = new FileError.FAILED (_("Unable to encode page %i").printf (encode_task.number)); - private uint8[] compress_jpeg (Gdk.Pixbuf image, int quality, int dpi) + write_task.data = (owned) output; +#else + + if (webp_data.length == 0) + write_task.error = new FileError.FAILED (_("Unable to encode page %i").printf (encode_task.number)); + + write_task.data = (owned) webp_data; +#endif + write_task.number = encode_task.number; + write_queue.push ((owned) write_task); + + update_progression (); + } +#endif + + private void encode_pdf (owned EncodeTask encode_task) { - jpeg_data = new ByteArray (); - string[] keys = { "quality", "density-unit", "x-density", "y-density", null }; - string[] values = { "%d".printf (quality), "dots-per-inch", "%d".printf (dpi), "%d".printf (dpi), null }; + var page = encode_task.page; + var image = page.get_image (true); + var width = image.width; + var height = image.height; + unowned uint8[] pixels = image.get_pixels (); + int depth = 8; + string color_space = "DeviceRGB"; + string? filter = null; + uint8[] data; + + if (page.is_color) + { + depth = 8; + color_space = "DeviceRGB"; + var data_length = height * width * 3; + data = new uint8[data_length]; + for (var row = 0; row < height; row++) + { + var in_offset = row * image.rowstride; + var out_offset = row * width * 3; + for (var x = 0; x < width; x++) + { + var in_o = in_offset + x*3; + var out_o = out_offset + x*3; + + data[out_o] = pixels[in_o]; + data[out_o+1] = pixels[in_o+1]; + data[out_o+2] = pixels[in_o+2]; + } + } + } + else if (page.depth == 2) + { + int shift_count = 6; + depth = 2; + color_space = "DeviceGray"; + var data_length = height * ((width * 2 + 7) / 8); + data = new uint8[data_length]; + var offset = 0; + for (var row = 0; row < height; row++) + { + /* Pad to the next line */ + if (shift_count != 6) + { + offset++; + shift_count = 6; + } + + var in_offset = row * image.rowstride; + for (var x = 0; x < width; x++) + { + /* Clear byte */ + if (shift_count == 6) + data[offset] = 0; + + /* Set bits */ + var p = pixels[in_offset + x*3]; + if (p >= 192) + data[offset] |= 3 << shift_count; + else if (p >= 128) + data[offset] |= 2 << shift_count; + else if (p >= 64) + data[offset] |= 1 << shift_count; + + /* Move to the next position */ + if (shift_count == 0) + { + offset++; + shift_count = 6; + } + else + shift_count -= 2; + } + } + } + else if (page.depth == 1) + { + int mask = 0x80; + + depth = 1; + color_space = "DeviceGray"; + var data_length = height * ((width + 7) / 8); + data = new uint8[data_length]; + var offset = 0; + for (var row = 0; row < height; row++) + { + /* Pad to the next line */ + if (mask != 0x80) + { + offset++; + mask = 0x80; + } + + var in_offset = row * image.rowstride; + for (var x = 0; x < width; x++) + { + /* Clear byte */ + if (mask == 0x80) + data[offset] = 0; + + /* Set bit */ + if (pixels[in_offset+x*3] != 0) + data[offset] |= (uint8) mask; + + /* Move to the next bit */ + mask >>= 1; + if (mask == 0) + { + offset++; + mask = 0x80; + } + } + } + } + else + { + depth = 8; + color_space = "DeviceGray"; + var data_length = height * width; + data = new uint8 [data_length]; + for (var row = 0; row < height; row++) + { + var in_offset = row * image.rowstride; + var out_offset = row * width; + for (var x = 0; x < width; x++) + data[out_offset+x] = pixels[in_offset+x*3]; + } + } + + /* Compress data and use zlib compression if it is smaller than JPEG. + * zlib compression is slower in the worst case, so do JPEG first + * and stop zlib if it exceeds the JPEG size */ + var write_task = new WriteTaskPDF (); + uint8[]? jpeg_data = null; try { - image.save_to_callbackv (write_pixbuf_data, "jpeg", keys, values); + jpeg_data = compress_jpeg (image, quality, page.dpi); } - catch (Error e) + catch (Error error) + { + write_task.error = error; + } + var zlib_data = compress_zlib (data, jpeg_data.length); + if (zlib_data != null) { + filter = "FlateDecode"; + data = zlib_data; + } + else + { + filter = "DCTDecode"; + data = jpeg_data; } - var data = (owned) jpeg_data.data; - jpeg_data = null; - return data; + write_task.number = encode_task.number; + write_task.data = data; + write_task.width = width; + write_task.height = height; + write_task.color_space = color_space; + write_task.depth = depth; + write_task.filter = filter; + write_task.dpi = page.dpi; + write_queue.push (write_task); + + update_progression (); } - private bool write_pixbuf_data (uint8[] buf) throws Error + private Error? write_multifile () { - jpeg_data.append (buf); - return true; + for (var i=0; i < n_pages; i++) + { + if (cancellable.is_cancelled ()) + { + finished_saving (); + return null; + } + + var write_task = write_queue.pop (); + if (write_task.error != null) + { + finished_saving (); + return write_task.error; + } + + var indexed_file = make_indexed_file (file.get_uri (), write_task.number, n_pages); + try + { + var stream = indexed_file.replace (null, false, FileCreateFlags.NONE); + stream.write_all (write_task.data, null); + } + catch (Error error) + { + finished_saving (); + return error; + } + } + + update_progression (); + finished_saving (); + return null; } - private void save_pdf (File file, int quality) throws Error + /* Those methods are run in the writer thread. It receive all + * write_tasks sent to it by the encoder threads and write those to + * disk. */ + + private Error? write_pdf () { /* Generate a random ID for this file */ var id = ""; for (var i = 0; i < 4; i++) id += "%08x".printf (Random.next_int ()); - var stream = file.replace (null, false, FileCreateFlags.NONE, null); + FileOutputStream? stream = null; + try + { + stream = file.replace (null, false, FileCreateFlags.NONE, null); + } + catch (Error error) + { + finished_saving (); + return error; + } var writer = new PDFWriter (stream); /* Choose object numbers */ @@ -304,163 +653,41 @@ public class Book writer.write_string (">>\n"); writer.write_string ("endobj\n"); - for (var i = 0; i < n_pages; i++) + /* Process each page in order */ + var tasks_in_standby = new Queue (); + for (int i = 0; i < n_pages; i++) { - var page = get_page (i); - var image = page.get_image (true); - var width = image.width; - var height = image.height; - unowned uint8[] pixels = image.get_pixels (); - var page_width = width * 72.0 / page.dpi; - var page_height = height * 72.0 / page.dpi; - - int depth = 8; - string color_space = "DeviceRGB"; - string? filter = null; - char[] width_buffer = new char[double.DTOSTR_BUF_SIZE]; - char[] height_buffer = new char[double.DTOSTR_BUF_SIZE]; - uint8[] data; - if (page.is_color) + if (cancellable.is_cancelled ()) { - depth = 8; - color_space = "DeviceRGB"; - var data_length = height * width * 3; - data = new uint8[data_length]; - for (var row = 0; row < height; row++) - { - var in_offset = row * image.rowstride; - var out_offset = row * width * 3; - for (var x = 0; x < width; x++) - { - var in_o = in_offset + x*3; - var out_o = out_offset + x*3; - - data[out_o] = pixels[in_o]; - data[out_o+1] = pixels[in_o+1]; - data[out_o+2] = pixels[in_o+2]; - } - } - } - else if (page.depth == 2) - { - int shift_count = 6; - depth = 2; - color_space = "DeviceGray"; - var data_length = height * ((width * 2 + 7) / 8); - data = new uint8[data_length]; - var offset = 0; - for (var row = 0; row < height; row++) - { - /* Pad to the next line */ - if (shift_count != 6) - { - offset++; - shift_count = 6; - } - - var in_offset = row * image.rowstride; - for (var x = 0; x < width; x++) - { - /* Clear byte */ - if (shift_count == 6) - data[offset] = 0; - - /* Set bits */ - var p = pixels[in_offset + x*3]; - if (p >= 192) - data[offset] |= 3 << shift_count; - else if (p >= 128) - data[offset] |= 2 << shift_count; - else if (p >= 64) - data[offset] |= 1 << shift_count; - - /* Move to the next position */ - if (shift_count == 0) - { - offset++; - shift_count = 6; - } - else - shift_count -= 2; - } - } + finished_saving (); + return null; } - else if (page.depth == 1) - { - int mask = 0x80; - - depth = 1; - color_space = "DeviceGray"; - var data_length = height * ((width + 7) / 8); - data = new uint8[data_length]; - var offset = 0; - for (var row = 0; row < height; row++) - { - /* Pad to the next line */ - if (mask != 0x80) - { - offset++; - mask = 0x80; - } - var in_offset = row * image.rowstride; - for (var x = 0; x < width; x++) - { - /* Clear byte */ - if (mask == 0x80) - data[offset] = 0; - - /* Set bit */ - if (pixels[in_offset+x*3] != 0) - data[offset] |= (uint8) mask; - - /* Move to the next bit */ - mask >>= 1; - if (mask == 0) - { - offset++; - mask = 0x80; - } - } - } - } + var write_task = tasks_in_standby.peek_head (); + if (write_task != null && write_task.number == i) + tasks_in_standby.pop_head (); else { - depth = 8; - color_space = "DeviceGray"; - var data_length = height * width; - data = new uint8 [data_length]; - for (var row = 0; row < height; row++) + while (true) { - var in_offset = row * image.rowstride; - var out_offset = row * width; - for (var x = 0; x < width; x++) - data[out_offset+x] = pixels[in_offset+x*3]; - } - } - - /* Compress data */ - var compressed_data = compress_zlib (data); - if (compressed_data != null) - { - /* Try if JPEG compression is better */ - if (depth > 1) - { - var jpeg_data = compress_jpeg (image, quality, page.dpi); - if (jpeg_data.length < compressed_data.length) + write_task = (WriteTaskPDF) write_queue.pop (); + if (write_task.error != null) { - filter = "DCTDecode"; - data = jpeg_data; + finished_saving (); + return write_task.error; } - } + if (write_task.number == i) + break; - if (filter == null) - { - filter = "FlateDecode"; - data = compressed_data; + tasks_in_standby.insert_sorted (write_task, (a, b) => {return a.number - b.number;}); } } + var page_width = write_task.width * 72.0 / write_task.dpi; + var page_height = write_task.height * 72.0 / write_task.dpi; + var width_buffer = new char[double.DTOSTR_BUF_SIZE]; + var height_buffer = new char[double.DTOSTR_BUF_SIZE]; + /* Page */ writer.write_string ("\n"); writer.start_object (page_numbers[i]); @@ -481,16 +708,16 @@ public class Book writer.write_string ("<<\n"); writer.write_string ("/Type /XObject\n"); writer.write_string ("/Subtype /Image\n"); - writer.write_string ("/Width %d\n".printf (width)); - writer.write_string ("/Height %d\n".printf (height)); - writer.write_string ("/ColorSpace /%s\n".printf (color_space)); - writer.write_string ("/BitsPerComponent %d\n".printf (depth)); - writer.write_string ("/Length %d\n".printf (data.length)); - if (filter != null) - writer.write_string ("/Filter /%s\n".printf (filter)); + writer.write_string ("/Width %d\n".printf (write_task.width)); + writer.write_string ("/Height %d\n".printf (write_task.height)); + writer.write_string ("/ColorSpace /%s\n".printf (write_task.color_space)); + writer.write_string ("/BitsPerComponent %d\n".printf (write_task.depth)); + writer.write_string ("/Length %d\n".printf (write_task.data.length)); + if (write_task.filter != null) + writer.write_string ("/Filter /%s\n".printf (write_task.filter)); writer.write_string (">>\n"); writer.write_string ("stream\n"); - writer.write (data); + writer.write (write_task.data); writer.write_string ("\n"); writer.write_string ("endstream\n"); writer.write_string ("endobj\n"); @@ -500,7 +727,7 @@ public class Book writer.start_object (struct_tree_root_number); writer.write_string ("%u 0 obj\n".printf (struct_tree_root_number)); writer.write_string ("<<\n"); - writer.write_string ("/Type /StructTreeRoot\n"); + writer.write_string ("/Type /StructTreeRoot\n"); writer.write_string (">>\n"); writer.write_string ("endobj\n"); @@ -517,8 +744,6 @@ public class Book writer.write_string ("\n"); writer.write_string ("endstream\n"); writer.write_string ("endobj\n"); - - saving (i); } /* Info */ @@ -535,10 +760,10 @@ public class Book var xref_offset = writer.offset; writer.write_string ("xref\n"); writer.write_string ("0 %zu\n".printf (writer.object_offsets.length + 1)); - writer.write_string ("%010zu 65535 f \n".printf (next_empty_object (writer, 0))); + writer.write_string ("%010zu 65535 f \n".printf (writer.next_empty_object (0))); for (var i = 0; i < writer.object_offsets.length; i++) if (writer.object_offsets[i] == 0) - writer.write_string ("%010zu 65535 f \n".printf (next_empty_object (writer, i + 1))); + writer.write_string ("%010zu 65535 f \n".printf (writer.next_empty_object (i + 1))); else writer.write_string ("%010zu 00000 n \n".printf (writer.object_offsets[i])); @@ -554,31 +779,102 @@ public class Book writer.write_string ("startxref\n"); writer.write_string ("%zu\n".printf (xref_offset)); writer.write_string ("%%EOF\n"); + + update_progression (); + finished_saving (); + return null; } - static int next_empty_object (PDFWriter writer, int start) + /* update_progression is called once by page by encoder threads and + * once at the end by writer thread. */ + private void update_progression () { - for (var i = start; i < writer.object_offsets.length; i++) - if (writer.object_offsets[i] == 0) - return i + 1; - return 0; + double step = 1.0 / (double)(n_pages+1); + progression_mutex.lock (); + progression += step; + progression_mutex.unlock (); + Idle.add (() => + { + progression_callback (progression); + return false; + }); } - public void save (string type, int quality, File file) throws Error + /* finished_saving is called by the writer thread when it's done, + * meaning there is nothing left to do or saving has been + * cancelled */ + private void finished_saving () { - switch (type) + /* At this point, any remaining encode_task ought to remain unprocessed */ + ThreadPool.free ((owned) encoder, true, true); + + /* Wake-up save_async method in main thread */ + Idle.add ((owned)save_async_callback); + } + + /* Utility methods */ + + private static uint8[]? compress_zlib (uint8[] data, uint max_size) + { + var stream = ZLib.DeflateStream (ZLib.Level.BEST_COMPRESSION); + var out_data = new uint8[max_size]; + + stream.next_in = data; + stream.next_out = out_data; + while (true) { - case "jpeg": - case "png": - save_multi_file (type, quality, file); - break; - case "pdf": - save_pdf (file, quality); - break; + /* Compression complete */ + if (stream.avail_in == 0) + break; + + /* Out of space */ + if (stream.avail_out == 0) + return null; + + if (stream.deflate (ZLib.Flush.FINISH) == ZLib.Status.STREAM_ERROR) + return null; } + + var n_written = out_data.length - stream.avail_out; + out_data.resize ((int) n_written); + + return out_data; + } + + private static uint8[] compress_jpeg (Gdk.Pixbuf image, int quality, int dpi) throws Error + { + uint8[] jpeg_data; + string[] keys = { "quality", "x-dpi", "y-dpi", null }; + string[] values = { "%d".printf (quality), "%d".printf (dpi), "%d".printf (dpi), null }; + + image.save_to_bufferv (out jpeg_data, "jpeg", keys, values); + return jpeg_data; } } +private class EncodeTask +{ + public int number; + public Page page; +} + +private class WriteTask +{ + public int number; + public uint8[] data; + public Error error; +} + +private class WriteTaskPDF : WriteTask +{ + public int width; + public int height; + public string color_space; + public int depth; + public string? filter; + public int dpi; +} + private class PDFWriter { public size_t offset = 0; @@ -621,31 +917,32 @@ private class PDFWriter { object_offsets[index - 1] = (uint)offset; } -} - -public class PsWriter -{ - public Cairo.PsSurface surface; - public FileOutputStream stream; - public PsWriter (FileOutputStream stream) + public int next_empty_object (int start) { - this.stream = stream; - surface = new Cairo.PsSurface.for_stream (write_cairo_data, 0, 0); + for (var i = start; i < object_offsets.length; i++) + if (object_offsets[i] == 0) + return i + 1; + return 0; } +} - private Cairo.Status write_cairo_data (uint8[] data) +public File make_indexed_file (string uri, uint i, uint n_pages) +{ + if (n_pages == 1) + return File.new_for_uri (uri); + + /* Insert index before extension */ + var basename = Path.get_basename (uri); + string prefix = uri, suffix = ""; + var extension_index = basename.last_index_of_char ('.'); + if (extension_index >= 0) { - try - { - stream.write_all (data, null, null); - } - catch (Error e) - { - warning ("Error writing data: %s", e.message); - return Cairo.Status.WRITE_ERROR; - } - - return Cairo.Status.SUCCESS; + suffix = basename.slice (extension_index, basename.length); + prefix = uri.slice (0, uri.length - suffix.length); } + var width = n_pages.to_string().length; + var number_format = "%%0%dd".printf (width); + var filename = prefix + "-" + number_format.printf (i + 1) + suffix; + return File.new_for_uri (filename); } diff --git a/src/help-overlay.ui b/src/help-overlay.ui new file mode 100644 index 0000000..dabec9f --- /dev/null +++ b/src/help-overlay.ui @@ -0,0 +1,128 @@ + + + + + 1 + + + 1 + + + 1 + Scanning + + + 1 + <ctrl>1 + Scan a single page + + + + + 1 + <ctrl>f + Scan all pages from document feeder + + + + + 1 + <ctrl>m + Scan continuously from a flatbed scanner + + + + + 1 + Escape + Stop scan in progress + + + + + + + 1 + Document Modification + + + 1 + less + Move page left + + + + + 1 + greater + Move page right + + + + + 1 + bracketleft + Rotate page to the left (anti-clockwise) + + + + + 1 + bracketright + Rotate page to the right (clockwise) + + + + + 1 + Delete + Delete page + + + + + + + 1 + Document Management + + + 1 + <ctrl>n + Start new document + + + + + 1 + <ctrl>s + Save scanned document + + + + + 1 + <ctrl>e + Email scanned document + + + + + 1 + <ctrl>p + Print scanned document + + + + + 1 + <ctrl>c + Copy current page to clipboard + + + + + + + + diff --git a/src/libwebp.vapi b/src/libwebp.vapi new file mode 100644 index 0000000..74bfdd5 --- /dev/null +++ b/src/libwebp.vapi @@ -0,0 +1,55 @@ +/* + * Copyright (C) 2017 Stéphane Fillion + * Authors: Stéphane Fillion + * + * This program is free software: you can redistribute it and/or modify it under + * the terms of the GNU General Public License as published by the Free Software + * Foundation, either version 3 of the License, or (at your option) any later + * version. See http://www.gnu.org/copyleft/gpl.html the full text of the + * license. + */ + +namespace WebP +{ + // Returns the size of the compressed data (pointed to by *output), or 0 if + // an error occurred. The compressed data must be released by the caller + // using the call 'free(*output)'. + // These functions compress using the lossy format, and the quality_factor + // can go from 0 (smaller output, lower quality) to 100 (best quality, + // larger output). + [CCode (cheader_filename = "webp/encode.h", cname = "WebPEncodeRGB")] + private size_t _encode_rgb ([CCode (array_length = false)] uint8[] rgb, + int width, + int height, + int stride, + float quality_factor, + [CCode (array_length = false)] out uint8[] output); + [CCode (cname = "vala_encode_rgb")] + public uint8[] encode_rgb (uint8[] rgb, int width, int height, int stride, float quality_factor) + { + uint8[] output; + size_t length; + length = _encode_rgb (rgb, width, height, stride, quality_factor, out output); + output.length = (int) length; + return output; + } + + // These functions are the equivalent of the above, but compressing in a + // lossless manner. Files are usually larger than lossy format, but will + // not suffer any compression loss. + [CCode (cheader_filename = "webp/encode.h", cname = "WebPEncodeLosslessRGB")] + private size_t _encode_lossless_rgb ([CCode (array_length = false)] uint8[] rgb, + int width, + int height, + int stride, + [CCode (array_length = false)] out uint8[] output); + [CCode (cname = "vala_encode_lossless_rgb")] + public uint8[] encode_lossless_rgb (uint8[] rgb, int width, int height, int stride) + { + uint8[] output; + size_t length; + length = _encode_lossless_rgb (rgb, width, height, stride, out output); + output.length = (int) length; + return output; + } +} diff --git a/src/libwebpmux.vapi b/src/libwebpmux.vapi new file mode 100644 index 0000000..f2461a2 --- /dev/null +++ b/src/libwebpmux.vapi @@ -0,0 +1,128 @@ +/* + * Copyright (C) 2017 Stéphane Fillion + * Authors: Stéphane Fillion + * + * This program is free software: you can redistribute it and/or modify it under + * the terms of the GNU General Public License as published by the Free Software + * Foundation, either version 3 of the License, or (at your option) any later + * version. See http://www.gnu.org/copyleft/gpl.html the full text of the + * license. + */ + +namespace WebP +{ + // Error codes + [CCode (cheader_filename = "webp/mux.h", cname = "WebPMuxError", cprefix = "WEBP_MUX_", has_type_id = false)] + public enum MuxError + { + OK = 1, + NOT_FOUND = 0, + INVALID_ARGUMENT = -1, + BAD_DATA = -2, + MEMORY_ERROR = -3, + NOT_ENOUGH_DATA = -4 + } + + // Data type used to describe 'raw' data, e.g., chunk data + // (ICC profile, metadata) and WebP compressed image data. + [CCode (cheader_filename = "webp/mux.h", cname = "WebPData", destroy_function = "", has_type_id = false)] + private struct Data + { + [CCode (array_length = false)] unowned uint8[] bytes; + size_t size; + } + + // main opaque object. + [CCode (cheader_filename = "webp/mux.h", cname = "WebPMux", free_function = "WebPMuxDelete")] + [Compact] + public class Mux + { + // Creates an empty mux object. + // Returns: + // A pointer to the newly created empty mux object. + // Or NULL in case of memory error. + [CCode (cname = "WebPMuxNew")] + public static Mux? new_mux (); + + // Sets the (non-animated and non-fragmented) image in the mux object. + // Note: Any existing images (including frames/fragments) will be removed. + // Parameters: + // mux - (in/out) object in which the image is to be set + // bitstream - (in) can be a raw VP8/VP8L bitstream or a single-image + // WebP file (non-animated and non-fragmented) + // copy_data - (in) value 1 indicates given data WILL be copied to the mux + // object and value 0 indicates data will NOT be copied. + // Returns: + // WEBP_MUX_INVALID_ARGUMENT - if mux is NULL or bitstream is NULL. + // WEBP_MUX_MEMORY_ERROR - on memory allocation error. + // WEBP_MUX_OK - on success. + [CCode (cname = "WebPMuxSetImage")] + private MuxError _set_image (Data bitstream, bool copy_data); + [CCode (cname = "vala_set_image")] + public MuxError set_image (uint8[] bitstream, bool copy_data) + { + Data data; + data.bytes = bitstream; + data.size = bitstream.length; + return _set_image (data, copy_data); + } + + // Adds a chunk with id 'fourcc' and data 'chunk_data' in the mux object. + // Any existing chunk(s) with the same id will be removed. + // Parameters: + // mux - (in/out) object to which the chunk is to be added + // fourcc - (in) a character array containing the fourcc of the given chunk; + // e.g., "ICCP", "XMP ", "EXIF" etc. + // chunk_data - (in) the chunk data to be added + // copy_data - (in) value 1 indicates given data WILL be copied to the mux + // object and value 0 indicates data will NOT be copied. + // Returns: + // WEBP_MUX_INVALID_ARGUMENT - if mux, fourcc or chunk_data is NULL + // or if fourcc corresponds to an image chunk. + // WEBP_MUX_MEMORY_ERROR - on memory allocation error. + // WEBP_MUX_OK - on success. + [CCode (cname = "WebPMuxSetChunk")] + private MuxError _set_chunk ([CCode (array_length = false)] uchar[] fourcc, + Data chunk_data, + bool copy_data); + [CCode (cname = "vala_set_chunk")] + public MuxError set_chunk (string fourcc, uint8[] chunk_data, bool copy_data) + requires (fourcc.length == 4) + { + Data data; + data.bytes = chunk_data; + data.size = chunk_data.length; + return _set_chunk ((uchar[]) fourcc, data, copy_data); + } + + // Assembles all chunks in WebP RIFF format and returns in 'assembled_data'. + // This function also validates the mux object. + // Note: The content of 'assembled_data' will be ignored and overwritten. + // Also, the content of 'assembled_data' is allocated using malloc(), and NOT + // owned by the 'mux' object. It MUST be deallocated by the caller by calling + // WebPDataClear(). It's always safe to call WebPDataClear() upon return, + // even in case of error. + // Parameters: + // mux - (in/out) object whose chunks are to be assembled + // assembled_data - (out) assembled WebP data + // Returns: + // WEBP_MUX_BAD_DATA - if mux object is invalid. + // WEBP_MUX_INVALID_ARGUMENT - if mux or assembled_data is NULL. + // WEBP_MUX_MEMORY_ERROR - on memory allocation error. + // WEBP_MUX_OK - on success. + [CCode (cname = "WebPMuxAssemble")] + private MuxError _assemble (out Data assembled_data); + [CCode (cname = "vala_assemble")] + public MuxError assemble (out uint8[] assembled_data) + { + Data data; + MuxError mux_error; + unowned uint8[] out_array; + mux_error = _assemble (out data); + out_array = data.bytes; + out_array.length = (int) data.size; + assembled_data = out_array; + return mux_error; + } + } +} diff --git a/src/meson.build b/src/meson.build index cfda86d..9e40e42 100644 --- a/src/meson.build +++ b/src/meson.build @@ -12,16 +12,23 @@ if packagekit_dep.found () vala_args += [ '-D', 'HAVE_PACKAGEKIT' ] dependencies += packagekit_dep endif +if webp_dep.found () and (not colord_dep.found () or webpmux_dep.found ()) # Webpmux only required if colord + vala_args += [ '-D', 'HAVE_WEBP' ] + dependencies += [ webp_dep, webpmux_dep ] +endif simple_scan = executable ('simple-scan', [ 'config.vapi', + 'app-window.vala', + 'authorize-dialog.vala', 'book.vala', 'book-view.vala', 'page.vala', 'page-view.vala', + 'preferences-dialog.vala', 'simple-scan.vala', 'scanner.vala', - 'ui.vala', + 'screensaver.vala', 'autosave-manager.vala' ] + resources, dependencies: dependencies, vala_args: vala_args, diff --git a/src/page.vala b/src/page.vala index 8936187..582aef8 100644 --- a/src/page.vala +++ b/src/page.vala @@ -624,13 +624,16 @@ public class Page return image; } - private string? get_icc_data_encoded (string icc_profile_filename) + public string? get_icc_data_encoded () { + if (color_profile == null) + return null; + /* Get binary data */ string contents; try { - FileUtils.get_contents (icc_profile_filename, out contents); + FileUtils.get_contents (color_profile, out contents); } catch (Error e) { @@ -641,63 +644,33 @@ public class Page /* Encode into base64 */ return Base64.encode ((uchar[]) contents.to_utf8 ()); } - + public void copy_to_clipboard (Gtk.Window window) - { + { var display = window.get_display (); var clipboard = Gtk.Clipboard.get_for_display (display, Gdk.SELECTION_CLIPBOARD); var image = get_image (true); clipboard.set_image (image); } - public void save (string type, int quality, File file) throws Error + public void save_png (File file) throws Error { var stream = file.replace (null, false, FileCreateFlags.NONE, null); - var writer = new PixbufWriter (stream); var image = get_image (true); string? icc_profile_data = null; if (color_profile != null) - icc_profile_data = get_icc_data_encoded (color_profile); + icc_profile_data = get_icc_data_encoded (); - if (strcmp (type, "jpeg") == 0) - { - string[] keys = { "x-dpi", "y-dpi", "quality", "icc-profile", null }; - string[] values = { "%d".printf (dpi), "%d".printf (dpi), "%d".printf (quality), icc_profile_data, null }; - if (icc_profile_data == null) - keys[3] = null; - writer.save (image, "jpeg", keys, values); - } - else if (strcmp (type, "png") == 0) - { - string[] keys = { "x-dpi", "y-dpi", "icc-profile", null }; - string[] values = { "%d".printf (dpi), "%d".printf (dpi), icc_profile_data, null }; - if (icc_profile_data == null) - keys[2] = null; - writer.save (image, "png", keys, values); - } - else - throw new FileError.INVAL ("Unknown file type: %s".printf (type)); - } -} + string[] keys = { "x-dpi", "y-dpi", "icc-profile", null }; + string[] values = { "%d".printf (dpi), "%d".printf (dpi), icc_profile_data, null }; + if (icc_profile_data == null) + keys[2] = null; -public class PixbufWriter -{ - public FileOutputStream stream; - - public PixbufWriter (FileOutputStream stream) - { - this.stream = stream; - } - - public void save (Gdk.Pixbuf image, string type, string[] option_keys, string[] option_values) throws Error - { - image.save_to_callbackv (write_pixbuf_data, type, option_keys, option_values); - } - - private bool write_pixbuf_data (uint8[] buf) throws Error - { - stream.write_all (buf, null, null); - return true; + image.save_to_callbackv ((buf) => + { + stream.write_all (buf, null, null); + return true; + }, "png", keys, values); } } diff --git a/src/preferences-dialog.ui b/src/preferences-dialog.ui new file mode 100644 index 0000000..2272b77 --- /dev/null +++ b/src/preferences-dialog.ui @@ -0,0 +1,608 @@ + + + + + + -100 + 100 + 1 + 10 + + + -100 + 100 + 1 + 10 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/src/preferences-dialog.vala b/src/preferences-dialog.vala new file mode 100644 index 0000000..bf213fb --- /dev/null +++ b/src/preferences-dialog.vala @@ -0,0 +1,534 @@ +/* + * Copyright (C) 2009-2017 Canonical Ltd. + * Author: Robert Ancell , + * Eduard Gotwig + * + * This program is free software: you can redistribute it and/or modify it under + * the terms of the GNU General Public License as published by the Free Software + * Foundation, either version 3 of the License, or (at your option) any later + * version. See http://www.gnu.org/copyleft/gpl.html the full text of the + * license. + */ + +[GtkTemplate (ui = "/org/gnome/SimpleScan/preferences-dialog.ui")] +private class PreferencesDialog : Gtk.Dialog +{ + private Settings settings; + + private bool setting_devices; + private bool user_selected_device; + + [GtkChild] + private Gtk.ComboBox device_combo; + [GtkChild] + private Gtk.ComboBox text_dpi_combo; + [GtkChild] + private Gtk.ComboBox photo_dpi_combo; + [GtkChild] + private Gtk.ComboBox paper_size_combo; + [GtkChild] + private Gtk.Scale brightness_scale; + [GtkChild] + private Gtk.Scale contrast_scale; + [GtkChild] + private Gtk.ListStore device_model; + [GtkChild] + private Gtk.RadioButton page_delay_3s_button; + [GtkChild] + private Gtk.RadioButton page_delay_5s_button; + [GtkChild] + private Gtk.RadioButton page_delay_7s_button; + [GtkChild] + private Gtk.RadioButton page_delay_10s_button; + [GtkChild] + private Gtk.RadioButton page_delay_15s_button; + [GtkChild] + private Gtk.ListStore text_dpi_model; + [GtkChild] + private Gtk.ListStore photo_dpi_model; + [GtkChild] + private Gtk.RadioButton front_side_button; + [GtkChild] + private Gtk.RadioButton back_side_button; + [GtkChild] + private Gtk.RadioButton both_side_button; + [GtkChild] + private Gtk.ListStore paper_size_model; + [GtkChild] + private Gtk.Adjustment brightness_adjustment; + [GtkChild] + private Gtk.Adjustment contrast_adjustment; + [GtkChild] + private Gtk.Button preferences_close_button; + + public PreferencesDialog (Settings settings, bool use_header_bar) + { + Object (use_header_bar: use_header_bar ? 1 : -1); + + if (use_header_bar) + preferences_close_button.visible = false; + + this.settings = settings; + + Gtk.TreeIter iter; + paper_size_model.append (out iter); + paper_size_model.set (iter, 0, 0, 1, 0, 2, + /* Combo box value for automatic paper size */ + _("Automatic"), -1); + paper_size_model.append (out iter); + paper_size_model.set (iter, 0, 1050, 1, 1480, 2, "A6", -1); + paper_size_model.append (out iter); + paper_size_model.set (iter, 0, 1480, 1, 2100, 2, "A5", -1); + paper_size_model.append (out iter); + paper_size_model.set (iter, 0, 2100, 1, 2970, 2, "A4", -1); + paper_size_model.append (out iter); + paper_size_model.set (iter, 0, 2159, 1, 2794, 2, "Letter", -1); + paper_size_model.append (out iter); + paper_size_model.set (iter, 0, 2159, 1, 3556, 2, "Legal", -1); + paper_size_model.append (out iter); + paper_size_model.set (iter, 0, 1016, 1, 1524, 2, "4×6", -1); + + var renderer = new Gtk.CellRendererText (); + device_combo.pack_start (renderer, true); + device_combo.add_attribute (renderer, "text", 1); + + var dpi = settings.get_int ("text-dpi"); + if (dpi <= 0) + dpi = DEFAULT_TEXT_DPI; + set_dpi_combo (text_dpi_combo, DEFAULT_TEXT_DPI, dpi); + text_dpi_combo.changed.connect (() => { settings.set_int ("text-dpi", get_text_dpi ()); }); + dpi = settings.get_int ("photo-dpi"); + if (dpi <= 0) + dpi = DEFAULT_PHOTO_DPI; + set_dpi_combo (photo_dpi_combo, DEFAULT_PHOTO_DPI, dpi); + photo_dpi_combo.changed.connect (() => { settings.set_int ("photo-dpi", get_photo_dpi ()); }); + + set_page_side ((ScanType) settings.get_enum ("page-side")); + front_side_button.toggled.connect ((button) => { if (button.active) settings.set_enum ("page-side", ScanType.ADF_FRONT); }); + back_side_button.toggled.connect ((button) => { if (button.active) settings.set_enum ("page-side", ScanType.ADF_BACK); }); + both_side_button.toggled.connect ((button) => { if (button.active) settings.set_enum ("page-side", ScanType.ADF_BOTH); }); + + renderer = new Gtk.CellRendererText (); + paper_size_combo.pack_start (renderer, true); + paper_size_combo.add_attribute (renderer, "text", 2); + + var lower = brightness_adjustment.lower; + var darker_label = "%s".printf (_("Darker")); + var upper = brightness_adjustment.upper; + var lighter_label = "%s".printf (_("Lighter")); + brightness_scale.add_mark (lower, Gtk.PositionType.BOTTOM, darker_label); + brightness_scale.add_mark (0, Gtk.PositionType.BOTTOM, null); + brightness_scale.add_mark (upper, Gtk.PositionType.BOTTOM, lighter_label); + brightness_adjustment.value = settings.get_int ("brightness"); + brightness_adjustment.value_changed.connect (() => { settings.set_int ("brightness", get_brightness ()); }); + + lower = contrast_adjustment.lower; + var less_label = "%s".printf (_("Less")); + upper = contrast_adjustment.upper; + var more_label = "%s".printf (_("More")); + contrast_scale.add_mark (lower, Gtk.PositionType.BOTTOM, less_label); + contrast_scale.add_mark (0, Gtk.PositionType.BOTTOM, null); + contrast_scale.add_mark (upper, Gtk.PositionType.BOTTOM, more_label); + contrast_adjustment.value = settings.get_int ("contrast"); + contrast_adjustment.value_changed.connect (() => { settings.set_int ("contrast", get_contrast ()); }); + + var paper_width = settings.get_int ("paper-width"); + var paper_height = settings.get_int ("paper-height"); + set_paper_size (paper_width, paper_height); + paper_size_combo.changed.connect (() => + { + int w, h; + get_paper_size (out w, out h); + settings.set_int ("paper-width", w); + settings.set_int ("paper-height", h); + }); + + set_page_delay (settings.get_int ("page-delay")); + page_delay_3s_button.toggled.connect ((button) => { if (button.active) settings.set_int ("page-delay", 3); }); + page_delay_5s_button.toggled.connect ((button) => { if (button.active) settings.set_int ("page-delay", 5); }); + page_delay_7s_button.toggled.connect ((button) => { if (button.active) settings.set_int ("page-delay", 7); }); + page_delay_10s_button.toggled.connect ((button) => { if (button.active) settings.set_int ("page-delay", 10); }); + page_delay_15s_button.toggled.connect ((button) => { if (button.active) settings.set_int ("page-delay", 15); }); + } + + public void set_scan_devices (List devices) + { + setting_devices = true; + + /* If the user hasn't chosen a scanner choose the best available one */ + var have_selection = false; + if (user_selected_device) + have_selection = device_combo.active >= 0; + + /* Add new devices */ + int index = 0; + Gtk.TreeIter iter; + foreach (var device in devices) + { + int n_delete = -1; + + /* Find if already exists */ + if (device_model.iter_nth_child (out iter, null, index)) + { + int i = 0; + do + { + string name; + bool matched; + + device_model.get (iter, 0, out name, -1); + matched = name == device.name; + + if (matched) + { + n_delete = i; + break; + } + i++; + } while (device_model.iter_next (ref iter)); + } + + /* If exists, remove elements up to this one */ + if (n_delete >= 0) + { + int i; + + /* Update label */ + device_model.set (iter, 1, device.label, -1); + + for (i = 0; i < n_delete; i++) + { + device_model.iter_nth_child (out iter, null, index); +#if VALA_0_36 + device_model.remove (ref iter); +#else + device_model.remove (iter); +#endif + } + } + else + { + device_model.insert (out iter, index); + device_model.set (iter, 0, device.name, 1, device.label, -1); + } + index++; + } + + /* Remove any remaining devices */ + while (device_model.iter_nth_child (out iter, null, index)) +#if VALA_0_36 + device_model.remove (ref iter); +#else + device_model.remove (iter); +#endif + + /* Select the previously selected device or the first available device */ + if (!have_selection) + { + var device = settings.get_string ("selected-device"); + if (device != null && find_scan_device (device, out iter)) + device_combo.set_active_iter (iter); + else + device_combo.set_active (0); + } + + setting_devices = false; + } + + public string? get_selected_device () + { + Gtk.TreeIter iter; + + if (device_combo.get_active_iter (out iter)) + { + string device; + device_model.get (iter, 0, out device, -1); + return device; + } + + return null; + } + + public string? get_selected_device_label () + { + Gtk.TreeIter iter; + + if (device_combo.get_active_iter (out iter)) + { + string label; + device_model.get (iter, 1, out label, -1); + return label; + } + + return null; + } + + public void set_selected_device (string device) + { + user_selected_device = true; + + Gtk.TreeIter iter; + if (!find_scan_device (device, out iter)) + return; + + device_combo.set_active_iter (iter); + } + + private bool find_scan_device (string device, out Gtk.TreeIter iter) + { + bool have_iter = false; + + if (device_model.get_iter_first (out iter)) + { + do + { + string d; + device_model.get (iter, 0, out d, -1); + if (d == device) + have_iter = true; + } while (!have_iter && device_model.iter_next (ref iter)); + } + + return have_iter; + } + + private void set_page_side (ScanType page_side) + { + switch (page_side) + { + case ScanType.ADF_FRONT: + front_side_button.active = true; + break; + case ScanType.ADF_BACK: + back_side_button.active = true; + break; + default: + case ScanType.ADF_BOTH: + both_side_button.active = true; + break; + } + } + + public ScanType get_page_side () + { + if (front_side_button.active) + return ScanType.ADF_FRONT; + else if (back_side_button.active) + return ScanType.ADF_BACK; + else + return ScanType.ADF_BOTH; + } + + public void set_paper_size (int width, int height) + { + Gtk.TreeIter iter; + bool have_iter; + + for (have_iter = paper_size_model.get_iter_first (out iter); + have_iter; + have_iter = paper_size_model.iter_next (ref iter)) + { + int w, h; + paper_size_model.get (iter, 0, out w, 1, out h, -1); + if (w == width && h == height) + break; + } + + if (!have_iter) + have_iter = paper_size_model.get_iter_first (out iter); + if (have_iter) + paper_size_combo.set_active_iter (iter); + } + + public int get_text_dpi () + { + Gtk.TreeIter iter; + int dpi = DEFAULT_TEXT_DPI; + + if (text_dpi_combo.get_active_iter (out iter)) + text_dpi_model.get (iter, 0, out dpi, -1); + + return dpi; + } + + public int get_photo_dpi () + { + Gtk.TreeIter iter; + int dpi = DEFAULT_PHOTO_DPI; + + if (photo_dpi_combo.get_active_iter (out iter)) + photo_dpi_model.get (iter, 0, out dpi, -1); + + return dpi; + } + + public bool get_paper_size (out int width, out int height) + { + Gtk.TreeIter iter; + + width = height = 0; + if (paper_size_combo.get_active_iter (out iter)) + { + paper_size_model.get (iter, 0, ref width, 1, ref height, -1); + return true; + } + + return false; + } + + public int get_brightness () + { + return (int) brightness_adjustment.value; + } + + public void set_brightness (int brightness) + { + brightness_adjustment.value = brightness; + } + + public int get_contrast () + { + return (int) contrast_adjustment.value; + } + + public void set_contrast (int contrast) + { + contrast_adjustment.value = contrast; + } + + public int get_page_delay () + { + if (page_delay_15s_button.active) + return 15; + else if (page_delay_10s_button.active) + return 10; + else if (page_delay_7s_button.active) + return 7; + else if (page_delay_5s_button.active) + return 5; + else + return 3; + } + + public void set_page_delay (int page_delay) + { + if (page_delay >= 15) + page_delay_15s_button.active = true; + else if (page_delay >= 10) + page_delay_10s_button.active = true; + else if (page_delay >= 7) + page_delay_7s_button.active = true; + else if (page_delay >= 5) + page_delay_5s_button.active = true; + else + page_delay_3s_button.active = true; + } + + private void set_dpi_combo (Gtk.ComboBox combo, int default_dpi, int current_dpi) + { + var renderer = new Gtk.CellRendererText (); + combo.pack_start (renderer, true); + combo.add_attribute (renderer, "text", 1); + + var model = combo.model as Gtk.ListStore; + int[] scan_resolutions = {75, 150, 300, 600, 1200, 2400}; + foreach (var dpi in scan_resolutions) + { + string label; + if (dpi == default_dpi) + /* Preferences dialog: Label for default resolution in resolution list */ + label = _("%d dpi (default)").printf (dpi); + else if (dpi == 75) + /* Preferences dialog: Label for minimum resolution in resolution list */ + label = _("%d dpi (draft)").printf (dpi); + else if (dpi == 1200) + /* Preferences dialog: Label for maximum resolution in resolution list */ + label = _("%d dpi (high resolution)").printf (dpi); + else + /* Preferences dialog: Label for resolution value in resolution list (dpi = dots per inch) */ + label = _("%d dpi").printf (dpi); + + Gtk.TreeIter iter; + model.append (out iter); + model.set (iter, 0, dpi, 1, label, -1); + + if (dpi == current_dpi) + combo.set_active_iter (iter); + } + } + + [GtkCallback] + private void device_combo_changed_cb (Gtk.Widget widget) + { + if (setting_devices) + return; + user_selected_device = true; + if (get_selected_device () != null) + settings.set_string ("selected-device", get_selected_device ()); + } +} + +private class PageIcon : Gtk.DrawingArea +{ + private string text; + private double r; + private double g; + private double b; + private const int MINIMUM_WIDTH = 20; + + public PageIcon (string text, double r = 1.0, double g = 1.0, double b = 1.0) + { + this.text = text; + this.r = r; + this.g = g; + this.b = b; + } + + public override void get_preferred_width (out int minimum_width, out int natural_width) + { + minimum_width = natural_width = MINIMUM_WIDTH; + } + + public override void get_preferred_height (out int minimum_height, out int natural_height) + { + minimum_height = natural_height = (int) Math.round (MINIMUM_WIDTH * Math.SQRT2); + } + + public override void get_preferred_height_for_width (int width, out int minimum_height, out int natural_height) + { + minimum_height = natural_height = (int) (width * Math.SQRT2); + } + + public override void get_preferred_width_for_height (int height, out int minimum_width, out int natural_width) + { + minimum_width = natural_width = (int) (height / Math.SQRT2); + } + + public override bool draw (Cairo.Context c) + { + var w = get_allocated_width (); + var h = get_allocated_height (); + if (w * Math.SQRT2 > h) + w = (int) Math.round (h / Math.SQRT2); + else + h = (int) Math.round (w * Math.SQRT2); + + c.translate ((get_allocated_width () - w) / 2, (get_allocated_height () - h) / 2); + + c.rectangle (0.5, 0.5, w - 1, h - 1); + + c.set_source_rgb (r, g, b); + c.fill_preserve (); + + c.set_line_width (1.0); + c.set_source_rgb (0.0, 0.0, 0.0); + c.stroke (); + + Cairo.TextExtents extents; + c.text_extents (text, out extents); + c.translate ((w - extents.width) * 0.5 - 0.5, (h + extents.height) * 0.5 - 0.5); + c.show_text (text); + + return true; + } +} diff --git a/src/screensaver.vala b/src/screensaver.vala new file mode 100644 index 0000000..ef2dfb8 --- /dev/null +++ b/src/screensaver.vala @@ -0,0 +1,25 @@ +/* + * Copyright (C) 2017 Stéphane Fillion + * Authors: Stéphane Fillion + * + * This program is free software: you can redistribute it and/or modify it under + * the terms of the GNU General Public License as published by the Free Software + * Foundation, either version 3 of the License, or (at your option) any later + * version. See http://www.gnu.org/copyleft/gpl.html the full text of the + * license. + */ + +[DBus (name = "org.freedesktop.ScreenSaver")] +public interface FreedesktopScreensaver : Object +{ + public static FreedesktopScreensaver get_proxy () throws IOError + { + return Bus.get_proxy_sync (BusType.SESSION, "org.freedesktop.ScreenSaver", "/org/freedesktop/ScreenSaver"); + } + + [DBus (name = "Inhibit")] + public abstract uint32 inhibit (string application_name, string reason_for_inhibit) throws IOError; + + [DBus (name = "UnInhibit")] + public abstract void uninhibit (uint32 cookie) throws IOError; +} diff --git a/src/simple-scan.gresource.xml b/src/simple-scan.gresource.xml index b6fe6a6..a62619e 100644 --- a/src/simple-scan.gresource.xml +++ b/src/simple-scan.gresource.xml @@ -1,6 +1,11 @@ - simple-scan.ui + app-window.ui + preferences-dialog.ui + authorize-dialog.ui + + + help-overlay.ui diff --git a/src/simple-scan.ui b/src/simple-scan.ui deleted file mode 100644 index 6e1d15a..0000000 --- a/src/simple-scan.ui +++ /dev/null @@ -1,1454 +0,0 @@ - - - - - False - 12 - False - True - normal - True - - - True - False - vertical - 12 - - - True - False - end - - - _Authorize - True - True - True - True - - - False - False - 0 - - - - - False - True - end - 0 - - - - - True - False - 5 - vertical - 12 - - - True - False - To connect to ? you need to authorize - - - True - True - 0 - - - - - True - False - 6 - 6 - - - True - True - True - - - - 1 - 0 - 1 - 1 - - - - - True - True - True - False - - - - 1 - 1 - 1 - 1 - - - - - True - False - _Username for resource: - True - username_entry - - - 0 - 0 - 1 - 1 - - - - - True - False - _Password: - True - password_entry - - - 0 - 1 - 1 - 1 - - - - - False - True - 1 - - - - - False - True - 1 - - - - - - authorize_button - - - - -100 - 100 - 1 - 10 - - - -100 - 100 - 1 - 10 - - - - - - - - - - - True - False - mail-send - - - True - False - gtk-help - - - - - - - - - - - 3 - Front and Back - - - 1 - Front - - - 2 - Back - - - - - - - - - - - - - - - - - - - - - - - 100 - 1 - 10 - - - 0 - 10000 - 100 - 1000 - - - - - - - - - - - - False - 7 - Preferences - False - scanner - normal - - - - - True - False - vertical - 2 - - - True - False - end - - - gtk-close - True - True - True - True - - - False - False - 0 - - - - - False - True - end - 0 - - - - - True - False - 5 - 6 - 6 - - - True - False - 0 - Scan S_ource: - True - device_combo - - - 0 - 0 - 1 - 1 - - - - - True - False - True - device_model - - - - 1 - 0 - 1 - 1 - - - - - True - False - 0 - _Text Resolution: - True - text_dpi_combo - - - 0 - 1 - 1 - 1 - - - - - True - False - 0 - _Photo Resolution: - True - photo_dpi_combo - - - 0 - 2 - 1 - 1 - - - - - True - False - True - text_dpi_model - - - 1 - 1 - 1 - 1 - - - - - True - False - True - photo_dpi_model - - - 1 - 2 - 1 - 1 - - - - - True - False - 0 - Scan Side: - True - photo_dpi_combo - - - 0 - 3 - 1 - 1 - - - - - True - False - True - page_side_model - - - 1 - 3 - 1 - 1 - - - - - True - False - 0 - Page Size: - True - photo_dpi_combo - - - 0 - 4 - 1 - 1 - - - - - True - False - True - paper_size_model - - - 1 - 4 - 1 - 1 - - - - - True - False - 0 - Brightness: - True - - - 0 - 5 - 1 - 1 - - - - - True - True - True - brightness_adjustment - False - - - 1 - 5 - 1 - 1 - - - - - True - False - 0 - Contrast: - True - contrast_scale - - - 0 - 6 - 1 - 1 - - - - - True - True - True - contrast_adjustment - False - - - 1 - 6 - 1 - 1 - - - - - True - False - 0 - Quality: - True - quality_scale - - - 0 - 7 - 1 - 1 - - - - - True - True - True - quality_adjustment - False - - - 1 - 7 - 1 - 1 - - - - - True - False - 0 - Delay between pages: - True - page_delay_scale - - - 0 - 8 - 1 - 1 - - - - - True - True - True - page_delay_adjustment - True - - - 1 - 8 - 1 - 1 - - - - - False - True - 1 - - - - - - preferences_close_button - - - - True - False - - - True - False - Single _Page - True - - - - - - True - False - All Pages From _Feeder - True - - - - - - True - False - _Multiple Pages From Flatbed - True - - - - - - True - False - - - - - True - False - Text - True - True - - - - - - True - False - Photo - True - True - True - text_button_menuitem - - - - - - True - False - - - True - False - Single _Page - True - - - - - - True - False - All Pages From _Feeder - True - - - - - - True - False - _Multiple Pages From Flatbed - True - - - - - - True - False - - - - - True - False - Text - True - True - - - - - - True - False - Photo - True - True - True - text_button_hb_menuitem - - - - - diff --git a/src/simple-scan.vala b/src/simple-scan.vala index 2ab83f0..841e702 100644 --- a/src/simple-scan.vala +++ b/src/simple-scan.vala @@ -23,7 +23,7 @@ public class SimpleScan : Gtk.Application /* Help string for command line --debug flag */ N_("Print debugging messages"), null}, { "fix-pdf", 0, 0, OptionArg.STRING, ref fix_pdf_filename, - N_("Fix PDF files generated with older versions of Simple Scan"), "FILENAME..."}, + N_("Fix PDF files generated with older versions of Simple Scan"), "FILENAME…"}, { null } }; private static Timer log_timer; @@ -32,12 +32,16 @@ public class SimpleScan : Gtk.Application private ScanDevice? default_device = null; private bool have_devices = false; private GUsb.Context usb_context; - private UserInterface ui; + private AppWindow app; private Scanner scanner; private Book book; public SimpleScan (ScanDevice? device = null) { + /* The inhibit () method use this */ + Object (application_id: "org.gnome.SimpleScan"); + register_session = true; + default_device = device; } @@ -45,11 +49,10 @@ public class SimpleScan : Gtk.Application { base.startup (); - ui = new UserInterface (); - book = ui.book; - ui.start_scan.connect (scan_cb); - ui.stop_scan.connect (cancel_cb); - ui.email.connect (email_cb); + app = new AppWindow (); + book = app.book; + app.start_scan.connect (scan_cb); + app.stop_scan.connect (cancel_cb); scanner = Scanner.get_instance (); scanner.update_devices.connect (update_scan_devices_cb); @@ -78,15 +81,15 @@ public class SimpleScan : Gtk.Application List device_list = null; device_list.append (default_device); - ui.set_scan_devices (device_list); - ui.selected_device = default_device.name; + app.set_scan_devices (device_list); + app.selected_device = default_device.name; } } public override void activate () { base.activate (); - ui.start (); + app.start (); scanner.start (); } @@ -94,7 +97,7 @@ public class SimpleScan : Gtk.Application { base.shutdown (); book = null; - ui = null; + app = null; usb_context = null; scanner.free (); } @@ -127,7 +130,7 @@ public class SimpleScan : Gtk.Application if (!have_devices) missing_driver = suggest_driver (); - ui.set_scan_devices (devices_copy, missing_driver); + app.set_scan_devices (devices_copy, missing_driver); } /* Taken from /usr/local/Brother/sane/Brsane.ini from brscan driver */ @@ -212,7 +215,7 @@ public class SimpleScan : Gtk.Application private void authorize_cb (Scanner scanner, string resource) { string username, password; - ui.authorize (resource, out username, out password); + app.authorize (resource, out username, out password); scanner.authorize (username, password); } @@ -222,7 +225,7 @@ public class SimpleScan : Gtk.Application var page = book.get_page (-1); if (page != null && !page.has_data) { - ui.selected_page = page; + app.selected_page = page; page.start (); return page; } @@ -262,7 +265,7 @@ public class SimpleScan : Gtk.Application page.set_custom_crop (cw, ch); page.move_crop (cx, cy); } - ui.selected_page = page; + app.selected_page = page; page.start (); return page; @@ -385,118 +388,80 @@ public class SimpleScan : Gtk.Application remove_empty_page (); if (error_code != Sane.Status.CANCELLED) { - ui.show_error (/* Title of error dialog when scan failed */ - _("Failed to scan"), - error_string, - have_devices); + app.show_error_dialog (/* Title of error dialog when scan failed */ + _("Failed to scan"), + error_string); } } - private void scanner_scanning_changed_cb (Scanner scanner) - { - ui.scanning = scanner.is_scanning (); - } - - private void scan_cb (UserInterface ui, string? device, ScanOptions options) - { - debug ("Requesting scan at %d dpi from device '%s'", options.dpi, device); + private uint inhibit_cookie; + private FreedesktopScreensaver? fdss; - if (!scanner.is_scanning ()) - append_page (); - - scanner.scan (device, options); - } - - private void cancel_cb (UserInterface ui) - { - scanner.cancel (); - } - - private string? get_temporary_filename (string prefix, string extension) + private void scanner_scanning_changed_cb (Scanner scanner) { - /* NOTE: I'm not sure if this is a 100% safe strategy to use g_file_open_tmp(), close and - * use the filename but it appears to work in practise */ + var is_scanning = scanner.is_scanning (); - var filename = "%sXXXXXX.%s".printf (prefix, extension); - string path; - try - { - var fd = FileUtils.open_tmp (filename, out path); - Posix.close (fd); - } - catch (Error e) + if (is_scanning) { - warning ("Error saving email attachment: %s", e.message); - return null; - } + /* Attempt to inhibit the screensaver when scanning */ + var reason = _("Scan in progress"); - return path; - } + /* This should work on Gnome, Budgie, Cinnamon, Mate, Unity, ... + * but will not work on KDE, LXDE, XFCE, ... */ + inhibit_cookie = inhibit (app, Gtk.ApplicationInhibitFlags.IDLE, reason); - private void email_cb (UserInterface ui, string profile, int quality) - { - var saved = false; - var command_line = "xdg-email"; - - /* Save text files as PDFs */ - if (profile == "text") - { - /* Open a temporary file */ - var path = get_temporary_filename ("scan", "pdf"); - if (path != null) + if (!is_inhibited (Gtk.ApplicationInhibitFlags.IDLE)) { - var file = File.new_for_path (path); - ui.show_progress_dialog (); + /* If the previous method didn't work, try the one + * provided by Freedesktop. It should work with KDE, + * LXDE, XFCE, and maybe others as well. */ try { - book.save ("pdf", quality, file); + if ((fdss = FreedesktopScreensaver.get_proxy ()) != null) + { + inhibit_cookie = fdss.inhibit ("Simple-Scan", reason); + } } - catch (Error e) - { - ui.hide_progress_dialog (); - warning ("Unable to save email file: %s", e.message); - return; - } - command_line += " --attach %s".printf (path); + catch (IOError error) {} } } else { - for (var i = 0; i < book.n_pages; i++) + /* When finished scanning, uninhibit if inhibit was working */ + if (inhibit_cookie != 0) { - var path = get_temporary_filename ("scan", "jpg"); - if (path == null) - { - saved = false; - break; - } - - var file = File.new_for_path (path); - try - { - book.get_page (i).save ("jpeg", quality, file); - } - catch (Error e) + if (fdss == null) + uninhibit (inhibit_cookie); + else { - warning ("Unable to save email file: %s", e.message); - return; + try + { + fdss.uninhibit (inhibit_cookie); + } + catch (IOError error) {} + fdss = null; } - command_line += " --attach %s".printf (path); - if (!saved) - break; + inhibit_cookie = 0; } } - debug ("Launching email client: %s", command_line); - try - { - Process.spawn_command_line_async (command_line); - } - catch (Error e) - { - warning ("Unable to start email: %s", e.message); - } + app.scanning = is_scanning; + } + + private void scan_cb (AppWindow ui, string? device, ScanOptions options) + { + debug ("Requesting scan at %d dpi from device '%s'", options.dpi, device); + + if (!scanner.is_scanning ()) + append_page (); + + scanner.scan (device, options); + } + + private void cancel_cb (AppWindow ui) + { + scanner.cancel (); } private static void log_cb (string? log_domain, LogLevelFlags log_level, string message) @@ -616,7 +581,7 @@ public class SimpleScan : Gtk.Application Intl.textdomain (GETTEXT_PACKAGE); var c = new OptionContext (/* Arguments and description for --help text */ - _("[DEVICE...] - Scanning utility")); + _("[DEVICE…] — Scanning utility")); c.add_main_entries (options, GETTEXT_PACKAGE); c.add_group (Gtk.get_option_group (true)); try @@ -627,7 +592,7 @@ public class SimpleScan : Gtk.Application { stderr.printf ("%s\n", e.message); stderr.printf (/* Text printed out when an unknown command-line argument provided */ - _("Run '%s --help' to see a full list of available command line options."), args[0]); + _("Run “%s --help” to see a full list of available command line options."), args[0]); stderr.printf ("\n"); return Posix.EXIT_FAILURE; } diff --git a/src/ui.vala b/src/ui.vala deleted file mode 100644 index 554b161..0000000 --- a/src/ui.vala +++ /dev/null @@ -1,2398 +0,0 @@ -/* - * Copyright (C) 2009-2015 Canonical Ltd. - * Author: Robert Ancell , - * Eduard Gotwig - * - * This program is free software: you can redistribute it and/or modify it under - * the terms of the GNU General Public License as published by the Free Software - * Foundation, either version 3 of the License, or (at your option) any later - * version. See http://www.gnu.org/copyleft/gpl.html the full text of the - * license. - */ - -[GtkTemplate (ui = "/org/gnome/SimpleScan/simple-scan.ui")] -public class UserInterface : Gtk.ApplicationWindow -{ - private const int DEFAULT_TEXT_DPI = 150; - private const int DEFAULT_PHOTO_DPI = 300; - - private const GLib.ActionEntry[] action_entries = - { - { "new_document", new_document_activate_cb }, - { "reorder", reorder_document_activate_cb }, - { "save", save_document_activate_cb }, - { "email", email_document_activate_cb }, - { "print", print_document_activate_cb }, - { "preferences", preferences_activate_cb }, - { "help", help_contents_activate_cb }, - { "about", about_activate_cb }, - { "quit", quit_activate_cb } - }; - - private Settings settings; - - [GtkChild] - private Gtk.MenuBar menubar; - [GtkChild] - private Gtk.Toolbar toolbar; - [GtkChild] - private Gtk.Menu page_menu; - [GtkChild] - private Gtk.Box main_vbox; - private Gtk.InfoBar info_bar; - private Gtk.Image info_bar_image; - private Gtk.Label info_bar_label; - private Gtk.Button info_bar_close_button; - private Gtk.Button info_bar_change_scanner_button; - private Gtk.Button info_bar_install_button; - [GtkChild] - private Gtk.RadioMenuItem custom_crop_menuitem; - [GtkChild] - private Gtk.RadioMenuItem a4_menuitem; - [GtkChild] - private Gtk.RadioMenuItem a5_menuitem; - [GtkChild] - private Gtk.RadioMenuItem a6_menuitem; - [GtkChild] - private Gtk.RadioMenuItem letter_menuitem; - [GtkChild] - private Gtk.RadioMenuItem legal_menuitem; - [GtkChild] - private Gtk.RadioMenuItem four_by_six_menuitem; - [GtkChild] - private Gtk.RadioMenuItem no_crop_menuitem; - [GtkChild] - private Gtk.MenuItem page_move_left_menuitem; - [GtkChild] - private Gtk.MenuItem page_move_right_menuitem; - [GtkChild] - private Gtk.MenuItem page_delete_menuitem; - [GtkChild] - private Gtk.MenuItem crop_rotate_menuitem; - [GtkChild] - private Gtk.MenuItem save_menuitem; - [GtkChild] - private Gtk.MenuItem email_menuitem; - [GtkChild] - private Gtk.MenuItem print_menuitem; - [GtkChild] - private Gtk.MenuItem copy_to_clipboard_menuitem; - [GtkChild] - private Gtk.Button save_button; - [GtkChild] - private Gtk.ToolButton save_toolbutton; - [GtkChild] - private Gtk.MenuItem stop_scan_menuitem; - [GtkChild] - private Gtk.ToolButton stop_toolbutton; - [GtkChild] - private Gtk.ToggleButton crop_button; - [GtkChild] - private Gtk.ToggleToolButton crop_toolbutton; - [GtkChild] - private Gtk.Button stop_button; - [GtkChild] - private Gtk.Button scan_button; - - [GtkChild] - private Gtk.RadioMenuItem text_button_menuitem; - [GtkChild] - private Gtk.RadioMenuItem text_button_hb_menuitem; - [GtkChild] - private Gtk.RadioMenuItem text_menuitem; - [GtkChild] - private Gtk.RadioMenuItem photo_button_menuitem; - [GtkChild] - private Gtk.RadioMenuItem photo_button_hb_menuitem; - [GtkChild] - private Gtk.RadioMenuItem photo_menuitem; - - [GtkChild] - private Gtk.Dialog authorize_dialog; - [GtkChild] - private Gtk.Label authorize_label; - [GtkChild] - private Gtk.Entry username_entry; - [GtkChild] - private Gtk.Entry password_entry; - - [GtkChild] - private Gtk.Dialog preferences_dialog; - [GtkChild] - private Gtk.ComboBox device_combo; - [GtkChild] - private Gtk.ComboBox text_dpi_combo; - [GtkChild] - private Gtk.ComboBox photo_dpi_combo; - [GtkChild] - private Gtk.ComboBox page_side_combo; - [GtkChild] - private Gtk.ComboBox paper_size_combo; - [GtkChild] - private Gtk.Scale brightness_scale; - [GtkChild] - private Gtk.Scale contrast_scale; - [GtkChild] - private Gtk.Scale quality_scale; - [GtkChild] - private Gtk.Scale page_delay_scale; - [GtkChild] - private Gtk.ListStore device_model; - [GtkChild] - private Gtk.ListStore text_dpi_model; - [GtkChild] - private Gtk.ListStore photo_dpi_model; - [GtkChild] - private Gtk.ListStore page_side_model; - [GtkChild] - private Gtk.ListStore paper_size_model; - [GtkChild] - private Gtk.Adjustment brightness_adjustment; - [GtkChild] - private Gtk.Adjustment contrast_adjustment; - [GtkChild] - private Gtk.Adjustment quality_adjustment; - [GtkChild] - private Gtk.Adjustment page_delay_adjustment; - private bool setting_devices; - private string? missing_driver = null; - private bool user_selected_device; - - private Gtk.FileChooserDialog? save_dialog; - private ProgressBarDialog progress_dialog; - - private bool have_error; - private string error_title; - private string error_text; - private bool error_change_scanner_hint; - - public Book book { get; private set; } - private bool book_needs_saving; - private string? book_uri = null; - - public Page selected_page - { - get - { - return book_view.selected_page; - } - set - { - book_view.selected_page = value; - } - } - - private AutosaveManager autosave_manager; - - private BookView book_view; - private bool updating_page_menu; - private int default_page_width; - private int default_page_height; - private int default_page_dpi; - private ScanDirection default_page_scan_direction; - - private string document_hint = "photo"; - - private bool scanning_ = false; - public bool scanning - { - get { return scanning_; } - set - { - scanning_ = value; - page_delete_menuitem.sensitive = !value; - stop_scan_menuitem.sensitive = value; - stop_toolbutton.sensitive = value; - scan_button.visible = !value; - stop_button.visible = value; - } - } - - private int window_width; - private int window_height; - private bool window_is_maximized; - private bool window_is_fullscreen; - - private uint save_state_timeout; - - public int brightness - { - get { return (int) brightness_adjustment.value; } - set { brightness_adjustment.value = value; } - } - - public int contrast - { - get { return (int) contrast_adjustment.value; } - set { contrast_adjustment.value = value; } - } - - public int quality - { - get { return (int) quality_adjustment.value; } - set { quality_adjustment.value = value; } - } - - public int page_delay - { - get { return (int) page_delay_adjustment.value; } - set { page_delay_adjustment.value = value; } - } - - public string? selected_device - { - owned get - { - Gtk.TreeIter iter; - - if (device_combo.get_active_iter (out iter)) - { - string device; - device_model.get (iter, 0, out device, -1); - return device; - } - - return null; - } - - set - { - Gtk.TreeIter iter; - if (!find_scan_device (value, out iter)) - return; - - device_combo.set_active_iter (iter); - user_selected_device = true; - } - } - - public signal void start_scan (string? device, ScanOptions options); - public signal void stop_scan (); - public signal void email (string profile, int quality); - - public UserInterface () - { - settings = new Settings ("org.gnome.SimpleScan"); - - book = new Book (); - book.page_added.connect (page_added_cb); - book.reordered.connect (reordered_cb); - book.page_removed.connect (page_removed_cb); - book.changed.connect (book_changed_cb); - - load (); - - clear_document (); - autosave_manager = new AutosaveManager (); - autosave_manager.book = book; - autosave_manager.load (); - - if (book.n_pages == 0) - book_needs_saving = false; - else - { - book_view.selected_page = book.get_page (0); - book_needs_saving = true; - book_changed_cb (book); - } - } - - ~UserInterface () - { - book.page_added.disconnect (page_added_cb); - book.reordered.disconnect (reordered_cb); - book.page_removed.disconnect (page_removed_cb); - } - - private bool find_scan_device (string device, out Gtk.TreeIter iter) - { - bool have_iter = false; - - if (device_model.get_iter_first (out iter)) - { - do - { - string d; - device_model.get (iter, 0, out d, -1); - if (d == device) - have_iter = true; - } while (!have_iter && device_model.iter_next (ref iter)); - } - - return have_iter; - } - - private void show_error_dialog (string error_title, string error_text) - { - var dialog = new Gtk.MessageDialog (this, - Gtk.DialogFlags.MODAL, - Gtk.MessageType.WARNING, - Gtk.ButtonsType.NONE, - "%s", error_title); - dialog.add_button (_("_Close"), 0); - dialog.format_secondary_text ("%s", error_text); - dialog.run (); - dialog.destroy (); - } - - public void authorize (string resource, out string username, out string password) - { - /* Label in authorization dialog. '%s' is replaced with the name of the resource requesting authorization */ - var description = _("Username and password required to access '%s'").printf (resource); - - username_entry.text = ""; - password_entry.text = ""; - authorize_label.set_text (description); - - authorize_dialog.visible = true; - authorize_dialog.run (); - authorize_dialog.visible = false; - - username = username_entry.text; - password = password_entry.text; - } - - [GtkCallback] - private void device_combo_changed_cb (Gtk.Widget widget) - { - if (setting_devices) - return; - user_selected_device = true; - if (selected_device != null) - settings.set_string ("selected-device", selected_device); - } - - private void update_info_bar () - { - Gtk.MessageType type; - string title, text, image_id; - bool show_close_button = false; - bool show_install_button = false; - bool show_change_scanner_button = false; - - if (have_error) - { - type = Gtk.MessageType.ERROR; - image_id = "dialog-error"; - title = error_title; - text = error_text; - show_close_button = true; - show_change_scanner_button = error_change_scanner_hint; - } - else if (device_model.iter_n_children (null) == 0) - { - type = Gtk.MessageType.WARNING; - image_id = "dialog-warning"; - if (missing_driver == null) - { - /* Warning displayed when no scanners are detected */ - title = _("No scanners detected"); - /* Hint to user on why there are no scanners detected */ - text = _("Please check your scanner is connected and powered on"); - } - else - { - /* Warning displayed when no drivers are installed but a compatible scanner is detected */ - title = _("Additional software needed"); - /* Instructions to install driver software */ - text = _("You need to install driver software for your scanner."); - show_install_button = true; - } - } - else - { - info_bar.visible = false; - return; - } - - info_bar.message_type = type; - info_bar_image.set_from_icon_name (image_id, Gtk.IconSize.DIALOG); - var message = "%s\n\n%s".printf (title, text); - info_bar_label.set_markup (message); - info_bar_close_button.visible = show_close_button; - info_bar_change_scanner_button.visible = show_change_scanner_button; - info_bar_install_button.visible = show_install_button; - info_bar.visible = true; - } - - public void set_scan_devices (List devices, string? missing_driver = null) - { - bool have_selection = false; - int index; - Gtk.TreeIter iter; - - setting_devices = true; - - this.missing_driver = missing_driver; - - /* If the user hasn't chosen a scanner choose the best available one */ - if (user_selected_device) - have_selection = device_combo.active >= 0; - - /* Add new devices */ - index = 0; - foreach (var device in devices) - { - int n_delete = -1; - - /* Find if already exists */ - if (device_model.iter_nth_child (out iter, null, index)) - { - int i = 0; - do - { - string name; - bool matched; - - device_model.get (iter, 0, out name, -1); - matched = name == device.name; - - if (matched) - { - n_delete = i; - break; - } - i++; - } while (device_model.iter_next (ref iter)); - } - - /* If exists, remove elements up to this one */ - if (n_delete >= 0) - { - int i; - - /* Update label */ - device_model.set (iter, 1, device.label, -1); - - for (i = 0; i < n_delete; i++) - { - device_model.iter_nth_child (out iter, null, index); - device_model.remove (iter); - } - } - else - { - device_model.insert (out iter, index); - device_model.set (iter, 0, device.name, 1, device.label, -1); - } - index++; - } - - /* Remove any remaining devices */ - while (device_model.iter_nth_child (out iter, null, index)) - device_model.remove (iter); - - /* Select the previously selected device or the first available device */ - if (!have_selection) - { - var device = settings.get_string ("selected-device"); - if (device != null && find_scan_device (device, out iter)) - device_combo.set_active_iter (iter); - else - device_combo.set_active (0); - } - - setting_devices = false; - - update_info_bar (); - } - - private string choose_file_location () - { - /* Get directory to save to */ - string? directory = null; - directory = settings.get_string ("save-directory"); - - if (directory == null || directory == "") - directory = Environment.get_user_special_dir (UserDirectory.DOCUMENTS); - - save_dialog = new Gtk.FileChooserDialog (/* Save dialog: Dialog title */ - _("Save As..."), - this, - Gtk.FileChooserAction.SAVE, - _("_Cancel"), Gtk.ResponseType.CANCEL, - _("_Save"), Gtk.ResponseType.ACCEPT, - null); - save_dialog.local_only = false; - if (book_uri != null) - save_dialog.set_uri (book_uri); - else { - save_dialog.set_current_folder (directory); - /* Default filename to use when saving document */ - save_dialog.set_current_name (_("Scanned Document.pdf")); - } - - /* Filter to only show images by default */ - var filter = new Gtk.FileFilter (); - filter.set_filter_name (/* Save dialog: Filter name to show only image files */ - _("Image Files")); - filter.add_pixbuf_formats (); - filter.add_mime_type ("application/pdf"); - save_dialog.add_filter (filter); - filter = new Gtk.FileFilter (); - filter.set_filter_name (/* Save dialog: Filter name to show all files */ - _("All Files")); - filter.add_pattern ("*"); - save_dialog.add_filter (filter); - - var file_type_store = new Gtk.ListStore (2, typeof (string), typeof (string)); - Gtk.TreeIter iter; - file_type_store.append (out iter); - file_type_store.set (iter, - /* Save dialog: Label for saving in PDF format */ - 0, _("PDF (multi-page document)"), - 1, ".pdf", - -1); - file_type_store.append (out iter); - file_type_store.set (iter, - /* Save dialog: Label for saving in JPEG format */ - 0, _("JPEG (compressed)"), - 1, ".jpg", - -1); - file_type_store.append (out iter); - file_type_store.set (iter, - /* Save dialog: Label for saving in PNG format */ - 0, _("PNG (lossless)"), - 1, ".png", - -1); - - var box = new Gtk.Box (Gtk.Orientation.HORIZONTAL, 6); - box.visible = true; - save_dialog.set_extra_widget (box); - - /* Label in save dialog beside combo box to choose file format (PDF, JPEG, PNG) */ - var label = new Gtk.Label (_("File format:")); - label.visible = true; - box.pack_start (label, false, false, 0); - - var file_type_combo = new Gtk.ComboBox.with_model (file_type_store); - file_type_combo.visible = true; - var renderer = new Gtk.CellRendererText (); - file_type_combo.pack_start (renderer, true); - file_type_combo.add_attribute (renderer, "text", 0); - - file_type_combo.set_active (0); - file_type_combo.changed.connect (() => - { - var extension = ""; - Gtk.TreeIter i; - if (file_type_combo.get_active_iter (out i)) - file_type_store.get (i, 1, out extension, -1); - - var path = save_dialog.get_filename (); - var filename = Path.get_basename (path); - - /* Replace extension */ - var extension_index = filename.last_index_of_char ('.'); - if (extension_index >= 0) - filename = filename.slice (0, extension_index); - filename = filename + extension; - save_dialog.set_current_name (filename); - }); - box.pack_start (file_type_combo, false, false, 0); - - string? uri = null; - while (true) - { - var response = save_dialog.run (); - if (response != Gtk.ResponseType.ACCEPT) - break; - - var extension = ""; - Gtk.TreeIter i; - if (file_type_combo.get_active_iter (out i)) - file_type_store.get (i, 1, out extension, -1); - - var path = save_dialog.get_filename (); - var filename = Path.get_basename (path); - - var extension_index = filename.last_index_of_char ('.'); - if (extension_index < 0) - path += extension; - - uri = File.new_for_path (path).get_uri (); - - /* Check the file(s) don't already exist */ - var files = new List (); - var format = uri_to_format (uri); - if (format == "jpeg" || format == "png") - { - for (var j = 0; j < book.n_pages; j++) - files.append (book.make_indexed_file (uri, j)); - } - else - files.append (File.new_for_uri (uri)); - - if (check_overwrite (save_dialog, files)) - break; - } - - settings.set_string ("save-directory", save_dialog.get_current_folder ()); - - save_dialog.destroy (); - save_dialog = null; - - return uri; - } - - private bool check_overwrite (Gtk.Window parent, List files) - { - foreach (var file in files) - { - if (!file.query_exists ()) - continue; - - var dialog = new Gtk.MessageDialog (parent, Gtk.DialogFlags.MODAL | Gtk.DialogFlags.DESTROY_WITH_PARENT, Gtk.MessageType.QUESTION, Gtk.ButtonsType.NONE, - /* Contents of dialog that shows if saving would overwrite and existing file. %s is replaced with the name of the file. */ - _("A file named “%s” already exists. Do you want to replace it?"), file.get_basename ()); - dialog.add_button (_("_Cancel"), Gtk.ResponseType.CANCEL); - dialog.add_button (/* Button in dialog that shows if saving would overwrite and existing file. Clicking the button allows simple-scan to overwrite the file. */ - _("_Replace"), Gtk.ResponseType.ACCEPT); - var response = dialog.run (); - dialog.destroy (); - - if (response != Gtk.ResponseType.ACCEPT) - return false; - } - - return true; - } - - private string uri_to_format (string uri) - { - var uri_lower = uri.down (); - if (uri_lower.has_suffix (".pdf")) - return "pdf"; - else if (uri_lower.has_suffix (".png")) - return "png"; - else - return "jpeg"; - } - - private bool save_document () - { - var uri = choose_file_location (); - if (uri == null) - return false; - - var file = File.new_for_uri (uri); - - debug ("Saving to '%s'", uri); - - var format = uri_to_format (uri); - - show_progress_dialog (); - try - { - book.save (format, quality, file); - } - catch (Error e) - { - hide_progress_dialog (); - warning ("Error saving file: %s", e.message); - show_error (/* Title of error dialog when save failed */ - _("Failed to save file"), - e.message, - false); - return false; - } - - book_needs_saving = false; - book_uri = uri; - return true; - } - - private bool prompt_to_save (string title, string discard_label) - { - if (!book_needs_saving) - return true; - - var dialog = new Gtk.MessageDialog (this, - Gtk.DialogFlags.MODAL, - Gtk.MessageType.WARNING, - Gtk.ButtonsType.NONE, - "%s", title); - dialog.format_secondary_text ("%s", - /* Text in dialog warning when a document is about to be lost*/ - _("If you don't save, changes will be permanently lost.")); - dialog.add_button (discard_label, Gtk.ResponseType.NO); - dialog.add_button (_("_Cancel"), Gtk.ResponseType.CANCEL); - dialog.add_button (_("_Save"), Gtk.ResponseType.YES); - - var response = dialog.run (); - dialog.destroy (); - - switch (response) - { - case Gtk.ResponseType.YES: - if (save_document ()) - return true; - else - return false; - case Gtk.ResponseType.NO: - return true; - default: - return false; - } - } - - private void clear_document () - { - book_view.default_page = new Page (default_page_width, - default_page_height, - default_page_dpi, - default_page_scan_direction); - book.clear (); - book_needs_saving = false; - book_uri = null; - save_menuitem.sensitive = false; - email_menuitem.sensitive = false; - print_menuitem.sensitive = false; - save_button.sensitive = false; - save_toolbutton.sensitive = false; - copy_to_clipboard_menuitem.sensitive = false; - } - - private void new_document () - { - if (!prompt_to_save (/* Text in dialog warning when a document is about to be lost */ - _("Save current document?"), - /* Button in dialog to create new document and discard unsaved document */ - _("Discard Changes"))) - return; - - if (scanning) - stop_scan (); - clear_document (); - } - - [GtkCallback] - private void new_button_clicked_cb (Gtk.Widget widget) - { - new_document(); - } - - public void new_document_activate_cb () - { - new_document(); - } - - private void set_document_hint (string document_hint, bool save = false) - { - this.document_hint = document_hint; - - if (document_hint == "text") - { - text_button_menuitem.active = true; - text_button_hb_menuitem.active = true; - text_menuitem.active = true; - } - else if (document_hint == "photo") - { - photo_button_menuitem.active = true; - photo_button_hb_menuitem.active = true; - photo_menuitem.active = true; - } - - if (save) - settings.set_string ("document-type", document_hint); - } - - [GtkCallback] - private void text_menuitem_toggled_cb (Gtk.CheckMenuItem widget) - { - if (widget.active) - set_document_hint ("text", true); - } - - [GtkCallback] - private void photo_menuitem_toggled_cb (Gtk.CheckMenuItem widget) - { - if (widget.active) - set_document_hint ("photo", true); - } - - private void set_page_side (ScanType page_side) - { - Gtk.TreeIter iter; - - if (page_side_model.get_iter_first (out iter)) - { - do - { - int s; - page_side_model.get (iter, 0, out s, -1); - if (s == page_side) - { - page_side_combo.set_active_iter (iter); - return; - } - } while (page_side_model.iter_next (ref iter)); - } - } - - private void set_paper_size (int width, int height) - { - Gtk.TreeIter iter; - bool have_iter; - - for (have_iter = paper_size_model.get_iter_first (out iter); - have_iter; - have_iter = paper_size_model.iter_next (ref iter)) - { - int w, h; - paper_size_model.get (iter, 0, out w, 1, out h, -1); - if (w == width && h == height) - break; - } - - if (!have_iter) - have_iter = paper_size_model.get_iter_first (out iter); - if (have_iter) - paper_size_combo.set_active_iter (iter); - } - - private int get_text_dpi () - { - Gtk.TreeIter iter; - int dpi = DEFAULT_TEXT_DPI; - - if (text_dpi_combo.get_active_iter (out iter)) - text_dpi_model.get (iter, 0, out dpi, -1); - - return dpi; - } - - private int get_photo_dpi () - { - Gtk.TreeIter iter; - int dpi = DEFAULT_PHOTO_DPI; - - if (photo_dpi_combo.get_active_iter (out iter)) - photo_dpi_model.get (iter, 0, out dpi, -1); - - return dpi; - } - - private ScanType get_page_side () - { - Gtk.TreeIter iter; - int page_side = ScanType.ADF_BOTH; - - if (page_side_combo.get_active_iter (out iter)) - page_side_model.get (iter, 0, out page_side, -1); - - return (ScanType) page_side; - } - - private bool get_paper_size (out int width, out int height) - { - Gtk.TreeIter iter; - - width = height = 0; - if (paper_size_combo.get_active_iter (out iter)) - { - paper_size_model.get (iter, 0, ref width, 1, ref height, -1); - return true; - } - - return false; - } - - private ScanOptions make_scan_options () - { - var options = new ScanOptions (); - if (document_hint == "text") - { - options.scan_mode = ScanMode.GRAY; - options.dpi = get_text_dpi (); - options.depth = 2; - } - else - { - options.scan_mode = ScanMode.COLOR; - options.dpi = get_photo_dpi (); - options.depth = 8; - } - get_paper_size (out options.paper_width, out options.paper_height); - options.brightness = brightness; - options.contrast = contrast; - options.page_delay = page_delay; - - return options; - } - - [GtkCallback] - private void scan_button_clicked_cb (Gtk.Widget widget) - { - var options = make_scan_options (); - options.type = ScanType.SINGLE; - start_scan (selected_device, options); - } - - [GtkCallback] - private void stop_scan_button_clicked_cb (Gtk.Widget widget) - { - stop_scan (); - } - - [GtkCallback] - private void continuous_scan_button_clicked_cb (Gtk.Widget widget) - { - if (scanning) - stop_scan (); - else - { - var options = make_scan_options (); - options.type = get_page_side (); - start_scan (selected_device, options); - } - } - - [GtkCallback] - private void batch_button_clicked_cb (Gtk.Widget widget) - { - var options = make_scan_options (); - options.type = ScanType.BATCH; - start_scan (selected_device, options); - } - - [GtkCallback] - private void preferences_button_clicked_cb (Gtk.Widget widget) - { - preferences_dialog.present (); - } - - public void preferences_activate_cb () - { - preferences_dialog.present (); - } - - [GtkCallback] - private bool preferences_dialog_delete_event_cb (Gtk.Widget widget, Gdk.EventAny event) - { - return true; - } - - [GtkCallback] - private void preferences_dialog_response_cb (Gtk.Widget widget, int response_id) - { - preferences_dialog.visible = false; - } - - private void update_page_menu () - { - var page = book_view.selected_page; - if (page == null) - { - page_move_left_menuitem.sensitive = false; - page_move_right_menuitem.sensitive = false; - } - else - { - var index = book.get_page_index (page); - page_move_left_menuitem.sensitive = index > 0; - page_move_right_menuitem.sensitive = index < book.n_pages - 1; - } - } - - private void page_selected_cb (BookView view, Page? page) - { - if (page == null) - return; - - updating_page_menu = true; - - update_page_menu (); - - var menuitem = no_crop_menuitem; - if (page.has_crop) - { - var crop_name = page.crop_name; - if (crop_name != null) - { - if (crop_name == "A4") - menuitem = a4_menuitem; - else if (crop_name == "A5") - menuitem = a5_menuitem; - else if (crop_name == "A6") - menuitem = a6_menuitem; - else if (crop_name == "letter") - menuitem = letter_menuitem; - else if (crop_name == "legal") - menuitem = legal_menuitem; - else if (crop_name == "4x6") - menuitem = four_by_six_menuitem; - } - else - menuitem = custom_crop_menuitem; - } - - menuitem.active = true; - crop_button.active = page.has_crop; - crop_toolbutton.active = page.has_crop; - - updating_page_menu = false; - } - - private void show_page_cb (BookView view, Page page) - { - var path = get_temporary_filename ("scanned-page", "png"); - if (path == null) - return; - var file = File.new_for_path (path); - - try - { - page.save ("png", quality, file); - } - catch (Error e) - { - show_error_dialog (/* Error message display when unable to save image for preview */ - _("Unable to save image for preview"), - e.message); - return; - } - - try - { - Gtk.show_uri (screen, file.get_uri (), Gtk.get_current_event_time ()); - } - catch (Error e) - { - show_error_dialog (/* Error message display when unable to preview image */ - _("Unable to open image preview application"), - e.message); - } - } - - private void show_page_menu_cb (BookView view) - { - page_menu.popup (null, null, null, 3, Gtk.get_current_event_time ()); - } - - [GtkCallback] - private void rotate_left_button_clicked_cb (Gtk.Widget widget) - { - if (updating_page_menu) - return; - var page = book_view.selected_page; - if (page != null) - page.rotate_left (); - } - - [GtkCallback] - private void rotate_right_button_clicked_cb (Gtk.Widget widget) - { - if (updating_page_menu) - return; - var page = book_view.selected_page; - if (page != null) - page.rotate_right (); - } - - private void set_crop (string? crop_name) - { - crop_rotate_menuitem.sensitive = crop_name != null; - - if (updating_page_menu) - return; - - var page = book_view.selected_page; - if (page == null) - { - warning ("Trying to set crop but no selected page"); - return; - } - - if (crop_name == null) - page.set_no_crop (); - else if (crop_name == "custom") - { - var width = page.width; - var height = page.height; - var crop_width = (int) (width * 0.8 + 0.5); - var crop_height = (int) (height * 0.8 + 0.5); - page.set_custom_crop (crop_width, crop_height); - page.move_crop ((width - crop_width) / 2, (height - crop_height) / 2); - } - else - page.set_named_crop (crop_name); - } - - [GtkCallback] - private void no_crop_menuitem_toggled_cb (Gtk.CheckMenuItem widget) - { - if (widget.active) - set_crop (null); - } - - [GtkCallback] - private void custom_crop_menuitem_toggled_cb (Gtk.CheckMenuItem widget) - { - if (widget.active) - set_crop ("custom"); - } - - [GtkCallback] - private void crop_button_toggled_cb (Gtk.ToggleButton widget) - { - if (updating_page_menu) - return; - - if (widget.active) - custom_crop_menuitem.active = true; - else - no_crop_menuitem.active = true; - } - - [GtkCallback] - private void crop_toolbutton_toggled_cb (Gtk.ToggleToolButton widget) - { - if (updating_page_menu) - return; - - if (widget.active) - custom_crop_menuitem.active = true; - else - no_crop_menuitem.active = true; - } - - [GtkCallback] - private void four_by_six_menuitem_toggled_cb (Gtk.CheckMenuItem widget) - { - if (widget.active) - set_crop ("4x6"); - } - - [GtkCallback] - private void legal_menuitem_toggled_cb (Gtk.CheckMenuItem widget) - { - if (widget.active) - set_crop ("legal"); - } - - [GtkCallback] - private void letter_menuitem_toggled_cb (Gtk.CheckMenuItem widget) - { - if (widget.active) - set_crop ("letter"); - } - - [GtkCallback] - private void a6_menuitem_toggled_cb (Gtk.CheckMenuItem widget) - { - if (widget.active) - set_crop ("A6"); - } - - [GtkCallback] - private void a5_menuitem_toggled_cb (Gtk.CheckMenuItem widget) - { - if (widget.active) - set_crop ("A5"); - } - - [GtkCallback] - private void a4_menuitem_toggled_cb (Gtk.CheckMenuItem widget) - { - if (widget.active) - set_crop ("A4"); - } - - [GtkCallback] - private void crop_rotate_menuitem_activate_cb (Gtk.Widget widget) - { - var page = book_view.selected_page; - if (page == null) - return; - page.rotate_crop (); - } - - [GtkCallback] - private void page_move_left_menuitem_activate_cb (Gtk.Widget widget) - { - var page = book_view.selected_page; - var index = book.get_page_index (page); - if (index > 0) - book.move_page (page, index - 1); - } - - [GtkCallback] - private void page_move_right_menuitem_activate_cb (Gtk.Widget widget) - { - var page = book_view.selected_page; - var index = book.get_page_index (page); - if (index < book.n_pages - 1) - book.move_page (page, book.get_page_index (page) + 1); - } - - [GtkCallback] - private void page_delete_menuitem_activate_cb (Gtk.Widget widget) - { - book_view.book.delete_page (book_view.selected_page); - } - - private void reorder_document () - { - var dialog = new Gtk.Window (); - dialog.type_hint = Gdk.WindowTypeHint.DIALOG; - dialog.modal = true; - dialog.border_width = 12; - /* Title of dialog to reorder pages */ - dialog.title = _("Reorder Pages"); - dialog.set_transient_for (this); - dialog.key_press_event.connect ((e) => - { - if (e.state == 0 && e.keyval == Gdk.Key.Escape) - { - dialog.destroy (); - return true; - } - - return false; - }); - dialog.visible = true; - - var g = new Gtk.Grid (); - g.row_homogeneous = true; - g.row_spacing = 6; - g.column_homogeneous = true; - g.column_spacing = 6; - g.visible = true; - dialog.add (g); - - /* Label on button for combining sides in reordering dialog */ - var b = make_reorder_button (_("Combine sides"), "F1F2F3B1B2B3-F1B1F2B2F3B3"); - b.clicked.connect (() => - { - book.combine_sides (); - dialog.destroy (); - }); - b.visible = true; - g.attach (b, 0, 0, 1, 1); - - /* Label on button for combining sides in reverse order in reordering dialog */ - b = make_reorder_button (_("Combine sides (reverse)"), "F1F2F3B3B2B1-F1B1F2B2F3B3"); - b.clicked.connect (() => - { - book.combine_sides_reverse (); - dialog.destroy (); - }); - b.visible = true; - g.attach (b, 1, 0, 1, 1); - - /* Label on button for reversing in reordering dialog */ - b = make_reorder_button (_("Reverse"), "C1C2C3C4C5C6-C6C5C4C3C2C1"); - b.clicked.connect (() => - { - book.reverse (); - dialog.destroy (); - }); - b.visible = true; - g.attach (b, 0, 2, 1, 1); - - /* Label on button for cancelling page reordering dialog */ - b = make_reorder_button (_("Keep unchanged"), "C1C2C3C4C5C6-C1C2C3C4C5C6"); - b.clicked.connect (() => - { - dialog.destroy (); - }); - b.visible = true; - g.attach (b, 1, 2, 1, 1); - - dialog.present (); - } - - public void reorder_document_activate_cb () - { - reorder_document (); - } - - [GtkCallback] - private void reorder_menuitem_activate_cb (Gtk.Widget widget) - { - reorder_document (); - } - - private Gtk.Button make_reorder_button (string text, string items) - { - var b = new Gtk.Button (); - - var vbox = new Gtk.Box (Gtk.Orientation.VERTICAL, 6); - vbox.visible = true; - b.add (vbox); - - var label = new Gtk.Label (text); - label.visible = true; - vbox.pack_start (label, true, true, 0); - - var rb = make_reorder_box (items); - rb.visible = true; - vbox.pack_start (rb, true, true, 0); - - return b; - } - - private Gtk.Box make_reorder_box (string items) - { - var box = new Gtk.Box (Gtk.Orientation.HORIZONTAL, 6); - box.visible = true; - - Gtk.Box? page_box = null; - for (var i = 0; items[i] != '\0'; i++) - { - if (items[i] == '-') - { - var a = new Gtk.Arrow (Gtk.ArrowType.RIGHT, Gtk.ShadowType.NONE); - a.visible = true; - box.pack_start (a, false, false, 0); - page_box = null; - continue; - } - - /* First character describes side */ - var side = items[i]; - i++; - if (items[i] == '\0') - break; - - if (page_box == null) - { - page_box = new Gtk.Box (Gtk.Orientation.HORIZONTAL, 3); - page_box.visible = true; - box.pack_start (page_box, false, false, 0); - } - - /* Get colours for each page (from Tango palette) */ - var r = 1.0; - var g = 1.0; - var b = 1.0; - switch (side) - { - case 'F': - /* Plum */ - r = 0x75 / 255.0; - g = 0x50 / 255.0; - b = 0x7B / 255.0; - break; - case 'B': - /* Orange */ - r = 0xF5 / 255.0; - g = 0x79 / 255.0; - b = 0.0; - break; - case 'C': - /* Butter to Scarlet Red */ - var p = (items[i] - '1') / 5.0; - r = (0xED / 255.0) * (1 - p) + 0xCC * p; - g = (0xD4 / 255.0) * (1 - p); - b = 0; - break; - } - - /* Mix with white to look more paper like */ - r = r + (1.0 - r) * 0.7; - g = g + (1.0 - g) * 0.7; - b = b + (1.0 - b) * 0.7; - - var icon = new PageIcon ("%c".printf (items[i]), r, g, b); - icon.visible = true; - page_box.pack_start (icon, false, false, 0); - } - - return box; - } - - [GtkCallback] - private void save_file_button_clicked_cb (Gtk.Widget widget) - { - save_document (); - } - - public void save_document_activate_cb () - { - save_document (); - } - - [GtkCallback] - private void copy_to_clipboard_button_clicked_cb (Gtk.Widget widget) - { - var page = book_view.selected_page; - if (page != null) - page.copy_to_clipboard (this); - } - - private void draw_page (Gtk.PrintOperation operation, - Gtk.PrintContext print_context, - int page_number) - { - var context = print_context.get_cairo_context (); - var page = book.get_page (page_number); - - /* Rotate to same aspect */ - bool is_landscape = false; - if (print_context.get_width () > print_context.get_height ()) - is_landscape = true; - if (page.is_landscape != is_landscape) - { - context.translate (print_context.get_width (), 0); - context.rotate (Math.PI_2); - } - - context.scale (print_context.get_dpi_x () / page.dpi, - print_context.get_dpi_y () / page.dpi); - - var image = page.get_image (true); - Gdk.cairo_set_source_pixbuf (context, image, 0, 0); - context.paint (); - } - - [GtkCallback] - private void email_button_clicked_cb (Gtk.Widget widget) - { - email (document_hint, quality); - } - - public void email_document_activate_cb () - { - email (document_hint, quality); - } - - private void print_document () - { - var print = new Gtk.PrintOperation (); - print.n_pages = (int) book.n_pages; - print.draw_page.connect (draw_page); - - try - { - print.run (Gtk.PrintOperationAction.PRINT_DIALOG, this); - } - catch (Error e) - { - warning ("Error printing: %s", e.message); - } - - print.draw_page.disconnect (draw_page); - } - - [GtkCallback] - private void print_button_clicked_cb (Gtk.Widget widget) - { - print_document (); - } - - public void print_document_activate_cb () - { - print_document (); - } - - private void launch_help () - { - try - { - Gtk.show_uri (screen, "help:simple-scan", Gtk.get_current_event_time ()); - } - catch (Error e) - { - show_error_dialog (/* Error message displayed when unable to launch help browser */ - _("Unable to open help file"), - e.message); - } - } - - [GtkCallback] - private void help_contents_menuitem_activate_cb (Gtk.Widget widget) - { - launch_help (); - } - - public void help_contents_activate_cb () - { - launch_help (); - } - - private void show_about () - { - string[] authors = { "Robert Ancell " }; - - /* The license this software is under (GPL3+) */ - string license = _("This program is free software: you can redistribute it and/or modify\nit under the terms of the GNU General Public License as published by\nthe Free Software Foundation, either version 3 of the License, or\n(at your option) any later version.\n\nThis program is distributed in the hope that it will be useful,\nbut WITHOUT ANY WARRANTY; without even the implied warranty of\nMERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the\nGNU General Public License for more details.\n\nYou should have received a copy of the GNU General Public License\nalong with this program. If not, see ."); - - /* Title of about dialog */ - string title = _("About Simple Scan"); - - /* Description of program */ - string description = _("Simple document scanning tool"); - - Gtk.show_about_dialog (this, - "title", title, - "program-name", "Simple Scan", - "version", VERSION, - "comments", description, - "logo-icon-name", "scanner", - "authors", authors, - "translator-credits", _("translator-credits"), - "website", "https://launchpad.net/simple-scan", - "copyright", "Copyright © 2009-2015 Canonical Ltd.", - "license", license, - "wrap-license", true, - null); - } - - [GtkCallback] - private void about_menuitem_activate_cb (Gtk.Widget widget) - { - show_about (); - } - - public void about_activate_cb () - { - show_about (); - } - - private bool on_quit () - { - if (!prompt_to_save (/* Text in dialog warning when a document is about to be lost */ - _("Save document before quitting?"), - /* Button in dialog to quit and discard unsaved document */ - _("Quit without Saving"))) - return false; - - destroy (); - - if (save_state_timeout != 0) - save_state (true); - - autosave_manager.cleanup (); - - return true; - } - - [GtkCallback] - private void quit_menuitem_activate_cb (Gtk.Widget widget) - { - on_quit (); - } - - public void quit_activate_cb () - { - on_quit (); - } - - public override void size_allocate (Gtk.Allocation allocation) - { - base.size_allocate (allocation); - - if (!window_is_maximized && !window_is_fullscreen) - { - get_size (out window_width, out window_height); - save_state (); - } - } - - private void info_bar_response_cb (Gtk.InfoBar widget, int response_id) - { - switch (response_id) - { - /* Change scanner */ - case 1: - device_combo.grab_focus (); - preferences_dialog.present (); - break; - /* Install drivers */ - case 2: - install_drivers (); - break; - default: - have_error = false; - error_title = null; - error_text = null; - update_info_bar (); - break; - } - } - - private void install_drivers () - { - var message = "", instructions = ""; - string[] packages_to_install = {}; - switch (missing_driver) - { - case "brscan": - case "brscan2": - case "brscan3": - case "brscan4": - /* Message to indicate a Brother scanner has been detected */ - message = _("You appear to have a Brother scanner."); - /* Instructions on how to install Brother scanner drivers */ - instructions = _("Drivers for this are available on the Brother website."); - break; - case "samsung": - /* Message to indicate a Samsung scanner has been detected */ - message = _("You appear to have a Samsung scanner."); - /* Instructions on how to install Samsung scanner drivers */ - instructions = _("Drivers for this are available on the Samsung website."); - break; - case "hpaio": - /* Message to indicate a HP scanner has been detected */ - message = _("You appear to have an HP scanner."); - packages_to_install = { "libsane-hpaio" }; - break; - case "epkowa": - /* Message to indicate an Epson scanner has been detected */ - message = _("You appear to have an Epson scanner."); - /* Instructions on how to install Epson scanner drivers */ - instructions = _("Drivers for this are available on the Epson website."); - break; - } - var dialog = new Gtk.Dialog.with_buttons (/* Title of dialog giving instructions on how to install drivers */ - _("Install drivers"), this, Gtk.DialogFlags.MODAL, _("_Close"), Gtk.ResponseType.CLOSE); - dialog.get_content_area ().border_width = 12; - dialog.get_content_area ().spacing = 6; - - var label = new Gtk.Label (message); - label.visible = true; - label.xalign = 0f; - dialog.get_content_area ().pack_start (label, true, true, 0); - - var instructions_box = new Gtk.Box (Gtk.Orientation.HORIZONTAL, 6); - instructions_box.visible = true; - dialog.get_content_area ().pack_start (instructions_box, true, true, 0); - - var stack = new Gtk.Stack (); - instructions_box.pack_start (stack, false, false, 0); - - var spinner = new Gtk.Spinner (); - spinner.visible = true; - stack.add (spinner); - - var status_label = new Gtk.Label (""); - status_label.visible = true; - stack.add (status_label); - - var instructions_label = new Gtk.Label (instructions); - instructions_label.visible = true; - instructions_label.xalign = 0f; - instructions_label.use_markup = true; - instructions_box.pack_start (instructions_label, false, false, 0); - - label = new Gtk.Label (/* Message in driver install dialog */ - _("Once installed you will need to restart Simple Scan.")); - label.visible = true; - label.xalign = 0f; - dialog.get_content_area ().border_width = 12; - dialog.get_content_area ().pack_start (label, true, true, 0); - - if (packages_to_install.length > 0) - { -#if HAVE_PACKAGEKIT - stack.visible = true; - spinner.active = true; - instructions_label.set_text (/* Label shown while installing drivers */ - _("Installing drivers...")); - install_packages.begin (packages_to_install, () => {}, (object, result) => - { - status_label.visible = true; - spinner.active = false; - status_label.set_text ("☒"); - stack.visible_child = status_label; - /* Label shown once drivers successfully installed */ - var result_text = _("Drivers installed successfully!"); - try - { - var results = install_packages.end (result); - if (results.get_error_code () == null) - status_label.set_text ("☑"); - else - { - var e = results.get_error_code (); - /* Label shown if failed to install drivers */ - result_text = _("Failed to install drivers (error code %d).").printf (e.code); - } - } - catch (Error e) - { - /* Label shown if failed to install drivers */ - result_text = _("Failed to install drivers."); - warning ("Failed to install drivers: %s", e.message); - } - instructions_label.set_text (result_text); - }); -#else - instructions_label.set_text (/* Label shown to prompt user to install packages (when PackageKit not available) */ - _("You need to install the %s package(s).").printf (string.joinv (", ", packages_to_install))); -#endif - } - - dialog.run (); - dialog.destroy (); - } - -#if HAVE_PACKAGEKIT - private async Pk.Results? install_packages (string[] packages, Pk.ProgressCallback progress_callback) throws GLib.Error - { - var task = new Pk.Task (); - Pk.Results results; - results = yield task.resolve_async (Pk.Filter.NOT_INSTALLED, packages, null, progress_callback); - if (results == null || results.get_error_code () != null) - return results; - - var package_array = results.get_package_array (); - var package_ids = new string[package_array.length + 1]; - package_ids[package_array.length] = null; - for (var i = 0; i < package_array.length; i++) - package_ids[i] = package_array.data[i].get_id (); - - return yield task.install_packages_async (package_ids, null, progress_callback); - } -#endif - - public override bool window_state_event (Gdk.EventWindowState event) - { - var result = Gdk.EVENT_PROPAGATE; - - if (base.window_state_event != null) - result = base.window_state_event (event); - - if ((event.changed_mask & Gdk.WindowState.MAXIMIZED) != 0) - { - window_is_maximized = (event.new_window_state & Gdk.WindowState.MAXIMIZED) != 0; - save_state (); - } - if ((event.changed_mask & Gdk.WindowState.FULLSCREEN) != 0) - { - window_is_fullscreen = (event.new_window_state & Gdk.WindowState.FULLSCREEN) != 0; - save_state (); - } - - return result; - } - - [GtkCallback] - private bool window_delete_event_cb (Gtk.Widget widget, Gdk.EventAny event) - { - return !on_quit (); - } - - private void page_size_changed_cb (Page page) - { - default_page_width = page.width; - default_page_height = page.height; - default_page_dpi = page.dpi; - save_state (); - } - - private void page_scan_direction_changed_cb (Page page) - { - default_page_scan_direction = page.scan_direction; - save_state (); - } - - private void page_added_cb (Book book, Page page) - { - page_size_changed_cb (page); - default_page_scan_direction = page.scan_direction; - page.size_changed.connect (page_size_changed_cb); - page.scan_direction_changed.connect (page_scan_direction_changed_cb); - - update_page_menu (); - } - - private void reordered_cb (Book book) - { - update_page_menu (); - } - - private void page_removed_cb (Book book, Page page) - { - page.size_changed.disconnect (page_size_changed_cb); - page.scan_direction_changed.disconnect (page_scan_direction_changed_cb); - - update_page_menu (); - } - - private void set_dpi_combo (Gtk.ComboBox combo, int default_dpi, int current_dpi) - { - var renderer = new Gtk.CellRendererText (); - combo.pack_start (renderer, true); - combo.add_attribute (renderer, "text", 1); - - var model = combo.model as Gtk.ListStore; - int[] scan_resolutions = {75, 150, 300, 600, 1200, 2400}; - foreach (var dpi in scan_resolutions) - { - string label; - if (dpi == default_dpi) - /* Preferences dialog: Label for default resolution in resolution list */ - label = _("%d dpi (default)").printf (dpi); - else if (dpi == 75) - /* Preferences dialog: Label for minimum resolution in resolution list */ - label = _("%d dpi (draft)").printf (dpi); - else if (dpi == 1200) - /* Preferences dialog: Label for maximum resolution in resolution list */ - label = _("%d dpi (high resolution)").printf (dpi); - else - /* Preferences dialog: Label for resolution value in resolution list (dpi = dots per inch) */ - label = _("%d dpi").printf (dpi); - - Gtk.TreeIter iter; - model.append (out iter); - model.set (iter, 0, dpi, 1, label, -1); - - if (dpi == current_dpi) - combo.set_active_iter (iter); - } - } - - private void book_changed_cb (Book book) - { - save_menuitem.sensitive = true; - email_menuitem.sensitive = true; - print_menuitem.sensitive = true; - save_button.sensitive = true; - save_toolbutton.sensitive = true; - book_needs_saving = true; - copy_to_clipboard_menuitem.sensitive = true; - } - - private void load () - { - Gtk.IconTheme.get_default ().append_search_path (ICON_DIR); - - Gtk.Window.set_default_icon_name ("scanner"); - - var app = Application.get_default () as Gtk.Application; - - if (is_traditional_desktop ()) - { - set_titlebar (null); - menubar.visible = true; - toolbar.visible = true; - } - else - { - app.add_action_entries (action_entries, this); - - var appmenu = new Menu (); - var section = new Menu (); - appmenu.append_section (null, section); - section.append (_("New Document"), "app.new_document"); - - section = new Menu (); - appmenu.append_section (null, section); - var menu = new Menu (); - section.append_submenu (_("Document"), menu); - menu.append (_("Reorder Pages"), "app.reorder"); - menu.append (_("Save"), "app.save"); - menu.append (_("Email..."), "app.email"); - menu.append (_("Print..."), "app.print"); - - section = new Menu (); - appmenu.append_section (null, section); - section.append (_("Preferences"), "app.preferences"); - - section = new Menu (); - appmenu.append_section (null, section); - section.append (_("Help"), "app.help"); - section.append (_("About"), "app.about"); - section.append (_("Quit"), "app.quit"); - - app.app_menu = appmenu; - - app.add_accelerator ("N", "app.new_document", null); - app.add_accelerator ("S", "app.save", null); - app.add_accelerator ("E", "app.email", null); - app.add_accelerator ("P", "app.print", null); - app.add_accelerator ("F1", "app.help", null); - app.add_accelerator ("Q", "app.quit", null); - } - app.add_window (this); - - /* Add InfoBar (not supported in Glade) */ - info_bar = new Gtk.InfoBar (); - info_bar.response.connect (info_bar_response_cb); - main_vbox.pack_start (info_bar, false, true, 0); - var hbox = new Gtk.Box (Gtk.Orientation.HORIZONTAL, 12); - var content_area = info_bar.get_content_area () as Gtk.Container; - content_area.add (hbox); - hbox.visible = true; - - info_bar_image = new Gtk.Image.from_icon_name ("dialog-warning", Gtk.IconSize.DIALOG); - hbox.pack_start (info_bar_image, false, true, 0); - info_bar_image.visible = true; - - info_bar_label = new Gtk.Label (null); - info_bar_label.set_alignment (0.0f, 0.5f); - hbox.pack_start (info_bar_label, true, true, 0); - info_bar_label.visible = true; - - info_bar_close_button = info_bar.add_button (_("_Close"), Gtk.ResponseType.CLOSE) as Gtk.Button; - info_bar_change_scanner_button = info_bar.add_button (/* Button in error infobar to open preferences dialog and change scanner */ - _("Change _Scanner"), 1) as Gtk.Button; - info_bar_install_button = info_bar.add_button (/* Button in error infobar to prompt user to install drivers */ - _("_Install Drivers"), 2) as Gtk.Button; - - Gtk.TreeIter iter; - paper_size_model.append (out iter); - paper_size_model.set (iter, 0, 0, 1, 0, 2, - /* Combo box value for automatic paper size */ - _("Automatic"), -1); - paper_size_model.append (out iter); - paper_size_model.set (iter, 0, 1050, 1, 1480, 2, "A6", -1); - paper_size_model.append (out iter); - paper_size_model.set (iter, 0, 1480, 1, 2100, 2, "A5", -1); - paper_size_model.append (out iter); - paper_size_model.set (iter, 0, 2100, 1, 2970, 2, "A4", -1); - paper_size_model.append (out iter); - paper_size_model.set (iter, 0, 2159, 1, 2794, 2, "Letter", -1); - paper_size_model.append (out iter); - paper_size_model.set (iter, 0, 2159, 1, 3556, 2, "Legal", -1); - paper_size_model.append (out iter); - paper_size_model.set (iter, 0, 1016, 1, 1524, 2, "4×6", -1); - - var dpi = settings.get_int ("text-dpi"); - if (dpi <= 0) - dpi = DEFAULT_TEXT_DPI; - set_dpi_combo (text_dpi_combo, DEFAULT_TEXT_DPI, dpi); - text_dpi_combo.changed.connect (() => { settings.set_int ("text-dpi", get_text_dpi ()); }); - dpi = settings.get_int ("photo-dpi"); - if (dpi <= 0) - dpi = DEFAULT_PHOTO_DPI; - set_dpi_combo (photo_dpi_combo, DEFAULT_PHOTO_DPI, dpi); - photo_dpi_combo.changed.connect (() => { settings.set_int ("photo-dpi", get_photo_dpi ()); }); - - var renderer = new Gtk.CellRendererText (); - device_combo.pack_start (renderer, true); - device_combo.add_attribute (renderer, "text", 1); - - renderer = new Gtk.CellRendererText (); - page_side_combo.pack_start (renderer, true); - page_side_combo.add_attribute (renderer, "text", 1); - set_page_side ((ScanType) settings.get_enum ("page-side")); - page_side_combo.changed.connect (() => { settings.set_enum ("page-side", get_page_side ()); }); - - renderer = new Gtk.CellRendererText (); - paper_size_combo.pack_start (renderer, true); - paper_size_combo.add_attribute (renderer, "text", 2); - var paper_width = settings.get_int ("paper-width"); - var paper_height = settings.get_int ("paper-height"); - set_paper_size (paper_width, paper_height); - paper_size_combo.changed.connect (() => - { - int w, h; - get_paper_size (out w, out h); - settings.set_int ("paper-width", w); - settings.set_int ("paper-height", h); - }); - - var lower = brightness_adjustment.lower; - var darker_label = "%s".printf (_("Darker")); - var upper = brightness_adjustment.upper; - var lighter_label = "%s".printf (_("Lighter")); - brightness_scale.add_mark (lower, Gtk.PositionType.BOTTOM, darker_label); - brightness_scale.add_mark (0, Gtk.PositionType.BOTTOM, null); - brightness_scale.add_mark (upper, Gtk.PositionType.BOTTOM, lighter_label); - brightness = settings.get_int ("brightness"); - brightness_adjustment.value_changed.connect (() => { settings.set_int ("brightness", brightness); }); - - lower = contrast_adjustment.lower; - var less_label = "%s".printf (_("Less")); - upper = contrast_adjustment.upper; - var more_label = "%s".printf (_("More")); - contrast_scale.add_mark (lower, Gtk.PositionType.BOTTOM, less_label); - contrast_scale.add_mark (0, Gtk.PositionType.BOTTOM, null); - contrast_scale.add_mark (upper, Gtk.PositionType.BOTTOM, more_label); - contrast = settings.get_int ("contrast"); - contrast_adjustment.value_changed.connect (() => { settings.set_int ("contrast", contrast); }); - - lower = quality_adjustment.lower; - var minimum_label = "%s".printf (_("Minimum")); - upper = quality_adjustment.upper; - var maximum_label = "%s".printf (_("Maximum")); - quality_scale.add_mark (lower, Gtk.PositionType.BOTTOM, minimum_label); - quality_scale.add_mark (75, Gtk.PositionType.BOTTOM, null); - quality_scale.add_mark (upper, Gtk.PositionType.BOTTOM, maximum_label); - quality = settings.get_int ("jpeg-quality"); - quality_adjustment.value_changed.connect (() => { settings.set_int ("jpeg-quality", quality); }); - - page_delay_scale.add_mark (0, Gtk.PositionType.BOTTOM, null); - page_delay_scale.add_mark (500, Gtk.PositionType.BOTTOM, null); - page_delay_scale.add_mark (1000, Gtk.PositionType.BOTTOM, null); - page_delay_scale.add_mark (2000, Gtk.PositionType.BOTTOM, null); - page_delay_scale.add_mark (4000, Gtk.PositionType.BOTTOM, null); - page_delay_scale.add_mark (6000, Gtk.PositionType.BOTTOM, null); - page_delay_scale.add_mark (8000, Gtk.PositionType.BOTTOM, null); - page_delay_scale.add_mark (10000, Gtk.PositionType.BOTTOM, null); - page_delay = settings.get_int ("page-delay"); - page_delay_scale.format_value.connect ((value) => { return "%.1fs".printf (value / 1000.0); }); - page_delay_adjustment.value_changed.connect (() => { settings.set_int ("page-delay", page_delay); }); - - var document_type = settings.get_string ("document-type"); - if (document_type != null) - set_document_hint (document_type); - - book_view = new BookView (book); - book_view.border_width = 18; - main_vbox.pack_end (book_view, true, true, 0); - book_view.page_selected.connect (page_selected_cb); - book_view.show_page.connect (show_page_cb); - book_view.show_menu.connect (show_page_menu_cb); - book_view.visible = true; - - authorize_dialog.transient_for = this; - preferences_dialog.transient_for = this; - - /* Load previous state */ - load_state (); - - /* Restore window size */ - debug ("Restoring window to %dx%d pixels", window_width, window_height); - set_default_size (window_width, window_height); - if (window_is_maximized) - { - debug ("Restoring window to maximized"); - maximize (); - } - if (window_is_fullscreen) - { - debug ("Restoring window to fullscreen"); - fullscreen (); - } - - progress_dialog = new ProgressBarDialog (this, _("Saving document...")); - book.saving.connect (book_saving_cb); - } - - private bool is_desktop (string name) - { - var desktop_name_list = Environment.get_variable ("XDG_CURRENT_DESKTOP"); - if (desktop_name_list == null) - return false; - - foreach (var n in desktop_name_list.split (":")) - if (n == name) - return true; - - return false; - } - - private bool is_traditional_desktop () - { - const string[] traditional_desktops = { "Unity", "XFCE", "MATE", "LXDE", "Cinnamon", "X-Cinnamon" }; - foreach (var name in traditional_desktops) - if (is_desktop (name)) - return true; - return false; - } - - private string state_filename - { - owned get { return Path.build_filename (Environment.get_user_cache_dir (), "simple-scan", "state"); } - } - - private void load_state () - { - debug ("Loading state from %s", state_filename); - - var f = new KeyFile (); - try - { - f.load_from_file (state_filename, KeyFileFlags.NONE); - } - catch (Error e) - { - if (!(e is FileError.NOENT)) - warning ("Failed to load state: %s", e.message); - } - window_width = state_get_integer (f, "window", "width", 600); - if (window_width <= 0) - window_width = 600; - window_height = state_get_integer (f, "window", "height", 400); - if (window_height <= 0) - window_height = 400; - window_is_maximized = state_get_boolean (f, "window", "is-maximized"); - window_is_fullscreen = state_get_boolean (f, "window", "is-fullscreen"); - default_page_width = state_get_integer (f, "last-page", "width", 595); - default_page_height = state_get_integer (f, "last-page", "height", 842); - default_page_dpi = state_get_integer (f, "last-page", "dpi", 72); - switch (state_get_string (f, "last-page", "scan-direction", "top-to-bottom")) - { - default: - case "top-to-bottom": - default_page_scan_direction = ScanDirection.TOP_TO_BOTTOM; - break; - case "bottom-to-top": - default_page_scan_direction = ScanDirection.BOTTOM_TO_TOP; - break; - case "left-to-right": - default_page_scan_direction = ScanDirection.LEFT_TO_RIGHT; - break; - case "right-to-left": - default_page_scan_direction = ScanDirection.RIGHT_TO_LEFT; - break; - } - } - - private int state_get_integer (KeyFile f, string group_name, string key, int default = 0) - { - try - { - return f.get_integer (group_name, key); - } - catch - { - return default; - } - } - - private bool state_get_boolean (KeyFile f, string group_name, string key, bool default = false) - { - try - { - return f.get_boolean (group_name, key); - } - catch - { - return default; - } - } - - private string state_get_string (KeyFile f, string group_name, string key, string default = "") - { - try - { - return f.get_string (group_name, key); - } - catch - { - return default; - } - } - - private void save_state (bool force = false) - { - if (!force) - { - if (save_state_timeout != 0) - Source.remove (save_state_timeout); - save_state_timeout = Timeout.add (100, () => - { - save_state (true); - save_state_timeout = 0; - return false; - }); - return; - } - - debug ("Saving state to %s", state_filename); - - var f = new KeyFile (); - f.set_integer ("window", "width", window_width); - f.set_integer ("window", "height", window_height); - f.set_boolean ("window", "is-maximized", window_is_maximized); - f.set_boolean ("window", "is-fullscreen", window_is_fullscreen); - f.set_integer ("last-page", "width", default_page_width); - f.set_integer ("last-page", "height", default_page_height); - f.set_integer ("last-page", "dpi", default_page_dpi); - switch (default_page_scan_direction) - { - case ScanDirection.TOP_TO_BOTTOM: - f.set_value ("last-page", "scan-direction", "top-to-bottom"); - break; - case ScanDirection.BOTTOM_TO_TOP: - f.set_value ("last-page", "scan-direction", "bottom-to-top"); - break; - case ScanDirection.LEFT_TO_RIGHT: - f.set_value ("last-page", "scan-direction", "left-to-right"); - break; - case ScanDirection.RIGHT_TO_LEFT: - f.set_value ("last-page", "scan-direction", "right-to-left"); - break; - } - try - { - FileUtils.set_contents (state_filename, f.to_data ()); - } - catch (Error e) - { - warning ("Failed to write state: %s", e.message); - } - } - - private void book_saving_cb (int page_number) - { - /* Prevent GUI from freezing */ - while (Gtk.events_pending ()) - Gtk.main_iteration (); - - var total = (int) book.n_pages; - var fraction = (page_number + 1.0) / total; - var complete = fraction == 1.0; - if (complete) - Timeout.add (500, () => { - progress_dialog.visible = false; - return false; - }); - var message = _("Saving page %d out of %d").printf (page_number + 1, total); - - progress_dialog.fraction = fraction; - progress_dialog.message = message; - } - - public void show_progress_dialog () - { - progress_dialog.visible = true; - } - - public void hide_progress_dialog () - { - progress_dialog.visible = false; - } - - public void show_error (string error_title, string error_text, bool change_scanner_hint) - { - have_error = true; - this.error_title = error_title; - this.error_text = error_text; - error_change_scanner_hint = change_scanner_hint; - update_info_bar (); - } - - public void start () - { - visible = true; - } -} - -private class ProgressBarDialog : Gtk.Window -{ - private Gtk.ProgressBar bar; - - public double fraction - { - get { return bar.fraction; } - set { bar.fraction = value; } - } - - public string message - { - get { return bar.text; } - set { bar.text = value; } - } - - public ProgressBarDialog (Gtk.ApplicationWindow parent, string title) - { - bar = new Gtk.ProgressBar (); - var hbox = new Gtk.Box (Gtk.Orientation.HORIZONTAL, 5); - var vbox = new Gtk.Box (Gtk.Orientation.VERTICAL, 5); - hbox.hexpand = true; - - bar.text = ""; - bar.show_text = true; - bar.set_size_request (225, 25); - set_size_request (250, 50); - - vbox.pack_start (bar, true, false, 0); - hbox.pack_start (vbox, true, false, 0); - add (hbox); - this.title = title; - - transient_for = parent; - set_position (Gtk.WindowPosition.CENTER_ON_PARENT); - modal = true; - resizable = false; - - hbox.visible = true; - vbox.visible = true; - bar.visible = true; - } -} - -// FIXME: Duplicated from simple-scan.vala -private string? get_temporary_filename (string prefix, string extension) -{ - /* NOTE: I'm not sure if this is a 100% safe strategy to use g_file_open_tmp(), close and - * use the filename but it appears to work in practise */ - - var filename = "%sXXXXXX.%s".printf (prefix, extension); - string path; - try - { - var fd = FileUtils.open_tmp (filename, out path); - Posix.close (fd); - } - catch (Error e) - { - warning ("Error saving email attachment: %s", e.message); - return null; - } - - return path; -} - -private class PageIcon : Gtk.DrawingArea -{ - private string text; - private double r; - private double g; - private double b; - private const int MINIMUM_WIDTH = 20; - - public PageIcon (string text, double r = 1.0, double g = 1.0, double b = 1.0) - { - this.text = text; - this.r = r; - this.g = g; - this.b = b; - } - - public override void get_preferred_width (out int minimum_width, out int natural_width) - { - minimum_width = natural_width = MINIMUM_WIDTH; - } - - public override void get_preferred_height (out int minimum_height, out int natural_height) - { - minimum_height = natural_height = (int) Math.round (MINIMUM_WIDTH * Math.SQRT2); - } - - public override void get_preferred_height_for_width (int width, out int minimum_height, out int natural_height) - { - minimum_height = natural_height = (int) (width * Math.SQRT2); - } - - public override void get_preferred_width_for_height (int height, out int minimum_width, out int natural_width) - { - minimum_width = natural_width = (int) (height / Math.SQRT2); - } - - public override bool draw (Cairo.Context c) - { - var w = get_allocated_width (); - var h = get_allocated_height (); - if (w * Math.SQRT2 > h) - w = (int) Math.round (h / Math.SQRT2); - else - h = (int) Math.round (w * Math.SQRT2); - - c.translate ((get_allocated_width () - w) / 2, (get_allocated_height () - h) / 2); - - c.rectangle (0.5, 0.5, w - 1, h - 1); - - c.set_source_rgb (r, g, b); - c.fill_preserve (); - - c.set_line_width (1.0); - c.set_source_rgb (0.0, 0.0, 0.0); - c.stroke (); - - Cairo.TextExtents extents; - c.text_extents (text, out extents); - c.translate ((w - extents.width) * 0.5 - 0.5, (h + extents.height) * 0.5 - 0.5); - c.show_text (text); - - return true; - } -} -- cgit v1.2.3