Key.cs 3.7 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238
  1. // Permission is hereby granted, free of charge, to any person obtaining
  2. // a copy of this software and associated documentation files (the
  3. // "Software"), to deal in the Software without restriction, including
  4. // without limitation the rights to use, copy, modify, merge, publish,
  5. // distribute, sublicense, and/or sell copies of the Software, and to
  6. // permit persons to whom the Software is furnished to do so, subject to
  7. // the following conditions:
  8. //
  9. // The above copyright notice and this permission notice shall be
  10. // included in all copies or substantial portions of the Software.
  11. //
  12. // THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
  13. // EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
  14. // MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
  15. // NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE
  16. // LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
  17. // OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION
  18. // WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
  19. //
  20. // Copyright (c) 2007 Novell, Inc. (http://www.novell.com)
  21. //
  22. // Authors:
  23. // Chris Toshok ([email protected])
  24. //
  25. using System;
  26. using System.ComponentModel;
  27. using System.Windows.Markup;
  28. namespace System.Windows.Input {
  29. [ValueSerializer (typeof (KeyValueSerializer))]
  30. [TypeConverter (typeof (KeyConverter))]
  31. public enum Key
  32. {
  33. None,
  34. Cancel,
  35. Back,
  36. Tab,
  37. LineFeed,
  38. Clear,
  39. Return,
  40. Enter = Return,
  41. Pause,
  42. CapsLock,
  43. Capital = CapsLock,
  44. HangulMode,
  45. KanaMode = HangulMode,
  46. JunjaMode,
  47. FinalMode,
  48. KanjiMode,
  49. HanjaMode = KanjiMode,
  50. Escape,
  51. ImeConvert,
  52. ImeNonConvert,
  53. ImeAccept,
  54. ImeModeChange,
  55. Space,
  56. PageUp,
  57. Prior = PageUp,
  58. PageDown,
  59. Next = PageDown,
  60. End,
  61. Home,
  62. Left,
  63. Up,
  64. Right,
  65. Down,
  66. Select,
  67. Print,
  68. Execute,
  69. PrintScreen,
  70. Snapshot = PrintScreen,
  71. Insert,
  72. Delete,
  73. Help,
  74. D0,
  75. D1,
  76. D2,
  77. D3,
  78. D4,
  79. D5,
  80. D6,
  81. D7,
  82. D8,
  83. D9,
  84. A,
  85. B,
  86. C,
  87. D,
  88. E,
  89. F,
  90. G,
  91. H,
  92. I,
  93. J,
  94. K,
  95. L,
  96. M,
  97. N,
  98. O,
  99. P,
  100. Q,
  101. R,
  102. S,
  103. T,
  104. U,
  105. V,
  106. W,
  107. X,
  108. Y,
  109. Z,
  110. LWin,
  111. RWin,
  112. Apps,
  113. Sleep,
  114. NumPad0,
  115. NumPad1,
  116. NumPad2,
  117. NumPad3,
  118. NumPad4,
  119. NumPad5,
  120. NumPad6,
  121. NumPad7,
  122. NumPad8,
  123. NumPad9,
  124. Multiply,
  125. Add,
  126. Separator,
  127. Subtract,
  128. Decimal,
  129. Divide,
  130. F1,
  131. F2,
  132. F3,
  133. F4,
  134. F5,
  135. F6,
  136. F7,
  137. F8,
  138. F9,
  139. F10,
  140. F11,
  141. F12,
  142. F13,
  143. F14,
  144. F15,
  145. F16,
  146. F17,
  147. F18,
  148. F19,
  149. F20,
  150. F21,
  151. F22,
  152. F23,
  153. F24,
  154. NumLock,
  155. Scroll,
  156. LeftShift,
  157. RightShift,
  158. LeftCtrl,
  159. RightCtrl,
  160. LeftAlt,
  161. RightAlt,
  162. BrowserBack,
  163. BrowserForward,
  164. BrowserRefresh,
  165. BrowserStop,
  166. BrowserSearch,
  167. BrowserFavorites,
  168. BrowserHome,
  169. VolumeMute,
  170. VolumeDown,
  171. VolumeUp,
  172. MediaNextTrack,
  173. MediaPreviousTrack,
  174. MediaStop,
  175. MediaPlayPause,
  176. LaunchMail,
  177. SelectMedia,
  178. LaunchApplication1,
  179. LaunchApplication2,
  180. Oem1,
  181. OemSemicolon = Oem1,
  182. OemPlus,
  183. OemComma,
  184. OemMinus,
  185. OemPeriod,
  186. Oem2,
  187. OemQuestion = Oem2,
  188. Oem3,
  189. OemTilde = Oem3,
  190. AbntC1,
  191. AbntC2,
  192. Oem4,
  193. OemOpenBrackets = Oem4,
  194. Oem5,
  195. OemPipe = Oem5,
  196. Oem6,
  197. OemCloseBrackets = Oem6,
  198. Oem7,
  199. OemQuotes = Oem7,
  200. Oem8,
  201. Oem102,
  202. OemBackslash = Oem102,
  203. ImeProcessed,
  204. System,
  205. OemAttn,
  206. DbeAlphanumeric = OemAttn,
  207. OemFinish,
  208. DbeKatakana = OemFinish,
  209. OemCopy,
  210. DbeHiragana = OemCopy,
  211. OemAuto,
  212. DbeSbcsChar = OemAuto,
  213. OemEnlw,
  214. DbeDbcsChar = OemEnlw,
  215. OemBackTab,
  216. DbeRoman = OemBackTab,
  217. Attn,
  218. DbeNoRoman = Attn,
  219. CrSel,
  220. DbeEnterWordRegisterMode = CrSel,
  221. ExSel,
  222. DbeEnterImeConfigureMode = ExSel,
  223. EraseEof,
  224. DbeFlushString = EraseEof,
  225. Play,
  226. DbeCodeInput = Play,
  227. Zoom,
  228. DbeNoCodeInput = Zoom,
  229. NoName,
  230. DbeDetermineString = NoName,
  231. Pa1,
  232. DbeEnterDialogConversionMode = Pa1,
  233. OemClear
  234. }
  235. }