summaryrefslogtreecommitdiff
path: root/vcl
diff options
context:
space:
mode:
authorLouis-Francis Ratté-Boulianne <lfrb@collabora.com>2014-12-03 17:04:15 -0500
committerMarkus Mohrhard <markus.mohrhard@collabora.co.uk>2014-12-11 07:57:28 +0100
commit6ecff9b87e2dd1e5bf72e24003e2a038d497db51 (patch)
treecf4c81d0d201e2601c0db8ab6c8cf4a6d3d2e7cd /vcl
parent83861ce123c2d7b1ce9c6acfbc0e457662eac944 (diff)
vcl: Use right size to draw native GTK window background
Change-Id: Id446d20599f072f657c6106d6c6457fce08830e6
Diffstat (limited to 'vcl')
-rw-r--r--vcl/unx/gtk/gdi/salnativewidgets-gtk.cxx11
1 files changed, 7 insertions, 4 deletions
diff --git a/vcl/unx/gtk/gdi/salnativewidgets-gtk.cxx b/vcl/unx/gtk/gdi/salnativewidgets-gtk.cxx
index 598005d9d567..d0f2bf2ac512 100644
--- a/vcl/unx/gtk/gdi/salnativewidgets-gtk.cxx
+++ b/vcl/unx/gtk/gdi/salnativewidgets-gtk.cxx
@@ -1551,13 +1551,11 @@ bool GtkSalGraphics::NWPaintGTKFrame(
bool GtkSalGraphics::NWPaintGTKWindowBackground(
GdkDrawable* gdkDrawable,
ControlType, ControlPart,
- const Rectangle& /* rControlRectangle */,
+ const Rectangle& rControlRectangle,
const clipList& rClipList,
ControlState /* nState */, const ImplControlValue&,
const OUString& )
{
- int w,h;
- gtk_window_get_size(GTK_WINDOW(m_pWindow),&w,&h);
GdkRectangle clipRect;
for( clipList::const_iterator it = rClipList.begin(); it != rClipList.end(); ++it )
{
@@ -1566,7 +1564,12 @@ bool GtkSalGraphics::NWPaintGTKWindowBackground(
clipRect.width = it->GetWidth();
clipRect.height = it->GetHeight();
- gtk_paint_flat_box(m_pWindow->style,gdkDrawable,GTK_STATE_NORMAL,GTK_SHADOW_NONE,&clipRect,m_pWindow,"base",0,0,w,h);
+ gtk_paint_flat_box(m_pWindow->style,gdkDrawable,GTK_STATE_NORMAL,GTK_SHADOW_NONE,&clipRect,
+ m_pWindow,"base",
+ rControlRectangle.Left(),
+ rControlRectangle.Top(),
+ rControlRectangle.GetWidth(),
+ rControlRectangle.GetHeight());
}
return true;