示例#1
0
CAddIns::CAddIns()
{

    if (instances++ > 0) return;
    qDebug() << "PluginLoader created";
#if defined(Q_OS_WIN)
    QDir pluginsDir("../");
#elif defined(Q_OS_MAC)
    QDir pluginsDir("../../../");
#endif
    LoadAddIns(pluginsDir);
}
示例#2
0
CParentWnd::CParentWnd()
{
	// OutputDebugStringOutput only at first
	// Get any settings from the registry
	SetDefaults();
	ReadFromRegistry();
	// After this call we may output to the debug file
	OpenDebugFile();
	DebugPrintVersion(DBGVersionBanner);
	// Force the system riched20 so we don't load office's version.
	(void) LoadFromSystemDir(_T("riched20.dll")); // STRING_OK
	// Second part is to load rundll32.exe
	// Don't plan on unloading this, so don't care about the return value
	(void) LoadFromSystemDir(_T("rundll32.exe")); // STRING_OK

	// Load DLLS and get functions from them
	ImportProcs();

	// Initialize objects for theming
	InitializeGDI();

	m_cRef = 1;

	m_hwinEventHook = SetWinEventHook(
		EVENT_OBJECT_REORDER,
		EVENT_OBJECT_REORDER,
		NULL,
		&MyWinEventProc,
		GetCurrentProcessId(),
		NULL,
		NULL);

	ForceOutlookMAPI(0 != RegKeys[regkeyFORCEOUTLOOKMAPI].ulCurDWORD);
	ForceSystemMAPI(0 != RegKeys[regkeyFORCESYSTEMMAPI].ulCurDWORD);

	LoadAddIns();

	// Notice we never create a window here!
	TRACE_CONSTRUCTOR(CLASS);
} // CParentWnd::CParentWnd