Some Question

Posted by user381937 
Some Question
July 15, 2010 01:56PM
I have a problem with Flasheff2_Flex,

I assign a effect to a panel with a Grid control on it, and apply the effect with this code:

import FlashEff2Flex;
import com.jumpeye.flashEff2.symbol.alphaBars.FESAlphaBars;
import com.jumpeye.Events.FLASHEFFEvents;

myEffect = new FlashEff2Flex();
showEffect = new FESAlphaBars();
myEffect.showTransition = showEffect;
addChild(myEffect);
myEffect._targetInstanceName = "panelListado";

<mx:Panel
layout="absolute"
id="panelListado" left="10" right="10" bottom="58" top="102">
<mx:ComboBox x="10" y="10" id="selTipoComunicacion"
dataProvider="{tiposComunicaciones.lastResult.tiposComunicaciones.tipoComunicacion}"
close="muestraTipo(event)" labelField="nombre" width="162"/>
<mx:DataGrid right="10" left="10" top="40" bottom="10"
id="dgComunicaciones"
dataProvider="{comunicaciones.lastResult.comunicaciones.comunicacion}"
itemClick="itemClickEvent(event);">
<mx:columns>
<mx:DataGridColumn headerText="Titulo Comunicacion" dataField="nombreComunicacion" id="columna"/>
</mx:columns>
</mx:DataGrid>
<mx:ComboBox x="180" y="10" id="selFormatoComunicacion"
dataProvider="{formatoComunicacion}"
close="cierraCombo(event);" />
</mx:Panel>

The problem is when i use the scrollbar of the grid, if a move the scroll to the botton of the grid, its works perfect, but when i move the scroll again to the top the panel became invisible.

Other question, when i Use Sparkle Effect with that panel:

Code Modified:

import com.jumpeye.flashEff2.symbol.sparkle.FESSparkle;

myEffect = new FlashEff2Flex();
showEffect = new FESSparkle();
myEffect.showTransition = showEffect;
addChild(myEffect);
myEffect._targetInstanceName = "panelListado";

The panel appear with animation but dissapear in a second.

I have the same problem with all effects, there is any solutions ofr that problems.

Sorry for my bad English.

Thnks
Re: Some Question
July 16, 2010 02:12PM
hello,

This problem is because of mx:panel, which removes and adds back the content when the scroll bars have to appear or vice versa. A fix for this is to use isTargetVisibleAtEnd property on FlashEff2 like this:

myEffect.isTargetVisibleAtEnd = true;


Also as a sugestion, use <mx:Panel visible="false" , so it will not appear as visible until effect in starts.

I can send you the complete source of the project were I tried, but it should work for you too.
Re: Some Question
July 19, 2010 07:56AM
Tnks Benji, it works perfectly, but i have another problem with that panel, when i scroll fast the grid, appear in the general application ugly scrollbars.

Any idea.

Tnks.
Re: Some Question
July 29, 2010 11:07AM
Hi,
I can't reproduce what you described, so if you can send me a link, I can take a look. Can you check to see if the problem still exist if you don't use the FlashEff animation? if yes, you can wait for transitionEnd event and remove the FlashEff from scene and create the initial context, otherwise we should look for other possible reasons.

It seems to be Ok, on my computer, on multiple tests.
Sorry, you do not have permission to post/reply in this forum.