Re-organised the plugin a bit.