Skip to content
This repository has been archived by the owner on Jan 4, 2019. It is now read-only.

Commit

Permalink
Implement getAllInWindow
Browse files Browse the repository at this point in the history
  • Loading branch information
darkdh committed Jul 26, 2018
1 parent 69d80e6 commit 4cd780d
Showing 1 changed file with 12 additions and 0 deletions.
12 changes: 12 additions & 0 deletions atom/common/api/resources/tabs_bindings.js
Original file line number Diff line number Diff line change
Expand Up @@ -137,6 +137,18 @@ binding.registerCustomHook(function(bindingsAPI, extensionId) {
})
})

apiFunctions.setHandleRequest('getAllInWindow', function (windowId, cb) {
var responseId = ipc.guid()
var queryInfo = {windowId: windowId}
query(queryInfo, function (evt, tab, error) {
if (error) {
lastError.run('tabs.getAllInWindow', error, '', () => { cb(null) })
} else {
cb(tab)
}
})
})

apiFunctions.setHandleRequest('captureVisibleTab', function (windowId, options, cb) {
// return an empty image url
cb('data:image/gif;base64,R0lGODlhAQABAAAAACH5BAEKAAEALAAAAAABAAEAAAICTAEAOw==')
Expand Down

0 comments on commit 4cd780d

Please sign in to comment.