Mercurial > projects > dwt-mac
comparison dwt/internal/image/JPEGAppn.d @ 34:5123b17c98ef
Ported dwt.events.*, dwt.graphics.GC, Region, dwt.internal.image.*
author | Jacob Carlborg <doob@me.com> <jacob.carlborg@gmail.com> |
---|---|
date | Sun, 14 Sep 2008 01:45:57 +0200 |
parents | 1a8b3cb347e0 |
children |
comparison
equal
deleted
inserted
replaced
33:965ac0a77267 | 34:5123b17c98ef |
---|---|
5 * which accompanies this distribution, and is available at | 5 * which accompanies this distribution, and is available at |
6 * http://www.eclipse.org/legal/epl-v10.html | 6 * http://www.eclipse.org/legal/epl-v10.html |
7 * | 7 * |
8 * Contributors: | 8 * Contributors: |
9 * IBM Corporation - initial API and implementation | 9 * IBM Corporation - initial API and implementation |
10 * Port to the D programming language: | |
11 * Frank Benoit <benoit@tionex.de> | |
10 *******************************************************************************/ | 12 *******************************************************************************/ |
11 module dwt.internal.image; | 13 module dwt.internal.image.JPEGAppn; |
12 | 14 |
15 import dwt.internal.image.JPEGVariableSizeSegment; | |
16 import dwt.internal.image.JPEGFileFormat; | |
17 import dwt.internal.image.LEDataInputStream; | |
13 | 18 |
14 final class JPEGAppn : JPEGVariableSizeSegment { | 19 final class JPEGAppn : JPEGVariableSizeSegment { |
15 | 20 |
16 public this(byte[] reference) { | 21 public this(byte[] reference) { |
17 super(reference); | 22 super(reference); |
18 } | 23 } |
19 | 24 |
20 public this(LEDataInputStream byteStream) { | 25 public this(LEDataInputStream byteStream) { |
21 super(byteStream); | 26 super(byteStream); |
22 } | 27 } |
23 | 28 |
24 public bool verify() { | 29 public override bool verify() { |
25 int marker = getSegmentMarker(); | 30 int marker = getSegmentMarker(); |
26 return marker >= JPEGFileFormat.APP0 && marker <= JPEGFileFormat.APP15; | 31 return marker >= JPEGFileFormat.APP0 && marker <= JPEGFileFormat.APP15; |
27 } | 32 } |
28 } | 33 } |