mirror of
https://github.com/microsoft/PowerToys.git
synced 2026-04-06 19:26:39 +02:00
[FileExplorer] StlThumbnailProvider (#15568)
* Adds StlThumbnailProvider * Spell checker fixes * Adds missing changes * Attempts to fix alpha background issue * Adds missing dependency references * Upgrades .NET Core 3.1 to .NET 5 * Updates Helix Toolkit to fix .net5 compatibility * Return null bitmap If STL model is empty
This commit is contained in:
@@ -39,6 +39,9 @@ const CLSID CLSID_GcodePreviewHandler = { 0xec52dea8, 0x7c9f, 0x4130, { 0xa7, 0x
|
||||
|
||||
// BFEE99B4-B74D-4348-BCA5-E757029647FF
|
||||
const GUID CLSID_GcodeThumbnailProvider = { 0xbfee99b4, 0xb74d, 0x4348, { 0xbc, 0xa5, 0xe7, 0x57, 0x02, 0x96, 0x47, 0xff } };
|
||||
|
||||
// 8BC8AFC2-4E7C-4695-818E-8C1FFDCEA2AF
|
||||
const GUID CLSID_StlThumbnailProvider = { 0x8bc8afc2, 0x4e7c, 0x4695, { 0x81, 0x8e, 0x8c, 0x1f, 0xfd, 0xce, 0xa2, 0xaf } };
|
||||
|
||||
// Pairs of NativeClsid vs ManagedClsid used for preview handlers.
|
||||
const std::vector<std::pair<CLSID, CLSID>> NativeToManagedClsid({
|
||||
|
||||
@@ -186,4 +186,7 @@
|
||||
<data name="Prevpane_Gcode_Settings_Displayname" xml:space="preserve">
|
||||
<value>G-code Previewer</value>
|
||||
</data>
|
||||
<data name="Stl_Thumbnail_Provider_Settings_Description" xml:space="preserve">
|
||||
<value>Stl Thumbnail Provider</value>
|
||||
</data>
|
||||
</root>
|
||||
@@ -54,6 +54,10 @@ PowerPreviewModule::PowerPreviewModule() :
|
||||
.settingDescription = GET_RESOURCE_STRING(IDS_GCODE_THUMBNAIL_PROVIDER_SETTINGS_DESCRIPTION),
|
||||
.registryChanges = getGcodeThumbnailHandlerChangeSet(installationDir, installPerUser) });
|
||||
|
||||
m_fileExplorerModules.push_back({ .settingName = L"stl-thumbnail-toggle-setting",
|
||||
.settingDescription = GET_RESOURCE_STRING(IDS_STL_THUMBNAIL_PROVIDER_SETTINGS_DESCRIPTION),
|
||||
.registryChanges = getStlThumbnailHandlerChangeSet(installationDir, installPerUser) });
|
||||
|
||||
try
|
||||
{
|
||||
PowerToysSettings::PowerToyValues settings =
|
||||
|
||||
Reference in New Issue
Block a user