mirror of
https://github.com/Quill-OS/quill.git
synced 2024-12-26 23:57:22 -08:00
Settings: various changes; Checkable list widgets: improvements
This commit is contained in:
parent
3189466166
commit
6ac7d4c006
6 changed files with 36 additions and 17 deletions
|
@ -437,3 +437,13 @@ void todo::resize() {
|
|||
this->setGeometry(QRect(QPoint(0,0), qApp->primaryScreen()->geometry().size()));
|
||||
this->repaint();
|
||||
}
|
||||
|
||||
void todo::on_itemsListWidget_itemClicked(QListWidgetItem *item)
|
||||
{
|
||||
if(item->checkState() == Qt::Unchecked) {
|
||||
item->setCheckState(Qt::Checked);
|
||||
}
|
||||
else {
|
||||
item->setCheckState(Qt::Unchecked);
|
||||
}
|
||||
}
|
||||
|
|
|
@ -55,6 +55,7 @@ private slots:
|
|||
void on_deselectAllItemsBtn_clicked();
|
||||
void on_saveCurrentListViewBtn_clicked();
|
||||
void on_editItemBtn_clicked();
|
||||
void on_itemsListWidget_itemClicked(QListWidgetItem *item);
|
||||
|
||||
signals:
|
||||
void showToast(QString messageToDisplay);
|
||||
|
|
|
@ -60,15 +60,20 @@ settings::settings(QWidget *parent) :
|
|||
ui->repackBtn->setStyleSheet("font-size: 9pt");
|
||||
ui->exportHighlightsBtn->setStyleSheet("font-size: 9pt");
|
||||
ui->uiScaleNumberLabel->setStyleSheet("font-size: 9pt; font-weight: bold");
|
||||
if(global::deviceID == "n705\n" or global::deviceID == "n905\n" or global::deviceID == "kt\n") {
|
||||
ui->previousBtn->setStyleSheet("padding: 7.5px;");
|
||||
ui->nextBtn->setStyleSheet("padding: 7.5px;");
|
||||
}
|
||||
else {
|
||||
ui->previousBtn->setStyleSheet("padding: 10px;");
|
||||
ui->nextBtn->setStyleSheet("padding: 10px");
|
||||
}
|
||||
|
||||
ui->previousBtn->setText("");
|
||||
ui->previousBtn->setIcon(QIcon(":/resources/chevron-left.png"));
|
||||
ui->nextBtn->setText("");
|
||||
ui->nextBtn->setIcon(QIcon(":/resources/chevron-right.png"));
|
||||
|
||||
ui->nextBtn->setFixedWidth(100);
|
||||
ui->previousBtn->setFixedWidth(100);
|
||||
|
||||
ui->requestLeaseBtn->hide();
|
||||
ui->usbmsBtn->hide();
|
||||
ui->label_3->hide();
|
||||
|
@ -573,14 +578,6 @@ void settings::on_nextBtn_clicked()
|
|||
}
|
||||
}
|
||||
|
||||
void settings::on_wordsNumber_valueChanged(int arg1)
|
||||
{
|
||||
QString number = QString::number(arg1);
|
||||
string number_str = number.toStdString();
|
||||
string_writeconfig(".config/07-words_number/config", number_str);
|
||||
log("Set text files words number to " + number, className);
|
||||
}
|
||||
|
||||
void settings::on_updateBtn_clicked()
|
||||
{
|
||||
log("'Update' button clicked", className);
|
||||
|
|
|
@ -41,7 +41,6 @@ private slots:
|
|||
void on_usbmsBtn_clicked();
|
||||
void on_previousBtn_clicked();
|
||||
void on_nextBtn_clicked();
|
||||
void on_wordsNumber_valueChanged(int arg1);
|
||||
void on_updateBtn_clicked();
|
||||
void on_darkModeCheckBox_toggled(bool checked);
|
||||
void on_uiScalingSlider_valueChanged(int value);
|
||||
|
|
|
@ -111,3 +111,13 @@ void highlightsListDialog::on_selectAllBtn_clicked()
|
|||
ui->listWidget->item(i)->setCheckState(Qt::Checked);
|
||||
}
|
||||
}
|
||||
|
||||
void highlightsListDialog::on_listWidget_itemClicked(QListWidgetItem *item)
|
||||
{
|
||||
if(item->checkState() == Qt::Unchecked) {
|
||||
item->setCheckState(Qt::Checked);
|
||||
}
|
||||
else {
|
||||
item->setCheckState(Qt::Unchecked);
|
||||
}
|
||||
}
|
||||
|
|
|
@ -2,6 +2,7 @@
|
|||
#define HIGHLIGHTSLISTDIALOG_H
|
||||
|
||||
#include <QDialog>
|
||||
#include <QListWidgetItem>
|
||||
|
||||
#include "functions.h"
|
||||
|
||||
|
@ -23,6 +24,7 @@ private slots:
|
|||
void on_cancelBtn_clicked();
|
||||
void on_okBtn_clicked();
|
||||
void on_selectAllBtn_clicked();
|
||||
void on_listWidget_itemClicked(QListWidgetItem *item);
|
||||
|
||||
signals:
|
||||
void showToast(QString messageToDisplay);
|
||||
|
|
Loading…
Reference in a new issue