Convert remaining QObject::connect to new syntax.
This commit is contained in:
parent
ae5089abfc
commit
b94564e360
|
@ -55,7 +55,7 @@ ConfigureOptionsDialog::ConfigureOptionsDialog(QWidget* parent, const OperationS
|
||||||
item = addPage(&generalPageWidget(), i18nc("@title:tab general application settings", "General"), QString(), i18n("General Settings"));
|
item = addPage(&generalPageWidget(), i18nc("@title:tab general application settings", "General"), QString(), i18n("General Settings"));
|
||||||
item->setIcon(QIcon::fromTheme(QStringLiteral("partitionmanager")).pixmap(IconSize(KIconLoader::Desktop)));
|
item->setIcon(QIcon::fromTheme(QStringLiteral("partitionmanager")).pixmap(IconSize(KIconLoader::Desktop)));
|
||||||
|
|
||||||
connect(&generalPageWidget().comboDefaultFileSystem(), SIGNAL(activated(int)), SLOT(onComboDefaultFileSystemActivated(int)));
|
connect(&generalPageWidget().comboDefaultFileSystem(), static_cast<void(QComboBox::*)(int)>(&QComboBox::activated), this, &ConfigureOptionsDialog::onComboDefaultFileSystemActivated);
|
||||||
connect(generalPageWidget().radioButton, &QRadioButton::toggled, this, &ConfigureOptionsDialog::onShredSourceActivated);
|
connect(generalPageWidget().radioButton, &QRadioButton::toggled, this, &ConfigureOptionsDialog::onShredSourceActivated);
|
||||||
|
|
||||||
item = addPage(&fileSystemColorsPageWidget(), i18nc("@title:tab", "File System Colors"), QString(), i18n("File System Color Settings"));
|
item = addPage(&fileSystemColorsPageWidget(), i18nc("@title:tab", "File System Colors"), QString(), i18n("File System Color Settings"));
|
||||||
|
@ -65,7 +65,7 @@ ConfigureOptionsDialog::ConfigureOptionsDialog(QWidget* parent, const OperationS
|
||||||
item = addPage(&advancedPageWidget(), i18nc("@title:tab advanced application settings", "Advanced"), QString(), i18n("Advanced Settings"));
|
item = addPage(&advancedPageWidget(), i18nc("@title:tab advanced application settings", "Advanced"), QString(), i18n("Advanced Settings"));
|
||||||
item->setIcon(QIcon::fromTheme(QStringLiteral("configure")).pixmap(IconSize(KIconLoader::Desktop)));
|
item->setIcon(QIcon::fromTheme(QStringLiteral("configure")).pixmap(IconSize(KIconLoader::Desktop)));
|
||||||
|
|
||||||
connect(&advancedPageWidget().comboBackend(), SIGNAL(activated(int)), SLOT(onComboBackendActivated(int)));
|
connect(&advancedPageWidget().comboBackend(), static_cast<void(QComboBox::*)(int)>(&QComboBox::activated), this, &ConfigureOptionsDialog::onComboDefaultFileSystemActivated);
|
||||||
} else
|
} else
|
||||||
advancedPageWidget().setVisible(false);
|
advancedPageWidget().setVisible(false);
|
||||||
|
|
||||||
|
|
|
@ -29,13 +29,11 @@ class OperationStack;
|
||||||
|
|
||||||
class ConfigureOptionsDialog : public KConfigDialog
|
class ConfigureOptionsDialog : public KConfigDialog
|
||||||
{
|
{
|
||||||
Q_OBJECT
|
|
||||||
|
|
||||||
public:
|
public:
|
||||||
ConfigureOptionsDialog(QWidget* parent, const OperationStack& ostack, const QString& name);
|
ConfigureOptionsDialog(QWidget* parent, const OperationStack& ostack, const QString& name);
|
||||||
~ConfigureOptionsDialog();
|
~ConfigureOptionsDialog();
|
||||||
|
|
||||||
protected Q_SLOTS:
|
protected:
|
||||||
void updateSettings() override;
|
void updateSettings() override;
|
||||||
void updateWidgetsDefault() override;
|
void updateWidgetsDefault() override;
|
||||||
bool hasChanged() override;
|
bool hasChanged() override;
|
||||||
|
@ -48,7 +46,6 @@ protected Q_SLOTS:
|
||||||
}
|
}
|
||||||
void onComboBackendActivated(int);
|
void onComboBackendActivated(int);
|
||||||
|
|
||||||
protected:
|
|
||||||
GeneralPageWidget& generalPageWidget() {
|
GeneralPageWidget& generalPageWidget() {
|
||||||
Q_ASSERT(m_GeneralPageWidget);
|
Q_ASSERT(m_GeneralPageWidget);
|
||||||
return *m_GeneralPageWidget;
|
return *m_GeneralPageWidget;
|
||||||
|
|
|
@ -26,8 +26,6 @@
|
||||||
*/
|
*/
|
||||||
class ApplyProgressDetailsWidget : public QWidget, public Ui::ApplyProgressDetailsWidgetBase
|
class ApplyProgressDetailsWidget : public QWidget, public Ui::ApplyProgressDetailsWidgetBase
|
||||||
{
|
{
|
||||||
Q_OBJECT
|
|
||||||
|
|
||||||
public:
|
public:
|
||||||
ApplyProgressDetailsWidget(QWidget* parent) : QWidget(parent) {
|
ApplyProgressDetailsWidget(QWidget* parent) : QWidget(parent) {
|
||||||
setupUi(this);
|
setupUi(this);
|
||||||
|
|
|
@ -43,7 +43,7 @@
|
||||||
|
|
||||||
#include <KAboutData>
|
#include <KAboutData>
|
||||||
#include <KConfigGroup>
|
#include <KConfigGroup>
|
||||||
#include <KIOWidgets/KRun>
|
#include <KRun>
|
||||||
#include <KIO/CopyJob>
|
#include <KIO/CopyJob>
|
||||||
#include <KJobUiDelegate>
|
#include <KJobUiDelegate>
|
||||||
#include <KLocalizedString>
|
#include <KLocalizedString>
|
||||||
|
@ -117,15 +117,15 @@ ApplyProgressDialog::~ApplyProgressDialog()
|
||||||
|
|
||||||
void ApplyProgressDialog::setupConnections()
|
void ApplyProgressDialog::setupConnections()
|
||||||
{
|
{
|
||||||
connect(&operationRunner(), SIGNAL(progressSub(int)), &dialogWidget().progressSub(), SLOT(setValue(int)));
|
connect(&operationRunner(), &OperationRunner::progressSub, &dialogWidget().progressSub(), &QProgressBar::setValue);
|
||||||
connect(&operationRunner(), SIGNAL(finished()), SLOT(onAllOpsFinished()));
|
connect(&operationRunner(), &OperationRunner::finished, this, &ApplyProgressDialog::onAllOpsFinished);
|
||||||
connect(&operationRunner(), SIGNAL(cancelled()), SLOT(onAllOpsCancelled()));
|
connect(&operationRunner(), &OperationRunner::cancelled, this, &ApplyProgressDialog::onAllOpsCancelled);
|
||||||
connect(&operationRunner(), SIGNAL(error()), SLOT(onAllOpsError()));
|
connect(&operationRunner(), &OperationRunner::error, this, &ApplyProgressDialog::onAllOpsError);
|
||||||
connect(&operationRunner(), SIGNAL(opStarted(int, Operation*)), SLOT(onOpStarted(int, Operation*)));
|
connect(&operationRunner(), &OperationRunner::opStarted, this, &ApplyProgressDialog::onOpStarted);
|
||||||
connect(&operationRunner(), SIGNAL(opFinished(int, Operation*)), SLOT(onOpFinished(int, Operation*)));
|
connect(&operationRunner(), &OperationRunner::opFinished, this, &ApplyProgressDialog::onOpFinished);
|
||||||
connect(&timer(), SIGNAL(timeout()), SLOT(onSecondElapsed()));
|
connect(&timer(), &QTimer::timeout, this, &ApplyProgressDialog::onSecondElapsed);
|
||||||
connect(&detailsWidget().buttonSave(), SIGNAL(clicked()), SLOT(saveReport()));
|
connect(&detailsWidget().buttonSave(), &QPushButton::clicked, this, &ApplyProgressDialog::saveReport);
|
||||||
connect(&detailsWidget().buttonBrowser(), SIGNAL(clicked()), SLOT(browserReport()));
|
connect(&detailsWidget().buttonBrowser(), &QPushButton::clicked, this, &ApplyProgressDialog::browserReport);
|
||||||
connect(dialogButtonBox, &QDialogButtonBox::accepted, this, &ApplyProgressDialog::accept);
|
connect(dialogButtonBox, &QDialogButtonBox::accepted, this, &ApplyProgressDialog::accept);
|
||||||
connect(dialogButtonBox, &QDialogButtonBox::rejected, this, &ApplyProgressDialog::reject);
|
connect(dialogButtonBox, &QDialogButtonBox::rejected, this, &ApplyProgressDialog::reject);
|
||||||
connect(detailsButton, &QPushButton::clicked, this, &ApplyProgressDialog::toggleDetails);
|
connect(detailsButton, &QPushButton::clicked, this, &ApplyProgressDialog::toggleDetails);
|
||||||
|
@ -165,7 +165,7 @@ void ApplyProgressDialog::resetReport()
|
||||||
detailsWidget().buttonSave().setEnabled(false);
|
detailsWidget().buttonSave().setEnabled(false);
|
||||||
detailsWidget().buttonBrowser().setEnabled(false);
|
detailsWidget().buttonBrowser().setEnabled(false);
|
||||||
|
|
||||||
connect(&report(), SIGNAL(outputChanged()), SLOT(updateReport()));
|
connect(&report(), &Report::outputChanged, this, &ApplyProgressDialog::updateReportUnforced);
|
||||||
}
|
}
|
||||||
|
|
||||||
void ApplyProgressDialog::closeEvent(QCloseEvent* e)
|
void ApplyProgressDialog::closeEvent(QCloseEvent* e)
|
||||||
|
@ -253,6 +253,11 @@ void ApplyProgressDialog::allOpsDone(const QString& msg)
|
||||||
setStatus(msg);
|
setStatus(msg);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
void ApplyProgressDialog::updateReportUnforced()
|
||||||
|
{
|
||||||
|
updateReport(false);
|
||||||
|
}
|
||||||
|
|
||||||
void ApplyProgressDialog::updateReport(bool force)
|
void ApplyProgressDialog::updateReport(bool force)
|
||||||
{
|
{
|
||||||
// Rendering the HTML in the QTextEdit is extremely expensive. So make sure not to do that
|
// Rendering the HTML in the QTextEdit is extremely expensive. So make sure not to do that
|
||||||
|
|
|
@ -45,7 +45,6 @@ class QKeyEvent;
|
||||||
*/
|
*/
|
||||||
class ApplyProgressDialog : public QDialog
|
class ApplyProgressDialog : public QDialog
|
||||||
{
|
{
|
||||||
Q_OBJECT
|
|
||||||
Q_DISABLE_COPY(ApplyProgressDialog)
|
Q_DISABLE_COPY(ApplyProgressDialog)
|
||||||
|
|
||||||
public:
|
public:
|
||||||
|
@ -64,7 +63,7 @@ public:
|
||||||
return *m_Report;
|
return *m_Report;
|
||||||
}
|
}
|
||||||
|
|
||||||
protected Q_SLOTS:
|
protected:
|
||||||
void onAllOpsFinished();
|
void onAllOpsFinished();
|
||||||
void onAllOpsCancelled();
|
void onAllOpsCancelled();
|
||||||
void onAllOpsError();
|
void onAllOpsError();
|
||||||
|
@ -76,9 +75,9 @@ protected Q_SLOTS:
|
||||||
void onSecondElapsed();
|
void onSecondElapsed();
|
||||||
void saveReport();
|
void saveReport();
|
||||||
void browserReport();
|
void browserReport();
|
||||||
|
void updateReportUnforced();
|
||||||
void updateReport(bool force = false);
|
void updateReport(bool force = false);
|
||||||
|
|
||||||
protected:
|
|
||||||
void onJobStarted(Job* job, Operation* op);
|
void onJobStarted(Job* job, Operation* op);
|
||||||
void onJobFinished(Job* job, Operation* op);
|
void onJobFinished(Job* job, Operation* op);
|
||||||
void toggleDetails();
|
void toggleDetails();
|
||||||
|
|
|
@ -44,7 +44,7 @@ CreatePartitionTableDialog::CreatePartitionTableDialog(QWidget* parent, const De
|
||||||
cancelButton = dialogButtonBox->addButton(QDialogButtonBox::Cancel);
|
cancelButton = dialogButtonBox->addButton(QDialogButtonBox::Cancel);
|
||||||
mainLayout->addWidget(dialogButtonBox);
|
mainLayout->addWidget(dialogButtonBox);
|
||||||
|
|
||||||
connect(&widget().radioMSDOS(), SIGNAL(toggled(bool)), SLOT(onMSDOSToggled(bool)));
|
connect(&widget().radioMSDOS(), &QRadioButton::toggled, this, &CreatePartitionTableDialog::onMSDOSToggled);
|
||||||
connect(dialogButtonBox, &QDialogButtonBox::accepted, this, &CreatePartitionTableDialog::accept);
|
connect(dialogButtonBox, &QDialogButtonBox::accepted, this, &CreatePartitionTableDialog::accept);
|
||||||
connect(dialogButtonBox, &QDialogButtonBox::rejected, this, &CreatePartitionTableDialog::reject);
|
connect(dialogButtonBox, &QDialogButtonBox::rejected, this, &CreatePartitionTableDialog::reject);
|
||||||
}
|
}
|
||||||
|
|
|
@ -32,8 +32,6 @@ class QPushButton;
|
||||||
|
|
||||||
class CreatePartitionTableDialog : public QDialog
|
class CreatePartitionTableDialog : public QDialog
|
||||||
{
|
{
|
||||||
Q_OBJECT
|
|
||||||
|
|
||||||
public:
|
public:
|
||||||
CreatePartitionTableDialog(QWidget* parent, const Device& d);
|
CreatePartitionTableDialog(QWidget* parent, const Device& d);
|
||||||
|
|
||||||
|
@ -51,7 +49,6 @@ protected:
|
||||||
return m_Device;
|
return m_Device;
|
||||||
}
|
}
|
||||||
|
|
||||||
protected Q_SLOTS:
|
|
||||||
void onMSDOSToggled(bool on);
|
void onMSDOSToggled(bool on);
|
||||||
|
|
||||||
private:
|
private:
|
||||||
|
|
|
@ -27,8 +27,6 @@
|
||||||
|
|
||||||
class CreatePartitionTableWidget : public QWidget, public Ui::CreatePartitionTableWidgetBase
|
class CreatePartitionTableWidget : public QWidget, public Ui::CreatePartitionTableWidgetBase
|
||||||
{
|
{
|
||||||
Q_OBJECT
|
|
||||||
|
|
||||||
public:
|
public:
|
||||||
CreatePartitionTableWidget(QWidget* parent);
|
CreatePartitionTableWidget(QWidget* parent);
|
||||||
|
|
||||||
|
|
|
@ -137,9 +137,9 @@ void DevicePropsDialog::setupDialog()
|
||||||
|
|
||||||
void DevicePropsDialog::setupConnections()
|
void DevicePropsDialog::setupConnections()
|
||||||
{
|
{
|
||||||
connect(&dialogWidget().radioSectorBased(), SIGNAL(toggled(bool)), SLOT(setDirty(bool)));
|
connect(&dialogWidget().radioSectorBased(), &QRadioButton::toggled, this, &DevicePropsDialog::setDirty);
|
||||||
connect(&dialogWidget().radioCylinderBased(), SIGNAL(toggled(bool)), SLOT(setDirty(bool)));
|
connect(&dialogWidget().radioCylinderBased(), &QRadioButton::toggled, this, &DevicePropsDialog::setDirty);
|
||||||
connect(&dialogWidget().buttonSmartMore(), SIGNAL(clicked(bool)), SLOT(onButtonSmartMore(bool)));
|
connect(&dialogWidget().buttonSmartMore(), &QPushButton::clicked, this, &DevicePropsDialog::onButtonSmartMore);
|
||||||
}
|
}
|
||||||
|
|
||||||
void DevicePropsDialog::setDirty(bool)
|
void DevicePropsDialog::setDirty(bool)
|
||||||
|
|
|
@ -39,7 +39,6 @@ class QString;
|
||||||
*/
|
*/
|
||||||
class DevicePropsDialog : public QDialog
|
class DevicePropsDialog : public QDialog
|
||||||
{
|
{
|
||||||
Q_OBJECT
|
|
||||||
Q_DISABLE_COPY(DevicePropsDialog)
|
Q_DISABLE_COPY(DevicePropsDialog)
|
||||||
|
|
||||||
public:
|
public:
|
||||||
|
@ -70,9 +69,6 @@ protected:
|
||||||
return *m_DialogWidget;
|
return *m_DialogWidget;
|
||||||
}
|
}
|
||||||
|
|
||||||
void onButtonSmartMore();
|
|
||||||
|
|
||||||
protected Q_SLOTS:
|
|
||||||
void setDirty(bool);
|
void setDirty(bool);
|
||||||
void onButtonSmartMore(bool);
|
void onButtonSmartMore(bool);
|
||||||
|
|
||||||
|
|
|
@ -29,8 +29,6 @@ class QWidget;
|
||||||
|
|
||||||
class EditMountOptionsDialog : public QDialog
|
class EditMountOptionsDialog : public QDialog
|
||||||
{
|
{
|
||||||
Q_OBJECT
|
|
||||||
|
|
||||||
public:
|
public:
|
||||||
EditMountOptionsDialog(QWidget* parent, const QStringList& options);
|
EditMountOptionsDialog(QWidget* parent, const QStringList& options);
|
||||||
~EditMountOptionsDialog();
|
~EditMountOptionsDialog();
|
||||||
|
|
|
@ -30,8 +30,6 @@ class QString;
|
||||||
|
|
||||||
class EditMountPointDialog : public QDialog
|
class EditMountPointDialog : public QDialog
|
||||||
{
|
{
|
||||||
Q_OBJECT
|
|
||||||
|
|
||||||
public:
|
public:
|
||||||
EditMountPointDialog(QWidget* parent, Partition& p);
|
EditMountPointDialog(QWidget* parent, Partition& p);
|
||||||
~EditMountPointDialog();
|
~EditMountPointDialog();
|
||||||
|
@ -41,7 +39,6 @@ protected:
|
||||||
return *m_DialogWidget;
|
return *m_DialogWidget;
|
||||||
}
|
}
|
||||||
|
|
||||||
protected Q_SLOTS:
|
|
||||||
void accept() override;
|
void accept() override;
|
||||||
|
|
||||||
private:
|
private:
|
||||||
|
|
|
@ -108,7 +108,7 @@ void FileSystemSupportDialog::setupDialog()
|
||||||
void FileSystemSupportDialog::setupConnections()
|
void FileSystemSupportDialog::setupConnections()
|
||||||
{
|
{
|
||||||
connect(dialogButtonBox->button(QDialogButtonBox::Ok), &QPushButton::clicked, this, &FileSystemSupportDialog::close);
|
connect(dialogButtonBox->button(QDialogButtonBox::Ok), &QPushButton::clicked, this, &FileSystemSupportDialog::close);
|
||||||
connect(&dialogWidget().buttonRescan(), SIGNAL(clicked()), SLOT(onButtonRescanClicked()));
|
connect(&dialogWidget().buttonRescan(), &QPushButton::clicked, this, &FileSystemSupportDialog::onButtonRescanClicked);
|
||||||
}
|
}
|
||||||
|
|
||||||
void FileSystemSupportDialog::onButtonRescanClicked()
|
void FileSystemSupportDialog::onButtonRescanClicked()
|
||||||
|
|
|
@ -35,7 +35,6 @@ class FileSystemSupportDialogWidget;
|
||||||
*/
|
*/
|
||||||
class FileSystemSupportDialog : public QDialog
|
class FileSystemSupportDialog : public QDialog
|
||||||
{
|
{
|
||||||
Q_OBJECT
|
|
||||||
Q_DISABLE_COPY(FileSystemSupportDialog)
|
Q_DISABLE_COPY(FileSystemSupportDialog)
|
||||||
|
|
||||||
public:
|
public:
|
||||||
|
@ -45,10 +44,9 @@ public:
|
||||||
public:
|
public:
|
||||||
QSize sizeHint() const override;
|
QSize sizeHint() const override;
|
||||||
|
|
||||||
protected Q_SLOTS:
|
protected:
|
||||||
void onButtonRescanClicked();
|
void onButtonRescanClicked();
|
||||||
|
|
||||||
protected:
|
|
||||||
FileSystemSupportDialogWidget& dialogWidget() {
|
FileSystemSupportDialogWidget& dialogWidget() {
|
||||||
Q_ASSERT(m_FileSystemSupportDialogWidget);
|
Q_ASSERT(m_FileSystemSupportDialogWidget);
|
||||||
return *m_FileSystemSupportDialogWidget;
|
return *m_FileSystemSupportDialogWidget;
|
||||||
|
|
|
@ -33,8 +33,6 @@ class Device;
|
||||||
*/
|
*/
|
||||||
class InsertDialog : public SizeDialogBase
|
class InsertDialog : public SizeDialogBase
|
||||||
{
|
{
|
||||||
Q_OBJECT
|
|
||||||
|
|
||||||
public:
|
public:
|
||||||
InsertDialog(QWidget* parent, Device& device, Partition& insertedPartition, const Partition& destPartition);
|
InsertDialog(QWidget* parent, Device& device, Partition& insertedPartition, const Partition& destPartition);
|
||||||
~InsertDialog();
|
~InsertDialog();
|
||||||
|
|
|
@ -51,7 +51,6 @@ public:
|
||||||
}
|
}
|
||||||
bool setSelectedDevice(const QString& device_node);
|
bool setSelectedDevice(const QString& device_node);
|
||||||
|
|
||||||
public Q_SLOTS:
|
|
||||||
void updateDevices(OperationStack::Devices& devices);
|
void updateDevices(OperationStack::Devices& devices);
|
||||||
|
|
||||||
protected:
|
protected:
|
||||||
|
|
|
@ -49,7 +49,6 @@ public:
|
||||||
m_ActionCollection = coll;
|
m_ActionCollection = coll;
|
||||||
}
|
}
|
||||||
|
|
||||||
public Q_SLOTS:
|
|
||||||
void updateOperations(const OperationStack::Operations& ops);
|
void updateOperations(const OperationStack::Operations& ops);
|
||||||
|
|
||||||
protected:
|
protected:
|
||||||
|
|
|
@ -182,7 +182,8 @@ void MainWindow::setupActions()
|
||||||
KStandardAction::quit(this, SLOT(close()), actionCollection());
|
KStandardAction::quit(this, SLOT(close()), actionCollection());
|
||||||
|
|
||||||
// Edit actions
|
// Edit actions
|
||||||
QAction* undoOperation = actionCollection()->addAction(QStringLiteral("undoOperation"), this, SLOT(onUndoOperation()));
|
QAction* undoOperation = actionCollection()->addAction(QStringLiteral("undoOperation"));
|
||||||
|
connect(undoOperation, &QAction::triggered, this, &MainWindow::onUndoOperation);
|
||||||
undoOperation->setEnabled(false);
|
undoOperation->setEnabled(false);
|
||||||
undoOperation->setText(i18nc("@action:inmenu", "Undo"));
|
undoOperation->setText(i18nc("@action:inmenu", "Undo"));
|
||||||
undoOperation->setToolTip(i18nc("@info:tooltip", "Undo the last operation"));
|
undoOperation->setToolTip(i18nc("@info:tooltip", "Undo the last operation"));
|
||||||
|
@ -190,14 +191,16 @@ void MainWindow::setupActions()
|
||||||
actionCollection()->setDefaultShortcut(undoOperation, QKeySequence(Qt::CTRL + Qt::Key_Z));
|
actionCollection()->setDefaultShortcut(undoOperation, QKeySequence(Qt::CTRL + Qt::Key_Z));
|
||||||
undoOperation->setIcon(QIcon::fromTheme(QStringLiteral("edit-undo")).pixmap(IconSize(KIconLoader::Toolbar)));
|
undoOperation->setIcon(QIcon::fromTheme(QStringLiteral("edit-undo")).pixmap(IconSize(KIconLoader::Toolbar)));
|
||||||
|
|
||||||
QAction* clearAllOperations = actionCollection()->addAction(QStringLiteral("clearAllOperations"), this, SLOT(onClearAllOperations()));
|
QAction* clearAllOperations = actionCollection()->addAction(QStringLiteral("clearAllOperations"));
|
||||||
|
connect(clearAllOperations, &QAction::triggered, this, &MainWindow::onClearAllOperations);
|
||||||
clearAllOperations->setEnabled(false);
|
clearAllOperations->setEnabled(false);
|
||||||
clearAllOperations->setText(i18nc("@action:inmenu clear the list of operations", "Clear"));
|
clearAllOperations->setText(i18nc("@action:inmenu clear the list of operations", "Clear"));
|
||||||
clearAllOperations->setToolTip(i18nc("@info:tooltip", "Clear all operations"));
|
clearAllOperations->setToolTip(i18nc("@info:tooltip", "Clear all operations"));
|
||||||
clearAllOperations->setStatusTip(i18nc("@info:status", "Empty the list of pending operations."));
|
clearAllOperations->setStatusTip(i18nc("@info:status", "Empty the list of pending operations."));
|
||||||
clearAllOperations->setIcon(QIcon::fromTheme(QStringLiteral("dialog-cancel")).pixmap(IconSize(KIconLoader::Toolbar)));
|
clearAllOperations->setIcon(QIcon::fromTheme(QStringLiteral("dialog-cancel")).pixmap(IconSize(KIconLoader::Toolbar)));
|
||||||
|
|
||||||
QAction* applyAllOperations = actionCollection()->addAction(QStringLiteral("applyAllOperations"), this, SLOT(onApplyAllOperations()));
|
QAction* applyAllOperations = actionCollection()->addAction(QStringLiteral("applyAllOperations"));
|
||||||
|
connect(applyAllOperations, &QAction::triggered, this, &MainWindow::onApplyAllOperations);
|
||||||
applyAllOperations->setEnabled(false);
|
applyAllOperations->setEnabled(false);
|
||||||
applyAllOperations->setText(i18nc("@action:inmenu apply all operations", "Apply"));
|
applyAllOperations->setText(i18nc("@action:inmenu apply all operations", "Apply"));
|
||||||
applyAllOperations->setToolTip(i18nc("@info:tooltip", "Apply all operations"));
|
applyAllOperations->setToolTip(i18nc("@info:tooltip", "Apply all operations"));
|
||||||
|
@ -205,14 +208,16 @@ void MainWindow::setupActions()
|
||||||
applyAllOperations->setIcon(QIcon::fromTheme(QStringLiteral("dialog-ok-apply")).pixmap(IconSize(KIconLoader::Toolbar)));
|
applyAllOperations->setIcon(QIcon::fromTheme(QStringLiteral("dialog-ok-apply")).pixmap(IconSize(KIconLoader::Toolbar)));
|
||||||
|
|
||||||
// Device actions
|
// Device actions
|
||||||
QAction* refreshDevices = actionCollection()->addAction(QStringLiteral("refreshDevices"), this, SLOT(onRefreshDevices()));
|
QAction* refreshDevices = actionCollection()->addAction(QStringLiteral("refreshDevices"));
|
||||||
|
connect(refreshDevices, &QAction::triggered, this, &MainWindow::onRefreshDevices);
|
||||||
refreshDevices->setText(i18nc("@action:inmenu refresh list of devices", "Refresh Devices"));
|
refreshDevices->setText(i18nc("@action:inmenu refresh list of devices", "Refresh Devices"));
|
||||||
refreshDevices->setToolTip(i18nc("@info:tooltip", "Refresh all devices"));
|
refreshDevices->setToolTip(i18nc("@info:tooltip", "Refresh all devices"));
|
||||||
refreshDevices->setStatusTip(i18nc("@info:status", "Renew the devices list."));
|
refreshDevices->setStatusTip(i18nc("@info:status", "Renew the devices list."));
|
||||||
actionCollection()->setDefaultShortcut(refreshDevices, Qt::Key_F5);
|
actionCollection()->setDefaultShortcut(refreshDevices, Qt::Key_F5);
|
||||||
refreshDevices->setIcon(QIcon::fromTheme(QStringLiteral("view-refresh")).pixmap(IconSize(KIconLoader::Toolbar)));
|
refreshDevices->setIcon(QIcon::fromTheme(QStringLiteral("view-refresh")).pixmap(IconSize(KIconLoader::Toolbar)));
|
||||||
|
|
||||||
QAction* createNewPartitionTable = actionCollection()->addAction(QStringLiteral("createNewPartitionTable"), this, SLOT(onCreateNewPartitionTable()));
|
QAction* createNewPartitionTable = actionCollection()->addAction(QStringLiteral("createNewPartitionTable"));
|
||||||
|
connect(createNewPartitionTable, &QAction::triggered, this, &MainWindow::onCreateNewPartitionTable);
|
||||||
createNewPartitionTable->setEnabled(false);
|
createNewPartitionTable->setEnabled(false);
|
||||||
createNewPartitionTable->setText(i18nc("@action:inmenu", "New Partition Table"));
|
createNewPartitionTable->setText(i18nc("@action:inmenu", "New Partition Table"));
|
||||||
createNewPartitionTable->setToolTip(i18nc("@info:tooltip", "Create a new partition table"));
|
createNewPartitionTable->setToolTip(i18nc("@info:tooltip", "Create a new partition table"));
|
||||||
|
@ -220,27 +225,31 @@ void MainWindow::setupActions()
|
||||||
actionCollection()->setDefaultShortcut(createNewPartitionTable, QKeySequence(Qt::CTRL + Qt::SHIFT + Qt::Key_N));
|
actionCollection()->setDefaultShortcut(createNewPartitionTable, QKeySequence(Qt::CTRL + Qt::SHIFT + Qt::Key_N));
|
||||||
createNewPartitionTable->setIcon(QIcon::fromTheme(QStringLiteral("edit-clear")).pixmap(IconSize(KIconLoader::Toolbar)));
|
createNewPartitionTable->setIcon(QIcon::fromTheme(QStringLiteral("edit-clear")).pixmap(IconSize(KIconLoader::Toolbar)));
|
||||||
|
|
||||||
QAction* exportPartitionTable = actionCollection()->addAction(QStringLiteral("exportPartitionTable"), this, SLOT(onExportPartitionTable()));
|
QAction* exportPartitionTable = actionCollection()->addAction(QStringLiteral("exportPartitionTable"));
|
||||||
|
connect(exportPartitionTable, &QAction::triggered, this, &MainWindow::onExportPartitionTable);
|
||||||
exportPartitionTable->setEnabled(false);
|
exportPartitionTable->setEnabled(false);
|
||||||
exportPartitionTable->setText(i18nc("@action:inmenu", "Export Partition Table"));
|
exportPartitionTable->setText(i18nc("@action:inmenu", "Export Partition Table"));
|
||||||
exportPartitionTable->setToolTip(i18nc("@info:tooltip", "Export a partition table"));
|
exportPartitionTable->setToolTip(i18nc("@info:tooltip", "Export a partition table"));
|
||||||
exportPartitionTable->setStatusTip(i18nc("@info:status", "Export the device's partition table to a text file."));
|
exportPartitionTable->setStatusTip(i18nc("@info:status", "Export the device's partition table to a text file."));
|
||||||
exportPartitionTable->setIcon(QIcon::fromTheme(QStringLiteral("document-export")).pixmap(IconSize(KIconLoader::Toolbar)));
|
exportPartitionTable->setIcon(QIcon::fromTheme(QStringLiteral("document-export")).pixmap(IconSize(KIconLoader::Toolbar)));
|
||||||
|
|
||||||
QAction* importPartitionTable = actionCollection()->addAction(QStringLiteral("importPartitionTable"), this, SLOT(onImportPartitionTable()));
|
QAction* importPartitionTable = actionCollection()->addAction(QStringLiteral("importPartitionTable"));
|
||||||
|
connect(importPartitionTable, &QAction::triggered, this, &MainWindow::onImportPartitionTable);
|
||||||
importPartitionTable->setEnabled(false);
|
importPartitionTable->setEnabled(false);
|
||||||
importPartitionTable->setText(i18nc("@action:inmenu", "Import Partition Table"));
|
importPartitionTable->setText(i18nc("@action:inmenu", "Import Partition Table"));
|
||||||
importPartitionTable->setToolTip(i18nc("@info:tooltip", "Import a partition table"));
|
importPartitionTable->setToolTip(i18nc("@info:tooltip", "Import a partition table"));
|
||||||
importPartitionTable->setStatusTip(i18nc("@info:status", "Import a partition table from a text file."));
|
importPartitionTable->setStatusTip(i18nc("@info:status", "Import a partition table from a text file."));
|
||||||
importPartitionTable->setIcon(QIcon::fromTheme(QStringLiteral("document-import")).pixmap(IconSize(KIconLoader::Toolbar)));
|
importPartitionTable->setIcon(QIcon::fromTheme(QStringLiteral("document-import")).pixmap(IconSize(KIconLoader::Toolbar)));
|
||||||
|
|
||||||
QAction* smartStatusDevice = actionCollection()->addAction(QStringLiteral("smartStatusDevice"), this, SLOT(onSmartStatusDevice()));
|
QAction* smartStatusDevice = actionCollection()->addAction(QStringLiteral("smartStatusDevice"));
|
||||||
|
connect(smartStatusDevice, &QAction::triggered, this, &MainWindow::onSmartStatusDevice);
|
||||||
smartStatusDevice->setEnabled(false);
|
smartStatusDevice->setEnabled(false);
|
||||||
smartStatusDevice->setText(i18nc("@action:inmenu", "SMART Status"));
|
smartStatusDevice->setText(i18nc("@action:inmenu", "SMART Status"));
|
||||||
smartStatusDevice->setToolTip(i18nc("@info:tooltip", "Show SMART status"));
|
smartStatusDevice->setToolTip(i18nc("@info:tooltip", "Show SMART status"));
|
||||||
smartStatusDevice->setStatusTip(i18nc("@info:status", "Show the device's SMART status if supported"));
|
smartStatusDevice->setStatusTip(i18nc("@info:status", "Show the device's SMART status if supported"));
|
||||||
|
|
||||||
QAction* propertiesDevice = actionCollection()->addAction(QStringLiteral("propertiesDevice"), this, SLOT(onPropertiesDevice()));
|
QAction* propertiesDevice = actionCollection()->addAction(QStringLiteral("propertiesDevice"));
|
||||||
|
connect(propertiesDevice, &QAction::triggered, this, &MainWindow::onPropertiesDevice2);
|
||||||
propertiesDevice->setEnabled(false);
|
propertiesDevice->setEnabled(false);
|
||||||
propertiesDevice->setText(i18nc("@action:inmenu", "Properties"));
|
propertiesDevice->setText(i18nc("@action:inmenu", "Properties"));
|
||||||
propertiesDevice->setToolTip(i18nc("@info:tooltip", "Show device properties dialog"));
|
propertiesDevice->setToolTip(i18nc("@info:tooltip", "Show device properties dialog"));
|
||||||
|
@ -248,7 +257,8 @@ void MainWindow::setupActions()
|
||||||
propertiesDevice->setIcon(QIcon::fromTheme(QStringLiteral("document-properties")).pixmap(IconSize(KIconLoader::Toolbar)));
|
propertiesDevice->setIcon(QIcon::fromTheme(QStringLiteral("document-properties")).pixmap(IconSize(KIconLoader::Toolbar)));
|
||||||
|
|
||||||
// Partition actions
|
// Partition actions
|
||||||
QAction* newPartition = actionCollection()->addAction(QStringLiteral("newPartition"), &pmWidget(), SLOT(onNewPartition()));
|
QAction* newPartition = actionCollection()->addAction(QStringLiteral("newPartition"));
|
||||||
|
connect(newPartition, &QAction::triggered, &pmWidget(), &PartitionManagerWidget::onNewPartition);
|
||||||
newPartition->setEnabled(false);
|
newPartition->setEnabled(false);
|
||||||
newPartition->setText(i18nc("@action:inmenu create a new partition", "New"));
|
newPartition->setText(i18nc("@action:inmenu create a new partition", "New"));
|
||||||
newPartition->setToolTip(i18nc("@info:tooltip", "New partition"));
|
newPartition->setToolTip(i18nc("@info:tooltip", "New partition"));
|
||||||
|
@ -256,7 +266,8 @@ void MainWindow::setupActions()
|
||||||
actionCollection()->setDefaultShortcut(newPartition, QKeySequence(Qt::CTRL + Qt::Key_N));
|
actionCollection()->setDefaultShortcut(newPartition, QKeySequence(Qt::CTRL + Qt::Key_N));
|
||||||
newPartition->setIcon(QIcon::fromTheme(QStringLiteral("document-new")).pixmap(IconSize(KIconLoader::Toolbar)));
|
newPartition->setIcon(QIcon::fromTheme(QStringLiteral("document-new")).pixmap(IconSize(KIconLoader::Toolbar)));
|
||||||
|
|
||||||
QAction* resizePartition = actionCollection()->addAction(QStringLiteral("resizePartition"), &pmWidget(), SLOT(onResizePartition()));
|
QAction* resizePartition = actionCollection()->addAction(QStringLiteral("resizePartition"));
|
||||||
|
connect(resizePartition, &QAction::triggered, &pmWidget(), &PartitionManagerWidget::onResizePartition);
|
||||||
resizePartition->setEnabled(false);
|
resizePartition->setEnabled(false);
|
||||||
resizePartition->setText(i18nc("@action:inmenu", "Resize/Move"));
|
resizePartition->setText(i18nc("@action:inmenu", "Resize/Move"));
|
||||||
resizePartition->setToolTip(i18nc("@info:tooltip", "Resize or move partition"));
|
resizePartition->setToolTip(i18nc("@info:tooltip", "Resize or move partition"));
|
||||||
|
@ -264,7 +275,8 @@ void MainWindow::setupActions()
|
||||||
actionCollection()->setDefaultShortcut(resizePartition, QKeySequence(Qt::CTRL + Qt::Key_R));
|
actionCollection()->setDefaultShortcut(resizePartition, QKeySequence(Qt::CTRL + Qt::Key_R));
|
||||||
resizePartition->setIcon(QIcon::fromTheme(QStringLiteral("arrow-right-double")).pixmap(IconSize(KIconLoader::Toolbar)));
|
resizePartition->setIcon(QIcon::fromTheme(QStringLiteral("arrow-right-double")).pixmap(IconSize(KIconLoader::Toolbar)));
|
||||||
|
|
||||||
QAction* deletePartition = actionCollection()->addAction(QStringLiteral("deletePartition"), &pmWidget(), SLOT(onDeletePartition()));
|
QAction* deletePartition = actionCollection()->addAction(QStringLiteral("deletePartition"));
|
||||||
|
connect(deletePartition, &QAction::triggered, &pmWidget(), &PartitionManagerWidget::onDeletePartition);
|
||||||
deletePartition->setEnabled(false);
|
deletePartition->setEnabled(false);
|
||||||
deletePartition->setText(i18nc("@action:inmenu", "Delete"));
|
deletePartition->setText(i18nc("@action:inmenu", "Delete"));
|
||||||
deletePartition->setToolTip(i18nc("@info:tooltip", "Delete partition"));
|
deletePartition->setToolTip(i18nc("@info:tooltip", "Delete partition"));
|
||||||
|
@ -272,7 +284,8 @@ void MainWindow::setupActions()
|
||||||
actionCollection()->setDefaultShortcut(deletePartition, QKeySequence::Delete);
|
actionCollection()->setDefaultShortcut(deletePartition, QKeySequence::Delete);
|
||||||
deletePartition->setIcon(QIcon::fromTheme(QStringLiteral("edit-delete")).pixmap(IconSize(KIconLoader::Toolbar)));
|
deletePartition->setIcon(QIcon::fromTheme(QStringLiteral("edit-delete")).pixmap(IconSize(KIconLoader::Toolbar)));
|
||||||
|
|
||||||
QAction* shredPartition = actionCollection()->addAction(QStringLiteral("shredPartition"), &pmWidget(), SLOT(onShredPartition()));
|
QAction* shredPartition = actionCollection()->addAction(QStringLiteral("shredPartition"));
|
||||||
|
connect(shredPartition, &QAction::triggered, &pmWidget(), &PartitionManagerWidget::onShredPartition);
|
||||||
shredPartition->setEnabled(false);
|
shredPartition->setEnabled(false);
|
||||||
shredPartition->setText(i18nc("@action:inmenu", "Shred"));
|
shredPartition->setText(i18nc("@action:inmenu", "Shred"));
|
||||||
shredPartition->setToolTip(i18nc("@info:tooltip", "Shred partition"));
|
shredPartition->setToolTip(i18nc("@info:tooltip", "Shred partition"));
|
||||||
|
@ -280,7 +293,8 @@ void MainWindow::setupActions()
|
||||||
actionCollection()->setDefaultShortcut(shredPartition, QKeySequence(Qt::SHIFT + Qt::Key_Delete));
|
actionCollection()->setDefaultShortcut(shredPartition, QKeySequence(Qt::SHIFT + Qt::Key_Delete));
|
||||||
shredPartition->setIcon(QIcon::fromTheme(QStringLiteral("edit-delete-shred")).pixmap(IconSize(KIconLoader::Toolbar)));
|
shredPartition->setIcon(QIcon::fromTheme(QStringLiteral("edit-delete-shred")).pixmap(IconSize(KIconLoader::Toolbar)));
|
||||||
|
|
||||||
QAction* copyPartition = actionCollection()->addAction(QStringLiteral("copyPartition"), &pmWidget(), SLOT(onCopyPartition()));
|
QAction* copyPartition = actionCollection()->addAction(QStringLiteral("copyPartition"));
|
||||||
|
connect(copyPartition, &QAction::triggered, &pmWidget(), &PartitionManagerWidget::onCopyPartition);
|
||||||
copyPartition->setEnabled(false);
|
copyPartition->setEnabled(false);
|
||||||
copyPartition->setText(i18nc("@action:inmenu", "Copy"));
|
copyPartition->setText(i18nc("@action:inmenu", "Copy"));
|
||||||
copyPartition->setToolTip(i18nc("@info:tooltip", "Copy partition"));
|
copyPartition->setToolTip(i18nc("@info:tooltip", "Copy partition"));
|
||||||
|
@ -288,7 +302,8 @@ void MainWindow::setupActions()
|
||||||
actionCollection()->setDefaultShortcut(copyPartition, QKeySequence(Qt::CTRL + Qt::Key_C));
|
actionCollection()->setDefaultShortcut(copyPartition, QKeySequence(Qt::CTRL + Qt::Key_C));
|
||||||
copyPartition->setIcon(QIcon::fromTheme(QStringLiteral("edit-copy")).pixmap(IconSize(KIconLoader::Toolbar)));
|
copyPartition->setIcon(QIcon::fromTheme(QStringLiteral("edit-copy")).pixmap(IconSize(KIconLoader::Toolbar)));
|
||||||
|
|
||||||
QAction* pastePartition = actionCollection()->addAction(QStringLiteral("pastePartition"), &pmWidget(), SLOT(onPastePartition()));
|
QAction* pastePartition = actionCollection()->addAction(QStringLiteral("pastePartition"));
|
||||||
|
connect(pastePartition, &QAction::triggered, &pmWidget(), &PartitionManagerWidget::onPastePartition);
|
||||||
pastePartition->setEnabled(false);
|
pastePartition->setEnabled(false);
|
||||||
pastePartition->setText(i18nc("@action:inmenu", "Paste"));
|
pastePartition->setText(i18nc("@action:inmenu", "Paste"));
|
||||||
pastePartition->setToolTip(i18nc("@info:tooltip", "Paste partition"));
|
pastePartition->setToolTip(i18nc("@info:tooltip", "Paste partition"));
|
||||||
|
@ -296,46 +311,53 @@ void MainWindow::setupActions()
|
||||||
actionCollection()->setDefaultShortcut(pastePartition, QKeySequence(Qt::CTRL + Qt::Key_V));
|
actionCollection()->setDefaultShortcut(pastePartition, QKeySequence(Qt::CTRL + Qt::Key_V));
|
||||||
pastePartition->setIcon(QIcon::fromTheme(QStringLiteral("edit-paste")).pixmap(IconSize(KIconLoader::Toolbar)));
|
pastePartition->setIcon(QIcon::fromTheme(QStringLiteral("edit-paste")).pixmap(IconSize(KIconLoader::Toolbar)));
|
||||||
|
|
||||||
QAction* editMountPoint = actionCollection()->addAction(QStringLiteral("editMountPoint"), &pmWidget(), SLOT(onEditMountPoint()));
|
QAction* editMountPoint = actionCollection()->addAction(QStringLiteral("editMountPoint"));
|
||||||
|
connect(editMountPoint, &QAction::triggered, &pmWidget(), &PartitionManagerWidget::onEditMountPoint);
|
||||||
editMountPoint->setEnabled(false);
|
editMountPoint->setEnabled(false);
|
||||||
editMountPoint->setText(i18nc("@action:inmenu", "Edit Mount Point"));
|
editMountPoint->setText(i18nc("@action:inmenu", "Edit Mount Point"));
|
||||||
editMountPoint->setToolTip(i18nc("@info:tooltip", "Edit mount point"));
|
editMountPoint->setToolTip(i18nc("@info:tooltip", "Edit mount point"));
|
||||||
editMountPoint->setStatusTip(i18nc("@info:status", "Edit a partition's mount point and options."));
|
editMountPoint->setStatusTip(i18nc("@info:status", "Edit a partition's mount point and options."));
|
||||||
|
|
||||||
QAction* mountPartition = actionCollection()->addAction(QStringLiteral("mountPartition"), &pmWidget(), SLOT(onMountPartition()));
|
QAction* mountPartition = actionCollection()->addAction(QStringLiteral("mountPartition"));
|
||||||
|
connect(mountPartition, &QAction::triggered, &pmWidget(), &PartitionManagerWidget::onMountPartition);
|
||||||
mountPartition->setEnabled(false);
|
mountPartition->setEnabled(false);
|
||||||
mountPartition->setText(i18nc("@action:inmenu", "Mount"));
|
mountPartition->setText(i18nc("@action:inmenu", "Mount"));
|
||||||
mountPartition->setToolTip(i18nc("@info:tooltip", "Mount or unmount partition"));
|
mountPartition->setToolTip(i18nc("@info:tooltip", "Mount or unmount partition"));
|
||||||
mountPartition->setStatusTip(i18nc("@info:status", "Mount or unmount a partition."));
|
mountPartition->setStatusTip(i18nc("@info:status", "Mount or unmount a partition."));
|
||||||
|
|
||||||
QAction* decryptPartition = actionCollection()->addAction(QStringLiteral("decryptPartition"), &pmWidget(), SLOT(onDecryptPartition()));
|
QAction* decryptPartition = actionCollection()->addAction(QStringLiteral("decryptPartition"));
|
||||||
|
connect(decryptPartition, &QAction::triggered, &pmWidget(), &PartitionManagerWidget::onDecryptPartition);
|
||||||
decryptPartition->setEnabled(false);
|
decryptPartition->setEnabled(false);
|
||||||
decryptPartition->setText(i18nc("@action:inmenu", "Unlock"));
|
decryptPartition->setText(i18nc("@action:inmenu", "Unlock"));
|
||||||
decryptPartition->setToolTip(i18nc("@info:tooltip", "Unlock or lock encrypted partition"));
|
decryptPartition->setToolTip(i18nc("@info:tooltip", "Unlock or lock encrypted partition"));
|
||||||
decryptPartition->setStatusTip(i18nc("@info:status", "Unlock or lock encrypted partition."));
|
decryptPartition->setStatusTip(i18nc("@info:status", "Unlock or lock encrypted partition."));
|
||||||
|
|
||||||
QAction* checkPartition = actionCollection()->addAction(QStringLiteral("checkPartition"), &pmWidget(), SLOT(onCheckPartition()));
|
QAction* checkPartition = actionCollection()->addAction(QStringLiteral("checkPartition"));
|
||||||
|
connect(checkPartition, &QAction::triggered, &pmWidget(), &PartitionManagerWidget::onCheckPartition);
|
||||||
checkPartition->setEnabled(false);
|
checkPartition->setEnabled(false);
|
||||||
checkPartition->setText(i18nc("@action:inmenu", "Check"));
|
checkPartition->setText(i18nc("@action:inmenu", "Check"));
|
||||||
checkPartition->setToolTip(i18nc("@info:tooltip", "Check partition"));
|
checkPartition->setToolTip(i18nc("@info:tooltip", "Check partition"));
|
||||||
checkPartition->setStatusTip(i18nc("@info:status", "Check a filesystem on a partition for errors."));
|
checkPartition->setStatusTip(i18nc("@info:status", "Check a filesystem on a partition for errors."));
|
||||||
checkPartition->setIcon(QIcon::fromTheme(QStringLiteral("flag")).pixmap(IconSize(KIconLoader::Toolbar)));
|
checkPartition->setIcon(QIcon::fromTheme(QStringLiteral("flag")).pixmap(IconSize(KIconLoader::Toolbar)));
|
||||||
|
|
||||||
QAction* propertiesPartition = actionCollection()->addAction(QStringLiteral("propertiesPartition"), &pmWidget(), SLOT(onPropertiesPartition()));
|
QAction* propertiesPartition = actionCollection()->addAction(QStringLiteral("propertiesPartition"));
|
||||||
|
connect(propertiesPartition, &QAction::triggered, &pmWidget(), &PartitionManagerWidget::onPropertiesPartition);
|
||||||
propertiesPartition->setEnabled(false);
|
propertiesPartition->setEnabled(false);
|
||||||
propertiesPartition->setText(i18nc("@action:inmenu", "Properties"));
|
propertiesPartition->setText(i18nc("@action:inmenu", "Properties"));
|
||||||
propertiesPartition->setToolTip(i18nc("@info:tooltip", "Show partition properties dialog"));
|
propertiesPartition->setToolTip(i18nc("@info:tooltip", "Show partition properties dialog"));
|
||||||
propertiesPartition->setStatusTip(i18nc("@info:status", "View and modify partition properties (label, partition flags, etc.)"));
|
propertiesPartition->setStatusTip(i18nc("@info:status", "View and modify partition properties (label, partition flags, etc.)"));
|
||||||
propertiesPartition->setIcon(QIcon::fromTheme(QStringLiteral("document-properties")).pixmap(IconSize(KIconLoader::Toolbar)));
|
propertiesPartition->setIcon(QIcon::fromTheme(QStringLiteral("document-properties")).pixmap(IconSize(KIconLoader::Toolbar)));
|
||||||
|
|
||||||
QAction* backup = actionCollection()->addAction(QStringLiteral("backupPartition"), &pmWidget(), SLOT(onBackupPartition()));
|
QAction* backup = actionCollection()->addAction(QStringLiteral("backupPartition"));
|
||||||
|
connect(backup, &QAction::triggered, &pmWidget(), &PartitionManagerWidget::onBackupPartition);
|
||||||
backup->setEnabled(false);
|
backup->setEnabled(false);
|
||||||
backup->setText(i18nc("@action:inmenu", "Backup"));
|
backup->setText(i18nc("@action:inmenu", "Backup"));
|
||||||
backup->setToolTip(i18nc("@info:tooltip", "Backup partition"));
|
backup->setToolTip(i18nc("@info:tooltip", "Backup partition"));
|
||||||
backup->setStatusTip(i18nc("@info:status", "Backup a partition to an image file."));
|
backup->setStatusTip(i18nc("@info:status", "Backup a partition to an image file."));
|
||||||
backup->setIcon(QIcon::fromTheme(QStringLiteral("document-export")).pixmap(IconSize(KIconLoader::Toolbar)));
|
backup->setIcon(QIcon::fromTheme(QStringLiteral("document-export")).pixmap(IconSize(KIconLoader::Toolbar)));
|
||||||
|
|
||||||
QAction* restore = actionCollection()->addAction(QStringLiteral("restorePartition"), &pmWidget(), SLOT(onRestorePartition()));
|
QAction* restore = actionCollection()->addAction(QStringLiteral("restorePartition"));
|
||||||
|
connect(restore, &QAction::triggered, &pmWidget(), &PartitionManagerWidget::onRestorePartition);
|
||||||
restore->setEnabled(false);
|
restore->setEnabled(false);
|
||||||
restore->setText(i18nc("@action:inmenu", "Restore"));
|
restore->setText(i18nc("@action:inmenu", "Restore"));
|
||||||
restore->setToolTip(i18nc("@info:tooltip", "Restore partition"));
|
restore->setToolTip(i18nc("@info:tooltip", "Restore partition"));
|
||||||
|
@ -343,7 +365,8 @@ void MainWindow::setupActions()
|
||||||
restore->setIcon(QIcon::fromTheme(QStringLiteral("document-import")).pixmap(IconSize(KIconLoader::Toolbar)));
|
restore->setIcon(QIcon::fromTheme(QStringLiteral("document-import")).pixmap(IconSize(KIconLoader::Toolbar)));
|
||||||
|
|
||||||
// View actions
|
// View actions
|
||||||
QAction* fileSystemSupport = actionCollection()->addAction(QStringLiteral("fileSystemSupport"), this, SLOT(onFileSystemSupport()));
|
QAction* fileSystemSupport = actionCollection()->addAction(QStringLiteral("fileSystemSupport"));
|
||||||
|
connect(fileSystemSupport, &QAction::triggered, this, &MainWindow::onFileSystemSupport);
|
||||||
fileSystemSupport->setText(i18nc("@action:inmenu", "File System Support"));
|
fileSystemSupport->setText(i18nc("@action:inmenu", "File System Support"));
|
||||||
fileSystemSupport->setToolTip(i18nc("@info:tooltip", "View file system support information"));
|
fileSystemSupport->setToolTip(i18nc("@info:tooltip", "View file system support information"));
|
||||||
fileSystemSupport->setStatusTip(i18nc("@info:status", "Show information about supported file systems."));
|
fileSystemSupport->setStatusTip(i18nc("@info:status", "Show information about supported file systems."));
|
||||||
|
@ -357,13 +380,15 @@ void MainWindow::setupActions()
|
||||||
KStandardAction::preferences(this, SLOT(onConfigureOptions()), actionCollection());
|
KStandardAction::preferences(this, SLOT(onConfigureOptions()), actionCollection());
|
||||||
|
|
||||||
// Log Actions
|
// Log Actions
|
||||||
QAction* clearLog = actionCollection()->addAction(QStringLiteral("clearLog"), &treeLog(), SLOT(onClearLog()));
|
QAction* clearLog = actionCollection()->addAction(QStringLiteral("clearLog"));
|
||||||
|
connect(clearLog, &QAction::triggered, &treeLog(), &TreeLog::onClearLog);
|
||||||
clearLog->setText(i18nc("@action:inmenu", "Clear Log"));
|
clearLog->setText(i18nc("@action:inmenu", "Clear Log"));
|
||||||
clearLog->setToolTip(i18nc("@info:tooltip", "Clear the log output"));
|
clearLog->setToolTip(i18nc("@info:tooltip", "Clear the log output"));
|
||||||
clearLog->setStatusTip(i18nc("@info:status", "Clear the log output panel."));
|
clearLog->setStatusTip(i18nc("@info:status", "Clear the log output panel."));
|
||||||
clearLog->setIcon(QIcon::fromTheme(QStringLiteral("edit-clear-list")).pixmap(IconSize(KIconLoader::Toolbar)));
|
clearLog->setIcon(QIcon::fromTheme(QStringLiteral("edit-clear-list")).pixmap(IconSize(KIconLoader::Toolbar)));
|
||||||
|
|
||||||
QAction* saveLog = actionCollection()->addAction(QStringLiteral("saveLog"), &treeLog(), SLOT(onSaveLog()));
|
QAction* saveLog = actionCollection()->addAction(QStringLiteral("saveLog"));
|
||||||
|
connect(saveLog, &QAction::triggered, &treeLog(), &TreeLog::onSaveLog);
|
||||||
saveLog->setText(i18nc("@action:inmenu", "Save Log"));
|
saveLog->setText(i18nc("@action:inmenu", "Save Log"));
|
||||||
saveLog->setToolTip(i18nc("@info:tooltip", "Save the log output"));
|
saveLog->setToolTip(i18nc("@info:tooltip", "Save the log output"));
|
||||||
saveLog->setStatusTip(i18nc("@info:status", "Save the log output to a file."));
|
saveLog->setStatusTip(i18nc("@info:status", "Save the log output to a file."));
|
||||||
|
@ -372,8 +397,8 @@ void MainWindow::setupActions()
|
||||||
|
|
||||||
void MainWindow::setupConnections()
|
void MainWindow::setupConnections()
|
||||||
{
|
{
|
||||||
connect(&listDevices(), SIGNAL(selectionChanged(const QString&)), &pmWidget(), SLOT(setSelectedDevice(const QString&)));
|
connect(&listDevices(), &ListDevices::selectionChanged, &pmWidget(), static_cast<void(PartitionManagerWidget::*)(const QString&)>(&PartitionManagerWidget::setSelectedDevice));
|
||||||
connect(&listDevices(), SIGNAL(deviceDoubleClicked(const QString&)), SLOT(onPropertiesDevice(const QString&)));
|
connect(&listDevices(), &ListDevices::deviceDoubleClicked, this, &MainWindow::onPropertiesDevice);
|
||||||
}
|
}
|
||||||
|
|
||||||
void MainWindow::setupStatusBar()
|
void MainWindow::setupStatusBar()
|
||||||
|
@ -1041,6 +1066,11 @@ void MainWindow::onSmartStatusDevice()
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
void MainWindow::onPropertiesDevice2()
|
||||||
|
{
|
||||||
|
onPropertiesDevice({});
|
||||||
|
}
|
||||||
|
|
||||||
void MainWindow::onPropertiesDevice(const QString&)
|
void MainWindow::onPropertiesDevice(const QString&)
|
||||||
{
|
{
|
||||||
Q_ASSERT(pmWidget().selectedDevice());
|
Q_ASSERT(pmWidget().selectedDevice());
|
||||||
|
|
|
@ -252,7 +252,8 @@ protected Q_SLOTS:
|
||||||
void onFileSystemSupport();
|
void onFileSystemSupport();
|
||||||
|
|
||||||
void onSmartStatusDevice();
|
void onSmartStatusDevice();
|
||||||
void onPropertiesDevice(const QString& device_node = QString());
|
void onPropertiesDevice2();
|
||||||
|
void onPropertiesDevice(const QString& deviceNode = {});
|
||||||
|
|
||||||
private:
|
private:
|
||||||
OperationStack* m_OperationStack;
|
OperationStack* m_OperationStack;
|
||||||
|
|
|
@ -115,12 +115,12 @@ void NewDialog::setupDialog()
|
||||||
|
|
||||||
void NewDialog::setupConnections()
|
void NewDialog::setupConnections()
|
||||||
{
|
{
|
||||||
connect(&dialogWidget().radioPrimary(), SIGNAL(toggled(bool)), SLOT(onRoleChanged(bool)));
|
connect(&dialogWidget().radioPrimary(), &QRadioButton::toggled, this, &NewDialog::onRoleChanged);
|
||||||
connect(&dialogWidget().radioExtended(), SIGNAL(toggled(bool)), SLOT(onRoleChanged(bool)));
|
connect(&dialogWidget().radioExtended(), &QRadioButton::toggled, this, &NewDialog::onRoleChanged);
|
||||||
connect(&dialogWidget().radioLogical(), SIGNAL(toggled(bool)), SLOT(onRoleChanged(bool)));
|
connect(&dialogWidget().radioLogical(), &QRadioButton::toggled, this, &NewDialog::onRoleChanged);
|
||||||
connect(&dialogWidget().checkBoxEncrypt(), SIGNAL(toggled(bool)), SLOT(onRoleChanged(bool)));
|
connect(&dialogWidget().checkBoxEncrypt(), &QCheckBox::toggled, this, &NewDialog::onRoleChanged);
|
||||||
connect(&dialogWidget().comboFileSystem(), SIGNAL(currentIndexChanged(int)), SLOT(onFilesystemChanged(int)));
|
connect(&dialogWidget().comboFileSystem(), static_cast<void(QComboBox::*)(int)>(&QComboBox::currentIndexChanged), this, &NewDialog::onFilesystemChanged);
|
||||||
connect(&dialogWidget().label(), SIGNAL(textChanged(const QString&)), SLOT(onLabelChanged(const QString&)));
|
connect(&dialogWidget().label(), &QLineEdit::textChanged, this, &NewDialog::onLabelChanged);
|
||||||
|
|
||||||
SizeDialogBase::setupConnections();
|
SizeDialogBase::setupConnections();
|
||||||
}
|
}
|
||||||
|
|
|
@ -35,19 +35,16 @@ class Device;
|
||||||
*/
|
*/
|
||||||
class NewDialog : public SizeDialogBase
|
class NewDialog : public SizeDialogBase
|
||||||
{
|
{
|
||||||
Q_OBJECT
|
|
||||||
|
|
||||||
public:
|
public:
|
||||||
NewDialog(QWidget* parent, Device& device, Partition& unallocatedPartition, PartitionRole::Roles r);
|
NewDialog(QWidget* parent, Device& device, Partition& unallocatedPartition, PartitionRole::Roles r);
|
||||||
~NewDialog();
|
~NewDialog();
|
||||||
|
|
||||||
protected Q_SLOTS:
|
protected:
|
||||||
void accept() override;
|
void accept() override;
|
||||||
void onRoleChanged(bool);
|
void onRoleChanged(bool);
|
||||||
void onFilesystemChanged(int);
|
void onFilesystemChanged(int);
|
||||||
void onLabelChanged(const QString& newLabel);
|
void onLabelChanged(const QString& newLabel);
|
||||||
|
|
||||||
protected:
|
|
||||||
void setupConnections() override;
|
void setupConnections() override;
|
||||||
void setupDialog() override;
|
void setupDialog() override;
|
||||||
void slotPasswordStatusChanged();
|
void slotPasswordStatusChanged();
|
||||||
|
|
|
@ -54,7 +54,7 @@ Q_SIGNALS:
|
||||||
void deviceDoubleClicked(const Device*);
|
void deviceDoubleClicked(const Device*);
|
||||||
void partitionDoubleClicked(const Partition* p);
|
void partitionDoubleClicked(const Partition* p);
|
||||||
|
|
||||||
public Q_SLOTS:
|
public:
|
||||||
void setSelectedDevice(Device* d);
|
void setSelectedDevice(Device* d);
|
||||||
void setSelectedDevice(const QString& device_node);
|
void setSelectedDevice(const QString& device_node);
|
||||||
|
|
||||||
|
@ -77,7 +77,6 @@ public Q_SLOTS:
|
||||||
|
|
||||||
void onPropertiesPartition();
|
void onPropertiesPartition();
|
||||||
|
|
||||||
public:
|
|
||||||
void init(OperationStack* ostack);
|
void init(OperationStack* ostack);
|
||||||
|
|
||||||
void clear();
|
void clear();
|
||||||
|
|
|
@ -255,20 +255,20 @@ void PartPropsDialog::updateHideAndShow()
|
||||||
|
|
||||||
void PartPropsDialog::setupConnections()
|
void PartPropsDialog::setupConnections()
|
||||||
{
|
{
|
||||||
connect(&dialogWidget().label(), SIGNAL(textEdited(const QString&)), SLOT(setDirty()));
|
connect(&dialogWidget().label(), &QLineEdit::textEdited, this, &PartPropsDialog::setDirty2);
|
||||||
connect(&dialogWidget().fileSystem(), SIGNAL(currentIndexChanged(int)), SLOT(onFilesystemChanged(int)));
|
connect(&dialogWidget().fileSystem(), static_cast<void(QComboBox::*)(int)>(&QComboBox::currentIndexChanged), this, &PartPropsDialog::onFilesystemChanged);
|
||||||
connect(&dialogWidget().checkRecreate(), SIGNAL(stateChanged(int)), SLOT(onRecreate(int)));
|
connect(&dialogWidget().checkRecreate(), &QCheckBox::stateChanged, this, &PartPropsDialog::onRecreate);
|
||||||
|
|
||||||
// We want to enable the OK-button whenever the user checks or unchecks a flag in the flag list.
|
// We want to enable the OK-button whenever the user checks or unchecks a flag in the flag list.
|
||||||
// But it seems Qt doesn't offer a foolproof way to detect if this has happened: The currentRow/ItemChanged
|
// But it seems Qt doesn't offer a foolproof way to detect if this has happened: The currentRow/ItemChanged
|
||||||
// signal only means the _current_ item has changed, but not necessarily that it was checked/unchecked. And
|
// signal only means the _current_ item has changed, but not necessarily that it was checked/unchecked. And
|
||||||
// itemClicked alone isn't enough either. We choose to rather enable the OK-button too often than too
|
// itemClicked alone isn't enough either. We choose to rather enable the OK-button too often than too
|
||||||
// seldom.
|
// seldom.
|
||||||
connect(&dialogWidget().listFlags(), SIGNAL(itemClicked(QListWidgetItem*)), SLOT(setDirty()));
|
connect(&dialogWidget().listFlags(), &QListWidget::itemClicked, this, &PartPropsDialog::setDirty);
|
||||||
connect(&dialogWidget().listFlags(), SIGNAL(currentRowChanged(int)), SLOT(setDirty()));
|
connect(&dialogWidget().listFlags(), &QListWidget::currentRowChanged, this, &PartPropsDialog::setDirty3);
|
||||||
}
|
}
|
||||||
|
|
||||||
void PartPropsDialog::setDirty()
|
void PartPropsDialog::setDirty(void*)
|
||||||
{
|
{
|
||||||
okButton->setEnabled(true);
|
okButton->setEnabled(true);
|
||||||
okButton->setDefault(true);
|
okButton->setDefault(true);
|
||||||
|
@ -347,7 +347,7 @@ void PartPropsDialog::onFilesystemChanged(int)
|
||||||
} else {
|
} else {
|
||||||
dialogWidget().fileSystem().disconnect(this);
|
dialogWidget().fileSystem().disconnect(this);
|
||||||
setupFileSystemComboBox();
|
setupFileSystemComboBox();
|
||||||
connect(&dialogWidget().fileSystem(), SIGNAL(currentIndexChanged(int)), SLOT(onFilesystemChanged(int)));
|
connect(&dialogWidget().fileSystem(), static_cast<void(QComboBox::*)(int)>(&QComboBox::currentIndexChanged), this, &PartPropsDialog::onFilesystemChanged);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -45,7 +45,6 @@ class QString;
|
||||||
*/
|
*/
|
||||||
class PartPropsDialog : public QDialog
|
class PartPropsDialog : public QDialog
|
||||||
{
|
{
|
||||||
Q_OBJECT
|
|
||||||
Q_DISABLE_COPY(PartPropsDialog)
|
Q_DISABLE_COPY(PartPropsDialog)
|
||||||
|
|
||||||
public:
|
public:
|
||||||
|
@ -106,8 +105,10 @@ protected:
|
||||||
|
|
||||||
void updatePartitionFileSystem();
|
void updatePartitionFileSystem();
|
||||||
|
|
||||||
protected Q_SLOTS:
|
protected:
|
||||||
void setDirty();
|
void setDirty(void *unused = nullptr);
|
||||||
|
void setDirty2(QString) {setDirty();};
|
||||||
|
void setDirty3(int) {setDirty();};
|
||||||
void onFilesystemChanged(int idx);
|
void onFilesystemChanged(int idx);
|
||||||
void onRecreate(int);
|
void onRecreate(int);
|
||||||
|
|
||||||
|
|
|
@ -32,8 +32,6 @@ class Device;
|
||||||
*/
|
*/
|
||||||
class ResizeDialog : public SizeDialogBase
|
class ResizeDialog : public SizeDialogBase
|
||||||
{
|
{
|
||||||
Q_OBJECT
|
|
||||||
|
|
||||||
public:
|
public:
|
||||||
ResizeDialog(QWidget* parent, Device& device, Partition& p, qint64 minFirst, qint64 maxLast);
|
ResizeDialog(QWidget* parent, Device& device, Partition& p, qint64 minFirst, qint64 maxLast);
|
||||||
~ResizeDialog();
|
~ResizeDialog();
|
||||||
|
@ -47,7 +45,6 @@ public:
|
||||||
return m_ResizedLastSector;
|
return m_ResizedLastSector;
|
||||||
}
|
}
|
||||||
|
|
||||||
public Q_SLOTS:
|
|
||||||
void accept() override;
|
void accept() override;
|
||||||
void reject() override;
|
void reject() override;
|
||||||
|
|
||||||
|
|
|
@ -25,19 +25,17 @@ class QShowEvent;
|
||||||
|
|
||||||
class ScanProgressDialog : public QProgressDialog
|
class ScanProgressDialog : public QProgressDialog
|
||||||
{
|
{
|
||||||
Q_OBJECT
|
|
||||||
|
|
||||||
public:
|
public:
|
||||||
ScanProgressDialog(QWidget* parent);
|
ScanProgressDialog(QWidget* parent);
|
||||||
|
|
||||||
protected:
|
|
||||||
void showEvent(QShowEvent* e) override;
|
|
||||||
|
|
||||||
public:
|
|
||||||
void setProgress(quint32 p) {
|
void setProgress(quint32 p) {
|
||||||
setValue(p);
|
setValue(p);
|
||||||
}
|
}
|
||||||
void setDeviceName(const QString& d);
|
void setDeviceName(const QString& d);
|
||||||
|
|
||||||
|
protected:
|
||||||
|
void showEvent(QShowEvent* e) override;
|
||||||
|
|
||||||
};
|
};
|
||||||
|
|
||||||
#endif
|
#endif
|
||||||
|
|
|
@ -28,8 +28,6 @@
|
||||||
*/
|
*/
|
||||||
class SizeDetailsWidget : public QWidget, public Ui::SizeDetailsWidgetBase
|
class SizeDetailsWidget : public QWidget, public Ui::SizeDetailsWidgetBase
|
||||||
{
|
{
|
||||||
Q_OBJECT
|
|
||||||
|
|
||||||
public:
|
public:
|
||||||
SizeDetailsWidget(QWidget* parent);
|
SizeDetailsWidget(QWidget* parent);
|
||||||
|
|
||||||
|
|
|
@ -143,16 +143,16 @@ void SizeDialogBase::setupConstraints()
|
||||||
|
|
||||||
void SizeDialogBase::setupConnections()
|
void SizeDialogBase::setupConnections()
|
||||||
{
|
{
|
||||||
connect(&dialogWidget().partResizerWidget(), SIGNAL(firstSectorChanged(qint64)), SLOT(onResizerWidgetFirstSectorChanged(qint64)));
|
connect(&dialogWidget().partResizerWidget(), &PartResizerWidget::firstSectorChanged, this, &SizeDialogBase::onResizerWidgetFirstSectorChanged);
|
||||||
connect(&dialogWidget().partResizerWidget(), SIGNAL(lastSectorChanged(qint64)), SLOT(onResizerWidgetLastSectorChanged(qint64)));
|
connect(&dialogWidget().partResizerWidget(), &PartResizerWidget::lastSectorChanged, this, &SizeDialogBase::onResizerWidgetLastSectorChanged);
|
||||||
|
|
||||||
connect(&dialogWidget().spinFreeBefore(), SIGNAL(valueChanged(double)), SLOT(onSpinFreeBeforeChanged(double)));
|
connect(&dialogWidget().spinFreeBefore(), static_cast<void(QDoubleSpinBox::*)(double)>(&QDoubleSpinBox::valueChanged), this, &SizeDialogBase::onSpinFreeBeforeChanged);
|
||||||
connect(&dialogWidget().spinFreeAfter(), SIGNAL(valueChanged(double)), SLOT(onSpinFreeAfterChanged(double)));
|
connect(&dialogWidget().spinFreeAfter(), static_cast<void(QDoubleSpinBox::*)(double)>(&QDoubleSpinBox::valueChanged), this, &SizeDialogBase::onSpinFreeAfterChanged);
|
||||||
connect(&dialogWidget().spinCapacity(), SIGNAL(valueChanged(double)), SLOT(onSpinCapacityChanged(double)));
|
connect(&dialogWidget().spinCapacity(), static_cast<void(QDoubleSpinBox::*)(double)>(&QDoubleSpinBox::valueChanged), this, &SizeDialogBase::onSpinCapacityChanged);
|
||||||
|
|
||||||
connect(&detailsWidget().spinFirstSector(), SIGNAL(valueChanged(double)), SLOT(onSpinFirstSectorChanged(double)));
|
connect(&detailsWidget().spinFirstSector(), static_cast<void(QDoubleSpinBox::*)(double)>(&QDoubleSpinBox::valueChanged), this, &SizeDialogBase::onSpinFirstSectorChanged);
|
||||||
connect(&detailsWidget().spinLastSector(), SIGNAL(valueChanged(double)), SLOT(onSpinLastSectorChanged(double)));
|
connect(&detailsWidget().spinLastSector(), static_cast<void(QDoubleSpinBox::*)(double)>(&QDoubleSpinBox::valueChanged), this, &SizeDialogBase::onSpinLastSectorChanged);
|
||||||
connect(&detailsWidget().checkAlign(), SIGNAL(toggled(bool)), SLOT(onAlignToggled(bool)));
|
connect(&detailsWidget().checkAlign(), &QCheckBox::toggled, this, &SizeDialogBase::onAlignToggled);
|
||||||
}
|
}
|
||||||
|
|
||||||
void SizeDialogBase::toggleDetails()
|
void SizeDialogBase::toggleDetails()
|
||||||
|
|
|
@ -37,7 +37,6 @@ class SizeDetailsWidget;
|
||||||
*/
|
*/
|
||||||
class SizeDialogBase : public QDialog
|
class SizeDialogBase : public QDialog
|
||||||
{
|
{
|
||||||
Q_OBJECT
|
|
||||||
Q_DISABLE_COPY(SizeDialogBase)
|
Q_DISABLE_COPY(SizeDialogBase)
|
||||||
|
|
||||||
protected:
|
protected:
|
||||||
|
@ -115,7 +114,7 @@ protected:
|
||||||
m_MaximumLength = s;
|
m_MaximumLength = s;
|
||||||
}
|
}
|
||||||
|
|
||||||
protected Q_SLOTS:
|
protected:
|
||||||
void onResizerWidgetFirstSectorChanged(qint64 newFirst);
|
void onResizerWidgetFirstSectorChanged(qint64 newFirst);
|
||||||
void onResizerWidgetLastSectorChanged(qint64 newLast);
|
void onResizerWidgetLastSectorChanged(qint64 newLast);
|
||||||
|
|
||||||
|
@ -127,7 +126,6 @@ protected Q_SLOTS:
|
||||||
void onSpinLastSectorChanged(double newLast);
|
void onSpinLastSectorChanged(double newLast);
|
||||||
void onAlignToggled(bool);
|
void onAlignToggled(bool);
|
||||||
|
|
||||||
protected:
|
|
||||||
void toggleDetails();
|
void toggleDetails();
|
||||||
|
|
||||||
SizeDialogWidget* m_SizeDialogWidget;
|
SizeDialogWidget* m_SizeDialogWidget;
|
||||||
|
|
|
@ -29,8 +29,6 @@
|
||||||
*/
|
*/
|
||||||
class SizeDialogWidget : public QWidget, public Ui::SizeDialogWidgetBase
|
class SizeDialogWidget : public QWidget, public Ui::SizeDialogWidgetBase
|
||||||
{
|
{
|
||||||
Q_OBJECT
|
|
||||||
|
|
||||||
public:
|
public:
|
||||||
SizeDialogWidget(QWidget* parent) : QWidget(parent), Ui::SizeDialogWidgetBase() {
|
SizeDialogWidget(QWidget* parent) : QWidget(parent), Ui::SizeDialogWidgetBase() {
|
||||||
setupUi(this);
|
setupUi(this);
|
||||||
|
|
|
@ -46,12 +46,11 @@ public:
|
||||||
void init();
|
void init();
|
||||||
void onNewLogMessage(Log::Level logLevel, const QString& s);
|
void onNewLogMessage(Log::Level logLevel, const QString& s);
|
||||||
|
|
||||||
protected Q_SLOTS:
|
|
||||||
void onClearLog();
|
void onClearLog();
|
||||||
void onSaveLog();
|
void onSaveLog();
|
||||||
void on_m_TreeLog_customContextMenuRequested(const QPoint& pos);
|
|
||||||
|
|
||||||
protected:
|
protected:
|
||||||
|
void on_m_TreeLog_customContextMenuRequested(const QPoint& pos);
|
||||||
void onHeaderContextMenu(const QPoint& pos);
|
void onHeaderContextMenu(const QPoint& pos);
|
||||||
|
|
||||||
QTreeWidget& treeLog() {
|
QTreeWidget& treeLog() {
|
||||||
|
|
Loading…
Reference in New Issue