Opened 13 years ago

Closed 13 years ago

Last modified 12 years ago

#551 closed defect (fixed)

New method: dojo.style.setStyleAttributes()

Reported by: wolfram.kriesing@… Owned by: Tom Trenka
Priority: high Milestone:
Component: Core Version: 0.2
Keywords: Cc:
Blocked By: Blocking:

Description

Set the given style attributes for the node. Ie. dojo.style.setStyleAttributes(myNode, "position:absolute; left:10px; top:10px;") This just makes it easier to set a style directly without the need to override it completely (as node.setAttribute() would). If there is a dojo-method for an attribute, like for "opacity" there is setOpacity, the dojo method is called instead. For example: dojo.style.setStyleAttributes(myNode, "opacity: .4"); Additionally all the dojo.style.set* methods can also be used. Ie. when attributes contains "outer-height: 10;" it will call dojo.style.setOuterHeight("10");

Attachments (1)

style.diff (1.8 KB) - added by wolfram.kriesing@… 13 years ago.
patch

Download all attachments as: .zip

Change History (6)

Changed 13 years ago by wolfram.kriesing@…

Attachment: style.diff added

patch

comment:1 Changed 13 years ago by Tom Trenka

Resolution: invalid
Status: newclosed

Wolfram, Thanks for the submission. However, unless you've filed a CLA with the Dojo Foundation, we can't take the patch (our apologies, but we have to be very careful about contributed code ownership, etc. etc.).

Also we're looking to refactor style.js at this point.

If you'd like to submit a CLA to the Dojo Foundation (instructions on the dojotoolkit.org site) and resubmit the patch for a later release (marked 0.4 or higher please), that'd be great--looks like there might be some use for it.

Tom Trenka

comment:2 Changed 13 years ago by alex

Milestone: 0.3.1
Resolution: invalid
Status: closedreopened

Tom: we have a CLA on file for Wolfram.

Regardless of whether or not he had sent a CLA, marking a bug that includes a patch as invalid is a bad thing to do. Discouraging patch submission is the last thing we want.

I'm re-opening and assigning to you to merge.

comment:3 Changed 13 years ago by alex

Owner: changed from anonymous to Tom Trenka
Status: reopenednew

comment:4 Changed 13 years ago by Tom Trenka

Resolution: fixed
Status: newclosed

Diff applied. Might be nice for committers to have access to a list of people who filed CLAs (or at least an indicator that the diff submitted is acceptable for committal), so that in doing bug triage we have a better idea of what patches can be accepted.

comment:5 Changed 12 years ago by (none)

Milestone: 0.3.1

Milestone 0.3.1 deleted

Note: See TracTickets for help on using tickets.