Merge lp:~mvo/deb-thumbnailer/mvo into lp:deb-thumbnailer

Proposed by Michael Vogt
Status: Merged
Merged at revision: 67
Proposed branch: lp:~mvo/deb-thumbnailer/mvo
Merge into: lp:deb-thumbnailer
Diff against target: 28 lines (+9/-2)
1 file modified
deb-thumbnailer (+9/-2)
To merge this branch: bzr merge lp:~mvo/deb-thumbnailer/mvo
Reviewer Review Type Date Requested Status
Deb Thumbnailer Team Pending
Review via email: mp+83779@code.launchpad.net

Description of the change

Thanks for your quick merge!

I found one more tiny bug that is fixed in this merge proposal.

Cheers,
 Michael

To post a comment you must log in.

Preview Diff

[H/L] Next/Prev Comment, [J/K] Next/Prev File, [N/P] Next/Prev Hunk
1=== modified file 'deb-thumbnailer'
2--- deb-thumbnailer 2011-11-29 11:39:44 +0000
3+++ deb-thumbnailer 2011-11-29 13:10:30 +0000
4@@ -243,6 +243,7 @@
5 proceed = False
6 # nautilus calls it with input, output, size
7 if len(sys.argv) == 4:
8+ #print sys.argv
9 try:
10 size = int(sys.argv[3])
11 except ValueError:
12@@ -253,8 +254,14 @@
13 output = urllib.url2pathname(sys.argv[2]).replace('file://', '')
14 thumbnailer = DebThumbnailer(input)
15 thumbnailer.create_overlay_icon_for_deb(output, size)
16- thumbnailer.cache_icon(output)
17- sys.exit(0)
18+ # output is always there, looks like nautilus is creating it, so
19+ # we need to check if the data makes sense
20+ # FIXME: do this in a more elegant way
21+ if os.path.exists(output) and os.path.getsize(output) > 0:
22+ thumbnailer.cache_icon(output)
23+ sys.exit(0)
24+ # tell nautilus we have no data
25+ sys.exit(1)
26 # options?
27 elif len(sys.argv) > 1 and sys.argv[1] == '--recreate':
28 rm_thumbnails()

Subscribers

People subscribed via source and target branches