Rietveld Code Review Tool
Help | Bug tracker | Discussion group | Source code

Unified Diff: src/plugin/PluginClass.cpp

Issue 11427013: Appear fast for IE (Closed)
Patch Set: Created Aug. 7, 2013, 5:44 a.m.
Use n/p to move between diff chunks; N/P to move between comments.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « no previous file | src/plugin/PluginDomTraverserBase.h » ('j') | src/plugin/PluginDomTraverserBase.h » ('J')
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: src/plugin/PluginClass.cpp
===================================================================
--- a/src/plugin/PluginClass.cpp
+++ b/src/plugin/PluginClass.cpp
@@ -259,11 +259,8 @@
s_criticalSectionLocal.Lock();
{
- if (settings->GetPluginEnabled())
- {
- s_mimeFilter = CPluginClientFactory::GetMimeFilterClientInstance();
- }
-
+ // We always register on startup and then check if we should do that in a seperate thread
Felix Dahlke 2013/08/07 09:34:49 I didn't immediately get this, how about: // Alwa
+ s_mimeFilter = CPluginClientFactory::GetMimeFilterClientInstance();
s_asyncWebBrowser2 = unknownSite;
s_instances.Add(this);
}
@@ -732,9 +729,15 @@
bool CPluginClass::InitObject(bool bBHO)
{
+ CPluginSettings* settings = CPluginSettings::GetInstance();
+
+ // Unregister, if disabled
Felix Dahlke 2013/08/07 09:34:49 This comment is kinda redundant, I think.
+ if (!settings->GetPluginEnabled())
+ {
+ s_mimeFilter->Unregister();
+ }
+
// Load theme module
-
-
s_criticalSectionLocal.Lock();
{
if (!s_hUxtheme)
@@ -818,8 +821,6 @@
}
}
-
- CPluginSettings* settings = CPluginSettings::GetInstance();
return true;
}
« no previous file with comments | « no previous file | src/plugin/PluginDomTraverserBase.h » ('j') | src/plugin/PluginDomTraverserBase.h » ('J')

Powered by Google App Engine
This is Rietveld