Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

Already on GitHub? Sign in to your account

Update library/pyjamas/ui/UIObject.py #775

Merged
merged 1 commit into from Oct 23, 2012

Conversation

Projects
None yet
2 participants
Contributor

joaoventura commented Sep 11, 2012

Add methods for returning the clientHeight and clientWidth properties of a UI object.

Update library/pyjamas/ui/UIObject.py
Added methods for returning the clientHeight and clientWidth of a UI object.
Member

anthonyrisinger commented Sep 24, 2012

i know it took forever and a day to respond to this -- sorry about that.

this should be fine, and matches the DOM spec ... however, clientWidth and clientHeight are DOM operations, and as such they need to be implemented in DOM.py, and then called from ui/UIObject.py.

eg, UIObject.getOffsetWidth should be calling DOM.getOffsetWidth (but [incorrectly] doesn't), so look instead at UIObject.getAbsoluteTop or UIObject.getAbsoluteLeft for an example of what i mean -- should be a quick change.

thanks João!

Member

anthonyrisinger commented Oct 23, 2012

LGTM, thanks @joaoventura!

anthonyrisinger added a commit that referenced this pull request Oct 23, 2012

Merge pull request #775 from joaoventura/patch-1
add `UIObject.getClientWidth` and `UIObject.getClientHeight`

(might be pushed down to DOM.py [low-level ops exported by all browsers])

@anthonyrisinger anthonyrisinger merged commit 52636dc into pyjs:master Oct 23, 2012

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment