/// <summary>Called inside the GetControlModes-Method to get the Global.ControlModes from derivations. /// This method should be overriden in the derivations to dynmically control the presentation mode depending on the current value which is bound via VBContent</summary> /// <param name="vbControl">A WPF-Control that implements IVBContent</param> /// <returns>ControlModesInfo</returns> public override Global.ControlModes OnGetControlModes(IVBContent vbControl) { if (vbControl == null) { return(base.OnGetControlModes(vbControl)); } Global.ControlModes result = base.OnGetControlModes(vbControl); if (result < Global.ControlModes.Enabled) { return(result); } //switch (vbControl.VBContent) //{ // case "CurrentMaterial\\BaseMDUnit": // default: // return result; //} return(result); }
/// <summary> /// Method that returns a source and path for WPF-Bindings by passing a ACUrl. /// </summary> /// <param name="acUrl">ACUrl of the Component, Property or Method</param> /// <param name="acTypeInfo">Reference to the iPlus-Type (ACClass)</param> /// <param name="source">The Source for WPF-Databinding</param> /// <param name="path">Relative path from the returned source for WPF-Databinding</param> /// <param name="rightControlMode">Information about access rights for the requested object</param> /// <returns><c>true</c> if binding could resolved for the passed ACUrl<c>false</c> otherwise</returns> public bool ACUrlBinding(string acUrl, ref IACType acTypeInfo, ref object source, ref string path, ref Global.ControlModes rightControlMode) { return(false); }
/// <summary> /// Method that returns a source and path for WPF-Bindings by passing a ACUrl. /// </summary> /// <param name="acUrl">ACUrl of the Component, Property or Method</param> /// <param name="acTypeInfo">Reference to the iPlus-Type (ACClass)</param> /// <param name="source">The Source for WPF-Databinding</param> /// <param name="path">Relative path from the returned source for WPF-Databinding</param> /// <param name="rightControlMode">Information about access rights for the requested object</param> /// <returns><c>true</c> if binding could resolved for the passed ACUrl<c>false</c> otherwise</returns> public bool ACUrlBinding(string acUrl, ref IACType acTypeInfo, ref object source, ref string path, ref Global.ControlModes rightControlMode) { if (_ObjectContextHelper == null) { return(false); } return(_ObjectContextHelper.ACUrlBinding(acUrl, ref acTypeInfo, ref source, ref path, ref rightControlMode)); }