]> Creatis software - bbtk.git/blobdiff - kernel/appli/bbi/bbi.cxx
*** empty log message ***
[bbtk.git] / kernel / appli / bbi / bbi.cxx
index 86952f5632ec0b33e23f72010eca28c04f2f500c..16cbb8f0b45565addc4cc3ed00180051f7e09380 100644 (file)
@@ -151,7 +151,7 @@ bool wxBBIApp::OnCmdLineParsed(wxCmdLineParser& parser)
 // main frame
 bool wxBBIApp::OnInit( )
 {
-      std::cout << "OnInit"<<std::endl;
+  //      std::cout << "OnInit"<<std::endl;
   wxApp::OnInit();
 #ifdef __WXGTK__
   //See http://www.wxwindows.org/faqgtk.htm#locale
@@ -194,7 +194,7 @@ bool wxBBIApp::OnInit( )
   if (help_on_script) 
     {
       std::string package; 
-      I->GetInterpreter()->GetExecuter()->GetFactory()->HelpBlackBox("workspace",package,false);
+      I->GetInterpreter()->GetExecuter()->GetFactory()->PrintHelpDescriptor("workspace",package,false);
     }
 
   /*
@@ -202,7 +202,7 @@ bool wxBBIApp::OnInit( )
   std::cout << "con="<<console<<std::endl;
   std::cout << "iws="<<bbtk::Wx::IsSomeWindowShown()<<std::endl;
   */
-  if (!(show_on_error || cmd.console || bbtk::Wx::IsSomeWindowShown() ))
+  if (!(show_on_error || cmd.console || bbtk::Wx::IsSomeWindowAlive() ))
     {
       I->Close();
       //      std::cout << "I->Close"<<std::endl;
@@ -212,7 +212,7 @@ bool wxBBIApp::OnInit( )
       //      std::cout << "!I->Close"<<std::endl;
     }
        
-       std::cout << "EO OnInit"<<std::endl;
+  //   std::cout << "EO OnInit"<<std::endl;
 
   return true;
 
@@ -225,6 +225,7 @@ bool wxBBIApp::OnInit( )
 // WINDOWS
 //==========================================================================
 IMPLEMENT_APP(wxBBIApp);
+
 //  How to have a Console and wxWidgets
 //  http://www.wxwidgets.org/wiki/index.php/MSVC_Setup_Guide
 //   In Visual C++ 6 (7 should be similar), to create an application that is both a console application 
@@ -232,7 +233,7 @@ IMPLEMENT_APP(wxBBIApp);
 //  you need to use the linker option "/subsystem:console" and the following code:
 int main(int argc, char* argv[])
 {
-  return WinMain(::GetModuleHandle(NULL), NULL, ::GetCommandLine(), SW_SHOWNORMAL);
+    return WinMain(::GetModuleHandle(NULL), NULL, ::GetCommandLine(), SW_SHOWNORMAL);
 }
 
 #else 
@@ -280,9 +281,9 @@ int main(int argc, char* argv[])
        {
          I->SetNoExecMode(false);
          std::string package; 
-         I->GetExecuter()->GetFactory()->HelpBlackBox("workspace",
-                                                      package,
-                                                      false);
+         I->GetExecuter()->GetFactory()->PrintHelpDescriptor("workspace",
+                                                             package,
+                                                             false);
        }
       if (cmdline.input_file.size()==0)
        I->CommandLineInterpreter();
@@ -313,10 +314,10 @@ int main(int argc, char* argv[])
 //==========================================================================
 
 #include "bbtkInterpreter.h"
+//#include "bbtkWx.h"
 
 int main(int argc, char* argv[])
 {  
-
   if (argc>2) 
     {
       std::cout << "usage : "<<argv[0]<<" [filename]"<<std::endl;
@@ -339,7 +340,7 @@ int main(int argc, char* argv[])
       I->InterpretFile(f);
     }
   
-  bbtk::Wx::LoopUntilAllWindowsClose(); 
+  //  bbtk::Wx::LoopUntilAllWindowsClose(); 
      
   return 0;