diff options
Diffstat (limited to 'vcl')
-rw-r--r-- | vcl/inc/unx/gtk/gtkgdi.hxx | 2 | ||||
-rw-r--r-- | vcl/unx/gtk/salnativewidgets-gtk.cxx | 28 |
2 files changed, 20 insertions, 10 deletions
diff --git a/vcl/inc/unx/gtk/gtkgdi.hxx b/vcl/inc/unx/gtk/gtkgdi.hxx index 707b0a2918c2..8187bdb5a043 100644 --- a/vcl/inc/unx/gtk/gtkgdi.hxx +++ b/vcl/inc/unx/gtk/gtkgdi.hxx @@ -384,7 +384,7 @@ protected: bool NWPaintGTKSlider( ControlPart nPart, const tools::Rectangle& rControlRectangle, ControlState nState, const ImplControlValue& aValue ); - bool NWPaintGTKListNode( + bool NWPaintGTKListNode( GdkDrawable* gdkDrawable, const tools::Rectangle& rControlRectangle, ControlState nState, const ImplControlValue& aValue ); }; diff --git a/vcl/unx/gtk/salnativewidgets-gtk.cxx b/vcl/unx/gtk/salnativewidgets-gtk.cxx index b0f015a24fe7..0ce990426813 100644 --- a/vcl/unx/gtk/salnativewidgets-gtk.cxx +++ b/vcl/unx/gtk/salnativewidgets-gtk.cxx @@ -1020,7 +1020,7 @@ bool GtkSalGraphics::DoDrawNativeControl( } else if( (nType == ControlType::ListNode) && (nPart == ControlPart::Entire) ) { - return NWPaintGTKListNode( aCtrlRect, nState, aValue ); + return NWPaintGTKListNode( pDrawable, aCtrlRect, nState, aValue ); } else if( (nType == ControlType::ListNet) && (nPart == ControlPart::Entire) ) { @@ -3347,7 +3347,18 @@ bool GtkSalGraphics::NWPaintGTKTooltip( return true; } +namespace +{ +void NWPaintGTKListNodeReal(SalX11Screen nXScreen, GdkDrawable* gdkDrawable, GtkStateType stateType, + gint w, int h, GtkExpanderStyle eStyle) +{ + gtk_paint_expander(gWidgetData[nXScreen].gTreeView->style, gdkDrawable, stateType, nullptr, + gWidgetData[nXScreen].gTreeView, "treeview", w / 2, h / 2, eStyle); +} +} + bool GtkSalGraphics::NWPaintGTKListNode( + GdkDrawable* gdkDrawable, const tools::Rectangle& rControlRectangle, ControlState nState, const ImplControlValue& rValue ) { @@ -3377,16 +3388,15 @@ bool GtkSalGraphics::NWPaintGTKListNode( break; } + if (GtkSalGraphics::bNeedPixmapPaint) + { + NWPaintGTKListNodeReal(m_nXScreen, gdkDrawable, stateType, w, h, eStyle); + return true; + } + BEGIN_PIXMAP_RENDER( aRect, pixDrawable ) { - gtk_paint_expander( gWidgetData[m_nXScreen].gTreeView->style, - pixDrawable, - stateType, - nullptr, - gWidgetData[m_nXScreen].gTreeView, - "treeview", - w/2, h/2, - eStyle ); + NWPaintGTKListNodeReal(m_nXScreen, pixDrawable, stateType, w, h, eStyle); } END_PIXMAP_RENDER( aRect ) |