Bug #2167
WDialog z-index ordering [3.3.1rc1]
Start date:
08/30/2013
Due date:
% Done:
0%
Estimated time:
Description
When creating WDialogs, the latest created dialog instance will overlap all other dialogs, and there's no way in bringing a dialog from the back to the front.
The Rocket-Launch example from the widget gallery shows this issue (create two or more dialogs).
My brute-force attempt to solve this via javascript/jQuery did not work (yet), but this is probably the rough direction to go?
WDialog *dlg = new WDialog("Dialog Example", content()); dlg->titleBar()->clicked().connect(std::bind([=](const WMouseEvent &mouseEvent) { const std::string id = dlg->id(); std::cout << format("dialog %s has been clicked", id) << std::endl; std::string query = format("$('#%s').parent().append($('#%s'));", id, id); dlg->doJavaScript(query); }, std::placeholders::_1));
Also, windows should probably come to the front not only by clicking the dialog-toolbar, but also when clicking any area of the dialog.
If I can help out, please let me know.
Thx,
Roman
PS: Example html attached which shows how to pop a div to the front.
PPS: I am using tinyformat for format-like operations
Files