]> Creatis software - bbtkGEditor.git/blobdiff - lib/EditorGraphicBBS/bbsKernelEditorGraphic/GPortModel.cxx
v1.1.0 BUG 1400
[bbtkGEditor.git] / lib / EditorGraphicBBS / bbsKernelEditorGraphic / GPortModel.cxx
index def04b12c6405aaa1fa283a33fa21d045aa4fbae..2ca30ba2c5d4fc8f843b7c3e74b34df7bbf6698a 100644 (file)
@@ -46,12 +46,12 @@ namespace bbtk {
     //=========================================================================
 
     GPortModel::GPortModel( ) {
-        _parentBox = NULL ;
-        _portType = -1 ;
-        _posInBox = 0 ;
-        _isConnected = false ;
-        _value = "" ;
-        _isValueSet = false ;
+        _parentBox             = NULL ;
+        _portType              = -1 ;
+        _posInBox              = 0 ;
+        _isConnected   = false ;
+        _value                 = "" ;
+        _isValueSet            = false ;
     }
 
     //=========================================================================
@@ -61,12 +61,10 @@ namespace bbtk {
     //=========================================================================
 
     void GPortModel::registerInBox( GBoxModel *blackBox , int portType , int pos ) {
-        _parentBox = blackBox ;
-        _portType = portType ;
-        _posInBox = pos ;
-
+        _parentBox     = blackBox ;
+        _portType      = portType ;
+        _posInBox      = pos ;
         updatePortPosition( ) ;
-
     }
 
     //=========================================================================
@@ -127,7 +125,7 @@ namespace bbtk {
     //=========================================================================
 
     GBoxModel* GPortModel::getParentBox( ) {
-        return _parentBox ;
+        return _parentBox;
     }
 
     //=========================================================================
@@ -146,6 +144,10 @@ namespace bbtk {
     //=========================================================================
 
     void GPortModel::setValue( std::string value ) {
+
+               //Removing Colons JPRG
+               _parentBox->removeColons(value);
+               
         _value = value ;
         if ( _value == "" ) {
             _isValueSet = false ;
@@ -158,7 +160,11 @@ namespace bbtk {
     //=========================================================================
 
     std::string GPortModel::getValue( ) {
-        return _value ;
+               //JPRG::Adding Colons
+               std::string text = _value;
+               _parentBox->addColons(text);
+               return text;
+               
     }
 
     //=========================================================================