now winix is using 'pikotools' (confparser, utf8, mainparser)

git-svn-id: svn://ttmath.org/publicrep/winix/trunk@792 e52654a7-88a9-db11-a3e9-0013d4bc506e
This commit is contained in:
2012-01-12 02:24:08 +00:00
parent cb33f20a24
commit b2d3ca9543
55 changed files with 1749 additions and 1884 deletions

View File

@@ -1,11 +1,10 @@
# DO NOT DELETE
groupinfo.o: groupinfo.h groups.h ../../core/confparser.h ../../core/item.h
groupinfo.o: ../../core/confparser.h ../../core/system.h ../../core/dirs.h
groupinfo.o: ../../core/item.h ../../core/dircontainer.h ../../db/db.h
groupinfo.o: ../../db/dbbase.h ../../db/dbconn.h ../../db/dbtextstream.h
groupinfo.o: ../../core/textstream.h ../../core/misc.h
groupinfo.o: ../../core/requesttypes.h ../../core/error.h
groupinfo.o: groupinfo.h groups.h ../../core/item.h ../../core/system.h
groupinfo.o: ../../core/dirs.h ../../core/item.h ../../core/dircontainer.h
groupinfo.o: ../../db/db.h ../../db/dbbase.h ../../db/dbconn.h
groupinfo.o: ../../db/dbtextstream.h ../../core/textstream.h
groupinfo.o: ../../core/misc.h ../../core/requesttypes.h ../../core/error.h
groupinfo.o: ../../db/dbitemquery.h ../../db/dbitemcolumns.h
groupinfo.o: ../../core/user.h ../../core/group.h ../../core/dircontainer.h
groupinfo.o: ../../core/ugcontainer.h ../../core/log.h
@@ -18,37 +17,36 @@ groupinfo.o: ../../core/mount.h ../../templates/locale.h
groupinfo.o: ../../notify/notify.h ../../notify/notifypool.h
groupinfo.o: ../../templates/patterns.h ../../templates/locale.h
groupinfo.o: ../../templates/localefilter.h ../../../ezc/src/ezc.h
groupinfo.o: ../../../ezc/src/utf8.h ../../../ezc/src/generator.h
groupinfo.o: ../../../ezc/src/pattern.h ../../../ezc/src/functions.h
groupinfo.o: ../../../ezc/src/funinfo.h ../../../ezc/src/stringconv.h
groupinfo.o: ../../notify/notifythread.h ../../core/basethread.h
groupinfo.o: ../../core/synchro.h ../../notify/templatesnotify.h
groupinfo.o: ../../core/config.h ../../core/users.h ../../core/ugcontainer.h
groupinfo.o: ../../../ezc/src/generator.h ../../../ezc/src/pattern.h
groupinfo.o: ../../../ezc/src/functions.h ../../../ezc/src/funinfo.h
groupinfo.o: ../../../ezc/src/stringconv.h ../../notify/notifythread.h
groupinfo.o: ../../core/basethread.h ../../core/synchro.h
groupinfo.o: ../../notify/templatesnotify.h ../../core/config.h
groupinfo.o: ../../core/users.h ../../core/ugcontainer.h
groupinfo.o: ../../core/lastcontainer.h ../../templates/misc.h
groupinfo.o: ../../templates/htmltextstream.h ../../core/mounts.h
groupinfo.o: ../../core/mountparser.h ../../core/crypt.h ../../core/run.h
groupinfo.o: ../../core/users.h ../../core/loadavg.h ../../core/image.h
groupinfo.o: ../../core/basethread.h ../../core/threadmanager.h
groupinfo.o: ../../core/log.h
groups.o: groups.h ../../core/confparser.h ../../core/log.h
groups.o: groups.h ../../core/log.h
init.o: ../../core/log.h ../../core/plugin.h ../../core/pluginmsg.h
init.o: ../../core/log.h ../../core/textstream.h ../../core/logmanipulators.h
init.o: ../../core/slog.h ../../core/cur.h ../../core/request.h
init.o: ../../core/requesttypes.h ../../core/item.h ../../core/error.h
init.o: ../../core/config.h ../../core/confparser.h ../../core/htmlfilter.h
init.o: ../../core/config.h ../../core/htmlfilter.h
init.o: ../../templates/htmltextstream.h ../../core/textstream.h
init.o: ../../core/misc.h ../../core/session.h ../../core/user.h
init.o: ../../core/plugindata.h ../../core/rebus.h ../../core/mount.h
init.o: ../../templates/locale.h ../../core/confparser.h ../../core/system.h
init.o: ../../core/dirs.h ../../core/dircontainer.h ../../db/db.h
init.o: ../../db/dbbase.h ../../db/dbconn.h ../../db/dbtextstream.h
init.o: ../../core/error.h ../../db/dbitemquery.h ../../core/item.h
init.o: ../../db/dbitemcolumns.h ../../core/user.h ../../core/group.h
init.o: ../../core/dircontainer.h ../../core/ugcontainer.h
init.o: ../../notify/notify.h ../../notify/notifypool.h
init.o: ../../templates/patterns.h ../../templates/locale.h
init.o: ../../templates/localefilter.h ../../../ezc/src/ezc.h
init.o: ../../../ezc/src/utf8.h ../../../ezc/src/generator.h
init.o: ../../templates/locale.h ../../core/system.h ../../core/dirs.h
init.o: ../../core/dircontainer.h ../../db/db.h ../../db/dbbase.h
init.o: ../../db/dbconn.h ../../db/dbtextstream.h ../../core/error.h
init.o: ../../db/dbitemquery.h ../../core/item.h ../../db/dbitemcolumns.h
init.o: ../../core/user.h ../../core/group.h ../../core/dircontainer.h
init.o: ../../core/ugcontainer.h ../../notify/notify.h
init.o: ../../notify/notifypool.h ../../templates/patterns.h
init.o: ../../templates/locale.h ../../templates/localefilter.h
init.o: ../../../ezc/src/ezc.h ../../../ezc/src/generator.h
init.o: ../../../ezc/src/pattern.h ../../../ezc/src/functions.h
init.o: ../../../ezc/src/funinfo.h ../../../ezc/src/stringconv.h
init.o: ../../notify/notifythread.h ../../core/basethread.h
@@ -84,12 +82,11 @@ init.o: ../../templates/indexpatterns.h ../../templates/patterns.h
init.o: ../../templates/changepatterns.h ../../core/sessionmanager.h
init.o: groupinfo.h
templates.o: ../../templates/templates.h ../../../ezc/src/ezc.h
templates.o: ../../../ezc/src/utf8.h ../../../ezc/src/generator.h
templates.o: ../../../ezc/src/pattern.h ../../core/item.h
templates.o: ../../../ezc/src/functions.h ../../../ezc/src/funinfo.h
templates.o: ../../../ezc/src/stringconv.h ../../core/misc.h
templates.o: ../../core/requesttypes.h ../../templates/patterncacher.h
templates.o: ../../core/item.h ../../core/confparser.h
templates.o: ../../../ezc/src/generator.h ../../../ezc/src/pattern.h
templates.o: ../../core/item.h ../../../ezc/src/functions.h
templates.o: ../../../ezc/src/funinfo.h ../../../ezc/src/stringconv.h
templates.o: ../../core/misc.h ../../core/requesttypes.h
templates.o: ../../templates/patterncacher.h ../../core/item.h
templates.o: ../../templates/indexpatterns.h ../../templates/patterns.h
templates.o: ../../templates/locale.h ../../templates/changepatterns.h
templates.o: ../../templates/htmltextstream.h ../../templates/localefilter.h
@@ -97,15 +94,15 @@ templates.o: ../../core/config.h ../../core/cur.h ../../core/system.h
templates.o: ../../core/dirs.h ../../core/dircontainer.h ../../db/db.h
templates.o: ../../db/dbbase.h ../../db/dbconn.h ../../db/dbtextstream.h
templates.o: ../../core/textstream.h ../../core/error.h
templates.o: ../../core/confparser.h ../../db/dbitemquery.h
templates.o: ../../db/dbitemcolumns.h ../../core/user.h ../../core/group.h
templates.o: ../../core/dircontainer.h ../../core/ugcontainer.h
templates.o: ../../core/log.h ../../core/textstream.h
templates.o: ../../core/logmanipulators.h ../../core/slog.h ../../core/cur.h
templates.o: ../../core/request.h ../../core/error.h ../../core/config.h
templates.o: ../../core/htmlfilter.h ../../templates/htmltextstream.h
templates.o: ../../core/session.h ../../core/user.h ../../core/plugindata.h
templates.o: ../../core/rebus.h ../../core/mount.h ../../templates/locale.h
templates.o: ../../db/dbitemquery.h ../../db/dbitemcolumns.h
templates.o: ../../core/user.h ../../core/group.h ../../core/dircontainer.h
templates.o: ../../core/ugcontainer.h ../../core/log.h
templates.o: ../../core/textstream.h ../../core/logmanipulators.h
templates.o: ../../core/slog.h ../../core/cur.h ../../core/request.h
templates.o: ../../core/error.h ../../core/config.h ../../core/htmlfilter.h
templates.o: ../../templates/htmltextstream.h ../../core/session.h
templates.o: ../../core/user.h ../../core/plugindata.h ../../core/rebus.h
templates.o: ../../core/mount.h ../../templates/locale.h
templates.o: ../../notify/notify.h ../../notify/notifypool.h
templates.o: ../../templates/patterns.h ../../notify/notifythread.h
templates.o: ../../core/basethread.h ../../core/synchro.h

