This repository has been archived by the owner on Feb 5, 2021. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 2
/
Copy pathlogview.h
138 lines (115 loc) · 3.92 KB
/
logview.h
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
#ifndef LOGVIEW_H
#define LOGVIEW_H
#include <QMutex>
#include <QStringList>
#include <QWidget>
#include "codeeditortabwidget.h"
#include "extension.h"
#include "quickwidgetapi.h"
#include "sqlite3helper.h"
class MainWindow;
class PresenceWidget;
class LogModel;
class LogTableView;
struct StatisticItem;
QT_BEGIN_NAMESPACE
class QTableView;
class QSplitter;
class QTimer;
class QQmlEngine;
class QJSEngine;
QT_END_NAMESPACE
class LogView : public QWidget
{
Q_OBJECT
public:
explicit LogView(QWidget *parent = NULL);
~LogView();
Sqlite3HelperPtr getSqlite3Helper();
void openZipBundle(const QString &zipBundle, const QString &crashInfo);
void openZipBundle(const QString &path);
void openRawLogFile(const QStringList &paths);
void openFolder(const QString &path);
bool matched(const QString &path);
bool matched(const QStringList &paths);
void copyCurrentCell();
void copyCurrentRow();
void copySelectedCells();
void copySelectedRows();
void copyCurrentCellWithXMLFormatted();
void copyCurrentRowWithXMLFormatted();
void copySelectedCellsWithXMLFormatted();
void copySelectedRowsWithXMLFormatted();
void addCurrentRowToBookmark();
void removeCurrentRowFromBookmark();
void addSelectedRowsToBookmark();
void removeSelectedRowsFromBookmark();
void removeAllBookmarks();
void gotoFirstBookmark();
void gotoPreviousBookmark();
void gotoNextBookmark();
void gotoLastBookmark();
void scrollToTop();
void scrollToBottom();
void gotoById(int i);
int rowCount();
void enableRegexpMode(bool enabled);
void inputKeyword();
void onClearKeyword();
void searchFieldContent();
void searchFieldID();
void searchFieldDateTime();
void searchFieldThread();
void searchFieldCategory();
void searchFieldSourceFile();
void searchFieldMethod();
void searchFieldLogFile();
void searchFieldLine();
void searchFieldLevel();
void onRunExtension(ExtensionPtr e);
const QString &getPath() const;
void setPath(const QString &path);
void newLogTableView();
void newLogLevelPieChart();
void newLogThreadPieChart();
void newLogSourceFilePieChart();
void newLogSourceLinePieChart();
void newLogCategoryPieChart();
void newLogMethodPieChart();
void newLogPresenceTableView();
signals:
void rowCountChanged();
void runExtension(ExtensionPtr e);
private slots:
void onDataLoaded();
void onShowLogItemsBetweenSelectedRows();
void onLogTableChartTabWidgetCurrentChanged(int index);
void onOpenSourceFileWithBuiltinEditor(const QString &filePath, int line);
void onOpenSourceFileInVS(const QString &filePath, int line);
void onOpenSourceFileWithOpenGrok(const QString &filePath, int line);
void onCloseLogTableChartTabWidgetTab(int index);
private:
Sqlite3HelperPtr m_sqlite3Helper;
QSplitter * m_verticalSplitter;
QTabWidget * m_logTableChartTabWidget;
CodeEditorTabWidget *m_codeEditorTabWidget;
QString m_path;
QString m_extractDir;
QString m_crashInfo;
QList<LogTableView *> m_logTableViews;
int m_logTableViewNr = 0;
bool event(QEvent *e) Q_DECL_OVERRIDE;
void extract(LogView *v, const QString &fileName, const QString &dirName);
void extractContent(const QString &text);
void openLog(const QString &logFile);
void gotoLogLine(int line, const QString &logFile);
void showCodeEditorPane();
void setChart(QtCharts::QChartView *chartView, const QList<QSharedPointer<StatisticItem>> &sis, const QString &label);
MainWindow * getMainWindow();
void openCrashReport();
void initialize();
LogTableView *createLogTableView();
};
class SourceWindow;
extern SourceWindow *g_sourceWindow;
#endif // LOGVIEW_H