summaryrefslogtreecommitdiff
path: root/tools.c
blob: 35ca8e26ddb430e7dac16f71da9f1f6114cf4ed7 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
#include "tools.h"
#include "imagelist.h"
#include "setup.h"

cDirList::cDirList(void)
{
  char *buffer = NULL;

  OptExclude("^lost\\+found$"); // lost+found Dir
  OptExclude("^\\."); // hidden Files
  OptExclude("\\.sdel$"); // del Files
  OptExclude("\\.smove$"); // move Files

  cTokenizer *token = new cTokenizer(ImageList.GetDirContains(), "@");
  for(int i = 1; i <= token->Count(); i++)
  {
    asprintf(&buffer, "^%s$", token->GetToken(i));
    OptExclude(buffer);
    FREENULL(buffer);
  }

  OptSort((eFileList)DVDSwitchSetup.SortMode);
  OptFilterType(tDir);

  delete(token);
}