From 9627837257cedc51840fd940767b1aac22553358 Mon Sep 17 00:00:00 2001
From: Gabriel Monnerat <gabriel@tiolive.com>
Date: Tue, 2 Nov 2010 18:13:29 +0000
Subject: [PATCH] 2010-11-02 gabriel * The initial commit

git-svn-id: https://svn.erp5.org/repos/public/erp5/trunk@39791 20353a03-c40f-0410-a6d1-a30d3c3de9de
---
 .../erp5_jquery/plugin/spinbtn.xml            |  26 ++
 .../plugin/spinbtn/JQuerySpinBtn.css.xml      |  81 +++++
 .../plugin/spinbtn/JQuerySpinBtn.js.xml       | 312 ++++++++++++++++++
 .../plugin/spinbtn/JQuerySpinBtn.min.js.xml   |  48 +++
 .../plugin/spinbtn/spinbtn_updn.png.xml       |  63 ++++
 bt5/erp5_jquery_plugin_spinbtn/bt/change_log  |   2 +
 .../bt/copyright_list                         |   1 +
 .../bt/dependency_list                        |   1 +
 bt5/erp5_jquery_plugin_spinbtn/bt/description |   1 +
 bt5/erp5_jquery_plugin_spinbtn/bt/license     |   1 +
 .../bt/maintainer_list                        |   1 +
 bt5/erp5_jquery_plugin_spinbtn/bt/revision    |   1 +
 .../bt/template_format_version                |   1 +
 .../bt/template_path_list                     |   2 +
 bt5/erp5_jquery_plugin_spinbtn/bt/title       |   1 +
 bt5/erp5_jquery_plugin_spinbtn/bt/version     |   1 +
 16 files changed, 543 insertions(+)
 create mode 100644 bt5/erp5_jquery_plugin_spinbtn/PathTemplateItem/portal_skins/erp5_jquery/plugin/spinbtn.xml
 create mode 100644 bt5/erp5_jquery_plugin_spinbtn/PathTemplateItem/portal_skins/erp5_jquery/plugin/spinbtn/JQuerySpinBtn.css.xml
 create mode 100644 bt5/erp5_jquery_plugin_spinbtn/PathTemplateItem/portal_skins/erp5_jquery/plugin/spinbtn/JQuerySpinBtn.js.xml
 create mode 100644 bt5/erp5_jquery_plugin_spinbtn/PathTemplateItem/portal_skins/erp5_jquery/plugin/spinbtn/JQuerySpinBtn.min.js.xml
 create mode 100644 bt5/erp5_jquery_plugin_spinbtn/PathTemplateItem/portal_skins/erp5_jquery/plugin/spinbtn/spinbtn_updn.png.xml
 create mode 100644 bt5/erp5_jquery_plugin_spinbtn/bt/change_log
 create mode 100644 bt5/erp5_jquery_plugin_spinbtn/bt/copyright_list
 create mode 100644 bt5/erp5_jquery_plugin_spinbtn/bt/dependency_list
 create mode 100644 bt5/erp5_jquery_plugin_spinbtn/bt/description
 create mode 100644 bt5/erp5_jquery_plugin_spinbtn/bt/license
 create mode 100644 bt5/erp5_jquery_plugin_spinbtn/bt/maintainer_list
 create mode 100644 bt5/erp5_jquery_plugin_spinbtn/bt/revision
 create mode 100644 bt5/erp5_jquery_plugin_spinbtn/bt/template_format_version
 create mode 100644 bt5/erp5_jquery_plugin_spinbtn/bt/template_path_list
 create mode 100644 bt5/erp5_jquery_plugin_spinbtn/bt/title
 create mode 100644 bt5/erp5_jquery_plugin_spinbtn/bt/version

