Commit 0bcf3158 authored by Laurent Montel's avatar Laurent Montel 😁
Browse files

Add script to remove style

parent 5c334acf
......@@ -148,11 +148,13 @@ QString WebEngineScript::scrollToPosition(const QPoint &pos)
return source;
}
QString WebEngineScript::removeStyleToElement(const QString &element)
QString WebEngineScript::removeStyleToElement(const QString &elementStr)
{
qDebug()<< "QString WebEngineScript::removeStyleToElement(const QString &element) not implemented";
//TODO
return {};
const QString source = QString::fromLatin1("var element = document.getElementById('%1'); "
"if (element) { "
" element.removeAttribute(\"style\");"
"}").arg(elementStr);
return source;
}
QString WebEngineScript::setStyleToElement(const QString &elementStr, const QString &style)
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment