mirror of https://github.com/dahall/Vanara.git
Fixed syntax errors in ComDlg32Tests
parent
30930565e6
commit
f617fffc81
|
@ -2,6 +2,7 @@
|
||||||
using NUnit.Framework.Internal;
|
using NUnit.Framework.Internal;
|
||||||
using System;
|
using System;
|
||||||
using System.Runtime.InteropServices;
|
using System.Runtime.InteropServices;
|
||||||
|
using Vanara.InteropServices;
|
||||||
using static Vanara.PInvoke.ComDlg32;
|
using static Vanara.PInvoke.ComDlg32;
|
||||||
using static Vanara.PInvoke.User32;
|
using static Vanara.PInvoke.User32;
|
||||||
|
|
||||||
|
@ -40,8 +41,8 @@ namespace Vanara.PInvoke.Tests
|
||||||
var ofn = new OPENFILENAME
|
var ofn = new OPENFILENAME
|
||||||
{
|
{
|
||||||
lStructSize = (uint)Marshal.SizeOf(typeof(OPENFILENAME)),
|
lStructSize = (uint)Marshal.SizeOf(typeof(OPENFILENAME)),
|
||||||
lpstrFile = fn,
|
lpstrFile = (IntPtr)fn,
|
||||||
nMaxFile = (uint)fnch.Capacity,
|
nMaxFile = (uint)fn.Capacity,
|
||||||
lpstrFilter = "All\0*.*\0Text\0*.txt\0",
|
lpstrFilter = "All\0*.*\0Text\0*.txt\0",
|
||||||
nFilterIndex = 1,
|
nFilterIndex = 1,
|
||||||
Flags = OFN.OFN_PATHMUSTEXIST | OFN.OFN_FILEMUSTEXIST
|
Flags = OFN.OFN_PATHMUSTEXIST | OFN.OFN_FILEMUSTEXIST
|
||||||
|
@ -59,8 +60,8 @@ namespace Vanara.PInvoke.Tests
|
||||||
{
|
{
|
||||||
lStructSize = (uint)Marshal.SizeOf(typeof(FINDREPLACE)),
|
lStructSize = (uint)Marshal.SizeOf(typeof(FINDREPLACE)),
|
||||||
hwndOwner = wnd.MessageWindowHandle,
|
hwndOwner = wnd.MessageWindowHandle,
|
||||||
lpstrFindWhat = fw,
|
lpstrFindWhat = (IntPtr)fw,
|
||||||
wFindWhatLen = (ushort)fwch.Length,
|
wFindWhatLen = (ushort)fw.Length,
|
||||||
};
|
};
|
||||||
Assert.That(wnd.hdlg = FindText(ref fr), Is.True);
|
Assert.That(wnd.hdlg = FindText(ref fr), Is.True);
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in New Issue