summaryrefslogtreecommitdiff
path: root/examples/apps/ide/src
diff options
context:
space:
mode:
authorGraeme Geldenhuys <graeme@mastermaths.co.za>2013-03-13 17:09:44 +0000
committerGraeme Geldenhuys <graeme@mastermaths.co.za>2013-03-13 17:09:44 +0000
commit0971cad935fa6ce9058f76b63b28264abb1a54f5 (patch)
tree332fa337dcc36bced0890beba1d074a996e25eab /examples/apps/ide/src
parent2294374b3cc195e8803cbed93e94071074c12e22 (diff)
downloadfpGUI-0971cad935fa6ce9058f76b63b28264abb1a54f5.tar.xz
ide: extra checks to make sure we have an editor instance
Diffstat (limited to 'examples/apps/ide/src')
-rw-r--r--examples/apps/ide/src/frm_main.pas4
1 files changed, 4 insertions, 0 deletions
diff --git a/examples/apps/ide/src/frm_main.pas b/examples/apps/ide/src/frm_main.pas
index ac21da58..6d4e81b7 100644
--- a/examples/apps/ide/src/frm_main.pas
+++ b/examples/apps/ide/src/frm_main.pas
@@ -242,6 +242,8 @@ begin
Exit;
FLastFindBackward := False;
edt := TfpgTextEdit(pcEditor.ActivePage.Components[0]);
+ if not Assigned(edt) then
+ Exit;
edt.FindText(FLastSearchText, FLastFindOptions, FLastFindBackward);
edt.SetFocus;
end;
@@ -254,6 +256,8 @@ begin
Exit;
FLastFindBackward := True;
edt := TfpgTextEdit(pcEditor.ActivePage.Components[0]);
+ if not Assigned(edt) then
+ Exit;
edt.FindText(FLastSearchText, FLastFindOptions, FLastFindBackward);
edt.SetFocus;
end;