File tree Expand file tree Collapse file tree 4 files changed +20
-7
lines changed
Expand file tree Collapse file tree 4 files changed +20
-7
lines changed Original file line number Diff line number Diff line change 11.idea
2- .vscode
2+ .vscode
3+ node_modules
Original file line number Diff line number Diff line change 11# NativeScript Insomnia
22
3+ [ ![ NPM version] [ npm-image ]] [ npm-url ]
4+ [ ![ Downloads] [ downloads-image ]] [ npm-url ]
5+ [ ![ Twitter Follow] [ twitter-image ]] [ twitter-url ]
6+
7+ [ npm-image ] :http://img.shields.io/npm/v/nativescript-insomnia.svg
8+ [ npm-url ] :https://npmjs.org/package/nativescript-insomnia
9+ [ downloads-image ] :http://img.shields.io/npm/dm/nativescript-insomnia.svg
10+ [ twitter-image ] :https://img.shields.io/twitter/follow/eddyverbruggen.svg?style=social&label=Follow%20me
11+ [ twitter-url ] :https://twitter.com/eddyverbruggen
12+
313## Demo app (Angular)
414This plugin is part of the [ plugin showcase app] ( https://github.com/EddyVerbruggen/nativescript-pluginshowcase/tree/master/app/ar ) I built using Angular.
515
Original file line number Diff line number Diff line change 1- var utils = require ( "tns-core-modules/utils/utils" ) ;
2-
31exports . keepAwake = function ( ) {
42 return new Promise ( function ( resolve , reject ) {
53 try {
6- var app = utils . ios . getter ( UIApplication , UIApplication . sharedApplication ) ;
4+ var app = UIApplication . sharedApplication ;
75 if ( ! app . idleTimerDisabled ) {
86 app . idleTimerDisabled = true ;
97 }
@@ -18,7 +16,7 @@ exports.keepAwake = function () {
1816exports . allowSleepAgain = function ( ) {
1917 return new Promise ( function ( resolve , reject ) {
2018 try {
21- var app = utils . ios . getter ( UIApplication , UIApplication . sharedApplication ) ;
19+ var app = UIApplication . sharedApplication ;
2220 if ( app . idleTimerDisabled ) {
2321 app . idleTimerDisabled = false ;
2422 }
Original file line number Diff line number Diff line change 11{
22 "name" : " nativescript-insomnia" ,
3- "version" : " 1.2.2 " ,
3+ "version" : " 1.2.3 " ,
44 "description" : " Make the screen not dim (and eventually lock the device) while Insomnia is active" ,
55 "main" : " insomnia" ,
66 "typings" : " index.d.ts" ,
2525 "author" : " Eddy Verbruggen <eddyverbruggen@gmail.com> (https://github.com/EddyVerbruggen)" ,
2626 "license" : " MIT" ,
2727 "bugs" : " https://github.com/eddyverbruggen/nativescript-insomnia/issues" ,
28- "homepage" : " https://github.com/eddyverbruggen/nativescript-insomnia"
28+ "homepage" : " https://github.com/eddyverbruggen/nativescript-insomnia" ,
29+ "devDependencies" : {
30+ "tns-core-modules" : " ~5.4.2" ,
31+ "tns-platform-declarations" : " ~5.4.2"
32+ }
2933}
You can’t perform that action at this time.
0 commit comments