add a callback to ComponentUpdateService::UnregisterComponent that executes customized operations on component removal.
Solution #1:
add a callback to ComponentUpdateService::UnregisterComponent that executes customized operations on component removal.
bool CrxUpdateService::UnregisterComponent(const std::string& id)
->
bool CrxUpdateService::UnregisterComponent(const std::string& id, base::Callback<void(bool)> callback)
|callback| is executed right before bool CrxUpdateService::DoUnregisterComponent(const CrxComponent& component) return.
Solution #2:
Solution #1:
add a callback to ComponentUpdateService::UnregisterComponent that executes customized operations on component removal.
bool CrxUpdateService::UnregisterComponent(const std::string& id)
->
bool CrxUpdateService::UnregisterComponent(const std::string& id, base::Callback<void(bool)> callback)
|callback| is executed right before bool CrxUpdateService::DoUnregisterComponent(const CrxComponent& component) return.
Solution #2:
add ComponentInstallerPolicy::OnCustomUninstall (to be implemented by all *_component_installer)
Call this function right before 'void ComponentInstaller::UninstallOnTaskRunner()' return.
Comment 1 by xiaochu@chromium.org
, Oct 31 2017