3
如何在chrome中使用AppleScript在后台打开新选项卡。 打开一个标签似乎很容易,但我无法找到可以调用的背景中打开标签,这意味着活动标签保持不变。如何使用AppleScript在Chrome中的后台打开新选项卡
如何在chrome中使用AppleScript在后台打开新选项卡。 打开一个标签似乎很容易,但我无法找到可以调用的背景中打开标签,这意味着活动标签保持不变。如何使用AppleScript在Chrome中的后台打开新选项卡
可以保存在变量中active tab index
和设置回您创建标签后:
tell application "Google Chrome"
set activeIndex to get active tab index of window 1
tell window 1
set newTab to make new tab with properties {URL:"http://www.google.com/"}
end tell
set active tab index of window 1 to activeIndex
end tell