I think the problem is that the documentation doesn't match what the
code does.

The internal documentation we have in the code says

    This widget shows a list of widgets defined in widgetData["widgets"]
    Those widgets can be collapsed or uncollapsed. When uncollapsed
    all the widgets are shown, when collapsed only the first
    widgetData["collapsed-widgets"] are shown. It has a title that comes
    in via widgetData["title"]. This widget expands all child widgets
    when initialized by specifying widgetData["expanded"] == true.
    It's in unexpanded mode by default.

There's nothing about 0 being a magic number and also collapsed-widgets
is the number of widgets that will still be shown when the widget is
collapsed.

I think it's best to update the documentation to match the code since
there's a few scopes using the widget already.

-- 
You received this bug notification because you are a member of Ubuntu
Bugs, which is subscribed to Ubuntu.
https://bugs.launchpad.net/bugs/1467886

Title:
  expandable widget cannot collapse widgets to the number defined by
  "collapsed-widgets"

To manage notifications about this bug go to:
https://bugs.launchpad.net/ubuntu/+source/unity-scopes-api/+bug/1467886/+subscriptions

-- 
ubuntu-bugs mailing list
ubuntu-bugs@lists.ubuntu.com
https://lists.ubuntu.com/mailman/listinfo/ubuntu-bugs

Reply via email to