- Revision
- 11260
- Author
- john
- Date
- 2006-07-26 09:32:56 -0700 (Wed, 26 Jul 2006)
Log Message
Fix bug#1301: Feeds parcel: mouseover link doesn't show URL in status bar. This is Markku's patch, which I reviewed.
Modified Paths
Diff
Modified: trunk/chandler/parcels/osaf/framework/blocks/ControlBlocks.py (11259 => 11260)
--- trunk/chandler/parcels/osaf/framework/blocks/ControlBlocks.py 2006-07-26 14:37:35 UTC (rev 11259) +++ trunk/chandler/parcels/osaf/framework/blocks/ControlBlocks.py 2006-07-26 16:32:56 UTC (rev 11260) @@ -231,8 +231,26 @@ editText.SetFont(Styles.getFont(getattr(self, "characterStyle", None))) return editText + +class HtmlWindowWithStatus(wx.html.HtmlWindow): + def __init__(self, *arguments, **keywords): + super (HtmlWindowWithStatus, self).__init__ (*arguments, **keywords) + # The default setting is to show link URLs in the statusbar of the mainframe. + self.showMessagesInStatusbar(wx.GetApp().mainFrame, True) + + def showMessagesInStatusbar(self, relatedFrame, show): + self.SetRelatedFrame(relatedFrame, u"%s") + if show: + self.SetRelatedStatusBar(0) + else: + self.SetRelatedStatusBar(-1) + + def OnSetTitle(self, title): + # This is an empty handler for setting the main frame window title. + # It is empty because we do not want to show the current URL in main frame window title. + pass -class wxHTML(wx.html.HtmlWindow): +class wxHTML(HtmlWindowWithStatus): def OnLinkClicked(self, link): webbrowser.open(link.GetHref()) @@ -880,7 +898,7 @@ self.widget.GoToItem (event.arguments['items'][0]) -class wxItemDetail(wx.html.HtmlWindow): +class wxItemDetail(HtmlWindowWithStatus): def OnLinkClicked(self, wx_linkinfo): """ Clicking on an item changes the selection (post event).
_______________________________________________ Commits mailing list [email protected] http://lists.osafoundation.org/mailman/listinfo/commits
