1
0
Fork 0
mirror of https://github.com/openstf/stf synced 2025-10-05 19:42:01 +02:00

Refactor InputAgent into STFService. Support copypasting (only pasting implemented in the UI right now though).

This commit is contained in:
Simo Kinnunen 2014-04-01 11:47:20 +09:00
parent 514fc3554d
commit 09eb8c539d
13 changed files with 379 additions and 50 deletions

View file

@ -347,6 +347,24 @@ module.exports = function(options) {
])
})
// Transactions
.on('clipboard.paste', function(channel, responseChannel, data) {
joinChannel(responseChannel)
push.send([
channel
, wireutil.envelope(new wire.PasteMessage(
data.text
))
])
})
.on('clipboard.copy', function(channel, responseChannel, data) {
joinChannel(responseChannel)
push.send([
channel
, wireutil.envelope(new wire.CopyMessage(
data.text
))
])
})
.on('device.identify', function(channel, responseChannel) {
push.send([
channel