version 1.2.2 #218

Merged
peri4 merged 1 commits from v1_master into v1_release 2024-05-02 12:10:44 +03:00
4 changed files with 8 additions and 5 deletions

View File

@@ -33,7 +33,7 @@ endif()
set_version(SHS
MAJOR 1
MINOR 2
REVISION 1
REVISION 2
BUILD "${BUILD_NUMBER}"
SUFFIX ""
OUTPUT "${SHS_VERSION_FILE}")

View File

@@ -338,8 +338,11 @@ void collectPlugins(QSet<QString> & out, const SHS::Object & o) {
QMapIterator<QString, SHS::Command> cit(o.commands);
while (cit.hasNext()) {
cit.next();
auto ppi = RUNTIME->plugins_manager->localInterface().getPlugin(cit.value().packet_cmd.plugin_id);
if (bpi.plugin)
SHS::PluginCommand plug_cmd = cit.value().packet_cmd;
if (!cit.value().cmd.isEmpty())
plug_cmd = cit.value().cmd[0];
auto ppi = RUNTIME->plugins_manager->localInterface().getPlugin(plug_cmd.plugin_id);
if (ppi.plugin)
out << ppi.manifest.name;
}
QMapIterator<QString, SHS::Object> oit(o.objects);
@@ -413,7 +416,6 @@ void SHServerDataGenerator::generate(BlockItem * block, const QString & filename
plugins.remove("");
data.used_plugins = plugins;
qDebug() << "found used plugins:" << plugins;
qDebug() << "***write to" << filename << QDir::current().absolutePath();
saveToFile(filename, data);

View File

@@ -425,6 +425,7 @@ bool ServerDesigner::makeAssembly(const QString & f) {
QString sdpp = QDir::tempPath() + "/" + QFileInfo(file_name).fileName();
RUNTIME->server_project.used_plugins = ScriptAnalyzer::getUsedPlugins(engine.fullScript());
qDebug() << "found used plugins:" << RUNTIME->server_project.used_plugins;
qDebug() << "scheme plugins:" << RUNTIME->server_data.used_plugins;
RUNTIME->server_project.save(sdpp);
ass.pack(f, RUNTIME->server_project.getAssFiles() << rp << uip << sdpp <<
RUNTIME->server_project.ui << RUNTIME->server_project.shs << RUNTIME->server_project.shs_db,

View File

@@ -949,7 +949,7 @@ QJSValue SHSScriptEngine::createScriptObject(SHS::Object & o, uint script_plugin
if (!cmd.cmd.isEmpty()) {
cmd.packet_cmd = cmd.cmd[0];
cmd.packet_cmd.plugin = RUNTIME->plugins_manager->localInterface().getPlugin(cmd.packet_cmd.plugin_id).plugin;
//qDebug() << o.name << cmd.name << cmd.packet_cmd.plugin_id << cmd.packet_cmd.plugin;
//qDebug() << o.name << cmd.name << cmd.packet_cmd.plugin_id << (cmd.packet_cmd.plugin? cmd.packet_cmd.plugin->name() : "0x0");
for (int i = 1; i < cmd.cmd.size(); ++i) {
cmd.gw_cmd << cmd.cmd[i];
cmd.gw_cmd.back().plugin = RUNTIME->plugins_manager->localInterface().getPlugin(cmd.gw_cmd.back().plugin_id).plugin;