Changeset 37585

Show
Ignore:
Timestamp:
10/14/08 05:50:51 (17 months ago)
Author:
vestbo@webkit.org
Message:

2008-10-14 Tor Arne Vestbø < tavestbo@trolltech.com>

Reviewed by Simon.

Fix QtWebKit scrollbar painting errors

Location:
trunk/WebCore
Files:
2 modified

Legend:

Unmodified
Added
Removed
  • trunk/WebCore/ChangeLog

    r37583 r37585  
     12008-10-14  Tor Arne Vestbø  <tavestbo@trolltech.com> 
     2 
     3        Reviewed by Simon. 
     4         
     5        Fix QtWebKit scrollbar painting errors 
     6 
     7        * platform/qt/ScrollbarThemeQt.cpp: 
     8        (WebCore::ScrollbarThemeQt::paint): 
     9        (WebCore::ScrollbarThemeQt::paintScrollCorner): 
     10 
    1112008-10-14  Tor Arne Vestbø  <tavestbo@trolltech.com> 
    212 
  • trunk/WebCore/platform/qt/ScrollbarThemeQt.cpp

    r37583 r37585  
    139139      return true; 
    140140 
     141    p.painter->save(); 
    141142    QStyleOptionSlider* opt = styleOptionSlider(scrollbar); 
    142143    p.painter->setClipRect(opt->rect.intersected(damageRect)); 
     
    155156    opt->rect.moveTo(topLeft); 
    156157#endif 
     158    p.painter->restore(); 
    157159 
    158160    return true; 
     
    229231    context->fillRect(rect, QApplication::palette().color(QPalette::Normal, QPalette::Window)); 
    230232#else 
     233    StylePainter p(context); 
     234    if (!p.isValid()) 
     235        return; 
     236 
    231237    QStyleOption option; 
    232238    option.rect = rect; 
    233     QApplication::style()->drawPrimitive(QStyle::PE_PanelScrollAreaCorner, 
    234             &option, context->platformContext(), 0); 
     239    p.drawPrimitive(QStyle::PE_PanelScrollAreaCorner, option); 
    235240#endif 
    236241}