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

Creating RadWindow from RadMediaPlayer causes errant behavior

5 Answers 63 Views
MediaPlayer
This is a migrated thread and some comments may be shown as answers.
Mark
Top achievements
Rank 1
Mark asked on 03 Nov 2011, 05:12 PM
I have a custom RadMediaPlayer template that adds a button to the player's control bar, which creates a RadWindow when clicked.  This window will allow my users to view and edit additional information about the video that is playing.  However, when the RadWindow is created and shown, any further interactions with the player cause the entire player to be unloaded and reloaded.  Are there any easy workarounds for this issue, or do I need to use a different control for this?

5 Answers, 1 is accepted

Sort by
0
Tina Stancheva
Telerik team
answered on 08 Nov 2011, 12:44 PM
Hi Mark,

I added a RadButton in the RadMediaPlayerWrapper default ControlTemplate and handled its Click event to open a RadWindow control. However,. I wasn't able to reproduce the issue you described. Can you please have a look at the attached sample and let me know if I'm missing something. Also, can you tell us the list of steps that lead to reproducing the issue?

Thank you in advance for your cooperation.

Greetings,
Tina Stancheva
the Telerik team

Explore the entire Telerik portfolio by downloading the Ultimate Collection trial package. Get it now >>

0
Mark
Top achievements
Rank 1
answered on 08 Nov 2011, 10:48 PM
Hello Tina,

Thank you for your reply.  Using your sample, I have been able to determine that this issue seems to only happen when the MediaPlayer is contained in a floating RadPane, which is necessary for our application.  I have modified the sample project you provided to demonstrate this, and since I cannot upload the project the modified XAML is below.  Leaving the window docked as it is initially, if you press play, click the button you added, and then press pause, it behaves as expected.  However, if you make the window floating and do the same thing, pressing the pause button causes the MediaPlayer to unload, reload, and begin the playback of the video at the beginning.  

<Grid>
    <telerik:RadDocking>
        <telerik:RadDocking.DocumentHost>
            <telerik:RadPaneGroup>
                <telerik:RadPane Header="RadPaneHeader">
                    <telerik:RadPane.Content>
                        <telerik:RadMediaPlayer x:Name="player"
                            AutoPlay="False" Style="{StaticResource RadMediaPlayerStyle}">
 
                            <telerik:RadMediaItem Source="http://ecn.channel9.msdn.com/o9/pdc09/wmv/CL16.wmv" VideoStretch="None">
                                <telerik:RadMediaItem.Header>
                                    <StackPanel Orientation="Horizontal">
                                        <StackPanel Margin="8">
                                            <TextBlock FontWeight="Normal" Text="Name: " />
                                            <TextBlock Margin="4"
                                   FontWeight="Bold"
                                   Text="Optimizing for Performance with the Windows Performance Toolkit" />
                                        </StackPanel>
                                        <StackPanel Margin="8">
                                            <TextBlock FontWeight="Normal" Text="Genre: " />
                                            <TextBlock Margin="4"
                                   FontWeight="Bold"
                                   Text="Tech Video" />
                                        </StackPanel>
                                    </StackPanel>
                                </telerik:RadMediaItem.Header>
                            </telerik:RadMediaItem>
 
                            <telerik:RadMediaItem Source="http://ecn.channel9.msdn.com/o9/pdc09/wmv/CL06.wmv" VideoStretch="None">
                                <telerik:RadMediaItem.Header>
                                    <StackPanel Orientation="Horizontal">
                                        <StackPanel Margin="8">
                                            <TextBlock FontWeight="Normal" Text="Name: " />
                                            <TextBlock Margin="4"
                                   FontWeight="Bold"
                                   Text="Networking and Web Services in Silverlight" />
                                        </StackPanel>
                                        <StackPanel Margin="8">
                                            <TextBlock FontWeight="Normal" Text="Genre: " />
                                            <TextBlock Grid.Column="1"
                                   Margin="4"
                                   FontWeight="Bold"
                                   Text="Tech Video" />
                                        </StackPanel>
                                    </StackPanel>
                                </telerik:RadMediaItem.Header>
                            </telerik:RadMediaItem>
                        </telerik:RadMediaPlayer>
                    </telerik:RadPane.Content>
                </telerik:RadPane>
            </telerik:RadPaneGroup>
        </telerik:RadDocking.DocumentHost>
    </telerik:RadDocking>
</Grid>
0
Petar Mladenov
Telerik team
answered on 11 Nov 2011, 06:17 PM
Hi Mark,

 Thank you for your feedback. We managed to reproduce this but we'll need some more time in order to investigate it deeper and provide you with a possible solution/workaround. We'll write you back on Monday.
Thank you for your understanding.

Best wishes,
Petar Mladenov
the Telerik team

Explore the entire Telerik portfolio by downloading the Ultimate Collection trial package. Get it now >>

0
Mark
Top achievements
Rank 1
answered on 08 Dec 2011, 10:57 PM
I never heard back from anyone regarding this issue, so I am wondering if there are any known workarounds or plans to resolve this.  
0
Petar Mladenov
Telerik team
answered on 12 Dec 2011, 02:13 PM
Hello Mark,

 Please accept my apologies for not replying as I had promised before. We did not find a workaround for this issue and we logged it as a bug in our RAdMediaPlayer . We also updated your telerik account points as a thanks for your cooperation.

All the best,
Petar Mladenov
the Telerik team

Explore the entire Telerik portfolio by downloading the Ultimate Collection trial package. Get it now >>

Tags
MediaPlayer
Asked by
Mark
Top achievements
Rank 1
Answers by
Tina Stancheva
Telerik team
Mark
Top achievements
Rank 1
Petar Mladenov
Telerik team
Share this question
or