MCPcopy Create free account
hub / github.com/bluescan/tacentview / DoSelect

Method DoSelect

Src/FileDialog.cpp:1098–1117  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

1096
1097
1098void FileDialog::DoSelect(const tString& filename)
1099{
1100 // Only allowed one selected max. Clear the others.
1101 for (ContentItem* i = SelectedNode->Contents.First(); i; i = i->Next())
1102 {
1103 if (i->Name == filename)
1104 {
1105 i->Selected = true;
1106
1107 // If item just selected and we're in SaveFile mode we need to update the Edit widget.
1108 // This widget uses the SaveFileResult string, so we update that.
1109 if (Mode == DialogMode::SaveFile)
1110 SaveFileResult = tGetFileBaseName(filename).Chr();
1111 }
1112 else
1113 {
1114 i->Selected = false;
1115 }
1116 }
1117}
1118
1119
1120tStringItem* FileDialog::BookmarksLoop()

Callers

nothing calls this directly

Calls

no outgoing calls

Tested by

no test coverage detected