Skip to content
This repository was archived by the owner on Aug 31, 2021. It is now read-only.

Commit fa4de52

Browse files
Merge pull request #2036 from livecode/bugfix-21414
[21414] Fix error when closing the SE and the Find window is still open
2 parents 909b9ac + c4d95c7 commit fa4de52

File tree

2 files changed

+11
-2
lines changed

2 files changed

+11
-2
lines changed

Toolset/palettes/script editor/behaviors/revsefindmaincardbehavior.livecodescript

Lines changed: 10 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -33,7 +33,11 @@ end menuPick
3333

3434
on closeCard
3535
historySave
36-
send "revSEFindFinalize" to (getCaller())
36+
local tCaller
37+
put getCaller() into tCaller
38+
if there is a stack tCaller then
39+
send "revSEFindFinalize" to tCaller
40+
end if
3741
pass closeCard
3842
end closeCard
3943

@@ -133,7 +137,11 @@ command updateButtonStates
133137
end updateButtonStates
134138

135139
private function getCaller
136-
return the long id of the cCaller of the owner of me
140+
if there is a stack (the cCaller of the owner of me) then
141+
return the long id of the cCaller of the owner of me
142+
else
143+
return empty
144+
end if
137145
end getCaller
138146

139147
# Returns

notes/bugfix-21414.md

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
# Fix error when closing the Script Editor and the Find window is still open

0 commit comments

Comments
 (0)