Changes can only be deleted by Administrators, or by the change owner
when they are granted the "Delete Own Changes" permission either on the
"Change Owners" virtual group or an internal group they are a member of.
This means that it is not possible to allow users to delete other users'
changes other than by granting the "Administrate Server" permission,
which also gives them all the other administrative capabilities. This is
also inconsistent with how the "Delete Drafts" permission works.
An example of where it would be better to have more flexible permissions
is allowing changes to be deleted by Project Owners on a per-project
basis, or by a group of users who are trusted (but not enough to grant
them Administrator capabilities).
Add a new permission "Delete Changes" which allows these use cases, thus
a change can now also be deleted by users who are:
- Member of a group that is explicitly granted "Delete Changes" on the
change's destination branch.
- Member of a group that is given the "Owner" permission on the project,
when the virtual group "Project Owners" is granted "Delete Changes" on
the change's destination branch.
Bug: Issue 9354
Change-Id: I9d5d779eb0a6ce18faca02b9fc90904ec5da91d9