count property of Qquickrepeater is not decreased to zero after deleting the last element

Bug #1368393 reported by Carla Sella on 2014-09-11
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
Canonical System Image
Medium
Unassigned
Ubuntu Clock App
Medium
Nekhelesh Ramananthan
Ubuntu UI Toolkit
Invalid
Undecided
Unassigned

Bug Description

In Ubuntu-clock-app, if you delete the last world city the count property of Qquickrepeater remains set at one instead of zero. If you add 2 world cities (count=2), and then delete one, the count changes to 1. If you delete the last one, the count remains as 1.

To reproduce the bug:
- launch the app with autopilot:
autopilot3 launch -i Qt qmlscene ../../app/ubuntu-clock-app.qml -I ../../builddir/backend/

- add a World city, clicking on the "Add City" button and selecting a city
- with autopilot3 vis verify the count property of QQuickRepater with objectName "userWorldCityRepeater" it will be set at 1, close autopilot vis
- swipe and delete the previously added city
- launch autopilot3 vis again and verify the count property of QQuickRepater with objectName "userWorldCityRepeater" it will still be set at 1 instead of decreasing of one and be set to 0.

Related branches

description: updated
Changed in ubuntu-clock-app:
status: New → Confirmed
Carla Sella (carla-sella) wrote :

If you look at the attached screenshot that I took of autopilot vis after deleting a world city I had added, you can see that in the clock
app the world city is gone, deleted, but in autopilot vis the world city is still there, it has not been delete, hence the count set at 1, at
least I think so!

Tim Peeters (tpeeters) wrote :

This sounds like an upstream bug in Repeater to me.

Can you create a small&simple test program to reproduce the issue?

Changed in ubuntu-ui-toolkit:
status: New → Incomplete
Zsombor Egri (zsombi) wrote :

GC (Garbage Collector) is the one responsible to delete this. And unfortunately we cannot really do much about this.

However, I would implement the feature using a ListView, where the model is a list of cities. ListView at least handles this much better. and after all, this is not a toolkit bug.

Changed in ubuntu-ui-toolkit:
status: Incomplete → Invalid
Nekhelesh Ramananthan (nik90) wrote :

Actually just a few days back, I replaced the repeater with a listview and I was still hitting this issue. But I will try to create a simple app to reproduce this issue.

tags: added: clock-app
Changed in ubuntu-clock-app:
milestone: none → 3.6
assignee: nobody → Nekhelesh Ramananthan (nik90)
importance: Undecided → Medium
status: Confirmed → In Progress

Fix committed into lp:ubuntu-clock-app at revision 366, scheduled for release in ubuntu-clock-app, milestone 3.5

Changed in ubuntu-clock-app:
status: In Progress → Fix Committed
Changed in canonical-devices-system-image:
milestone: none → ww46-2015
status: New → Confirmed
importance: Undecided → Medium
Changed in ubuntu-clock-app:
status: Fix Committed → Fix Released
Changed in canonical-devices-system-image:
status: Confirmed → Fix Committed
Changed in canonical-devices-system-image:
status: Fix Committed → Fix Released
To post a comment you must log in.
This report contains Public information  Edit
Everyone can see this information.

Other bug subscribers

Bug attachments