Clipboard Formats
Mikhail Cherkasov
mikhail.cherkasov at oracle.com
Sat Dec 22 13:42:06 PST 2012
Sounds like I don't have to dig native code, it's good news, thanks for
help.
23.12.2012 1:29, Mike Swingler пишет:
> On Dec 22, 2012, at 3:00 PM, Mikhail Cherkasov <mikhail.cherkasov at oracle.com> wrote:
>
>> Hello All,
>>
>> Jdk 7 has less data flavor types than jdk 6, the following types are missing from in jdk 7:
>> -text/plain; class=java.io.InputStream; charset=MacRoman
>> -text/plain; class=java.nio.ByteBuffer; charset=MacRoman
>> -text/plain; class="[B"; charset=MacRoman
>>
>> You can print available formats by this code:
>> for (final DataFlavor flavor : Toolkit.getDefaultToolkit().getSystemClipboard().getAvailableDataFlavors()) {
>> System.out.println(flavor.getMimeType());
>> }
>>
>> Does anyone know why this DataFlavors are absent in jdk 7?
>> And is it possible to get them back? if yes, how I can do this?
>>
>> I have not idea where to get jdk6 source code for macos, so I can't compare
>> Java_sun_lwawt_macosx_CClipboard_getClipboardFormats method implementation.
> Java_sun_lwawt_macosx_CClipboard_getClipboardFormats() and Java_apple_awt_CClipboard_getClipboardFormats() in Java SE 6 are line-for-line copies of each other. Also, CClipboard.m in OpenJDK 8 is largely identical to the original version created in 2002 by Scott Kovatch. :-)
>
> I have noticed that the flavormap.properties file is significantly different. Perhaps that would be a fruitful area of investigation.
>
> Regards,
> Mike Swingler
> Apple Inc.
>
More information about the macosx-port-dev
mailing list