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

PaginationControl and SlideView OverlayContent

6 Answers 47 Views
PaginationControl
This is a migrated thread and some comments may be shown as answers.
This question is locked. New answers and comments are not allowed.
Mike
Top achievements
Rank 1
Mike asked on 09 May 2014, 01:29 PM
Hi.

Im am using the Pagination Control with the SlideView and Described in the Documentation. This is working great so far. Now I also activated the OverlayContent in my SlideView. Also this is working fine as expected. But not I have an issue. Because my overlay has a transparency the paging indicator (dots ins sample app) is still visible in background. Is there a possibility to toggle paging indicator visibility depending on showing the overlay?

Best regards Mike.

6 Answers, 1 is accepted

Sort by
0
Todor
Telerik team
answered on 14 May 2014, 11:56 AM
Hello Mike,

Thank you for writing.

There is no way to determine whether the overlay is currently displayed or not, but since you know when this happens (on Tap), you can change the pagination control's visibility when RadSlideView's Tap event occurs.

Let us know if you need further assistance.

Regards,
Todor
Telerik
 

Check out the Telerik Platform - the only platform that combines a rich set of UI tools with powerful cloud services to develop web, hybrid and native mobile apps.

 
0
Mike
Top achievements
Rank 1
answered on 16 May 2014, 10:18 AM
Hi.

Thanx for your reply.

Now I check the radslideview's tap event as you suggested

GalleryRadSlideView.Tap += GalleryView_Tap;

Inside I am just toggle the Pagination visibility.
So far so good, but when I am tapping inside the Overlay Content the Overlay will not be hidden, only if I tab outside.
Therefore I wanted to check the radSlideView's 

IsOverlayContentDisplayed = true

But this is always true.
Is there a possibility to check if overlay is shown or not to decice if I should show or hide the paging?
0
Todor
Telerik team
answered on 21 May 2014, 08:34 AM
Hello Mike,

Thank you for writing back.

I'm not sure I understand correctly the scenario where the issue occurs. I have attached a sample which demonstrates the approach that I mentioned.

On a side note, IsOverlayContentDisplayed is not always true. For example you can see that if the ManipulationStarted event occurs when the overlay is not displayed, the value of this property is correctly still false. However by the time the Tap event occurs, its value is already changed to true.

Please have a look at the sample and let me know if this approach works for you. If not, please elaborate a bit more about the scenario when it is not applicable.

Regards,
Todor
Telerik
 

Check out the Telerik Platform - the only platform that combines a rich set of UI tools with powerful cloud services to develop web, hybrid and native mobile apps.

 
0
Mike
Top achievements
Rank 1
answered on 23 May 2014, 09:18 AM
Hello.

Thank you very much for your sample. I checked it out and I did it the same way.
The issue seems to be my overlay template definition. I have a ScrollViewer
around the textblock, thus I can show long descriptions in the overlay and scroll inside.
This is the issue. When I tap inside the scroll viewer the overlay keeps visible, but the paging toggles.
I did this change in your sample, so you can test and see what I mean.
0
Mike
Top achievements
Rank 1
answered on 23 May 2014, 09:20 AM
Hmm I only can attach images - no zip files.
So I post the code here:

<telerikPrimitives:RadSlideView.OverlayContentTemplate>
     <DataTemplate>
         <Grid Opacity="0.5"
               VerticalAlignment="Center"
               Background="Gray">
             <ScrollViewer Grid.Row="1" Height="170" VerticalScrollBarVisibility="Auto">
                 <TextBlock Text="{Binding}"
                 FontSize="{StaticResource PhoneFontSizeLarge}"
                 FontFamily="{StaticResource PhoneFontFamilySemiLight}"
                 VerticalAlignment="Top"/>
             </ScrollViewer>
         </Grid>
     </DataTemplate>
 </telerikPrimitives:RadSlideView.OverlayContentTemplate>
0
Todor
Telerik team
answered on 28 May 2014, 10:25 AM
Hello Mike,

Thank you for getting back to us.

The ScrollViewer consumes the manipulation so it doesn't reach to RadSlideView and thus the overlay is not hidden. You can change this by manually handling when to show and hide the overlay by using RadSlideView's public methods. Here is the change that I made to the sample project:

private void OnSlideViewTap(object sender, System.Windows.Input.GestureEventArgs e)
{
    if(pagination.Visibility == System.Windows.Visibility.Visible)
    {
        slideView.ShowOverlayContent();
        pagination.Visibility = System.Windows.Visibility.Collapsed;
    }
    else
    {
        slideView.HideOverlayContent();
        pagination.Visibility = System.Windows.Visibility.Visible;
    }
}

Let me know if you need further assistance.

Regards,
Todor
Telerik
 

Check out the Telerik Platform - the only platform that combines a rich set of UI tools with powerful cloud services to develop web, hybrid and native mobile apps.

 
Tags
PaginationControl
Asked by
Mike
Top achievements
Rank 1
Answers by
Todor
Telerik team
Mike
Top achievements
Rank 1
Share this question
or