Skip to content

GitLab

  • Projects
  • Groups
  • Snippets
  • Help
    • Loading...
  • Help
    • Help
    • Support
    • Community forum
    • Submit feedback
    • Contribute to GitLab
  • Sign in
Settings
Settings
  • Project overview
    • Project overview
    • Details
    • Activity
    • Releases
  • Repository
    • Repository
    • Files
    • Commits
    • Branches
    • Tags
    • Contributors
    • Graph
    • Compare
  • Issues 676
    • Issues 676
    • List
    • Boards
    • Labels
    • Service Desk
    • Milestones
  • Merge Requests 53
    • Merge Requests 53
  • CI / CD
    • CI / CD
    • Pipelines
    • Jobs
    • Schedules
  • Operations
    • Operations
    • Incidents
    • Environments
  • Packages & Registries
    • Packages & Registries
    • Container Registry
  • Analytics
    • Analytics
    • CI / CD
    • Repository
    • Value Stream
  • Wiki
    • Wiki
  • Snippets
    • Snippets
  • Members
    • Members
  • Collapse sidebar
  • Activity
  • Graph
  • Create a new issue
  • Jobs
  • Commits
  • Issue Boards
  • GNOME
  • SettingsSettings
  • Merge Requests
  • !267

Merged
Opened Nov 05, 2018 by Benjamin Berg@bbergMaintainer

power: Correctly lookup or insert new items into combobox

  • Overview 4
  • Commits 1
  • Pipelines 2
  • Changes 1

This should be cherry-picked to stable.

The code to lookup or insert items into the combobox had a few issues. It would assume that the items are sorted, causing existing items to not be found and be inserted instead. It also would simply forget to insert an item if it was larger than all existing items.

This code is now changed to iterate over all items, finding the best insertion point in the process (next item has a larger value, or the values are not increasing anymore). The item will only be inserted if it has not been found.

Fixes #261 (closed)

Assignee
Assign to
Reviewer
Request review from
GNOME 3.30
Milestone
GNOME 3.30 (Past due)
Assign milestone
Time tracking
Reference: GNOME/gnome-control-center!267
Source branch: benzea/power-combobox-value-setting