mirror of
https://github.com/Hofknecht/SystemTrayMenu.git
synced 2024-06-30 03:51:14 +12:00
run visual studio code Cleanup
This commit is contained in:
parent
0e38067e79
commit
4a294c7d76
|
@ -1,11 +1,4 @@
|
|||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.ComponentModel;
|
||||
using System.Data;
|
||||
using System.Drawing;
|
||||
using System.Linq;
|
||||
using System.Text;
|
||||
using System.Threading.Tasks;
|
||||
using System.Windows.Forms;
|
||||
|
||||
namespace SystemTrayMenu.Controls
|
||||
|
|
|
@ -156,7 +156,7 @@ namespace SystemTrayMenu
|
|||
{
|
||||
DataGridViewElementStates states = DataGridViewElementStates.None;
|
||||
dgv.AutoResizeRows();
|
||||
int height = (int)(dgv.Rows.GetRowsHeight(states));
|
||||
int height = (int)(dgv.Rows.GetRowsHeight(states));
|
||||
int heightMax = screen.Bounds.Height -
|
||||
new Taskbar().Size.Height -
|
||||
labelTitle.Height;
|
||||
|
|
|
@ -1,17 +1,4 @@
|
|||
using Clearcove.Logging;
|
||||
using IWshRuntimeLibrary;
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.ComponentModel;
|
||||
using System.Diagnostics;
|
||||
using System.Drawing;
|
||||
using System.IO;
|
||||
using System.Linq;
|
||||
using System.Runtime.InteropServices;
|
||||
using System.Text;
|
||||
using System.Windows.Forms;
|
||||
using SystemTrayMenu.Helper;
|
||||
using TAFactory.IconPack;
|
||||
using System.Collections.Generic;
|
||||
|
||||
namespace SystemTrayMenu.Controls
|
||||
{
|
||||
|
|
|
@ -488,7 +488,7 @@ namespace SystemTrayMenu.Controls
|
|||
var graphics = Graphics.FromImage(target);
|
||||
graphics.DrawIcon(originalIcon, 0, 0);
|
||||
graphics.DrawIcon(overlay, 0, 0);
|
||||
target.MakeTransparent(target.GetPixel(1,1));
|
||||
target.MakeTransparent(target.GetPixel(1, 1));
|
||||
return Icon.FromHandle(target.GetHicon());
|
||||
}
|
||||
|
||||
|
|
|
@ -1,5 +1,4 @@
|
|||
using Microsoft.Win32;
|
||||
using System;
|
||||
|
||||
namespace SystemTrayMenu.Helper
|
||||
{
|
||||
|
|
|
@ -1,5 +1,4 @@
|
|||
using System.Drawing;
|
||||
using System.Windows.Forms;
|
||||
using System.Windows.Forms;
|
||||
|
||||
namespace SystemTrayMenu.Helper
|
||||
{
|
||||
|
|
|
@ -19,7 +19,7 @@ namespace SystemTrayMenu
|
|||
public const int MenuRowsHeight = 18;
|
||||
public const int LengthMax = 37;
|
||||
public const int ButtonTextPaddingLeft = 18;
|
||||
public const int ButtonTextPaddingRight= 12;
|
||||
public const int ButtonTextPaddingRight = 12;
|
||||
|
||||
public const int Scrollspeed = 4;
|
||||
|
||||
|
|
|
@ -1,5 +1,4 @@
|
|||
using Clearcove.Logging;
|
||||
using Microsoft.Win32;
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.ComponentModel;
|
||||
|
|
|
@ -425,7 +425,7 @@ namespace SystemTrayMenu
|
|||
// Using SHGetSetSettings would be much better in performance but the results are not accurate.
|
||||
// We have to go for the shell interface in order to receive the correct settings:
|
||||
// https://docs.microsoft.com/en-us/windows/win32/shell/ishelldispatch4-getsetting
|
||||
const int SSF_SHOWALLOBJECTS = 0x00000001;
|
||||
const int SSF_SHOWALLOBJECTS = 0x00000001;
|
||||
const int SSF_SHOWSUPERHIDDEN = 0x00040000;
|
||||
|
||||
HideHiddenEntries = !iShellDispatch4.GetSetting(SSF_SHOWALLOBJECTS);
|
||||
|
@ -487,9 +487,9 @@ namespace SystemTrayMenu
|
|||
|
||||
try
|
||||
{
|
||||
files = Directory.GetFiles(path). Where(p =>
|
||||
!Path.GetFileName(p).Equals("desktop.ini", StringComparison.OrdinalIgnoreCase) && // Windows folder settings, e.g. Win10 "desktop.ini", Win2003 "Desktop.ini"
|
||||
!Path.GetFileName(p).Equals("thumbs.db", StringComparison.OrdinalIgnoreCase) // Windows thumbnail cache
|
||||
files = Directory.GetFiles(path).Where(p =>
|
||||
!Path.GetFileName(p).Equals("desktop.ini", StringComparison.OrdinalIgnoreCase) && // Windows folder settings, e.g. Win10 "desktop.ini", Win2003 "Desktop.ini"
|
||||
!Path.GetFileName(p).Equals("thumbs.db", StringComparison.OrdinalIgnoreCase) // Windows thumbnail cache
|
||||
).ToArray();
|
||||
Array.Sort(files, new WindowsExplorerSort());
|
||||
}
|
||||
|
@ -1085,7 +1085,7 @@ namespace SystemTrayMenu
|
|||
{
|
||||
dgv.FirstDisplayedScrollingRowIndex = row.Index;
|
||||
}
|
||||
else if(row.Index >=
|
||||
else if (row.Index >=
|
||||
dgv.FirstDisplayedScrollingRowIndex +
|
||||
dgv.DisplayedRowCount(false))
|
||||
{
|
||||
|
|
Loading…
Reference in a new issue