Move Neochat specific libQuotient events to their own folder

This commit is contained in:
James Graham
2023-05-05 19:59:45 +01:00
committed by Tobias Fella
parent e0983fcc8c
commit 4b993775c6
16 changed files with 15 additions and 16 deletions

View File

@@ -30,11 +30,9 @@ add_library(neochat STATIC
models/devicesmodel.cpp models/devicesmodel.cpp
filetypesingleton.cpp filetypesingleton.cpp
login.cpp login.cpp
stickerevent.cpp
models/webshortcutmodel.cpp models/webshortcutmodel.cpp
blurhash.cpp blurhash.cpp
blurhashimageprovider.cpp blurhashimageprovider.cpp
joinrulesevent.cpp
models/collapsestateproxymodel.cpp models/collapsestateproxymodel.cpp
urlhelper.cpp urlhelper.cpp
windowcontroller.cpp windowcontroller.cpp
@@ -49,9 +47,11 @@ add_library(neochat STATIC
models/searchmodel.cpp models/searchmodel.cpp
texthandler.cpp texthandler.cpp
logger.cpp logger.cpp
imagepackevent.cpp
stickermodel.cpp stickermodel.cpp
imagepacksmodel.cpp imagepacksmodel.cpp
events/imagepackevent.cpp
events/joinrulesevent.cpp
events/stickerevent.cpp
) )
add_executable(neochat-app add_executable(neochat-app
@@ -67,7 +67,7 @@ target_link_libraries(neochat-app PRIVATE
if(Quotient_VERSION_MINOR GREATER 6) if(Quotient_VERSION_MINOR GREATER 6)
target_compile_definitions(neochat PUBLIC QUOTIENT_07) target_compile_definitions(neochat PUBLIC QUOTIENT_07)
target_sources(neochat PRIVATE pollevent.cpp pollhandler.cpp) target_sources(neochat PRIVATE events/pollevent.cpp pollhandler.cpp)
else() else()
target_compile_definitions(neochat PUBLIC QUOTIENT_VERSION=\"${Quotient_VERSION}\") target_compile_definitions(neochat PUBLIC QUOTIENT_VERSION=\"${Quotient_VERSION}\")
target_sources(neochat PRIVATE neochataccountregistry.cpp) target_sources(neochat PRIVATE neochataccountregistry.cpp)

View File

@@ -8,7 +8,7 @@ using namespace Quotient;
ImagePackEventContent::ImagePackEventContent(const QJsonObject &json) ImagePackEventContent::ImagePackEventContent(const QJsonObject &json)
{ {
if(json.contains(QStringLiteral("pack"))) { if (json.contains(QStringLiteral("pack"))) {
pack = ImagePackEventContent::Pack{ pack = ImagePackEventContent::Pack{
fromJson<Omittable<QString>>(json["pack"].toObject()["display_name"]), fromJson<Omittable<QString>>(json["pack"].toObject()["display_name"]),
#ifdef QUOTIENT_07 #ifdef QUOTIENT_07
@@ -49,6 +49,7 @@ ImagePackEventContent::ImagePackEventContent(const QJsonObject &json)
} }
} }
void ImagePackEventContent::fillJson(QJsonObject* o) const { void ImagePackEventContent::fillJson(QJsonObject *o) const
{
// TODO // TODO
} }

View File

@@ -2,7 +2,6 @@
// SPDX-License-Identifier: LGPL-2.0-or-later // SPDX-License-Identifier: LGPL-2.0-or-later
#include "imagepacksmodel.h" #include "imagepacksmodel.h"
#include "imagepackevent.h"
#include "neochatroom.h" #include "neochatroom.h"
#include <KLocalizedString> #include <KLocalizedString>

View File

@@ -3,7 +3,7 @@
#pragma once #pragma once
#include "imagepackevent.h" #include "events/imagepackevent.h"
#include <QAbstractListModel> #include <QAbstractListModel>
#include <QPointer> #include <QPointer>
#include <QVector> #include <QVector>

View File

@@ -14,9 +14,9 @@
#include <user.h> #include <user.h>
#ifdef QUOTIENT_07 #ifdef QUOTIENT_07
#include "pollevent.h" #include "events/pollevent.h"
#endif #endif
#include "stickerevent.h" #include "events/stickerevent.h"
#include <QDebug> #include <QDebug>
#include <QGuiApplication> #include <QGuiApplication>

View File

@@ -38,16 +38,16 @@
#include <qt_connection_util.h> #include <qt_connection_util.h>
#include "controller.h" #include "controller.h"
#include "joinrulesevent.h" #include "events/joinrulesevent.h"
#include "neochatconfig.h" #include "neochatconfig.h"
#include "neochatuser.h" #include "neochatuser.h"
#include "notificationsmanager.h" #include "notificationsmanager.h"
#ifdef QUOTIENT_07 #ifdef QUOTIENT_07
#include "pollevent.h" #include "events/pollevent.h"
#include "pollhandler.h" #include "pollhandler.h"
#endif #endif
#include "events/stickerevent.h"
#include "filetransferpseudojob.h" #include "filetransferpseudojob.h"
#include "stickerevent.h"
#include "texthandler.h" #include "texthandler.h"
#ifndef Q_OS_ANDROID #ifndef Q_OS_ANDROID

View File

@@ -2,8 +2,8 @@
// SPDX-License-Identifier: LGPL-2.0-or-later // SPDX-License-Identifier: LGPL-2.0-or-later
#include "pollhandler.h" #include "pollhandler.h"
#include "events/pollevent.h"
#include "neochatroom.h" #include "neochatroom.h"
#include "pollevent.h"
#include <algorithm> #include <algorithm>
#include <csapi/relations.h> #include <csapi/relations.h>
#include <events/roompowerlevelsevent.h> #include <events/roompowerlevelsevent.h>

View File

@@ -3,7 +3,6 @@
#include "stickermodel.h" #include "stickermodel.h"
#include "imagepackevent.h"
#include "imagepacksmodel.h" #include "imagepacksmodel.h"
using namespace Quotient; using namespace Quotient;

View File

@@ -3,7 +3,7 @@
#pragma once #pragma once
#include "imagepackevent.h" #include "events/imagepackevent.h"
#include "neochatroom.h" #include "neochatroom.h"
#include <QAbstractListModel> #include <QAbstractListModel>
#include <QObject> #include <QObject>