View File

@@ -2,7 +2,7 @@
* This file is a part of Winix
* and is not publicly distributed
*
* Copyright (c) 2011, Tomasz Sowa
* Copyright (c) 2011-2012, Tomasz Sowa
* All rights reserved.
*
*/
@@ -50,11 +50,11 @@ Groups * GroupInfo::FindGroups(long dir_id)
bool GroupInfo::ParseGroups(const std::wstring & str, Groups & groups)
{
groups.Clear();
Space & space = *groups.GetSpace();
PT::Space & space = *groups.GetSpace();
conf_parser.SetSpace(space);
conf_parser.UTF8(config->utf8);
if( conf_parser.ParseString(str) == ConfParser::ok )
if( conf_parser.ParseString(str) == PT::ConfParser::ok )
{
groups.Reindex();
}
@@ -65,7 +65,7 @@ bool GroupInfo::ParseGroups(const std::wstring & str, Groups & groups)
groups.Clear();
}
return conf_parser.status == ConfParser::ok;
return conf_parser.status == PT::ConfParser::ok;
}

View File

@@ -2,7 +2,7 @@
* This file is a part of Winix
* and is not publicly distributed
*
* Copyright (c) 2011, Tomasz Sowa
* Copyright (c) 2011-2012, Tomasz Sowa
* All rights reserved.
*
*/
@@ -13,7 +13,7 @@
#include <string>
#include <vector>
#include "groups.h"
#include "core/confparser.h"
#include "confparser/confparser.h"
#include "core/item.h"
#include "core/system.h"
#include "core/config.h"
@@ -67,7 +67,7 @@ private:
typedef std::map<long, GroupsWrapItem> GroupsWrap;
GroupsWrap groups_wrap;
ConfParser conf_parser;
PT::ConfParser conf_parser;
std::vector<Item*> config_dir_tab;
Item config_file;

