Chromium Code Reviews| OLD | NEW |
|---|---|
| (Empty) | |
| 1 <!DOCTYPE html> | |
| 2 <html> | |
| 3 <head> | |
| 4 <meta charset="utf-8"> | |
| 5 <title i18n-content="title"></title> | |
| 6 <link rel="stylesheet" href="newtab.css"> | |
| 7 <!-- Don't scale the viewport in either portrait or landscape mode. | |
| 8 Note that this means apps will be reflowed when rotated (like iPad). | |
| 9 If we wanted to maintain position we could remove 'maximum-scale' so | |
| 10 that we'd zoom out in portrait mode, but then there would be a bunch | |
| 11 of unusable space at the bottom. | |
| 12 --> | |
| 13 <meta name="viewport" content="user-scalable=no, width=device-width, maximum-s cale=1.0" /> | |
|
arv (Not doing code reviews)
2011/03/10 19:25:59
No /> in HTML
Rick Byers
2011/03/11 02:44:33
Done.
| |
| 14 </head> | |
| 15 <body> | |
| 16 <div id="apps-frame"> | |
| 17 <div id="apps-page-list"> | |
| 18 <div class="apps-page"> | |
| 19 <!-- This is used as a template which JS copies and fills in. The | |
| 20 template itself is never actually displayed. For this HTML to | |
| 21 validate, I need to supply and img src attribute, but to avoid | |
|
arv (Not doing code reviews)
2011/03/10 19:25:59
validation is over rated. Don't let it get to you
Rick Byers
2011/03/11 02:44:33
Thanks!
I think this comment is stale anyway -
| |
| 22 errors/warnings in chrome it needs to be a valid image. I use | |
| 23 trash-open because I want to get it preloaded anyway to avoid flicker. | |
| 24 Note that this isn't inside of apps-frame so that we can easily search | |
| 25 for and manipulate all real apps. | |
| 26 An app-container is always a direct child of an apps-page, and is | |
| 27 expected to have a single 'app' child element holding the visible | |
| 28 content, and 'img' and 'span' tags as descendants somewhere. | |
| 29 --> | |
| 30 <div class="app-container" id="app-template"> | |
| 31 <div class="app"> | |
| 32 <img src="trash-open.png"/> | |
| 33 <span>App name</span> | |
| 34 </div> | |
| 35 </div> | |
| 36 </div> | |
| 37 </div> | |
| 38 </div> | |
| 39 <div id="footer"> | |
| 40 <ul id="dot-list"> | |
| 41 <li class="dot"></li> | |
| 42 </ul> | |
| 43 <div id="trash"> | |
| 44 </div> | |
| 45 </div> | |
| 46 <!-- If this page isn't loaded as a chrome extension, try to load the | |
| 47 standalone hacks --> | |
| 48 <script type="text/javascript"> | |
|
arv (Not doing code reviews)
2011/03/10 19:25:59
skip type
Rick Byers
2011/03/11 02:44:33
Done. But I'm curious why - isn't it better to be
arv (Not doing code reviews)
2011/03/11 20:08:46
type is optional and defaults to text/javascript i
| |
| 49 if(!window.chrome || !window.chrome.send) { | |
|
arv (Not doing code reviews)
2011/03/10 19:25:59
ws after if
Rick Byers
2011/03/11 02:44:33
Done.
| |
| 50 // Dynamically reference the standalone script in the source tree. This | |
| 51 // is intentionally obfuscated so that grit doesn't try to embed this | |
|
arv (Not doing code reviews)
2011/03/10 19:25:59
This should be easy to fix in a cleaner way. Take
Rick Byers
2011/03/11 02:44:33
Perfect, thanks! I was never really happy with th
| |
| 52 // file in the chrome resources | |
| 53 document.write('<script type=\"text/javascript\" ' + | |
| 54 'src=\"standalone/standalone_hack.js\"></scr' + 'ipt>'); | |
| 55 } | |
| 56 </script> | |
| 57 <!-- Substitute localized strings for all elements with il8n-content | |
| 58 attributes. --> | |
| 59 <script type="text/javascript" src="../shared/js/i18n_template.js"></script> | |
| 60 <!-- template data placeholder --> | |
| 61 <script type="text/javascript"> | |
| 62 i18nTemplate.process(document, templateData); | |
| 63 </script> | |
| 64 | |
| 65 <script type="text/javascript" src="eventtracker.js"></script> | |
| 66 <script type="text/javascript" src="touchhandler.js"></script> | |
| 67 <script type="text/javascript" src="slider.js"></script> | |
| 68 <script type="text/javascript" src="grabber.js"></script> | |
| 69 <script type="text/javascript" src="newtab.js"></script> | |
| 70 </body> | |
| 71 </html> | |
| OLD | NEW |