Options
All
  • Public
  • Public/Protected
  • All
Menu

Class SettingsHandler

handle settings (Set/Get them and their default values, ...)

Hierarchy

  • SettingsHandler

Index

Methods

isValidURL

  • isValidURL(urlToCheck: string): boolean

Static checkIfIdIsAllowed

  • checkIfIdIsAllowed(id: string, modifiable?: boolean): boolean

Static getDefaultValue

  • getDefaultValue(id: "restartInfo" | "windowBounds" | "minWindowBounds" | "searchFilter" | "sort" | "savedEntries" | "savedLinks" | "githubLatestReleaseUrl" | "nativeTitleBar" | "userName" | "userUrl" | "userPassword" | "minimizeToSystemTray" | "devMode" | "checkForUpdatesOnStartup" | "checkForUpdatesCronJob" | "checkForUpdatesCronJobConfiguration" | "checkForFeedCronJob" | "checkForFeedCronJobConfiguration" | "autoLaunch" | "globalShortcutShow", modifiable?: boolean): any
  • Get the default value of the setting

    Parameters

    • id: "restartInfo" | "windowBounds" | "minWindowBounds" | "searchFilter" | "sort" | "savedEntries" | "savedLinks" | "githubLatestReleaseUrl" | "nativeTitleBar" | "userName" | "userUrl" | "userPassword" | "minimizeToSystemTray" | "devMode" | "checkForUpdatesOnStartup" | "checkForUpdatesCronJob" | "checkForUpdatesCronJobConfiguration" | "checkForFeedCronJob" | "checkForFeedCronJobConfiguration" | "autoLaunch" | "globalShortcutShow"
    • Default value modifiable: boolean = false

      Specify if hidden or modifiable setting

    Returns any

Static getLocalValue

  • getLocalValue(id: "restartInfo" | "windowBounds" | "minWindowBounds" | "searchFilter" | "sort" | "savedEntries" | "savedLinks" | "githubLatestReleaseUrl" | "nativeTitleBar" | "userName" | "userUrl" | "userPassword" | "minimizeToSystemTray" | "devMode" | "checkForUpdatesOnStartup" | "checkForUpdatesCronJob" | "checkForUpdatesCronJobConfiguration" | "checkForFeedCronJob" | "checkForFeedCronJobConfiguration" | "autoLaunch" | "globalShortcutShow", modifiable?: boolean): any
  • Get the local value of the setting or the default if no local one was found

    Parameters

    • id: "restartInfo" | "windowBounds" | "minWindowBounds" | "searchFilter" | "sort" | "savedEntries" | "savedLinks" | "githubLatestReleaseUrl" | "nativeTitleBar" | "userName" | "userUrl" | "userPassword" | "minimizeToSystemTray" | "devMode" | "checkForUpdatesOnStartup" | "checkForUpdatesCronJob" | "checkForUpdatesCronJobConfiguration" | "checkForFeedCronJob" | "checkForFeedCronJobConfiguration" | "autoLaunch" | "globalShortcutShow"
    • Default value modifiable: boolean = false

      Specify if hidden or modifiable setting

    Returns any

    {import('../API/SettingsTypes').Hidden.SettingsType | import('../API/SettingsTypes').Modifiable.SettingsType | undefined}

Static getModifiableSettingsWithCurrentValue

Static getSettingsObjectByIdHelper

  • getSettingsObjectByIdHelper(settings: object[], id: string): any

Static getValue

  • getValue(id: "restartInfo" | "windowBounds" | "minWindowBounds" | "searchFilter" | "sort" | "savedEntries" | "savedLinks" | "githubLatestReleaseUrl" | "nativeTitleBar" | "userName" | "userUrl" | "userPassword" | "minimizeToSystemTray" | "devMode" | "checkForUpdatesOnStartup" | "checkForUpdatesCronJob" | "checkForUpdatesCronJobConfiguration" | "checkForFeedCronJob" | "checkForFeedCronJobConfiguration" | "autoLaunch" | "globalShortcutShow", modifiable?: boolean): any
  • Get settings object value

    Parameters

    • id: "restartInfo" | "windowBounds" | "minWindowBounds" | "searchFilter" | "sort" | "savedEntries" | "savedLinks" | "githubLatestReleaseUrl" | "nativeTitleBar" | "userName" | "userUrl" | "userPassword" | "minimizeToSystemTray" | "devMode" | "checkForUpdatesOnStartup" | "checkForUpdatesCronJob" | "checkForUpdatesCronJobConfiguration" | "checkForFeedCronJob" | "checkForFeedCronJobConfiguration" | "autoLaunch" | "globalShortcutShow"
    • Default value modifiable: boolean = false

      Specify if hidden or modifiable setting

    Returns any

Static makeModifiableTypeChecks

  • makeModifiableTypeChecks(type: "password" | "toggle" | "text" | "cronJob" | "url" | "keyboardShortcut", value: any): void

Static save

  • save(): void

Static setModifiableOrHidden

  • setModifiableOrHidden(id: "restartInfo" | "windowBounds" | "minWindowBounds" | "searchFilter" | "sort" | "savedEntries" | "savedLinks" | "githubLatestReleaseUrl" | "nativeTitleBar" | "userName" | "userUrl" | "userPassword" | "minimizeToSystemTray" | "devMode" | "checkForUpdatesOnStartup" | "checkForUpdatesCronJob" | "checkForUpdatesCronJobConfiguration" | "checkForFeedCronJob" | "checkForFeedCronJobConfiguration" | "autoLaunch" | "globalShortcutShow", value: any, modifiable?: boolean): void
  • Set hidden or modifiable settings

    Parameters

    • id: "restartInfo" | "windowBounds" | "minWindowBounds" | "searchFilter" | "sort" | "savedEntries" | "savedLinks" | "githubLatestReleaseUrl" | "nativeTitleBar" | "userName" | "userUrl" | "userPassword" | "minimizeToSystemTray" | "devMode" | "checkForUpdatesOnStartup" | "checkForUpdatesCronJob" | "checkForUpdatesCronJobConfiguration" | "checkForFeedCronJob" | "checkForFeedCronJobConfiguration" | "autoLaunch" | "globalShortcutShow"
    • value: any
    • Default value modifiable: boolean = false

      Specify if hidden or modifiable setting

    Returns void

Generated using TypeDoc