MCPcopy Create free account
hub / github.com/ErrorAtLine0/infinipaint / commit

Method commit

src/DrawingProgram/Tools/EllipseDrawTool.cpp:154–168  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

152}
153
154void EllipseDrawTool::commit() {
155 if(objInfoBeingEdited) {
156 NetworkingObjects::NetObjOwnerPtr<CanvasComponentContainer>& containerPtr = objInfoBeingEdited->obj;
157 containerPtr->commit_update(drawP);
158 containerPtr->send_comp_update(drawP, true);
159 commitUpdate = false;
160 if(containerPtr->get_world_bounds().has_value())
161 drawP.layerMan.add_undo_place_component(objInfoBeingEdited);
162 else {
163 auto& components = containerPtr->parentLayer->get_layer().components;
164 components->erase(components, containerPtr->objInfo);
165 }
166 objInfoBeingEdited = nullptr;
167 }
168}
169
170void EllipseDrawTool::draw(SkCanvas* canvas, const DrawData& drawData) {
171}

Callers

nothing calls this directly

Calls 4

commit_updateMethod · 0.80
send_comp_updateMethod · 0.80
eraseMethod · 0.45

Tested by

no test coverage detected