0

Using any control from Windows Phone Toolkit in XNA/XAML hybrid project hangs application under certain conditions:

  1. Create "Windows Phone XAML and XNA App" project

  2. Add Silverlight for WP Toolkit by typing:

    Install-Package SilverlightToolkitWP -Version 4.2012.6.25
    

    in Package Manager Console

  3. In MainPage.xaml add toolkit namespace:

    <phone:PhoneApplicationPage
    ...
    xmlns:toolkit="clr-namespace:Microsoft.Phone.Controls;assembly=Microsoft.Phone.Controls.Toolkit"
    ...>
    
  4. Add any control from toolkit eg. TimePicker:

    <Grid x:Name="ContentPanel" Grid.Row="1" Margin="12,0,12,0">
        <!--Create a single button to navigate to the second page which is rendered with the XNA Framework-->
        <Button Height="100" Content="Change to game page" Click="Button_Click" />
        <toolkit:TimePicker />
    </Grid>
    
  5. Run app on WP8 device or WP8 emulator (on WP7 this problem doesn't exist)

  6. Click "Change to game page" button

  7. Lock and unlock screen or switch to another app then return.

  8. Click back button to return to MainPage

  9. Click on TimePicker and try to change time.

  10. Application isn't killed but UI is blocked

I read that WP8 runs WP7 apps in 100% compatibility but it seems this isn't true...

4

2 に答える 2

0

これは、WP8 のツールキットの正しいバージョンではありません。現時点では、 https: //nuget.org/packages/WPtoolkit (2012 年 10 月バージョン、バージョン 4.2012.10.30)を使用する必要があります。

于 2013-03-13T05:59:56.657 に答える