@@ -180,7 +180,6 @@ public sealed partial class Settings : Form
180180 public static SortedDictionary < int , Image > entriesApplicationIcon = new SortedDictionary < int , Image > ( ) ;
181181 public static SortedDictionary < int , string > entriesText = new SortedDictionary < int , string > ( ) ;
182182 public static SortedDictionary < int , string > entriesTextTrimmed = new SortedDictionary < int , string > ( ) ;
183- //public static SortedDictionary<int, bool> entriesShow = new SortedDictionary<int, bool>();
184183 public static SortedDictionary < int , bool > entriesIsFavorite = new SortedDictionary < int , bool > ( ) ;
185184 public static SortedDictionary < int , bool > entriesIsUrl = new SortedDictionary < int , bool > ( ) ;
186185 public static SortedDictionary < int , bool > entriesIsEmail = new SortedDictionary < int , bool > ( ) ;
@@ -266,7 +265,6 @@ public sealed partial class Settings : Form
266265 bool activatedHotkeys = false ; // the hotkeys should not be enabled until we have loaded everything into the clipboard list
267266 private DateTime lastClipboardEvent = DateTime . MinValue ;
268267 private int minMsBetween = 100 ;
269- //public static bool isProcessingRawClipboard = false;
270268
271269
272270 // ###########################################################################################
@@ -467,7 +465,6 @@ protected override void WndProc(ref Message m)
467465 whoUpdatedClipboardName = HandleClipboard . GetActiveApplicationName ( ) ;
468466 }
469467
470- //Logging.Log("Received clipboard [UPDATE] event");
471468 Logging . Log ( "Received clipboard [UPDATE] event from application [" + whoUpdatedClipboardName + "]" ) ;
472469
473470 // Set an overall boolean that will depict if we should continue processing clipboard
@@ -524,8 +521,8 @@ protected override void WndProc(ref Message m)
524521
525522 isProcessingClipboard = false ;
526523 }
527-
528524 break ;
525+
529526 default :
530527 base . WndProc ( ref m ) ;
531528 break ;
@@ -924,7 +921,6 @@ public static void ClearHistory()
924921 entriesIsTransparent . Clear ( ) ;
925922 entriesIsUrl . Clear ( ) ;
926923 entriesOriginal . Clear ( ) ;
927- //entriesShow.Clear();
928924 entriesText . Clear ( ) ;
929925 entriesTextTrimmed . Clear ( ) ;
930926 entriesOrder . Clear ( ) ;
@@ -944,7 +940,6 @@ public void SelectHistoryEntry(int index)
944940 int entriesInList = History . entriesInList ;
945941 if ( entriesInList > 0 )
946942 {
947- //MoveEntryToTop(entryIndex);
948943 MoveEntryToTop ( index ) ;
949944
950945 // Restore the original clipboard, if we are within the "Paste on hotkey only" mode
@@ -1062,7 +1057,6 @@ public void ToggleEnabled()
10621057 UiGeneralToggleEnableClipboard . Enabled = true ;
10631058 UiGeneralLabelEnableClipboard . Enabled = true ;
10641059 UiGeneralLabelEnableClipboardShortcut . Enabled = true ;
1065- //UiHotkeysButtonToggleApplication.Enabled = true;
10661060
10671061 SetFieldsBasedOnHistoryEnabled ( ) ;
10681062
@@ -1119,7 +1113,6 @@ public void ToggleEnabled()
11191113 UiGeneralLabelPasteToApplication . Enabled = false ;
11201114 UiGeneralToggleAlwaysPasteOriginal . Enabled = false ;
11211115 UiGeneralLabelAlwaysPasteOriginal . Enabled = false ;
1122- //UiHotkeysButtonToggleApplication.Enabled = false;
11231116 UiHotkeysButtonPasteHotkey . Enabled = false ;
11241117 UiHotkeysRadioUseStandardWindowsMethod . Enabled = false ;
11251118 UiHotkeysRadioPasteOnHotkey . Enabled = false ;
@@ -1264,19 +1257,6 @@ private void MainWindow_FormClosing(object sender, FormClosingEventArgs e)
12641257 }
12651258
12661259
1267- // ###########################################################################################
1268- // When pressing one of the history hotkeys then change focus to this application to prevent the keypresses go in to the active application
1269- // ###########################################################################################
1270-
1271- /*
1272- private void ChangeFocusToHovText()
1273- {
1274- NativeMethods.SetForegroundWindow(Handle);
1275- Logging.Log("Set focus to HovText");
1276- }
1277- */
1278-
1279-
12801260 // ###########################################################################################
12811261 // When an entry has been submitted to the clipboard then pass back focus to the originating application
12821262 // ###########################################################################################
@@ -1371,7 +1351,6 @@ private static void ConvertLegacyRegistry()
13711351 else
13721352 {
13731353 firstTimeLaunch = false ;
1374- //Logging.Log("Registry [" + registryPath + "] exists, so this is an [already initialized] launch");
13751354 }
13761355 }
13771356
@@ -1475,8 +1454,6 @@ private static void InitializeRegistry()
14751454 Logging . Log ( " \" HistorySearch\" = [" + regVal + "]" ) ;
14761455 regVal = GetRegistryKey ( registryPath , "FavoritesEnable" ) ;
14771456 Logging . Log ( " \" FavoritesEnable\" = [" + regVal + "]" ) ;
1478- //regVal = GetRegistryKey(registryPath, "FavoritesKeep");
1479- //Logging.Log(" \"FavoritesKeep\" = [" + regVal + "]");
14801457 regVal = GetRegistryKey ( registryPath , "CopyImages" ) ;
14811458 Logging . Log ( " \" CopyImages\" = [" + regVal + "]" ) ;
14821459 regVal = GetRegistryKey ( registryPath , "PasteOnSelection" ) ;
@@ -2807,7 +2784,6 @@ private void TrayIconAbout_Click(object sender, EventArgs e)
28072784 var tabToSelect = UiFormTabControl . TabPages . Cast < TabPage > ( ) . FirstOrDefault ( tab => tab . Name == tabName ) ;
28082785 if ( tabToSelect != null )
28092786 {
2810- //UiFormTabControl.SelectedIndex = 9; // About
28112787 UiFormTabControl . SelectedTab = tabToSelect ;
28122788 }
28132789 }
@@ -2825,7 +2801,6 @@ private void TrayIconSettings_Click(object sender, EventArgs e)
28252801 var tabToSelect = UiFormTabControl . TabPages . Cast < TabPage > ( ) . FirstOrDefault ( tab => tab . Name == tabName ) ;
28262802 if ( tabToSelect != null )
28272803 {
2828- //UiFormTabControl.SelectedIndex = 0; // General
28292804 UiFormTabControl . SelectedTab = tabToSelect ;
28302805 }
28312806 }
@@ -2887,7 +2862,6 @@ private void NotifyIcon_MouseDoubleClick(object sender, MouseEventArgs e)
28872862 var tabToSelect = UiFormTabControl . TabPages . Cast < TabPage > ( ) . FirstOrDefault ( tab => tab . Name == tabName ) ;
28882863 if ( tabToSelect != null )
28892864 {
2890- //UiFormTabControl.SelectedIndex = 0; // General
28912865 UiFormTabControl . SelectedTab = tabToSelect ;
28922866 }
28932867 }
@@ -2940,7 +2914,6 @@ private void GuiHotkeyBehaviourPaste_CheckedChanged(object sender, EventArgs e)
29402914 UiGeneralLabelRestoreOriginal . Enabled = false ;
29412915 UiHotkeysLabelPasteHotkey . Enabled = true ;
29422916 isEnabledPasteOnHotkey = true ;
2943- // HandleClipboard.SetClipboard(HandleClipboard.threadSafeIndex - 1);
29442917 SetNotifyIcon ( ) ;
29452918 }
29462919
@@ -3013,7 +2986,6 @@ private void HotkeySearch(object sender, NHotkey.HotkeyEventArgs e)
30132986 GetEntryCounter ( ) ;
30142987
30152988 // Check if application is enabled
3016- //if (isApplicationEnabled && entryCounter > 0)
30172989 if ( isApplicationEnabled )
30182990 {
30192991 // Hide the history list again, if it already is visible and I pressed the hotkey again
@@ -3034,9 +3006,6 @@ private void HotkeySearch(object sender, NHotkey.HotkeyEventArgs e)
30343006 originatingApplicationName = HandleClipboard . GetActiveApplicationName ( ) ;
30353007 history . SetupForm ( ) ;
30363008
3037- // Always change focus to HovText to ensure we can catch the key-up event
3038- //ChangeFocusToHovText();
3039-
30403009 // Only proceed if the entry counter is equal to or more than 0
30413010 if ( entryCounter > 0 )
30423011 {
@@ -3061,7 +3030,6 @@ private void HotkeyPasteOnHotkey(object sender, NHotkey.HotkeyEventArgs e)
30613030 {
30623031 // Get active application and change focus to HovText
30633032 originatingApplicationName = HandleClipboard . GetActiveApplicationName ( ) ;
3064- //ChangeFocusToHovText();
30653033
30663034 // Show the invisible form, so we can catch the key-up event
30673035 pasteOnHotkey . Show ( ) ;
@@ -4780,7 +4748,6 @@ public void UpdateMemoryConsumed()
47804748
47814749 public void UpdateClipboardEntriesCounters ( )
47824750 {
4783- //if (HandleClipboard.clipboardQueue.Count == 0 && clipboardSaveQueue.Count == 0)
47844751 if ( ! isProcessingClipboardQueue && ! isClipboardSaveQueueBeingProcessed )
47854752 {
47864753 try
@@ -5337,7 +5304,6 @@ public static void AutoInstall(string argument)
53375304
53385305 // Terminate the main application
53395306 settings . Close ( ) ;
5340- //Environment.Exit(0);
53415307 }
53425308
53435309
0 commit comments