WPF Animation execute twice -


i faced issue regarding animation execute twice, please check code:

<grid>          <grid.columndefinitions>              <columndefinition width="auto"/>              <columndefinition width="*"/>              <columndefinition width="auto"/>          </grid.columndefinitions>            <listview x:name="lsthandled" grid.column="0" visibility="visible">              <listviewitem>jimmy</listviewitem>              <listviewitem>jimmy</listviewitem>              <listviewitem>jimmy</listviewitem>              <listviewitem>jimmy</listviewitem>              <listviewitem>jimmy</listviewitem>              <listviewitem>jimmy</listviewitem>              <listviewitem>jimmy</listviewitem>              <listviewitem>jimmy</listviewitem>              <listview.triggers>                  <eventtrigger routedevent="listview.mouseenter">                      <beginstoryboard>                          <storyboard>                              <thicknessanimation                                  storyboard.targetname="spall"                                  storyboard.targetproperty="(stackpanel.margin)"                                  from="-100,0,0,0" to="0,0,0,0"                                  autoreverse="false"                                  duration="0:0:1"/>                          </storyboard>                      </beginstoryboard>                  </eventtrigger>              </listview.triggers>          </listview>            <stackpanel x:name="spall" grid.column="0" width="100" margin="-100,0,0,0" orientation="horizontal">              <listview x:name="handled">                  <listviewitem>hello</listviewitem>                  <listviewitem>hello</listviewitem>                  <listviewitem>hello</listviewitem>                  <listviewitem>hello</listviewitem>                  <listviewitem>hello</listviewitem>                  <listviewitem>hello</listviewitem>                  <listviewitem>hello</listviewitem>                  <listviewitem>hello</listviewitem>              </listview>              <listview x:name="unhandled">                  <listviewitem>world</listviewitem>                  <listviewitem>world</listviewitem>                  <listviewitem>world</listviewitem>                  <listviewitem>world</listviewitem>                  <listviewitem>world</listviewitem>                  <listviewitem>world</listviewitem>                  <listviewitem>world</listviewitem>                  <listviewitem>world</listviewitem>              </listview>              <stackpanel.triggers>                  <eventtrigger routedevent="stackpanel.mouseleave">                      <beginstoryboard>                          <storyboard>                              <thicknessanimation                                  storyboard.targetname="spall"                                  storyboard.targetproperty="(stackpanel.margin)"                                  from="0,0,0,0" to="-100,0,0,0"                                  autoreverse="false"                                  duration="0:0:1"/>                                                        </storyboard>                      </beginstoryboard>                  </eventtrigger>              </stackpanel.triggers>          </stackpanel>      </grid>

when mouse leave "spall" stackpanel. fired mouse enter event listview. how avoid issue?

thanks lot!

they both in same grid column overlap , enter/leave events :) separate them in ui.


Popular posts from this blog

c# - ODP.NET Oracle.ManagedDataAccess causes ORA-12537 network session end of file -

matlab - Compression and Decompression of ECG Signal using HUFFMAN ALGORITHM -

utf 8 - split utf-8 string into bytes in python -