+
+
IF(WIN32)
SET (EXECUTABLE_OUTPUT_REL_PATH "")
SET (LIBRARY_OUTPUT_REL_PATH "")
-
#-----------------------------------------------------------------------------
# The var BBTK_BIN_PATH
# gives the system-dependent path to output binaries
ELSE(WIN32)
SET(BBTK_LIB_PATH lib)
# For Xcode : have to test the cmake generator !
-# IF (APPLE)
-# SET(BBTK_BIN_PATH ${EXECUTABLE_OUTPUT_PATH}/Debug)
-# ELSE(APPLE)
+ IF ( CMAKE_GENERATOR STREQUAL Xcode)
+ SET(BBTK_BIN_PATH ${EXECUTABLE_OUTPUT_PATH}/Debug)
+ ELSE(CMAKE_GENERATOR STREQUAL Xcode)
SET(BBTK_BIN_PATH ${EXECUTABLE_OUTPUT_PATH})
-# ENDIF(APPLE)
+ ENDIF(CMAKE_GENERATOR STREQUAL Xcode)
SET(BBTK_BBI ${BBTK_BIN_PATH}/bbi)
SET(BBTK_BBS2CPP ${BBTK_BIN_PATH}/bbs2cpp)
SET(BBTK_BBC ${BBTK_BIN_PATH}/bbc)
Program: bbtk
Module: $RCSfile: bbtkBlackBox.cxx,v $
Language: C++
- Date: $Date: 2009/02/27 11:20:25 $
- Version: $Revision: 1.39 $
+ Date: $Date: 2009/03/23 13:06:41 $
+ Version: $Revision: 1.40 $
=========================================================================*/
/* ---------------------------------------------------------------------
static std::set<BlackBox::WeakPointer> bbmgExecutionList;
//=========================================================================
+
BlackBox::Deleter::Deleter()
{
}
bool wasExecuting = bbGlobalGetSomeBoxExecuting();
bbGlobalSetSomeBoxExecuting(true);
+ this->bbCreateWidget();
+
// Updates its inputs
IOStatus s = bbUpdateInputs();
if ( (s != UPTODATE) ||
bbBoxProcessModeIsAlways() )
{
- // Displays the window (WxBlackbox)
- // bbShowWindow(caller);
+ // Displays the window (WxBlackbox)
+ // bbShowWindow(caller);
- // Actual processing (virtual)
- this->bbProcess();
+ // Actual processing (virtual)
+ this->bbProcess();
- // Update the I/O statuses
- bbComputePostProcessStatus();
+ // Update the I/O statuses
+ bbComputePostProcessStatus();
}
else
{
<<std::endl);
}
+ this->bbShowWidget();
+
+
bbtkDebugMessage("process",3,
"<= BlackBox::bbRecursiveExecute() ["
<<bbGetFullName()<<"]"<<std::endl);
Program: bbtk
Module: $RCSfile: bbtkBlackBox.h,v $
Language: C++
- Date: $Date: 2008/12/11 09:50:35 $
- Version: $Revision: 1.21 $
+ Date: $Date: 2009/03/23 13:06:41 $
+ Version: $Revision: 1.22 $
=========================================================================*/
/* ---------------------------------------------------------------------
IOStatus bbUpdateInputs();
//==================================================================
+
+ //==================================================================
+ /// Actual CreateWidget method (vitual)
+ /// Overloaded in AtomicBlacBox and descendants
+ virtual void bbCreateWidget()
+ {
+ // bbtkError("BlackBox::bbCreateWidget called : how can this happen ?");
+ }
+ //==================================================================
+
+ //==================================================================
+ /// Actual ShowWidget method (vitual)
+ /// Overloaded in AtomicBlacBox and descendants
+ virtual void bbShowWidget()
+ {
+ // bbtkError("BlackBox::bbShowWidget called : how can this happen ?");
+ }
+ //==================================================================
+
+
//==================================================================
/// Actual processing method (vitual)
/// Overloaded in AtomicBlacBox and descendants
/// 2) Releases the box descriptor
struct BBTK_EXPORT Deleter : public Object::Deleter
{
- Deleter();
+ Deleter();
void Delete(Object* p);
};
//==================================================================
Program: bbtk
Module: $RCSfile: bbtkConfigurationFile.cxx,v $
Language: C++
- Date: $Date: 2009/01/28 13:20:32 $
- Version: $Revision: 1.28 $
+ Date: $Date: 2009/03/23 13:06:41 $
+ Version: $Revision: 1.29 $
=========================================================================*/
/* ---------------------------------------------------------------------
// ==> Set system paths
mBin_path = Utilities::GetExecutablePath();
-
+
+
+
+
+/* EED 23 Mars 2009
#ifdef MACOSX
mInstall_path = mBin_path + "/../../../..";
#else
mInstall_path = mBin_path + "/..";
#endif
-
-
+*/
+#ifdef MACOSX
+ mBin_path = mBin_path + "/../../..";
+#endif
+ mInstall_path = mBin_path + "/..";
+
+
+
// The relative path to the doc folder (=BBTK_DOC_REL_PATH)
// mDoc_rel_path = BBTK_STRINGIFY_SYMBOL(BBTK_DOC_REL_PATH);
// The path to the doc folder (=mInstall_path+"/"+mDoc_rel_path)
Program: bbtk
Module: $RCSfile: bbtkWxBlackBox.cxx,v $
Language: C++
- Date: $Date: 2008/12/12 12:56:28 $
- Version: $Revision: 1.36 $
+ Date: $Date: 2009/03/23 13:06:41 $
+ Version: $Revision: 1.37 $
=========================================================================*/
/* ---------------------------------------------------------------------
bbtkDebugMessage("wx",5,"WxBlackBoxDialog::bbShow() ["
<<bbGetBlackBox()->bbGetFullName()<<"]"<<std::endl);
WxBlackBoxWindow::bbShow();
+ Show(false);
SetReturnCode( wxDialog::ShowModal() );
bbClose();
}
}
//=========================================================================
+
+ //=========================================================================
+ void WxBlackBox::bbCreateWidget()
+ {
+ // If output widget not connected : have to create and show the window
+ if ( (*bbGetOutputConnectorMap().find("Widget")).second->GetConnectionVector().size() == 0 )
+ {
+ Window* show = 0;
+ // If the window already exists : no need creating it
+ if (bbGetWindow()!=0)
+ {
+ bbtkDebugMessage("wx",2,
+ "-> Window already exists"
+ <<std::endl);
+ show = bbGetWindow();
+ } // bbGetWindow
+ // Else create window
+ else
+ {
+ bbtkDebugMessage("wx",2,
+ "-> Creating the window"
+ <<std::endl);
+
+ // Input WinDialog set to true : creating a Dialog
+ if (bbGetInputWinDialog())
+ {
+ bbtkDebugMessage("wx",2,
+ " Input WinDialog set to true : creating a Dialog"
+ <<std::endl);
+ show = (Window*) new WxBlackBoxDialog( GetThisPointer<WxBlackBox>(),
+ Wx::GetTopWindow(),
+ std2wx( bbGetInputWinTitle() + " - bbtk (c) CREATIS LRMN"),
+ wxSize( bbGetInputWinWidth() , bbGetInputWinHeight() ));
+ //bbGetInputWinWidth() , bbGetInputWinHeight() ) );
+// show->bbGetDialog()->Update();
+// show->bbGetDialog()->Refresh();
+
+ //show->bbGetDialog()->Iconize(true);
+ show->bbGetDialog()->Show(true);
+// show->bbGetDialog()->Show(false);
+// show->bbGetDialog()->SetSize(wxSize( bbGetInputWinWidth() , bbGetInputWinHeight() ));
+
+ }
+ // Input WinDialog set to false : creating a Frame
+ else
+ {
+ bbtkDebugMessage("process",2,
+ " Input WinDialog set to false : creating a Frame"
+ <<std::endl);
+ show = (Window*) new WxBlackBoxFrame( GetThisPointer<WxBlackBox>(),
+ Wx::GetTopWindow(),
+ std2wx( bbGetInputWinTitle() + " - bbtk (c) CREATIS LRMN"),
+ wxSize( bbGetInputWinWidth() , bbGetInputWinHeight() ) );
+// show->bbGetFrame()->Update();
+// show->bbGetFrame()->Refresh();
+ show->bbGetFrame()->Show();
+ }
+
+ } // else bbGetWindow
+// show->bbShow();
+
+ } // bbGetOutputConnectorMap().find("Widget")).second->GetConnectionVector().size()
+ }
+ //=========================================================================
+
+
+ //=========================================================================
+ void WxBlackBox::bbShowWidget()
+ {
+ // Show the window
+ Window *show = bbGetWindow();
+ if (show!=NULL)
+ {
+ show->bbShow();
+ }
+ }
+ //=========================================================================
+
+
+ //=========================================================================
+ void WxBlackBox::bbProcess()
+ {
+ // TODO : update the window size and title
+ this->bbUserProcess();
+ }
+ //=========================================================================
+
+ /* EED BORRAME original 18 mars 2009
//=========================================================================
void WxBlackBox::bbProcess()
{
// If output widget not connected : have to create and show the window
- if ( (*bbGetOutputConnectorMap().find("Widget")).second
- ->GetConnectionVector().size() == 0 )
+ if ( (*bbGetOutputConnectorMap().find("Widget")).second->GetConnectionVector().size() == 0 )
{
- Window* show = 0;
+ Window* show = 0;
// If the window already exists : no need creating it
if (bbGetWindow()!=0)
{
}
//=========================================================================
-
+*/
//=========================================================================
Program: bbtk
Module: $RCSfile: bbtkWxBlackBox.h,v $
Language: C++
- Date: $Date: 2008/12/11 15:30:04 $
- Version: $Revision: 1.24 $
+ Date: $Date: 2009/03/23 13:06:41 $
+ Version: $Revision: 1.25 $
========================================================================*/
- //==================================================================
+ //==================================================================
+ /// Overloaded bbCreateWidget method for WxBlackBoxes which handles
+ /// the window creation if needed
+ virtual void bbCreateWidget();
+ //==================================================================
+
+ //==================================================================
+ /// Overloaded bbShowWidget method for WxBlackBoxes which handles
+ /// the window creation if needed
+ virtual void bbShowWidget();
+ //==================================================================
+
+ //==================================================================
/// Overloaded processing method for WxBlackBoxes which handles
/// the window creation if needed
virtual void bbProcess();
//==================================================================
-
+
+
+
+
+
//==================================================================
/// If necessary creates the WxBlackBoxWindow associated to the box
/// and shows it
/// The WxBlackBoxWindow associated to the box
Window* bbmWindow;
+
/// The WxBlackBoxWidgetEventHandler associated to the box
WxBlackBoxWidgetEventHandler* bbmWidgetEventHandler;
Program: bbtk
Module: $RCSfile: bbtkWxGUIHtmlBrowser.cxx,v $
Language: C++
- Date: $Date: 2008/11/25 13:18:30 $
- Version: $Revision: 1.12 $
+ Date: $Date: 2009/03/23 13:06:41 $
+ Version: $Revision: 1.13 $
=========================================================================*/
/* ---------------------------------------------------------------------
mwxHtmlWindow->SetBorders(5);
// mwxHtmlWindow->FitInside();
- wxStaticBoxSizer* hw =
- new wxStaticBoxSizer( new wxStaticBox( this, -1, _T(""),
- wxDefaultPosition,
- size ),
- wxVERTICAL );
-
- hw->Add ( mwxHtmlWindow, 1, wxEXPAND );
-
- sizer->Add ( bsizer , 0, wxEXPAND );
- sizer->Add ( hw, 1, wxGROW ); // | wxLEFT | wxRIGHT | wxBOTTOM, 10 );
+ sizer->Add ( bsizer , 0, wxEXPAND );
+
+// EED: This have a problem in macOS
+// wxStaticBoxSizer* hw =
+// new wxStaticBoxSizer(
+// new wxStaticBox( this, -1, _T(""), wxDefaultPosition, size ),
+// wxVERTICAL
+// );
+// hw->Add ( mwxHtmlWindow, 1, wxEXPAND );
+//EED sizer->Add ( hw, 1, wxGROW ); // | wxLEFT | wxRIGHT | wxBOTTOM, 10 );
+
+ sizer->Add ( mwxHtmlWindow, 1, wxGROW ); // | wxLEFT | wxRIGHT | wxBOTTOM, 10 );
panel -> SetSizer(sizer);
panel -> SetAutoLayout(true);
//========================================================================
void WxGUIHtmlBrowser::UpdateURL()
{
-
wxString s = mwxHtmlWindow->GetOpenedPage();
if (!mwxHtmlWindow->GetOpenedAnchor().IsEmpty())
{
Program: bbtk
Module: $RCSfile: bbtkWxGUIScriptingInterface.cxx,v $
Language: C++
- Date: $Date: 2009/01/27 14:22:57 $
- Version: $Revision: 1.33 $
+ Date: $Date: 2009/03/23 13:06:41 $
+ Version: $Revision: 1.34 $
=========================================================================*/
/* ---------------------------------------------------------------------
.Bottom()
.MinSize(wxSize(100,100))
);
+
m_mgr.AddPane(mWxGUICommand,
wxAuiPaneInfo().Name(wxT("command_content"))
.Caption(wxT("Command"))