mirror of https://github.com/WerWolv/ImHex.git
fix: Diff view crash when closing provider that's being diffed
This commit is contained in:
parent
dacb64ae66
commit
a6eaa34f6d
|
@ -34,10 +34,16 @@ namespace hex::plugin::builtin {
|
||||||
this->m_upperCaseHex = static_cast<int>(upperCaseHex);
|
this->m_upperCaseHex = static_cast<int>(upperCaseHex);
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
|
|
||||||
|
EventManager::subscribe<EventProviderClosed>(this, [this](prv::Provider *) {
|
||||||
|
this->m_providerA = -1;
|
||||||
|
this->m_providerB = -1;
|
||||||
|
});
|
||||||
}
|
}
|
||||||
|
|
||||||
ViewDiff::~ViewDiff() {
|
ViewDiff::~ViewDiff() {
|
||||||
EventManager::unsubscribe<EventSettingsChanged>(this);
|
EventManager::unsubscribe<EventSettingsChanged>(this);
|
||||||
|
EventManager::unsubscribe<EventProviderClosed>(this);
|
||||||
}
|
}
|
||||||
|
|
||||||
static void drawProviderSelector(int &provider) {
|
static void drawProviderSelector(int &provider) {
|
||||||
|
|
Loading…
Reference in New Issue