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

github.com/kornelski/7z.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
Diffstat (limited to 'CPP/7zip/UI/Agent/ArchiveFolderOpen.cpp')
-rw-r--r--[-rwxr-xr-x]CPP/7zip/UI/Agent/ArchiveFolderOpen.cpp14
1 files changed, 7 insertions, 7 deletions
diff --git a/CPP/7zip/UI/Agent/ArchiveFolderOpen.cpp b/CPP/7zip/UI/Agent/ArchiveFolderOpen.cpp
index 3a16a667..13d94bdf 100755..100644
--- a/CPP/7zip/UI/Agent/ArchiveFolderOpen.cpp
+++ b/CPP/7zip/UI/Agent/ArchiveFolderOpen.cpp
@@ -15,8 +15,8 @@ void CArchiveFolderManager::LoadFormats()
int CArchiveFolderManager::FindFormat(const UString &type)
{
- for (int i = 0; i < _codecs->Formats.Size(); i++)
- if (type.CompareNoCase(_codecs->Formats[i].Name) == 0)
+ FOR_VECTOR (i, _codecs->Formats)
+ if (type.IsEqualToNoCase(_codecs->Formats[i].Name))
return i;
return -1;
}
@@ -60,11 +60,11 @@ STDMETHODIMP CArchiveFolderManager::GetExtensions(const wchar_t *type, BSTR *ext
static void AddIconExt(const CCodecIcons &lib, UString &dest)
{
- for (int j = 0; j < lib.IconPairs.Size(); j++)
+ FOR_VECTOR (i, lib.IconPairs)
{
if (!dest.IsEmpty())
dest += L' ';
- dest += lib.IconPairs[j].Ext;
+ dest += lib.IconPairs[i].Ext;
}
}
@@ -73,7 +73,7 @@ STDMETHODIMP CArchiveFolderManager::GetExtensions(BSTR *extensions)
LoadFormats();
*extensions = 0;
UString res;
- for (int i = 0; i < _codecs->Libs.Size(); i++)
+ FOR_VECTOR (i, _codecs->Libs)
AddIconExt(_codecs->Libs[i], res);
AddIconExt(_codecs->InternalIcons, res);
return StringToBstr(res, extensions);
@@ -84,7 +84,7 @@ STDMETHODIMP CArchiveFolderManager::GetIconPath(const wchar_t *ext, BSTR *iconPa
LoadFormats();
*iconPath = 0;
*iconIndex = 0;
- for (int i = 0; i < _codecs->Libs.Size(); i++)
+ FOR_VECTOR (i, _codecs->Libs)
{
const CCodecLib &lib = _codecs->Libs[i];
int ii;
@@ -112,7 +112,7 @@ STDMETHODIMP CArchiveFolderManager::GetTypes(BSTR *types)
{
LoadFormats();
UString typesStrings;
- for(int i = 0; i < _codecs.Formats.Size(); i++)
+ FOR_VECTOR(i, _codecs.Formats)
{
const CArcInfoEx &ai = _codecs.Formats[i];
if (ai.AssociateExts.Size() == 0)