aboutsummaryrefslogtreecommitdiff
path: root/ui.qt/source
diff options
context:
space:
mode:
Diffstat (limited to 'ui.qt/source')
-rw-r--r--ui.qt/source/DatabaseClient.cpp5
-rw-r--r--ui.qt/source/DatabaseClient.hpp7
-rw-r--r--ui.qt/source/DatabaseServer.cpp5
-rw-r--r--ui.qt/source/DatabaseServer.hpp7
-rw-r--r--ui.qt/source/Document.cpp (renamed from ui.qt/source/document.cpp)2
-rw-r--r--ui.qt/source/Document.hpp (renamed from ui.qt/source/document.hpp)0
-rw-r--r--ui.qt/source/Keyword.cpp (renamed from ui.qt/source/keyword.cpp)6
-rw-r--r--ui.qt/source/Keyword.hpp (renamed from ui.qt/source/keyword.hpp)4
-rw-r--r--ui.qt/source/KnowledgeFragment.cpp (renamed from ui.qt/source/knowledgefragment.cpp)6
-rw-r--r--ui.qt/source/KnowledgeFragment.hpp (renamed from ui.qt/source/knowledgefragment.hpp)12
-rw-r--r--ui.qt/source/fwd.hpp6
-rw-r--r--ui.qt/source/main.cpp12
12 files changed, 48 insertions, 24 deletions
diff --git a/ui.qt/source/DatabaseClient.cpp b/ui.qt/source/DatabaseClient.cpp
new file mode 100644
index 0000000..430fe79
--- /dev/null
+++ b/ui.qt/source/DatabaseClient.cpp
@@ -0,0 +1,5 @@
+#include "DatabaseClient.hpp"
+
+DatabaseClient::DatabaseClient()
+{
+}
diff --git a/ui.qt/source/DatabaseClient.hpp b/ui.qt/source/DatabaseClient.hpp
new file mode 100644
index 0000000..17c6ed7
--- /dev/null
+++ b/ui.qt/source/DatabaseClient.hpp
@@ -0,0 +1,7 @@
+#pragma once
+
+class DatabaseClient
+{
+public:
+ DatabaseClient();
+};
diff --git a/ui.qt/source/DatabaseServer.cpp b/ui.qt/source/DatabaseServer.cpp
new file mode 100644
index 0000000..a850e63
--- /dev/null
+++ b/ui.qt/source/DatabaseServer.cpp
@@ -0,0 +1,5 @@
+#include "DatabaseServer.hpp"
+
+DatabaseServer::DatabaseServer()
+{
+}
diff --git a/ui.qt/source/DatabaseServer.hpp b/ui.qt/source/DatabaseServer.hpp
new file mode 100644
index 0000000..0cd5039
--- /dev/null
+++ b/ui.qt/source/DatabaseServer.hpp
@@ -0,0 +1,7 @@
+#pragma once
+
+class DatabaseServer
+{
+public:
+ DatabaseServer();
+};
diff --git a/ui.qt/source/document.cpp b/ui.qt/source/Document.cpp
index 377913b..272ac4c 100644
--- a/ui.qt/source/document.cpp
+++ b/ui.qt/source/Document.cpp
@@ -1,4 +1,4 @@
-#include "document.hpp"
+#include "Document.hpp"
#include <QBrush>
#include <QColor>
diff --git a/ui.qt/source/document.hpp b/ui.qt/source/Document.hpp
index 5ef1bba..5ef1bba 100644
--- a/ui.qt/source/document.hpp
+++ b/ui.qt/source/Document.hpp
diff --git a/ui.qt/source/keyword.cpp b/ui.qt/source/Keyword.cpp
index f782437..f6c18be 100644
--- a/ui.qt/source/keyword.cpp
+++ b/ui.qt/source/Keyword.cpp
@@ -1,9 +1,9 @@
-#include "keyword.hpp"
+#include "Keyword.hpp"
-#include "knowledgefragment.hpp"
+#include "KnowledgeFragment.hpp"
Keyword::Keyword(const QString& name)
- : name(name)
+ : mName(name)
{
}
diff --git a/ui.qt/source/keyword.hpp b/ui.qt/source/Keyword.hpp
index bc50473..481b5bb 100644
--- a/ui.qt/source/keyword.hpp
+++ b/ui.qt/source/Keyword.hpp
@@ -8,8 +8,8 @@
class Keyword
{
private:
- QString name;
- std::vector<KnowledgeId> associations;
+ QString mName;
+ std::vector<KnowledgeId> mAssociations;
public:
Keyword(const QString& name);
diff --git a/ui.qt/source/knowledgefragment.cpp b/ui.qt/source/KnowledgeFragment.cpp
index 4db09e7..3d08f6e 100644
--- a/ui.qt/source/knowledgefragment.cpp
+++ b/ui.qt/source/KnowledgeFragment.cpp
@@ -1,11 +1,11 @@
-#include "knowledgefragment.hpp"
+#include "KnowledgeFragment.hpp"
KnowledgeFragment::KnowledgeFragment(KnowledgeId id)
- : id{ id }
+ : mId{ id }
{
}
KnowledgeId KnowledgeFragment::getId() const
{
- return id;
+ return mId;
}
diff --git a/ui.qt/source/knowledgefragment.hpp b/ui.qt/source/KnowledgeFragment.hpp
index 533d99f..9f4912d 100644
--- a/ui.qt/source/knowledgefragment.hpp
+++ b/ui.qt/source/KnowledgeFragment.hpp
@@ -14,9 +14,9 @@ struct KnowledgeId
class KnowledgeFragment
{
private:
- QDateTime createTime;
- QDateTime modifyTime;
- KnowledgeId id;
+ QDateTime mCreateTime;
+ QDateTime mModifyTime;
+ KnowledgeId mId;
public:
KnowledgeFragment(KnowledgeId id);
@@ -27,9 +27,9 @@ public:
class KnowledgeDatabase
{
private:
- std::vector<KnowledgeFragment> storage;
- std::vector<size_t> index; // Mapping from KnowledgeId (index) to `storage` index
- KnowledgeId nextId;
+ std::vector<KnowledgeFragment> mStorage;
+ std::vector<size_t> mIndex; // Mapping from KnowledgeId (index) to `storage` index
+ KnowledgeId mNextId;
public:
KnowledgeId allocateFragment();
diff --git a/ui.qt/source/fwd.hpp b/ui.qt/source/fwd.hpp
index 7a24ded..14e0033 100644
--- a/ui.qt/source/fwd.hpp
+++ b/ui.qt/source/fwd.hpp
@@ -1,13 +1,13 @@
#pragma once
-// document.hpp
+// Document.hpp
class DocumentHandler;
-// keyword.hpp
+// Keyword.hpp
class Keyword;
class KeywordDatabase;
-// knowledgefragment.cpp
+// Knowledgefragment.cpp
struct KnowledgeId;
class KnowledgeFragment;
class KnowledgeDatabase;
diff --git a/ui.qt/source/main.cpp b/ui.qt/source/main.cpp
index fab148c..863ee20 100644
--- a/ui.qt/source/main.cpp
+++ b/ui.qt/source/main.cpp
@@ -8,14 +8,14 @@ int main(int argc, char *argv[])
QApplication app(argc, argv);
QTranslator translator;
- const QStringList uiLanguages = QLocale::system().uiLanguages();
- for (const QString& locale : uiLanguages) {
- const QString baseName = "EpistmoolUI_" + QLocale(locale).name();
- if (translator.load(":/i18n/" + baseName)) {
+ const QStringList uiLanguages = QLocale::system().uiLanguages();
+ for (const QString& locale : uiLanguages) {
+ const QString baseName = "EpistmoolUI_" + QLocale(locale).name();
+ if (translator.load(":/i18n/" + baseName)) {
app.installTranslator(&translator);
break;
- }
- }
+ }
+ }
QQmlApplicationEngine engine;
const QUrl url(u"qrc:/EpistmoolUI/source/qml/MainWindow.qml"_qs);