fixed [Ctrl][F1] (hide/expand ribbon) sync issue

This commit is contained in:
John Jenko 2009-11-19 14:40:27 +00:00
parent e7d6cda035
commit 8f81a3a3e7
2 changed files with 10 additions and 1 deletions

View File

@ -140,9 +140,18 @@ namespace Volian.Controls.Library
InitializeComponent(); InitializeComponent();
_RibbonControl.SizeChanged += new EventHandler(_RibbonControl_SizeChanged); _RibbonControl.SizeChanged += new EventHandler(_RibbonControl_SizeChanged);
} }
void _RibbonControl_SizeChanged(object sender, EventArgs e) void _RibbonControl_SizeChanged(object sender, EventArgs e)
{ {
this.Size = _RibbonControl.Size; this.Size = _RibbonControl.Size;
if (MyStepItem != null)
{
// This is needed to reset the Ribbon Expanded status when [CTRL][F1] is used.
// We found that using the [CTRL][F1] keystroke will cause the Ribbon state to
// be out so of sync with that of the QAT menu option to expand/hide the ribbon.
// Note: the QAT menu is to the right of the V start button in the upper left
_RibbonControl.Expanded = MyStepItem.MyStepPanel.MyStepTabPanel.MyDisplayTabControl.RibbonExpanded;
}
} }
public bool Expanded public bool Expanded
{ {