Fix problem with Item Selected. Fixes problem so that Item selected stays selected even if it is not active.

Also, makes DSOFramer properly select the related tab when it becomes active.
This commit is contained in:
Rich
2008-02-26 16:20:00 +00:00
parent f6bb58d4d4
commit ee9acb929d
6 changed files with 88 additions and 43 deletions

View File

@@ -433,8 +433,8 @@ namespace Volian.Controls.Library
this.BackColorChanged += new EventHandler(vlnCSLARTB_BackColorChanged);
//_DisplayRTB.Enter += new EventHandler(_DisplayRTB_Enter);
//_DisplayRTB.Leave += new EventHandler(_DisplayRTB_Leave);
_DisplayRTB.GotFocus += new EventHandler(_DisplayRTB_GotFocus);
_DisplayRTB.LostFocus += new EventHandler(_DisplayRTB_LostFocus);
//_DisplayRTB.GotFocus += new EventHandler(_DisplayRTB_GotFocus);
//_DisplayRTB.LostFocus += new EventHandler(_DisplayRTB_LostFocus);
_DisplayRTB.MouseClick += new MouseEventHandler(_DisplayRTB_MouseClick);
if (item != null)
{
@@ -541,16 +541,16 @@ namespace Volian.Controls.Library
// _Panel._ItemSelected = _MyItem;
// _Panel.OnItemSelectedChanged(sender, new DisplayPanelEventArgs(this, null));
//}
void _DisplayRTB_LostFocus(object sender, EventArgs e)
{
_Panel._ItemSelected = null;
_Panel.OnItemSelectedChanged(sender, null);
}
void _DisplayRTB_GotFocus(object sender, EventArgs e)
{
_Panel._ItemSelected = _MyItem;
_Panel.OnItemSelectedChanged(sender, new DisplayPanelEventArgs(this, null));
}
//void _DisplayRTB_LostFocus(object sender, EventArgs e)
//{
// //_Panel.ItemSelected = null;
// //_Panel.OnItemSelectedChanged(sender, null);
//}
//void _DisplayRTB_GotFocus(object sender, EventArgs e)
//{
// _Panel.ItemSelected = _MyItem;
// //_Panel.OnItemSelectedChanged(sender, new DisplayPanelEventArgs(this, null));
//}
//void _DisplayRTB_Leave(object sender, EventArgs e)
//{
// _Panel._ItemSelected = null;
@@ -938,7 +938,7 @@ namespace Volian.Controls.Library
_Moving = false;
BottomMost.AdjustLocation();
}
void _DisplayRTB_LinkGoTo(object sender, System.Windows.Forms.LinkClickedEventArgs e)
private void _DisplayRTB_LinkGoTo(object sender, System.Windows.Forms.LinkClickedEventArgs e)
{
_MyLog.DebugFormat("_DisplayRTB_LinkGoTo " + e.LinkText);
_Panel.OnLinkClicked(sender, new DisplayLinkEventArgs(this, e));
@@ -947,14 +947,15 @@ namespace Volian.Controls.Library
{
_Panel.OnItemClick(this, new DisplayPanelEventArgs(this, e));
}
private void veRichTextBoxText_Enter(object sender, EventArgs e)
private void _DisplayRTB_Enter(object sender, EventArgs e)
{
_DisplayRTB.BackColor = _Panel.ActiveColor;
}
private void veRichTextBoxText_Leave(object sender, EventArgs e)
{
_DisplayRTB.BackColor = _Panel.InactiveColor;
_Panel.DisplayRTB = _DisplayRTB;
_Panel.ItemSelected = _MyItem;
}
//private void veRichTextBoxText_Leave(object sender, EventArgs e)
//{
//}
private void _DisplayRTB_LinkModifyTran(object sender, LinkClickedEventArgs e)
{