MCPcopy Create free account
hub / github.com/Serial-Studio/Serial-Studio / commit

Method commit

app/src/DataModel/Editors/PainterCodeEditor.cpp:217–232  ·  view source on GitHub ↗

* @brief Force-flushes the current editor text to the selected painter group. */

Source from the content-addressed store, hash-verified

215 * @brief Force-flushes the current editor text to the selected painter group.
216 */
217void DataModel::PainterCodeEditor::commit()
218{
219 if (m_readingCode)
220 return;
221
222 if (auto* ime = QGuiApplication::inputMethod()) {
223 if (ime->isVisible() || !ime->inputItemRectangle().isEmpty())
224 ime->commit();
225 }
226
227 auto& editor = DataModel::ProjectEditor::instance();
228 if (!editor.currentGroupIsPainter())
229 return;
230
231 editor.setCurrentGroupPainterCode(text());
232}
233
234/**
235 * @brief Selects all editor text.

Callers 12

quazip_closeFunction · 0.80
writeBytesFunction · 0.80
processItemsMethod · 0.80
writeColumnDefsMethod · 0.80
storeProjectMetadataMethod · 0.80
writeRawBytesMethod · 0.80
writeTableSnapshotsMethod · 0.80
deleteSessionMethod · 0.80
deleteTagMethod · 0.80
storeProjectMetadataMethod · 0.80
snapshotMethod · 0.80
writeProjectFileMethod · 0.80

Calls 3

isEmptyMethod · 0.80
currentGroupIsPainterMethod · 0.80

Tested by

no test coverage detected