Rev 1540 | Rev 1563 | Go to most recent revision | Show entire file | Regard whitespace | Details | Blame | Last modification | View Log | RSS feed
Rev 1540 | Rev 1550 | ||
---|---|---|---|
Line 4... | Line 4... | ||
4 | ;; Copyright (C) MenuetOS 2000-2004 Ville Mikael Turjanmaa ;; |
4 | ;; Copyright (C) MenuetOS 2000-2004 Ville Mikael Turjanmaa ;; |
5 | ;; Distributed under terms of the GNU General Public License ;; |
5 | ;; Distributed under terms of the GNU General Public License ;; |
6 | ;; ;; |
6 | ;; ;; |
7 | ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; |
7 | ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; |
Line 8... | Line 8... | ||
8 | 8 | ||
Line 9... | Line 9... | ||
9 | $Revision: 1540 $ |
9 | $Revision: 1550 $ |
10 | 10 | ||
11 | ;============================================================================== |
11 | ;============================================================================== |
Line 1221... | Line 1221... | ||
1221 | ;> edi = pointer to WDATA struct |
1221 | ;> edi = pointer to WDATA struct |
1222 | ;------------------------------------------------------------------------------ |
1222 | ;------------------------------------------------------------------------------ |
1223 | push eax ebx |
1223 | push eax ebx |
Line 1224... | Line 1224... | ||
1224 | 1224 | ||
- | 1225 | ; TODO: do we really need `draw_limits`? |
|
1225 | ; TODO: do we really need `draw_limits`? |
1226 | ; Yes, they are used by background drawing code. |
1226 | mov ecx, [eax + BOX.left] |
1227 | mov ecx, [eax + BOX.left] |
1227 | mov edx, [ebx + BOX.left] |
1228 | mov edx, [ebx + BOX.left] |
1228 | cmp ecx, edx |
1229 | cmp ecx, edx |
1229 | jle @f |
1230 | jle @f |
1230 | xchg ecx, edx |
1231 | mov ecx, edx |
- | 1232 | @@: mov [draw_limits.left], ecx |
|
1231 | @@: mov [draw_limits.left], ecx |
1233 | mov ecx, [eax + BOX.left] |
1232 | mov ecx, [eax + BOX.width] |
1234 | add ecx, [eax + BOX.width] |
- | 1235 | add edx, [ebx + BOX.width] |
|
1233 | cmp ecx, [ebx + BOX.width] |
1236 | cmp ecx, edx |
1234 | jae @f |
- | |
1235 | mov ecx, [ebx + BOX.width] |
1237 | jae @f |
1236 | @@: add ecx, edx |
1238 | mov ecx, edx |
1237 | mov [draw_limits.right], ecx |
1239 | @@: mov [draw_limits.right], ecx |
1238 | mov ecx, [eax + BOX.top] |
1240 | mov ecx, [eax + BOX.top] |
1239 | mov edx, [ebx + BOX.top] |
1241 | mov edx, [ebx + BOX.top] |
1240 | cmp ecx, edx |
1242 | cmp ecx, edx |
1241 | jle @f |
1243 | jle @f |
1242 | xchg ecx, edx |
1244 | mov ecx, edx |
- | 1245 | @@: mov [draw_limits.top], ecx |
|
1243 | @@: mov [draw_limits.top], ecx |
1246 | mov ecx, [eax + BOX.top] |
1244 | mov ecx, [eax + BOX.height] |
1247 | add ecx, [eax + BOX.height] |
- | 1248 | add edx, [ebx + BOX.height] |
|
1245 | cmp ecx, [ebx + BOX.height] |
1249 | cmp ecx, edx |
1246 | jae @f |
- | |
1247 | mov ecx, [ebx + BOX.height] |
1250 | jae @f |
1248 | @@: add ecx, edx |
1251 | mov ecx, edx |
Line 1249... | Line 1252... | ||
1249 | mov [draw_limits.bottom], ecx |
1252 | @@: mov [draw_limits.bottom], ecx |
1250 | 1253 | ||
1251 | ; recalculate screen buffer at old position |
1254 | ; recalculate screen buffer at old position |
1252 | push ebx |
1255 | push ebx |