Merge lp://staging/~tpeeters/ubuntu-ui-toolkit/optIn-tabsDrawer into lp://staging/ubuntu-ui-toolkit
Proposed by
Tim Peeters
Status: | Rejected | ||||||||
---|---|---|---|---|---|---|---|---|---|
Rejected by: | Tim Peeters | ||||||||
Proposed branch: | lp://staging/~tpeeters/ubuntu-ui-toolkit/optIn-tabsDrawer | ||||||||
Merge into: | lp://staging/ubuntu-ui-toolkit | ||||||||
Prerequisite: | lp://staging/~tpeeters/ubuntu-ui-toolkit/tabBarInStyle | ||||||||
Diff against target: |
1779 lines (+613/-512) (has conflicts) 37 files modified
debian/changelog (+0/-21) modules/Ubuntu/Components/Header.qml (+24/-1) modules/Ubuntu/Components/MainView.qml (+8/-0) modules/Ubuntu/Components/Panel.qml (+31/-0) modules/Ubuntu/Components/TabBar.qml (+24/-5) modules/Ubuntu/Components/Tabs.qml (+6/-1) modules/Ubuntu/Components/TextField.qml (+11/-10) modules/Ubuntu/Components/TextInputPopover.qml (+1/-3) modules/Ubuntu/Components/Themes/Ambiance/NewHeaderStyle.qml (+146/-0) modules/Ubuntu/Components/Themes/Ambiance/TabBarStyle.qml (+5/-3) modules/Ubuntu/Components/Themes/Ambiance/qmldir (+1/-0) modules/Ubuntu/Components/plugin/bottombarvisibilitycommunicator.cpp (+75/-0) modules/Ubuntu/Components/plugin/bottombarvisibilitycommunicator.h (+59/-0) modules/Ubuntu/Components/plugin/inversemouseareatype.h (+4/-11) modules/Ubuntu/Components/plugin/plugin.cpp (+3/-0) modules/Ubuntu/Components/plugin/plugin.pro (+2/-0) modules/Ubuntu/Components/plugin/quickutils.cpp (+1/-1) modules/Ubuntu/Components/plugin/quickutils.h (+1/-1) modules/Ubuntu/Test/Test.pro (+0/-1) modules/Ubuntu/Test/plugin/plugin.pro (+0/-25) modules/Ubuntu/Test/plugin/uctestcase.cpp (+0/-50) modules/Ubuntu/Test/plugin/uctestcase.h (+0/-47) tests/autopilot/ubuntuuitoolkit/emulators.py (+87/-20) tests/autopilot/ubuntuuitoolkit/tests/test_emulators.py (+42/-32) tests/resources/navigation/SimpleTabs.qml (+2/-0) tests/resources/navigation/StackWithTabs.qml (+22/-32) tests/resources/navigation/Tabs.qml (+8/-2) tests/unit/plugin_dependency.pri (+0/-3) tests/unit_x11/tst_components/tst_tabbar.qml (+7/-0) tests/unit_x11/tst_inversemousearea/InverseMouseAreaClip.qml (+0/-73) tests/unit_x11/tst_inversemousearea/InverseMouseAreaInFlickable.qml (+0/-52) tests/unit_x11/tst_inversemousearea/InverseMouseAreaInPage.qml (+0/-46) tests/unit_x11/tst_inversemousearea/InverseMouseAreaOnTop.qml (+6/-0) tests/unit_x11/tst_inversemousearea/InverseMouseAreaOnTopNoAccept.qml (+6/-1) tests/unit_x11/tst_inversemousearea/InverseMouseAreaParentClipped.qml (+0/-56) tests/unit_x11/tst_inversemousearea/InverseMouseAreaTopmostItem.qml (+9/-10) tests/unit_x11/tst_layouts/tst_layouts.cpp (+22/-5) Text conflict in tests/resources/navigation/Tabs.qml |
||||||||
To merge this branch: | bzr merge lp://staging/~tpeeters/ubuntu-ui-toolkit/optIn-tabsDrawer | ||||||||
Related bugs: |
|
||||||||
Related blueprints: |
New header and bottom edge
(Essential)
|
Reviewer | Review Type | Date Requested | Status |
---|---|---|---|
Tim Peeters | Disapprove | ||
PS Jenkins bot | continuous-integration | Needs Fixing | |
Leo Arias | code review of the autopilot tests and helpers | Pending | |
Review via email: mp+212496@code.staging.launchpad.net |
This proposal supersedes a proposal from 2014-03-10.
Description of the change
Add new tab patterns (and autopilot tests for those patterns) which are used when useDeprecatedTo
To post a comment you must log in.
Unmerged revisions
- 975. By Tim Peeters
-
merge tabbarInStyle
- 974. By Tim Peeters
-
update Tabs example
- 973. By Tim Peeters
-
update StackWithTabs example
- 972. By Tim Peeters
-
fix TypeError when closing StackWithTabs example
- 971. By Tim Peeters
-
merge 25-pageTitle
- 970. By Tim Peeters
-
merge 20-tabbarInStyle
- 969. By Tim Peeters
-
bug no longer present in this branch
- 968. By Tim Peeters
-
remove unused variable
- 967. By Tim Peeters
-
link bug
- 966. By Tim Peeters
-
merge optIn-newHeader
42 + // FIXME: Currently autopilot can only get visual items, but once it is
43 + // updated to support non-visual items, a QtObject may be used.
Please add a link to http:// pad.lv/ 1273956 so we know what you are referring to. Also, I find it useful to sign the FIXME comments, with something like --timp - 2014-03-19
637 + current_tab = tabs.get_ current_ tab() bIndex == index: tabs.selectedTa bIndex) ) Exception( '.format( index)) to_next_ tab()
638 + number_of_switches = 0
639 + while not tabs.selectedTa
640 + logger.debug(
641 + 'Current tab index: {0}.'.format(
642 + if number_of_switches >= number_of_tabs - 1:
643 + # This prevents a loop. But if this error is ever raised, it's
644 + # likely there's a bug on the emulator or on the QML Tab.
645 + raise ToolkitEmulator
646 + 'The tab with index {0} was not selected.
647 + current_tab = self.switch_
648 + number_of_switches += 1
649 + return current_tab
You should move this into a method. You can call it something like _switch_ to_deprecated_ tab_by_ index
651 + if (index != tabs.selectedTa bIndex) : header( ).switch_ to_tab_ by_index( index) current_ tab()
652 + self.get_
653 + current_tab = tabs.get_
654 + return current_tab
This is not a big deal, but it would also make it clearer putting those statements on _switch_ to_tab_ in_drawer_ by_index
668 + return false
Typo. It's False.
677 + try: single( TabBar) undError: Exception( _NO_TABS_ ERROR) switch_ to_next_ tab() animating( ).wait_ for(False)
678 + tab_bar = self.select_
679 + except dbus.StateNotFo
680 + raise ToolkitEmulator
681 + tab_bar.
682 + self._get_
Same thing here ^
684 + try: single( 'AbstractButton ', objectName= 'tabsButton' ) undError: Exception( _NO_TABS_ ERROR) device. click_object( tabs_drawer_ button) properties = self.select_ single( 'QQuickItem' , objectName= 'tabsModelPrope rties') properties. selectedIndex + 1) % tabs_model_ properties. count root_instance( ).select_ single( 'Standard' , 'tabButton' +str(next_ tab_index) ) undError: Exception( "Tab button {0} not found." .format( next_tab_ index)) device. click_object( tab_button)
685 + tabs_drawer_button = self.select_
686 + except dbus.StateNotFo
687 + raise ToolkitEmulator
688 + self.pointing_
689 +
690 + tabs_model_
691 + next_tab_index = (tabs_model_
692 +
693 + try:
694 + tab_button = self.get_
695 + objectName=
696 + except dbus.StateNotFo
697 + raise ToolkitEmulator
698 +
699 + self.pointing_
and here ^. Please wrap them in something like _switch_ to_next_ deprecated_ tab, and _switch_ to_next_ tab_in_ drawer
4 + try: single( 'AbstractButton ', objectName= 'tabsButton' ) undError: Exception( _NO_TABS_ ERROR)
685 + tabs_drawer_button = self.select_
686 + except dbus.StateNotFo
687 + raise ToolkitEmulator
You can also move this ^
724 + try: root_instance( ).select_ single( 'Standard' , 'tabButton' +str(index) ) undError: Exception( "Tab button {0} not found." .format( index))
725 + tab_button = self.get_
726 + objectName=
727 + except dbus.StateNotFo
728 + raise ToolkitEmulator
and this ^ into a private methods, as you have the same statements twice.
755 +class DeprecatedTabsT estCase( TabsTestCase) :
I would prefer to do it with scenarios. Take a look at http:// paste.ubuntu. com/7121301/
I haven't tried it, but something like that should work.
70...