From dd31fec6f73a5aa77ae31fd055d8d752dfee3182 Mon Sep 17 00:00:00 2001 From: "coadde [Márcio Alexandre Silva Delgado]" Date: Tue, 3 Feb 2015 20:58:05 -0200 Subject: update mcomix --- libre/mcomix/PKGBUILD | 14 +--- libre/mcomix/libre.patch | 202 ++++++++++++++++++++--------------------------- libre/mcomix/zoom.patch | 17 ---- 3 files changed, 90 insertions(+), 143 deletions(-) delete mode 100644 libre/mcomix/zoom.patch (limited to 'libre') diff --git a/libre/mcomix/PKGBUILD b/libre/mcomix/PKGBUILD index b6dd55def..27ce9f419 100644 --- a/libre/mcomix/PKGBUILD +++ b/libre/mcomix/PKGBUILD @@ -4,8 +4,8 @@ # Maintainer: André Silva pkgname=mcomix -pkgver=1.00 -pkgrel=6.parabola2 +pkgver=1.01 +pkgrel=1.parabola1 pkgdesc="A user-friendly, customizable image viewer specifically designed to handle comic books, without nonfree unrar support" arch=('any') url="http://sourceforge.net/projects/mcomix/" @@ -17,7 +17,6 @@ conflicts=('comix' 'mcomix-libre') replaces=('comix' 'mcomix-libre') install='mcomix.install' source=("http://downloads.sourceforge.net/project/mcomix/MComix-${pkgver}/mcomix-${pkgver}.tar.bz2" - 'zoom.patch' 'libre.patch') prepare() { @@ -40,10 +39,6 @@ build() { do sed -i 's_#!/usr/bin/env python_#!/usr/bin/env python2_' $file done - - # Fix zoom in, zoom out keyboard shortcuts: - # https://sourceforge.net/p/mcomix/bugs/62/ - patch -Np1 < ${srcdir}/zoom.patch } package() { @@ -60,6 +55,5 @@ package() { install -Dm644 mime/comicbook.schemas ${pkgdir}/usr/share/gconf/schemas/mcomix.schemas } -md5sums=('3a916dd9da17043ab59ccd17e26eb932' - 'c80705bf6f132bfba20dcb84b79c9cb7' - 'cbb3730d3bed153b88208163e83d60e2') +md5sums=('c2837c3baf226798246db834d22d1de8' + '6ba9f4c88c18440a48bb84a03940d4a7') diff --git a/libre/mcomix/libre.patch b/libre/mcomix/libre.patch index e3f12f703..916f46e6c 100644 --- a/libre/mcomix/libre.patch +++ b/libre/mcomix/libre.patch @@ -1,8 +1,7 @@ -diff --git a/mcomix/about_dialog.py b/mcomix/about_dialog.py -index 9f956d5..10ff0be 100644 ---- a/mcomix/about_dialog.py -+++ b/mcomix/about_dialog.py -@@ -27,7 +27,7 @@ class _AboutDialog(gtk.AboutDialog): +diff -Nur a/mcomix/about_dialog.py b/mcomix/about_dialog.py +--- a/mcomix/about_dialog.py 2014-07-20 14:41:41.000000000 -0300 ++++ b/mcomix/about_dialog.py 2015-02-03 20:06:18.707598152 -0200 +@@ -27,7 +27,7 @@ comment = \ _('%s is an image viewer specifically designed to handle comic books.') % \ constants.APPNAME + u' ' + \ @@ -11,34 +10,18 @@ index 9f956d5..10ff0be 100644 self.set_comments(comment) license = \ -diff --git a/mcomix/archive_extractor.py b/mcomix/archive_extractor.py -index afed5c7..bc969bf 100644 ---- a/mcomix/archive_extractor.py -+++ b/mcomix/archive_extractor.py -@@ -12,8 +12,8 @@ class Extractor: - - """Extractor is a threaded class for extracting different archive formats. - -- The Extractor can be loaded with paths to archives (currently ZIP, tar, -- or RAR archives) and a path to a destination directory. Once an archive -+ The Extractor can be loaded with paths to archives (currently ZIP or tar -+ archives) and a path to a destination directory. Once an archive - has been set it is possible to filter out the files to be extracted and - set the order in which they should be extracted. The extraction can - then be started in a new thread in which files are extracted one by one, -diff --git a/mcomix/archive_tools.py b/mcomix/archive_tools.py -index 66c3f14..151a904 100644 ---- a/mcomix/archive_tools.py -+++ b/mcomix/archive_tools.py -@@ -8,7 +8,6 @@ import tarfile - from mcomix import constants +diff -Nur a/mcomix/archive_tools.py b/mcomix/archive_tools.py +--- a/mcomix/archive_tools.py 2014-07-28 11:32:51.000000000 -0300 ++++ b/mcomix/archive_tools.py 2015-02-03 20:10:46.137856205 -0200 +@@ -11,7 +11,6 @@ from mcomix import log from mcomix.archive import zip + from mcomix.archive import zip_external -from mcomix.archive import rar from mcomix.archive import tar from mcomix.archive import sevenzip from mcomix.archive import lha -@@ -16,9 +15,6 @@ from mcomix.archive import lha +@@ -20,9 +19,6 @@ def szip_available(): return sevenzip.SevenZipArchive.is_available() @@ -48,7 +31,7 @@ index 66c3f14..151a904 100644 def lha_available(): return lha.LhaArchive.is_available() or szip_available() -@@ -31,9 +27,6 @@ def get_supported_archive_regex(): +@@ -35,9 +31,6 @@ if szip_available(): formats.extend(constants.SZIP_FORMATS[1]) @@ -58,44 +41,43 @@ index 66c3f14..151a904 100644 if lha_available(): formats.extend(constants.LHA_FORMATS[1]) -@@ -71,10 +64,7 @@ def archive_mime_type(path): +@@ -81,10 +74,7 @@ else: return constants.TAR -- if magic == 'Rar!': +- if magic[0:4] == 'Rar!': - return constants.RAR - -- elif magic == '7z\xBC\xAF': -+ if magic == '7z\xBC\xAF': +- elif magic[0:4] == '7z\xBC\xAF': ++ if magic[0:4] == '7z\xBC\xAF': return constants.SEVENZIP - elif magic[2:] == '-l': -@@ -124,11 +114,6 @@ def get_archive_handler(path): - return zip.ZipArchive(path) - elif mime in (constants.TAR, constants.GZIP, constants.BZIP2): + # Headers for TAR-XZ and TAR-LZMA that aren't supported by tarfile +@@ -143,11 +133,6 @@ + return sevenzip.SevenZipArchive(path) + elif type in (constants.TAR, constants.GZIP, constants.BZIP2): return tar.TarArchive(path) -- elif mime == constants.RAR and rar.RarArchive.is_available(): +- elif type == constants.RAR and rar.RarArchive.is_available(): - return rar.RarArchive(path) -- elif mime == constants.RAR and sevenzip.SevenZipArchive.is_available(): +- elif type == constants.RAR and sevenzip.SevenZipArchive.is_available(): - log.info('Using Sevenzip for RAR archives.') - return sevenzip.SevenZipArchive(path) - elif mime == constants.SEVENZIP and sevenzip.SevenZipArchive.is_available(): + elif type == constants.SEVENZIP and sevenzip.SevenZipArchive.is_available(): return sevenzip.SevenZipArchive(path) - elif mime == constants.LHA and lha.LhaArchive.is_available(): -diff --git a/mcomix/constants.py b/mcomix/constants.py -index fad3b78..3c225c5 100644 ---- a/mcomix/constants.py -+++ b/mcomix/constants.py -@@ -28,7 +28,7 @@ FILEINFO_PICKLE_PATH = os.path.join(DATA_DIR, 'file.pickle') - PREFERENCE_PICKLE_PATH = os.path.join(CONFIG_DIR, 'preferences.pickle') + elif type == constants.LHA and lha.LhaArchive.is_available(): +diff -Nur a/mcomix/constants.py b/mcomix/constants.py +--- a/mcomix/constants.py 2015-01-31 06:06:26.000000000 -0200 ++++ b/mcomix/constants.py 2015-02-03 20:11:54.983850230 -0200 +@@ -41,7 +41,7 @@ + LAST_INDEX = -1 + UNION_INDEX = -2 - ZOOM_MODE_BEST, ZOOM_MODE_WIDTH, ZOOM_MODE_HEIGHT, ZOOM_MODE_MANUAL, ZOOM_MODE_SIZE = range(5) --ZIP, RAR, TAR, GZIP, BZIP2, PDF, SEVENZIP, LHA = range(8) -+ZIP, TAR, GZIP, BZIP2, PDF, SEVENZIP, LHA = range(7) +-ZIP, RAR, TAR, GZIP, BZIP2, PDF, SEVENZIP, LHA, ZIP_EXTERNAL = range(9) ++ZIP, TAR, GZIP, BZIP2, PDF, SEVENZIP, LHA, ZIP_EXTERNAL = range(8) NORMAL_CURSOR, GRAB_CURSOR, WAIT_CURSOR, NO_CURSOR = range(4) LIBRARY_DRAG_EXTERNAL_ID, LIBRARY_DRAG_BOOK_ID, LIBRARY_DRAG_COLLECTION_ID = range(3) AUTOROTATE_NEVER, AUTOROTATE_WIDTH_90, AUTOROTATE_WIDTH_270, \ -@@ -57,9 +57,6 @@ SUPPORTED_IMAGE_REGEX = re.compile(r'\.(jpg|jpeg|png|gif|tif|tiff|bmp|ppm|pgm|pb +@@ -70,9 +70,6 @@ ZIP_FORMATS = ( ('application/x-zip', 'application/zip', 'application/x-zip-compressed', 'application/x-cbz'), ('*.zip', '*.cbz')) @@ -105,11 +87,10 @@ index fad3b78..3c225c5 100644 TAR_FORMATS = ( ('application/x-tar', 'application/x-gzip', 'application/x-bzip2', 'application/x-cbt'), ('*.tar', '*.gz', '*.bz2', '*.bzip2', '*.cbt')) -diff --git a/mcomix/file_chooser_base_dialog.py b/mcomix/file_chooser_base_dialog.py -index 4d2a34e..c518842 100644 ---- a/mcomix/file_chooser_base_dialog.py -+++ b/mcomix/file_chooser_base_dialog.py -@@ -88,9 +88,6 @@ class _BaseFileChooserDialog(gtk.Dialog): +diff -Nur a/mcomix/file_chooser_base_dialog.py b/mcomix/file_chooser_base_dialog.py +--- a/mcomix/file_chooser_base_dialog.py 2014-01-18 06:01:42.000000000 -0200 ++++ b/mcomix/file_chooser_base_dialog.py 2015-02-03 20:13:45.971467307 -0200 +@@ -88,9 +88,6 @@ # extractor availability. mimetypes = constants.ZIP_FORMATS[0] + constants.TAR_FORMATS[0] patterns = constants.ZIP_FORMATS[1] + constants.TAR_FORMATS[1] @@ -119,7 +100,7 @@ index 4d2a34e..c518842 100644 if archive_tools.szip_available(): mimetypes += constants.SZIP_FORMATS[0] patterns += constants.SZIP_FORMATS[1] -@@ -107,10 +104,6 @@ class _BaseFileChooserDialog(gtk.Dialog): +@@ -107,10 +104,6 @@ self.add_filter(_('Tar archives'), *constants.TAR_FORMATS) @@ -130,11 +111,10 @@ index 4d2a34e..c518842 100644 if archive_tools.szip_available(): self.add_filter(_('7z archives'), *constants.SZIP_FORMATS) -diff --git a/mcomix/messages/mcomix.pot b/mcomix/messages/mcomix.pot -index 54ece85..482c051 100644 ---- a/mcomix/messages/mcomix.pot -+++ b/mcomix/messages/mcomix.pot -@@ -24,7 +24,7 @@ msgid "%s is an image viewer specifically designed to handle comic books." +diff -Nur a/mcomix/messages/mcomix.pot b/mcomix/messages/mcomix.pot +--- a/mcomix/messages/mcomix.pot 2015-01-31 05:55:44.000000000 -0200 ++++ b/mcomix/messages/mcomix.pot 2015-02-03 20:32:26.271598749 -0200 +@@ -24,7 +24,7 @@ msgstr "" #: mcomix/about_dialog.py:30 @@ -143,7 +123,7 @@ index 54ece85..482c051 100644 msgstr "" #: mcomix/about_dialog.py:34 -@@ -241,10 +241,6 @@ msgstr "" +@@ -242,10 +242,6 @@ msgid "Tar archives" msgstr "" @@ -154,7 +134,7 @@ index 54ece85..482c051 100644 #: mcomix/file_chooser_base_dialog.py:115 msgid "7z archives" msgstr "" -@@ -1345,10 +1341,6 @@ msgstr "" +@@ -1568,10 +1564,6 @@ msgid "Bzip2 compressed tar archive" msgstr "" @@ -165,11 +145,10 @@ index 54ece85..482c051 100644 #: mcomix/strings.py:14 msgid "7z archive" msgstr "" -diff --git a/mcomix/process.py b/mcomix/process.py -index 4ba60c6..c37699d 100644 ---- a/mcomix/process.py -+++ b/mcomix/process.py -@@ -10,10 +10,7 @@ from mcomix import i18n +diff -Nur a/mcomix/process.py b/mcomix/process.py +--- a/mcomix/process.py 2014-07-25 13:37:00.000000000 -0300 ++++ b/mcomix/process.py 2015-02-03 20:16:10.747046736 -0200 +@@ -20,10 +20,7 @@ class Process: """The subprocess and popen2 modules in Python are broken (see issue @@ -181,11 +160,10 @@ index 4ba60c6..c37699d 100644 """ # TODO: I can no longer reproduce the issue. Check if this version of # process.py still solves it. -diff --git a/mcomix/recent.py b/mcomix/recent.py -index 3d4613d..3f5c511 100644 ---- a/mcomix/recent.py -+++ b/mcomix/recent.py -@@ -30,8 +30,7 @@ class RecentFilesMenu(gtk.RecentChooserMenu): +diff -Nur a/mcomix/recent.py b/mcomix/recent.py +--- a/mcomix/recent.py 2014-06-09 03:08:26.000000000 -0300 ++++ b/mcomix/recent.py 2015-02-03 20:17:14.779514387 -0200 +@@ -31,8 +31,7 @@ rfilter.add_pixbuf_formats() mimetypes, patterns = itertools.izip(constants.ZIP_FORMATS, @@ -195,10 +173,9 @@ index 3d4613d..3f5c511 100644 for mimetype in itertools.chain.from_iterable(mimetypes): rfilter.add_mime_type(mimetype) -diff --git a/mcomix/strings.py b/mcomix/strings.py -index c5ca21f..cc69236 100644 ---- a/mcomix/strings.py -+++ b/mcomix/strings.py +diff -Nur a/mcomix/strings.py b/mcomix/strings.py +--- a/mcomix/strings.py 2014-01-18 06:01:42.000000000 -0200 ++++ b/mcomix/strings.py 2015-02-03 20:18:10.421674128 -0200 @@ -3,14 +3,13 @@ This file should only be imported after gettext has been correctly initialized and installed in the global namespace. """ @@ -215,20 +192,19 @@ index c5ca21f..cc69236 100644 SEVENZIP: _('7z archive'), LHA: _('LHA archive') } -diff --git a/mcomix.egg-info/SOURCES.txt b/mcomix.egg-info/SOURCES.txt -index 62de3ad..85a65df 100644 ---- a/mcomix.egg-info/SOURCES.txt -+++ b/mcomix.egg-info/SOURCES.txt -@@ -77,8 +77,6 @@ mcomix.egg-info/top_level.txt - mcomix/archive/__init__.py - mcomix/archive/archive_base.py +diff -Nur a/mcomix.egg-info/SOURCES.txt b/mcomix.egg-info/SOURCES.txt +--- a/mcomix.egg-info/SOURCES.txt 2015-01-31 06:08:19.000000000 -0200 ++++ b/mcomix.egg-info/SOURCES.txt 2015-02-03 20:19:25.537920559 -0200 +@@ -84,8 +84,6 @@ + mcomix/archive/archive_recursive.py mcomix/archive/lha.py + mcomix/archive/pdf.py -mcomix/archive/rar.py -mcomix/archive/rarfile.py mcomix/archive/sevenzip.py mcomix/archive/tar.py mcomix/archive/zip.py -@@ -183,18 +181,13 @@ mime/comicthumb.1.gz +@@ -184,18 +182,13 @@ mime/mcomix.desktop mime/mcomix.thumbnailer mime/mcomix.xml @@ -249,10 +225,9 @@ index 62de3ad..85a65df 100644 -mime/icons/48x48/application-x-cbz.png \ No newline at end of file +mime/icons/48x48/application-x-cbz.png -diff --git a/mime/comicbook.schemas b/mime/comicbook.schemas -index cdc4a4a..21b6214 100644 ---- a/mime/comicbook.schemas -+++ b/mime/comicbook.schemas +diff -Nur a/mime/comicbook.schemas b/mime/comicbook.schemas +--- a/mime/comicbook.schemas 2013-01-08 14:26:46.000000000 -0200 ++++ b/mime/comicbook.schemas 2015-02-03 20:20:10.809688373 -0200 @@ -1,28 +1,6 @@ @@ -282,11 +257,10 @@ index cdc4a4a..21b6214 100644 /schemas/desktop/gnome/thumbnailers/application@x-cbz/enable /desktop/gnome/thumbnailers/application@x-cbz/enable comicthumb -diff --git a/mime/comicthumb b/mime/comicthumb -index 5728e2a..d77a4a1 100755 ---- a/mime/comicthumb -+++ b/mime/comicthumb -@@ -7,7 +7,7 @@ comicthumb is dependent on the Python Imaging Library (PIL). +diff -Nur a/mime/comicthumb b/mime/comicthumb +--- a/mime/comicthumb 2013-01-13 14:35:00.000000000 -0200 ++++ b/mime/comicthumb 2015-02-03 20:22:30.481808283 -0200 +@@ -7,7 +7,7 @@ comicthumb was originally written by Christoph Wolk, this version was re-written from scratch for Comix 4 by Pontus Ekberg. @@ -295,7 +269,7 @@ index 5728e2a..d77a4a1 100755 Usage: comicthumb INFILE OUTFILE [SIZE] """ -@@ -28,16 +28,13 @@ except ImportError: +@@ -28,16 +28,13 @@ print __doc__ sys.exit(1) @@ -314,7 +288,7 @@ index 5728e2a..d77a4a1 100755 """ # TODO: I can no longer reproduce the issue. Check if this version of # process.py still solves it. -@@ -94,19 +91,6 @@ class Extractor: +@@ -94,19 +91,6 @@ elif self._type in [TAR, GZIP, BZIP2]: self._tfile = tarfile.open(src, 'r') self._files = self._tfile.getnames() @@ -334,7 +308,7 @@ index 5728e2a..d77a4a1 100755 def get_files(self): """Return a list of the files in the archive.""" -@@ -121,11 +105,6 @@ class Extractor: +@@ -121,11 +105,6 @@ return cStringIO.StringIO(self._zfile.read(chosen)) elif self._type in [TAR, GZIP, BZIP2]: return cStringIO.StringIO(self._tfile.extractfile(chosen).read()) @@ -346,7 +320,7 @@ index 5728e2a..d77a4a1 100755 def archive_mime_type(path): -@@ -145,8 +124,6 @@ def archive_mime_type(path): +@@ -145,8 +124,6 @@ if magic.startswith('\037\213'): return GZIP return TAR @@ -355,30 +329,27 @@ index 5728e2a..d77a4a1 100755 except Exception: print '! Error while reading', path return None -diff --git a/mime/mcomix.desktop b/mime/mcomix.desktop -index ee6d8b9..19ec7cd 100644 ---- a/mime/mcomix.desktop -+++ b/mime/mcomix.desktop -@@ -19,4 +19,4 @@ Terminal=false +diff -Nur a/mime/mcomix.desktop b/mime/mcomix.desktop +--- a/mime/mcomix.desktop 2013-01-08 14:26:46.000000000 -0200 ++++ b/mime/mcomix.desktop 2015-02-03 20:24:12.805803236 -0200 +@@ -19,4 +19,4 @@ Type=Application StartupNotify=true Categories=Graphics;Viewer; -MimeType=application/x-cbz;application/x-cbr;application/x-cbt;image/jpeg;image/png;image/gif;image/tiff;image/bmp;image/x-icon;image/x-xpixmap;image/x-xbitmap;application/x-zip;application/zip;application/x-rar;application/x-tar;application/x-gzip;application/x-bzip2;image/svg+xml;image/svg;image/svg-xml;image/vnd.adobe.svg+xml;text/xml-svg;image/x-portable-anymap;image/x-portable-bitmap;image/x-portable-graymap;image/x-portable-pixmap;image/x-pcx;image/x-cmu-raster;image/x-sun-raster;image/x-tga;application/x-7z-compressed;application/x-cb7;application/x-lzh;application/x-lha;application/x-lzh-compressed; +MimeType=application/x-cbz;application/x-cbt;image/jpeg;image/png;image/gif;image/tiff;image/bmp;image/x-icon;image/x-xpixmap;image/x-xbitmap;application/x-zip;application/zip;application/x-tar;application/x-gzip;application/x-bzip2;image/svg+xml;image/svg;image/svg-xml;image/vnd.adobe.svg+xml;text/xml-svg;image/x-portable-anymap;image/x-portable-bitmap;image/x-portable-graymap;image/x-portable-pixmap;image/x-pcx;image/x-cmu-raster;image/x-sun-raster;image/x-tga;application/x-7z-compressed;application/x-cb7;application/x-lzh;application/x-lha;application/x-lzh-compressed; -diff --git a/mime/mcomix.thumbnailer b/mime/mcomix.thumbnailer -index 4dcfc67..667dc8b 100644 ---- a/mime/mcomix.thumbnailer -+++ b/mime/mcomix.thumbnailer +diff -Nur a/mime/mcomix.thumbnailer b/mime/mcomix.thumbnailer +--- a/mime/mcomix.thumbnailer 2014-01-18 06:01:42.000000000 -0200 ++++ b/mime/mcomix.thumbnailer 2015-02-03 20:27:12.596127651 -0200 @@ -1,4 +1,4 @@ [Thumbnailer Entry] TryExec=comicthumb Exec=comicthumb %u %o %s -MimeType=application/x-cbr;application/x-cbz;application/x-cbt; +MimeType=application/x-cbz;application/x-cbt; -diff --git a/mime/mcomix.xml b/mime/mcomix.xml -index 765c254..b13e2da 100644 ---- a/mime/mcomix.xml -+++ b/mime/mcomix.xml +diff -Nur a/mime/mcomix.xml b/mime/mcomix.xml +--- a/mime/mcomix.xml 2013-01-08 14:26:46.000000000 -0200 ++++ b/mime/mcomix.xml 2015-02-03 20:27:36.940405337 -0200 @@ -5,11 +5,6 @@ Comic Book Archive (Zip compressed) @@ -391,11 +362,10 @@ index 765c254..b13e2da 100644 -diff --git a/setup.py b/setup.py -index 9eb7782..9979111 100755 ---- a/setup.py -+++ b/setup.py -@@ -78,23 +78,18 @@ setuptools.setup( +diff -Nur a/setup.py b/setup.py +--- a/setup.py 2014-06-09 03:08:26.000000000 -0300 ++++ b/setup.py 2015-02-03 20:28:30.005795579 -0200 +@@ -79,23 +79,18 @@ ('share/icons/hicolor/48x48/apps', ['mcomix/images/48x48/mcomix.png']), ('share/icons/hicolor/16x16/mimetypes', ['mime/icons/16x16/application-x-cbz.png', diff --git a/libre/mcomix/zoom.patch b/libre/mcomix/zoom.patch deleted file mode 100644 index 26dc3ba6f..000000000 --- a/libre/mcomix/zoom.patch +++ /dev/null @@ -1,17 +0,0 @@ -diff --git a/mcomix-1.00/mcomix/event.py b/mcomix-1.00-mod/mcomix/event.py -index bc8cf79..bf80ec2 100644 ---- a/mcomix/event.py -+++ b/mcomix/event.py -@@ -117,8 +117,11 @@ class EventHandler: - - # Zooming commands for manual zoom mode - manager.register('zoom in', -- ['equal'], -+ ['plus', 'KP_Add', 'equal'], - self._window.actiongroup.get_action('zoom_in').activate) -+ manager.register('zoom out', -+ ['minus', 'KP_Subtract'], -+ self._window.actiongroup.get_action('zoom_out').activate) - # Zoom out is already defined as GTK menu hotkey - manager.register('zoom original', - ['KP_0'], -- cgit v1.2.3