| 27 | #include <QMessageBox> |
| 28 | |
| 29 | DriverPathWidget::DriverPathWidget(const Path& path, bool enabled) : path(path), enabled(enabled) { |
| 30 | this->setChecked(enabled); |
| 31 | |
| 32 | const Configurator& configurator = Configurator::Get(); |
| 33 | |
| 34 | this->buttom_remove = new QPushButton(this); |
| 35 | this->buttom_remove->setIcon(::Get(configurator.current_theme_mode, ::ICON_FILE_REMOVE)); |
| 36 | this->buttom_remove->setFixedSize(24, 24); |
| 37 | |
| 38 | this->setText(format("%s", this->path.AbsolutePath().c_str()).c_str()); |
| 39 | this->setToolTip(format("%s", this->path.AbsolutePath().c_str()).c_str()); |
| 40 | |
| 41 | this->connect(this, SIGNAL(toggled(bool)), this, SLOT(on_toggled(bool))); |
| 42 | this->connect(this->buttom_remove, SIGNAL(clicked(bool)), this, SLOT(on_buttom_remove_clicked(bool))); |
| 43 | } |
| 44 | |
| 45 | void DriverPathWidget::resizeEvent(QResizeEvent* event) { |
| 46 | QSize size = event->size(); |
nothing calls this directly
no test coverage detected