[rkward-cvs] SF.net SVN: rkward:[3733] trunk/rkward/rkward

tfry at users.sourceforge.net tfry at users.sourceforge.net
Fri Sep 9 08:56:33 UTC 2011


Revision: 3733
          http://rkward.svn.sourceforge.net/rkward/?rev=3733&view=rev
Author:   tfry
Date:     2011-09-09 08:56:32 +0000 (Fri, 09 Sep 2011)
Log Message:
-----------
Fix another confusion between isSatisfied() and isValid() (keeps giving me a headache). Remove some obsolete connections to requiredness property.

Modified Paths:
--------------
    trunk/rkward/rkward/plugin/rkcomponent.cpp
    trunk/rkward/rkward/plugins/00saveload/import/import_csv.xml
    trunk/rkward/rkward/plugins/00saveload/import/import_spss.xml
    trunk/rkward/rkward/plugins/00saveload/save/write.xml
    trunk/rkward/rkward/plugins/00saveload/save/write_table.xml

Modified: trunk/rkward/rkward/plugin/rkcomponent.cpp
===================================================================
--- trunk/rkward/rkward/plugin/rkcomponent.cpp	2011-09-09 07:28:46 UTC (rev 3732)
+++ trunk/rkward/rkward/plugin/rkcomponent.cpp	2011-09-09 08:56:32 UTC (rev 3733)
@@ -148,6 +148,7 @@
 bool RKComponentBase::isSatisfied () {
 	RK_TRACE (PLUGIN);
 	if (!required) return true;
+	if (isComponent () && static_cast<RKComponent*>(this)->isInactive ()) return true;
 	if (isValid ()) return true;
  	if (isComponent ()) RK_DO (qDebug ("component not satisfied: %s", qPrintable (static_cast<RKComponent*> (this)->getIdInParent ())), PLUGIN, DL_DEBUG);
 	return false;		// never happens in RKComponentBase, but might in subclasses
@@ -257,7 +258,6 @@
 	RK_TRACE (PLUGIN);
 #warning TODO: I do not think we need this. Use recursiveStatus, instead
 
-	if (isInactive ()) return true;
 	for (QHash<QString, RKComponentBase*>::const_iterator it = child_map.constBegin (); it != child_map.constEnd (); ++it) {
 		if (!(it.value ()->isSatisfied ())) return false;
 	}

Modified: trunk/rkward/rkward/plugins/00saveload/import/import_csv.xml
===================================================================
--- trunk/rkward/rkward/plugins/00saveload/import/import_csv.xml	2011-09-09 07:28:46 UTC (rev 3732)
+++ trunk/rkward/rkward/plugins/00saveload/import/import_csv.xml	2011-09-09 08:56:32 UTC (rev 3733)
@@ -27,7 +27,6 @@
 		
 		<convert id="customdec" mode="equals" sources="dec.string" standard="other" />
 		<connect client="custom_dec.enabled" governor="customdec" />
-		<connect client="custom_dec.required" governor="custom_dec.enabled" />
 		
 		<convert id="quickNTT2" mode="or" sources="quickNone;quickTAB;quickTAB2"/>
 		<connect client="sep.sepTab.enabled" governor="quickNTT2" />
@@ -41,7 +40,6 @@
 		
 		<convert id="customsep" mode="equals" sources="sep.string" standard="other" />
 		<connect client="custom_sep.enabled" governor="customsep" />
-		<connect client="custom_sep.required" governor="custom_sep.enabled" />
 		
 		<connect client="quote.quoteSingQ.enabled" governor="quickNone" />
 		<connect client="quote.quoteDoubQSingQ.enabled" governor="quickNone" />
@@ -50,22 +48,17 @@
 		
 		<convert id="customquote" mode="equals" sources="quote.string" standard="other" />
 		<connect client="custom_quote.enabled" governor="customquote" />
-		<connect client="custom_quote.required" governor="custom_quote.enabled" />
 
 		<convert id="userow" mode="equals" sources="rowname.string" standard="rowcol" />
 		<convert id="customizerow" mode="equals" sources="rowname.string" standard="custoRow" />
 		<convert id="customizerow2" mode="and" sources="isrow.state;customizerow" standard="custoRow" />
 		<connect client="nomrow.enabled" governor="userow" />
-		<connect client="nomrow.required" governor="userow" />
 		<connect client="rownames.enabled" governor="customizerow" />
-		<connect client="rownames.required" governor="customizerow" />
 
 		<convert id="customizecol" mode="equals" sources="colname.string" standard="custoCol" />
 		<connect client="colnames.enabled" governor="customizecol" />
-		<connect client="colnames.required" governor="customizecol" />
 		<convert id="customizeclasses" mode="equals" sources="colclass.string" standard="custoClass" />
 		<connect client="custoClasses.enabled" governor="customizeclasses" />
-		<connect client="custoClasses.required" governor="customizeclasses" />
 	</logic>
 	<dialog label="Import Text / CSV data" >
 		<tabbook>
@@ -92,7 +85,7 @@
 							<option id="decComma" value="','" label="',' (Comma)" />
 							<option id="decOther" value="other" label="Other (specify below)" />
 						</radio>
-						<input id="custom_dec" label="Specify decimal point character" />
+						<input id="custom_dec" label="Specify decimal point character" required="true"/>
 					</column>
 					<column>
 						<radio id="sep" label="Field separator character" >
@@ -102,7 +95,7 @@
 							<option id="sepSpace" value="' '" label="Space" />
 							<option id="sepOther" value="other" label="Other (specify below)" />
 						</radio>
-						<input id="custom_sep" label="Specify field separator character" />
+						<input id="custom_sep" label="Specify field separator character" required="true"/>
 					</column>
 				</row>
 			</tab>
@@ -116,8 +109,8 @@
 								<option value="rowcol" label="As specified in column x:" />
 								<option value="custoRow" label="Use a vector" />
 							</radio>
-							<input size="small" id="nomrow" initial="1" label="Column number or variable name" />
-							<input id="rownames" label="Vector of row names (quoted)" />
+							<input size="small" id="nomrow" initial="1" label="Column number or variable name" required="true"/>
+							<input id="rownames" label="Vector of row names (quoted)" required="true"/>
 							<stretch/>
 						</frame>
 					</column>
@@ -127,13 +120,13 @@
 								<option value="" label="Default" />
 								<option value="custoCol" label="Use a character vector" />
 							</radio>
-							<input id="colnames" label="Vector of column names (quoted)" />
+							<input id="colnames" label="Vector of column names (quoted)" required="true"/>
 						<checkbox id="flush" label="Skip any further fields" value=", flush=TRUE" value_unchecked="" />
 							<radio id="colclass" label="Classes of columns" >
 								<option value="" label="Default" />
 								<option value="custoClass" label="Use a character vector" />
 							</radio>
-							<input id="custoClasses" label="Vector of column classes (quoted)" />
+							<input id="custoClasses" label="Vector of column classes (quoted)" required="true"/>
 						</frame>
 					</column>
 				</row>
@@ -155,7 +148,7 @@
 						<option id="quoteNone" value="''" label="None / disabled" />
 						<option id="quoteOther" value="other" label="Other (specify below)" />
 					</radio>
-					<input id="custom_quote" label="Specify quoting character(s)" />
+					<input id="custom_quote" label="Specify quoting character(s)" required="true"/>
 				</column>
 				<column>
 						<input size="small" initial="0" id="skip" label="Skip x lines at the start of the file" />

Modified: trunk/rkward/rkward/plugins/00saveload/import/import_spss.xml
===================================================================
--- trunk/rkward/rkward/plugins/00saveload/import/import_spss.xml	2011-09-09 07:28:46 UTC (rev 3732)
+++ trunk/rkward/rkward/plugins/00saveload/import/import_spss.xml	2011-09-09 08:56:32 UTC (rev 3733)
@@ -15,7 +15,6 @@
 		<convert id="other_encoding" mode="equals" standard="other" sources="encoding.string" />
 		<convert id="other_encoding2" mode="and" sources="other_encoding;do_locale_conversion.state" />
 		<connect governor="other_encoding2" client="user_encoding.enabled" />
-		<connect governor="other_encoding2" client="user_encoding.required" />
 	</logic>
 	<dialog label="Import SPSS file">
 		<tabbook>
@@ -58,7 +57,7 @@
 					<option value="ISO8859-16" label="ISO8859-16 Latin-10 South-Eastern European"/>
 					<option value="other" label="Other (specify below)"/>
 				</dropdown>
-				<input id="user_encoding" label="Other encoding" />
+				<input id="user_encoding" label="Other encoding" required="true"/>
 			</tab>
 		</tabbook>
 	</dialog>

Modified: trunk/rkward/rkward/plugins/00saveload/save/write.xml
===================================================================
--- trunk/rkward/rkward/plugins/00saveload/save/write.xml	2011-09-09 07:28:46 UTC (rev 3732)
+++ trunk/rkward/rkward/plugins/00saveload/save/write.xml	2011-09-09 08:56:32 UTC (rev 3733)
@@ -8,7 +8,6 @@
 		<convert id="customsep" mode="equals" sources="sep.string" standard="other" />
 		<convert id="enable_customsep" mode="and" sources="customsep;sep.enables" />
 		<connect client="custom_sep.enabled" governor="enable_customsep" />
-		<connect client="custom_sep.required" governor="custom_sep.enabled" />
 	</logic>
 
 	<dialog label="Write vector / matrix" >
@@ -29,7 +28,7 @@
 							<option id="sepSpace" value=" " label="Space" checked="true" />
 							<option id="sepOther" value="other" label="Other (specify below)" />
 						</radio>
-						<input id="custom_sep" label="Specify field separator character" />
+						<input id="custom_sep" label="Specify field separator character" required="true"/>
 					</column>
 					<column>
 						<spinbox type="integer" initial="1" min="1" id="ncolumns" max="100" label="Number of columns to write" />

Modified: trunk/rkward/rkward/plugins/00saveload/save/write_table.xml
===================================================================
--- trunk/rkward/rkward/plugins/00saveload/save/write_table.xml	2011-09-09 07:28:46 UTC (rev 3732)
+++ trunk/rkward/rkward/plugins/00saveload/save/write_table.xml	2011-09-09 08:56:32 UTC (rev 3733)
@@ -6,9 +6,7 @@
 		<convert id="customizerow" mode="equals" sources="rows.string" standard="custoRow" />
 		<convert id="customizecol" mode="equals" sources="columns.string" standard="custoCol" />
 		<connect client="rownames.enabled" governor="customizerow" />
-		<connect client="rownames.required" governor="customizerow" />
 		<connect client="colnames.enabled" governor="customizecol" />
-		<connect client="colnames.required" governor="customizecol" />
 	</logic>
 	<dialog label="Write as table">
 		<tabbook>
@@ -33,13 +31,13 @@
 					<option value="FALSE" label="No names" />
 					<option value="custoCol" label="Customize" />
 				</radio>
-				<varslot multi="false" classes="integer numeric character" source="varname" id="colnames" label="Columns names" />
+				<varslot multi="false" classes="integer numeric character" source="varname" id="colnames" label="Columns names" required="true"/>
 				<radio id="rows" label="Name of rows" >
 					<option value="TRUE" id="temp1" label="Use the names of the rows" />
 					<option value="FALSE" id="temp2" label="No names" />
 					<option value="custoRow" label="Customize rows" />
 				</radio>
-				<varslot multi="false" classes="integer numeric character" id="rownames" source="varname" label="Names of rows" />
+				<varslot multi="false" classes="integer numeric character" id="rownames" source="varname" label="Names of rows" required="true"/>
 				<varselector id="varname" />
 			</tab>
 			<tab label="Options" >

This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.





More information about the rkward-tracker mailing list