# HG changeset patch # User Sebastien Jodogne # Date 1711118142 -3600 # Node ID 5fc3ea6acbd5e15df601ffb71acd3ffad3e898b8 # Parent dd0cd39e6259ada3f199e12a1e07b5814fc16d9e fix deprecated calls diff -r dd0cd39e6259 -r 5fc3ea6acbd5 Sources/Plugin.cpp --- a/Sources/Plugin.cpp Fri Mar 22 15:34:22 2024 +0100 +++ b/Sources/Plugin.cpp Fri Mar 22 15:35:42 2024 +0100 @@ -50,6 +50,8 @@ #include +#define ORTHANC_PLUGIN_NAME "stl" + // Forward declaration void ReadStaticAsset(std::string& target, @@ -1632,7 +1634,7 @@ << ") is insufficient to create DICOM STL, it should be above 1.12.1"; } - OrthancPluginSetDescription(context, "STL plugin for Orthanc."); + OrthancPlugins::SetDescription(ORTHANC_PLUGIN_NAME, "STL plugin for Orthanc."); OrthancPlugins::RegisterRestCallback("/stl/app/(.*)", true); OrthancPlugins::RegisterRestCallback("/instances/([0-9a-f-]+)/stl", true); @@ -1654,7 +1656,7 @@ dictionary["HAS_CREATE_DICOM_STL"] = (hasCreateDicomStl_ ? "true" : "false"); explorer = Orthanc::Toolbox::SubstituteVariables(explorer, dictionary); - OrthancPluginExtendOrthancExplorer(OrthancPlugins::GetGlobalContext(), explorer.c_str()); + OrthancPlugins::ExtendOrthancExplorer(ORTHANC_PLUGIN_NAME, explorer); } return 0; @@ -1669,7 +1671,7 @@ ORTHANC_PLUGINS_API const char* OrthancPluginGetName() { - return "stl"; + return ORTHANC_PLUGIN_NAME; }