Browse Source

* Patch from Graeme Geldenhuys:
* Minor classname adjustment
* Query.SQL.Text ---> Query.SQLText otherwise the setter method is bypassed,
which could contain custom code.
* uses clause cleanup

git-svn-id: trunk@11388 -

michael 17 years ago
parent
commit
d763279046
1 changed files with 4 additions and 4 deletions
  1. 4 4
      packages/fcl-db/src/codegen/fpcgtiopf.pp

+ 4 - 4
packages/fcl-db/src/codegen/fpcgtiopf.pp

@@ -125,8 +125,8 @@ end;
 constructor TTiOPFCodeOptions.Create;
 constructor TTiOPFCodeOptions.Create;
 begin
 begin
   inherited Create;
   inherited Create;
-  FListAncestorName:='TTiObjectList';
-  AncestorClass:='TTiObject';
+  FListAncestorName:='TtiObjectList';
+  AncestorClass:='TtiObject';
   ObjectClassName:='MyObject';
   ObjectClassName:='MyObject';
   FVisitorOptions:=[voRead,voCreate,voDelete,voUpdate];
   FVisitorOptions:=[voRead,voCreate,voDelete,voUpdate];
   FClassOptions:=[caCreateList,caListAddMethod,caListItemsProperty];
   FClassOptions:=[caCreateList,caListAddMethod,caListItemsProperty];
@@ -185,7 +185,7 @@ function TTiOPFCodeGenerator.GetInterfaceUsesClause: string;
 begin
 begin
   Result:=inherited GetInterfaceUsesClause;
   Result:=inherited GetInterfaceUsesClause;
   If (Result<>'') then
   If (Result<>'') then
-    Result:=Result+',';
+    Result:=Result+', ';
   Result:=Result+'tiVisitor, tiVisitorDB, tiObject';
   Result:=Result+'tiVisitor, tiVisitorDB, tiObject';
 end;
 end;
 
 
@@ -702,7 +702,7 @@ end;
 procedure TTiOPFCodeGenerator.WriteSetSQL(Strings : TStrings; Const ASQL : String);
 procedure TTiOPFCodeGenerator.WriteSetSQL(Strings : TStrings; Const ASQL : String);
 
 
 begin
 begin
-  Addln(Strings,Format('Query.SQL.Text:=%s;',[ASQL]));
+  Addln(Strings,Format('Query.SQLText:=%s;',[ASQL]));
 end;
 end;
 
 
 procedure TTiOPFCodeGenerator.WriteDeleteVisitor(Strings : TStrings; Const ObjectClassName : String);
 procedure TTiOPFCodeGenerator.WriteDeleteVisitor(Strings : TStrings; Const ObjectClassName : String);