| 215 | } |
| 216 | |
| 217 | ui::ScrollView *dialog::OpenScrollView( |
| 218 | Plugin *workPlugin, |
| 219 | const wchar_t *titleText) |
| 220 | { |
| 221 | if (s_currentDialog != CURRENT_DIALOG_NONE) |
| 222 | return NULL; |
| 223 | |
| 224 | bool isMainThread = thread::ThreadIDCache::Check(); |
| 225 | |
| 226 | paf::wstring title = titleText; |
| 227 | |
| 228 | if (!isMainThread) |
| 229 | thread::RMutex::MainThreadMutex()->Lock(); |
| 230 | |
| 231 | s_currentDialog = CommonGuiDialog::Dialog::Show(workPlugin, &title, NULL, &CommonGuiDialog::Param::s_dialogXView, CommonGuiEventHandler, NULL); |
| 232 | ui::Widget *ret = CommonGuiDialog::Dialog::GetWidget(s_currentDialog, CommonGuiDialog::REGISTER_ID_SCROLL_VIEW); |
| 233 | s_currentPlugin = workPlugin; |
| 234 | |
| 235 | if (!isMainThread) |
| 236 | thread::RMutex::MainThreadMutex()->Unlock(); |
| 237 | |
| 238 | return (ui::ScrollView *)ret; |
| 239 | } |
| 240 | |
| 241 | void dialog::Close() |
| 242 | { |