[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 06:23:13 UTC 2009
The following commit has been merged in the debian/unstable branch:
commit 416421afc6a5c06c296eeaa5830264565ca5102e
Author: mjs <mjs at 268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Date: Wed Jul 3 12:20:19 2002 +0000
WebCore:
WebCore part of fixes for:
Radar 2950616 - JavaScript window.screenX and window.screenY always return -1
Radar 2950614 - JavaScript window.screenLeft and window.screenTop
properties are unimplemented
Radar 2950609 - JavaScript window.outerHeight and
window.outerWidth properties always return 0
* khtml/ecma/kjs_window.h:
* khtml/ecma/kjs_window.cpp:
(Window::get): Make ScreenLeft and ScreenTop synonyms for ScreenX
and ScreenY respectively.
* kwq/KWQKHTMLPart.mm:
(KWQKHTMLPartImpl::setView): Set the real part's view too.
* kwq/kdecore/kwin.h: Remove unneeded fields.
* kwq/KWQKWin.mm:
(KWin::info): Implemented.
* kwq/qt/qwidget.h:
* kwq/KWQWidget.mm:
(QWidget::winId): Return long instead of int, to make sure there
is room for a pointer even on 64-bit architectures.
(QWidget::mapToGlobal): Use the top level widget to map.
WebKit:
WebKit part of fixes for:
Radar 2950616 - JavaScript window.screenX and window.screenY always return -1
Radar 2950614 - JavaScript window.screenLeft and window.screenTop
properties are unimplemented
Radar 2950609 - JavaScript window.outerHeight and
window.outerWidth properties always return 0
* WebView.subproj/IFHTMLView.mm:
(-[IFHTMLView provisionalDataSourceChanged:]): Pass the real
document view to the newly created bridge, since it will be ready
by now and is needed by JavaScript.
git-svn-id: http://svn.webkit.org/repository/webkit/trunk@1506 268f45cc-cd09-0410-ab3c-d52691b4dbfc
diff --git a/WebCore/ChangeLog-2002-12-03 b/WebCore/ChangeLog-2002-12-03
index 32b04ea..1ce6a37 100644
--- a/WebCore/ChangeLog-2002-12-03
+++ b/WebCore/ChangeLog-2002-12-03
@@ -1,3 +1,28 @@
+2002-07-03 Maciej Stachowiak <mjs at apple.com>
+
+ WebCore part of fixes for:
+
+ Radar 2950616 - JavaScript window.screenX and window.screenY always return -1
+ Radar 2950614 - JavaScript window.screenLeft and window.screenTop
+ properties are unimplemented
+ Radar 2950609 - JavaScript window.outerHeight and
+ window.outerWidth properties always return 0
+
+ * khtml/ecma/kjs_window.h:
+ * khtml/ecma/kjs_window.cpp:
+ (Window::get): Make ScreenLeft and ScreenTop synonyms for ScreenX
+ and ScreenY respectively.
+ * kwq/KWQKHTMLPart.mm:
+ (KWQKHTMLPartImpl::setView): Set the real part's view too.
+ * kwq/kdecore/kwin.h: Remove unneeded fields.
+ * kwq/KWQKWin.mm:
+ (KWin::info): Implemented.
+ * kwq/qt/qwidget.h:
+ * kwq/KWQWidget.mm:
+ (QWidget::winId): Return long instead of int, to make sure there
+ is room for a pointer even on 64-bit architectures.
+ (QWidget::mapToGlobal): Use the top level widget to map.
+
2002-07-03 Richard Williamson <rjw at apple.com>
* kwq/KWQScrollView.mm:
diff --git a/WebCore/ChangeLog-2003-10-25 b/WebCore/ChangeLog-2003-10-25
index 32b04ea..1ce6a37 100644
--- a/WebCore/ChangeLog-2003-10-25
+++ b/WebCore/ChangeLog-2003-10-25
@@ -1,3 +1,28 @@
+2002-07-03 Maciej Stachowiak <mjs at apple.com>
+
+ WebCore part of fixes for:
+
+ Radar 2950616 - JavaScript window.screenX and window.screenY always return -1
+ Radar 2950614 - JavaScript window.screenLeft and window.screenTop
+ properties are unimplemented
+ Radar 2950609 - JavaScript window.outerHeight and
+ window.outerWidth properties always return 0
+
+ * khtml/ecma/kjs_window.h:
+ * khtml/ecma/kjs_window.cpp:
+ (Window::get): Make ScreenLeft and ScreenTop synonyms for ScreenX
+ and ScreenY respectively.
+ * kwq/KWQKHTMLPart.mm:
+ (KWQKHTMLPartImpl::setView): Set the real part's view too.
+ * kwq/kdecore/kwin.h: Remove unneeded fields.
+ * kwq/KWQKWin.mm:
+ (KWin::info): Implemented.
+ * kwq/qt/qwidget.h:
+ * kwq/KWQWidget.mm:
+ (QWidget::winId): Return long instead of int, to make sure there
+ is room for a pointer even on 64-bit architectures.
+ (QWidget::mapToGlobal): Use the top level widget to map.
+
2002-07-03 Richard Williamson <rjw at apple.com>
* kwq/KWQScrollView.mm:
diff --git a/WebCore/ChangeLog-2005-08-23 b/WebCore/ChangeLog-2005-08-23
index 32b04ea..1ce6a37 100644
--- a/WebCore/ChangeLog-2005-08-23
+++ b/WebCore/ChangeLog-2005-08-23
@@ -1,3 +1,28 @@
+2002-07-03 Maciej Stachowiak <mjs at apple.com>
+
+ WebCore part of fixes for:
+
+ Radar 2950616 - JavaScript window.screenX and window.screenY always return -1
+ Radar 2950614 - JavaScript window.screenLeft and window.screenTop
+ properties are unimplemented
+ Radar 2950609 - JavaScript window.outerHeight and
+ window.outerWidth properties always return 0
+
+ * khtml/ecma/kjs_window.h:
+ * khtml/ecma/kjs_window.cpp:
+ (Window::get): Make ScreenLeft and ScreenTop synonyms for ScreenX
+ and ScreenY respectively.
+ * kwq/KWQKHTMLPart.mm:
+ (KWQKHTMLPartImpl::setView): Set the real part's view too.
+ * kwq/kdecore/kwin.h: Remove unneeded fields.
+ * kwq/KWQKWin.mm:
+ (KWin::info): Implemented.
+ * kwq/qt/qwidget.h:
+ * kwq/KWQWidget.mm:
+ (QWidget::winId): Return long instead of int, to make sure there
+ is room for a pointer even on 64-bit architectures.
+ (QWidget::mapToGlobal): Use the top level widget to map.
+
2002-07-03 Richard Williamson <rjw at apple.com>
* kwq/KWQScrollView.mm:
diff --git a/WebCore/khtml/ecma/kjs_window.cpp b/WebCore/khtml/ecma/kjs_window.cpp
index 4cb0224..aca49dc 100644
--- a/WebCore/khtml/ecma/kjs_window.cpp
+++ b/WebCore/khtml/ecma/kjs_window.cpp
@@ -201,6 +201,10 @@ const ClassInfo Window::info = { "Window", 0, &WindowTable, 0 };
personalbar Window::Personalbar DontDelete|ReadOnly
screenX Window::ScreenX DontDelete|ReadOnly
screenY Window::ScreenY DontDelete|ReadOnly
+#ifdef APPLE_CHANGES
+ screenLeft Window::ScreenLeft DontDelete|ReadOnly
+ screenTop Window::ScreenTop DontDelete|ReadOnly
+#endif
scrollbars Window::Scrollbars DontDelete|ReadOnly
scroll Window::Scroll DontDelete|Function 2
scrollBy Window::ScrollBy DontDelete|Function 2
@@ -466,10 +470,16 @@ Value Window::get(ExecState *exec, const UString &p) const
return Value(retrieve(m_part->parentPart() ? m_part->parentPart() : (KHTMLPart*)m_part));
case Personalbar:
return Undefined(); // ###
+#ifdef APPLE_CHANGES
+ case ScreenLeft:
+#endif
case ScreenX: {
QRect sg = QApplication::desktop()->screenGeometry(QApplication::desktop()->screenNumber(m_part->view()));
return Number(m_part->view()->mapToGlobal(QPoint(0,0)).x() + sg.x());
}
+#ifdef APPLE_CHANGES
+ case ScreenTop:
+#endif
case ScreenY: {
QRect sg = QApplication::desktop()->screenGeometry(QApplication::desktop()->screenNumber(m_part->view()));
return Number(m_part->view()->mapToGlobal(QPoint(0,0)).y() + sg.y());
diff --git a/WebCore/khtml/ecma/kjs_window.h b/WebCore/khtml/ecma/kjs_window.h
index 40e8c75..0b4924c 100644
--- a/WebCore/khtml/ecma/kjs_window.h
+++ b/WebCore/khtml/ecma/kjs_window.h
@@ -107,6 +107,9 @@ namespace KJS {
InnerWidth, Length, _Location, Name, _Navigator, _Konqueror, ClientInformation,
OffscreenBuffering, Opener, OuterHeight, OuterWidth, PageXOffset, PageYOffset,
Parent, Personalbar, ScreenX, ScreenY, Scrollbars, Scroll, ScrollBy,
+#ifdef APPLE_CHANGES
+ ScreenTop, ScreenLeft,
+#endif
ScrollTo, MoveBy, MoveTo, ResizeBy, ResizeTo, Self, _Window, Top, _Screen,
Image, Option, Alert, Confirm, Prompt, Open, SetTimeout, ClearTimeout,
Focus, Blur, Close, SetInterval, ClearInterval, CaptureEvents, Onabort, Onblur,
diff --git a/WebCore/kwq/KWQKHTMLPart.mm b/WebCore/kwq/KWQKHTMLPart.mm
index b8b4a72..831288a 100644
--- a/WebCore/kwq/KWQKHTMLPart.mm
+++ b/WebCore/kwq/KWQKHTMLPart.mm
@@ -628,6 +628,7 @@ void KWQKHTMLPartImpl::setBaseURL(const KURL &url)
void KWQKHTMLPartImpl::setView(KHTMLView *view)
{
d->m_view = view;
+ part->setWidget(view);
}
void KWQKHTMLPartImpl::setTitle(const DOMString &title)
diff --git a/WebCore/kwq/KWQKHTMLPartImpl.mm b/WebCore/kwq/KWQKHTMLPartImpl.mm
index b8b4a72..831288a 100644
--- a/WebCore/kwq/KWQKHTMLPartImpl.mm
+++ b/WebCore/kwq/KWQKHTMLPartImpl.mm
@@ -628,6 +628,7 @@ void KWQKHTMLPartImpl::setBaseURL(const KURL &url)
void KWQKHTMLPartImpl::setView(KHTMLView *view)
{
d->m_view = view;
+ part->setWidget(view);
}
void KWQKHTMLPartImpl::setTitle(const DOMString &title)
diff --git a/WebCore/kwq/KWQKWin.h b/WebCore/kwq/KWQKWin.h
index bec5351..c238d08 100644
--- a/WebCore/kwq/KWQKWin.h
+++ b/WebCore/kwq/KWQKWin.h
@@ -26,19 +26,15 @@
#ifndef KWIN_H_
#define KWIN_H_
-#include <qobject.h>
#include <qrect.h>
-#include <qstring.h>
class KWin {
public:
struct Info {
QRect geometry;
- QString name;
- QString visibleName;
};
- static Info info(int win);
+ static Info info(long win);
};
#endif
diff --git a/WebCore/kwq/KWQKWin.mm b/WebCore/kwq/KWQKWin.mm
index b5318a7..db265b2 100644
--- a/WebCore/kwq/KWQKWin.mm
+++ b/WebCore/kwq/KWQKWin.mm
@@ -24,11 +24,13 @@
*/
#import <kwin.h>
-
#import <kwqdebug.h>
+#import <qwidget.h>
-KWin::Info KWin::info(int win)
+KWin::Info KWin::info(long win)
{
- _logNotYetImplemented();
- return KWin::Info();
+ KWin::Info winInfo;
+ winInfo.geometry = ((QWidget *)win)->frameGeometry();
+
+ return winInfo;
}
diff --git a/WebCore/kwq/KWQWidget.h b/WebCore/kwq/KWQWidget.h
index 86b5deb..2befd39 100644
--- a/WebCore/kwq/KWQWidget.h
+++ b/WebCore/kwq/KWQWidget.h
@@ -71,7 +71,7 @@ public:
virtual void setAutoMask(bool);
virtual void setMouseTracking(bool);
- int winId() const;
+ long winId() const;
int x() const;
int y() const;
int width() const;
diff --git a/WebCore/kwq/KWQWidget.mm b/WebCore/kwq/KWQWidget.mm
index 377a6eb..6be8eb5 100644
--- a/WebCore/kwq/KWQWidget.mm
+++ b/WebCore/kwq/KWQWidget.mm
@@ -90,9 +90,9 @@ void QWidget::setMouseTracking(bool)
{
}
-int QWidget::winId() const
+long QWidget::winId() const
{
- return (int)this;
+ return (long)this;
}
int QWidget::x() const
@@ -169,9 +169,12 @@ QPoint QWidget::mapToGlobal(const QPoint &p) const
{
// This is only used by JavaScript to implement the getting
// the screenX and screen Y coordinates.
- NSPoint sp;
- sp = [[data->view window] convertBaseToScreen: [data->view convertPoint: NSMakePoint(p.x(), p.y()) toView: nil]];
- return QPoint((int)sp.x, (int)sp.y);
+
+ if (topLevelWidget() != nil) {
+ return topLevelWidget()->mapToGlobal(p);
+ } else {
+ return p;
+ }
}
void QWidget::setFocus()
diff --git a/WebCore/kwq/kdecore/kwin.h b/WebCore/kwq/kdecore/kwin.h
index bec5351..c238d08 100644
--- a/WebCore/kwq/kdecore/kwin.h
+++ b/WebCore/kwq/kdecore/kwin.h
@@ -26,19 +26,15 @@
#ifndef KWIN_H_
#define KWIN_H_
-#include <qobject.h>
#include <qrect.h>
-#include <qstring.h>
class KWin {
public:
struct Info {
QRect geometry;
- QString name;
- QString visibleName;
};
- static Info info(int win);
+ static Info info(long win);
};
#endif
diff --git a/WebCore/kwq/qt/qwidget.h b/WebCore/kwq/qt/qwidget.h
index 86b5deb..2befd39 100644
--- a/WebCore/kwq/qt/qwidget.h
+++ b/WebCore/kwq/qt/qwidget.h
@@ -71,7 +71,7 @@ public:
virtual void setAutoMask(bool);
virtual void setMouseTracking(bool);
- int winId() const;
+ long winId() const;
int x() const;
int y() const;
int width() const;
diff --git a/WebKit/ChangeLog b/WebKit/ChangeLog
index 817c7ea..cd67237 100644
--- a/WebKit/ChangeLog
+++ b/WebKit/ChangeLog
@@ -1,5 +1,20 @@
2002-07-03 Maciej Stachowiak <mjs at apple.com>
+ WebKit part of fixes for:
+
+ Radar 2950616 - JavaScript window.screenX and window.screenY always return -1
+ Radar 2950614 - JavaScript window.screenLeft and window.screenTop
+ properties are unimplemented
+ Radar 2950609 - JavaScript window.outerHeight and
+ window.outerWidth properties always return 0
+
+ * WebView.subproj/IFHTMLView.mm:
+ (-[IFHTMLView provisionalDataSourceChanged:]): Pass the real
+ document view to the newly created bridge, since it will be ready
+ by now and is needed by JavaScript.
+
+2002-07-03 Maciej Stachowiak <mjs at apple.com>
+
* Plugins.subproj/IFPluginView.mm:
(-[IFPluginView status:]): Fix build problem. Why doesn't
compiling catch these more reliably?
diff --git a/WebKit/ChangeLog-2002-12-03 b/WebKit/ChangeLog-2002-12-03
index 817c7ea..cd67237 100644
--- a/WebKit/ChangeLog-2002-12-03
+++ b/WebKit/ChangeLog-2002-12-03
@@ -1,5 +1,20 @@
2002-07-03 Maciej Stachowiak <mjs at apple.com>
+ WebKit part of fixes for:
+
+ Radar 2950616 - JavaScript window.screenX and window.screenY always return -1
+ Radar 2950614 - JavaScript window.screenLeft and window.screenTop
+ properties are unimplemented
+ Radar 2950609 - JavaScript window.outerHeight and
+ window.outerWidth properties always return 0
+
+ * WebView.subproj/IFHTMLView.mm:
+ (-[IFHTMLView provisionalDataSourceChanged:]): Pass the real
+ document view to the newly created bridge, since it will be ready
+ by now and is needed by JavaScript.
+
+2002-07-03 Maciej Stachowiak <mjs at apple.com>
+
* Plugins.subproj/IFPluginView.mm:
(-[IFPluginView status:]): Fix build problem. Why doesn't
compiling catch these more reliably?
diff --git a/WebKit/WebView.subproj/IFHTMLView.mm b/WebKit/WebView.subproj/IFHTMLView.mm
index 003db22..ee826f2 100644
--- a/WebKit/WebView.subproj/IFHTMLView.mm
+++ b/WebKit/WebView.subproj/IFHTMLView.mm
@@ -120,18 +120,14 @@
{
IFWebCoreBridge *bridge = [dataSource _bridge];
- // Create a temporary provisional view. It will be replaced with
- // the actual view once the datasource has been committed.
- IFHTMLView *provisionalView = [[IFHTMLView alloc] initWithFrame:NSMakeRect(0,0,0,0)];
+ IFHTMLView *provisionalView = [[[dataSource webFrame] webView] documentView];
NSRect r = [self frame];
_private->provisionalWidget = [bridge createKHTMLViewWithNSView:provisionalView
- width:(int)r.size.width height:(int)r.size.height
+ width:(int)r.size.width height:(int)r.size.height
marginWidth:[[[dataSource webFrame] webView] _marginWidth]
marginHeight:[[[dataSource webFrame] webView] _marginHeight]];
-
- [provisionalView release];
}
- (void)provisionalDataSourceCommitted: (IFWebDataSource *)dataSource
@@ -536,4 +532,5 @@
widget->keyReleaseEvent(&kEvent);
}
+
@end
diff --git a/WebKit/WebView.subproj/WebHTMLView.m b/WebKit/WebView.subproj/WebHTMLView.m
index 003db22..ee826f2 100644
--- a/WebKit/WebView.subproj/WebHTMLView.m
+++ b/WebKit/WebView.subproj/WebHTMLView.m
@@ -120,18 +120,14 @@
{
IFWebCoreBridge *bridge = [dataSource _bridge];
- // Create a temporary provisional view. It will be replaced with
- // the actual view once the datasource has been committed.
- IFHTMLView *provisionalView = [[IFHTMLView alloc] initWithFrame:NSMakeRect(0,0,0,0)];
+ IFHTMLView *provisionalView = [[[dataSource webFrame] webView] documentView];
NSRect r = [self frame];
_private->provisionalWidget = [bridge createKHTMLViewWithNSView:provisionalView
- width:(int)r.size.width height:(int)r.size.height
+ width:(int)r.size.width height:(int)r.size.height
marginWidth:[[[dataSource webFrame] webView] _marginWidth]
marginHeight:[[[dataSource webFrame] webView] _marginHeight]];
-
- [provisionalView release];
}
- (void)provisionalDataSourceCommitted: (IFWebDataSource *)dataSource
@@ -536,4 +532,5 @@
widget->keyReleaseEvent(&kEvent);
}
+
@end
--
WebKit Debian packaging
More information about the Pkg-webkit-commits
mailing list