* CBLOCK4 block added to the "User-Defined Functions" 45/12645/2
Clément DAVID [Tue, 24 Sep 2013 07:46:22 +0000 (09:46 +0200)]
* Bug #12924 fixed - Block type 2004 were not handled as a valid block type.

Change-Id: Icf2f70b42729f1fdca258688a8e5ac682c994a14

scilab/CHANGES_5.5.X
scilab/modules/scicos_blocks/macros/Misc/CBLOCK4.sci
scilab/modules/xcos/etc/Xcos-style.xml
scilab/modules/xcos/etc/palettes.xml
scilab/modules/xcos/images/palettes/CBLOCK4.png [new file with mode: 0644]
scilab/modules/xcos/src/java/org/scilab/modules/xcos/block/BasicBlock.java

index 1034b67..df8e7ab 100644 (file)
@@ -152,6 +152,8 @@ Xcos
 
 * xcosAddToolsMenu added to let the user perform some actions on the graph.
 
+* CBLOCK4 block added to the "User-Defined Functions"
+
 * Bug #7350 fixed - The I/O ports numbering of a superblock was not updated
                     when a new port was dropped.
 
@@ -220,6 +222,8 @@ Xcos
 
 * Bug #12877 fixed - Incorrect output port dimensions and types in GENSIN_f, GENSQR_f, STEP_FUNCTION and STEP blocks fixed.
 
+* Bug #12924 fixed - Blocks type 2004 was not handled as a valid block type.
+
 
 Toolbox Skeleton
 =================
index 3943828..f2541c2 100644 (file)
@@ -190,7 +190,7 @@ function [x,y,typ]=CBLOCK4(job,arg1,arg2)
         []);
 
         gr_i=["xstringb(orig(1),orig(2),''C block4'',sz(1),sz(2),''fill'');"]
-        x=standard_define([2 2],model,label,gr_i)
+        x=standard_define([4 2],model,label,gr_i)
     end
 endfunction
 
index 6dca2c3..e5fadf5 100644 (file)
     <add as="CBLOCK" extend="blockWithLabel">
         <add as="displayedLabel" value="C block 2:&lt;BR&gt;%1$s"/>
     </add>
+    <add as="CBLOCK4" extend="blockWithLabel">
+        <add as="displayedLabel" value="C block 4:&lt;BR&gt;%1$s"/>
+    </add>
     <add as="generic_block3" extend="blockWithLabel">
         <add as="displayedLabel" value="native block:&lt;BR&gt;%1$s"/>
     </add>
index c98bb80..ff35981 100644 (file)
             <block name="CBLOCK">
                 <icon variable="SCI" path="/modules/xcos/images/palettes/CBLOCK.png"/>
             </block>
+            <block name="CBLOCK4">
+                <icon variable="SCI" path="/modules/xcos/images/palettes/CBLOCK4.png"/>
+            </block>
             <block name="DEBUG_SCICOS">
                 <icon variable="SCI" path="/modules/xcos/images/palettes/DEBUG_SCICOS.png"/>
             </block>
diff --git a/scilab/modules/xcos/images/palettes/CBLOCK4.png b/scilab/modules/xcos/images/palettes/CBLOCK4.png
new file mode 100644 (file)
index 0000000..7474478
Binary files /dev/null and b/scilab/modules/xcos/images/palettes/CBLOCK4.png differ
index ae98bbb..746daa8 100644 (file)
@@ -380,14 +380,22 @@ public class BasicBlock extends ScilabGraphUniqueObject implements Serializable
         SCILAB(5.0),
         /** Debug blocks */
         DEBUG(99),
+        /** dynamic {@link #TYPE_1} Fortran blocks (fortran_block.sci) */
+        DYNAMIC_FORTRAN_1(1001.0),
+        /** dynamic {@link #TYPE_1} C blocks (c_block.sci) */
+        DYNAMIC_C_1(2001.0),
+        /** Explicit dynamic {@link #TYPE_4} blocks (CBLOCK.sci) */
+        DYNAMIC_EXPLICIT_4(2004.0),
+        /** Implicit {@link #TYPE_1} Fortran blocks (DIFF_f.sci) */
+        OLDBLOCKS(10001.0),
+        /** Implicit {@link #C_OR_FORTRAN} blocks */
+        IMPLICIT_C_OR_FORTRAN(10004.0),
+        /** Implicit dynamic {@link #TYPE_4} blocks (CBLOCK.sci) */
+        DYNAMIC_IMPLICIT_4(12004.0),
         /** Modelica {@link #C_OR_FORTRAN} blocks */
         MODELICA(30004.0),
         /** Magic types */
-        UNKNOWN(5.0),
-        /** Implicit {@link #TYPE_1} blocks */
-        OLDBLOCKS(10001.0),
-        /** Implicit {@link #C_OR_FORTRAN} blocks */
-        IMPLICIT_C_OR_FORTRAN(10004.0);
+        UNKNOWN(5.0);
 
         private double value;