Ignore:
Timestamp:
09/05/07 20:36:37 (17 years ago)
Author:
tbretz
Message:
*** empty log message ***
File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/MagicSoft/Mars/callisto.cc

    r8683 r8741  
    6161    gLog << "   --debug-env[=1]           Display untouched resources after program execution" << endl;
    6262    gLog << "   --debug-env=2             Display untouched resources after eventloop setup" << endl;
    63     gLog << "   --debug-env=3             Debug setting resources from resource file" << endl;
     63    gLog << "   --debug-env=3             Debug setting resources from resource file and command line" << endl;
    6464    gLog << "   --debug-mem               Debug memory usage" << endl << endl;
     65    gLog << "   --rc=Name:option          Set or overwrite a resource of the resource file." << endl;
     66    gLog << "                             (Note, that this option can be used multiple times." << endl;
    6567    gLog << endl;
    6668    gLog << "   -q                        Quit when job is finished" << endl;
     
    198200
    199201    //
    200     // check for the right usage of the program
     202    // check for the right usage of the program (number of arguments)
    201203    //
    202204    if (arg.GetNumArguments()!=1)
     
    207209    }
    208210
     211    //
     212    // Now we access/read the resource file. This will remove all
     213    // --rc= from the list of arguments.
     214    //
     215    MEnv env(kConfig);
     216    if (!env.IsValid())
     217    {
     218        gLog << err << "ERROR - Reading resource file " << kConfig << "." << endl;
     219        return 0xfe;
     220    }
     221
     222    // And move the resource options from the command line to the MEnv
     223    if (!env.TakeEnv(arg, kDebugEnv>2))
     224        return 0xfd;
     225
     226    //
     227    // check for the right usage of the program (number of options)
     228    //
    209229    if (arg.GetNumOptions()>0)
    210230    {
     
    339359    d->SetBit(MStatusDisplay::kExitLoopOnExit);
    340360    d->SetTitle(kSequence);
    341 
    342     MEnv env(kConfig);
    343     if (!env.IsValid())
    344     {
    345         gLog << err << "Configuration file " << kConfig << " not found." << endl;
    346         return 0xfe;
    347     }
    348361
    349362    if (kModeC/* || kUseTest*/)
Note: See TracChangeset for help on using the changeset viewer.