Justin Baker
Justin Baker
Perhaps macros(at least the functionality) can be created with grasp?
...? What ? Is this even an issue?
I couldn't reproduce this. I got the memo var using this code https://gist.github.com/7cb1aa3cdcec59517abc
Why are you creating a new div element? And why insert it at all if new_content wasn't even supplied as an argument?
The content is inserted in "ui-dialog-content" div, and isn't padded at all by an extra div. Inserting new div's every time the content is change wouldn't really be a good...
Actually, I'm wrong. What you're doing is inserting another div into the content div rather than updating the content inside the content div. setContent: function(new_content) { if(new_content){ this.element.select('.ui-widget-content').first().update(new_content); } },...
No, with the above code I posted it would update the innerHTML of the content. No wrapper needed.
That would mean that no content was supplied originally. Also, wouldn't ".ui-dialog-content" be better? The content div has both classes.
I would see if the content is blank, and if so, create the dialog-content div and insert it into the dialog's element, otherwise change the value of the dialog-content div
Doesn't it already do that? https://github.com/madrobby/scripty2/blob/master/src/ui/controls/dialog.js#L169