IDE: clean up

git-svn-id: trunk@40694 -
This commit is contained in:
mattias 2013-04-02 10:10:54 +00:00
parent 214609634e
commit a85c98d0a8
14 changed files with 39 additions and 43 deletions

View File

@ -67,7 +67,7 @@ type
procedure LoadLFM;
function RemoveAll: TModalResult;
procedure FindNiceNodeBounds(LFMNode: TLFMTreeNode;
var StartPos, EndPos: integer);
out StartPos, EndPos: integer);
function FindListBoxError: TLFMError;
procedure WriteLFMErrors;
function FindAndFixMissingComponentClasses: TModalResult;
@ -108,7 +108,7 @@ type
RemoveAllButton: TBitBtn;
SynLFMSyn1: TSynLFMSyn;
procedure ErrorsListBoxClick(Sender: TObject);
procedure FormClose(Sender: TObject; var CloseAction: TCloseAction);
procedure FormClose(Sender: TObject; var {%H-}CloseAction: TCloseAction);
procedure LFMSynEditSpecialLineMarkup(Sender: TObject; Line: integer;
var Special: boolean; AMarkup: TSynSelectedColor);
procedure RemoveAllButtonClick(Sender: TObject);
@ -594,7 +594,7 @@ begin
end;
procedure TLFMChecker.FindNiceNodeBounds(LFMNode: TLFMTreeNode;
var StartPos, EndPos: integer);
out StartPos, EndPos: integer);
var
Src: String;
begin

View File

@ -255,9 +255,6 @@ implementation
{$R *.lfm}
type
TWinControlClass = class of TWinControl;
function ShowCodeToolsDefinesEditor(ACodeToolBoss: TCodeToolManager;
Options: TCodeToolsOptions; Macros: TTransferMacroList): TModalResult;
var CodeToolsDefinesEditor: TCodeToolsDefinesEditor;

View File

