remove clipboard deprecations

This commit is contained in:
Shelley Vohr 2018-05-23 09:04:39 -07:00
parent b3edfd7d89
commit 438ac61ff7
No known key found for this signature in database
GPG key ID: F13993A75599653C
2 changed files with 0 additions and 66 deletions

View file

@ -2,41 +2,8 @@ if (process.platform === 'linux' && process.type === 'renderer') {
// On Linux we could not access clipboard in renderer process.
module.exports = require('electron').remote.clipboard
} else {
const {deprecate} = require('electron')
const clipboard = process.atomBinding('clipboard')
// TODO(codebytere): remove in 3.0
clipboard.readHtml = function () {
if (!process.noDeprecations) {
deprecate.warn('clipboard.readHtml', 'clipboard.readHTML')
}
return clipboard.readHTML()
}
// TODO(codebytere): remove in 3.0
clipboard.writeHtml = function () {
if (!process.noDeprecations) {
deprecate.warn('clipboard.writeHtml', 'clipboard.writeHTML')
}
return clipboard.writeHTML()
}
// TODO(codebytere): remove in 3.0
clipboard.readRtf = function () {
if (!process.noDeprecations) {
deprecate.warn('clipboard.readRtf', 'clipboard.writeRTF')
}
return clipboard.readRTF()
}
// TODO(codebytere): remove in 3.0
clipboard.writeRtf = function () {
if (!process.noDeprecations) {
deprecate.warn('clipboard.writeRtf', 'clipboard.writeRTF')
}
return clipboard.writeRTF()
}
// Read/write to find pasteboard over IPC since only main process is notified
// of changes
if (process.platform === 'darwin' && process.type === 'renderer') {