Move selectedTabIndex to tabs model
Affects | Status | Importance | Assigned to | Milestone | |
---|---|---|---|---|---|
Ubuntu UI Toolkit |
Fix Released
|
Critical
|
Tim Peeters | ||
ubuntu-ui-toolkit (Ubuntu) |
Fix Released
|
Undecided
|
Unassigned |
Bug Description
Code from Tabs.qml:
property alias selectedTabIndex: bar.selectedIndex
There is also some checking of the model inside TabBar.qml. This is not good because we do not want Tabs to depend on the TabBar. For upcoming changes (TabBar will be deprecated eventually, but for now we will give the app developers the option to choose between the "old" TabBar, and a new way to display the tabs), I want to load the TabBar inside a Loader only when it is needed. So some code may need to be moved from TabBar to Tabs, and the alias listed above must be removed.
Update: unity8 uses the tabbar (and will use the tabs drawer in the header) without the Tabs, so we decided to move the selected tab index to the model instead of the Tabs.
Related branches
- PS Jenkins bot: Approve (continuous-integration)
- Tim Peeters: Approve
- Zsombor Egri: Approve
-
Diff: 163 lines (+38/-7)4 files modifiedmodules/Ubuntu/Components/TabBar.qml (+24/-5)
modules/Ubuntu/Components/Tabs.qml (+6/-1)
modules/Ubuntu/Components/Themes/Ambiance/TabBarStyle.qml (+1/-1)
tests/unit_x11/tst_components/tst_tabbar.qml (+7/-0)
Changed in ubuntu-ui-toolkit: | |
importance: | Undecided → High |
description: | updated |
Changed in ubuntu-ui-toolkit: | |
assignee: | nobody → Tim Peeters (tpeeters) |
status: | New → In Progress |
Changed in ubuntu-ui-toolkit: | |
importance: | High → Critical |
summary: |
- Tabs model logic is in TabBar, but should be in Tabs + Tabs model logic is in TabBar, but should be in tabs model |
description: | updated |
summary: |
- Tabs model logic is in TabBar, but should be in tabs model + Move selectedTabIndex to tabs model |
tags: | added: header tabs |
Changed in ubuntu-ui-toolkit: | |
milestone: | none → march-2014 |
Changed in ubuntu-ui-toolkit: | |
status: | In Progress → Fix Committed |
Changed in ubuntu-ui-toolkit: | |
status: | Fix Committed → Fix Released |
A complication in fixing this bug is that the scopes use the TabBar without Tabs.