- if uri.startswith('place:sort=8') \
- or uri.startswith('place://sort=8'):
- value = 'MostVisited'
- elif uri.startswith('place:folder=BOOKMARKS_MENU') \
- or uri.startswith('place://folder=BOOKMARKS_MENU'):
- value = 'RecentlyBookmarked'
- elif uri.startswith('place:sort=14') \
- or uri.startswith('place://sort=14'):
- value = 'RecentTags'
+ if uri.startswith('place:folder'):
+ value = 'Recently Bookmarked'
+ elif uri.startswith('place:sort=8') or \
+ uri.startswith('place:redirectsMode'):
+ value = 'Most Visited'
+ elif uri.startswith('place:sort=14') or \
+ uri.startswith('place:type=6'):
+ value = 'Recent Tags'
+ else:
+ raise ValueError('UNKNOWN place URI: %s' % uri)