From 6e527d6b95205999b5511631fe3009a020f01e37 Mon Sep 17 00:00:00 2001 From: "dougt%meer.net" Date: Fri, 9 Dec 2005 21:04:23 +0000 Subject: [PATCH] no more hacking loading required without nss --- minimo/base/Minimo.cpp | 54 ------------------------------------------ 1 file changed, 54 deletions(-) diff --git a/minimo/base/Minimo.cpp b/minimo/base/Minimo.cpp index 901e3831c8e..90402c3943e 100755 --- a/minimo/base/Minimo.cpp +++ b/minimo/base/Minimo.cpp @@ -496,53 +496,6 @@ void OverrideComponents() } } -/* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * - * - * Complete hack below. We to ensure that the layout of all - * of the shared libaries are at tightly packed as possible. - * We do this by explictly loading all of the modules we - * know about at compile time. This seams to work for our - * purposes. Ultimately, we should statically link all of - * these libraries. - * - * If you are building this to put on a ROM where XIP exists. - * - * For more information: - * 1) http://msdn.microsoft.com/library/default.asp?url=/ \ - library/en-us/dncenet/html/advmemmgmt.asp - * - * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * */ -#ifdef WINCE -#define HACKY_PRE_LOAD_LIBRARY 1 -#endif - -#ifdef HACKY_PRE_LOAD_LIBRARY -typedef struct _library -{ - const unsigned short* name; - HMODULE module; -} _library; - -_library Libraries[] = -{ - { L"nssckbi.dll", NULL }, - { NULL, NULL }, -}; - -void LoadKnownLibs() -{ - for (int i=0; Libraries[i].name; i++) - Libraries[i].module = LoadLibraryW(Libraries[i].name); -} - -void UnloadKnownLibs() -{ - for (int i=0; Libraries[i].name; i++) - if (Libraries[i].module) - FreeLibrary(Libraries[i].module); -} -#endif // HACKY_PRE_LOAD_LIBRARY - int main(int argc, char *argv[]) { #ifdef MOZ_WIDGET_GTK2 @@ -552,10 +505,6 @@ int main(int argc, char *argv[]) CreateSplashScreen(); -#ifdef HACKY_PRE_LOAD_LIBRARY - LoadKnownLibs(); -#endif - #ifdef _BUILD_STATIC_BIN NS_InitEmbedding(nsnull, nsnull, kPStaticModules, kStaticModuleCount); #else @@ -628,9 +577,6 @@ int main(int argc, char *argv[]) // Close down Embedding APIs NS_TermEmbedding(); -#ifdef HACKY_PRE_LOAD_LIBRARY - UnloadKnownLibs(); -#endif return NS_OK; }