diff options
author | Shin'ya Ueoka <ueokande@i-beam.org> | 2018-07-28 10:51:52 +0900 |
---|---|---|
committer | Shin'ya Ueoka <ueokande@i-beam.org> | 2018-07-28 14:20:29 +0900 |
commit | ccdb0a2428bbdc56e8288442f844a4bb3b8f9a11 (patch) | |
tree | c1d653b3792917473bace600d12a071b35f6168c /src/background/actions/tab.js | |
parent | 66c23423f931bb66c59cd29cf9279a5de5d56535 (diff) |
Clean old codes
Diffstat (limited to 'src/background/actions/tab.js')
-rw-r--r-- | src/background/actions/tab.js | 34 |
1 files changed, 0 insertions, 34 deletions
diff --git a/src/background/actions/tab.js b/src/background/actions/tab.js deleted file mode 100644 index 0f32a90..0000000 --- a/src/background/actions/tab.js +++ /dev/null @@ -1,34 +0,0 @@ -import actions from './index'; - -const openNewTab = async( - url, openerTabId, background = false, adjacent = false -) => { - if (!adjacent) { - await browser.tabs.create({ url, active: !background }); - return { type: '' }; - } - let tabs = await browser.tabs.query({ - active: true, currentWindow: true - }); - await browser.tabs.create({ - url, - openerTabId, - active: !background, - index: tabs[0].index + 1 - }); - return { type: '' }; -}; - -const openToTab = async(url, tab) => { - await browser.tabs.update(tab.id, { url: url }); - return { type: '' }; -}; - -const selected = (tabId) => { - return { - type: actions.TAB_SELECTED, - tabId, - }; -}; - -export { openNewTab, openToTab, selected }; |