Main parts of plugin done.