@@ -26,24 +26,23 @@ namespace Files.App.ViewModels.Previews
2626{
2727 public sealed class ShellPreviewViewModel : BasePreviewModel
2828 {
29- public ShellPreviewViewModel ( ListedItem item )
30- : base ( item )
31- {
32- }
33-
34- public async override Task < List < FileProperty > > LoadPreviewAndDetailsAsync ( )
35- => [ ] ;
36-
37- private const string IPreviewHandlerIid = "{8895b1c6-b41f-4c1c-a562-0d564250836f}" ;
38- private static readonly Guid QueryAssociationsClsid = new Guid ( 0xa07034fd , 0x6caa , 0x4954 , 0xac , 0x3f , 0x97 , 0xa2 , 0x72 , 0x16 , 0xf9 , 0x8a ) ;
39- private static readonly Guid IQueryAssociationsIid = Guid . ParseExact ( "c46ca590-3c3f-11d2-bee6-0000f805ca57" , "d" ) ;
29+ private static readonly Guid IPreviewHandlerIid = new ( 0x8895b1c6 , 0xb41f , 0x4c1c , 0xa5 , 0x62 , 0x0d , 0x56 , 0x42 , 0x50 , 0x83 , 0x6f ) ;
30+ private static readonly Guid QueryAssociationsClsid = new ( 0xa07034fd , 0x6caa , 0x4954 , 0xac , 0x3f , 0x97 , 0xa2 , 0x72 , 0x16 , 0xf9 , 0x8a ) ;
31+ private static readonly Guid IQueryAssociationsIid = new ( 0xc46ca590 , 0x3c3f , 0x11d2 , 0xbe , 0xe6 , 0x00 , 0x00 , 0xf8 , 0x05 , 0xca , 0x57 ) ;
4032
4133 PreviewHandler ? currentHandler ;
4234 ContentExternalOutputLink ? outputLink ;
4335 WNDCLASSEXW ? wCls ;
4436 HWND hwnd = HWND . Null ;
4537 bool isOfficePreview = false ;
4638
39+ public ShellPreviewViewModel ( ListedItem item ) : base ( item )
40+ {
41+ }
42+
43+ public async override Task < List < FileProperty > > LoadPreviewAndDetailsAsync ( )
44+ => [ ] ;
45+
4746 public static unsafe Guid ? FindPreviewHandlerFor ( string extension , nint hwnd )
4847 {
4948 if ( string . IsNullOrEmpty ( extension ) )
@@ -64,7 +63,7 @@ public async override Task<List<FileProperty>> LoadPreviewAndDetailsAsync()
6463
6564 queryAssoc . Init ( ASSOCF . ASSOCF_INIT_DEFAULTTOSTAR , lpwszExtension , HKEY . Null , new ( hwnd ) ) ;
6665
67- fixed ( char * pszIPreviewHandlerIID = IPreviewHandlerIid )
66+ fixed ( char * pszIPreviewHandlerIID = IPreviewHandlerIid . ToString ( ) )
6867 {
6968 PWSTR lpwszIPreviewHandlerIID = new ( pszIPreviewHandlerIID ) ;
7069
0 commit comments