Merge lp:~fboucault/unity-2d/window_buttons_left_aligned_and_fixed_width into lp:unity-2d/3.0

Proposed by Florian Boucault
Status: Merged
Approved by: Aurélien Gâteau
Approved revision: 448
Merged at revision: 448
Proposed branch: lp:~fboucault/unity-2d/window_buttons_left_aligned_and_fixed_width
Merge into: lp:unity-2d/3.0
Diff against target: 19 lines (+2/-1)
1 file modified
panel/applets/appname/appnameapplet.cpp (+2/-1)
To merge this branch: bzr merge lp:~fboucault/unity-2d/window_buttons_left_aligned_and_fixed_width
Reviewer Review Type Date Requested Status
Aurélien Gâteau (community) Approve
Review via email: mp+53155@code.launchpad.net

Description of the change

[panel] Force window buttons to have a fixed width and to be left aligned.

To post a comment you must log in.
Revision history for this message
Florian Boucault (fboucault) wrote :

The bug is easy to reproduce by programmatically removing the m_label and m_menuBarWidget from AppNameApplet.

448. By Florian Boucault

Forgotten change.

Revision history for this message
Aurélien Gâteau (agateau) wrote :

Good catch.

review: Approve

Preview Diff

[H/L] Next/Prev Comment, [J/K] Next/Prev File, [N/P] Next/Prev Hunk
1=== modified file 'panel/applets/appname/appnameapplet.cpp'
2--- panel/applets/appname/appnameapplet.cpp 2011-01-15 01:41:03 +0000
3+++ panel/applets/appname/appnameapplet.cpp 2011-03-13 03:04:11 +0000
4@@ -144,6 +144,7 @@
5 void setupWindowButtonWidget()
6 {
7 m_windowButtonWidget = new QWidget;
8+ m_windowButtonWidget->setSizePolicy(QSizePolicy::Fixed, QSizePolicy::Minimum);
9 QHBoxLayout* layout = new QHBoxLayout(m_windowButtonWidget);
10 layout->setContentsMargins(0, 0, WINDOW_BUTTONS_RIGHT_MARGIN, 0);
11 layout->setSpacing(0);
12@@ -198,7 +199,7 @@
13 QHBoxLayout* layout = new QHBoxLayout(this);
14 layout->setMargin(0);
15 layout->setSpacing(0);
16- layout->addWidget(d->m_windowButtonWidget);
17+ layout->addWidget(d->m_windowButtonWidget, 0, Qt::AlignLeft);
18 layout->addWidget(d->m_label);
19 layout->addWidget(d->m_menuBarWidget);
20

Subscribers

People subscribed via source and target branches