Merge lp:~diegosarmentero/ubuntuone-windows-installer/wizard-sizes into lp:ubuntuone-windows-installer

Proposed by Diego Sarmentero
Status: Merged
Approved by: Natalia Bidart
Approved revision: 53
Merged at revision: 51
Proposed branch: lp:~diegosarmentero/ubuntuone-windows-installer/wizard-sizes
Merge into: lp:ubuntuone-windows-installer
Diff against target: 698 lines (+150/-119)
17 files modified
data/qt/choose_sign_in.ui (+3/-0)
data/qt/congratulations.ui (+3/-0)
data/qt/folders.ui (+3/-0)
data/qt/license.ui (+3/-13)
data/qt/local_folders.ui (+3/-0)
data/qt/preferences.ui (+5/-1)
data/qt/setup_account.ui (+80/-17)
data/qt/side_widget.ui (+5/-38)
data/qt/sign_in.ui (+3/-0)
data/qt/sync_now_or_later.ui (+3/-0)
data/qt/ubuntuone.qss (+0/-1)
ubuntuone_installer/gui/qt/__init__.py (+17/-0)
ubuntuone_installer/gui/qt/gui.py (+7/-6)
ubuntuone_installer/gui/qt/main/windows.py (+2/-1)
ubuntuone_installer/gui/qt/side_widget.py (+4/-8)
ubuntuone_installer/gui/qt/tests/test_gui.py (+3/-3)
ubuntuone_installer/gui/qt/tests/test_side_widget.py (+6/-31)
To merge this branch: bzr merge lp:~diegosarmentero/ubuntuone-windows-installer/wizard-sizes
Reviewer Review Type Date Requested Status
Natalia Bidart (community) Approve
Roberto Alsina (community) Approve
Review via email: mp+73804@code.launchpad.net

Commit message

Fixed Installer Sizes to fit the specs.

Description of the change

Fixed Installer Sizes to fit the specs.

To post a comment you must log in.
Revision history for this message
Roberto Alsina (ralsina) wrote :

+1, ran tests on both platforms, looked at the running program's UI, everything looks good.

review: Approve
46. By Roberto Alsina

Fix import order to make tools happy.

47. By Diego Sarmentero

Improved Are You Sure Dialog to avoid closing the wizard on dialog reject.

Revision history for this message
Natalia Bidart (nataliabidart) wrote :

Has a conflict in ubuntuone_installer/gui/qt/gui.py.

review: Needs Fixing
48. By Diego Sarmentero

merge.
conflict resolved.

Revision history for this message
Diego Sarmentero (diegosarmentero) wrote :

> Has a conflict in ubuntuone_installer/gui/qt/gui.py.

Resolved

Revision history for this message
Natalia Bidart (nataliabidart) wrote :

I'm getting all these failures (confirmed they are not present in trunk):

[FAIL]
Traceback (most recent call last):
  File "/home/nessita/canonical/u1/windows-installer/review_wizard-sizes/ubuntuone_installer/gui/qt/tests/test_gui.py", line 421, in test_continue_cancels_cancel
    self.assertEqual(self.ui.isVisible(), True)
twisted.trial.unittest.FailTest: not equal:
a = False
b = True

ubuntuone_installer.gui.qt.tests.test_gui.MainWindowTestCase.test_continue_cancels_cancel
===============================================================================
[FAIL]
Traceback (most recent call last):
  File "/home/nessita/canonical/u1/windows-installer/review_wizard-sizes/ubuntuone_installer/gui/qt/tests/test_gui.py", line 175, in test_execute_uninstall_on_licence_cancel
    self.assertTrue(self._called)
twisted.trial.unittest.FailTest: None

ubuntuone_installer.gui.qt.tests.test_gui.MainWindowTestCase.test_execute_uninstall_on_licence_cancel
===============================================================================
[FAIL]
Traceback (most recent call last):
  File "/home/nessita/canonical/u1/windows-installer/review_wizard-sizes/ubuntuone_installer/gui/qt/tests/test_gui.py", line 186, in test_execute_uninstall_on_licence_cancel_frozen
    self.assertTrue(self._called)
twisted.trial.unittest.FailTest: None

ubuntuone_installer.gui.qt.tests.test_gui.MainWindowTestCase.test_execute_uninstall_on_licence_cancel_frozen
-------------------------------------------------------------------------------
Ran 125 tests in 1.513s

FAILED (skips=1, failures=3, successes=121)

review: Needs Fixing
49. By Diego Sarmentero

Assigning Bug.

50. By Diego Sarmentero

Fixed issue on starting control panel.

51. By Diego Sarmentero

Fixed tests.

52. By Diego Sarmentero

Removed unnecessary html from license.ui

53. By Diego Sarmentero

Assigning bug.

Revision history for this message
Natalia Bidart (nataliabidart) wrote :

Looks good!

review: Approve

Preview Diff

