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
diff options
context:
space:
mode:
authorUnderground78 <underground78@users.sourceforge.net>2013-05-09 15:58:06 +0400
committerUnderground78 <underground78@users.sourceforge.net>2013-05-09 16:57:31 +0400
commit841850e767074c65c45ffca56939c297a77c1616 (patch)
tree42e06273191dc0b275787fed8f56ac9a0f28e3d0
parent2acb3c5749326e59f6f2c6f48692a32dc7e705f5 (diff)
Cosmetics: Use IsEmpty() instead of comparing with the empty string.
-rw-r--r--src/Subtitles/RealTextParser.cpp4
-rw-r--r--src/filters/renderer/VideoRenderers/DX9AllocatorPresenter.cpp6
-rw-r--r--src/mpc-hc/AppSettings.cpp6
-rw-r--r--src/mpc-hc/FGManager.cpp2
-rw-r--r--src/mpc-hc/MainFrm.cpp6
-rw-r--r--src/mpc-hc/PPageFileInfoClip.cpp2
-rw-r--r--src/mpc-hc/PPageFileInfoDetails.cpp2
-rw-r--r--src/mpc-hc/PPageFileMediaInfo.cpp2
-rw-r--r--src/mpc-hc/PPageOutput.cpp2
-rw-r--r--src/mpc-hc/SubtitleDlDlg.cpp6
-rw-r--r--src/mpc-hc/mplayerc.cpp6
11 files changed, 22 insertions, 22 deletions
diff --git a/src/Subtitles/RealTextParser.cpp b/src/Subtitles/RealTextParser.cpp
index 99ce59637..7d1d2c3d7 100644
--- a/src/Subtitles/RealTextParser.cpp
+++ b/src/Subtitles/RealTextParser.cpp
@@ -1,5 +1,5 @@
/*
- * (C) 2008-2012 see Authors.txt
+ * (C) 2008-2013 see Authors.txt
*
* This file is part of MPC-HC.
*
@@ -117,7 +117,7 @@ bool CRealTextParser::ParseRealText(wstring p_szFile)
m_RealText.m_bCenter = true;
} else if (oTag.m_szName == L"required") {
// Ignore
- } else if (oTag.m_szName == L"") {
+ } else if (oTag.m_szName.empty()) {
// Ignore
} else {
// assume formating tag (handled later)
diff --git a/src/filters/renderer/VideoRenderers/DX9AllocatorPresenter.cpp b/src/filters/renderer/VideoRenderers/DX9AllocatorPresenter.cpp
index 1be320e31..805202ed7 100644
--- a/src/filters/renderer/VideoRenderers/DX9AllocatorPresenter.cpp
+++ b/src/filters/renderer/VideoRenderers/DX9AllocatorPresenter.cpp
@@ -848,7 +848,7 @@ UINT CDX9AllocatorPresenter::GetAdapter(IDirect3D9* pD3D, bool bGetAdapter)
m_D3D9Device = _T("");
const CRenderersSettings& s = GetRenderersSettings();
- if (bGetAdapter && (pD3D->GetAdapterCount() > 1) && (s.D3D9RenderDevice != _T(""))) {
+ if (bGetAdapter && (pD3D->GetAdapterCount() > 1) && !s.D3D9RenderDevice.IsEmpty()) {
TCHAR strGUID[50];
D3DADAPTER_IDENTIFIER9 adapterIdentifier;
@@ -2006,13 +2006,13 @@ void CDX9AllocatorPresenter::DrawStats()
DrawText(rc, strText, 1);
OffsetRect(&rc, 0, TextHeight);
- if (m_D3D9Device != _T("")) {
+ if (!m_D3D9Device.IsEmpty()) {
strText = "Render device: " + m_D3D9Device;
DrawText(rc, strText, 1);
OffsetRect(&rc, 0, TextHeight);
}
- if (m_Decoder != _T("")) {
+ if (!m_Decoder.IsEmpty()) {
strText = "Decoder : " + m_Decoder;
DrawText(rc, strText, 1);
OffsetRect(&rc, 0, TextHeight);
diff --git a/src/mpc-hc/AppSettings.cpp b/src/mpc-hc/AppSettings.cpp
index 918b26e76..7677e84d3 100644
--- a/src/mpc-hc/AppSettings.cpp
+++ b/src/mpc-hc/AppSettings.cpp
@@ -495,7 +495,7 @@ bool CAppSettings::IsD3DFullscreen() const
CString CAppSettings::SelectedAudioRenderer() const
{
CString strResult;
- if (AfxGetMyApp()->m_AudioRendererDisplayName_CL != _T("")) {
+ if (!AfxGetMyApp()->m_AudioRendererDisplayName_CL.IsEmpty()) {
strResult = AfxGetMyApp()->m_AudioRendererDisplayName_CL;
} else {
strResult = AfxGetAppSettings().strAudioRendererDisplayName;
@@ -1127,8 +1127,8 @@ void CAppSettings::LoadSettings()
{
CString temp = pApp->GetProfileString(IDS_R_SETTINGS, IDS_RS_SPLOGFONT, _T(""));
subdefstyle <<= temp;
- if (temp == _T("")) {
- subdefstyle.relativeTo = 1; //default "Position subtitles relative to the video frame" option is checked
+ if (temp.IsEmpty()) {
+ subdefstyle.relativeTo = 1; // default "Position subtitles relative to the video frame" option is checked
}
}
fOverridePlacement = !!pApp->GetProfileInt(IDS_R_SETTINGS, IDS_RS_SPOVERRIDEPLACEMENT, FALSE);
diff --git a/src/mpc-hc/FGManager.cpp b/src/mpc-hc/FGManager.cpp
index 9b05ddec1..9685acc66 100644
--- a/src/mpc-hc/FGManager.cpp
+++ b/src/mpc-hc/FGManager.cpp
@@ -2638,7 +2638,7 @@ CFGManagerPlayer::CFGManagerPlayer(LPCTSTR pName, LPUNKNOWN pUnk, HWND hWnd)
pFGF = DEBUG_NEW CFGFilterInternal<CMpcAudioRenderer>(AUDRNDT_MPC, MERIT64_ABOVE_DSHOW + 2);
pFGF->AddType(MEDIATYPE_Audio, MEDIASUBTYPE_NULL);
m_transform.AddTail(pFGF);
- } else if (SelAudioRenderer != "") {
+ } else if (!SelAudioRenderer.IsEmpty()) {
pFGF = DEBUG_NEW CFGFilterRegistry(SelAudioRenderer, m_armerit);
pFGF->AddType(MEDIATYPE_Audio, MEDIASUBTYPE_NULL);
m_transform.AddTail(pFGF);
diff --git a/src/mpc-hc/MainFrm.cpp b/src/mpc-hc/MainFrm.cpp
index 9f21a2b0b..5d5db0d95 100644
--- a/src/mpc-hc/MainFrm.cpp
+++ b/src/mpc-hc/MainFrm.cpp
@@ -797,7 +797,7 @@ int CMainFrame::OnCreate(LPCREATESTRUCT lpCreateStruct)
int curPos = 0;
strRes = strList.Tokenize(_T("|"), curPos);
- while (strRes != _T("")) {
+ while (!strRes.IsEmpty()) {
m_shaderlabels.AddTail(strRes);
strRes = strList.Tokenize(_T("|"), curPos);
}
@@ -808,7 +808,7 @@ int CMainFrame::OnCreate(LPCREATESTRUCT lpCreateStruct)
int curPos = 0;
strRes = strList.Tokenize(_T("|"), curPos);
- while (strRes != _T("")) {
+ while (!strRes.IsEmpty()) {
m_shaderlabelsScreenSpace.AddTail(strRes);
strRes = strList.Tokenize(_T("|"), curPos);
}
@@ -11708,7 +11708,7 @@ bool CMainFrame::OpenMediaPrivate(CAutoPtr<OpenMediaData> pOMD)
mi_fn = pDVDData->path;
CPath path(mi_fn);
CString ext = path.GetExtension();
- if (ext == _T("")) {
+ if (ext.IsEmpty()) {
if (mi_fn.Right(10) == _T("\\VIDEO_TS\\")) {
mi_fn = mi_fn + _T("VTS_01_1.VOB");
} else {
diff --git a/src/mpc-hc/PPageFileInfoClip.cpp b/src/mpc-hc/PPageFileInfoClip.cpp
index 4e4a98fa9..8b6a7caee 100644
--- a/src/mpc-hc/PPageFileInfoClip.cpp
+++ b/src/mpc-hc/PPageFileInfoClip.cpp
@@ -97,7 +97,7 @@ BOOL CPPageFileInfoClip::OnInitDialog()
{
__super::OnInitDialog();
- if (m_fn == _T("")) {
+ if (m_fn.IsEmpty()) {
BeginEnumFilters(m_pFG, pEF, pBF) {
CComQIPtr<IFileSourceFilter> pFSF = pBF;
if (pFSF) {
diff --git a/src/mpc-hc/PPageFileInfoDetails.cpp b/src/mpc-hc/PPageFileInfoDetails.cpp
index dceefcd77..3ec5cda99 100644
--- a/src/mpc-hc/PPageFileInfoDetails.cpp
+++ b/src/mpc-hc/PPageFileInfoDetails.cpp
@@ -105,7 +105,7 @@ BOOL CPPageFileInfoDetails::OnInitDialog()
{
__super::OnInitDialog();
- if (m_fn == _T("")) {
+ if (m_fn.IsEmpty()) {
BeginEnumFilters(m_pFG, pEF, pBF) {
CComQIPtr<IFileSourceFilter> pFSF = pBF;
if (pFSF) {
diff --git a/src/mpc-hc/PPageFileMediaInfo.cpp b/src/mpc-hc/PPageFileMediaInfo.cpp
index b1284be4b..465dc971a 100644
--- a/src/mpc-hc/PPageFileMediaInfo.cpp
+++ b/src/mpc-hc/PPageFileMediaInfo.cpp
@@ -91,7 +91,7 @@ BOOL CPPageFileMediaInfo::OnInitDialog()
return TRUE;
}
- if (m_fn == _T("")) {
+ if (m_fn.IsEmpty()) {
BeginEnumFilters(m_pFG, pEF, pBF) {
CComQIPtr<IFileSourceFilter> pFSF = pBF;
if (pFSF) {
diff --git a/src/mpc-hc/PPageOutput.cpp b/src/mpc-hc/PPageOutput.cpp
index 4fb83183c..e18ff61af 100644
--- a/src/mpc-hc/PPageOutput.cpp
+++ b/src/mpc-hc/PPageOutput.cpp
@@ -236,7 +236,7 @@ BOOL CPPageOutput::OnInitDialog()
if (::StringFromGUID2(adapterIdentifier.DeviceIdentifier, strGUID, 50) > 0) {
cstrGUID = strGUID;
}
- if ((cstrGUID != _T(""))) {
+ if (!cstrGUID.IsEmpty()) {
boolean m_find = false;
for (INT_PTR i = 0; !m_find && (i < m_D3D9GUIDNames.GetCount()); i++) {
if (m_D3D9GUIDNames.GetAt(i) == cstrGUID) {
diff --git a/src/mpc-hc/SubtitleDlDlg.cpp b/src/mpc-hc/SubtitleDlDlg.cpp
index 6863cffff..e2fdd9c76 100644
--- a/src/mpc-hc/SubtitleDlDlg.cpp
+++ b/src/mpc-hc/SubtitleDlDlg.cpp
@@ -224,11 +224,11 @@ bool CSubtitleDlDlg::Parse()
sub.nick = value;
} else if (param == "email") {
sub.email = value;
- } else if (param == "" && value == "endsubtitle") {
+ } else if (param.IsEmpty() && value == "endsubtitle") {
m.subs.AddTail(sub);
- } else if (param == "" && value == "endmovie") {
+ } else if (param.IsEmpty() && value == "endmovie") {
m_pTA->raw_movies.AddTail(m);
- } else if (param == "" && value == "end") {
+ } else if (param.IsEmpty() && value == "end") {
break;
}
}
diff --git a/src/mpc-hc/mplayerc.cpp b/src/mpc-hc/mplayerc.cpp
index 28e68c330..8afc5badf 100644
--- a/src/mpc-hc/mplayerc.cpp
+++ b/src/mpc-hc/mplayerc.cpp
@@ -1809,7 +1809,7 @@ void GetCurDispMode(dispmode& dm, CString& DisplayName)
{
HDC hDC;
CString DisplayName1 = DisplayName;
- if ((DisplayName == _T("Current")) || (DisplayName == _T(""))) {
+ if ((DisplayName == _T("Current")) || DisplayName.IsEmpty()) {
CMonitor monitor;
CMonitors monitors;
monitor = monitors.GetNearestMonitor(AfxGetApp()->m_pMainWnd);
@@ -1830,7 +1830,7 @@ bool GetDispMode(int i, dispmode& dm, CString& DisplayName)
DEVMODE devmode;
CString DisplayName1 = DisplayName;
devmode.dmSize = sizeof(DEVMODE);
- if ((DisplayName == _T("Current")) || (DisplayName == _T(""))) {
+ if ((DisplayName == _T("Current")) || DisplayName.IsEmpty()) {
CMonitor monitor;
CMonitors monitors;
monitor = monitors.GetNearestMonitor(AfxGetApp()->m_pMainWnd);
@@ -1868,7 +1868,7 @@ void SetDispMode(const dispmode& dm, CString& DisplayName)
dmScreenSettings.dmDisplayFlags = dm.dmDisplayFlags;
dmScreenSettings.dmFields = DM_PELSWIDTH | DM_PELSHEIGHT | DM_BITSPERPEL | DM_DISPLAYFREQUENCY | DM_DISPLAYFLAGS;
CString DisplayName1 = DisplayName;
- if ((DisplayName == _T("Current")) || (DisplayName == _T(""))) {
+ if ((DisplayName == _T("Current")) || DisplayName.IsEmpty()) {
CMonitor monitor;
CMonitors monitors;
monitor = monitors.GetNearestMonitor(AfxGetApp()->m_pMainWnd);