mirror of
https://github.com/microsoft/PowerToys.git
synced 2026-04-05 18:57:19 +02:00
whitespace stylecop fixes for Wox.Infra (#5689)
* Limited to whitespace * removing stylecop again
This commit is contained in:
@@ -26,6 +26,7 @@ namespace Wox.Infrastructure.Image
|
||||
var i = _data[path];
|
||||
return i;
|
||||
}
|
||||
|
||||
set
|
||||
{
|
||||
_data[path] = value;
|
||||
@@ -89,5 +90,4 @@ namespace Wox.Infrastructure.Image
|
||||
Usage = new ConcurrentDictionary<string, int>(usage);
|
||||
}
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
@@ -48,7 +48,6 @@ namespace Wox.Infrastructure.Image
|
||||
{
|
||||
return null;
|
||||
}
|
||||
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@@ -69,7 +69,7 @@ namespace Wox.Infrastructure.Image
|
||||
_storage.Save(ImageCache.GetUsageAsDictionary());
|
||||
}
|
||||
|
||||
//Todo : Update it with icons specific to each theme.
|
||||
// Todo : Update it with icons specific to each theme.
|
||||
public static void UpdateIconPath(Theme theme)
|
||||
{
|
||||
if (theme == Theme.Light || theme == Theme.HighContrastWhite)
|
||||
@@ -93,6 +93,7 @@ namespace Wox.Infrastructure.Image
|
||||
}
|
||||
|
||||
public ImageType ImageType { get; }
|
||||
|
||||
public ImageSource ImageSource { get; }
|
||||
}
|
||||
|
||||
@@ -138,14 +139,13 @@ namespace Wox.Infrastructure.Image
|
||||
{
|
||||
/* Directories can also have thumbnails instead of shell icons.
|
||||
* Generating thumbnails for a bunch of folders while scrolling through
|
||||
* results from Everything makes a big impact on performance and
|
||||
* Wox responsibility.
|
||||
* results from Everything makes a big impact on performance and
|
||||
* Wox responsibility.
|
||||
* - Solution: just load the icon
|
||||
*/
|
||||
type = ImageType.Folder;
|
||||
image = WindowsThumbnailProvider.GetThumbnail(path, Constant.ThumbnailSize,
|
||||
Constant.ThumbnailSize, ThumbnailOptions.IconOnly);
|
||||
|
||||
}
|
||||
else if (File.Exists(path))
|
||||
{
|
||||
@@ -159,9 +159,9 @@ namespace Wox.Infrastructure.Image
|
||||
}
|
||||
else
|
||||
{
|
||||
/* Although the documentation for GetImage on MSDN indicates that
|
||||
/* Although the documentation for GetImage on MSDN indicates that
|
||||
* if a thumbnail is available it will return one, this has proved to not
|
||||
* be the case in many situations while testing.
|
||||
* be the case in many situations while testing.
|
||||
* - Solution: explicitly pass the ThumbnailOnly flag
|
||||
*/
|
||||
image = WindowsThumbnailProvider.GetThumbnail(path, Constant.ThumbnailSize,
|
||||
|
||||
@@ -50,11 +50,13 @@ namespace Wox.Infrastructure.Image
|
||||
out IntPtr ppv);
|
||||
|
||||
void GetParent(out IShellItem ppsi);
|
||||
|
||||
void GetDisplayName(SIGDN sigdnName, out IntPtr ppszName);
|
||||
|
||||
void GetAttributes(uint sfgaoMask, out uint psfgaoAttribs);
|
||||
|
||||
void Compare(IShellItem psi, uint hint, out int piOrder);
|
||||
}
|
||||
;
|
||||
|
||||
internal enum SIGDN : uint
|
||||
{
|
||||
@@ -105,9 +107,9 @@ namespace Wox.Infrastructure.Image
|
||||
private int height;
|
||||
|
||||
public int Width { set { width = value; } }
|
||||
|
||||
public int Height { set { height = value; } }
|
||||
}
|
||||
;
|
||||
|
||||
public static BitmapSource GetThumbnail(string fileName, int width, int height, ThumbnailOptions options)
|
||||
{
|
||||
|
||||
Reference in New Issue
Block a user