Quantcast
Viewing all articles
Browse latest Browse all 801

Created Issue: NullReferenceException unhandled while opening ContextMenu in Landscape mode [10938]

Hi,

There is a bug in ContextMenu api.
Case Description:
1. Set page's SupportedOrientation as PortraitOrLandscape
2. Create a Panaroma View and have PanaromaItem in it.
3. Create a ListBox inside PanaromaItem and bind it to a string based ObservationCollection<T>
4. Create the DataTemplate in ListBox, where ListBoxItem contains one TextBlock, which is bounded to collection's data items.
5. Generate Hold Event of TextBlock (inside ListBoxItem).
6. Create and set ContextMenu at RUNTIME on Hold Event of textBlock (inside ListBoxItem).
7. Change Configuration Type to 'Release' from 'Debug'
8. Run the application in DEVICE.
9. On Hold Event in Landscape mode. NullReferenceException is caught.

Following is the stacktrace:

at Microsoft.Phone.Controls.ContextMenu.UpdateContextMenuPlacement()
at Microsoft.Phone.Controls.ContextMenu.OpenPopup(Point position)
at Microsoft.Phone.Controls.ContextMenu.OnOwnerHold(Object sender, GestureEventArgs e)
at MS.Internal.CoreInvokeHandler.InvokeEventHandler(Int32 typeIndex, Delegate handlerDelegate, Object sender, Object args)
at MS.Internal.JoltHelper.FireEvent(IntPtr unmanagedObj, IntPtr unmanagedObjArgs, Int32 argsTypeIndex, Int32 actualArgsTypeIndex, String eventName)

Viewing all articles
Browse latest Browse all 801

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>