[SCM] WebKit Debian packaging branch, webkit-1.1, updated. upstream/1.1.21-584-g1e41756
eric at webkit.org
eric at webkit.org
Fri Feb 26 22:25:59 UTC 2010
The following commit has been merged in the webkit-1.1 branch:
commit 9efc390cb20fc52524c3491b866f0b93c49092f5
Author: eric at webkit.org <eric at webkit.org@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Date: Sat Feb 20 00:41:48 2010 +0000
2010-02-19 James Hawkins <jhawkins at chromium.org>
Reviewed by Darin Fisher.
[Chromium] Call WebViewClient::didAcceptAutoFillSuggestion when the
user selects a suggestion from the AutoFill suggestions popup.
https://bugs.webkit.org/show_bug.cgi?id=35174
* public/WebViewClient.h:
(WebKit::WebViewClient::didAcceptAutoFillSuggestion):
* src/AutoFillPopupMenuClient.cpp:
(WebKit::AutoFillPopupMenuClient::valueChanged):
* src/AutoFillPopupMenuClient.h:
git-svn-id: http://svn.webkit.org/repository/webkit/trunk@55037 268f45cc-cd09-0410-ab3c-d52691b4dbfc
diff --git a/WebKit/chromium/ChangeLog b/WebKit/chromium/ChangeLog
index 245cd9e..abb4ef1 100644
--- a/WebKit/chromium/ChangeLog
+++ b/WebKit/chromium/ChangeLog
@@ -1,5 +1,20 @@
2010-02-19 James Hawkins <jhawkins at chromium.org>
+ Reviewed by Darin Fisher.
+
+ [Chromium] Call WebViewClient::didAcceptAutoFillSuggestion when the
+ user selects a suggestion from the AutoFill suggestions popup.
+
+ https://bugs.webkit.org/show_bug.cgi?id=35174
+
+ * public/WebViewClient.h:
+ (WebKit::WebViewClient::didAcceptAutoFillSuggestion):
+ * src/AutoFillPopupMenuClient.cpp:
+ (WebKit::AutoFillPopupMenuClient::valueChanged):
+ * src/AutoFillPopupMenuClient.h:
+
+2010-02-19 James Hawkins <jhawkins at chromium.org>
+
Reviewed by Eric Seidel.
[Chromium] Use the m_suggestionsPopupClient pointer to refer to the
diff --git a/WebKit/chromium/public/WebViewClient.h b/WebKit/chromium/public/WebViewClient.h
index a2de115..bb4e3c5 100644
--- a/WebKit/chromium/public/WebViewClient.h
+++ b/WebKit/chromium/public/WebViewClient.h
@@ -278,6 +278,13 @@ public:
virtual void removeAutofillSuggestions(const WebString& name,
const WebString& value) { }
+ // Informs the browser that the user has selected an AutoFill suggestion
+ // for a WebNode. |name| and |label| form a key into the set of AutoFill
+ // profiles.
+ virtual void didAcceptAutoFillSuggestion(const WebNode&,
+ const WebString& name,
+ const WebString& label) { }
+
// Geolocation ---------------------------------------------------------
// Access the embedder API for geolocation services.
diff --git a/WebKit/chromium/src/AutoFillPopupMenuClient.cpp b/WebKit/chromium/src/AutoFillPopupMenuClient.cpp
index 8e6cab4..4f8793a 100644
--- a/WebKit/chromium/src/AutoFillPopupMenuClient.cpp
+++ b/WebKit/chromium/src/AutoFillPopupMenuClient.cpp
@@ -32,8 +32,11 @@
#include "AutoFillPopupMenuClient.h"
#include "HTMLInputElement.h"
+#include "WebNode.h"
#include "WebString.h"
#include "WebVector.h"
+#include "WebViewClient.h"
+#include "WebViewImpl.h"
using namespace WebCore;
@@ -59,6 +62,19 @@ void AutoFillPopupMenuClient::removeSuggestionAtIndex(unsigned listIndex)
m_labels.remove(listIndex);
}
+void AutoFillPopupMenuClient::valueChanged(unsigned listIndex, bool fireEvents)
+{
+ ASSERT(listIndex >= 0 && listIndex < m_names.size());
+
+ WebViewImpl* webView = getWebView();
+ if (!webView)
+ return;
+
+ webView->client()->didAcceptAutoFillSuggestion(WebNode(getTextField()),
+ m_names[listIndex],
+ m_labels[listIndex]);
+}
+
void AutoFillPopupMenuClient::initialize(
HTMLInputElement* textField,
const WebVector<WebString>& names,
diff --git a/WebKit/chromium/src/AutoFillPopupMenuClient.h b/WebKit/chromium/src/AutoFillPopupMenuClient.h
index 1912fa3..568ce4d 100644
--- a/WebKit/chromium/src/AutoFillPopupMenuClient.h
+++ b/WebKit/chromium/src/AutoFillPopupMenuClient.h
@@ -50,6 +50,9 @@ public:
virtual WebString getSuggestion(unsigned listIndex) const;
virtual void removeSuggestionAtIndex(unsigned listIndex);
+ // WebCore::PopupMenuClient implementation:
+ virtual void valueChanged(unsigned listIndex, bool fireEvents = true);
+
void initialize(WebCore::HTMLInputElement*,
const WebVector<WebString>& names,
const WebVector<WebString>& labels,
--
WebKit Debian packaging
More information about the Pkg-webkit-commits
mailing list