return catman->AddCategoryEntry(JAVASCRIPT_GLOBAL_CONSTRUCTOR_CATEGORY, "Image", NS_HTMLIMGELEMENT_CONTRACTID,
nsresult rv = catman->AddCategoryEntry(JAVASCRIPT_GLOBAL_CONSTRUCTOR_CATEGORY, "Image", NS_HTMLIMGELEMENT_CONTRACTID, PR_TRUE, PR_TRUE, getter_Copies(previous)); NS_ENSURE_SUCCESS(rv, rv);  return catman->AddCategoryEntry(JAVASCRIPT_GLOBAL_CONSTRUCTOR_PROTO_ALIAS_CATEGORY, "Image", "HTMLImageElement",
RegisterHTMLImgElement(nsIComponentManager *aCompMgr,                       nsIFile* aPath,                       const char* aRegistryLocation,                       const char* aComponentType,                       const nsModuleComponentInfo* aInfo){  nsCOMPtr<nsICategoryManager> catman =    do_GetService(NS_CATEGORYMANAGER_CONTRACTID);  if (! catman)    return NS_ERROR_FAILURE;  nsXPIDLCString previous;  return catman->AddCategoryEntry(JAVASCRIPT_GLOBAL_CONSTRUCTOR_CATEGORY,                                  "Image", NS_HTMLIMGELEMENT_CONTRACTID,                                  PR_TRUE, PR_TRUE, getter_Copies(previous));}