mirror of
https://github.com/SubtitleEdit/subtitleedit.git
synced 2024-11-22 03:02:35 +01:00
Video volume is now zero during video load in main form
git-svn-id: https://subtitleedit.googlecode.com/svn/trunk@273 99eadd0c-20b8-1223-b5c4-2a2b2df33de2
This commit is contained in:
parent
90d4cd3d80
commit
71f919deb2
@ -1067,8 +1067,7 @@ namespace Nikse.SubtitleEdit.Forms
|
||||
|
||||
if (!string.IsNullOrEmpty(videoFileName) && File.Exists(videoFileName))
|
||||
{
|
||||
OpenVideo(videoFileName);
|
||||
|
||||
OpenVideo(videoFileName);
|
||||
}
|
||||
else if (!string.IsNullOrEmpty(fileName) && (toolStripButtonToogleVideo.Checked || toolStripButtonToogleWaveForm.Checked))
|
||||
{
|
||||
@ -6184,7 +6183,6 @@ namespace Nikse.SubtitleEdit.Forms
|
||||
return false;
|
||||
}
|
||||
|
||||
|
||||
Encoding encoding;
|
||||
_subtitleAlternate = new Subtitle();
|
||||
_subtitleAlternateFileName = fileName;
|
||||
@ -6249,7 +6247,9 @@ namespace Nikse.SubtitleEdit.Forms
|
||||
VideoInfo videoInfo = ShowVideoInfo(fileName);
|
||||
toolStripComboBoxFrameRate.Text = videoInfo.FramesPerSecond.ToString();
|
||||
|
||||
|
||||
Utilities.InitializeVideoPlayerAndContainer(fileName, videoInfo, mediaPlayer, VideoLoaded, VideoEnded);
|
||||
mediaPlayer.Volume = 0;
|
||||
labelVideoInfo.Text = Path.GetFileName(fileName) + " " + videoInfo.Width + "x" + videoInfo.Height + " " + videoInfo.VideoCodec;
|
||||
|
||||
string peakWaveFileName = GetPeakWaveFileName(fileName);
|
||||
@ -6272,6 +6272,7 @@ namespace Nikse.SubtitleEdit.Forms
|
||||
void VideoLoaded(object sender, EventArgs e)
|
||||
{
|
||||
mediaPlayer.Stop();
|
||||
mediaPlayer.Volume = Configuration.Settings.General.VideoPlayerDefaultVolume;
|
||||
timer1.Start();
|
||||
|
||||
trackBarWaveFormPosition.Maximum = (int)mediaPlayer.Duration;
|
||||
|
Loading…
Reference in New Issue
Block a user