[KSS-checkins] r50415 - in kukit/kukit.js/branch/ree-1.4-markup-and-syntax-changes: . kukit

reebalazs at codespeak.net reebalazs at codespeak.net
Mon Jan 7 08:08:06 CET 2008


Author: reebalazs
Date: Mon Jan  7 08:08:00 2008
New Revision: 50415

Modified:
   kukit/kukit.js/branch/ree-1.4-markup-and-syntax-changes/   (props changed)
   kukit/kukit.js/branch/ree-1.4-markup-and-syntax-changes/kukit/selectorreg.js
Log:
Rename kssWidget -> kssMarkedNode

Modified: kukit/kukit.js/branch/ree-1.4-markup-and-syntax-changes/kukit/selectorreg.js
==============================================================================
--- kukit/kukit.js/branch/ree-1.4-markup-and-syntax-changes/kukit/selectorreg.js	(original)
+++ kukit/kukit.js/branch/ree-1.4-markup-and-syntax-changes/kukit/selectorreg.js	Mon Jan  7 08:08:00 2008
@@ -162,32 +162,32 @@
     return results;
 });
 
-kukit.sr.KssWidgetPP = function() {};
-kukit.sr.KssWidgetPP.prototype = {
-    check: function(args) {
+kukit.sr.KssMarkedNodePP = function() {
+    this.check = function(args){
 ;;;     if (args.length != 2) {
-;;;         throw new Error('kssWidget selector method needs 2 arguments');
+;;;         throw new Error('kssMarkedNode selector method needs 2 arguments (keyType, key)');
 ;;;     }
-    },
-    eval: function(args, node, defaultParameters) {
-        var keytype =  args[0];
+    };
+    this.eval = function(args, node, defaultParameters) {
+        var keyType =  args[0];
         var key =  args[1];
-;;;     if (keytype.match(/[ -]/)) {
-;;;         kukit.E = 'keytype parameter in kssIdOfValue provider cannot contain';
+;;;     if (keyType.match(/[ -]/)) {
+;;;         kukit.E = 'keyType parameter in kssMarkedNode selection provider cannot contain';
 ;;;         kukit.E += ' dashes or spaces.';
 ;;;         throw new Error(kukit.E);
 ;;;     }
 ;;;     if (key.match(/[ -]/)) {
-;;;         kukit.E = 'key parameter in kssIdOfValue provider cannot contain';
+;;;         kukit.E = 'key parameter in kssMarkedNode provider cannot contain';
 ;;;         kukit.E += ' dashes or spaces.';
 ;;;         throw new Error(kukit.E);
 ;;;     }
         var markup = kukit.dom.locateMarkup(node, true, 
                 kukit.dom.getKssValue, 
-                keytype, key);
-        // Just return the markup's node as a single result.
+                keyType, key);
+        // Just return the markup's node as a single selection result.
         return [markup.node];
-    }
+    };
 };
-kukit.pprovidersGlobalRegistry.register('kssWidget', kukit.sr.KssWidgetPP, 'selection');
+// returnTyoe is 'selection'.
+kukit.pprovidersGlobalRegistry.register('kssMarkedNode', kukit.sr.KssMarkedNodePP, 'selection');
 


More information about the Kukit-checkins mailing list