Tengo una configuración de mac mini en un televisor para monitorear nuestra red. Me gustaría configurar las páginas de monitoreo que nos gustaría ver en un conjunto de pestañas y hacer que Safari las recorra automáticamente. Algo así como las estaciones de servicio usan para cambiar las transmisiones de video; algún tipo de conmutador automático.
Miré glims pero no parece tener la funcionalidad. ¿Hay alguna manera de hacer esto con safari base o alguien sabe de un complemento que hará este comportamiento en Safari?
Puede usar este bloque de AppleScript para recorrer sus pestañas en una ventana:
tell application "Safari"
repeat
repeat with i from (count of tabs of window 1) to 1 by -1
set thisTab to tab i of window 1
set current tab of window 1 to thisTab
delay 1
end repeat
end repeat
end tell
Esto pasará por todas sus pestañas y cambiará cada 1 segundo. Simplemente cambie el retraso para cambiar el tiempo antes de que cambie cada pestaña.
Me encontré queriendo actualizar las pestañas en muchas ventanas a la vez pasando a la siguiente pestaña y luego volviendo al principio.
En mi caso las ventanas se identifican por tener prefijo de título en común, y mi retraso es de 20s
tell application "Safari"
repeat
set theWindows to windows
set windowCount to count of theWindows
-- log windowCount as text
repeat with theWindow in theWindows
set windowName to name of theWindow
if windowName starts with "<common_prefix>" then
set tabCount to count of the tabs of theWindow
set currentTabIdx to index of current tab of theWindow
log currentTabIdx
if currentTabIdx = tabCount then
set currentTabIdx to 0
end if
set current tab of theWindow to tab (currentTabIdx + 1) of theWindow
end if
end repeat
delay 20
end repeat
end tell
Vlad
pedro gracia
stu wilson