View File

@@ -2,7 +2,7 @@
* This file is a part of Winix
* and is not publicly distributed
*
* Copyright (c) 2011, Tomasz Sowa
* Copyright (c) 2011-2012, Tomasz Sowa
* All rights reserved.
*
*/
@@ -17,7 +17,7 @@ namespace GroupItem
Space * Groups::GetSpace()
PT::Space * Groups::GetSpace()
{
return &space;
}
@@ -50,20 +50,20 @@ void Groups::Reindex()
}
void Groups::ReindexGroups(GroupIndex & group_index, Space & set)
void Groups::ReindexGroups(GroupIndex & group_index, PT::Space & set)
{
size_t i, v;
// loop through all groups in the set
for( i=0 ; i < set.spaces.size() ; ++i )
{
Space & group = *set.spaces[i];
PT::Space & group = *set.spaces[i];
const std::wstring & key = group.Text(L"key", L"value");
// loop through all values in the group
for(v=0 ; v<group.spaces.size() ; )
{
Space::Table::iterator vali = group.spaces[v]->table.find(key);
PT::Space::Table::iterator vali = group.spaces[v]->table.find(key);
if( vali != group.spaces[v]->table.end() && vali->second.size() == 1 )
{
@@ -93,7 +93,7 @@ size_t i, v;
}
void Groups::SortValues(Space & group)
void Groups::SortValues(PT::Space & group)
{
sort_by = group.Text(L"sort_by");
sort_asc = (group.Text(L"sort_asc", L"true") == L"true");
@@ -106,7 +106,7 @@ void Groups::SortValues(Space & group)
}
bool Groups::SortFunHelper::operator()(Space * sp1, Space * sp2)
bool Groups::SortFunHelper::operator()(PT::Space * sp1, PT::Space * sp2)
{
const std::wstring & val1 = sp1->Text(groups->sort_by, L"");
const std::wstring & val2 = sp2->Text(groups->sort_by, L"");
@@ -157,11 +157,11 @@ const std::wstring & Groups::GetOption(size_t seti, size_t groupi, size_t valuei
{
if( seti < space.spaces.size() )
{
Space & groups = *space.spaces[seti];
PT::Space & groups = *space.spaces[seti];
if( groupi < groups.spaces.size() )
{
Space & value = *groups.spaces[groupi];
PT::Space & value = *groups.spaces[groupi];
if( valuei < value.spaces.size() )
return value.spaces[valuei]->Text(option);
@@ -183,7 +183,7 @@ size_t Groups::Size(size_t seti, size_t groupi)
{
if( seti < space.spaces.size() )
{
Space & groups = *space.spaces[seti];
PT::Space & groups = *space.spaces[seti];
if( groupi < groups.spaces.size() )
return groups.spaces[groupi]->spaces.size();

View File

@@ -2,7 +2,7 @@
* This file is a part of Winix
* and is not publicly distributed
*
* Copyright (c) 2011, Tomasz Sowa
* Copyright (c) 2011-2012, Tomasz Sowa
* All rights reserved.
*
*/
@@ -13,7 +13,7 @@
#include <map>
#include <vector>
#include <string>
#include "core/confparser.h"
#include "confparser/confparser.h"
@@ -29,7 +29,7 @@ public:
reading all space
(sets and groups)
*/
Space * GetSpace();
PT::Space * GetSpace();
/*
@@ -82,7 +82,7 @@ private:
# sets should have a unique name
# groups don't have a name
*/
Space space;
PT::Space space;
/*
@@ -108,20 +108,20 @@ private:
std::wstring sort_by;
bool sort_asc;
Space::Value sort_value;
PT::Space::Value sort_value;
struct SortFunHelper
{
Groups * groups;
SortFunHelper(Groups * pgroups) : groups(pgroups) {};
size_t SortValue(const std::wstring & val);
bool operator()(Space * sp1, Space * sp2);
bool operator()(PT::Space * sp1, PT::Space * sp2);
};
void ReindexGroups(GroupIndex & group_index, Space & set);
void SortValues(Space & group);
void ReindexGroups(GroupIndex & group_index, PT::Space & set);
void SortValues(PT::Space & group);
};
}