openFile is the mobile-specific way of opening a file
(url string)
| 201 | |
| 202 | // openFile is the mobile-specific way of opening a file |
| 203 | func openFile(url string) (io.ReadCloser, error) { |
| 204 | usedUrl := url |
| 205 | if strings.HasPrefix(url, "assets/") { |
| 206 | usedUrl = usedUrl[7:] |
| 207 | } |
| 208 | |
| 209 | return asset.Open(usedUrl) |
| 210 | } |
| 211 | |
| 212 | // IsAndroidChrome tells if the browser is Chrome for android |
| 213 | func IsAndroidChrome() bool { |