Is it possible to extend an asset editor window?

I hope I am using the right term there. When you double click an asset in the content browser, an editor window opens up for that asset.

What I need to do is extend the editor window for Texture assets in two ways:

  1. Get a hook when the editor window is opened so I can run some code
  2. Add new controls to the editor window (Buttons to execute some actions)