1 | svoid extendRectToIncludePoint_modifyOriginal(Rect r, int x, int y) { |
2 | if (x < r.x) { int diff = r.x-x; r.x -= diff; r.w += diff; } |
3 | if (x >= r.x2()) { int diff = x-r.x2(); r.w += diff; } |
4 | if (y < r.y) { int diff = r.y-y; r.y -= diff; r.h += diff; } |
5 | if (y >= r.y2()) { int diff = y-r.y2(); r.h += diff; } |
6 | } |
download show line numbers debug dex old transpilations
Travelled to 12 computer(s): bhatertpkbcr, cbybwowwnfue, cfunsshuasjs, gwrvuhgaqvyk, irmadwmeruwu, ishqpsrjomds, lpdgvwnxivlt, mqqgnosmbjvj, pyentgdyhuwx, pzhvpgtvlbxg, tvejysmllsmz, vouqrxazstgt
No comments. add comment
Snippet ID: | #1019583 |
Snippet name: | extendRectToIncludePoint_modifyOriginal |
Eternal ID of this version: | #1019583/2 |
Text MD5: | c64c76a434dc7e3ee369fd8658439571 |
Author: | stefan |
Category: | javax |
Type: | JavaX fragment (include) |
Public (visible to everyone): | Yes |
Archived (hidden from active list): | No |
Created/modified: | 2018-11-12 23:32:31 |
Source code size: | 316 bytes / 6 lines |
Pitched / IR pitched: | No / No |
Views / Downloads: | 254 / 313 |
Version history: | 1 change(s) |
Referenced in: | [show references] |