MCPcopy Create free account
hub / github.com/WarmUpTill/SceneSwitcher / RunActions

Method RunActions

lib/queue/action-queue.cpp:141–171  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

139}
140
141void ActionQueue::RunActions()
142{
143 std::shared_ptr<MacroAction> action;
144 while (true) {
145 { // Grab next action to run
146 std::unique_lock<std::mutex> lock(_mutex);
147 while (_actions.empty() && !_stop) {
148 _lastEmpty =
149 std::chrono::high_resolution_clock::now();
150 _cv.wait(lock);
151 }
152
153 if (_stop) {
154 return;
155 }
156 action = _actions.front();
157 _actions.pop_front();
158 }
159
160 if (!action) {
161 continue;
162 }
163
164 if (ActionLoggingEnabled()) {
165 blog(LOG_INFO, "Performing action '%s' in queue '%s'",
166 action->GetId().c_str(), _name.c_str());
167 action->LogAction();
168 }
169 action->PerformAction();
170 }
171}
172
173ActionQueueSettingsDialog::ActionQueueSettingsDialog(QWidget *parent,
174 ActionQueue &settings)

Callers

nothing calls this directly

Calls 7

nowClass · 0.85
ActionLoggingEnabledFunction · 0.85
emptyMethod · 0.45
c_strMethod · 0.45
GetIdMethod · 0.45
LogActionMethod · 0.45
PerformActionMethod · 0.45

Tested by

no test coverage detected