feat: add TextField API

This commit is contained in:
Cheng Zhao 2018-05-24 16:26:17 +09:00
parent 2eb5b751f3
commit ba3700141f
6 changed files with 112 additions and 1 deletions

View file

@ -21,6 +21,7 @@ module.exports = [
{name: 'screen', file: 'screen'},
{name: 'session', file: 'session'},
{name: 'systemPreferences', file: 'system-preferences'},
{name: 'TextField', file: 'text-field'},
{name: 'TopLevelWindow', file: 'top-level-window'},
{name: 'TouchBar', file: 'touch-bar'},
{name: 'Tray', file: 'tray'},

View file

@ -0,0 +1,15 @@
'use strict'
const electron = require('electron')
const {View} = electron
const {TextField} = process.atomBinding('text_field')
Object.setPrototypeOf(TextField.prototype, View.prototype)
TextField.prototype._init = function () {
// Call parent class's _init.
View.prototype._init.call(this)
}
module.exports = TextField