Return-Path: X-Original-To: apmail-flex-commits-archive@www.apache.org Delivered-To: apmail-flex-commits-archive@www.apache.org Received: from mail.apache.org (hermes.apache.org [140.211.11.3]) by minotaur.apache.org (Postfix) with SMTP id 67910175A5 for ; Mon, 5 Jan 2015 23:21:21 +0000 (UTC) Received: (qmail 13161 invoked by uid 500); 5 Jan 2015 23:21:21 -0000 Delivered-To: apmail-flex-commits-archive@flex.apache.org Received: (qmail 13099 invoked by uid 500); 5 Jan 2015 23:21:21 -0000 Mailing-List: contact commits-help@flex.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: dev@flex.apache.org Delivered-To: mailing list commits@flex.apache.org Received: (qmail 12780 invoked by uid 99); 5 Jan 2015 23:21:21 -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, 05 Jan 2015 23:21:21 +0000 Received: by tyr.zones.apache.org (Postfix, from userid 65534) id DD791A40D55; Mon, 5 Jan 2015 23:21:20 +0000 (UTC) Content-Type: text/plain; charset="us-ascii" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit From: aharui@apache.org To: commits@flex.apache.org Date: Mon, 05 Jan 2015 23:21:32 -0000 Message-Id: In-Reply-To: <86f66907f35c4e20b6101eef0cf8cbce@git.apache.org> References: <86f66907f35c4e20b6101eef0cf8cbce@git.apache.org> X-Mailer: ASF-Git Admin Mailer Subject: [13/16] git commit: [flex-asjs] [refs/heads/develop] - when dispatching some events, target doesn't get set so fallback to using currentTarget which seems to work for now when dispatching some events, target doesn't get set so fallback to using currentTarget which seems to work for now Project: http://git-wip-us.apache.org/repos/asf/flex-asjs/repo Commit: http://git-wip-us.apache.org/repos/asf/flex-asjs/commit/98487bfc Tree: http://git-wip-us.apache.org/repos/asf/flex-asjs/tree/98487bfc Diff: http://git-wip-us.apache.org/repos/asf/flex-asjs/diff/98487bfc Branch: refs/heads/develop Commit: 98487bfc74e24ca43957c363c9fa27190d66bd7e Parents: 7487a05 Author: Alex Harui Authored: Mon Jan 5 14:28:32 2015 -0800 Committer: Alex Harui Committed: Mon Jan 5 15:21:02 2015 -0800 ---------------------------------------------------------------------- .../js/FlexJS/src/org/apache/flex/core/HTMLElementWrapper.js | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) ---------------------------------------------------------------------- http://git-wip-us.apache.org/repos/asf/flex-asjs/blob/98487bfc/frameworks/js/FlexJS/src/org/apache/flex/core/HTMLElementWrapper.js ---------------------------------------------------------------------- diff --git a/frameworks/js/FlexJS/src/org/apache/flex/core/HTMLElementWrapper.js b/frameworks/js/FlexJS/src/org/apache/flex/core/HTMLElementWrapper.js index 4eca663..be0426a 100644 --- a/frameworks/js/FlexJS/src/org/apache/flex/core/HTMLElementWrapper.js +++ b/frameworks/js/FlexJS/src/org/apache/flex/core/HTMLElementWrapper.js @@ -138,8 +138,10 @@ org.apache.flex.core.HTMLElementWrapper.prototype.removeBead = function(bead) { * @return {Object} The wrapping object. */ Event.prototype.get_target = function() { - var obj = this.target.flexjs_wrapper; - return obj; + var obj = this.target; + if (!obj) + return this.currentTarget; + return obj.flexjs_wrapper; };