Commit b12fc503 authored by Elen.Subbotina's avatar Elen.Subbotina Committed by Alexander Trofimov

(1.0.1.207): ASCOfficeOdfFile


git-svn-id: svn://fileserver/activex/AVS/Sources/TeamlabOffice/trunk/ServerComponents@57642 954022d7-b5bf-4e40-9824-e11837661b57
parent 02cae2f5
......@@ -2,6 +2,6 @@
//1
//0
//1
//206
#define INTVER 1,0,1,206
#define STRVER "1,0,1,206\0"
//207
#define INTVER 1,0,1,207
#define STRVER "1,0,1,207\0"
......@@ -29,10 +29,10 @@ mediaitems::item::item( std::wstring const & _href,
outputName(_outputName),
mediaInternal(_mediaInternal),
Id(_Id),
used_rels (false),
valid(true) // ""
{
count_add = 1;
count_used = 0;
}
std::wstring mediaitems::add_or_find(const std::wstring & href, Type type, bool & isInternal)
......@@ -72,12 +72,13 @@ std::wstring mediaitems::add_or_find(const std::wstring & href, Type type, bool
if ( type == typeChart)outputPath= outputPath + L".xml";
std::wstring id;
BOOST_FOREACH(item const & elm, items_)
BOOST_FOREACH(item & elm, items_)
{
if (elm.href == inputPath)
{
id = elm.Id;
outputPath = elm.outputName;
elm.count_add++;
break;
}
}
......@@ -117,15 +118,14 @@ void mediaitems::dump_rels(rels & Rels)
size_t i = 0;
BOOST_FOREACH(item & elm, items_)
{
if (elm.used_rels)continue; // ( ....)
if (elm.count_used > elm.count_add)continue; // ( ....)
Rels.add( relationship(
elm.Id,
utils::media::get_rel_type(elm.type),
elm.valid ? elm.outputName : L"NULL",
elm.mediaInternal ? L"" : L"External" )
);
elm.used_rels = true;
elm.count_used++;
}
}
......
......@@ -36,7 +36,8 @@ public:
bool mediaInternal;
bool valid;
std::wstring Id;
bool used_rels;
int count_used;
int count_add;
};
typedef std::vector< item > items_array;
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment