Ignore:
Timestamp:
Apr 26, 2007, 1:55:46 PM (18 years ago)
Author:
RBRi
Message:

CmdLine parameter access fixed

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/NewView/CmdLineParameterUnit.pas

    r109 r119  
    5555
    5656       FUNCTION handleSwitchWithValue(const aSwitchString : String; const aSwitch : String; var aValue : String) : Boolean;
    57        PROCEDURE parseSwitch(aSwitchString : String);
     57       PROCEDURE parseSwitch(const aSwitchString : String);
    5858       PROPERTY getParsedFileNames : AnsiString read parsedFileNames;
    5959       PROPERTY getParsedSearchText : AnsiString read parsedSearchText;
     
    8383  // returns a string containing the whole
    8484  // command line parametes
    85   // this as function has a problem with returning an AnsiString
    86   // ! you have to provide an AnsiString (normaly an empty one)
    87   PROCEDURE nativeOS2GetCmdLineParameter(aResult : AnsiString);
     85  FUNCTION nativeOS2GetCmdLineParameter : AnsiString;
    8886
    8987
     
    523521
    524522
    525   Procedure TCmdLineParameters.parseSwitch(aSwitchString : String);
     523  Procedure TCmdLineParameters.parseSwitch(const aSwitchString : String);
    526524  var
    527525    tmpCurrentChar : char;
     
    620618
    621619
    622   PROCEDURE nativeOS2GetCmdLineParameter(aResult : AnsiString);
     620  FUNCTION nativeOS2GetCmdLineParameter : AnsiString;
    623621  VAR
    624622    tmpPtib : PTIB;       // thread information block
     
    638636    tmpParams := tmpCmd + StrLen(tmpCmd) + 1;
    639637
    640     AnsiSetString(aResult, tmpParams, StrLen(tmpParams));
     638    result := '';
     639    AnsiSetString(result, tmpParams, StrLen(tmpParams));
    641640  END;
    642641END.
Note: See TracChangeset for help on using the changeset viewer.