diff options
| author | Jørgen P. Tjernø <[email protected]> | 2013-12-02 19:31:46 -0800 |
|---|---|---|
| committer | Jørgen P. Tjernø <[email protected]> | 2013-12-02 19:46:31 -0800 |
| commit | f56bb35301836e56582a575a75864392a0177875 (patch) | |
| tree | de61ddd39de3e7df52759711950b4c288592f0dc /mp/src/public/tier3/tier3.h | |
| parent | Mark some more files as text. (diff) | |
| download | source-sdk-2013-f56bb35301836e56582a575a75864392a0177875.tar.xz source-sdk-2013-f56bb35301836e56582a575a75864392a0177875.zip | |
Fix line endings. WHAMMY.
Diffstat (limited to 'mp/src/public/tier3/tier3.h')
| -rw-r--r-- | mp/src/public/tier3/tier3.h | 228 |
1 files changed, 114 insertions, 114 deletions
diff --git a/mp/src/public/tier3/tier3.h b/mp/src/public/tier3/tier3.h index 537e617d..7f533531 100644 --- a/mp/src/public/tier3/tier3.h +++ b/mp/src/public/tier3/tier3.h @@ -1,114 +1,114 @@ -//========= Copyright Valve Corporation, All rights reserved. ============//
-//
-// Purpose: A higher level link library for general use in the game and tools.
-//
-//===========================================================================//
-
-
-#ifndef TIER3_H
-#define TIER3_H
-
-#if defined( _WIN32 )
-#pragma once
-#endif
-
-#include "tier2/tier2.h"
-
-
-//-----------------------------------------------------------------------------
-// Forward declarations
-//-----------------------------------------------------------------------------
-class IStudioRender;
-class IMatSystemSurface;
-class IDataCache;
-class IMDLCache;
-class IVideoServices;
-class IDmeMakefileUtils;
-class IPhysicsCollision;
-class ISoundEmitterSystemBase;
-class IVTex;
-
-namespace vgui
-{
- class ISurface;
- class IVGui;
- class IInput;
- class IPanel;
- class ILocalize;
- class ISchemeManager;
- class ISystem;
-}
-
-
-//-----------------------------------------------------------------------------
-// These tier3 libraries must be set by any users of this library.
-// They can be set by calling ConnectTier3Libraries.
-// It is hoped that setting this, and using this library will be the common mechanism for
-// allowing link libraries to access tier3 library interfaces
-//-----------------------------------------------------------------------------
-extern IStudioRender *g_pStudioRender;
-extern IStudioRender *studiorender;
-extern IMatSystemSurface *g_pMatSystemSurface;
-extern vgui::ISurface *g_pVGuiSurface;
-extern vgui::IInput *g_pVGuiInput;
-extern vgui::IVGui *g_pVGui;
-extern vgui::IPanel *g_pVGuiPanel;
-extern vgui::ILocalize *g_pVGuiLocalize;
-extern vgui::ISchemeManager *g_pVGuiSchemeManager;
-extern vgui::ISystem *g_pVGuiSystem;
-extern IDataCache *g_pDataCache; // FIXME: Should IDataCache be in tier2?
-extern IMDLCache *g_pMDLCache;
-extern IMDLCache *mdlcache;
-extern IVideoServices *g_pVideo;
-extern IDmeMakefileUtils *g_pDmeMakefileUtils;
-extern IPhysicsCollision *g_pPhysicsCollision;
-extern ISoundEmitterSystemBase *g_pSoundEmitterSystem;
-extern IVTex *g_pVTex;
-
-
-//-----------------------------------------------------------------------------
-// Call this to connect to/disconnect from all tier 3 libraries.
-// It's up to the caller to check the globals it cares about to see if ones are missing
-//-----------------------------------------------------------------------------
-void ConnectTier3Libraries( CreateInterfaceFn *pFactoryList, int nFactoryCount );
-void DisconnectTier3Libraries();
-
-
-//-----------------------------------------------------------------------------
-// Helper empty implementation of an IAppSystem for tier2 libraries
-//-----------------------------------------------------------------------------
-template< class IInterface, int ConVarFlag = 0 >
-class CTier3AppSystem : public CTier2AppSystem< IInterface, ConVarFlag >
-{
- typedef CTier2AppSystem< IInterface, ConVarFlag > BaseClass;
-
-public:
- CTier3AppSystem( bool bIsPrimaryAppSystem = true ) : BaseClass( bIsPrimaryAppSystem )
- {
- }
-
- virtual bool Connect( CreateInterfaceFn factory )
- {
- if ( !BaseClass::Connect( factory ) )
- return false;
-
- if ( BaseClass::IsPrimaryAppSystem() )
- {
- ConnectTier3Libraries( &factory, 1 );
- }
- return true;
- }
-
- virtual void Disconnect()
- {
- if ( BaseClass::IsPrimaryAppSystem() )
- {
- DisconnectTier3Libraries();
- }
- BaseClass::Disconnect();
- }
-};
-
-
-#endif // TIER3_H
-
+//========= Copyright Valve Corporation, All rights reserved. ============// +// +// Purpose: A higher level link library for general use in the game and tools. +// +//===========================================================================// + + +#ifndef TIER3_H +#define TIER3_H + +#if defined( _WIN32 ) +#pragma once +#endif + +#include "tier2/tier2.h" + + +//----------------------------------------------------------------------------- +// Forward declarations +//----------------------------------------------------------------------------- +class IStudioRender; +class IMatSystemSurface; +class IDataCache; +class IMDLCache; +class IVideoServices; +class IDmeMakefileUtils; +class IPhysicsCollision; +class ISoundEmitterSystemBase; +class IVTex; + +namespace vgui +{ + class ISurface; + class IVGui; + class IInput; + class IPanel; + class ILocalize; + class ISchemeManager; + class ISystem; +} + + +//----------------------------------------------------------------------------- +// These tier3 libraries must be set by any users of this library. +// They can be set by calling ConnectTier3Libraries. +// It is hoped that setting this, and using this library will be the common mechanism for +// allowing link libraries to access tier3 library interfaces +//----------------------------------------------------------------------------- +extern IStudioRender *g_pStudioRender; +extern IStudioRender *studiorender; +extern IMatSystemSurface *g_pMatSystemSurface; +extern vgui::ISurface *g_pVGuiSurface; +extern vgui::IInput *g_pVGuiInput; +extern vgui::IVGui *g_pVGui; +extern vgui::IPanel *g_pVGuiPanel; +extern vgui::ILocalize *g_pVGuiLocalize; +extern vgui::ISchemeManager *g_pVGuiSchemeManager; +extern vgui::ISystem *g_pVGuiSystem; +extern IDataCache *g_pDataCache; // FIXME: Should IDataCache be in tier2? +extern IMDLCache *g_pMDLCache; +extern IMDLCache *mdlcache; +extern IVideoServices *g_pVideo; +extern IDmeMakefileUtils *g_pDmeMakefileUtils; +extern IPhysicsCollision *g_pPhysicsCollision; +extern ISoundEmitterSystemBase *g_pSoundEmitterSystem; +extern IVTex *g_pVTex; + + +//----------------------------------------------------------------------------- +// Call this to connect to/disconnect from all tier 3 libraries. +// It's up to the caller to check the globals it cares about to see if ones are missing +//----------------------------------------------------------------------------- +void ConnectTier3Libraries( CreateInterfaceFn *pFactoryList, int nFactoryCount ); +void DisconnectTier3Libraries(); + + +//----------------------------------------------------------------------------- +// Helper empty implementation of an IAppSystem for tier2 libraries +//----------------------------------------------------------------------------- +template< class IInterface, int ConVarFlag = 0 > +class CTier3AppSystem : public CTier2AppSystem< IInterface, ConVarFlag > +{ + typedef CTier2AppSystem< IInterface, ConVarFlag > BaseClass; + +public: + CTier3AppSystem( bool bIsPrimaryAppSystem = true ) : BaseClass( bIsPrimaryAppSystem ) + { + } + + virtual bool Connect( CreateInterfaceFn factory ) + { + if ( !BaseClass::Connect( factory ) ) + return false; + + if ( BaseClass::IsPrimaryAppSystem() ) + { + ConnectTier3Libraries( &factory, 1 ); + } + return true; + } + + virtual void Disconnect() + { + if ( BaseClass::IsPrimaryAppSystem() ) + { + DisconnectTier3Libraries(); + } + BaseClass::Disconnect(); + } +}; + + +#endif // TIER3_H + |