Team Fortress 2 Source Code as on 22/4/2020
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

47 lines
1.3 KiB

  1. //========= Copyright Valve Corporation, All rights reserved. ============//
  2. //
  3. // Purpose:
  4. //
  5. //=============================================================================
  6. #include "dme_controls/dmemdlpanel.h"
  7. #include "dme_controls/dmecontrols.h"
  8. #include "dme_controls/dmepanel.h"
  9. #include "movieobjects/dmemdl.h"
  10. #include "movieobjects/dmemdlmakefile.h"
  11. // memdbgon must be the last include file in a .cpp file!!!
  12. #include "tier0/memdbgon.h"
  13. using namespace vgui;
  14. IMPLEMENT_DMEPANEL_FACTORY( CDmeMDLPanel, DmeMDLMakefile, "DmeMakeFileOutputPreview", "MDL MakeFile Output Preview", false );
  15. //-----------------------------------------------------------------------------
  16. // Constructor, destructor
  17. //-----------------------------------------------------------------------------
  18. CDmeMDLPanel::CDmeMDLPanel( vgui::Panel *pParent, const char *pName ) : BaseClass( pParent, pName )
  19. {
  20. }
  21. CDmeMDLPanel::~CDmeMDLPanel()
  22. {
  23. }
  24. //-----------------------------------------------------------------------------
  25. // DMEPanel..
  26. //-----------------------------------------------------------------------------
  27. void CDmeMDLPanel::SetDmeElement( CDmeMDLMakefile *pMDLMakefile )
  28. {
  29. if ( pMDLMakefile != NULL )
  30. {
  31. CDmeMDL *pMDL = CastElement< CDmeMDL >( pMDLMakefile->GetOutputElement( true ) );
  32. if ( pMDL )
  33. {
  34. SetMDL( pMDL->GetMDL() );
  35. }
  36. }
  37. }