Chromium Code Reviews| OLD | NEW |
|---|---|
| 1 <!DOCTYPE html> | 1 <!DOCTYPE html> |
| 2 <html i18n-values=" | 2 <html i18n-values=" |
| 3 dir:textdirection; | 3 dir:textdirection; |
| 4 bookmarkbarattached:bookmarkbarattached; | 4 bookmarkbarattached:bookmarkbarattached; |
| 5 hasattribution:hasattribution; | 5 hasattribution:hasattribution; |
| 6 anim:anim; | 6 anim:anim; |
| 7 syncispresent:syncispresent; | 7 syncispresent:syncispresent; |
| 8 customlogo:customlogo" | 8 customlogo:customlogo" |
| 9 install-animation-enabled="true"> | 9 install-animation-enabled="true"> |
| 10 <head> | 10 <head> |
| (...skipping 269 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
| 280 | 280 |
| 281 <script src="ntp/util.js"></script> | 281 <script src="ntp/util.js"></script> |
| 282 <script src="ntp/most_visited.js"></script> | 282 <script src="ntp/most_visited.js"></script> |
| 283 <script src="new_new_tab.js"></script> | 283 <script src="new_new_tab.js"></script> |
| 284 <script src="ntp/apps.js"></script> | 284 <script src="ntp/apps.js"></script> |
| 285 | 285 |
| 286 <script> | 286 <script> |
| 287 cr.ui.decorate('menu', cr.ui.Menu); | 287 cr.ui.decorate('menu', cr.ui.Menu); |
| 288 cr.ui.decorate('command', cr.ui.Command); | 288 cr.ui.decorate('command', cr.ui.Command); |
| 289 cr.ui.decorate('button[menu]', cr.ui.MenuButton); | 289 cr.ui.decorate('button[menu]', cr.ui.MenuButton); |
| 290 </script> | 290 </script> |
|
Aaron Boodman
2010/11/30 18:38:32
It's a little odd to have separate script blocks l
xiyuan
2010/11/30 19:07:58
Done.
| |
| 291 | 291 |
| 292 <script> | 292 <script> |
| 293 if (cr.isChromeOS) | |
| 294 $('closed-sections-bar').setAttribute('chromeos', true); | |
| 295 </script> | |
| 296 | |
| 297 <script> | |
| 293 initializeLogin(); | 298 initializeLogin(); |
| 294 | 299 |
| 295 initializeSection('apps', MINIMIZED_APPS, Section.APPS); | 300 initializeSection('apps', MINIMIZED_APPS, Section.APPS); |
| 296 initializeSection('most-visited', MINIMIZED_THUMB, Section.THUMB); | 301 initializeSection('most-visited', MINIMIZED_THUMB, Section.THUMB); |
| 297 initializeSection('recently-closed', MINIMIZED_RECENT); | 302 initializeSection('recently-closed', MINIMIZED_RECENT); |
| 298 | 303 |
| 299 updateSimpleSection('apps', Section.APPS); | 304 updateSimpleSection('apps', Section.APPS); |
| 300 updateSimpleSection('most-visited', Section.THUMB); | 305 updateSimpleSection('most-visited', Section.THUMB); |
| 301 var appsInitiallyVisible = !(shownSections & MINIMIZED_APPS); | 306 var appsInitiallyVisible = !(shownSections & MINIMIZED_APPS); |
| 302 var mostVisitedInitiallyVisible = !(shownSections & MINIMIZED_THUMB); | 307 var mostVisitedInitiallyVisible = !(shownSections & MINIMIZED_THUMB); |
| 303 var recentlyClosedInitiallyVisible = !(shownSections & MINIMIZED_RECENT); | 308 var recentlyClosedInitiallyVisible = !(shownSections & MINIMIZED_RECENT); |
| 304 // Apps and recently closed start as hidden in the HTML, most visited is | 309 // Apps and recently closed start as hidden in the HTML, most visited is |
| 305 // initially visible. Adapt to the change received from the prefs by forcing | 310 // initially visible. Adapt to the change received from the prefs by forcing |
| 306 // all three sections to update. | 311 // all three sections to update. |
| 307 shownSections &= ~MINIMIZED_THUMB; | 312 shownSections &= ~MINIMIZED_THUMB; |
| 308 shownSections |= MINIMIZED_APPS | MINIMIZED_RECENT; | 313 shownSections |= MINIMIZED_APPS | MINIMIZED_RECENT; |
| 309 setSectionVisible('apps', Section.APPS, appsInitiallyVisible, MINIMIZED_APPS); | 314 setSectionVisible('apps', Section.APPS, appsInitiallyVisible, MINIMIZED_APPS); |
| 310 setSectionVisible( | 315 setSectionVisible( |
| 311 'most-visited', Section.THUMB, | 316 'most-visited', Section.THUMB, |
| 312 mostVisitedInitiallyVisible, MINIMIZED_THUMB); | 317 mostVisitedInitiallyVisible, MINIMIZED_THUMB); |
| 313 setSectionVisible( | 318 setSectionVisible( |
| 314 'recently-closed', undefined, | 319 'recently-closed', undefined, |
| 315 recentlyClosedInitiallyVisible, MINIMIZED_RECENT); | 320 recentlyClosedInitiallyVisible, MINIMIZED_RECENT); |
| 316 layoutSections(); | 321 layoutSections(); |
| 317 </script> | 322 </script> |
| 318 </html> | 323 </html> |
| OLD | NEW |