backup op does not target a device
svn path=/trunk/extragear/sysadmin/partitionmanager/; revision=1129869
This commit is contained in:
parent
5327ca792a
commit
15e23d806e
|
@ -46,16 +46,6 @@ BackupOperation::BackupOperation(Device& d, Partition& p, const QString& filenam
|
|||
addJob(backupJob());
|
||||
}
|
||||
|
||||
bool BackupOperation::targets(const Device& d) const
|
||||
{
|
||||
return d == targetDevice();
|
||||
}
|
||||
|
||||
bool BackupOperation::targets(const Partition& p) const
|
||||
{
|
||||
return p == backupPartition();
|
||||
}
|
||||
|
||||
QString BackupOperation::description() const
|
||||
{
|
||||
return QString(i18nc("@info/plain", "Backup partition <filename>%1</filename> (%2, %3) to <filename>%4</filename>", backupPartition().deviceNode(), Capacity(backupPartition()).toString(), backupPartition().fileSystem().name(), fileName()));
|
||||
|
@ -69,7 +59,7 @@ bool BackupOperation::canBackup(const Partition* p)
|
|||
{
|
||||
if (p == NULL)
|
||||
return false;
|
||||
|
||||
|
||||
if (p->isMounted())
|
||||
return false;
|
||||
|
||||
|
|
|
@ -46,8 +46,8 @@ class BackupOperation : public Operation
|
|||
void preview() {}
|
||||
void undo() {}
|
||||
|
||||
virtual bool targets(const Device& d) const;
|
||||
virtual bool targets(const Partition& p) const;
|
||||
virtual bool targets(const Device&) const { return false; }
|
||||
virtual bool targets(const Partition&) const { return false; }
|
||||
|
||||
static bool canBackup(const Partition* p);
|
||||
|
||||
|
|
Loading…
Reference in New Issue