| Index: src/plugin/PluginClass.cpp |
| =================================================================== |
| --- a/src/plugin/PluginClass.cpp |
| +++ b/src/plugin/PluginClass.cpp |
| @@ -47,8 +47,6 @@ |
| uint32_t iconHeight = 32; |
| uint32_t iconWidth = 32; |
| -CPluginMimeFilterClient* CPluginClass::s_mimeFilter = NULL; |
| - |
| CLOSETHEMEDATA pfnClose = NULL; |
| DRAWTHEMEBACKGROUND pfnDrawThemeBackground = NULL; |
| OPENTHEMEDATA pfnOpenThemeData = NULL; |
| @@ -244,7 +242,7 @@ |
| s_criticalSectionLocal.Lock(); |
| { |
| // Always register on startup, then check if we need to unregister in a separate thread |
| - s_mimeFilter = CPluginClientFactory::GetMimeFilterClientInstance(); |
| + CPluginClientFactory::GetMimeFilterClientInstance(); |
| s_asyncWebBrowser2 = unknownSite; |
| s_instances.insert(this); |
| } |
| @@ -511,11 +509,6 @@ |
| std::wstring url(urlVariant->bstrVal, SysStringLen(urlVariant->bstrVal)); |
| UnescapeUrl(url); |
| - //Register a mime filter if it's not registered yet |
|
Eric
2015/03/27 13:35:50
I'm assuming there was a reason to have this state
sergei
2015/04/01 18:49:32
It was indeed the issue here. We disable the plugi
|
| - if (s_mimeFilter == nullptr) |
| - { |
| - s_mimeFilter = CPluginClientFactory::GetMimeFilterClientInstance(); |
| - } |
| // If webbrowser2 is equal to top level browser (as set in SetSite), we are |
| // navigating new page |
| CPluginClient* client = CPluginClient::GetInstance(); |
| @@ -661,7 +654,7 @@ |
| if (!settings->GetPluginEnabled()) |
| { |
| - s_mimeFilter->Unregister(); |
| + CPluginClientFactory::ReleaseMimeFilterClientInstance(); |
|
Oleksandr
2015/03/27 08:02:29
This fixes the issue. Just calling Unregister() he
sergei
2015/04/01 18:49:32
No, it does not mean that our APP handlers remain
|
| } |
| // Load theme module |
| @@ -1120,12 +1113,10 @@ |
| { |
| if (settings->GetPluginEnabled()) |
| { |
| - s_mimeFilter = CPluginClientFactory::GetMimeFilterClientInstance(); |
| + CPluginClientFactory::GetMimeFilterClientInstance(); |
| } |
| else |
| { |
| - s_mimeFilter = NULL; |
| - |
| CPluginClientFactory::ReleaseMimeFilterClientInstance(); |
| } |
| } |