From: caballero Date: Wed, 29 Apr 2009 12:23:57 +0000 (+0000) Subject: Added command line interaction with the synchronization option. X-Git-Tag: EED.02Oct2009~82 X-Git-Url: https://git.creatis.insa-lyon.fr/pubgit/?a=commitdiff_plain;h=9f8b288b5f8f56bc58fd01ddcb687833eb5ffa5b;p=creaImageIO.git Added command line interaction with the synchronization option. --- diff --git a/appli/TestWxGimmickReaderDialog/main.cxx b/appli/TestWxGimmickReaderDialog/main.cxx index f2885d1..94838a8 100644 --- a/appli/TestWxGimmickReaderDialog/main.cxx +++ b/appli/TestWxGimmickReaderDialog/main.cxx @@ -38,7 +38,7 @@ bool myApp::OnInit( ) -1, _T("Select image(s) - Gimmick! (c) CREATIS-LRMN 2008"), wxDefaultPosition, - wxSize(600,750), + wxSize(635,750), min_dim, max_dim, output_dim, diff --git a/appli/gimmick/main.cxx b/appli/gimmick/main.cxx index bee8ff1..0a44cf0 100644 --- a/appli/gimmick/main.cxx +++ b/appli/gimmick/main.cxx @@ -1,5 +1,5 @@ #include - + using namespace boost; namespace po = boost::program_options; @@ -28,15 +28,17 @@ int main(int ac, char* av[]) ("file,f",po::value< vector >(),"Adds the file to the local database") ("dir,d",po::value< vector >(),"Adds the directory to the local database") ("sync,s","Synchronizes the local database with the files") - ("recurse,r","Recurse into sub-directories (default=off)"); + ("recurse,r","Recurse into sub-directories (default=off)") + ("repair,R","Repair the database (on synchronization) (default=off)") + ("check,c","Check for attribute differences (on synchronization) (default=off)"); + //Describes third group of options po::options_description option("OPTIONS"); option.add_options() ("verbose,v",po::value(&verb),"Verbosity level (default=`1')") ("debug,D",po::value(&deb),"Debug messages level (default=`0')"); - - + //Adds the groups into a big one po::options_description cmdline_options; cmdline_options.add(generic).add(command).add(option); @@ -86,10 +88,22 @@ int main(int ac, char* av[]) } if (vm.count("dir")) { std::vector dirs=vm["dir"].as< vector >(); - g.AddDir(handler,dirs.front(), vm.count("recurse")); + bool recu=false; + std::stringstream out; + out<