Merge lp:~mterry/unity8/default-wallpaper into lp:unity8
- default-wallpaper
- Merge into trunk
Status: | Superseded |
---|---|
Proposed branch: | lp:~mterry/unity8/default-wallpaper |
Merge into: | lp:unity8 |
Diff against target: |
846 lines (+278/-133) 25 files modified
build.sh (+1/-0) debian/control (+1/-0) qml/Components/Lockscreen.qml (+1/-5) qml/Components/Wallpaper.qml (+45/-0) qml/Components/WallpaperResolver.qml (+28/-42) qml/Dash/DashBackground.qml (+16/-11) qml/Greeter/CoverPage.qml (+5/-5) qml/Greeter/Greeter.qml (+7/-0) qml/Greeter/NarrowView.qml (+3/-1) qml/Greeter/WideView.qml (+1/-0) qml/Shell.qml (+16/-1) qml/Stages/DesktopStage.qml (+1/-3) tests/mocks/AccountsService/AccountsService.cpp (+1/-1) tests/qmltests/Components/tst_Lockscreen.qml (+1/-1) tests/qmltests/Components/tst_WallpaperResolver.qml (+28/-42) tests/qmltests/Components/tst_ZoomableImage.qml (+1/-1) tests/qmltests/Dash/Previews/tst_PreviewExpandable.qml (+3/-3) tests/qmltests/Dash/Previews/tst_PreviewImageGallery.qml (+6/-6) tests/qmltests/Dash/Previews/tst_PreviewZoomableImage.qml (+7/-7) tests/qmltests/Greeter/TestView.qml (+1/-0) tests/qmltests/Greeter/tst_Greeter.qml (+7/-1) tests/qmltests/Greeter/tst_NarrowView.qml (+14/-1) tests/qmltests/Greeter/tst_WideView.qml (+12/-1) tests/qmltests/Stages/tst_DesktopStage.qml (+1/-1) tests/qmltests/tst_Shell.qml (+71/-0) |
To merge this branch: | bzr merge lp:~mterry/unity8/default-wallpaper |
Related bugs: |
Reviewer | Review Type | Date Requested | Status |
---|---|---|---|
Unity8 CI Bot | continuous-integration | Needs Fixing | |
Unity Team | Pending | ||
Review via email: mp+297636@code.launchpad.net |
This proposal has been superseded by a proposal from 2016-07-08.
Commit message
Use the default system wallpaper instead of our custom one.
Additionally, crop the default wallpaper instead of rotating it, only darken the wallpaper if it's not the default one, and avoid reloading the wallpaper when the device is rotated.
Description of the change
* Are there any related MPs required for this MP to build/function as expected? Please list.
- https:/
- https:/
I've made silo 23 that includes all three for easier testing.
* Did you perform an exploratory manual test run of your code change and any related functionality?
Yes
* If you changed the packaging (debian), did you subscribe the ubuntu-unity team to this MP?
I'm on the team
* If you changed the UI, has there been a design review?
Regarding not darkening the default wallpaper, see [1]. We are *supposed* to blur custom wallpapers instead of merely darkening them, but that will a separate MP.
Regarding cropping instead of rotating, see [2]. Though we don't do the user-settable center line. Again, that can be a separate MP (bug 1593880).
Additionally, I passed this MP by John Lea with screenshots and he's fine with it, though he didn't actually run it.
[1] https:/
[2] https:/
Unity8 CI Bot (unity8-ci-bot) wrote : | # |
Unity8 CI Bot (unity8-ci-bot) wrote : | # |
FAILED: Continuous integration, rev:2449
https:/
Executed test runs:
SUCCESS: https:/
FAILURE: https:/
FAILURE: https:/
FAILURE: https:/
SUCCESS: https:/
SUCCESS: https:/
SUCCESS: https:/
SUCCESS: https:/
SUCCESS: https:/
deb: https:/
SUCCESS: https:/
deb: https:/
SUCCESS: https:/
deb: https:/
SUCCESS: https:/
deb: https:/
SUCCESS: https:/
deb: https:/
SUCCESS: https:/
deb: https:/
SUCCESS: https:/
deb: https:/
SUCCESS: https:/
deb: https:/
SUCCESS: https:/
deb: https:/
Click here to trigger a rebuild:
https:/
- 2488. By CI Train Bot Account
-
Resync trunk.
- 2489. By Launchpad Translations on behalf of unity-team
-
Launchpad automatic translations update.
- 2490. By Launchpad Translations on behalf of unity-team
-
Launchpad automatic translations update.
- 2491. By Michael Terry
-
Support unlocking via fingerprint, if one is registered.
- 2492. By CI Train Bot Account
-
Releasing 8.12+16.
10.20160620. 3-0ubuntu1
Unity8 CI Bot (unity8-ci-bot) wrote : | # |
FAILED: Continuous integration, rev:2450
https:/
Executed test runs:
SUCCESS: https:/
SUCCESS: https:/
SUCCESS: https:/
UNSTABLE: https:/
SUCCESS: https:/
SUCCESS: https:/
SUCCESS: https:/
SUCCESS: https:/
SUCCESS: https:/
deb: https:/
SUCCESS: https:/
deb: https:/
SUCCESS: https:/
deb: https:/
SUCCESS: https:/
deb: https:/
SUCCESS: https:/
deb: https:/
SUCCESS: https:/
deb: https:/
SUCCESS: https:/
deb: https:/
SUCCESS: https:/
deb: https:/
SUCCESS: https:/
deb: https:/
Click here to trigger a rebuild:
https:/
- 2493. By CI Train Bot Account
-
Resync trunk.
- 2494. By Launchpad Translations on behalf of unity-team
-
Launchpad automatic translations update.
Unity8 CI Bot (unity8-ci-bot) wrote : | # |
FAILED: Continuous integration, rev:2451
https:/
Executed test runs:
SUCCESS: https:/
UNSTABLE: https:/
SUCCESS: https:/
UNSTABLE: https:/
SUCCESS: https:/
SUCCESS: https:/
SUCCESS: https:/
SUCCESS: https:/
SUCCESS: https:/
deb: https:/
SUCCESS: https:/
deb: https:/
SUCCESS: https:/
deb: https:/
SUCCESS: https:/
deb: https:/
SUCCESS: https:/
deb: https:/
SUCCESS: https:/
deb: https:/
SUCCESS: https:/
deb: https:/
SUCCESS: https:/
deb: https:/
SUCCESS: https:/
deb: https:/
Click here to trigger a rebuild:
https:/
- 2495. By Albert Astals Cid
-
Added live video playback in dash previews
- 2496. By Albert Astals Cid
-
Stop watching the old header item height once it's not our header anymore
It doesn't really matter since in ListViewWithPag
eHeader: :itemImplicitHe ightChanged we compare with m_headerItem again so it won't break anything but better be watching only the things we really care about - 2497. By Albert Astals Cid
-
LVWPH: cull the header item when not on view to save some painting
- 2498. By Michael Zanetti
-
set minimum window sizes on dash
We can't just set them on C++ level because that would not be
DGU aware, instead of going for hackery with qml bindings to the
C++, lets go for using QtQuick.Window directly. - 2499. By Albert Astals Cid
-
Adapt test to new mock behaviour
- 2500. By Josh Arenson
-
Make PreviewRatingSi
ngleDisplay visible again after editing a review. (LP: #1587097) - 2501. By Daniel d'Andrada
-
Cursor: Let AnimatedSprite run only on animated cursors and while the display is on
That awesome component would keep running even on single-frame animations (ie,
on non-animated cursors) triggering redraws or otherwise keeping CPU busy for nothing.Also optimize things by using a regular and bug-free Image component to display
non-animated (single-frame) cursors.A second optimization is to only load the cursor image at all if the device
has a mouse/touchpad in the first place. (LP: #1588873, #1594358) - 2502. By Marco Trevisan (Treviño)
-
Unity8.conf: ensure MIR_SOCKET is set for future customers (such as the dash)
This ensures that if we run unity8 as standalone in Mir on X/KMS the MIR_SOCKET
is defined for other clients. - 2503. By Marco Trevisan (Treviño)
-
ClientIndicator: be more informative about loading failures for dynamically created objects
- 2504. By Lukáš Tinkl
-
Fix some smaller issues with OOBE wizard password pages (LP: #1590467)
- 2505. By Lukáš Tinkl
-
Prevent mouse wheel events from going through shell elements (LP: #1536268)
- 2506. By Daniel d'Andrada
-
Fix missing screenshot when orientation changes while shell rotation ongoing
- Device orientation changes
- Shell starts rotating
- Device orientation changes again
- Shell finishes rotation
- A new shell rotation starts to match that new device orientationOn that second rotation, the screenshot would be missing.
That's because UpdateShellTran
sformations was using requestedOrient ationAngle
directly, which is wrong for all but the ImmediateRotationAction. This is a regression caused by revision 2378
"Ensure shell transformations use bindings as OrientedShell can get resized" (LP: #1587796) - 2507. By Albert Astals Cid
-
Don't let the mouse go outside the parentItem (LP: #1525350)
- 2508. By Lukáš Tinkl
-
Do not let mouse and wheel events pass thru the titlebar (LP: #1588424)
- 2509. By Lukáš Tinkl
-
Hide the maximize window button based on size restrictions (LP: #1541982)
- 2510. By Michael Terry
-
Stop unity8 from getting in a "switch-to-greeter" loop when locking on a desktop. (LP: #1593718)
- 2511. By Michael Zanetti
-
displace application windows when the OSK would cover them
- 2512. By Nick Dedekind
-
Force dash to always stay in the main stage. (lp:#1592404) (LP: #1592404)
- 2513. By Nick Dedekind
-
Save the last surface stage on stage drop. (LP: #1579003)
- 2514. By Nick Dedekind
-
Default portrait only apps to the side stage. (LP: #1573153)
- 2515. By Albert Astals Cid
-
Use non deprecated package names
qtdeclarative5-
ubuntu- web-plugin -> qml-module- ubuntu- web
qtdeclarative5-qtmultimedia- plugin -> qml-module- qtmultimedia
qtdeclarative5-ubuntu- ui-toolkit- plugin -> qml-module- ubuntu- components
qtdeclarative5-ubuntu- thumbnailer0. 1 -> qml-module- ubuntu- thumbnailer0. 1 - 2516. By Albert Astals Cid
-
Mark system includes as such
Useful so you don't get warnings about unfixable things
- 2517. By Josh Arenson
-
Correct errors in all png images to prevent libpng warnings.
Run:
$ mogrify `find -name *.png` - 2518. By Albert Astals Cid
-
Fix initialization order warning
- 2519. By Albert Astals Cid
-
Do not rely on deleteLater not crashing on null pointers
- 2520. By Albert Astals Cid
-
Add more headers of classes we use for automoc to be run
Fixes compilation with ubsan
- 2521. By Albert Astals Cid
-
CardTool: Fix the fallback value to be a size and not an integer
- 2522. By Albert Astals Cid
-
CardTool: Include Ubuntu Components since we're using units.gu
- 2523. By Albert Astals Cid
-
Rework tst_PreviewRati
ngDisplayCreati onRanges Remove the time comparison and actually check that only a small amount of items is being created
- 2524. By CI Train Bot Account
-
Releasing 8.12+16.
10.20160627. 5-0ubuntu1 - 2525. By CI Train Bot Account
-
Resync trunk.
Unity8 CI Bot (unity8-ci-bot) wrote : | # |
FAILED: Continuous integration, rev:2452
https:/
Executed test runs:
SUCCESS: https:/
FAILURE: https:/
UNSTABLE: https:/
SUCCESS: https:/
SUCCESS: https:/
SUCCESS: https:/
SUCCESS: https:/
SUCCESS: https:/
SUCCESS: https:/
deb: https:/
SUCCESS: https:/
deb: https:/
SUCCESS: https:/
deb: https:/
SUCCESS: https:/
deb: https:/
SUCCESS: https:/
deb: https:/
SUCCESS: https:/
deb: https:/
SUCCESS: https:/
deb: https:/
SUCCESS: https:/
deb: https:/
SUCCESS: https:/
deb: https:/
Click here to trigger a rebuild:
https:/
- 2526. By Launchpad Translations on behalf of unity-team
-
Launchpad automatic translations update.
Unity8 CI Bot (unity8-ci-bot) wrote : | # |
FAILED: Continuous integration, rev:2453
https:/
Executed test runs:
SUCCESS: https:/
UNSTABLE: https:/
SUCCESS: https:/
SUCCESS: https:/
SUCCESS: https:/
SUCCESS: https:/
SUCCESS: https:/
SUCCESS: https:/
SUCCESS: https:/
deb: https:/
SUCCESS: https:/
deb: https:/
SUCCESS: https:/
deb: https:/
SUCCESS: https:/
deb: https:/
SUCCESS: https:/
deb: https:/
SUCCESS: https:/
deb: https:/
SUCCESS: https:/
deb: https:/
SUCCESS: https:/
deb: https:/
SUCCESS: https:/
deb: https:/
Click here to trigger a rebuild:
https:/
- 2527. By Launchpad Translations on behalf of unity-team
-
Launchpad automatic translations update.
Unity8 CI Bot (unity8-ci-bot) wrote : | # |
FAILED: Continuous integration, rev:2454
https:/
Executed test runs:
SUCCESS: https:/
UNSTABLE: https:/
SUCCESS: https:/
UNSTABLE: https:/
SUCCESS: https:/
SUCCESS: https:/
SUCCESS: https:/
SUCCESS: https:/
SUCCESS: https:/
deb: https:/
SUCCESS: https:/
deb: https:/
SUCCESS: https:/
deb: https:/
SUCCESS: https:/
deb: https:/
SUCCESS: https:/
deb: https:/
SUCCESS: https:/
deb: https:/
SUCCESS: https:/
deb: https:/
SUCCESS: https:/
deb: https:/
SUCCESS: https:/
deb: https:/
Click here to trigger a rebuild:
https:/
- 2528. By Launchpad Translations on behalf of unity-team
-
Launchpad automatic translations update.
- 2529. By Michael Zanetti
-
don't displace windows if the OSK is on another screen (LP: #1598917)
- 2530. By CI Train Bot Account
-
Releasing 8.12+16.
10.20160705- 0ubuntu1
Unity8 CI Bot (unity8-ci-bot) wrote : | # |
FAILED: Continuous integration, rev:2455
https:/
Executed test runs:
SUCCESS: https:/
UNSTABLE: https:/
SUCCESS: https:/
UNSTABLE: https:/
SUCCESS: https:/
SUCCESS: https:/
SUCCESS: https:/
SUCCESS: https:/
SUCCESS: https:/
deb: https:/
SUCCESS: https:/
deb: https:/
SUCCESS: https:/
deb: https:/
SUCCESS: https:/
deb: https:/
SUCCESS: https:/
deb: https:/
SUCCESS: https:/
deb: https:/
SUCCESS: https:/
deb: https:/
SUCCESS: https:/
deb: https:/
SUCCESS: https:/
deb: https:/
Click here to trigger a rebuild:
https:/
- 2531. By Launchpad Translations on behalf of unity-team
-
Launchpad automatic translations update.
- 2532. By Launchpad Translations on behalf of unity-team
-
Launchpad automatic translations update.
- 2533. By Michael Zanetti
-
emit the correct role changed signal on count visible changed (LP: #1599925)
- 2534. By CI Train Bot Account
-
Releasing 8.12+16.
10.20160707- 0ubuntu1
Unity8 CI Bot (unity8-ci-bot) wrote : | # |
FAILED: Continuous integration, rev:2456
https:/
Executed test runs:
FAILURE: https:/
SUCCESS: https:/
SUCCESS: https:/
SUCCESS: https:/
SUCCESS: https:/
FAILURE: https:/
FAILURE: https:/
FAILURE: https:/
FAILURE: https:/
FAILURE: https:/
FAILURE: https:/
FAILURE: https:/
FAILURE: https:/
FAILURE: https:/
Click here to trigger a rebuild:
https:/
- 2535. By Launchpad Translations on behalf of unity-team
-
Launchpad automatic translations update.
- 2536. By Launchpad Translations on behalf of unity-team
-
Launchpad automatic translations update.
- 2537. By Josh Arenson <josh@blackbox> --author=Josh Arenson <email address hidden>
-
Add unity8-greeter package which contains a basic, but usable LightDM greeter. (LP: #1324602)
- 2538. By Josh Arenson
-
Add a SessionsModel to lightdm to support the greeter's session chooser
- 2539. By Michael Terry
-
Make sure indicators and launcher hide when power button is pressed on greeter. (LP: #1595569)
- 2540. By Michael Terry
-
Fix tablet greeter focus to be always-on, no longer hiding the OSK or forcing a mouse click to type a password.
I've also squeezed some other small fixes in:
- Support Up and Down keys in user list.
- Don't accept non-digit characters when prompting for passcode (we ask OSK to show only digits, but due to bug 1586435, it shows other characters too; plus if the user has an external keyboard, they can type anything anyway).
- When prompting for a passcode in wide-view (tablet/desktop), stop at 4 digits just like we do in narrow-view.
- Don't show "Retry" during brief period before a prompt comes in from PAM.
- Don't let user drag user list if there's only one entry.Now as for the focus changes...
One of the big reasons we lost keyboard focus before was because we set the shell to disabled whenever the greeter was "between PAM events" -- mostly so that the user can't swipe away greeter before we get our first prompt or are otherwise unsure about exactly what authentication is needed.
But disabled qml items can't be focused. So I've rejiggered things a bit. Instead of disabling the whole shell, I just disable the launcher, the indicators, and make the greeter non-swipeable.
I also do some tricks with the prompt so that it looks disabled (while we check with PAM about the password) but isn't actually. I don't want to make it look to the user that pressing backspace while they wait for PAM does anything, so after the user presses Enter, I present a fake label on top of the prompt that looks like a disabled prompt, while simultaneously hiding the prompt contents. (LP: #1435923)
- 2541. By CI Train Bot Account
-
Releasing 8.12+16.
10.20160711- 0ubuntu1 - 2542. By Launchpad Translations on behalf of unity-team
-
Launchpad automatic translations update.
- 2543. By CI Train Bot Account
-
Make use of MirSurface:
:inputBounds and drop UbuntuKeyboardInfo hack - 2544. By CI Train Bot Account
-
Releasing 8.13+16.
10.20160714- 0ubuntu1 - 2545. By CI Train Bot Account
-
Resync trunk.
- 2546. By Launchpad Translations on behalf of unity-team
-
Launchpad automatic translations update.
- 2547. By Launchpad Translations on behalf of unity-team
-
Launchpad automatic translations update.
- 2548. By Timo Jyrinki
-
* Rebuild against Qt 5.6.
* Add https://code.launchpad .net/~aacid/ unity8/ floor_includes/ +merge/ 300850 - 2549. By CI Train Bot Account
-
Bump the version to secure UITK compatibility
- 2550. By Albert Astals Cid
-
Pass the correct number of arguments to mapToItem
One argument used to work in Qt 5.4 and 5.5 but it is not documented and seems to have broken on Qt 5.6 so just update to the correct signature (LP: #1606835)
Approved by: Michael Zanetti
- 2551. By CI Train Bot Account
-
Releasing 8.14+16.
10.20160728- 0ubuntu1 - 2552. By Launchpad Translations on behalf of unity-team
-
Launchpad automatic translations update.
- 2553. By Michael Terry
-
Connect our mock AccountsService background files with our mock liblightdm background files
- 2554. By Michael Terry
-
Fix deb build
- 2555. By Michael Terry
-
Fix usersmodel test
- 2556. By Michael Terry
-
Merge greeter-apps
- 2557. By Michael Terry
-
Merge greeter-apps
- 2558. By Michael Terry
-
Just always link to mock liblightdm, especially now that our mock AS module needs it
- 2559. By Michael Terry
-
Don't set mock backgrounds if none exist
- 2560. By Michael Terry
-
Merge greeter-apps
- 2561. By Michael Terry
-
Add an indicator to the greeter when a user is logged in (only shown if we have more than one user)
- 2562. By Michael Terry
-
Hide the greeter OSK if indicators are open and don't show the edge tutorial during an emergency call.
- 2563. By Michael Terry
-
Switch from lockscreen PIN pad to a passcode entry box that uses the OSK.
- 2564. By Michael Terry
-
Use the default system wallpaper instead of our custom one.
- 2565. By Michael Terry
-
Remove old backgrounds
- 2566. By Michael Terry
-
add missing test image; re-use QImageReaders more; fix test
- 2567. By Michael Terry
-
Fix test I broke in a merge
- 2568. By Michael Terry
-
Fix a couple shell tests
- 2569. By Michael Terry
-
More tweaks
- 2570. By Michael Terry
-
Whoops, don't break support for color backgrounds
- 2571. By Michael Terry
-
Merge greeter-
no-lockscreen
Unmerged revisions
Preview Diff
1 | === modified file 'build.sh' |
2 | --- build.sh 2016-06-06 15:58:24 +0000 |
3 | +++ build.sh 2016-07-05 15:13:35 +0000 |
4 | @@ -55,6 +55,7 @@ |
5 | qml-module-ubuntu-connectivity \ |
6 | ubuntu-mobile-icons \ |
7 | ubuntu-system-settings \ |
8 | + ubuntu-wallpapers \ |
9 | unity-plugin-scopes \ |
10 | xvfb \ |
11 | || exit 5 |
12 | |
13 | === modified file 'debian/control' |
14 | --- debian/control 2016-06-27 18:44:35 +0000 |
15 | +++ debian/control 2016-07-05 15:13:35 +0000 |
16 | @@ -138,6 +138,7 @@ |
17 | qtdeclarative5-ubuntu-settings-components (>= 0.7), |
18 | qtdeclarative5-unity-notifications-plugin (>= 0.1.2) | unity-notifications-impl, |
19 | ubuntu-thumbnailer-impl-0, |
20 | + ubuntu-wallpapers, |
21 | unity-application-impl-17, |
22 | unity-notifications-impl-3, |
23 | unity-plugin-scopes | unity-scopes-impl, |
24 | |
25 | === modified file 'qml/Components/Lockscreen.qml' |
26 | --- qml/Components/Lockscreen.qml 2016-05-26 20:59:30 +0000 |
27 | +++ qml/Components/Lockscreen.qml 2016-07-05 15:13:35 +0000 |
28 | @@ -107,17 +107,13 @@ |
29 | visible: root.background.toString() !== "" |
30 | } |
31 | |
32 | - Image { |
33 | + Wallpaper { |
34 | id: backgroundImage |
35 | objectName: "lockscreenBackground" |
36 | anchors { |
37 | fill: parent |
38 | } |
39 | - // Limit how much memory we'll reserve for this image |
40 | - sourceSize.height: height |
41 | - sourceSize.width: width |
42 | source: root.required ? root.background : "" |
43 | - fillMode: Image.PreserveAspectCrop |
44 | } |
45 | |
46 | // This is to |
47 | |
48 | === added file 'qml/Components/Wallpaper.qml' |
49 | --- qml/Components/Wallpaper.qml 1970-01-01 00:00:00 +0000 |
50 | +++ qml/Components/Wallpaper.qml 2016-07-05 15:13:35 +0000 |
51 | @@ -0,0 +1,45 @@ |
52 | +/* |
53 | + * Copyright (C) 2013-2016 Canonical, Ltd. |
54 | + * |
55 | + * This program is free software; you can redistribute it and/or modify |
56 | + * it under the terms of the GNU General Public License as published by |
57 | + * the Free Software Foundation; version 3. |
58 | + * |
59 | + * This program is distributed in the hope that it will be useful, |
60 | + * but WITHOUT ANY WARRANTY; without even the implied warranty of |
61 | + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the |
62 | + * GNU General Public License for more details. |
63 | + * |
64 | + * You should have received a copy of the GNU General Public License |
65 | + * along with this program. If not, see <http://www.gnu.org/licenses/>. |
66 | + */ |
67 | + |
68 | +import QtQuick 2.4 |
69 | +import QtQuick.Window 2.2 |
70 | +import Ubuntu.Components 1.3 |
71 | + |
72 | +Item { |
73 | + id: root |
74 | + property url source |
75 | + |
76 | + CrossFadeImage { |
77 | + anchors.fill: parent |
78 | + fillMode: Image.PreserveAspectCrop |
79 | + |
80 | + // Limit how much memory we reserve and avoid reloading when item size |
81 | + // changes or is rotated by specifying sourceSize. |
82 | + // |
83 | + // FIXME: If the source image has a portrait aspect ratio, we should swap |
84 | + // sourceSize.width and sourceSize.height to prevent blurriness from double |
85 | + // scaling. We could easily do that with a tiny image loader to check |
86 | + // the aspect ratio first, but when we change sourceSize, we lose all |
87 | + // the benefits of CrossFadeImage. So we need to fix that component |
88 | + // first to gracefully handle sourceSize changes (LP: #1599203). |
89 | + readonly property int maxSize: Math.max(Screen.width, Screen.height) |
90 | + sourceSize.width: 0 |
91 | + sourceSize.height: maxSize |
92 | + |
93 | + // TODO: fix blurriness when using thumbnailer urls |
94 | + source: root.source |
95 | + } |
96 | +} |
97 | |
98 | === modified file 'qml/Components/WallpaperResolver.qml' |
99 | --- qml/Components/WallpaperResolver.qml 2016-05-18 13:38:27 +0000 |
100 | +++ qml/Components/WallpaperResolver.qml 2016-07-05 15:13:35 +0000 |
101 | @@ -15,49 +15,35 @@ |
102 | */ |
103 | |
104 | import QtQuick 2.4 |
105 | -import AccountsService 0.1 |
106 | -import GSettings 1.0 |
107 | import Ubuntu.Components 1.3 |
108 | |
109 | -/* |
110 | - Defines the background URL based on several factors, such as: |
111 | - - default, fallback, background |
112 | - - Background set in AccountSettings, if any |
113 | - - Background set in GSettings, if any |
114 | - */ |
115 | -QtObject { |
116 | - // Users should set their UI width here. |
117 | - property real width |
118 | - |
119 | - property url defaultBackground: Qt.resolvedUrl(width >= units.gu(60) ? "../graphics/tablet_background.jpg" |
120 | - : "../graphics/phone_background.jpg") |
121 | - |
122 | - // That's the property users of this component are going to consume. |
123 | - readonly property url background: asImageTester.status == Image.Ready ? asImageTester.source |
124 | - : gsImageTester.status == Image.Ready ? gsImageTester.source : defaultBackground |
125 | - |
126 | - // This is a dummy image to detect if the custom AS set wallpaper loads successfully. |
127 | - property var _asImageTester: Image { |
128 | - id: asImageTester |
129 | - source: AccountsService.backgroundFile != undefined && AccountsService.backgroundFile.length > 0 ? AccountsService.backgroundFile : "" |
130 | - height: 0 |
131 | - width: 0 |
132 | - sourceSize.height: 0 |
133 | - sourceSize.width: 0 |
134 | - } |
135 | - |
136 | - // This is a dummy image to detect if the custom GSettings set wallpaper loads successfully. |
137 | - property var _gsImageTester: Image { |
138 | - id: gsImageTester |
139 | - source: backgroundSettings.pictureUri && backgroundSettings.pictureUri.length > 0 ? backgroundSettings.pictureUri : "" |
140 | - height: 0 |
141 | - width: 0 |
142 | - sourceSize.height: 0 |
143 | - sourceSize.width: 0 |
144 | - } |
145 | - |
146 | - property var _gsettings: GSettings { |
147 | - id: backgroundSettings |
148 | - schema.id: "org.gnome.desktop.background" |
149 | +Item { |
150 | + id: root |
151 | + |
152 | + // Provide a list of wallpapers to resolve here, preferred ones first |
153 | + property var candidates: [] |
154 | + |
155 | + readonly property url background: { |
156 | + for (var i = 0; i < repeater.count; i++) { |
157 | + if (repeater.itemAt(i).status === Image.Ready) |
158 | + return candidates[i]; |
159 | + } |
160 | + if (i > 0) { |
161 | + return candidates[i - 1]; // last item is last resort |
162 | + } else { |
163 | + return ""; |
164 | + } |
165 | + } |
166 | + |
167 | + Repeater { |
168 | + id: repeater |
169 | + model: root.candidates |
170 | + delegate: Image { |
171 | + source: modelData |
172 | + height: 0 |
173 | + width: 0 |
174 | + sourceSize.height: 0 |
175 | + sourceSize.width: 0 |
176 | + } |
177 | } |
178 | } |
179 | |
180 | === modified file 'qml/Dash/DashBackground.qml' |
181 | --- qml/Dash/DashBackground.qml 2015-12-18 09:05:24 +0000 |
182 | +++ qml/Dash/DashBackground.qml 2016-07-05 15:13:35 +0000 |
183 | @@ -15,16 +15,21 @@ |
184 | */ |
185 | |
186 | import QtQuick 2.4 |
187 | -import QtQuick.Window 2.2 |
188 | import Ubuntu.Thumbnailer 0.1 |
189 | - |
190 | -Image { |
191 | - source: "image://thumbnailer/" + Qt.resolvedUrl("graphics/paper.png") |
192 | - fillMode: Image.PreserveAspectCrop |
193 | - horizontalAlignment: Image.AlignRight |
194 | - verticalAlignment: Image.AlignTop |
195 | - // avoid CPU scaling when window size changes |
196 | - readonly property int maxSize: Math.max(Screen.width, Screen.height) |
197 | - sourceSize.width: maxSize |
198 | - sourceSize.height: 0 |
199 | +import "../Components" |
200 | + |
201 | +Wallpaper { |
202 | + source: "image://thumbnailer/" + resolver.background |
203 | + |
204 | + WallpaperResolver { |
205 | + id: resolver |
206 | + |
207 | + // FIXME: https://launchpad.net/bugs/1592870 asks for a sane, stable name |
208 | + // for the default paper background. But for now, here we are. |
209 | + candidates: [ |
210 | + // These are provided by the ubuntu-wallpapers package. |
211 | + "file:///usr/share/backgrounds/Xerus_Wallpaper_Grey_4096x2304.png", // xenial |
212 | + "file:///usr/share/backgrounds/Suru_Wallpaper_Desktop_4096x2304_Gray.png" // vivid |
213 | + ] |
214 | + } |
215 | } |
216 | |
217 | === removed file 'qml/Dash/graphics/paper.png' |
218 | Binary files qml/Dash/graphics/paper.png 2016-06-03 23:00:28 +0000 and qml/Dash/graphics/paper.png 1970-01-01 00:00:00 +0000 differ |
219 | === modified file 'qml/Greeter/CoverPage.qml' |
220 | --- qml/Greeter/CoverPage.qml 2016-06-18 22:37:48 +0000 |
221 | +++ qml/Greeter/CoverPage.qml 2016-07-05 15:13:35 +0000 |
222 | @@ -25,6 +25,7 @@ |
223 | property real dragHandleLeftMargin |
224 | property real launcherOffset |
225 | property alias background: greeterBackground.source |
226 | + property alias hasCustomBackground: backgroundShade.visible |
227 | property real backgroundTopMargin |
228 | property var infographicModel |
229 | property bool draggable: true |
230 | @@ -82,24 +83,23 @@ |
231 | color: "black" |
232 | } |
233 | |
234 | - CrossFadeImage { |
235 | + Wallpaper { |
236 | id: greeterBackground |
237 | objectName: "greeterBackground" |
238 | anchors { |
239 | fill: parent |
240 | topMargin: root.backgroundTopMargin |
241 | } |
242 | - fillMode: Image.PreserveAspectCrop |
243 | - // Limit how much memory we'll reserve for this image |
244 | - sourceSize.height: height |
245 | - sourceSize.width: width |
246 | } |
247 | |
248 | // Darkens wallpaper so that we can read text on it and see infographic |
249 | Rectangle { |
250 | + id: backgroundShade |
251 | + objectName: "backgroundShade" |
252 | anchors.fill: parent |
253 | color: "black" |
254 | opacity: 0.4 |
255 | + visible: false |
256 | } |
257 | |
258 | Infographics { |
259 | |
260 | === modified file 'qml/Greeter/Greeter.qml' |
261 | --- qml/Greeter/Greeter.qml 2016-06-27 18:44:00 +0000 |
262 | +++ qml/Greeter/Greeter.qml 2016-07-05 15:13:35 +0000 |
263 | @@ -32,6 +32,7 @@ |
264 | property real dragHandleLeftMargin: 0 |
265 | |
266 | property url background |
267 | + property bool hasCustomBackground |
268 | |
269 | // How far to offset the top greeter layer during a launcher left-drag |
270 | property real launcherOffset |
271 | @@ -366,6 +367,12 @@ |
272 | |
273 | Binding { |
274 | target: loader.item |
275 | + property: "hasCustomBackground" |
276 | + value: root.hasCustomBackground |
277 | + } |
278 | + |
279 | + Binding { |
280 | + target: loader.item |
281 | property: "locked" |
282 | value: root.locked |
283 | } |
284 | |
285 | === modified file 'qml/Greeter/NarrowView.qml' |
286 | --- qml/Greeter/NarrowView.qml 2016-06-20 20:23:28 +0000 |
287 | +++ qml/Greeter/NarrowView.qml 2016-07-05 15:13:35 +0000 |
288 | @@ -27,6 +27,7 @@ |
289 | property alias delayMinutes: lockscreen.delayMinutes |
290 | property alias backgroundTopMargin: coverPage.backgroundTopMargin |
291 | property url background |
292 | + property bool hasCustomBackground |
293 | property bool locked |
294 | property bool alphanumeric |
295 | property var userModel // unused |
296 | @@ -120,7 +121,7 @@ |
297 | visible: required |
298 | enabled: !coverPage.shown |
299 | background: root.background |
300 | - darkenBackground: 0.4 |
301 | + darkenBackground: root.hasCustomBackground ? 0.4 : 0 |
302 | alphaNumeric: root.alphanumeric |
303 | minPinLength: 4 |
304 | maxPinLength: 4 |
305 | @@ -172,6 +173,7 @@ |
306 | height: parent.height |
307 | width: parent.width |
308 | background: root.background |
309 | + hasCustomBackground: root.hasCustomBackground |
310 | onTease: root.tease() |
311 | onClicked: hide() |
312 | |
313 | |
314 | === modified file 'qml/Greeter/WideView.qml' |
315 | --- qml/Greeter/WideView.qml 2016-06-18 22:37:48 +0000 |
316 | +++ qml/Greeter/WideView.qml 2016-07-05 15:13:35 +0000 |
317 | @@ -26,6 +26,7 @@ |
318 | property int delayMinutes // TODO |
319 | property alias backgroundTopMargin: coverPage.backgroundTopMargin |
320 | property alias background: coverPage.background |
321 | + property alias hasCustomBackground: coverPage.hasCustomBackground |
322 | property bool locked |
323 | property alias alphanumeric: loginList.alphanumeric |
324 | property alias userModel: loginList.model |
325 | |
326 | === modified file 'qml/Shell.qml' |
327 | --- qml/Shell.qml 2016-06-20 16:25:15 +0000 |
328 | +++ qml/Shell.qml 2016-07-05 15:13:35 +0000 |
329 | @@ -145,7 +145,21 @@ |
330 | |
331 | WallpaperResolver { |
332 | id: wallpaperResolver |
333 | - width: shell.width |
334 | + objectName: "wallpaperResolver" |
335 | + |
336 | + readonly property url defaultBackground: "file:///usr/share/backgrounds/warty-final-ubuntu.png" |
337 | + readonly property bool hasCustomBackground: background != defaultBackground |
338 | + |
339 | + GSettings { |
340 | + id: backgroundSettings |
341 | + schema.id: "org.gnome.desktop.background" |
342 | + } |
343 | + |
344 | + candidates: [ |
345 | + AccountsService.backgroundFile, |
346 | + backgroundSettings.pictureUri, |
347 | + defaultBackground |
348 | + ] |
349 | } |
350 | |
351 | readonly property alias greeter: greeterLoader.item |
352 | @@ -421,6 +435,7 @@ |
353 | launcherOffset: launcher.progress |
354 | forcedUnlock: wizard.active || shell.mode === "full-shell" |
355 | background: wallpaperResolver.background |
356 | + hasCustomBackground: wallpaperResolver.hasCustomBackground |
357 | allowFingerprint: !dialogs.hasActiveDialog && |
358 | !notifications.topmostIsFullscreen && |
359 | !panel.indicators.shown |
360 | |
361 | === modified file 'qml/Stages/DesktopStage.qml' |
362 | --- qml/Stages/DesktopStage.qml 2016-06-27 18:44:07 +0000 |
363 | +++ qml/Stages/DesktopStage.qml 2016-07-05 15:13:35 +0000 |
364 | @@ -238,12 +238,10 @@ |
365 | anchors.fill: parent |
366 | focus: spread.state !== "altTab" |
367 | |
368 | - CrossFadeImage { |
369 | + Wallpaper { |
370 | id: wallpaper |
371 | anchors.fill: parent |
372 | source: root.background |
373 | - sourceSize { height: root.height; width: root.width } |
374 | - fillMode: Image.PreserveAspectCrop |
375 | } |
376 | |
377 | TopLevelSurfaceRepeater { |
378 | |
379 | === removed file 'qml/graphics/phone_background.jpg' |
380 | Binary files qml/graphics/phone_background.jpg 2015-07-16 15:48:32 +0000 and qml/graphics/phone_background.jpg 1970-01-01 00:00:00 +0000 differ |
381 | === removed file 'qml/graphics/tablet_background.jpg' |
382 | Binary files qml/graphics/tablet_background.jpg 2014-04-14 15:49:40 +0000 and qml/graphics/tablet_background.jpg 1970-01-01 00:00:00 +0000 differ |
383 | === modified file 'tests/mocks/AccountsService/AccountsService.cpp' |
384 | --- tests/mocks/AccountsService/AccountsService.cpp 2016-06-20 15:24:27 +0000 |
385 | +++ tests/mocks/AccountsService/AccountsService.cpp 2016-07-05 15:13:35 +0000 |
386 | @@ -23,7 +23,7 @@ |
387 | m_enableFingerprintIdentification(true), |
388 | m_enableLauncherWhileLocked(true), |
389 | m_enableIndicatorsWhileLocked(true), |
390 | - m_backgroundFile(qmlDirectory() + "/graphics/phone_background.jpg"), |
391 | + m_backgroundFile(""), |
392 | m_statsWelcomeScreen(true), |
393 | m_failedLogins(0), |
394 | m_failedFingerprintLogins(0), |
395 | |
396 | === modified file 'tests/qmltests/Components/tst_Lockscreen.qml' |
397 | --- tests/qmltests/Components/tst_Lockscreen.qml 2016-05-26 20:59:30 +0000 |
398 | +++ tests/qmltests/Components/tst_Lockscreen.qml 2016-07-05 15:13:35 +0000 |
399 | @@ -38,7 +38,7 @@ |
400 | minPinLength: minPinLengthTextField.text |
401 | maxPinLength: maxPinLengthTextField.text |
402 | delayMinutes: delayMinutesTextField.text |
403 | - background: "../../../qml/graphics/phone_background.jpg" |
404 | + background: "/usr/share/backgrounds/warty-final-ubuntu.png" |
405 | } |
406 | |
407 | Connections { |
408 | |
409 | === modified file 'tests/qmltests/Components/tst_WallpaperResolver.qml' |
410 | --- tests/qmltests/Components/tst_WallpaperResolver.qml 2015-10-20 08:10:03 +0000 |
411 | +++ tests/qmltests/Components/tst_WallpaperResolver.qml 2016-07-05 15:13:35 +0000 |
412 | @@ -18,8 +18,6 @@ |
413 | import QtTest 1.0 |
414 | import Ubuntu.Components 1.3 |
415 | import Unity.Test 0.1 |
416 | -import AccountsService 0.1 |
417 | -import GSettings 1.0 |
418 | |
419 | import "../../../qml/Components" |
420 | |
421 | @@ -32,7 +30,6 @@ |
422 | |
423 | WallpaperResolver { |
424 | id: wallpaperResolver |
425 | - width: units.gu(70) |
426 | } |
427 | |
428 | UnityTestCase { |
429 | @@ -42,48 +39,37 @@ |
430 | |
431 | function test_background_data() { |
432 | return [ |
433 | - {tag: "color", |
434 | - accounts: Qt.resolvedUrl("data:image/svg+xml,<svg><rect width='100%' height='100%' fill='#dd4814'/></svg>"), |
435 | - gsettings: "", |
436 | - output: Qt.resolvedUrl("data:image/svg+xml,<svg><rect width='100%' height='100%' fill='#dd4814'/></svg>")}, |
437 | - |
438 | - {tag: "empty", accounts: "", gsettings: "", output: "defaultBackground"}, |
439 | - |
440 | - {tag: "as-specified", |
441 | - accounts: Qt.resolvedUrl("../../data/unity/backgrounds/blue.png"), |
442 | - gsettings: "", |
443 | - output: Qt.resolvedUrl("../../data/unity/backgrounds/blue.png")}, |
444 | - |
445 | - {tag: "gs-specified", |
446 | - accounts: "", |
447 | - gsettings: Qt.resolvedUrl("../../data/unity/backgrounds/red.png"), |
448 | - output: Qt.resolvedUrl("../../data/unity/backgrounds/red.png")}, |
449 | - |
450 | - {tag: "both-specified", |
451 | - accounts: Qt.resolvedUrl("../../data/unity/backgrounds/blue.png"), |
452 | - gsettings: Qt.resolvedUrl("../../data/unity/backgrounds/red.png"), |
453 | - output: Qt.resolvedUrl("../../data/unity/backgrounds/blue.png")}, |
454 | - |
455 | - {tag: "invalid-as", |
456 | - accounts: Qt.resolvedUrl("../../data/unity/backgrounds/nope.png"), |
457 | - gsettings: Qt.resolvedUrl("../../data/unity/backgrounds/red.png"), |
458 | - output: Qt.resolvedUrl("../../data/unity/backgrounds/red.png")}, |
459 | - |
460 | - {tag: "invalid-both", |
461 | - accounts: Qt.resolvedUrl("../../data/unity/backgrounds/nope.png"), |
462 | - gsettings: Qt.resolvedUrl("../../data/unity/backgrounds/stillnope.png"), |
463 | - output: "defaultBackground"}, |
464 | + {tag: "none-valid", |
465 | + list: ["/first", "/middle", "/last"], |
466 | + output: "file:///last"}, |
467 | + |
468 | + {tag: "first-valid", |
469 | + list: [Qt.resolvedUrl("../../data/unity/backgrounds/blue.png"), |
470 | + "/middle", "/last"], |
471 | + output: Qt.resolvedUrl("../../data/unity/backgrounds/blue.png")}, |
472 | + |
473 | + {tag: "middle-valid", |
474 | + list: ["/first", |
475 | + Qt.resolvedUrl("../../data/unity/backgrounds/red.png"), |
476 | + "/last"], |
477 | + output: Qt.resolvedUrl("../../data/unity/backgrounds/red.png")}, |
478 | + |
479 | + {tag: "last-valid", |
480 | + list: ["/first", |
481 | + "/middle", |
482 | + Qt.resolvedUrl("../../data/unity/backgrounds/red.png")], |
483 | + output: Qt.resolvedUrl("../../data/unity/backgrounds/red.png")}, |
484 | + |
485 | + {tag: "multiple-valid", |
486 | + list: [Qt.resolvedUrl("../../data/unity/backgrounds/blue.png"), |
487 | + Qt.resolvedUrl("../../data/unity/backgrounds/red.png")], |
488 | + output: Qt.resolvedUrl("../../data/unity/backgrounds/blue.png")}, |
489 | ] |
490 | } |
491 | + |
492 | function test_background(data) { |
493 | - AccountsService.backgroundFile = data.accounts; |
494 | - GSettingsController.setPictureUri(data.gsettings); |
495 | - |
496 | - if (data.output === "defaultBackground") { |
497 | - tryCompare(wallpaperResolver, "background", wallpaperResolver.defaultBackground); |
498 | - } else { |
499 | - tryCompare(wallpaperResolver, "background", data.output); |
500 | - } |
501 | + wallpaperResolver.candidates = data.list; |
502 | + tryCompare(wallpaperResolver, "background", data.output); |
503 | } |
504 | } |
505 | } |
506 | |
507 | === modified file 'tests/qmltests/Components/tst_ZoomableImage.qml' |
508 | --- tests/qmltests/Components/tst_ZoomableImage.qml 2016-01-22 23:40:25 +0000 |
509 | +++ tests/qmltests/Components/tst_ZoomableImage.qml 2016-07-05 15:13:35 +0000 |
510 | @@ -31,7 +31,7 @@ |
511 | } |
512 | |
513 | property var widgetData1: { |
514 | - "source": "../../../qml/graphics/phone_background.jpg", |
515 | + "source": "../../../tests/graphics/avatars/amanda@12.png", |
516 | "zoomable": false |
517 | } |
518 | |
519 | |
520 | === modified file 'tests/qmltests/Dash/Previews/tst_PreviewExpandable.qml' |
521 | --- tests/qmltests/Dash/Previews/tst_PreviewExpandable.qml 2016-05-11 14:26:08 +0000 |
522 | +++ tests/qmltests/Dash/Previews/tst_PreviewExpandable.qml 2016-07-05 15:13:35 +0000 |
523 | @@ -54,8 +54,8 @@ |
524 | |
525 | property var galleryData: { |
526 | "sources": [ |
527 | - "../../graphics/phone_background.jpg", |
528 | - "../../graphics/tablet_background.jpg", |
529 | + "../../../tests/graphics/avatars/amanda@12.png", |
530 | + "../../../tests/graphics/avatars/funky@12.png", |
531 | "../../../tests/graphics/clock@18.png", |
532 | "../../graphics/borked" |
533 | ] |
534 | @@ -71,7 +71,7 @@ |
535 | } |
536 | |
537 | property var imageData: { |
538 | - "source": "../../graphics/phone_background.jpg", |
539 | + "source": "../../../tests/graphics/avatars/amanda@12.png", |
540 | "zoomable": false |
541 | } |
542 | |
543 | |
544 | === modified file 'tests/qmltests/Dash/Previews/tst_PreviewImageGallery.qml' |
545 | --- tests/qmltests/Dash/Previews/tst_PreviewImageGallery.qml 2016-04-13 08:16:05 +0000 |
546 | +++ tests/qmltests/Dash/Previews/tst_PreviewImageGallery.qml 2016-07-05 15:13:35 +0000 |
547 | @@ -31,8 +31,8 @@ |
548 | |
549 | property var sourcesModel1: { |
550 | "sources": [ |
551 | - "../../graphics/phone_background.jpg", |
552 | - "../../graphics/tablet_background.jpg", |
553 | + "../../../tests/graphics/avatars/amanda@12.png", |
554 | + "../../../tests/graphics/avatars/funky@12.png", |
555 | "../../../tests/graphics/clock@18.png", |
556 | "../../graphics/borked" |
557 | ] |
558 | @@ -40,8 +40,8 @@ |
559 | |
560 | property var sourcesModel1WithFallback: { |
561 | "sources": [ |
562 | - "../../graphics/phone_background.jpg", |
563 | - "../../graphics/tablet_background.jpg", |
564 | + "../../../tests/graphics/avatars/amanda@12.png", |
565 | + "../../../tests/graphics/avatars/funky@12.png", |
566 | "../../../tests/graphics/clock@18.png", |
567 | "../../graphics/borked" |
568 | ] |
569 | @@ -50,8 +50,8 @@ |
570 | |
571 | property var sourcesModelEmptyWithFallback: { |
572 | "sources": [ |
573 | - "../../graphics/phone_background.jpg", |
574 | - "../../graphics/tablet_background.jpg", |
575 | + "../../../tests/graphics/avatars/amanda@12.png", |
576 | + "../../../tests/graphics/avatars/funky@12.png", |
577 | "../../../tests/graphics/clock@18.png", |
578 | "" |
579 | ] |
580 | |
581 | === modified file 'tests/qmltests/Dash/Previews/tst_PreviewZoomableImage.qml' |
582 | --- tests/qmltests/Dash/Previews/tst_PreviewZoomableImage.qml 2016-04-04 09:01:45 +0000 |
583 | +++ tests/qmltests/Dash/Previews/tst_PreviewZoomableImage.qml 2016-07-05 15:13:35 +0000 |
584 | @@ -26,7 +26,7 @@ |
585 | color: "lightgrey" |
586 | |
587 | property var widgetData0: { |
588 | - "source": "../../graphics/phone_background.jpg", |
589 | + "source": "../../../tests/graphics/avatars/amanda@12.png", |
590 | "zoomable": false |
591 | } |
592 | |
593 | @@ -36,17 +36,17 @@ |
594 | |
595 | property var widgetData2: { |
596 | "source": "fadsasf", |
597 | - "fallback": "../../graphics/phone_background.jpg" |
598 | + "fallback": "../../../tests/graphics/avatars/amanda@12.png" |
599 | } |
600 | |
601 | property var widgetData3: { |
602 | "source": "", |
603 | - "fallback": "../../graphics/phone_background.jpg" |
604 | + "fallback": "../../../tests/graphics/avatars/amanda@12.png" |
605 | } |
606 | |
607 | property var widgetData4: { |
608 | "source": "fadsasf", |
609 | - "fallback": "../../graphics/phone_background.jpg" |
610 | + "fallback": "../../../tests/graphics/avatars/amanda@12.png" |
611 | } |
612 | |
613 | Loader { |
614 | @@ -123,11 +123,11 @@ |
615 | waitForRendering(zoomableImage); |
616 | waitForRendering(lazyImage); |
617 | tryCompare(lazyImage, "state", "ready"); |
618 | - verify(lazyImage.sourceImage.source.toString().indexOf("phone_background") > -1); |
619 | - zoomableImage.widgetData["source"] = "../../graphics/tablet_background.jpg" |
620 | + verify(lazyImage.sourceImage.source.toString().indexOf("amanda") > -1); |
621 | + zoomableImage.widgetData["source"] = "../../../tests/graphics/avatars/funky@12.png" |
622 | zoomableImage.widgetDataChanged(); |
623 | tryCompare(lazyImage, "state", "ready"); |
624 | - verify(lazyImage.sourceImage.source.toString().indexOf("tablet_background") > -1); |
625 | + verify(lazyImage.sourceImage.source.toString().indexOf("funky") > -1); |
626 | } |
627 | } |
628 | } |
629 | |
630 | === modified file 'tests/qmltests/Greeter/TestView.qml' |
631 | --- tests/qmltests/Greeter/TestView.qml 2016-05-25 19:25:51 +0000 |
632 | +++ tests/qmltests/Greeter/TestView.qml 2016-07-05 15:13:35 +0000 |
633 | @@ -27,6 +27,7 @@ |
634 | property int delayMinutes |
635 | property real backgroundTopMargin |
636 | property url background |
637 | + property bool hasCustomBackground |
638 | property bool locked |
639 | property bool alphanumeric |
640 | property var userModel |
641 | |
642 | === modified file 'tests/qmltests/Greeter/tst_Greeter.qml' |
643 | --- tests/qmltests/Greeter/tst_Greeter.qml 2016-06-20 17:37:25 +0000 |
644 | +++ tests/qmltests/Greeter/tst_Greeter.qml 2016-07-05 15:13:35 +0000 |
645 | @@ -29,7 +29,7 @@ |
646 | width: units.gu(120) |
647 | height: units.gu(80) |
648 | |
649 | - property url defaultBackground: Qt.resolvedUrl("../../../qml/graphics/tablet_background.jpg") |
650 | + property url defaultBackground: "/usr/share/backgrounds/warty-final-ubuntu.png" |
651 | |
652 | Component.onCompleted: { |
653 | // set the mock mode before loading |
654 | @@ -379,6 +379,12 @@ |
655 | compare(view.background, Qt.resolvedUrl("testing")); |
656 | } |
657 | |
658 | + function test_hasCustomBackground() { |
659 | + verify(!view.hasCustomBackground); |
660 | + greeter.hasCustomBackground = true; |
661 | + verify(view.hasCustomBackground); |
662 | + } |
663 | + |
664 | function test_notifyAboutToFocusApp() { |
665 | greeter.notifyUserRequestedApp("fake-app"); |
666 | compare(viewTryToUnlockSpy.count, 1); |
667 | |
668 | === modified file 'tests/qmltests/Greeter/tst_NarrowView.qml' |
669 | --- tests/qmltests/Greeter/tst_NarrowView.qml 2016-06-18 22:37:48 +0000 |
670 | +++ tests/qmltests/Greeter/tst_NarrowView.qml 2016-07-05 15:13:35 +0000 |
671 | @@ -39,7 +39,7 @@ |
672 | property bool itemDestroyed: false |
673 | sourceComponent: Component { |
674 | NarrowView { |
675 | - background: Qt.resolvedUrl("../../../qml/graphics/phone_background.jpg") |
676 | + background: "/usr/share/backgrounds/warty-final-ubuntu.png" |
677 | userModel: LightDM.Users |
678 | infographicModel: LightDM.Infographic |
679 | |
680 | @@ -350,6 +350,19 @@ |
681 | compare(teaseSpy.count, data.count); |
682 | } |
683 | |
684 | + function test_customBackground() { |
685 | + var lockscreen = findChild(view, "lockscreen"); |
686 | + var coverPage = findChild(view, "coverPage"); |
687 | + var backgroundShade = findChild(coverPage, "backgroundShade"); |
688 | + |
689 | + compare(lockscreen.darkenBackground, 0); |
690 | + verify(!backgroundShade.visible); |
691 | + |
692 | + view.hasCustomBackground = true; |
693 | + compare(lockscreen.darkenBackground, 0.4); |
694 | + verify(backgroundShade.visible); |
695 | + } |
696 | + |
697 | function test_respondedWithPin() { |
698 | view.locked = true; |
699 | swipeAwayCover(); |
700 | |
701 | === modified file 'tests/qmltests/Greeter/tst_WideView.qml' |
702 | --- tests/qmltests/Greeter/tst_WideView.qml 2016-06-18 22:37:48 +0000 |
703 | +++ tests/qmltests/Greeter/tst_WideView.qml 2016-07-05 15:13:35 +0000 |
704 | @@ -47,7 +47,7 @@ |
705 | WideView { |
706 | id: view |
707 | |
708 | - background: Qt.resolvedUrl("../../../qml/graphics/tablet_background.jpg") |
709 | + background: "/usr/share/backgrounds/warty-final-ubuntu.png" |
710 | userModel: LightDM.Users |
711 | infographicModel: LightDM.Infographic |
712 | |
713 | @@ -390,6 +390,17 @@ |
714 | compare(view.currentIndex, 0); // confirm we didn't change |
715 | } |
716 | |
717 | + function test_customBackground() { |
718 | + var coverPage = findChild(view, "coverPage"); |
719 | + var backgroundShade = findChild(coverPage, "backgroundShade"); |
720 | + |
721 | + verify(!view.hasCustomBackground); |
722 | + verify(!backgroundShade.visible); |
723 | + |
724 | + view.hasCustomBackground = true; |
725 | + verify(backgroundShade.visible); |
726 | + } |
727 | + |
728 | function test_respondedWithPassword() { |
729 | view.locked = true; |
730 | view.showPrompt("Prompt", true, true); |
731 | |
732 | === modified file 'tests/qmltests/Stages/tst_DesktopStage.qml' |
733 | --- tests/qmltests/Stages/tst_DesktopStage.qml 2016-06-27 18:44:07 +0000 |
734 | +++ tests/qmltests/Stages/tst_DesktopStage.qml 2016-07-05 15:13:35 +0000 |
735 | @@ -75,7 +75,7 @@ |
736 | sourceComponent: Component { |
737 | DesktopStage { |
738 | anchors.fill: parent |
739 | - background: "../../../qml/graphics/tablet_background.jpg" |
740 | + background: "/usr/share/backgrounds/warty-final-ubuntu.png" |
741 | focus: true |
742 | |
743 | Component.onCompleted: { |
744 | |
745 | === modified file 'tests/qmltests/tst_Shell.qml' |
746 | --- tests/qmltests/tst_Shell.qml 2016-06-18 22:37:48 +0000 |
747 | +++ tests/qmltests/tst_Shell.qml 2016-07-05 15:13:35 +0000 |
748 | @@ -536,6 +536,7 @@ |
749 | |
750 | AccountsService.demoEdges = false; |
751 | AccountsService.demoEdgesCompleted = []; |
752 | + AccountsService.backgroundFile = ""; |
753 | Wizard.System.wizardEnabled = false; |
754 | shellLoader.mode = "full-greeter"; |
755 | |
756 | @@ -548,6 +549,7 @@ |
757 | sessionSpy.clear(); |
758 | |
759 | GSettingsController.setLifecycleExemptAppids([]); |
760 | + GSettingsController.setPictureUri(""); |
761 | |
762 | // there should be only unity8-dash window over there |
763 | tryCompare(ApplicationManager, "count", 1); |
764 | @@ -1311,6 +1313,22 @@ |
765 | tryCompare(tutorial, "paused", false); |
766 | } |
767 | |
768 | + |
769 | + function test_customBackground() { |
770 | + loadShell("desktop"); |
771 | + shell.usageScenario = "desktop"; |
772 | + waitForRendering(shell); |
773 | + |
774 | + var wallpaperResolver = findInvisibleChild(shell, "wallpaperResolver"); |
775 | + var greeter = findChild(shell, "greeter"); |
776 | + verify(!greeter.hasCustomBackground); |
777 | + compare(greeter.background, wallpaperResolver.defaultBackground); |
778 | + |
779 | + AccountsService.backgroundFile = Qt.resolvedUrl("../graphics/applicationIcons/dash.png"); |
780 | + tryCompare(greeter, "hasCustomBackground", true); |
781 | + compare(greeter.background, AccountsService.backgroundFile); |
782 | + } |
783 | + |
784 | function test_tapOnRightEdgeReachesApplicationSurface() { |
785 | loadShell("phone"); |
786 | swipeAwayGreeter(); |
787 | @@ -2401,6 +2419,59 @@ |
788 | compare(topmostSurfaceItem.touchReleaseCount, 2); |
789 | } |
790 | |
791 | + function test_background_data() { |
792 | + return [ |
793 | + {tag: "color", |
794 | + accounts: Qt.resolvedUrl("data:image/svg+xml,<svg><rect width='100%' height='100%' fill='#dd4814'/></svg>"), |
795 | + gsettings: "", |
796 | + output: Qt.resolvedUrl("data:image/svg+xml,<svg><rect width='100%' height='100%' fill='#dd4814'/></svg>")}, |
797 | + |
798 | + {tag: "empty", accounts: "", gsettings: "", output: "defaultBackground"}, |
799 | + |
800 | + {tag: "as-specified", |
801 | + accounts: Qt.resolvedUrl("../data/unity/backgrounds/blue.png"), |
802 | + gsettings: "", |
803 | + output: Qt.resolvedUrl("../data/unity/backgrounds/blue.png")}, |
804 | + |
805 | + {tag: "gs-specified", |
806 | + accounts: "", |
807 | + gsettings: Qt.resolvedUrl("../data/unity/backgrounds/red.png"), |
808 | + output: Qt.resolvedUrl("../data/unity/backgrounds/red.png")}, |
809 | + |
810 | + {tag: "both-specified", |
811 | + accounts: Qt.resolvedUrl("../data/unity/backgrounds/blue.png"), |
812 | + gsettings: Qt.resolvedUrl("../data/unity/backgrounds/red.png"), |
813 | + output: Qt.resolvedUrl("../data/unity/backgrounds/blue.png")}, |
814 | + |
815 | + {tag: "invalid-as", |
816 | + accounts: Qt.resolvedUrl("../data/unity/backgrounds/nope.png"), |
817 | + gsettings: Qt.resolvedUrl("../data/unity/backgrounds/red.png"), |
818 | + output: Qt.resolvedUrl("../data/unity/backgrounds/red.png")}, |
819 | + |
820 | + {tag: "invalid-both", |
821 | + accounts: Qt.resolvedUrl("../data/unity/backgrounds/nope.png"), |
822 | + gsettings: Qt.resolvedUrl("../data/unity/backgrounds/stillnope.png"), |
823 | + output: "defaultBackground"}, |
824 | + ] |
825 | + } |
826 | + function test_background(data) { |
827 | + loadShell("phone"); |
828 | + shell.usageScenario = "phone"; |
829 | + waitForRendering(shell); |
830 | + |
831 | + AccountsService.backgroundFile = data.accounts; |
832 | + GSettingsController.setPictureUri(data.gsettings); |
833 | + |
834 | + var wallpaperResolver = findChild(shell, "wallpaperResolver"); |
835 | + if (data.output === "defaultBackground") { |
836 | + tryCompare(wallpaperResolver, "background", wallpaperResolver.defaultBackground); |
837 | + verify(!wallpaperResolver.hasCustomBackground); |
838 | + } else { |
839 | + tryCompare(wallpaperResolver, "background", data.output); |
840 | + verify(wallpaperResolver.hasCustomBackground); |
841 | + } |
842 | + } |
843 | + |
844 | function test_switchKeymap() { |
845 | // start with phone shell |
846 | loadShell("phone"); |
FAILED: Continuous integration, rev:2448 /unity8- jenkins. ubuntu. com/job/ lp-unity8- ci/1508/ /unity8- jenkins. ubuntu. com/job/ build/2011 /unity8- jenkins. ubuntu. com/job/ test-0- autopkgtest/ label=amd64, release= vivid+overlay, testname= qmluitests. sh/1022 /unity8- jenkins. ubuntu. com/job/ test-0- autopkgtest/ label=amd64, release= xenial+ overlay, testname= qmluitests. sh/1022 /unity8- jenkins. ubuntu. com/job/ test-0- autopkgtest/ label=amd64, release= yakkety, testname= qmluitests. sh/1022 /unity8- jenkins. ubuntu. com/job/ build-0- fetch/2039 /unity8- jenkins. ubuntu. com/job/ build-1- sourcepkg/ release= vivid+overlay/ 1956 /unity8- jenkins. ubuntu. com/job/ build-1- sourcepkg/ release= xenial+ overlay/ 1956 /unity8- jenkins. ubuntu. com/job/ build-1- sourcepkg/ release= yakkety/ 1956 /unity8- jenkins. ubuntu. com/job/ build-2- binpkg/ arch=amd64, release= vivid+overlay/ 1947 /unity8- jenkins. ubuntu. com/job/ build-2- binpkg/ arch=amd64, release= vivid+overlay/ 1947/artifact/ output/ *zip*/output. zip /unity8- jenkins. ubuntu. com/job/ build-2- binpkg/ arch=amd64, release= xenial+ overlay/ 1947 /unity8- jenkins. ubuntu. com/job/ build-2- binpkg/ arch=amd64, release= xenial+ overlay/ 1947/artifact/ output/ *zip*/output. zip /unity8- jenkins. ubuntu. com/job/ build-2- binpkg/ arch=amd64, release= yakkety/ 1947 /unity8- jenkins. ubuntu. com/job/ build-2- binpkg/ arch=amd64, release= yakkety/ 1947/artifact/ output/ *zip*/output. zip /unity8- jenkins. ubuntu. com/job/ build-2- binpkg/ arch=armhf, release= vivid+overlay/ 1947 /unity8- jenkins. ubuntu. com/job/ build-2- binpkg/ arch=armhf, release= vivid+overlay/ 1947/artifact/ output/ *zip*/output. zip /unity8- jenkins. ubuntu. com/job/ build-2- binpkg/ arch=armhf, release= xenial+ overlay/ 1947 /unity8- jenkins. ubuntu. com/job/ build-2- binpkg/ arch=armhf, release= xenial+ overlay/ 1947/artifact/ output/ *zip*/output. zip /unity8- jenkins. ubuntu. com/job/ build-2- binpkg/ arch=armhf, release= yakkety/ 1947 /unity8- jenkins. ubuntu. com/job/ build-2- binpkg/ arch=armhf, release= yakkety/ 1947/artifact/ output/ *zip*/output. zip /unity8- jenkins. ubuntu. com/job/ build-2- binpkg/ arch=i386, release= vivid+overlay/ 1947 /unity8- jenkins. ubuntu. com/job/ build-2- binpkg/ arch=i386, release= vivid+overlay/ 1947/artifact/ output/ *zip*/output. zip /unity8- jenkins. ubuntu. com/job/ build-2- binpkg/ arch=i386, release= xenial+ overlay/ 1947 /unity8- jenkins. ubuntu. com/job/ build-2- binpkg/ arch=i386, release= xenial+ overlay/ 1947/artifact/ output/ *zip*/output. zip /unity8- jenkins. ubuntu. com/job/ build-2- binpkg/ arch=i386, release= yakkety/ 1947 /unity8- jenkins. ubuntu. com/job/ build-2- binpkg/ arch=i386, release= yakkety/ 1947/artifact/ output/ *zip*/output. zip
https:/
Executed test runs:
SUCCESS: https:/
UNSTABLE: https:/
UNSTABLE: https:/
UNSTABLE: https:/
SUCCESS: https:/
SUCCESS: https:/
SUCCESS: https:/
SUCCESS: https:/
SUCCESS: https:/
deb: https:/
SUCCESS: https:/
deb: https:/
SUCCESS: https:/
deb: https:/
SUCCESS: https:/
deb: https:/
SUCCESS: https:/
deb: https:/
SUCCESS: https:/
deb: https:/
SUCCESS: https:/
deb: https:/
SUCCESS: https:/
deb: https:/
SUCCESS: https:/
deb: https:/
Click here to trigger a rebuild: /unity8- jenkins. ubuntu. com/job/ lp-unity8- ci/1508/ rebuild
https:/