Implemented interface member:
method
GetDataPresent
System.Windows.Forms.IDataObject.GetDataPresent(System.String, System.Boolean)
89 references to GetDataPresent
System.Windows.Forms (5)
System\Windows\Forms\OLE\DataObject.cs (5)
247
public virtual bool GetDataPresent(string format) =>
GetDataPresent
(format, autoConvert: true);
307
public virtual bool ContainsAudio() =>
GetDataPresent
(DataFormats.WaveAudioConstant, autoConvert: false);
309
public virtual bool ContainsFileDropList() =>
GetDataPresent
(DataFormats.FileDropConstant, autoConvert: true);
311
public virtual bool ContainsImage() =>
GetDataPresent
(DataFormats.BitmapConstant, autoConvert: true);
319
return
GetDataPresent
(ConvertToDataFormats(format), autoConvert: false);
System.Windows.Forms.Tests (84)
System\Windows\Forms\DataObjectTests.ClipboardTests.cs (5)
76
dataObject.
GetDataPresent
(format, autoConvert).Should().BeFalse();
113
dataObject.
GetDataPresent
(format, autoConvert: false).Should().BeTrue();
114
dataObject.
GetDataPresent
(format, autoConvert: true).Should().BeTrue();
177
dataObject.
GetDataPresent
(format, autoConvert: true).Should().BeTrue();
178
dataObject.
GetDataPresent
(format, autoConvert: false).Should().BeTrue();
System\Windows\Forms\DataObjectTests.cs (79)
80
.Setup(o => o.
GetDataPresent
(DataFormats.WaveAudio, false))
84
mockDataObject.Verify(o => o.
GetDataPresent
(DataFormats.WaveAudio, false), Times.Once());
103
.Setup(o => o.
GetDataPresent
(DataFormats.FileDrop, true))
107
mockDataObject.Verify(o => o.
GetDataPresent
(DataFormats.FileDrop, true), Times.Once());
126
.Setup(o => o.
GetDataPresent
(DataFormats.Bitmap, true))
130
mockDataObject.Verify(o => o.
GetDataPresent
(DataFormats.Bitmap, true), Times.Once());
188
.Setup(o => o.
GetDataPresent
(expectedFormat, false))
192
mockDataObject.Verify(o => o.
GetDataPresent
(expectedFormat, false), Times.Once());
544
.Setup(o => o.
GetDataPresent
(format, true))
548
mockDataObject.Verify(o => o.
GetDataPresent
(format, true), Times.Once());
592
dataObject.
GetDataPresent
(format, autoConvert).Should().Be(result);
979
dataObject.
GetDataPresent
(DataFormats.WaveAudio, autoConvert: true).Should().BeTrue();
980
dataObject.
GetDataPresent
(DataFormats.WaveAudio, autoConvert: false).Should().BeTrue();
1037
dataObject.
GetDataPresent
(DataFormats.WaveAudio, autoConvert: true).Should().BeTrue();
1038
dataObject.
GetDataPresent
(DataFormats.WaveAudio, autoConvert: false).Should().BeTrue();
1093
dataObject.
GetDataPresent
(format, autoConvert: false).Should().BeTrue();
1094
dataObject.
GetDataPresent
(format, autoConvert: true).Should().BeTrue();
1110
dataObject.
GetDataPresent
(format, autoConvert: false).Should().BeTrue();
1111
dataObject.
GetDataPresent
(format, autoConvert: true).Should().BeTrue();
1128
dataObject.
GetDataPresent
(DataFormats.Serializable, autoConvert: false).Should().BeTrue();
1129
dataObject.
GetDataPresent
(DataFormats.Serializable, autoConvert: true).Should().BeTrue();
1130
dataObject.
GetDataPresent
(data2.GetType().FullName, autoConvert: false).Should().BeTrue();
1131
dataObject.
GetDataPresent
(data2.GetType().FullName, autoConvert: true).Should().BeTrue();
1194
dataObject.
GetDataPresent
(format, autoConvert: false).Should().BeTrue();
1195
dataObject.
GetDataPresent
(format, autoConvert: true).Should().BeTrue();
1223
dataObject.
GetDataPresent
(format, autoConvert: false).Should().BeTrue();
1224
dataObject.
GetDataPresent
(format, autoConvert: true).Should().BeTrue();
1268
dataObject.
GetDataPresent
(DataFormats.Bitmap, autoConvert: true).Should().BeTrue();
1269
dataObject.
GetDataPresent
(DataFormats.Bitmap, autoConvert: false).Should().BeTrue();
1270
dataObject.
GetDataPresent
(typeof(Bitmap).FullName, autoConvert: true).Should().BeTrue();
1271
dataObject.
GetDataPresent
(typeof(Bitmap).FullName, autoConvert: false).Should().BeFalse();
1272
dataObject.
GetDataPresent
(DataFormats.Dib, autoConvert: true).Should().BeFalse();
1273
dataObject.
GetDataPresent
(DataFormats.Dib, autoConvert: false).Should().BeFalse();
1347
dataObject.
GetDataPresent
(format, autoConvert: true).Should().BeTrue();
1348
dataObject.
GetDataPresent
(format, autoConvert: false).Should().BeTrue();
1391
dataObject.
GetDataPresent
(format, autoConvert: true).Should().BeTrue();
1392
dataObject.
GetDataPresent
(format, autoConvert: false).Should().BeTrue();
1421
dataObject.
GetDataPresent
(DataFormats.Bitmap, autoConvert: true).Should().BeTrue();
1422
dataObject.
GetDataPresent
(DataFormats.Bitmap, autoConvert: false).Should().BeTrue();
1423
dataObject.
GetDataPresent
(typeof(Bitmap).FullName, autoConvert: true).Should().BeTrue();
1424
dataObject.
GetDataPresent
(typeof(Bitmap).FullName, autoConvert: false).Should().BeFalse();
1425
dataObject.
GetDataPresent
(DataFormats.Dib, autoConvert: true).Should().BeFalse();
1426
dataObject.
GetDataPresent
(DataFormats.Dib, autoConvert: false).Should().BeFalse();
1542
dataObject.
GetDataPresent
(DataFormats.FileDrop, autoConvert: true).Should().BeTrue();
1543
dataObject.
GetDataPresent
(DataFormats.FileDrop, autoConvert: false).Should().BeTrue();
1544
dataObject.
GetDataPresent
("FileName", autoConvert: true).Should().BeTrue();
1545
dataObject.
GetDataPresent
("FileName", autoConvert: false).Should().BeFalse();
1546
dataObject.
GetDataPresent
("FileNameW", autoConvert: true).Should().BeTrue();
1547
dataObject.
GetDataPresent
("FileNameW", autoConvert: false).Should().BeFalse();
1602
dataObject.
GetDataPresent
(DataFormats.Bitmap, autoConvert: true).Should().BeTrue();
1603
dataObject.
GetDataPresent
(DataFormats.Bitmap, autoConvert: false).Should().BeTrue();
1604
dataObject.
GetDataPresent
(typeof(Bitmap).FullName, autoConvert: true).Should().BeTrue();
1605
dataObject.
GetDataPresent
(typeof(Bitmap).FullName, autoConvert: false).Should().BeFalse();
1606
dataObject.
GetDataPresent
(DataFormats.Dib, autoConvert: true).Should().BeFalse();
1607
dataObject.
GetDataPresent
(DataFormats.Dib, autoConvert: false).Should().BeFalse();
1676
dataObject.
GetDataPresent
(DataFormats.UnicodeText, autoConvert: true).Should().BeTrue();
1677
dataObject.
GetDataPresent
(DataFormats.UnicodeText, autoConvert: false).Should().BeTrue();
1678
dataObject.
GetDataPresent
(DataFormats.Text, autoConvert: true).Should().BeFalse();
1679
dataObject.
GetDataPresent
(DataFormats.Text, autoConvert: false).Should().BeFalse();
1680
dataObject.
GetDataPresent
(DataFormats.StringFormat, autoConvert: true).Should().BeFalse();
1681
dataObject.
GetDataPresent
(DataFormats.StringFormat, autoConvert: false).Should().BeFalse();
1682
dataObject.
GetDataPresent
(DataFormats.Rtf, autoConvert: true).Should().BeFalse();
1683
dataObject.
GetDataPresent
(DataFormats.Rtf, autoConvert: false).Should().BeFalse();
1684
dataObject.
GetDataPresent
(DataFormats.Html, autoConvert: true).Should().BeFalse();
1685
dataObject.
GetDataPresent
(DataFormats.Html, autoConvert: false).Should().BeFalse();
1686
dataObject.
GetDataPresent
(DataFormats.CommaSeparatedValue, autoConvert: true).Should().BeFalse();
1687
dataObject.
GetDataPresent
(DataFormats.CommaSeparatedValue, autoConvert: false).Should().BeFalse();
1755
dataObject.
GetDataPresent
(DataFormats.UnicodeText, autoConvert: true).Should().Be(expectedUnicodeText is not null);
1756
dataObject.
GetDataPresent
(DataFormats.UnicodeText, autoConvert: false).Should().Be(expectedUnicodeText is not null);
1757
dataObject.
GetDataPresent
(DataFormats.Text, autoConvert: true).Should().BeFalse();
1758
dataObject.
GetDataPresent
(DataFormats.Text, autoConvert: false).Should().BeFalse();
1759
dataObject.
GetDataPresent
(DataFormats.StringFormat, autoConvert: true).Should().BeFalse();
1760
dataObject.
GetDataPresent
(DataFormats.StringFormat, autoConvert: false).Should().BeFalse();
1761
dataObject.
GetDataPresent
(DataFormats.Rtf, autoConvert: true).Should().Be(expectedRtfText is not null);
1762
dataObject.
GetDataPresent
(DataFormats.Rtf, autoConvert: false).Should().Be(expectedRtfText is not null);
1763
dataObject.
GetDataPresent
(DataFormats.Html, autoConvert: true).Should().Be(expectedHtmlText is not null);
1764
dataObject.
GetDataPresent
(DataFormats.Html, autoConvert: false).Should().Be(expectedHtmlText is not null);
1765
dataObject.
GetDataPresent
(DataFormats.CommaSeparatedValue, autoConvert: true).Should().Be(expectedCsvText is not null);
1766
dataObject.
GetDataPresent
(DataFormats.CommaSeparatedValue, autoConvert: false).Should().Be(expectedCsvText is not null);