Showing the changes to assets/javascripts/app (1 of 4 files). Show all
Unified · Split
| @@ -79,6 +79,14 @@ class app.Settings · 78 unmodified lines | |||
| 79 | catch | 79 | catch |
| 80 | return | 80 | return |
| 81 | 81 | ||
| 82 | hasLayout: (name) -> | ||
| 83 | try | ||
| 84 | layout = (Cookies.get(LAYOUT_KEY) || '').split(' ') | ||
| 85 | $.arrayDelete(layout, '') | ||
| 86 | return layout.indexOf(name) isnt -1 | ||
| 87 | catch | ||
| 88 | return false | ||
| 89 | |||
| 82 | setSize: (value) -> | 90 | setSize: (value) -> |
| 83 | try | 91 | try |
| 84 | Cookies.set SIZE_KEY, value, path: '/', expires: 1e8 | 92 | Cookies.set SIZE_KEY, value, path: '/', expires: 1e8 |