Completed
Last Updated: 27 Mar 2019 11:44 by Dimitar
sebastien
Created on: 20 Mar 2019 15:26
Category: RibbonBar
Type: Bug Report
2
Paint problem when RadRibbonBar.Expanded=false and opening a dialog (FileFolderDialog) form on RibbonBarButton

Structure:

  • Add a RadRibbonBar
  • Add a RibbonTab
  • Add a RadRibbonBarGroup
  • Add a button in the group
  • Clicked event of button must do a FileFolderDialog.ShowDialog()

 

How to reproduce:

  • reduce (collapse) the RadRibbonBar with the ^ button on the far right
  • click on the button that will show the DialogForm

 

Result:

   the menu will be repainted over the dialogform

 

Using the Fluent theme.

Sometimes the popped up menu is just plain white, sometimes its painted correctly (showing buttons) but always over the DialogForm.

 

thanks

Attached Files:
4 comments
Dimitar
Posted on: 27 Mar 2019 11:44
Hello, 
 
A Fix will be available in LIB Version 2019.1.401 scheduled for April 1st.

Best regards, 
Dimitar
sebastien
Posted on: 21 Mar 2019 20:11

The workaround didn't work for a specific button. The button open's a third party software (.exe)

 

I tried calling a Refresh, also an Application.DoEvents but nothing is working. The other application is doing a file or folder browser dialog. 

 

private void radButtonConvert_Click(object sender, EventArgs e)
        {
            if (radRibbonBarMain.RibbonBarElement.Popup != null)
            {
                radRibbonBarMain.RibbonBarElement.Popup.ClosePopup(Telerik.WinControls.UI.RadPopupCloseReason.Mouse);
                Refresh();
                Application.DoEvents();
            }

            try
            {
                // Use ProcessStartInfo class
                ProcessStartInfo startInfo = new ProcessStartInfo();
                startInfo.CreateNoWindow = false;
                startInfo.UseShellExecute = false;
                startInfo.FileName = "ConfigurationConversion.exe";
                startInfo.WindowStyle = ProcessWindowStyle.Normal;
                startInfo.Verb = "runas";

                // Start the process with the info we specified.
                // Call WaitForExit and then the using statement will close.
                using (Process exeProcess = Process.Start(startInfo))
                {
                    exeProcess.WaitForExit();
                }
            }
            catch
            {
                // Log error.
            }
        }
ADMIN
Dess | Tech Support Engineer, Principal
Posted on: 21 Mar 2019 09:06
Hello, Sebastien,

I would like to follow up with further information.

After further investigating the specific scenario, I would like to confirm that it is considered to be an issue with the default behavior of the RibbonBarPopup. I have logged it in our feedback portal by making this thread public. You can track its progress, subscribe for status changes and add your comments on the following link - feedback item.

I have also updated your Telerik points.

Feel free to use the previously suggested solution.

Regards,
Dess | Tech Support Engineer, Sr.
Progress Telerik
Get quickly onboarded and successful with your Telerik and/or Kendo UI products with the Virtual Classroom free technical training, available to all active customers. Learn More.
ADMIN
Dess | Tech Support Engineer, Principal
Posted on: 21 Mar 2019 08:32
Hello, Sebastien,

Following the provided information, I was able to replicate the undesired behavior. Indeed, this behavior doesn't look proper. That is why I would like to explain more details why this behavior occurs. By default, when the ribbon is collapsed and the popup is shown by clicking the tab, it is expected to be closed when you click the RibbonBarPopup. This is executed when handling the mouse up message in RibbonBarPopup. But the Click event of the button element is fired before that. As a result you obtain the illustrated result. 

Changing the popup closing when handling the mouse down message for example would be a generic change in the behavior of RadRibbonBar and unexpected to other customers. That is why I would recommend you before showing the file dialog to close the popup. Thus, you will ensure that the layout will be proper. Here is demonstrated a sample code snippet: 

private void radButtonElement1_Click(object sender, EventArgs e)
{
    this.radRibbonBar1.RibbonBarElement.Popup.ClosePopup(Telerik.WinControls.UI.RadPopupCloseReason.Mouse);
    new OpenFileDialog().ShowDialog();
}

I hope this information helps. If you need any further assistance please don't hesitate to contact me. 

Regards,
Dess | Tech Support Engineer, Sr.
Progress Telerik
Get quickly onboarded and successful with your Telerik and/or Kendo UI products with the Virtual Classroom free technical training, available to all active customers. Learn More.