Skip to content

Commit

Permalink
Fix create note from different space error
Browse files Browse the repository at this point in the history
  • Loading branch information
sballin committed Sep 29, 2021
1 parent e8013be commit 975a63c
Showing 1 changed file with 7 additions and 2 deletions.
9 changes: 7 additions & 2 deletions info.plist
Original file line number Diff line number Diff line change
Expand Up @@ -901,8 +901,11 @@ on alfred_script(q)
show first note in default account
tell application "System Events"
tell process "Notes"
set focused of text area of scroll area of group 1 of splitter group 1 of splitter group 1 of window 1 to true
key code {125,125} -- down, down
-- Try because coming from a different space can cause an error
try
set focused of text area of scroll area of group 1 of splitter group 1 of splitter group 1 of window 1 to true
key code {125,125} -- down, down
end try
end tell
end tell
end if
Expand Down Expand Up @@ -1344,6 +1347,8 @@ or create note</string>
<key>sortByDate</key>
<string>1</string>
</dict>
<key>variablesdontexport</key>
<array/>
<key>version</key>
<string>3.5.1</string>
<key>webaddress</key>
Expand Down

0 comments on commit 975a63c

Please sign in to comment.