Mercurial > projects > dwt2
diff org.eclipse.swt.win32.win32.x86/src/org/eclipse/swt/internal/image/FileFormat.d @ 22:4642ab680468
some work on dwt-win for tango/phobos
author | Frank Benoit <benoit@tionex.de> |
---|---|
date | Fri, 20 Mar 2009 12:52:28 +0100 |
parents | f36c67707cb3 |
children | 536e43f63c81 |
line wrap: on
line diff
--- a/org.eclipse.swt.win32.win32.x86/src/org/eclipse/swt/internal/image/FileFormat.d Thu Mar 19 20:38:55 2009 +0100 +++ b/org.eclipse.swt.win32.win32.x86/src/org/eclipse/swt/internal/image/FileFormat.d Fri Mar 20 12:52:28 2009 +0100 @@ -32,7 +32,11 @@ import org.eclipse.swt.internal.image.JPEGFileFormat; import org.eclipse.swt.internal.image.PNGFileFormat; -import tango.core.Tuple; +version(Tango){ + import tango.core.Tuple; +} else { // Phobos + import std.typetuple; +} /** * Abstract factory class for loading/unloading images from files or streams @@ -43,7 +47,12 @@ static const String FORMAT_PACKAGE = "org.eclipse.swt.internal.image"; //$NON-NLS-1$ static const String FORMAT_SUFFIX = "FileFormat"; //$NON-NLS-1$ static const String[] FORMATS = [ "WinBMP"[], "WinBMP", "GIF", "WinICO", "JPEG", "PNG", "TIFF", "OS2BMP" ]; //$NON-NLS-1$//$NON-NLS-2$ //$NON-NLS-3$ //$NON-NLS-4$//$NON-NLS-5$ //$NON-NLS-6$//$NON-NLS-7$//$NON-NLS-8$ - alias Tuple!( WinBMPFileFormat, WinBMPFileFormat, GIFFileFormat, WinICOFileFormat, JPEGFileFormat, PNGFileFormat, TIFFFileFormat, OS2BMPFileFormat ) TFormats; + version(Tango){ + alias Tuple!( WinBMPFileFormat, WinBMPFileFormat, GIFFileFormat, WinICOFileFormat, JPEGFileFormat, PNGFileFormat, TIFFFileFormat, OS2BMPFileFormat ) TFormats; + } else { // Phobos + alias TypeTuple!( WinBMPFileFormat, WinBMPFileFormat, GIFFileFormat, WinICOFileFormat, JPEGFileFormat, PNGFileFormat, TIFFFileFormat, OS2BMPFileFormat ) TFormats; + } + LEDataInputStream inputStream; LEDataOutputStream outputStream; ImageLoader loader;