Namespace: Data

Data

Manage the extensions data

Source:

Members


<private, static, constant> _DATA_VERSION :int

Version of localStorage - update when items are added, removed, changed

Type:
  • int
Default Value:
  • 17
Source:

<private, static, constant> _DEF_VALUES :app.Data.LocalStorage

Default values in localStorage

Type:
Source:

Methods


<private, static> _addDefaults()

Save the _DEF_VALUES items, if they do not already exist

Source:

<private, static> _convertSliderValue(key)

Convert a setting-slider value due to addition of units

Parameters:
Name Type Description
key string

localStorage key

Source:

<private, static> _getTimeFormat() → {int}

Get default time format based on locale

Source:
Returns:

12 or 24

Type
int

<private, static> _processEnabled()

Set state based on screensaver enabled flag Note: this does not effect the keep awake settings so you could use the extension as a display keep awake scheduler without using the screensaver

Source:

<private, static> _processIdleTime()

Set wait time for screen saver display after machine is idle

Source:

<private, static> _processKeepAwake()

Set power scheduling features

Source:

<private, static> _setOS() → {Promise}

Set the 'os' value

Source:
Returns:

err on failure

Type
Promise

<static> initialize()

Initialize the data saved in localStorage

Source:

<static> processState( [key])

Process changes to localStorage items

Parameters:
Name Type Argument Default Description
key string <optional>
'all'

the item that changed

Source:

<static> restoreDefaults()

Restore default values for data saved in localStorage

Source:

<static> update()

Update the data saved in localStorage

Source:

Type Definitions


LocalStorage

Values for items in localStorage

Type:
  • Object
Properties:
Name Type Description
version int

version of data

enabled boolean

is screensaver enabled

permPicasa string

optional permission for Picasa

permBackground string

optional permission to run in bg

allowBackground boolean

run Chrome in background

idleTime app.Data.UnitValue

idle time to display screensaver

transitionTime app.Data.UnitValue

time between photos

skip boolean

ignore extreme aspect ratio photos

shuffle boolean

randomize photo order

photoSizing int

photo display type

photoTransition int

transition animation

interactive boolean

vcr controls for screensaver

showTime int

time display format

largeTime boolean

display larger time label

showPhotog boolean

display name on own photos

showLocation boolean

display photo location

background string

background image

keepAwake boolean

manage computer poser settings

chromeFullscreen boolean

don't display over fullscreen

allDisplays boolean

show on all displays

activeStart string

Keep Wake start time '00:00' 24 hr

activeStop string

Keep Wake stop time '00:00' 24 hr

allowSuspend boolean

let computer sleep

allowPhotoClicks boolean

show photo source on left click

useSpaceReddit boolean

use this photo source

useEarthReddit boolean

use this photo source

useAnimalReddit boolean

use this photo source

useEditors500px boolean

use this photo source

usePopular500px boolean

use this photo source

useYesterday500px boolean

use this photo source

useInterestingFlickr boolean

use this photo source

useChromecast boolean

use this photo source

useAuthors boolean

use this photo source

useSpaceReddit boolean

use this photo source

fullResGoogle boolean

true for actual size Google photos

isAlbumMode boolean

true if Google Photos album mode

useGoogle boolean

use this photo source

useGoogleAlbums boolean

use this photo source

albumSelections Array

user's selected Google Photos albums

useGooglePhotos boolean

use this photo source

Source:

UnitValue

A number and associated units

Type:
  • Object
Properties:
Name Type Description
base number

value in base unit

display number

value in display unit

unit int

display unit

Source: