| 53 | } |
| 54 | |
| 55 | void dialog::OpenYesNo(Plugin *workPlugin, const wchar_t *titleText, const wchar_t *messageText) |
| 56 | { |
| 57 | if (s_currentDialog != CURRENT_DIALOG_NONE) |
| 58 | return; |
| 59 | |
| 60 | bool isMainThread = thread::ThreadIDCache::Check(); |
| 61 | |
| 62 | paf::wstring title = titleText; |
| 63 | paf::wstring message = messageText; |
| 64 | |
| 65 | if (!isMainThread) |
| 66 | thread::RMutex::MainThreadMutex()->Lock(); |
| 67 | |
| 68 | s_currentDialog = CommonGuiDialog::Dialog::Show(workPlugin, &title, &message, &CommonGuiDialog::Param::s_dialogYesNo, CommonGuiEventHandler, NULL); |
| 69 | s_currentPlugin = workPlugin; |
| 70 | |
| 71 | if (!isMainThread) |
| 72 | thread::RMutex::MainThreadMutex()->Unlock(); |
| 73 | } |
| 74 | |
| 75 | void dialog::OpenOk(Plugin *workPlugin, const wchar_t *titleText, const wchar_t *messageText) |
| 76 | { |