Desktop: simple window with tuner intergration
This commit is contained in:
parent
d41035ecc2
commit
8815fd2b65
2 changed files with 16 additions and 2 deletions
|
@ -1,4 +1,16 @@
|
|||
import QtQuick 2.0
|
||||
import LJTuner 1.0
|
||||
|
||||
Item {
|
||||
anchors.fill: parent
|
||||
Tuner {
|
||||
id: tuner
|
||||
running: true
|
||||
}
|
||||
Text {
|
||||
text: tuner.freq.toFixed(2) + " Hz"
|
||||
font.pixelSize: parent.height / 4
|
||||
anchors.horizontalCenter: parent.horizontalCenter
|
||||
anchors.verticalCenter: parent.verticalCenter
|
||||
}
|
||||
}
|
||||
|
|
|
@ -2,9 +2,11 @@
|
|||
#include <QQuickView>
|
||||
#include <QtQml>
|
||||
|
||||
int main(int argc, char* argv[])
|
||||
#include "Tuner.hpp"
|
||||
|
||||
Q_DECL_EXPORT int main(int argc, char* argv[])
|
||||
{
|
||||
// qmlRegisterType<DBMeter>("LJDBMeter", 1, 0, "DBMeter");
|
||||
qmlRegisterType<Tuner>("LJTuner", 1, 0, "Tuner");
|
||||
|
||||
QGuiApplication app(argc, argv);
|
||||
QQuickView view;
|
||||
|
|
Loading…
Reference in a new issue