[SCM] WebKit Debian packaging branch, debian/unstable, updated. debian/1.1.15-1-40151-g37bb677
trey
trey at 268f45cc-cd09-0410-ab3c-d52691b4dbfc
Sat Sep 26 07:26:48 UTC 2009
The following commit has been merged in the debian/unstable branch:
commit 0750c599143992a4410b17f3fa48cc2e50a60c35
Author: trey <trey at 268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Date: Mon Mar 3 06:48:51 2003 +0000
Use a KWQPopUpButton in place of NSPopUpButton. The only addition is that
it implements the KWQWidgetHolder protocol. This is needed in order to
auto set PopUps during autofill.
Reviewed by Maciej.
* kwq/KWQComboBox.mm:
(QComboBox::QComboBox): Make a KWQPopUpButton instead of NSPopUpButton.
(QComboBox::~QComboBox): trivial s/KWQPopUpButton/NSPopUpButton/
(QComboBox::insertItem): ditto
(QComboBox::sizeHint): ditto
(QComboBox::baselinePosition): ditto
(QComboBox::clear): ditto
(QComboBox::setCurrentItem): ditto
(QComboBox::currentItem): ditto
(-[KWQPopUpButtonCell widget]): Also implement KWQWidgetHolder
(-[KWQPopUpButton widget]): Implement KWQWidgetHolder by calling our cell.
git-svn-id: http://svn.webkit.org/repository/webkit/trunk@3724 268f45cc-cd09-0410-ab3c-d52691b4dbfc
diff --git a/WebCore/ChangeLog-2003-10-25 b/WebCore/ChangeLog-2003-10-25
index 89b2d3f..0cbaff9 100644
--- a/WebCore/ChangeLog-2003-10-25
+++ b/WebCore/ChangeLog-2003-10-25
@@ -1,3 +1,23 @@
+2003-03-02 Trey Matteson <trey at apple.com>
+
+ Use a KWQPopUpButton in place of NSPopUpButton. The only addition is that
+ it implements the KWQWidgetHolder protocol. This is needed in order to
+ auto set PopUps during autofill.
+
+ Reviewed by Maciej.
+
+ * kwq/KWQComboBox.mm:
+ (QComboBox::QComboBox): Make a KWQPopUpButton instead of NSPopUpButton.
+ (QComboBox::~QComboBox): trivial s/KWQPopUpButton/NSPopUpButton/
+ (QComboBox::insertItem): ditto
+ (QComboBox::sizeHint): ditto
+ (QComboBox::baselinePosition): ditto
+ (QComboBox::clear): ditto
+ (QComboBox::setCurrentItem): ditto
+ (QComboBox::currentItem): ditto
+ (-[KWQPopUpButtonCell widget]): Also implement KWQWidgetHolder
+ (-[KWQPopUpButton widget]): Implement KWQWidgetHolder by calling our cell.
+
2003-02-28 Darin Adler <darin at apple.com>
* khtml/css/parser.y: Fixed bad check-in that broke the build in a subtle way.
diff --git a/WebCore/ChangeLog-2005-08-23 b/WebCore/ChangeLog-2005-08-23
index 89b2d3f..0cbaff9 100644
--- a/WebCore/ChangeLog-2005-08-23
+++ b/WebCore/ChangeLog-2005-08-23
@@ -1,3 +1,23 @@
+2003-03-02 Trey Matteson <trey at apple.com>
+
+ Use a KWQPopUpButton in place of NSPopUpButton. The only addition is that
+ it implements the KWQWidgetHolder protocol. This is needed in order to
+ auto set PopUps during autofill.
+
+ Reviewed by Maciej.
+
+ * kwq/KWQComboBox.mm:
+ (QComboBox::QComboBox): Make a KWQPopUpButton instead of NSPopUpButton.
+ (QComboBox::~QComboBox): trivial s/KWQPopUpButton/NSPopUpButton/
+ (QComboBox::insertItem): ditto
+ (QComboBox::sizeHint): ditto
+ (QComboBox::baselinePosition): ditto
+ (QComboBox::clear): ditto
+ (QComboBox::setCurrentItem): ditto
+ (QComboBox::currentItem): ditto
+ (-[KWQPopUpButtonCell widget]): Also implement KWQWidgetHolder
+ (-[KWQPopUpButton widget]): Implement KWQWidgetHolder by calling our cell.
+
2003-02-28 Darin Adler <darin at apple.com>
* khtml/css/parser.y: Fixed bad check-in that broke the build in a subtle way.
diff --git a/WebCore/kwq/KWQComboBox.mm b/WebCore/kwq/KWQComboBox.mm
index 3d226e9..31fa51c 100644
--- a/WebCore/kwq/KWQComboBox.mm
+++ b/WebCore/kwq/KWQComboBox.mm
@@ -25,6 +25,7 @@
#import "KWQComboBox.h"
+#import "KWQView.h"
#import "KWQKHTMLPart.h"
#import "WebCoreBridge.h"
@@ -58,19 +59,22 @@ using khtml::RenderWidget;
- (void)action:(id)sender;
@end
- at interface KWQPopUpButtonCell : NSPopUpButtonCell
+ at interface KWQPopUpButtonCell : NSPopUpButtonCell <KWQWidgetHolder>
{
QWidget *widget;
}
- initWithWidget:(QWidget *)widget;
@end
+ at interface KWQPopUpButton : NSPopUpButton <KWQWidgetHolder>
+ at end
+
QComboBox::QComboBox()
: _adapter([[KWQComboBoxAdapter alloc] initWithQComboBox:this])
, _widthGood(false)
, _activated(this, SIGNAL(activated(int)))
{
- NSPopUpButton *button = [[NSPopUpButton alloc] init];
+ KWQPopUpButton *button = [[KWQPopUpButton alloc] init];
KWQPopUpButtonCell *cell = [[KWQPopUpButtonCell alloc] initWithWidget:this];
[button setCell:cell];
@@ -89,14 +93,14 @@ QComboBox::QComboBox()
QComboBox::~QComboBox()
{
- NSPopUpButton *button = (NSPopUpButton *)getView();
+ KWQPopUpButton *button = (KWQPopUpButton *)getView();
[button setTarget:nil];
[_adapter release];
}
void QComboBox::insertItem(const QString &text, int index)
{
- NSPopUpButton *button = (NSPopUpButton *)getView();
+ KWQPopUpButton *button = (KWQPopUpButton *)getView();
int numItems = [button numberOfItems];
if (index < 0) {
index = numItems;
@@ -114,7 +118,7 @@ void QComboBox::insertItem(const QString &text, int index)
QSize QComboBox::sizeHint() const
{
- NSPopUpButton *button = (NSPopUpButton *)getView();
+ KWQPopUpButton *button = (KWQPopUpButton *)getView();
float width;
if (_widthGood) {
@@ -157,27 +161,27 @@ void QComboBox::setFrameGeometry(const QRect &r)
int QComboBox::baselinePosition() const
{
// Menu text is at the top.
- NSPopUpButton *button = (NSButton *)getView();
+ KWQPopUpButton *button = (KWQPopUpButton *)getView();
return (int)ceil(-TOP_MARGIN + VERTICAL_FUDGE_FACTOR
+ TEXT_VERTICAL_NUDGE + [[button font] ascender]);
}
void QComboBox::clear()
{
- NSPopUpButton *button = (NSPopUpButton *)getView();
+ KWQPopUpButton *button = (KWQPopUpButton *)getView();
[button removeAllItems];
_widthGood = false;
}
void QComboBox::setCurrentItem(int index)
{
- NSPopUpButton *button = (NSPopUpButton *)getView();
+ KWQPopUpButton *button = (KWQPopUpButton *)getView();
[button selectItemAtIndex:index];
}
int QComboBox::currentItem() const
{
- NSPopUpButton *button = (NSPopUpButton *)getView();
+ KWQPopUpButton *button = (KWQPopUpButton *)getView();
return [button indexOfSelectedItem];
}
@@ -239,4 +243,18 @@ int QComboBox::currentItem() const
[super drawInteriorWithFrame:cellFrame inView:controlView];
}
+- (QWidget *)widget
+{
+ return widget;
+}
+
+ at end
+
+ at implementation KWQPopUpButton
+
+- (QWidget *)widget
+{
+ return [(KWQPopUpButtonCell *)[self cell] widget];
+}
+
@end
--
WebKit Debian packaging
More information about the Pkg-webkit-commits
mailing list