old-commit-hash: d78546afbd91bcbf2f6c147eac3f30c3db31a09d
This commit is contained in:
iejMac
2021-03-25 17:09:23 -07:00
committed by GitHub
parent 0d5dec9276
commit 0f1140931f
+3 -1
View File
@@ -60,7 +60,7 @@ TermsPage::TermsPage(QWidget *parent) : QFrame(parent){
main_layout->setMargin(40);
main_layout->setSpacing(40);
QQuickWidget *text = new QQuickWidget(QUrl::fromLocalFile("qt/offroad/text_view.qml"), this);
QQuickWidget *text = new QQuickWidget(this);
text->setResizeMode(QQuickWidget::SizeRootObjectToView);
text->setSizePolicy(QSizePolicy::Expanding, QSizePolicy::Expanding);
text->setAttribute(Qt::WA_AlwaysStackOnTop);
@@ -71,6 +71,8 @@ TermsPage::TermsPage(QWidget *parent) : QFrame(parent){
QString text_view = util::read_file("../assets/offroad/tc.html").c_str();
text->rootContext()->setContextProperty("text_view", text_view);
text->setSource(QUrl::fromLocalFile("qt/offroad/text_view.qml"));
main_layout->addWidget(text);
// TODO: add decline page