[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:52 UTC 2009
The following commit has been merged in the debian/unstable branch:
commit d74e7dbfa311cadef645db476c6d94a9220c2567
Author: darin <darin at 268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Date: Thu Jun 27 20:19:11 2002 +0000
Fix Java. My changes this morning broke it.
* khtml/rendering/render_applet.cpp: (RenderApplet::processArguments):
Re-add required APPLE_CHANGES. Pass arguments to KJavaAppletWidget::processArguments.
* kwq/khtml/java/kjavaappletwidget.h: Added KJavaAppletWidget::processArguments.
* kwq/KWQKJavaAppletWidget.mm: (KJavaAppletWidget::processArguments): Added.
Some QFont fixes.
* kwq/qt/qfont.h: Remove unused setPixelSizeFloat.
* kwq/KWQFont.mm: Change to keep family names in a set. Since there are only
a small number of family names ever encountered, this is a bit of a memory win.
(QFont::QFont): Don't retain the family name.
(QFont::~QFont): Don't release the family name.
(QFont::setFamily): Put the family name in a set, and use the one from the set.
(QFont::operator=): Don't retain or release.
(QFont::operator==): Use == to compare the name.
git-svn-id: http://svn.webkit.org/repository/webkit/trunk@1459 268f45cc-cd09-0410-ab3c-d52691b4dbfc
diff --git a/WebCore/ChangeLog-2002-12-03 b/WebCore/ChangeLog-2002-12-03
index a3059ec..f537cce 100644
--- a/WebCore/ChangeLog-2002-12-03
+++ b/WebCore/ChangeLog-2002-12-03
@@ -1,3 +1,23 @@
+2002-06-27 Darin Adler <darin at apple.com>
+
+ Fix Java. My changes this morning broke it.
+
+ * khtml/rendering/render_applet.cpp: (RenderApplet::processArguments):
+ Re-add required APPLE_CHANGES. Pass arguments to KJavaAppletWidget::processArguments.
+ * kwq/khtml/java/kjavaappletwidget.h: Added KJavaAppletWidget::processArguments.
+ * kwq/KWQKJavaAppletWidget.mm: (KJavaAppletWidget::processArguments): Added.
+
+ Some QFont fixes.
+
+ * kwq/qt/qfont.h: Remove unused setPixelSizeFloat.
+ * kwq/KWQFont.mm: Change to keep family names in a set. Since there are only
+ a small number of family names ever encountered, this is a bit of a memory win.
+ (QFont::QFont): Don't retain the family name.
+ (QFont::~QFont): Don't release the family name.
+ (QFont::setFamily): Put the family name in a set, and use the one from the set.
+ (QFont::operator=): Don't retain or release.
+ (QFont::operator==): Use == to compare the name.
+
=== Alexander-10 ===
2002-06-27 Richard Williamson <rjw at apple.com>
diff --git a/WebCore/ChangeLog-2003-10-25 b/WebCore/ChangeLog-2003-10-25
index a3059ec..f537cce 100644
--- a/WebCore/ChangeLog-2003-10-25
+++ b/WebCore/ChangeLog-2003-10-25
@@ -1,3 +1,23 @@
+2002-06-27 Darin Adler <darin at apple.com>
+
+ Fix Java. My changes this morning broke it.
+
+ * khtml/rendering/render_applet.cpp: (RenderApplet::processArguments):
+ Re-add required APPLE_CHANGES. Pass arguments to KJavaAppletWidget::processArguments.
+ * kwq/khtml/java/kjavaappletwidget.h: Added KJavaAppletWidget::processArguments.
+ * kwq/KWQKJavaAppletWidget.mm: (KJavaAppletWidget::processArguments): Added.
+
+ Some QFont fixes.
+
+ * kwq/qt/qfont.h: Remove unused setPixelSizeFloat.
+ * kwq/KWQFont.mm: Change to keep family names in a set. Since there are only
+ a small number of family names ever encountered, this is a bit of a memory win.
+ (QFont::QFont): Don't retain the family name.
+ (QFont::~QFont): Don't release the family name.
+ (QFont::setFamily): Put the family name in a set, and use the one from the set.
+ (QFont::operator=): Don't retain or release.
+ (QFont::operator==): Use == to compare the name.
+
=== Alexander-10 ===
2002-06-27 Richard Williamson <rjw at apple.com>
diff --git a/WebCore/ChangeLog-2005-08-23 b/WebCore/ChangeLog-2005-08-23
index a3059ec..f537cce 100644
--- a/WebCore/ChangeLog-2005-08-23
+++ b/WebCore/ChangeLog-2005-08-23
@@ -1,3 +1,23 @@
+2002-06-27 Darin Adler <darin at apple.com>
+
+ Fix Java. My changes this morning broke it.
+
+ * khtml/rendering/render_applet.cpp: (RenderApplet::processArguments):
+ Re-add required APPLE_CHANGES. Pass arguments to KJavaAppletWidget::processArguments.
+ * kwq/khtml/java/kjavaappletwidget.h: Added KJavaAppletWidget::processArguments.
+ * kwq/KWQKJavaAppletWidget.mm: (KJavaAppletWidget::processArguments): Added.
+
+ Some QFont fixes.
+
+ * kwq/qt/qfont.h: Remove unused setPixelSizeFloat.
+ * kwq/KWQFont.mm: Change to keep family names in a set. Since there are only
+ a small number of family names ever encountered, this is a bit of a memory win.
+ (QFont::QFont): Don't retain the family name.
+ (QFont::~QFont): Don't release the family name.
+ (QFont::setFamily): Put the family name in a set, and use the one from the set.
+ (QFont::operator=): Don't retain or release.
+ (QFont::operator==): Use == to compare the name.
+
=== Alexander-10 ===
2002-06-27 Richard Williamson <rjw at apple.com>
diff --git a/WebCore/khtml/rendering/render_applet.cpp b/WebCore/khtml/rendering/render_applet.cpp
index e2ff6c0..3ca2f0c 100644
--- a/WebCore/khtml/rendering/render_applet.cpp
+++ b/WebCore/khtml/rendering/render_applet.cpp
@@ -120,6 +120,10 @@ void RenderApplet::layout()
void RenderApplet::processArguments(const QMap<QString, QString> &args)
{
KJavaAppletWidget *w = static_cast<KJavaAppletWidget*>(m_widget);
+#ifdef APPLE_CHANGES
+ if (w)
+ w->processArguments(args);
+#endif
KJavaApplet* applet = w ? w->applet() : 0;
if ( applet ) {
diff --git a/WebCore/kwq/KWQFont.h b/WebCore/kwq/KWQFont.h
index 999095e..f0ef13d 100644
--- a/WebCore/kwq/KWQFont.h
+++ b/WebCore/kwq/KWQFont.h
@@ -51,7 +51,6 @@ public:
QString family() const;
void setFamily(const QString &);
void setPixelSize(int);
- void setPixelSizeFloat(float);
void setWeight(int);
int weight() const;
bool setItalic(bool);
diff --git a/WebCore/kwq/KWQFont.mm b/WebCore/kwq/KWQFont.mm
index 016821a..e42c278 100644
--- a/WebCore/kwq/KWQFont.mm
+++ b/WebCore/kwq/KWQFont.mm
@@ -29,14 +29,14 @@
#import <Cocoa/Cocoa.h>
QFont::QFont()
- : _family([@"" retain])
+ : _family(@"")
, _trait(0)
, _size(12.0)
{
}
QFont::QFont(const QFont ©From)
- : _family([copyFrom._family retain])
+ : _family(copyFrom._family)
, _trait(copyFrom._trait)
, _size(copyFrom._size)
{
@@ -44,7 +44,6 @@ QFont::QFont(const QFont ©From)
QFont::~QFont()
{
- [_family release];
}
int QFont::pixelSize() const
@@ -59,8 +58,18 @@ QString QFont::family() const
void QFont::setFamily(const QString &qfamilyName)
{
- [_family release];
- _family = [qfamilyName.getNSString() copy];
+ // Uset an immutable copy of the name, but keep a set of
+ // all family names so we don't end up with too many objects.
+ static NSMutableSet *families;
+ if (families == nil) {
+ families = [[NSMutableSet alloc] init];
+ }
+ NSString *mutableName = qfamilyName.getNSString();
+ _family = [families member:mutableName];
+ if (!_family) {
+ [families addObject:mutableName];
+ _family = [families member:mutableName];
+ }
}
void QFont::setPixelSize(int sz)
@@ -68,11 +77,6 @@ void QFont::setPixelSize(int sz)
_size = sz;
}
-void QFont::setPixelSizeFloat(float sz)
-{
- _size = sz;
-}
-
void QFont::setWeight(int weight)
{
if (weight == Bold) {
@@ -111,8 +115,6 @@ bool QFont::bold() const
QFont &QFont::operator=(const QFont &assignFrom)
{
- [assignFrom._family retain];
- [_family release];
_family = assignFrom._family;
_trait = assignFrom._trait;
_size = assignFrom._size;
@@ -121,7 +123,7 @@ QFont &QFont::operator=(const QFont &assignFrom)
bool QFont::operator==(const QFont &compareFont) const
{
- return [_family isEqual:compareFont._family]
+ return _family == compareFont._family
&& _trait == compareFont._trait
&& _size == compareFont._size;
}
diff --git a/WebCore/kwq/KWQKJavaAppletWidget.h b/WebCore/kwq/KWQKJavaAppletWidget.h
index 51377f7..9cf16f4 100644
--- a/WebCore/kwq/KWQKJavaAppletWidget.h
+++ b/WebCore/kwq/KWQKJavaAppletWidget.h
@@ -61,6 +61,8 @@ public:
KJavaAppletWidget(KJavaAppletContext *, QWidget *);
~KJavaAppletWidget();
+ void processArguments(const QMap<QString, QString>&);
+
KJavaApplet *applet() { return &m_applet; }
void setBaseURL(const QString &);
diff --git a/WebCore/kwq/KWQKJavaAppletWidget.mm b/WebCore/kwq/KWQKJavaAppletWidget.mm
index 6f558dd..5203304 100644
--- a/WebCore/kwq/KWQKJavaAppletWidget.mm
+++ b/WebCore/kwq/KWQKJavaAppletWidget.mm
@@ -55,6 +55,13 @@ void KJavaAppletWidget::setParameter(const QString &name, const QString &value)
[immutableString release];
}
+void KJavaAppletWidget::processArguments(const QMap<QString, QString> &arguments)
+{
+ for (QMap<QString, QString>::ConstIterator it = arguments.begin(); it != arguments.end(); ++it) {
+ setParameter(it.key(), it.data());
+ }
+}
+
void KJavaAppletWidget::showApplet()
{
setView([[WebCoreViewFactory sharedFactory]
diff --git a/WebCore/kwq/khtml/java/kjavaappletwidget.h b/WebCore/kwq/khtml/java/kjavaappletwidget.h
index 51377f7..9cf16f4 100644
--- a/WebCore/kwq/khtml/java/kjavaappletwidget.h
+++ b/WebCore/kwq/khtml/java/kjavaappletwidget.h
@@ -61,6 +61,8 @@ public:
KJavaAppletWidget(KJavaAppletContext *, QWidget *);
~KJavaAppletWidget();
+ void processArguments(const QMap<QString, QString>&);
+
KJavaApplet *applet() { return &m_applet; }
void setBaseURL(const QString &);
diff --git a/WebCore/kwq/qt/qfont.h b/WebCore/kwq/qt/qfont.h
index 999095e..f0ef13d 100644
--- a/WebCore/kwq/qt/qfont.h
+++ b/WebCore/kwq/qt/qfont.h
@@ -51,7 +51,6 @@ public:
QString family() const;
void setFamily(const QString &);
void setPixelSize(int);
- void setPixelSizeFloat(float);
void setWeight(int);
int weight() const;
bool setItalic(bool);
--
WebKit Debian packaging
More information about the Pkg-webkit-commits
mailing list