void Signaltypes::reload_types() { bool exists; QDomElement *root; root = getRootElement(); if(root == NULL) return; // probably already threw the appropriate error. for(QDomElement new_type = root->firstChildElement("Signaltype"); not new_type.isNull(); new_type = new_type.nextSiblingElement("Signaltype")) { exists = false; if ( not new_type.hasAttribute("Name") ) { QMessageBox::information(parent->mainwindow, tr("Signaltypes"), tr("%1 has no Name attribute.").arg(new_type.tagName()) ); continue; } for(unsigned i=0; i<types.size(); i++) { if(types[i]->name == new_type.attribute("Name")) { exists = true; delete types[i]; types[i] = new Signaltype(this, &new_type); break; } } if(not exists) { types.push_back( new Signaltype(this, &new_type) ); } } }
void Client::loadTopLevelWindows() { Element* root = getRootElement(); if (root) { future = QtConcurrent::run(this, &Client::getImmediateChildren, root, true); watcher.setFuture(future); } }
void Signaltypes::load_types() { reset(); QDomElement *root = getRootElement(); if(root == NULL) return; // probably already threw the appropriate error. for(QDomElement child = root->firstChildElement("Signaltype"); not child.isNull(); child = child.nextSiblingElement("Signaltype")) { types.push_back( new Signaltype(this, &child) ); } delete root; }
ElementPtr Node::getRootElementChecked() const throw(Exceptions::CheckFailed) { ElementPtr result = getRootElement(); ZS_THROW_CUSTOM_IF(Exceptions::CheckFailed, !result) return result; }
void AccessibilityController::rootElementGetterCallback(CppVariant* result) { result->set(*(getRootElement()->getAsCppVariant())); }
void TransactionalDocument::triggerDomEventDocument ( XProcessor& xproc, DomEventType domEventType ) { ElementRef root = getRootElement(); processDomEvent ( xproc, domEventType, root ); }
void XMLTree::log(Log::ModuleId logModule, Log::Level level) const { if (Log::isLevelEnabled(logModule, level)) { getRootElement().log(logModule, level); } }