Return-Path: X-Original-To: apmail-tapestry-commits-archive@minotaur.apache.org Delivered-To: apmail-tapestry-commits-archive@minotaur.apache.org Received: from mail.apache.org (hermes.apache.org [140.211.11.3]) by minotaur.apache.org (Postfix) with SMTP id 6EF82D346 for ; Mon, 17 Sep 2012 00:43:26 +0000 (UTC) Received: (qmail 40104 invoked by uid 500); 17 Sep 2012 00:43:26 -0000 Delivered-To: apmail-tapestry-commits-archive@tapestry.apache.org Received: (qmail 40071 invoked by uid 500); 17 Sep 2012 00:43:26 -0000 Mailing-List: contact commits-help@tapestry.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: dev@tapestry.apache.org Delivered-To: mailing list commits@tapestry.apache.org Received: (qmail 40064 invoked by uid 99); 17 Sep 2012 00:43:26 -0000 Received: from tyr.zones.apache.org (HELO tyr.zones.apache.org) (140.211.11.114) by apache.org (qpsmtpd/0.29) with ESMTP; Mon, 17 Sep 2012 00:43:26 +0000 Received: by tyr.zones.apache.org (Postfix, from userid 65534) id EC3C537031; Mon, 17 Sep 2012 00:43:25 +0000 (UTC) Content-Type: text/plain; charset="us-ascii" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit From: bobharner@apache.org To: commits@tapestry.apache.org X-Mailer: ASF-Git Admin Mailer Subject: [2/2] git commit: Fixed TAP5-1903 ("Bug that affects the javascript when a zone which contains an upload component is re render"). Thanks to Boris Horvat for the patch Message-Id: <20120917004325.EC3C537031@tyr.zones.apache.org> Date: Mon, 17 Sep 2012 00:43:25 +0000 (UTC) Fixed TAP5-1903 ("Bug that affects the javascript when a zone which contains an upload component is re render"). Thanks to Boris Horvat for the patch Project: http://git-wip-us.apache.org/repos/asf/tapestry-5/repo Commit: http://git-wip-us.apache.org/repos/asf/tapestry-5/commit/32efc0de Tree: http://git-wip-us.apache.org/repos/asf/tapestry-5/tree/32efc0de Diff: http://git-wip-us.apache.org/repos/asf/tapestry-5/diff/32efc0de Branch: refs/heads/master Commit: 32efc0dee12412fe6a54b6bf536b658c45941a52 Parents: aa3ee48 Author: bharner Authored: Sun Sep 16 20:20:31 2012 -0400 Committer: bharner Committed: Sun Sep 16 20:41:08 2012 -0400 ---------------------------------------------------------------------- .../apache/tapestry5/upload/components/upload.js | 12 +++++++----- 1 files changed, 7 insertions(+), 5 deletions(-) ---------------------------------------------------------------------- http://git-wip-us.apache.org/repos/asf/tapestry-5/blob/32efc0de/tapestry-upload/src/main/resources/org/apache/tapestry5/upload/components/upload.js ---------------------------------------------------------------------- diff --git a/tapestry-upload/src/main/resources/org/apache/tapestry5/upload/components/upload.js b/tapestry-upload/src/main/resources/org/apache/tapestry5/upload/components/upload.js index 274e35d..595dc39 100644 --- a/tapestry-upload/src/main/resources/org/apache/tapestry5/upload/components/upload.js +++ b/tapestry-upload/src/main/resources/org/apache/tapestry5/upload/components/upload.js @@ -17,9 +17,11 @@ * component is dynamically added to the form via Ajax. */ Tapestry.Initializer.injectedUpload = function(element) -{ - var form = $(element).form; - - form.enctype = "multipart/form-data"; - form.encoding = "multipart/form-data"; +{ + var form = $(element).form; + if (form) + { + form.enctype = "multipart/form-data"; + form.encoding = "multipart/form-data"; + } } \ No newline at end of file