Uninstalling a Plugin

I’m unsure how to uninstall a plugin. I’m writing a plugin that’s modifying the database and I want to clean up what I’ve done if the plugin is uninstalled. However, I can’t figure out what action triggers a plugin’s uninstall() method. Simply deactivating the plugin doesn’t seem to call this method. I can remove it from the “installed” list of plugins in the config file, but that only allows the install() function to be called again if I activate the plugin.

http://dev.piwik.org/trac/ticket/546

Thanks @vipsoft