#include "ignoreuserspage.hpp" #include "singletons/settingsmanager.hpp" #include "util/layoutcreator.hpp" #include #include #include #include #include #include // clang-format off #define INFO "/ignore in chat ignores a user\n/unignore in chat unignores a user\n\nChatterino uses the twitch api for ignored users so they are shared with the webchat.\nIf you use your own oauth key make sure that it has the correct permissions.\n" // clang-format on namespace chatterino { namespace widgets { namespace settingspages { IgnoreUsersPage::IgnoreUsersPage() : SettingsPage("Ignore Users", "") { singletons::SettingManager &settings = singletons::SettingManager::getInstance(); util::LayoutCreator layoutCreator(this); auto layout = layoutCreator.setLayoutType(); auto label = layout.emplace(INFO); label->setWordWrap(true); label->setStyleSheet("color: #BBB"); auto group = layout.emplace("Ignored users").setLayoutType(); { group.append( this->createCheckBox("Enable twitch ignored users", settings.enableTwitchIgnoredUsers)); auto anyways = group.emplace().withoutMargin(); { anyways.emplace("Show anyways if:"); anyways.emplace(); anyways->addStretch(1); } auto addremove = group.emplace().withoutMargin(); { auto add = addremove.emplace("Ignore user"); auto remove = addremove.emplace("Unignore User"); addremove->addStretch(1); } auto userList = group.emplace(); } } } // namespace settingspages } // namespace widgets } // namespace chatterino