mirror of
https://gitlab.com/eql/lqml.git
synced 2025-12-06 02:30:38 -08:00
revisions
This commit is contained in:
parent
9114e28b92
commit
fc662c4f48
16 changed files with 37 additions and 39 deletions
|
|
@ -49,6 +49,7 @@ ios {
|
||||||
}
|
}
|
||||||
|
|
||||||
LIBS += -llqml -llisp -Ltmp -lapp
|
LIBS += -llqml -llisp -Ltmp -lapp
|
||||||
|
HEADERS += ../../src/cpp/main.h
|
||||||
SOURCES += ../../src/cpp/main.cpp
|
SOURCES += ../../src/cpp/main.cpp
|
||||||
|
|
||||||
RESOURCES = $$files(qml/*)
|
RESOURCES = $$files(qml/*)
|
||||||
|
|
|
||||||
|
|
@ -57,6 +57,7 @@ ios {
|
||||||
}
|
}
|
||||||
|
|
||||||
LIBS += -llqml -llisp -Ltmp -lapp
|
LIBS += -llqml -llisp -Ltmp -lapp
|
||||||
|
HEADERS += ../../src/cpp/main.h
|
||||||
SOURCES += ../../src/cpp/main.cpp
|
SOURCES += ../../src/cpp/main.cpp
|
||||||
|
|
||||||
RESOURCES = $$files(qml/*)
|
RESOURCES = $$files(qml/*)
|
||||||
|
|
|
||||||
|
|
@ -14,6 +14,10 @@ Important note
|
||||||
(see also `src/mkdirs.sh`) and rebuild the whole library for every single
|
(see also `src/mkdirs.sh`) and rebuild the whole library for every single
|
||||||
platform.
|
platform.
|
||||||
|
|
||||||
|
You may find that an example won't work anymore after upgrading LQML. This is
|
||||||
|
probably due to internal changes, so you better wipe off the whole example and
|
||||||
|
start over.
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
Build executable
|
Build executable
|
||||||
|
|
|
||||||
|
|
@ -8,9 +8,9 @@ reloading QML.*
|
||||||
doesn't depend on Swank, and should therefore also be stable (it uses a local
|
doesn't depend on Swank, and should therefore also be stable (it uses a local
|
||||||
trivial web server).*
|
trivial web server).*
|
||||||
|
|
||||||
*You may even run both the desktop and mobile device auto reload simultaneously
|
*You may even run both desktop and (one or more) mobile device auto reloads
|
||||||
(`swank-server` example only), because they both watch/load the same QML
|
simultaneously (`swank-server` example only), because they all watch/load the
|
||||||
sources.*
|
same QML sources, if they point to the same desktop IP*
|
||||||
|
|
||||||
|
|
||||||
QML Preview and Slime
|
QML Preview and Slime
|
||||||
|
|
|
||||||
|
|
@ -1,5 +1,4 @@
|
||||||
#ifndef ECL_EXT_H
|
#pragma once
|
||||||
#define ECL_EXT_H
|
|
||||||
|
|
||||||
#undef SLOT
|
#undef SLOT
|
||||||
|
|
||||||
|
|
@ -87,5 +86,3 @@ void iniCLFunctions();
|
||||||
void error_msg(const char*, cl_object);
|
void error_msg(const char*, cl_object);
|
||||||
|
|
||||||
QT_END_NAMESPACE
|
QT_END_NAMESPACE
|
||||||
|
|
||||||
#endif
|
|
||||||
|
|
|
||||||
|
|
@ -1,8 +1,7 @@
|
||||||
// header to be included in external Qt libraries
|
// header to be included in external Qt libraries
|
||||||
// for calling ECL functions from Qt
|
// for calling ECL functions from Qt
|
||||||
|
|
||||||
#ifndef ECL_FUN_H
|
#pragma once
|
||||||
#define ECL_FUN_H
|
|
||||||
|
|
||||||
#include <QVariant>
|
#include <QVariant>
|
||||||
|
|
||||||
|
|
@ -28,5 +27,3 @@ extern QVariant ecl_fun(
|
||||||
const QVariant& = QVariant());
|
const QVariant& = QVariant());
|
||||||
|
|
||||||
QT_END_NAMESPACE
|
QT_END_NAMESPACE
|
||||||
|
|
||||||
#endif
|
|
||||||
|
|
|
||||||
|
|
@ -3,8 +3,7 @@
|
||||||
//
|
//
|
||||||
// does not depend on LQML
|
// does not depend on LQML
|
||||||
|
|
||||||
#ifndef ECL_FUN_PLUGIN
|
#pragma once
|
||||||
#define ECL_FUN_PLUGIN
|
|
||||||
|
|
||||||
#undef SLOT
|
#undef SLOT
|
||||||
|
|
||||||
|
|
@ -439,5 +438,3 @@ QVariant ecl_fun(const QByteArray& pkgFun,
|
||||||
}
|
}
|
||||||
|
|
||||||
QT_END_NAMESPACE
|
QT_END_NAMESPACE
|
||||||
|
|
||||||
#endif
|
|
||||||
|
|
|
||||||
|
|
@ -6,7 +6,7 @@
|
||||||
#include <QStringList>
|
#include <QStringList>
|
||||||
#include <QDebug>
|
#include <QDebug>
|
||||||
|
|
||||||
const char LQML::version[] = "22.3.2"; // Mar 2022
|
const char LQML::version[] = "22.3.3"; // Mar 2022
|
||||||
|
|
||||||
extern "C" void ini_LQML(cl_object);
|
extern "C" void ini_LQML(cl_object);
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -1,5 +1,4 @@
|
||||||
#ifndef LQML_H
|
#pragma once
|
||||||
#define LQML_H
|
|
||||||
|
|
||||||
#undef SLOT
|
#undef SLOT
|
||||||
|
|
||||||
|
|
@ -49,4 +48,3 @@ public Q_SLOTS:
|
||||||
|
|
||||||
QT_END_NAMESPACE
|
QT_END_NAMESPACE
|
||||||
|
|
||||||
#endif
|
|
||||||
|
|
|
||||||
|
|
@ -1,3 +1,6 @@
|
||||||
|
#include "main.h"
|
||||||
|
#include "lqml.h"
|
||||||
|
#include "qml_ext.h"
|
||||||
#include <QDir>
|
#include <QDir>
|
||||||
#include <QGuiApplication>
|
#include <QGuiApplication>
|
||||||
#include <QTimer>
|
#include <QTimer>
|
||||||
|
|
@ -6,8 +9,6 @@
|
||||||
#include <QQmlFileSelector>
|
#include <QQmlFileSelector>
|
||||||
#include <QQuickView>
|
#include <QQuickView>
|
||||||
#include <iostream>
|
#include <iostream>
|
||||||
#include "lqml.h"
|
|
||||||
#include "qml_ext.h"
|
|
||||||
|
|
||||||
#ifdef Q_OS_MACOS
|
#ifdef Q_OS_MACOS
|
||||||
#define ADD_MACOS_BUNDLE_IMPORT_PATH \
|
#define ADD_MACOS_BUNDLE_IMPORT_PATH \
|
||||||
|
|
@ -49,7 +50,8 @@ int main(int argc, char* argv[]) {
|
||||||
app.setApplicationName(QFileInfo(app.applicationFilePath()).baseName());
|
app.setApplicationName(QFileInfo(app.applicationFilePath()).baseName());
|
||||||
QStringList arguments(QCoreApplication::arguments());
|
QStringList arguments(QCoreApplication::arguments());
|
||||||
|
|
||||||
QQuickView view;
|
Engine engine;
|
||||||
|
QQuickView view(&engine, nullptr);
|
||||||
ADD_MACOS_BUNDLE_IMPORT_PATH
|
ADD_MACOS_BUNDLE_IMPORT_PATH
|
||||||
view.engine()->addImportPath(QStringLiteral(":/"));
|
view.engine()->addImportPath(QStringLiteral(":/"));
|
||||||
if (qEnvironmentVariableIntValue("QT_QUICK_CORE_PROFILE")) {
|
if (qEnvironmentVariableIntValue("QT_QUICK_CORE_PROFILE")) {
|
||||||
|
|
@ -65,6 +67,7 @@ int main(int argc, char* argv[]) {
|
||||||
|
|
||||||
Lisp lisp;
|
Lisp lisp;
|
||||||
view.engine()->rootContext()->setContextProperty("Lisp", &lisp);
|
view.engine()->rootContext()->setContextProperty("Lisp", &lisp);
|
||||||
|
view.engine()->rootContext()->setContextProperty("Engine", &engine);
|
||||||
|
|
||||||
LQML lqml(argc, argv, &view);
|
LQML lqml(argc, argv, &view);
|
||||||
if (arguments.contains("-v") || arguments.contains("--version")) {
|
if (arguments.contains("-v") || arguments.contains("--version")) {
|
||||||
|
|
|
||||||
11
src/cpp/main.h
Normal file
11
src/cpp/main.h
Normal file
|
|
@ -0,0 +1,11 @@
|
||||||
|
#pragma once
|
||||||
|
|
||||||
|
#include <QQmlEngine>
|
||||||
|
|
||||||
|
class Engine : public QQmlEngine {
|
||||||
|
Q_OBJECT
|
||||||
|
public:
|
||||||
|
Engine(QObject* parent = nullptr) : QQmlEngine(parent) {}
|
||||||
|
|
||||||
|
Q_INVOKABLE void clearCache() { clearComponentCache(); }
|
||||||
|
};
|
||||||
|
|
@ -1,5 +1,4 @@
|
||||||
#ifndef MARSHAL_H
|
#pragma once
|
||||||
#define MARSHAL_H
|
|
||||||
|
|
||||||
#undef SLOT
|
#undef SLOT
|
||||||
|
|
||||||
|
|
@ -99,5 +98,3 @@ cl_object from_qobject_pointer(QObject*);
|
||||||
QString toCamelCase(const QString&);
|
QString toCamelCase(const QString&);
|
||||||
|
|
||||||
QT_END_NAMESPACE
|
QT_END_NAMESPACE
|
||||||
|
|
||||||
#endif
|
|
||||||
|
|
|
||||||
|
|
@ -1,5 +1,4 @@
|
||||||
#ifndef QML_EXT_H
|
#pragma once
|
||||||
#define QML_EXT_H
|
|
||||||
|
|
||||||
#include <QtQml>
|
#include <QtQml>
|
||||||
|
|
||||||
|
|
@ -36,5 +35,3 @@ public:
|
||||||
};
|
};
|
||||||
|
|
||||||
QT_END_NAMESPACE
|
QT_END_NAMESPACE
|
||||||
|
|
||||||
#endif
|
|
||||||
|
|
|
||||||
|
|
@ -1,5 +1,4 @@
|
||||||
#ifndef QT_ECL_H
|
#pragma once
|
||||||
#define QT_ECL_H
|
|
||||||
|
|
||||||
#include <QVariant>
|
#include <QVariant>
|
||||||
|
|
||||||
|
|
@ -25,5 +24,3 @@ QVariant ecl_fun(
|
||||||
const QVariant& = QVariant());
|
const QVariant& = QVariant());
|
||||||
|
|
||||||
QT_END_NAMESPACE
|
QT_END_NAMESPACE
|
||||||
|
|
||||||
#endif
|
|
||||||
|
|
|
||||||
|
|
@ -1,5 +1,4 @@
|
||||||
#ifndef SINGLE_SHOT_H
|
#pragma once
|
||||||
#define SINGLE_SHOT_H
|
|
||||||
|
|
||||||
#undef SLOT
|
#undef SLOT
|
||||||
|
|
||||||
|
|
@ -22,5 +21,3 @@ protected:
|
||||||
};
|
};
|
||||||
|
|
||||||
QT_END_NAMESPACE
|
QT_END_NAMESPACE
|
||||||
|
|
||||||
#endif
|
|
||||||
|
|
|
||||||
|
|
@ -27,7 +27,8 @@ HEADERS += \
|
||||||
cpp/qml_ext.h \
|
cpp/qml_ext.h \
|
||||||
cpp/lqml.h \
|
cpp/lqml.h \
|
||||||
cpp/qt_ecl.h \
|
cpp/qt_ecl.h \
|
||||||
cpp/single_shot.h
|
cpp/single_shot.h \
|
||||||
|
cpp/main.h
|
||||||
|
|
||||||
SOURCES += \
|
SOURCES += \
|
||||||
cpp/marshal.cpp \
|
cpp/marshal.cpp \
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue