Back to index

lightning-sunbird  0.9+nobinonly
Defines | Functions | Variables
nsSpatialNavigationService.cpp File Reference
#include "nsSpatialNavigationPrivate.h"

Go to the source code of this file.

Defines

#define SpatialNavigation_CID
#define SpatialNavigation_ContractID   "@mozilla.org/spatialNavigation/service;1"
#define SpatialNavigationService_CID
#define SpatialNavigationService_ContractID   "@mozilla.org/spatialnavigation/service"

Functions

static NS_METHOD SpatialNavigationServiceRegistration (nsIComponentManager *aCompMgr, nsIFile *aPath, const char *registryLocation, const char *componentType, const nsModuleComponentInfo *info)
static NS_METHOD SpatialNavigationServiceUnregistration (nsIComponentManager *aCompMgr, nsIFile *aPath, const char *registryLocation, const nsModuleComponentInfo *info)

Variables

static const nsModuleComponentInfo components []

Define Documentation

Value:
{ 0xd1b91385, 0xe1c1, 0x46ec, \
{0x8d, 0x15, 0x88, 0x0c, 0x45, 0xbe, 0x8e, 0x0e} }

Definition at line 177 of file nsSpatialNavigationService.cpp.

#define SpatialNavigation_ContractID   "@mozilla.org/spatialNavigation/service;1"

Definition at line 181 of file nsSpatialNavigationService.cpp.

Value:
{ 0x4125624b, 0xaf22, 0x4d50, \
{ 0x87, 0xf6, 0x40, 0x19, 0xc9, 0x85, 0x7b, 0x58} }

Definition at line 183 of file nsSpatialNavigationService.cpp.

#define SpatialNavigationService_ContractID   "@mozilla.org/spatialnavigation/service"

Definition at line 187 of file nsSpatialNavigationService.cpp.


Function Documentation

static NS_METHOD SpatialNavigationServiceRegistration ( nsIComponentManager aCompMgr,
nsIFile aPath,
const char *  registryLocation,
const char *  componentType,
const nsModuleComponentInfo info 
) [static]

Definition at line 189 of file nsSpatialNavigationService.cpp.

{
  nsresult rv;
  
  nsCOMPtr<nsIServiceManager> servman = do_QueryInterface((nsISupports*)aCompMgr, &rv);
  if (NS_FAILED(rv))
    return rv;
  
  
  nsCOMPtr<nsICategoryManager> catman;
  servman->GetServiceByContractID(NS_CATEGORYMANAGER_CONTRACTID, 
                                  NS_GET_IID(nsICategoryManager), 
                                  getter_AddRefs(catman));
  
  if (NS_FAILED(rv))
    return rv;
  
  char* previous = nsnull;
  rv = catman->AddCategoryEntry("app-startup",
                                "SpatialNavigationService", 
                                SpatialNavigationService_ContractID,
                                PR_TRUE, 
                                PR_TRUE, 
                                &previous);
  if (previous)
    nsMemory::Free(previous);
  
  return rv;
}

Here is the call graph for this function:

static NS_METHOD SpatialNavigationServiceUnregistration ( nsIComponentManager aCompMgr,
nsIFile aPath,
const char *  registryLocation,
const nsModuleComponentInfo info 
) [static]

Definition at line 223 of file nsSpatialNavigationService.cpp.

{
  nsresult rv;
  
  nsCOMPtr<nsIServiceManager> servman = do_QueryInterface((nsISupports*)aCompMgr, &rv);
  if (NS_FAILED(rv))
    return rv;
  
  nsCOMPtr<nsICategoryManager> catman;
  servman->GetServiceByContractID(NS_CATEGORYMANAGER_CONTRACTID, 
                                  NS_GET_IID(nsICategoryManager), 
                                  getter_AddRefs(catman));
  
  if (NS_FAILED(rv))
    return rv;
  
  rv = catman->DeleteCategoryEntry("app-startup",
                                   "SpatialNavigationService", 
                                   PR_TRUE);
  
  return rv;
}

Here is the call graph for this function:


Variable Documentation

Initial value:

Definition at line 254 of file nsSpatialNavigationService.cpp.