Merge lp:~mvo/software-center/reoder-lobby-screen into lp:software-center

Proposed by Michael Vogt
Status: Merged
Merged at revision: 3116
Proposed branch: lp:~mvo/software-center/reoder-lobby-screen
Merge into: lp:software-center
Diff against target: 59 lines (+11/-19)
1 file modified
softwarecenter/ui/gtk3/views/catview_gtk.py (+11/-19)
To merge this branch: bzr merge lp:~mvo/software-center/reoder-lobby-screen
Reviewer Review Type Date Requested Status
Łukasz Czyżykowski (community) Approve
software-store-developers Pending
Review via email: mp+120709@code.launchpad.net

Description of the change

This branch reoders the lobby screen according to the spec at https://wiki.ubuntu.com/SoftwareCenter#Home_screen

To post a comment you must log in.
Revision history for this message
Łukasz Czyżykowski (lukasz-czyzykowski) wrote :

LGTM

review: Approve

Preview Diff

[H/L] Next/Prev Comment, [J/K] Next/Prev File, [N/P] Next/Prev Hunk
1=== modified file 'softwarecenter/ui/gtk3/views/catview_gtk.py'
2--- softwarecenter/ui/gtk3/views/catview_gtk.py 2012-08-17 08:13:20 +0000
3+++ softwarecenter/ui/gtk3/views/catview_gtk.py 2012-08-22 06:19:27 +0000
4@@ -267,6 +267,12 @@
5
6 self.right_column = Gtk.Box.new(Gtk.Orientation.VERTICAL, self.SPACING)
7 self.top_hbox.pack_start(self.right_column, True, True, 0)
8+ self.bottom_hbox = Gtk.HBox(spacing=StockEms.SMALL)
9+ bottom_hbox_alignment = Gtk.Alignment()
10+ bottom_hbox_alignment.set_padding(0, 0, StockEms.MEDIUM - 2,
11+ StockEms.MEDIUM - 2)
12+ bottom_hbox_alignment.add(self.bottom_hbox)
13+ self.vbox.pack_start(bottom_hbox_alignment, False, False, 0)
14
15 self._append_whats_new()
16 self._append_top_rated()
17@@ -366,7 +372,7 @@
18 self.top_rated_frame = FramedHeaderBox()
19 self.top_rated_frame.set_header_label(_("Top Rated"))
20 self.top_rated_frame.add(self.top_rated)
21- self.right_column.pack_start(self.top_rated_frame, True, True, 0)
22+ self.bottom_hbox.pack_start(self.top_rated_frame, True, True, 0)
23 top_rated_cat = self._update_top_rated_content()
24 # only display the 'More' LinkButton if we have top_rated content
25 if top_rated_cat is not None:
26@@ -404,29 +410,15 @@
27 def _update_recommended_for_you_content(self):
28 if (self.recommended_for_you_panel and
29 self.recommended_for_you_panel.get_parent()):
30- self.bottom_hbox.remove(self.recommended_for_you_panel)
31+ self.right_column.remove(self.recommended_for_you_panel)
32 self.recommended_for_you_panel = RecommendationsPanelLobby(self)
33- self.bottom_hbox.pack_start(self.recommended_for_you_panel,
34+ self.right_column.pack_start(self.recommended_for_you_panel,
35 True, True, 0)
36
37 def _append_recommended_for_you(self):
38- # TODO: This space will initially contain an opt-in screen, and this
39- # will update to the tile view of recommended apps when ready
40- # see https://wiki.ubuntu.com/SoftwareCenter#Home_screen
41- self.bottom_hbox = Gtk.HBox(spacing=StockEms.SMALL)
42- bottom_hbox_alignment = Gtk.Alignment()
43- bottom_hbox_alignment.set_padding(0, 0, StockEms.MEDIUM - 2,
44- StockEms.MEDIUM - 2)
45- bottom_hbox_alignment.add(self.bottom_hbox)
46- self.vbox.pack_start(bottom_hbox_alignment, False, False, 0)
47-
48- # TODO: During development, place the "Recommended For You" panel
49- # at the bottom, but swap this with the Top Rated panel once
50- # the recommended for you pieces are done and deployed
51- # see https://wiki.ubuntu.com/SoftwareCenter#Home_screen
52 self.recommended_for_you_panel = RecommendationsPanelLobby(self)
53- self.bottom_hbox.pack_start(self.recommended_for_you_panel,
54- True, True, 0)
55+ self.right_column.pack_start(
56+ self.recommended_for_you_panel, True, True, 0)
57
58 def _update_appcount(self):
59 enq = AppEnquire(self.cache, self.db)

Subscribers

People subscribed via source and target branches