|
1552 |
domClass.toggle(favoritesCategory._button.domNode, 'favoritesHidden', emptyFavorites); |
1552 |
domClass.toggle(favoritesCategory._button.domNode, 'favoritesHidden', emptyFavorites); |
1553 |
|
1553 |
|
1554 |
// take the first visible category as fallback for the last selected one |
1554 |
// take the first visible category as fallback for the last selected one |
1555 |
this._lastCategory = emptyFavorites ? this.getCategories()[1] : favoritesCategory; |
1555 |
this._lastCategory = emptyFavorites ? this.getCategories().filter(function(category) {return category['id'] != '_favorites_'})[0] : this.getCategories()[0]; |
1556 |
|
1556 |
|
1557 |
// spread category buttons over whole width |
1557 |
// spread category buttons over whole width |
1558 |
styles.insertCssRule('.umc .umcCategoryBar .dijitButton', lang.replace('width: {0}%', [100.0 / this.getCategories().length])); |
1558 |
styles.insertCssRule('.umc .umcCategoryBar .dijitButton', lang.replace('width: {0}%', [100.0 / this.getCategories().length])); |