]> Creatis software - bbtk.git/commitdiff
no message
authorEduardo Davila <Eduardo.Davila@creatis.insa-lyon.fr>
Sun, 8 May 2011 08:48:56 +0000 (08:48 +0000)
committerEduardo Davila <Eduardo.Davila@creatis.insa-lyon.fr>
Sun, 8 May 2011 08:48:56 +0000 (08:48 +0000)
packages/wx/src/bbwxLaunchBrowser.cxx [new file with mode: 0644]
packages/wx/src/bbwxLaunchBrowser.h [new file with mode: 0644]
samples/SampleOutputObserver/bbtkSampleOutputObserver.cxx

diff --git a/packages/wx/src/bbwxLaunchBrowser.cxx b/packages/wx/src/bbwxLaunchBrowser.cxx
new file mode 100644 (file)
index 0000000..39ff19e
--- /dev/null
@@ -0,0 +1,74 @@
+//===== 
+// Before editing this file, make sure it's a file of your own (i.e.: it wasn't generated from xml description; if so : your modifications will be lost)
+//===== 
+#include "bbwxLaunchBrowser.h"
+#include "bbwxPackage.h"
+
+#include <wx/utils.h>
+
+namespace bbwx
+{
+
+BBTK_ADD_BLACK_BOX_TO_PACKAGE(wx,LaunchBrowser)
+BBTK_BLACK_BOX_IMPLEMENTATION(LaunchBrowser,bbtk::AtomicBlackBox);
+//===== 
+// Before editing this file, make sure it's a file of your own (i.e.: it wasn't generated from xml description; if so : your modifications will be lost)
+//===== 
+void LaunchBrowser::Process()
+{
+
+// THE MAIN PROCESSING METHOD BODY
+//   Here we simply set the input 'In' value to the output 'Out'
+//   And print out the output value
+// INPUT/OUTPUT ACCESSORS ARE OF THE FORM :
+//    void bbSet{Input|Output}NAME(const TYPE&)
+//    const TYPE& bbGet{Input|Output}NAME() const 
+//    Where :
+//    * NAME is the name of the input/output
+//      (the one provided in the attribute 'name' of the tag 'input')
+//    * TYPE is the C++ type of the input/output
+//      (the one provided in the attribute 'type' of the tag 'input')
+
+       wxLaunchDefaultBrowser( wxString( bbGetInputIn().c_str() , wxConvUTF8)  );
+  
+}
+//===== 
+// Before editing this file, make sure it's a file of your own (i.e.: it wasn't generated from xml description; if so : your modifications will be lost)
+//===== 
+void LaunchBrowser::bbUserSetDefaultValues()
+{
+
+//  SET HERE THE DEFAULT INPUT/OUTPUT VALUES OF YOUR BOX 
+//    Here we initialize the input 'In' to 0
+   bbSetInputIn("http://www.creatis.insa-lyon.fr");
+  
+}
+//===== 
+// Before editing this file, make sure it's a file of your own (i.e.: it wasn't generated from xml description; if so : your modifications will be lost)
+//===== 
+void LaunchBrowser::bbUserInitializeProcessing()
+{
+
+//  THE INITIALIZATION METHOD BODY :
+//    Here does nothing 
+//    but this is where you should allocate the internal/output pointers 
+//    if any 
+
+  
+}
+//===== 
+// Before editing this file, make sure it's a file of your own (i.e.: it wasn't generated from xml description; if so : your modifications will be lost)
+//===== 
+void LaunchBrowser::bbUserFinalizeProcessing()
+{
+
+//  THE FINALIZATION METHOD BODY :
+//    Here does nothing 
+//    but this is where you should desallocate the internal/output pointers 
+//    if any
+  
+}
+}
+// EO namespace bbwx
+
+
diff --git a/packages/wx/src/bbwxLaunchBrowser.h b/packages/wx/src/bbwxLaunchBrowser.h
new file mode 100644 (file)
index 0000000..a1b2234
--- /dev/null
@@ -0,0 +1,47 @@
+//===== 
+// Before editing this file, make sure it's a file of your own (i.e.: it wasn't generated from xml description; if so : your modifications will be lost)
+//===== 
+#ifndef __bbwxLaunchBrowser_h_INCLUDED__
+#define __bbwxLaunchBrowser_h_INCLUDED__
+#include "bbwx_EXPORT.h"
+#include "bbtkAtomicBlackBox.h"
+#include "iostream"
+
+#include <string>
+
+namespace bbwx
+{
+
+class bbwx_EXPORT LaunchBrowser
+ : 
+   public bbtk::AtomicBlackBox
+{
+  BBTK_BLACK_BOX_INTERFACE(LaunchBrowser,bbtk::AtomicBlackBox);
+//===== 
+// Before editing this file, make sure it's a file of your own (i.e.: it wasn't generated from xml description; if so : your modifications will be lost)
+//===== 
+       BBTK_DECLARE_INPUT(In,std::string);
+ // BBTK_DECLARE_OUTPUT(Out,double);
+  BBTK_PROCESS(Process);
+  void Process();
+//===== 
+// Before editing this file, make sure it's a file of your own (i.e.: it wasn't generated from xml description; if so : your modifications will be lost)
+//===== 
+};
+
+BBTK_BEGIN_DESCRIBE_BLACK_BOX(LaunchBrowser,bbtk::AtomicBlackBox);
+BBTK_NAME("LaunchBrowser");
+BBTK_AUTHOR("Info-Dev");
+BBTK_DESCRIPTION("Launch default Browser");
+BBTK_CATEGORY("");
+       BBTK_INPUT(LaunchBrowser,In,"URL",std::string,"");
+//BBTK_OUTPUT(LaunchBrowser,Out,"First output",double,"");
+BBTK_END_DESCRIBE_BLACK_BOX(LaunchBrowser);
+//===== 
+// Before editing this file, make sure it's a file of your own (i.e.: it wasn't generated from xml description; if so : your modifications will be lost)
+//===== 
+}
+// EO namespace bbwx
+
+#endif // __bbwxLaunchBrowser_h_INCLUDED__
+
index 9d32543e69a8fd41b85fbf8c3c3dad0ea8d13d6e..d00166352c9e15a8dc755e216512d37442b38b95 100644 (file)
@@ -132,7 +132,7 @@ void ClassWithTwoSliders::OnSlider( bbtk::BlackBox::Pointer p,
 int main(int argv, char* argc[])
 {
  // To track all ...
-  //  bbtk::MessageManager::SetMessageLevel("all",9);
+       bbtk::MessageManager::SetMessageLevel("all",9);
   SliderCallback();
   ClassWithTwoSliders C;
 }