[SCM] WebKit Debian packaging branch, debian/unstable, updated. debian/1.1.15-1-40151-g37bb677
mjs
mjs at 268f45cc-cd09-0410-ab3c-d52691b4dbfc
Sat Sep 26 07:40:12 UTC 2009
The following commit has been merged in the debian/unstable branch:
commit f2fdcccd5988a83b8cce08ff439b60da7fd3df08
Author: mjs <mjs at 268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Date: Fri May 2 20:09:49 2003 +0000
WebCore:
Reviewed by Darin.
- fixed 2936175 - MALLORY: please implement onResize
* khtml/khtmlview.cpp:
(KHTMLView::resizeEvent): Put most of this in #if !APPLE_CHANGES,
since we already do the relayout and such on resize elswhere.
* kwq/KWQEvent.h: Add a minimal QResizeEvent.
* kwq/KWQKHTMLPart.h:
* kwq/KWQKHTMLPart.mm:
(KWQKHTMLPart::sendResizeEvent): Send it to the view.
* kwq/WebCoreBridge.h:
* kwq/WebCoreBridge.mm:
(-[WebCoreBridge sendResizeEvent]): Send it to the part.
WebKit:
Reviewed by Darin.
- fixed 2936175 - MALLORY: please implement onResize
* WebView.subproj/WebHTMLViewPrivate.h:
* WebView.subproj/WebHTMLView.m:
(-[WebHTMLView layoutToPageWidth:]): If we just resized and we're
not printing, make sure to send a resize event after the layout.
git-svn-id: http://svn.webkit.org/repository/webkit/trunk@4266 268f45cc-cd09-0410-ab3c-d52691b4dbfc
diff --git a/WebCore/ChangeLog-2003-10-25 b/WebCore/ChangeLog-2003-10-25
index 6386e7b..e5b43c7 100644
--- a/WebCore/ChangeLog-2003-10-25
+++ b/WebCore/ChangeLog-2003-10-25
@@ -1,3 +1,20 @@
+2003-05-02 Maciej Stachowiak <mjs at apple.com>
+
+ Reviewed by Darin.
+
+ - fixed 2936175 - MALLORY: please implement onResize
+
+ * khtml/khtmlview.cpp:
+ (KHTMLView::resizeEvent): Put most of this in #if !APPLE_CHANGES,
+ since we already do the relayout and such on resize elswhere.
+ * kwq/KWQEvent.h: Add a minimal QResizeEvent.
+ * kwq/KWQKHTMLPart.h:
+ * kwq/KWQKHTMLPart.mm:
+ (KWQKHTMLPart::sendResizeEvent): Send it to the view.
+ * kwq/WebCoreBridge.h:
+ * kwq/WebCoreBridge.mm:
+ (-[WebCoreBridge sendResizeEvent]): Send it to the part.
+
2003-05-02 David Hyatt <hyatt at apple.com>
Fix for 3184113, bottom margins didn't collapse with their children
diff --git a/WebCore/ChangeLog-2005-08-23 b/WebCore/ChangeLog-2005-08-23
index 6386e7b..e5b43c7 100644
--- a/WebCore/ChangeLog-2005-08-23
+++ b/WebCore/ChangeLog-2005-08-23
@@ -1,3 +1,20 @@
+2003-05-02 Maciej Stachowiak <mjs at apple.com>
+
+ Reviewed by Darin.
+
+ - fixed 2936175 - MALLORY: please implement onResize
+
+ * khtml/khtmlview.cpp:
+ (KHTMLView::resizeEvent): Put most of this in #if !APPLE_CHANGES,
+ since we already do the relayout and such on resize elswhere.
+ * kwq/KWQEvent.h: Add a minimal QResizeEvent.
+ * kwq/KWQKHTMLPart.h:
+ * kwq/KWQKHTMLPart.mm:
+ (KWQKHTMLPart::sendResizeEvent): Send it to the view.
+ * kwq/WebCoreBridge.h:
+ * kwq/WebCoreBridge.mm:
+ (-[WebCoreBridge sendResizeEvent]): Send it to the part.
+
2003-05-02 David Hyatt <hyatt at apple.com>
Fix for 3184113, bottom margins didn't collapse with their children
diff --git a/WebCore/khtml/khtmlview.cpp b/WebCore/khtml/khtmlview.cpp
index 3380851..049fe45 100644
--- a/WebCore/khtml/khtmlview.cpp
+++ b/WebCore/khtml/khtmlview.cpp
@@ -321,6 +321,7 @@ void KHTMLView::resizeEvent (QResizeEvent* e)
{
QScrollView::resizeEvent(e);
+#if !APPLE_CHANGES
int w = visibleWidth();
int h = visibleHeight();
@@ -330,7 +331,7 @@ void KHTMLView::resizeEvent (QResizeEvent* e)
// due to the size change.
if(visibleHeight() != h || visibleWidth() != w)
layout();
-
+#endif
if ( m_part && m_part->xmlDocImpl() )
m_part->xmlDocImpl()->dispatchWindowEvent( EventImpl::RESIZE_EVENT, false, false );
KApplication::sendPostedEvents(viewport(), QEvent::Paint);
diff --git a/WebCore/kwq/KWQEvent.h b/WebCore/kwq/KWQEvent.h
index 5cf5e3e..da0b507 100644
--- a/WebCore/kwq/KWQEvent.h
+++ b/WebCore/kwq/KWQEvent.h
@@ -49,6 +49,7 @@ public:
KeyPress,
KeyRelease,
Paint,
+ Resize
};
QEvent( Type t ) : _type(t) {}
@@ -127,11 +128,16 @@ public:
};
class QHideEvent;
-class QResizeEvent;
class QShowEvent;
class QWheelEvent;
class QContextMenuEvent;
+class QResizeEvent : public QEvent {
+ public:
+ QResizeEvent() : QEvent(Resize) {}
+};
+
+
class QCustomEvent : public QEvent {
public:
QCustomEvent(Type type, void *data = 0) : QEvent(type), d(data) { }
diff --git a/WebCore/kwq/KWQKHTMLPart.h b/WebCore/kwq/KWQKHTMLPart.h
index 2559746..b64a638 100644
--- a/WebCore/kwq/KWQKHTMLPart.h
+++ b/WebCore/kwq/KWQKHTMLPart.h
@@ -143,6 +143,7 @@ public:
khtml::RenderObject *renderer();
void forceLayout();
void forceLayoutForPageWidth(float pageWidth);
+ void sendResizeEvent();
void paint(QPainter *, const QRect &);
void paintSelectionOnly(QPainter *p, const QRect &rect);
diff --git a/WebCore/kwq/KWQKHTMLPart.mm b/WebCore/kwq/KWQKHTMLPart.mm
index 22526fa..748196e 100644
--- a/WebCore/kwq/KWQKHTMLPart.mm
+++ b/WebCore/kwq/KWQKHTMLPart.mm
@@ -1154,6 +1154,15 @@ void KWQKHTMLPart::forceLayoutForPageWidth(float pageWidth)
}
}
+void KWQKHTMLPart::sendResizeEvent()
+{
+ KHTMLView *v = d->m_view;
+ if (v) {
+ QResizeEvent e;
+ d->m_view->resizeEvent(&e);
+ }
+}
+
void KWQKHTMLPart::runJavaScriptAlert(const QString &message)
{
[_bridge runJavaScriptAlertPanelWithMessage:message.getNSString()];
diff --git a/WebCore/kwq/WebCoreBridge.h b/WebCore/kwq/WebCoreBridge.h
index b235615..5320934 100644
--- a/WebCore/kwq/WebCoreBridge.h
+++ b/WebCore/kwq/WebCoreBridge.h
@@ -144,6 +144,7 @@ enum FrameBorderStyle {
- (void)reapplyStylesForDeviceType:(WebCoreDeviceType)deviceType;
- (void)forceLayout;
- (void)forceLayoutForPageWidth:(float)pageWidth;
+- (void)sendResizeEvent;
- (BOOL)needsLayout;
- (void)adjustFrames:(NSRect)rect;
- (void)drawRect:(NSRect)rect;
diff --git a/WebCore/kwq/WebCoreBridge.mm b/WebCore/kwq/WebCoreBridge.mm
index e7fd507..cac8aed 100644
--- a/WebCore/kwq/WebCoreBridge.mm
+++ b/WebCore/kwq/WebCoreBridge.mm
@@ -359,6 +359,11 @@ static BOOL nowPrinting(WebCoreBridge *self)
[self _setupRootForPrinting:NO];
}
+- (void)sendResizeEvent
+{
+ _part->sendResizeEvent();
+}
+
- (void)drawRect:(NSRect)rect withPainter:(QPainter *)p
{
[self _setupRootForPrinting:YES];
diff --git a/WebKit/ChangeLog b/WebKit/ChangeLog
index 987e3fc..f755578 100644
--- a/WebKit/ChangeLog
+++ b/WebKit/ChangeLog
@@ -1,3 +1,15 @@
+2003-05-02 Maciej Stachowiak <mjs at apple.com>
+
+ Reviewed by Darin.
+
+ - fixed 2936175 - MALLORY: please implement onResize
+
+ * WebView.subproj/WebHTMLViewPrivate.h:
+ * WebView.subproj/WebHTMLView.m:
+ (-[WebHTMLView layoutToPageWidth:]): If we just resized and we're
+ not printing, make sure to send a resize event after the layout.
+
+
2003-05-02 Darin Adler <darin at apple.com>
Reviewed by John.
diff --git a/WebKit/WebView.subproj/WebHTMLView.m b/WebKit/WebView.subproj/WebHTMLView.m
index eec245c..e233bf5 100644
--- a/WebKit/WebView.subproj/WebHTMLView.m
+++ b/WebKit/WebView.subproj/WebHTMLView.m
@@ -317,7 +317,14 @@
}
_private->needsLayout = NO;
- _private->lastLayoutSize = [(NSClipView *)[self superview] documentVisibleRect].size;
+ if (!_private->printing) {
+ NSSize newLayoutSize = [(NSClipView *)[self superview] documentVisibleRect].size;
+ if (_private->laidOutAtLeastOnce && !NSEqualSizes(_private->lastLayoutSize, newLayoutSize)) {
+ [[self _bridge] sendResizeEvent];
+ }
+ _private->lastLayoutSize = newLayoutSize;
+ _private->laidOutAtLeastOnce = YES;
+ }
[self setNeedsDisplay:YES];
diff --git a/WebKit/WebView.subproj/WebHTMLViewPrivate.h b/WebKit/WebView.subproj/WebHTMLViewPrivate.h
index 9601781..c964911 100644
--- a/WebKit/WebView.subproj/WebHTMLViewPrivate.h
+++ b/WebKit/WebView.subproj/WebHTMLViewPrivate.h
@@ -22,6 +22,7 @@
BOOL inNextValidKeyView;
BOOL ignoringMouseDraggedEvents;
BOOL printing;
+ BOOL laidOutAtLeastOnce;
id savedSubviews;
BOOL subviewsSetAside;
--
WebKit Debian packaging
More information about the Pkg-webkit-commits
mailing list