Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix a video playback issue related to 'playvideo' #3

Merged
merged 2 commits into from
Dec 14, 2019
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
7 changes: 6 additions & 1 deletion sp/src/game/client/vgui_video.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,12 @@ VideoPanel::VideoPanel( unsigned int nXPos, unsigned int nYPos, unsigned int nHe
m_nPlaybackHeight( 0 ),
m_bAllowAlternateMedia( allowAlternateMedia )
{

#ifdef MAPBASE
vgui::VPANEL pParent = enginevgui->GetPanel( PANEL_ROOT );
#else
vgui::VPANEL pParent = enginevgui->GetPanel( PANEL_GAMEUIDLL );
#endif
SetParent( pParent );
SetVisible( false );

Expand Down Expand Up @@ -420,4 +425,4 @@ CON_COMMAND( playvideo_exitcommand, "Plays a video and fires and exit command wh
Warning( "Unable to play video: %s\n", strFullpath );
engine->ClientCmd( pExitCommand );
}
}
}