diff --git a/clientgui/NoticeListCtrl.cpp b/clientgui/NoticeListCtrl.cpp index 513c0725ad..ebd9f05b3f 100644 --- a/clientgui/NoticeListCtrl.cpp +++ b/clientgui/NoticeListCtrl.cpp @@ -51,6 +51,7 @@ BEGIN_EVENT_TABLE( CNoticeListCtrl, wxWindow ) ////@begin CNoticeListCtrl event table entries EVT_WEBVIEW_NAVIGATING(ID_LIST_NOTIFICATIONSVIEW, CNoticeListCtrl::OnLinkClicked) + EVT_WEBVIEW_ERROR(ID_LIST_NOTIFICATIONSVIEW, CNoticeListCtrl::OnWebViewError) ////@end CNoticeListCtrl event table entries END_EVENT_TABLE() @@ -175,10 +176,29 @@ void CNoticeListCtrl::SetItemCount(int newCount) { eol_to_br(strDescription); localize(strDescription); + // RSS feeds and web pages may use protocol-relative (scheme-relative) + // URLs, such as + // Since the html comes from a web server via http, the scheme is + // assumed to also be http. But we have cached the html in a local + // file, so it is no longer associated with the http protocol / scheme. + // Therefore all our URLs must explicity specify the http protocol. + // + // The second argument to wxWebView::SetPage is supposed to take care + // of this automatically, but fails to do so under Windows, so we do + // it here explicitly. + strDescription.Replace(wxT("\"//"), wxT("\"http://")); + dtBuffer.Set((time_t)np->create_time); strCreateTime = dtBuffer.Format(); - strBuffer = wxT("
");
+ // Put dividers between notices, but not before first or after last
+ if (i == 0) {
+ strBuffer = wxEmptyString;
+ } else {
+ strBuffer = wxT(" "); + } + + strBuffer += wxT("
"); + strBuffer += wxT(" |