mirror of
https://github.com/OrcaSlicer/OrcaSlicer.git
synced 2026-07-18 08:22:06 +00:00
Add support for sorting plugins by status, name, or source in both ascending and descending order.
30 lines
640 B
C++
30 lines
640 B
C++
#pragma once
|
|
|
|
#include <string>
|
|
|
|
namespace Slic3r
|
|
{
|
|
namespace GUI
|
|
{
|
|
enum class PluginSource
|
|
{
|
|
// IMPORTANT: ordinal order is the Plugins dialog Source sort priority.
|
|
Mine,
|
|
Subscribed,
|
|
Local
|
|
};
|
|
|
|
inline std::string to_string(PluginSource source)
|
|
{
|
|
switch (source)
|
|
{
|
|
case PluginSource::Mine: return "mine";
|
|
case PluginSource::Subscribed: return "subscribed";
|
|
case PluginSource::Local: return "local";
|
|
}
|
|
|
|
return "local";
|
|
}
|
|
}
|
|
} // namespace Slic3r::GUI
|