コード例 #1
0
ファイル: unicode2keysym.cpp プロジェクト: bwilcox/pwsafe
KeySym unicode2keysym(wchar_t wc)
{
  static const keymap_t keymap = GetKeyMap();
  keymap_t::const_iterator itr = keymap.find(wc);
  if ( itr != keymap.end())
    return itr->second;
  return NoSymbol;
}
コード例 #2
0
ファイル: x11_loop.hpp プロジェクト: mstorsjo/vlc
 /// Translate X11 KeySyms to VLC key codes.
 static int keysymToVlcKey( KeySym keysym )
 {
     keymap_t::const_iterator i=m_keymap.find(keysym);
     return i!=m_keymap.end() ? (i->second) : keysym;
 }