Merge lp:~evfool/software-center/lp927426 into lp:software-center

Proposed by Robert Roth
Status: Merged
Merged at revision: 3012
Proposed branch: lp:~evfool/software-center/lp927426
Merge into: lp:software-center
Diff against target: 242 lines (+75/-15) (has conflicts)
8 files modified
data/ui/gtk3/dialogs.ui (+1/-1)
debian/changelog (+25/-2)
softwarecenter/db/categories.py (+1/-1)
softwarecenter/ui/gtk3/app.py (+11/-4)
softwarecenter/ui/gtk3/models/appstore2.py (+10/-2)
softwarecenter/ui/gtk3/widgets/buttons.py (+1/-0)
softwarecenter/ui/gtk3/widgets/reviews.py (+12/-4)
test/gtk3/test_appstore2.py (+14/-1)
Text conflict in debian/changelog
To merge this branch: bzr merge lp:~evfool/software-center/lp927426
Reviewer Review Type Date Requested Status
software-store-developers Pending
Review via email: mp+106492@code.launchpad.net

Description of the change

Changed the reference to store to Software Center, as requested in bug #927426. The merge proposal is for quantal, as it breaks the strings, so it might not be appropriate for precise.

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 'data/ui/gtk3/dialogs.ui'
2--- data/ui/gtk3/dialogs.ui 2012-03-19 14:23:18 +0000
3+++ data/ui/gtk3/dialogs.ui 2012-05-19 16:24:17 +0000
4@@ -102,7 +102,7 @@
5 <property name="visible">True</property>
6 <property name="can_focus">False</property>
7 <property name="xalign">0</property>
8- <property name="label" translatable="yes">Once Update Manager has finished the repairs, you can close it and return to the store.</property>
9+ <property name="label" translatable="yes">Once Update Manager has finished the repairs, you can close it and return to Software Center.</property>
10 <property name="use_markup">True</property>
11 <property name="wrap">True</property>
12 </object>
13
14=== modified file 'debian/changelog'
15--- debian/changelog 2012-05-15 09:23:50 +0000
16+++ debian/changelog 2012-05-19 16:24:17 +0000
17@@ -1,3 +1,4 @@
18+<<<<<<< TREE
19 BRANCH INSTEAD until "quantal" gets the first upload
20
21 ALSO DO NOT MERGE TRUNK BACK INTO 5.2, ONLY 5.2 INTO TRUNK
22@@ -19,6 +20,25 @@
23 -- Michael Vogt <michael.vogt@ubuntu.com> Fri, 11 May 2012 10:06:18 +0200
24
25 software-center (5.2.2) UNRELEASED; urgency=low
26+=======
27+software-center (5.2.3) UNRELEASED; urgency=low
28+
29+ [ Robert Roth ]
30+ * lp:~evfool/software-center/lp987801:
31+ - Only show the version label once for each version in
32+ reviews (LP: #987801)
33+ * lp:~evfool/software-center/lp874430:
34+ - display tooltips for package titles in the application
35+ tiles of the lobby view (LP: #874430)
36+
37+ [ Michael Vogt ]
38+ * lp:~mvo/software-center/lp872760-for-5.2:
39+ - fix translations for certain category names (LP: #872760)
40+
41+ -- Gary Lasker <gary.lasker@canonical.com> Fri, 18 May 2012 01:32:10 -0400
42+
43+software-center (5.2.2) precise-proposed; urgency=low
44+>>>>>>> MERGE-SOURCE
45
46 [ Michael Vogt ]
47 * lp:~mvo/software-center/whatsnew-leak-lp985389:
48@@ -57,7 +77,10 @@
49 * lp:~gary-lasker/software-center/fix-crash_lp973379:
50 - ensure that the cache is ready before using the recommender
51 service (LP: #973379 )
52-
53+ * lp:~gary-lasker/software-center/toolbar-buttons-insensitive-during-startup:
54+ - set the toolbar buttons insensitive for the duration of time that the
55+ lobby panels are initializing (LP: #999486, LP: #994341)
56+
57 [ Robert Roth ]
58 * lp:~evfool/software-center/bug532072:
59 - escape markup for support info and license (LP: #993279)
60@@ -88,7 +111,7 @@
61 - test code change only! add memory and cpt stats to the
62 test script
63
64- -- Gary Lasker <gary.lasker@canonical.com> Mon, 14 May 2012 22:36:15 -0400
65+ -- Michael Vogt <michael.vogt@ubuntu.com> Tue, 15 May 2012 20:22:02 +0200
66
67 software-center (5.2.1) precise-proposed; urgency=low
68
69
70=== modified file 'softwarecenter/db/categories.py'
71--- softwarecenter/db/categories.py 2012-03-20 10:28:51 +0000
72+++ softwarecenter/db/categories.py 2012-05-19 16:24:17 +0000
73@@ -532,7 +532,7 @@
74 'SportsGame': 'Games;Sports',
75 '3DGraphics': 'Graphics;3D Graphics',
76 'VectorGraphics': 'Graphics;Drawing',
77-'RasterGraphics': 'Graphics;Painting',
78+'RasterGraphics': 'Graphics;Painting & Editing',
79 'Photography': 'Graphics;Photography',
80 'Publishing': 'Graphics;Publishing',
81 'Scanning': 'Graphics;Scanning & OCR',
82
83=== modified file 'softwarecenter/ui/gtk3/app.py'
84--- softwarecenter/ui/gtk3/app.py 2012-05-15 09:23:50 +0000
85+++ softwarecenter/ui/gtk3/app.py 2012-05-19 16:24:17 +0000
86@@ -273,6 +273,10 @@
87 self.vbox1.pack_start(self.global_pane, False, False, 0)
88 self.vbox1.reorder_child(self.global_pane, 1)
89
90+ # start with the toolbar buttons insensitive and don't make them
91+ # sensitive until the panel elements are ready
92+ #self.global_pane.view_switcher.set_sensitive(False)
93+
94 # available pane
95 self.available_pane = AvailablePane(self.cache,
96 self.db,
97@@ -292,8 +296,8 @@
98 self.distro,
99 self.icons,
100 self.datadir)
101- #~ self.installed_pane.connect("installed-pane-created",
102- #~ self.on_installed_pane_created)
103+ self.installed_pane.connect("installed-pane-created",
104+ self.on_installed_pane_created)
105 self.view_manager.register(self.installed_pane,
106 ViewPages.INSTALLED)
107
108@@ -472,9 +476,12 @@
109 "recommendations-opt-out",
110 self._on_recommendations_opt_out)
111 self.menuitem_recommendations.set_sensitive(True)
112+ # set the main toolbar buttons sensitive
113+ self.global_pane.view_switcher.set_sensitive(True)
114
115- #~ def on_installed_pane_created(self, widget):
116- #~ pass
117+ def on_installed_pane_created(self, widget):
118+ # set the main toolbar buttons sensitive
119+ self.global_pane.view_switcher.set_sensitive(True)
120
121 def _on_recommendations_opt_in(self, rec_panel):
122 self._update_recommendations_menuitem(opted_in=True)
123
124=== modified file 'softwarecenter/ui/gtk3/models/appstore2.py'
125--- softwarecenter/ui/gtk3/models/appstore2.py 2012-05-11 13:48:04 +0000
126+++ softwarecenter/ui/gtk3/models/appstore2.py 2012-05-19 16:24:17 +0000
127@@ -34,6 +34,7 @@
128 split_icon_ext,
129 capitalize_first_word,
130 utf8,
131+ unescape,
132 )
133 from softwarecenter.backend import get_install_backend
134 from softwarecenter.backend.reviews import get_review_loader
135@@ -249,8 +250,15 @@
136 for cat in self.all_categories:
137 if cat.untranslated_name == catname:
138 return cat.name
139- # else just use plain gettext
140- return _(catname)
141+ # try normal translation first
142+ translated_catname = _(catname)
143+ if translated_catname == catname:
144+ # if no normal translation is found, try to find a escaped
145+ # translation (LP: #872760)
146+ translated_catname = _(GObject.markup_escape_text(catname))
147+ # the parent expect the string unescaped
148+ translated_catname = unescape(translated_catname)
149+ return translated_catname
150
151 def get_categories(self, doc):
152 categories = doc.get_value(XapianValues.CATEGORIES).split(';') or []
153
154=== modified file 'softwarecenter/ui/gtk3/widgets/buttons.py'
155--- softwarecenter/ui/gtk3/widgets/buttons.py 2012-03-16 16:52:54 +0000
156+++ softwarecenter/ui/gtk3/widgets/buttons.py 2012-05-19 16:24:17 +0000
157@@ -201,6 +201,7 @@
158 GObject.markup_escape_text(label))
159 self.title.set_alignment(0.0, 0.5)
160 self.title.set_use_markup(True)
161+ self.title.set_tooltip_text(label)
162 self.title.set_ellipsize(Pango.EllipsizeMode.END)
163 self.content_right.pack_start(self.title, False, False, 0)
164
165
166=== modified file 'softwarecenter/ui/gtk3/widgets/reviews.py'
167--- softwarecenter/ui/gtk3/widgets/reviews.py 2012-05-15 08:37:41 +0000
168+++ softwarecenter/ui/gtk3/widgets/reviews.py 2012-05-19 16:24:17 +0000
169@@ -194,11 +194,18 @@
170 UI vbox out of them
171 """
172 self.logged_in_person = get_person_from_config()
173+ is_first_for_version = None
174 if self.reviews:
175+ previous_review = None
176 for r in self.reviews:
177 pkgversion = self._parent.app_details.version
178+ if previous_review:
179+ is_first_for_version = previous_review.version != r.version
180+ else:
181+ is_first_for_version = True
182+ previous_review = r
183 review = UIReview(r, pkgversion, self.logged_in_person,
184- self.useful_votes)
185+ self.useful_votes, is_first_for_version)
186 review.show_all()
187 self.vbox.pack_start(review, True, True, 0)
188
189@@ -399,7 +406,8 @@
190 useful/inappropriate etc
191 """
192 def __init__(self, review_data=None, app_version=None,
193- logged_in_person=None, useful_votes=None):
194+ logged_in_person=None, useful_votes=None,
195+ first_for_version=True):
196 GObject.GObject.__init__(self)
197 self.set_spacing(StockEms.SMALL)
198
199@@ -439,8 +447,8 @@
200 self.usefulness_error = False
201 self.delete_error = False
202 self.modify_error = False
203-
204- self.pack_start(self.version_label, False, False, 0)
205+ if first_for_version:
206+ self.pack_start(self.version_label, False, False, 0)
207 self.pack_start(self.header, False, False, 0)
208 self.pack_start(self.body, False, False, 0)
209 self.pack_start(self.footer, False, False, StockEms.SMALL)
210
211=== modified file 'test/gtk3/test_appstore2.py'
212--- test/gtk3/test_appstore2.py 2012-01-16 14:42:49 +0000
213+++ test/gtk3/test_appstore2.py 2012-05-19 16:24:17 +0000
214@@ -4,7 +4,7 @@
215 import xapian
216
217 from gi.repository import Gtk
218-
219+from mock import patch
220
221 from testutils import setup_test_env
222 setup_test_env()
223@@ -24,6 +24,19 @@
224 self.icons = get_test_gtk3_icon_cache()
225 self.db = get_test_db()
226
227+ def test_lp872760(self):
228+ def monkey_(s):
229+ translations = {
230+ "Painting &amp; Editing" : "translation for Painting &amp; "
231+ "Editing",
232+ }
233+ return translations.get(s, s)
234+ with patch("softwarecenter.ui.gtk3.models.appstore2._", new=monkey_):
235+ model = AppListStore(self.db, self.cache, self.icons)
236+ untranslated = "Painting & Editing"
237+ translated = model._category_translate(untranslated)
238+ self.assertNotEqual(untranslated, translated)
239+
240 def test_app_store(self):
241 # get a enquire object
242 enquirer = AppEnquire(self.cache, self.db)