mirror of
https://github.com/qelectrotech/qelectrotech-source-mirror.git
synced 2025-12-23 10:30:53 +01:00
Replace foreach function by for, please try and report problem
git-svn-id: svn+ssh://svn.tuxfamily.org/svnroot/qet/qet/trunk@4900 bfdf4180-ca20-0410-9c96-a3a8aa849046
This commit is contained in:
@@ -211,7 +211,7 @@ QList<Terminal *> CustomElement::terminals() const {
|
||||
/// @return la liste des conducteurs rattaches a cet element
|
||||
QList<Conductor *> CustomElement::conductors() const {
|
||||
QList<Conductor *> conductors;
|
||||
foreach(Terminal *t, list_terminals) conductors << t -> conductors();
|
||||
for (Terminal *t: list_terminals) conductors << t -> conductors();
|
||||
return(conductors);
|
||||
}
|
||||
|
||||
@@ -850,7 +850,7 @@ void CustomElement::setPainterStyle(QDomElement &e, QPainter &qp) {
|
||||
|
||||
// agit sur le QPen et la QBrush en fonction des valeurs rencontrees
|
||||
QRegExp rx("^\\s*([a-z-]+)\\s*:\\s*([a-z-]+)\\s*$");
|
||||
foreach (QString style, styles) {
|
||||
for (QString style: styles) {
|
||||
if (rx.exactMatch(style)) {
|
||||
QString style_name = rx.cap(1);
|
||||
QString style_value = rx.cap(2);
|
||||
@@ -988,7 +988,7 @@ ElementTextItem* CustomElement::setTaggedText(const QString &tagg, const QString
|
||||
* @param tagg
|
||||
*/
|
||||
ElementTextItem* CustomElement::taggedText(const QString &tagg) const {
|
||||
foreach (ElementTextItem *eti, list_texts_) {
|
||||
for (ElementTextItem *eti: list_texts_) {
|
||||
if (eti -> tagg() == tagg) return eti;
|
||||
}
|
||||
return NULL;
|
||||
|
||||
Reference in New Issue
Block a user