mirror of
https://github.com/kangyu-california/PersistentWindows.git
synced 2025-05-12 05:25:37 +02:00
EnterDbEntryName() may return null, indicating user cancelled the dialog
This commit is contained in:
parent
b26c92a6ed
commit
f2c9dda7ee
1 changed files with 8 additions and 2 deletions
|
@ -488,7 +488,10 @@ namespace PersistentWindows.SystrayShell
|
||||||
pwp.dbDisplayKey = pwp.GetDisplayKey();
|
pwp.dbDisplayKey = pwp.GetDisplayKey();
|
||||||
if ((User32.GetKeyState(0x11) & 0x8000) != 0) //ctrl key pressed
|
if ((User32.GetKeyState(0x11) & 0x8000) != 0) //ctrl key pressed
|
||||||
{
|
{
|
||||||
pwp.dbDisplayKey += EnterDbEntryName();
|
var name = EnterDbEntryName();
|
||||||
|
if (String.IsNullOrEmpty(name))
|
||||||
|
return;
|
||||||
|
pwp.dbDisplayKey += name;
|
||||||
}
|
}
|
||||||
|
|
||||||
capture_to_hdd_timer.Change(delay_capture ? delay_manual_capture : 0, Timeout.Infinite);
|
capture_to_hdd_timer.Change(delay_capture ? delay_manual_capture : 0, Timeout.Infinite);
|
||||||
|
@ -519,7 +522,10 @@ namespace PersistentWindows.SystrayShell
|
||||||
pwp.dbDisplayKey = pwp.GetDisplayKey();
|
pwp.dbDisplayKey = pwp.GetDisplayKey();
|
||||||
if ((User32.GetKeyState(0x11) & 0x8000) != 0) //ctrl key pressed
|
if ((User32.GetKeyState(0x11) & 0x8000) != 0) //ctrl key pressed
|
||||||
{
|
{
|
||||||
pwp.dbDisplayKey += EnterDbEntryName();
|
var name = EnterDbEntryName();
|
||||||
|
if (String.IsNullOrEmpty(name))
|
||||||
|
return;
|
||||||
|
pwp.dbDisplayKey += name;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
pwp.StartRestoreTimer(milliSecond : 2000 /*wait mouse settle still for taskbar restore*/);
|
pwp.StartRestoreTimer(milliSecond : 2000 /*wait mouse settle still for taskbar restore*/);
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue