mirror of
https://github.com/PrismLauncher/PrismLauncher.git
synced 2026-07-04 20:36:58 +03:00
refactor: allow copy operation with whitelist
Signed-off-by: Sefa Eyeoglu <contact@scrumplex.net>
This commit is contained in:
parent
ddfb449b28
commit
e048bce13e
4 changed files with 47 additions and 6 deletions
|
|
@ -88,9 +88,14 @@ class copy {
|
|||
m_followSymlinks = follow;
|
||||
return *this;
|
||||
}
|
||||
copy& blacklist(const IPathMatcher* filter)
|
||||
copy& matcher(const IPathMatcher* filter)
|
||||
{
|
||||
m_blacklist = filter;
|
||||
m_matcher = filter;
|
||||
return *this;
|
||||
}
|
||||
copy& whitelist(bool whitelist)
|
||||
{
|
||||
m_whitelist = whitelist;
|
||||
return *this;
|
||||
}
|
||||
bool operator()() { return operator()(QString()); }
|
||||
|
|
@ -100,7 +105,8 @@ class copy {
|
|||
|
||||
private:
|
||||
bool m_followSymlinks = true;
|
||||
const IPathMatcher* m_blacklist = nullptr;
|
||||
const IPathMatcher* m_matcher = nullptr;
|
||||
bool m_whitelist = false;
|
||||
QDir m_src;
|
||||
QDir m_dst;
|
||||
};
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue