mirror of
https://github.com/Cockatrice/Cockatrice.git
synced 2026-06-11 00:24:47 -07:00
Fix Qt5 Slot/Signals for QCheckBoxes (#5201)
This commit is contained in:
parent
f2b0fa164e
commit
c6bfc8b8ea
4 changed files with 53 additions and 65 deletions
|
|
@ -80,8 +80,7 @@ DlgConnect::DlgConnect(QWidget *parent) : QDialog(parent)
|
||||||
autoConnectCheckBox->setEnabled(false);
|
autoConnectCheckBox->setEnabled(false);
|
||||||
}
|
}
|
||||||
|
|
||||||
connect(savePasswordCheckBox, SIGNAL(QT_STATE_CHANGED(QT_STATE_CHANGED_T)), this,
|
connect(savePasswordCheckBox, &QCheckBox::QT_STATE_CHANGED, this, &DlgConnect::passwordSaved);
|
||||||
SLOT(passwordSaved(QT_STATE_CHANGED_T)));
|
|
||||||
|
|
||||||
serverIssuesLabel =
|
serverIssuesLabel =
|
||||||
new QLabel(tr("If you have any trouble connecting or registering then contact the server staff for help!"));
|
new QLabel(tr("If you have any trouble connecting or registering then contact the server staff for help!"));
|
||||||
|
|
|
||||||
|
|
@ -81,8 +81,7 @@ void DlgCreateGame::sharedCtor()
|
||||||
|
|
||||||
spectatorsAllowedCheckBox = new QCheckBox(tr("&Spectators can watch"));
|
spectatorsAllowedCheckBox = new QCheckBox(tr("&Spectators can watch"));
|
||||||
spectatorsAllowedCheckBox->setChecked(true);
|
spectatorsAllowedCheckBox->setChecked(true);
|
||||||
connect(spectatorsAllowedCheckBox, SIGNAL(QT_STATE_CHANGED(QT_STATE_CHANGED_T)), this,
|
connect(spectatorsAllowedCheckBox, &QCheckBox::QT_STATE_CHANGED, this, &DlgCreateGame::spectatorsAllowedChanged);
|
||||||
SLOT(spectatorsAllowedChanged(QT_STATE_CHANGED_T)));
|
|
||||||
spectatorsNeedPasswordCheckBox = new QCheckBox(tr("Spectators &need a password to watch"));
|
spectatorsNeedPasswordCheckBox = new QCheckBox(tr("Spectators &need a password to watch"));
|
||||||
spectatorsCanTalkCheckBox = new QCheckBox(tr("Spectators can &chat"));
|
spectatorsCanTalkCheckBox = new QCheckBox(tr("Spectators can &chat"));
|
||||||
spectatorsSeeEverythingCheckBox = new QCheckBox(tr("Spectators can see &hands"));
|
spectatorsSeeEverythingCheckBox = new QCheckBox(tr("Spectators can see &hands"));
|
||||||
|
|
|
||||||
|
|
@ -74,10 +74,9 @@ GeneralSettingsPage::GeneralSettingsPage()
|
||||||
|
|
||||||
connect(&languageBox, SIGNAL(currentIndexChanged(int)), this, SLOT(languageBoxChanged(int)));
|
connect(&languageBox, SIGNAL(currentIndexChanged(int)), this, SLOT(languageBoxChanged(int)));
|
||||||
connect(&updateReleaseChannelBox, SIGNAL(currentIndexChanged(int)), &settings, SLOT(setUpdateReleaseChannel(int)));
|
connect(&updateReleaseChannelBox, SIGNAL(currentIndexChanged(int)), &settings, SLOT(setUpdateReleaseChannel(int)));
|
||||||
connect(&updateNotificationCheckBox, SIGNAL(QT_STATE_CHANGED(QT_STATE_CHANGED_T)), &settings,
|
connect(&updateNotificationCheckBox, &QCheckBox::QT_STATE_CHANGED, &settings, &SettingsCache::setNotifyAboutUpdate);
|
||||||
SLOT(setNotifyAboutUpdate(QT_STATE_CHANGED_T)));
|
connect(&newVersionOracleCheckBox, &QCheckBox::QT_STATE_CHANGED, &settings,
|
||||||
connect(&newVersionOracleCheckBox, SIGNAL(QT_STATE_CHANGED(QT_STATE_CHANGED_T)), &settings,
|
&SettingsCache::setNotifyAboutNewVersion);
|
||||||
SLOT(setNotifyAboutNewVersion(QT_STATE_CHANGED_T)));
|
|
||||||
connect(&showTipsOnStartup, SIGNAL(clicked(bool)), &settings, SLOT(setShowTipsOnStartup(bool)));
|
connect(&showTipsOnStartup, SIGNAL(clicked(bool)), &settings, SLOT(setShowTipsOnStartup(bool)));
|
||||||
|
|
||||||
auto *personalGrid = new QGridLayout;
|
auto *personalGrid = new QGridLayout;
|
||||||
|
|
@ -324,12 +323,10 @@ AppearanceSettingsPage::AppearanceSettingsPage()
|
||||||
themeGroupBox->setLayout(themeGrid);
|
themeGroupBox->setLayout(themeGrid);
|
||||||
|
|
||||||
displayCardNamesCheckBox.setChecked(settings.getDisplayCardNames());
|
displayCardNamesCheckBox.setChecked(settings.getDisplayCardNames());
|
||||||
connect(&displayCardNamesCheckBox, SIGNAL(QT_STATE_CHANGED(QT_STATE_CHANGED_T)), &settings,
|
connect(&displayCardNamesCheckBox, &QCheckBox::QT_STATE_CHANGED, &settings, &SettingsCache::setDisplayCardNames);
|
||||||
SLOT(setDisplayCardNames(QT_STATE_CHANGED_T)));
|
|
||||||
|
|
||||||
cardScalingCheckBox.setChecked(settings.getScaleCards());
|
cardScalingCheckBox.setChecked(settings.getScaleCards());
|
||||||
connect(&cardScalingCheckBox, SIGNAL(QT_STATE_CHANGED(QT_STATE_CHANGED_T)), &settings,
|
connect(&cardScalingCheckBox, &QCheckBox::QT_STATE_CHANGED, &settings, &SettingsCache::setCardScaling);
|
||||||
SLOT(setCardScaling(QT_STATE_CHANGED_T)));
|
|
||||||
|
|
||||||
verticalCardOverlapPercentBox.setValue(settings.getStackCardOverlapPercent());
|
verticalCardOverlapPercentBox.setValue(settings.getStackCardOverlapPercent());
|
||||||
verticalCardOverlapPercentBox.setRange(0, 80);
|
verticalCardOverlapPercentBox.setRange(0, 80);
|
||||||
|
|
@ -346,12 +343,10 @@ AppearanceSettingsPage::AppearanceSettingsPage()
|
||||||
cardsGroupBox->setLayout(cardsGrid);
|
cardsGroupBox->setLayout(cardsGrid);
|
||||||
|
|
||||||
horizontalHandCheckBox.setChecked(settings.getHorizontalHand());
|
horizontalHandCheckBox.setChecked(settings.getHorizontalHand());
|
||||||
connect(&horizontalHandCheckBox, SIGNAL(QT_STATE_CHANGED(QT_STATE_CHANGED_T)), &settings,
|
connect(&horizontalHandCheckBox, &QCheckBox::QT_STATE_CHANGED, &settings, &SettingsCache::setHorizontalHand);
|
||||||
SLOT(setHorizontalHand(QT_STATE_CHANGED_T)));
|
|
||||||
|
|
||||||
leftJustifiedHandCheckBox.setChecked(settings.getLeftJustified());
|
leftJustifiedHandCheckBox.setChecked(settings.getLeftJustified());
|
||||||
connect(&leftJustifiedHandCheckBox, SIGNAL(QT_STATE_CHANGED(QT_STATE_CHANGED_T)), &settings,
|
connect(&leftJustifiedHandCheckBox, &QCheckBox::QT_STATE_CHANGED, &settings, &SettingsCache::setLeftJustified);
|
||||||
SLOT(setLeftJustified(QT_STATE_CHANGED_T)));
|
|
||||||
|
|
||||||
auto *handGrid = new QGridLayout;
|
auto *handGrid = new QGridLayout;
|
||||||
handGrid->addWidget(&horizontalHandCheckBox, 0, 0, 1, 2);
|
handGrid->addWidget(&horizontalHandCheckBox, 0, 0, 1, 2);
|
||||||
|
|
@ -361,8 +356,8 @@ AppearanceSettingsPage::AppearanceSettingsPage()
|
||||||
handGroupBox->setLayout(handGrid);
|
handGroupBox->setLayout(handGrid);
|
||||||
|
|
||||||
invertVerticalCoordinateCheckBox.setChecked(settings.getInvertVerticalCoordinate());
|
invertVerticalCoordinateCheckBox.setChecked(settings.getInvertVerticalCoordinate());
|
||||||
connect(&invertVerticalCoordinateCheckBox, SIGNAL(QT_STATE_CHANGED(QT_STATE_CHANGED_T)), &settings,
|
connect(&invertVerticalCoordinateCheckBox, &QCheckBox::QT_STATE_CHANGED, &settings,
|
||||||
SLOT(setInvertVerticalCoordinate(QT_STATE_CHANGED_T)));
|
&SettingsCache::setInvertVerticalCoordinate);
|
||||||
|
|
||||||
minPlayersForMultiColumnLayoutEdit.setMinimum(2);
|
minPlayersForMultiColumnLayoutEdit.setMinimum(2);
|
||||||
minPlayersForMultiColumnLayoutEdit.setValue(settings.getMinPlayersForMultiColumnLayout());
|
minPlayersForMultiColumnLayoutEdit.setValue(settings.getMinPlayersForMultiColumnLayout());
|
||||||
|
|
@ -442,37 +437,37 @@ UserInterfaceSettingsPage::UserInterfaceSettingsPage()
|
||||||
{
|
{
|
||||||
// general settings and notification settings
|
// general settings and notification settings
|
||||||
notificationsEnabledCheckBox.setChecked(SettingsCache::instance().getNotificationsEnabled());
|
notificationsEnabledCheckBox.setChecked(SettingsCache::instance().getNotificationsEnabled());
|
||||||
connect(¬ificationsEnabledCheckBox, SIGNAL(QT_STATE_CHANGED(QT_STATE_CHANGED_T)), &SettingsCache::instance(),
|
connect(¬ificationsEnabledCheckBox, &QCheckBox::QT_STATE_CHANGED, &SettingsCache::instance(),
|
||||||
SLOT(setNotificationsEnabled(QT_STATE_CHANGED_T)));
|
&SettingsCache::setNotificationsEnabled);
|
||||||
connect(¬ificationsEnabledCheckBox, SIGNAL(QT_STATE_CHANGED(QT_STATE_CHANGED_T)), this,
|
connect(¬ificationsEnabledCheckBox, &QCheckBox::QT_STATE_CHANGED, this,
|
||||||
SLOT(setNotificationEnabled(QT_STATE_CHANGED_T)));
|
&UserInterfaceSettingsPage::setNotificationEnabled);
|
||||||
|
|
||||||
specNotificationsEnabledCheckBox.setChecked(SettingsCache::instance().getSpectatorNotificationsEnabled());
|
specNotificationsEnabledCheckBox.setChecked(SettingsCache::instance().getSpectatorNotificationsEnabled());
|
||||||
specNotificationsEnabledCheckBox.setEnabled(SettingsCache::instance().getNotificationsEnabled());
|
specNotificationsEnabledCheckBox.setEnabled(SettingsCache::instance().getNotificationsEnabled());
|
||||||
connect(&specNotificationsEnabledCheckBox, SIGNAL(QT_STATE_CHANGED(QT_STATE_CHANGED_T)), &SettingsCache::instance(),
|
connect(&specNotificationsEnabledCheckBox, &QCheckBox::QT_STATE_CHANGED, &SettingsCache::instance(),
|
||||||
SLOT(setSpectatorNotificationsEnabled(QT_STATE_CHANGED_T)));
|
&SettingsCache::setSpectatorNotificationsEnabled);
|
||||||
|
|
||||||
buddyConnectNotificationsEnabledCheckBox.setChecked(
|
buddyConnectNotificationsEnabledCheckBox.setChecked(
|
||||||
SettingsCache::instance().getBuddyConnectNotificationsEnabled());
|
SettingsCache::instance().getBuddyConnectNotificationsEnabled());
|
||||||
buddyConnectNotificationsEnabledCheckBox.setEnabled(SettingsCache::instance().getNotificationsEnabled());
|
buddyConnectNotificationsEnabledCheckBox.setEnabled(SettingsCache::instance().getNotificationsEnabled());
|
||||||
connect(&buddyConnectNotificationsEnabledCheckBox, SIGNAL(QT_STATE_CHANGED(QT_STATE_CHANGED_T)),
|
connect(&buddyConnectNotificationsEnabledCheckBox, &QCheckBox::QT_STATE_CHANGED, &SettingsCache::instance(),
|
||||||
&SettingsCache::instance(), SLOT(setBuddyConnectNotificationsEnabled(QT_STATE_CHANGED_T)));
|
&SettingsCache::setBuddyConnectNotificationsEnabled);
|
||||||
|
|
||||||
doubleClickToPlayCheckBox.setChecked(SettingsCache::instance().getDoubleClickToPlay());
|
doubleClickToPlayCheckBox.setChecked(SettingsCache::instance().getDoubleClickToPlay());
|
||||||
connect(&doubleClickToPlayCheckBox, SIGNAL(QT_STATE_CHANGED(QT_STATE_CHANGED_T)), &SettingsCache::instance(),
|
connect(&doubleClickToPlayCheckBox, &QCheckBox::QT_STATE_CHANGED, &SettingsCache::instance(),
|
||||||
SLOT(setDoubleClickToPlay(QT_STATE_CHANGED_T)));
|
&SettingsCache::setDoubleClickToPlay);
|
||||||
|
|
||||||
playToStackCheckBox.setChecked(SettingsCache::instance().getPlayToStack());
|
playToStackCheckBox.setChecked(SettingsCache::instance().getPlayToStack());
|
||||||
connect(&playToStackCheckBox, SIGNAL(QT_STATE_CHANGED(QT_STATE_CHANGED_T)), &SettingsCache::instance(),
|
connect(&playToStackCheckBox, &QCheckBox::QT_STATE_CHANGED, &SettingsCache::instance(),
|
||||||
SLOT(setPlayToStack(QT_STATE_CHANGED_T)));
|
&SettingsCache::setPlayToStack);
|
||||||
|
|
||||||
annotateTokensCheckBox.setChecked(SettingsCache::instance().getAnnotateTokens());
|
annotateTokensCheckBox.setChecked(SettingsCache::instance().getAnnotateTokens());
|
||||||
connect(&annotateTokensCheckBox, SIGNAL(QT_STATE_CHANGED(QT_STATE_CHANGED_T)), &SettingsCache::instance(),
|
connect(&annotateTokensCheckBox, &QCheckBox::QT_STATE_CHANGED, &SettingsCache::instance(),
|
||||||
SLOT(setAnnotateTokens(QT_STATE_CHANGED_T)));
|
&SettingsCache::setAnnotateTokens);
|
||||||
|
|
||||||
useTearOffMenusCheckBox.setChecked(SettingsCache::instance().getUseTearOffMenus());
|
useTearOffMenusCheckBox.setChecked(SettingsCache::instance().getUseTearOffMenus());
|
||||||
connect(&useTearOffMenusCheckBox, &QCheckBox::QT_STATE_CHANGED, &SettingsCache::instance(),
|
connect(&useTearOffMenusCheckBox, &QCheckBox::QT_STATE_CHANGED, &SettingsCache::instance(),
|
||||||
[](QT_STATE_CHANGED_T state) { SettingsCache::instance().setUseTearOffMenus(state == Qt::Checked); });
|
[](const QT_STATE_CHANGED_T state) { SettingsCache::instance().setUseTearOffMenus(state == Qt::Checked); });
|
||||||
|
|
||||||
auto *generalGrid = new QGridLayout;
|
auto *generalGrid = new QGridLayout;
|
||||||
generalGrid->addWidget(&doubleClickToPlayCheckBox, 0, 0);
|
generalGrid->addWidget(&doubleClickToPlayCheckBox, 0, 0);
|
||||||
|
|
@ -493,8 +488,8 @@ UserInterfaceSettingsPage::UserInterfaceSettingsPage()
|
||||||
|
|
||||||
// animation settings
|
// animation settings
|
||||||
tapAnimationCheckBox.setChecked(SettingsCache::instance().getTapAnimation());
|
tapAnimationCheckBox.setChecked(SettingsCache::instance().getTapAnimation());
|
||||||
connect(&tapAnimationCheckBox, SIGNAL(QT_STATE_CHANGED(QT_STATE_CHANGED_T)), &SettingsCache::instance(),
|
connect(&tapAnimationCheckBox, &QCheckBox::QT_STATE_CHANGED, &SettingsCache::instance(),
|
||||||
SLOT(setTapAnimation(QT_STATE_CHANGED_T)));
|
&SettingsCache::setTapAnimation);
|
||||||
|
|
||||||
auto *animationGrid = new QGridLayout;
|
auto *animationGrid = new QGridLayout;
|
||||||
animationGrid->addWidget(&tapAnimationCheckBox, 0, 0);
|
animationGrid->addWidget(&tapAnimationCheckBox, 0, 0);
|
||||||
|
|
@ -504,8 +499,8 @@ UserInterfaceSettingsPage::UserInterfaceSettingsPage()
|
||||||
|
|
||||||
// deck editor settings
|
// deck editor settings
|
||||||
openDeckInNewTabCheckBox.setChecked(SettingsCache::instance().getOpenDeckInNewTab());
|
openDeckInNewTabCheckBox.setChecked(SettingsCache::instance().getOpenDeckInNewTab());
|
||||||
connect(&openDeckInNewTabCheckBox, SIGNAL(QT_STATE_CHANGED(QT_STATE_CHANGED_T)), &SettingsCache::instance(),
|
connect(&openDeckInNewTabCheckBox, &QCheckBox::QT_STATE_CHANGED, &SettingsCache::instance(),
|
||||||
SLOT(setOpenDeckInNewTab(QT_STATE_CHANGED_T)));
|
&SettingsCache::setOpenDeckInNewTab);
|
||||||
|
|
||||||
auto *deckEditorGrid = new QGridLayout;
|
auto *deckEditorGrid = new QGridLayout;
|
||||||
deckEditorGrid->addWidget(&openDeckInNewTabCheckBox, 0, 0);
|
deckEditorGrid->addWidget(&openDeckInNewTabCheckBox, 0, 0);
|
||||||
|
|
@ -554,8 +549,8 @@ void UserInterfaceSettingsPage::retranslateUi()
|
||||||
DeckEditorSettingsPage::DeckEditorSettingsPage()
|
DeckEditorSettingsPage::DeckEditorSettingsPage()
|
||||||
{
|
{
|
||||||
picDownloadCheckBox.setChecked(SettingsCache::instance().getPicDownload());
|
picDownloadCheckBox.setChecked(SettingsCache::instance().getPicDownload());
|
||||||
connect(&picDownloadCheckBox, SIGNAL(QT_STATE_CHANGED(QT_STATE_CHANGED_T)), &SettingsCache::instance(),
|
connect(&picDownloadCheckBox, &QCheckBox::QT_STATE_CHANGED, &SettingsCache::instance(),
|
||||||
SLOT(setPicDownload(QT_STATE_CHANGED_T)));
|
&SettingsCache::setPicDownload);
|
||||||
|
|
||||||
urlLinkLabel.setTextInteractionFlags(Qt::LinksAccessibleByMouse);
|
urlLinkLabel.setTextInteractionFlags(Qt::LinksAccessibleByMouse);
|
||||||
urlLinkLabel.setOpenExternalLinks(true);
|
urlLinkLabel.setOpenExternalLinks(true);
|
||||||
|
|
@ -870,30 +865,29 @@ void DeckEditorSettingsPage::retranslateUi()
|
||||||
MessagesSettingsPage::MessagesSettingsPage()
|
MessagesSettingsPage::MessagesSettingsPage()
|
||||||
{
|
{
|
||||||
chatMentionCheckBox.setChecked(SettingsCache::instance().getChatMention());
|
chatMentionCheckBox.setChecked(SettingsCache::instance().getChatMention());
|
||||||
connect(&chatMentionCheckBox, SIGNAL(QT_STATE_CHANGED(QT_STATE_CHANGED_T)), &SettingsCache::instance(),
|
connect(&chatMentionCheckBox, &QCheckBox::QT_STATE_CHANGED, &SettingsCache::instance(),
|
||||||
SLOT(setChatMention(QT_STATE_CHANGED_T)));
|
&SettingsCache::setChatMention);
|
||||||
|
|
||||||
chatMentionCompleterCheckbox.setChecked(SettingsCache::instance().getChatMentionCompleter());
|
chatMentionCompleterCheckbox.setChecked(SettingsCache::instance().getChatMentionCompleter());
|
||||||
connect(&chatMentionCompleterCheckbox, SIGNAL(QT_STATE_CHANGED(QT_STATE_CHANGED_T)), &SettingsCache::instance(),
|
connect(&chatMentionCompleterCheckbox, &QCheckBox::QT_STATE_CHANGED, &SettingsCache::instance(),
|
||||||
SLOT(setChatMentionCompleter(QT_STATE_CHANGED_T)));
|
&SettingsCache::setChatMentionCompleter);
|
||||||
|
|
||||||
explainMessagesLabel.setTextInteractionFlags(Qt::LinksAccessibleByMouse);
|
explainMessagesLabel.setTextInteractionFlags(Qt::LinksAccessibleByMouse);
|
||||||
explainMessagesLabel.setOpenExternalLinks(true);
|
explainMessagesLabel.setOpenExternalLinks(true);
|
||||||
|
|
||||||
ignoreUnregUsersMainChat.setChecked(SettingsCache::instance().getIgnoreUnregisteredUsers());
|
ignoreUnregUsersMainChat.setChecked(SettingsCache::instance().getIgnoreUnregisteredUsers());
|
||||||
ignoreUnregUserMessages.setChecked(SettingsCache::instance().getIgnoreUnregisteredUserMessages());
|
ignoreUnregUserMessages.setChecked(SettingsCache::instance().getIgnoreUnregisteredUserMessages());
|
||||||
connect(&ignoreUnregUsersMainChat, SIGNAL(QT_STATE_CHANGED(QT_STATE_CHANGED_T)), &SettingsCache::instance(),
|
connect(&ignoreUnregUsersMainChat, &QCheckBox::QT_STATE_CHANGED, &SettingsCache::instance(),
|
||||||
SLOT(setIgnoreUnregisteredUsers(QT_STATE_CHANGED_T)));
|
&SettingsCache::setIgnoreUnregisteredUsers);
|
||||||
connect(&ignoreUnregUserMessages, SIGNAL(QT_STATE_CHANGED(QT_STATE_CHANGED_T)), &SettingsCache::instance(),
|
connect(&ignoreUnregUserMessages, &QCheckBox::QT_STATE_CHANGED, &SettingsCache::instance(),
|
||||||
SLOT(setIgnoreUnregisteredUserMessages(QT_STATE_CHANGED_T)));
|
&SettingsCache::setIgnoreUnregisteredUserMessages);
|
||||||
|
|
||||||
invertMentionForeground.setChecked(SettingsCache::instance().getChatMentionForeground());
|
invertMentionForeground.setChecked(SettingsCache::instance().getChatMentionForeground());
|
||||||
connect(&invertMentionForeground, SIGNAL(QT_STATE_CHANGED(QT_STATE_CHANGED_T)), this,
|
connect(&invertMentionForeground, &QCheckBox::QT_STATE_CHANGED, this, &MessagesSettingsPage::updateTextColor);
|
||||||
SLOT(updateTextColor(QT_STATE_CHANGED_T)));
|
|
||||||
|
|
||||||
invertHighlightForeground.setChecked(SettingsCache::instance().getChatHighlightForeground());
|
invertHighlightForeground.setChecked(SettingsCache::instance().getChatHighlightForeground());
|
||||||
connect(&invertHighlightForeground, SIGNAL(QT_STATE_CHANGED(QT_STATE_CHANGED_T)), this,
|
connect(&invertHighlightForeground, &QCheckBox::QT_STATE_CHANGED, this,
|
||||||
SLOT(updateTextHighlightColor(QT_STATE_CHANGED_T)));
|
&MessagesSettingsPage::updateTextHighlightColor);
|
||||||
|
|
||||||
mentionColor = new QLineEdit();
|
mentionColor = new QLineEdit();
|
||||||
mentionColor->setText(SettingsCache::instance().getChatMentionColor());
|
mentionColor->setText(SettingsCache::instance().getChatMentionColor());
|
||||||
|
|
@ -901,16 +895,15 @@ MessagesSettingsPage::MessagesSettingsPage()
|
||||||
connect(mentionColor, SIGNAL(textChanged(QString)), this, SLOT(updateColor(QString)));
|
connect(mentionColor, SIGNAL(textChanged(QString)), this, SLOT(updateColor(QString)));
|
||||||
|
|
||||||
messagePopups.setChecked(SettingsCache::instance().getShowMessagePopup());
|
messagePopups.setChecked(SettingsCache::instance().getShowMessagePopup());
|
||||||
connect(&messagePopups, SIGNAL(QT_STATE_CHANGED(QT_STATE_CHANGED_T)), &SettingsCache::instance(),
|
connect(&messagePopups, &QCheckBox::QT_STATE_CHANGED, &SettingsCache::instance(),
|
||||||
SLOT(setShowMessagePopups(QT_STATE_CHANGED_T)));
|
&SettingsCache::setShowMessagePopups);
|
||||||
|
|
||||||
mentionPopups.setChecked(SettingsCache::instance().getShowMentionPopup());
|
mentionPopups.setChecked(SettingsCache::instance().getShowMentionPopup());
|
||||||
connect(&mentionPopups, SIGNAL(QT_STATE_CHANGED(QT_STATE_CHANGED_T)), &SettingsCache::instance(),
|
connect(&mentionPopups, &QCheckBox::QT_STATE_CHANGED, &SettingsCache::instance(),
|
||||||
SLOT(setShowMentionPopups(QT_STATE_CHANGED_T)));
|
&SettingsCache::setShowMentionPopups);
|
||||||
|
|
||||||
roomHistory.setChecked(SettingsCache::instance().getRoomHistory());
|
roomHistory.setChecked(SettingsCache::instance().getRoomHistory());
|
||||||
connect(&roomHistory, SIGNAL(QT_STATE_CHANGED(QT_STATE_CHANGED_T)), &SettingsCache::instance(),
|
connect(&roomHistory, &QCheckBox::QT_STATE_CHANGED, &SettingsCache::instance(), &SettingsCache::setRoomHistory);
|
||||||
SLOT(setRoomHistory(QT_STATE_CHANGED_T)));
|
|
||||||
|
|
||||||
customAlertString = new QLineEdit();
|
customAlertString = new QLineEdit();
|
||||||
customAlertString->setPlaceholderText(tr("Word1 Word2 Word3"));
|
customAlertString->setPlaceholderText(tr("Word1 Word2 Word3"));
|
||||||
|
|
@ -1112,8 +1105,8 @@ void MessagesSettingsPage::retranslateUi()
|
||||||
SoundSettingsPage::SoundSettingsPage()
|
SoundSettingsPage::SoundSettingsPage()
|
||||||
{
|
{
|
||||||
soundEnabledCheckBox.setChecked(SettingsCache::instance().getSoundEnabled());
|
soundEnabledCheckBox.setChecked(SettingsCache::instance().getSoundEnabled());
|
||||||
connect(&soundEnabledCheckBox, SIGNAL(QT_STATE_CHANGED(QT_STATE_CHANGED_T)), &SettingsCache::instance(),
|
connect(&soundEnabledCheckBox, &QCheckBox::QT_STATE_CHANGED, &SettingsCache::instance(),
|
||||||
SLOT(setSoundEnabled(QT_STATE_CHANGED_T)));
|
&SettingsCache::setSoundEnabled);
|
||||||
|
|
||||||
QString themeName = SettingsCache::instance().getSoundThemeName();
|
QString themeName = SettingsCache::instance().getSoundThemeName();
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -96,12 +96,9 @@ ZoneViewWidget::ZoneViewWidget(Player *_player,
|
||||||
// numberCard is the num of cards we want to reveal from an area. Ex: scry the top 3 cards.
|
// numberCard is the num of cards we want to reveal from an area. Ex: scry the top 3 cards.
|
||||||
// If the number is < 0 then it means that we can make the area sorted and we dont care about the order.
|
// If the number is < 0 then it means that we can make the area sorted and we dont care about the order.
|
||||||
if (numberCards < 0) {
|
if (numberCards < 0) {
|
||||||
connect(&sortByNameCheckBox, SIGNAL(QT_STATE_CHANGED(QT_STATE_CHANGED_T)), this,
|
connect(&sortByNameCheckBox, &QCheckBox::QT_STATE_CHANGED, this, &ZoneViewWidget::processSortByName);
|
||||||
SLOT(processSortByName(QT_STATE_CHANGED_T)));
|
connect(&sortByTypeCheckBox, &QCheckBox::QT_STATE_CHANGED, this, &ZoneViewWidget::processSortByType);
|
||||||
connect(&sortByTypeCheckBox, SIGNAL(QT_STATE_CHANGED(QT_STATE_CHANGED_T)), this,
|
connect(&pileViewCheckBox, &QCheckBox::QT_STATE_CHANGED, this, &ZoneViewWidget::processSetPileView);
|
||||||
SLOT(processSortByType(QT_STATE_CHANGED_T)));
|
|
||||||
connect(&pileViewCheckBox, SIGNAL(QT_STATE_CHANGED(QT_STATE_CHANGED_T)), this,
|
|
||||||
SLOT(processSetPileView(QT_STATE_CHANGED_T)));
|
|
||||||
sortByNameCheckBox.setChecked(SettingsCache::instance().getZoneViewSortByName());
|
sortByNameCheckBox.setChecked(SettingsCache::instance().getZoneViewSortByName());
|
||||||
sortByTypeCheckBox.setChecked(SettingsCache::instance().getZoneViewSortByType());
|
sortByTypeCheckBox.setChecked(SettingsCache::instance().getZoneViewSortByType());
|
||||||
pileViewCheckBox.setChecked(SettingsCache::instance().getZoneViewPileView());
|
pileViewCheckBox.setChecked(SettingsCache::instance().getZoneViewPileView());
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue