Source/WebCore/ChangeLog

 12012-03-31 Martin Robinson <mrobinson@igalia.com>
 2
 3 [GTK] [Stable] --disable geolocation broken after recent merges
 4 https://bugs.webkit.org/show_bug.cgi?id=82452
 5
 6 Reviewed by NOBODY (OOPS!).
 7
 8 Test: platform/gtk/fast/forms/large-toggle-elements.html
 9
 10 Instead of drawing a toggle button across the entire rectangle of
 11 the WebCore control, draw a default-sized one cenetered in the rectangle.
 12
 13 * platform/gtk/RenderThemeGtk3.cpp:
 14 (WebCore::paintToggle): Draw default-sized toggles.
 15
1162012-03-30 Nat Duca <nduca@chromium.org>
217
318 [chromium] Bump max texture updates per frame to 48

Source/WebCore/platform/gtk/RenderThemeGtk3.cpp

@@static void setToggleSize(GtkStyleContext* context, RenderStyle* style)
218218 style->setHeight(Length(indicatorSize, Fixed));
219219}
220220
221 static void paintToggle(const RenderThemeGtk* theme, GType widgetType, RenderObject* renderObject, const PaintInfo& paintInfo, const IntRect& rect)
 221static void paintToggle(const RenderThemeGtk* theme, GType widgetType, RenderObject* renderObject, const PaintInfo& paintInfo, const IntRect& fullRect)
222222{
223223 GtkStyleContext* context = getStyleContext(widgetType);
224224 gtk_style_context_save(context);
225225
 226 // Some themes do not render large toggle buttons properly, so we simply
 227 // shrink the rectangle back down to the default size and then center it
 228 // in the full toggle button region. The reason for not simply forcing toggle
 229 // buttons to be a smaller size is that we don't want to break site layouts.
 230 gint indicatorSize;
 231 gtk_style_context_get_style(context, "indicator-size", &indicatorSize, NULL);
 232 IntRect rect(fullRect);
 233 if (rect.width() > indicatorSize) {
 234 rect.inflateX(-(rect.width() - indicatorSize) / 2);
 235 rect.setWidth(indicatorSize); // In case rect.width() was equal to indicatorSize + 1.
 236 }
 237
 238 if (rect.height() > indicatorSize) {
 239 rect.inflateY(-(rect.height() - indicatorSize) / 2);
 240 rect.setHeight(indicatorSize); // In case rect.height() was equal to indicatorSize + 1.
 241 }
 242
226243 gtk_style_context_set_direction(context, static_cast<GtkTextDirection>(gtkTextDirection(renderObject->style()->direction())));
227244 gtk_style_context_add_class(context, widgetType == GTK_TYPE_CHECK_BUTTON ? GTK_STYLE_CLASS_CHECK : GTK_STYLE_CLASS_RADIO);
228245

LayoutTests/ChangeLog

 12012-03-31 Martin Robinson <mrobinson@igalia.com>
 2
 3 [GTK] [Stable] --disable geolocation broken after recent merges
 4 https://bugs.webkit.org/show_bug.cgi?id=82452
 5
 6 Reviewed by NOBODY (OOPS!).
 7
 8 Add a test for this issue.
 9
 10 * platform/gtk/fast/forms/large-toggle-elements-expected.png: Added.
 11 * platform/gtk/fast/forms/large-toggle-elements-expected.txt: Added.
 12 * platform/gtk/fast/forms/large-toggle-elements.html: Added.
 13
1142012-03-30 Dirk Pranke <dpranke@chromium.org>
215
316 Unreviewed, new baseline.

LayoutTests/platform/gtk/fast/forms/large-toggle-elements-expected.png


Added

0d12092179a4c917dca2dd7a2ef75fdc

LayoutTests/platform/gtk/fast/forms/large-toggle-elements-expected.txt

 1layer at (0,0) size 800x600
 2 RenderView at (0,0) size 800x600
 3layer at (0,0) size 800x600
 4 RenderBlock {HTML} at (0,0) size 800x600
 5 RenderBody {BODY} at (8,8) size 784x584
 6 RenderText {#text} at (0,0) size 704x17
 7 text run at (0,0) width 704: "This is a test that large toggle elements render correctly. See https://bugs.webkit.org/show_bug.cgi?id=82833 "
 8 RenderBlock {INPUT} at (4,21) size 200x200
 9 RenderText {#text} at (208,205) size 4x17
 10 text run at (208,205) width 4: " "
 11 RenderBlock {INPUT} at (216,21) size 200x200
 12 RenderText {#text} at (0,0) size 0x0

LayoutTests/platform/gtk/fast/forms/large-toggle-elements.html

 1This is a test that large toggle elements render correctly.
 2See https://bugs.webkit.org/show_bug.cgi?id=82833
 3<input type="checkbox" style="height:200px; width:200px"/>
 4<input type="radio" style="height:200px; width:200px"/>