refactor: move Notebook enums to their own file (#6220)
Co-authored-by: Mm2PL <miau@mail.kotmisia.pl>
This commit is contained in:
@@ -43,6 +43,7 @@
|
||||
- Dev: Use `QMetaObject::invokeMethod` to run code on a specific thread. (#6203)
|
||||
- Dev: Added a `run-and-kill.sh` script to help debug crash-on-exit bugs. (#6188)
|
||||
- Dev: Refactored the `TimeoutStackStyle` enum into its own file. (#6216)
|
||||
- Dev: Refactored `Notebook`-related enums into their own file. (#6220)
|
||||
- Dev: Refactored event API initialization away from Application and into TwitchIrcServer. (#6198)
|
||||
- Dev: Updated GoogleTest to v1.17.0. (#6180)
|
||||
- Dev: Mini refactor of `TwitchAccount`. (#6182)
|
||||
|
||||
@@ -4,9 +4,12 @@
|
||||
#include "controllers/hotkeys/Hotkey.hpp"
|
||||
#include "controllers/hotkeys/HotkeyCategory.hpp"
|
||||
#include "controllers/hotkeys/HotkeyModel.hpp"
|
||||
#include "singletons/Settings.hpp"
|
||||
#include "util/RapidJsonSerializeQString.hpp" // IWYU pragma: keep
|
||||
|
||||
#include <pajlada/settings.hpp>
|
||||
#include <QMessageBox>
|
||||
#include <QShortcut>
|
||||
#include <QWidget>
|
||||
|
||||
namespace {
|
||||
|
||||
|
||||
@@ -13,16 +13,15 @@
|
||||
# include <QString>
|
||||
# include <sol/forward.hpp>
|
||||
|
||||
# include <algorithm>
|
||||
# include <map>
|
||||
# include <memory>
|
||||
# include <utility>
|
||||
# include <vector>
|
||||
|
||||
struct lua_State;
|
||||
|
||||
namespace chatterino {
|
||||
|
||||
class Settings;
|
||||
class Paths;
|
||||
|
||||
class PluginController
|
||||
|
||||
@@ -15,8 +15,8 @@
|
||||
#include "controllers/nicknames/Nickname.hpp"
|
||||
#include "controllers/sound/ISoundController.hpp"
|
||||
#include "singletons/Toasts.hpp"
|
||||
#include "util/RapidJsonSerializeQString.hpp"
|
||||
#include "widgets/Notebook.hpp"
|
||||
#include "util/RapidJsonSerializeQString.hpp" // IWYU pragma: keep
|
||||
#include "widgets/NotebookEnums.hpp"
|
||||
|
||||
#include <pajlada/settings/setting.hpp>
|
||||
#include <pajlada/settings/settinglistener.hpp>
|
||||
|
||||
@@ -5,8 +5,8 @@
|
||||
#include "common/Version.hpp"
|
||||
#include "singletons/Settings.hpp"
|
||||
#include "singletons/WindowManager.hpp"
|
||||
#include "util/Helpers.hpp"
|
||||
#include "widgets/dialogs/QualityPopup.hpp"
|
||||
#include "widgets/Notebook.hpp"
|
||||
#include "widgets/splits/Split.hpp"
|
||||
#include "widgets/Window.hpp"
|
||||
|
||||
|
||||
@@ -1,6 +1,7 @@
|
||||
#pragma once
|
||||
|
||||
#include "widgets/BaseWidget.hpp"
|
||||
#include "widgets/NotebookEnums.hpp"
|
||||
|
||||
#include <pajlada/signals/signal.hpp>
|
||||
#include <pajlada/signals/signalholder.hpp>
|
||||
@@ -21,17 +22,6 @@ class NotebookTab;
|
||||
class SplitContainer;
|
||||
class Split;
|
||||
|
||||
enum NotebookTabLocation { Top = 0, Left = 1, Right = 2, Bottom = 3 };
|
||||
|
||||
// Controls the visibility of tabs in this notebook
|
||||
enum NotebookTabVisibility : int {
|
||||
// Show all tabs
|
||||
AllTabs = 0,
|
||||
|
||||
// Only show tabs containing splits that are live
|
||||
LiveOnly = 1,
|
||||
};
|
||||
|
||||
using TabVisibilityFilter = std::function<bool(const NotebookTab *)>;
|
||||
|
||||
class Notebook : public BaseWidget
|
||||
|
||||
@@ -0,0 +1,16 @@
|
||||
#pragma once
|
||||
|
||||
namespace chatterino {
|
||||
|
||||
enum NotebookTabLocation { Top = 0, Left = 1, Right = 2, Bottom = 3 };
|
||||
|
||||
// Controls the visibility of tabs in this notebook
|
||||
enum NotebookTabVisibility : int {
|
||||
// Show all tabs
|
||||
AllTabs = 0,
|
||||
|
||||
// Only show tabs containing splits that are live
|
||||
LiveOnly = 1,
|
||||
};
|
||||
|
||||
} // namespace chatterino
|
||||
@@ -20,6 +20,7 @@
|
||||
#include <QGraphicsEffect>
|
||||
#include <QGridLayout>
|
||||
#include <QKeySequence>
|
||||
#include <QMessageBox>
|
||||
#include <QSizeGrip>
|
||||
|
||||
#ifdef Q_OS_WIN
|
||||
|
||||
@@ -3,7 +3,6 @@
|
||||
#include "Application.hpp"
|
||||
#include "common/Channel.hpp"
|
||||
#include "common/Literals.hpp"
|
||||
#include "common/network/NetworkRequest.hpp"
|
||||
#include "common/QLogging.hpp"
|
||||
#include "controllers/accounts/AccountController.hpp"
|
||||
#include "controllers/commands/CommandController.hpp"
|
||||
@@ -15,7 +14,6 @@
|
||||
#include "providers/IvrApi.hpp"
|
||||
#include "providers/pronouns/Pronouns.hpp"
|
||||
#include "providers/twitch/api/Helix.hpp"
|
||||
#include "providers/twitch/ChannelPointReward.hpp"
|
||||
#include "providers/twitch/TwitchAccount.hpp"
|
||||
#include "providers/twitch/TwitchChannel.hpp"
|
||||
#include "providers/twitch/TwitchIrcServer.hpp"
|
||||
@@ -34,6 +32,7 @@
|
||||
#include "widgets/helper/InvisibleSizeGrip.hpp"
|
||||
#include "widgets/helper/Line.hpp"
|
||||
#include "widgets/Label.hpp"
|
||||
#include "widgets/Notebook.hpp"
|
||||
#include "widgets/Scrollbar.hpp"
|
||||
#include "widgets/splits/Split.hpp"
|
||||
#include "widgets/Window.hpp"
|
||||
|
||||
@@ -41,6 +41,7 @@
|
||||
#include "widgets/helper/EffectLabel.hpp"
|
||||
#include "widgets/helper/ScrollbarHighlight.hpp"
|
||||
#include "widgets/helper/SearchPopup.hpp"
|
||||
#include "widgets/Notebook.hpp"
|
||||
#include "widgets/Scrollbar.hpp"
|
||||
#include "widgets/splits/Split.hpp"
|
||||
#include "widgets/splits/SplitInput.hpp"
|
||||
|
||||
@@ -10,6 +10,7 @@
|
||||
#include "widgets/helper/EditableModelView.hpp"
|
||||
|
||||
#include <QHeaderView>
|
||||
#include <QMessageBox>
|
||||
#include <QTableView>
|
||||
|
||||
namespace chatterino {
|
||||
|
||||
@@ -28,6 +28,7 @@
|
||||
#include <QFontDialog>
|
||||
#include <QFormLayout>
|
||||
#include <QLabel>
|
||||
#include <QMessageBox>
|
||||
#include <QScrollArea>
|
||||
|
||||
namespace {
|
||||
|
||||
Reference in New Issue
Block a user