summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--Source/WebCore/page/FrameView.cpp18
-rw-r--r--Source/WebCore/platform/qt/ScrollbarThemeQStyle.cpp8
-rw-r--r--Source/WebCore/plugins/win/PluginViewWin.cpp7
-rw-r--r--Source/WebCore/rendering/RenderLayerBacking.cpp8
-rw-r--r--Source/WebKit2/WebProcess/WebCoreSupport/WebFrameLoaderClient.cpp4
-rw-r--r--Tools/qmake/mkspecs/features/unix/default_post.prf6
6 files changed, 23 insertions, 28 deletions
diff --git a/Source/WebCore/page/FrameView.cpp b/Source/WebCore/page/FrameView.cpp
index 209030309..4823b48d0 100644
--- a/Source/WebCore/page/FrameView.cpp
+++ b/Source/WebCore/page/FrameView.cpp
@@ -4147,24 +4147,6 @@ void FrameView::removeChild(Widget* widget)
bool FrameView::wheelEvent(const PlatformWheelEvent& wheelEvent)
{
- // Note that to allow for rubber-band over-scroll behavior, even non-scrollable views
- // should handle wheel events.
-#if !ENABLE(RUBBER_BANDING)
- if (!isScrollable())
- return false;
-#endif
-
- if (delegatesScrolling()) {
- IntSize offset = scrollOffset();
- IntSize newOffset = IntSize(offset.width() - wheelEvent.deltaX(), offset.height() - wheelEvent.deltaY());
- if (offset != newOffset) {
- ScrollView::scrollTo(newOffset);
- scrollPositionChanged();
- frame()->loader()->client()->didChangeScrollOffset();
- }
- return true;
- }
-
// We don't allow mouse wheeling to happen in a ScrollView that has had its scrollbars explicitly disabled.
if (!canHaveScrollbars())
return false;
diff --git a/Source/WebCore/platform/qt/ScrollbarThemeQStyle.cpp b/Source/WebCore/platform/qt/ScrollbarThemeQStyle.cpp
index f89945771..d8c440b90 100644
--- a/Source/WebCore/platform/qt/ScrollbarThemeQStyle.cpp
+++ b/Source/WebCore/platform/qt/ScrollbarThemeQStyle.cpp
@@ -34,6 +34,8 @@
#include "ScrollView.h"
#include "Scrollbar.h"
+#include <QGuiApplication>
+
namespace WebCore {
ScrollbarThemeQStyle::ScrollbarThemeQStyle()
@@ -93,8 +95,10 @@ static QStyleFacadeOption initSliderStyleOption(ScrollbarThemeClient* scrollbar,
opt.palette = widget->property("palette").value<QPalette>();
opt.rect = widget->property("rect").value<QRect>();
opt.direction = static_cast<Qt::LayoutDirection>(widget->property("layoutDirection").toInt());
- } else
+ } else {
opt.state |= QStyleFacade::State_Active;
+ opt.direction = QGuiApplication::layoutDirection();
+ }
opt.state &= ~QStyleFacade::State_HasFocus;
@@ -116,6 +120,8 @@ static QStyleFacadeOption initSliderStyleOption(ScrollbarThemeClient* scrollbar,
opt.slider.singleStep = scrollbar->lineStep();
opt.slider.minimum = 0;
opt.slider.maximum = qMax(0, scrollbar->maximum());
+ if (opt.slider.orientation == Qt::Horizontal && opt.direction == Qt::RightToLeft)
+ opt.slider.upsideDown = true;
ScrollbarPart pressedPart = scrollbar->pressedPart();
ScrollbarPart hoveredPart = scrollbar->hoveredPart();
if (pressedPart != NoPart) {
diff --git a/Source/WebCore/plugins/win/PluginViewWin.cpp b/Source/WebCore/plugins/win/PluginViewWin.cpp
index fae3c4415..d1f99bed7 100644
--- a/Source/WebCore/plugins/win/PluginViewWin.cpp
+++ b/Source/WebCore/plugins/win/PluginViewWin.cpp
@@ -350,11 +350,10 @@ static inline IntPoint contentsToNativeWindow(FrameView* view, const IntPoint& p
#if PLATFORM(QT)
// Our web view's QWidget isn't necessarily a native window itself. Map the position
// all the way up to the QWidget associated with the HWND returned as NPNVnetscapeWindow.
- PlatformPageClient client = view->hostWindow()->platformPageClient();
- return client->mapToOwnerWindow(view->contentsToWindow(point));
-#else
- return view->contentsToWindow(point);
+ if (PlatformPageClient client = view->hostWindow()->platformPageClient())
+ return client->mapToOwnerWindow(view->contentsToWindow(point));
#endif
+ return view->contentsToWindow(point);
}
static inline IntRect contentsToNativeWindow(FrameView* view, const IntRect& rect)
diff --git a/Source/WebCore/rendering/RenderLayerBacking.cpp b/Source/WebCore/rendering/RenderLayerBacking.cpp
index 955315eef..143c7d32c 100644
--- a/Source/WebCore/rendering/RenderLayerBacking.cpp
+++ b/Source/WebCore/rendering/RenderLayerBacking.cpp
@@ -1447,6 +1447,14 @@ bool canCreateTiledImage(const RenderStyle* style)
if (!image->isBitmapImage())
return false;
+#if USE(COORDINATED_GRAPHICS)
+ // Direct compositing becomes slow when the images are too
+ // large and the UIProcess asserts if one of the dimensions
+ // is larger than 2000.
+ if (2000 < std::max(image->width(), image->height()))
+ return false;
+#endif
+
return true;
}
diff --git a/Source/WebKit2/WebProcess/WebCoreSupport/WebFrameLoaderClient.cpp b/Source/WebKit2/WebProcess/WebCoreSupport/WebFrameLoaderClient.cpp
index 0c02f31e5..657a25dcc 100644
--- a/Source/WebKit2/WebProcess/WebCoreSupport/WebFrameLoaderClient.cpp
+++ b/Source/WebKit2/WebProcess/WebCoreSupport/WebFrameLoaderClient.cpp
@@ -1202,11 +1202,9 @@ void WebFrameLoaderClient::transitionToCommittedForNewPage()
m_frameCameFromPageCache = false;
- ScrollbarMode defaultScrollbarMode = shouldHideScrollbars ? ScrollbarAlwaysOff : ScrollbarAuto;
-
m_frame->coreFrame()->createView(webPage->size(), backgroundColor, isTransparent,
IntSize(), currentFixedVisibleContentRect, shouldUseFixedLayout,
- defaultScrollbarMode, /* lock */ shouldHideScrollbars, defaultScrollbarMode, /* lock */ shouldHideScrollbars);
+ ScrollbarAuto, /* lock */ shouldHideScrollbars, ScrollbarAuto, /* lock */ shouldHideScrollbars);
if (int minimumLayoutWidth = webPage->minimumLayoutSize().width()) {
int minimumLayoutHeight = std::max(webPage->minimumLayoutSize().height(), 1);
diff --git a/Tools/qmake/mkspecs/features/unix/default_post.prf b/Tools/qmake/mkspecs/features/unix/default_post.prf
index a29534d3a..2df72d909 100644
--- a/Tools/qmake/mkspecs/features/unix/default_post.prf
+++ b/Tools/qmake/mkspecs/features/unix/default_post.prf
@@ -8,8 +8,10 @@
# 387 to make layout test results same on 32 and on 64 bit builds.
# See https://bugs.webkit.org/show_bug.cgi?id=52810#c39 for details.
linux-g++*:isEqual(QT_ARCH,i386) {
- QMAKE_CFLAGS += -march=pentium4 -msse2 -mfpmath=sse
- QMAKE_CXXFLAGS += -march=pentium4 -msse2 -mfpmath=sse
+ !production_build {
+ QMAKE_CFLAGS += -march=pentium4 -msse2 -mfpmath=sse
+ QMAKE_CXXFLAGS += -march=pentium4 -msse2 -mfpmath=sse
+ }
# Use the stabs format for 32 bit debug builds to make the object files a bit smaller.
QMAKE_CXXFLAGS_DEBUG -= -g