C2021-021 Set the Find/Replace button text, and tool tip based on whether the user has write privileges
This commit is contained in:
parent
23659c9b93
commit
69bff04f78
@ -3423,13 +3423,24 @@ namespace VEPROMS
|
||||
{
|
||||
StepPanel pnl = tc.SelectedDisplayTabItem.MyStepTabPanel.MyStepPanel;
|
||||
if (pnl != null)
|
||||
{
|
||||
// C2021-021 change the tool tip for the Find and Find/Replace button based on the user's accessibility to the procedure.
|
||||
// also change the text on the buttons to read either Find or Find/Replace
|
||||
// also toggle the Replace tab on the dialog based on the user's accessibility to the procedure
|
||||
bool isReviewer = !MyUserInfo.IsAllowedToEdit(tc.SelectedDisplayTabItem.MyItemInfo.MyDocVersion);
|
||||
pnl.MyStepTabPanel.MyStepTabRibbon.SetButtonAndMenuEnabling(true);
|
||||
this.dlgFindReplace.ToggleReplaceTab(isReviewer ? E_ViewMode.View : E_ViewMode.Edit);
|
||||
pnl.MyStepTabPanel.MyStepTabRibbon.ToggleFindReplaceToolTip(isReviewer);
|
||||
}
|
||||
}
|
||||
}
|
||||
private void tc_StepPanelModeChange(object sender, StepRTBModeChangeEventArgs args)
|
||||
{
|
||||
this.lblEditView.Text = args.ViewMode == E_ViewMode.Edit ? "Edit" : "View";
|
||||
this.dlgFindReplace.ToggleReplaceTab(args.ViewMode);
|
||||
// C2021-021 change the tool tip for the Find and Find/Replace button based on the user's accessibility to the procedure.
|
||||
// also change the text on the buttons to read either Find or Find/Replace
|
||||
tc.SelectedDisplayTabItem.MyStepTabPanel.MyStepTabRibbon.ToggleFindReplaceToolTip(args.ViewMode == E_ViewMode.View);
|
||||
}
|
||||
private ItemInfo _CurrentItem = null;
|
||||
private StepRTB _LastStepRTB = null;
|
||||
|
Loading…
x
Reference in New Issue
Block a user