diff options
author | ConfuSomu | 2023-08-15 19:55:52 -0400 |
---|---|---|
committer | ConfuSomu | 2023-08-15 20:16:07 -0400 |
commit | def9f251739e9a0d6d0ff1c98dc4562dade3e9ef (patch) | |
tree | 1e36bddaf8d04312cf81f5335f3afedc6aa5c784 /src/archive | |
parent | ade98b4cf6630635e2fdbf84ac29fe83a79cc371 (diff) | |
download | ActorViewer-def9f251739e9a0d6d0ff1c98dc4562dade3e9ef.tar ActorViewer-def9f251739e9a0d6d0ff1c98dc4562dade3e9ef.tar.gz ActorViewer-def9f251739e9a0d6d0ff1c98dc4562dade3e9ef.zip |
Implement "fill address" in instance settings
Implement the "fill address" action in the instance login settings frame
that is in the network tab.
Diffstat (limited to 'src/archive')
-rw-r--r-- | src/archive/base_archive.cpp | 4 | ||||
-rw-r--r-- | src/archive/base_archive.h | 1 | ||||
-rw-r--r-- | src/archive/mastodon.cpp | 5 | ||||
-rw-r--r-- | src/archive/mastodon.h | 1 |
4 files changed, 11 insertions, 0 deletions
diff --git a/src/archive/base_archive.cpp b/src/archive/base_archive.cpp index 14fa417..47cadf2 100644 --- a/src/archive/base_archive.cpp +++ b/src/archive/base_archive.cpp @@ -11,3 +11,7 @@ Archive* Archive::create_archive(ArchiveType archive_type, const QString& main_f } Archive::Archive(const QString& filename) : main_filename(filename) {} + +const QString Archive::get_instance_address() { + return ""; +} diff --git a/src/archive/base_archive.h b/src/archive/base_archive.h index fcabcf1..4fdf08c 100644 --- a/src/archive/base_archive.h +++ b/src/archive/base_archive.h @@ -29,6 +29,7 @@ public: virtual void update_status_list(ViewStatusTypes allowed_types, QListWidget *parent) = 0; virtual const QString get_html_status_info(int status_index, int text_zone_width, StatusType status_type, QLocale* locale) = 0; virtual const QString get_html_status_text(int status_index) = 0; + virtual const QString get_instance_address(); protected: Archive(const QString& main_filename); diff --git a/src/archive/mastodon.cpp b/src/archive/mastodon.cpp index 297383e..01d476d 100644 --- a/src/archive/mastodon.cpp +++ b/src/archive/mastodon.cpp @@ -70,6 +70,11 @@ bool MastodonArchive::is_status_type_allowed(StatusType status_type, ViewStatusT } } +const QString MastodonArchive::get_instance_address() { + // TODO: implement + return "https://example.com"; +} + // specific to Mastodon ActivityStreams archives StatusType MastodonArchive::get_status_type(QJsonObject obj) { /* diff --git a/src/archive/mastodon.h b/src/archive/mastodon.h index 48be1f3..15a89f2 100644 --- a/src/archive/mastodon.h +++ b/src/archive/mastodon.h @@ -19,6 +19,7 @@ public: void update_status_list(ViewStatusTypes allowed_types, QListWidget *parent); const QString get_html_status_info(int status_index, int text_zone_width, StatusType status_type, QLocale* locale); const QString get_html_status_text(int status_index); + const QString get_instance_address(); private: QDir archive_root_dir; QDir attachment_dir; |