This commit is contained in:
@@ -632,8 +632,9 @@ namespace Volian.Controls.Library
|
|||||||
{
|
{
|
||||||
_MouseDown = true;
|
_MouseDown = true;
|
||||||
//Console.WriteLine("vvvvvvvvvv StepRTB Mouse Down id= {0}",MyItemInfo.ItemID);
|
//Console.WriteLine("vvvvvvvvvv StepRTB Mouse Down id= {0}",MyItemInfo.ItemID);
|
||||||
|
bool inPsi = this.Parent.FindForm().Name.Contains("frmPSI");
|
||||||
if (!_ContextMenuStripChanged)
|
if (!_ContextMenuStripChanged)
|
||||||
OnSetMenu(this, new StepRTBMenuEventArgs("OpenContextMenu"));
|
OnSetMenu(this, new StepRTBMenuEventArgs(inPsi?"PSI":"OpenContextMenu"));
|
||||||
_ContextMenuStripChanged = false;
|
_ContextMenuStripChanged = false;
|
||||||
CorrectSelectionAtEndOfLine();
|
CorrectSelectionAtEndOfLine();
|
||||||
}
|
}
|
||||||
@@ -945,7 +946,7 @@ namespace Volian.Controls.Library
|
|||||||
else
|
else
|
||||||
AddLink20(linkUrl, linkValue);
|
AddLink20(linkUrl, linkValue);
|
||||||
}
|
}
|
||||||
private string FontTable
|
public string FontTable
|
||||||
{
|
{
|
||||||
get
|
get
|
||||||
{
|
{
|
||||||
|
@@ -96,6 +96,10 @@ namespace Volian.Controls.Library
|
|||||||
//Console.WriteLine(string.Format("StepTabRibbon: In set of MyStepRTB, Selected Text = {0}", MyStepRTB.SelectedText));
|
//Console.WriteLine(string.Format("StepTabRibbon: In set of MyStepRTB, Selected Text = {0}", MyStepRTB.SelectedText));
|
||||||
switch (_MyStepRTB.FieldToEdit)
|
switch (_MyStepRTB.FieldToEdit)
|
||||||
{
|
{
|
||||||
|
case E_FieldToEdit.PSI:
|
||||||
|
_ContextMenuBar.SetContextMenuEx(_MyStepRTB, btnCMPSI);
|
||||||
|
_DefaultContextMenu = btnCMPSI;
|
||||||
|
break;
|
||||||
case E_FieldToEdit.StepText:
|
case E_FieldToEdit.StepText:
|
||||||
if (MyFlexGrid != null)
|
if (MyFlexGrid != null)
|
||||||
{
|
{
|
||||||
@@ -147,7 +151,7 @@ namespace Volian.Controls.Library
|
|||||||
MessageBox.Show("No symbols are available, check with administrator");
|
MessageBox.Show("No symbols are available, check with administrator");
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
BuildSymbolGallery(sl, galleryContainerSymbolsCM, galleryContainerSymbolsCM3, galleryContainerSymbolsGrid);
|
BuildSymbolGallery(sl, galleryContainerSymbolsCM, galleryContainerSymbolsCM3, galleryContainerSymbolsGrid, galleryContainerSymbolsCM4);
|
||||||
//BuildSymbolGallery(sl, galleryContainerSymbolsCM);
|
//BuildSymbolGallery(sl, galleryContainerSymbolsCM);
|
||||||
//BuildSymbolGallery(sl, galleryContainerSymbolsCM3);
|
//BuildSymbolGallery(sl, galleryContainerSymbolsCM3);
|
||||||
//BuildSymbolGallery(sl, galleryContainerSymbolsGrid);
|
//BuildSymbolGallery(sl, galleryContainerSymbolsGrid);
|
||||||
@@ -247,7 +251,7 @@ namespace Volian.Controls.Library
|
|||||||
// //SetButtonAndMenuEnabling(false);
|
// //SetButtonAndMenuEnabling(false);
|
||||||
//}
|
//}
|
||||||
|
|
||||||
private void BuildSymbolGallery(SymbolList sl, DevComponents.DotNetBar.GalleryContainer gc1, DevComponents.DotNetBar.GalleryContainer gc2, DevComponents.DotNetBar.GalleryContainer gc3)
|
private void BuildSymbolGallery(SymbolList sl, DevComponents.DotNetBar.GalleryContainer gc1, DevComponents.DotNetBar.GalleryContainer gc2, DevComponents.DotNetBar.GalleryContainer gc3, DevComponents.DotNetBar.GalleryContainer gc4)
|
||||||
{
|
{
|
||||||
foreach (Symbol sym in sl)
|
foreach (Symbol sym in sl)
|
||||||
{
|
{
|
||||||
@@ -269,6 +273,9 @@ namespace Volian.Controls.Library
|
|||||||
DevComponents.DotNetBar.ButtonItem btnCM3 = GetCMButton(sym);
|
DevComponents.DotNetBar.ButtonItem btnCM3 = GetCMButton(sym);
|
||||||
btnCM3.Click += new System.EventHandler(btnSym_Click);
|
btnCM3.Click += new System.EventHandler(btnSym_Click);
|
||||||
gc3.SubItems.Add(btnCM3);
|
gc3.SubItems.Add(btnCM3);
|
||||||
|
DevComponents.DotNetBar.ButtonItem btnCM4 = GetCMButton(sym);
|
||||||
|
btnCM4.Click += new System.EventHandler(btnSym_Click);
|
||||||
|
gc4.SubItems.Add(btnCM4);
|
||||||
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@@ -1302,7 +1309,9 @@ namespace Volian.Controls.Library
|
|||||||
{
|
{
|
||||||
bool displayMenu = false;
|
bool displayMenu = false;
|
||||||
E_AccStep? actable = 0;
|
E_AccStep? actable = 0;
|
||||||
StepData sd = MyItemInfo.FormatStepData;
|
if (menuName.Contains("PSI")) Console.WriteLine("menu = {0}", menuName);
|
||||||
|
|
||||||
|
StepData sd = MyItemInfo==null?null:MyItemInfo.FormatStepData;
|
||||||
if (sd != null) // will be null if section
|
if (sd != null) // will be null if section
|
||||||
{
|
{
|
||||||
actable = sd.StepEditData.AcTable;
|
actable = sd.StepEditData.AcTable;
|
||||||
@@ -1311,6 +1320,10 @@ namespace Volian.Controls.Library
|
|||||||
//btnInsCaut.Enabled = (actable & E_AccStep.AddingCaution) > 0;
|
//btnInsCaut.Enabled = (actable & E_AccStep.AddingCaution) > 0;
|
||||||
switch (menuName)
|
switch (menuName)
|
||||||
{
|
{
|
||||||
|
case "PSI":
|
||||||
|
displayMenu = true;
|
||||||
|
_ContextMenuBar.SetContextMenuEx(_MyStepRTB, btnCMPSI);
|
||||||
|
break;
|
||||||
case "InsHLS":
|
case "InsHLS":
|
||||||
displayMenu = true;
|
displayMenu = true;
|
||||||
_ContextMenuBar.SetContextMenuEx(_MyStepRTB, btnCMInsHLS);
|
_ContextMenuBar.SetContextMenuEx(_MyStepRTB, btnCMInsHLS);
|
||||||
@@ -1980,7 +1993,7 @@ namespace Volian.Controls.Library
|
|||||||
//_RibbonControl.Height = rbnBorderlistBox.Height + _RibbonControl.Height - _RibbonControl.ClientSize.Height;
|
//_RibbonControl.Height = rbnBorderlistBox.Height + _RibbonControl.Height - _RibbonControl.ClientSize.Height;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
public enum E_FieldToEdit { StepText, Text, Number };
|
public enum E_FieldToEdit { StepText, Text, Number, PSI };
|
||||||
public class StepTabRibbonEventArgs : EventArgs
|
public class StepTabRibbonEventArgs : EventArgs
|
||||||
{
|
{
|
||||||
public StepTabRibbonEventArgs() { ; }
|
public StepTabRibbonEventArgs() { ; }
|
||||||
|
BIN
PROMS/Volian.Controls.Library/StepTabRibbon.designer.cs
generated
BIN
PROMS/Volian.Controls.Library/StepTabRibbon.designer.cs
generated
Binary file not shown.
Reference in New Issue
Block a user