@@ -27,6 +27,7 @@ FocusScope {
2727 id: sortProxyModel
2828 source: appDrawerModel
2929 filterString: searchField.text
30+ sortBy: AppDrawerProxyModel.SortByAToZ
3031 }
3132
3233 Item {
@@ -57,6 +58,9 @@ FocusScope {
5758 },
5859 Action {
5960 text: i18n.ctr("Most used apps", "Most used")
61+ },
62+ Action {
63+ text: "DBG"
6064 }
6165 ]
6266
@@ -72,7 +76,13 @@ FocusScope {
7276 Loader {
7377 id: listLoader
7478 anchors { left: parent.left; top: sectionsContainer.bottom; right: parent.right; bottom: parent.bottom; leftMargin: units.gu(1); rightMargin: units.gu(1) }
75− sourceComponent: sections.selectedIndex == 0 ? aToZComponent : mostUsedComponent
79+ sourceComponent: {
80+ switch (sections.selectedIndex) {
81+ case 0: return aToZComponent;
82+ case 1: return mostUsedComponent;
83+ default: return debugComponent;
84+ }
85+ }
7686 }
7787
7888 MouseArea {
@@ -108,6 +118,27 @@ FocusScope {
108118 }
109119 }
110120
121+ Component {
122+ id: debugComponent
123+ ListView {
124+ anchors.fill: parent
125+ topMargin: units.gu(1)
126+ bottomMargin: units.gu(1)
127+ spacing: units.gu(1)
128+ clip: true
129+
130+ model: sortProxyModel
131+// model: AppDrawerProxyModel {
132+// source: sortProxyModel
133+// group: AppDrawerProxyModel.GroupByAToZ
134+// sortBy: AppDrawerProxyModel.SortByAToZ
135+// }
136+ delegate: Label {
137+ text: model.letter + " - " + model.name
138+ }
139+ }
140+ }
141+
111142 Component {
112143 id: mostUsedComponent
113144 ListView {
@@ -135,7 +166,6 @@ FocusScope {
135166 // NOTE: Cannot use gridView.rows here as it would evaluate to 0 at first and only update later,
136167 // which messes up the ListView.
137168 height: (Math.ceil(mostUsedGridView.model.count / mostUsedGridView.columns) * mostUsedGridView.delegateHeight) + units.gu(2)
138− enabled: parent.interactive
139169
140170 DrawerGridView {
141171 id: mostUsedGridView
@@ -170,6 +200,7 @@ FocusScope {
170200
171201 model: AppDrawerProxyModel {
172202 source: sortProxyModel
203+ sortBy: AppDrawerProxyModel.SortByAToZ
173204 group: AppDrawerProxyModel.GroupByAToZ
174205 }
175206
@@ -177,7 +208,6 @@ FocusScope {
177208 width: parent.width
178209 color: "#20ffffff"
179210 aspect: UbuntuShape.Flat
180− enabled: parent.interactive
181211
182212 // NOTE: Cannot use gridView.rows here as it would evaluate to 0 at first and only update later,
183213 // which messes up the ListView.