MCPcopy Create free account
hub / github.com/MyGUI/mygui / commandFileDrop

Method commandFileDrop

Tools/SkinEditor/EditorState.cpp:212–239  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

210 }
211
212 void EditorState::commandFileDrop(const MyGUI::UString& _commandName, bool& _result)
213 {
214 if (!checkCommand())
215 return;
216
217 mDropFileName = CommandManager::getInstance().getCommandData();
218 if (mDropFileName.empty())
219 return;
220
221 if (ActionManager::getInstance().getChanges())
222 {
223 MyGUI::Message* message = MessageBoxManager::getInstance().create(
224 replaceTags("Warning"),
225 replaceTags("MessageUnsavedData"),
226 MyGUI::MessageBoxStyle::IconQuest | MyGUI::MessageBoxStyle::Yes | MyGUI::MessageBoxStyle::No |
227 MyGUI::MessageBoxStyle::Cancel);
228 message->eventMessageBoxResult +=
229 MyGUI::newDelegate(this, &EditorState::notifyMessageBoxResultLoadDropFile);
230 }
231 else
232 {
233 clear();
234
235 loadDropFile();
236 }
237
238 _result = true;
239 }
240
241 void EditorState::notifyMessageBoxResultLoad(MyGUI::Message* _sender, MyGUI::MessageBoxStyle _result)
242 {

Callers

nothing calls this directly

Calls 6

replaceTagsFunction · 0.85
newDelegateFunction · 0.85
clearFunction · 0.85
emptyMethod · 0.45
getChangesMethod · 0.45
createMethod · 0.45

Tested by

no test coverage detected