Welcome to mirror list, hosted at ThFree Co, Russian Federation.

github.com/mpc-hc/mpc-hc.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorv0lt <v0lt@rambler.ru>2012-08-31 17:02:10 +0400
committerv0lt <v0lt@rambler.ru>2012-08-31 17:02:10 +0400
commitd06fa1ea8f24aef96191572bd676743f9427d3eb (patch)
treef0fdb22ef1d1f8b9a2f7aa4e1d49403c27748f77 /src
parentdef82a0173d86e7c65538cda5e394138cfc9bb27 (diff)
updated scaling for setting windows of filters (1)
Diffstat (limited to 'src')
-rw-r--r--src/filters/parser/MpegSplitter/MpegSplitterSettingsWnd.cpp29
-rw-r--r--src/filters/renderer/MpcAudioRenderer/MpcAudioRendererSettingsWnd.cpp7
-rw-r--r--src/filters/transform/MPCVideoDec/MPCVideoDecSettingsWnd.cpp1
-rw-r--r--src/filters/transform/MpaDecFilter/MpaDecSettingsWnd.cpp21
-rw-r--r--src/filters/transform/Mpeg2DecFilter/Mpeg2DecSettingsWnd.cpp1
5 files changed, 37 insertions, 22 deletions
diff --git a/src/filters/parser/MpegSplitter/MpegSplitterSettingsWnd.cpp b/src/filters/parser/MpegSplitter/MpegSplitterSettingsWnd.cpp
index 1d4b67ad5..6e12fb83f 100644
--- a/src/filters/parser/MpegSplitter/MpegSplitterSettingsWnd.cpp
+++ b/src/filters/parser/MpegSplitter/MpegSplitterSettingsWnd.cpp
@@ -55,33 +55,38 @@ void CMpegSplitterSettingsWnd::OnDisconnect()
bool CMpegSplitterSettingsWnd::OnActivate()
{
+ ASSERT(IPP_FONTSIZE == 13);
+ const int h20 = IPP_SCALE(20);
+ const int h25 = IPP_SCALE(25);
+ const int h30 = IPP_SCALE(30);
+ const int& hgrp = h25;
DWORD dwStyle = WS_VISIBLE | WS_CHILD | WS_TABSTOP;
CPoint p(10, 10);
m_cbFastStreamChange.Create(ResStr(IDS_MPEGSPLITTER_FSTREAM_CHANGE), dwStyle | BS_AUTOCHECKBOX | BS_LEFTTEXT, CRect(p, CSize(IPP_SCALE(305), m_fontheight)), this, IDC_PP_FAST_STREAM_SELECT);
- p.y += m_fontheight + 5;
+ p.y += h20;
m_cbForcedSub.Create(ResStr(IDS_MPEGSPLITTER_SUB_FORCING), dwStyle | BS_AUTOCHECKBOX | BS_LEFTTEXT, CRect(p, CSize(IPP_SCALE(305), m_fontheight)), this, IDC_PP_SUBTITLE_FORCED);
- p.y += m_fontheight + 5;
+ p.y += h20;
m_cbTrackPriority.Create(ResStr(IDS_MPEGSPLITTER_TRACKS_ORDER), dwStyle | BS_AUTOCHECKBOX | BS_LEFTTEXT, CRect(p, CSize(IPP_SCALE(305), m_fontheight)), this, IDC_PP_TRACK_PRIORITY);
- p.y += m_fontheight + 5;
+ p.y += h20;
m_cbAlternativeDuration.Create(ResStr(IDS_MPEGSPLITTER_ALT_DUR_CALC), dwStyle | BS_AUTOCHECKBOX | BS_LEFTTEXT, CRect(p, CSize(IPP_SCALE(305), m_fontheight)), this, IDC_PP_ALTERNATIVE_DURATION);
- p.y += m_fontheight + 5;
+ p.y += h20;
m_txtAudioLanguageOrder.Create(ResStr(IDS_MPEGSPLITTER_LANG_ORDER), WS_VISIBLE | WS_CHILD, CRect(p, CSize(IPP_SCALE(200), m_fontheight)), this, (UINT)IDC_STATIC);
- p.y += m_fontheight + 5;
+ p.y += h20;
m_edtAudioLanguageOrder.CreateEx(WS_EX_CLIENTEDGE, _T("EDIT"), _T(""), WS_CHILD | WS_VISIBLE | WS_TABSTOP, CRect(p, CSize(IPP_SCALE(305), m_fontheight + 5)), this, IDC_PP_AUDIO_LANGUAGE_ORDER);
- p.y += m_fontheight + 10;
+ p.y += h25;
m_txtSubtitlesLanguageOrder.Create(ResStr(IDS_MPEGSPLITTER_SUB_ORDER), WS_VISIBLE | WS_CHILD, CRect(p, CSize(IPP_SCALE(200), m_fontheight)), this, (UINT)IDC_STATIC);
- p.y += m_fontheight + 5;
+ p.y += h20;
m_edtSubtitlesLanguageOrder.CreateEx(WS_EX_CLIENTEDGE, _T("EDIT"), _T(""), WS_CHILD | WS_VISIBLE | WS_TABSTOP, CRect(p, CSize(IPP_SCALE(305), m_fontheight + 5)), this, IDC_PP_SUBTITLES_LANGUAGE_ORDER);
- p.y += m_fontheight * 2;
+ p.y += h25;
m_txtVC1_GuidFlag.Create(ResStr(IDS_MPEGSPLITTER_VC1_GUIDFLAG), WS_VISIBLE | WS_CHILD, CRect(p, CSize(IPP_SCALE(200), m_fontheight)), this, (UINT)IDC_STATIC);
- p.y += m_fontheight + 5;
+ p.y += h20;
m_cbVC1_GuidFlag.Create(dwStyle | CBS_DROPDOWNLIST | WS_VSCROLL, CRect(p, CSize(IPP_SCALE(305), 200)), this, IDC_PP_VC1_GUIDFLAG);
m_cbVC1_GuidFlag.AddString(_T("Default"));
m_cbVC1_GuidFlag.AddString(_T("Cyberlink VC-1 Decoder"));
@@ -89,10 +94,10 @@ bool CMpegSplitterSettingsWnd::OnActivate()
SetClassLongPtr(GetDlgItem(IDC_PP_VC1_GUIDFLAG)->m_hWnd, GCLP_HCURSOR, (LONG_PTR)AfxGetApp()->LoadStandardCursor(IDC_HAND));
- p.y += m_fontheight * 2;
- m_grpTrueHD.Create(ResStr(IDS_MPEGSPLITTER_TRUEHD_OUTPUT), WS_VISIBLE | WS_CHILD | BS_GROUPBOX, CRect(p+ CPoint(-5, 0), CSize(IPP_SCALE(305), IPP_SCALE(40))), this, (UINT)IDC_STATIC);
+ p.y += h30;
+ m_grpTrueHD.Create(ResStr(IDS_MPEGSPLITTER_TRUEHD_OUTPUT), WS_VISIBLE | WS_CHILD | BS_GROUPBOX, CRect(p+ CPoint(-5, 0), CSize(IPP_SCALE(305), hgrp + h20)), this, (UINT)IDC_STATIC);
- p.y += m_fontheight + 5;
+ p.y += h20;
m_cbTrueHD.Create(_T("TrueHD"), dwStyle | BS_AUTORADIOBUTTON | BS_TOP | BS_MULTILINE | WS_GROUP, CRect(p, CSize(IPP_SCALE(95), m_fontheight + 5)), this, IDC_PP_TRUEHD);
m_cbAC3Core.Create(_T("AC-3 core"), dwStyle | BS_AUTORADIOBUTTON | BS_TOP | BS_MULTILINE, CRect(p + CPoint(IPP_SCALE(100), 0), CSize(IPP_SCALE(95), m_fontheight + 5)), this, IDC_PP_AC3CORE);
m_cbAsIs.Create(ResStr(IDS_MPEGSPLITTER_THD_NOSPLIT), dwStyle | BS_AUTORADIOBUTTON | BS_TOP | BS_MULTILINE, CRect(p + CPoint(IPP_SCALE(200), 0), CSize(IPP_SCALE(95), m_fontheight + 5)), this, IDC_PP_ASIS);
diff --git a/src/filters/renderer/MpcAudioRenderer/MpcAudioRendererSettingsWnd.cpp b/src/filters/renderer/MpcAudioRenderer/MpcAudioRendererSettingsWnd.cpp
index 8c0dfd48c..b42e42ef1 100644
--- a/src/filters/renderer/MpcAudioRenderer/MpcAudioRendererSettingsWnd.cpp
+++ b/src/filters/renderer/MpcAudioRenderer/MpcAudioRendererSettingsWnd.cpp
@@ -77,13 +77,16 @@ bool CALLBACK DSEnumProc(LPGUID lpGUID,
bool CMpcAudioRendererSettingsWnd::OnActivate()
{
+ ASSERT(IPP_FONTSIZE == 13);
DWORD dwStyle = WS_VISIBLE | WS_CHILD | WS_TABSTOP;
CPoint p(10, 10);
m_cbWasapiMode.Create(ResStr(IDS_ARS_WASAPI_MODE), dwStyle | BS_AUTOCHECKBOX | BS_LEFTTEXT, CRect(p, CSize(IPP_SCALE(300), m_fontheight)), this, IDC_PP_WASAPI_MODE);
- p.y += m_fontheight + 5;
+
+ p.y += IPP_SCALE(20);
m_cbMuteFastForward.Create(ResStr(IDS_ARS_MUTE_FAST_FORWARD), dwStyle | BS_AUTOCHECKBOX | BS_LEFTTEXT, CRect(p, CSize(IPP_SCALE(300), m_fontheight)), this, IDC_PP_MUTE_FAST_FORWARD);
- p.y += m_fontheight * 2;
+
+ p.y += IPP_SCALE(25);
m_txtSoundDevice.Create(ResStr(IDS_ARS_SOUND_DEVICE), WS_VISIBLE | WS_CHILD, CRect(p, CSize(IPP_SCALE(95), m_fontheight)), this, (UINT)IDC_STATIC);
m_cbSoundDevice.Create(dwStyle | CBS_DROPDOWNLIST | WS_VSCROLL, CRect(p + CPoint(IPP_SCALE(100), -4), CSize(IPP_SCALE(200), 200)), this, IDC_PP_SOUND_DEVICE);
diff --git a/src/filters/transform/MPCVideoDec/MPCVideoDecSettingsWnd.cpp b/src/filters/transform/MPCVideoDec/MPCVideoDecSettingsWnd.cpp
index b428207f7..5f232d63c 100644
--- a/src/filters/transform/MPCVideoDec/MPCVideoDecSettingsWnd.cpp
+++ b/src/filters/transform/MPCVideoDec/MPCVideoDecSettingsWnd.cpp
@@ -96,6 +96,7 @@ void CMPCVideoDecSettingsWnd::OnDisconnect()
bool CMPCVideoDecSettingsWnd::OnActivate()
{
+ ASSERT(IPP_FONTSIZE == 13);
DWORD dwStyle = WS_VISIBLE | WS_CHILD | WS_TABSTOP;
CPoint p(10, 10);
GUID* DxvaGui = NULL;
diff --git a/src/filters/transform/MpaDecFilter/MpaDecSettingsWnd.cpp b/src/filters/transform/MpaDecFilter/MpaDecSettingsWnd.cpp
index 268c44e08..9e3f2f132 100644
--- a/src/filters/transform/MpaDecFilter/MpaDecSettingsWnd.cpp
+++ b/src/filters/transform/MpaDecFilter/MpaDecSettingsWnd.cpp
@@ -68,9 +68,14 @@ void CMpaDecSettingsWnd::OnDisconnect()
bool CMpaDecSettingsWnd::OnActivate()
{
+ ASSERT(IPP_FONTSIZE == 13);
+ const int h20 = IPP_SCALE(20);
+ const int h25 = IPP_SCALE(25);
+ const int h30 = IPP_SCALE(30);
+ const int& hgrp = h25;
DWORD dwStyle = WS_VISIBLE | WS_CHILD | WS_TABSTOP;
- CRect r;
CPoint p(10, 10);
+ CRect r;
m_outputformat_static.Create(ResStr(IDS_MPADEC_SAMPLE_FMT), WS_VISIBLE | WS_CHILD, CRect(p, CSize(IPP_SCALE(120), m_fontheight)), this);
m_outputformat_combo.Create(dwStyle | CBS_DROPDOWNLIST, CRect(p + CPoint(IPP_SCALE(125), -4), CSize(IPP_SCALE(80), 200)), this, IDC_PP_COMBO1);
@@ -84,16 +89,16 @@ bool CMpaDecSettingsWnd::OnActivate()
m_outputformat_combo.SetCurSel(i);
}
}
- p.y += IPP_SCALE(25);
+ p.y += h25;
m_drc_check.Create(ResStr(IDS_MPADEC_DRC), dwStyle | BS_AUTOCHECKBOX, CRect(p, CSize(IPP_SCALE(205), m_fontheight)), this, IDC_PP_CHECK2);
m_drc_check.SetCheck(m_drc);
- p.y += IPP_SCALE(30);
+ p.y += h25;
- m_mixer_group.Create(_T(""), WS_VISIBLE | WS_CHILD | BS_GROUPBOX, CRect(p + CPoint(-5, 0), CSize(IPP_SCALE(215), IPP_SCALE(45))), this, (UINT)IDC_STATIC);
+ m_mixer_group.Create(_T(""), WS_VISIBLE | WS_CHILD | BS_GROUPBOX, CRect(p + CPoint(-5, 0), CSize(IPP_SCALE(215), hgrp + h20)), this, (UINT)IDC_STATIC);
m_mixer_check.Create(ResStr(IDS_MPADEC_MIXER), dwStyle | BS_AUTOCHECKBOX, CRect(p, CSize(IPP_SCALE(60), m_fontheight)), this, IDC_PP_CHECK1);
m_mixer_check.SetCheck(m_mixer);
- p.y += IPP_SCALE(20);
+ p.y += h20;
m_mixer_layout_static.Create(ResStr(IDS_MPADEC_MIX_SPEAKERS), WS_VISIBLE | WS_CHILD, CRect(p, CSize(IPP_SCALE(120), m_fontheight)), this);
m_mixer_layout_combo.Create(dwStyle | CBS_DROPDOWNLIST, CRect(p + CPoint(IPP_SCALE(125), -4), CSize(IPP_SCALE(80), 200)), this, IDC_PP_COMBO2);
m_mixer_layout_combo.SetItemData(m_mixer_layout_combo.AddString(ResStr(IDS_MPADEC_MONO)), SPK_MONO);
@@ -109,10 +114,10 @@ bool CMpaDecSettingsWnd::OnActivate()
}
m_mixer_layout_combo.GetWindowRect(r);
ScreenToClient(r);
- p.y += IPP_SCALE(35);
+ p.y += h30;
- m_spdif_group.Create(ResStr(IDS_MPADEC_SPDIF), WS_VISIBLE | WS_CHILD | BS_GROUPBOX, CRect(p + CPoint(-5, 0), CSize(IPP_SCALE(215), IPP_SCALE(40))), this, (UINT)IDC_STATIC);
- p.y += IPP_SCALE(20);
+ m_spdif_group.Create(ResStr(IDS_MPADEC_SPDIF), WS_VISIBLE | WS_CHILD | BS_GROUPBOX, CRect(p + CPoint(-5, 0), CSize(IPP_SCALE(215), hgrp + h20)), this, (UINT)IDC_STATIC);
+ p.y += h20;
m_spdif_ac3_check.Create(_T("AC-3"), dwStyle | BS_AUTOCHECKBOX, CRect(p, CSize(IPP_SCALE(45), m_fontheight)), this, IDC_PP_CHECK3);
m_spdif_ac3_check.SetCheck(m_spdif_ac3);
m_spdif_dts_check.Create(_T("DTS"), dwStyle | BS_AUTOCHECKBOX, CRect(p + CPoint(IPP_SCALE(50), 0), CSize(IPP_SCALE(45), m_fontheight)), this, IDC_PP_CHECK4);
diff --git a/src/filters/transform/Mpeg2DecFilter/Mpeg2DecSettingsWnd.cpp b/src/filters/transform/Mpeg2DecFilter/Mpeg2DecSettingsWnd.cpp
index bfa277754..f212a5f92 100644
--- a/src/filters/transform/Mpeg2DecFilter/Mpeg2DecSettingsWnd.cpp
+++ b/src/filters/transform/Mpeg2DecFilter/Mpeg2DecSettingsWnd.cpp
@@ -79,6 +79,7 @@ void CMpeg2DecSettingsWnd::OnDisconnect()
bool CMpeg2DecSettingsWnd::OnActivate()
{
+ ASSERT(IPP_FONTSIZE == 13);
DWORD dwStyle = WS_VISIBLE | WS_CHILD | WS_TABSTOP;
CPoint p(10, 10);