[SCM] WebKit Debian packaging branch, debian/unstable, updated. debian/1.1.15-1-40151-g37bb677
darin
darin at 268f45cc-cd09-0410-ab3c-d52691b4dbfc
Sat Sep 26 06:20:49 UTC 2009
The following commit has been merged in the debian/unstable branch:
commit abfb2acfe7d2dc5a9d2761f700f7590c2f4c8794
Author: darin <darin at 268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Date: Thu Jun 20 23:35:01 2002 +0000
WebCore:
* kwq/KWQKCharsets.mm: Removed unneeded parts.
* kwq/KWQStyle.mm: Removed.
* kwq/KWQToolTip.mm: Removed.
* kwq/KWQVariant.mm: Simplified.
* kwq/Makefile.am: Removed KWQStyle.mm and KWQToolTip.mm.
* kwq/KWQRefPtr.h: Streamlined implementation that inlines
a bit less and is more efficient for creating empty pointers.
* kwq/KWQStyle.h: Removed unused stuff.
* kwq/kdecore/kcharsets.h: Removed unneeded parts.
* kwq/qt/qsortedlist.h: Removed unneeded parts.
* kwq/qt/qtooltip.h: Removed unneeded parts.
* kwq/qt/qvariant.h: Removed unneeded parts.
* khtml/khtmlview.cpp: (KHTMLView::~KHTMLView):
Remove unneeded APPLE_CHANGES -- no need to nil something out in
a destructor.
WebKit:
Fix for leak where sub-frame IFHTMLViews would not call _stopPlugins.
* Plugins.subproj/IFPluginView.mm:
(-[IFPluginView viewWillMoveToWindow:]):
* WebView.subproj/IFHTMLView.mm:
(-[IFHTMLView viewWillMoveToWindow:]):
Use this viewWillMoveToWindow instead of removeFromSuperview; it's a more
reliable way to handle cases where the view is removed from the view hierarchy.
Fix for IFWebFrame -> IFWebDataSource -> LoadProgressMonitor -> IFWebFrame
reference cycle.
* WebView.subproj/IFLocationChangeHandler.h: Add dataSource parameters for the
methods that don't have them so this can be "delegate" style.
* WebView.subproj/IFWebController.h: Pass a dataSource instead of a frame
when asking for a location change handler.
* WebView.subproj/IFMainURLHandleClient.mm:
(-[IFMainURLHandleClient IFURLHandle:resourceDataDidBecomeAvailable:]):
Pass dataSource for locationChangeDone.
* WebView.subproj/IFWebDataSourcePrivate.mm: (-[IFWebDataSource _startLoading:]):
Pass dataSource for locationChangeStarted.
* WebView.subproj/IFWebFrame.mm: (-[IFWebFrame setProvisionalDataSource:]):
Pass a dataSource instead of a frame when asking for a location change handler.
* WebView.subproj/IFWebFramePrivate.mm:
(-[IFWebFrame _transitionProvisionalToCommitted]): Pass dataSource for
locationChangeCommitted.
(-[IFWebFrame _isLoadComplete]): Pass dataSource for locationChangeDone.
* force-clean-timestamp: Give this mechanism a try. I'm not sure
we really need a clean build right now.
* WebView.subproj/IFWebDataSource.mm: Simplify.
WebBrowser:
Fix for IFWebFrame -> IFWebDataSource -> LoadProgressMonitor -> IFWebFrame
reference cycle.
* LoadProgressMonitor.h:
* LoadProgressMonitor.m:
(-[LoadProgressMonitor monitorLocationChangeHandler:forFrame:]):
(-[LoadProgressMonitor setError:forLocationChangeHandler:frame:]):
Changed to pass frames around, since the location change handler can't
store a frame any more.
* LocationChangeHandler.h: Updated for new API that's delegate style,
where the data source is passed into all methods rather than being retained.
* LocationChangeHandler.m:
(-[LocationChangeHandler initWithBrowserDocument:]): A frame isn't passed
any more.
(-[LocationChangeHandler dealloc]): No frame to release.
(-[LocationChangeHandler _mainFrame]): Get from document, not frame.
(-[LocationChangeHandler _loadMonitor]): Get from document, not frame.
(-[LocationChangeHandler locationChangeStartedForDataSource:]):
(-[LocationChangeHandler locationChangeCommittedForDataSource:]):
(-[LocationChangeHandler locationChangeDone:forDataSource:]):
(-[LocationChangeHandler receivedPageTitle:forDataSource:]):
(-[LocationChangeHandler serverRedirectTo:forDataSource:]):
(-[LocationChangeHandler requestContentPolicyForMIMEType:dataSource:]):
(-[LocationChangeHandler unableToImplementContentPolicy:forDataSource:]):
Use passed dataSource rather then the frame.
* WebController.m:
(-[WebController provideLocationChangeHandlerForDataSource:]):
No frame to pass in any more.
* WebBrowser.pbproj/project.pbxproj: Project Builder had some axe to grind.
git-svn-id: http://svn.webkit.org/repository/webkit/trunk@1411 268f45cc-cd09-0410-ab3c-d52691b4dbfc
diff --git a/WebCore/ChangeLog-2002-12-03 b/WebCore/ChangeLog-2002-12-03
index 0559830..87e7e62 100644
--- a/WebCore/ChangeLog-2002-12-03
+++ b/WebCore/ChangeLog-2002-12-03
@@ -1,3 +1,25 @@
+2002-06-20 Darin Adler <darin at apple.com>
+
+ * kwq/KWQKCharsets.mm: Removed unneeded parts.
+ * kwq/KWQStyle.mm: Removed.
+ * kwq/KWQToolTip.mm: Removed.
+ * kwq/KWQVariant.mm: Simplified.
+ * kwq/Makefile.am: Removed KWQStyle.mm and KWQToolTip.mm.
+
+ * kwq/KWQRefPtr.h: Streamlined implementation that inlines
+ a bit less and is more efficient for creating empty pointers.
+
+ * kwq/KWQStyle.h: Removed unused stuff.
+
+ * kwq/kdecore/kcharsets.h: Removed unneeded parts.
+ * kwq/qt/qsortedlist.h: Removed unneeded parts.
+ * kwq/qt/qtooltip.h: Removed unneeded parts.
+ * kwq/qt/qvariant.h: Removed unneeded parts.
+
+ * khtml/khtmlview.cpp: (KHTMLView::~KHTMLView):
+ Remove unneeded APPLE_CHANGES -- no need to nil something out in
+ a destructor.
+
=== Alexander-9 ===
2002-06-19 Richard Williamson (local) <rjw at apple.com>
diff --git a/WebCore/ChangeLog-2003-10-25 b/WebCore/ChangeLog-2003-10-25
index 0559830..87e7e62 100644
--- a/WebCore/ChangeLog-2003-10-25
+++ b/WebCore/ChangeLog-2003-10-25
@@ -1,3 +1,25 @@
+2002-06-20 Darin Adler <darin at apple.com>
+
+ * kwq/KWQKCharsets.mm: Removed unneeded parts.
+ * kwq/KWQStyle.mm: Removed.
+ * kwq/KWQToolTip.mm: Removed.
+ * kwq/KWQVariant.mm: Simplified.
+ * kwq/Makefile.am: Removed KWQStyle.mm and KWQToolTip.mm.
+
+ * kwq/KWQRefPtr.h: Streamlined implementation that inlines
+ a bit less and is more efficient for creating empty pointers.
+
+ * kwq/KWQStyle.h: Removed unused stuff.
+
+ * kwq/kdecore/kcharsets.h: Removed unneeded parts.
+ * kwq/qt/qsortedlist.h: Removed unneeded parts.
+ * kwq/qt/qtooltip.h: Removed unneeded parts.
+ * kwq/qt/qvariant.h: Removed unneeded parts.
+
+ * khtml/khtmlview.cpp: (KHTMLView::~KHTMLView):
+ Remove unneeded APPLE_CHANGES -- no need to nil something out in
+ a destructor.
+
=== Alexander-9 ===
2002-06-19 Richard Williamson (local) <rjw at apple.com>
diff --git a/WebCore/ChangeLog-2005-08-23 b/WebCore/ChangeLog-2005-08-23
index 0559830..87e7e62 100644
--- a/WebCore/ChangeLog-2005-08-23
+++ b/WebCore/ChangeLog-2005-08-23
@@ -1,3 +1,25 @@
+2002-06-20 Darin Adler <darin at apple.com>
+
+ * kwq/KWQKCharsets.mm: Removed unneeded parts.
+ * kwq/KWQStyle.mm: Removed.
+ * kwq/KWQToolTip.mm: Removed.
+ * kwq/KWQVariant.mm: Simplified.
+ * kwq/Makefile.am: Removed KWQStyle.mm and KWQToolTip.mm.
+
+ * kwq/KWQRefPtr.h: Streamlined implementation that inlines
+ a bit less and is more efficient for creating empty pointers.
+
+ * kwq/KWQStyle.h: Removed unused stuff.
+
+ * kwq/kdecore/kcharsets.h: Removed unneeded parts.
+ * kwq/qt/qsortedlist.h: Removed unneeded parts.
+ * kwq/qt/qtooltip.h: Removed unneeded parts.
+ * kwq/qt/qvariant.h: Removed unneeded parts.
+
+ * khtml/khtmlview.cpp: (KHTMLView::~KHTMLView):
+ Remove unneeded APPLE_CHANGES -- no need to nil something out in
+ a destructor.
+
=== Alexander-9 ===
2002-06-19 Richard Williamson (local) <rjw at apple.com>
diff --git a/WebCore/khtml/khtmlview.cpp b/WebCore/khtml/khtmlview.cpp
index 82b2510..81598ad 100644
--- a/WebCore/khtml/khtmlview.cpp
+++ b/WebCore/khtml/khtmlview.cpp
@@ -249,9 +249,6 @@ KHTMLView::~KHTMLView()
doc->detach();
}
delete d; d = 0;
-#ifdef APPLE_CHANGES
- m_part = 0;
-#endif
}
void KHTMLView::init()
diff --git a/WebCore/kwq/KWQKCharsets.h b/WebCore/kwq/KWQKCharsets.h
index b17466a..89b45ca 100644
--- a/WebCore/kwq/KWQKCharsets.h
+++ b/WebCore/kwq/KWQKCharsets.h
@@ -1,5 +1,5 @@
/*
- * Copyright (C) 2001 Apple Computer, Inc. All rights reserved.
+ * Copyright (C) 2001, 2002 Apple Computer, Inc. All rights reserved.
*
* Redistribution and use in source and binary forms, with or without
* modification, are permitted provided that the following conditions
@@ -26,41 +26,27 @@
#ifndef KCHARSETS_H_
#define KCHARSETS_H_
-#ifdef HAVE_CONFIG_H
-#include <config.h>
-#endif
-
#include <qfont.h>
#include <qstring.h>
class QTextCodec;
-// class KCharsets =============================================================
-
class KCharsets {
public:
-
- // constructors, copy constructors, and destructors ------------------------
-
- KCharsets();
- ~KCharsets();
-
- // member functions --------------------------------------------------------
-
QTextCodec *codecForName(const QString &) const;
QTextCodec *codecForName(const QString &, bool &) const;
QFont::CharSet charsetForEncoding(const QString &) const;
QFont::CharSet charsetForEncoding(const QString &, bool) const;
- void setQFont(QFont &, QFont::CharSet) const;
- void setQFont(QFont &, QString) const;
+ void setQFont(QFont &, QFont::CharSet) const { }
+ void setQFont(QFont &, QString) const { }
QString name(QFont::CharSet);
QString xCharsetName(QFont::CharSet) const;
bool supportsScript(const QFont &, QFont::CharSet);
-}; // class KCharsets ==========================================================
+};
#endif
diff --git a/WebCore/kwq/KWQKCharsets.mm b/WebCore/kwq/KWQKCharsets.mm
index 535bd80..9d30d3a 100644
--- a/WebCore/kwq/KWQKCharsets.mm
+++ b/WebCore/kwq/KWQKCharsets.mm
@@ -1,5 +1,5 @@
/*
- * Copyright (C) 2001 Apple Computer, Inc. All rights reserved.
+ * Copyright (C) 2001, 2002 Apple Computer, Inc. All rights reserved.
*
* Redistribution and use in source and binary forms, with or without
* modification, are permitted provided that the following conditions
@@ -23,26 +23,10 @@
* OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
*/
-// FIXME: obviously many functions here can be made inline
-
#import <kcharsets.h>
#import <qtextcodec.h>
#import <kwqdebug.h>
-// constructors, copy constructors, and destructors ----------------------------
-
-KCharsets::KCharsets()
-{
- // do nothing
-}
-
-KCharsets::~KCharsets()
-{
- // do nothing
-}
-
-// member functions --------------------------------------------------------
-
QTextCodec *KCharsets::codecForName(const QString &qs) const
{
return QTextCodec::codecForName(qs.latin1());
@@ -75,22 +59,6 @@ QFont::CharSet KCharsets::charsetForEncoding(const QString &, bool) const
return QFont::Unicode;
}
-void KCharsets::setQFont(QFont &font, QFont::CharSet) const
-{
- // FIXME: do we need a real implementation here?
- // [kocienda: 2001-11-05] I don't think we need to implement this
- // do nothing
-// _logNeverImplemented();
-}
-
-void KCharsets::setQFont(QFont &, QString) const
-{
- // FIXME: do we need a real implementation here?
- // [kocienda: 2001-11-05] I don't think we need to implement this
- // do nothing
-// _logNeverImplemented();
-}
-
QString KCharsets::name(QFont::CharSet)
{
// FIXME: need real implementation here
@@ -111,4 +79,3 @@ bool KCharsets::supportsScript(const QFont &, QFont::CharSet)
_logPartiallyImplemented();
return true;
}
-
diff --git a/WebCore/kwq/KWQRefPtr.h b/WebCore/kwq/KWQRefPtr.h
index 8615376..dc33f4b 100644
--- a/WebCore/kwq/KWQRefPtr.h
+++ b/WebCore/kwq/KWQRefPtr.h
@@ -1,5 +1,5 @@
/*
- * Copyright (C) 2001 Apple Computer, Inc. All rights reserved.
+ * Copyright (C) 2001, 2002 Apple Computer, Inc. All rights reserved.
*
* Redistribution and use in source and binary forms, with or without
* modification, are permitted provided that the following conditions
@@ -26,69 +26,58 @@
#ifndef KWQREFPTR_H_
#define KWQREFPTR_H_
-#ifdef HAVE_CONFIG_H
-#include <config.h>
-#endif
-
-
template <class T> class KWQRefPtr {
public:
- explicit KWQRefPtr(T* ptr = 0) : pointer(ptr)
- {
- ref();
- }
+ KWQRefPtr() : pointer(0) { }
+ explicit KWQRefPtr(T*);
+ ~KWQRefPtr() { unref(); }
- KWQRefPtr(const KWQRefPtr& r) : pointer(r.pointer)
- {
- ref();
- }
+ KWQRefPtr(const KWQRefPtr&);
+ KWQRefPtr& operator=(const KWQRefPtr&);
- KWQRefPtr& operator=(const KWQRefPtr& r) {
- if (&r != this) {
- r.ref();
- unref();
- pointer = r.pointer;
- }
- return *this;
- }
-
- ~KWQRefPtr()
- {
- unref();
- }
-
- bool isNull() const {
- return pointer == 0;
- }
-
- T& operator*() const {
- return *pointer;
- }
-
- T* operator->() const {
- return pointer;
- }
+ bool isNull() const { return pointer == 0; }
+ T& operator*() const { return *pointer; }
+ T* operator->() const { return pointer; }
private:
- void unref()
- {
- if (!isNull()) {
- if (--pointer->refCount == 0) {
- delete pointer;
- }
- }
- }
-
- void ref() const
- {
- if (!isNull()) {
- ++pointer->refCount;
- }
- }
+ void unref();
+ void ref() const;
T* pointer;
};
+template <class T> KWQRefPtr<T>::KWQRefPtr(T* p)
+ : pointer(p)
+{
+ ref();
+}
+
+template <class T> KWQRefPtr<T>::KWQRefPtr(const KWQRefPtr& r)
+ : pointer(r.pointer)
+{
+ ref();
+}
+
+template <class T> KWQRefPtr<T>& KWQRefPtr<T>::operator=(const KWQRefPtr& r)
+{
+ r.ref();
+ unref();
+ pointer = r.pointer;
+ return *this;
+}
+
+template <class T> void KWQRefPtr<T>::ref() const
+{
+ if (pointer) {
+ ++pointer->refCount;
+ }
+}
-#endif
+template <class T> void KWQRefPtr<T>::unref()
+{
+ if (pointer && --pointer->refCount == 0) {
+ delete pointer;
+ }
+}
+#endif
diff --git a/WebCore/kwq/KWQSortedList.h b/WebCore/kwq/KWQSortedList.h
index e8b4b76..34ca5d8 100644
--- a/WebCore/kwq/KWQSortedList.h
+++ b/WebCore/kwq/KWQSortedList.h
@@ -1,5 +1,5 @@
/*
- * Copyright (C) 2001 Apple Computer, Inc. All rights reserved.
+ * Copyright (C) 2001, 2002 Apple Computer, Inc. All rights reserved.
*
* Redistribution and use in source and binary forms, with or without
* modification, are permitted provided that the following conditions
@@ -26,43 +26,10 @@
#ifndef QSORTEDLIST_H_
#define QSORTEDLIST_H_
-#ifdef HAVE_CONFIG_H
-#include <config.h>
-#endif
-
-// USING_BORROWED_QSORTEDLIST ==================================================
-
-#ifdef USING_BORROWED_QSORTEDLIST
-#include <_qsortedlist.h>
-#else
-
-#include "qptrlist.h"
-
-// class QSortedList ===========================================================
+#include <qptrlist.h>
template<class T> class QSortedList : public QPtrList<T> {
public:
-
- // typedefs ----------------------------------------------------------------
- // enums -------------------------------------------------------------------
- // constants ---------------------------------------------------------------
- // static member functions -------------------------------------------------
-
- // constructors, copy constructors, and destructors ------------------------
-
- QSortedList() : QPtrList<T>() {}
- QSortedList(const QSortedList<T> &sl) : QPtrList<T>(sl) {}
- ~QSortedList() {}
-
- // Member functions --------------------------------------------------------
-
- // operators ---------------------------------------------------------------
-
- QSortedList<T> &operator=(const QSortedList<T> &sl) { QPtrList<T>::operator=(sl); return *this; }
-
-// protected -------------------------------------------------------------------
-// private ---------------------------------------------------------------------
-
virtual int compareItems(void *a, void *b)
{
T *ta = (T *)a;
@@ -75,9 +42,6 @@ public:
return 1;
}
}
-
-}; // class QSortedList ========================================================
-
-#endif // USING_BORROWED_QSORTEDLIST
+};
#endif
diff --git a/WebCore/kwq/KWQStyle.mm b/WebCore/kwq/KWQStyle.mm
deleted file mode 100644
index 80da04e..0000000
--- a/WebCore/kwq/KWQStyle.mm
+++ /dev/null
@@ -1,45 +0,0 @@
-/*
- * Copyright (C) 2001 Apple Computer, Inc. All rights reserved.
- *
- * Redistribution and use in source and binary forms, with or without
- * modification, are permitted provided that the following conditions
- * are met:
- * 1. Redistributions of source code must retain the above copyright
- * notice, this list of conditions and the following disclaimer.
- * 2. Redistributions in binary form must reproduce the above copyright
- * notice, this list of conditions and the following disclaimer in the
- * documentation and/or other materials provided with the distribution.
- *
- * THIS SOFTWARE IS PROVIDED BY APPLE COMPUTER, INC. ``AS IS'' AND ANY
- * EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
- * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
- * PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL APPLE COMPUTER, INC. OR
- * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL,
- * EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO,
- * PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR
- * PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY
- * OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
- * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
- * OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
- */
-
-#import <kwqdebug.h>
-#import <KWQStyle.h>
-
-QStyle::QStyle()
-{
- _logNotYetImplemented();
-}
-
-
-QStyle::~QStyle()
-{
- _logNotYetImplemented();
-}
-
-
-Qt::GUIStyle QStyle::guiStyle() const
-{
- return MacStyle;
-}
-
diff --git a/WebCore/kwq/KWQToolTip.h b/WebCore/kwq/KWQToolTip.h
index f520941..e0a678c 100644
--- a/WebCore/kwq/KWQToolTip.h
+++ b/WebCore/kwq/KWQToolTip.h
@@ -1,5 +1,5 @@
/*
- * Copyright (C) 2001 Apple Computer, Inc. All rights reserved.
+ * Copyright (C) 2001, 2002 Apple Computer, Inc. All rights reserved.
*
* Redistribution and use in source and binary forms, with or without
* modification, are permitted provided that the following conditions
@@ -26,58 +26,14 @@
#ifndef QTOOLTIP_H_
#define QTOOLTIP_H_
-#ifdef HAVE_CONFIG_H
-#include <config.h>
-#endif
-
-#include <qnamespace.h>
#include <qpalette.h>
-#include <qwidget.h>
-#include <qrect.h>
-#include <qsize.h>
-
-// class QToolTip ==============================================================
-class QToolTip : public Qt {
+class QToolTip {
public:
-
- // typedefs ----------------------------------------------------------------
- // enums -------------------------------------------------------------------
- // constants ---------------------------------------------------------------
-
- // static member functions -------------------------------------------------
-
- static QPalette palette();
-
- // constructors, copy constructors, and destructors ------------------------
-
- QToolTip(QWidget *);
-
-// add no-op destructor
- virtual ~QToolTip() {}
-
- // member functions --------------------------------------------------------
-
- void tip(const QRect &, const QString &);
+ QToolTip(QWidget *) { }
+ void tip(const QRect &r, const QString &s) { }
- // operators ---------------------------------------------------------------
-
-// protected -------------------------------------------------------------------
-
- virtual void maybeTip(const QPoint &) = 0;
-
-// private ---------------------------------------------------------------------
-
-private:
-
-// add copy constructor
-// this private declaration prevents copying
- QToolTip(const QToolTip &);
-
-// add assignment operator
-// this private declaration prevents assignment
- QToolTip &operator=(const QToolTip &);
-
-}; // class QToolTip ===========================================================
+ static QPalette palette() { return QPalette(); }
+};
#endif
diff --git a/WebCore/kwq/KWQToolTip.mm b/WebCore/kwq/KWQToolTip.mm
deleted file mode 100644
index af4d4ec..0000000
--- a/WebCore/kwq/KWQToolTip.mm
+++ /dev/null
@@ -1,43 +0,0 @@
-/*
- * Copyright (C) 2001 Apple Computer, Inc. All rights reserved.
- *
- * Redistribution and use in source and binary forms, with or without
- * modification, are permitted provided that the following conditions
- * are met:
- * 1. Redistributions of source code must retain the above copyright
- * notice, this list of conditions and the following disclaimer.
- * 2. Redistributions in binary form must reproduce the above copyright
- * notice, this list of conditions and the following disclaimer in the
- * documentation and/or other materials provided with the distribution.
- *
- * THIS SOFTWARE IS PROVIDED BY APPLE COMPUTER, INC. ``AS IS'' AND ANY
- * EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
- * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
- * PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL APPLE COMPUTER, INC. OR
- * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL,
- * EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO,
- * PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR
- * PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY
- * OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
- * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
- * OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
- */
-
-#import <kwqdebug.h>
-#import <qtooltip.h>
-
-QPalette QToolTip::palette()
-{
- static QPalette pal;
- return pal;
-}
-
-QToolTip::QToolTip(QWidget *)
-{
- _logNotYetImplemented();
-}
-
-void QToolTip::tip(const QRect &, const QString &)
-{
- _logNotYetImplemented();
-}
diff --git a/WebCore/kwq/KWQVariant.h b/WebCore/kwq/KWQVariant.h
index 571f572..340da07 100644
--- a/WebCore/kwq/KWQVariant.h
+++ b/WebCore/kwq/KWQVariant.h
@@ -1,5 +1,5 @@
/*
- * Copyright (C) 2001 Apple Computer, Inc. All rights reserved.
+ * Copyright (C) 2001, 2002 Apple Computer, Inc. All rights reserved.
*
* Redistribution and use in source and binary forms, with or without
* modification, are permitted provided that the following conditions
@@ -26,23 +26,14 @@
#ifndef QVARIANT_H_
#define QVARIANT_H_
-#ifdef HAVE_CONFIG_H
-#include <config.h>
-#endif
-
+#include <KWQDef.h>
#include <KWQRefPtr.h>
-typedef unsigned int uint;
-
class QString;
-// class QVariant ==============================================================
-
class QVariant {
public:
- // typedefs ----------------------------------------------------------------
-
enum Type {
Invalid,
String,
@@ -51,37 +42,27 @@ public:
Bool
};
- // enums -------------------------------------------------------------------
- // constants ---------------------------------------------------------------
- // static member functions -------------------------------------------------
-
- // constructors, copy constructors, and destructors ------------------------
-
QVariant();
QVariant(bool, int);
QVariant(double);
QVariant(const QString &);
- QVariant(const QVariant &);
~QVariant();
- // member functions --------------------------------------------------------
-
+ QVariant(const QVariant &);
+ QVariant& operator=(const QVariant &);
+
Type type() const;
+
bool toBool() const;
uint toUInt() const;
+
QString asString() const;
- // operators ---------------------------------------------------------------
-
- QVariant &operator=(const QVariant &);
-
-// protected -------------------------------------------------------------------
-// private ---------------------------------------------------------------------
private:
class QVariantPrivate;
KWQRefPtr<QVariantPrivate> d;
-}; // class QVariant ===========================================================
+};
#endif
diff --git a/WebCore/kwq/KWQVariant.mm b/WebCore/kwq/KWQVariant.mm
index d56f228..33e1d1a 100644
--- a/WebCore/kwq/KWQVariant.mm
+++ b/WebCore/kwq/KWQVariant.mm
@@ -1,5 +1,5 @@
/*
- * Copyright (C) 2001 Apple Computer, Inc. All rights reserved.
+ * Copyright (C) 2001, 2002 Apple Computer, Inc. All rights reserved.
*
* Redistribution and use in source and binary forms, with or without
* modification, are permitted provided that the following conditions
@@ -22,35 +22,15 @@
* (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
* OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
*/
-#import <kwqdebug.h>
#import <qvariant.h>
+
#import <qstring.h>
class QVariant::QVariantPrivate {
public:
- QVariantPrivate() : t(QVariant::Invalid), refCount(0)
- {
- }
-
- ~QVariantPrivate() {
- clear();
- }
-
- void clear()
- {
- switch (t) {
- case QVariant::Invalid:
- case QVariant::UInt:
- case QVariant::Double:
- case QVariant::Bool:
- break;
- case QVariant::String:
- delete (QString*)value.p;
- break;
- }
- t = QVariant::Invalid;
- }
+ QVariantPrivate(QVariant::Type type = QVariant::Invalid);
+ ~QVariantPrivate();
QVariant::Type t;
@@ -62,94 +42,100 @@ public:
} value;
int refCount;
-
- friend class KWQRefPtr<QVariantPrivate>;
};
-QVariant::QVariant() : d(new QVariantPrivate())
+QVariant::QVariantPrivate::QVariantPrivate(QVariant::Type type)
+ : t(type), refCount(0)
{
}
-
-QVariant::QVariant(bool val, int i) : d(new QVariantPrivate())
+QVariant::QVariantPrivate::~QVariantPrivate()
{
- d->t = Bool;
- d->value.d = val;
+ if (t == QVariant::String)
+ delete (QString*)value.p;
}
+QVariant::QVariant() : d(new QVariantPrivate)
+{
+}
-QVariant::QVariant(double val) : d(new QVariantPrivate())
+QVariant::QVariant(bool val, int i) : d(new QVariantPrivate(Bool))
{
- d->t = Double;
d->value.d = val;
}
+QVariant::QVariant(double val) : d(new QVariantPrivate(Double))
+{
+ d->value.d = val;
+}
-QVariant::QVariant(const QString &s) : d(new QVariantPrivate())
+QVariant::QVariant(const QString &s) : d(new QVariantPrivate(String))
{
- d->t = String;
d->value.p = new QString(s);
}
-
-QVariant::QVariant(const QVariant &other) : d(0)
+QVariant::~QVariant()
{
- d = other.d;
}
-
-QVariant::~QVariant()
+QVariant::QVariant(const QVariant &v)
+ : d(v.d)
{
}
+QVariant &QVariant::operator=(const QVariant &v)
+{
+ d = v.d;
+ return *this;
+}
QVariant::Type QVariant::type() const
{
return d->t;
}
-
bool QVariant::toBool() const
{
- if (d->t == Bool) {
+ switch (d->t) {
+ case Bool:
return d->value.b;
- }
- if (d->t == Double) {
+ case UInt:
+ return d->value.u;
+ case Double:
return d->value.d != 0.0;
+ case Invalid:
+ case String:
+ break;
}
- if (d->t == UInt) {
- return d->value.u != 0;
- }
-
- return FALSE;
+ return false;
}
-
uint QVariant::toUInt() const
{
- if (d->t == UInt) {
- return (int)d->value.u;
- }
- if (d->t == Double) {
- return (int)d->value.d;
- }
- if (d->t == Bool) {
- return (int)d->value.b;
+ switch (d->t) {
+ case Bool:
+ return d->value.b;
+ case UInt:
+ return d->value.u;
+ case Double:
+ return (uint)d->value.d;
+ case Invalid:
+ case String:
+ break;
}
-
return 0;
}
-
QString QVariant::asString() const
-{
- return *((QString *)d->value.p);
-}
-
-
-QVariant &QVariant::operator=(const QVariant &other)
{
- d = other.d;
- return *this;
+ switch (d->t) {
+ case String:
+ return *(QString *)d->value.p;
+ case Invalid:
+ case Bool:
+ case UInt:
+ case Double:
+ break;
+ }
+ return QString();
}
-
diff --git a/WebCore/kwq/Makefile.am b/WebCore/kwq/Makefile.am
index eb08f10..c882a1e 100644
--- a/WebCore/kwq/Makefile.am
+++ b/WebCore/kwq/Makefile.am
@@ -92,12 +92,10 @@ libkwq_o_SOURCES = \
KWQScrollView.mm \
KWQString.mm \
KWQStringList.mm \
- KWQStyle.mm \
KWQStyleSheet.mm \
KWQTextArea.mm \
KWQTextEdit.mm \
KWQTimer.mm \
- KWQToolTip.mm \
KWQValueListImpl.mm \
KWQVariant.mm \
KWQVectorImpl.mm \
diff --git a/WebCore/kwq/kdecore/kcharsets.h b/WebCore/kwq/kdecore/kcharsets.h
index b17466a..89b45ca 100644
--- a/WebCore/kwq/kdecore/kcharsets.h
+++ b/WebCore/kwq/kdecore/kcharsets.h
@@ -1,5 +1,5 @@
/*
- * Copyright (C) 2001 Apple Computer, Inc. All rights reserved.
+ * Copyright (C) 2001, 2002 Apple Computer, Inc. All rights reserved.
*
* Redistribution and use in source and binary forms, with or without
* modification, are permitted provided that the following conditions
@@ -26,41 +26,27 @@
#ifndef KCHARSETS_H_
#define KCHARSETS_H_
-#ifdef HAVE_CONFIG_H
-#include <config.h>
-#endif
-
#include <qfont.h>
#include <qstring.h>
class QTextCodec;
-// class KCharsets =============================================================
-
class KCharsets {
public:
-
- // constructors, copy constructors, and destructors ------------------------
-
- KCharsets();
- ~KCharsets();
-
- // member functions --------------------------------------------------------
-
QTextCodec *codecForName(const QString &) const;
QTextCodec *codecForName(const QString &, bool &) const;
QFont::CharSet charsetForEncoding(const QString &) const;
QFont::CharSet charsetForEncoding(const QString &, bool) const;
- void setQFont(QFont &, QFont::CharSet) const;
- void setQFont(QFont &, QString) const;
+ void setQFont(QFont &, QFont::CharSet) const { }
+ void setQFont(QFont &, QString) const { }
QString name(QFont::CharSet);
QString xCharsetName(QFont::CharSet) const;
bool supportsScript(const QFont &, QFont::CharSet);
-}; // class KCharsets ==========================================================
+};
#endif
diff --git a/WebCore/kwq/qt/qsortedlist.h b/WebCore/kwq/qt/qsortedlist.h
index e8b4b76..34ca5d8 100644
--- a/WebCore/kwq/qt/qsortedlist.h
+++ b/WebCore/kwq/qt/qsortedlist.h
@@ -1,5 +1,5 @@
/*
- * Copyright (C) 2001 Apple Computer, Inc. All rights reserved.
+ * Copyright (C) 2001, 2002 Apple Computer, Inc. All rights reserved.
*
* Redistribution and use in source and binary forms, with or without
* modification, are permitted provided that the following conditions
@@ -26,43 +26,10 @@
#ifndef QSORTEDLIST_H_
#define QSORTEDLIST_H_
-#ifdef HAVE_CONFIG_H
-#include <config.h>
-#endif
-
-// USING_BORROWED_QSORTEDLIST ==================================================
-
-#ifdef USING_BORROWED_QSORTEDLIST
-#include <_qsortedlist.h>
-#else
-
-#include "qptrlist.h"
-
-// class QSortedList ===========================================================
+#include <qptrlist.h>
template<class T> class QSortedList : public QPtrList<T> {
public:
-
- // typedefs ----------------------------------------------------------------
- // enums -------------------------------------------------------------------
- // constants ---------------------------------------------------------------
- // static member functions -------------------------------------------------
-
- // constructors, copy constructors, and destructors ------------------------
-
- QSortedList() : QPtrList<T>() {}
- QSortedList(const QSortedList<T> &sl) : QPtrList<T>(sl) {}
- ~QSortedList() {}
-
- // Member functions --------------------------------------------------------
-
- // operators ---------------------------------------------------------------
-
- QSortedList<T> &operator=(const QSortedList<T> &sl) { QPtrList<T>::operator=(sl); return *this; }
-
-// protected -------------------------------------------------------------------
-// private ---------------------------------------------------------------------
-
virtual int compareItems(void *a, void *b)
{
T *ta = (T *)a;
@@ -75,9 +42,6 @@ public:
return 1;
}
}
-
-}; // class QSortedList ========================================================
-
-#endif // USING_BORROWED_QSORTEDLIST
+};
#endif
diff --git a/WebCore/kwq/qt/qtooltip.h b/WebCore/kwq/qt/qtooltip.h
index f520941..e0a678c 100644
--- a/WebCore/kwq/qt/qtooltip.h
+++ b/WebCore/kwq/qt/qtooltip.h
@@ -1,5 +1,5 @@
/*
- * Copyright (C) 2001 Apple Computer, Inc. All rights reserved.
+ * Copyright (C) 2001, 2002 Apple Computer, Inc. All rights reserved.
*
* Redistribution and use in source and binary forms, with or without
* modification, are permitted provided that the following conditions
@@ -26,58 +26,14 @@
#ifndef QTOOLTIP_H_
#define QTOOLTIP_H_
-#ifdef HAVE_CONFIG_H
-#include <config.h>
-#endif
-
-#include <qnamespace.h>
#include <qpalette.h>
-#include <qwidget.h>
-#include <qrect.h>
-#include <qsize.h>
-
-// class QToolTip ==============================================================
-class QToolTip : public Qt {
+class QToolTip {
public:
-
- // typedefs ----------------------------------------------------------------
- // enums -------------------------------------------------------------------
- // constants ---------------------------------------------------------------
-
- // static member functions -------------------------------------------------
-
- static QPalette palette();
-
- // constructors, copy constructors, and destructors ------------------------
-
- QToolTip(QWidget *);
-
-// add no-op destructor
- virtual ~QToolTip() {}
-
- // member functions --------------------------------------------------------
-
- void tip(const QRect &, const QString &);
+ QToolTip(QWidget *) { }
+ void tip(const QRect &r, const QString &s) { }
- // operators ---------------------------------------------------------------
-
-// protected -------------------------------------------------------------------
-
- virtual void maybeTip(const QPoint &) = 0;
-
-// private ---------------------------------------------------------------------
-
-private:
-
-// add copy constructor
-// this private declaration prevents copying
- QToolTip(const QToolTip &);
-
-// add assignment operator
-// this private declaration prevents assignment
- QToolTip &operator=(const QToolTip &);
-
-}; // class QToolTip ===========================================================
+ static QPalette palette() { return QPalette(); }
+};
#endif
diff --git a/WebCore/kwq/qt/qvariant.h b/WebCore/kwq/qt/qvariant.h
index 571f572..340da07 100644
--- a/WebCore/kwq/qt/qvariant.h
+++ b/WebCore/kwq/qt/qvariant.h
@@ -1,5 +1,5 @@
/*
- * Copyright (C) 2001 Apple Computer, Inc. All rights reserved.
+ * Copyright (C) 2001, 2002 Apple Computer, Inc. All rights reserved.
*
* Redistribution and use in source and binary forms, with or without
* modification, are permitted provided that the following conditions
@@ -26,23 +26,14 @@
#ifndef QVARIANT_H_
#define QVARIANT_H_
-#ifdef HAVE_CONFIG_H
-#include <config.h>
-#endif
-
+#include <KWQDef.h>
#include <KWQRefPtr.h>
-typedef unsigned int uint;
-
class QString;
-// class QVariant ==============================================================
-
class QVariant {
public:
- // typedefs ----------------------------------------------------------------
-
enum Type {
Invalid,
String,
@@ -51,37 +42,27 @@ public:
Bool
};
- // enums -------------------------------------------------------------------
- // constants ---------------------------------------------------------------
- // static member functions -------------------------------------------------
-
- // constructors, copy constructors, and destructors ------------------------
-
QVariant();
QVariant(bool, int);
QVariant(double);
QVariant(const QString &);
- QVariant(const QVariant &);
~QVariant();
- // member functions --------------------------------------------------------
-
+ QVariant(const QVariant &);
+ QVariant& operator=(const QVariant &);
+
Type type() const;
+
bool toBool() const;
uint toUInt() const;
+
QString asString() const;
- // operators ---------------------------------------------------------------
-
- QVariant &operator=(const QVariant &);
-
-// protected -------------------------------------------------------------------
-// private ---------------------------------------------------------------------
private:
class QVariantPrivate;
KWQRefPtr<QVariantPrivate> d;
-}; // class QVariant ===========================================================
+};
#endif
diff --git a/WebKit/ChangeLog b/WebKit/ChangeLog
index a3e1dd5..3e28250 100644
--- a/WebKit/ChangeLog
+++ b/WebKit/ChangeLog
@@ -1,3 +1,42 @@
+2002-06-20 Darin Adler <darin at apple.com>
+
+ Fix for leak where sub-frame IFHTMLViews would not call _stopPlugins.
+
+ * Plugins.subproj/IFPluginView.mm:
+ (-[IFPluginView viewWillMoveToWindow:]):
+ * WebView.subproj/IFHTMLView.mm:
+ (-[IFHTMLView viewWillMoveToWindow:]):
+ Use this viewWillMoveToWindow instead of removeFromSuperview; it's a more
+ reliable way to handle cases where the view is removed from the view hierarchy.
+
+ Fix for IFWebFrame -> IFWebDataSource -> LoadProgressMonitor -> IFWebFrame
+ reference cycle.
+
+ * WebView.subproj/IFLocationChangeHandler.h: Add dataSource parameters for the
+ methods that don't have them so this can be "delegate" style.
+ * WebView.subproj/IFWebController.h: Pass a dataSource instead of a frame
+ when asking for a location change handler.
+
+ * WebView.subproj/IFMainURLHandleClient.mm:
+ (-[IFMainURLHandleClient IFURLHandle:resourceDataDidBecomeAvailable:]):
+ Pass dataSource for locationChangeDone.
+
+ * WebView.subproj/IFWebDataSourcePrivate.mm: (-[IFWebDataSource _startLoading:]):
+ Pass dataSource for locationChangeStarted.
+
+ * WebView.subproj/IFWebFrame.mm: (-[IFWebFrame setProvisionalDataSource:]):
+ Pass a dataSource instead of a frame when asking for a location change handler.
+
+ * WebView.subproj/IFWebFramePrivate.mm:
+ (-[IFWebFrame _transitionProvisionalToCommitted]): Pass dataSource for
+ locationChangeCommitted.
+ (-[IFWebFrame _isLoadComplete]): Pass dataSource for locationChangeDone.
+
+ * force-clean-timestamp: Give this mechanism a try. I'm not sure
+ we really need a clean build right now.
+
+ * WebView.subproj/IFWebDataSource.mm: Simplify.
+
2002-06-20 Kenneth Kocienda <kocienda at apple.com>
A more complete fix for this bug:
diff --git a/WebKit/ChangeLog-2002-12-03 b/WebKit/ChangeLog-2002-12-03
index a3e1dd5..3e28250 100644
--- a/WebKit/ChangeLog-2002-12-03
+++ b/WebKit/ChangeLog-2002-12-03
@@ -1,3 +1,42 @@
+2002-06-20 Darin Adler <darin at apple.com>
+
+ Fix for leak where sub-frame IFHTMLViews would not call _stopPlugins.
+
+ * Plugins.subproj/IFPluginView.mm:
+ (-[IFPluginView viewWillMoveToWindow:]):
+ * WebView.subproj/IFHTMLView.mm:
+ (-[IFHTMLView viewWillMoveToWindow:]):
+ Use this viewWillMoveToWindow instead of removeFromSuperview; it's a more
+ reliable way to handle cases where the view is removed from the view hierarchy.
+
+ Fix for IFWebFrame -> IFWebDataSource -> LoadProgressMonitor -> IFWebFrame
+ reference cycle.
+
+ * WebView.subproj/IFLocationChangeHandler.h: Add dataSource parameters for the
+ methods that don't have them so this can be "delegate" style.
+ * WebView.subproj/IFWebController.h: Pass a dataSource instead of a frame
+ when asking for a location change handler.
+
+ * WebView.subproj/IFMainURLHandleClient.mm:
+ (-[IFMainURLHandleClient IFURLHandle:resourceDataDidBecomeAvailable:]):
+ Pass dataSource for locationChangeDone.
+
+ * WebView.subproj/IFWebDataSourcePrivate.mm: (-[IFWebDataSource _startLoading:]):
+ Pass dataSource for locationChangeStarted.
+
+ * WebView.subproj/IFWebFrame.mm: (-[IFWebFrame setProvisionalDataSource:]):
+ Pass a dataSource instead of a frame when asking for a location change handler.
+
+ * WebView.subproj/IFWebFramePrivate.mm:
+ (-[IFWebFrame _transitionProvisionalToCommitted]): Pass dataSource for
+ locationChangeCommitted.
+ (-[IFWebFrame _isLoadComplete]): Pass dataSource for locationChangeDone.
+
+ * force-clean-timestamp: Give this mechanism a try. I'm not sure
+ we really need a clean build right now.
+
+ * WebView.subproj/IFWebDataSource.mm: Simplify.
+
2002-06-20 Kenneth Kocienda <kocienda at apple.com>
A more complete fix for this bug:
diff --git a/WebKit/Plugins.subproj/IFPluginView.mm b/WebKit/Plugins.subproj/IFPluginView.mm
index a7c7e13..2ef9b73 100644
--- a/WebKit/Plugins.subproj/IFPluginView.mm
+++ b/WebKit/Plugins.subproj/IFPluginView.mm
@@ -569,10 +569,11 @@ static char *newCString(NSString *string)
return YES;
}
-- (void)removeFromSuperview
+- (void)viewWillMoveToWindow:(NSWindow *)newWindow
{
- [self stop];
- [super removeFromSuperview];
+ if (!newWindow)
+ [self stop];
+ [super viewWillMoveToWindow:newWindow];
}
#pragma mark NOTIFICATIONS
diff --git a/WebKit/Plugins.subproj/WebPluginView.m b/WebKit/Plugins.subproj/WebPluginView.m
index a7c7e13..2ef9b73 100644
--- a/WebKit/Plugins.subproj/WebPluginView.m
+++ b/WebKit/Plugins.subproj/WebPluginView.m
@@ -569,10 +569,11 @@ static char *newCString(NSString *string)
return YES;
}
-- (void)removeFromSuperview
+- (void)viewWillMoveToWindow:(NSWindow *)newWindow
{
- [self stop];
- [super removeFromSuperview];
+ if (!newWindow)
+ [self stop];
+ [super viewWillMoveToWindow:newWindow];
}
#pragma mark NOTIFICATIONS
diff --git a/WebKit/WebView.subproj/IFHTMLView.mm b/WebKit/WebView.subproj/IFHTMLView.mm
index 0fa7bca..fd3bd1f 100644
--- a/WebKit/WebView.subproj/IFHTMLView.mm
+++ b/WebKit/WebView.subproj/IFHTMLView.mm
@@ -77,19 +77,14 @@
}
-- (void)removeFromSuperview
+- (void)viewWillMoveToWindow:(NSWindow *)window
{
- [self _stopPlugins];
- [super removeFromSuperview];
+ if (!window)
+ [self _stopPlugins];
+ [super viewWillMoveToWindow:window];
}
-- (void)removeFromSuperviewWithoutNeedingDisplay
-{
- [self _stopPlugins];
- [super removeFromSuperviewWithoutNeedingDisplay];
-}
-
// This method is typically called by the view's controller when
// the data source is changed.
- (void)provisionalDataSourceChanged:(IFWebDataSource *)dataSource
diff --git a/WebKit/WebView.subproj/IFLocationChangeHandler.h b/WebKit/WebView.subproj/IFLocationChangeHandler.h
index aa9f9dd..5f5929f 100644
--- a/WebKit/WebView.subproj/IFLocationChangeHandler.h
+++ b/WebKit/WebView.subproj/IFLocationChangeHandler.h
@@ -45,16 +45,16 @@ typedef enum {
@protocol IFLocationChangeHandler <NSObject>
-- (void)locationChangeStarted;
+- (void)locationChangeStartedForDataSource: (IFWebDataSource *)dataSource;
// Sent after locationChangeStarted.
// Implementations typically call haveContentPolicy:forLocationChangeHandler: on IFWebController
// after determining the appropriate policy, perhaps by presenting a non-blocking dialog to the user.
- (void)requestContentPolicyForMIMEType: (NSString *)type dataSource: (IFWebDataSource *)dataSource;
-- (void)locationChangeCommitted;
+- (void)locationChangeCommittedForDataSource: (IFWebDataSource *)dataSource;
-- (void)locationChangeDone: (IFError *)error;
+- (void)locationChangeDone: (IFError *)error forDataSource: (IFWebDataSource *)dataSource;
- (void)receivedPageTitle: (NSString *)title forDataSource: (IFWebDataSource *)dataSource;
diff --git a/WebKit/WebView.subproj/IFMainURLHandleClient.mm b/WebKit/WebView.subproj/IFMainURLHandleClient.mm
index 5f8b074..0c5a455 100644
--- a/WebKit/WebView.subproj/IFMainURLHandleClient.mm
+++ b/WebKit/WebView.subproj/IFMainURLHandleClient.mm
@@ -169,7 +169,7 @@
}else if(contentPolicy == IFContentPolicySave || contentPolicy == IFContentPolicyOpenExternally){
if(!downloadHandler){
[frame->_private setProvisionalDataSource:nil];
- [[dataSource _locationChangeHandler] locationChangeDone:nil];
+ [[dataSource _locationChangeHandler] locationChangeDone:nil forDataSource:dataSource];
downloadHandler = [[IFDownloadHandler alloc] initWithDataSource:dataSource];
}
[downloadHandler receivedData:data];
diff --git a/WebKit/WebView.subproj/IFWebController.h b/WebKit/WebView.subproj/IFWebController.h
index accd598..bd4f2c7 100644
--- a/WebKit/WebView.subproj/IFWebController.h
+++ b/WebKit/WebView.subproj/IFWebController.h
@@ -82,7 +82,7 @@ typedef enum {
@protocol IFWebControllerPolicyHandler <NSObject>
-- (id <IFLocationChangeHandler>)provideLocationChangeHandlerForFrame: (IFWebFrame *)frame;
+- (id <IFLocationChangeHandler>)provideLocationChangeHandlerForDataSource: (IFWebDataSource *)dataSource;
// URLPolicyForURL: is used to determine what to do BEFORE a URL is loaded, i.e.
// before it is clicked or loaded via a URL bar. Clients can choose to handle the
diff --git a/WebKit/WebView.subproj/IFWebDataSource.mm b/WebKit/WebView.subproj/IFWebDataSource.mm
index 7a035bf..09f9699 100644
--- a/WebKit/WebView.subproj/IFWebDataSource.mm
+++ b/WebKit/WebView.subproj/IFWebDataSource.mm
@@ -19,25 +19,20 @@
@implementation IFWebDataSource
-- (void)_commonInitialization
-{
- _private = [[IFWebDataSourcePrivate alloc] init];
-}
-
-(id)initWithURL:(NSURL *)theURL
{
- return [self initWithURL:theURL attributes:nil flags:0];
+ return [self initWithURL:theURL attributes:nil flags:0];
}
-(id)initWithURL:(NSURL *)theURL attributes:(NSDictionary *)theAttributes
{
- return [self initWithURL:theURL attributes:theAttributes flags:0];
+ return [self initWithURL:theURL attributes:theAttributes flags:0];
}
-(id)initWithURL:(NSURL *)theURL attributes:(NSDictionary *)theAttributes flags:(unsigned)theFlags;
{
[super init];
- [self _commonInitialization];
+ _private = [[IFWebDataSourcePrivate alloc] init];
_private->inputURL = [theURL retain];
_private->mainHandle = [[IFURLHandle alloc] initWithURL: _private->inputURL attributes:theAttributes flags:theFlags];
return self;
diff --git a/WebKit/WebView.subproj/IFWebDataSourcePrivate.mm b/WebKit/WebView.subproj/IFWebDataSourcePrivate.mm
index b3611ec..00de98f 100644
--- a/WebKit/WebView.subproj/IFWebDataSourcePrivate.mm
+++ b/WebKit/WebView.subproj/IFWebDataSourcePrivate.mm
@@ -177,7 +177,7 @@ static NSMutableDictionary *_repTypes=nil;
[self _setLoading:YES];
- [[self _locationChangeHandler] locationChangeStarted];
+ [[self _locationChangeHandler] locationChangeStartedForDataSource:self];
}
- (void)_addURLHandle: (IFURLHandle *)handle
diff --git a/WebKit/WebView.subproj/IFWebFrame.mm b/WebKit/WebView.subproj/IFWebFrame.mm
index 505eb1e..bdf2a80 100644
--- a/WebKit/WebView.subproj/IFWebFrame.mm
+++ b/WebKit/WebView.subproj/IFWebFrame.mm
@@ -148,7 +148,7 @@
[self stopLoading];
}
- locationChangeHandler = [[[self controller] policyHandler] provideLocationChangeHandlerForFrame: self];
+ locationChangeHandler = [[[self controller] policyHandler] provideLocationChangeHandlerForDataSource: newDataSource];
[newDataSource _setLocationChangeHandler: locationChangeHandler];
diff --git a/WebKit/WebView.subproj/IFWebFramePrivate.mm b/WebKit/WebView.subproj/IFWebFramePrivate.mm
index 98bdbe8..083af91 100644
--- a/WebKit/WebView.subproj/IFWebFramePrivate.mm
+++ b/WebKit/WebView.subproj/IFWebFramePrivate.mm
@@ -38,7 +38,9 @@ static const char * const stateNames[6] = {
{
[webView _setController: nil];
[dataSource _setController: nil];
+ [dataSource _setLocationChangeHandler: nil];
[provisionalDataSource _setController: nil];
+ [provisionalDataSource _setLocationChangeHandler: nil];
[name autorelease];
[webView autorelease];
@@ -70,6 +72,7 @@ static const char * const stateNames[6] = {
{
if (dataSource != d) {
[dataSource _setController: nil];
+ [dataSource _setLocationChangeHandler: nil];
[dataSource autorelease];
dataSource = [d retain];
}
@@ -245,7 +248,7 @@ static const char * const stateNames[6] = {
[self _setState: IFWEBFRAMESTATE_COMMITTED_PAGE];
- [[[self dataSource] _locationChangeHandler] locationChangeCommitted];
+ [[[self dataSource] _locationChangeHandler] locationChangeCommittedForDataSource:[self dataSource]];
// If we have a title let the controller know about it.
if ([[self dataSource] pageTitle])
@@ -323,7 +326,7 @@ static const char * const stateNames[6] = {
if (![pd isLoading]) {
WEBKITDEBUGLEVEL (WEBKIT_LOG_LOADING, "%s: checking complete in IFWEBFRAMESTATE_PROVISIONAL, load done\n", [[self name] cString]);
- [[pd _locationChangeHandler] locationChangeDone: [pd mainDocumentError]];
+ [[pd _locationChangeHandler] locationChangeDone: [pd mainDocumentError] forDataSource:pd];
// We now the provisional data source didn't cut the mustard, release it.
[_private setProvisionalDataSource: nil];
@@ -379,7 +382,7 @@ static const char * const stateNames[6] = {
[thisDocumentView setNeedsDisplay: YES];
[thisDocumentView display];
- [[ds _locationChangeHandler] locationChangeDone: [ds mainDocumentError]];
+ [[ds _locationChangeHandler] locationChangeDone: [ds mainDocumentError] forDataSource:ds];
//if ([ds isDocumentHTML])
// [[ds representation] part]->closeURL();
diff --git a/WebKit/WebView.subproj/WebController.h b/WebKit/WebView.subproj/WebController.h
index accd598..bd4f2c7 100644
--- a/WebKit/WebView.subproj/WebController.h
+++ b/WebKit/WebView.subproj/WebController.h
@@ -82,7 +82,7 @@ typedef enum {
@protocol IFWebControllerPolicyHandler <NSObject>
-- (id <IFLocationChangeHandler>)provideLocationChangeHandlerForFrame: (IFWebFrame *)frame;
+- (id <IFLocationChangeHandler>)provideLocationChangeHandlerForDataSource: (IFWebDataSource *)dataSource;
// URLPolicyForURL: is used to determine what to do BEFORE a URL is loaded, i.e.
// before it is clicked or loaded via a URL bar. Clients can choose to handle the
diff --git a/WebKit/WebView.subproj/WebDataSource.m b/WebKit/WebView.subproj/WebDataSource.m
index 7a035bf..09f9699 100644
--- a/WebKit/WebView.subproj/WebDataSource.m
+++ b/WebKit/WebView.subproj/WebDataSource.m
@@ -19,25 +19,20 @@
@implementation IFWebDataSource
-- (void)_commonInitialization
-{
- _private = [[IFWebDataSourcePrivate alloc] init];
-}
-
-(id)initWithURL:(NSURL *)theURL
{
- return [self initWithURL:theURL attributes:nil flags:0];
+ return [self initWithURL:theURL attributes:nil flags:0];
}
-(id)initWithURL:(NSURL *)theURL attributes:(NSDictionary *)theAttributes
{
- return [self initWithURL:theURL attributes:theAttributes flags:0];
+ return [self initWithURL:theURL attributes:theAttributes flags:0];
}
-(id)initWithURL:(NSURL *)theURL attributes:(NSDictionary *)theAttributes flags:(unsigned)theFlags;
{
[super init];
- [self _commonInitialization];
+ _private = [[IFWebDataSourcePrivate alloc] init];
_private->inputURL = [theURL retain];
_private->mainHandle = [[IFURLHandle alloc] initWithURL: _private->inputURL attributes:theAttributes flags:theFlags];
return self;
diff --git a/WebKit/WebView.subproj/WebDataSourcePrivate.m b/WebKit/WebView.subproj/WebDataSourcePrivate.m
index b3611ec..00de98f 100644
--- a/WebKit/WebView.subproj/WebDataSourcePrivate.m
+++ b/WebKit/WebView.subproj/WebDataSourcePrivate.m
@@ -177,7 +177,7 @@ static NSMutableDictionary *_repTypes=nil;
[self _setLoading:YES];
- [[self _locationChangeHandler] locationChangeStarted];
+ [[self _locationChangeHandler] locationChangeStartedForDataSource:self];
}
- (void)_addURLHandle: (IFURLHandle *)handle
diff --git a/WebKit/WebView.subproj/WebFrame.m b/WebKit/WebView.subproj/WebFrame.m
index 505eb1e..bdf2a80 100644
--- a/WebKit/WebView.subproj/WebFrame.m
+++ b/WebKit/WebView.subproj/WebFrame.m
@@ -148,7 +148,7 @@
[self stopLoading];
}
- locationChangeHandler = [[[self controller] policyHandler] provideLocationChangeHandlerForFrame: self];
+ locationChangeHandler = [[[self controller] policyHandler] provideLocationChangeHandlerForDataSource: newDataSource];
[newDataSource _setLocationChangeHandler: locationChangeHandler];
diff --git a/WebKit/WebView.subproj/WebFrameLoadDelegate.h b/WebKit/WebView.subproj/WebFrameLoadDelegate.h
index aa9f9dd..5f5929f 100644
--- a/WebKit/WebView.subproj/WebFrameLoadDelegate.h
+++ b/WebKit/WebView.subproj/WebFrameLoadDelegate.h
@@ -45,16 +45,16 @@ typedef enum {
@protocol IFLocationChangeHandler <NSObject>
-- (void)locationChangeStarted;
+- (void)locationChangeStartedForDataSource: (IFWebDataSource *)dataSource;
// Sent after locationChangeStarted.
// Implementations typically call haveContentPolicy:forLocationChangeHandler: on IFWebController
// after determining the appropriate policy, perhaps by presenting a non-blocking dialog to the user.
- (void)requestContentPolicyForMIMEType: (NSString *)type dataSource: (IFWebDataSource *)dataSource;
-- (void)locationChangeCommitted;
+- (void)locationChangeCommittedForDataSource: (IFWebDataSource *)dataSource;
-- (void)locationChangeDone: (IFError *)error;
+- (void)locationChangeDone: (IFError *)error forDataSource: (IFWebDataSource *)dataSource;
- (void)receivedPageTitle: (NSString *)title forDataSource: (IFWebDataSource *)dataSource;
diff --git a/WebKit/WebView.subproj/WebFramePrivate.m b/WebKit/WebView.subproj/WebFramePrivate.m
index 98bdbe8..083af91 100644
--- a/WebKit/WebView.subproj/WebFramePrivate.m
+++ b/WebKit/WebView.subproj/WebFramePrivate.m
@@ -38,7 +38,9 @@ static const char * const stateNames[6] = {
{
[webView _setController: nil];
[dataSource _setController: nil];
+ [dataSource _setLocationChangeHandler: nil];
[provisionalDataSource _setController: nil];
+ [provisionalDataSource _setLocationChangeHandler: nil];
[name autorelease];
[webView autorelease];
@@ -70,6 +72,7 @@ static const char * const stateNames[6] = {
{
if (dataSource != d) {
[dataSource _setController: nil];
+ [dataSource _setLocationChangeHandler: nil];
[dataSource autorelease];
dataSource = [d retain];
}
@@ -245,7 +248,7 @@ static const char * const stateNames[6] = {
[self _setState: IFWEBFRAMESTATE_COMMITTED_PAGE];
- [[[self dataSource] _locationChangeHandler] locationChangeCommitted];
+ [[[self dataSource] _locationChangeHandler] locationChangeCommittedForDataSource:[self dataSource]];
// If we have a title let the controller know about it.
if ([[self dataSource] pageTitle])
@@ -323,7 +326,7 @@ static const char * const stateNames[6] = {
if (![pd isLoading]) {
WEBKITDEBUGLEVEL (WEBKIT_LOG_LOADING, "%s: checking complete in IFWEBFRAMESTATE_PROVISIONAL, load done\n", [[self name] cString]);
- [[pd _locationChangeHandler] locationChangeDone: [pd mainDocumentError]];
+ [[pd _locationChangeHandler] locationChangeDone: [pd mainDocumentError] forDataSource:pd];
// We now the provisional data source didn't cut the mustard, release it.
[_private setProvisionalDataSource: nil];
@@ -379,7 +382,7 @@ static const char * const stateNames[6] = {
[thisDocumentView setNeedsDisplay: YES];
[thisDocumentView display];
- [[ds _locationChangeHandler] locationChangeDone: [ds mainDocumentError]];
+ [[ds _locationChangeHandler] locationChangeDone: [ds mainDocumentError] forDataSource:ds];
//if ([ds isDocumentHTML])
// [[ds representation] part]->closeURL();
diff --git a/WebKit/WebView.subproj/WebHTMLView.m b/WebKit/WebView.subproj/WebHTMLView.m
index 0fa7bca..fd3bd1f 100644
--- a/WebKit/WebView.subproj/WebHTMLView.m
+++ b/WebKit/WebView.subproj/WebHTMLView.m
@@ -77,19 +77,14 @@
}
-- (void)removeFromSuperview
+- (void)viewWillMoveToWindow:(NSWindow *)window
{
- [self _stopPlugins];
- [super removeFromSuperview];
+ if (!window)
+ [self _stopPlugins];
+ [super viewWillMoveToWindow:window];
}
-- (void)removeFromSuperviewWithoutNeedingDisplay
-{
- [self _stopPlugins];
- [super removeFromSuperviewWithoutNeedingDisplay];
-}
-
// This method is typically called by the view's controller when
// the data source is changed.
- (void)provisionalDataSourceChanged:(IFWebDataSource *)dataSource
diff --git a/WebKit/WebView.subproj/WebLocationChangeDelegate.h b/WebKit/WebView.subproj/WebLocationChangeDelegate.h
index aa9f9dd..5f5929f 100644
--- a/WebKit/WebView.subproj/WebLocationChangeDelegate.h
+++ b/WebKit/WebView.subproj/WebLocationChangeDelegate.h
@@ -45,16 +45,16 @@ typedef enum {
@protocol IFLocationChangeHandler <NSObject>
-- (void)locationChangeStarted;
+- (void)locationChangeStartedForDataSource: (IFWebDataSource *)dataSource;
// Sent after locationChangeStarted.
// Implementations typically call haveContentPolicy:forLocationChangeHandler: on IFWebController
// after determining the appropriate policy, perhaps by presenting a non-blocking dialog to the user.
- (void)requestContentPolicyForMIMEType: (NSString *)type dataSource: (IFWebDataSource *)dataSource;
-- (void)locationChangeCommitted;
+- (void)locationChangeCommittedForDataSource: (IFWebDataSource *)dataSource;
-- (void)locationChangeDone: (IFError *)error;
+- (void)locationChangeDone: (IFError *)error forDataSource: (IFWebDataSource *)dataSource;
- (void)receivedPageTitle: (NSString *)title forDataSource: (IFWebDataSource *)dataSource;
diff --git a/WebKit/WebView.subproj/WebLocationChangeHandler.h b/WebKit/WebView.subproj/WebLocationChangeHandler.h
index aa9f9dd..5f5929f 100644
--- a/WebKit/WebView.subproj/WebLocationChangeHandler.h
+++ b/WebKit/WebView.subproj/WebLocationChangeHandler.h
@@ -45,16 +45,16 @@ typedef enum {
@protocol IFLocationChangeHandler <NSObject>
-- (void)locationChangeStarted;
+- (void)locationChangeStartedForDataSource: (IFWebDataSource *)dataSource;
// Sent after locationChangeStarted.
// Implementations typically call haveContentPolicy:forLocationChangeHandler: on IFWebController
// after determining the appropriate policy, perhaps by presenting a non-blocking dialog to the user.
- (void)requestContentPolicyForMIMEType: (NSString *)type dataSource: (IFWebDataSource *)dataSource;
-- (void)locationChangeCommitted;
+- (void)locationChangeCommittedForDataSource: (IFWebDataSource *)dataSource;
-- (void)locationChangeDone: (IFError *)error;
+- (void)locationChangeDone: (IFError *)error forDataSource: (IFWebDataSource *)dataSource;
- (void)receivedPageTitle: (NSString *)title forDataSource: (IFWebDataSource *)dataSource;
diff --git a/WebKit/WebView.subproj/WebMainResourceClient.m b/WebKit/WebView.subproj/WebMainResourceClient.m
index 5f8b074..0c5a455 100644
--- a/WebKit/WebView.subproj/WebMainResourceClient.m
+++ b/WebKit/WebView.subproj/WebMainResourceClient.m
@@ -169,7 +169,7 @@
}else if(contentPolicy == IFContentPolicySave || contentPolicy == IFContentPolicyOpenExternally){
if(!downloadHandler){
[frame->_private setProvisionalDataSource:nil];
- [[dataSource _locationChangeHandler] locationChangeDone:nil];
+ [[dataSource _locationChangeHandler] locationChangeDone:nil forDataSource:dataSource];
downloadHandler = [[IFDownloadHandler alloc] initWithDataSource:dataSource];
}
[downloadHandler receivedData:data];
diff --git a/WebKit/WebView.subproj/WebMainResourceLoader.m b/WebKit/WebView.subproj/WebMainResourceLoader.m
index 5f8b074..0c5a455 100644
--- a/WebKit/WebView.subproj/WebMainResourceLoader.m
+++ b/WebKit/WebView.subproj/WebMainResourceLoader.m
@@ -169,7 +169,7 @@
}else if(contentPolicy == IFContentPolicySave || contentPolicy == IFContentPolicyOpenExternally){
if(!downloadHandler){
[frame->_private setProvisionalDataSource:nil];
- [[dataSource _locationChangeHandler] locationChangeDone:nil];
+ [[dataSource _locationChangeHandler] locationChangeDone:nil forDataSource:dataSource];
downloadHandler = [[IFDownloadHandler alloc] initWithDataSource:dataSource];
}
[downloadHandler receivedData:data];
diff --git a/WebKit/WebView.subproj/WebView.h b/WebKit/WebView.subproj/WebView.h
index accd598..bd4f2c7 100644
--- a/WebKit/WebView.subproj/WebView.h
+++ b/WebKit/WebView.subproj/WebView.h
@@ -82,7 +82,7 @@ typedef enum {
@protocol IFWebControllerPolicyHandler <NSObject>
-- (id <IFLocationChangeHandler>)provideLocationChangeHandlerForFrame: (IFWebFrame *)frame;
+- (id <IFLocationChangeHandler>)provideLocationChangeHandlerForDataSource: (IFWebDataSource *)dataSource;
// URLPolicyForURL: is used to determine what to do BEFORE a URL is loaded, i.e.
// before it is clicked or loaded via a URL bar. Clients can choose to handle the
diff --git a/WebKit/force-clean-timestamp b/WebKit/force-clean-timestamp
index e69de29..8d93060 100644
--- a/WebKit/force-clean-timestamp
+++ b/WebKit/force-clean-timestamp
@@ -0,0 +1 @@
+WebCore changes 6/19
--
WebKit Debian packaging
More information about the Pkg-webkit-commits
mailing list