mirror of
https://gitlab.gnome.org/GNOME/gparted
synced 2024-11-05 20:46:55 +00:00
Add comment summarising current operation merging rules (#755214)
This information is already documented in the existing comments associated with the calls to merge_operations() and assignments to the mergetype variables. The table just summaries the rules together in one place. Bug 755214 - Refactor operation merging
This commit is contained in:
parent
5793c5ac03
commit
27e5bbeece
1 changed files with 24 additions and 0 deletions
|
@ -758,6 +758,30 @@ bool Win_GParted::merge_two_operations( unsigned int first, unsigned int second
|
|||
return false;
|
||||
}
|
||||
|
||||
// Try to merge pending operations in the operations[] vector using the specified merge
|
||||
// type.
|
||||
//
|
||||
// Summary of all the operation merging rules for each operation type coded into the
|
||||
// ::activate_*() methods:
|
||||
//
|
||||
// Operation type Partition status Merge type Method
|
||||
// ----------------- ---------------- -------------------- -----------------
|
||||
// resize/move Real MERGE_LAST_WITH_PREV activate_resize()
|
||||
// resize/move New MERGE_LAST_WITH_ANY activate_resize()
|
||||
// paste * none activate_paste()
|
||||
// new * none activate_new()
|
||||
// delete Real none activate_delete()
|
||||
// delete New MERGE_ALL_ADJACENT activate_delete()
|
||||
// format Real MERGE_LAST_WITH_PREV activate_format()
|
||||
// format New MERGE_LAST_WITH_ANY activate_format()
|
||||
// check Real [1] MERGE_LAST_WITH_ANY activate_check()
|
||||
// label file system Real [1] MERGE_LAST_WITH_ANY activate_label_filesystem()
|
||||
// name partition Real [1] MERGE_LAST_WITH_ANY activate_name_partition()
|
||||
// new UUID Real [1] MERGE_LAST_WITH_ANY activate_change_uuid()
|
||||
//
|
||||
// [1] The UI only allows these operations to be applied to real partitions; where as the
|
||||
// other mergeable operations can be applied to both real partitions and new, pending
|
||||
// create partitions.
|
||||
void Win_GParted::merge_operations( MergeType mergetype )
|
||||
{
|
||||
unsigned int num_ops = operations.size();
|
||||
|
|
Loading…
Reference in a new issue