diff options
author | Dianne Hackborn <hackbod@google.com> | 2010-07-09 11:44:11 -0700 |
---|---|---|
committer | Dianne Hackborn <hackbod@google.com> | 2010-07-09 16:58:19 -0700 |
commit | 289b9b62372ef52a06113b83dfb870e2c2fb325a (patch) | |
tree | e444446a331fdbe9b936a0c2570a609675468d05 /libs | |
parent | 2aaa9e9fc5ddc05cedbe530c7a41eca0e3a62b7a (diff) | |
download | frameworks_base-289b9b62372ef52a06113b83dfb870e2c2fb325a.zip frameworks_base-289b9b62372ef52a06113b83dfb870e2c2fb325a.tar.gz frameworks_base-289b9b62372ef52a06113b83dfb870e2c2fb325a.tar.bz2 |
Add ANativeWindow API for directly drawing to the surface bits.
Also other cleanup and fixes:
- We now properly set the default window format to 565.
- New APIs to set the window format and flags from native code.
- Tweaked glue for simpler handling of the "destroy" message.
- Um, other stuff.
Change-Id: Id7790a21a2fa9a19b91854d225324a7c1e7c6ade
Diffstat (limited to 'libs')
-rw-r--r-- | libs/ui/Rect.cpp | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/libs/ui/Rect.cpp b/libs/ui/Rect.cpp index 66b9576..5694e00 100644 --- a/libs/ui/Rect.cpp +++ b/libs/ui/Rect.cpp @@ -18,11 +18,11 @@ namespace android { -static inline int min(int a, int b) { +static inline int32_t min(int32_t a, int32_t b) { return (a<b) ? a : b; } -static inline int max(int a, int b) { +static inline int32_t max(int32_t a, int32_t b) { return (a>b) ? a : b; } @@ -53,7 +53,7 @@ bool Rect::operator < (const Rect& rhs) const return false; } -Rect& Rect::offsetTo(int x, int y) +Rect& Rect::offsetTo(int32_t x, int32_t y) { right -= left - x; bottom -= top - y; @@ -62,7 +62,7 @@ Rect& Rect::offsetTo(int x, int y) return *this; } -Rect& Rect::offsetBy(int x, int y) +Rect& Rect::offsetBy(int32_t x, int32_t y) { left += x; top += y; |