| 1162 | Memory::Delete(Tool); |
| 1163 | } |
| 1164 | |
| 1165 | void FEditorUI::AddPendingTools() |
| 1166 | { |
| 1167 | FEditorTool* NewTool = nullptr; |
| 1168 | while (ToolsPendingAdd.Dequeue(NewTool)) |
| 1169 | { |
| 1170 | EditorTools.Add(NewTool); |
| 1171 | } |
| 1172 | } |
| 1173 | |
| 1174 | void FEditorUI::PushModal(const FString& Title, ImVec2 Size, TMoveOnlyFunction<bool()> DrawFunction) |
| 1175 | { |
| 1176 | ModalManager.CreateDialogue(Title, Size, Move(DrawFunction)); |
| 1177 | } |
| 1178 | |
| 1179 | bool FEditorUI::ConfirmWritable(TVector<FString> VirtualPaths, TMoveOnlyFunction<void()> Then, bool bThenSaves) |
| 1180 | { |
| 1181 | TVector<FString> ReadOnly; |
| 1182 | for (FString& Path : VirtualPaths) |
| 1183 | { |
| 1184 | if (VFS::IsReadOnlyOnDisk(FStringView(*Path, Path.Len()))) |
| 1185 | { |
| 1186 | ReadOnly.Add(Move(Path)); |
| 1187 | } |
| 1188 | } |
| 1189 | if (ReadOnly.IsEmpty()) |
| 1190 | { |
| 1191 | return true; |
| 1192 | } |
| 1193 |
no test coverage detected