This commit is contained in:
2009-07-24 11:49:35 +00:00
parent 9c82153da1
commit a216184be8
3 changed files with 64 additions and 93 deletions

View File

@@ -42,7 +42,7 @@ namespace VEPROMS
_SelectedStepTabPanel = value;
if (value == null) // DSO Tab Panel
{
if (tc.SelectedDisplayTabItem != null)
if (tc.SelectedDisplayTabItem != null && tc.SelectedDisplayTabItem.MyItemInfo != null) // 2nd part is for unassociated libdocs
SelectedDVI = tc.SelectedDisplayTabItem.MyItemInfo.MyActiveParent.ActiveParent as DocVersionInfo;
else
SelectedDVI = null;
@@ -425,26 +425,7 @@ namespace VEPROMS
// //}
//}
#endregion
#region Edit/View Modes
/// <summary>
/// Edit Mode button on the bottom tool bar
/// </summary>
/// <param name="sender"></param>
/// <param name="e"></param>
private void btnEditMode_Click(object sender, EventArgs e)
{
btnEditView.Text = btnEditMode.Text;
}
/// <summary>
/// View Mode button on the bottom tool bar
/// </summary>
/// <param name="sender"></param>
/// <param name="e"></param>
private void btnViewMode_Click(object sender, EventArgs e)
{
btnEditView.Text = btnViewMode.Text;
}
#region Bottom Button Modes
/// <summary>
/// Insert button on the bottom tool bar
@@ -889,9 +870,14 @@ namespace VEPROMS
displayTags.MyRTB = (SelectedStepTabPanel == null) ? null : SelectedStepTabPanel.MyStepPanel.SelectedStepItem.MyStepRTB;
}
#endregion
private void tc_StepPanelModeChange(object sender, StepRTBModeChangeEventArgs args)
{
this.lblEditView.Text = args.ViewMode == E_ViewMode.Edit ? "Edit" : "View";
}
private ItemInfo _CurrentItem = null;
private void tc_ItemSelectedChanged(object sender, ItemSelectedChangedEventArgs args)
{
lblEditView.Text = " ";
if (args == null)
{
_CurrentItem = null;
@@ -936,6 +922,7 @@ namespace VEPROMS
displayRO.MyRTB = args.MyStepItem.MyStepRTB;
displayTags.MyRTB = args.MyStepItem.MyStepRTB;
displayRO.ProgressBar = bottomProgBar;
lblEditView.Text = args.MyStepItem.MyStepRTB.ViewRTB ? "View" : "Edit";
}
if(tc.SelectedDisplayTabItem != null)
SelectedStepTabPanel = ((DisplayTabItem)tc.SelectedDisplayTabItem).MyStepTabPanel;