Mercurial > dwindows
changeset 951:7193401d139a
Added support for dw_window_get_pos_size() to work on individual controls on Mac.
author | bsmith@81767d24-ef19-dc11-ae90-00e081727c95 |
---|---|
date | Sun, 01 May 2011 04:40:24 +0000 |
parents | 73ff2daed8ca |
children | abb9203adc05 |
files | mac/dw.m |
diffstat | 1 files changed, 14 insertions(+), 0 deletions(-) [+] |
line wrap: on
line diff
--- a/mac/dw.m Sun May 01 03:31:40 2011 +0000 +++ b/mac/dw.m Sun May 01 04:40:24 2011 +0000 @@ -7586,6 +7586,20 @@ *height = rect.size.height; return; } + else if([ object isKindOfClass:[ NSControl class ] ]) + { + NSControl *control = handle; + NSRect rect = [control frame]; + if(x) + *x = rect.origin.x; + if(y) + *y = rect.origin.y; + if(width) + *width = rect.size.width; + if(height) + *height = rect.size.height; + return; + } } /*