electron/lib/browser/api/system-preferences.js

16 lines
554 B
JavaScript
Raw Normal View History

'use strict'
2018-09-13 16:10:51 +00:00
const { EventEmitter } = require('events')
const { deprecate } = require('electron')
const { systemPreferences, SystemPreferences } = process.electronBinding('system_preferences')
2016-04-24 12:13:46 +00:00
// SystemPreferences is an EventEmitter.
2016-08-02 11:38:35 +00:00
Object.setPrototypeOf(SystemPreferences.prototype, EventEmitter.prototype)
EventEmitter.call(systemPreferences)
2016-04-24 12:13:46 +00:00
if ('appLevelAppearance' in systemPreferences) {
deprecate.fnToProperty(systemPreferences, 'appLevelAppearance', '_getAppLevelAppearance', '_setAppLevelAppearance')
}
2016-04-24 12:13:46 +00:00
module.exports = systemPreferences