* Fixed compilation and cleaned the demos applications

git-svn-id: https://svn.code.sf.net/p/lazarus-ccr/svn@412 8e941d3f-bd1b-0410-a28a-d453659cc2b4
This commit is contained in:
blikblum
2008-04-10 03:06:03 +00:00
parent 4c622efc11
commit 40fa686aa4
19 changed files with 6603 additions and 3783 deletions

View File

@ -1,7 +1,7 @@
<?xml version="1.0"?>
<CONFIG>
<ProjectOptions>
<PathDelim Value="\"/>
<PathDelim Value="/"/>
<Version Value="6"/>
<General>
<Flags>
@ -9,7 +9,7 @@
</Flags>
<SessionStorage Value="InProjectDir"/>
<MainUnit Value="0"/>
<IconPath Value=".\"/>
<IconPath Value="./"/>
<TargetFileExt Value=".exe"/>
</General>
<VersionInfo>
@ -23,7 +23,7 @@
<RunParams>
<local>
<FormatVersion Value="1"/>
<LaunchingApplication PathPlusParams="\usr\X11R6\bin\xterm -T 'Lazarus Run Output' -e $(LazarusDir)\tools\runwait.sh $(TargetCmdLine)"/>
<LaunchingApplication PathPlusParams="/usr/X11R6/bin/xterm -T 'Lazarus Run Output' -e $(LazarusDir)/tools/runwait.sh $(TargetCmdLine)"/>
</local>
</RunParams>
<RequiredPackages Count="3">
@ -152,7 +152,6 @@
</ProjectOptions>
<CompilerOptions>
<Version Value="5"/>
<PathDelim Value="\"/>
<CodeGeneration>
<Generate Value="Faster"/>
</CodeGeneration>

View File

@ -7,38 +7,38 @@ object Form1: TForm1
VertScrollBar.Page = 436
ActiveControl = Button1
Caption = 'Form1'
ClientHeight = 437
ClientWidth = 612
Font.Height = -11
Font.Name = 'MS Sans Serif'
OnClose = FormClose
OnCreate = FormCreate
LCLVersion = '0.9.25'
object Label1: TLabel
Left = 204
Height = 14
Top = 351
Width = 152
Left = 129
Height = 17
Top = 348
Width = 227
Anchors = [akRight, akBottom]
Caption = 'Array data of the clicked node'
Color = clNone
ParentColor = False
end
object Label2: TLabel
Left = 362
Height = 14
Top = 335
Width = 227
Left = 249
Height = 17
Top = 332
Width = 340
Anchors = [akRight, akBottom]
Caption = 'Find and show the node by specific array index'
Color = clNone
ParentColor = False
end
object Label3: TLabel
Left = 358
Height = 14
Top = 351
Width = 246
Left = 241
Height = 17
Top = 348
Width = 363
Anchors = [akRight, akBottom]
Caption = 'Type index to get related tree node on the screen:'
Color = clNone
ParentColor = False
end
object Button1: TButton

View File

@ -116,7 +116,7 @@ type
procedure FormCreate(Sender: TObject);
procedure MyTreeBeforeCellPaint(Sender: TBaseVirtualTree;
TargetCanvas: TCanvas; Node: PVirtualNode; Column: TColumnIndex;
CellRect: TRect);
const CellRect: TRect);
procedure MyTreePaintText(Sender: TBaseVirtualTree;
const TargetCanvas: TCanvas; Node: PVirtualNode;
Column: TColumnIndex; TextType: TVSTTextType);
@ -139,22 +139,8 @@ var
implementation
uses Math;
//fpc 204 does not have comparevalue
function CompareValue ( const A, B : Integer) : Integer;
begin
result:=1;
if a=b then
result:=0
else
if a<b then
result:=-1;
end;
uses
Math;
procedure TForm1.MyTreeGetText(Sender: TBaseVirtualTree;
Node: PVirtualNode; Column: TColumnIndex; TextType: TVSTTextType;
@ -420,7 +406,7 @@ end;
procedure TForm1.MyTreeBeforeCellPaint(Sender: TBaseVirtualTree;
TargetCanvas: TCanvas; Node: PVirtualNode; Column: TColumnIndex;
CellRect: TRect);
const CellRect: TRect);
begin
// This is example how to conditionally

View File

