11 #include "preferences.hpp"
12 #include "ui_preferences.h"
14 using namespace Huggle;
20 ui->tableWidget->setColumnCount(4);
23 header <<
"Name" <<
"Author" <<
"Description" <<
"Status" <<
"Version";
24 ui->tableWidget->setHorizontalHeaderLabels(header);
25 ui->tableWidget->verticalHeader()->setVisible(
false);
26 ui->tableWidget->horizontalHeader()->setSelectionBehavior(QAbstractItemView::SelectRows);
27 ui->tableWidget->setEditTriggers(QAbstractItemView::NoEditTriggers);
28 #if QT_VERSION >= 0x050000
30 ui->tableWidget->horizontalHeader()->setSectionResizeMode(QHeaderView::ResizeToContents);
33 ui->tableWidget->horizontalHeader()->setResizeMode(QHeaderView::ResizeToContents);
35 ui->tableWidget->setShowGrid(
false);
37 while (c < HuggleQueueFilter::Filters.count())
39 ui->listWidget->addItem(HuggleQueueFilter::Filters.at(c)->QueueName);
50 void Huggle::Preferences::on_listWidget_itemSelectionChanged()
52 if (ui->listWidget->currentRow() == 0)
59 HuggleQueueFilter *f = HuggleQueueFilter::Filters.at(ui->listWidget->currentRow());
61 ui->lineEdit->setText(f->QueueName);
64 Preferences::~Preferences()
69 void Preferences::Disable()
71 ui->checkBox_6->setEnabled(
false);
72 ui->checkBox_7->setEnabled(
false);
73 ui->checkBox_8->setEnabled(
false);
74 ui->checkBox_9->setEnabled(
false);
75 ui->checkBox_10->setEnabled(
false);
76 ui->pushButton_4->setEnabled(
false);
77 ui->pushButton_5->setEnabled(
false);
78 ui->pushButton_6->setEnabled(
false);
79 ui->lineEdit->setEnabled(
false);
82 void Preferences::EnableQueues()
84 ui->lineEdit->setEnabled(
true);
85 ui->checkBox_6->setEnabled(
true);
86 ui->checkBox_7->setEnabled(
true);
87 ui->checkBox_8->setEnabled(
true);
88 ui->checkBox_9->setEnabled(
true);
89 ui->checkBox_10->setEnabled(
true);
90 ui->pushButton_4->setEnabled(
true);
91 ui->pushButton_5->setEnabled(
true);
92 ui->pushButton_6->setEnabled(
true);
95 void Preferences::on_pushButton_clicked()
100 void Huggle::Preferences::on_pushButton_2_clicked()
Preferences(QWidget *parent=0)
Filter that can be applied to edit queue.
static bool WarnUserSpaceRoll
Warn you in case you want to revert a user page.
static bool UsingIRC
Whether IRC is being used.
bool getIgnoreBots() const
static bool AutomaticallyResolveConflicts
Resolve edit conflict without asking user.
static void SaveConfig()
Save the local configuration to file.
static bool EnforceManualSoftwareRollback
If this is true huggle will always use software rollback even if user has the rollback privileges...