57 lines
668 B
C++
Executable File
57 lines
668 B
C++
Executable File
/*
|
|
* This file is a part of Winix
|
|
* and is not publicly distributed
|
|
*
|
|
* Copyright (c) 2010, Tomasz Sowa
|
|
* All rights reserved.
|
|
*
|
|
*/
|
|
|
|
#include "threadinfo.h"
|
|
|
|
|
|
|
|
namespace Thread
|
|
{
|
|
|
|
|
|
void ThreadInfo::SetSystem(System * psystem)
|
|
{
|
|
system = psystem;
|
|
}
|
|
|
|
|
|
void ThreadInfo::Clear()
|
|
{
|
|
item_tab.clear();
|
|
thread_tab.clear();
|
|
item_sort_tab.clear();
|
|
}
|
|
|
|
|
|
|
|
Item * ThreadInfo::FindThreadDir()
|
|
{
|
|
const std::wstring & dir_str = system->mounts.pmount->FirstArg(mount_par_thread_dir);
|
|
|
|
if( dir_str.empty() )
|
|
return 0;
|
|
|
|
int res = system->FollowAllLinks(dir_str, out_dir_tab, out_item);
|
|
|
|
if( res != 0 )
|
|
return 0;
|
|
|
|
return out_dir_tab.back();
|
|
}
|
|
|
|
|
|
|
|
|
|
} // namespace
|
|
|
|
|
|
|
|
|
|
|