void getDomChanges(List<DomElement> result, WApplication app) { DomElement e = DomElement.getForUpdate(this, this.getDomElementType()); if (!this.isStubbed() && this.flags_.get(BIT_GRID_CHANGED)) { DomElement newE = this.createDomElement(app); e.replaceWith(newE); } else { if (this.rowsChanged_ != null) { for (Iterator<WTableRow> i_it = this.rowsChanged_.iterator(); i_it.hasNext(); ) { WTableRow i = i_it.next(); DomElement e2 = DomElement.getForUpdate(i, DomElementType.DomElement_TR); i.updateDom(e2, false); result.add(e2); } ; this.rowsChanged_ = null; } if (this.rowsAdded_ != 0) { DomElement etb = DomElement.getForUpdate(this.getId() + "tb", DomElementType.DomElement_TBODY); for (int i = 0; i < (int) this.rowsAdded_; ++i) { DomElement tr = this.createRow(this.getRowCount() - this.rowsAdded_ + i, true, app); etb.addChild(tr); } result.add(etb); this.rowsAdded_ = 0; } if (this.flags_.get(BIT_COLUMNS_CHANGED)) { for (int i = 0; i < this.columns_.size(); ++i) { DomElement e2 = DomElement.getForUpdate(this.columns_.get(i), DomElementType.DomElement_COL); this.columns_.get(i).updateDom(e2, false); result.add(e2); } this.flags_.clear(BIT_COLUMNS_CHANGED); } this.updateDom(e, false); } result.add(e); }