aboutsummaryrefslogtreecommitdiffstats
path: root/src
diff options
context:
space:
mode:
authorConfuSomu2023-11-18 22:21:41 -0500
committerConfuSomu2023-11-18 22:21:41 -0500
commitde3482f5a8dcd3f07c2d9eff28608b7f5a01858f (patch)
treec8d7987e82cdd0ca75c04643ff8c8bdc684a2982 /src
parent8ee7a379bbd8c1e2d7831208308bf11eabcdc79d (diff)
downloadActorViewer-de3482f5a8dcd3f07c2d9eff28608b7f5a01858f.tar
ActorViewer-de3482f5a8dcd3f07c2d9eff28608b7f5a01858f.tar.gz
ActorViewer-de3482f5a8dcd3f07c2d9eff28608b7f5a01858f.zip
Remove duplicate status info widget
Diffstat (limited to 'src')
-rw-r--r--src/mainwindow.cpp6
-rw-r--r--src/mainwindow.ui23
2 files changed, 3 insertions, 26 deletions
diff --git a/src/mainwindow.cpp b/src/mainwindow.cpp
index 8f72f23..82f4b37 100644
--- a/src/mainwindow.cpp
+++ b/src/mainwindow.cpp
@@ -1,6 +1,5 @@
#include "mainwindow.h"
#include "./ui_mainwindow.h"
-#include "src/activitypub/appost.h"
#include "src/archive/base_archive.h"
#include "src/finddialog.h"
#include "src/list_item.h"
@@ -154,8 +153,9 @@ void MainWindow::on_actionOpen_URL_triggered(bool checked) {
if (ok and not url.isEmpty()) {
Instance* instance = Instance::create_instance();
APPost* post = instance->get_post_from_url(url);
- QString html = post->get_html_render({ui->statusInfoText->width(), &locale_context});
- ui->statusInfoText->setHtml(html);
+ // Activity will be freed by StatusInfoWidget
+ APActivity* activity = new APActivity({.object = post});
+ status_info_widget->do_process_activity(activity);
delete instance; instance = nullptr;
} else return;
}
diff --git a/src/mainwindow.ui b/src/mainwindow.ui
index 2d7cf30..0ab8c02 100644
--- a/src/mainwindow.ui
+++ b/src/mainwindow.ui
@@ -57,29 +57,6 @@
</item>
</layout>
</item>
- <item row="1" column="1">
- <widget class="QTextEdit" name="statusInfoText">
- <property name="cursor" stdset="0">
- <cursorShape>IBeamCursor</cursorShape>
- </property>
- <property name="undoRedoEnabled">
- <bool>false</bool>
- </property>
- <property name="readOnly">
- <bool>true</bool>
- </property>
- <property name="html">
- <string>&lt;!DOCTYPE HTML PUBLIC &quot;-//W3C//DTD HTML 4.0//EN&quot; &quot;http://www.w3.org/TR/REC-html40/strict.dtd&quot;&gt;
-&lt;html&gt;&lt;head&gt;&lt;meta name=&quot;qrichtext&quot; content=&quot;1&quot; /&gt;&lt;style type=&quot;text/css&quot;&gt;
-p, li { white-space: pre-wrap; }
-&lt;/style&gt;&lt;/head&gt;&lt;body style=&quot; font-family:'Noto Sans'; font-size:10pt; font-weight:400; font-style:normal;&quot;&gt;
-&lt;p align=&quot;center&quot; style=&quot; margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;&quot;&gt;&lt;span style=&quot; font-style:italic;&quot;&gt;Select Status to display from list.&lt;/span&gt;&lt;/p&gt;&lt;/body&gt;&lt;/html&gt;</string>
- </property>
- <property name="textInteractionFlags">
- <set>Qt::TextBrowserInteraction</set>
- </property>
- </widget>
- </item>
</layout>
</widget>
<widget class="QMenuBar" name="menubar">