* Clears this selection. * * @return {Selection} This selection.
()
| 142 | */ |
| 143 | |
| 144 | clear() { |
| 145 | |
| 146 | const layer = this.layer; |
| 147 | |
| 148 | for(const object of this) { |
| 149 | |
| 150 | object.layers.disable(layer); |
| 151 | |
| 152 | } |
| 153 | |
| 154 | return super.clear(); |
| 155 | |
| 156 | } |
| 157 | |
| 158 | /** |
| 159 | * Clears this selection and adds the given objects. |