[H/L] Next/Prev Comment, [J/K] Next/Prev File, [N/P] Next/Prev Hunk
=== modified file 'data/qt/choose_sign_in.ui'
--- data/qt/choose_sign_in.ui 2011-08-05 19:34:29 +0000
+++ data/qt/choose_sign_in.ui 2011-09-07 11:54:54 +0000
@@ -17,6 +17,9 @@
17 <property name="leftMargin">17 <property name="leftMargin">
18 <number>0</number>18 <number>0</number>
19 </property>19 </property>
20 <property name="topMargin">
21 <number>0</number>
22 </property>
20 <property name="rightMargin">23 <property name="rightMargin">
21 <number>0</number>24 <number>0</number>
22 </property>25 </property>
2326
=== modified file 'data/qt/congratulations.ui'
--- data/qt/congratulations.ui 2011-08-29 01:35:26 +0000
+++ data/qt/congratulations.ui 2011-09-07 11:54:54 +0000
@@ -17,6 +17,9 @@
17 <property name="spacing">17 <property name="spacing">
18 <number>24</number>18 <number>24</number>
19 </property>19 </property>
20 <property name="topMargin">
21 <number>0</number>
22 </property>
20 <item>23 <item>
21 <widget class="QLabel" name="label">24 <widget class="QLabel" name="label">
22 <property name="font">25 <property name="font">
2326
=== modified file 'data/qt/folders.ui'
--- data/qt/folders.ui 2011-08-10 21:06:46 +0000
+++ data/qt/folders.ui 2011-09-07 11:54:54 +0000
@@ -14,6 +14,9 @@
14 <string>Form</string>14 <string>Form</string>
15 </property>15 </property>
16 <layout class="QVBoxLayout" name="verticalLayout">16 <layout class="QVBoxLayout" name="verticalLayout">
17 <property name="topMargin">
18 <number>0</number>
19 </property>
17 <item>20 <item>
18 <layout class="QHBoxLayout" name="horizontalLayout">21 <layout class="QHBoxLayout" name="horizontalLayout">
19 <item>22 <item>
2023
=== modified file 'data/qt/license.ui'
--- data/qt/license.ui 2011-07-12 03:24:48 +0000
+++ data/qt/license.ui 2011-09-07 11:54:54 +0000
@@ -14,21 +14,11 @@
14 <string>Form</string>14 <string>Form</string>
15 </property>15 </property>
16 <layout class="QVBoxLayout" name="verticalLayout">16 <layout class="QVBoxLayout" name="verticalLayout">
17 <property name="topMargin">
18 <number>0</number>
19 </property>
17 <item>20 <item>
18 <widget class="QTextBrowser" name="textBrowser">21 <widget class="QTextBrowser" name="textBrowser">
19 <property name="html">
20 <string>&lt;!DOCTYPE HTML PUBLIC &quot;-//W3C//DTD HTML 4.0//EN&quot; &quot;http://www.w3.org/TR/REC-html40/strict.dtd&quot;&gt;
21&lt;html&gt;&lt;head&gt;&lt;meta name=&quot;qrichtext&quot; content=&quot;1&quot; /&gt;&lt;style type=&quot;text/css&quot;&gt;
22p, li { white-space: pre-wrap; }
23&lt;/style&gt;&lt;/head&gt;&lt;body style=&quot; font-family:'MS Shell Dlg 2'; font-size:8.25pt; font-weight:400; font-style:normal;&quot;&gt;
24&lt;p style=&quot; margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;&quot;&gt;&lt;span style=&quot; font-size:14pt; font-weight:600;&quot;&gt;License Agreement&lt;/span&gt;&lt;/p&gt;
25&lt;p style=&quot;-qt-paragraph-type:empty; margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px; font-size:8pt;&quot;&gt;&lt;/p&gt;
26&lt;p style=&quot; margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;&quot;&gt;&lt;span style=&quot; font-size:8pt;&quot;&gt;This program is free software: you can redistribute it and/or modify it under the terms of the GNU General Public License version 3, as published by the Free Software Foundation.&lt;/span&gt;&lt;/p&gt;
27&lt;p style=&quot;-qt-paragraph-type:empty; margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px; font-size:8pt;&quot;&gt;&lt;/p&gt;
28&lt;p style=&quot; margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;&quot;&gt;&lt;span style=&quot; font-size:8pt;&quot;&gt;Ubuntu One Basic is free, while additional service add-ons may be paid for services.&lt;/span&gt;&lt;/p&gt;
29&lt;p style=&quot;-qt-paragraph-type:empty; margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px; font-size:8pt;&quot;&gt;&lt;/p&gt;
30&lt;p style=&quot; margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;&quot;&gt;&lt;span style=&quot; font-size:8pt;&quot;&gt;As free software, this programme is distributed without warranty. See the GNU General Public License for more details at &lt;/span&gt;&lt;a href=&quot;http://www.gnu.org/licenses&quot;&gt;&lt;span style=&quot; font-size:8pt; text-decoration: underline; color:#dd4814;&quot;&gt;http://www.gnu.org/licenses&lt;/span&gt;&lt;/a&gt;&lt;/p&gt;&lt;/body&gt;&lt;/html&gt;</string>
31 </property>
32 <property name="openExternalLinks">22 <property name="openExternalLinks">
33 <bool>true</bool>23 <bool>true</bool>
34 </property>24 </property>
3525
=== modified file 'data/qt/local_folders.ui'
--- data/qt/local_folders.ui 2011-08-15 13:29:08 +0000
+++ data/qt/local_folders.ui 2011-09-07 11:54:54 +0000
@@ -14,6 +14,9 @@
14 <string>Form</string>14 <string>Form</string>
15 </property>15 </property>
16 <layout class="QVBoxLayout" name="verticalLayout_2">16 <layout class="QVBoxLayout" name="verticalLayout_2">
17 <property name="topMargin">
18 <number>0</number>
19 </property>
17 <item>20 <item>
18 <widget class="QLabel" name="label">21 <widget class="QLabel" name="label">
19 <property name="text">22 <property name="text">
2023
=== modified file 'data/qt/preferences.ui'
--- data/qt/preferences.ui 2011-08-10 21:06:46 +0000
+++ data/qt/preferences.ui 2011-09-07 11:54:54 +0000
@@ -13,7 +13,11 @@
13 <property name="windowTitle">13 <property name="windowTitle">
14 <string>Form</string>14 <string>Form</string>
15 </property>15 </property>
16 <layout class="QVBoxLayout" name="verticalLayout"/>16 <layout class="QVBoxLayout" name="verticalLayout">
17 <property name="topMargin">
18 <number>0</number>
19 </property>
20 </layout>
17 </widget>21 </widget>
18 <resources/>22 <resources/>
19 <connections/>23 <connections/>
2024
=== modified file 'data/qt/setup_account.ui'
--- data/qt/setup_account.ui 2011-08-29 12:49:25 +0000
+++ data/qt/setup_account.ui 2011-09-07 11:54:54 +0000
@@ -6,8 +6,8 @@
6 <rect>6 <rect>
7 <x>0</x>7 <x>0</x>
8 <y>0</y>8 <y>0</y>
9 <width>583</width>9 <width>543</width>
10 <height>538</height>10 <height>523</height>
11 </rect>11 </rect>
12 </property>12 </property>
13 <property name="sizePolicy">13 <property name="sizePolicy">
@@ -29,11 +29,20 @@
29 <property name="spacing">29 <property name="spacing">
30 <number>0</number>30 <number>0</number>
31 </property>31 </property>
32 <property name="leftMargin">
33 <number>0</number>
34 </property>
35 <property name="topMargin">
36 <number>0</number>
37 </property>
32 <property name="rightMargin">38 <property name="rightMargin">
33 <number>6</number>39 <number>3</number>
40 </property>
41 <property name="bottomMargin">
42 <number>0</number>
34 </property>43 </property>
35 <item>44 <item>
36 <layout class="QGridLayout" name="gridLayout" columnminimumwidth="310,250">45 <layout class="QGridLayout" name="gridLayout" columnminimumwidth="310,220">
37 <item row="0" column="0">46 <item row="0" column="0">
38 <widget class="QLabel" name="password_info_label">47 <widget class="QLabel" name="password_info_label">
39 <property name="sizePolicy">48 <property name="sizePolicy">
@@ -412,9 +421,15 @@
412 <verstretch>0</verstretch>421 <verstretch>0</verstretch>
413 </sizepolicy>422 </sizepolicy>
414 </property>423 </property>
424 <property name="minimumSize">
425 <size>
426 <width>220</width>
427 <height>0</height>
428 </size>
429 </property>
415 <property name="maximumSize">430 <property name="maximumSize">
416 <size>431 <size>
417 <width>300</width>432 <width>220</width>
418 <height>16777215</height>433 <height>16777215</height>
419 </size>434 </size>
420 </property>435 </property>
@@ -428,14 +443,17 @@
428 <bool>true</bool>443 <bool>true</bool>
429 </property>444 </property>
430 <property name="indent">445 <property name="indent">
431 <number>20</number>446 <number>0</number>
432 </property>447 </property>
433 </widget>448 </widget>
434 </item>449 </item>
435 <item row="1" column="1">450 <item row="1" column="1">
436 <layout class="QVBoxLayout" name="verticalLayout_7">451 <layout class="QVBoxLayout" name="verticalLayout_7">
452 <property name="spacing">
453 <number>0</number>
454 </property>
437 <property name="leftMargin">455 <property name="leftMargin">
438 <number>10</number>456 <number>0</number>
439 </property>457 </property>
440 <item>458 <item>
441 <widget class="QLabel" name="name_assistance">459 <widget class="QLabel" name="name_assistance">
@@ -445,9 +463,15 @@
445 <verstretch>0</verstretch>463 <verstretch>0</verstretch>
446 </sizepolicy>464 </sizepolicy>
447 </property>465 </property>
466 <property name="minimumSize">
467 <size>
468 <width>220</width>
469 <height>0</height>
470 </size>
471 </property>
448 <property name="maximumSize">472 <property name="maximumSize">
449 <size>473 <size>
450 <width>300</width>474 <width>220</width>
451 <height>16777215</height>475 <height>16777215</height>
452 </size>476 </size>
453 </property>477 </property>
@@ -457,14 +481,20 @@
457 <property name="alignment">481 <property name="alignment">
458 <set>Qt::AlignBottom|Qt::AlignLeading|Qt::AlignLeft</set>482 <set>Qt::AlignBottom|Qt::AlignLeading|Qt::AlignLeft</set>
459 </property>483 </property>
484 <property name="wordWrap">
485 <bool>true</bool>
486 </property>
460 </widget>487 </widget>
461 </item>488 </item>
462 </layout>489 </layout>
463 </item>490 </item>
464 <item row="3" column="1">491 <item row="3" column="1">
465 <layout class="QVBoxLayout" name="verticalLayout_8">492 <layout class="QVBoxLayout" name="verticalLayout_8">
493 <property name="spacing">
494 <number>0</number>
495 </property>
466 <property name="leftMargin">496 <property name="leftMargin">
467 <number>10</number>497 <number>0</number>
468 </property>498 </property>
469 <item>499 <item>
470 <widget class="QLabel" name="email_assistance">500 <widget class="QLabel" name="email_assistance">
@@ -474,9 +504,15 @@
474 <verstretch>0</verstretch>504 <verstretch>0</verstretch>
475 </sizepolicy>505 </sizepolicy>
476 </property>506 </property>
507 <property name="minimumSize">
508 <size>
509 <width>220</width>
510 <height>0</height>
511 </size>
512 </property>
477 <property name="maximumSize">513 <property name="maximumSize">
478 <size>514 <size>
479 <width>300</width>515 <width>220</width>
480 <height>16777215</height>516 <height>16777215</height>
481 </size>517 </size>
482 </property>518 </property>
@@ -486,14 +522,20 @@
486 <property name="alignment">522 <property name="alignment">
487 <set>Qt::AlignBottom|Qt::AlignLeading|Qt::AlignLeft</set>523 <set>Qt::AlignBottom|Qt::AlignLeading|Qt::AlignLeft</set>
488 </property>524 </property>
525 <property name="wordWrap">
526 <bool>true</bool>
527 </property>
489 </widget>528 </widget>
490 </item>529 </item>
491 </layout>530 </layout>
492 </item>531 </item>
493 <item row="4" column="1">532 <item row="4" column="1">
494 <layout class="QVBoxLayout" name="verticalLayout_9">533 <layout class="QVBoxLayout" name="verticalLayout_9">
534 <property name="spacing">
535 <number>0</number>
536 </property>
495 <property name="leftMargin">537 <property name="leftMargin">
496 <number>10</number>538 <number>0</number>
497 </property>539 </property>
498 <item>540 <item>
499 <widget class="QLabel" name="confirm_email_assistance">541 <widget class="QLabel" name="confirm_email_assistance">
@@ -503,9 +545,15 @@
503 <verstretch>0</verstretch>545 <verstretch>0</verstretch>
504 </sizepolicy>546 </sizepolicy>
505 </property>547 </property>
548 <property name="minimumSize">
549 <size>
550 <width>220</width>
551 <height>0</height>
552 </size>
553 </property>
506 <property name="maximumSize">554 <property name="maximumSize">
507 <size>555 <size>
508 <width>300</width>556 <width>220</width>
509 <height>16777215</height>557 <height>16777215</height>
510 </size>558 </size>
511 </property>559 </property>
@@ -515,6 +563,12 @@
515 <property name="alignment">563 <property name="alignment">
516 <set>Qt::AlignBottom|Qt::AlignLeading|Qt::AlignLeft</set>564 <set>Qt::AlignBottom|Qt::AlignLeading|Qt::AlignLeft</set>
517 </property>565 </property>
566 <property name="wordWrap">
567 <bool>true</bool>
568 </property>
569 <property name="indent">
570 <number>0</number>
571 </property>
518 </widget>572 </widget>
519 </item>573 </item>
520 </layout>574 </layout>
@@ -527,17 +581,26 @@
527 <verstretch>0</verstretch>581 <verstretch>0</verstretch>
528 </sizepolicy>582 </sizepolicy>
529 </property>583 </property>
584 <property name="minimumSize">
585 <size>
586 <width>220</width>
587 <height>0</height>
588 </size>
589 </property>
530 <property name="maximumSize">590 <property name="maximumSize">
531 <size>591 <size>
532 <width>300</width>592 <width>220</width>
533 <height>16777215</height>593 <height>16777215</height>
534 </size>594 </size>
535 </property>595 </property>
536 <property name="text">596 <property name="text">
537 <string>password_assistance</string>597 <string>password_assistance</string>
538 </property>598 </property>
599 <property name="wordWrap">
600 <bool>true</bool>
601 </property>
539 <property name="indent">602 <property name="indent">
540 <number>20</number>603 <number>17</number>
541 </property>604 </property>
542 </widget>605 </widget>
543 </item>606 </item>
@@ -552,7 +615,7 @@
552 <property name="sizeHint" stdset="0">615 <property name="sizeHint" stdset="0">
553 <size>616 <size>
554 <width>20</width>617 <width>20</width>
555 <height>20</height>618 <height>15</height>
556 </size>619 </size>
557 </property>620 </property>
558 </spacer>621 </spacer>
@@ -568,7 +631,7 @@
568 <property name="sizeHint" stdset="0">631 <property name="sizeHint" stdset="0">
569 <size>632 <size>
570 <width>20</width>633 <width>20</width>
571 <height>20</height>634 <height>15</height>
572 </size>635 </size>
573 </property>636 </property>
574 </spacer>637 </spacer>
@@ -584,7 +647,7 @@
584 <property name="sizeHint" stdset="0">647 <property name="sizeHint" stdset="0">
585 <size>648 <size>
586 <width>20</width>649 <width>20</width>
587 <height>20</height>650 <height>15</height>
588 </size>651 </size>
589 </property>652 </property>
590 </spacer>653 </spacer>
591654
=== modified file 'data/qt/side_widget.ui'
--- data/qt/side_widget.ui 2011-07-14 10:53:49 +0000
+++ data/qt/side_widget.ui 2011-09-07 11:54:54 +0000
@@ -6,8 +6,8 @@
6 <rect>6 <rect>
7 <x>0</x>7 <x>0</x>
8 <y>0</y>8 <y>0</y>
9 <width>200</width>9 <width>170</width>
10 <height>563</height>10 <height>466</height>
11 </rect>11 </rect>
12 </property>12 </property>
13 <property name="sizePolicy">13 <property name="sizePolicy">
@@ -18,8 +18,8 @@
18 </property>18 </property>
19 <property name="minimumSize">19 <property name="minimumSize">
20 <size>20 <size>
21 <width>200</width>21 <width>170</width>
22 <height>0</height>22 <height>466</height>
23 </size>23 </size>
24 </property>24 </property>
25 <property name="windowTitle">25 <property name="windowTitle">
@@ -36,7 +36,7 @@
36 <number>40</number>36 <number>40</number>
37 </property>37 </property>
38 <property name="margin">38 <property name="margin">
39 <number>10</number>39 <number>0</number>
40 </property>40 </property>
41 <item>41 <item>
42 <widget class="QLabel" name="ubuntu_one_logo_label">42 <widget class="QLabel" name="ubuntu_one_logo_label">
@@ -145,39 +145,6 @@
145 </layout>145 </layout>
146 </item>146 </item>
147 <item>147 <item>
148 <layout class="QHBoxLayout" name="horizontalLayout_3">
149 <property name="spacing">
150 <number>7</number>
151 </property>
152 <item>
153 <widget class="QLabel" name="choose_icon_label">
154 <property name="sizePolicy">
155 <sizepolicy hsizetype="Fixed" vsizetype="Fixed">
156 <horstretch>0</horstretch>
157 <verstretch>0</verstretch>
158 </sizepolicy>
159 </property>
160 <property name="text">
161 <string/>
162 </property>
163 <property name="pixmap">
164 <pixmap resource="images.qrc">:/progress_arrow_grey.png</pixmap>
165 </property>
166 </widget>
167 </item>
168 <item>
169 <widget class="QLabel" name="choose_services_label">
170 <property name="enabled">
171 <bool>true</bool>
172 </property>
173 <property name="text">
174 <string>Choose services</string>
175 </property>
176 </widget>
177 </item>
178 </layout>
179 </item>
180 <item>
181 <layout class="QHBoxLayout" name="horizontalLayout_4">148 <layout class="QHBoxLayout" name="horizontalLayout_4">
182 <property name="spacing">149 <property name="spacing">
183 <number>7</number>150 <number>7</number>
184151
=== modified file 'data/qt/sign_in.ui'
--- data/qt/sign_in.ui 2011-07-27 14:53:56 +0000
+++ data/qt/sign_in.ui 2011-09-07 11:54:54 +0000
@@ -14,6 +14,9 @@
14 <string>Form</string>14 <string>Form</string>
15 </property>15 </property>
16 <layout class="QVBoxLayout" name="verticalLayout">16 <layout class="QVBoxLayout" name="verticalLayout">
17 <property name="topMargin">
18 <number>0</number>
19 </property>
17 <item>20 <item>
18 <widget class="QLabel" name="label">21 <widget class="QLabel" name="label">
19 <property name="font">22 <property name="font">
2023
=== modified file 'data/qt/sync_now_or_later.ui'
--- data/qt/sync_now_or_later.ui 2011-06-28 19:18:35 +0000
+++ data/qt/sync_now_or_later.ui 2011-09-07 11:54:54 +0000
@@ -17,6 +17,9 @@
17 <property name="spacing">17 <property name="spacing">
18 <number>24</number>18 <number>24</number>
19 </property>19 </property>
20 <property name="topMargin">
21 <number>0</number>
22 </property>
20 <item>23 <item>
21 <widget class="QLabel" name="label">24 <widget class="QLabel" name="label">
22 <property name="font">25 <property name="font">
2326
=== modified file 'data/qt/ubuntuone.qss'
--- data/qt/ubuntuone.qss 2011-08-24 18:08:14 +0000
+++ data/qt/ubuntuone.qss 2011-09-07 11:54:54 +0000
@@ -10,7 +10,6 @@
10 border-right-width: 1px;10 border-right-width: 1px;
11 color: white;11 color: white;
12 min-height: 100px;12 min-height: 100px;
13 margin-left: 10px;
14}13}
1514
16QWizard,15QWizard,
1716
=== modified file 'ubuntuone_installer/gui/qt/__init__.py'
--- ubuntuone_installer/gui/qt/__init__.py 2011-06-22 10:47:08 +0000
+++ ubuntuone_installer/gui/qt/__init__.py 2011-09-07 11:54:54 +0000
@@ -17,3 +17,20 @@
17# with this program. If not, see <http://www.gnu.org/licenses/>.17# with this program. If not, see <http://www.gnu.org/licenses/>.
1818
19"""The Qt graphical interface for the Ubuntu One Installer."""19"""The Qt graphical interface for the Ubuntu One Installer."""
20
21
22LICENSE_CONTENT = """<html>
23 <body style="font-family:Ubuntu">
24 <h2>License Agreement</h2>
25 <p>This program is free software: you can redistribute it and/or modify
26 it under the terms of the GNU General Public License version 3, as
27 published by the Free Software Foundation.</p>
28 <p>Ubuntu One Basic is free, while additional service add-ons may be
29 paid for services.</p>
30 <p>As free software, this programme is distributed without warranty.
31 See the GNU General Public License for more details at
32 <a href='http://www.gnu.org/licenses'
33 style="color:#dd4814;">http://www.gnu.org/licenses</a>
34 </p>
35 </body>
36<html>"""
2037
=== modified file 'ubuntuone_installer/gui/qt/gui.py'
--- ubuntuone_installer/gui/qt/gui.py 2011-09-06 17:30:24 +0000
+++ ubuntuone_installer/gui/qt/gui.py 2011-09-07 11:54:54 +0000
@@ -64,7 +64,7 @@
64 setup_account_ui,64 setup_account_ui,
65)65)
6666
67from ubuntuone_installer.gui.qt import utils67from ubuntuone_installer.gui import qt
68from ubuntuone_installer.gui.qt.are_you_sure import AreYouSure68from ubuntuone_installer.gui.qt.are_you_sure import AreYouSure
69from ubuntuone_installer.gui.qt.currentuser import CurrentUserController69from ubuntuone_installer.gui.qt.currentuser import CurrentUserController
70from ubuntuone_installer.gui.qt.folders import FoldersPage70from ubuntuone_installer.gui.qt.folders import FoldersPage
@@ -98,6 +98,7 @@
98 self._next_id = None98 self._next_id = None
99 super(LicensePage, self).__init__(license_ui.Ui_Form(), None, parent)99 super(LicensePage, self).__init__(license_ui.Ui_Form(), None, parent)
100 self.header.setVisible(False)100 self.header.setVisible(False)
101 self.ui.textBrowser.setHtml(qt.LICENSE_CONTENT)
101102
102 # Invalid names of Qt-inherited methods103 # Invalid names of Qt-inherited methods
103 # pylint: disable=C0103104 # pylint: disable=C0103
@@ -285,8 +286,8 @@
285 self.setWindowFlags(flags)286 self.setWindowFlags(flags)
286287
287 self.setWindowTitle(APP_NAME)288 self.setWindowTitle(APP_NAME)
288 self.setMinimumHeight(590)289 self.setMinimumHeight(538)
289 self.setMinimumWidth(800)290 self.setMinimumWidth(740)
290 self.setWizardStyle(self.ModernStyle)291 self.setWizardStyle(self.ModernStyle)
291 self.close_callback = close_callback292 self.close_callback = close_callback
292293
@@ -426,10 +427,10 @@
426 """The main window is being closed, call any custom callback."""427 """The main window is being closed, call any custom callback."""
427 # Finished, not cancelled428 # Finished, not cancelled
428 if result == 1: # Cancelled429 if result == 1: # Cancelled
429 utils.start_control_panel()430 qt.utils.start_control_panel()
430 elif self.currentId() == self.LICENSE_PAGE_ID:431 elif self.currentId() == self.LICENSE_PAGE_ID:
431 if AreYouSure(self).exec_():432 if not AreYouSure(self).exec_():
432 utils.uninstall_application()433 qt.utils.uninstall_application()
433 else:434 else:
434 return435 return
435 elif self.currentId() != self.CONGRATULATIONS_PAGE:436 elif self.currentId() != self.CONGRATULATIONS_PAGE:
436437
=== modified file 'ubuntuone_installer/gui/qt/main/windows.py'
--- ubuntuone_installer/gui/qt/main/windows.py 2011-09-01 11:15:49 +0000
+++ ubuntuone_installer/gui/qt/main/windows.py 2011-09-07 11:54:54 +0000
@@ -47,7 +47,8 @@
47 """Handle credentials success."""47 """Handle credentials success."""
48 if creds: # Have credentials already48 if creds: # Have credentials already
49 try:49 try:
50 gui.utils.start_control_panel()50 from ubuntuone_installer.gui.qt import utils
51 utils.start_control_panel()
51 except OSError:52 except OSError:
52 QtGui.QMessageBox.critical(53 QtGui.QMessageBox.critical(
53 None, "Ubuntu One", gui.STARTING_CP_ERROR)54 None, "Ubuntu One", gui.STARTING_CP_ERROR)
5455
=== modified file 'ubuntuone_installer/gui/qt/side_widget.py'
--- ubuntuone_installer/gui/qt/side_widget.py 2011-07-14 03:55:39 +0000
+++ ubuntuone_installer/gui/qt/side_widget.py 2011-09-07 11:54:54 +0000
@@ -33,9 +33,8 @@
3333
34 install_stage = 034 install_stage = 0
35 signin_stage = 135 signin_stage = 1
36 choose_services_stage = 236 select_sync_folders_stage = 2
37 select_sync_folders_stage = 337 sync_stage = 3
38 sync_stage = 4
3938
40 def __init__(self, *args, **kwargs):39 def __init__(self, *args, **kwargs):
41 super(SideWidget, self).__init__(*args, **kwargs)40 super(SideWidget, self).__init__(*args, **kwargs)
@@ -48,13 +47,10 @@
48 self.stage = stage47 self.stage = stage
49 self.ui.install_label.setEnabled(stage >= 0)48 self.ui.install_label.setEnabled(stage >= 0)
50 self.ui.sign_in_label.setEnabled(stage >= 1)49 self.ui.sign_in_label.setEnabled(stage >= 1)
51 self.ui.choose_services_label.setEnabled(stage >= 2)50 self.ui.select_folders_label.setEnabled(stage >= 2)
52 self.ui.select_folders_label.setEnabled(stage >= 3)51 self.ui.sync_label.setEnabled(stage >= 3)
53 self.ui.sync_label.setEnabled(stage >= 4)
54 self.set_stage_icon(self.ui.install_icon_label, self.install_stage)52 self.set_stage_icon(self.ui.install_icon_label, self.install_stage)
55 self.set_stage_icon(self.ui.sign_icon_label, self.signin_stage)53 self.set_stage_icon(self.ui.sign_icon_label, self.signin_stage)
56 self.set_stage_icon(self.ui.choose_icon_label,
57 self.choose_services_stage)
58 self.set_stage_icon(self.ui.folders_icon_label,54 self.set_stage_icon(self.ui.folders_icon_label,
59 self.select_sync_folders_stage)55 self.select_sync_folders_stage)
60 self.set_stage_icon(self.ui.sync_icon_label, self.sync_stage)56 self.set_stage_icon(self.ui.sync_icon_label, self.sync_stage)
6157
=== modified file 'ubuntuone_installer/gui/qt/tests/test_gui.py'
--- ubuntuone_installer/gui/qt/tests/test_gui.py 2011-09-06 16:25:25 +0000
+++ ubuntuone_installer/gui/qt/tests/test_gui.py 2011-09-07 11:54:54 +0000
@@ -175,7 +175,7 @@
175 self.ui.restart()175 self.ui.restart()
176 self.ui.show()176 self.ui.show()
177 self.addCleanup(self.ui.hide)177 self.addCleanup(self.ui.hide)
178 gui.AreYouSure.result = 1178 gui.AreYouSure.result = 0
179 self.patch(utils, "uninstall_application", self._set_called)179 self.patch(utils, "uninstall_application", self._set_called)
180 self.ui.done(result=0)180 self.ui.done(result=0)
181 self.assertTrue(self._called)181 self.assertTrue(self._called)
@@ -186,7 +186,7 @@
186 self.ui.restart()186 self.ui.restart()
187 self.ui.show()187 self.ui.show()
188 self.addCleanup(self.ui.hide)188 self.addCleanup(self.ui.hide)
189 gui.AreYouSure.result = 1189 gui.AreYouSure.result = 0
190 self.patch(utils, "uninstall_application", self._set_called)190 self.patch(utils, "uninstall_application", self._set_called)
191 self.ui.done(result=0)191 self.ui.done(result=0)
192 self.assertTrue(self._called)192 self.assertTrue(self._called)
@@ -419,7 +419,7 @@
419419
420 def test_continue_cancels_cancel(self):420 def test_continue_cancels_cancel(self):
421 """Clicking 'Continue' cancels cancellation."""421 """Clicking 'Continue' cancels cancellation."""
422 gui.AreYouSure.result = 0422 gui.AreYouSure.result = 1
423 self.patch(subprocess, "Popen", self._set_called)423 self.patch(subprocess, "Popen", self._set_called)
424 self.ui.show()424 self.ui.show()
425 self.addCleanup(self.ui.hide)425 self.addCleanup(self.ui.hide)
426426
=== modified file 'ubuntuone_installer/gui/qt/tests/test_side_widget.py'
--- ubuntuone_installer/gui/qt/tests/test_side_widget.py 2011-07-14 03:55:39 +0000
+++ ubuntuone_installer/gui/qt/tests/test_side_widget.py 2011-09-07 11:54:54 +0000
@@ -43,8 +43,6 @@
43 self.assertEqual(43 self.assertEqual(
44 self.ui.ui.sign_in_label.isEnabled(), False)44 self.ui.ui.sign_in_label.isEnabled(), False)
45 self.assertEqual(45 self.assertEqual(
46 self.ui.ui.choose_services_label.isEnabled(), False)
47 self.assertEqual(
48 self.ui.ui.select_folders_label.isEnabled(), False)46 self.ui.ui.select_folders_label.isEnabled(), False)
49 self.assertEqual(47 self.assertEqual(
50 self.ui.ui.sync_label.isEnabled(), False)48 self.ui.ui.sync_label.isEnabled(), False)
@@ -58,8 +56,6 @@
58 self.assertEqual(56 self.assertEqual(
59 self.ui.ui.sign_in_label.isEnabled(), True)57 self.ui.ui.sign_in_label.isEnabled(), True)
60 self.assertEqual(58 self.assertEqual(
61 self.ui.ui.choose_services_label.isEnabled(), False)
62 self.assertEqual(
63 self.ui.ui.select_folders_label.isEnabled(), False)59 self.ui.ui.select_folders_label.isEnabled(), False)
64 self.assertEqual(60 self.assertEqual(
65 self.ui.ui.sync_label.isEnabled(), False)61 self.ui.ui.sync_label.isEnabled(), False)
@@ -73,9 +69,7 @@
73 self.assertEqual(69 self.assertEqual(
74 self.ui.ui.sign_in_label.isEnabled(), True)70 self.ui.ui.sign_in_label.isEnabled(), True)
75 self.assertEqual(71 self.assertEqual(
76 self.ui.ui.choose_services_label.isEnabled(), True)72 self.ui.ui.select_folders_label.isEnabled(), True)
77 self.assertEqual(
78 self.ui.ui.select_folders_label.isEnabled(), False)
79 self.assertEqual(73 self.assertEqual(
80 self.ui.ui.sync_label.isEnabled(), False)74 self.ui.ui.sync_label.isEnabled(), False)
81 self.check_state_pixmap(2)75 self.check_state_pixmap(2)
@@ -88,28 +82,11 @@
88 self.assertEqual(82 self.assertEqual(
89 self.ui.ui.sign_in_label.isEnabled(), True)83 self.ui.ui.sign_in_label.isEnabled(), True)
90 self.assertEqual(84 self.assertEqual(
91 self.ui.ui.choose_services_label.isEnabled(), True)
92 self.assertEqual(
93 self.ui.ui.select_folders_label.isEnabled(), True)85 self.ui.ui.select_folders_label.isEnabled(), True)
94 self.assertEqual(86 self.assertEqual(
95 self.ui.ui.sync_label.isEnabled(), False)87 self.ui.ui.sync_label.isEnabled(), True)
96 self.check_state_pixmap(3)88 self.check_state_pixmap(3)
9789
98 def test_stage_4(self):
99 """Check that each stage in the widget enables the right labels."""
100 self.ui.set_stage(4)
101 self.assertEqual(
102 self.ui.ui.install_label.isEnabled(), True)
103 self.assertEqual(
104 self.ui.ui.sign_in_label.isEnabled(), True)
105 self.assertEqual(
106 self.ui.ui.choose_services_label.isEnabled(), True)
107 self.assertEqual(
108 self.ui.ui.select_folders_label.isEnabled(), True)
109 self.assertEqual(
110 self.ui.ui.sync_label.isEnabled(), True)
111 self.check_state_pixmap(4)
112
113 def get_pixmap_data(self, pixmap):90 def get_pixmap_data(self, pixmap):
114 """Get the raw data of a QPixmap."""91 """Get the raw data of a QPixmap."""
115 byte_array = QtCore.QByteArray()92 byte_array = QtCore.QByteArray()
@@ -128,7 +105,6 @@
128105
129 def check_state_pixmap(self, stage):106 def check_state_pixmap(self, stage):
130 """Check if each label has the proper pixmap depending on the state."""107 """Check if each label has the proper pixmap depending on the state."""
131 print stage
132 active_pixmap = QtGui.QPixmap(":/progress_arrow_orange.png")108 active_pixmap = QtGui.QPixmap(":/progress_arrow_orange.png")
133 no_active_pixmap = QtGui.QPixmap(":/progress_arrow_grey.png")109 no_active_pixmap = QtGui.QPixmap(":/progress_arrow_grey.png")
134 complete_pixmap = QtGui.QPixmap(":/progress_tick.png")110 complete_pixmap = QtGui.QPixmap(":/progress_tick.png")
@@ -137,19 +113,18 @@
137 labels = (113 labels = (
138 self.ui.ui.install_icon_label,114 self.ui.ui.install_icon_label,
139 self.ui.ui.sign_icon_label,115 self.ui.ui.sign_icon_label,
140 self.ui.ui.choose_icon_label,
141 self.ui.ui.folders_icon_label,116 self.ui.ui.folders_icon_label,
142 self.ui.ui.sync_icon_label)117 self.ui.ui.sync_icon_label)
143118
144 for item in labels[:stage]:119 for item in labels[:stage]:
145 self.assertEqualPixmaps(complete_pixmap, item.pixmap())120 self.assertEqualPixmaps(complete_pixmap, item.pixmap())
146121
147 if stage != 4:122 if stage != 3:
148 self.assertEqualPixmaps(active_pixmap, labels[stage].pixmap())123 self.assertEqualPixmaps(active_pixmap, labels[stage].pixmap())
149 else:124 else:
150 self.assertEqualPixmaps(sync_active_pixmap, labels[4].pixmap())125 self.assertEqualPixmaps(sync_active_pixmap, labels[3].pixmap())
151126
152 if stage < 4:127 if stage < 3:
153 for item in labels[stage + 1:len(labels) - 1]:128 for item in labels[stage + 1:len(labels) - 1]:
154 self.assertEqualPixmaps(no_active_pixmap, item.pixmap())129 self.assertEqualPixmaps(no_active_pixmap, item.pixmap())
155 self.assertEqualPixmaps(sync_no_active_pixmap, labels[4].pixmap())130 self.assertEqualPixmaps(sync_no_active_pixmap, labels[3].pixmap())

Subscribers

People subscribed via source and target branches