Thanks for your branch! I like the idea of going for a simple fix, unfortunately this seems to only
fix parts of the issue as e.g.:
- searching for "foo"
- change "by name"
- go back
- go a a category like "accessories" will sort by name, but the combo will show "by top rated"
(note that this is not a regression, but a different incarnation of the bug or a different bug that is very similar to this one).
As for the bit:
...
8 + sortmode=self.get_sort_mode(),
...
I am not sure that this is needed, the name of the function is certainly very misleading, my suggestion would
be to do something like (suggestions for better names welcome of course):
=== modified file 'softwarecenter/ui/gtk3/panes/availablepane.py'
--- softwarecenter/ui/gtk3/panes/availablepane.py 2012-03-30 09:46:20 +0000
+++ softwarecenter/ui/gtk3/panes/availablepane.py 2012-04-10 09:37:54 +0000
@@ -618,7 +618,7 @@ self.refresh_apps()
- def quick_query(self, query):
+ def quick_query_len(self, query):
+ """ do a blocking query that only returns the amount of
+ matches from this query
+ """
# a blocking query and does not emit "query-complete"
with ExecutionTime("enquirer.set_query() quick query"): self.enquirer.set_query(
To make it clearer what its actually doing. So unless I miss something, the sort order should not
influence the amount of items returned, so it should be ok to omit it.
Thanks for your branch! I like the idea of going for a simple fix, unfortunately this seems to only
fix parts of the issue as e.g.:
- searching for "foo"
- change "by name"
- go back
- go a a category like "accessories" will sort by name, but the combo will show "by top rated"
(note that this is not a regression, but a different incarnation of the bug or a different bug that is very similar to this one).
As for the bit: self.get_ sort_mode( ), /ui/gtk3/ panes/available pane.py' ui/gtk3/ panes/available pane.py 2012-03-30 09:46:20 +0000 ui/gtk3/ panes/available pane.py 2012-04-10 09:37:54 +0000
self. refresh_ apps()
...
8 + sortmode=
...
I am not sure that this is needed, the name of the function is certainly very misleading, my suggestion would
be to do something like (suggestions for better names welcome of course):
=== modified file 'softwarecenter
--- softwarecenter/
+++ softwarecenter/
@@ -618,7 +618,7 @@
query = self.get_query() query(query) query_len( query)
self. subcategories_ view.set_ subcategory( category, n_matches)
- n_matches = self.quick_
+ n_matches = self.quick_
=== modified file 'softwarecenter /ui/gtk3/ panes/softwarep ane.py' ui/gtk3/ panes/softwarep ane.py 2012-04-04 14:40:09 +0000 ui/gtk3/ panes/softwarep ane.py 2012-04-10 09:34:25 +0000
self. show_appview_ spinner( )
self. _refresh_ apps_with_ apt_cache( query)
--- softwarecenter/
+++ softwarecenter/
@@ -431,7 +431,10 @@
- def quick_query(self, query): len(self, query): "enquirer. set_query( ) quick query"):
self. enquirer. set_query(
+ def quick_query_
+ """ do a blocking query that only returns the amount of
+ matches from this query
+ """
# a blocking query and does not emit "query-complete"
with ExecutionTime(
To make it clearer what its actually doing. So unless I miss something, the sort order should not
influence the amount of items returned, so it should be ok to omit it.