This is a migrated thread and some comments may be shown as answers.

How to disable animation for CellPointerOver event?

5 Answers 75 Views
Calendar
This is a migrated thread and some comments may be shown as answers.
k
Top achievements
Rank 1
k asked on 01 Feb 2016, 08:41 AM

Hi,

How can I disable animation of a calendar cell when the mouse goes over it?

 

Thanks

Krzysztof 

 

5 Answers, 1 is accepted

Sort by
0
k
Top achievements
Rank 1
answered on 01 Feb 2016, 02:13 PM

I will try to describe my problem more precisely.

I use RadCalendar with a custom style selector:

<telerik:RadCalendar x:Name ="Calendar"
             DisplayMode="YearView"
                     CellStyleSelector="{StaticResource CustomCalendarStyleSelector}"                            
                    />

 

public class CustomCalendarStyleSelector : CalendarCellStyleSelector
{
 
    public DataTemplate MonthTemplate { get; set; }
 
    protected override void SelectStyleCore(CalendarCellStyleContext context, RadCalendar container)
    {
         context.CellTemplate = MonthTemplate;
         context.ApplyCellTemplateDecorations = false;
    }
     
}

My template contains an image, and when the  mouse pointer goes over image, it blinks, as it would be redrawn or animated. Is it possible to get rid of this blinking?

Here is my DataTemplate:

<templates:CustomCalendarStyleSelector x:Key="CustomCalendarStyleSelector" >
 
    <templates:CustomCalendarStyleSelector.MonthTemplate>
        <DataTemplate>
            <Image Source="/Assets/Icons/illness_64.png"
              HorizontalAlignment="Center"
              VerticalAlignment="Center"
              Stretch="None"                            
                       >
            </Image>
        </DataTemplate>
    </templates:CustomCalendarStyleSelector.MonthTemplate>
 
</templates:CustomCalendarStyleSelector>

0
Pavel R. Pavlov
Telerik team
answered on 04 Feb 2016, 08:15 AM
Hello,

I believe you need to customize the RadCalendar.PointerOverCellStyle. In your specific scenario you can try setting it to x:Null. More about customizing the cell styling can be found in our documentation.

Please give this approach a try and let us know if you need any further assistance.

Regards,
Pavel R. Pavlov
Telerik
Do you want to have your say when we set our development plans? Do you want to know when a feature you care about is added or when a bug fixed? Explore the Telerik Feedback Portal and vote to affect the priority of the items
0
k
Top achievements
Rank 1
answered on 04 Feb 2016, 08:28 AM

Well, i've tried that, but without success.

The problem occurs only when DisplayMode is set to YearView and the app is deployed to local machine. On the Mobile Emulator I could not reproduce it. Strange ...

Regards

Krzysztof

 

 

0
Pavel R. Pavlov
Telerik team
answered on 04 Feb 2016, 09:32 AM
Hi Krzysztof,

After further investigation we found the cause of this issue. It turned out that the CellTemplate of the affected (highlighted) cell is reapplied on every arrange cycle. This fact in combination with the fact that the images are loading a bit slower leads to the reported behavior. We logged this issue in our backlog for fixing in our future releases. As a small sign of compensation I updated your Telerik account accordingly.

Regards,
Pavel R. Pavlov
Telerik
Do you want to have your say when we set our development plans? Do you want to know when a feature you care about is added or when a bug fixed? Explore the Telerik Feedback Portal and vote to affect the priority of the items
0
lucky
Top achievements
Rank 1
answered on 02 Apr 2020, 08:13 AM
Turning off animations won’t necessarily speed up your system, however it can cause certain activities to feel quicker. Obviously, in case you're on an exceptionally old framework, you may see a progressively perceptible speed increment, however the vast majority of this is about restorative inclination.
Tags
Calendar
Asked by
k
Top achievements
Rank 1
Answers by
k
Top achievements
Rank 1
Pavel R. Pavlov
Telerik team
lucky
Top achievements
Rank 1
Share this question
or