@ -2,7 +2,7 @@
<CONFIG>
<ProjectOptions>
<PathDelim Value="/"/>
<Version Value="5"/>
<Version Value="6"/>
<General>
<Flags>
<AlwaysBuild Value="False"/>

File diff suppressed because it is too large Load Diff

View File

@ -2,15 +2,27 @@ program images;
{$mode objfpc}{$H+}
{$define DEBUG_VTV}
uses
{$IFDEF UNIX}{$IFDEF UseCThreads}
cthreads,
{$ENDIF}{$ENDIF}
Interfaces, // this includes the LCL widgetset
Forms
{ add your units here }, Unit1;
{ add your units here }, Unit1
{$ifdef DEBUG_VTV}
,ipcchannel, vtlogger
{$endif}
;
begin
{$ifdef DEBUG_VTV}
Logger.Channels.Add(TIPCChannel.Create);
Logger.Clear;
Logger.ActiveClasses := [lcHeaderOffset];
{$endif}
Application.Initialize;
Application.CreateForm(TForm1, Form1);
Application.Run;

View File

@ -2,7 +2,7 @@
<CONFIG>
<ProjectOptions>
<PathDelim Value="/"/>
<Version Value="5"/>
<Version Value="6"/>
<General>
<Flags>
<AlwaysBuild Value="False"/>

View File

@ -1,15 +1,15 @@
<?xml version="1.0"?>
<CONFIG>
<ProjectOptions>
<PathDelim Value="\"/>
<Version Value="5"/>
<PathDelim Value="/"/>
<Version Value="6"/>
<General>
<Flags>
<AlwaysBuild Value="False"/>
</Flags>
<SessionStorage Value="InProjectDir"/>
<MainUnit Value="0"/>
<IconPath Value=".\"/>
<IconPath Value="./"/>
<TargetFileExt Value=".exe"/>
</General>
<VersionInfo>
@ -23,7 +23,7 @@
<RunParams>
<local>
<FormatVersion Value="1"/>
<LaunchingApplication PathPlusParams="\usr\X11R6\bin\xterm -T 'Lazarus Run Output' -e $(LazarusDir)\tools\runwait.sh $(TargetCmdLine)"/>
<LaunchingApplication PathPlusParams="/usr/X11R6/bin/xterm -T 'Lazarus Run Output' -e $(LazarusDir)/tools/runwait.sh $(TargetCmdLine)"/>
</local>
</RunParams>
<RequiredPackages Count="3">
@ -65,7 +65,6 @@
</ProjectOptions>
<CompilerOptions>
<Version Value="5"/>
<PathDelim Value="\"/>
<CodeGeneration>
<Generate Value="Faster"/>
</CodeGeneration>

File diff suppressed because it is too large Load Diff

View File

@ -19,8 +19,8 @@ unit Main;
interface
uses
LCLIntf, Messages, SysUtils, Variants, Classes, Graphics, Controls, Forms,
Dialogs, VirtualTrees, ImgList, ExtCtrls, StdCtrls, Buttons, LResources;
LCLIntf, SysUtils, Variants, Classes, Graphics, Controls, Forms,
Dialogs, VirtualTrees, ExtCtrls, StdCtrls, Buttons, LResources;
type
TfrmMain =

View File

@ -22,8 +22,8 @@ unit VTDBExample;
interface
uses
delphicompat, LCLIntf, Messages, SysUtils, Classes, Graphics, Controls, Forms, Dialogs,
VirtualTrees, StdCtrls, ExtCtrls, sqlite3ds, DB, Menus, VTreeData, ImgList, Buttons, LResources;
delphicompat, LCLIntf, SysUtils, Classes, Graphics, Controls, Forms, Dialogs,
VirtualTrees, StdCtrls, ExtCtrls, sqlite3ds, Menus, VTreeData, Buttons, LResources;
type
@ -113,11 +113,15 @@ implementation
r : TRect;
begin
{get size of desktop}
//todo: not implemented under gtk
{$ifdef Windows}
SystemParametersInfo(SPI_GETWORKAREA, 0, @r, 0);
Height := r.Bottom-Top;
Width := r.Right-Left;
Application.ProcessMessages;
{$endif}
LoadDataset;
end;

View File

