we can create links (hard links, symbolic links) now
added winix functions: ln winix function 'default' can be used without redirecting now added new tickets types: TypeProgress, TypeString, TypeMultistring, TypeImages, TypeFiles now tickets are combined with files added winix functions: showtickets fixed mountpoints: when the default root mount was created its parameter table was empty and it caused accessing to a non-existing objects fixed logger: modifiers (log1, log2, log3) were incorrectly treated added modifier: log4 (debug info) now we are moving threads to a new plugin 'thread' created directory: plugins/thread (not finished yet) git-svn-id: svn://ttmath.org/publicrep/winix/trunk@704 e52654a7-88a9-db11-a3e9-0013d4bc506e
This commit is contained in:
@@ -36,6 +36,12 @@ void dir_without_slash(Info & i)
|
||||
}
|
||||
|
||||
|
||||
void dir_is_root(Info & i)
|
||||
{
|
||||
i.res = request->dir_tab.size() == 1;
|
||||
}
|
||||
|
||||
|
||||
void dir_parent(Info & i)
|
||||
{
|
||||
if( request->dir_tab.empty() )
|
||||
@@ -253,50 +259,16 @@ void dir_tab_link(Info & i)
|
||||
}
|
||||
|
||||
|
||||
static Item dir_last_default_item;
|
||||
static size_t dir_last_default_item_reqid = 0;
|
||||
static std::wstring dir_last_path;
|
||||
|
||||
|
||||
|
||||
void dir_last_default_item_init()
|
||||
void dir_last_link_to(Info & i)
|
||||
{
|
||||
if( dir_last_default_item_reqid == request->id )
|
||||
return;
|
||||
|
||||
dir_last_default_item_reqid = request->id;
|
||||
dir_last_default_item.Clear();
|
||||
|
||||
if( request->dir_tab.empty() )
|
||||
return;
|
||||
|
||||
long default_item = request->dir_tab.back()->default_item;
|
||||
|
||||
if( default_item == -1 )
|
||||
return;
|
||||
|
||||
// !! tutaj nie musimy odczytywac wszystkiego (contentu itp)
|
||||
if( db->GetItemById(default_item, dir_last_default_item) != WINIX_ERR_OK )
|
||||
dir_last_default_item.Clear();
|
||||
i.out << request->dir_tab.back()->link_to;
|
||||
}
|
||||
|
||||
|
||||
|
||||
void dir_last_default_item_dir(Info & i)
|
||||
void dir_last_is_link_redirect(Info & i)
|
||||
{
|
||||
dir_last_default_item_init();
|
||||
|
||||
if( dir_last_default_item.parent_id != -1 )
|
||||
if( system->dirs.MakePath(dir_last_default_item.parent_id, dir_last_path) )
|
||||
i.out << dir_last_path;
|
||||
}
|
||||
|
||||
|
||||
void dir_last_default_item_url(Info & i)
|
||||
{
|
||||
dir_last_default_item_init();
|
||||
|
||||
i.out << dir_last_default_item.url;
|
||||
i.res = request->dir_tab.back()->link_redirect == 1;
|
||||
}
|
||||
|
||||
|
||||
|
||||
Reference in New Issue
Block a user