MCPcopy Create free account
hub / github.com/Serial-Studio/Serial-Studio / luaNotify

Function luaNotify

app/src/DataModel/NotificationCenter.cpp:492–502  ·  view source on GitHub ↗

* @brief Lua C closure that posts a notification event by level integer. */

Source from the content-addressed store, hash-verified

490 * @brief Lua C closure that posts a notification event by level integer.
491 */
492static int luaNotify(lua_State* L)
493{
494 const int level = static_cast<int>(luaL_checkinteger(L, 1));
495 QString channel;
496 QString title;
497 QString subtitle;
498 resolveLuaArgs(L, 2, channel, title, subtitle);
499
500 DataModel::NotificationCenter::instance().post(level, channel, title, subtitle);
501 return 0;
502}
503
504/**
505 * @brief Lua C closure that posts an Info-level notification.

Callers

nothing calls this directly

Calls 3

luaL_checkintegerFunction · 0.85
resolveLuaArgsFunction · 0.85
postMethod · 0.45

Tested by

no test coverage detected