diff --git a/bt5/erp5_jquery_plugin_spinbtn/PathTemplateItem/portal_skins/erp5_jquery/plugin/spinbtn.xml b/bt5/erp5_jquery_plugin_spinbtn/PathTemplateItem/portal_skins/erp5_jquery/plugin/spinbtn.xml
new file mode 100644
index 0000000000..9ad8250ee0
--- /dev/null
+++ b/bt5/erp5_jquery_plugin_spinbtn/PathTemplateItem/portal_skins/erp5_jquery/plugin/spinbtn.xml
@@ -0,0 +1,26 @@
+<?xml version="1.0"?>
+<ZopeData>
+  <record id="1" aka="AAAAAAAAAAE=">
+    <pickle>
+      <global name="Folder" module="OFS.Folder"/>
+    </pickle>
+    <pickle>
+      <dictionary>
+        <item>
+            <key> <string>_objects</string> </key>
+            <value>
+              <tuple/>
+            </value>
+        </item>
+        <item>
+            <key> <string>id</string> </key>
+            <value> <string>spinbtn</string> </value>
+        </item>
+        <item>
+            <key> <string>title</string> </key>
+            <value> <string></string> </value>
+        </item>
+      </dictionary>
+    </pickle>
+  </record>
+</ZopeData>
diff --git a/bt5/erp5_jquery_plugin_spinbtn/PathTemplateItem/portal_skins/erp5_jquery/plugin/spinbtn/JQuerySpinBtn.css.xml b/bt5/erp5_jquery_plugin_spinbtn/PathTemplateItem/portal_skins/erp5_jquery/plugin/spinbtn/JQuerySpinBtn.css.xml
new file mode 100644
index 0000000000..c4d6da1bff
--- /dev/null
+++ b/bt5/erp5_jquery_plugin_spinbtn/PathTemplateItem/portal_skins/erp5_jquery/plugin/spinbtn/JQuerySpinBtn.css.xml
@@ -0,0 +1,81 @@
+<?xml version="1.0"?>
+<ZopeData>
+  <record id="1" aka="AAAAAAAAAAE=">
+    <pickle>
+      <global name="DTMLMethod" module="OFS.DTMLMethod"/>
+    </pickle>
+    <pickle>
+      <dictionary>
+        <item>
+            <key> <string>_Cacheable__manager_id</string> </key>
+            <value> <string>http_cache</string> </value>
+        </item>
+        <item>
+            <key> <string>__name__</string> </key>
+            <value> <string>JQuerySpinBtn.css</string> </value>
+        </item>
+        <item>
+            <key> <string>_vars</string> </key>
+            <value>
+              <dictionary/>
+            </value>
+        </item>
+        <item>
+            <key> <string>globals</string> </key>
+            <value>
+              <dictionary/>
+            </value>
+        </item>
+        <item>
+            <key> <string>raw</string> </key>
+            <value> <string encoding="cdata"><![CDATA[
+
+/*\n
+\tStyles to make ordinary <INPUT type="text"/> look like a spinbutton/spinbox control.\n
+\tUse with JQuerySpinBtn.js to provide the spin functionality by reacting to mouse etc.\n
+\t(Requires a reference to the JQuery library found at http://jquery.com/src/latest/)\n
+\t(Hats-off to John Resig for creating the excellent JQuery library. It is fab.)\n
+\n
+\tThis control is achieved with no extra html markup whatsoever and uses unobtrusive javascript.\n
+\n
+\tWritten by George Adamson, Software Unity (george.jquery@softwareunity.com) September 2006.\n
+\tBig improvements added by Mark Gibson, (mgibson@designlinks.net) September 2006.\n
+\n
+\tDo contact me with comments and suggestions but please don\'t ask for support.\n
+\tAs much as I\'d love to help with specific problems I have plenty to get on with already!\n
+\n
+\tGo ahead and use it in your own projects. This code is provided \'as is\'.\n
+\tSure I\'ve tested in heaps of ways. Its good for me, but you use it at your own risk.\n
+\tSoftwareUnity and I are certainly not responsible if your computer sets fire to the sofa,\n
+\thacks into the pentagon, hijacks a plane or gives you any kind of hassle whatsoever.\n
+\n
+\tIf you\'d like your spin-button image in a different place then you\'ll need to alter both\n
+\tthe CSS below and the javascript isMouseOverUpDn() function to accommodate the new position.\n
+\tYou could even have left and right buttons either side of the textbox.\n
+*/\n
+\n
+INPUT.spin-button {\n
+\t/* explicitly put padding for top/bottom/left in here so that Opera displays it better */\n
+\tpadding: 2px 20px 2px 2px;\n
+\tbackground-repeat:no-repeat;\t\t/* Warning: Img may disappear in Firefox if you use \'background-attachment:fixed\' ! */\n
+\tbackground-position:100% 0%;\n
+\tbackground-image:url(\'spinbtn_updn.png\');\n
+\tbackground-color:white; /* Needed for Opera */\n
+}\n
+\n
+INPUT.spin-button.up {\t\t\t\t\t/* Change button img when mouse is over the UP-arrow */\n
+\tcursor:pointer;\n
+\tbackground-position:100% -18px;\t\t/* 18px matches height of 2 visible buttons */\n
+}\n
+INPUT.spin-button.down {\t\t\t\t/* Change button img when mouse is over the DOWN-arrow */\n
+\tcursor:pointer;\n
+\tbackground-position:100% -36px;\t\t/* 36px matches height of 2x2 visible buttons */\n
+}\n
+
+
+]]></string> </value>
+        </item>
+      </dictionary>
+    </pickle>
+  </record>
+</ZopeData>
diff --git a/bt5/erp5_jquery_plugin_spinbtn/PathTemplateItem/portal_skins/erp5_jquery/plugin/spinbtn/JQuerySpinBtn.js.xml b/bt5/erp5_jquery_plugin_spinbtn/PathTemplateItem/portal_skins/erp5_jquery/plugin/spinbtn/JQuerySpinBtn.js.xml
new file mode 100644
index 0000000000..46b1da0a4a
--- /dev/null
+++ b/bt5/erp5_jquery_plugin_spinbtn/PathTemplateItem/portal_skins/erp5_jquery/plugin/spinbtn/JQuerySpinBtn.js.xml
@@ -0,0 +1,312 @@
+<?xml version="1.0"?>
+<ZopeData>
+  <record id="1" aka="AAAAAAAAAAE=">
+    <pickle>
+      <global name="File" module="OFS.Image"/>
+    </pickle>
+    <pickle>
+      <dictionary>
+        <item>
+            <key> <string>_Cacheable__manager_id</string> </key>
+            <value> <string>http_cache</string> </value>
+        </item>
+        <item>
+            <key> <string>_EtagSupport__etag</string> </key>
+            <value> <string>ts80003855.5</string> </value>
+        </item>
+        <item>
+            <key> <string>__name__</string> </key>
+            <value> <string>JQuerySpinBtn.js</string> </value>
+        </item>
+        <item>
+            <key> <string>content_type</string> </key>
+            <value> <string>application/x-javascript</string> </value>
+        </item>
+        <item>
+            <key> <string>data</string> </key>
+            <value> <string encoding="cdata"><![CDATA[
+
+/* SpinButton control\n
+ *\n
+ * Adds bells and whistles to any ordinary textbox to\n
+ * make it look and feel like a SpinButton Control.\n
+ *\n
+ * Originally written by George Adamson, Software Unity (george.jquery@softwareunity.com) August 2006.\n
+ * - Added min/max options\n
+ * - Added step size option\n
+ * - Added bigStep (page up/down) option\n
+ *\n
+ * Modifications made by Mark Gibson, (mgibson@designlinks.net) September 2006:\n
+ * - Converted to jQuery plugin\n
+ * - Allow limited or unlimited min/max values\n
+ * - Allow custom class names, and add class to input element\n
+ * - Removed global vars\n
+ * - Reset (to original or through config) when invalid value entered\n
+ * - Repeat whilst holding mouse button down (with initial pause, like keyboard repeat)\n
+ * - Support mouse wheel in Firefox\n
+ * - Fix double click in IE\n
+ * - Refactored some code and renamed some vars\n
+ *\n
+ * Modifications by Jeff Schiller, June 2009:\n
+ * - provide callback function for when the value changes based on the following\n
+ *   http://www.mail-archive.com/jquery-en@googlegroups.com/msg36070.html\n
+ * Modifications by Jeff Schiller, July 2009:\n
+ * - improve styling for widget in Opera\n
+ * - consistent key-repeat handling cross-browser\n
+ * Modifications by Alexis Deveria, October 2009:\n
+ * - provide "stepfunc" callback option to allow custom function to run when changing a value\n
+ * - Made adjustValue(0) only run on certain keyup events, not all.\n
+ *\n
+ * Tested in IE6, Opera9, Firefox 1.5\n
+ * v1.0  11 Aug 2006 - George Adamson\t- First release\n
+ * v1.1     Aug 2006 - George Adamson\t- Minor enhancements\n
+ * v1.2  27 Sep 2006 - Mark Gibson\t\t- Major enhancements\n
+ * v1.3a 28 Sep 2006 - George Adamson\t- Minor enhancements\n
+ * v1.4  18 Jun 2009 - Jeff Schiller    - Added callback function\n
+ * v1.5  06 Jul 2009 - Jeff Schiller    - Fixes for Opera.  \n
+ * v1.6  13 Oct 2009 - Alexis Deveria   - Added stepfunc function  \n
+ * v1.7  21 Oct 2009 - Alexis Deveria   - Minor fixes\n
+ *                                        Fast-repeat for keys and live updating as you type.\n
+ * v1.8  12 Jan 2010 - Benjamin Thomas  - Fixes for mouseout behavior.\n
+ *                                        Added smallStep\n
+ \n
+ Sample usage:\n
+ \n
+\t// Create group of settings to initialise spinbutton(s). (Optional)\n
+\tvar myOptions = {\n
+\t\t\t\t\tmin: 0,\t\t\t\t\t\t// Set lower limit.\n
+\t\t\t\t\tmax: 100,\t\t\t\t\t// Set upper limit.\n
+\t\t\t\t\tstep: 1,\t\t\t\t\t// Set increment size.\n
+\t\t\t\t\tsmallStep: 0.5,\t\t\t\t// Set shift-click increment size.\n
+\t\t\t\t\tspinClass: mySpinBtnClass,\t// CSS class to style the spinbutton. (Class also specifies url of the up/down button image.)\n
+\t\t\t\t\tupClass: mySpinUpClass,\t\t// CSS class for style when mouse over up button.\n
+\t\t\t\t\tdownClass: mySpinDnClass\t// CSS class for style when mouse over down button.\n
+\t\t\t\t\t}\n
+ \n
+\t$(document).ready(function(){\n
+\n
+\t\t// Initialise INPUT element(s) as SpinButtons: (passing options if desired)\n
+\t\t$("#myInputElement").SpinButton(myOptions);\n
+\n
+\t});\n
+ \n
+ */\n
+$.fn.SpinButton = function(cfg){\n
+\treturn this.each(function(){\n
+\n
+\t\tthis.repeating = false;\n
+\t\t\n
+\t\t// Apply specified options or defaults:\n
+\t\t// (Ought to refactor this some day to use $.extend() instead)\n
+\t\tthis.spinCfg = {\n
+\t\t\t//min: cfg && cfg.min ? Number(cfg.min) : null,\n
+\t\t\t//max: cfg && cfg.max ? Number(cfg.max) : null,\n
+\t\t\tmin: cfg && !isNaN(parseFloat(cfg.min)) ? Number(cfg.min) : null,\t// Fixes bug with min:0\n
+\t\t\tmax: cfg && !isNaN(parseFloat(cfg.max)) ? Number(cfg.max) : null,\n
+\t\t\tstep: cfg && cfg.step ? Number(cfg.step) : 1,\n
+\t\t\tstepfunc: cfg && cfg.stepfunc ? cfg.stepfunc : false,\n
+\t\t\tpage: cfg && cfg.page ? Number(cfg.page) : 10,\n
+\t\t\tupClass: cfg && cfg.upClass ? cfg.upClass : \'up\',\n
+\t\t\tdownClass: cfg && cfg.downClass ? cfg.downClass : \'down\',\n
+\t\t\treset: cfg && cfg.reset ? cfg.reset : this.value,\n
+\t\t\tdelay: cfg && cfg.delay ? Number(cfg.delay) : 500,\n
+\t\t\tinterval: cfg && cfg.interval ? Number(cfg.interval) : 100,\n
+\t\t\t_btn_width: 20,\n
+\t\t\t_direction: null,\n
+\t\t\t_delay: null,\n
+\t\t\t_repeat: null,\n
+\t\t\tcallback: cfg && cfg.callback ? cfg.callback : null\n
+\t\t};\n
+\n
+\t\t// if a smallStep isn\'t supplied, use half the regular step\n
+\t\tthis.spinCfg.smallStep = cfg && cfg.smallStep ? cfg.smallStep : this.spinCfg.step/2;\n
+\t\t\n
+\t\tthis.adjustValue = function(i){\n
+\t\t\tvar v;\n
+\t\t\tif(isNaN(this.value)) {\n
+\t\t\t\tv = this.spinCfg.reset;\n
+\t\t\t} else if($.isFunction(this.spinCfg.stepfunc)) {\n
+\t\t\t\tv = this.spinCfg.stepfunc(this, i);\n
+\t\t\t} else {\n
+\t\t\t\t// weirdest javascript bug ever: 5.1 + 0.1 = 5.199999999\n
+\t\t\t\tv = Number((Number(this.value) + Number(i)).toFixed(5));\n
+\t\t\t}\n
+\t\t\tif (this.spinCfg.min !== null) v = Math.max(v, this.spinCfg.min);\n
+\t\t\tif (this.spinCfg.max !== null) v = Math.min(v, this.spinCfg.max);\n
+\t\t\tthis.value = v;\n
+\t\t\tif ($.isFunction(this.spinCfg.callback)) this.spinCfg.callback(this);\n
+\t\t};\n
+\t\t\n
+\t\t$(this)\n
+\t\t.addClass(cfg && cfg.spinClass ? cfg.spinClass : \'spin-button\')\n
+\t\t\n
+\t\t.mousemove(function(e){\n
+\t\t\t// Determine which button mouse is over, or not (spin direction):\n
+\t\t\tvar x = e.pageX || e.x;\n
+\t\t\tvar y = e.pageY || e.y;\n
+\t\t\tvar el = e.target || e.srcElement;\n
+\t\t\tvar height = $(el).outerHeight()/2;\n
+\t\t\tvar direction = \n
+\t\t\t\t(x > coord(el,\'offsetLeft\') + el.offsetWidth - this.spinCfg._btn_width)\n
+\t\t\t\t? ((y < coord(el,\'offsetTop\') + height) ? 1 : -1) : 0;\n
+\t\t\t\n
+\t\t\tif (direction !== this.spinCfg._direction) {\n
+\t\t\t\t// Style up/down buttons:\n
+\t\t\t\tswitch(direction){\n
+\t\t\t\t\tcase 1: // Up arrow:\n
+\t\t\t\t\t\t$(this).removeClass(this.spinCfg.downClass).addClass(this.spinCfg.upClass);\n
+\t\t\t\t\t\tbreak;\n
+\t\t\t\t\tcase -1: // Down arrow:\n
+\t\t\t\t\t\t$(this).removeClass(this.spinCfg.upClass).addClass(this.spinCfg.downClass);\n
+\t\t\t\t\t\tbreak;\n
+\t\t\t\t\tdefault: // Mouse is elsewhere in the textbox\n
+\t\t\t\t\t\t$(this).removeClass(this.spinCfg.upClass).removeClass(this.spinCfg.downClass);\n
+\t\t\t\t}\n
+\t\t\t\t\n
+\t\t\t\t// Set spin direction:\n
+\t\t\t\tthis.spinCfg._direction = direction;\n
+\t\t\t}\n
+\t\t})\n
+\t\t\n
+\t\t.mouseout(function(){\n
+\t\t\t// Reset up/down buttons to their normal appearance when mouse moves away:\n
+\t\t\t$(this).removeClass(this.spinCfg.upClass).removeClass(this.spinCfg.downClass);\n
+\t\t\tthis.spinCfg._direction = null;\n
+\t\t\twindow.clearInterval(this.spinCfg._repeat);\n
+\t\t\twindow.clearTimeout(this.spinCfg._delay);\n
+\t\t})\n
+\t\t\n
+\t\t.mousedown(function(e){\n
+\t\t\tif ( e.button === 0 && this.spinCfg._direction != 0) {\n
+\t\t\t\t// Respond to click on one of the buttons:\n
+\t\t\t\tvar self = this;\n
+\t\t\t\tvar stepSize = e.shiftKey ? self.spinCfg.smallStep : self.spinCfg.step\n
+\n
+\t\t\t\tvar adjust = function() {\n
+\t\t\t\t\tself.adjustValue(self.spinCfg._direction * stepSize);\n
+\t\t\t\t};\n
+\t\t\t\n
+\t\t\t\tadjust();\n
+\t\t\t\t\n
+\t\t\t\t// Initial delay before repeating adjustment\n
+\t\t\t\tself.spinCfg._delay = window.setTimeout(function() {\n
+\t\t\t\t\tadjust();\n
+\t\t\t\t\t// Repeat adjust at regular intervals\n
+\t\t\t\t\tself.spinCfg._repeat = window.setInterval(adjust, self.spinCfg.interval);\n
+\t\t\t\t}, self.spinCfg.delay);\n
+\t\t\t}\n
+\t\t})\n
+\t\t\n
+\t\t.mouseup(function(e){\n
+\t\t\t// Cancel repeating adjustment\n
+\t\t\twindow.clearInterval(this.spinCfg._repeat);\n
+\t\t\twindow.clearTimeout(this.spinCfg._delay);\n
+\t\t})\n
+\t\t\n
+\t\t.dblclick(function(e) {\n
+\t\t\tif ($.browser.msie)\n
+\t\t\t\tthis.adjustValue(this.spinCfg._direction * this.spinCfg.step);\n
+\t\t})\n
+\t\t\n
+\t\t.keydown(function(e){\n
+\t\t\t// Respond to up/down arrow keys.\n
+\t\t\tswitch(e.keyCode){\n
+\t\t\t\tcase 38: this.adjustValue(this.spinCfg.step);  break; // Up\n
+\t\t\t\tcase 40: this.adjustValue(-this.spinCfg.step); break; // Down\n
+\t\t\t\tcase 33: this.adjustValue(this.spinCfg.page);  break; // PageUp\n
+\t\t\t\tcase 34: this.adjustValue(-this.spinCfg.page); break; // PageDown\n
+\t\t\t}\n
+\t\t})\n
+\t\t\n
+\t\t/*\n
+\t\thttp://unixpapa.com/js/key.html describes the current state-of-affairs for\n
+\t\tkey repeat events:\n
+\t\t- Safari 3.1 changed their model so that keydown is reliably repeated going forward\n
+\t\t- Firefox and Opera still only repeat the keypress event, not the keydown\n
+\t\t*/\n
+\t\t.keypress(function(e){\n
+\t\t\tif (this.repeating) {\n
+\t\t\t\t// Respond to up/down arrow keys.\n
+\t\t\t\tswitch(e.keyCode){\n
+\t\t\t\t\tcase 38: this.adjustValue(this.spinCfg.step);  break; // Up\n
+\t\t\t\t\tcase 40: this.adjustValue(-this.spinCfg.step); break; // Down\n
+\t\t\t\t\tcase 33: this.adjustValue(this.spinCfg.page);  break; // PageUp\n
+\t\t\t\t\tcase 34: this.adjustValue(-this.spinCfg.page); break; // PageDown\n
+\t\t\t\t}\n
+\t\t\t} \n
+\t\t\t// we always ignore the first keypress event (use the keydown instead)\n
+\t\t\telse {\n
+\t\t\t\tthis.repeating = true;\n
+\t\t\t}\n
+\t\t})\n
+\t\t\n
+\t\t// clear the \'repeating\' flag\n
+\t\t.keyup(function(e) {\n
+\t\t\tthis.repeating = false;\n
+\t\t\tswitch(e.keyCode){\n
+\t\t\t\tcase 38: // Up\n
+\t\t\t\tcase 40: // Down\n
+\t\t\t\tcase 33: // PageUp\n
+\t\t\t\tcase 34: // PageDown\n
+\t\t\t\tcase 13: this.adjustValue(0); break; // Enter/Return\n
+\t\t\t}\n
+\t\t})\n
+\t\t\n
+\t\t.bind("mousewheel", function(e){\n
+\t\t\t// Respond to mouse wheel in IE. (It returns up/dn motion in multiples of 120)\n
+\t\t\tif (e.wheelDelta >= 120)\n
+\t\t\t\tthis.adjustValue(this.spinCfg.step);\n
+\t\t\telse if (e.wheelDelta <= -120)\n
+\t\t\t\tthis.adjustValue(-this.spinCfg.step);\n
+\t\t\t\n
+\t\t\te.preventDefault();\n
+\t\t})\n
+\t\t\n
+\t\t.change(function(e){\n
+\t\t\tthis.adjustValue(0);\n
+\t\t});\n
+\t\t\n
+\t\tif (this.addEventListener) {\n
+\t\t\t// Respond to mouse wheel in Firefox\n
+\t\t\tthis.addEventListener(\'DOMMouseScroll\', function(e) {\n
+\t\t\t\tif (e.detail > 0)\n
+\t\t\t\t\tthis.adjustValue(-this.spinCfg.step);\n
+\t\t\t\telse if (e.detail < 0)\n
+\t\t\t\t\tthis.adjustValue(this.spinCfg.step);\n
+\t\t\t\t\n
+\t\t\t\te.preventDefault();\n
+\t\t\t}, false);\n
+\t\t}\n
+\t});\n
+\t\n
+\tfunction coord(el,prop) {\n
+\t\tvar c = el[prop], b = document.body;\n
+\t\t\n
+\t\twhile ((el = el.offsetParent) && (el != b)) {\n
+\t\t\tif (!$.browser.msie || (el.currentStyle.position != \'relative\'))\n
+\t\t\t\tc += el[prop];\n
+\t\t}\n
+\t\t\n
+\t\treturn c;\n
+\t}\n
+};\n
+
+
+]]></string> </value>
+        </item>
+        <item>
+            <key> <string>precondition</string> </key>
+            <value> <string></string> </value>
+        </item>
+        <item>
+            <key> <string>size</string> </key>
+            <value> <int>9261</int> </value>
+        </item>
+        <item>
+            <key> <string>title</string> </key>
+            <value> <string></string> </value>
+        </item>
+      </dictionary>
+    </pickle>
+  </record>
+</ZopeData>
diff --git a/bt5/erp5_jquery_plugin_spinbtn/PathTemplateItem/portal_skins/erp5_jquery/plugin/spinbtn/JQuerySpinBtn.min.js.xml b/bt5/erp5_jquery_plugin_spinbtn/PathTemplateItem/portal_skins/erp5_jquery/plugin/spinbtn/JQuerySpinBtn.min.js.xml
new file mode 100644
index 0000000000..4f6050cdc3
--- /dev/null
+++ b/bt5/erp5_jquery_plugin_spinbtn/PathTemplateItem/portal_skins/erp5_jquery/plugin/spinbtn/JQuerySpinBtn.min.js.xml
@@ -0,0 +1,48 @@
+<?xml version="1.0"?>
+<ZopeData>
+  <record id="1" aka="AAAAAAAAAAE=">
+    <pickle>
+      <global name="File" module="OFS.Image"/>
+    </pickle>
+    <pickle>
+      <dictionary>
+        <item>
+            <key> <string>_Cacheable__manager_id</string> </key>
+            <value> <string>http_cache</string> </value>
+        </item>
+        <item>
+            <key> <string>_EtagSupport__etag</string> </key>
+            <value> <string>ts80003855.69</string> </value>
+        </item>
+        <item>
+            <key> <string>__name__</string> </key>
+            <value> <string>JQuerySpinBtn.min.js</string> </value>
+        </item>
+        <item>
+            <key> <string>content_type</string> </key>
+            <value> <string>application/x-javascript</string> </value>
+        </item>
+        <item>
+            <key> <string>data</string> </key>
+            <value> <string encoding="cdata"><![CDATA[
+
+;$.fn.SpinButton=function(a){return this.each(function(){this.repeating=false;this.spinCfg={min:a&&!isNaN(parseFloat(a.min))?Number(a.min):null,max:a&&!isNaN(parseFloat(a.max))?Number(a.max):null,step:a&&a.step?Number(a.step):1,stepfunc:a&&a.stepfunc?a.stepfunc:false,page:a&&a.page?Number(a.page):10,upClass:a&&a.upClass?a.upClass:"up",downClass:a&&a.downClass?a.downClass:"down",reset:a&&a.reset?a.reset:this.value,delay:a&&a.delay?Number(a.delay):500,interval:a&&a.interval?Number(a.interval):100,_btn_width:20,_direction:null,_delay:null,_repeat:null,callback:a&&a.callback?a.callback:null};this.spinCfg.smallStep=a&&a.smallStep?a.smallStep:this.spinCfg.step/2;this.adjustValue=function(d){var c;if(isNaN(this.value)){c=this.spinCfg.reset}else{if($.isFunction(this.spinCfg.stepfunc)){c=this.spinCfg.stepfunc(this,d)}else{c=Number((Number(this.value)+Number(d)).toFixed(5))}}if(this.spinCfg.min!==null){c=Math.max(c,this.spinCfg.min)}if(this.spinCfg.max!==null){c=Math.min(c,this.spinCfg.max)}this.value=c;if($.isFunction(this.spinCfg.callback)){this.spinCfg.callback(this)}};$(this).addClass(a&&a.spinClass?a.spinClass:"spin-button").mousemove(function(h){var d=h.pageX||h.x;var i=h.pageY||h.y;var f=h.target||h.srcElement;var c=$(f).outerHeight()/2;var g=(d>b(f,"offsetLeft")+f.offsetWidth-this.spinCfg._btn_width)?((i<b(f,"offsetTop")+c)?1:-1):0;if(g!==this.spinCfg._direction){switch(g){case 1:$(this).removeClass(this.spinCfg.downClass).addClass(this.spinCfg.upClass);break;case -1:$(this).removeClass(this.spinCfg.upClass).addClass(this.spinCfg.downClass);break;default:$(this).removeClass(this.spinCfg.upClass).removeClass(this.spinCfg.downClass)}this.spinCfg._direction=g}}).mouseout(function(){$(this).removeClass(this.spinCfg.upClass).removeClass(this.spinCfg.downClass);this.spinCfg._direction=null;window.clearInterval(this.spinCfg._repeat);window.clearTimeout(this.spinCfg._delay)}).mousedown(function(g){if(g.button===0&&this.spinCfg._direction!=0){var d=this;var c=g.shiftKey?d.spinCfg.smallStep:d.spinCfg.step;var f=function(){d.adjustValue(d.spinCfg._direction*c)};f();d.spinCfg._delay=window.setTimeout(function(){f();d.spinCfg._repeat=window.setInterval(f,d.spinCfg.interval)},d.spinCfg.delay)}}).mouseup(function(c){window.clearInterval(this.spinCfg._repeat);window.clearTimeout(this.spinCfg._delay)}).dblclick(function(c){if($.browser.msie){this.adjustValue(this.spinCfg._direction*this.spinCfg.step)}}).keydown(function(c){switch(c.keyCode){case 38:this.adjustValue(this.spinCfg.step);break;case 40:this.adjustValue(-this.spinCfg.step);break;case 33:this.adjustValue(this.spinCfg.page);break;case 34:this.adjustValue(-this.spinCfg.page);break}}).keypress(function(c){if(this.repeating){switch(c.keyCode){case 38:this.adjustValue(this.spinCfg.step);break;case 40:this.adjustValue(-this.spinCfg.step);break;case 33:this.adjustValue(this.spinCfg.page);break;case 34:this.adjustValue(-this.spinCfg.page);break}}else{this.repeating=true}}).keyup(function(c){this.repeating=false;switch(c.keyCode){case 38:case 40:case 33:case 34:case 13:this.adjustValue(0);break}}).bind("mousewheel",function(c){if(c.wheelDelta>=120){this.adjustValue(this.spinCfg.step)}else{if(c.wheelDelta<=-120){this.adjustValue(-this.spinCfg.step)}}c.preventDefault()}).change(function(c){this.adjustValue(0)});if(this.addEventListener){this.addEventListener("DOMMouseScroll",function(c){if(c.detail>0){this.adjustValue(-this.spinCfg.step)}else{if(c.detail<0){this.adjustValue(this.spinCfg.step)}}c.preventDefault()},false)}});function b(e,g){var f=e[g],d=document.body;while((e=e.offsetParent)&&(e!=d)){if(!$.browser.msie||(e.currentStyle.position!="relative")){f+=e[g]}}return f}};
+
+]]></string> </value>
+        </item>
+        <item>
+            <key> <string>precondition</string> </key>
+            <value> <string></string> </value>
+        </item>
+        <item>
+            <key> <string>size</string> </key>
+            <value> <int>3677</int> </value>
+        </item>
+        <item>
+            <key> <string>title</string> </key>
+            <value> <string></string> </value>
+        </item>
+      </dictionary>
+    </pickle>
+  </record>
+</ZopeData>
diff --git a/bt5/erp5_jquery_plugin_spinbtn/PathTemplateItem/portal_skins/erp5_jquery/plugin/spinbtn/spinbtn_updn.png.xml b/bt5/erp5_jquery_plugin_spinbtn/PathTemplateItem/portal_skins/erp5_jquery/plugin/spinbtn/spinbtn_updn.png.xml
new file mode 100644
index 0000000000..3af5009b89
--- /dev/null
+++ b/bt5/erp5_jquery_plugin_spinbtn/PathTemplateItem/portal_skins/erp5_jquery/plugin/spinbtn/spinbtn_updn.png.xml
@@ -0,0 +1,63 @@
+<?xml version="1.0"?>
+<ZopeData>
+  <record id="1" aka="AAAAAAAAAAE=">
+    <pickle>
+      <global name="Image" module="OFS.Image"/>
+    </pickle>
+    <pickle>
+      <dictionary>
+        <item>
+            <key> <string>_Cacheable__manager_id</string> </key>
+            <value> <string>http_cache</string> </value>
+        </item>
+        <item>
+            <key> <string>_EtagSupport__etag</string> </key>
+            <value> <string>ts80003854.11</string> </value>
+        </item>
+        <item>
+            <key> <string>__name__</string> </key>
+            <value> <string>spinbtn_updn.png</string> </value>
+        </item>
+        <item>
+            <key> <string>content_type</string> </key>
+            <value> <string>image/png</string> </value>
+        </item>
+        <item>
+            <key> <string>data</string> </key>
+            <value> <string encoding="base64">iVBORw0KGgoAAAANSUhEUgAAABEAAAA2CAMAAAAWGoJGAAAAAXNSR0IArs4c6QAAAUdQTFRF6fT6
+BhUdCyk4DC4/DS9ADzhMFBMSFlFvGFd3GVx+G2GEIXikIXmmI36sI4CuJIKxJSQjJ47CKI/DKJHF
+KSgnKZPIKZbMKikoMC8uQ6bYRkVESklISqnZS0pJT05NT6zaUlJRVa/cYrXfZWRjZmVkZ2ZlZ7jg
+aWlobGtqbLrhbm1scbzid3Z1eHd2eHd3eL/jeXl4enl4e3p6fn18h8bmisjnj4+Pj8rokcvok8zo
+lJSTls3pmJeXm5qam5ubo6Oio9TspqWkqNbtqaioqamoq6uqsK+vstvvuLi3u7q6vr6+v+HywL+/
+wMC/wcHBysrKzc3M09PS1ev21+z22O3329vb5vP55/T66Ojo6eno6urq7Pb77vf78Pf78fHx8vLy
+8/Pz9PT09fX19vb29/f3+Pj4+Pv9+/3+/Pz8/f39/f7+/v7+////0stKKAAAAAF0Uk5TAEDm2GYA
+AAD0SURBVCjPY2AgHoTqBqIKREiwsUWhiMgJCAgoIAsYSck6S0sZIwTslVUCGPyVlR3hIsrKnkDS
+Q1kZLuLjC6a8/OAitrZgysYOLsLGZgUkzdjY4CI6bGxuDK5sbAYIy1QFxK1EBNSRHaQhJSWlheoN
+PWVDNJ9GukQx0AZ4C7mjCgSxMjKGIAtEczIxMXFFI4mIsnNocrCLIQSUuHmcGBy4udXgItzcpkDS
+hJsbLmJhCabMrYdfGA5gOlRUBFPyinARRkYZICnJyAgXEWRk1GfQZmQURljGw8Qiw8zEi+wgPnZ2
+dn4UN4cJcQuHo3osWDOEhHABANJgIXKLmJLiAAAAAElFTkSuQmCC</string> </value>
+        </item>
+        <item>
+            <key> <string>height</string> </key>
+            <value> <int>54</int> </value>
+        </item>
+        <item>
+            <key> <string>precondition</string> </key>
+            <value> <string></string> </value>
+        </item>
+        <item>
+            <key> <string>size</string> </key>
+            <value> <int>666</int> </value>
+        </item>
+        <item>
+            <key> <string>title</string> </key>
+            <value> <string></string> </value>
+        </item>
+        <item>
+            <key> <string>width</string> </key>
+            <value> <int>17</int> </value>
+        </item>
+      </dictionary>
+    </pickle>
+  </record>
+</ZopeData>
diff --git a/bt5/erp5_jquery_plugin_spinbtn/bt/change_log b/bt5/erp5_jquery_plugin_spinbtn/bt/change_log
new file mode 100644
index 0000000000..6c7854e368
--- /dev/null
+++ b/bt5/erp5_jquery_plugin_spinbtn/bt/change_log
@@ -0,0 +1,2 @@
+2010-11-02 gabriel
+* The initial commit
\ No newline at end of file
diff --git a/bt5/erp5_jquery_plugin_spinbtn/bt/copyright_list b/bt5/erp5_jquery_plugin_spinbtn/bt/copyright_list
new file mode 100644
index 0000000000..47af9544bf
--- /dev/null
+++ b/bt5/erp5_jquery_plugin_spinbtn/bt/copyright_list
@@ -0,0 +1 @@
+2010 (c) Nexedi SA
\ No newline at end of file
diff --git a/bt5/erp5_jquery_plugin_spinbtn/bt/dependency_list b/bt5/erp5_jquery_plugin_spinbtn/bt/dependency_list
new file mode 100644
index 0000000000..a3d3a39331
--- /dev/null
+++ b/bt5/erp5_jquery_plugin_spinbtn/bt/dependency_list
@@ -0,0 +1 @@
+erp5_jquery
\ No newline at end of file
diff --git a/bt5/erp5_jquery_plugin_spinbtn/bt/description b/bt5/erp5_jquery_plugin_spinbtn/bt/description
new file mode 100644
index 0000000000..27837eb5f3
--- /dev/null
+++ b/bt5/erp5_jquery_plugin_spinbtn/bt/description
@@ -0,0 +1 @@
+This  Business Template contains only static files of  Spinbtn Plugin. This plugin provides spin-button interface on your form.
\ No newline at end of file
diff --git a/bt5/erp5_jquery_plugin_spinbtn/bt/license b/bt5/erp5_jquery_plugin_spinbtn/bt/license
new file mode 100644
index 0000000000..3a3e12bcad
--- /dev/null
+++ b/bt5/erp5_jquery_plugin_spinbtn/bt/license
@@ -0,0 +1 @@
+GPL
\ No newline at end of file
diff --git a/bt5/erp5_jquery_plugin_spinbtn/bt/maintainer_list b/bt5/erp5_jquery_plugin_spinbtn/bt/maintainer_list
new file mode 100644
index 0000000000..38363f7303
--- /dev/null
+++ b/bt5/erp5_jquery_plugin_spinbtn/bt/maintainer_list
@@ -0,0 +1 @@
+gabriel
\ No newline at end of file
diff --git a/bt5/erp5_jquery_plugin_spinbtn/bt/revision b/bt5/erp5_jquery_plugin_spinbtn/bt/revision
new file mode 100644
index 0000000000..d8263ee986
--- /dev/null
+++ b/bt5/erp5_jquery_plugin_spinbtn/bt/revision
@@ -0,0 +1 @@
+2
\ No newline at end of file
diff --git a/bt5/erp5_jquery_plugin_spinbtn/bt/template_format_version b/bt5/erp5_jquery_plugin_spinbtn/bt/template_format_version
new file mode 100644
index 0000000000..56a6051ca2
--- /dev/null
+++ b/bt5/erp5_jquery_plugin_spinbtn/bt/template_format_version
@@ -0,0 +1 @@
+1
\ No newline at end of file
diff --git a/bt5/erp5_jquery_plugin_spinbtn/bt/template_path_list b/bt5/erp5_jquery_plugin_spinbtn/bt/template_path_list
new file mode 100644
index 0000000000..457e730688
--- /dev/null
+++ b/bt5/erp5_jquery_plugin_spinbtn/bt/template_path_list
@@ -0,0 +1,2 @@
+portal_skins/erp5_jquery/plugin/spinbtn
+portal_skins/erp5_jquery/plugin/spinbtn/**
\ No newline at end of file
diff --git a/bt5/erp5_jquery_plugin_spinbtn/bt/title b/bt5/erp5_jquery_plugin_spinbtn/bt/title
new file mode 100644
index 0000000000..819a62dc9e
--- /dev/null
+++ b/bt5/erp5_jquery_plugin_spinbtn/bt/title
@@ -0,0 +1 @@
+erp5_jquery_plugin_spinbtn
\ No newline at end of file
diff --git a/bt5/erp5_jquery_plugin_spinbtn/bt/version b/bt5/erp5_jquery_plugin_spinbtn/bt/version
new file mode 100644
index 0000000000..48360de846
--- /dev/null
+++ b/bt5/erp5_jquery_plugin_spinbtn/bt/version
@@ -0,0 +1 @@
+5.4.7
\ No newline at end of file
-- 
2.30.9