pressobjects-svn-commit Mailing List for PressObjects SDK
Status: Pre-Alpha
Brought to you by:
jcmoraisjr
You can subscribe to this list here.
2006 |
Jan
|
Feb
|
Mar
|
Apr
|
May
|
Jun
|
Jul
(9) |
Aug
(33) |
Sep
(14) |
Oct
(33) |
Nov
(60) |
Dec
(10) |
---|---|---|---|---|---|---|---|---|---|---|---|---|
2007 |
Jan
(33) |
Feb
(61) |
Mar
(47) |
Apr
(18) |
May
(96) |
Jun
(59) |
Jul
(70) |
Aug
(54) |
Sep
(56) |
Oct
(38) |
Nov
(37) |
Dec
(17) |
2008 |
Jan
(25) |
Feb
(24) |
Mar
(14) |
Apr
(15) |
May
(51) |
Jun
(47) |
Jul
(17) |
Aug
(10) |
Sep
(5) |
Oct
(42) |
Nov
(12) |
Dec
(24) |
2009 |
Jan
(18) |
Feb
(5) |
Mar
(2) |
Apr
|
May
|
Jun
|
Jul
|
Aug
(1) |
Sep
|
Oct
|
Nov
|
Dec
|
2010 |
Jan
|
Feb
|
Mar
|
Apr
|
May
(3) |
Jun
|
Jul
|
Aug
(7) |
Sep
(3) |
Oct
|
Nov
|
Dec
(1) |
2011 |
Jan
|
Feb
|
Mar
|
Apr
|
May
(2) |
Jun
(3) |
Jul
|
Aug
(1) |
Sep
|
Oct
|
Nov
|
Dec
|
2012 |
Jan
|
Feb
|
Mar
|
Apr
(4) |
May
(4) |
Jun
|
Jul
(1) |
Aug
|
Sep
|
Oct
|
Nov
(2) |
Dec
|
From: <jcm...@us...> - 2012-11-15 21:04:45
|
Revision: 1095 http://pressobjects.svn.sourceforge.net/pressobjects/?rev=1095&view=rev Author: jcmoraisjr Date: 2012-11-15 21:04:38 +0000 (Thu, 15 Nov 2012) Log Message: ----------- [MVP] Fixed path-references-nil error when using path as sub-presenter. Modified Paths: -------------- trunk/Source/Core/PressMVPModel.pas Modified: trunk/Source/Core/PressMVPModel.pas =================================================================== --- trunk/Source/Core/PressMVPModel.pas 2012-11-15 16:22:12 UTC (rev 1094) +++ trunk/Source/Core/PressMVPModel.pas 2012-11-15 21:04:38 UTC (rev 1095) @@ -2351,7 +2351,7 @@ begin VModel := FSubModelList[I] as TPressMVPAttributeModel; if Assigned(ASubject) then - VModel.Subject := ASubject.AttributeByPath(VModel.SubjectPath) + VModel.Subject := ASubject.FindPathAttribute(VModel.SubjectPath, False) else VModel.Subject := nil; end; This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <jcm...@us...> - 2012-11-15 16:22:18
|
Revision: 1094 http://pressobjects.svn.sourceforge.net/pressobjects/?rev=1094&view=rev Author: jcmoraisjr Date: 2012-11-15 16:22:12 +0000 (Thu, 15 Nov 2012) Log Message: ----------- [Metadata] Fixed signed number parsing. Modified Paths: -------------- trunk/Source/Core/PressMetadata.pas Modified: trunk/Source/Core/PressMetadata.pas =================================================================== --- trunk/Source/Core/PressMetadata.pas 2012-07-01 01:27:10 UTC (rev 1093) +++ trunk/Source/Core/PressMetadata.pas 2012-11-15 16:22:12 UTC (rev 1094) @@ -496,7 +496,11 @@ if IsValidIdent(Reader.NextChar) then VValue := Reader.ReadPath else + begin VValue := Reader.ReadToken; + if (VValue <> '') and (VValue[1] in ['-', '+']) then + VValue := VValue + Reader.ReadNumber; + end; Token := Reader.ReadToken; end else VValue := SPressTrueString; This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <jcm...@us...> - 2012-07-01 01:27:17
|
Revision: 1093 http://pressobjects.svn.sourceforge.net/pressobjects/?rev=1093&view=rev Author: jcmoraisjr Date: 2012-07-01 01:27:10 +0000 (Sun, 01 Jul 2012) Log Message: ----------- [Subject] Fixed exception trying to dereference an owned object. Modified Paths: -------------- trunk/Source/Core/PressAttributes.pas Modified: trunk/Source/Core/PressAttributes.pas =================================================================== --- trunk/Source/Core/PressAttributes.pas 2012-05-15 01:44:15 UTC (rev 1092) +++ trunk/Source/Core/PressAttributes.pas 2012-07-01 01:27:10 UTC (rev 1093) @@ -3891,7 +3891,7 @@ ChangeType: TPressProxyChangeType); begin inherited; - if Assigned(Instance) and Instance.IsOwned then + if Assigned(Instance) and Instance.IsOwned and (ChangeType = pctAssigning) then raise EPressError.CreateFmt(SInstanceAlreadyOwned, [Instance.ClassType, Instance.Id]); end; This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <jcm...@us...> - 2012-05-15 01:44:22
|
Revision: 1092 http://pressobjects.svn.sourceforge.net/pressobjects/?rev=1092&view=rev Author: jcmoraisjr Date: 2012-05-15 01:44:15 +0000 (Tue, 15 May 2012) Log Message: ----------- [Web] Moving fcgi broker to the web package. Modified Paths: -------------- trunk/Source/Packages/Laz/PressLazBrokersRT.lpk trunk/Source/Packages/Laz/PressLazWebRT.lpk Modified: trunk/Source/Packages/Laz/PressLazBrokersRT.lpk =================================================================== --- trunk/Source/Packages/Laz/PressLazBrokersRT.lpk 2012-05-04 01:00:39 UTC (rev 1091) +++ trunk/Source/Packages/Laz/PressLazBrokersRT.lpk 2012-05-15 01:44:15 UTC (rev 1092) @@ -1,27 +1,21 @@ <?xml version="1.0"?> <CONFIG> - <Package Version="3"> + <Package Version="4"> <PathDelim Value="\"/> <Name Value="PressLazBrokersRT"/> - <AddToProjectUsesSection Value="False"/> <CompilerOptions> - <Version Value="8"/> + <Version Value="11"/> <PathDelim Value="\"/> <SearchPaths> - <OtherUnitFiles Value="..\..\Brokers\"/> + <OtherUnitFiles Value="..\..\Brokers"/> <UnitOutputDirectory Value="..\..\..\bin\Laz\Brokers\$(TargetCPU)-$(TargetOS)"/> </SearchPaths> - <Parsing> - <SyntaxOptions> - <UseAnsiStrings Value="True"/> - </SyntaxOptions> - </Parsing> <Other> <CompilerPath Value="$(CompPath)"/> </Other> </CompilerOptions> <Version Minor="1" Release="1"/> - <Files Count="7"> + <Files Count="6"> <Item1> <Filename Value="..\..\Brokers\Press.inc"/> <Type Value="Include"/> @@ -43,13 +37,9 @@ <UnitName Value="PressPgSQLBroker"/> </Item5> <Item6> - <Filename Value="..\..\Brokers\PressWebFCLFCGIBroker.pas"/> - <UnitName Value="PressWebFCLFCGIBroker"/> - </Item6> - <Item7> <Filename Value="..\..\Brokers\PressXCLBroker.pas"/> <UnitName Value="PressXCLBroker"/> - </Item7> + </Item6> </Files> <RequiredPkgs Count="2"> <Item1> Modified: trunk/Source/Packages/Laz/PressLazWebRT.lpk =================================================================== --- trunk/Source/Packages/Laz/PressLazWebRT.lpk 2012-05-04 01:00:39 UTC (rev 1091) +++ trunk/Source/Packages/Laz/PressLazWebRT.lpk 2012-05-15 01:44:15 UTC (rev 1092) @@ -15,7 +15,7 @@ </Other> </CompilerOptions> <Version Minor="1" Release="1"/> - <Files Count="2"> + <Files Count="3"> <Item1> <Filename Value="..\..\Core\PressWebHandler.pas"/> <UnitName Value="PressWebHandler"/> @@ -24,6 +24,10 @@ <Filename Value="..\..\Brokers\PressWebFCLCGIBroker.pas"/> <UnitName Value="PressWebFCLCGIBroker"/> </Item2> + <Item3> + <Filename Value="..\..\Brokers\PressWebFCLFCGIBroker.pas"/> + <UnitName Value="PressWebFCLFCGIBroker"/> + </Item3> </Files> <RequiredPkgs Count="2"> <Item1> This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <jcm...@us...> - 2012-05-04 01:00:45
|
Revision: 1091 http://pressobjects.svn.sourceforge.net/pressobjects/?rev=1091&view=rev Author: jcmoraisjr Date: 2012-05-04 01:00:39 +0000 (Fri, 04 May 2012) Log Message: ----------- [OPF] Implemented Unique metadata. Modified Paths: -------------- trunk/Source/Core/PressOPFStorage.pas trunk/Source/Core/PressSubject.pas Modified: trunk/Source/Core/PressOPFStorage.pas =================================================================== --- trunk/Source/Core/PressOPFStorage.pas 2012-05-02 23:36:04 UTC (rev 1090) +++ trunk/Source/Core/PressOPFStorage.pas 2012-05-04 01:00:39 UTC (rev 1091) @@ -714,16 +714,20 @@ var VField: TPressOPFFieldMetadata; VFieldOptions: TPressOPFFieldOptions; + VIndexOptions: TPressOPFIndexOptions; begin VFieldOptions := []; if AAttributeMetadata.NotNull then VFieldOptions := VFieldOptions + [foNotNull]; if AAttributeMetadata.Index then VFieldOptions := VFieldOptions + [foIndexed]; + VIndexOptions := []; + if AAttributeMetadata.Unique then + VIndexOptions := VIndexOptions + [ioUnique]; VField := AddField( AAttributeMetadata.PersistentName, AAttributeMetadata.ShortName, AAttributeMetadata.AttributeClass.AttributeBaseType, - AAttributeMetadata.Size, VFieldOptions, [], ATableMetadata); + AAttributeMetadata.Size, VFieldOptions, VIndexOptions, ATableMetadata); if AStorageMap.Metadata.IdMetadata = AAttributeMetadata then begin ATableMetadata.PrimaryKey := TPressOPFIndexMetadata.Create( Modified: trunk/Source/Core/PressSubject.pas =================================================================== --- trunk/Source/Core/PressSubject.pas 2012-05-02 23:36:04 UTC (rev 1090) +++ trunk/Source/Core/PressSubject.pas 2012-05-04 01:00:39 UTC (rev 1091) @@ -156,11 +156,13 @@ FPersLinkPosName: string; FShortName: string; FSize: Integer; + FUnique: Boolean; FWeakReference: Boolean; function BuildPersLinkChildName: string; function BuildPersLinkName: string; function BuildPersLinkParentName: string; function DefaultLazyLoadState: Boolean; + function GetIndex: Boolean; function GetPersLinkChildName: string; function GetPersLinkName: string; function GetPersLinkParentName: string; @@ -209,7 +211,7 @@ property DefaultValue: string read FDefaultValue write FDefaultValue; property EditMask: string read FEditMask write FEditMask; property GeneratorName: string read FGeneratorName write FGeneratorName; - property Index: Boolean read FIndex write FIndex; + property Index: Boolean read GetIndex write FIndex; property IsPersistent: Boolean read FIsPersistent write FIsPersistent default True; property LazyLoad: Boolean read FLazyLoad write FLazyLoad stored StoreLazyLoad; property NotNull: Boolean read FNotNull write FNotNull; @@ -220,6 +222,7 @@ property PersLinkParentName: string read GetPersLinkParentName write FPersLinkParentName stored StorePersLinkParentName; property PersLinkPosName: string read FPersLinkPosName write FPersLinkPosName stored StorePersLinkPosName; property ShortName: string read GetShortName write FShortName stored StoreShortName; + property Unique: Boolean read FUnique write FUnique default False; property WeakReference: Boolean read FWeakReference write FWeakReference default False; end; @@ -1562,6 +1565,11 @@ FAttributeClass.InheritsFrom(TPressItems); end; +function TPressAttributeMetadata.GetIndex: Boolean; +begin + Result := FIndex or Unique; +end; + procedure TPressAttributeMetadata.Finit; begin FCalcMetadata.Free; This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <jcm...@us...> - 2012-05-02 23:36:10
|
Revision: 1090 http://pressobjects.svn.sourceforge.net/pressobjects/?rev=1090&view=rev Author: jcmoraisjr Date: 2012-05-02 23:36:04 +0000 (Wed, 02 May 2012) Log Message: ----------- [Web] Fixed mime type. Property Changed: ---------------- trunk/Source/Brokers/PressWebFCLCGIBroker.pas trunk/Source/Brokers/PressWebFCLFCGIBroker.pas trunk/Source/Packages/Laz/PressLazBrokersRT.lpk Property changes on: trunk/Source/Brokers/PressWebFCLCGIBroker.pas ___________________________________________________________________ Modified: svn:mime-type - text/html + text/plain Property changes on: trunk/Source/Brokers/PressWebFCLFCGIBroker.pas ___________________________________________________________________ Modified: svn:mime-type - text/html + text/plain Property changes on: trunk/Source/Packages/Laz/PressLazBrokersRT.lpk ___________________________________________________________________ Modified: svn:mime-type - text/html + text/plain This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <sil...@us...> - 2012-05-02 03:36:17
|
Revision: 1089 http://pressobjects.svn.sourceforge.net/pressobjects/?rev=1089&view=rev Author: silvioprog Date: 2012-05-02 03:36:11 +0000 (Wed, 02 May 2012) Log Message: ----------- [Web] Web broker for Fast-CGI. Modified Paths: -------------- trunk/Source/Brokers/PressWebFCLCGIBroker.pas trunk/Source/Packages/Laz/PressLazBrokersRT.lpk Added Paths: ----------- trunk/Source/Brokers/PressWebFCLFCGIBroker.pas Property Changed: ---------------- trunk/Source/Brokers/PressWebFCLCGIBroker.pas trunk/Source/Packages/Laz/PressLazBrokersRT.lpk Modified: trunk/Source/Brokers/PressWebFCLCGIBroker.pas =================================================================== --- trunk/Source/Brokers/PressWebFCLCGIBroker.pas 2012-04-25 22:17:34 UTC (rev 1088) +++ trunk/Source/Brokers/PressWebFCLCGIBroker.pas 2012-05-02 03:36:11 UTC (rev 1089) @@ -1,6 +1,20 @@ +(* + PressObjects, FCL-Web Broker + Copyright (C) 2007 Laserpress Ltda. + + http://www.pressobjects.org + + See the file LICENSE.txt, included in this distribution, + for details about the copyright. + + This library is distributed in the hope that it will be useful, + but WITHOUT ANY WARRANTY; without even the implied warranty of + MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. +*) + unit PressWebFCLCGIBroker; -{$mode objfpc}{$H+} +{$I Press.inc} interface Property changes on: trunk/Source/Brokers/PressWebFCLCGIBroker.pas ___________________________________________________________________ Modified: svn:mime-type - text/plain + text/html Added: trunk/Source/Brokers/PressWebFCLFCGIBroker.pas =================================================================== --- trunk/Source/Brokers/PressWebFCLFCGIBroker.pas (rev 0) +++ trunk/Source/Brokers/PressWebFCLFCGIBroker.pas 2012-05-02 03:36:11 UTC (rev 1089) @@ -0,0 +1,164 @@ +(* + PressObjects, FCL-Web Fast-CGI Broker + Copyright (C) 2007 Laserpress Ltda. + + http://www.pressobjects.org + + Collaborator(s): + . sil...@gm... + + See the file LICENSE.txt, included in this distribution, + for details about the copyright. + + This library is distributed in the hope that it will be useful, + but WITHOUT ANY WARRANTY; without even the implied warranty of + MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. +*) + +unit PressWebFCLFCGIBroker; + +{$I Press.inc} + +interface + +uses + HTTPDefs, + custweb, + custfcgi, + Classes, + PressClasses, + PressApplication, + PressWebHandler; + +type + + TPressWebFCLFCGIApp = class; + + { TPressWebFCLFCGIAppManager } + + TPressWebFCLFCGIAppManager = class(TPressManagedIObject, IPressAppManager) + private + FApp: TPressWebFCLFCGIApp; + FIdleMethod: TPressIdleMethod; + FOnIdle: TNotifyEvent; + procedure AppIdle(ASender: TObject); + protected + procedure Finit; override; + public + procedure Done; + procedure Finalize; + function HasMainForm: Boolean; + procedure IdleNotification(AIdleMethod: TPressIdleMethod); + procedure Init; + function MainForm: TObject; + procedure Run; + end; + + { TPressWebFCLFCGIHandler } + + TPressWebFCLFCGIHandler = class(TFCGIHandler) + public + procedure HandleRequest(ARequest: TRequest; AResponse: TResponse); override; + end; + + { TPressWebFCLFCGIApp } + + TPressWebFCLFCGIApp = class(TCustomFCGIApplication) + private + function GetOnIdle: TNotifyEvent; + procedure SetOnIdle(const AValue: TNotifyEvent); + protected + function InitializeWebHandler: TWebHandler; override; + property OnIdle: TNotifyEvent read GetOnIdle write SetOnIdle; + end; + +implementation + +uses + SysUtils; + +{ TPressWebFCLFCGIAppManager } + +procedure TPressWebFCLFCGIAppManager.AppIdle(ASender: TObject); +begin + if Assigned(FIdleMethod) then + FIdleMethod; + if Assigned(FOnIdle) then + FOnIdle(ASender); +end; + +procedure TPressWebFCLFCGIAppManager.Finit; +begin + FApp.OnIdle := nil; + FreeAndNil(FApp); + inherited Finit; +end; + +procedure TPressWebFCLFCGIAppManager.Done; +begin + FApp.OnIdle := FOnIdle; +end; + +procedure TPressWebFCLFCGIAppManager.Finalize; +begin +end; + +function TPressWebFCLFCGIAppManager.HasMainForm: Boolean; +begin + Result := False; +end; + +procedure TPressWebFCLFCGIAppManager.IdleNotification(AIdleMethod: TPressIdleMethod); +begin + FIdleMethod := AIdleMethod; +end; + +procedure TPressWebFCLFCGIAppManager.Init; +begin + FreeAndNil(FApp); + FApp := TPressWebFCLFCGIApp.Create(nil); + FOnIdle := FApp.OnIdle; + FApp.OnIdle := @AppIdle; + FApp.Initialize; +end; + +function TPressWebFCLFCGIAppManager.MainForm: TObject; +begin + Result := nil; +end; + +procedure TPressWebFCLFCGIAppManager.Run; +begin + FApp.Run; +end; + +{ TPressWebFCLFCGIHandler } + +procedure TPressWebFCLFCGIHandler.HandleRequest(ARequest: TRequest; + AResponse: TResponse); +begin + TPressWebHandler.DefaultService.HandleRequest(ARequest, AResponse); +end; + +{ TPressWebFCLFCGIApp } + +function TPressWebFCLFCGIApp.InitializeWebHandler: TWebHandler; +begin + Result := TPressWebFCLFCGIHandler.Create(Self); +end; + +function TPressWebFCLFCGIApp.GetOnIdle: TNotifyEvent; +begin + Result := WebHandler.OnIdle; +end; + +procedure TPressWebFCLFCGIApp.SetOnIdle(const AValue: TNotifyEvent); +begin + WebHandler.OnIdle := AValue; +end; + +initialization + PressApp.RegisterAppManager(TPressWebFCLFCGIAppManager.Create); + +end. + Property changes on: trunk/Source/Brokers/PressWebFCLFCGIBroker.pas ___________________________________________________________________ Added: svn:mime-type + text/html Added: svn:eol-style + native Modified: trunk/Source/Packages/Laz/PressLazBrokersRT.lpk =================================================================== --- trunk/Source/Packages/Laz/PressLazBrokersRT.lpk 2012-04-25 22:17:34 UTC (rev 1088) +++ trunk/Source/Packages/Laz/PressLazBrokersRT.lpk 2012-05-02 03:36:11 UTC (rev 1089) @@ -21,31 +21,35 @@ </Other> </CompilerOptions> <Version Minor="1" Release="1"/> - <Files Count="6"> + <Files Count="7"> <Item1> - <Filename Value="..\..\Brokers\PressXCLBroker.pas"/> - <UnitName Value="PressXCLBroker"/> + <Filename Value="..\..\Brokers\Press.inc"/> + <Type Value="Include"/> </Item1> <Item2> - <Filename Value="..\..\Brokers\Press.inc"/> - <Type Value="Include"/> + <Filename Value="..\..\Brokers\PressDataSetBroker.pas"/> + <UnitName Value="PressDataSetBroker"/> </Item2> <Item3> - <Filename Value="..\..\Brokers\PressDataSetBroker.pas"/> - <UnitName Value="PressDataSetBroker"/> + <Filename Value="..\..\Brokers\PressIBFbBroker.pas"/> + <UnitName Value="PressIBFbBroker"/> </Item3> <Item4> - <Filename Value="..\..\Brokers\PressIBFbBroker.pas"/> - <UnitName Value="PressIBFbBroker"/> + <Filename Value="..\..\Brokers\PressOracleBroker.pas"/> + <UnitName Value="PressOracleBroker"/> </Item4> <Item5> - <Filename Value="..\..\Brokers\PressOracleBroker.pas"/> - <UnitName Value="PressOracleBroker"/> + <Filename Value="..\..\Brokers\PressPgSQLBroker.pas"/> + <UnitName Value="PressPgSQLBroker"/> </Item5> <Item6> - <Filename Value="..\..\Brokers\PressPgSQLBroker.pas"/> - <UnitName Value="PressPgSQLBroker"/> + <Filename Value="..\..\Brokers\PressWebFCLFCGIBroker.pas"/> + <UnitName Value="PressWebFCLFCGIBroker"/> </Item6> + <Item7> + <Filename Value="..\..\Brokers\PressXCLBroker.pas"/> + <UnitName Value="PressXCLBroker"/> + </Item7> </Files> <RequiredPkgs Count="2"> <Item1> Property changes on: trunk/Source/Packages/Laz/PressLazBrokersRT.lpk ___________________________________________________________________ Modified: svn:mime-type - text/plain + text/html This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <sil...@us...> - 2012-04-25 22:17:40
|
Revision: 1088 http://pressobjects.svn.sourceforge.net/pressobjects/?rev=1088&view=rev Author: silvioprog Date: 2012-04-25 22:17:34 +0000 (Wed, 25 Apr 2012) Log Message: ----------- [Web] Removes irrelevant informations. Modified Paths: -------------- trunk/Source/Packages/Laz/PressLazWebRT.lpk Modified: trunk/Source/Packages/Laz/PressLazWebRT.lpk =================================================================== --- trunk/Source/Packages/Laz/PressLazWebRT.lpk 2012-04-25 02:48:36 UTC (rev 1087) +++ trunk/Source/Packages/Laz/PressLazWebRT.lpk 2012-04-25 22:17:34 UTC (rev 1088) @@ -3,12 +3,11 @@ <Package Version="4"> <PathDelim Value="\"/> <Name Value="PressLazWebRT"/> - <AddToProjectUsesSection Value="True"/> <CompilerOptions> <Version Value="11"/> <PathDelim Value="\"/> <SearchPaths> - <OtherUnitFiles Value="..\..\Brokers;\home\jcmoraisjr\devel\press\Source\Core\"/> + <OtherUnitFiles Value="..\..\Brokers;..\..\Core"/> <UnitOutputDirectory Value="..\..\..\bin\Laz\Brokers\$(TargetCPU)-$(TargetOS)"/> </SearchPaths> <Other> This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <jcm...@us...> - 2012-04-25 02:48:42
|
Revision: 1087 http://pressobjects.svn.sourceforge.net/pressobjects/?rev=1087&view=rev Author: jcmoraisjr Date: 2012-04-25 02:48:36 +0000 (Wed, 25 Apr 2012) Log Message: ----------- [Web] Persistence sample. Modified Paths: -------------- trunk/Demos/WebBasic/WebBasic.lpi trunk/Demos/WebBasic/WebBasic.lpr trunk/Demos/WebBasic/WebBrokers.pas trunk/Demos/WebBasic/WebHome.pas Added Paths: ----------- trunk/Demos/WebBasic/PersonBO.pas trunk/Demos/WebBasic/WebBasic.cf trunk/Demos/WebBasic/WebPerson.pas Added: trunk/Demos/WebBasic/PersonBO.pas =================================================================== --- trunk/Demos/WebBasic/PersonBO.pas (rev 0) +++ trunk/Demos/WebBasic/PersonBO.pas 2012-04-25 02:48:36 UTC (rev 1087) @@ -0,0 +1,54 @@ +unit PersonBO; + +{$mode objfpc}{$H+} + +interface + +uses + PressSubject, + PressAttributes; + +type + + { TPerson } + + TPerson = class(TPressObject) + _Name: TPressString; + private + function GetName: string; + procedure SetName(AValue: string); + protected + class function InternalMetadataStr: string; override; + published + property Name: string read GetName write SetName; + end; + +implementation + +{ TPerson } + +function TPerson.GetName: string; +begin + Result := _Name.Value; +end; + +procedure TPerson.SetName(AValue: string); +begin + _Name.Value := AValue; +end; + +class function TPerson.InternalMetadataStr: string; +begin + Result := 'TPerson IsPersistent PersistentName="Person" (' + + 'Name: String(60) PersistentName="PersonName";' + + ')'; +end; + +initialization + TPerson.RegisterClass; + +finalization + TPerson.UnregisterClass; + +end. + Property changes on: trunk/Demos/WebBasic/PersonBO.pas ___________________________________________________________________ Added: svn:mime-type + text/plain Added: svn:eol-style + native Added: trunk/Demos/WebBasic/WebBasic.cf =================================================================== --- trunk/Demos/WebBasic/WebBasic.cf (rev 0) +++ trunk/Demos/WebBasic/WebBasic.cf 2012-04-25 02:48:36 UTC (rev 1087) @@ -0,0 +1,9 @@ +[OPFBroker] +DefaultServiceName := 'SQLdb'; + +[OPFBroker.SQLdb] +Connector.Database.ConnectorType := 'postgresql'; +Connector.Database.Hostname := 'localhost'; +Connector.Database.DatabaseName := 'webbasic'; +Connector.Database.UserName := 'webbasic'; +Connector.Database.Password := 'abc'; Property changes on: trunk/Demos/WebBasic/WebBasic.cf ___________________________________________________________________ Added: svn:mime-type + text/plain Added: svn:eol-style + native Modified: trunk/Demos/WebBasic/WebBasic.lpi =================================================================== --- trunk/Demos/WebBasic/WebBasic.lpi 2012-04-25 02:44:15 UTC (rev 1086) +++ trunk/Demos/WebBasic/WebBasic.lpi 2012-04-25 02:48:36 UTC (rev 1087) @@ -35,21 +35,24 @@ <LaunchingApplication PathPlusParams="/usr/bin/xterm -T 'Lazarus Run Output' -e $(LazarusDir)/tools/runwait.sh $(TargetCmdLine)"/> </local> </RunParams> - <RequiredPackages Count="4"> + <RequiredPackages Count="5"> <Item1> - <PackageName Value="PressLazWebRT"/> + <PackageName Value="PressLazSQLdbRT"/> </Item1> <Item2> - <PackageName Value="PressLazCoreRT"/> + <PackageName Value="PressLazWebRT"/> </Item2> <Item3> - <PackageName Value="WebLaz"/> + <PackageName Value="PressLazCoreRT"/> </Item3> <Item4> + <PackageName Value="WebLaz"/> + </Item4> + <Item5> <PackageName Value="FCL"/> - </Item4> + </Item5> </RequiredPackages> - <Units Count="5"> + <Units Count="7"> <Unit0> <Filename Value="WebBasic.lpr"/> <IsPartOfProject Value="True"/> @@ -75,6 +78,16 @@ <IsPartOfProject Value="True"/> <UnitName Value="WebHome"/> </Unit4> + <Unit5> + <Filename Value="PersonBO.pas"/> + <IsPartOfProject Value="True"/> + <UnitName Value="PersonBO"/> + </Unit5> + <Unit6> + <Filename Value="WebPerson.pas"/> + <IsPartOfProject Value="True"/> + <UnitName Value="WebPerson"/> + </Unit6> </Units> </ProjectOptions> <CompilerOptions> Modified: trunk/Demos/WebBasic/WebBasic.lpr =================================================================== --- trunk/Demos/WebBasic/WebBasic.lpr 2012-04-25 02:44:15 UTC (rev 1086) +++ trunk/Demos/WebBasic/WebBasic.lpr 2012-04-25 02:48:36 UTC (rev 1087) @@ -4,7 +4,7 @@ heaptrc, PressApplication, PressLazWebRT, WebBrokers, - WebHelloWorld, WebInfo, WebHome; + WebHelloWorld, WebInfo, WebHome, PersonBO, WebPerson; begin PressApp.Run; Modified: trunk/Demos/WebBasic/WebBrokers.pas =================================================================== --- trunk/Demos/WebBasic/WebBrokers.pas 2012-04-25 02:44:15 UTC (rev 1086) +++ trunk/Demos/WebBasic/WebBrokers.pas 2012-04-25 02:48:36 UTC (rev 1087) @@ -6,9 +6,19 @@ uses PressMessages_ptbr, + PressSubject, + PressAttributes, + PressSQLdbBroker, + pqconnection, PressWebFCLCGIBroker; implementation +initialization + PressModel.DefaultKeyType := TPressInt64; + PressModel.DefaultGeneratorName := 'gen_oid'; + PressModel.ClassIdType := TPressInt64; + PressModel.ClassIdStorageName := 'Classes'; + end. Modified: trunk/Demos/WebBasic/WebHome.pas =================================================================== --- trunk/Demos/WebBasic/WebHome.pas 2012-04-25 02:44:15 UTC (rev 1086) +++ trunk/Demos/WebBasic/WebHome.pas 2012-04-25 02:48:36 UTC (rev 1087) @@ -31,7 +31,7 @@ procedure TWebIndexRequestHandler.HandleRequest(ARequest: TRequest; AResponse: TResponse); begin - AResponse.Contents.Add('<a href="WebBasic/">Go Home</a><br/>'); + AResponse.Contents.Add('<a href="' + ARequest.ScriptName + '/">Home</a><br/>'); end; { TWebHomeRequestHandler } @@ -40,7 +40,8 @@ AResponse: TResponse); begin AResponse.Contents.Add('<a href="hello">Hello</a><br/>'); - AResponse.Contents.Add('<a href="info">Info</a><br/>'); + AResponse.Contents.Add('<a href="info">Info</a> (http content)<br/>'); + AResponse.Contents.Add('<a href="person/">Person</a> (Persistence)<br/>'); end; initialization Added: trunk/Demos/WebBasic/WebPerson.pas =================================================================== --- trunk/Demos/WebBasic/WebPerson.pas (rev 0) +++ trunk/Demos/WebBasic/WebPerson.pas 2012-04-25 02:48:36 UTC (rev 1087) @@ -0,0 +1,64 @@ +unit WebPerson; + +{$mode objfpc}{$H+} + +interface + +uses + HTTPDefs, + PressWebHandler; + +type + + { TPersonRequestHandler } + + TPersonRequestHandler = class(TInterfacedObject, IPressWebRequestHandler) + protected + procedure HandleRequest(ARequest: TRequest; AResponse: TResponse); + end; + +implementation + +uses + PressOPF, + PersonBO; + +{ TPersonRequestHandler } + +procedure TPersonRequestHandler.HandleRequest(ARequest: TRequest; + AResponse: TResponse); +var + VPerson: TPerson; +begin + AResponse.Contents.Add('<html><head><meta charset="UTF-8"></head><body>'); + if ARequest.PathInfo = '/person/save' then + begin + VPerson := TPerson.Create; + try + VPerson.Name := ARequest.ContentFields.Values['name']; + PressOPFService.Store(VPerson); + AResponse.Contents.Add(VPerson.Name + ' saved'); + finally + VPerson.Free; + end; + end else if ARequest.PathInfo = '/person/ddl' then + begin + AResponse.Contents.Add('<textarea cols="60" rows="30">'); + AResponse.Contents.Add(PressOPFService.CreateDatabaseStatement); + AResponse.Contents.Add('</textarea>'); + end else + begin + AResponse.Contents.Add('<form method="post" action="' + ARequest.ScriptName + '/person/save">'); + AResponse.Contents.Add('Name: <input type="text" name="name" value="">'); + AResponse.Contents.Add('<input type="submit" value="Save">'); + AResponse.Contents.Add('</form>'); + AResponse.Contents.Add('<a href="' + ARequest.ScriptName + '/person/ddl">DDL</a>'); + end; + AResponse.Contents.Add('<body></html>'); +end; + +initialization + TPressWebHandler.DefaultService.RegisterRequestHandler('/person/*', TPersonRequestHandler.Create); + +end. + Property changes on: trunk/Demos/WebBasic/WebPerson.pas ___________________________________________________________________ Added: svn:mime-type + text/plain Added: svn:eol-style + native This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <jcm...@us...> - 2012-04-25 02:44:21
|
Revision: 1086 http://pressobjects.svn.sourceforge.net/pressobjects/?rev=1086&view=rev Author: jcmoraisjr Date: 2012-04-25 02:44:15 +0000 (Wed, 25 Apr 2012) Log Message: ----------- [Web] Minor fixes. Modified Paths: -------------- trunk/Demos/WebBasic/WebInfo.pas Modified: trunk/Demos/WebBasic/WebInfo.pas =================================================================== --- trunk/Demos/WebBasic/WebInfo.pas 2012-04-16 03:40:07 UTC (rev 1085) +++ trunk/Demos/WebBasic/WebInfo.pas 2012-04-25 02:44:15 UTC (rev 1086) @@ -31,7 +31,7 @@ var I: Integer; begin - AResponse.Contents.Add('<h2>hello</h2>'); + AResponse.Contents.Add('<h2>Info</h2>'); AResponse.Contents.Add('<form method="post" enctype="multipart/form-data" action="' + ARequest.ScriptName + ARequest.PathInfo + '">'); AResponse.Contents.Add('<input type="file" name="f">'); AResponse.Contents.Add('<input type="text" name="a" value="b">'); @@ -78,7 +78,7 @@ ARequest.Files.Files[I].LocalFileName + ' - ' + ARequest.Files.Files[I].ContentType); AResponse.Contents.Add('Fields:'); for I := 0 to Pred(ARequest.FieldCount) do - AResponse.Contents.Add(IntToStr(I) + ': ' + ARequest.Fields[I] + ' - ' + ARequest.FieldNames[I] + ' - ' + ARequest.FieldValues[I]); + AResponse.Contents.Add(IntToStr(I) + ': ' + ARequest.FieldNames[I] + ': ' + ARequest.FieldValues[I]); AResponse.Contents.Add('CookieFields:'); for I := 0 to Pred(ARequest.CookieFields.Count) do AResponse.Contents.Add(IntToStr(I) + ': ' + ARequest.CookieFields[I]); This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <jcm...@us...> - 2012-04-16 03:40:14
|
Revision: 1085 http://pressobjects.svn.sourceforge.net/pressobjects/?rev=1085&view=rev Author: jcmoraisjr Date: 2012-04-16 03:40:07 +0000 (Mon, 16 Apr 2012) Log Message: ----------- [Web] Drafts of the core web implementation. Modified Paths: -------------- trunk/Source/Core/PressApplication.pas trunk/Source/Core/PressClasses.pas Added Paths: ----------- trunk/Demos/WebBasic/ trunk/Demos/WebBasic/WebBasic.lpi trunk/Demos/WebBasic/WebBasic.lpr trunk/Demos/WebBasic/WebBrokers.pas trunk/Demos/WebBasic/WebHelloWorld.pas trunk/Demos/WebBasic/WebHome.pas trunk/Demos/WebBasic/WebInfo.pas trunk/Source/Brokers/PressWebFCLCGIBroker.pas trunk/Source/Core/PressWebHandler.pas trunk/Source/Packages/Laz/PressLazWebRT.lpk Added: trunk/Demos/WebBasic/WebBasic.lpi =================================================================== --- trunk/Demos/WebBasic/WebBasic.lpi (rev 0) +++ trunk/Demos/WebBasic/WebBasic.lpi 2012-04-16 03:40:07 UTC (rev 1085) @@ -0,0 +1,109 @@ +<?xml version="1.0"?> +<CONFIG> + <ProjectOptions> + <Version Value="9"/> + <General> + <Flags> + <MainUnitHasCreateFormStatements Value="False"/> + </Flags> + <SessionStorage Value="InProjectDir"/> + <MainUnit Value="0"/> + <Title Value="WebBasic"/> + <UseAppBundle Value="False"/> + <ResourceType Value="res"/> + </General> + <i18n> + <EnableI18N LFM="False"/> + </i18n> + <VersionInfo> + <StringTable ProductVersion=""/> + </VersionInfo> + <BuildModes Count="1"> + <Item1 Name="Default" Default="True"/> + </BuildModes> + <PublishOptions> + <Version Value="2"/> + <DestinationDirectory Value="/var/www/cgi-bin/webbasic"/> + <IgnoreBinaries Value="False"/> + <IncludeFileFilter Value="*"/> + <UseExcludeFileFilter Value="True"/> + <ExcludeFileFilter Value="*.(bak|ppu|o|so);*~;backup"/> + </PublishOptions> + <RunParams> + <local> + <FormatVersion Value="1"/> + <LaunchingApplication PathPlusParams="/usr/bin/xterm -T 'Lazarus Run Output' -e $(LazarusDir)/tools/runwait.sh $(TargetCmdLine)"/> + </local> + </RunParams> + <RequiredPackages Count="4"> + <Item1> + <PackageName Value="PressLazWebRT"/> + </Item1> + <Item2> + <PackageName Value="PressLazCoreRT"/> + </Item2> + <Item3> + <PackageName Value="WebLaz"/> + </Item3> + <Item4> + <PackageName Value="FCL"/> + </Item4> + </RequiredPackages> + <Units Count="5"> + <Unit0> + <Filename Value="WebBasic.lpr"/> + <IsPartOfProject Value="True"/> + <UnitName Value="WebBasic"/> + </Unit0> + <Unit1> + <Filename Value="WebHelloWorld.pas"/> + <IsPartOfProject Value="True"/> + <UnitName Value="WebHelloWorld"/> + </Unit1> + <Unit2> + <Filename Value="WebBrokers.pas"/> + <IsPartOfProject Value="True"/> + <UnitName Value="WebBrokers"/> + </Unit2> + <Unit3> + <Filename Value="WebInfo.pas"/> + <IsPartOfProject Value="True"/> + <UnitName Value="WebInfo"/> + </Unit3> + <Unit4> + <Filename Value="WebHome.pas"/> + <IsPartOfProject Value="True"/> + <UnitName Value="WebHome"/> + </Unit4> + </Units> + </ProjectOptions> + <CompilerOptions> + <Version Value="11"/> + <Target> + <Filename Value="WebBasic"/> + </Target> + <SearchPaths> + <IncludeFiles Value="$(ProjOutDir)"/> + <UnitOutputDirectory Value="../../bin/Laz/Demos/WebBasic"/> + </SearchPaths> + <Other> + <CompilerMessages> + <MsgFileName Value=""/> + </CompilerMessages> + <CompilerPath Value="$(CompPath)"/> + </Other> + </CompilerOptions> + <Debugging> + <Exceptions Count="3"> + <Item1> + <Name Value="EAbort"/> + </Item1> + <Item2> + <Name Value="ECodetoolError"/> + </Item2> + <Item3> + <Name Value="EFOpenError"/> + </Item3> + </Exceptions> + </Debugging> +</CONFIG> Property changes on: trunk/Demos/WebBasic/WebBasic.lpi ___________________________________________________________________ Added: svn:mime-type + text/plain Added: svn:eol-style + native Added: trunk/Demos/WebBasic/WebBasic.lpr =================================================================== --- trunk/Demos/WebBasic/WebBasic.lpr (rev 0) +++ trunk/Demos/WebBasic/WebBasic.lpr 2012-04-16 03:40:07 UTC (rev 1085) @@ -0,0 +1,12 @@ +program WebBasic; + +uses + heaptrc, + PressApplication, PressLazWebRT, + WebBrokers, + WebHelloWorld, WebInfo, WebHome; + +begin + PressApp.Run; +end. + Property changes on: trunk/Demos/WebBasic/WebBasic.lpr ___________________________________________________________________ Added: svn:mime-type + text/plain Added: svn:eol-style + native Added: trunk/Demos/WebBasic/WebBrokers.pas =================================================================== --- trunk/Demos/WebBasic/WebBrokers.pas (rev 0) +++ trunk/Demos/WebBasic/WebBrokers.pas 2012-04-16 03:40:07 UTC (rev 1085) @@ -0,0 +1,14 @@ +unit WebBrokers; + +{$mode objfpc}{$H+} + +interface + +uses + PressMessages_ptbr, + PressWebFCLCGIBroker; + +implementation + +end. + Property changes on: trunk/Demos/WebBasic/WebBrokers.pas ___________________________________________________________________ Added: svn:mime-type + text/plain Added: svn:eol-style + native Added: trunk/Demos/WebBasic/WebHelloWorld.pas =================================================================== --- trunk/Demos/WebBasic/WebHelloWorld.pas (rev 0) +++ trunk/Demos/WebBasic/WebHelloWorld.pas 2012-04-16 03:40:07 UTC (rev 1085) @@ -0,0 +1,33 @@ +unit WebHelloWorld; + +{$mode objfpc}{$H+} + +interface + +uses + HTTPDefs, + PressWebHandler; + +type + + { THelloWorldRequestHandler } + + THelloWorldRequestHandler = class(TInterfacedObject, IPressWebRequestHandler) + protected + procedure HandleRequest(ARequest: TRequest; AResponse: TResponse); + end; + +implementation + +{ THelloWorldRequestHandler } + +procedure THelloWorldRequestHandler.HandleRequest(ARequest: TRequest; AResponse: TResponse); +begin + AResponse.Contents.Add('Hello World!'); +end; + +initialization + TPressWebHandler.DefaultService.RegisterRequestHandler('/hello', THelloWorldRequestHandler.Create); + +end. + Property changes on: trunk/Demos/WebBasic/WebHelloWorld.pas ___________________________________________________________________ Added: svn:mime-type + text/plain Added: svn:eol-style + native Added: trunk/Demos/WebBasic/WebHome.pas =================================================================== --- trunk/Demos/WebBasic/WebHome.pas (rev 0) +++ trunk/Demos/WebBasic/WebHome.pas 2012-04-16 03:40:07 UTC (rev 1085) @@ -0,0 +1,51 @@ +unit WebHome; + +{$mode objfpc}{$H+} + +interface + +uses + HTTPDefs, + PressWebHandler; + +type + + { TWebIndexRequestHandler } + + TWebIndexRequestHandler = class(TInterfacedObject, IPressWebRequestHandler) + protected + procedure HandleRequest(ARequest: TRequest; AResponse: TResponse); + end; + + { TWebHomeRequestHandler } + + TWebHomeRequestHandler = class(TInterfacedObject, IPressWebRequestHandler) + protected + procedure HandleRequest(ARequest: TRequest; AResponse: TResponse); + end; + +implementation + +{ TWebIndexRequestHandler } + +procedure TWebIndexRequestHandler.HandleRequest(ARequest: TRequest; + AResponse: TResponse); +begin + AResponse.Contents.Add('<a href="WebBasic/">Go Home</a><br/>'); +end; + +{ TWebHomeRequestHandler } + +procedure TWebHomeRequestHandler.HandleRequest(ARequest: TRequest; + AResponse: TResponse); +begin + AResponse.Contents.Add('<a href="hello">Hello</a><br/>'); + AResponse.Contents.Add('<a href="info">Info</a><br/>'); +end; + +initialization + TPressWebHandler.DefaultService.RegisterRequestHandler('', TWebIndexRequestHandler.Create); + TPressWebHandler.DefaultService.RegisterRequestHandler('/', TWebHomeRequestHandler.Create); + +end. + Property changes on: trunk/Demos/WebBasic/WebHome.pas ___________________________________________________________________ Added: svn:mime-type + text/plain Added: svn:eol-style + native Added: trunk/Demos/WebBasic/WebInfo.pas =================================================================== --- trunk/Demos/WebBasic/WebInfo.pas (rev 0) +++ trunk/Demos/WebBasic/WebInfo.pas 2012-04-16 03:40:07 UTC (rev 1085) @@ -0,0 +1,144 @@ +unit WebInfo; + +{$mode objfpc}{$H+} + +interface + +uses + HTTPDefs, + PressWebHandler; + +type + + { TInfoRequestHandler } + + TInfoRequestHandler = class(TInterfacedObject, IPressWebRequestHandler) + protected + procedure HandleRequest(ARequest: TRequest; AResponse: TResponse); + end; + +implementation + +uses + SysUtils; + +{ TInfoRequestHandler } + +procedure TInfoRequestHandler.HandleRequest(ARequest: TRequest; + AResponse: TResponse); +const + CBool: array[Boolean] of string = ('False', 'True'); +var + I: Integer; +begin + AResponse.Contents.Add('<h2>hello</h2>'); + AResponse.Contents.Add('<form method="post" enctype="multipart/form-data" action="' + ARequest.ScriptName + ARequest.PathInfo + '">'); + AResponse.Contents.Add('<input type="file" name="f">'); + AResponse.Contents.Add('<input type="text" name="a" value="b">'); + AResponse.Contents.Add('<input type="text" name="c" value="d">'); + AResponse.Contents.Add('<input type="submit" value="Ok"'); + AResponse.Contents.Add('</form>'); + AResponse.Contents.Add('<hr/>'); + AResponse.Contents.Add('QueryString: ' + ARequest.QueryString); + AResponse.Contents.Add('QueryFields:'); + for I := 0 to Pred(ARequest.QueryFields.Count) do + AResponse.Contents.Add(IntToStr(I) + ': ' + ARequest.QueryFields[I]); + AResponse.Contents.Add('ContentFields:'); + for I := 0 to Pred(ARequest.ContentFields.Count) do + AResponse.Contents.Add(IntToStr(I) + ': ' + ARequest.ContentFields[I]); + AResponse.Contents.Add('Files:'); + for I := 0 to Pred(ARequest.Files.Count) do + begin + AResponse.Contents.Add(IntToStr(I) + ': ' + ARequest.Files.Files[I].FileName + ' - ' + + ARequest.Files.Files[I].LocalFileName + ' - ' + ARequest.Files.Files[I].ContentType); + end; + AResponse.Contents.Add('Host: ' + ARequest.Host); + AResponse.Contents.Add('ScriptName: ' + ARequest.ScriptName); + AResponse.Contents.Add('PathInfo: ' + ARequest.PathInfo); + AResponse.Contents.Add('Method: ' + ARequest.Method); + AResponse.Contents.Add('URL: ' + ARequest.URL); + AResponse.Contents.Add('<hr/>'); + AResponse.Contents.Add('ReturnedPathInfo: ' + ARequest.ReturnedPathInfo); + AResponse.Contents.Add('1-GetNextPathInfo: ' + ARequest.GetNextPathInfo + ' - ReturnedPathInfo: ' + ARequest.ReturnedPathInfo); + AResponse.Contents.Add('2-GetNextPathInfo: ' + ARequest.GetNextPathInfo + ' - ReturnedPathInfo: ' + ARequest.ReturnedPathInfo); + AResponse.Contents.Add('3-GetNextPathInfo: ' + ARequest.GetNextPathInfo + ' - ReturnedPathInfo: ' + ARequest.ReturnedPathInfo); + AResponse.Contents.Add('4-GetNextPathInfo: ' + ARequest.GetNextPathInfo + ' - ReturnedPathInfo: ' + ARequest.ReturnedPathInfo); + AResponse.Contents.Add('5-GetNextPathInfo: ' + ARequest.GetNextPathInfo + ' - ReturnedPathInfo: ' + ARequest.ReturnedPathInfo); + AResponse.Contents.Add('6-GetNextPathInfo: ' + ARequest.GetNextPathInfo + ' - ReturnedPathInfo: ' + ARequest.ReturnedPathInfo); + AResponse.Contents.Add('LocalPathPrefix: ' + ARequest.LocalPathPrefix); + AResponse.Contents.Add('CommandLine: ' + ARequest.CommandLine); + AResponse.Contents.Add('Command: ' + ARequest.Command); + AResponse.Contents.Add('URI: ' + ARequest.URI); + AResponse.Contents.Add('QueryString: ' + ARequest.QueryString); + AResponse.Contents.Add('HeaderLine: ' + ARequest.HeaderLine); + AResponse.Contents.Add('HandleGetOnPost: ' + CBool[ARequest.HandleGetOnPost]); + AResponse.Contents.Add('Files:'); + for I := 0 to Pred(ARequest.Files.Count) do + AResponse.Contents.Add(IntToStr(I) + ': ' + ARequest.Files.Files[I].FileName + ' - ' + + ARequest.Files.Files[I].LocalFileName + ' - ' + ARequest.Files.Files[I].ContentType); + AResponse.Contents.Add('Fields:'); + for I := 0 to Pred(ARequest.FieldCount) do + AResponse.Contents.Add(IntToStr(I) + ': ' + ARequest.Fields[I] + ' - ' + ARequest.FieldNames[I] + ' - ' + ARequest.FieldValues[I]); + AResponse.Contents.Add('CookieFields:'); + for I := 0 to Pred(ARequest.CookieFields.Count) do + AResponse.Contents.Add(IntToStr(I) + ': ' + ARequest.CookieFields[I]); + AResponse.Contents.Add('ContentFields:'); + for I := 0 to Pred(ARequest.ContentFields.Count) do + AResponse.Contents.Add(IntToStr(I) + ': ' + ARequest.ContentFields[I]); + AResponse.Contents.Add('QueryFields:'); + for I := 0 to Pred(ARequest.QueryFields.Count) do + AResponse.Contents.Add(IntToStr(I) + ': ' + ARequest.QueryFields[I]); + AResponse.Contents.Add(''); + + AResponse.Contents.Add('HttpVersion: ' + ARequest.HttpVersion); + AResponse.Contents.Add('ProtocolVersion: ' + ARequest.ProtocolVersion); + AResponse.Contents.Add('Accept: ' + ARequest.Accept); + AResponse.Contents.Add('AcceptCharset: ' + ARequest.AcceptCharset); + AResponse.Contents.Add('AcceptEncoding: ' + ARequest.AcceptEncoding); + AResponse.Contents.Add('AcceptLanguage: ' + ARequest.AcceptLanguage); + AResponse.Contents.Add('Authorization: ' + ARequest.Authorization); + AResponse.Contents.Add('Connection: ' + ARequest.Connection); + AResponse.Contents.Add('ContentEncoding: ' + ARequest.ContentEncoding); + AResponse.Contents.Add('ContentLanguage: ' + ARequest.ContentLanguage); + AResponse.Contents.Add('ContentLength: ' + IntToStr(ARequest.ContentLength)); + AResponse.Contents.Add('ContentType: ' + ARequest.ContentType); + AResponse.Contents.Add('Cookie: ' + ARequest.Cookie); + AResponse.Contents.Add('Date: ' + ARequest.Date); + AResponse.Contents.Add('Expires: ' + ARequest.Expires); + AResponse.Contents.Add('From: ' + ARequest.From); + AResponse.Contents.Add('IfModifiedSince: ' + ARequest.IfModifiedSince); + AResponse.Contents.Add('LastModified: ' + ARequest.LastModified); + AResponse.Contents.Add('Location: ' + ARequest.Location); + AResponse.Contents.Add('Pragma: ' + ARequest.Pragma); + AResponse.Contents.Add('Referer: ' + ARequest.Referer); + AResponse.Contents.Add('RetryAfter: ' + ARequest.RetryAfter); + AResponse.Contents.Add('Server: ' + ARequest.Server); + AResponse.Contents.Add('SetCookie: ' + ARequest.SetCookie); + AResponse.Contents.Add('UserAgent: ' + ARequest.UserAgent); + AResponse.Contents.Add('WWWAuthenticate: ' + ARequest.WWWAuthenticate); + AResponse.Contents.Add('PathInfo: ' + ARequest.PathInfo); + AResponse.Contents.Add('PathTranslated: ' + ARequest.PathTranslated); + AResponse.Contents.Add('RemoteAddress: ' + ARequest.RemoteAddress); + AResponse.Contents.Add('RemoteHost: ' + ARequest.RemoteHost); + AResponse.Contents.Add('ScriptName: ' + ARequest.ScriptName); + AResponse.Contents.Add('ServerPort: ' + IntToStr(ARequest.ServerPort)); + AResponse.Contents.Add('HTTPAccept: ' + ARequest.HTTPAccept); + AResponse.Contents.Add('HTTPAcceptCharset: ' + ARequest.HTTPAcceptCharset); + AResponse.Contents.Add('HTTPAcceptEncoding: ' + ARequest.HTTPAcceptEncoding); + AResponse.Contents.Add('HTTPIfModifiedSince: ' + ARequest.HTTPIfModifiedSince); + AResponse.Contents.Add('HTTPReferer: ' + ARequest.HTTPReferer); + AResponse.Contents.Add('HTTUserAgent: ' + ARequest.HTTPUserAgent); + AResponse.Contents.Add('Method: ' + ARequest.Method); + AResponse.Contents.Add('URL: ' + ARequest.URL); + AResponse.Contents.Add('Host: ' + ARequest.Host); + AResponse.Contents.Add('HTTPXRequestedWith: ' + ARequest.HTTPXRequestedWith); + + for I := 2 to Pred(AResponse.Contents.Count) do + AResponse.Contents[I] := AResponse.Contents[I] + '<br>'; +end; + +initialization + TPressWebHandler.DefaultService.RegisterRequestHandler('/info*', TInfoRequestHandler.Create); + +end. + Property changes on: trunk/Demos/WebBasic/WebInfo.pas ___________________________________________________________________ Added: svn:mime-type + text/plain Added: svn:eol-style + native Added: trunk/Source/Brokers/PressWebFCLCGIBroker.pas =================================================================== --- trunk/Source/Brokers/PressWebFCLCGIBroker.pas (rev 0) +++ trunk/Source/Brokers/PressWebFCLCGIBroker.pas 2012-04-16 03:40:07 UTC (rev 1085) @@ -0,0 +1,120 @@ +unit PressWebFCLCGIBroker; + +{$mode objfpc}{$H+} + +interface + +uses + HTTPDefs, + custweb, + custcgi, + PressClasses, + PressApplication, + PressWebHandler; + +type + + TPressWebFCLCGIApp = class; + + { TPressWebFCLCGIAppManager } + + TPressWebFCLCGIAppManager = class(TPressManagedIObject, IPressAppManager) + private + FApp: TPressWebFCLCGIApp; + FIdleMethod: TPressIdleMethod; + protected + procedure Finit; override; + public + procedure Done; + procedure Finalize; + function HasMainForm: Boolean; + procedure IdleNotification(AIdleMethod: TPressIdleMethod); + procedure Init; + function MainForm: TObject; + procedure Run; + end; + + { TPressWebFCLCGIHandler } + + TPressWebFCLCGIHandler = class(TCGIHandler) + public + procedure HandleRequest(ARequest: TRequest; AResponse: TResponse); override; + end; + + { TPressWebFCLCGIApp } + + TPressWebFCLCGIApp = class(TCustomCGIApplication) + protected + function InitializeWebHandler: TWebHandler; override; + end; + +implementation + +uses + SysUtils; + +{ TPressWebFCLCGIAppManager } + +procedure TPressWebFCLCGIAppManager.Finit; +begin + FreeAndNil(FApp); + inherited Finit; +end; + +procedure TPressWebFCLCGIAppManager.Done; +begin +end; + +procedure TPressWebFCLCGIAppManager.Finalize; +begin +end; + +function TPressWebFCLCGIAppManager.HasMainForm: Boolean; +begin + Result := False; +end; + +procedure TPressWebFCLCGIAppManager.IdleNotification(AIdleMethod: TPressIdleMethod); +begin + FIdleMethod := AIdleMethod; +end; + +procedure TPressWebFCLCGIAppManager.Init; +begin + FreeAndNil(FApp); + FApp := TPressWebFCLCGIApp.Create(nil); + FApp.Initialize; +end; + +function TPressWebFCLCGIAppManager.MainForm: TObject; +begin + Result := nil; +end; + +procedure TPressWebFCLCGIAppManager.Run; +begin + FApp.Run; + if Assigned(FIdleMethod) then + FIdleMethod; +end; + +{ TPressWebFCLCGIHandler } + +procedure TPressWebFCLCGIHandler.HandleRequest(ARequest: TRequest; + AResponse: TResponse); +begin + TPressWebHandler.DefaultService.HandleRequest(ARequest, AResponse); +end; + +{ TPressWebFCLCGIApp } + +function TPressWebFCLCGIApp.InitializeWebHandler: TWebHandler; +begin + Result := TPressWebFCLCGIHandler.Create(Self); +end; + +initialization + PressApp.RegisterAppManager(TPressWebFCLCGIAppManager.Create); + +end. + Property changes on: trunk/Source/Brokers/PressWebFCLCGIBroker.pas ___________________________________________________________________ Added: svn:mime-type + text/plain Added: svn:eol-style + native Modified: trunk/Source/Core/PressApplication.pas =================================================================== --- trunk/Source/Core/PressApplication.pas 2011-08-21 21:04:43 UTC (rev 1084) +++ trunk/Source/Core/PressApplication.pas 2012-04-16 03:40:07 UTC (rev 1085) @@ -33,6 +33,7 @@ CPressMVPServicesBase = $0400; CPressLogServicesBase = $0500; CPressDialogServicesBase = $0600; + CPressWebServicesBase = $0700; CPressUserDefinedServicesBase = $8000; Modified: trunk/Source/Core/PressClasses.pas =================================================================== --- trunk/Source/Core/PressClasses.pas 2011-08-21 21:04:43 UTC (rev 1084) +++ trunk/Source/Core/PressClasses.pas 2012-04-16 03:40:07 UTC (rev 1085) @@ -35,6 +35,8 @@ EPressConversionError = class(EPressError); + EPressWebException = class(EPressError); + TPressTextPos = record Line, Column: Integer; Position: Integer; Added: trunk/Source/Core/PressWebHandler.pas =================================================================== --- trunk/Source/Core/PressWebHandler.pas (rev 0) +++ trunk/Source/Core/PressWebHandler.pas 2012-04-16 03:40:07 UTC (rev 1085) @@ -0,0 +1,213 @@ +unit PressWebHandler; + +{$mode objfpc}{$H+} + +interface + +uses + Classes, + HTTPDefs, + fgl, + PressClasses, + PressApplication; + +const + CPressWebHandlerService = CPressWebServicesBase + $0001; + +type + + EPressWebHandler = class(EPressWebException); + + IPressWebRequestHandler = interface(IUnknown) + ['{350D929B-88D8-4643-9C94-6225A1BBDB0B}'] + procedure HandleRequest(ARequest: TRequest; AResponse: TResponse); + end; + + { TPressWebRequestHandlerItem } + + TPressWebRequestHandlerItem = class(TObject) + private + FPattern: string; + FHandler: IPressWebRequestHandler; + public + constructor Create(APattern: string; AHandler: IPressWebRequestHandler); + property Pattern: string read FPattern; + property Handler: IPressWebRequestHandler read FHandler; + end; + + TPressWebRequestHandlerList = specialize TFPGObjectList<TPressWebRequestHandlerItem>; + + { TPressWebRequestInvoker } + + TPressWebRequestInvoker = class(TObject) + private + FHandlerList: TPressWebRequestHandlerList; + protected + procedure DoHandleRequest(AHandler: IPressWebRequestHandler; ARequest: TRequest; AResponse: TResponse); virtual; + procedure InternalInvoke(ARequest: TRequest; AResponse: TResponse); virtual; + function PatternMatch(const APattern, APathInfo: string): Boolean; virtual; + public + constructor Create; + destructor Destroy; override; + procedure Invoke(ARequest: TRequest; AResponse: TResponse); + property HandlerList: TPressWebRequestHandlerList read FHandlerList; + end; + + { TPressWebHandler } + + TPressWebHandler = class(TPressService) + private + FInvoker: TPressWebRequestInvoker; + protected + procedure Finit; override; + function InternalCreateInvoker: TPressWebRequestInvoker; virtual; + procedure InternalIsDefaultChanged; override; + class function InternalServiceType: TPressServiceType; override; + public + constructor Create; override; + class function DefaultService: TPressWebHandler; + procedure HandleRequest(ARequest: TRequest; AResponse: TResponse); virtual; + procedure RegisterRequestHandler(const APattern: string; AHandler: IPressWebRequestHandler); virtual; + end; + +implementation + +uses + SysUtils; + +var + _WebHandlerDefaultService: TPressWebHandler; + +{ TPressWebRequestHandlerItem } + +constructor TPressWebRequestHandlerItem.Create(APattern: string; + AHandler: IPressWebRequestHandler); +begin + inherited Create; + FPattern := APattern; + FHandler := AHandler; +end; + +{ TPressWebRequestInvoker } + +procedure TPressWebRequestInvoker.DoHandleRequest( + AHandler: IPressWebRequestHandler; ARequest: TRequest; AResponse: TResponse); +begin + AHandler.HandleRequest(ARequest, AResponse); +end; + +procedure TPressWebRequestInvoker.InternalInvoke(ARequest: TRequest; + AResponse: TResponse); +var + VPath: string; + I: Integer; +begin + VPath := ARequest.PathInfo; + for I := 0 to Pred(HandlerList.Count) do + if PatternMatch(HandlerList[I].Pattern, VPath) then + DoHandleRequest(HandlerList[I].Handler, ARequest, AResponse); +end; + +function TPressWebRequestInvoker.PatternMatch( + const APattern, APathInfo: string): Boolean; +var + VPatternLength, VPathLength, VPos, I: Integer; +begin + Result := APattern = APathInfo; + if Result then + Exit; + VPatternLength := Length(APattern); + VPathLength := Length(APathInfo); + Result := VPathLength + 1 >= VPatternLength; + if not Result then + Exit; + VPos := Pos('*', APattern); + Result := VPos <> 0; + if not Result then + Exit; + Result := False; + for I := 1 to Pred(VPos) do + if APattern[I] <> APathInfo[I] then + Exit; + for I := VPatternLength downto Succ(VPos) do + if APattern[I] <> APathInfo[VPathLength + I - VPatternLength] then + Exit; + Result := True; +end; + +constructor TPressWebRequestInvoker.Create; +begin + FHandlerList := TPressWebRequestHandlerList.Create; +end; + +destructor TPressWebRequestInvoker.Destroy; +begin + FHandlerList.Free; + inherited Destroy; +end; + +procedure TPressWebRequestInvoker.Invoke(ARequest: TRequest; + AResponse: TResponse); +begin + InternalInvoke(ARequest, AResponse); +end; + +{ TPressWebHandler } + +procedure TPressWebHandler.Finit; +begin + FreeAndNil(FInvoker); + inherited Finit; +end; + +function TPressWebHandler.InternalCreateInvoker: TPressWebRequestInvoker; +begin + Result := TPressWebRequestInvoker.Create; +end; + +procedure TPressWebHandler.InternalIsDefaultChanged; +begin + inherited InternalIsDefaultChanged; + _WebHandlerDefaultService := Registry.DefaultService as TPressWebHandler; +end; + +class function TPressWebHandler.InternalServiceType: TPressServiceType; +begin + Result := CPressWebHandlerService; +end; + +constructor TPressWebHandler.Create; +begin + inherited Create; + FInvoker := TPressWebRequestInvoker.Create; +end; + +class function TPressWebHandler.DefaultService: TPressWebHandler; +begin + if _WebHandlerDefaultService = nil then + _WebHandlerDefaultService := + PressApp.Registry[InternalServiceType].DefaultService as TPressWebHandler; + Result := _WebHandlerDefaultService; +end; + +procedure TPressWebHandler.HandleRequest(ARequest: TRequest; + AResponse: TResponse); +begin + if Assigned(FInvoker) then + FInvoker.Invoke(ARequest, AResponse); +end; + +procedure TPressWebHandler.RegisterRequestHandler(const APattern: string; + AHandler: IPressWebRequestHandler); +begin + FInvoker.HandlerList.Add(TPressWebRequestHandlerItem.Create(APattern, AHandler)); +end; + +initialization + TPressWebHandler.RegisterService; + +finalization + TPressWebHandler.UnregisterService; + +end. + Property changes on: trunk/Source/Core/PressWebHandler.pas ___________________________________________________________________ Added: svn:mime-type + text/plain Added: svn:eol-style + native Added: trunk/Source/Packages/Laz/PressLazWebRT.lpk =================================================================== --- trunk/Source/Packages/Laz/PressLazWebRT.lpk (rev 0) +++ trunk/Source/Packages/Laz/PressLazWebRT.lpk 2012-04-16 03:40:07 UTC (rev 1085) @@ -0,0 +1,46 @@ +<?xml version="1.0"?> +<CONFIG> + <Package Version="4"> + <PathDelim Value="\"/> + <Name Value="PressLazWebRT"/> + <AddToProjectUsesSection Value="True"/> + <CompilerOptions> + <Version Value="11"/> + <PathDelim Value="\"/> + <SearchPaths> + <OtherUnitFiles Value="..\..\Brokers;\home\jcmoraisjr\devel\press\Source\Core\"/> + <UnitOutputDirectory Value="..\..\..\bin\Laz\Brokers\$(TargetCPU)-$(TargetOS)"/> + </SearchPaths> + <Other> + <CompilerPath Value="$(CompPath)"/> + </Other> + </CompilerOptions> + <Version Minor="1" Release="1"/> + <Files Count="2"> + <Item1> + <Filename Value="..\..\Core\PressWebHandler.pas"/> + <UnitName Value="PressWebHandler"/> + </Item1> + <Item2> + <Filename Value="..\..\Brokers\PressWebFCLCGIBroker.pas"/> + <UnitName Value="PressWebFCLCGIBroker"/> + </Item2> + </Files> + <RequiredPkgs Count="2"> + <Item1> + <PackageName Value="PressLazCoreRT"/> + </Item1> + <Item2> + <PackageName Value="FCL"/> + <MinVersion Major="1" Valid="True"/> + </Item2> + </RequiredPkgs> + <UsageOptions> + <UnitPath Value="$(PkgOutDir)\"/> + </UsageOptions> + <PublishOptions> + <Version Value="2"/> + <IgnoreBinaries Value="False"/> + </PublishOptions> + </Package> +</CONFIG> Property changes on: trunk/Source/Packages/Laz/PressLazWebRT.lpk ___________________________________________________________________ Added: svn:mime-type + text/plain Added: svn:eol-style + native This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <jcm...@us...> - 2011-08-21 21:04:49
|
Revision: 1084 http://pressobjects.svn.sourceforge.net/pressobjects/?rev=1084&view=rev Author: jcmoraisjr Date: 2011-08-21 21:04:43 +0000 (Sun, 21 Aug 2011) Log Message: ----------- [Core] Facade for direct use of Expression. Modified Paths: -------------- trunk/Source/Core/PressExpression.pas trunk/Source/Core/PressSubject.pas Modified: trunk/Source/Core/PressExpression.pas =================================================================== --- trunk/Source/Core/PressExpression.pas 2011-06-28 01:39:20 UTC (rev 1083) +++ trunk/Source/Core/PressExpression.pas 2011-08-21 21:04:43 UTC (rev 1084) @@ -48,6 +48,7 @@ TPressExpression = class(TPressExpressionObject) private FCalc: TObjectList; + FOwnedReader: TPressExpressionReader; FRes: PPressExpressionValue; FVars: TPressExpressionVarList; function GetCalc: TObjectList; @@ -62,8 +63,10 @@ function InternalParseOperation(Reader: TPressParserReader): TPressExpressionOperation; virtual; procedure InternalRead(Reader: TPressParserReader); override; public + constructor Create; + constructor Create(AExpression: string); destructor Destroy; override; - function ParseExpression(Reader: TPressParserReader): PPressExpressionValue; + function ParseExpression(Reader: TPressExpressionReader): PPressExpressionValue; property Calc: TObjectList read GetCalc; property Res: PPressExpressionValue read FRes; property Vars: TPressExpressionVarList read GetVars; @@ -205,6 +208,7 @@ begin FVars.Free; FCalc.Free; + FOwnedReader.Free; inherited; end; @@ -226,6 +230,8 @@ var I: Integer; begin + if not Assigned(FRes) and Assigned(FOwnedReader) then + ParseExpression(FOwnedReader); if Assigned(FRes) then begin if Assigned(FCalc) then @@ -265,12 +271,23 @@ procedure TPressExpression.InternalRead(Reader: TPressParserReader); begin inherited; - ParseExpression(Reader); + ParseExpression(Reader as TPressExpressionReader); Reader.ReadMatchEof; end; +constructor TPressExpression.Create; +begin + inherited Create(nil); +end; + +constructor TPressExpression.Create(AExpression: string); +begin + inherited Create(nil); + FOwnedReader := TPressExpressionReader.Create(AExpression); +end; + function TPressExpression.ParseExpression( - Reader: TPressParserReader): PPressExpressionValue; + Reader: TPressExpressionReader): PPressExpressionValue; var VItem: TPressExpressionItem; begin @@ -452,7 +469,7 @@ begin inherited; Reader.ReadMatch('('); - Res := (Owner as TPressExpression).ParseExpression(Reader); + Res := (Owner as TPressExpression).ParseExpression(Reader as TPressExpressionReader); Reader.ReadMatch(')'); end; @@ -516,7 +533,8 @@ Reader.ReadMatch(','); if Length(VParams) = I then SetLength(VParams, I + CDelta); - VParams[I] := (Owner as TPressExpression).ParseExpression(Reader); + VParams[I] := (Owner as TPressExpression).ParseExpression( + Reader as TPressExpressionReader); Inc(I); end; Reader.ReadMatch(')'); Modified: trunk/Source/Core/PressSubject.pas =================================================================== --- trunk/Source/Core/PressSubject.pas 2011-06-28 01:39:20 UTC (rev 1083) +++ trunk/Source/Core/PressSubject.pas 2011-08-21 21:04:43 UTC (rev 1084) @@ -3685,7 +3685,7 @@ constructor TPressSubjectExpression.Create(AInstance: TPressObject); begin - inherited Create(nil); + inherited Create; FInstance := AInstance; end; This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <jcm...@us...> - 2011-06-28 01:39:27
|
Revision: 1083 http://pressobjects.svn.sourceforge.net/pressobjects/?rev=1083&view=rev Author: jcmoraisjr Date: 2011-06-28 01:39:20 +0000 (Tue, 28 Jun 2011) Log Message: ----------- [Packages] UIB and Zeos RT packages. Added Paths: ----------- trunk/Source/Packages/Laz/PressLazUIBRT.lpk trunk/Source/Packages/Laz/PressLazZeosRT.lpk Added: trunk/Source/Packages/Laz/PressLazUIBRT.lpk =================================================================== --- trunk/Source/Packages/Laz/PressLazUIBRT.lpk (rev 0) +++ trunk/Source/Packages/Laz/PressLazUIBRT.lpk 2011-06-28 01:39:20 UTC (rev 1083) @@ -0,0 +1,48 @@ +<?xml version="1.0"?> +<CONFIG> + <Package Version="3"> + <PathDelim Value="\"/> + <Name Value="PressLazUIBRT"/> + <CompilerOptions> + <Version Value="10"/> + <PathDelim Value="\"/> + <SearchPaths> + <OtherUnitFiles Value="..\..\Brokers"/> + <UnitOutputDirectory Value="..\..\..\bin\Laz\Brokers\$(TargetCPU)-$(TargetOS)"/> + </SearchPaths> + <Other> + <CompilerMessages> + <UseMsgFile Value="True"/> + </CompilerMessages> + <CompilerPath Value="$(CompPath)"/> + </Other> + </CompilerOptions> + <Version Minor="1" Release="1"/> + <Files Count="1"> + <Item1> + <Filename Value="..\..\Brokers\PressUIBBroker.pas"/> + <UnitName Value="PressUIBBroker"/> + </Item1> + </Files> + <Type Value="RunAndDesignTime"/> + <RequiredPkgs Count="3"> + <Item1> + <PackageName Value="UIBLaz"/> + </Item1> + <Item2> + <PackageName Value="PressLazBrokersRT"/> + </Item2> + <Item3> + <PackageName Value="FCL"/> + <MinVersion Major="1" Valid="True"/> + </Item3> + </RequiredPkgs> + <UsageOptions> + <UnitPath Value="$(PkgOutDir)"/> + </UsageOptions> + <PublishOptions> + <Version Value="2"/> + <IgnoreBinaries Value="False"/> + </PublishOptions> + </Package> +</CONFIG> Property changes on: trunk/Source/Packages/Laz/PressLazUIBRT.lpk ___________________________________________________________________ Added: svn:mime-type + text/plain Added: svn:eol-style + native Added: trunk/Source/Packages/Laz/PressLazZeosRT.lpk =================================================================== --- trunk/Source/Packages/Laz/PressLazZeosRT.lpk (rev 0) +++ trunk/Source/Packages/Laz/PressLazZeosRT.lpk 2011-06-28 01:39:20 UTC (rev 1083) @@ -0,0 +1,48 @@ +<?xml version="1.0"?> +<CONFIG> + <Package Version="3"> + <PathDelim Value="\"/> + <Name Value="PressLazZeosRT"/> + <CompilerOptions> + <Version Value="10"/> + <PathDelim Value="\"/> + <SearchPaths> + <OtherUnitFiles Value="..\..\Brokers"/> + <UnitOutputDirectory Value="..\..\..\bin\Laz\Brokers\$(TargetCPU)-$(TargetOS)"/> + </SearchPaths> + <Other> + <CompilerMessages> + <UseMsgFile Value="True"/> + </CompilerMessages> + <CompilerPath Value="$(CompPath)"/> + </Other> + </CompilerOptions> + <Version Minor="1" Release="1"/> + <Files Count="1"> + <Item1> + <Filename Value="..\..\Brokers\PressZeosBroker.pas"/> + <UnitName Value="PressZeosBroker"/> + </Item1> + </Files> + <Type Value="RunAndDesignTime"/> + <RequiredPkgs Count="3"> + <Item1> + <PackageName Value="zcomponent"/> + </Item1> + <Item2> + <PackageName Value="PressLazBrokersRT"/> + </Item2> + <Item3> + <PackageName Value="FCL"/> + <MinVersion Major="1" Valid="True"/> + </Item3> + </RequiredPkgs> + <UsageOptions> + <UnitPath Value="$(PkgOutDir)"/> + </UsageOptions> + <PublishOptions> + <Version Value="2"/> + <IgnoreBinaries Value="False"/> + </PublishOptions> + </Package> +</CONFIG> Property changes on: trunk/Source/Packages/Laz/PressLazZeosRT.lpk ___________________________________________________________________ Added: svn:mime-type + text/plain Added: svn:eol-style + native This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <jcm...@us...> - 2011-06-25 03:54:48
|
Revision: 1082 http://pressobjects.svn.sourceforge.net/pressobjects/?rev=1082&view=rev Author: jcmoraisjr Date: 2011-06-25 03:54:42 +0000 (Sat, 25 Jun 2011) Log Message: ----------- [Core] Fixed delphi compilation error Modified Paths: -------------- trunk/Source/Core/Press.inc Modified: trunk/Source/Core/Press.inc =================================================================== --- trunk/Source/Core/Press.inc 2011-06-25 02:07:27 UTC (rev 1081) +++ trunk/Source/Core/Press.inc 2011-06-25 03:54:42 UTC (rev 1082) @@ -39,11 +39,6 @@ {$DEFINE SUPPORTS_DYNAMICARRAYS} {$DEFINE SUPPORTS_DEFAULTPARAMS} {$DEFINE SUPPORTS_OVERLOAD} - {$IFNDEF WINDOWS} - {$IF (FPC_VERSION >= 2) AND (FPC_RELEASE > 4)} - {$DEFINE PressIIntfUsesCDecl} - {$ENDIF} - {$ENDIF} {$ELSE} {$DEFINE VCL} {$ENDIF} @@ -112,7 +107,11 @@ {$UNDEF PressLogDAOPersistence} {$ENDIF} -{$IFNDEF FPC} // Only FPC and Delphi >= 5 are supported +{$IFDEF FPC} // Only FPC and Delphi >= 5 are supported + {$IFNDEF VER1}{$IFNDEF VER2_0}{$IFNDEF VER2_1}{$IFNDEF VER2_2}{$IFNDEF VER2_3}{$IFNDEF VER2_4} + {$DEFINE FPC251UP} + {$ENDIF}{$ENDIF}{$ENDIF}{$ENDIF}{$ENDIF}{$ENDIF} +{$ELSE} {$DEFINE BORLAND_CG} {$IFDEF VER130} // D5 {$DEFINE MSWINDOWS} @@ -136,3 +135,9 @@ {$ENDIF} {$ENDIF} {$ENDIF} + +{$IFDEF FPC251UP} + {$IFNDEF WINDOWS} + {$DEFINE PressIIntfUsesCDecl} + {$ENDIF} +{$ENDIF} This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <jcm...@us...> - 2011-06-25 02:07:34
|
Revision: 1081 http://pressobjects.svn.sourceforge.net/pressobjects/?rev=1081&view=rev Author: jcmoraisjr Date: 2011-06-25 02:07:27 +0000 (Sat, 25 Jun 2011) Log Message: ----------- [Core] Fixed fpc 2.5+ compilation under linux. Modified Paths: -------------- trunk/Source/Core/Press.inc trunk/Source/Core/PressClasses.pas Modified: trunk/Source/Core/Press.inc =================================================================== --- trunk/Source/Core/Press.inc 2011-05-11 02:04:31 UTC (rev 1080) +++ trunk/Source/Core/Press.inc 2011-06-25 02:07:27 UTC (rev 1081) @@ -39,6 +39,11 @@ {$DEFINE SUPPORTS_DYNAMICARRAYS} {$DEFINE SUPPORTS_DEFAULTPARAMS} {$DEFINE SUPPORTS_OVERLOAD} + {$IFNDEF WINDOWS} + {$IF (FPC_VERSION >= 2) AND (FPC_RELEASE > 4)} + {$DEFINE PressIIntfUsesCDecl} + {$ENDIF} + {$ENDIF} {$ELSE} {$DEFINE VCL} {$ENDIF} Modified: trunk/Source/Core/PressClasses.pas =================================================================== --- trunk/Source/Core/PressClasses.pas 2011-05-11 02:04:31 UTC (rev 1080) +++ trunk/Source/Core/PressClasses.pas 2011-06-25 02:07:27 UTC (rev 1081) @@ -79,10 +79,10 @@ FRefCount: Integer; protected procedure Finit; virtual; - function QueryInterface({$ifdef fpc_has_constref}constref{$else}const{$endif} IID: TGUID; out Obj): HResult; stdcall; + function QueryInterface({$ifdef fpc_has_constref}constref{$else}const{$endif} IID: TGUID; out Obj): HResult; {$ifdef PressIIntfUsesCDecl}cdecl{$else}stdcall{$endif}; function SupportsIntf(const IID: TGUID): Boolean; - function _AddRef: Integer; stdcall; - function _Release: Integer; stdcall; + function _AddRef: Integer; {$ifdef PressIIntfUsesCDecl}cdecl{$else}stdcall{$endif}; + function _Release: Integer; {$ifdef PressIIntfUsesCDecl}cdecl{$else}stdcall{$endif}; public destructor Destroy; reintroduce; function AddRef: Integer; virtual; @@ -389,7 +389,7 @@ end; function TPressManagedObject.QueryInterface( - {$ifdef fpc_has_constref}constref{$else}const{$endif} IID: TGUID; out Obj): HResult; stdcall; + {$ifdef fpc_has_constref}constref{$else}const{$endif} IID: TGUID; out Obj): HResult; {$ifdef PressIIntfUsesCDecl}cdecl{$else}stdcall{$endif}; begin if GetInterface(IID, Obj) then Result := 0 @@ -416,12 +416,12 @@ {$endif} end; -function TPressManagedObject._AddRef: Integer; stdcall; +function TPressManagedObject._AddRef: Integer; {$ifdef PressIIntfUsesCDecl}cdecl{$else}stdcall{$endif}; begin Result := AddRef; end; -function TPressManagedObject._Release: Integer; stdcall; +function TPressManagedObject._Release: Integer; {$ifdef PressIIntfUsesCDecl}cdecl{$else}stdcall{$endif}; begin Result := Release; if Result = 0 then This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <jcm...@us...> - 2011-05-11 02:04:37
|
Revision: 1080 http://pressobjects.svn.sourceforge.net/pressobjects/?rev=1080&view=rev Author: jcmoraisjr Date: 2011-05-11 02:04:31 +0000 (Wed, 11 May 2011) Log Message: ----------- [Brokers] Fixed Zeos 7+ compilation. Modified Paths: -------------- trunk/Source/Brokers/PressZeosBroker.pas Modified: trunk/Source/Brokers/PressZeosBroker.pas =================================================================== --- trunk/Source/Brokers/PressZeosBroker.pas 2011-05-11 01:53:23 UTC (rev 1079) +++ trunk/Source/Brokers/PressZeosBroker.pas 2011-05-11 02:04:31 UTC (rev 1080) @@ -16,6 +16,8 @@ {$I Press.inc} +{.$define zeos7up} // define if you are using Zeos 7+ + interface uses @@ -33,6 +35,10 @@ ZDataset; type +{$ifndef zeos7up} + TLoginEvent = TZLoginEvent; +{$endif} + TPressZeosConnector = class; TPressZeosBroker = class(TPressOPFBroker) @@ -96,7 +102,7 @@ function GetDatabase: string; function GetHostName: string; function GetLoginPrompt: Boolean; - function GetOnLogin: TLoginEvent; + function GetOnLogin: TZLoginEvent; function GetPassword: string; function GetPort: Integer; function GetProperties: TStrings; @@ -111,7 +117,7 @@ procedure SetDatabase(const AValue: string); procedure SetHostName(const AValue: string); procedure SetLoginPrompt(AValue: Boolean); - procedure SetOnLogin(AValue: TLoginEvent); + procedure SetOnLogin(AValue: TZLoginEvent); procedure SetPassword(const AValue: string); procedure SetPort(AValue: Integer); procedure SetProperties(AValue: TStrings); @@ -137,7 +143,7 @@ property AfterConnect: TNotifyEvent read GetAfterConnect write SetAfterConnect; property BeforeDisconnect: TNotifyEvent read GetBeforeDisconnect write SetBeforeDisconnect; property AfterDisconnect: TNotifyEvent read GetAfterDisconnect write SetAfterDisconnect; - property OnLogin: TLoginEvent read GetOnLogin write SetOnLogin; + property OnLogin: TZLoginEvent read GetOnLogin write SetOnLogin; end; implementation @@ -211,7 +217,7 @@ function TPressZeosConnector.InternalDBMSName: string; begin if Connection.Connected then - Result := Connection.DbcConnection.GetMetadata.GetDatabaseProductName + Result := Connection.DbcConnection.GetMetadata.{$ifdef zeos7up}GetDatabaseInfo.{$endif}GetDatabaseProductName else Result := Connection.Protocol; end; @@ -342,7 +348,7 @@ Result := Connection.LoginPrompt; end; -function TPressZeosConnection.GetOnLogin: TLoginEvent; +function TPressZeosConnection.GetOnLogin: TZLoginEvent; begin Result := Connection.OnLogin; end; @@ -422,7 +428,7 @@ Connection.LoginPrompt := AValue; end; -procedure TPressZeosConnection.SetOnLogin(AValue: TLoginEvent); +procedure TPressZeosConnection.SetOnLogin(AValue: TZLoginEvent); begin Connection.OnLogin := AValue; end; This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <jcm...@us...> - 2011-05-11 01:53:29
|
Revision: 1079 http://pressobjects.svn.sourceforge.net/pressobjects/?rev=1079&view=rev Author: jcmoraisjr Date: 2011-05-11 01:53:23 +0000 (Wed, 11 May 2011) Log Message: ----------- [Core] Fixed fpc 2.5+ compilation. Modified Paths: -------------- trunk/Source/Core/PressClasses.pas Modified: trunk/Source/Core/PressClasses.pas =================================================================== --- trunk/Source/Core/PressClasses.pas 2010-12-24 14:08:20 UTC (rev 1078) +++ trunk/Source/Core/PressClasses.pas 2011-05-11 01:53:23 UTC (rev 1079) @@ -79,7 +79,7 @@ FRefCount: Integer; protected procedure Finit; virtual; - function QueryInterface(const IID: TGUID; out Obj): HResult; stdcall; + function QueryInterface({$ifdef fpc_has_constref}constref{$else}const{$endif} IID: TGUID; out Obj): HResult; stdcall; function SupportsIntf(const IID: TGUID): Boolean; function _AddRef: Integer; stdcall; function _Release: Integer; stdcall; @@ -389,7 +389,7 @@ end; function TPressManagedObject.QueryInterface( - const IID: TGUID; out Obj): HResult; stdcall; + {$ifdef fpc_has_constref}constref{$else}const{$endif} IID: TGUID; out Obj): HResult; stdcall; begin if GetInterface(IID, Obj) then Result := 0 This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <jcm...@us...> - 2010-12-24 14:08:26
|
Revision: 1078 http://pressobjects.svn.sourceforge.net/pressobjects/?rev=1078&view=rev Author: jcmoraisjr Date: 2010-12-24 14:08:20 +0000 (Fri, 24 Dec 2010) Log Message: ----------- [MVP] Declared as protected some methods that implements some MVP-View interfaces. Modified Paths: -------------- trunk/Source/Brokers/PressXCLBroker.pas Modified: trunk/Source/Brokers/PressXCLBroker.pas =================================================================== --- trunk/Source/Brokers/PressXCLBroker.pas 2010-09-28 01:02:47 UTC (rev 1077) +++ trunk/Source/Brokers/PressXCLBroker.pas 2010-12-24 14:08:20 UTC (rev 1078) @@ -145,18 +145,18 @@ FViewMouseDownEvent: TMouseEvent; FViewMouseUpEvent: TMouseEvent; FVisible: Boolean; + function GetModel: TPressMVPModel; + procedure SetEnabled(Value: Boolean); + protected function AccessError(const ADataType: string): EPressMVPError; function GetAccessMode: TPressAccessMode; function GetEnabled: Boolean; function GetIsChanged: Boolean; - function GetModel: TPressMVPModel; function GetReadOnly: Boolean; function GetVisible: Boolean; procedure SetAccessMode(Value: TPressAccessMode); - procedure SetEnabled(Value: Boolean); procedure SetReadOnly(Value: Boolean); procedure SetVisible(Value: Boolean); - protected procedure ViewClickEvent(Sender: TObject); virtual; procedure ViewDblClickEvent(Sender: TObject); virtual; procedure ViewMouseDownEvent(Sender: TObject; Button: TMouseButton; Shift: TShiftState; X, Y: Integer); virtual; This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <jcm...@us...> - 2010-09-28 01:02:53
|
Revision: 1077 http://pressobjects.svn.sourceforge.net/pressobjects/?rev=1077&view=rev Author: jcmoraisjr Date: 2010-09-28 01:02:47 +0000 (Tue, 28 Sep 2010) Log Message: ----------- [Subject] implemented utf8 routines. Modified Paths: -------------- trunk/Source/Core/PressAttributes.pas trunk/Source/Core/PressUtils.pas Modified: trunk/Source/Core/PressAttributes.pas =================================================================== --- trunk/Source/Core/PressAttributes.pas 2010-09-01 02:44:34 UTC (rev 1076) +++ trunk/Source/Core/PressAttributes.pas 2010-09-28 01:02:47 UTC (rev 1077) @@ -1366,7 +1366,7 @@ VMaxSize := Metadata.Size else VMaxSize := 0; - if (VMaxSize > 0) and (Length(AValue) > VMaxSize) then + if (VMaxSize > 0) and (PressLength(AValue) > VMaxSize) then begin if Assigned(Owner) then VOwnerName := Owner.ClassName Modified: trunk/Source/Core/PressUtils.pas =================================================================== --- trunk/Source/Core/PressUtils.pas 2010-09-01 02:44:34 UTC (rev 1076) +++ trunk/Source/Core/PressUtils.pas 2010-09-28 01:02:47 UTC (rev 1077) @@ -27,6 +27,7 @@ PressClasses; function PressFormatMaskText(const EditMask: string; const Value: string): string; +function PressLength(AStr: string): {$ifdef fpc}PtrInt; inline;{$else}Integer;{$endif} function PressVarFormat(const AFormat: string; const AArgs: array of Variant): string; procedure PressGenerateGUID(out AGUID: TGUID); procedure PressAsIntf(const AInstance: IInterface; const AIntf: TGUID; out AInst); @@ -57,6 +58,7 @@ {$ENDIF} {$ifdef lcl} Translations, + LCLProc, {$endif} PressConsts; @@ -68,6 +70,11 @@ .FormatMaskText(EditMask, Value){$ENDIF}; end; +function PressLength(AStr: string): {$ifdef fpc}PtrInt; inline;{$else}Integer;{$endif} +begin + Result := {$ifdef lcl}UTF8Length(AStr){$else}Length(AStr){$endif}; +end; + function PressVarFormat(const AFormat: string; const AArgs: array of Variant): string; var VConsts: array of TVarRec; This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <jcm...@us...> - 2010-09-01 02:44:43
|
Revision: 1076 http://pressobjects.svn.sourceforge.net/pressobjects/?rev=1076&view=rev Author: jcmoraisjr Date: 2010-09-01 02:44:34 +0000 (Wed, 01 Sep 2010) Log Message: ----------- [Core] Fixed some encoding issues. Modified Paths: -------------- trunk/Source/Brokers/PressFastReportBroker.pas trunk/Source/Brokers/PressXCLBroker.pas trunk/Source/Core/PressClasses.pas trunk/Source/Core/PressMVPInteractor.pas trunk/Source/Core/PressUtils.pas Modified: trunk/Source/Brokers/PressFastReportBroker.pas =================================================================== --- trunk/Source/Brokers/PressFastReportBroker.pas 2010-09-01 02:31:50 UTC (rev 1075) +++ trunk/Source/Brokers/PressFastReportBroker.pas 2010-09-01 02:44:34 UTC (rev 1076) @@ -59,11 +59,9 @@ implementation uses - {$ifndef d5}Variants,{$endif} SysUtils, Forms, - PressConsts, - PressUtils; + PressConsts; { TPressFRReport } @@ -151,8 +149,6 @@ VFieldName := ParName; end; OnNeedValue(VDataSetName, VFieldName, ParValue, False); - if VarType(ParValue) = varString then - ParValue := PressEncodeString(ParValue); end; end; Modified: trunk/Source/Brokers/PressXCLBroker.pas =================================================================== --- trunk/Source/Brokers/PressXCLBroker.pas 2010-09-01 02:31:50 UTC (rev 1075) +++ trunk/Source/Brokers/PressXCLBroker.pas 2010-09-01 02:44:34 UTC (rev 1076) @@ -490,7 +490,6 @@ ExtDlgs, PressSubject, PressConsts, - PressUtils, PressPicture; type @@ -747,7 +746,7 @@ begin FNotifier := TPressNotifier.Create({$IFDEF FPC}@{$ENDIF}Notify); FMVPCommand := ACommand; - Caption := PressEncodeString(FMVPCommand.Caption); + Caption := FMVPCommand.Caption; Enabled := FMVPCommand.Enabled; Visible := FMVPCommand.Visible; ShortCut := FMVPCommand.ShortCut; @@ -1242,7 +1241,7 @@ function TPressMVPEditView.GetAsString: string; begin - Result := PressDecodeString(TPressXCLCustomEditFriend(Control).Text); + Result := TPressXCLCustomEditFriend(Control).Text; end; function TPressMVPEditView.GetControl: TCustomEdit; @@ -1282,7 +1281,7 @@ if AccessMode = amInvisible then TPressXCLCustomEditFriend(Control).Text := '' else - TPressXCLCustomEditFriend(Control).Text := PressEncodeString(Model.AsString); + TPressXCLCustomEditFriend(Control).Text := Model.AsString; Unchanged; end; @@ -1302,7 +1301,7 @@ procedure TPressMVPEditView.SetText(const Value: string); begin - TPressXCLCustomEditFriend(Control).Text := PressEncodeString(Value); + TPressXCLCustomEditFriend(Control).Text := Value; end; procedure TPressMVPEditView.ViewChangeEvent(Sender: TObject); @@ -1334,7 +1333,7 @@ function TPressMVPDateTimeView.GetAsString: string; begin - Result := PressDecodeString(TPressXCLCustomCalendarFriend(Control).Text); + Result := TPressXCLCustomCalendarFriend(Control).Text; end; function TPressMVPDateTimeView.GetControl: TCustomCalendar; @@ -1488,7 +1487,7 @@ function TPressMVPComboBoxView.GetAsString: string; begin - Result := PressDecodeString(TPressXCLCustomComboBoxFriend(Control).Text); + Result := TPressXCLCustomComboBoxFriend(Control).Text; end; function TPressMVPComboBoxView.GetControl: TCustomComboBox; @@ -1538,7 +1537,7 @@ procedure TPressMVPComboBoxView.InternalAddReference(const ACaption: string); begin - Control.Items.Add(PressEncodeString(ACaption)); + Control.Items.Add(ACaption); end; procedure TPressMVPComboBoxView.InternalClear; @@ -1560,7 +1559,7 @@ if AccessMode = amInvisible then TPressXCLCustomComboBoxFriend(Control).Text := '' else - TPressXCLCustomComboBoxFriend(Control).Text := PressEncodeString(Model.AsString); + TPressXCLCustomComboBoxFriend(Control).Text := Model.AsString; Unchanged; end; @@ -1931,7 +1930,7 @@ function TPressMVPCaptionView.GetAsString: string; begin - Result := PressDecodeString(TPressXCLControlFriend(Control).Caption); + Result := TPressXCLControlFriend(Control).Caption; end; procedure TPressMVPCaptionView.InternalUpdate; @@ -1941,12 +1940,12 @@ if AccessMode = amInvisible then TPressXCLControlFriend(Control).Caption := '' else - TPressXCLControlFriend(Control).Caption := PressEncodeString(Model.AsString); + TPressXCLControlFriend(Control).Caption := Model.AsString; end; procedure TPressMVPCaptionView.SetText(const Value: string); begin - TPressXCLControlFriend(Control).Caption := PressEncodeString(Value); + TPressXCLControlFriend(Control).Caption := Value; end; { TPressMVPLabelView } @@ -2111,7 +2110,7 @@ procedure TPressMVPFormView.SetText(const Value: string); begin - Control.Caption := PressEncodeString(Value); + Control.Caption := Value; end; procedure TPressMVPFormView.Show(AModal: Boolean); Modified: trunk/Source/Core/PressClasses.pas =================================================================== --- trunk/Source/Core/PressClasses.pas 2010-09-01 02:31:50 UTC (rev 1075) +++ trunk/Source/Core/PressClasses.pas 2010-09-01 02:44:34 UTC (rev 1076) @@ -307,20 +307,19 @@ Windows, {$ENDIF} Math, - PressConsts, - PressUtils; + PressConsts; { EPressError } constructor EPressError.Create(const AMsg: string); begin - inherited Create(PressEncodeString(AMsg)); + inherited Create(AMsg); end; constructor EPressError.CreateFmt(const AMsg: string; const AArgs: array of const); begin - inherited CreateFmt(PressEncodeString(AMsg), AArgs); + inherited CreateFmt(AMsg, AArgs); end; { EPressParseError } Modified: trunk/Source/Core/PressMVPInteractor.pas =================================================================== --- trunk/Source/Core/PressMVPInteractor.pas 2010-09-01 02:31:50 UTC (rev 1075) +++ trunk/Source/Core/PressMVPInteractor.pas 2010-09-01 02:44:34 UTC (rev 1076) @@ -816,7 +816,7 @@ else {alCenter} VLeft := (ARect.Left + ARect.Right - PressWidget.TextWidth(ACanvasHandle, AText)) div 2; end; - PressWidget.TextRect(ACanvasHandle, ARect, VLeft, VTop, PressEncodeString(AText)); + PressWidget.TextRect(ACanvasHandle, ARect, VLeft, VTop, AText); end; { TPressMVPDrawItemInteractor } Modified: trunk/Source/Core/PressUtils.pas =================================================================== --- trunk/Source/Core/PressUtils.pas 2010-09-01 02:31:50 UTC (rev 1075) +++ trunk/Source/Core/PressUtils.pas 2010-09-01 02:44:34 UTC (rev 1076) @@ -34,7 +34,6 @@ function PressSetPropertyValue(AObject: TPersistent; const APathName, AValue: string; AError: Boolean = False): Boolean; procedure PressDebug(const AStr: string); function PressUnquotedStr(const AStr: string): string; -function PressDecodeString(const AStr: string): string; function PressEncodeString(const AStr: string): string; {$ifdef d5down} function PressD5VariantToInt64(AVariant: Variant): Int64; @@ -268,16 +267,6 @@ Result := AStr; end; -function PressDecodeString(const AStr: string): string; -begin -{$ifdef lcl} - if SystemCharSetIsUTF8 then - Result := Utf8Decode(AStr) - else -{$endif} - Result := AStr; -end; - function PressEncodeString(const AStr: string): string; begin {$ifdef lcl} This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <jcm...@us...> - 2010-09-01 02:31:56
|
Revision: 1075 http://pressobjects.svn.sourceforge.net/pressobjects/?rev=1075&view=rev Author: jcmoraisjr Date: 2010-09-01 02:31:50 +0000 (Wed, 01 Sep 2010) Log Message: ----------- [Packages] fixed output dir. Modified Paths: -------------- trunk/Source/Packages/Laz/PressLazBrokersRT.lpk trunk/Source/Packages/Laz/PressLazCoreRT.lpk trunk/Source/Packages/Laz/PressLazFBLibRT.lpk trunk/Source/Packages/Laz/PressLazReportRT.lpk trunk/Source/Packages/Laz/PressLazSQLdbRT.lpk Modified: trunk/Source/Packages/Laz/PressLazBrokersRT.lpk =================================================================== --- trunk/Source/Packages/Laz/PressLazBrokersRT.lpk 2010-08-30 00:46:40 UTC (rev 1074) +++ trunk/Source/Packages/Laz/PressLazBrokersRT.lpk 2010-09-01 02:31:50 UTC (rev 1075) @@ -9,7 +9,7 @@ <PathDelim Value="\"/> <SearchPaths> <OtherUnitFiles Value="..\..\Brokers\"/> - <UnitOutputDirectory Value="..\..\..\bin\laz\Brokers\$(TargetCPU)-$(TargetOS)"/> + <UnitOutputDirectory Value="..\..\..\bin\Laz\Brokers\$(TargetCPU)-$(TargetOS)"/> </SearchPaths> <Parsing> <SyntaxOptions> Modified: trunk/Source/Packages/Laz/PressLazCoreRT.lpk =================================================================== --- trunk/Source/Packages/Laz/PressLazCoreRT.lpk 2010-08-30 00:46:40 UTC (rev 1074) +++ trunk/Source/Packages/Laz/PressLazCoreRT.lpk 2010-09-01 02:31:50 UTC (rev 1075) @@ -9,7 +9,7 @@ <PathDelim Value="\"/> <SearchPaths> <OtherUnitFiles Value="..\..\Core\"/> - <UnitOutputDirectory Value="..\..\..\bin\laz\Core\$(TargetCPU)-$(TargetOS)\"/> + <UnitOutputDirectory Value="..\..\..\bin\Laz\Core\$(TargetCPU)-$(TargetOS)\"/> </SearchPaths> <Parsing> <SyntaxOptions> Modified: trunk/Source/Packages/Laz/PressLazFBLibRT.lpk =================================================================== --- trunk/Source/Packages/Laz/PressLazFBLibRT.lpk 2010-08-30 00:46:40 UTC (rev 1074) +++ trunk/Source/Packages/Laz/PressLazFBLibRT.lpk 2010-09-01 02:31:50 UTC (rev 1075) @@ -8,7 +8,7 @@ <PathDelim Value="\"/> <SearchPaths> <OtherUnitFiles Value="..\..\Brokers\"/> - <UnitOutputDirectory Value="..\..\..\bin\laz\Brokers\$(TargetCPU)-$(TargetOS)"/> + <UnitOutputDirectory Value="..\..\..\bin\Laz\Brokers\$(TargetCPU)-$(TargetOS)"/> </SearchPaths> <Parsing> <SyntaxOptions> Modified: trunk/Source/Packages/Laz/PressLazReportRT.lpk =================================================================== --- trunk/Source/Packages/Laz/PressLazReportRT.lpk 2010-08-30 00:46:40 UTC (rev 1074) +++ trunk/Source/Packages/Laz/PressLazReportRT.lpk 2010-09-01 02:31:50 UTC (rev 1075) @@ -8,7 +8,7 @@ <PathDelim Value="\"/> <SearchPaths> <OtherUnitFiles Value="..\..\Brokers\"/> - <UnitOutputDirectory Value="..\..\..\bin\laz\Brokers\$(TargetCPU)-$(TargetOS)"/> + <UnitOutputDirectory Value="..\..\..\bin\Laz\Brokers\$(TargetCPU)-$(TargetOS)"/> </SearchPaths> <Parsing> <SyntaxOptions> Modified: trunk/Source/Packages/Laz/PressLazSQLdbRT.lpk =================================================================== --- trunk/Source/Packages/Laz/PressLazSQLdbRT.lpk 2010-08-30 00:46:40 UTC (rev 1074) +++ trunk/Source/Packages/Laz/PressLazSQLdbRT.lpk 2010-09-01 02:31:50 UTC (rev 1075) @@ -9,7 +9,7 @@ <PathDelim Value="\"/> <SearchPaths> <OtherUnitFiles Value="..\..\Brokers\"/> - <UnitOutputDirectory Value="..\..\..\bin\laz\Brokers\$(TargetCPU)-$(TargetOS)"/> + <UnitOutputDirectory Value="..\..\..\bin\Laz\Brokers\$(TargetCPU)-$(TargetOS)"/> </SearchPaths> <Parsing> <SyntaxOptions> This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <jcm...@us...> - 2010-08-30 00:46:47
|
Revision: 1074 http://pressobjects.svn.sourceforge.net/pressobjects/?rev=1074&view=rev Author: jcmoraisjr Date: 2010-08-30 00:46:40 +0000 (Mon, 30 Aug 2010) Log Message: ----------- [Core] Fixed charset issue with fpc. Modified Paths: -------------- trunk/Source/Core/PressMessages.inc trunk/Source/Core/PressMessages.pas trunk/Source/Core/PressMessages_de.pas trunk/Source/Core/PressMessages_ptbr.pas Modified: trunk/Source/Core/PressMessages.inc =================================================================== --- trunk/Source/Core/PressMessages.inc 2010-08-30 00:44:24 UTC (rev 1073) +++ trunk/Source/Core/PressMessages.inc 2010-08-30 00:46:40 UTC (rev 1074) @@ -1,146 +1,146 @@ // Error messages from core and adjacent classes - SCannotReleaseInstance := SCannotReleaseInstance_rst; - SEnumItemNotFound := SEnumItemNotFound_rst; - SInvalidIdentifier := SInvalidIdentifier_rst; - SInvalidInterfaceTypecast := SInvalidInterfaceTypecast_rst; - SInvalidLogon := SInvalidLogon_rst; - SMethodNotFound := SMethodNotFound_rst; - SNoLoggedUser := SNoLoggedUser_rst; - SPasswordsDontMatch := SPasswordsDontMatch_rst; - SPropertyIsReadOnly := SPropertyIsReadOnly_rst; - SPropertyNotFound := SPropertyNotFound_rst; - SServiceNotFound := SServiceNotFound_rst; - SStringLengthOutOfBounds := SStringLengthOutOfBounds_rst; - STokenExpected := STokenExpected_rst; - STokenLengthOutOfBounds := STokenLengthOutOfBounds_rst; - SUnassignedAppManager := SUnassignedAppManager_rst; - SUnassignedServiceType := SUnassignedServiceType_rst; - SUnexpectedEof := SUnexpectedEof_rst; - SUnsupportedFeature := SUnsupportedFeature_rst; - SUnsupportedVariantType := SUnsupportedVariantType_rst; + SCannotReleaseInstance := PressEncodeString(SCannotReleaseInstance_rst); + SEnumItemNotFound := PressEncodeString(SEnumItemNotFound_rst); + SInvalidIdentifier := PressEncodeString(SInvalidIdentifier_rst); + SInvalidInterfaceTypecast := PressEncodeString(SInvalidInterfaceTypecast_rst); + SInvalidLogon := PressEncodeString(SInvalidLogon_rst); + SMethodNotFound := PressEncodeString(SMethodNotFound_rst); + SNoLoggedUser := PressEncodeString(SNoLoggedUser_rst); + SPasswordsDontMatch := PressEncodeString(SPasswordsDontMatch_rst); + SPropertyIsReadOnly := PressEncodeString(SPropertyIsReadOnly_rst); + SPropertyNotFound := PressEncodeString(SPropertyNotFound_rst); + SServiceNotFound := PressEncodeString(SServiceNotFound_rst); + SStringLengthOutOfBounds := PressEncodeString(SStringLengthOutOfBounds_rst); + STokenExpected := PressEncodeString(STokenExpected_rst); + STokenLengthOutOfBounds := PressEncodeString(STokenLengthOutOfBounds_rst); + SUnassignedAppManager := PressEncodeString(SUnassignedAppManager_rst); + SUnassignedServiceType := PressEncodeString(SUnassignedServiceType_rst); + SUnexpectedEof := PressEncodeString(SUnexpectedEof_rst); + SUnsupportedFeature := PressEncodeString(SUnsupportedFeature_rst); + SUnsupportedVariantType := PressEncodeString(SUnsupportedVariantType_rst); // Error messages from the Data Type (Subject) framework - SAttributeAccessError := SAttributeAccessError_rst; - SAttributeConversionError := SAttributeConversionError_rst; - SAttributeIsNotItem := SAttributeIsNotItem_rst; - SAttributeIsNotValue := SAttributeIsNotValue_rst; - SAttributeNotFound := SAttributeNotFound_rst; - SAttributeTypeNotFound := SAttributeTypeNotFound_rst; - SCannotAssignOwnerPartsMetadata := SCannotAssignOwnerPartsMetadata_rst; - SCannotRecursivelyCreateMetadatas := SCannotRecursivelyCreateMetadatas_rst; - SClassNotFound := SClassNotFound_rst; - SEnumMetadataNotFound := SEnumMetadataNotFound_rst; - SEnumOutOfBounds := SEnumOutOfBounds_rst; - SInstanceAlreadyOwned := SInstanceAlreadyOwned_rst; - SInstanceNotFound := SInstanceNotFound_rst; - SInvalidAttributeClass := SInvalidAttributeClass_rst; - SInvalidAttributeName := SInvalidAttributeName_rst; - SInvalidAttributeValue := SInvalidAttributeValue_rst; - SInvalidClassInheritance := SInvalidClassInheritance_rst; - SMetadataNotFound := SMetadataNotFound_rst; - SMetadataParseError := SMetadataParseError_rst; - SNoReferenceOrDataAccess := SNoReferenceOrDataAccess_rst; - SParseFormulaError := SParseFormulaError_rst; - SPathReferencesNil := SPathReferencesNil_rst; - SSingletonClassNotFound := SSingletonClassNotFound_rst; - SStringOverflow := SStringOverflow_rst; - SUnsupportedAttribute := SUnsupportedAttribute_rst; - SUnsupportedAttributeType := SUnsupportedAttributeType_rst; - SUnsupportedGraphicFormat := SUnsupportedGraphicFormat_rst; + SAttributeAccessError := PressEncodeString(SAttributeAccessError_rst); + SAttributeConversionError := PressEncodeString(SAttributeConversionError_rst); + SAttributeIsNotItem := PressEncodeString(SAttributeIsNotItem_rst); + SAttributeIsNotValue := PressEncodeString(SAttributeIsNotValue_rst); + SAttributeNotFound := PressEncodeString(SAttributeNotFound_rst); + SAttributeTypeNotFound := PressEncodeString(SAttributeTypeNotFound_rst); + SCannotAssignOwnerPartsMetadata := PressEncodeString(SCannotAssignOwnerPartsMetadata_rst); + SCannotRecursivelyCreateMetadatas := PressEncodeString(SCannotRecursivelyCreateMetadatas_rst); + SClassNotFound := PressEncodeString(SClassNotFound_rst); + SEnumMetadataNotFound := PressEncodeString(SEnumMetadataNotFound_rst); + SEnumOutOfBounds := PressEncodeString(SEnumOutOfBounds_rst); + SInstanceAlreadyOwned := PressEncodeString(SInstanceAlreadyOwned_rst); + SInstanceNotFound := PressEncodeString(SInstanceNotFound_rst); + SInvalidAttributeClass := PressEncodeString(SInvalidAttributeClass_rst); + SInvalidAttributeName := PressEncodeString(SInvalidAttributeName_rst); + SInvalidAttributeValue := PressEncodeString(SInvalidAttributeValue_rst); + SInvalidClassInheritance := PressEncodeString(SInvalidClassInheritance_rst); + SMetadataNotFound := PressEncodeString(SMetadataNotFound_rst); + SMetadataParseError := PressEncodeString(SMetadataParseError_rst); + SNoReferenceOrDataAccess := PressEncodeString(SNoReferenceOrDataAccess_rst); + SParseFormulaError := PressEncodeString(SParseFormulaError_rst); + SPathReferencesNil := PressEncodeString(SPathReferencesNil_rst); + SSingletonClassNotFound := PressEncodeString(SSingletonClassNotFound_rst); + SStringOverflow := PressEncodeString(SStringOverflow_rst); + SUnsupportedAttribute := PressEncodeString(SUnsupportedAttribute_rst); + SUnsupportedAttributeType := PressEncodeString(SUnsupportedAttributeType_rst); + SUnsupportedGraphicFormat := PressEncodeString(SUnsupportedGraphicFormat_rst); // Error messages from the MVP framework - SAmbiguousClass := SAmbiguousClass_rst; - SColumnDataParseError := SColumnDataParseError_rst; - SComponentIsNotAControl := SComponentIsNotAControl_rst; - SComponentNotFound := SComponentNotFound_rst; - SDisplayNamesAlreadyAssigned := SDisplayNamesAlreadyAssigned_rst; - SMaxItemCountReached := SMaxItemCountReached_rst; - SUnassignedAttributeType := SUnassignedAttributeType_rst; - SUnassignedItemObjectClass := SUnassignedItemObjectClass_rst; - SUnassignedMainForm := SUnassignedMainForm_rst; - SUnassignedModel := SUnassignedModel_rst; - SUnassignedPresenterBO := SUnassignedPresenterBO_rst; - SUnassignedPresenterForm := SUnassignedPresenterForm_rst; - SUnassignedPresenterParent := SUnassignedPresenterParent_rst; - SUnassignedSubject := SUnassignedSubject_rst; - SUnassignedWidgetManager := SUnassignedWidgetManager_rst; - SUnexpectedMVPClassParam := SUnexpectedMVPClassParam_rst; - SUnsupportedComponent := SUnsupportedComponent_rst; - SUnsupportedControl := SUnsupportedControl_rst; - SUnsupportedDisplayNames := SUnsupportedDisplayNames_rst; - SUnsupportedModel := SUnsupportedModel_rst; - SUnsupportedObject := SUnsupportedObject_rst; - SUnsupportedSubject := SUnsupportedSubject_rst; - SViewAccessError := SViewAccessError_rst; - SWidgetManagerAlreadyAssigned := SWidgetManagerAlreadyAssigned_rst; + SAmbiguousClass := PressEncodeString(SAmbiguousClass_rst); + SColumnDataParseError := PressEncodeString(SColumnDataParseError_rst); + SComponentIsNotAControl := PressEncodeString(SComponentIsNotAControl_rst); + SComponentNotFound := PressEncodeString(SComponentNotFound_rst); + SDisplayNamesAlreadyAssigned := PressEncodeString(SDisplayNamesAlreadyAssigned_rst); + SMaxItemCountReached := PressEncodeString(SMaxItemCountReached_rst); + SUnassignedAttributeType := PressEncodeString(SUnassignedAttributeType_rst); + SUnassignedItemObjectClass := PressEncodeString(SUnassignedItemObjectClass_rst); + SUnassignedMainForm := PressEncodeString(SUnassignedMainForm_rst); + SUnassignedModel := PressEncodeString(SUnassignedModel_rst); + SUnassignedPresenterBO := PressEncodeString(SUnassignedPresenterBO_rst); + SUnassignedPresenterForm := PressEncodeString(SUnassignedPresenterForm_rst); + SUnassignedPresenterParent := PressEncodeString(SUnassignedPresenterParent_rst); + SUnassignedSubject := PressEncodeString(SUnassignedSubject_rst); + SUnassignedWidgetManager := PressEncodeString(SUnassignedWidgetManager_rst); + SUnexpectedMVPClassParam := PressEncodeString(SUnexpectedMVPClassParam_rst); + SUnsupportedComponent := PressEncodeString(SUnsupportedComponent_rst); + SUnsupportedControl := PressEncodeString(SUnsupportedControl_rst); + SUnsupportedDisplayNames := PressEncodeString(SUnsupportedDisplayNames_rst); + SUnsupportedModel := PressEncodeString(SUnsupportedModel_rst); + SUnsupportedObject := PressEncodeString(SUnsupportedObject_rst); + SUnsupportedSubject := PressEncodeString(SUnsupportedSubject_rst); + SViewAccessError := PressEncodeString(SViewAccessError_rst); + SWidgetManagerAlreadyAssigned := PressEncodeString(SWidgetManagerAlreadyAssigned_rst); // Error messages from the OPF framework - SAttributeCannotBeNull := SAttributeCannotBeNull_rst; - SAttributeReferencesOwnedClass := SAttributeReferencesOwnedClass_rst; - SCannotChangeOPFBroker := SCannotChangeOPFBroker_rst; - SCannotStoreOrphanObject := SCannotStoreOrphanObject_rst; - SCannotUseAggregateFunctionHere := SCannotUseAggregateFunctionHere_rst; - SClassIsNotPersistent := SClassIsNotPersistent_rst; - SDatabaseIdentifierTooLong := SDatabaseIdentifierTooLong_rst; - SFieldNotFound := SFieldNotFound_rst; - SObjectChangedError := SObjectChangedError_rst; - STargetClassIsNotPersistent := STargetClassIsNotPersistent_rst; - SUnassignedPersistenceService := SUnassignedPersistenceService_rst; - SUnsupportedConnector := SUnsupportedConnector_rst; - SUnsupportedFieldType := SUnsupportedFieldType_rst; + SAttributeCannotBeNull := PressEncodeString(SAttributeCannotBeNull_rst); + SAttributeReferencesOwnedClass := PressEncodeString(SAttributeReferencesOwnedClass_rst); + SCannotChangeOPFBroker := PressEncodeString(SCannotChangeOPFBroker_rst); + SCannotStoreOrphanObject := PressEncodeString(SCannotStoreOrphanObject_rst); + SCannotUseAggregateFunctionHere := PressEncodeString(SCannotUseAggregateFunctionHere_rst); + SClassIsNotPersistent := PressEncodeString(SClassIsNotPersistent_rst); + SDatabaseIdentifierTooLong := PressEncodeString(SDatabaseIdentifierTooLong_rst); + SFieldNotFound := PressEncodeString(SFieldNotFound_rst); + SObjectChangedError := PressEncodeString(SObjectChangedError_rst); + STargetClassIsNotPersistent := PressEncodeString(STargetClassIsNotPersistent_rst); + SUnassignedPersistenceService := PressEncodeString(SUnassignedPersistenceService_rst); + SUnsupportedConnector := PressEncodeString(SUnsupportedConnector_rst); + SUnsupportedFieldType := PressEncodeString(SUnsupportedFieldType_rst); // Error messages from brokers - SUnassignedPersistenceConnector := SUnassignedPersistenceConnector_rst; + SUnassignedPersistenceConnector := PressEncodeString(SUnassignedPersistenceConnector_rst); // Messages for visual components - SConnectionManagerCaption := SConnectionManagerCaption_rst; + SConnectionManagerCaption := PressEncodeString(SConnectionManagerCaption_rst); // Messages for Commands - SPressTodayCommand := SPressTodayCommand_rst; - SPressLoadPictureCommand := SPressLoadPictureCommand_rst; - SPressRemovePictureCommand := SPressRemovePictureCommand_rst; - SPressIncludeObjectCommand := SPressIncludeObjectCommand_rst; - SPressAddItemCommand := SPressAddItemCommand_rst; - SPressInsertItemCommand := SPressInsertItemCommand_rst; - SPressSelectItemCommand := SPressSelectItemCommand_rst; - SPressEditItemCommand := SPressEditItemCommand_rst; - SPressRemoveItemCommand := SPressRemoveItemCommand_rst; - SPressRefreshCommand := SPressRefreshCommand_rst; - SPressSaveFormCommand := SPressSaveFormCommand_rst; - SPressCancelFormCommand := SPressCancelFormCommand_rst; - SPressCloseFormCommand := SPressCloseFormCommand_rst; - SPressExecuteQueryCommand := SPressExecuteQueryCommand_rst; - SPressAssignSelectionQueryCommand := SPressAssignSelectionQueryCommand_rst; - SPressSelectAllCommand := SPressSelectAllCommand_rst; - SPressSelectNoneCommand := SPressSelectNoneCommand_rst; - SPressSelectCurrentCommand := SPressSelectCurrentCommand_rst; - SPressSelectInvertCommand := SPressSelectInvertCommand_rst; - SPressSortByCommand := SPressSortByCommand_rst; - SPressManageReportCommand := SPressManageReportCommand_rst; + SPressTodayCommand := PressEncodeString(SPressTodayCommand_rst); + SPressLoadPictureCommand := PressEncodeString(SPressLoadPictureCommand_rst); + SPressRemovePictureCommand := PressEncodeString(SPressRemovePictureCommand_rst); + SPressIncludeObjectCommand := PressEncodeString(SPressIncludeObjectCommand_rst); + SPressAddItemCommand := PressEncodeString(SPressAddItemCommand_rst); + SPressInsertItemCommand := PressEncodeString(SPressInsertItemCommand_rst); + SPressSelectItemCommand := PressEncodeString(SPressSelectItemCommand_rst); + SPressEditItemCommand := PressEncodeString(SPressEditItemCommand_rst); + SPressRemoveItemCommand := PressEncodeString(SPressRemoveItemCommand_rst); + SPressRefreshCommand := PressEncodeString(SPressRefreshCommand_rst); + SPressSaveFormCommand := PressEncodeString(SPressSaveFormCommand_rst); + SPressCancelFormCommand := PressEncodeString(SPressCancelFormCommand_rst); + SPressCloseFormCommand := PressEncodeString(SPressCloseFormCommand_rst); + SPressExecuteQueryCommand := PressEncodeString(SPressExecuteQueryCommand_rst); + SPressAssignSelectionQueryCommand := PressEncodeString(SPressAssignSelectionQueryCommand_rst); + SPressSelectAllCommand := PressEncodeString(SPressSelectAllCommand_rst); + SPressSelectNoneCommand := PressEncodeString(SPressSelectNoneCommand_rst); + SPressSelectCurrentCommand := PressEncodeString(SPressSelectCurrentCommand_rst); + SPressSelectInvertCommand := PressEncodeString(SPressSelectInvertCommand_rst); + SPressSortByCommand := PressEncodeString(SPressSortByCommand_rst); + SPressManageReportCommand := PressEncodeString(SPressManageReportCommand_rst); // Partial translations for parsers or another error messages - SPressAttributeNameMsg := SPressAttributeNameMsg_rst; - SPressBooleanValueMsg := SPressBooleanValueMsg_rst; - SPressClassNameMsg := SPressClassNameMsg_rst; - SPressExpressionMsg := SPressExpressionMsg_rst; - SPressEofMsg := SPressEofMsg_rst; - SPressFunctionMsg := SPressFunctionMsg_rst; - SPressIdentifierMsg := SPressIdentifierMsg_rst; - SPressIntegerValueMsg := SPressIntegerValueMsg_rst; - SPressLineBreakMsg := SPressLineBreakMsg_rst; - SPressNumberValueMsg := SPressNumberValueMsg_rst; - SPressPropertyNameMsg := SPressPropertyNameMsg_rst; - SPressReportErrorMsg := SPressReportErrorMsg_rst; - SPressStringDelimiterMsg := SPressStringDelimiterMsg_rst; - SPressStringValueMsg := SPressStringValueMsg_rst; + SPressAttributeNameMsg := PressEncodeString(SPressAttributeNameMsg_rst); + SPressBooleanValueMsg := PressEncodeString(SPressBooleanValueMsg_rst); + SPressClassNameMsg := PressEncodeString(SPressClassNameMsg_rst); + SPressExpressionMsg := PressEncodeString(SPressExpressionMsg_rst); + SPressEofMsg := PressEncodeString(SPressEofMsg_rst); + SPressFunctionMsg := PressEncodeString(SPressFunctionMsg_rst); + SPressIdentifierMsg := PressEncodeString(SPressIdentifierMsg_rst); + SPressIntegerValueMsg := PressEncodeString(SPressIntegerValueMsg_rst); + SPressLineBreakMsg := PressEncodeString(SPressLineBreakMsg_rst); + SPressNumberValueMsg := PressEncodeString(SPressNumberValueMsg_rst); + SPressPropertyNameMsg := PressEncodeString(SPressPropertyNameMsg_rst); + SPressReportErrorMsg := PressEncodeString(SPressReportErrorMsg_rst); + SPressStringDelimiterMsg := PressEncodeString(SPressStringDelimiterMsg_rst); + SPressStringValueMsg := PressEncodeString(SPressStringValueMsg_rst); // Messages for user access - SPressNoAccess := SPressNoAccess_rst; - SPressReadOnlyAccess := SPressReadOnlyAccess_rst; - SPressReadWriteAccess := SPressReadWriteAccess_rst; + SPressNoAccess := PressEncodeString(SPressNoAccess_rst); + SPressReadOnlyAccess := PressEncodeString(SPressReadOnlyAccess_rst); + SPressReadWriteAccess := PressEncodeString(SPressReadWriteAccess_rst); // Messages for dialog box - SPressCancelChangesDialog := SPressCancelChangesDialog_rst; - SPressConfirmRemoveOneItemDialog := SPressConfirmRemoveOneItemDialog_rst; - SPressConfirmRemoveItemsDialog := SPressConfirmRemoveItemsDialog_rst; - SPressSaveChangesDialog := SPressSaveChangesDialog_rst; + SPressCancelChangesDialog := PressEncodeString(SPressCancelChangesDialog_rst); + SPressConfirmRemoveOneItemDialog := PressEncodeString(SPressConfirmRemoveOneItemDialog_rst); + SPressConfirmRemoveItemsDialog := PressEncodeString(SPressConfirmRemoveItemsDialog_rst); + SPressSaveChangesDialog := PressEncodeString(SPressSaveChangesDialog_rst); Modified: trunk/Source/Core/PressMessages.pas =================================================================== --- trunk/Source/Core/PressMessages.pas 2010-08-30 00:44:24 UTC (rev 1073) +++ trunk/Source/Core/PressMessages.pas 2010-08-30 00:46:40 UTC (rev 1074) @@ -23,7 +23,8 @@ implementation uses - PressConsts; + PressConsts, + PressUtils; resourcestring {$I PressMessages_en.inc} Modified: trunk/Source/Core/PressMessages_de.pas =================================================================== --- trunk/Source/Core/PressMessages_de.pas 2010-08-30 00:44:24 UTC (rev 1073) +++ trunk/Source/Core/PressMessages_de.pas 2010-08-30 00:46:40 UTC (rev 1074) @@ -30,7 +30,8 @@ implementation uses - PressConsts; + PressConsts, + PressUtils; resourcestring {$I PressMessages_de.inc} Modified: trunk/Source/Core/PressMessages_ptbr.pas =================================================================== --- trunk/Source/Core/PressMessages_ptbr.pas 2010-08-30 00:44:24 UTC (rev 1073) +++ trunk/Source/Core/PressMessages_ptbr.pas 2010-08-30 00:46:40 UTC (rev 1074) @@ -30,7 +30,8 @@ implementation uses - PressConsts; + PressConsts, + PressUtils; resourcestring {$I PressMessages_ptbr.inc} This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <jcm...@us...> - 2010-08-30 00:44:30
|
Revision: 1073 http://pressobjects.svn.sourceforge.net/pressobjects/?rev=1073&view=rev Author: jcmoraisjr Date: 2010-08-30 00:44:24 +0000 (Mon, 30 Aug 2010) Log Message: ----------- [Brokers] Fixed charset issue with LazReport. Modified Paths: -------------- trunk/Source/Brokers/PressFastReportBroker.pas Modified: trunk/Source/Brokers/PressFastReportBroker.pas =================================================================== --- trunk/Source/Brokers/PressFastReportBroker.pas 2010-08-30 00:39:18 UTC (rev 1072) +++ trunk/Source/Brokers/PressFastReportBroker.pas 2010-08-30 00:44:24 UTC (rev 1073) @@ -59,9 +59,11 @@ implementation uses + {$ifndef d5}Variants,{$endif} SysUtils, Forms, - PressConsts; + PressConsts, + PressUtils; { TPressFRReport } @@ -149,6 +151,8 @@ VFieldName := ParName; end; OnNeedValue(VDataSetName, VFieldName, ParValue, False); + if VarType(ParValue) = varString then + ParValue := PressEncodeString(ParValue); end; end; This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <jcm...@us...> - 2010-08-30 00:39:24
|
Revision: 1072 http://pressobjects.svn.sourceforge.net/pressobjects/?rev=1072&view=rev Author: jcmoraisjr Date: 2010-08-30 00:39:18 +0000 (Mon, 30 Aug 2010) Log Message: ----------- [Brokers] Fixed compilation issue with LCL. Modified Paths: -------------- trunk/Source/Brokers/PressXCLBroker.pas Modified: trunk/Source/Brokers/PressXCLBroker.pas =================================================================== --- trunk/Source/Brokers/PressXCLBroker.pas 2010-08-30 00:03:22 UTC (rev 1071) +++ trunk/Source/Brokers/PressXCLBroker.pas 2010-08-30 00:39:18 UTC (rev 1072) @@ -102,13 +102,13 @@ TPressXCLMenuItem = class(TMenuItem) private FNotifier: TPressNotifier; - FCommand: TPressMVPCommand; + FMVPCommand: TPressMVPCommand; procedure Notify(AEvent: TPressEvent); public constructor Create(AOwner: TComponent; ACommand: TPressMVPCommand); reintroduce; virtual; destructor Destroy; override; procedure Click; override; - property Command: TPressMVPCommand read FCommand write FCommand; + property MVPCommand: TPressMVPCommand read FMVPCommand write FMVPCommand; end; TPressXCLCommandMenu = class(TPressMVPCommandMenu) @@ -746,12 +746,12 @@ if Assigned(ACommand) then begin FNotifier := TPressNotifier.Create({$IFDEF FPC}@{$ENDIF}Notify); - FCommand := ACommand; - Caption := PressEncodeString(FCommand.Caption); - Enabled := FCommand.Enabled; - Visible := FCommand.Visible; - ShortCut := FCommand.ShortCut; - FNotifier.AddNotificationItem(FCommand, [TPressMVPCommandChangedEvent]); + FMVPCommand := ACommand; + Caption := PressEncodeString(FMVPCommand.Caption); + Enabled := FMVPCommand.Enabled; + Visible := FMVPCommand.Visible; + ShortCut := FMVPCommand.ShortCut; + FNotifier.AddNotificationItem(FMVPCommand, [TPressMVPCommandChangedEvent]); end else Caption := '-'; end; @@ -759,8 +759,8 @@ procedure TPressXCLMenuItem.Click; begin inherited; - if Assigned(FCommand) then - FCommand.Execute; + if Assigned(FMVPCommand) then + FMVPCommand.Execute; end; destructor TPressXCLMenuItem.Destroy; @@ -771,8 +771,8 @@ procedure TPressXCLMenuItem.Notify(AEvent: TPressEvent); begin - if Assigned(FCommand) then - Enabled := FCommand.Enabled; + if Assigned(FMVPCommand) then + Enabled := FMVPCommand.Enabled; end; { TPressXCLCommandMenu } This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <jcm...@us...> - 2010-08-30 00:03:28
|
Revision: 1071 http://pressobjects.svn.sourceforge.net/pressobjects/?rev=1071&view=rev Author: jcmoraisjr Date: 2010-08-30 00:03:22 +0000 (Mon, 30 Aug 2010) Log Message: ----------- [adm] ignoring bin dir Property Changed: ---------------- trunk/ Property changes on: trunk ___________________________________________________________________ Added: svn:ignore + bin This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |