I want to report 2 issues:
1. The Telerik.WinControls.UI.RadRibbonBar is not correctly implement the System.ComponentModel.INotifyPropertyChanged ( see propeties like Expanded and CollapseRibbonOnTabDoubleClick)
2. The property CollapseRibbonOnTabDoubleClick of the Telerik.WinControls.UI.RadRibbonBar does not work
Desired behaviour: Given a form with an expanded RadRibbonBar docked, the groups and buttons to be always visible( to disable the collapsing of the RadRibbonBar)
Expected behaviour: Given a form with an expanded RadRibbonBar docked with the property CollapseRibbonOnTabDoubleClick setted to false. Any user double click maded at run-time on the tab ribbon buttons to not collapse the ribbon bar.
Steps to reproduce: Create a new WinForms solution. In the designer of the form insert from the toolbox a new RadRibbonBar. Add a tab(click on the Add New Tab ... button and insert a text), a group( click on the Add New Group ... button and insert a text) and a button in the group ( in the group bounds right click and from the contextual menu choose Add an item > RadButtonElement).
Open the code window by right clicking in the designer surface area and choosing from the contextual menu View code.
Insert in the form constructor, immediately after the InitializeComponent(); method call
| this.radRibbonBar1.PropertyChanged += new PropertyChangedEventHandler(radRibbonBar1_PropertyChanged); |
| this.radRibbonBar1.Expanded = true; |
| this.radRibbonBar1.CollapseRibbonOnTabDoubleClick = true; |
| this.radRibbonBar1.CollapseRibbonOnTabDoubleClick = false; |
Insert a new method in the form class:
| void radRibbonBar1_PropertyChanged(object sender, PropertyChangedEventArgs e) |
| { |
| if ("CollapseRibbonOnTabDoubleClick" == e.PropertyName || "Expanded" == e.PropertyName) |
| this.Text = string.Format("CollapseRibbonOnTabDoubleClick {0} Expanded {1}", this.radRibbonBar1.CollapseRibbonOnTabDoubleClick, this.radRibbonBar1.Expanded); |
| } |
Run the application and double click the tab button( not the button in the group). Expected state of the form: a title bar with the text: CollapseRibbonOnTabDoubleClick false Expanded true and the ribbon bar to be expanded( the group to be visible)
Could you please help me to reach the desired scenario described earlier?
| // folder details child view and relation |
| GridViewTemplate foldersTemplate = new GridViewTemplate(); |
| foldersTemplate.EnableGrouping = false; |
| foldersTemplate.AllowAddNewRow = false; |
| foldersTemplate.ShowColumnHeaders = false; |
| foldersTemplate.Columns.Add(new GridViewDataColumn(FDScheduleIdField) { IsVisible = false }); |
| foldersTemplate.Columns.Add(new GridViewDataColumn(FDFolderNameField) { Width = 400 }); |
| foldersTemplate.DataSource = _folders; |
| radGridView1.MasterGridViewTemplate.ChildGridViewTemplates.Add(foldersTemplate); |
| GridViewRelation foldersRelation = new GridViewRelation(radGridView1.MasterGridViewTemplate); |
| foldersRelation.ChildTemplate = foldersTemplate; |
| foldersRelation.RelationName = "upload_folders"; |
| foldersRelation.ParentColumnNames.Add(CUCompletedUploadIdField); |
| foldersRelation.ChildColumnNames.Add(FDScheduleIdField); |
| radGridView1.Relations.Add(foldersRelation); |
| // add logs child view and relation |
| GridViewTemplate logsTemplate = new GridViewTemplate(); |
| logsTemplate.EnableGrouping = false; |
| logsTemplate.AllowAddNewRow = false; |
| logsTemplate.ShowColumnHeaders = false; |
| logsTemplate.Columns.Add(new GridViewDataColumn(ULIdField) { IsVisible = false }); |
| logsTemplate.Columns.Add(new GridViewDataColumn(ULNameField) { Width = 400 }); |
| logsTemplate.DataSource = _logs; |
| radGridView1.MasterGridViewTemplate.ChildGridViewTemplates.Add(logsTemplate); |
| GridViewRelation logsRelation = new GridViewRelation(radGridView1.MasterGridViewTemplate); |
| logsRelation.ChildTemplate = logsTemplate; |
| logsRelation.RelationName = "upload_logs"; |
| logsRelation.ParentColumnNames.Add(CUCompletedUploadIdField); |
| logsRelation.ChildColumnNames.Add(ULIdField); |
| radGridView1.Relations.Add(logsRelation); |