From 439d68c14fd37ed01b34ed37f74116148bc7382b Mon Sep 17 00:00:00 2001 From: alexs75 Date: Sun, 17 Feb 2013 14:31:05 +0000 Subject: [PATCH] RxDBGrid: fix compile with fpc 2.6 git-svn-id: https://svn.code.sf.net/p/lazarus-ccr/svn@2689 8e941d3f-bd1b-0410-a28a-d453659cc2b4 --- components/rx/languages/rxconst.uk.po | 4 ++-- components/rx/languages/rxdconst.uk.po | 1 + components/rx/rxdbgrid_findunit.pas | 12 +++++++++++- 3 files changed, 14 insertions(+), 3 deletions(-) diff --git a/components/rx/languages/rxconst.uk.po b/components/rx/languages/rxconst.uk.po index 6cd996c07..2d2c53ff5 100644 --- a/components/rx/languages/rxconst.uk.po +++ b/components/rx/languages/rxconst.uk.po @@ -95,8 +95,7 @@ msgid "Control not found in validate %s." msgstr "Елемент управління не знайдений в валідаторі %s" #: rxconst.sfilenotexec -msgid "" -"File specified is not an executable file, dynamic-link library, or icon file" +msgid "File specified is not an executable file, dynamic-link library, or icon file" msgstr "Вказаний файл не виконуваний, не бібліотека і не іконка" #: rxconst.sflatbuttons @@ -234,3 +233,4 @@ msgstr "Набір віджетів WinCE" #: rxconst.swindowsicofiles msgid "Windows Ico files (*.ico)|*.ico|All files (*.*)|*.*" msgstr "Файли іконок Windows (*.ico)|*.ico|Всі файли (*.*)|*.*" + diff --git a/components/rx/languages/rxdconst.uk.po b/components/rx/languages/rxdconst.uk.po index f59c7265b..0a5926a19 100644 --- a/components/rx/languages/rxdconst.uk.po +++ b/components/rx/languages/rxdconst.uk.po @@ -437,3 +437,4 @@ msgstr "Введіть ваш пароль" #: rxdconst.susernamelabel msgid "&User name:" msgstr "&Ім'я користувача" + diff --git a/components/rx/rxdbgrid_findunit.pas b/components/rx/rxdbgrid_findunit.pas index fc9a1dd0a..60d2eb358 100644 --- a/components/rx/rxdbgrid_findunit.pas +++ b/components/rx/rxdbgrid_findunit.pas @@ -31,7 +31,7 @@ Copyright (C) 2005-2010 Lagunov Aleksey alexs@hotbox.ru and Lazarus team unit rxdbgrid_findunit; -{$mode objfpc}{$H+} +{$I rx.inc} interface @@ -133,7 +133,11 @@ begin LOptions:=LOptions+[loPartialKey]; SearchOrigin:=TRxSearchDirection(RadioGroup1.ItemIndex); + {$IFDEF NoAutomatedBookmark} + P:=FDataSet.GetBookmark; + {$ELSE} P:=FDataSet.Bookmark; + {$ENDIF} if SearchOrigin = rsdForward then FDataSet.Next else @@ -141,8 +145,14 @@ begin FDataSet.Prior; R:=DataSetLocateThrough(FDataSet, FieldName, Edit1.Text, LOptions, SearchOrigin); finally + {$IFDEF NoAutomatedBookmark} + if not R then + FDataSet.GotoBookmark(P); + FDataSet.FreeBookmark(P); + {$ELSE} if not R then FDataSet.Bookmark:=P; + {$ENDIF} end; end; end;