diff options
author | Jonathan Marshall <jmarshall@never.you.mind> | 2011-06-30 14:15:15 +1200 |
---|---|---|
committer | Jonathan Marshall <jmarshall@never.you.mind> | 2011-06-30 14:15:15 +1200 |
commit | 1c2d0e17ab2cf0a50b33540bc5f403e9fd6d5ca4 (patch) | |
tree | ed3fdfda97841696c30da2fb763d353f865e2a4a | |
parent | 1fb3d8754b9c50e9a055285381df2a2cd1b4ce5a (diff) |
compute correct render rect for the label control - fixes #11651 (labels without <height> specified)
-rw-r--r-- | xbmc/guilib/GUILabelControl.cpp | 5 | ||||
-rw-r--r-- | xbmc/guilib/GUILabelControl.h | 1 |
2 files changed, 6 insertions, 0 deletions
diff --git a/xbmc/guilib/GUILabelControl.cpp b/xbmc/guilib/GUILabelControl.cpp index 17c4633f19..af7e39fa29 100644 --- a/xbmc/guilib/GUILabelControl.cpp +++ b/xbmc/guilib/GUILabelControl.cpp @@ -123,6 +123,11 @@ void CGUILabelControl::Process(unsigned int currentTime, CDirtyRegionList &dirty CGUIControl::Process(currentTime, dirtyregions); } +CRect CGUILabelControl::CalcRenderRegion() const +{ + return m_label.GetRenderRect(); +} + void CGUILabelControl::Render() { m_label.Render(); diff --git a/xbmc/guilib/GUILabelControl.h b/xbmc/guilib/GUILabelControl.h index cf6780511a..cd0222bbdd 100644 --- a/xbmc/guilib/GUILabelControl.h +++ b/xbmc/guilib/GUILabelControl.h @@ -51,6 +51,7 @@ public: virtual bool OnMessage(CGUIMessage& message); virtual CStdString GetDescription() const; virtual float GetWidth() const; + virtual CRect CalcRenderRegion() const; const CLabelInfo& GetLabelInfo() const { return m_label.GetLabelInfo(); }; void SetLabel(const std::string &strLabel); |