mirror of
https://github.com/subsurface/subsurface.git
synced 2025-02-19 22:16:15 +00:00
Add QMLManager class
Add a QMLManager class. This class will be used as a link between the C++ and QML aspects of the mobile application. Signed-off-by: Grace Karanja <gracie.karanja89@gmail.com> Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
This commit is contained in:
parent
6ba5b45c00
commit
59be048549
2 changed files with 62 additions and 0 deletions
31
qt-mobile/qmlmanager.cpp
Normal file
31
qt-mobile/qmlmanager.cpp
Normal file
|
@ -0,0 +1,31 @@
|
|||
#include "qmlmanager.h"
|
||||
|
||||
|
||||
QMLManager::QMLManager()
|
||||
{
|
||||
|
||||
}
|
||||
|
||||
|
||||
QMLManager::~QMLManager()
|
||||
{
|
||||
|
||||
}
|
||||
|
||||
QString QMLManager::filename()
|
||||
{
|
||||
return m_fileName;
|
||||
}
|
||||
|
||||
void QMLManager::setFilename(const QString &f)
|
||||
{
|
||||
m_fileName = f;
|
||||
emit filenameChanged();
|
||||
loadFile();
|
||||
}
|
||||
|
||||
void QMLManager::loadFile()
|
||||
{
|
||||
QUrl url(m_fileName);
|
||||
QString strippedFileName = url.toLocalFile();
|
||||
}
|
Loading…
Add table
Add a link
Reference in a new issue