]> git.pld-linux.org Git - packages/jquery-thickbox.git/commitdiff
- hack for form elements; rel 11 auto/ac/jquery-thickbox-3_1-11 auto/th/jquery-thickbox-3_1-11
authorElan Ruusamäe <glen@pld-linux.org>
Thu, 10 Jun 2010 12:26:09 +0000 (12:26 +0000)
committercvs2git <feedback@pld-linux.org>
Sun, 24 Jun 2012 12:13:13 +0000 (12:13 +0000)
Changed files:
    forminput-contents.patch -> 1.1
    jquery-thickbox.spec -> 1.19

forminput-contents.patch [new file with mode: 0644]
jquery-thickbox.spec

diff --git a/forminput-contents.patch b/forminput-contents.patch
new file mode 100644 (file)
index 0000000..90bfb56
--- /dev/null
@@ -0,0 +1,25 @@
+--- jquery-thickbox-3.1/thickbox.js~   2010-06-10 15:17:03.061497743 +0300
++++ jquery-thickbox-3.1/thickbox.js    2010-06-10 15:16:25.310662166 +0300
+@@ -236,11 +236,17 @@
+                                       
+                       $("#TB_closeWindowButton").click(tb_remove);
+                       
+-                              if(url.indexOf('TB_inline') != -1){     
+-                                      $("#TB_ajaxContent").append($('#' + params['inlineId']).children());
+-                                      $("#TB_window").unload(function () {
+-                                              $('#' + params['inlineId']).append( $("#TB_ajaxContent").children() ); // move elements back when you're finished
+-                                      });
++                              if(url.indexOf('TB_inline') != -1){
++                                      var el = $('#' + params['inlineId']);
++                                      // if inline element is actually form element, take it's value
++                                      if (/textarea|input|select/.test(el[0].nodeName.toLowerCase())) {
++                                              $("#TB_ajaxContent").html('<center>'+el.val()+'</center>');
++                                      } else {
++                                              $("#TB_ajaxContent").append(el.children());
++                                              $("#TB_window").unload(function () {
++                                                      $('#' + params['inlineId']).append( $("#TB_ajaxContent").children() ); // move elements back when you're finished
++                                              });
++                                      }
+                                       tb_position();
+                                       $("#TB_load").remove();
+                                       $("#TB_window").css({display:"block"}); 
index f713eaf82e96892fe250415ea38d32819a43c959..8b3d0ffff7e200fc8f782c2121e7b6d9c52290f7 100644 (file)
@@ -5,7 +5,7 @@
 Summary:       ThickBox
 Name:          jquery-thickbox
 Version:       3.1
-Release:       10
+Release:       11
 License:       MIT / GPL
 Group:         Applications/WWW
 Source0:       http://jquery.com/demo/thickbox/thickbox-code/thickbox.js
@@ -22,6 +22,7 @@ Patch1:               no-doctype.patch
 Patch2:                animation-url.patch
 Patch3:                hide-peek-trough-obj.patch
 Patch4:                translation.patch
+Patch5:                forminput-contents.patch
 BuildRequires: js
 BuildRequires: rpmbuild(macros) >= 1.268
 BuildRequires: yuicompressor
@@ -54,6 +55,7 @@ cp -a %{SOURCE3} .
 %patch2 -p1
 %patch3 -p0
 %patch4 -p1
+%patch5 -p1
 
 # Apache 1.3 / Apache 2.x config
 cat > apache.conf <<'EOF'
This page took 0.030779 seconds and 4 git commands to generate.