@ -93,8 +93,8 @@ interface
implementation
uses
CommCtrl;
//uses
// CommCtrl;
(*
uses
PropertiesDemo, GridDemo;

File diff suppressed because it is too large Load Diff

View File

@ -19,8 +19,8 @@ unit VTNoData;
interface
uses
delphicompat, LCLIntf, Messages, SysUtils, Variants, Classes, Graphics, Controls, Forms,
Dialogs, VirtualTrees, ImgList, ExtCtrls, StdCtrls, LResources;
delphicompat, LCLIntf, SysUtils, Variants, Classes, Graphics, Controls, Forms,
Dialogs, VirtualTrees, ExtCtrls, StdCtrls, LResources;
type
TfrmVTNoData =
@ -264,8 +264,10 @@ implementation
r : TRect;
begin
{get size of desktop}
{$ifdef Windows}
SystemParametersInfo(SPI_GETWORKAREA, 0, @r, 0);
Height := r.Bottom-Top;
{$endif}
end;
initialization

View File

@ -6,10 +6,13 @@ object frmViewCode: TfrmViewCode
HorzScrollBar.Page = 552
VertScrollBar.Page = 353
Caption = 'Quick Code Viewer'
ClientHeight = 354
ClientWidth = 553
Font.Height = -11
Font.Name = 'Tahoma'
OnActivate = FormActivate
Position = poDefaultPosOnly
LCLVersion = '0.9.25'
object SynEdit1: TSynEdit
Height = 354
Width = 553
@ -18,8 +21,6 @@ object frmViewCode: TfrmViewCode
Font.Name = 'courier'
ParentColor = False
TabOrder = 0
BookMarkOptions.OnChange = nil
Gutter.OnChange = nil
Gutter.CodeFoldingWidth = 14
Highlighter = SynPasSyn1
Keystrokes = <
@ -346,7 +347,6 @@ object frmViewCode: TfrmViewCode
Lines.Strings = (
'SynEdit1'
)
SelectedColor.OnChange = nil
end
object SynPasSyn1: TSynPasSyn
Enabled = False

View File

@ -29,9 +29,11 @@ implementation
r : TRect;
begin
{get size of desktop}
{$ifdef Windows}
SystemParametersInfo(SPI_GETWORKAREA, 0, @r, 0);
Height := r.Bottom-Top;
Width := r.Right-Left;
{$endif}
end;
initialization

View File

@ -1,15 +1,15 @@
<?xml version="1.0"?>
<CONFIG>
<ProjectOptions>
<PathDelim Value="\"/>
<Version Value="5"/>
<PathDelim Value="/"/>
<Version Value="6"/>
<General>
<Flags>
<AlwaysBuild Value="False"/>
</Flags>
<SessionStorage Value="InProjectDir"/>
<MainUnit Value="0"/>
<IconPath Value=".\"/>
<IconPath Value="./"/>
<TargetFileExt Value=".exe"/>
</General>
<VersionInfo>
@ -23,7 +23,7 @@
<RunParams>
<local>
<FormatVersion Value="1"/>
<LaunchingApplication PathPlusParams="\usr\X11R6\bin\xterm -T 'Lazarus Run Output' -e $(LazarusDir)\tools\runwait.sh $(TargetCmdLine)"/>
<LaunchingApplication PathPlusParams="/usr/X11R6/bin/xterm -T 'Lazarus Run Output' -e $(LazarusDir)/tools/runwait.sh $(TargetCmdLine)"/>
</local>
</RunParams>
<RequiredPackages Count="4">
@ -109,7 +109,6 @@
</ProjectOptions>
<CompilerOptions>
<Version Value="5"/>
<PathDelim Value="\"/>
<CodeGeneration>
<Generate Value="Faster"/>
</CodeGeneration>

View File

@ -8,12 +8,18 @@ uses
{$ENDIF}{$ENDIF}
Interfaces, // this includes the LCL widgetset
Forms
{ add your units here }, Main,vtlogger,ipcchannel, lclextensions_package;
{ add your units here }, Main
{$ifdef DEBUG_VTV}
,vtlogger, ipcchannel
{$endif}
;
begin
{$ifdef DEBUG_VTV}
Logger.Channels.Add(TIPCChannel.Create);
Logger.Clear;
Logger.ActiveClasses:=[lcScroll,lcWarning];
Logger.ActiveClasses := [lcScroll, lcWarning];
{$endif}
Application.Initialize;
Application.CreateForm(TfrmMain, frmMain);
Application.Run;