-
Notifications
You must be signed in to change notification settings - Fork 44
Expand file tree
/
Copy pathToggle Sequential.applescript
More file actions
38 lines (28 loc) · 1.11 KB
/
Toggle Sequential.applescript
File metadata and controls
38 lines (28 loc) · 1.11 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
(*
# DESCRIPTION #
Toggles whether the selected item is sequential or parallel. Thanks to Brandon Pittman for your javascript-based version: https://gist.github.com/brandonpittman/c826c9feddf9eeb094eb
# LICENSE #
Copyright © 2015-2020 Dan Byler (contact: dbyler@gmail.com)
Licensed under MIT License (http://www.opensource.org/licenses/mit-license.php)
(TL;DR: no warranty, do whatever you want with it.)
# CHANGE HISTORY#
2020-02-16
- Updated for OmniFocus 3
2015-05-17
- Initial release
*)
tell application "OmniFocus"
tell content of first document window of front document
set validSelectedItemsList to value of (selected trees where class of its value is not item and class of its value is not folder and class of its value is not tag and class of its value is not perspective)
if (count of validSelectedItemsList) is 0 then return
set autosave to false
repeat with thisItem in validSelectedItemsList
if sequential of thisItem is false then
set sequential of thisItem to true
else
set sequential of thisItem to false
end if
end repeat
set autosave to true
end tell
end tell