revisions

This commit is contained in:
pls.153 2024-05-23 10:28:06 +02:00
parent f02422ddfe
commit ce8b07845c
31 changed files with 2 additions and 92 deletions

View file

@ -4,8 +4,6 @@
#include <QMessageBox>
#include <QtDebug>
QT_BEGIN_NAMESPACE
QObject* ini() {
// any QObject inherited class will do
static QObject* cpp = nullptr;
@ -37,4 +35,3 @@ QVariant CPP::callLisp(const QVariant& arg) {
return ecl_fun("cl:format", false, "~R", arg);
}
QT_END_NAMESPACE

View file

@ -8,8 +8,6 @@
#define LIB_EXPORT
#endif
QT_BEGIN_NAMESPACE
extern "C" { LIB_EXPORT QObject* ini(); }
class CPP : public QObject {
@ -23,4 +21,3 @@ public:
Q_INVOKABLE QVariant callLisp(const QVariant&);
};
QT_END_NAMESPACE

View file

@ -8,8 +8,6 @@
#include <ecl_fun.h>
#endif
QT_BEGIN_NAMESPACE
QObject* ini() {
static QObject* qt = nullptr;
if (qt == nullptr) {
@ -30,4 +28,3 @@ QVariant QT::rotateImage(const QVariant& imagePath, const QVariant& angle) {
return imagePath;
}
QT_END_NAMESPACE

View file

@ -8,8 +8,6 @@
#define LIB_EXPORT
#endif
QT_BEGIN_NAMESPACE
extern "C" { LIB_EXPORT QObject* ini(); }
class QT : public QObject {
@ -19,4 +17,3 @@ public:
Q_INVOKABLE QVariant rotateImage(const QVariant&, const QVariant&);
};
QT_END_NAMESPACE

View file

@ -23,8 +23,6 @@ Q_DECLARE_METATYPE (TextCursor*)
Q_DECLARE_METATYPE (SyntaxHighlighter*)
Q_DECLARE_METATYPE (QTextDocument*)
QT_BEGIN_NAMESPACE
QObject* ini() {
static QObject* qt = nullptr;
if (qt == nullptr) {
@ -364,4 +362,3 @@ QVariant QT::sendToUlisp(const QVariant &vData) {
}
#endif
QT_END_NAMESPACE

View file

@ -24,8 +24,6 @@
#define DELETE_LATER(var) \
QTimer::singleShot(0, var, &QObject::deleteLater)
QT_BEGIN_NAMESPACE
extern "C" { LIB_EXPORT QObject* ini(); }
#if (defined Q_OS_UNIX) && !(defined NO_USB)
@ -119,4 +117,3 @@ public:
#endif
};
QT_END_NAMESPACE

View file

@ -8,8 +8,6 @@
#include <QtCore/private/qandroidextras_p.h>
#endif
QT_BEGIN_NAMESPACE
static void clearEventualExceptions() {
#if (QT_VERSION < 0x060000)
QAndroidJniEnvironment env;
@ -138,4 +136,3 @@ void QT::iniJni() {
clearEventualExceptions();
}
QT_END_NAMESPACE

View file

@ -20,11 +20,11 @@ public Q_SLOTS:
public:
static USB_ME* _this;
bool ready = false;
QtAndroidService* emitter = nullptr;
Connection* con = nullptr;
QTimer timer;
QByteArrayList packets;
bool ready = false;
void received(const QByteArray&);

View file

@ -2,11 +2,8 @@
#import <UIKit/UIKit.h>
QT_BEGIN_NAMESPACE
QVariant QT::keepScreenOn(const QVariant& on) {
[UIApplication sharedApplication].idleTimerDisabled = on.toBool() ? YES : NO;
return on;
}
QT_END_NAMESPACE

View file

@ -25,8 +25,6 @@
#include "connection/connection.h"
#endif
QT_BEGIN_NAMESPACE
QObject* ini() {
static QObject* qt = nullptr;
if (qt == nullptr) {
@ -255,4 +253,3 @@ QVariant QT::localIp() {
return QVariant();
}
QT_END_NAMESPACE

View file

@ -16,8 +16,6 @@
class Connection;
#endif
QT_BEGIN_NAMESPACE
extern "C" { LIB_EXPORT QObject* ini(); }
class QT : public QObject {
@ -67,4 +65,3 @@ public:
#endif
};
QT_END_NAMESPACE

View file

@ -108,7 +108,7 @@ USB permission.
## WiFi
If you have a radio with intgrated WiFi (like LILYGO T-Beam, HELTEC v3), you
If you have a radio with intgrated WiFi (like LILYGO T-Beam, Heltec v3), you
can setup your WiFi connection using the Python CLI:
```
meshtastic \

View file

@ -2,8 +2,6 @@
#include <QtAndroid>
#include <QAndroidJniEnvironment>
QT_BEGIN_NAMESPACE
QVariant QT::keepScreenOn(const QVariant& on) {
QtAndroid::runOnAndroidThread([&] {
QAndroidJniObject activity = QtAndroid::androidActivity();
@ -23,4 +21,3 @@ QVariant QT::keepScreenOn(const QVariant& on) {
return on;
}
QT_END_NAMESPACE

View file

@ -3,8 +3,6 @@
#include <QObject>
#include <QVariant>
QT_BEGIN_NAMESPACE
extern "C" { QObject* ini(); }
class QT : public QObject {
@ -14,4 +12,3 @@ public:
Q_INVOKABLE QVariant keepScreenOn(const QVariant& = true);
};
QT_END_NAMESPACE

View file

@ -2,11 +2,8 @@
#import <UIKit/UIKit.h>
QT_BEGIN_NAMESPACE
QVariant QT::keepScreenOn(const QVariant& on) {
[UIApplication sharedApplication].idleTimerDisabled = on.toBool() ? YES : NO;
return on;
}
QT_END_NAMESPACE

View file

@ -6,8 +6,6 @@
#include <QtAndroid>
#include <QAndroidJniEnvironment>
QT_BEGIN_NAMESPACE
static int getIntField(const char* name) {
QAndroidJniObject activity = QtAndroid::androidActivity();
return static_cast<int>(activity.getField<jint>(name));
@ -47,4 +45,3 @@ QVariant QT::heartRateAccuracy() {
return getIntField("_heart_rate_accuracy_");
}
QT_END_NAMESPACE

View file

@ -3,8 +3,6 @@
#include <QObject>
#include <QVariant>
QT_BEGIN_NAMESPACE
extern "C" { QObject* ini(); }
class QT : public QObject {
@ -17,4 +15,3 @@ public:
Q_INVOKABLE QVariant heartRateAccuracy();
};
QT_END_NAMESPACE

View file

@ -24,8 +24,6 @@
#endif
#endif
QT_BEGIN_NAMESPACE
void iniCLFunctions() {
cl_object l_qml(STRING("QML"));
if (cl_find_package(l_qml) == ECL_NIL) {
@ -962,4 +960,3 @@ cl_object qapropos2(cl_object l_search, cl_object l_obj, cl_object l_no_offset)
return ECL_NIL;
}
QT_END_NAMESPACE

View file

@ -6,8 +6,6 @@
#include <QList>
#include <QVariant>
QT_BEGIN_NAMESPACE
#define DEFUN(name, c_name, num_args) \
ecl_def_c_function(ecl_read_from_cstring(name), (cl_objectfn_fixed)c_name, num_args);
@ -92,4 +90,3 @@ cl_object set_shutdown_p (cl_object);
void iniCLFunctions();
void error_msg(const char*, cl_object);
QT_END_NAMESPACE

View file

@ -5,8 +5,6 @@
#include <QVariant>
QT_BEGIN_NAMESPACE
extern QVariant ecl_fun(
const QByteArray&,
const QVariant& = QVariant(),
@ -26,4 +24,3 @@ extern QVariant ecl_fun(
const QVariant& = QVariant(),
const QVariant& = QVariant());
QT_END_NAMESPACE

View file

@ -16,8 +16,6 @@
#include <QRectF>
#include <ecl/ecl.h>
QT_BEGIN_NAMESPACE
#define STRING(s) ecl_make_constant_base_string(s, -1)
#define STRING_COPY(s) (s ? ecl_make_simple_base_string(s, -1) : ECL_NIL)
@ -535,4 +533,3 @@ void ini_lisp() {
si_safe_eval(2, ecl_read_from_cstring((char*)lisp_code), ECL_NIL);
}
QT_END_NAMESPACE

View file

@ -10,8 +10,6 @@
class QQuickView;
QT_BEGIN_NAMESPACE
#define EVAL_ERROR_VALUE -1
typedef void (*lisp_ini)(cl_object);
@ -46,5 +44,3 @@ public Q_SLOTS:
void exitEventLoop() { eventLoop->exit(); }
};
QT_END_NAMESPACE

View file

@ -7,8 +7,6 @@
#include <QtGui/QGuiApplication>
#include <QtGui/QInputMethodEvent>
QT_BEGIN_NAMESPACE
#define STRING(s) ecl_make_constant_base_string(s, -1)
#define DEFUN(name, c_name, num_args) \
@ -126,4 +124,3 @@ Q_SIGNALS:
#endif
};
QT_END_NAMESPACE

View file

@ -6,8 +6,6 @@
#include <QtGui/QColor>
#include <QtQml/QJSValue>
QT_BEGIN_NAMESPACE
static void warning_msg(const char* message, cl_object l_args) {
STATIC_SYMBOL (s_error_output, "*ERROR-OUTPUT*")
cl_format(4,
@ -346,4 +344,3 @@ cl_object from_qobject_pointer(QObject* qobject) {
ecl_make_unsigned_integer(reinterpret_cast<quintptr>(qobject)));
}
QT_END_NAMESPACE

View file

@ -6,8 +6,6 @@
#include <QRectF>
#include <QVariant>
QT_BEGIN_NAMESPACE
#define STRING(s) ecl_make_constant_base_string(s, -1)
#define STRING_COPY(s) (s ? ecl_make_simple_base_string(s, -1) : ECL_NIL)
@ -96,4 +94,3 @@ cl_object from_qobject_pointer(QObject*);
QString toCamelCase(const QString&);
QT_END_NAMESPACE

View file

@ -2,8 +2,6 @@
#include "lqml.h"
#include "ecl_fun.h"
QT_BEGIN_NAMESPACE
static QVariant qmlApply(QObject* caller,
const QString& function,
const QVariantList& arguments) {
@ -112,4 +110,3 @@ QVariant Lisp::apply(const QJSValue& caller_or_function,
return qmlApply(caller, function, arguments);
}
QT_END_NAMESPACE

View file

@ -2,8 +2,6 @@
#include <QtQml>
QT_BEGIN_NAMESPACE
class Lisp : public QObject {
Q_OBJECT
@ -34,4 +32,3 @@ public:
const QJSValue& = QJSValue());
};
QT_END_NAMESPACE

View file

@ -3,8 +3,6 @@
#include "ecl_ext.h"
#include <QVariant>
QT_BEGIN_NAMESPACE
static QHash<QByteArray, void*> lisp_functions;
static cl_object lisp_apply(cl_object l_fun, cl_object l_args) {
@ -97,5 +95,3 @@ QVariant ecl_fun(const QByteArray& pkgFun,
return QVariant();
}
QT_END_NAMESPACE

View file

@ -2,8 +2,6 @@
#include <QVariant>
QT_BEGIN_NAMESPACE
QVariant ecl_fun(
const QByteArray&,
const QVariant& = QVariant(),
@ -23,4 +21,3 @@ QVariant ecl_fun(
const QVariant& = QVariant(),
const QVariant& = QVariant());
QT_END_NAMESPACE

View file

@ -1,7 +1,5 @@
#include "single_shot.h"
QT_BEGIN_NAMESPACE
SingleShot::SingleShot(int msec, void* fun)
: function(fun) {
id = startTimer(msec);
@ -21,5 +19,3 @@ void SingleShot::timerEvent(QTimerEvent*) {
deleteLater();
}
QT_END_NAMESPACE

View file

@ -5,8 +5,6 @@
#include <ecl/ecl.h>
#include <QObject>
QT_BEGIN_NAMESPACE
class SingleShot : public QObject {
Q_OBJECT
@ -20,4 +18,3 @@ protected:
void timerEvent(QTimerEvent*) override;
};
QT_END_NAMESPACE