Release v0.4.0: add screen capture and annotation editor
This commit is contained in:
+11
-1
@@ -17,7 +17,8 @@ std::vector<std::pair<int, std::wstring>> shortcuts(const Settings &s)
|
||||
{Case, s.casing},
|
||||
{Translit, s.translit},
|
||||
{Undo, s.undo},
|
||||
{ShowHistory, s.clipboard}};
|
||||
{ShowHistory, s.clipboard},
|
||||
{Screenshot, s.screenshot}};
|
||||
for (size_t i = 0; i < s.direct.size(); ++i)
|
||||
out.emplace_back(Direct + (int)i, s.direct[i]);
|
||||
return out;
|
||||
@@ -586,6 +587,11 @@ void App::dispatch(int command)
|
||||
return;
|
||||
try
|
||||
{
|
||||
if (command == Screenshot)
|
||||
{
|
||||
if (!busy) showScreenshot(*this);
|
||||
return;
|
||||
}
|
||||
if (command == ShowHistory)
|
||||
{
|
||||
showHistory(*this);
|
||||
@@ -1096,6 +1102,7 @@ void App::trayMenu()
|
||||
{
|
||||
HMENU menu = CreatePopupMenu();
|
||||
AppendMenuW(menu, MF_STRING, 10, L"Clipboard history");
|
||||
AppendMenuW(menu, MF_STRING, 24, L"Capture screen region…");
|
||||
AppendMenuW(menu, MF_STRING, 11, L"Settings…");
|
||||
SetMenuDefaultItem(menu, 11, FALSE);
|
||||
AppendMenuW(menu, MF_STRING, 12, L"Snippets…");
|
||||
@@ -1127,6 +1134,9 @@ void App::trayMenu()
|
||||
{
|
||||
switch (cmd)
|
||||
{
|
||||
case 24:
|
||||
dispatch(Screenshot);
|
||||
break;
|
||||
case 10:
|
||||
showHistory(*this);
|
||||
break;
|
||||
|
||||
Reference in New Issue
Block a user