| OLD | NEW |
| 1 // Copyright 2015 The Chromium Authors. All rights reserved. | 1 // Copyright 2015 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 window.addEventListener('load', function() { | 5 window.addEventListener('load', function() { |
| 6 downloads.Manager.onLoad(); | 6 downloads.Manager.onLoad(); |
| 7 | 7 document.fonts.load('bold 12px Roboto'); |
| 8 if (!cr.isChromeOS) { | |
| 9 // TODO(dbeam): this is copied out of roboto.css. I excluded roboto.css from | |
| 10 // vulcanize.py and tried to re-use the "src:" rule from the file via | |
| 11 // querySelector(href$=roboto.css).sheet.rules[2].style.src, but alas .rules | |
| 12 // can't be accessed because the origins don't match (chrome://resources vs | |
| 13 // chrome://downloads). So it's duplicated. | |
| 14 new FontFace('Roboto', "local('Roboto Bold'), local('Roboto-Bold'), " + | |
| 15 "url(chrome://resources/roboto/roboto-bold.woff2) format('woff2')", | |
| 16 {weight: 'bold'}).load(); | |
| 17 } | |
| 18 }); | 8 }); |
| OLD | NEW |