Ver código fonte

Allow setting an id on labels

Neal Wilson 8 anos atrás
pai
commit
52b0f99e43
1 arquivos alterados com 4 adições e 0 exclusões
  1. 4
    0
      src/typica.w

+ 4
- 0
src/typica.w Ver arquivo

5244
                 QLabel *label = new QLabel(QCoreApplication::translate(
5244
                 QLabel *label = new QLabel(QCoreApplication::translate(
5245
                     "configuration",
5245
                     "configuration",
5246
                     currentElement.text().toUtf8().data()));
5246
                     currentElement.text().toUtf8().data()));
5247
+                if(currentElement.hasAttribute("id"))
5248
+                {
5249
+                    label->setObjectName(currentElement.attribute("id"));
5250
+                }
5247
                 layout->addWidget(label);
5251
                 layout->addWidget(label);
5248
             }
5252
             }
5249
             else if(currentElement.tagName() == "lcdtemperature")
5253
             else if(currentElement.tagName() == "lcdtemperature")

Carregando…
Cancelar
Salvar