5

I find ECB mode quite useful at times due to its souped up Speedbar and nice code browsing capabilities. Unfortunately, I also heavily rely on winner mode, which is incompatible with ECB. Even after I do M-x ecb-deactivate, all the ECB defuns appear loaded, and winner commands still throw an error about ECB/winner incompatibility. Is there a way to remove the ECB definitions so that winner works as before, short of restarting Emacs?

Luke Girvin
  • 13,221
  • 9
  • 64
  • 84
Leo Alekseyev
  • 12,893
  • 5
  • 44
  • 44
  • What's the error message? Which version of ECB are you using? – Luke Girvin Feb 22 '12 at 13:32
  • This is ECB 2.40 running on Emacs 24.0.93 The error is `let: ECB 2.40 - Error: Can't use winner-mode functions in the ecb-frame.` I should point out that it /is/ specified in the docs that winner-mode cannot be used with ECB. However, I would expect winner-mode functionality to be restored if I turn ECB off. – Leo Alekseyev Feb 22 '12 at 15:06

1 Answers1

8

The problem seems to be that ECB uses advice to display the error message ("Can't use winner-mode functions in the ecb-frame"), and this advice is not activated when ecb-deactivate is called.

I was able to work around this problem by disabling the advice in ecb-deactivate-hook:

(add-hook 'ecb-deactivate-hook 
      (lambda ()
         (ecb-disable-advices 'ecb-winman-not-supported-function-advices t)))

However, you should probably report this as a bug to the maintainers of ECB.

Stefan
  • 27,908
  • 4
  • 53
  • 82
Luke Girvin
  • 13,221
  • 9
  • 64
  • 84