Changeset 31399 in webkit


Ignore:
Timestamp:
Mar 28, 2008 11:26:04 AM (16 years ago)
Author:
alp@webkit.org
Message:

2008-03-28 Jasper Bryant-Greene <jasper@unix.geek.nz>

Reviewed by Alp Toker.

http://bugs.webkit.org/show_bug.cgi?id=18061
PlatformScrollBarGtk attempts to allocate negative width and/or height for widgets

Missing clampNegativeToZero() call meant that we tried to allocate widgets with negative width and/or height.

  • platform/gtk/PlatformScrollBarGtk.cpp: (PlatformScrollbar::geometryChanged):
Location:
trunk/WebCore
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • trunk/WebCore/ChangeLog

    r31398 r31399  
     12008-03-28  Jasper Bryant-Greene  <jasper@unix.geek.nz>
     2
     3        Reviewed by Alp Toker.
     4
     5        http://bugs.webkit.org/show_bug.cgi?id=18061
     6        PlatformScrollBarGtk attempts to allocate negative width and/or height for widgets
     7
     8        Missing clampNegativeToZero() call meant that we tried to allocate widgets with negative width and/or height.
     9
     10        * platform/gtk/PlatformScrollBarGtk.cpp:
     11        (PlatformScrollbar::geometryChanged):
     12
    1132008-03-28  Brady Eidson  <beidson@apple.com>
    214
  • trunk/WebCore/platform/gtk/PlatformScrollBarGtk.cpp

    r29961 r31399  
    123123    FrameView* frameView = static_cast<FrameView*>(parent());
    124124    IntRect windowRect = IntRect(frameView->contentsToWindow(frameGeometry().location()), frameGeometry().size());
    125     GtkAllocation allocation = { windowRect.x(), windowRect.y(), windowRect.width(), windowRect.height() };
     125
     126    IntSize sz = frameGeometry().size();
     127    sz.clampNegativeToZero();
     128
     129    GtkAllocation allocation = { windowRect.x(), windowRect.y(), sz.width(), sz.height() };
    126130    gtk_widget_size_allocate(gtkWidget(), &allocation);
    127131}
Note: See TracChangeset for help on using the changeset viewer.