OLD | NEW |
1 // Copyright (c) 2011 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2011 The Chromium Authors. All rights reserved. |
2 // Use of this source code is governed by a BSD-style license that can be | 2 // Use of this source code is governed by a BSD-style license that can be |
3 // found in the LICENSE file. | 3 // found in the LICENSE file. |
4 | 4 |
5 // File Description: | 5 // File Description: |
6 // Contains all the necessary functions for rendering the NTP on mobile | 6 // Contains all the necessary functions for rendering the NTP on mobile |
7 // devices. | 7 // devices. |
8 | 8 |
9 /** | 9 /** |
10 * The event type used to determine when a touch starts. | 10 * The event type used to determine when a touch starts. |
(...skipping 2444 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
2455 [ | 2455 [ |
2456 ContextMenuItemIds.RECENTLY_CLOSED_OPEN_IN_NEW_TAB, | 2456 ContextMenuItemIds.RECENTLY_CLOSED_OPEN_IN_NEW_TAB, |
2457 templateData.elementopeninnewtab | 2457 templateData.elementopeninnewtab |
2458 ], | 2458 ], |
2459 [ | 2459 [ |
2460 ContextMenuItemIds.RECENTLY_CLOSED_OPEN_IN_INCOGNITO_TAB, | 2460 ContextMenuItemIds.RECENTLY_CLOSED_OPEN_IN_INCOGNITO_TAB, |
2461 templateData.elementopeninincognitotab | 2461 templateData.elementopeninincognitotab |
2462 ], | 2462 ], |
2463 [ | 2463 [ |
2464 ContextMenuItemIds.RECENTLY_CLOSED_REMOVE, | 2464 ContextMenuItemIds.RECENTLY_CLOSED_REMOVE, |
2465 templateData.elementremove | 2465 templateData.removeall |
2466 ] | 2466 ] |
2467 ]; | 2467 ]; |
2468 } else if (section == SectionType.FOREIGN_SESSION_HEADER) { | 2468 } else if (section == SectionType.FOREIGN_SESSION_HEADER) { |
2469 menuOptions = [ | 2469 menuOptions = [ |
2470 [ | 2470 [ |
2471 ContextMenuItemIds.FOREIGN_SESSIONS_REMOVE, | 2471 ContextMenuItemIds.FOREIGN_SESSIONS_REMOVE, |
2472 templateData.elementremove | 2472 templateData.elementremove |
2473 ] | 2473 ] |
2474 ]; | 2474 ]; |
2475 } else if (section == SectionType.PROMO_VC_SESSION_HEADER) { | 2475 } else if (section == SectionType.PROMO_VC_SESSION_HEADER) { |
(...skipping 184 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
2660 // NTP Entry point. | 2660 // NTP Entry point. |
2661 ///////////////////////////////////////////////////////////////////////////// | 2661 ///////////////////////////////////////////////////////////////////////////// |
2662 | 2662 |
2663 /* | 2663 /* |
2664 * Handles initializing the UI when the page has finished loading. | 2664 * Handles initializing the UI when the page has finished loading. |
2665 */ | 2665 */ |
2666 window.addEventListener('DOMContentLoaded', function(evt) { | 2666 window.addEventListener('DOMContentLoaded', function(evt) { |
2667 ntp.init(); | 2667 ntp.init(); |
2668 $('content-area').style.display = 'block'; | 2668 $('content-area').style.display = 'block'; |
2669 }); | 2669 }); |
OLD | NEW |