[PageHeadState] Cannot create pageheadstate with name ""
Affects | Status | Importance | Assigned to | Milestone | |
---|---|---|---|---|---|
ubuntu-ui-toolkit (Ubuntu) |
Won't Fix
|
High
|
Tim Peeters |
Bug Description
PageHeadState does not accept the state name to be "". As a result that creates issues which requires a hack to fix it.
1. Run the sample app attached where the default pageheadstate is called "".
2. Notice that when the app loads, you don't see the add button despite it being the default state that should be loaded.
Let's say we fix this issue by naming the default state to "Default". We then run into another issue,
1. Run the changed app and notice that the add button is now visible. You will also see a console message that says "State changed to: Default".
2. Press the add button which should trigger the other pageheadstate "contact". Console will also read "State changed to: Contact" as expected.
3. Now press the contact button, and notice that the add button is missing again. Here the console says "State switched to: ". So it switches to the empty "" and not the default state.
Changed in ubuntu-ui-toolkit (Ubuntu): | |
assignee: | nobody → Tim Peeters (tpeeters) |
importance: | Undecided → High |
status: | New → Triaged |
no longer affects: | ubuntu-ui-toolkit |
it is not enough to just rename the default "" state to something else, if you want to extend a state like default, then you must specify that. See State QML type documentation.