LogViewer
A modern log viewer with AI-assisted analysis (Qt 6)
Loading...
Searching...
No Matches
ItemDetailsView.hpp
Go to the documentation of this file.
1#pragma once
2
3#include "IView.hpp"
4#include "IUiPanels.hpp"
5
6#include <QWidget>
7
8class QTableWidget;
9class QTableWidgetItem;
10
11namespace db
12{
13class EventsContainer;
14}
15
16namespace ui::qt
17{
18
19class ItemDetailsView : public QWidget,
21 public mvc::IView
22{
23 Q_OBJECT
24
25 public:
26 explicit ItemDetailsView(
27 db::EventsContainer& events, QWidget* parent = nullptr);
28
29 void RefreshView() override;
30 void ShowControl(bool show) override;
31
32 void OnDataUpdated() override;
33 void OnCurrentIndexUpdated(const int index) override;
34
35 public slots:
36 void OnActualRowChanged(int actualRow);
37
38 private:
39 void DisplayEvent(int actualRow);
41 void ShowCurrentEvent();
42
44 QTableWidget* m_details {nullptr};
45 int m_currentlyDisplayedRow {-1}; // Track which event is currently displayed
46};
47
48} // namespace ui::qt
Interface for view components in the MVC architecture.
High-performance, thread-safe container for managing large collections of LogEvent objects.
Definition EventsContainer.hpp:129
Interface for view components in the MVC architecture.
Definition IView.hpp:26
Toolkit-agnostic interface for the item/event details pane.
Definition IUiPanels.hpp:87
Definition ItemDetailsView.hpp:22
void OnCurrentIndexUpdated(const int index) override
Called when the current item index in the model is updated.
Definition ItemDetailsView.cpp:109
void OnActualRowChanged(int actualRow)
Definition ItemDetailsView.cpp:114
void OnDataUpdated() override
Called when the model's data is updated.
Definition ItemDetailsView.cpp:103
void ShowCurrentEvent()
Shows the container's current event (or nothing).
Definition ItemDetailsView.cpp:81
void ShowControl(bool show) override
Show or hide the panel's visual control.
Definition ItemDetailsView.cpp:98
void RefreshView() override
Refreshes the details view content.
Definition ItemDetailsView.cpp:73
int m_currentlyDisplayedRow
Definition ItemDetailsView.hpp:45
db::EventsContainer & m_events
Definition ItemDetailsView.hpp:43
QTableWidget * m_details
Definition ItemDetailsView.hpp:44
void DisplayEvent(int actualRow)
Definition ItemDetailsView.cpp:155
Database and data model components for the LogViewer application.
Definition EventsContainer.cpp:17
Definition ConfigEditorDialog.cpp:19