mirror of
https://github.com/Chatterino/chatterino2.git
synced 2024-11-21 22:24:07 +01:00
Remove unused PluginController::callEvery{,WithArgs}
This commit is contained in:
parent
a40d29a514
commit
87605077cb
2 changed files with 0 additions and 27 deletions
|
@ -259,28 +259,6 @@ bool PluginController::reload(const QString &codename)
|
|||
return true;
|
||||
}
|
||||
|
||||
void PluginController::callEvery(const QString &functionName)
|
||||
{
|
||||
for (const auto &[name, plugin] : this->plugins_)
|
||||
{
|
||||
lua_getglobal(plugin->state_, functionName.toStdString().c_str());
|
||||
lua_pcall(plugin->state_, 0, 0, 0);
|
||||
}
|
||||
}
|
||||
|
||||
void PluginController::callEveryWithArgs(
|
||||
const QString &functionName, int count,
|
||||
const std::function<void(const std::unique_ptr<Plugin> &pl, lua_State *L)>
|
||||
&argCb)
|
||||
{
|
||||
for (const auto &[name, plugin] : this->plugins_)
|
||||
{
|
||||
lua_getglobal(plugin->state_, functionName.toStdString().c_str());
|
||||
argCb(plugin, plugin->state_);
|
||||
lua_pcall(plugin->state_, count, 0, 0);
|
||||
}
|
||||
}
|
||||
|
||||
QString PluginController::tryExecPluginCommand(const QString &commandName,
|
||||
const CommandContext &ctx)
|
||||
{
|
||||
|
|
|
@ -28,11 +28,6 @@ class PluginController : public Singleton
|
|||
public:
|
||||
void initialize(Settings &settings, Paths &paths) override;
|
||||
void save() override{};
|
||||
void callEvery(const QString &functionName);
|
||||
void callEveryWithArgs(
|
||||
const QString &functionName, int count,
|
||||
const std::function<void(const std::unique_ptr<Plugin> &pl,
|
||||
lua_State *L)> &argCb);
|
||||
|
||||
QString tryExecPluginCommand(const QString &commandName,
|
||||
const CommandContext &ctx);
|
||||
|
|
Loading…
Reference in a new issue