mirror of
https://github.com/DeviceFarmer/stf.git
synced 2026-04-19 03:53:28 +02:00
Rename "input" plugin to "service". It does many more things than just input.
This commit is contained in:
@@ -7,14 +7,14 @@ var wireutil = require('../../../wire/util')
|
||||
module.exports = syrup.serial()
|
||||
.dependency(require('../support/router'))
|
||||
.dependency(require('../support/push'))
|
||||
.dependency(require('./input'))
|
||||
.define(function(options, router, push, input) {
|
||||
.dependency(require('./service'))
|
||||
.define(function(options, router, push, service) {
|
||||
var log = logger.createLogger('device:plugins:clipboard')
|
||||
|
||||
router.on(wire.PasteMessage, function(channel, message) {
|
||||
log.info('Pasting "%s" to clipboard', message.text)
|
||||
var reply = wireutil.reply(options.serial)
|
||||
input.paste(message.text)
|
||||
service.paste(message.text)
|
||||
.then(function() {
|
||||
push.send([
|
||||
channel
|
||||
@@ -33,7 +33,7 @@ module.exports = syrup.serial()
|
||||
router.on(wire.CopyMessage, function(channel) {
|
||||
log.info('Copying clipboard contents')
|
||||
var reply = wireutil.reply(options.serial)
|
||||
input.copy()
|
||||
service.copy()
|
||||
.then(function(content) {
|
||||
push.send([
|
||||
channel
|
||||
|
||||
Reference in New Issue
Block a user