Mercurial > projects > dwt-mac
comparison dwt/layout/FormData.d @ 7:e831403a80a9
Add 'cast' to casts
author | Frank Benoit <benoit@tionex.de> |
---|---|
date | Wed, 27 Aug 2008 14:30:35 +0200 |
parents | 1a8b3cb347e0 |
children | fbe68c33eeee |
comparison
equal
deleted
inserted
replaced
6:b903c16b6f48 | 7:e831403a80a9 |
---|---|
170 } | 170 } |
171 } | 171 } |
172 } | 172 } |
173 if (bottomControl is null) return cacheBottom = bottom; | 173 if (bottomControl is null) return cacheBottom = bottom; |
174 isVisited = true; | 174 isVisited = true; |
175 FormData bottomData = (FormData) bottomControl.getLayoutData (); | 175 FormData bottomData = cast(FormData) bottomControl.getLayoutData (); |
176 FormAttachment bottomAttachment = bottomData.getBottomAttachment (bottomControl, spacing, flushCache); | 176 FormAttachment bottomAttachment = bottomData.getBottomAttachment (bottomControl, spacing, flushCache); |
177 switch (bottom.alignment) { | 177 switch (bottom.alignment) { |
178 case DWT.BOTTOM: | 178 case DWT.BOTTOM: |
179 cacheBottom = bottomAttachment.plus (bottom.offset); | 179 cacheBottom = bottomAttachment.plus (bottom.offset); |
180 break; | 180 break; |
211 } | 211 } |
212 } | 212 } |
213 } | 213 } |
214 if (leftControl is null) return cacheLeft = left; | 214 if (leftControl is null) return cacheLeft = left; |
215 isVisited = true; | 215 isVisited = true; |
216 FormData leftData = (FormData) leftControl.getLayoutData (); | 216 FormData leftData = cast(FormData) leftControl.getLayoutData (); |
217 FormAttachment leftAttachment = leftData.getLeftAttachment (leftControl, spacing, flushCache); | 217 FormAttachment leftAttachment = leftData.getLeftAttachment (leftControl, spacing, flushCache); |
218 switch (left.alignment) { | 218 switch (left.alignment) { |
219 case DWT.LEFT: | 219 case DWT.LEFT: |
220 cacheLeft = leftAttachment.plus (left.offset); | 220 cacheLeft = leftAttachment.plus (left.offset); |
221 break; | 221 break; |
258 } | 258 } |
259 } | 259 } |
260 } | 260 } |
261 if (rightControl is null) return cacheRight = right; | 261 if (rightControl is null) return cacheRight = right; |
262 isVisited = true; | 262 isVisited = true; |
263 FormData rightData = (FormData) rightControl.getLayoutData (); | 263 FormData rightData = cast(FormData) rightControl.getLayoutData (); |
264 FormAttachment rightAttachment = rightData.getRightAttachment (rightControl, spacing, flushCache); | 264 FormAttachment rightAttachment = rightData.getRightAttachment (rightControl, spacing, flushCache); |
265 switch (right.alignment) { | 265 switch (right.alignment) { |
266 case DWT.RIGHT: | 266 case DWT.RIGHT: |
267 cacheRight = rightAttachment.plus (right.offset); | 267 cacheRight = rightAttachment.plus (right.offset); |
268 break; | 268 break; |
299 } | 299 } |
300 } | 300 } |
301 } | 301 } |
302 if (topControl is null) return cacheTop = top; | 302 if (topControl is null) return cacheTop = top; |
303 isVisited = true; | 303 isVisited = true; |
304 FormData topData = (FormData) topControl.getLayoutData (); | 304 FormData topData = cast(FormData) topControl.getLayoutData (); |
305 FormAttachment topAttachment = topData.getTopAttachment (topControl, spacing, flushCache); | 305 FormAttachment topAttachment = topData.getTopAttachment (topControl, spacing, flushCache); |
306 switch (top.alignment) { | 306 switch (top.alignment) { |
307 case DWT.TOP: | 307 case DWT.TOP: |
308 cacheTop = topAttachment.plus (top.offset); | 308 cacheTop = topAttachment.plus (top.offset); |
309 break; | 309 break; |