diff options
| author | FluorescentCIAAfricanAmerican <[email protected]> | 2020-04-22 12:56:21 -0400 |
|---|---|---|
| committer | FluorescentCIAAfricanAmerican <[email protected]> | 2020-04-22 12:56:21 -0400 |
| commit | 3bf9df6b2785fa6d951086978a3e66f49427166a (patch) | |
| tree | 2c0f1f0c63c4832882bc93814ebd2c2b1c6224e5 /utils/mdmpRipper/CMDDetailPanel.cpp | |
| download | archived-source-engine-2018-hl2-src-master.tar.xz archived-source-engine-2018-hl2-src-master.zip | |
Diffstat (limited to 'utils/mdmpRipper/CMDDetailPanel.cpp')
| -rw-r--r-- | utils/mdmpRipper/CMDDetailPanel.cpp | 40 |
1 files changed, 40 insertions, 0 deletions
diff --git a/utils/mdmpRipper/CMDDetailPanel.cpp b/utils/mdmpRipper/CMDDetailPanel.cpp new file mode 100644 index 0000000..b76a290 --- /dev/null +++ b/utils/mdmpRipper/CMDDetailPanel.cpp @@ -0,0 +1,40 @@ +//========= Copyright Valve Corporation, All rights reserved. ============// +#include "vgui_controls/HTML.h" +#include "CMDDetailPanel.h" + +using namespace vgui; + +CMDDetailPanel::CMDDetailPanel( vgui::Panel *pParent, const char *pName ) : + BaseClass( pParent, pName, true ) +{ + SetParent( pParent ); + m_pDetailWindow = new vgui::HTML(this, "Details"); + m_pDetailWindow->SetParent( this ); + m_pDetailWindow->SetSize( 770, 475 ); + LoadControlSettings( "MDDetailPanel.res" ); + m_pDetailWindow->OpenURL( "about:blank" ); +} + +void CMDDetailPanel::OpenURL( const char *url ) +{ + m_pDetailWindow->OpenURL( "about:blank" ); + m_pDetailWindow->OpenURL( url ); + m_pDetailWindow->SetVisible( true ); +} + + +void CMDDetailPanel::OnCommand( const char *pCommand ) +{ + if ( !Q_strcmp( pCommand, "Close" ) ) + { + Close(); + } +} + +void CMDDetailPanel::Close() +{ + m_pDetailWindow->SetVisible( false ); + SetVisible( false ); + KeyValues *kv = new KeyValues( "Refresh" ); + this->PostActionSignal( kv ); +} |