Leaked source code of windows server 2003
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

254 lines
12 KiB

  1. #undef DEBUGGING
  2. #include <windows.h>
  3. #include <commctrl.h>
  4. #define VER_FILETYPE VFT_APP
  5. #define VER_FILESUBTYPE VFT2_UNKNOWN
  6. #define VER_FILEDESCRIPTION_STR "Windows GUI symbolic debugger"
  7. #define VER_INTERNALNAME_STR "windbg.exe\0"
  8. #define VER_ORIGINALFILENAME_STR "windbg.exe\0"
  9. #include <dbgver.h>
  10. #include "windbg.h"
  11. #include "dialogs.h"
  12. #include "menu.h"
  13. #include "dialogs.dlg"
  14. #include "resource.h"
  15. HELPCURSOR CURSOR "bitmaps/help.cur"
  16. WINDBGICON ICON "bitmaps/windbg.ico"
  17. DOCICON ICON "bitmaps/source.ico"
  18. CPUICON ICON "bitmaps/reg.ico"
  19. LOCALSICON ICON "bitmaps/local.ico"
  20. WATCHICON ICON "bitmaps/watch.ico"
  21. DISASMICON ICON "bitmaps/asm.ico"
  22. CMDICON ICON "bitmaps/ncmdwin.ico"
  23. SPADICON ICON "bitmaps/spad.ico"
  24. MEMORYICON ICON "bitmaps/memory.ico"
  25. CALLSTACKICON ICON "bitmaps/stack.ico"
  26. PROCTHREADICON ICON "bitmaps/procthrd.ico"
  27. //
  28. // Bitmaps for Windbg buttons.
  29. //
  30. IDB_BMP_TOOLBAR BITMAP "bitmaps/toolbar.bmp"
  31. MAIN_MENU MENU
  32. BEGIN
  33. POPUP "&File"
  34. BEGIN
  35. MENUITEM "&Open Source File...\tCtrl+O", IDM_FILE_OPEN
  36. MENUITEM "&Close Current Window\tCtrl+F4", IDM_FILE_CLOSE
  37. MENUITEM SEPARATOR
  38. MENUITEM "Open &Executable...\tCtrl+E", IDM_FILE_OPEN_EXECUTABLE
  39. MENUITEM "A&ttach to a Process...\tF6", IDM_FILE_ATTACH
  40. MENUITEM "Open Crash &Dump...\tCtrl+D", IDM_FILE_OPEN_CRASH_DUMP
  41. MENUITEM "Connect to &Remote Session...\tCtrl+R", IDM_FILE_CONNECT_TO_REMOTE
  42. MENUITEM "&Kernel Debug...\tCtrl+K", IDM_FILE_KERNEL_DEBUG
  43. MENUITEM SEPARATOR
  44. MENUITEM "&Symbol File Path ...\tCtrl+S", IDM_FILE_SYMBOL_PATH
  45. MENUITEM "Source File &Path ...\tCtrl+P", IDM_FILE_SOURCE_PATH
  46. MENUITEM "&Image File Path ...\tCtrl+I", IDM_FILE_IMAGE_PATH
  47. MENUITEM SEPARATOR
  48. MENUITEM "Open &Workspace...\tCtrl+W", IDM_FILE_OPEN_WORKSPACE
  49. MENUITEM "Save Workspace", IDM_FILE_SAVE_WORKSPACE
  50. MENUITEM "Save Workspace &As...", IDM_FILE_SAVE_WORKSPACE_AS
  51. MENUITEM "Clear Workspace...", IDM_FILE_CLEAR_WORKSPACE
  52. MENUITEM "Delete Workspaces...", IDM_FILE_DELETE_WORKSPACES
  53. MENUITEM "Open Workspace in File...", IDM_FILE_OPEN_WORKSPACE_FILE
  54. MENUITEM "Save Workspace to File...", IDM_FILE_SAVE_WORKSPACE_FILE
  55. MENUITEM SEPARATOR
  56. MENUITEM "Map Network Drive...", IDM_FILE_MAP_NET_DRIVE,
  57. MENUITEM "Disconnect Network Drive...", IDM_FILE_DISCONN_NET_DRIVE,
  58. MENUITEM SEPARATOR
  59. POPUP "Recent &Files"
  60. BEGIN
  61. MENUITEM "Recent File", IDM_FILE_MRU_FILE1, GRAYED
  62. END
  63. MENUITEM SEPARATOR
  64. MENUITEM "E&xit\aAlt+F4", IDM_FILE_EXIT
  65. END
  66. POPUP "&Edit"
  67. BEGIN
  68. MENUITEM "Cu&t\tCtrl+X", IDM_EDIT_CUT
  69. MENUITEM "&Copy\tCtrl+C", IDM_EDIT_COPY
  70. MENUITEM "&Paste\tCtrl+V", IDM_EDIT_PASTE
  71. MENUITEM "Select &All\tCtrl+A", IDM_EDIT_SELECT_ALL
  72. MENUITEM "&Write Window Text to File", IDM_EDIT_WRITE_TEXT_TO_FILE,
  73. MENUITEM "&Add to Command Output", IDM_EDIT_ADD_TO_COMMAND_HISTORY
  74. MENUITEM "Clear Command O&utput", IDM_EDIT_CLEAR_COMMAND_HISTORY
  75. MENUITEM SEPARATOR
  76. MENUITEM "&Find...\tCtrl+F", IDM_EDIT_FIND, GRAYED
  77. MENUITEM "Find &Next\tF3", IDM_EDIT_FIND_NEXT, GRAYED
  78. MENUITEM SEPARATOR
  79. MENUITEM "&Go to Address...\tCtrl+G", IDM_EDIT_GOTO_ADDRESS, GRAYED
  80. MENUITEM "Go to &Line...\tCtrl+L", IDM_EDIT_GOTO_LINE, GRAYED
  81. MENUITEM "Go to Current &Instruction...\tAlt+Keypad *", IDM_EDIT_GOTO_CURRENT_IP, GRAYED
  82. MENUITEM SEPARATOR
  83. MENUITEM "&Breakpoints...\tAlt+F9", IDM_EDIT_BREAKPOINTS
  84. MENUITEM "&Open/Close Log File...", IDM_EDIT_LOG_FILE
  85. MENUITEM SEPARATOR
  86. MENUITEM "&Properties...", IDM_EDIT_PROPERTIES, GRAYED
  87. END
  88. POPUP "&View"
  89. BEGIN
  90. MENUITEM "&Command\tAlt+1", IDM_VIEW_COMMAND
  91. MENUITEM "&Watch\tAlt+2", IDM_VIEW_WATCH
  92. MENUITEM "&Locals\tAlt+3", IDM_VIEW_LOCALS
  93. MENUITEM "&Registers\tAlt+4", IDM_VIEW_REGISTERS
  94. MENUITEM "&Memory\tAlt+5", IDM_VIEW_MEMORY
  95. MENUITEM "Call Stac&k\tAlt+6", IDM_VIEW_CALLSTACK
  96. MENUITEM "&Disassembly\tAlt+7", IDM_VIEW_DISASM
  97. MENUITEM "&Scratch Pad\tAlt+8", IDM_VIEW_SCRATCH
  98. MENUITEM "Processes and Threads\tAlt+9", IDM_VIEW_PROCESS_THREAD
  99. MENUITEM SEPARATOR
  100. MENUITEM "&Verbose Output\tCtrl+Alt+V", IDM_VIEW_TOGGLE_VERBOSE
  101. MENUITEM "Sho&w Version\tCtrl+Alt+W", IDM_VIEW_SHOW_VERSION
  102. MENUITEM SEPARATOR
  103. MENUITEM "Tool&bar", IDM_VIEW_TOOLBAR, CHECKED
  104. MENUITEM "&Status Bar", IDM_VIEW_STATUS, CHECKED
  105. MENUITEM SEPARATOR
  106. MENUITEM "Fo&nt...", IDM_VIEW_FONT
  107. MENUITEM "&Options...", IDM_VIEW_OPTIONS
  108. END
  109. POPUP "&Debug"
  110. BEGIN
  111. MENUITEM "&Go\tF5", IDM_DEBUG_GO
  112. MENUITEM "Go &Unhandled Exception", IDM_DEBUG_GO_UNHANDLED
  113. MENUITEM "Go &Handled Exception", IDM_DEBUG_GO_HANDLED
  114. MENUITEM "&Restart\tCtrl+Shift+F5", IDM_DEBUG_RESTART
  115. MENUITEM "Stop &Debugging\tShift+F5", IDM_DEBUG_STOPDEBUGGING
  116. MENUITEM "&Break\tCtrl+Break", IDM_DEBUG_BREAK
  117. MENUITEM SEPARATOR
  118. MENUITEM "Step &Into\tF11 or F8", IDM_DEBUG_STEPINTO
  119. MENUITEM "Step &Over\tF10", IDM_DEBUG_STEPOVER
  120. MENUITEM "Step Out\tShift+F11", IDM_DEBUG_STEPOUT
  121. MENUITEM "Run to &Cursor\tCtrl+F10 or F7", IDM_DEBUG_RUNTOCURSOR
  122. MENUITEM SEPARATOR
  123. MENUITEM "&Source Mode", IDM_DEBUG_SOURCE_MODE, CHECKED
  124. MENUITEM SEPARATOR
  125. MENUITEM "&Event Filters...", IDM_DEBUG_EVENT_FILTERS
  126. MENUITEM "&Modules...", IDM_DEBUG_MODULES
  127. MENUITEM SEPARATOR
  128. POPUP "&Kernel Connection"
  129. BEGIN
  130. MENUITEM "Cycle B&aud Rate\tCtrl+Alt+A", IDM_KDEBUG_TOGGLE_BAUDRATE
  131. MENUITEM "Cycle Initial Break\tCtrl+Alt+K", IDM_KDEBUG_TOGGLE_INITBREAK
  132. MENUITEM "Resynchronize\tCtrl+Alt+R", IDM_KDEBUG_RECONNECT
  133. END
  134. END
  135. POPUP "&Window"
  136. BEGIN
  137. MENUITEM "C&ascade", IDM_WINDOW_CASCADE
  138. MENUITEM "Tile &Horizontally", IDM_WINDOW_TILE_HORZ
  139. MENUITEM "Tile &Vertically", IDM_WINDOW_TILE_VERT
  140. MENUITEM "Arran&ge", IDM_WINDOW_ARRANGE
  141. MENUITEM "Arrange &Icons", IDM_WINDOW_ARRANGE_ICONS
  142. MENUITEM "Close All S&ource Windows", IDM_WINDOW_CLOSE_ALL_DOCWIN
  143. MENUITEM SEPARATOR
  144. MENUITEM "A&uto-arrange", IDM_WINDOW_AUTO_ARRANGE
  145. MENUITEM "A&rrange All Windows", IDM_WINDOW_ARRANGE_ALL
  146. MENUITEM "Overlay &Source", IDM_WINDOW_OVERLAY_SOURCE
  147. MENUITEM "Automatically Open &Disassembly", IDM_WINDOW_AUTO_DISASM
  148. END
  149. POPUP "&Help"
  150. BEGIN
  151. MENUITEM "&Contents", IDM_HELP_CONTENTS
  152. MENUITEM "&Index", IDM_HELP_INDEX
  153. MENUITEM "&Search", IDM_HELP_SEARCH
  154. MENUITEM SEPARATOR
  155. MENUITEM "&About...", IDM_HELP_ABOUT
  156. END
  157. END
  158. //
  159. // Default accelerators
  160. //
  161. MAIN_ACC ACCELERATORS
  162. BEGIN
  163. // File Menu
  164. "O", IDM_FILE_OPEN, VIRTKEY, CONTROL
  165. "E", IDM_FILE_OPEN_EXECUTABLE, VIRTKEY, CONTROL
  166. VK_F6, IDM_FILE_ATTACH, VIRTKEY
  167. "D", IDM_FILE_OPEN_CRASH_DUMP, VIRTKEY, CONTROL
  168. "K", IDM_FILE_KERNEL_DEBUG, VIRTKEY, CONTROL
  169. "P", IDM_FILE_SOURCE_PATH, VIRTKEY, CONTROL
  170. "S", IDM_FILE_SYMBOL_PATH, VIRTKEY, CONTROL
  171. "R", IDM_FILE_CONNECT_TO_REMOTE, VIRTKEY, CONTROL
  172. "I", IDM_FILE_IMAGE_PATH, VIRTKEY, CONTROL
  173. VK_F4, IDM_FILE_EXIT, VIRTKEY, ALT
  174. "W", IDM_FILE_OPEN_WORKSPACE, VIRTKEY, CONTROL
  175. // Edit Menu
  176. // CUA compliant & old style
  177. "X", IDM_EDIT_CUT, VIRTKEY, CONTROL
  178. VK_DELETE, IDM_EDIT_CUT, VIRTKEY, SHIFT
  179. "C", IDM_EDIT_COPY, VIRTKEY, CONTROL
  180. VK_INSERT, IDM_EDIT_COPY, VIRTKEY, CONTROL
  181. "V", IDM_EDIT_PASTE, VIRTKEY, CONTROL
  182. VK_INSERT, IDM_EDIT_PASTE, VIRTKEY, SHIFT
  183. "A", IDM_EDIT_SELECT_ALL, VIRTKEY, CONTROL
  184. "F", IDM_EDIT_FIND, VIRTKEY, CONTROL
  185. VK_F3, IDM_EDIT_FIND_NEXT, VIRTKEY
  186. VK_F3, IDM_EDIT_FIND_NEXT, VIRTKEY, SHIFT
  187. "G", IDM_EDIT_GOTO_ADDRESS, VIRTKEY, CONTROL
  188. "L", IDM_EDIT_GOTO_LINE, VIRTKEY, CONTROL
  189. VK_MULTIPLY,IDM_EDIT_GOTO_CURRENT_IP, VIRTKEY, ALT
  190. VK_F9, IDM_EDIT_BREAKPOINTS, VIRTKEY, ALT
  191. VK_F9, IDM_EDIT_TOGGLEBREAKPOINT, VIRTKEY
  192. // Debug Menu
  193. VK_F5, IDM_DEBUG_GO, VIRTKEY
  194. VK_F5, IDM_DEBUG_RESTART, VIRTKEY, SHIFT, CONTROL
  195. VK_F5, IDM_DEBUG_STOPDEBUGGING, VIRTKEY, SHIFT
  196. VK_CANCEL, IDM_DEBUG_BREAK, VIRTKEY, CONTROL
  197. // Old Key
  198. VK_F7, IDM_DEBUG_RUNTOCURSOR, VIRTKEY
  199. // New Key
  200. VK_F10, IDM_DEBUG_RUNTOCURSOR, VIRTKEY, CONTROL
  201. // Old key
  202. VK_F8, IDM_DEBUG_STEPINTO, VIRTKEY
  203. // New key
  204. VK_F11, IDM_DEBUG_STEPINTO, VIRTKEY
  205. VK_F10, IDM_DEBUG_STEPOVER, VIRTKEY
  206. VK_F11, IDM_DEBUG_STEPOUT, VIRTKEY, SHIFT
  207. "A", IDM_KDEBUG_TOGGLE_BAUDRATE, VIRTKEY, CONTROL, ALT
  208. "D", IDM_KDEBUG_TOGGLE_DEBUG, VIRTKEY, CONTROL, ALT
  209. "K", IDM_KDEBUG_TOGGLE_INITBREAK,VIRTKEY, CONTROL, ALT
  210. "R", IDM_KDEBUG_RECONNECT, VIRTKEY, CONTROL, ALT
  211. "V", IDM_VIEW_TOGGLE_VERBOSE, VIRTKEY, CONTROL, ALT
  212. "W", IDM_VIEW_SHOW_VERSION, VIRTKEY, CONTROL, ALT
  213. "1", IDM_VIEW_COMMAND, VIRTKEY, ALT
  214. "2", IDM_VIEW_WATCH, VIRTKEY, ALT
  215. "3", IDM_VIEW_LOCALS, VIRTKEY, ALT
  216. "4", IDM_VIEW_REGISTERS, VIRTKEY, ALT
  217. "5", IDM_VIEW_MEMORY, VIRTKEY, ALT
  218. "6", IDM_VIEW_CALLSTACK, VIRTKEY, ALT
  219. "7", IDM_VIEW_DISASM, VIRTKEY, ALT
  220. "8", IDM_VIEW_SCRATCH, VIRTKEY, ALT
  221. "9", IDM_VIEW_PROCESS_THREAD, VIRTKEY, ALT
  222. "1", IDM_VIEW_COMMAND, VIRTKEY, ALT, SHIFT
  223. "2", IDM_VIEW_WATCH, VIRTKEY, ALT, SHIFT
  224. "3", IDM_VIEW_LOCALS, VIRTKEY, ALT, SHIFT
  225. "4", IDM_VIEW_REGISTERS, VIRTKEY, ALT, SHIFT
  226. "5", IDM_VIEW_MEMORY, VIRTKEY, ALT, SHIFT
  227. "6", IDM_VIEW_CALLSTACK, VIRTKEY, ALT, SHIFT
  228. "7", IDM_VIEW_DISASM, VIRTKEY, ALT, SHIFT
  229. "8", IDM_VIEW_SCRATCH, VIRTKEY, ALT, SHIFT
  230. "9", IDM_VIEW_PROCESS_THREAD, VIRTKEY, ALT, SHIFT
  231. END
  232. // Define the string table
  233. #include <res_str.i>