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
|
||||
HEADERS += ../../src/cpp/main.h
|
||||
SOURCES += ../../src/cpp/main.cpp
|
||||
|
||||
RESOURCES = $$files(qml/*)
|
||||
|
|
|
|||
|
|
@ -57,6 +57,7 @@ ios {
|
|||
}
|
||||
|
||||
LIBS += -llqml -llisp -Ltmp -lapp
|
||||
HEADERS += ../../src/cpp/main.h
|
||||
SOURCES += ../../src/cpp/main.cpp
|
||||
|
||||
RESOURCES = $$files(qml/*)
|
||||
|
|
|
|||
|
|
@ -14,6 +14,10 @@ Important note
|
|||
(see also `src/mkdirs.sh`) and rebuild the whole library for every single
|
||||
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
|
||||
|
|
|
|||
|
|
@ -8,9 +8,9 @@ reloading QML.*
|
|||
doesn't depend on Swank, and should therefore also be stable (it uses a local
|
||||
trivial web server).*
|
||||
|
||||
*You may even run both the desktop and mobile device auto reload simultaneously
|
||||
(`swank-server` example only), because they both watch/load the same QML
|
||||
sources.*
|
||||
*You may even run both desktop and (one or more) mobile device auto reloads
|
||||
simultaneously (`swank-server` example only), because they all watch/load the
|
||||
same QML sources, if they point to the same desktop IP*
|
||||
|
||||
|
||||
QML Preview and Slime
|
||||
|
|
|
|||
|
|
@ -1,5 +1,4 @@
|
|||
#ifndef ECL_EXT_H
|
||||
#define ECL_EXT_H
|
||||
#pragma once
|
||||
|
||||
#undef SLOT
|
||||
|
||||
|
|
@ -87,5 +86,3 @@ void iniCLFunctions();
|
|||
void error_msg(const char*, cl_object);
|
||||
|
||||
QT_END_NAMESPACE
|
||||
|
||||
#endif
|
||||
|
|
|
|||
|
|
@ -1,8 +1,7 @@
|
|||
// header to be included in external Qt libraries
|
||||
// for calling ECL functions from Qt
|
||||
|
||||
#ifndef ECL_FUN_H
|
||||
#define ECL_FUN_H
|
||||
#pragma once
|
||||
|
||||
#include <QVariant>
|
||||
|
||||
|
|
@ -28,5 +27,3 @@ extern QVariant ecl_fun(
|
|||
const QVariant& = QVariant());
|
||||
|
||||
QT_END_NAMESPACE
|
||||
|
||||
#endif
|
||||
|
|
|
|||
|
|
@ -3,8 +3,7 @@
|
|||
//
|
||||
// does not depend on LQML
|
||||
|
||||
#ifndef ECL_FUN_PLUGIN
|
||||
#define ECL_FUN_PLUGIN
|
||||
#pragma once
|
||||
|
||||
#undef SLOT
|
||||
|
||||
|
|
@ -439,5 +438,3 @@ QVariant ecl_fun(const QByteArray& pkgFun,
|
|||
}
|
||||
|
||||
QT_END_NAMESPACE
|
||||
|
||||
#endif
|
||||
|
|
|
|||
|
|
@ -6,7 +6,7 @@
|
|||
#include <QStringList>
|
||||
#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);
|
||||
|
||||
|
|
|
|||
|
|
@ -1,5 +1,4 @@
|
|||
#ifndef LQML_H
|
||||
#define LQML_H
|
||||
#pragma once
|
||||
|
||||
#undef SLOT
|
||||
|
||||
|
|
@ -49,4 +48,3 @@ public Q_SLOTS:
|
|||
|
||||
QT_END_NAMESPACE
|
||||
|
||||
#endif
|
||||
|
|
|
|||
|
|
@ -1,3 +1,6 @@
|
|||
#include "main.h"
|
||||
#include "lqml.h"
|
||||
#include "qml_ext.h"
|
||||
#include <QDir>
|
||||
#include <QGuiApplication>
|
||||
#include <QTimer>
|
||||
|
|
@ -6,8 +9,6 @@
|
|||
#include <QQmlFileSelector>
|
||||
#include <QQuickView>
|
||||
#include <iostream>
|
||||
#include "lqml.h"
|
||||
#include "qml_ext.h"
|
||||
|
||||
#ifdef Q_OS_MACOS
|
||||
#define ADD_MACOS_BUNDLE_IMPORT_PATH \
|
||||
|
|
@ -49,7 +50,8 @@ int main(int argc, char* argv[]) {
|
|||
app.setApplicationName(QFileInfo(app.applicationFilePath()).baseName());
|
||||
QStringList arguments(QCoreApplication::arguments());
|
||||
|
||||
QQuickView view;
|
||||
Engine engine;
|
||||
QQuickView view(&engine, nullptr);
|
||||
ADD_MACOS_BUNDLE_IMPORT_PATH
|
||||
view.engine()->addImportPath(QStringLiteral(":/"));
|
||||
if (qEnvironmentVariableIntValue("QT_QUICK_CORE_PROFILE")) {
|
||||
|
|
@ -65,6 +67,7 @@ int main(int argc, char* argv[]) {
|
|||
|
||||
Lisp lisp;
|
||||
view.engine()->rootContext()->setContextProperty("Lisp", &lisp);
|
||||
view.engine()->rootContext()->setContextProperty("Engine", &engine);
|
||||
|
||||
LQML lqml(argc, argv, &view);
|
||||
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
|
||||
#define MARSHAL_H
|
||||
#pragma once
|
||||
|
||||
#undef SLOT
|
||||
|
||||
|
|
@ -99,5 +98,3 @@ cl_object from_qobject_pointer(QObject*);
|
|||
QString toCamelCase(const QString&);
|
||||
|
||||
QT_END_NAMESPACE
|
||||
|
||||
#endif
|
||||
|
|
|
|||
|
|
@ -1,5 +1,4 @@
|
|||
#ifndef QML_EXT_H
|
||||
#define QML_EXT_H
|
||||
#pragma once
|
||||
|
||||
#include <QtQml>
|
||||
|
||||
|
|
@ -36,5 +35,3 @@ public:
|
|||
};
|
||||
|
||||
QT_END_NAMESPACE
|
||||
|
||||
#endif
|
||||
|
|
|
|||
|
|
@ -1,5 +1,4 @@
|
|||
#ifndef QT_ECL_H
|
||||
#define QT_ECL_H
|
||||
#pragma once
|
||||
|
||||
#include <QVariant>
|
||||
|
||||
|
|
@ -25,5 +24,3 @@ QVariant ecl_fun(
|
|||
const QVariant& = QVariant());
|
||||
|
||||
QT_END_NAMESPACE
|
||||
|
||||
#endif
|
||||
|
|
|
|||
|
|
@ -1,5 +1,4 @@
|
|||
#ifndef SINGLE_SHOT_H
|
||||
#define SINGLE_SHOT_H
|
||||
#pragma once
|
||||
|
||||
#undef SLOT
|
||||
|
||||
|
|
@ -22,5 +21,3 @@ protected:
|
|||
};
|
||||
|
||||
QT_END_NAMESPACE
|
||||
|
||||
#endif
|
||||
|
|
|
|||
|
|
@ -27,7 +27,8 @@ HEADERS += \
|
|||
cpp/qml_ext.h \
|
||||
cpp/lqml.h \
|
||||
cpp/qt_ecl.h \
|
||||
cpp/single_shot.h
|
||||
cpp/single_shot.h \
|
||||
cpp/main.h
|
||||
|
||||
SOURCES += \
|
||||
cpp/marshal.cpp \
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue