[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:21:48 UTC 2009


The following commit has been merged in the debian/unstable branch:
commit 6f57ec949a2a221cbe96f53d9a9d7355743c6fba
Author: darin <darin at 268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Date:   Thu Jun 27 16:17:31 2002 +0000

    WebCore:
    
            * khtml/rendering/render_applet.cpp: Remove include of <iostream.h> to avoid bloat.
            (RenderApplet::RenderApplet): Remove APPLE_CHANGES.
            (RenderApplet::processArguments): Remove APPLE_CHANGES.
    	This file is now back to 100% the same as the KDE original.
    
            * kwq/khtml/java/kjavaappletwidget.h: Added a bit of stuff so we match the interface
    	of the KDE original and don't need APPLE_CHANGES.
            * kwq/KWQKJavaAppletWidget.mm: Remove include of <iostream.h> to avoid bloat.
            (KJavaAppletWidget::KJavaAppletWidget): Update for parameters that match the
    	KDE original.
            (KJavaAppletWidget::~KJavaAppletWidget): Added.
            (KJavaAppletWidget::setBaseURL): Added.
            (KJavaAppletWidget::setParameter): Put strings into an NSMutableDictionary.
            (KJavaAppletWidget::showApplet): Use the new baseURL and parameters dictionary.
    
            * kwq/WebCoreViewFactory.h: Add baseURL parameter.
            * kwq/WebCoreViewFactory.m:
            (-[WebCoreViewFactory viewForJavaAppletWithFrame:baseURL:parameters:]): Add baseURL parameter.
    
            * kwq/kdecore/kurl.h: Fix NSURL definition to fit idiom.
            * kwq/qt/qmap.h: Added the const version of the [] operator.
    
            * khtml/ecma/kjs_navigator.cpp: Tweak whitespace.
            * khtml/html/html_documentimpl.cpp: Tweak to make it a little closer to original.
    
            * kwq/KWQKCookieJar.h: Reduce includes.
            * kwq/KWQKCookieJar.mm: Move includes in here.
    
            * kwq/WebCoreCookieAdapter.h: Fix comment that emacs munged.
    
    WebKit:
    
            * WebCoreSupport.subproj/IFWebCoreViewFactory.m:
            (-[IFWebCoreViewFactory viewForJavaAppletWithFrame:baseURL:parameters:]):
    	Pass baseURL as a separate parameter.
    
            * WebView.subproj/IFBaseLocationChangeHandler.m: Fix a typo. I think this
    	file might be unneeded, but I won't delete it until I hear from Chris.
    
    
    git-svn-id: http://svn.webkit.org/repository/webkit/trunk@1454 268f45cc-cd09-0410-ab3c-d52691b4dbfc

diff --git a/WebCore/ChangeLog-2002-12-03 b/WebCore/ChangeLog-2002-12-03
index 720a5c6..bd3072a 100644
--- a/WebCore/ChangeLog-2002-12-03
+++ b/WebCore/ChangeLog-2002-12-03
@@ -1,3 +1,35 @@
+2002-06-27  Darin Adler  <darin at apple.com>
+
+        * khtml/rendering/render_applet.cpp: Remove include of <iostream.h> to avoid bloat.
+        (RenderApplet::RenderApplet): Remove APPLE_CHANGES.
+        (RenderApplet::processArguments): Remove APPLE_CHANGES.
+	This file is now back to 100% the same as the KDE original.
+
+        * kwq/khtml/java/kjavaappletwidget.h: Added a bit of stuff so we match the interface
+	of the KDE original and don't need APPLE_CHANGES.
+        * kwq/KWQKJavaAppletWidget.mm: Remove include of <iostream.h> to avoid bloat.
+        (KJavaAppletWidget::KJavaAppletWidget): Update for parameters that match the
+	KDE original.
+        (KJavaAppletWidget::~KJavaAppletWidget): Added.
+        (KJavaAppletWidget::setBaseURL): Added.
+        (KJavaAppletWidget::setParameter): Put strings into an NSMutableDictionary.
+        (KJavaAppletWidget::showApplet): Use the new baseURL and parameters dictionary.
+
+        * kwq/WebCoreViewFactory.h: Add baseURL parameter.
+        * kwq/WebCoreViewFactory.m:
+        (-[WebCoreViewFactory viewForJavaAppletWithFrame:baseURL:parameters:]): Add baseURL parameter.
+
+        * kwq/kdecore/kurl.h: Fix NSURL definition to fit idiom.
+        * kwq/qt/qmap.h: Added the const version of the [] operator.
+
+        * khtml/ecma/kjs_navigator.cpp: Tweak whitespace.
+        * khtml/html/html_documentimpl.cpp: Tweak to make it a little closer to original.
+
+        * kwq/KWQKCookieJar.h: Reduce includes.
+        * kwq/KWQKCookieJar.mm: Move includes in here.
+
+        * kwq/WebCoreCookieAdapter.h: Fix comment that emacs munged.
+
 2002-06-27  Richard Williamson  <rjw at apple.com>
 
         * kwq/WebCoreBridge.h:
diff --git a/WebCore/ChangeLog-2003-10-25 b/WebCore/ChangeLog-2003-10-25
index 720a5c6..bd3072a 100644
--- a/WebCore/ChangeLog-2003-10-25
+++ b/WebCore/ChangeLog-2003-10-25
@@ -1,3 +1,35 @@
+2002-06-27  Darin Adler  <darin at apple.com>
+
+        * khtml/rendering/render_applet.cpp: Remove include of <iostream.h> to avoid bloat.
+        (RenderApplet::RenderApplet): Remove APPLE_CHANGES.
+        (RenderApplet::processArguments): Remove APPLE_CHANGES.
+	This file is now back to 100% the same as the KDE original.
+
+        * kwq/khtml/java/kjavaappletwidget.h: Added a bit of stuff so we match the interface
+	of the KDE original and don't need APPLE_CHANGES.
+        * kwq/KWQKJavaAppletWidget.mm: Remove include of <iostream.h> to avoid bloat.
+        (KJavaAppletWidget::KJavaAppletWidget): Update for parameters that match the
+	KDE original.
+        (KJavaAppletWidget::~KJavaAppletWidget): Added.
+        (KJavaAppletWidget::setBaseURL): Added.
+        (KJavaAppletWidget::setParameter): Put strings into an NSMutableDictionary.
+        (KJavaAppletWidget::showApplet): Use the new baseURL and parameters dictionary.
+
+        * kwq/WebCoreViewFactory.h: Add baseURL parameter.
+        * kwq/WebCoreViewFactory.m:
+        (-[WebCoreViewFactory viewForJavaAppletWithFrame:baseURL:parameters:]): Add baseURL parameter.
+
+        * kwq/kdecore/kurl.h: Fix NSURL definition to fit idiom.
+        * kwq/qt/qmap.h: Added the const version of the [] operator.
+
+        * khtml/ecma/kjs_navigator.cpp: Tweak whitespace.
+        * khtml/html/html_documentimpl.cpp: Tweak to make it a little closer to original.
+
+        * kwq/KWQKCookieJar.h: Reduce includes.
+        * kwq/KWQKCookieJar.mm: Move includes in here.
+
+        * kwq/WebCoreCookieAdapter.h: Fix comment that emacs munged.
+
 2002-06-27  Richard Williamson  <rjw at apple.com>
 
         * kwq/WebCoreBridge.h:
diff --git a/WebCore/ChangeLog-2005-08-23 b/WebCore/ChangeLog-2005-08-23
index 720a5c6..bd3072a 100644
--- a/WebCore/ChangeLog-2005-08-23
+++ b/WebCore/ChangeLog-2005-08-23
@@ -1,3 +1,35 @@
+2002-06-27  Darin Adler  <darin at apple.com>
+
+        * khtml/rendering/render_applet.cpp: Remove include of <iostream.h> to avoid bloat.
+        (RenderApplet::RenderApplet): Remove APPLE_CHANGES.
+        (RenderApplet::processArguments): Remove APPLE_CHANGES.
+	This file is now back to 100% the same as the KDE original.
+
+        * kwq/khtml/java/kjavaappletwidget.h: Added a bit of stuff so we match the interface
+	of the KDE original and don't need APPLE_CHANGES.
+        * kwq/KWQKJavaAppletWidget.mm: Remove include of <iostream.h> to avoid bloat.
+        (KJavaAppletWidget::KJavaAppletWidget): Update for parameters that match the
+	KDE original.
+        (KJavaAppletWidget::~KJavaAppletWidget): Added.
+        (KJavaAppletWidget::setBaseURL): Added.
+        (KJavaAppletWidget::setParameter): Put strings into an NSMutableDictionary.
+        (KJavaAppletWidget::showApplet): Use the new baseURL and parameters dictionary.
+
+        * kwq/WebCoreViewFactory.h: Add baseURL parameter.
+        * kwq/WebCoreViewFactory.m:
+        (-[WebCoreViewFactory viewForJavaAppletWithFrame:baseURL:parameters:]): Add baseURL parameter.
+
+        * kwq/kdecore/kurl.h: Fix NSURL definition to fit idiom.
+        * kwq/qt/qmap.h: Added the const version of the [] operator.
+
+        * khtml/ecma/kjs_navigator.cpp: Tweak whitespace.
+        * khtml/html/html_documentimpl.cpp: Tweak to make it a little closer to original.
+
+        * kwq/KWQKCookieJar.h: Reduce includes.
+        * kwq/KWQKCookieJar.mm: Move includes in here.
+
+        * kwq/WebCoreCookieAdapter.h: Fix comment that emacs munged.
+
 2002-06-27  Richard Williamson  <rjw at apple.com>
 
         * kwq/WebCoreBridge.h:
diff --git a/WebCore/khtml/ecma/kjs_navigator.cpp b/WebCore/khtml/ecma/kjs_navigator.cpp
index 4d3edf8..dbc8b0e 100644
--- a/WebCore/khtml/ecma/kjs_navigator.cpp
+++ b/WebCore/khtml/ecma/kjs_navigator.cpp
@@ -234,7 +234,7 @@ Value Navigator::getValueProperty(ExecState *exec, int token) const
     return Value(new MimeTypes(exec));
   case CookieEnabled:
 #ifdef APPLE_CHANGES
-      return Boolean(KWQKCookieJar::cookieEnabled());
+    return Boolean(KWQKCookieJar::cookieEnabled());
 #else
     return Boolean(true); /// ##### FIXME
 #endif
diff --git a/WebCore/khtml/html/html_documentimpl.cpp b/WebCore/khtml/html/html_documentimpl.cpp
index 552531e..59b9d8b 100644
--- a/WebCore/khtml/html/html_documentimpl.cpp
+++ b/WebCore/khtml/html/html_documentimpl.cpp
@@ -48,12 +48,12 @@
 #include <kcharsets.h>
 #include <kglobalsettings.h>
 
-
 #include "css/cssproperties.h"
 #include "css/cssstyleselector.h"
 #include "css/css_stylesheetimpl.h"
 #include <stdlib.h>
 #include <qptrstack.h>
+
 #ifdef APPLE_CHANGES
 #include <KWQKCookieJar.h>
 #endif
@@ -134,7 +134,7 @@ DOMString HTMLDocumentImpl::lastModified() const
 DOMString HTMLDocumentImpl::cookie() const
 {
 #ifdef APPLE_CHANGES
-    return KWQKCookieJar::cookie(KURL(URL()));
+    return KWQKCookieJar::cookie(URL());
 #else
     QCString replyType;
     QByteArray params, reply;
@@ -167,7 +167,7 @@ DOMString HTMLDocumentImpl::cookie() const
 void HTMLDocumentImpl::setCookie( const DOMString & value )
 {
 #ifdef APPLE_CHANGES
-    return KWQKCookieJar::setCookie(KURL(URL()), value.string());
+    return KWQKCookieJar::setCookie(URL(), value.string());
 #else
     long windowId = view() ? view()->winId() : 0;
     QByteArray params;
diff --git a/WebCore/khtml/rendering/render_applet.cpp b/WebCore/khtml/rendering/render_applet.cpp
index 0b0c1aa..e2ff6c0 100644
--- a/WebCore/khtml/rendering/render_applet.cpp
+++ b/WebCore/khtml/rendering/render_applet.cpp
@@ -37,7 +37,6 @@
 #include "java/kjavaappletwidget.h"
 #include "misc/htmltags.h"
 #include "html/html_objectimpl.h"
-#include <iostream.h>
 
 using namespace khtml;
 using namespace DOM;
@@ -57,12 +56,8 @@ RenderApplet::RenderApplet(HTMLElementImpl *applet, const QMap<QString, QString>
 
     if ( context ) {
         //kdDebug(6100) << "RenderApplet::RenderApplet, setting QWidget" << endl;
-#ifdef APPLE_CHANGES
-        setQWidget( new KJavaAppletWidget(args) );
-#else
         setQWidget( new KJavaAppletWidget(context, _view->viewport()) );
         processArguments(args);
-#endif
     }
 }
 
@@ -93,6 +88,7 @@ int RenderApplet::intrinsicHeight() const
 void RenderApplet::layout()
 {
     //kdDebug(6100) << "RenderApplet::layout" << endl;
+
     KHTMLAssert( !layouted() );
     KHTMLAssert( minMaxKnown() );
 
@@ -121,8 +117,6 @@ void RenderApplet::layout()
     setLayouted();
 }
 
-#ifndef APPLE_CHANGES
-
 void RenderApplet::processArguments(const QMap<QString, QString> &args)
 {
     KJavaAppletWidget *w = static_cast<KJavaAppletWidget*>(m_widget);
@@ -148,8 +142,6 @@ void RenderApplet::processArguments(const QMap<QString, QString> &args)
     }
 }
 
-#endif // APPLE_CHANGES
-
 RenderEmptyApplet::RenderEmptyApplet(DOM::NodeImpl* node)
   : RenderWidget(node)
 {
diff --git a/WebCore/kwq/KWQKCookieJar.h b/WebCore/kwq/KWQKCookieJar.h
index d001e08..7681221 100644
--- a/WebCore/kwq/KWQKCookieJar.h
+++ b/WebCore/kwq/KWQKCookieJar.h
@@ -23,9 +23,8 @@
  * OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
  */
 
-
-#include <qstring.h>
-#include <kurl.h>
+class QString;
+class KURL;
 
 class KWQKCookieJar
 {
@@ -34,4 +33,3 @@ public:
     static void setCookie(const KURL &, const QString &);
     static bool cookieEnabled();
 };
-
diff --git a/WebCore/kwq/KWQKCookieJar.mm b/WebCore/kwq/KWQKCookieJar.mm
index 3eda2a5..f87fea3 100644
--- a/WebCore/kwq/KWQKCookieJar.mm
+++ b/WebCore/kwq/KWQKCookieJar.mm
@@ -23,9 +23,9 @@
  * OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
  */
 
-#include <KWQKCookieJar.h>
-#include <WebCoreCookieAdapter.h>
-
+#import <KWQKCookieJar.h>
+#import <WebCoreCookieAdapter.h>
+#import <kurl.h>
 
 QString KWQKCookieJar::cookie(const KURL &url)
 {
diff --git a/WebCore/kwq/KWQKJavaAppletWidget.h b/WebCore/kwq/KWQKJavaAppletWidget.h
index c3ea588..51377f7 100644
--- a/WebCore/kwq/KWQKJavaAppletWidget.h
+++ b/WebCore/kwq/KWQKJavaAppletWidget.h
@@ -27,26 +27,52 @@
 #include <qmap.h>
 #include <qstring.h>
 
-class KJavaApplet;
+class KJavaAppletContext;
+class KJavaAppletWidget;
 
-class KJavaAppletWidget : public QWidget
+#ifdef __OBJC__
+ at class NSURL;
+ at class NSMutableDictionary;
+#else
+class NSURL;
+class NSMutableDictionary;
+#endif
+
+class KJavaApplet
 {
-    KJavaApplet *m_applet;
-    QMap<QString, QString> arguments;
-    QRect frame;
-    
 public:
-    KJavaAppletWidget(const QMap<QString, QString> &args);
-    void setParameter(const QString &name, const QString &value){arguments.insert(name, value);}
-    KJavaApplet* applet() { return m_applet; }
-    void showApplet();
+    KJavaApplet(KJavaAppletWidget &widget) : m_widget(widget) { }
+
+    void setAppletClass(const QString &) { }
+    void setAppletName(const QString &) { }
+    void setArchives(const QString &) { }
+    void setBaseURL(const QString &);
+    void setCodeBase(const QString &) { }
+    
+    void setParameter(const QString &, const QString &);
+
+private:
+    KJavaAppletWidget &m_widget;
 };
 
-class KJavaApplet
+class KJavaAppletWidget : public QWidget
 {
-    KJavaAppletWidget *m_widget;
-    
 public:
-    KJavaApplet(KJavaAppletWidget *widget){m_widget = widget;}
-    void setParameter(const QString &name, const QString &value) { m_widget->setParameter(name, value); }
+    KJavaAppletWidget(KJavaAppletContext *, QWidget *);
+    ~KJavaAppletWidget();
+    
+    KJavaApplet *applet() { return &m_applet; }
+    
+    void setBaseURL(const QString &);
+    void setParameter(const QString &, const QString &);
+
+    void showApplet();
+
+private:
+    KJavaApplet m_applet;
+    NSURL *m_baseURL;
+    NSMutableDictionary *m_parameters;
 };
+
+inline void KJavaApplet::setBaseURL(const QString &URL) { m_widget.setBaseURL(URL); }
+inline void KJavaApplet::setParameter(const QString &name, const QString &value) { m_widget.setParameter(name, value); }
diff --git a/WebCore/kwq/KWQKJavaAppletWidget.mm b/WebCore/kwq/KWQKJavaAppletWidget.mm
index 7def555..6f558dd 100644
--- a/WebCore/kwq/KWQKJavaAppletWidget.mm
+++ b/WebCore/kwq/KWQKJavaAppletWidget.mm
@@ -25,20 +25,40 @@
 
 #import <java/kjavaappletwidget.h>
 #import <WebCoreViewFactory.h>
-#include <iostream.h>
+#import <WebFoundation/IFNSURLExtensions.h>
 
-KJavaAppletWidget::KJavaAppletWidget(const QMap<QString, QString> &args) {
-    arguments = args; 
-    m_applet = new KJavaApplet(this);
+KJavaAppletWidget::KJavaAppletWidget(KJavaAppletContext *, QWidget *)
+    : m_applet(*this)
+    , m_baseURL(nil)
+    , m_parameters([[NSMutableDictionary alloc] init])
+{
+}
+
+KJavaAppletWidget::~KJavaAppletWidget()
+{
+    [m_baseURL release];
+    [m_parameters release];
+}
+
+void KJavaAppletWidget::setBaseURL(const QString &baseURL)
+{
+    [m_baseURL release];
+    m_baseURL = [[NSURL _IF_URLWithString:baseURL.getNSString()] retain];
+}
+
+void KJavaAppletWidget::setParameter(const QString &name, const QString &value)
+{
+    // When putting strings into dictionaries, we should use an immutable copy.
+    // That's not necessary for keys, because they are copied.
+    NSString *immutableString = [value.getNSString() copy];
+    [m_parameters setObject:immutableString forKey:name.getNSString()];
+    [immutableString release];
 }
 
 void KJavaAppletWidget::showApplet()
 {
-    NSMutableDictionary *argsDictionary = [NSMutableDictionary dictionaryWithCapacity:arguments.count()];
-    for (QMap<QString, QString>::ConstIterator it = arguments.begin(); it != arguments.end(); ++it) {
-        [argsDictionary setObject:it.data().getNSString() forKey:it.key().getNSString()];
-    }
     setView([[WebCoreViewFactory sharedFactory] 
-                viewForJavaAppletWithFrame:NSMakeRect(pos().x(), pos().y(), size().width(), size().height())
-                andArguments:argsDictionary]);
-}
\ No newline at end of file
+    	viewForJavaAppletWithFrame:NSMakeRect(pos().x(), pos().y(), size().width(), size().height())
+                           baseURL:m_baseURL
+                        parameters:m_parameters]);
+}
diff --git a/WebCore/kwq/KWQKURL.h b/WebCore/kwq/KWQKURL.h
index 9c1d869..5601cd5 100644
--- a/WebCore/kwq/KWQKURL.h
+++ b/WebCore/kwq/KWQKURL.h
@@ -33,7 +33,7 @@
 #ifdef __OBJC__
 @class NSURL;
 #else
-typedef void NSURL;
+class NSURL;
 #endif
 
 class KURL {
diff --git a/WebCore/kwq/KWQMap.h b/WebCore/kwq/KWQMap.h
index 43a442f..1e79c79 100644
--- a/WebCore/kwq/KWQMap.h
+++ b/WebCore/kwq/KWQMap.h
@@ -238,6 +238,13 @@ public:
 	return ((QMapNode<K,V> *)insertInternal(&tmp, false))->value;
     }
 
+    V operator[](const K& key) const
+    {
+	QMapNode<K,V> tmp(key, V());
+        QMapNode<K,V> *result = (QMapNode<K,V> *)findInternal(&tmp);
+	return result ? result->value : V();
+    }
+
 protected:
     virtual void copyNode(const KWQMapNodeImpl *isrc, KWQMapNodeImpl *idst) const
     {
diff --git a/WebCore/kwq/WebCoreCookieAdapter.h b/WebCore/kwq/WebCoreCookieAdapter.h
index 2c2546c..d74b4b7 100644
--- a/WebCore/kwq/WebCoreCookieAdapter.h
+++ b/WebCore/kwq/WebCoreCookieAdapter.h
@@ -16,8 +16,8 @@
  * 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
+ * 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.
diff --git a/WebCore/kwq/WebCoreViewFactory.h b/WebCore/kwq/WebCoreViewFactory.h
index cd50854..3ff1de9 100644
--- a/WebCore/kwq/WebCoreViewFactory.h
+++ b/WebCore/kwq/WebCoreViewFactory.h
@@ -38,7 +38,7 @@
 - (NSView *)viewForPluginWithURL:(NSURL *)url serviceType:(NSString *)serviceType arguments:(NSArray *)arguments baseURL:(NSURL *)baseURL;
 - (NSArray *)pluginsInfo; // array of id <WebCorePluginInfo>
 
-- (NSView *)viewForJavaAppletWithFrame:(NSRect)frame andArguments:(NSDictionary *)arguments;
+- (NSView *)viewForJavaAppletWithFrame:(NSRect)frame baseURL:(NSURL *)URL parameters:(NSDictionary *)parameters;
 
 @end
 
diff --git a/WebCore/kwq/WebCoreViewFactory.m b/WebCore/kwq/WebCoreViewFactory.m
index 21ada9e..63e6e9c 100644
--- a/WebCore/kwq/WebCoreViewFactory.m
+++ b/WebCore/kwq/WebCoreViewFactory.m
@@ -55,7 +55,7 @@ static WebCoreViewFactory *sharedFactory;
     return nil;
 }
 
-- (NSView *)viewForJavaAppletWithFrame:(NSRect)frame andArguments:(NSDictionary *)arguments
+- (NSView *)viewForJavaAppletWithFrame:(NSRect)frame baseURL:(NSURL *)baseURL parameters:(NSDictionary *)parameters
 {
     return nil;
 }
diff --git a/WebCore/kwq/kdecore/kurl.h b/WebCore/kwq/kdecore/kurl.h
index 9c1d869..5601cd5 100644
--- a/WebCore/kwq/kdecore/kurl.h
+++ b/WebCore/kwq/kdecore/kurl.h
@@ -33,7 +33,7 @@
 #ifdef __OBJC__
 @class NSURL;
 #else
-typedef void NSURL;
+class NSURL;
 #endif
 
 class KURL {
diff --git a/WebCore/kwq/khtml/java/kjavaappletwidget.h b/WebCore/kwq/khtml/java/kjavaappletwidget.h
index c3ea588..51377f7 100644
--- a/WebCore/kwq/khtml/java/kjavaappletwidget.h
+++ b/WebCore/kwq/khtml/java/kjavaappletwidget.h
@@ -27,26 +27,52 @@
 #include <qmap.h>
 #include <qstring.h>
 
-class KJavaApplet;
+class KJavaAppletContext;
+class KJavaAppletWidget;
 
-class KJavaAppletWidget : public QWidget
+#ifdef __OBJC__
+ at class NSURL;
+ at class NSMutableDictionary;
+#else
+class NSURL;
+class NSMutableDictionary;
+#endif
+
+class KJavaApplet
 {
-    KJavaApplet *m_applet;
-    QMap<QString, QString> arguments;
-    QRect frame;
-    
 public:
-    KJavaAppletWidget(const QMap<QString, QString> &args);
-    void setParameter(const QString &name, const QString &value){arguments.insert(name, value);}
-    KJavaApplet* applet() { return m_applet; }
-    void showApplet();
+    KJavaApplet(KJavaAppletWidget &widget) : m_widget(widget) { }
+
+    void setAppletClass(const QString &) { }
+    void setAppletName(const QString &) { }
+    void setArchives(const QString &) { }
+    void setBaseURL(const QString &);
+    void setCodeBase(const QString &) { }
+    
+    void setParameter(const QString &, const QString &);
+
+private:
+    KJavaAppletWidget &m_widget;
 };
 
-class KJavaApplet
+class KJavaAppletWidget : public QWidget
 {
-    KJavaAppletWidget *m_widget;
-    
 public:
-    KJavaApplet(KJavaAppletWidget *widget){m_widget = widget;}
-    void setParameter(const QString &name, const QString &value) { m_widget->setParameter(name, value); }
+    KJavaAppletWidget(KJavaAppletContext *, QWidget *);
+    ~KJavaAppletWidget();
+    
+    KJavaApplet *applet() { return &m_applet; }
+    
+    void setBaseURL(const QString &);
+    void setParameter(const QString &, const QString &);
+
+    void showApplet();
+
+private:
+    KJavaApplet m_applet;
+    NSURL *m_baseURL;
+    NSMutableDictionary *m_parameters;
 };
+
+inline void KJavaApplet::setBaseURL(const QString &URL) { m_widget.setBaseURL(URL); }
+inline void KJavaApplet::setParameter(const QString &name, const QString &value) { m_widget.setParameter(name, value); }
diff --git a/WebCore/kwq/qt/qmap.h b/WebCore/kwq/qt/qmap.h
index 43a442f..1e79c79 100644
--- a/WebCore/kwq/qt/qmap.h
+++ b/WebCore/kwq/qt/qmap.h
@@ -238,6 +238,13 @@ public:
 	return ((QMapNode<K,V> *)insertInternal(&tmp, false))->value;
     }
 
+    V operator[](const K& key) const
+    {
+	QMapNode<K,V> tmp(key, V());
+        QMapNode<K,V> *result = (QMapNode<K,V> *)findInternal(&tmp);
+	return result ? result->value : V();
+    }
+
 protected:
     virtual void copyNode(const KWQMapNodeImpl *isrc, KWQMapNodeImpl *idst) const
     {
diff --git a/WebKit/ChangeLog b/WebKit/ChangeLog
index d0138c5..302e6ff 100644
--- a/WebKit/ChangeLog
+++ b/WebKit/ChangeLog
@@ -1,3 +1,12 @@
+2002-06-27  Darin Adler  <darin at apple.com>
+
+        * WebCoreSupport.subproj/IFWebCoreViewFactory.m:
+        (-[IFWebCoreViewFactory viewForJavaAppletWithFrame:baseURL:parameters:]):
+	Pass baseURL as a separate parameter.
+
+        * WebView.subproj/IFBaseLocationChangeHandler.m: Fix a typo. I think this
+	file might be unneeded, but I won't delete it until I hear from Chris.
+
 2002-06-27  Richard Williamson  <rjw at apple.com>
         
         Fix selection in 'slow' code path (non-base characters and font substitution).
diff --git a/WebKit/ChangeLog-2002-12-03 b/WebKit/ChangeLog-2002-12-03
index d0138c5..302e6ff 100644
--- a/WebKit/ChangeLog-2002-12-03
+++ b/WebKit/ChangeLog-2002-12-03
@@ -1,3 +1,12 @@
+2002-06-27  Darin Adler  <darin at apple.com>
+
+        * WebCoreSupport.subproj/IFWebCoreViewFactory.m:
+        (-[IFWebCoreViewFactory viewForJavaAppletWithFrame:baseURL:parameters:]):
+	Pass baseURL as a separate parameter.
+
+        * WebView.subproj/IFBaseLocationChangeHandler.m: Fix a typo. I think this
+	file might be unneeded, but I won't delete it until I hear from Chris.
+
 2002-06-27  Richard Williamson  <rjw at apple.com>
         
         Fix selection in 'slow' code path (non-base characters and font substitution).
diff --git a/WebKit/WebCoreSupport.subproj/IFWebCoreViewFactory.m b/WebKit/WebCoreSupport.subproj/IFWebCoreViewFactory.m
index 4e15d1e..45300da 100644
--- a/WebKit/WebCoreSupport.subproj/IFWebCoreViewFactory.m
+++ b/WebKit/WebCoreSupport.subproj/IFWebCoreViewFactory.m
@@ -66,19 +66,16 @@
     return [[IFPluginDatabase installedPlugins] plugins];
 }
 
-- (NSView *)viewForJavaAppletWithFrame:(NSRect)frame andArguments:(NSDictionary *)arguments
+- (NSView *)viewForJavaAppletWithFrame:(NSRect)frame baseURL:(NSURL *)baseURL parameters:(NSDictionary *)parameters
 {
     IFPlugin *plugin;
-    NSURL *baseURL;
     
     plugin = [[IFPluginDatabase installedPlugins] pluginForMimeType:@"application/x-java-applet"];
     if (plugin == nil) {
         return nil;
     }
     
-    baseURL = [NSURL _IF_URLWithString:[arguments objectForKey:@"baseURL"]];
-
-    return [[[IFPluginView alloc] initWithFrame:frame plugin:plugin url:nil baseURL:baseURL mime:@"application/x-java-applet" arguments:arguments] autorelease];
+    return [[[IFPluginView alloc] initWithFrame:frame plugin:plugin url:nil baseURL:baseURL mime:@"application/x-java-applet" arguments:parameters] autorelease];
 }
 
 @end
diff --git a/WebKit/WebCoreSupport.subproj/WebViewFactory.m b/WebKit/WebCoreSupport.subproj/WebViewFactory.m
index 4e15d1e..45300da 100644
--- a/WebKit/WebCoreSupport.subproj/WebViewFactory.m
+++ b/WebKit/WebCoreSupport.subproj/WebViewFactory.m
@@ -66,19 +66,16 @@
     return [[IFPluginDatabase installedPlugins] plugins];
 }
 
-- (NSView *)viewForJavaAppletWithFrame:(NSRect)frame andArguments:(NSDictionary *)arguments
+- (NSView *)viewForJavaAppletWithFrame:(NSRect)frame baseURL:(NSURL *)baseURL parameters:(NSDictionary *)parameters
 {
     IFPlugin *plugin;
-    NSURL *baseURL;
     
     plugin = [[IFPluginDatabase installedPlugins] pluginForMimeType:@"application/x-java-applet"];
     if (plugin == nil) {
         return nil;
     }
     
-    baseURL = [NSURL _IF_URLWithString:[arguments objectForKey:@"baseURL"]];
-
-    return [[[IFPluginView alloc] initWithFrame:frame plugin:plugin url:nil baseURL:baseURL mime:@"application/x-java-applet" arguments:arguments] autorelease];
+    return [[[IFPluginView alloc] initWithFrame:frame plugin:plugin url:nil baseURL:baseURL mime:@"application/x-java-applet" arguments:parameters] autorelease];
 }
 
 @end
diff --git a/WebKit/WebView.subproj/IFBaseLocationChangeHandler.m b/WebKit/WebView.subproj/IFBaseLocationChangeHandler.m
index 918f1bf..1163a94 100644
--- a/WebKit/WebView.subproj/IFBaseLocationChangeHandler.m
+++ b/WebKit/WebView.subproj/IFBaseLocationChangeHandler.m
@@ -1,4 +1,4 @@
-/*	IFBaseLocationChangeHander.m
+/*	IFBaseLocationChangeHandler.m
 
         Copyright 2001, Apple, Inc. All rights reserved.
 */
@@ -22,11 +22,11 @@
 {
 }
 
-+ (NSString *)suggestedFileanemForURL: (NSURL *) andContentType: (IFContentType *)type
++ (NSString *)suggestedFileanemForURL: (NSURL *) andContentType: (IFURLContentType *)type
 {
 }
 
-+ (NSString *)suggestedDirectoryForURL: (NSURL *) andContentType: (IFContentType *)type
++ (NSString *)suggestedDirectoryForURL: (NSURL *) andContentType: (IFURLContentType *)type
 {
 }
 

-- 
WebKit Debian packaging



More information about the Pkg-webkit-commits mailing list