[royale-asjs] branch develop updated: SparkRoyale: Improve handle itemRendererFunction in DataGroup - Implement some sort of working label property in ItemRenderer
This is an automated email from the ASF dual-hosted git repository. piotrz pushed a commit to branch develop in repository https://gitbox.apache.org/repos/asf/royale-asjs.git The following commit(s) were added to refs/heads/develop by this push: new 3cfd8aa SparkRoyale: Improve handle itemRendererFunction in DataGroup - Implement some sort of working label property in ItemRenderer 3cfd8aa is described below commit 3cfd8aa4db48b0ded5527cb0ebf8d3125a87b895 Author: pzarzycki AuthorDate: Tue Dec 15 07:55:16 2020 + SparkRoyale: Improve handle itemRendererFunction in DataGroup - Implement some sort of working label property in ItemRenderer --- .../src/main/royale/spark/components/DataGroup.as | 23 ++ .../components/supportClasses/ItemRenderer.as | 27 +++--- 2 files changed, 27 insertions(+), 23 deletions(-) diff --git a/frameworks/projects/SparkRoyale/src/main/royale/spark/components/DataGroup.as b/frameworks/projects/SparkRoyale/src/main/royale/spark/components/DataGroup.as index b5ffa41..b920669 100644 --- a/frameworks/projects/SparkRoyale/src/main/royale/spark/components/DataGroup.as +++ b/frameworks/projects/SparkRoyale/src/main/royale/spark/components/DataGroup.as @@ -556,8 +556,13 @@ public class DataGroup extends GroupBase implements IItemRendererProvider, IStra */ public function get itemRendererFunction():Function // not implemeneted { -//return _itemRendererFunction; - return null; +var itemRendererFunctionBead:ItemRendererFunctionBead = getBeadByType(ItemRendererFunctionBead) as ItemRendererFunctionBead; + if (itemRendererFunctionBead) +{ +return itemRendererFunctionBead.itemRendererFunction; +} + +return null; } /** @@ -565,13 +570,13 @@ public class DataGroup extends GroupBase implements IItemRendererProvider, IStra */ public function set itemRendererFunction(value:Function):void { - var itemRendererFunctionBead:ItemRendererFunctionBead = getBeadByType(ItemRendererFunctionBead) as ItemRendererFunctionBead; - if (!itemRendererFunctionBead) - { - itemRendererFunctionBead = new ItemRendererFunctionBead(); - addBead(itemRendererFunctionBead); - } - itemRendererFunctionBead.itemRendererFunction = value; +var itemRendererFunctionBead:ItemRendererFunctionBead = getBeadByType(ItemRendererFunctionBead) as ItemRendererFunctionBead; +if (!itemRendererFunctionBead) +{ +itemRendererFunctionBead = new ItemRendererFunctionBead(); +addBead(itemRendererFunctionBead); +} +itemRendererFunctionBead.itemRendererFunction = value; } //-- diff --git a/frameworks/projects/SparkRoyale/src/main/royale/spark/components/supportClasses/ItemRenderer.as b/frameworks/projects/SparkRoyale/src/main/royale/spark/components/supportClasses/ItemRenderer.as index f599776..eb34517 100644 --- a/frameworks/projects/SparkRoyale/src/main/royale/spark/components/supportClasses/ItemRenderer.as +++ b/frameworks/projects/SparkRoyale/src/main/royale/spark/components/supportClasses/ItemRenderer.as @@ -610,12 +610,6 @@ public class ItemRenderer extends DataRenderer implements IItemRenderer //invalidateRendererState(); } } - -// not implemented -public function get label():String {return "label"} - -// not implemented -public function set label(value:String):void {} //-- // label @@ -625,9 +619,9 @@ public class ItemRenderer extends DataRenderer implements IItemRenderer * @private * Storage var for label */ - /* private var _label:String = ""; + private var _label:String = ""; -[Bindable("labelChanged")] */ +[Bindable("labelChanged")] /** * @inheritDoc @@ -639,15 +633,15 @@ public class ItemRenderer extends DataRenderer implements IItemRenderer * @playerversion AIR 1.5 * @productversion Royale 0.9.4 */ -/* public function get label():String +public function get label():String { return _label; -} */ +} /** * @private */ -/* public function set label(value:String):void + public function set label(value:String):void { if (value == _label) return; @@ -656,11 +650,16 @@ public class ItemRenderer extends DataRenderer implements IItemRenderer // Push the label down into the labelDisplay, // if it exists -if (labelDisplay) -labelDisplay.text = _label; +COMPILE::JS +{ +if (this.element) { +//labelDisplay.text = _label; +this.element.textContent = value; +} +} dispatchEvent(new
[royale-asjs] branch develop updated: CruxQuickStart Example: Update Moonshine IDE project file
This is an automated email from the ASF dual-hosted git repository. piotrz pushed a commit to branch develop in repository https://gitbox.apache.org/repos/asf/royale-asjs.git The following commit(s) were added to refs/heads/develop by this push: new 497ca70 CruxQuickStart Example: Update Moonshine IDE project file 497ca70 is described below commit 497ca7061745e14d337beb26d6a511a971b8896d Author: Piotr Zarzycki AuthorDate: Mon Dec 14 18:03:44 2020 +0100 CruxQuickStart Example: Update Moonshine IDE project file --- .../crux/CruxQuickStart/CruxQuickStart.as3proj | 74 -- 1 file changed, 40 insertions(+), 34 deletions(-) diff --git a/examples/crux/CruxQuickStart/CruxQuickStart.as3proj b/examples/crux/CruxQuickStart/CruxQuickStart.as3proj index a7dd58a..8db8a9a 100644 --- a/examples/crux/CruxQuickStart/CruxQuickStart.as3proj +++ b/examples/crux/CruxQuickStart/CruxQuickStart.as3proj @@ -19,15 +19,15 @@ --> - - - - - - + + + + + + !-- Other classes to be compiled into your SWF -- @@ -40,38 +40,41 @@ + + + + - - - - - + + + + - + + - - - - - + + - - - - + + + + + - + + - - - - - + + + + + @@ -83,6 +86,7 @@ + @@ -91,23 +95,25 @@ null False + + - + - - - + + - - -null + + + +Apple iPad null null null
[royale-asjs] branch develop updated: Fix erratic behavior of Jewel SearchFilter bead
This is an automated email from the ASF dual-hosted git repository. raudjcholo pushed a commit to branch develop in repository https://gitbox.apache.org/repos/asf/royale-asjs.git The following commit(s) were added to refs/heads/develop by this push: new b173cfb Fix erratic behavior of Jewel SearchFilter bead b173cfb is described below commit b173cfb6680be139e76a3a262dbc43d85aaeccb1 Author: Raul Nuñez AuthorDate: Mon Dec 14 16:47:34 2020 +0100 Fix erratic behavior of Jewel SearchFilter bead --- .../org/apache/royale/jewel/beads/controls/combobox/SearchFilter.as | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/frameworks/projects/Jewel/src/main/royale/org/apache/royale/jewel/beads/controls/combobox/SearchFilter.as b/frameworks/projects/Jewel/src/main/royale/org/apache/royale/jewel/beads/controls/combobox/SearchFilter.as index 89322d5..822e1fe 100644 --- a/frameworks/projects/Jewel/src/main/royale/org/apache/royale/jewel/beads/controls/combobox/SearchFilter.as +++ b/frameworks/projects/Jewel/src/main/royale/org/apache/royale/jewel/beads/controls/combobox/SearchFilter.as @@ -25,6 +25,7 @@ package org.apache.royale.jewel.beads.controls.combobox import org.apache.royale.jewel.supportClasses.textinput.TextInputBase; import org.apache.royale.jewel.List; import org.apache.royale.events.MouseEvent; +import org.apache.royale.events.IEventDispatcher; /** * The SearchFilter bead class is a specialty bead that can be used with @@ -103,7 +104,8 @@ package org.apache.royale.jewel.beads.controls.combobox override protected function onInputFocus(event:Event):void{ if (!comboView.popUpVisible) -comboView.popUpVisible = true; + IEventDispatcher((comboView as IComboBoxView).textinput).dispatchEvent(new Event(MouseEvent.CLICK)); + } protected function popUpOpenedHandler():void {
[royale-asjs] branch develop updated: Update MXRoyaleClasses.as Added ContextMenuItem
This is an automated email from the ASF dual-hosted git repository. pushminakazi pushed a commit to branch develop in repository https://gitbox.apache.org/repos/asf/royale-asjs.git The following commit(s) were added to refs/heads/develop by this push: new da2ee4a Update MXRoyaleClasses.as Added ContextMenuItem da2ee4a is described below commit da2ee4aa28f27be9910dace478eb5c3cf6868818 Author: pashminakazi <42200979+pashminak...@users.noreply.github.com> AuthorDate: Mon Dec 14 20:38:08 2020 +0500 Update MXRoyaleClasses.as Added ContextMenuItem --- frameworks/projects/MXRoyale/src/main/royale/MXRoyaleClasses.as | 1 + 1 file changed, 1 insertion(+) diff --git a/frameworks/projects/MXRoyale/src/main/royale/MXRoyaleClasses.as b/frameworks/projects/MXRoyale/src/main/royale/MXRoyaleClasses.as index 5a26b73..c1ee48a 100644 --- a/frameworks/projects/MXRoyale/src/main/royale/MXRoyaleClasses.as +++ b/frameworks/projects/MXRoyale/src/main/royale/MXRoyaleClasses.as @@ -359,6 +359,7 @@ internal class MXRoyaleClasses import mx.controls.menuClasses.IMenuDataDescriptor; IMenuDataDescriptor; import mx.controls.menuClasses.IMenuBarItemRenderer; IMenuBarItemRenderer; import mx.utils.GraphicsUtil; GraphicsUtil; +import mx.dummy.ContextMenuItem; ContextMenuItem; } }
[royale-asjs] branch develop updated: Update mx-royale-manifest.xml Added AddChild
This is an automated email from the ASF dual-hosted git repository. pushminakazi pushed a commit to branch develop in repository https://gitbox.apache.org/repos/asf/royale-asjs.git The following commit(s) were added to refs/heads/develop by this push: new 9b19659 Update mx-royale-manifest.xml Added AddChild 9b19659 is described below commit 9b196593cd16d78fb3a99b3f3ae5c84b0f01fb3a Author: pashminakazi <42200979+pashminak...@users.noreply.github.com> AuthorDate: Mon Dec 14 20:37:55 2020 +0500 Update mx-royale-manifest.xml Added AddChild --- frameworks/projects/MXRoyale/src/main/resources/mx-royale-manifest.xml | 1 + 1 file changed, 1 insertion(+) diff --git a/frameworks/projects/MXRoyale/src/main/resources/mx-royale-manifest.xml b/frameworks/projects/MXRoyale/src/main/resources/mx-royale-manifest.xml index d69dfeb..bf00bbe 100644 --- a/frameworks/projects/MXRoyale/src/main/resources/mx-royale-manifest.xml +++ b/frameworks/projects/MXRoyale/src/main/resources/mx-royale-manifest.xml @@ -221,4 +221,5 @@ +
[royale-asjs] branch develop updated: Create ContextMenuItem.as
This is an automated email from the ASF dual-hosted git repository. pushminakazi pushed a commit to branch develop in repository https://gitbox.apache.org/repos/asf/royale-asjs.git The following commit(s) were added to refs/heads/develop by this push: new 1b81780 Create ContextMenuItem.as 1b81780 is described below commit 1b8178089758f37f21c317e2d6bbbc4b5de1705a Author: pashminakazi <42200979+pashminak...@users.noreply.github.com> AuthorDate: Mon Dec 14 20:36:12 2020 +0500 Create ContextMenuItem.as --- .../src/main/royale/mx/dummy/ContextMenuItem.as| 30 ++ 1 file changed, 30 insertions(+) diff --git a/frameworks/projects/MXRoyale/src/main/royale/mx/dummy/ContextMenuItem.as b/frameworks/projects/MXRoyale/src/main/royale/mx/dummy/ContextMenuItem.as new file mode 100644 index 000..c495d9c --- /dev/null +++ b/frameworks/projects/MXRoyale/src/main/royale/mx/dummy/ContextMenuItem.as @@ -0,0 +1,30 @@ + +// +// Licensed to the Apache Software Foundation (ASF) under one or more +// contributor license agreements. See the NOTICE file distributed with +// this work for additional information regarding copyright ownership. +// The ASF licenses this file to You under the Apache License, Version 2.0 +// (the "License"); you may not use this file except in compliance with +// the License. You may obtain a copy of the License at +// +// http://www.apache.org/licenses/LICENSE-2.0 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. +// + +package mx.dummy +{ +import org.apache.royale.events.EventDispatcher; + +public class ContextMenuItem extends EventDispatcher +{ + public function ContextMenuItem(caption:String, separatorBefore:Boolean = false, enabled:Boolean = true, visible:Boolean = true) { + //super(caption, separatorBefore, enabled,visible); + } + +} +}
[royale-asjs] branch develop updated: Create AddChild.as
This is an automated email from the ASF dual-hosted git repository. pushminakazi pushed a commit to branch develop in repository https://gitbox.apache.org/repos/asf/royale-asjs.git The following commit(s) were added to refs/heads/develop by this push: new c083a0e Create AddChild.as c083a0e is described below commit c083a0e3a820e7fa348718f2fe86112dda463cb4 Author: pashminakazi <42200979+pashminak...@users.noreply.github.com> AuthorDate: Mon Dec 14 20:35:09 2020 +0500 Create AddChild.as --- .../MXRoyale/src/main/royale/mx/states/AddChild.as | 185 + 1 file changed, 185 insertions(+) diff --git a/frameworks/projects/MXRoyale/src/main/royale/mx/states/AddChild.as b/frameworks/projects/MXRoyale/src/main/royale/mx/states/AddChild.as new file mode 100644 index 000..0e68f61 --- /dev/null +++ b/frameworks/projects/MXRoyale/src/main/royale/mx/states/AddChild.as @@ -0,0 +1,185 @@ + +// +// Licensed to the Apache Software Foundation (ASF) under one or more +// contributor license agreements. See the NOTICE file distributed with +// this work for additional information regarding copyright ownership. +// The ASF licenses this file to You under the Apache License, Version 2.0 +// (the "License"); you may not use this file except in compliance with +// the License. You may obtain a copy of the License at +// +// http://www.apache.org/licenses/LICENSE-2.0 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. +// + + +package mx.states +{ +import mx.core.ContainerCreationPolicy; +import mx.core.IDeferredInstance; +import mx.core.mx_internal; +import mx.core.UIComponent; +import mx.resources.IResourceManager; +import mx.resources.ResourceManager; + +use namespace mx_internal; + +[DefaultProperty("targetFactory")] + +[ResourceBundle("states")] + +/** + * The AddChild class adds a child display object, such as a component, + * to a container as part of a view state. + * You use this class in the overrides property of the State class. + * Use the creationPolicy property to specify to create the child + * at application startup or when you change to a view state. + * + * The child does not dispatch the creationComplete event until + * it is added to a container. For example, the following code adds a + * Button control as part of a view state change: + * + * + * mx:AddChild relativeTo="{v1}" + * mx:Button id="b0" label="New Button"/ + * /mx:AddChild + * + * In the previous example, the Button control does not dispatch + * the creationComplete event until you change state and the + * Button control is added to a container. + * If the AddChild class defines both the Button and a container, such as a Canvas container, + * then the Button control dispatches the creationComplete event when it is created. + * For example, if the creationPolicy property is set to all, + * the Button control dispatches the event at application startup. + * If the creationPolicy property is set to auto, + * the Button control dispatches the event when you change to the view state. + * + * @mxml + * + * The mx:AddChild tag + * has the following attributes: + * + * + * mx:AddChild + * Properties + * target="null" + * targetFactory="null" + * creationPolicy="auto" + * position="lastChild" + * relativeTo="parent of the State object" + * / + * + * + * @see mx.states.State + * @see mx.states.RemoveChild + * @see mx.states.Transition + * @see mx.effects.AddChildAction + * + * @includeExample examples/StatesExample.mxml + * + * @langversion 3.0 + * @playerversion Flash 9 + * @playerversion AIR 1.1 + * @productversion Flex 3 + */ + public class AddChild extends UIComponent //OverrideBase +{ +//include "../core/Version.as"; + + //-- +// +// Constructor +// + //-- + +/** + * Constructor. + * + * @param relativeTo The component relative to which child is added. + * + * @param target The child object. + * All Flex components are subclasses of the UIComponent class. + * + * @param position the location in the display list of the target + * relative to the relativeTo component. Must be one of the following: + * "firstChild", "lastChild", "before" or "after". + * + * @langversion 3.0 + * @playerversion Flash 9 + * @playerversion AIR 1.1 + * @productversion
[royale-asjs] branch develop updated: Update DataGridColumn.as Added dataTipField
This is an automated email from the ASF dual-hosted git repository. pushminakazi pushed a commit to branch develop in repository https://gitbox.apache.org/repos/asf/royale-asjs.git The following commit(s) were added to refs/heads/develop by this push: new 0757b2c Update DataGridColumn.as Added dataTipField 0757b2c is described below commit 0757b2cd7d6f16420d7b870938e732977bd2c685 Author: pashminakazi <42200979+pashminak...@users.noreply.github.com> AuthorDate: Mon Dec 14 19:12:56 2020 +0500 Update DataGridColumn.as Added dataTipField --- .../mx/controls/dataGridClasses/DataGridColumn.as | 48 ++ 1 file changed, 48 insertions(+) diff --git a/frameworks/projects/MXRoyale/src/main/royale/mx/controls/dataGridClasses/DataGridColumn.as b/frameworks/projects/MXRoyale/src/main/royale/mx/controls/dataGridClasses/DataGridColumn.as index 82ba89f..575c1f4 100644 --- a/frameworks/projects/MXRoyale/src/main/royale/mx/controls/dataGridClasses/DataGridColumn.as +++ b/frameworks/projects/MXRoyale/src/main/royale/mx/controls/dataGridClasses/DataGridColumn.as @@ -950,6 +950,54 @@ public class DataGridColumn extends org.apache.royale.html.supportClasses.DataGr { _editable = value; } + + //-- + // dataTipField + //-- + + /** +* @private +* Storage for the dataTipField property. +*/ + private var _dataTipField:String; + + [Bindable("dataTipFieldChanged")] + [Inspectable(category="Advanced", defaultValue="label")] + + /** +* The name of the field in the data provider to display as the datatip. +* By default, the DataGrid control looks for a property named +* label on each data provider item and displays it. +* However, if the data provider does not contain a label +* property, you can set the dataTipField property to +* specify a different property. +* For example, you could set the value to "FullName" when a user views a +* set of people's names included from a database. +* +* @langversion 3.0 +* @playerversion Flash 9 +* @playerversion AIR 1.1 +* @productversion Flex 3 +*/ + public function get dataTipField():String + { + return _dataTipField; + } + + /** +* @private +*/ + public function set dataTipField(value:String):void + { + _dataTipField = value; + + if (owner) + { + //owner.invalidateList(); + } + + dispatchEvent(new Event("dataTipChanged")); + } } }