33 instantiations of SafeArrayScope
System.Windows.Forms (5)
System\Windows\Forms\Accessibility\AccessibleObject.cs (4)
642UIA_PROPERTY_ID.UIA_RuntimeIdPropertyId => (VARIANT)new SafeArrayScope<int>(RuntimeId), 945*pRetVal = new SafeArrayScope<int>(RuntimeId); 1046*pRetVal = new SafeArrayScope<int>(RuntimeId); 3029*pRetVal = result is null ? SAFEARRAY.CreateEmpty(VARENUM.VT_I4) : new SafeArrayScope<int>(result);
System\Windows\Forms\Controls\WebBrowser\HtmlDocument.cs (1)
415using SafeArrayScope<object> scope = new(1);
System.Windows.Forms.Primitives (6)
System\Windows\Forms\Automation\UiaTextProvider.cs (3)
85return new(SAFEARRAY.CreateEmpty(VARENUM.VT_R8)); 88SafeArrayScope<double> result = new((uint)(rectArray.Count * 4)); 109SafeArrayScope<double> result = new(4);
System\Windows\Forms\Automation\UiaTextRange.cs (1)
345SafeArrayScope<double> ownerBounds = new(result.data.parray);
Windows\Win32\System\Com\ComSafeArrayScope.cs (2)
30_value = new(value); 41_value = new(PInvokeCore.SafeArrayCreate(VARENUM.VT_UNKNOWN, 1, &saBound));
System.Windows.Forms.Primitives.Tests (22)
System\Windows\Forms\Automation\UiaTextRangeTests.cs (12)
546SafeArrayScope<double> array = new(4); 564using SafeArrayScope<double> actual = new((SAFEARRAY*)null); 576SafeArrayScope<double> array = new(4); 594using SafeArrayScope<double> actual = new((SAFEARRAY*)null); 602SafeArrayScope<double> array = new(4); 623using SafeArrayScope<double> safeArrayScope = new((SAFEARRAY*)null); 641SafeArrayScope<double> array = new(4); 664using SafeArrayScope<double> actual = new((SAFEARRAY*)null); 690SafeArrayScope<double> array = new(4); 747using SafeArrayScope<double> actual = new((SAFEARRAY*)null); 772SafeArrayScope<double> array = new(4); 829using SafeArrayScope<double> actual = new((SAFEARRAY*)null);
Windows\Win32\System\Com\SafeArrayScopeTests.cs (10)
12using SafeArrayScope<int> scope = new(intArray); 23using SafeArrayScope<string> scope = new(size: 1); 24using SafeArrayScope<int> scope2 = new(size: 0); 32Assert.Throws<ArgumentException>(() => new SafeArrayScope<short>(size: 1)); 38using SafeArrayScope<string> scope = new(size: 2); 51using SafeArrayScope<int> scope = new(size: 2); 62SafeArrayScope<string> scope = new(size: 1); 73ArgumentException e = Assert.Throws<ArgumentException>(() => new SafeArrayScope<IUnknown>(size: 1)); 78e = Assert.Throws<ArgumentException>(() => new SafeArrayScope<IUnknown>(array)); 93ArgumentException e = Assert.Throws<ArgumentException>(() => new SafeArrayScope<string>(array));
34 references to SafeArrayScope
System.Private.Windows.Core (5)
Windows\Win32\System\Com\SafeArrayScope.cs (5)
250public static explicit operator VARIANT(in SafeArrayScope<T> scope) => new() { vt = VARENUM.VT_ARRAY | scope.Value->VarType, data = new() { parray = (SAFEARRAY*)scope._value } }; 252public static implicit operator SAFEARRAY*(in SafeArrayScope<T> scope) => (SAFEARRAY*)scope._value; 254public static implicit operator nint(in SafeArrayScope<T> scope) => scope._value; 257public static implicit operator SAFEARRAY**(in SafeArrayScope<T> scope) => (SAFEARRAY**)Unsafe.AsPointer(ref Unsafe.AsRef(in scope._value)); 260public static implicit operator void**(in SafeArrayScope<T> scope) => (void**)Unsafe.AsPointer(ref Unsafe.AsRef(in scope._value));
System.Windows.Forms (1)
System\Windows\Forms\Controls\WebBrowser\HtmlDocument.cs (1)
415using SafeArrayScope<object> scope = new(1);
System.Windows.Forms.Primitives (6)
System\Windows\Forms\Automation\UiaTextProvider.cs (4)
81public static SafeArrayScope<double> RectListToDoubleArray(List<Rectangle> rectArray) 88SafeArrayScope<double> result = new((uint)(rectArray.Count * 4)); 107internal static SafeArrayScope<double> BoundingRectangleAsArray(Rectangle bounds) 109SafeArrayScope<double> result = new(4);
System\Windows\Forms\Automation\UiaTextRange.cs (1)
345SafeArrayScope<double> ownerBounds = new(result.data.parray);
Windows\Win32\System\Com\ComSafeArrayScope.cs (1)
21private readonly SafeArrayScope<nint> _value;
System.Windows.Forms.Primitives.Tests (22)
System\Windows\Forms\Automation\UiaTextProviderTests.cs (3)
69using SafeArrayScope<double> actual = UiaTextProvider.RectListToDoubleArray( 86using SafeArrayScope<double> actual = UiaTextProvider.RectListToDoubleArray(null!); 93using SafeArrayScope<double> actual = UiaTextProvider.RectListToDoubleArray([]);
System\Windows\Forms\Automation\UiaTextRangeTests.cs (13)
546SafeArrayScope<double> array = new(4); 564using SafeArrayScope<double> actual = new((SAFEARRAY*)null); 566using SafeArrayScope<double> expectedRectArray = UiaTextProvider.BoundingRectangleAsArray(expected); 576SafeArrayScope<double> array = new(4); 594using SafeArrayScope<double> actual = new((SAFEARRAY*)null); 602SafeArrayScope<double> array = new(4); 623using SafeArrayScope<double> safeArrayScope = new((SAFEARRAY*)null); 641SafeArrayScope<double> array = new(4); 664using SafeArrayScope<double> actual = new((SAFEARRAY*)null); 690SafeArrayScope<double> array = new(4); 747using SafeArrayScope<double> actual = new((SAFEARRAY*)null); 772SafeArrayScope<double> array = new(4); 829using SafeArrayScope<double> actual = new((SAFEARRAY*)null);
Windows\Win32\System\Com\SafeArrayScopeTests.cs (6)
12using SafeArrayScope<int> scope = new(intArray); 23using SafeArrayScope<string> scope = new(size: 1); 24using SafeArrayScope<int> scope2 = new(size: 0); 38using SafeArrayScope<string> scope = new(size: 2); 51using SafeArrayScope<int> scope = new(size: 2); 62SafeArrayScope<string> scope = new(size: 1);