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

Hide playlist button

6 Answers 92 Views
MediaPlayer
This is a migrated thread and some comments may be shown as answers.
Edo Cof
Top achievements
Rank 1
Edo Cof asked on 21 May 2010, 07:15 PM
I can not hide playlist button. I don't see any need to show playlist button if there is just one item in playlist.

I try to set IsPlaylistVisible to false, but the button is still visible.

I am talking the button right next to FullScreen.

6 Answers, 1 is accepted

Sort by
0
Tina Stancheva
Telerik team
answered on 27 May 2010, 10:05 AM
Hi Edo Cof,

in order to hide the Playlist Button you will need to edit the template of the RadMediaPlayer and remove the following lines from the RadMediaPlayerStyle:
<telerik:RadButton VerticalAlignment="Center" Width="42" Padding="5"
            Template="{StaticResource MediaPlayer_Button}"
            Command="telerikMedia:MediaCommands.TogglePlaylist">
    <StackPanel>
        <Rectangle Fill="{StaticResource MediaPlayer_ButtonBackgroundPath}" Stroke="{StaticResource MediaPlayer_ButtonBorderPath}" StrokeThickness="1" Height="3" Width="12"/>
        <Rectangle Fill="{StaticResource MediaPlayer_ButtonBackgroundPath}" Stroke="{StaticResource MediaPlayer_ButtonBorderPath}" StrokeThickness="1" Height="3" Margin="0 1" Width="12"/>
        <Rectangle Fill="{StaticResource MediaPlayer_ButtonBackgroundPath}" Stroke="{StaticResource MediaPlayer_ButtonBorderPath}" StrokeThickness="1" Height="3" Width="12"/>
    </StackPanel>
</telerik:RadButton>

I prepared an example illustrating this approach - I commented the above lines in it. Please take a look at it and let me know if it works for you.

Greetings,
Tina Stancheva
the Telerik team

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 Public Issue Tracking system and vote to affect the priority of the items.
0
Brian Azzi
Top achievements
Rank 2
answered on 24 Aug 2011, 07:28 PM
Maybe this is a silly question, but how do I access that template / edit it? I don't have access to Blend, can this be done in VS 2010? (Sorry if it's a new user issue *grin*).

Thanks,
-Brian
0
Tina Stancheva
Telerik team
answered on 26 Aug 2011, 09:07 AM
Hi Brian Azzi,

You can find the xaml file defining the default ControlTemplate of the RadMediaPlayer in the Themes solution in your installation folder. This article will get you started on how to modify a Telerik built-in theme.

I also attached the latest style of the RadMediaPlayer and the RadMediaItem controls from the default Office_Black theme. I hope it helps you.

Kind regards,
Tina Stancheva
the Telerik team

Thank you for being the most amazing .NET community! Your unfailing support is what helps us charge forward! We'd appreciate your vote for Telerik in this year's DevProConnections Awards. We are competing in mind-blowing 20 categories and every vote counts! VOTE for Telerik NOW >>

0
Brian Azzi
Top achievements
Rank 2
answered on 26 Aug 2011, 01:53 PM
Very helpful information, thank you. : )  
0
Brian Azzi
Top achievements
Rank 2
answered on 29 Aug 2011, 07:24 PM
Ok... so I'm hiding the playlist button successfully on the player, but it still shows up when I switch to fullscreen mode. What template would I override to hide it in fullscreen mode as well?
0
Kiril Stanoev
Telerik team
answered on 01 Sep 2011, 02:35 PM
Hello Brian,

Once you edit the style of RadMediaPlayer, you need to edit the style of PopupMediaPlayerWrapper as well. While in PopupMediaPlayerWrapper, you should navigate to LayoutRoot > VideoControlsPanel > StackPanel > PlaylistToggle. The PlaylistToggle is the button you want to collapse.



Please have a look at the attached project for further reference.

Kind regards,
Kiril Stanoev
the Telerik team

Thank you for being the most amazing .NET community! Your unfailing support is what helps us charge forward! We'd appreciate your vote for Telerik in this year's DevProConnections Awards. We are competing in mind-blowing 20 categories and every vote counts! VOTE for Telerik NOW >>

Tags
MediaPlayer
Asked by
Edo Cof
Top achievements
Rank 1
Answers by
Tina Stancheva
Telerik team
Brian Azzi
Top achievements
Rank 2
Kiril Stanoev
Telerik team
Share this question
or