File indexing completed on 2024-12-08 04:34:13

0001 /*
0002    SPDX-FileCopyrightText: 2023-2024 Laurent Montel <montel.org>
0003 
0004    SPDX-License-Identifier: LGPL-2.0-or-later
0005 */
0006 #pragma once
0007 
0008 #include "libruqolawidgets_private_export.h"
0009 #include "localdatabase/localmessagedatabase.h"
0010 #include <QWidget>
0011 class RocketChatAccount;
0012 class MessageListView;
0013 class QLineEdit;
0014 class MessagesModel;
0015 class QSpinBox;
0016 class QDateTimeEdit;
0017 class QCheckBox;
0018 class LIBRUQOLAWIDGETS_TESTS_EXPORT ExploreDatabaseWidget : public QWidget
0019 {
0020     Q_OBJECT
0021 public:
0022     explicit ExploreDatabaseWidget(RocketChatAccount *account, QWidget *parent = nullptr);
0023     ~ExploreDatabaseWidget() override;
0024 
0025 private:
0026     LIBRUQOLAWIDGETS_NO_EXPORT void slotLoad();
0027     RocketChatAccount *const mRocketChatAccount;
0028     MessageListView *const mMessageListView;
0029     std::unique_ptr<LocalMessageDatabase> mLocalMessageDatabase;
0030     QLineEdit *const mRoomName;
0031     QSpinBox *const mNumberOfMessages;
0032     QCheckBox *const mUseStartDateTime;
0033     QDateTimeEdit *const mStartDateTime;
0034     QCheckBox *const mUseEndDateTime;
0035     QDateTimeEdit *const mEndDateTime;
0036     MessagesModel *const mMessageModel;
0037 };