 
 (defun erl-refactor-version()
   (interactive)
-  (message "Wrangler version 0.6.1"))
- 
-
+  (message "Wrangler version 0.6.2"))
+
+
+(defun add-wrangler-menu()
+  (define-key erlang-extended-mode-map "\C-c\C-_"  'erl-refactor-undo)
+  (define-key erlang-extended-mode-map  "\C-c\C-b" 'erl-wrangler-code-inspector-var-instances)
+  (setq erlang-menu-items
+	(erlang-menu-add-below 'refactor-menu-items
+			       'distel-menu-items
+			       erlang-menu-items))
+  (erlang-menu-init)
+  )
+
+(defun remove-wrangler-menu()
+  (define-key erlang-extended-mode-map "\C-c\C-_" nil)
+  (define-key erlang-extended-mode-map "\C-c\C-b" nil)
+  (setq erlang-menu-items 
+	(erlang-menu-delete 'refactor-menu-items erlang-menu-items))
+  (erlang-menu-init)
+  )
+
+
+

  ;;     :type '(repeat directory)
  ;;     :group 'erlang-refac)

  
(defvar refactor-menu-items
  '(nil
    ("Wrangler Code Inspector"

    ("\M-?"      erl-complete)	; Some windowmanagers hijack M-TAB..
    ("\C-c\C-de" erl-ie-show-session)
    ("\C-c\C-df" erl-refactor-subfunction)
    ("\C-c\C-dF" erl-find-module)
    ("\C-c\C-dg" erl-ping)
    ("\C-c\C-dh" erl-find-doc-under-point)
