ultimatepp/reference/HotKey/main.cpp
cxl d1b98bdc3f .reference
git-svn-id: svn://ultimatepp.org/upp/trunk@13921 f0d560ea-af0d-0410-9eb7-867de7ffcac7
2020-01-21 08:44:38 +00:00

13 lines
330 B
C++

#include <CtrlLib/CtrlLib.h>
using namespace Upp;
GUI_APP_MAIN
{
TopWindow win;
int id = Ctrl::RegisterSystemHotKey(K_CTRL|K_F1, [] { PromptOK("Ctrl+F1"); });
Ctrl::RegisterSystemHotKey(K_ALT|K_CTRL|K_SHIFT|K_A, [] { PromptOK("Ctrl+Alt+Shift+A"); });
win.Run();
Ctrl::UnregisterSystemHotKey(id);
win.Run();
}