mirror of
https://github.com/pocoproject/poco.git
synced 2025-10-14 15:05:35 +02:00
added exception handling in Requesthandler, added WebWidgetsException
This commit is contained in:
@@ -114,6 +114,15 @@ void PageRenderer::renderHead(const Renderable* pRenderable, const RenderContext
|
||||
ostr << "<script type=\"text/javascript\">";
|
||||
ostr << "Ext.onReady(function() {";
|
||||
ostr << "Ext.QuickTips.init();";
|
||||
ostr << "Ext.Ajax.on({'requestexception':function(conn, resp, obj){";
|
||||
ostr << "Ext.Msg.show({";
|
||||
ostr << "title:'Server Error',";
|
||||
ostr << "msg:resp.statusText,";
|
||||
ostr << "buttons:Ext.Msg.OK,";
|
||||
ostr << "icon:Ext.MessageBox.ERROR";
|
||||
ostr << "});";
|
||||
ostr << "}});";
|
||||
|
||||
// always nest a panel around, so we can get rid of dynamic casts to check for parent type
|
||||
ostr << "new Ext.Panel({renderTo:'p" << pPage->id() << "',border:false,bodyBorder:false";
|
||||
if (!pPage->beforeRender.jsDelegates().empty() || !pPage->afterRender.jsDelegates().empty())
|
||||
|
@@ -142,13 +142,13 @@ void Utility::initialize(ResourceManager::Ptr ptr, const Poco::Path& extJSDir)
|
||||
ptr->appendJSInclude(Poco::Path(aDir, "ext-base.js"));
|
||||
ptr->appendJSInclude(Poco::Path(aDir, "ext-all.js"));
|
||||
ptr->appendJSInclude(Poco::Path(aDir, "DDView.js"));
|
||||
ptr->appendJSInclude(Poco::Path(aDir, "MultiSelect.js"));
|
||||
ptr->appendJSInclude(Poco::Path(aDir, "Multiselect.js"));
|
||||
|
||||
Poco::Path cssAll("resources/css/ext-all.css");
|
||||
cssAll.makeFile();
|
||||
|
||||
ptr->appendCSSInclude(Poco::Path(aDir, cssAll));
|
||||
ptr->appendCSSInclude(Poco::Path(aDir, "MultiSelect.css"));
|
||||
ptr->appendCSSInclude(Poco::Path(aDir, "Multiselect.css"));
|
||||
}
|
||||
|
||||
|
||||
|
Reference in New Issue
Block a user