@ -35,8 +35,7 @@ uses
StdCtrls, Buttons, ComCtrls, ExtCtrls, FileUtil, AVGLvlTree,
SynEdit, DefineTemplates, ExprEval,
IDEWindowIntf, IDEHelpIntf,
EditorOptions, LazarusIDEStrConsts, InputHistory, CodeToolsOptions,
IDEContextHelpEdit, IDEProcs;
EditorOptions, LazarusIDEStrConsts, InputHistory, CodeToolsOptions, IDEProcs;
type
TCodeToolsDefinesNodeValues = class
@ -70,15 +69,15 @@ type
ValueGroupbox: TGroupBox;
ValuesListview: TListView;
procedure CodeToolsDefinesDialogCLOSE(Sender: TObject;
var CloseAction: TCloseAction);
var {%H-}CloseAction: TCloseAction);
procedure CodeToolsDefinesDialogCREATE(Sender: TObject);
procedure DirectoryBrowseButtonCLICK(Sender: TObject);
procedure DirectoryComboboxCHANGE(Sender: TObject);
procedure FormDestroy(Sender: TObject);
procedure HelpButtonClick(Sender: TObject);
procedure ParsedTemplatesTreeViewSelectionChanged(Sender: TObject);
procedure ValuesListviewSELECTITEM(Sender: TObject; Item: TListItem;
Selected: Boolean);
procedure ValuesListviewSELECTITEM(Sender: TObject; {%H-}Item: TListItem;
{%H-}Selected: Boolean);
private
FDefineTree: TDefineTree;
FNodeValues: TAvgLvlTree;
@ -90,7 +89,7 @@ type
procedure ClearValues;
procedure FillTemplateTree;
procedure SetComboBox(AComboBox: TComboBox; const NewText: string);
procedure DefineTreeCalculate(Tree: TDefineTree; Node: TDefineTemplate;
procedure DefineTreeCalculate(DefineTree: TDefineTree; Node: TDefineTemplate;
ValueParsed: boolean; const ParsedValue: string;
ExpressionCalculated: boolean; const ExpressionResult: string;
Execute: boolean);
@ -414,7 +413,7 @@ begin
//writeln('TCodeToolsDefinesDialog.SetComboBox Text=',AComboBox.Text,' NewText=',NewText);
end;
procedure TCodeToolsDefinesDialog.DefineTreeCalculate(Tree: TDefineTree;
procedure TCodeToolsDefinesDialog.DefineTreeCalculate(DefineTree: TDefineTree;
Node: TDefineTemplate; ValueParsed: boolean; const ParsedValue: string;
ExpressionCalculated: boolean; const ExpressionResult: string;
Execute: boolean);

View File

@ -85,8 +85,8 @@ type
ErrorType: TJITFormError; var Action: TModalResult); virtual;
procedure JITListBeforeCreate(Sender: TObject; Instance: TPersistent);
procedure JITListException(Sender: TObject; E: Exception;
var Action: TModalResult);
procedure JITListPropertyNotFound(Sender: TObject; Reader: TReader;
var {%H-}Action: TModalResult);
procedure JITListPropertyNotFound(Sender: TObject; {%H-}Reader: TReader;
Instance: TPersistent; var PropName: string; IsPath: boolean;
var Handled, Skip: Boolean);
procedure JITListFindAncestors(Sender: TObject; AClass: TClass;
@ -152,7 +152,7 @@ type
): TComponent;
function FindJITComponentByClass(AComponentClass: TComponentClass
): TComponent;
procedure WriteMethodPropertyEvent(Writer: TWriter; Instance: TPersistent;
procedure WriteMethodPropertyEvent(Writer: TWriter; {%H-}Instance: TPersistent;
PropInfo: PPropInfo; const MethodValue, DefMethodValue: TMethod;
var Handled: boolean);
function SaveUnitComponentToBinStream(AnUnitInfo: TUnitInfo;
@ -220,8 +220,8 @@ type
ComponentClass: TComponentClass; Root: TComponent;
ParentControl: TWinControl; NewComponents: TFPList); override;
function FixupReferences(AComponent: TComponent): TModalResult;
procedure WriterFindAncestor(Writer: TWriter; Component: TComponent;
const Name: string;
procedure WriterFindAncestor({%H-}Writer: TWriter; Component: TComponent;
const {%H-}Name: string;
var Ancestor, RootAncestor: TComponent);
procedure SetComponentNameAndClass(AComponent: TComponent;
const NewName, NewClassName: shortstring);
@ -271,11 +271,11 @@ type
public
destructor Destroy; override;
procedure DefineProperty(const Name: string;
ReadData: TReaderProc; WriteData: TWriterProc;
HasData: Boolean); override;
{%H-}ReadData: TReaderProc; {%H-}WriteData: TWriterProc;
{%H-}HasData: Boolean); override;
procedure DefineBinaryProperty(const Name: string;
ReadData, WriteData: TStreamProc;
HasData: Boolean); override;
{%H-}ReadData, {%H-}WriteData: TStreamProc;
{%H-}HasData: Boolean); override;
property DefinePropertyNames: TStrings read FDefinePropertyNames;
end;

View File

@ -1245,7 +1245,7 @@ type
function Add(AName: String): TEditorUserDefinedWords;
function IndexOf(AName: String): Integer;
function IndexOf(AList: TEditorUserDefinedWords): Integer;
procedure Remove(AName: String; FreeList: Boolean = True);
procedure Remove(AName: String; {%H-}FreeList: Boolean = True);
procedure Remove(AList: TEditorUserDefinedWords; FreeList: Boolean = True);
procedure Delete(AIndex: Integer);
function Count: Integer;

View File

@ -165,7 +165,7 @@ type
URLLabel: TLabel;
AllListBox: TListBox;
procedure AddButtonClick(Sender: TObject);
procedure AllListBoxSelectionChange(Sender: TObject; User: boolean);
procedure AllListBoxSelectionChange(Sender: TObject; {%H-}User: boolean);
procedure ButtonPanel1Click(Sender: TObject);
procedure ButtonPanel1OKButtonClick(Sender: TObject);
procedure DeleteButtonClick(Sender: TObject);

View File

@ -37,7 +37,7 @@ unit IDEDefs;
interface
uses
Classes, SysUtils, Menus, MacroIntf;
Classes, SysUtils, Menus;
type
TIDEFileStateFlag = (

View File

@ -692,7 +692,7 @@ begin
end;
end;
function ValueOfKey(const aLine, aKey: string; var aValue: string): boolean;
function ValueOfKey(const aLine, aKey: string; out aValue: string): boolean;
// If aKey is found in aLine, separate a quoted number following "aKey =",
// save it to aValue and return True. Return False if aKey is not found.
// Example line: version_nr = '2';
@ -700,6 +700,7 @@ var
i,j: Integer;
begin
Result:=False;
aValue:='';
i:=Pos(aKey, aLine);
if i>0 then begin // aKey found
i:=PosEx('=', aLine, i+Length(aKey));

View File

@ -33,7 +33,7 @@ uses
Classes, SysUtils,
LCLMemManager,
Forms,
UnitResources, SrcEditorIntf, LazFileCache;
UnitResources, LazFileCache;
type
@ -43,7 +43,7 @@ type
public
class function FindResourceDirective(Source: TObject): boolean; override;
class function ResourceDirectiveFilename: string; override;
class function GetUnitResourceFilename(AUnitFilename: string; Loading: boolean): string; override;
class function GetUnitResourceFilename(AUnitFilename: string; {%H-}Loading: boolean): string; override;
class procedure TextStreamToBinStream(ATxtStream, ABinStream: TExtMemoryStream); override;
class procedure BinStreamToTextStream(ABinStream, ATextStream: TExtMemoryStream); override;
class function GetClassNameFromStream(s: TStream; out IsInherited: Boolean): shortstring; override;

View File

@ -59,18 +59,17 @@ uses
{$IFDEF IDE_MEM_CHECK}
MemCheck,
{$ENDIF}
Classes, LCLType, LCLIntf, StdCtrls, Buttons, Menus, ComCtrls, SysUtils,
Classes, LCLType, LCLIntf, Buttons, Menus, SysUtils,
typinfo, Controls, Graphics, ExtCtrls, Dialogs, FileUtil, Forms,
CodeToolManager, CodeCache, AVL_Tree, SynEditKeyCmds,
// IDE
PropEdits, ObjectInspector, MenuIntf, SrcEditorIntf, ProjectIntf, MacroIntf,
PropEdits, ObjectInspector, MenuIntf, SrcEditorIntf, ProjectIntf,
CompOptsIntf, LazIDEIntf,
LazConf, LazarusIDEStrConsts,
ProjectDefs, Project, PublishModule, BuildLazDialog, Compiler,
ComponentReg,
TransferMacros, OutputFilter, IDEDefs, MsgView, ProgressDlg,
ProjectDefs, Project, PublishModule, BuildLazDialog,
TransferMacros, IDEDefs, ProgressDlg,
EnvironmentOpts, EditorOptions, CompilerOptions, KeyMapping, IDEProcs,
IDEOptionDefs, CodeToolsDefines;
IDEOptionDefs;
type
// The IDE is at anytime in a specific state:
@ -272,7 +271,7 @@ type
FInheritedUnits: string;
public
function GetResourceSource(const ResourceName: string): string; override;
function GetInterfaceSource(const Filename, SourceName,
function GetInterfaceSource(const {%H-}Filename, {%H-}SourceName,
ResourceName: string): string; override;
property InheritedUnits: string read FInheritedUnits write FInheritedUnits;
end;

View File

@ -41,7 +41,7 @@ interface
uses
Classes, SysUtils, AVL_Tree,
LCLProc, LCLType, ClipBrd, Controls, Dialogs, FileUtil, Forms,
Menus, ExtCtrls, StdCtrls, ComCtrls, Graphics,
Menus, ExtCtrls, ComCtrls, Graphics,
CodeToolManager,
IDEImagesIntf, IDEExternToolIntf, IDECommands, MenuIntf, IDEMsgIntf,
SrcEditorIntf, LazIDEIntf,
@ -106,7 +106,7 @@ type
Shift: TShiftState);
procedure MessageViewDrawItem(Sender: TCustomTreeView; Node: TTreeNode;
State: TCustomDrawState; Stage: TCustomDrawStage;
var PaintImages, DefaultDraw: Boolean);
var {%H-}PaintImages, {%H-}DefaultDraw: Boolean);
procedure SaveAllToFileMenuItemClick(Sender: TObject);
procedure OnQuickFixClick(Sender: TObject);
private

View File

@ -45,7 +45,7 @@ type
procedure FormDestroy(Sender: TObject);
private
public
procedure ApplicationIdle(Sender: TObject; var Done: Boolean);
procedure ApplicationIdle(Sender: TObject; var {%H-}Done: Boolean);
end;
var
@ -67,7 +67,7 @@ type
StartTime: TDateTime;
StartTimeValid: boolean;
constructor Create;
procedure ApplicationIdle(Sender: TObject; var Done: Boolean);
procedure ApplicationIdle(Sender: TObject; var {%H-}Done: Boolean);
end;
{ TProgressWait }

View File

@ -35,8 +35,8 @@ interface
uses
Classes, SysUtils, FileUtil, Laz2_XMLCfg, lazutf8classes, Process, LCLProc,
Controls, Forms, CodeToolManager, CodeCache, FileProcs, LazConf, LResources,
resource, DialogProcs, groupiconresource, ProjectIntf, ProjectResourcesIntf;
Controls, Forms, CodeToolManager, FileProcs, LazConf, LResources,
resource, groupiconresource, ProjectIntf, ProjectResourcesIntf;
type
TIconData = array of byte;

View File

@ -180,9 +180,9 @@ type
FRemoveTermCmd: TSynEditorCommand;
FToggleTermCmd: TSynEditorCommand;
procedure ProcessSynCommand(Sender: TObject; AfterProcessing: boolean;
procedure ProcessSynCommand(Sender: TObject; {%H-}AfterProcessing: boolean;
var Handled: boolean; var Command: TSynEditorCommand;
var AChar: TUTF8Char; Data: pointer; HandlerData: pointer);
var {%H-}AChar: TUTF8Char; {%H-}Data: pointer; {%H-}HandlerData: pointer);
protected
function CreateTermsList: TSynSearchTermDict; override;
public