Return-Path: X-Original-To: archive-asf-public-internal@cust-asf2.ponee.io Delivered-To: archive-asf-public-internal@cust-asf2.ponee.io Received: from cust-asf.ponee.io (cust-asf.ponee.io [163.172.22.183]) by cust-asf2.ponee.io (Postfix) with ESMTP id 1B537200D4B for ; Mon, 27 Nov 2017 12:40:24 +0100 (CET) Received: by cust-asf.ponee.io (Postfix) id 19DF0160C13; Mon, 27 Nov 2017 11:40:24 +0000 (UTC) Delivered-To: archive-asf-public@cust-asf.ponee.io Received: from mail.apache.org (hermes.apache.org [140.211.11.3]) by cust-asf.ponee.io (Postfix) with SMTP id 378BE160C02 for ; Mon, 27 Nov 2017 12:40:23 +0100 (CET) Received: (qmail 86900 invoked by uid 500); 27 Nov 2017 11:40:22 -0000 Mailing-List: contact dev-help@royale.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: dev@royale.apache.org Delivered-To: mailing list dev@royale.apache.org Received: (qmail 86888 invoked by uid 99); 27 Nov 2017 11:40:21 -0000 Received: from pnap-us-west-generic-nat.apache.org (HELO spamd3-us-west.apache.org) (209.188.14.142) by apache.org (qpsmtpd/0.29) with ESMTP; Mon, 27 Nov 2017 11:40:21 +0000 Received: from localhost (localhost [127.0.0.1]) by spamd3-us-west.apache.org (ASF Mail Server at spamd3-us-west.apache.org) with ESMTP id 2030418030B for ; Mon, 27 Nov 2017 11:40:21 +0000 (UTC) X-Virus-Scanned: Debian amavisd-new at spamd3-us-west.apache.org X-Spam-Flag: NO X-Spam-Score: 0.379 X-Spam-Level: X-Spam-Status: No, score=0.379 tagged_above=-999 required=6.31 tests=[DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, RCVD_IN_DNSWL_NONE=-0.0001, RCVD_IN_MSPIKE_H3=-0.01, RCVD_IN_MSPIKE_WL=-0.01, RCVD_IN_SORBS_SPAM=0.5, SPF_PASS=-0.001] autolearn=disabled Authentication-Results: spamd3-us-west.apache.org (amavisd-new); dkim=pass (2048-bit key) header.d=gmail.com Received: from mx1-lw-eu.apache.org ([10.40.0.8]) by localhost (spamd3-us-west.apache.org [10.40.0.10]) (amavisd-new, port 10024) with ESMTP id NA3FO_cqWjn4 for ; Mon, 27 Nov 2017 11:40:19 +0000 (UTC) Received: from mail-wm0-f65.google.com (mail-wm0-f65.google.com [74.125.82.65]) by mx1-lw-eu.apache.org (ASF Mail Server at mx1-lw-eu.apache.org) with ESMTPS id 47A755F216 for ; Mon, 27 Nov 2017 11:40:19 +0000 (UTC) Received: by mail-wm0-f65.google.com with SMTP id r68so33651525wmr.3 for ; Mon, 27 Nov 2017 03:40:19 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=mime-version:subject:from:in-reply-to:date :content-transfer-encoding:message-id:references:to; bh=wWTTfhQ1FkC45rVlr0nmN/0FeZm3ViMWBd9cRutOF34=; b=D2oJfnAV0DvXrE193b/YDvUGNpv9VtGd4UUO6d1tjv3w3F5q8CfxlbQ2wOsYHVcAxO bozQF6EpPnAmGZr0xPIj9cetd9vTksiAgrF2gfA3PJQ62RlMjc0W6h1xmL3OZurMN6s9 zo8GFhyK5SvOo+9agKDA9cGXbby1Sj49aZ90FZY5xUQ08h0YMxDrNOvCQqOvlvKudSQ5 5b+ULOE1zUE+aEhXGm9BJwYgGgVyZ9W95JhBvx0J0pTtsXm2pxUdg94MnTful1NUR7Ts e0DgfwS/8R50bqzhs8eWKnMWtrXZmbtWBGmqOnQet9aTfN64NETX6RXf9A5VRApZFi/J bXVA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:mime-version:subject:from:in-reply-to:date :content-transfer-encoding:message-id:references:to; bh=wWTTfhQ1FkC45rVlr0nmN/0FeZm3ViMWBd9cRutOF34=; b=pzXDhjmEzdp7aqmTypgafgXm2wZ6WU00iluoFQ6MlovrHbCaFqQK7WlfiWzqhjE30V cPqEvnNvuAnmtiJxZvzvSHNu2Q2/cNSBLeXREk2ks/SEcgjxdcVXZmUkGzSQnSHtvwrB HilLDRfVM/s/0duSjlLoNnsl4RLH+iJvw+f3GD9I+dU/Buzq16pMu9e0YB61p4gRhuiB YsTjse3t317/u8fcoDk6pZQ7z3rbb3Cb18V1s/NK0CkBFcT8U1MdLJQWb21rktdhXODM JYEGxkEUswjM5CFZeGW26NhQMf8lh6U+7E6qftmUIbXHcgemlolSRmkZC0DywDHw8rYm Nc3g== X-Gm-Message-State: AJaThX60H0EKQhJpezqY9bjDSu8+Qnpa5gNSAm8eVXleRaHbh/vymRKd M1O4BG7Swu4KbILHpa8XsZvOyjGt X-Google-Smtp-Source: AGs4zMad6LPV06gr4XJKpW9Vk9m9mfyoo4wfVVeZMraWTvQhdt8jTh022GN48/cPAmrZjIVoxf/8gA== X-Received: by 10.28.229.19 with SMTP id c19mr14858064wmh.156.1511782818383; Mon, 27 Nov 2017 03:40:18 -0800 (PST) Received: from [10.0.0.26] ([82.166.23.15]) by smtp.gmail.com with ESMTPSA id n12sm2138176wrn.76.2017.11.27.03.40.17 for (version=TLS1 cipher=ECDHE-RSA-AES128-SHA bits=128/128); Mon, 27 Nov 2017 03:40:17 -0800 (PST) Content-Type: text/plain; charset=utf-8 Mime-Version: 1.0 (Mac OS X Mail 8.2 \(2104\)) Subject: Re: [royale-asjs] branch develop updated: Fixed event dispatching on tba view change From: Harbs In-Reply-To: <151178147455.7244.16892257237469906462@gitbox.apache.org> Date: Mon, 27 Nov 2017 13:40:14 +0200 Content-Transfer-Encoding: quoted-printable Message-Id: References: <151178147455.7244.16892257237469906462@gitbox.apache.org> To: dev@royale.apache.org X-Mailer: Apple Mail (2.2104) archived-at: Mon, 27 Nov 2017 11:40:24 -0000 I=E2=80=99m not sure that viewChanged is the best event to be = dispatching here. It turns out that viewChanged is dispatched in two unrelated cases: 1. When the IViewManagerView is assigned to the ViewManagerBase. 2. When the current view is set by the IViewManagerView. The way it is, it=E2=80=99s currently difficult to differentiate between = the two cases. It feels like the correct event to be dispatching for case 2 is = =E2=80=9CcurrentViewChanged=E2=80=9D or =E2=80=9CactiveViewChanged=E2=80=9D= or =E2=80=9CselectedViewChanged=E2=80=9D. Thoughts? Harbs > On Nov 27, 2017, at 1:17 PM, harbs@apache.org wrote: >=20 > This is an automated email from the ASF dual-hosted git repository. >=20 > harbs pushed a commit to branch develop > in repository https://gitbox.apache.org/repos/asf/royale-asjs.git >=20 >=20 > The following commit(s) were added to refs/heads/develop by this push: > new 6711a8d Fixed event dispatching on tba view change > 6711a8d is described below >=20 > commit 6711a8d137ecca2d4dfaa48f1c0689282157df47 > Author: Harbs > AuthorDate: Mon Nov 27 13:17:42 2017 +0200 >=20 > Fixed event dispatching on tba view change >=20 > Removed an extra layoutNeeded > Dispatch viewChanged > --- > .../org/apache/royale/mobile/beads/TabbedViewManagerView.as | 9 = +++++++-- > 1 file changed, 7 insertions(+), 2 deletions(-) >=20 > diff --git = a/frameworks/projects/Mobile/src/main/royale/org/apache/royale/mobile/bead= s/TabbedViewManagerView.as = b/frameworks/projects/Mobile/src/main/royale/org/apache/royale/mobile/bead= s/TabbedViewManagerView.as > index 64c7b80..bef33ee 100644 > --- = a/frameworks/projects/Mobile/src/main/royale/org/apache/royale/mobile/bead= s/TabbedViewManagerView.as > +++ = b/frameworks/projects/Mobile/src/main/royale/org/apache/royale/mobile/bead= s/TabbedViewManagerView.as > @@ -104,6 +104,11 @@ package org.apache.royale.mobile.beads > =09 > private var _currentView:IViewManagerView; > =09 > + /** > + * @royaleignorecoercion org.apache.royale.core.UIBase > + * @royaleignorecoercion = org.apache.royale.mobile.IViewManagerView > + * @royaleignorecoercion = org.apache.royale.mobile.IViewManager > + */ > protected function showViewByIndex(index:int):void > { > var model:ViewManagerModel =3D = _strand.getBeadByType(IBeadModel) as ViewManagerModel; > @@ -117,9 +122,8 @@ package org.apache.royale.mobile.beads > =09 > COMPILE::JS { > if (_currentView) { > - = UIBase(_currentView).element.style["flex-grow"] =3D "1"; > + (_currentView as = UIBase).element.style["flex-grow"] =3D "1"; > } > - getHost().dispatchEvent(new = Event("layoutNeeded")); > } > COMPILE::SWF { > if (UIBase(_currentView).style =3D=3D = null) { > @@ -131,6 +135,7 @@ package org.apache.royale.mobile.beads > =09 > // Now that the view has changed, refresh the = layout on this component. > getHost().dispatchEvent(new = Event("layoutNeeded")); > + getHost().dispatchEvent(new = Event("viewChanged")); > } > protected function = insertCurrentView(view:IViewManagerView):void{ > getHost().addElementAt(view,(navigationBar ? 1 : = 0)); >=20 > --=20 > To stop receiving notification emails like this one, please contact > ['"commits@royale.apache.org" '].