The Ribbon control is very nice. Once again - great work!!!
I need a calendar item type. I am going to try a workaround, it would save so much time if it was a part of the ribbon.
Also is there a way to adjust the height of the ribbon when it is attached to a layout?
as in:
var rib = layout.attachRibbon( {...} )
Here’s a few prototypes I needed. These do not handle every type yet, for example checkboxes and combo. As I use them I’ll add the logic. In the meantime, thought this may be helpful to others:
dhtmlXRibbon.prototype.setValues = function(obj){
var typ
for (var prop in obj){
typ = this.getItemType(prop);
if (typ == 'input') this.setValue(prop, obj[prop]);
if (typ == 'text') this.setItemText(prop, obj[prop]);
}
}
dhtmlXRibbon.prototype.dirty = function(obj){
var typ
for (var prop in obj){
typ = this.getItemType(prop);
if (typ == 'input' && obj[prop] != this.getValue(prop) )
return true;
}
return false;
}