File indexing completed on 2024-09-08 07:33:55
0001 /* This file is part of the KDE project 0002 Copyright (C) 2007 Alessandro Praduroux <pradu@pradu.it> 0003 Copyright (C) 2013 Amandeep Singh <aman.dedman@gmail.com> 0004 0005 This program is free software; you can redistribute it and/or 0006 modify it under the terms of the GNU General Public 0007 License as published by the Free Software Foundation; either 0008 version 2 of the License, or (at your option) any later version. 0009 */ 0010 0011 #ifndef KRFB_MAINWINDOW_H 0012 #define KRFB_MAINWINDOW_H 0013 0014 #include "ui_mainwidget.h" 0015 0016 #include <KXmlGuiWindow> 0017 0018 class QLineEdit; 0019 0020 class MainWindow : public KXmlGuiWindow 0021 { 0022 Q_OBJECT 0023 0024 public: 0025 explicit MainWindow(QWidget *parent = nullptr); 0026 ~MainWindow() override; 0027 0028 public Q_SLOTS: 0029 void showConfiguration(); 0030 0031 protected: 0032 void readProperties(const KConfigGroup & group) override; 0033 void saveProperties(KConfigGroup & group) override; 0034 0035 private Q_SLOTS: 0036 void editPassword(); 0037 void editUnattendedPassword(); 0038 void toggleDesktopSharing(bool enable); 0039 void passwordChanged(const QString&); 0040 void aboutConnectionAddress(); 0041 void aboutUnattendedMode(); 0042 0043 private: 0044 Ui::MainWidget m_ui; 0045 bool m_passwordEditable; 0046 QLineEdit *m_passwordLineEdit = nullptr; 0047 }; 0048 0049 #endif