mirror of
https://github.com/Adaptix-Framework/AdaptixC2
synced 2026-06-08 10:20:39 +00:00
Add files via upload
This commit is contained in:
@@ -3,6 +3,9 @@
|
||||
|
||||
#include <main.h>
|
||||
|
||||
class QTimer;
|
||||
class QMutex;
|
||||
|
||||
class ListDelegate : public QStyledItemDelegate {
|
||||
public:
|
||||
using QStyledItemDelegate::QStyledItemDelegate;
|
||||
@@ -106,16 +109,26 @@ protected:
|
||||
class TextEditConsole : public QTextEdit {
|
||||
Q_OBJECT
|
||||
QTextCursor cachedCursor;
|
||||
int maxLines = 30000;
|
||||
int maxLines = 150000;
|
||||
bool autoScroll = false;
|
||||
bool noWrap = true;
|
||||
int appendCount = 0;
|
||||
|
||||
QString pendingText;
|
||||
QTimer* batchTimer = nullptr;
|
||||
QMutex* batchMutex = nullptr;
|
||||
static const int BATCH_INTERVAL_MS = 100;
|
||||
static const int MAX_BATCH_SIZE = 64 * 1024;
|
||||
|
||||
void trimExcessLines();
|
||||
void createContextMenu(const QPoint &pos);
|
||||
void setBufferSize(int size);
|
||||
|
||||
private Q_SLOTS:
|
||||
void flushPendingText();
|
||||
|
||||
public:
|
||||
explicit TextEditConsole(QWidget* parent = nullptr, int maxLines = 30000, bool noWrap = true, bool autoScroll = false);
|
||||
explicit TextEditConsole(QWidget* parent = nullptr, int maxLines = 150000, bool noWrap = true, bool autoScroll = false);
|
||||
|
||||
void appendPlain(const QString& text);
|
||||
void appendFormatted(const QString& text, const std::function<void(QTextCharFormat&)> &styleFn);
|
||||
|
||||
Reference in New Issue
Block a user