Merge lp:~thad-fisch-deactivatedaccount/mugshot/menu-item-visibility into lp:~mugshot-dev/mugshot/trunk

Proposed by Thaddaeus Tintenfisch
Status: Merged
Merged at revision: 74
Proposed branch: lp:~thad-fisch-deactivatedaccount/mugshot/menu-item-visibility
Merge into: lp:~mugshot-dev/mugshot/trunk
Diff against target: 28 lines (+5/-5)
1 file modified
mugshot/MugshotWindow.py (+5/-5)
To merge this branch: bzr merge lp:~thad-fisch-deactivatedaccount/mugshot/menu-item-visibility
Reviewer Review Type Date Requested Status
Sean Davis Approve
Review via email: mp+208869@code.launchpad.net

Description of the change

Commit does also include a cosmetic change (use faces_dir which is globally defined).

To post a comment you must log in.
Revision history for this message
Sean Davis (bluesabre) wrote :

Wow, silly typo on my part. Merging!

review: Approve

Preview Diff

[H/L] Next/Prev Comment, [J/K] Next/Prev File, [N/P] Next/Prev Hunk
1=== modified file 'mugshot/MugshotWindow.py'
2--- mugshot/MugshotWindow.py 2014-01-26 00:44:26 +0000
3+++ mugshot/MugshotWindow.py 2014-02-28 19:12:03 +0000
4@@ -179,8 +179,8 @@
5 self.image_menu = builder.get_object('image_menu')
6 self.image_menu.attach_to_widget(self.image_button, detach_cb)
7 self.image_from_camera = builder.get_object('image_from_camera')
8- image_from_browse = builder.get_object('image_from_browse')
9- image_from_browse.set_visible(os.path.exists(faces_dir) and
10+ image_from_stock = builder.get_object('image_from_stock')
11+ image_from_stock.set_visible(os.path.exists(faces_dir) and
12 len(os.listdir(faces_dir)) > 0)
13
14 # Entry widgets (chfn)
15@@ -713,10 +713,10 @@
16 logger.debug("Stock browser already loaded.")
17 return
18
19- # If they have not, load each photo from /usr/share/pixmaps/faces.
20+ # If they have not, load each photo from faces_dir.
21 logger.debug("Loading stock browser photos.")
22- for filename in os.listdir('/usr/share/pixmaps/faces'):
23- full_path = os.path.join('/usr/share/pixmaps/faces/', filename)
24+ for filename in os.listdir(faces_dir):
25+ full_path = os.path.join(faces_dir, filename)
26 if os.path.isfile(full_path):
27 pixbuf = GdkPixbuf.Pixbuf.new_from_file(full_path)
28 scaled = pixbuf.scale_simple(90, 90, GdkPixbuf.InterpType.HYPER)

Subscribers

People subscribed via source and target branches

to all changes: