Image extension fails to notify of source changes
Affects | Status | Importance | Assigned to | Milestone | |
---|---|---|---|---|---|
Canonical System Image |
Fix Released
|
Critical
|
Zoltan Balogh | ||
ubuntu-ui-toolkit (Ubuntu RTM) |
Fix Released
|
Critical
|
Cris Dywan |
Bug Description
When importing Ubuntu.Components, the base Image QML type is enhanced (with the UCQQuickImageEx
This breaks the emission of the sourceChanged signal. Application developers cannot implement the onSourceChanged slot to be notified of changes to the value of the 'source' property, and this isn’t documented anywhere.
Another issue I’m observing with this custom extension is that an image is not reloaded if I do the following, and invoke the reload() function on the image (this works if I comment out the import of Ubuntu.Components):
Image {
cache: false
function reload() {
var s = source
source = ""
source = s
}
}
Similarly (and maybe even more worrying), actually changing the value of the source property (by appending a fragment to the URL) doesn’t trigger a reload either, as demonstrated by the attached example (requires a random image named "test.jpg" in the same folder).
Related branches
- PS Jenkins bot: Approve (continuous-integration)
- Cris Dywan: Approve
- Olivier Tilloy (community): Approve
-
Diff: 47 lines (+20/-5)2 files modifiedsrc/Ubuntu/Components/plugin/ucqquickimageextension.cpp (+3/-2)
tests/unit_x11/tst_components/tst_imageprovider.qml (+17/-3)
- Tim Peeters: Approve
- PS Jenkins bot: Approve (continuous-integration)
-
Diff: 221 lines (+132/-12)5 files modifiedsrc/Ubuntu/Components/plugin/ucqquickimageextension.cpp (+11/-6)
src/Ubuntu/Components/plugin/ucscalingimageprovider.cpp (+3/-1)
tests/unit_x11/tst_components/battery-100-charging.svg (+25/-0)
tests/unit_x11/tst_components/shape.svg (+77/-0)
tests/unit_x11/tst_components/tst_imageprovider.qml (+16/-5)
affects: | ubuntu-ui-toolkit (Ubuntu) → ubuntu-ui-toolkit (Ubuntu RTM) |
Changed in ubuntu-ui-toolkit (Ubuntu RTM): | |
assignee: | Zsombor Egri (zsombi) → Christian Dywan (kalikiana) |
no longer affects: | ubuntu-ui-toolkit (Ubuntu) |
Changed in canonical-devices-system-image: | |
status: | New → Fix Committed |
importance: | Undecided → Critical |
assignee: | nobody → Zoltan Balogh (bzoltan) |
milestone: | none → ww02-2016 |
Changed in canonical-devices-system-image: | |
status: | Fix Committed → Fix Released |
The bug still exists with the latest vivid-proposed as of today.