Fixes #173.
Unified · Split
| @@ -87,6 +87,7 @@ · 86 unmodified lines | ||
| 87 | 87 | @hideLoading() |
| 88 | 88 | @welcomeBack() unless @doc |
| 89 | 89 | @removeEvent 'ready bootError' |
| 90 | + navigator.mozApps?.getSelf().onsuccess = -> app.mozApp = true | |
| 90 | 91 | return |
| 91 | 92 | |
| 92 | 93 | initDoc: (doc) -> |
| @@ -43,6 +43,8 @@ canICloseTheTab = -> · 42 unmodified lines | ||
| 43 | 43 | if app.AppCache.isEnabled() |
| 44 | 44 | """ Yes! Even offline, you can open a new tab, go to <a href="http://devdocs.io">devdocs.io</a>, and everything will work as if you were online (provided you installed all the documentations you want to use beforehand).<br> |
| 45 | 45 | Note that loading any page other than <a href="http://devdocs.io">devdocs.io</a> directly won't work (due to limitations in AppCache). """ |
| 46 | + else if app.mozApp | |
| 47 | + """ Yes! Even offline, you can open the app and everything will work as if you were online (provided you installed all the documentations you want to use beforehand). """ | |
| 46 | 48 | else |
| 47 | 49 | """ No. AppCache isn't available in your browser (or is disabled) so loading <a href="http://devdocs.io">devdocs.io</a> offline won't work.<br> |
| 48 | 50 | The current tab will continue to work, though (provided you installed all the documentations you want to use beforehand). """ |