diff options
author | Graeme Geldenhuys <graeme@mastermaths.co.za> | 2010-08-11 14:33:50 +0200 |
---|---|---|
committer | Graeme Geldenhuys <graeme@mastermaths.co.za> | 2010-08-11 14:33:50 +0200 |
commit | 52d2902b355616876bafbbfebe95bbd7cd6b545e (patch) | |
tree | 84de7a46ca0bf3412c0562b74e3b7bd631fb364d | |
parent | 93602fbd55fe9075a988b983b56ed4e8927d422d (diff) | |
download | fpGUI-52d2902b355616876bafbbfebe95bbd7cd6b545e.tar.xz |
docview: Replaced the fake TImageList with the actual TfpgImageList
-rw-r--r-- | docview/src/HelpFile.pas | 13 | ||||
-rw-r--r-- | docview/src/nvNullObjects.pas | 18 |
2 files changed, 5 insertions, 26 deletions
diff --git a/docview/src/HelpFile.pas b/docview/src/HelpFile.pas index acba5b14..ac5e68e7 100644 --- a/docview/src/HelpFile.pas +++ b/docview/src/HelpFile.pas @@ -13,6 +13,7 @@ Interface uses Classes ,SysUtils + ,fpg_imagelist ,IPFFileFormatUnit ,HelpTopic // ,HelpBitmap @@ -140,8 +141,7 @@ type property ReferencedFiles: TStringList read _ReferencedFiles; - procedure GetImages( ImageOffsets: TList; - Images: TImageList ); + procedure GetImages( ImageOffsets: TList; Images: TfpgImageList ); function GetImage( ImageOffset: longint ): THelpBitmap; @@ -1057,8 +1057,7 @@ begin end; end; -procedure THelpFile.GetImages( ImageOffsets: TList; - Images: TImageList ); +procedure THelpFile.GetImages( ImageOffsets: TList; Images: TfpgImageList ); var ListIndex: longint; ImageOffset: longint; @@ -1081,13 +1080,11 @@ begin + e.Message );} begin Bitmap := THelpBitmap.Create; - Bitmap.LoadFromResourceName( 'MissingBitmap' ); + Bitmap.LoadFromResourceName( 'MissingBitmap' ); // TODO: Add image resource to DocView end; end; - Images.Add( Bitmap, nil ); - Bitmap.Destroy; - + Images.AddImage(Bitmap); end; end; diff --git a/docview/src/nvNullObjects.pas b/docview/src/nvNullObjects.pas index ee849b12..a97841d0 100644 --- a/docview/src/nvNullObjects.pas +++ b/docview/src/nvNullObjects.pas @@ -10,16 +10,6 @@ uses type EHelpBitmapException = class(Exception); - // forward declaration - THelpBitmap = class; - - - TImageList = class(TObjectList) - public - procedure Add(ABitmap: THelpBitmap; AParam2: TObject); - end; - - THelpBitmap = class(TObject) public constructor CreateFromHelpFile( FileHandle: TFileStream; Offset: longint ); @@ -32,16 +22,8 @@ implementation -{ TImageList } - -procedure TImageList.Add(ABitmap: THelpBitmap; AParam2: TObject); -begin - // -end; - { THelpBitmap } - constructor THelpBitmap.CreateFromHelpFile(FileHandle: TFileStream; Offset: longint); begin inherited Create; |