Changeset 338 for tools


Ignore:
Timestamp:
Feb 27, 2010, 10:48:45 AM (14 years ago)
Author:
george
Message:
  • Přidáno: Volba -d pro zobrazení dat DBC souboru.
Location:
tools/dbc_export
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • tools/dbc_export/DBCExport.lpi

    r337 r338  
    3535        <IsPartOfProject Value="True"/>
    3636        <UnitName Value="DBCExport"/>
    37         <CursorPos X="16" Y="68"/>
    38         <TopLine Value="98"/>
     37        <CursorPos X="3" Y="107"/>
     38        <TopLine Value="105"/>
    3939        <EditorIndex Value="0"/>
    40         <UsageCount Value="30"/>
     40        <UsageCount Value="31"/>
    4141        <Loaded Value="True"/>
    4242        <SyntaxHighlighter Value="Delphi"/>
     
    117117        <TopLine Value="71"/>
    118118        <EditorIndex Value="4"/>
    119         <UsageCount Value="21"/>
     119        <UsageCount Value="22"/>
    120120        <Loaded Value="True"/>
    121121        <SyntaxHighlighter Value="Delphi"/>
     
    128128        <TopLine Value="60"/>
    129129        <EditorIndex Value="2"/>
    130         <UsageCount Value="21"/>
     130        <UsageCount Value="22"/>
    131131        <Loaded Value="True"/>
    132132        <SyntaxHighlighter Value="Delphi"/>
     
    138138        <TopLine Value="1"/>
    139139        <EditorIndex Value="3"/>
    140         <UsageCount Value="21"/>
     140        <UsageCount Value="22"/>
    141141        <Loaded Value="True"/>
    142142        <SyntaxHighlighter Value="None"/>
  • tools/dbc_export/DBCExport.pas

    r337 r338  
    2222    NewDBCFileName: string;
    2323    ColumnTypeDefinition: string;
     24    DisplayData: Boolean;
    2425    constructor Create(TheOwner: TComponent); override;
    2526    destructor Destroy; override;
     
    5051  if HasOption('c', 'coltypedef') then begin
    5152    ColumnTypeDefinition := GetOptionValue('c', 'coltypedef');
     53  end;
     54  if HasOption('d', 'display') then begin
     55    DisplayData := True;
    5256  end;
    5357
     
    9599  WriteLn('  -f --file        Source DBC file name');
    96100  WriteLn('  -n --newfile     New created DBC file name');
    97   WriteLn('  -c --coltypedef  DBC column type definition string');
    98   WriteLn('                     u - uint32, s - string');
     101  WriteLn('  -c --coltypedef  DBC column type definition string (u - uint32, s - string)');
     102  WriteLn('  -d --display     Display DBC data');
    99103end;
    100104
    101105procedure TDBCExport.ShowDBC;
    102106var
    103   //X, Y: Integer;
    104   //Text: string;
     107  X, Y: Integer;
     108  Text: string;
    105109  I: Integer;
    106110begin
     
    115119          LoadColumnStrings(I - 1);
    116120
    117       (*for Y := 0 to Length(Cells) - 1 do begin
     121      // Display DBC data
     122      if DisplayData then
     123      for Y := 0 to Length(Cells) - 1 do begin
    118124        Text := '';
    119125        for X := 0 to Length(Cells[Y]) - 1 do
     
    122128        WriteLn(Text);
    123129      end;
    124       *)
     130
    125131      WriteLn('Save');
    126132      SaveToFile(NewDBCFileName);
Note: See TracChangeset for help on using the changeset viewer.