StackOverflowException with data-bound context menus

Ribbon for WPF Forum

Posted 10 years ago by Phil Devaney - Senior Software Engineer, Serck Controls Ltd
Version: 9.1.0505
Platform: Windows Forms Controls
Environment: Windows Vista (64-bit)
Avatar
I've been using the DataTemplates described in this post http://www.actiprosoftware.com/Support/Forums/ViewForumTopic.aspx?ForumTopicID=3495 to display context menus that are built using data-binding, and most of the time its works fine. However I have recently discovered a bug that causes a StackOverflowException with the following repeated call stack:

etc. etc.
System.Windows.DependencyObject.SetValue(dp, value)    
ActiproSoftware.Windows.Controls.Ribbon.Controls.Primitives.PopupButtonBase.IsPopupOpen.set(value = true)    
ActiproSoftware.Windows.Controls.Ribbon.UI.PopupControlService.f(A_0 = {ActiproSoftware.Windows.Controls.Ribbon.Controls.PopupButton})    
ActiproSoftware.Windows.Controls.Ribbon.UI.PopupControlService.b(A_0 = {ActiproSoftware.Windows.Controls.Ribbon.Controls.PopupButton}, A_1 = {System.Windows.DependencyPropertyChangedEventArgs})    
System.Windows.DependencyObject.OnPropertyChanged(e)    
System.Windows.FrameworkElement.OnPropertyChanged(e = {System.Windows.DependencyPropertyChangedEventArgs})    
ActiproSoftware.Windows.Controls.Ribbon.Controls.Primitives.ControlBase.OnPropertyChanged(e = {System.Windows.DependencyPropertyChangedEventArgs})    
ActiproSoftware.Windows.Controls.Ribbon.Controls.Primitives.ButtonBase.OnPropertyChanged(e = {System.Windows.DependencyPropertyChangedEventArgs})    
ActiproSoftware.Windows.Controls.Ribbon.Controls.PopupButton.OnPropertyChanged(e = {System.Windows.DependencyPropertyChangedEventArgs})    
System.Windows.DependencyObject.NotifyPropertyChange(args = {System.Windows.DependencyPropertyChangedEventArgs})    
System.Windows.DependencyObject.UpdateEffectiveValue(entryIndex, dp, metadata, oldEntry = {System.Windows.EffectiveValueEntry}, newEntry, coerceWithDeferredReference, operationType)    
System.Windows.DependencyObject.SetValueCommon(dp, value, metadata, coerceWithDeferredReference, operationType, isInternal)    
System.Windows.DependencyObject.SetValue(dp, value)    
I've emailed a sample project that demonstrates the problem. To reproduce, display the context menu for the top button, which consists of a single item with a sub-menu. BEFORE the sub-menu is automatically displayed, left-click the top-level item and the StackOverflowException is thrown. The same thing on a normally, statically defined menu doesn't crash.

Comments (1)

Posted 10 years ago by Actipro Software Support - Cleveland, OH, USA
Avatar
Hi Phil,

Thanks for the report and the sample application. We have fixed this issue for the next maintenance release.


Actipro Software Support

The latest build of this product (v2018.1 build 0675) was released 1 month ago, which was after the last post in this thread.

Add Comment

Please log in to a validated account to post comments.