Example #1
0
        public static object GetObjectForVariant(Variant variant)
        {
            IntPtr ptr = UnsafeMethods.ConvertVariantByrefToPtr(ref variant);

            return(System.Runtime.InteropServices.Marshal.GetObjectForNativeVariant(ptr));
        }
Example #2
0
 public void SetAsByrefError(ref Int32 value)
 {
     Debug.Assert(IsEmpty); // The setter can only be called once as VariantClear might be needed otherwise
     VariantType = (VarEnum.VT_ERROR | VarEnum.VT_BYREF);
     _typeUnion._unionTypes._byref = UnsafeMethods.ConvertInt32ByrefToPtr(ref value);
 }
Example #3
0
 /// <summary>
 /// Initializes a new instance of the <see cref="DW.CodedUI.BasicElements.BasicListItem" /> class
 /// </summary>
 /// <param name="automationElement">The automation control.</param>
 public BasicListItem(AutomationElement automationElement)
     : base(automationElement)
 {
     Unsafe = new UnsafeMethods(automationElement);
 }
Example #4
0
 public void SetAsByrefDecimal(ref Decimal value)
 {
     Debug.Assert(IsEmpty); // The setter can only be called once as VariantClear might be needed otherwise
     VariantType = (VarEnum.VT_DECIMAL | VarEnum.VT_BYREF);
     _typeUnion._unionTypes._byref = UnsafeMethods.ConvertDecimalByrefToPtr(ref value);
 }
Example #5
0
 /// <summary>
 /// Initializes a new instance of the <see cref="DW.CodedUI.BasicElements.BasicRadioButton" /> class.
 /// </summary>
 /// <param name="automationElement">The automation control.</param>
 public BasicRadioButton(AutomationElement automationElement)
     : base(automationElement)
 {
     Unsafe = new UnsafeMethods(automationElement);
 }
Example #6
0
 /// <summary>
 /// Initializes a new instance of the <see cref="DW.CodedUI.BasicElements.BasicExpander" /> class.
 /// </summary>
 /// <param name="automationElement">The automation control.</param>
 public BasicExpander(AutomationElement automationElement)
     : base(automationElement)
 {
     Unsafe = new UnsafeMethods(automationElement);
 }
Example #7
0
 /// <summary>
 /// Initializes a new instance of the <see cref="DW.CodedUI.BasicElements.BasicCheckBox" /> class.
 /// </summary>
 /// <param name="automationElement">The automation control.</param>
 public BasicCheckBox(AutomationElement automationElement)
     : base(automationElement)
 {
     Unsafe = new UnsafeMethods(automationElement);
 }
Example #8
0
 /// <summary>
 /// Initializes a new instance of the <see cref="DW.CodedUI.BasicElements.BasicTreeView" /> class.
 /// </summary>
 /// <param name="automationElement">The automation control.</param>
 public BasicTreeView(AutomationElement automationElement)
     : base(automationElement)
 {
     Unsafe = new UnsafeMethods(automationElement);
 }
Example #9
0
 /// <summary>
 /// Initializes a new instance of the <see cref="DW.CodedUI.BasicElements.BasicDataCell" /> class.
 /// </summary>
 /// <param name="automationElement">The automation control.</param>
 public BasicDataCell(AutomationElement automationElement)
     : base(automationElement)
 {
     Unsafe = new UnsafeMethods(automationElement);
 }
Example #10
0
 /// <summary>
 /// Initializes a new instance of the <see cref="DW.CodedUI.BasicElements.BasicWindow" /> class.
 /// </summary>
 /// <param name="automationElement">The automation control</param>
 public BasicDialog(AutomationElement automationElement)
     : base(automationElement)
 {
     Unsafe = new UnsafeMethods(automationElement);
 }
Example #11
0
 /// <summary>
 /// Initializes a new instance of the <see cref="DW.CodedUI.BasicElements.BasicDataColumnHeader" /> class.
 /// </summary>
 /// <param name="automationElement">The automation control.</param>
 public BasicDataColumnHeader(AutomationElement automationElement)
     : base(automationElement)
 {
     Unsafe = new UnsafeMethods(automationElement);
 }