mirror of
https://github.com/arsenetar/dupeguru.git
synced 2024-11-17 12:39:02 +00:00
pe qt: adjusted to the new dg structure, and set v1.7.3
--HG-- extra : convert_revision : svn%3Ac306627e-7827-47d3-bdf0-9a457c9553a1/trunk%4024
This commit is contained in:
parent
2498517e0e
commit
9c1473b877
23
pe/qt/app.py
23
pe/qt/app.py
@ -10,9 +10,8 @@ import os.path as op
|
|||||||
from PyQt4.QtGui import QImage
|
from PyQt4.QtGui import QImage
|
||||||
import PIL.Image
|
import PIL.Image
|
||||||
|
|
||||||
from hs import fs
|
from hsfs import phys, IT_ATTRS, IT_MD5, IT_EXTRA
|
||||||
from hs.fs import phys
|
from hsutil.str import get_file_ext
|
||||||
from hs.utils.str import get_file_ext
|
|
||||||
|
|
||||||
from dupeguru import data_pe
|
from dupeguru import data_pe
|
||||||
from dupeguru.picture.cache import Cache
|
from dupeguru.picture.cache import Cache
|
||||||
@ -27,24 +26,24 @@ from preferences_dialog import PreferencesDialog
|
|||||||
|
|
||||||
class File(phys.File):
|
class File(phys.File):
|
||||||
cls_info_map = {
|
cls_info_map = {
|
||||||
'size': fs.IT_ATTRS,
|
'size': IT_ATTRS,
|
||||||
'ctime': fs.IT_ATTRS,
|
'ctime': IT_ATTRS,
|
||||||
'mtime': fs.IT_ATTRS,
|
'mtime': IT_ATTRS,
|
||||||
'md5': fs.IT_MD5,
|
'md5': IT_MD5,
|
||||||
'md5partial': fs.IT_MD5,
|
'md5partial': IT_MD5,
|
||||||
'dimensions': fs.IT_EXTRA,
|
'dimensions': IT_EXTRA,
|
||||||
}
|
}
|
||||||
|
|
||||||
def _initialize_info(self, section):
|
def _initialize_info(self, section):
|
||||||
super(File, self)._initialize_info(section)
|
super(File, self)._initialize_info(section)
|
||||||
if section == fs.IT_EXTRA:
|
if section == IT_EXTRA:
|
||||||
self._info.update({
|
self._info.update({
|
||||||
'dimensions': (0,0),
|
'dimensions': (0,0),
|
||||||
})
|
})
|
||||||
|
|
||||||
def _read_info(self, section):
|
def _read_info(self, section):
|
||||||
super(File, self)._read_info(section)
|
super(File, self)._read_info(section)
|
||||||
if section == fs.IT_EXTRA:
|
if section == IT_EXTRA:
|
||||||
im = PIL.Image.open(unicode(self.path))
|
im = PIL.Image.open(unicode(self.path))
|
||||||
self._info['dimensions'] = im.size
|
self._info['dimensions'] = im.size
|
||||||
|
|
||||||
@ -66,7 +65,7 @@ class Directory(phys.Directory):
|
|||||||
class DupeGuru(DupeGuruBase):
|
class DupeGuru(DupeGuruBase):
|
||||||
LOGO_NAME = 'logo_pe'
|
LOGO_NAME = 'logo_pe'
|
||||||
NAME = 'dupeGuru Picture Edition'
|
NAME = 'dupeGuru Picture Edition'
|
||||||
VERSION = '1.7.2'
|
VERSION = '1.7.3'
|
||||||
DELTA_COLUMNS = frozenset([2, 5, 6])
|
DELTA_COLUMNS = frozenset([2, 5, 6])
|
||||||
|
|
||||||
def __init__(self):
|
def __init__(self):
|
||||||
|
@ -9,6 +9,7 @@
|
|||||||
# The release version is outdated. Use at least r672 on http://svn.pyinstaller.org/trunk
|
# The release version is outdated. Use at least r672 on http://svn.pyinstaller.org/trunk
|
||||||
|
|
||||||
import os
|
import os
|
||||||
|
import os.path as op
|
||||||
import shutil
|
import shutil
|
||||||
from app import DupeGuru
|
from app import DupeGuru
|
||||||
|
|
||||||
@ -17,7 +18,9 @@ def print_and_do(cmd):
|
|||||||
os.system(cmd)
|
os.system(cmd)
|
||||||
|
|
||||||
# Removing build and dist
|
# Removing build and dist
|
||||||
|
if op.exists('build'):
|
||||||
shutil.rmtree('build')
|
shutil.rmtree('build')
|
||||||
|
if op.exists('dist'):
|
||||||
shutil.rmtree('dist')
|
shutil.rmtree('dist')
|
||||||
|
|
||||||
version = DupeGuru.VERSION
|
version = DupeGuru.VERSION
|
||||||
|
@ -30,9 +30,9 @@ os.chdir('..')
|
|||||||
|
|
||||||
os.chdir(op.join('modules', 'block'))
|
os.chdir(op.join('modules', 'block'))
|
||||||
os.system('python setup.py build_ext --inplace')
|
os.system('python setup.py build_ext --inplace')
|
||||||
move(op.join('modules', 'block', '_block.so'), op.join('picture', '_block.so'))
|
|
||||||
move(op.join('modules', 'block', '_block.pyd'), op.join('picture', '_block.pyd'))
|
|
||||||
os.chdir(op.join('..', '..'))
|
os.chdir(op.join('..', '..'))
|
||||||
|
move(op.join('modules', 'block', '_block.so'), op.join('.', '_block.so'))
|
||||||
|
move(op.join('modules', 'block', '_block.pyd'), op.join('.', '_block.pyd'))
|
||||||
|
|
||||||
print_and_do("pyuic4 details_dialog.ui > details_dialog_ui.py")
|
print_and_do("pyuic4 details_dialog.ui > details_dialog_ui.py")
|
||||||
print_and_do("pyuic4 preferences_dialog.ui > preferences_dialog_ui.py")
|
print_and_do("pyuic4 preferences_dialog.ui > preferences_dialog_ui.py")
|
||||||
|
Loading…
Reference in New Issue
Block a user