1 2010-12-21 Darin Adler <darin@apple.com>
3 Reviewed by Sam Weinig.
5 Mac WebKit delivers an extra didCommit when loading web archives
6 https://bugs.webkit.org/show_bug.cgi?id=51419
8 * UIProcess/WebFrameProxy.cpp:
9 (WebKit::WebFrameProxy::didStartProvisionalLoad): Added assertions so we catch
10 inconsistencies here instead of at the application level. Later, we will have
11 to decide what to do in cases these assertions fail. The right policy is probably
12 to consider it a web process failure and do whatever we do for those.
13 (WebKit::WebFrameProxy::didReceiveServerRedirectForProvisionalLoad): Ditto.
14 (WebKit::WebFrameProxy::didFailProvisionalLoad): Ditto.
15 (WebKit::WebFrameProxy::didCommitLoad): Ditto.
16 (WebKit::WebFrameProxy::didFinishLoad): Ditto.
17 (WebKit::WebFrameProxy::didFailLoad): Ditto.
19 2010-12-21 Anders Carlsson <andersca@apple.com>
21 Fix Snow Leopard build.
23 * WebProcess/Plugins/Netscape/NetscapeBrowserFuncs.cpp:
24 (WebKit::NPN_GetValue):
26 2010-12-21 Anders Carlsson <andersca@apple.com>
28 Reviewed by Dan Bernstein.
30 Fix crash when a Carbon plug-in fails to initialize correctly
31 https://bugs.webkit.org/show_bug.cgi?id=51415
33 * WebProcess/Plugins/Netscape/NetscapeBrowserFuncs.cpp:
34 (WebKit::NPN_GetValue):
35 Don't claim to support the QuickDraw event model.
37 * WebProcess/Plugins/Netscape/mac/NetscapePluginMac.mm:
38 (WebKit::NetscapePlugin::platformDestroy):
39 Only try to remove the window from the map if it's not null.
41 2010-12-21 Anders Carlsson <andersca@apple.com>
43 Reviewed by Darin Adler.
45 Add ArgumentCoder support for CFDataRef
46 https://bugs.webkit.org/show_bug.cgi?id=51412
48 * Shared/cf/ArgumentCodersCF.cpp:
49 (CoreIPC::typeFromCFTypeRef):
52 * Shared/cf/ArgumentCodersCF.h:
54 2010-12-21 Anders Carlsson <andersca@apple.com>
56 Reviewed by John Sullivan.
58 Clicking missing plug-in text does not show a sheet
59 https://bugs.webkit.org/show_bug.cgi?id=51403
61 * UIProcess/API/C/WKPage.h:
62 Add missingPluginButtonClicked to WKPageUIClient.
64 * UIProcess/WebPageProxy.cpp:
65 (WebKit::WebPageProxy::missingPluginButtonClicked):
66 Call the WebUIClient member function.
68 * UIProcess/WebPageProxy.messages.in:
69 Add MissingPluginButtonClicked message.
71 * UIProcess/WebUIClient.cpp:
72 (WebKit::WebUIClient::missingPluginButtonClicked):
73 Call the WKPageUIClient callback.
75 * UIProcess/WebUIClient.h:
76 * WebProcess/WebCoreSupport/WebChromeClient.cpp:
77 (WebKit::WebChromeClient::shouldMissingPluginMessageBeButton):
78 Always return true for now.
80 (WebKit::WebChromeClient::missingPluginButtonClicked):
81 Send a MissingPluginButtonClicked message.
83 2010-12-21 Laszlo Gombos <laszlo.1.gombos@nokia.com>
85 Reviewed by Andreas Kling.
87 [Qt] Set BUILDING_QT__ consistently
88 https://bugs.webkit.org/show_bug.cgi?id=51341
90 * WebKit2.pro: Remove the definition of BUILDING_QT__ as it
91 is already defined in WebKit.pri.
93 2010-12-20 Sam Weinig <sam@webkit.org>
95 Reviewed by Anders Carlsson.
97 WebKit2: Add resource load client API
98 https://bugs.webkit.org/show_bug.cgi?id=51370
100 This just pipes through the basic resource load client data.
102 * UIProcess/API/C/WKPage.cpp:
103 (WKPageSetPageResourceLoadClient):
104 * UIProcess/API/C/WKPage.h:
105 * UIProcess/WebPageProxy.cpp:
106 (WebKit::WebPageProxy::initializeResourceLoadClient):
107 (WebKit::WebPageProxy::didInitiateLoadForResource):
108 (WebKit::WebPageProxy::didSendRequestForResource):
109 (WebKit::WebPageProxy::didReceiveResponseForResource):
110 (WebKit::WebPageProxy::didReceiveContentLengthForResource):
111 (WebKit::WebPageProxy::didFinishLoadForResource):
112 (WebKit::WebPageProxy::didFailLoadForResource):
113 * UIProcess/WebPageProxy.h:
114 * UIProcess/WebPageProxy.messages.in:
115 * UIProcess/WebResourceLoadClient.cpp: Added.
116 (WebKit::WebResourceLoadClient::didInitiateLoadForResource):
117 (WebKit::WebResourceLoadClient::didSendRequestForResource):
118 (WebKit::WebResourceLoadClient::didReceiveResponseForResource):
119 (WebKit::WebResourceLoadClient::didReceiveContentLengthForResource):
120 (WebKit::WebResourceLoadClient::didFinishLoadForResource):
121 (WebKit::WebResourceLoadClient::didFailLoadForResource):
122 * UIProcess/WebResourceLoadClient.h: Added.
124 * WebKit2.xcodeproj/project.pbxproj:
125 * WebProcess/WebCoreSupport/WebFrameLoaderClient.cpp:
126 (WebKit::WebFrameLoaderClient::assignIdentifierToInitialRequest):
127 (WebKit::WebFrameLoaderClient::dispatchWillSendRequest):
128 (WebKit::WebFrameLoaderClient::dispatchDidReceiveResponse):
129 (WebKit::WebFrameLoaderClient::dispatchDidReceiveContentLength):
130 (WebKit::WebFrameLoaderClient::dispatchDidFinishLoading):
131 (WebKit::WebFrameLoaderClient::dispatchDidFailLoading):
132 * win/WebKit2.vcproj:
134 2010-12-20 Anders Carlsson <andersca@apple.com>
136 Reviewed by Sam Weinig.
138 Add a TextChecker class, hook up spelling and grammar toggling
139 https://bugs.webkit.org/show_bug.cgi?id=51363
141 * UIProcess/API/mac/WKView.mm:
142 (-[WKView validateUserInterfaceItem:]):
143 (-[WKView toggleContinuousSpellChecking:]):
144 (-[WKView toggleGrammarChecking:]):
145 * UIProcess/TextChecker.h: Added.
146 * UIProcess/WebPageProxy.cpp:
147 (WebKit::WebPageProxy::unmarkAllMisspellings):
148 (WebKit::WebPageProxy::unmarkAllBadGrammar):
149 * UIProcess/WebPageProxy.h:
150 * UIProcess/mac/TextCheckerMac.mm: Added.
151 (WebKit::TextChecker::isContinuousSpellCheckingAllowed):
152 (WebKit::TextChecker::isContinuousSpellCheckingEnabled):
153 (WebKit::TextChecker::setContinuousSpellCheckingEnabled):
154 (WebKit::TextChecker::isGrammarCheckingEnabled):
155 (WebKit::TextChecker::setGrammarCheckingEnabled):
156 * UIProcess/qt/TextCheckerQt.cpp: Added.
157 (WebKit::TextChecker::isContinuousSpellCheckingAllowed):
158 (WebKit::TextChecker::isContinuousSpellCheckingEnabled):
159 (WebKit::TextChecker::setContinuousSpellCheckingEnabled):
160 (WebKit::TextChecker::isGrammarCheckingEnabled):
161 (WebKit::TextChecker::setGrammarCheckingEnabled):
162 * UIProcess/win/TextCheckerWin.cpp: Added.
163 (WebKit::TextChecker::isContinuousSpellCheckingAllowed):
164 (WebKit::TextChecker::isContinuousSpellCheckingEnabled):
165 (WebKit::TextChecker::setContinuousSpellCheckingEnabled):
166 (WebKit::TextChecker::isGrammarCheckingEnabled):
167 (WebKit::TextChecker::setGrammarCheckingEnabled):
169 * WebKit2.xcodeproj/project.pbxproj:
170 * WebProcess/WebPage/WebPage.cpp:
171 (WebKit::WebPage::unmarkAllMisspellings):
172 (WebKit::WebPage::unmarkAllBadGrammar):
173 * WebProcess/WebPage/WebPage.h:
174 * WebProcess/WebPage/WebPage.messages.in:
175 * win/WebKit2.vcproj:
177 2010-12-20 Anders Carlsson <andersca@apple.com>
179 Reviewed by Sam Weinig.
181 Flash plug-in does not work on YouTube video page when accelerated compositing is disabled
182 https://bugs.webkit.org/show_bug.cgi?id=51348
183 <rdar://problem/8787667>
185 * Platform/CoreIPC/HandleMessage.h:
186 (CoreIPC::callMemberFunction):
189 * PluginProcess/PluginControllerProxy.cpp:
190 (WebKit::PluginControllerProxy::create):
191 (WebKit::PluginControllerProxy::PluginControllerProxy):
192 These now take an additional isAcceleratedCompositingEnabled parameter.
194 (WebKit::PluginControllerProxy::isAcceleratedCompositingEnabled):
195 Return m_isAcceleratedCompositingEnabled.
197 * PluginProcess/PluginControllerProxy.h:
198 * PluginProcess/WebProcessConnection.cpp:
199 (WebKit::WebProcessConnection::createPlugin):
200 This now takes an additional isAcceleratedCompositingEnabled parameter.
202 * PluginProcess/WebProcessConnection.messages.in:
203 Add isAcceleratedCompositingEnabled parameter to the CreatePlugin message.
205 * WebProcess/Plugins/PluginProxy.cpp:
206 (WebKit::PluginProxy::initialize):
207 Pass isAcceleratedCompositingEnabled when sending the CreatePlugin message.
209 2010-12-20 Anders Carlsson <andersca@apple.com>
211 Unreviewed, rolling out r74345.
212 http://trac.webkit.org/changeset/74345
213 https://bugs.webkit.org/show_bug.cgi?id=51115
217 * Platform/CoreIPC/Connection.h:
218 * Platform/CoreIPC/qt/ConnectionQt.cpp:
219 (CoreIPC::Connection::open):
221 2010-12-20 Balazs Kelemen <kbalazs@webkit.org>
223 Reviewed by Kenneth Rohde Christiansen.
225 [Qt][WK2] Crash in web process after the connection had been closed
226 https://bugs.webkit.org/show_bug.cgi?id=51115
228 Do not call connectionDidClose with a connection that has been explicitly
229 invalidated on the listener thread.
230 * Platform/CoreIPC/Connection.h:
231 * Platform/CoreIPC/qt/ConnectionQt.cpp:
232 (CoreIPC::Connection::disconnectHandler): Added.
233 (CoreIPC::Connection::open):
235 2010-12-19 Dan Bernstein <mitz@apple.com>
237 Reviewed by Sam Weinig.
239 Improve the fix for <rdar://problem/8769525>.
241 * UIProcess/API/mac/WKView.mm:
242 (-[WKView performKeyEquivalent:]): Do not retain the view. Doing so is necessary in
243 -[WebHTMLView performKeyEquivalent:], which this method was based upon, but not here, because
244 there is no way for the web process to cause the WKView to be released while it is handling
247 2010-12-19 Dan Bernstein <mitz@apple.com>
249 Reviewed by Sam Weinig.
251 <rdar://problem/8769525> WKView leak when performing key equivalents
252 https://bugs.webkit.org/show_bug.cgi?id=51315
254 * UIProcess/API/mac/WKView.mm:
255 (-[WKView performKeyEquivalent:]): Use a RetainPtr to ensure that the view is released in the
256 early return code path.
258 2010-12-19 Benjamin Poulain <benjamin.poulain@nokia.com>
260 Reviewed by Kenneth Rohde Christiansen.
262 [Qt] [WK2] QWKPagePrivate::paint() does not need to save the graphics context
263 https://bugs.webkit.org/show_bug.cgi?id=51300
265 Remove the unnecessary save() and restore() on the QPainter.
267 * UIProcess/API/qt/qwkpage.cpp:
268 (QWKPagePrivate::paint):
270 2010-12-19 Kenneth Rohde Christiansen <kenneth@webkit.org>
272 Reviewed by Andreas Kling.
274 [Qt] [WK2] Client are expected to render their own background for WebPages
275 https://bugs.webkit.org/show_bug.cgi?id=51296
277 Remove the rendering of the checkerboard from the tiled DrawingAreaProxy
279 * UIProcess/TiledDrawingAreaProxy.cpp:
280 (WebKit::TiledDrawingAreaProxy::paint):
281 * UIProcess/TiledDrawingAreaTile.h:
282 * UIProcess/qt/TiledDrawingAreaTileQt.cpp:
284 2010-12-19 Benjamin Poulain <benjamin.poulain@nokia.com>
286 Reviewed by Kenneth Rohde Christiansen.
288 [Qt] [WK2] Client are expected to render their own background for WebPages
289 https://bugs.webkit.org/show_bug.cgi?id=51296
291 Do not render a white background before rendering the page with DrawingAreaProxy.
293 * UIProcess/API/qt/qwkpage.cpp:
294 (QWKPagePrivate::paint):
296 2010-12-17 Darin Adler <darin@apple.com>
298 Reviewed by Dan Bernstein.
300 Window title for image documents shows corrupted characters instead of multiplication sign when using WebKit2
301 https://bugs.webkit.org/show_bug.cgi?id=43505
303 * WebProcess/WebCoreSupport/WebPlatformStrategies.cpp: Changed UI_STRING macros to return
304 WebCore::String objects instead of C strings.
305 (WebKit::formatLocalizedString): Added. Uses the Core Foundation string formatting function for
306 reasons explained in the comment.
307 (WebKit::WebPlatformStrategies::multipleFileUploadText): Use formatLocalizedString instead of
309 (WebKit::WebPlatformStrategies::imageTitle): Ditto.
310 (WebKit::WebPlatformStrategies::localizedMediaTimeDescription): Ditto.
312 2010-12-17 Anders Carlsson <andersca@apple.com>
314 Reviewed by Sam Weinig.
316 Resizing a WKView while loading a page can leave the page at a size that doesn't match the window
317 https://bugs.webkit.org/show_bug.cgi?id=51282
318 <rdar://problem/8133142>
320 Fix a race condition in waitForMessage. If we time out on the wait condition, we would keep the
321 m_waitForMessageMutex mutex unlocked for a brief period of time before taking the lock again and
322 then removing the messageID/destinationID pair from the hash map. Under some circumstances, the
323 connection queue would update the hash map right before we removed it, leading to a lost message.
325 * Platform/CoreIPC/Connection.cpp:
326 (CoreIPC::Connection::waitForMessage):
328 2010-12-17 Anders Carlsson <andersca@apple.com>
330 Reviewed by Simon Fraser.
332 Clean up ChunkedUpdateDrawingAreaProxy
333 https://bugs.webkit.org/show_bug.cgi?id=51277
335 Get rid of m_lastSetViewSize since it was always equal to m_size.
337 * UIProcess/ChunkedUpdateDrawingAreaProxy.cpp:
338 (WebKit::ChunkedUpdateDrawingAreaProxy::sizeDidChange):
341 (WebKit::ChunkedUpdateDrawingAreaProxy::didSetSize):
342 Call sendSetSize if the size differs.
344 (WebKit::ChunkedUpdateDrawingAreaProxy::sendSetSize):
345 Move code from sizeDidChange over here.
347 * UIProcess/ChunkedUpdateDrawingAreaProxy.h:
348 * UIProcess/DrawingAreaProxy.cpp:
349 (WebKit::DrawingAreaProxy::setSize):
350 Add back the early return if the sizes are equal.
352 2010-12-17 Brent Fulgham <bfulgham@webkit.org>
354 Unreviewed build fix.
356 * WebProcess/WebPage/win/WebPageWin.cpp:
357 (WebKit::WebPage::canHandleRequest): Provide alternative for
358 non-CFNetwork implementation.
360 2010-12-17 Ada Chan <adachan@apple.com>
362 Reviewed by Anders Carlsson.
364 Implement WKView::setInitialFocus().
365 https://bugs.webkit.org/show_bug.cgi?id=51274
367 * UIProcess/API/C/win/WKView.cpp:
368 (WKViewSetInitialFocus):
369 * UIProcess/API/C/win/WKView.h:
370 * UIProcess/WebPageProxy.cpp:
371 (WebKit::WebPageProxy::setInitialFocus): Send message to the Web Process to set
373 * UIProcess/WebPageProxy.h:
374 * UIProcess/win/WebView.cpp:
375 (WebKit::WebView::setInitialFocus):
376 * UIProcess/win/WebView.h:
377 * WebProcess/WebPage/WebPage.cpp:
378 (WebKit::WebPage::setInitialFocus): Set the focused node to null initially. Then
379 ask FocusController to set the initial focus based on the focus direction.
380 * WebProcess/WebPage/WebPage.h:
381 * WebProcess/WebPage/WebPage.messages.in: Add a new message for SetInitialFocus.
383 2010-12-17 Anders Carlsson <andersca@apple.com>
385 Reviewed by Sam Weinig.
387 Remove a check that probably uncovered a resizing bug.
389 * UIProcess/DrawingAreaProxy.cpp:
390 (WebKit::DrawingAreaProxy::setSize):
392 2010-12-17 Brian Weinstein <bweinstein@apple.com>
396 * UIProcess/qt/WebPopupMenuProxyQt.h:
398 2010-12-17 Brian Weinstein <bweinstein@apple.com>
400 Reviewed by Anders Carlsson.
402 Text area does not update when you arrow through a <select> in WebKit2
403 https://bugs.webkit.org/show_bug.cgi?id=51269
404 <rdar://problem/8612853>
408 Insteaed of keeping track of the selected index of a <select> just in the UI process, we
409 need to pass this information along to the web process so that the web process can draw
410 the correct text in the text field at the top of the select, when the selection changes (via
411 the arrows or other typing while the select is opened).
413 When the selected item in a popup changes, the UI process sends a message to the web process, telling
414 it about the new selected index. The web process gets this message, and then sets the text that
415 is visible in the select element.
417 * UIProcess/API/mac/PageClientImpl.h: CreatePopupMenuProxy now takes a WebPageProxy.
418 * UIProcess/API/mac/PageClientImpl.mm:
419 (WebKit::PageClientImpl::createPopupMenuProxy): Pass the WebPageProxy to create.
420 * UIProcess/API/qt/qwkpage.cpp:
421 (QWKPagePrivate::createPopupMenuProxy):
422 * UIProcess/API/qt/qwkpage_p.h: CreatePopupMenuProxy now takes a WebPageProxy.
423 * UIProcess/PageClient.h: CreatePopupMenuProxy now takes a WebPageProxy.
424 * UIProcess/WebPageProxy.cpp:
425 (WebKit::WebPageProxy::valueChangedForPopupMenu): Send that the selected index changed to the
427 (WebKit::WebPageProxy::setTextFromItemForPopupMenu): Send that we should update the text for the
428 active popup menu (with the index of the item to show).
429 (WebKit::WebPageProxy::showPopupMenu): Pass the WebPageProxy to createPopupMenuProxy.
430 * UIProcess/WebPageProxy.h:
431 * UIProcess/WebPopupMenuProxy.h: Add a client who has virtual functions for the state changing of the
432 popup menu. ShowPopupMenu doesn't take a new selected index anymore, that is handled by the client,
433 and calling down to the web process.
434 (WebKit::WebPopupMenuProxy::Client::~Client):
435 (WebKit::WebPopupMenuProxy::WebPopupMenuProxy): Initialize the client.
436 * UIProcess/mac/WebPopupMenuProxyMac.h:
437 (WebKit::WebPopupMenuProxyMac::create): Takes a WebPopupMenuProxy::Client, and passes it to the constructor.
438 * UIProcess/mac/WebPopupMenuProxyMac.mm:
439 (WebKit::WebPopupMenuProxyMac::WebPopupMenuProxyMac): Update what's initialized by the constructor.
440 (WebKit::WebPopupMenuProxyMac::showPopupMenu): Call through to the web process that the value changed.
441 * UIProcess/qt/WebPopupMenuProxyQt.cpp:
442 (WebKit::WebPopupMenuProxyQt::WebPopupMenuProxyQt): Update what's initialized by the constructor.
443 * UIProcess/win/WebPopupMenuProxyWin.cpp:
444 (WebKit::WebPopupMenuProxyWin::WebPopupMenuProxyWin): Ditto.
445 (WebKit::WebPopupMenuProxyWin::showPopupMenu): Call through to the web process that the value changed.
446 (WebKit::WebPopupMenuProxyWin::setFocusedIndex): Resolve a FIXME to set the text of the popup menu.
447 * UIProcess/win/WebPopupMenuProxyWin.h:
448 (WebKit::WebPopupMenuProxyWin::create): Take in a WebPopupMenuProxy::client, and pass it to the constructor.
449 * UIProcess/win/WebView.cpp:
450 (WebKit::WebView::createPopupMenuProxy): Pass the WebPageProxy to create.
451 * UIProcess/win/WebView.h:
452 * WebProcess/WebCoreSupport/WebPopupMenu.cpp:
453 (WebKit::WebPopupMenu::setTextForIndex): Call through to setTextFromItem to set the select text.
454 * WebProcess/WebCoreSupport/WebPopupMenu.h:
455 * WebProcess/WebPage/WebPage.cpp: Call through to setTextForIndex on the active popup menu.
456 (WebKit::WebPage::setTextForActivePopupMenu):
457 * WebProcess/WebPage/WebPage.h:
458 * WebProcess/WebPage/WebPage.messages.in: Add a new message.
460 2010-12-17 Anders Carlsson <andersca@apple.com>
462 Reviewed by Sam Weinig.
464 DrawingAreaProxy::setSize shouldn't be a virtual member function
465 https://bugs.webkit.org/show_bug.cgi?id=51275
467 Add a pure virtual sizeDidChange member function to DrawingAreaProxy, and only
468 call it if the size changes.
470 * UIProcess/ChunkedUpdateDrawingAreaProxy.cpp:
471 (WebKit::ChunkedUpdateDrawingAreaProxy::sizeDidChange):
472 * UIProcess/ChunkedUpdateDrawingAreaProxy.h:
473 * UIProcess/DrawingAreaProxy.cpp:
474 (WebKit::DrawingAreaProxy::setSize):
475 * UIProcess/DrawingAreaProxy.h:
476 (WebKit::DrawingAreaProxy::size):
477 * UIProcess/LayerBackedDrawingAreaProxy.cpp:
478 (WebKit::LayerBackedDrawingAreaProxy::sizeDidChange):
479 * UIProcess/LayerBackedDrawingAreaProxy.h:
480 * UIProcess/TiledDrawingAreaProxy.cpp:
481 (WebKit::TiledDrawingAreaProxy::sizeDidChange):
482 * UIProcess/TiledDrawingAreaProxy.h:
484 2010-12-17 Anders Carlsson <andersca@apple.com>
486 Reviewed by Sam Weinig.
488 Add a WebPageProxy parameter to the DrawingAreaProxy constructor
489 https://bugs.webkit.org/show_bug.cgi?id=51271
491 * UIProcess/API/mac/WKView.mm:
492 (-[WKView initWithFrame:contextRef:pageGroupRef:]):
493 (-[WKView _switchToDrawingAreaTypeIfNecessary:DrawingAreaInfo::]):
494 * UIProcess/API/qt/qgraphicswkview.cpp:
495 (QGraphicsWKView::QGraphicsWKView):
496 * UIProcess/ChunkedUpdateDrawingAreaProxy.cpp:
497 (WebKit::ChunkedUpdateDrawingAreaProxy::create):
498 (WebKit::ChunkedUpdateDrawingAreaProxy::ChunkedUpdateDrawingAreaProxy):
499 * UIProcess/ChunkedUpdateDrawingAreaProxy.h:
500 * UIProcess/DrawingAreaProxy.cpp:
501 (WebKit::DrawingAreaProxy::DrawingAreaProxy):
502 * UIProcess/DrawingAreaProxy.h:
503 * UIProcess/LayerBackedDrawingAreaProxy.cpp:
504 (WebKit::LayerBackedDrawingAreaProxy::create):
505 (WebKit::LayerBackedDrawingAreaProxy::LayerBackedDrawingAreaProxy):
506 * UIProcess/LayerBackedDrawingAreaProxy.h:
507 * UIProcess/TiledDrawingAreaProxy.cpp:
508 (WebKit::TiledDrawingAreaProxy::create):
509 (WebKit::TiledDrawingAreaProxy::TiledDrawingAreaProxy):
510 * UIProcess/TiledDrawingAreaProxy.h:
511 * UIProcess/win/WebView.cpp:
512 (WebKit::WebView::WebView):
513 (WebKit::WebView::switchToDrawingAreaTypeIfNecessary):
515 2010-12-17 Dan Bernstein <mitz@apple.com>
517 Reviewed by Darin Adler.
519 Add API for "Always Use the Complex Text Code Path"
520 https://bugs.webkit.org/show_bug.cgi?id=51265
522 * Shared/WebProcessCreationParameters.cpp:
523 (WebKit::WebProcessCreationParameters::WebProcessCreationParameters): Initialize shouldAlwaysUseComplexTextCodePath.
524 (WebKit::WebProcessCreationParameters::encode): Encode shouldAlwaysUseComplexTextCodePath.
525 (WebKit::WebProcessCreationParameters::decode): Decode shouldAlwaysUseComplexTextCodePath.
526 * Shared/WebProcessCreationParameters.h:
527 * UIProcess/API/C/WKContext.cpp:
528 (_WKContextSetAlwaysUsesComplexTextCodePath): Added.
529 * UIProcess/API/C/WKContextPrivate.h:
530 * UIProcess/WebContext.cpp:
531 (WebKit::WebContext::WebContext): Initialize m_alwaysUsesComplexTextCodePath.
532 (WebKit::WebContext::ensureWebProcess): Set shouldAlwaysUseComplexTextCodePath in the creation parameters.
533 (WebKit::WebContext::setAlwaysUsesComplexTextCodePath): Added. Sets m_alwaysUsesComplexTextCodePath and
534 sends a message to the WebProcess.
535 * UIProcess/WebContext.h:
536 * WebProcess/WebProcess.cpp:
537 (WebKit::WebProcess::initializeWebProcess): Call setAlwaysUsesComplexTextCodePath() based on the creation
539 (WebKit::WebProcess::setAlwaysUsesComplexTextCodePath): Added.
540 * WebProcess/WebProcess.h:
541 * WebProcess/WebProcess.messages.in: Added SetAlwaysUsesComplexTextCodePath.
543 2010-12-17 Sam Weinig <sam@webkit.org>
545 Reviewed by Darin Adler.
547 WebKit2: Implement a title attribute per frame
548 https://bugs.webkit.org/show_bug.cgi?id=51266
550 Cache the title of each frame on the WebFrameProxy. Removes
551 the WebPageProxy's cache of the main frame title to just
552 access the main frame.
554 We clear the cached title on new committed loads and on failures
557 * UIProcess/API/C/WKFrame.cpp:
559 * UIProcess/API/C/WKFrame.h:
560 * UIProcess/WebFrameProxy.cpp:
561 (WebKit::WebFrameProxy::didCommitLoad):
562 (WebKit::WebFrameProxy::didFailLoad):
563 (WebKit::WebFrameProxy::didChangeTitle):
564 * UIProcess/WebFrameProxy.h:
565 (WebKit::WebFrameProxy::title):
566 * UIProcess/WebPageProxy.cpp:
567 (WebKit::WebPageProxy::close):
568 (WebKit::WebPageProxy::pageTitle):
569 (WebKit::WebPageProxy::didReceiveTitleForFrame):
570 (WebKit::WebPageProxy::processDidCrash):
571 * UIProcess/WebPageProxy.h:
573 2010-12-16 Darin Adler <darin@apple.com>
575 Reviewed by Maciej Stachowiak.
577 Add text encoding menu API for WebKit2
578 https://bugs.webkit.org/show_bug.cgi?id=51226
580 * UIProcess/API/C/WKPage.cpp:
581 (WKPageSupportsTextEncoding): Added.
582 (WKPageCopyCustomTextEncodingName): Added.
583 (WKPageSetCustomTextEncodingName): Added.
584 * UIProcess/API/C/WKPage.h: Added the functions above.
586 * UIProcess/WebPageProxy.cpp:
587 (WebKit::WebPageProxy::WebPageProxy): Initialize
588 m_mainFrameHasCustomRepresentation to false.
589 (WebKit::WebPageProxy::supportsTextEncoding): Added.
590 (WebKit::WebPageProxy::setCustomTextEncodingName): Added.
591 (WebKit::WebPageProxy::didCommitLoadForFrame): Set
592 m_mainFrameHasCustomRepresentation.
594 * UIProcess/WebPageProxy.h: Added supportsTextEncoding,
595 setCustomTextEncodingName, customTextEncodingName, and
596 m_mainFrameHasCustomRepresentation.
598 * UIProcess/WebPageProxy.messages.in: Tweaked formatting
599 (added a blank line).
601 * WebProcess/WebPage/WebPage.cpp:
602 (WebKit::WebPage::setCustomTextEncodingName): Added.
603 * WebProcess/WebPage/WebPage.h: Added setCustomTextEncodingName.
605 * WebProcess/WebPage/WebPage.messages.in: Added the
606 SetCustomTextEncodingName message. Tweaked formatting of the
609 2010-12-17 Sheriff Bot <webkit.review.bot@gmail.com>
611 Unreviewed, rolling out r74201.
612 http://trac.webkit.org/changeset/74201
613 https://bugs.webkit.org/show_bug.cgi?id=51248
615 It broke ~6000 layout tests (Requested by Ossy_ on #webkit).
617 * UIProcess/API/qt/qgraphicswkview.cpp:
618 (QGraphicsWKView::setGeometry):
619 (QGraphicsWKView::itemChange):
621 2010-12-16 Sam Weinig <sam@webkit.org>
623 Reviewed by Darin Adler.
625 Add svn:eol-style native to the message.in files as a favor to Darin Adler.
627 * PluginProcess/PluginControllerProxy.messages.in: Added property svn:eol-style.
628 * PluginProcess/PluginProcess.messages.in: Added property svn:eol-style.
629 * PluginProcess/WebProcessConnection.messages.in: Added property svn:eol-style.
630 * Shared/Plugins/NPObjectMessageReceiver.messages.in: Added property svn:eol-style.
631 * UIProcess/Downloads/DownloadProxy.messages.in: Added property svn:eol-style.
632 * UIProcess/Plugins/PluginProcessProxy.messages.in: Added property svn:eol-style.
633 * UIProcess/WebContext.messages.in: Added property svn:eol-style.
634 * UIProcess/WebDatabaseManagerProxy.messages.in: Added property svn:eol-style.
635 * UIProcess/WebInspectorProxy.messages.in: Added property svn:eol-style.
636 * UIProcess/WebPageProxy.messages.in: Added property svn:eol-style.
637 * UIProcess/WebProcessProxy.messages.in: Added property svn:eol-style.
638 * WebProcess/Authentication/AuthenticationManager.messages.in: Added property svn:eol-style.
639 * WebProcess/Plugins/PluginProxy.messages.in: Added property svn:eol-style.
640 * WebProcess/WebCoreSupport/WebDatabaseManager.messages.in: Added property svn:eol-style.
641 * WebProcess/WebPage/WebInspector.messages.in: Added property svn:eol-style.
642 * WebProcess/WebPage/WebPage.messages.in: Added property svn:eol-style.
643 * WebProcess/WebProcess.messages.in: Added property svn:eol-style.
645 2010-12-16 Sam Weinig <sam@webkit.org>
647 Reviewed by Anders Carlsson.
649 Move NSURLCache initialization from the ProcessLauncherMac to the centralized
650 WebContext initialize WebProcess mechanism.
652 * Shared/WebProcessCreationParameters.cpp:
653 (WebKit::WebProcessCreationParameters::WebProcessCreationParameters):
654 (WebKit::WebProcessCreationParameters::encode):
655 (WebKit::WebProcessCreationParameters::decode):
656 * Shared/WebProcessCreationParameters.h:
657 * UIProcess/Launcher/mac/ProcessLauncherMac.mm:
658 (WebKit::ProcessLauncher::launchProcess):
659 * UIProcess/mac/WebContextMac.mm:
660 (WebKit::WebContext::platformInitializeWebProcess):
661 * WebProcess/WebProcess.cpp:
662 (WebKit::WebProcess::initializeWebProcess):
663 * WebProcess/mac/WebProcessMac.mm:
664 (WebKit::WebProcess::platformInitializeWebProcess):
665 * WebProcess/mac/WebProcessMainMac.mm:
666 (WebKit::WebProcessMain):
667 * WebProcess/win/WebProcessWin.cpp:
668 (WebKit::WebProcess::platformInitializeWebProcess):
669 (WebKit::WebProcess::setShouldPaintNativeControls):
671 2010-12-16 Anders Carlsson <andersca@apple.com>
673 Reviewed by Dan Bernstein.
675 Defer getting a PluginProcessConnection object until the plug-in is initialized
676 https://bugs.webkit.org/show_bug.cgi?id=51207
677 <rdar://problem/8731306>
679 Before this change, we would pass the PluginProcessConnection to the PluginProxy constructor, but not
680 call PluginProcessConnection::addPluginProxy (which associates the plug-in proxy with the connection)
681 until the plug-in is initialized.
683 This could lead to a PluginProxy holding a reference to a PluginProcessConnection when the PluginProxyConnection
684 itself did not know anything about the PluginProxy. This would happen when a page with plug-ins is opened in a background
685 tab, with the plug-ins not yet initialized.
687 Because of this, we could end up in a weird state, where the PluginProcessConnection would think that there are no
688 more plug-ins alive, and invalidate (and null out) the underlying CoreIPC connection, which would lead to crashes
689 when trying to send messages to the connection during later initialization.
691 The fix is to pass the plug-in path to the PluginProxy constructor, and get the connection from PluginProxy::initialize.
693 PluginProcessConnection object
694 * WebProcess/Plugins/PluginProxy.cpp:
695 (WebKit::PluginProxy::create):
696 (WebKit::PluginProxy::PluginProxy):
697 (WebKit::PluginProxy::initialize):
698 * WebProcess/Plugins/PluginProxy.h:
699 * WebProcess/WebPage/WebPage.cpp:
700 (WebKit::WebPage::createPlugin):
702 2010-12-16 Enrica Casucci <enrica@apple.com>
704 Reviewed by Maciej Stachowiak.
706 WebKit2: Cannot copy two successive selections using cmd-c
707 <rdar://problem/8680309>
708 https://bugs.webkit.org/show_bug.cgi?id=51203
710 The previous implementation assumed a call sequence from AppKit that
711 was not always happening.
712 When the user clicks on the pulldown menu, AppKit sends validateUserInterfaceItem
713 calls for each element that needs validation and we used to count the number of
714 validation requests being sent to the web process.
715 All these calls are made before we have the chance to get one reply from the WebProcess.
716 We also delayed the menu update until we had received all the replies to the validation requests.
717 At that point we called update on the menu to trigger the validation one more time with
718 the data retrived from the WebProcess.
719 When the user simply presses cmd-c, only one call to vaidateUserInterfaceItem is made
720 and the menu update triggered the validation of all the menu entries causing the internal
721 state to be out of sync.
722 The new implementation is very simple: for each validation request from AppKit we send
723 a request to the WebProcess and we cache a reference to the menu item being validated.
724 When the WebProcess replies, we retrieve the menu item from our cache and update its state.
726 * UIProcess/API/mac/WKView.mm:
727 (-[WKView initWithFrame:contextRef:pageGroupRef:]): Removed initialization of deleted memebers.
728 (-[WKView validateUserInterfaceItem:]): Request validation to the WebProcess and return YES to
729 allow AppKit to do the keyBinding processing.
730 (-[WKView _setUserInterfaceItemState:enabled:state:]): Called when the WebProcess replies to the
731 validation request to check/uncheck and enable/disable the menu item.
733 2010-12-16 Anders Carlsson <andersca@apple.com>
735 Reviewed by Oliver Hunt.
737 Don't try to call plug-in member functions if the plug-in hasn't been initialized
738 https://bugs.webkit.org/show_bug.cgi?id=51205
739 <rdar://problem/8730204>
741 Make sure that all PluginView functions that can be called while a plug-in has not been
742 initialized (if the plug-in page is in a background tab for example) have an additional
743 check for m_isInitialized.
745 * WebProcess/Plugins/PluginView.cpp:
746 (WebKit::PluginView::setWindowIsFocused):
747 (WebKit::PluginView::windowAndViewFramesChanged):
748 (WebKit::PluginView::platformLayer):
749 (WebKit::PluginView::scriptObject):
750 (WebKit::PluginView::privateBrowsingStateChanged):
751 (WebKit::PluginView::handleEvent):
752 (WebKit::PluginView::viewGeometryDidChange):
753 (WebKit::PluginView::setFocus):
755 2010-12-16 Anders Carlsson <andersca@apple.com>
757 Reviewed by John Sullivan.
759 Add a bunch of m_isStarted assertions to plug-in code.
761 * WebProcess/Plugins/Netscape/NetscapePlugin.cpp:
762 (WebKit::NetscapePlugin::frameDidFinishLoading):
763 (WebKit::NetscapePlugin::frameDidFail):
764 (WebKit::NetscapePlugin::didEvaluateJavaScript):
765 (WebKit::NetscapePlugin::streamDidReceiveResponse):
766 (WebKit::NetscapePlugin::streamDidReceiveData):
767 (WebKit::NetscapePlugin::streamDidFinishLoading):
768 (WebKit::NetscapePlugin::streamDidFail):
769 (WebKit::NetscapePlugin::manualStreamDidReceiveResponse):
770 (WebKit::NetscapePlugin::manualStreamDidReceiveData):
771 (WebKit::NetscapePlugin::manualStreamDidFinishLoading):
772 (WebKit::NetscapePlugin::manualStreamDidFail):
773 (WebKit::NetscapePlugin::handleMouseEvent):
774 (WebKit::NetscapePlugin::handleWheelEvent):
775 (WebKit::NetscapePlugin::handleMouseEnterEvent):
776 (WebKit::NetscapePlugin::handleMouseLeaveEvent):
777 (WebKit::NetscapePlugin::handleKeyboardEvent):
778 (WebKit::NetscapePlugin::setFocus):
779 (WebKit::NetscapePlugin::pluginScriptableNPObject):
780 (WebKit::NetscapePlugin::privateBrowsingStateChanged):
782 2010-12-16 Anders Carlsson <andersca@apple.com>
784 Reviewed by Darin Adler.
786 Save the manual plug-in stream data and redeliver it when the plug-in is initialized
787 https://bugs.webkit.org/show_bug.cgi?id=51201
789 * WebProcess/Plugins/PluginView.cpp:
790 (WebKit::PluginView::PluginView):
791 Initialize m_manualStreamState.
793 (WebKit::PluginView::manualLoadDidReceiveResponse):
794 If the plug-in hasn't been initialized, store the response.
796 (WebKit::PluginView::manualLoadDidReceiveData):
797 If the plug-in hasn't been initialized, store the data.
799 (WebKit::PluginView::manualLoadDidFinishLoading):
800 If the plug-in hasn't been initialized, update the state.
802 (WebKit::PluginView::manualLoadDidFail):
803 If the plug-in hasn't been initialized, store the error and update the state.
805 (WebKit::PluginView::initializePlugin):
806 Call redeliverManualStream.
808 (WebKit::PluginView::redeliverManualStream):
809 Redeliver the manual stream to the plug-in.
811 * WebProcess/Plugins/PluginView.h:
813 2010-12-16 Kimmo Kinnunen <kimmo.t.kinnunen@nokia.com>
815 Reviewed by Andreas Kling.
817 [Qt] Turn off drawing area updates if the item is not visible
819 The updates are controlled by the QGraphicsItem::visible property.
821 * UIProcess/API/qt/qgraphicswkview.cpp:
822 (QGraphicsWKViewPrivate::updateViewportSize):
823 (QGraphicsWKView::setGeometry):
824 (QGraphicsWKView::itemChange):
826 2010-12-15 Dan Bernstein <mitz@apple.com>
828 Reviewed by Sam Weinig.
830 <rdar://problem/8731320> WebProcess’s CFNetwork cache is in ~/Library/Caches/com.apple.WebProcess
832 * UIProcess/Launcher/mac/ProcessLauncherMac.mm:
833 (WebKit::ProcessLauncher::launchProcess): Get the location, disk capacity and memory capacity
834 of the UI process’s NSURLCache and pass them to the WebProcess.
835 * WebProcess/mac/WebProcessMainMac.mm:
836 (WebKit::WebProcessMain): If an NSURLCache location was passed on the command line, set the
837 shared NSURLCache to that path and use the specified capacities as initial values.
839 2010-12-15 Dan Bernstein <mitz@apple.com>
841 Reviewed by Sam “I blame andersca” Weinig.
843 Allow responses to be cached by the NSURLCache.
845 * WebProcess/WebCoreSupport/WebFrameLoaderClient.cpp:
846 (WebKit::WebFrameLoaderClient::willCacheResponse): Changed to return the response instead of 0.
848 2010-12-14 Enrica Casucci <enrica@apple.com>
850 Reviewed by Adam Roben.
852 Add IME support to WebKit2 on Windows
853 https://bugs.webkit.org/show_bug.cgi?id=51049
854 The implementation is very close to the one in WebKit.
855 The main change is the addition of handlers for WM_IME_STARTCOMPOSITION,
856 WM_IME_REQUEST, WM_IME_COMPOSITION, WM_IME_ENDCOMPOSITION,
857 WM_IME_SELECT, WM_IME_SETCONTEXT and a number of new messages
858 between the UI process and the WebProcess to send/retrieve
859 the data being handled by the messages listed above.
861 * UIProcess/PageClient.h: Added compositionSelectionChanged for Windows platform.
862 * UIProcess/WebPageProxy.cpp:
863 The following methods send synchronous messages to the WebProcess.
864 (WebKit::WebPageProxy::firstRectForCharacterInSelectedRange): Retrieves the rectangle to position
865 the cnadidates window.
866 (WebKit::WebPageProxy::getSelectedText): Retrieves the currently selected text.
867 The following methods send asynchronous messages to the WebProcess.
868 (WebKit::WebPageProxy::confirmComposition):
869 (WebKit::WebPageProxy::setComposition):
870 (WebKit::WebPageProxy::didChangeSelection): Name changed.
871 (WebKit::WebPageProxy::didChangeCompositionSelection): Called when there is a change
872 in the composition selection.
873 * UIProcess/WebPageProxy.messages.in: Added messages corresponding to the methods above.
874 * UIProcess/win/WebView.cpp:
875 (WebKit::WebView::wndProc): Added handling of messages for IME.
876 The following are the handlers for the window message being sent during composition.
877 (WebKit::WebView::onIMEComposition):
878 (WebKit::WebView::onIMEEndComposition):
879 (WebKit::WebView::onIMERequestCharPosition):
880 (WebKit::WebView::onIMERequestReconvertString):
881 (WebKit::WebView::onIMERequest):
882 (WebKit::WebView::onIMESelect):
883 (WebKit::WebView::onIMESetContext):
884 * WebProcess/WebCoreSupport/WebEditorClient.cpp:
885 (WebKit::WebEditorClient::respondToChangedSelection): Added notification
886 of composition selection changed for Windows.
887 * WebProcess/WebPage/win/WebPageWin.cpp:
888 The following are the WebProcess counterparts of the new messages.
889 (WebKit::WebPage::confirmComposition):
890 (WebKit::WebPage::setComposition):
891 (WebKit::WebPage::firstRectForCharacterInSelectedRange):
892 (WebKit::WebPage::getSelectedText):
894 2010-12-15 Sam Weinig <sam@webkit.org>
896 Reviewed by Brady Eidson.
898 Loading webkit.org over and over is slower in WebKit2 than WebKit1, looks like page is not cached
899 <rdar://problem/8774683>
900 https://bugs.webkit.org/show_bug.cgi?id=51143
902 * WebProcess/WebCoreSupport/WebFrameLoaderClient.cpp:
903 (WebKit::WebFrameLoaderClient::canCachePage): Return true as long as we
904 are not a custom representation (eg. a PDF).
905 (WebKit::WebFrameLoaderClient::shouldCacheResponse): Always return true.
906 * WebProcess/WebPage/WebPage.cpp:
907 (WebKit::WebPage::updatePreferences): Enable the page cache.
909 2010-12-15 Simon Fraser <simon.fraser@apple.com>
911 Reviewed by Adele Peterson.
913 WebKit2 in compositing mode no longer has font smoothing
914 https://bugs.webkit.org/show_bug.cgi?id=50733
916 Tell the root GraphicsLayer that its contents are opaque
917 if the WebPage draws its background, and that background
920 The GraphicsLayer then uses the 'contentsOpaque' setting to
921 determine whether to use font smoothing.
923 Add pageBackgroundTransparencyChanged() to DrawingArea
924 so that the WebPage can inform the DrawingArea when the
925 background transparency changes.
927 * WebProcess/WebPage/DrawingArea.h:
928 (WebKit::DrawingArea::pageBackgroundTransparencyChanged):
929 (WebKit::DrawingArea::onPageClose):
930 * WebProcess/WebPage/LayerBackedDrawingArea.cpp:
931 (WebKit::LayerBackedDrawingArea::LayerBackedDrawingArea):
932 (WebKit::LayerBackedDrawingArea::pageBackgroundTransparencyChanged):
933 * WebProcess/WebPage/LayerBackedDrawingArea.h:
934 * WebProcess/WebPage/WebPage.cpp:
935 (WebKit::WebPage::setDrawsBackground):
936 (WebKit::WebPage::setDrawsTransparentBackground):
938 2010-12-15 Anders Carlsson <andersca@apple.com>
940 Reviewed by Sam Weinig.
942 Fix assertion in plugins/return-error-from-new-stream-callback-in-full-frame-plugin.html test
943 https://bugs.webkit.org/show_bug.cgi?id=51136
945 Ensure that a plug-in that has explicitly cancelled the manual stream won't get any more callbacks.
947 * PluginProcess/PluginControllerProxy.cpp:
948 (WebKit::PluginControllerProxy::PluginControllerProxy):
949 (WebKit::PluginControllerProxy::cancelManualStreamLoad):
950 (WebKit::PluginControllerProxy::manualStreamDidReceiveResponse):
951 (WebKit::PluginControllerProxy::manualStreamDidReceiveData):
952 (WebKit::PluginControllerProxy::manualStreamDidFinishLoading):
953 (WebKit::PluginControllerProxy::manualStreamDidFail):
954 * PluginProcess/PluginControllerProxy.h:
956 2010-12-15 Brian Weinstein <bweinstein@apple.com>
958 Windows Build Fix. A .h file was added to the vcproj twice, but not its corresponding cpp file.
960 * win/WebKit2.vcproj:
962 2010-12-15 Sam Weinig <sam@webkit.org>
964 Reviewed by Anders Carlsson.
966 WebKit2: Can't add files to an <input type=file>
967 https://bugs.webkit.org/show_bug.cgi?id=51087
969 * Scripts/webkit2/messages.py:
972 * Shared/API/c/WKBase.h:
973 Adds WKOpenPanelParametersRef and WKOpenPanelResultListenerRef.
975 * Shared/APIObject.h:
976 Adds TypeOpenPanelParameters and TypeOpenPanelResultListener.
978 * Shared/WebOpenPanelParameters.cpp: Added.
979 (WebKit::WebOpenPanelParameters::create):
980 (WebKit::WebOpenPanelParameters::WebOpenPanelParameters):
981 (WebKit::WebOpenPanelParameters::~WebOpenPanelParameters):
982 (WebKit::WebOpenPanelParameters::Data::encode):
983 (WebKit::WebOpenPanelParameters::Data::decode):
984 * Shared/WebOpenPanelParameters.h: Added.
985 (WebKit::WebOpenPanelParameters::allowMultipleFiles):
986 (WebKit::WebOpenPanelParameters::type):
987 Class representing options one can pass to open panel.
989 * UIProcess/API/C/WKAPICast.h:
990 Add casts for WebOpenPanelParameters and WebOpenPanelResultListenerProxy.
992 * UIProcess/API/C/WKOpenPanelParameters.cpp: Added.
993 (WKOpenPanelParametersGetTypeID):
994 (WKOpenPanelParametersGetAllowsMultipleFiles):
995 * UIProcess/API/C/WKOpenPanelParameters.h: Added.
996 * UIProcess/API/C/WKOpenPanelResultListener.cpp: Added.
997 (WKOpenPanelResultListenerGetTypeID):
998 (WKOpenPanelResultListenerChooseFiles):
999 (WKOpenPanelResultListenerCancel):
1000 * UIProcess/API/C/WKOpenPanelResultListener.h: Added.
1003 * UIProcess/API/C/WKPage.h:
1004 Add new UI callback, WKPageRunOpenPanelCallback.
1006 * UIProcess/API/C/WebKit2.h:
1007 Add includes for new API headers.
1009 * UIProcess/API/qt/qwkpage.cpp:
1011 Stub out the runOpenPanel callback.
1013 * UIProcess/WebOpenPanelResultListenerProxy.cpp: Added.
1014 (WebKit::WebOpenPanelResultListenerProxy::WebOpenPanelResultListenerProxy):
1015 (WebKit::WebOpenPanelResultListenerProxy::~WebOpenPanelResultListenerProxy):
1016 (WebKit::WebOpenPanelResultListenerProxy::chooseFiles):
1017 (WebKit::WebOpenPanelResultListenerProxy::cancel):
1018 (WebKit::WebOpenPanelResultListenerProxy::invalidate):
1019 * UIProcess/WebOpenPanelResultListenerProxy.h: Added.
1020 (WebKit::WebOpenPanelResultListenerProxy::create):
1021 (WebKit::WebOpenPanelResultListenerProxy::type):
1022 Adds the listener used to choose files for <input type=file>
1024 * UIProcess/WebPageProxy.cpp:
1025 (WebKit::WebPageProxy::runOpenPanel):
1026 (WebKit::WebPageProxy::didChooseFilesForOpenPanel):
1027 (WebKit::WebPageProxy::didCancelForOpenPanel):
1028 * UIProcess/WebPageProxy.h:
1029 * UIProcess/WebPageProxy.messages.in:
1030 * UIProcess/WebUIClient.cpp:
1031 (WebKit::WebUIClient::runOpenPanel):
1032 * UIProcess/WebUIClient.h:
1033 * WebProcess/WebCoreSupport/WebChromeClient.cpp:
1034 (WebKit::WebChromeClient::runOpenPanel):
1035 * WebProcess/WebPage/WebOpenPanelResultListener.cpp: Added.
1036 (WebKit::WebOpenPanelResultListener::create):
1037 (WebKit::WebOpenPanelResultListener::WebOpenPanelResultListener):
1038 (WebKit::WebOpenPanelResultListener::~WebOpenPanelResultListener):
1039 (WebKit::WebOpenPanelResultListener::didChooseFiles):
1040 * WebProcess/WebPage/WebOpenPanelResultListener.h: Added.
1041 (WebKit::WebOpenPanelResultListener::disconnectFromPage):
1042 * WebProcess/WebPage/WebPage.cpp:
1043 (WebKit::WebPage::close):
1044 (WebKit::WebPage::setActiveOpenPanelResultListener):
1045 (WebKit::WebPage::didChooseFilesForOpenPanel):
1046 (WebKit::WebPage::didCancelForOpenPanel):
1047 * WebProcess/WebPage/WebPage.h:
1048 (WebKit::WebPage::activeOpenPanelResultListener):
1049 * WebProcess/WebPage/WebPage.messages.in:
1050 Pipe through file choosing.
1053 * WebKit2.xcodeproj/project.pbxproj:
1054 * win/WebKit2.vcproj:
1055 * win/WebKit2Generated.make:
1058 2010-12-15 Anders Carlsson <andersca@apple.com>
1060 Reviewed by Maciej Stachowiak.
1062 Semi-reproducible crash in ChunkedUpdateDrawingArea::paintIntoUpdateChunk closing a particular yahoo page
1063 https://bugs.webkit.org/show_bug.cgi?id=51126
1064 <rdar://problem/8771219>
1066 Laying out the web page can cause the drawing area to change so we need to protect against this.
1068 * WebProcess/WebPage/ChunkedUpdateDrawingArea.cpp:
1069 (WebKit::ChunkedUpdateDrawingArea::display):
1070 * WebProcess/WebPage/LayerBackedDrawingArea.cpp:
1071 (WebKit::LayerBackedDrawingArea::display):
1072 * WebProcess/WebPage/mac/LayerBackedDrawingAreaMac.mm:
1073 (WebKit::LayerBackedDrawingArea::updateLayoutRunLoopObserverFired):
1075 2010-12-15 Brian Weinstein <bweinstein@apple.com>
1077 Reviewed by Adam Roben.
1079 WebKit2: WebPageWin needs implementations of hasLocalDataForURL and canHandleRequest
1080 https://bugs.webkit.org/show_bug.cgi?id=51090
1082 Implement these functions for WebKit2 on Windows.
1084 * WebProcess/WebPage/WebPage.cpp:
1085 (WebKit::WebPage::hasLocalDataForURL): Does the cross-platform part of the check for having local
1086 data (file URL or subresource), then calls platformHasLocalDataForURL to let the platform do
1087 their specific checks.
1088 * WebProcess/WebPage/WebPage.h:
1089 * WebProcess/WebPage/mac/WebPageMac.mm:
1090 (WebKit::WebPage::platformHasLocalDataForURL): Moved the cross-platform code from here to WebPage::hasLocalDataForURL.
1091 * WebProcess/WebPage/qt/WebPageQt.cpp:
1092 (WebKit::WebPage::platformHasLocalDataForURL): Renamed from hasLocalDataForURL.
1093 * WebProcess/WebPage/win/WebPageWin.cpp:
1094 (WebKit::WebPage::platformHasLocalDataForURL): Renamed from hasLocalDataForURL and implemented with CFNetwork calls. This is the
1095 CFNetwork equivalent of the code in WebPageMac::platformHasLocalDataForURL.
1096 (WebKit::WebPage::canHandleRequest): Copied the line of code from WebView::canHandleRequest in WebKit1, with a FIXME saying
1097 this might not be enough (although it was in WebKit1 on Windows).
1099 2010-12-15 Sheriff Bot <webkit.review.bot@gmail.com>
1101 Unreviewed, rolling out r74117.
1102 http://trac.webkit.org/changeset/74117
1103 https://bugs.webkit.org/show_bug.cgi?id=51113
1105 This broke the GTK1 build. (Requested by mrobinson on
1108 * GNUmakefile.am: Removed.
1109 * Scripts/generate-forwarding-headers.pl:
1111 * gtk/webkit2.pc.in: Removed.
1113 2010-12-15 Amruth Raj <amruthraj@motorola.com> and Ravi Kasibhatla <ravi.kasibhatla@motorola.com>
1115 Reviewed by Martin Robinson.
1117 Changes to enable building WebKit2 for Gtk port.
1118 (https://bugs.webkit.org/show_bug.cgi?id=37369)
1120 * GNUmakefile.am: Added.
1121 * Scripts/generate-forwarding-headers.pl: For GTK port, taking 1 extra argument for copying network headers.
1122 * WebKit2Prefix.h: Included WebCore/config.h for GTK port as the first header file for WebKit2 sources files.
1124 * gtk/webkit2.pc.in: Added.
1126 2010-12-15 Jan Erik Hanssen <jhanssen@sencha.com>
1128 Reviewed by Andreas Kling.
1130 [Qt][WK2] webkit2 does not compile on OS X
1131 https://bugs.webkit.org/show_bug.cgi?id=50128
1133 prctl(2) is only available on Linux, so use an atexit handler for killing
1134 all the child processes when the process is exiting.
1136 * UIProcess/Launcher/qt/ProcessLauncherQt.cpp:
1137 (WebKit::cleanupProcesses):
1138 (WebKit::QtWebProcess::QtWebProcess):
1139 (WebKit::QtWebProcess::processStateChanged):
1140 (WebKit::ProcessLauncherHelper::instance):
1142 2010-12-14 Anders Carlsson <andersca@apple.com>
1146 * win/WebKit2Common.vsprops:
1148 2010-12-14 Anders Carlsson <andersca@apple.com>
1154 2010-12-14 Anders Carlsson <andersca@apple.com>
1156 Reviewed by TYPO FIX.
1160 * Shared/Plugins/Netscape/mac/NetscapePluginModuleMac.mm:
1161 (WebKit::NetscapePluginModule::determineQuirks):
1163 2010-12-14 Anders Carlsson <andersca@apple.com>
1165 Reviewed by Sam Weinig.
1167 Cannot type into plugin edit field
1168 https://bugs.webkit.org/show_bug.cgi?id=51074
1169 <rdar://problem/8483741>
1171 Add a PrognameShouldBeWebKitPluginHost quirk, since it turns out Flash Player calls getprogname() and checks
1172 if the return value is "WebKitPluginHost" in order to determine when to handle NPCocoaEventKeyDown events.
1174 * PluginProcess/PluginProcess.cpp:
1175 (WebKit::PluginProcess::netscapePluginModule):
1176 If the plug-in module has the PrognameShouldBeWebKitPluginHost quirk, call setprogname("WebKitPluginHost").
1178 * Shared/Plugins/Netscape/NetscapePluginModule.cpp:
1179 (WebKit::NetscapePluginModule::load):
1180 Call determineQuirks()
1182 * Shared/Plugins/Netscape/mac/NetscapePluginModuleMac.mm:
1183 (WebKit::NetscapePluginModule::determineQuirks):
1184 Add the PrognameShouldBeWebKitPluginHost quirk for Flash.
1186 * Shared/Plugins/Netscape/win/NetscapePluginModuleWin.cpp:
1187 (WebKit::NetscapePluginModule::determineQuirks):
1188 * Shared/Plugins/Netscape/x11/NetscapePluginModuleX11.cpp:
1189 (WebKit::NetscapePluginModule::determineQuirks):
1192 * Shared/Plugins/PluginQuirks.h:
1193 Add new PluginQuirks file.
1195 * WebKit2.xcodeproj/project.pbxproj:
1198 2010-12-14 Anders Carlsson <andersca@apple.com>
1200 Reviewed by Sam Weinig.
1202 Add a NetscapePluginModuleX11 and move the Qt implementation of PluginInfoStore::getPluginInfo there
1203 https://bugs.webkit.org/show_bug.cgi?id=51066
1205 * Shared/Plugins/Netscape/x11/NetscapePluginModuleX11.cpp: Copied from WebKit2/UIProcess/Plugins/qt/PluginInfoStoreQt.cpp.
1206 (WebKit::NetscapePluginModule::getPluginInfo):
1207 * UIProcess/Plugins/qt/PluginInfoStoreQt.cpp:
1208 (WebKit::PluginInfoStore::getPluginInfo):
1211 2010-12-14 Anders Carlsson <andersca@apple.com>
1213 Reviewed by Dan Bernstein.
1215 Move Windows version of getPluginInfo to NetscapePluginModule
1216 https://bugs.webkit.org/show_bug.cgi?id=51073
1218 * Shared/Plugins/Netscape/win/NetscapePluginModuleWin.cpp: Added.
1219 (WebKit::getVersionInfo):
1220 (WebKit::fileVersion):
1221 (WebKit::NetscapePluginModule::getPluginInfo):
1222 * UIProcess/Plugins/win/PluginInfoStoreWin.cpp:
1223 (WebKit::PluginInfoStore::getPluginInfo):
1224 * win/WebKit2.vcproj:
1226 2010-12-14 Alice Liu <alice.liu@apple.com>
1230 * UIProcess/WebProcessProxy.h:
1231 (WebKit::WebProcessProxy::sendSync):
1232 Move the default argument to the declaration.
1234 2010-12-14 Anders Carlsson <andersca@apple.com>
1236 Reviewed by Adam Roben.
1238 Move PluginInfoStore::getPluginInfo to NetscapePluginModule
1239 https://bugs.webkit.org/show_bug.cgi?id=51058
1241 * Shared/Plugins/Netscape/mac/NetscapePluginModuleMac.mm:
1242 Move implementation of PluginInfoStore::getPluginInfo and related
1243 helper functions here.
1245 * UIProcess/Plugins/mac/PluginInfoStoreMac.mm:
1246 (WebKit::PluginInfoStore::getPluginInfo):
1247 Just call NetscapePluginModule::getPluginInfo here for now.
1249 * WebKit2.xcodeproj/project.pbxproj:
1250 Add NetscapePluginModuleMac.mm.
1252 2010-12-14 Anders Carlsson <andersca@apple.com>
1254 Reviewed by John Sullivan.
1256 Switch name and description order when fetching Carbon plug-in info
1257 https://bugs.webkit.org/show_bug.cgi?id=46211
1259 The plug-in description comes before the name in the Carbon string list resource.
1261 * UIProcess/Plugins/mac/PluginInfoStoreMac.mm:
1262 (WebKit::getPluginInfoFromCarbonResources):
1264 2010-12-14 Anders Carlsson <andersca@apple.com>
1266 Reviewed by Adam Roben.
1268 Move NetscapePluginModule.{cpp|h} to Shared/Plugins/Netscape
1269 https://bugs.webkit.org/show_bug.cgi?id=51052
1271 * Shared/Plugins/Netscape/NetscapePluginModule.cpp: Renamed from WebKit2/WebProcess/Plugins/Netscape/NetscapePluginModule.cpp.
1272 * Shared/Plugins/Netscape/NetscapePluginModule.h: Renamed from WebKit2/WebProcess/Plugins/Netscape/NetscapePluginModule.h.
1274 * WebKit2.xcodeproj/project.pbxproj:
1275 * win/WebKit2.vcproj:
1276 * win/WebKit2Common.vsprops:
1278 2010-12-14 Anders Carlsson <andersca@apple.com>
1280 Reviewed by Sam Weinig.
1282 Handle complex text input for plug-ins
1283 https://bugs.webkit.org/show_bug.cgi?id=51047
1285 * PluginProcess/PluginControllerProxy.cpp:
1286 (WebKit::PluginControllerProxy::sendComplexTextInput):
1287 Pass along the text input to the plug-in.
1289 * PluginProcess/PluginControllerProxy.messages.in:
1290 Add SendComplexTextInput message.
1292 * UIProcess/API/mac/WKTextInputWindowController.h: Added.
1293 * UIProcess/API/mac/WKTextInputWindowController.mm: Added.
1294 Add text input window controller, mostly copied from WebKit1.
1296 * UIProcess/API/mac/WKView.mm:
1297 (-[WKView keyDown:]):
1298 If needed, pass along the event to the text input window controller.
1300 (-[WKView inputContext]):
1301 Return the input context of the text input window controller.
1303 (-[WKView _setComplexTextInputEnabled:pluginComplexTextInputIdentifier:]):
1304 Notify the input window controller that the input source changed.
1306 * UIProcess/WebPageProxy.cpp:
1307 (WebKit::WebPageProxy::sendComplexTextInputToPlugin):
1308 Send the complex text input to the web process.
1310 * WebKit2.xcodeproj/project.pbxproj:
1313 * WebProcess/Plugins/Netscape/mac/NetscapePluginMac.mm:
1314 (WebKit::convertStringToKeyCodes):
1315 Convert a string to a vector of key codes in the current encoding.
1317 (WebKit::NetscapePlugin::sendComplexTextInput):
1318 In the Cocoa event model, create and dispatch an NPCocoaEventTextInput event.
1319 In the Carbon event model, convert the string to individual key codes and send them
1322 * WebProcess/Plugins/PluginProxy.cpp:
1323 (WebKit::PluginProxy::sendComplexTextInput):
1324 Send the text to the plug-in controller proxy.
1326 * WebProcess/Plugins/PluginView.cpp:
1327 (WebKit::PluginView::sendComplexTextInput):
1328 If the plug-in has a matching text input identifier, call Plugin::sendComplexTextInput.
1330 * WebProcess/WebPage/WebPage.messages.in:
1331 Add SendComplexTextInputToPlugin message.
1333 * WebProcess/WebPage/mac/WebPageMac.mm:
1334 (WebKit::WebPage::sendComplexTextInputToPlugin):
1335 Iterate over all known plug-in views and try to find one to send the text input to.
1337 2010-12-13 Alexey Proskuryakov <ap@apple.com>
1339 Reviewed by Adam Barth.
1341 https://bugs.webkit.org/show_bug.cgi?id=50953
1342 DNS Prefetch should be an opt-in feature
1344 Pass the preference through WebKit2.
1346 * Shared/WebPreferencesStore.h:
1347 * UIProcess/API/C/WKPreferences.cpp:
1348 (WKPreferencesSetDNSPrefetchingEnabled):
1349 (WKPreferencesGetDNSPrefetchingEnabled):
1350 * UIProcess/API/C/WKPreferences.h:
1351 * WebProcess/WebPage/WebPage.cpp:
1352 (WebKit::WebPage::updatePreferences):
1354 2010-12-13 Anders Carlsson <andersca@apple.com>
1356 Reviewed by Kevin Decker.
1358 Pass the complex text input status to the WKView
1359 https://bugs.webkit.org/show_bug.cgi?id=50993
1361 * UIProcess/API/mac/PageClientImpl.h:
1362 * UIProcess/API/mac/PageClientImpl.mm:
1363 (WebKit::PageClientImpl::setComplexTextInputEnabled):
1364 * UIProcess/API/mac/WKView.mm:
1365 (-[WKView _setComplexTextInputEnabled:pluginComplexTextInputIdentifier:]):
1366 * UIProcess/API/mac/WKViewInternal.h:
1367 * UIProcess/PageClient.h:
1368 * UIProcess/WebPageProxy.cpp:
1369 (WebKit::WebPageProxy::setComplexTextInputEnabled):
1371 2010-12-14 Benjamin Poulain <benjamin.poulain@nokia.com>
1373 Reviewed by Kenneth Rohde Christiansen.
1375 WebKit 2 does not send touch cancel events correctly between processes
1376 https://bugs.webkit.org/show_bug.cgi?id=50235
1378 The classes WebKit2PlatformTouchPoint and WebKit2PlatformTouchEvent
1379 misses the conversion of TouchCancel events and points.
1381 This patch add the missing enums when converting from a WebTouchEvent
1382 to a PlatformTouchEvent.
1384 Testing is already covered by fast/events/touch/send-oncancel-event.html
1386 * Shared/WebEventConversion.cpp:
1387 (WebKit::WebKit2PlatformTouchPoint::WebKit2PlatformTouchPoint):
1388 (WebKit::WebKit2PlatformTouchEvent::WebKit2PlatformTouchEvent):
1390 2010-12-14 Zalan Bujtas <zbujtas@gmail.com>
1392 Reviewed by Kenneth Rohde Christiansen.
1394 Add loadFinished() for provisional load error
1395 This fixes the hanging UI state, when provisional load error occurs due to
1396 the async nature of policy check.
1398 https://bugs.webkit.org/show_bug.cgi?id=48724
1400 * UIProcess/API/qt/ClientImpl.cpp:
1402 (qt_wk_didFailProvisionalLoadWithErrorForFrame):
1403 (qt_wk_didFinishLoadForFrame):
1404 (qt_wk_didFailLoadWithErrorForFrame):
1406 2010-12-13 Sam Weinig <sam@webkit.org>
1408 Reviewed by Anders Carlsson.
1410 WebKit2: Need to be able to set the application name for the user agent for a WKPage
1411 https://bugs.webkit.org/show_bug.cgi?id=51011
1414 WebKit2: Need to be able to set the application name for the user agent for a WKPage
1415 <rdar://problem/8564532>
1416 WebKit2: Need to be able to get the computed user agent for a WKPage
1417 <rdar://problem/8637285>
1419 Moves user agent computation to the UIProcess and just passes it to the WebProcess
1420 when it has changed.
1422 * Shared/WebPageCreationParameters.cpp:
1423 (WebKit::WebPageCreationParameters::encode):
1424 (WebKit::WebPageCreationParameters::decode):
1425 * Shared/WebPageCreationParameters.h:
1426 Add a user agent to the creation parameters.
1428 * UIProcess/API/C/WKPage.cpp:
1429 (WKPageCopyUserAgent):
1430 (WKPageCopyApplicationNameForUserAgent):
1431 (WKPageSetApplicationNameForUserAgent):
1432 (WKPageSetCustomUserAgent):
1433 * UIProcess/API/C/WKPage.h:
1434 Add new API to set the application name and access the computed user agent.
1436 * UIProcess/WebPageProxy.cpp:
1437 (WebKit::WebPageProxy::WebPageProxy):
1438 (WebKit::WebPageProxy::close):
1439 (WebKit::WebPageProxy::setUserAgent):
1440 (WebKit::WebPageProxy::setApplicationNameForUserAgent):
1441 (WebKit::WebPageProxy::setCustomUserAgent):
1442 (WebKit::WebPageProxy::processDidCrash):
1443 (WebKit::WebPageProxy::creationParameters):
1444 * UIProcess/WebPageProxy.h:
1445 (WebKit::WebPageProxy::userAgent):
1446 (WebKit::WebPageProxy::applicationNameForUserAgent):
1447 * UIProcess/mac/WebPageProxyMac.mm: Added.
1448 * WebProcess/WebPage/WebPage.cpp:
1449 (WebKit::WebPage::WebPage):
1450 (WebKit::WebPage::setUserAgent):
1451 * WebProcess/WebPage/WebPage.h:
1452 (WebKit::WebPage::userAgent):
1453 * WebProcess/WebPage/WebPage.messages.in:
1454 Pipe through user agent.
1456 (WebKit::callGestalt):
1457 (WebKit::macOSXVersionString):
1458 (WebKit::userVisibleWebKitVersionString):
1459 (WebKit::WebPageProxy::standardUserAgent):
1460 * UIProcess/win/WebPageProxyWin.cpp: Added.
1461 (WebKit::windowsVersion):
1462 (WebKit::userVisibleWebKitVersionString):
1463 (WebKit::WebPageProxy::standardUserAgent):
1464 Port standardUserAgent computation from WebKit1.
1466 * UIProcess/qt/WebPageProxyQt.cpp: Added.
1467 (WebKit::WebPageProxy::standardUserAgent):
1468 Stub out the user agent so there is no change in behavior.
1471 * WebKit2.xcodeproj/project.pbxproj:
1472 * win/WebKit2.vcproj:
1475 2010-12-13 Brady Eidson <beidson@apple.com>
1477 Reviewed by Jon Honeycutt (and Brian Weinstein in heart).
1479 <rdar://problem/8752202> and https://bugs.webkit.org/show_bug.cgi?id=50997
1480 Expose "link title" and "link label" to InjectedBundleHitTestResult API
1482 * WebProcess/InjectedBundle/API/c/WKBundleHitTestResult.cpp:
1483 (WKBundleHitTestResultCopyLinkLabel):
1484 (WKBundleHitTestResultCopyLinkTitle):
1485 * WebProcess/InjectedBundle/API/c/WKBundleHitTestResult.h:
1487 * WebProcess/InjectedBundle/InjectedBundleHitTestResult.cpp:
1488 (WebKit::InjectedBundleHitTestResult::linkLabel):
1489 (WebKit::InjectedBundleHitTestResult::linkTitle):
1490 * WebProcess/InjectedBundle/InjectedBundleHitTestResult.h:
1492 2010-12-13 Brian Weinstein <bweinstein@apple.com>
1494 Windows Build Fix. Add a needed include.
1496 * UIProcess/win/WebView.cpp:
1498 2010-12-13 Sam Weinig <sam@webkit.org>
1500 Reviewed by Anders Carlsson.
1502 Remove associated page concept from WKView constructor
1503 https://bugs.webkit.org/show_bug.cgi?id=50983
1505 Step 2: Remove WebPageNamespace. It no longer does anything.
1507 * Shared/APIObject.h:
1508 * UIProcess/API/C/WKPage.h:
1509 * UIProcess/API/mac/WKView.mm:
1510 (-[WKView initWithFrame:contextRef:pageGroupRef:]):
1511 * UIProcess/API/qt/qgraphicswkview.cpp:
1512 * UIProcess/API/qt/qwkcontext.cpp:
1513 (QWKContext::QWKContext):
1514 * UIProcess/API/qt/qwkcontext_p.h:
1515 * UIProcess/API/qt/qwkpage.cpp:
1516 (QWKPagePrivate::QWKPagePrivate):
1517 * UIProcess/API/qt/qwkpage_p.h:
1518 * UIProcess/WebContext.cpp:
1519 (WebKit::WebContext::WebContext):
1520 (WebKit::WebContext::~WebContext):
1521 (WebKit::WebContext::createWebPage):
1522 * UIProcess/WebContext.h:
1523 * UIProcess/WebPageNamespace.cpp: Removed.
1524 * UIProcess/WebPageNamespace.h: Removed.
1525 * UIProcess/WebPageProxy.cpp:
1526 * UIProcess/WebPageProxy.h:
1527 (WebKit::WebPageProxy::context):
1528 * UIProcess/WebProcessProxy.cpp:
1529 (WebKit::WebProcessProxy::createWebPage):
1530 * UIProcess/WebProcessProxy.h:
1531 * UIProcess/win/WebView.cpp:
1532 (WebKit::WebView::WebView):
1533 * UIProcess/win/WebView.h:
1535 * WebKit2.xcodeproj/project.pbxproj:
1536 * win/WebKit2.vcproj:
1538 2010-12-13 Sam Weinig <sam@webkit.org>
1542 * UIProcess/win/WebView.h:
1544 2010-12-13 Sam Weinig <sam@webkit.org>
1548 * UIProcess/win/WebInspectorProxyWin.cpp:
1549 (WebKit::WebInspectorProxy::platformCreateInspectorPage):
1550 * UIProcess/win/WebView.h:
1551 (WebKit::WebView::create):
1553 2010-12-13 Sam Weinig <sam@webkit.org>
1555 Reviewed by Anders Carlsson.
1557 Remove associated page concept from WKView constructor
1558 https://bugs.webkit.org/show_bug.cgi?id=50983
1560 Step 1: Remove associate page constructors from WKView and make
1561 all views use the shared namespace for the context.
1563 * UIProcess/API/C/win/WKView.cpp:
1564 * UIProcess/API/C/win/WKView.h:
1565 * UIProcess/API/mac/WKView.h:
1566 * UIProcess/API/mac/WKView.mm:
1567 (-[WKView initWithFrame:contextRef:pageGroupRef:]):
1568 * UIProcess/API/qt/qwkcontext.cpp:
1569 * UIProcess/API/qt/qwkcontext.h:
1570 * UIProcess/mac/WebInspectorProxyMac.mm:
1571 (WebKit::WebInspectorProxy::platformCreateInspectorPage):
1572 * UIProcess/win/WebView.cpp:
1573 (WebKit::WebView::WebView):
1574 * UIProcess/win/WebView.h:
1575 (WebKit::WebView::create):
1577 2010-12-13 Anders Carlsson <andersca@apple.com>
1581 * UIProcess/WebPageProxy.h:
1583 2010-12-13 Brian Weinstein <bweinstein@apple.com>
1585 Reviewed by Adam Roben.
1587 WebKit2: Leaks a WebView when opening/closing Web Inspector on Windows
1588 https://bugs.webkit.org/show_bug.cgi?id=50975
1589 <rdar://problem/8763501>
1591 Make m_inspectorView be a RefPtr<WebView>, instead of a WebView*.
1593 * UIProcess/WebInspectorProxy.cpp:
1594 (WebKit::WebInspectorProxy::WebInspectorProxy): If we are on Windows, include WebView.h.
1595 * UIProcess/WebInspectorProxy.h: Change the type of m_inspectorView to a RefPtr<WebView>.
1596 * UIProcess/win/WebInspectorProxyWin.cpp:
1597 (WebKit::WebInspectorProxy::platformCreateInspectorPage): Remove the call to leakRef when creating the WebView.
1599 2010-12-13 Anders Carlsson <andersca@apple.com>
1601 Reviewed by Darin Adler.
1603 Pass the complex text input state all the way to the UI process
1604 https://bugs.webkit.org/show_bug.cgi?id=50980
1606 * PluginProcess/PluginControllerProxy.cpp:
1607 (WebKit::PluginControllerProxy::setComplexTextInputEnabled):
1608 * UIProcess/WebPageProxy.cpp:
1609 (WebKit::WebPageProxy::setComplexTextInputEnabled):
1610 * UIProcess/WebPageProxy.h:
1611 * UIProcess/WebPageProxy.messages.in:
1612 * WebProcess/Plugins/Netscape/NetscapePlugin.h:
1613 * WebProcess/Plugins/Netscape/mac/NetscapePluginMac.mm:
1614 (WebKit::NetscapePlugin::pluginComplexTextInputIdentifier):
1615 * WebProcess/Plugins/Plugin.h:
1616 * WebProcess/Plugins/PluginProxy.cpp:
1617 (WebKit::PluginProxy::pluginComplexTextInputIdentifier):
1618 (WebKit::PluginProxy::setComplexTextInputEnabled):
1619 * WebProcess/Plugins/PluginProxy.h:
1620 * WebProcess/Plugins/PluginProxy.messages.in:
1621 * WebProcess/Plugins/PluginView.cpp:
1622 (WebKit::PluginView::setComplexTextInputEnabled):
1624 2010-12-13 Sam Weinig <sam@webkit.org>
1626 Reviewed by Anders Carlsson.
1628 Change the WebKit2 public API so there is no explicit WKPageNamespace object
1629 https://bugs.webkit.org/show_bug.cgi?id=50898
1631 * Shared/API/c/WKBase.h: Remove definition of WKPageNamespaceRef.
1632 * UIProcess/API/C/WKAPICast.h: Remove toAPI/toImpl for WKPageNamespaceRef.
1634 * UIProcess/API/C/WKPage.cpp:
1635 * UIProcess/API/C/WKPage.h:
1636 Replace WKPageGetPageNamespace with WKPageGetContext.
1638 * UIProcess/API/C/WKPageNamespace.cpp: Removed.
1639 * UIProcess/API/C/WKPageNamespace.h: Removed.
1641 * UIProcess/API/C/WebKit2.h: Remove #include of WKPageNamespace.h.
1643 * UIProcess/API/C/win/WKView.cpp:
1644 (WKViewCreate): Changed to take a WKContextRef instead of a WKPageNamespaceRef.
1645 (WKViewCreateUsingSharedProcess): Added. Similar to WKViewCreate except that
1646 all callers of it will have their views end up in the same shared process, whereas
1647 with WKViewCreate, a new internal page namespace will be created and could place
1648 the view's WebPage into a new process.
1649 (WKViewCreateForAssociatedPage): Added. Creates a view that is forced to use the
1650 same process as the passed in page.
1652 * UIProcess/win/WebView.cpp:
1653 (WebKit::WebView::WebView):
1654 (WebKit::WebView::initialize):
1655 * UIProcess/win/WebView.h:
1656 (WebKit::WebView::create):
1657 (WebKit::WebView::createUsingSharedProcess):
1658 (WebKit::WebView::createForAssociatedPage):
1659 Implementation of the WKView create functions.
1661 * UIProcess/API/C/win/WKView.h:
1662 * UIProcess/API/mac/WKView.h:
1663 * UIProcess/API/mac/WKView.mm:
1664 (-[WKView initWithFrame:]):
1665 (-[WKView initWithFrame:contextRef:]):
1666 (-[WKView initWithFrame:contextRef:pageGroupRef:]):
1667 (-[WKView initWithFrame:contextRef:usingSharedProcess:]):
1668 (-[WKView initWithFrame:contextRef:pageGroupRef:usingSharedProcess:]):
1669 (-[WKView initWithFrame:forAssociatedPageRef:]):
1670 (-[WKView initWithFrame:forAssociatedPageRef:pageGroupRef:]):
1671 (-[WKView initWithFrame:pageNamespace:pageGroup:]):
1672 Add new initializers for the objective-c WKView. It follows the same
1673 pattern as WKViewRef.
1675 * UIProcess/API/qt/qwkcontext.cpp:
1676 (QWKContext::QWKContext):
1677 * UIProcess/API/qt/qwkcontext.h:
1678 Remove uses of WKPageNamespaceRef.
1680 * UIProcess/WebContext.cpp:
1681 (WebKit::WebContext::sharedPageNamespace): Returns a shared
1682 page namespace used by the view's createUsingSharedProcess constructions.
1683 (WebKit::WebContext::createPageNamespace): Change to return
1684 a PassRefPtr to make things clearer.
1685 (WebKit::WebContext::pageNamespaceWasDestroyed): Clear the shared
1686 namespace if it is cleared.
1687 * UIProcess/WebContext.h:
1689 * UIProcess/WebPageNamespace.h: Remove unused "struct WKContextStatistics".
1691 * UIProcess/WebPageProxy.cpp:
1692 (WebKit::WebPageProxy::context):
1693 * UIProcess/WebPageProxy.h:
1696 * UIProcess/mac/WebInspectorProxyMac.mm:
1697 (WebKit::WebInspectorProxy::platformCreateInspectorPage):
1698 * UIProcess/win/WebInspectorProxyWin.cpp:
1699 (WebKit::WebInspectorProxy::platformCreateInspectorPage):
1700 Use forAssociatedPageRef constructor for the WebInspector view.
1703 * WebKit2.xcodeproj/project.pbxproj:
1704 * win/WebKit2.vcproj:
1705 * win/WebKit2Generated.make:
1706 Remove WKPageNamespace.h/cpp.
1708 2010-12-13 Brent Fulgham <bfulgham@webkit.org>
1710 Unreviewed build fix.
1712 * UIProcess/win/WebInspectorProxyWin.cpp: Non-Apple builds
1713 need to include <wtf/RetainPtr.h>.
1715 2010-12-13 Brent Fulgham <bfulgham@webkit.org>
1717 Unreviewed build fix after r73807.
1719 Added stub implementation of Download object.
1721 * WebProcess/Downloads/curl: Added.
1722 * WebProcess/Downloads/curl/DownloadCurl.cpp: Added.
1723 (WebKit::Download::start):
1724 (WebKit::Download::startWithHandle):
1725 (WebKit::Download::cancel):
1726 (WebKit::Download::platformInvalidate):
1727 * win/WebKit2.vcproj: Exclude DownloadCFNet for Cairo builds,
1728 added DownloadCurl (excluded for regular Apple builds.)
1730 2010-12-13 Anders Carlsson <andersca@apple.com>
1732 Reviewed by Sam Weinig.
1734 Add the ability for plug-ins to toggle complex text input
1735 https://bugs.webkit.org/show_bug.cgi?id=50966
1737 * PluginProcess/PluginControllerProxy.cpp:
1738 (WebKit::PluginControllerProxy::PluginControllerProxy):
1739 Initialize m_isComplexTextInputEnabled.
1741 (WebKit::PluginControllerProxy::setComplexTextInputEnabled):
1742 Update m_isComplexTextInputEnabled.
1744 * PluginProcess/PluginControllerProxy.h:
1745 * WebProcess/Plugins/Netscape/NetscapePlugin.cpp:
1746 (WebKit::NetscapePlugin::NetscapePlugin):
1747 Initialize m_pluginHasFocus and m_windowHasFocus.
1749 * WebProcess/Plugins/Netscape/NetscapePlugin.h:
1750 (WebKit::NetscapePlugin::isWindowActive):
1751 Return m_windowHasFocus.
1753 * WebProcess/Plugins/Netscape/mac/NetscapePluginMac.mm:
1754 (WebKit::NetscapePlugin::platformSetFocus):
1755 Update m_pluginHasFocus and call setComplexTextInputEnabled.
1757 (WebKit::NetscapePlugin::windowFocusChanged):
1758 Update m_windowHasFocus and call setComplexTextInputEnabled.
1760 * WebProcess/Plugins/PluginController.h:
1761 Add setComplexTextInputEnabled.
1763 * WebProcess/Plugins/PluginView.cpp:
1764 (WebKit::PluginView::setComplexTextInputEnabled):
1765 * WebProcess/Plugins/PluginView.h:
1766 Add setComplexTextInputEnabled
1768 2010-12-13 David Hyatt <hyatt@apple.com>
1770 Reviewed by Adam Roben.
1772 Remove the space behavior that I added. It's covered in EventHandler in WebCore
1773 already for Windows.
1775 * WebProcess/WebPage/win/WebPageWin.cpp:
1776 (WebKit::WebPage::performDefaultBehaviorForKeyEvent):
1778 2010-12-13 David Hyatt <hyatt@apple.com>
1780 Reviewed by Sam Weinig.
1782 https://bugs.webkit.org/show_bug.cgi?id=48545, Home/End, PageUp/PageDwn should respect writing-mode. Use
1783 logical scrolling instead of physical scrolling for those keys in WebKit2.
1785 * WebProcess/WebPage/mac/WebPageMac.mm:
1786 (WebKit::logicalScroll):
1787 (WebKit::WebPage::performDefaultBehaviorForKeyEvent):
1788 * WebProcess/WebPage/qt/WebPageQt.cpp:
1789 (WebKit::logicalScroll):
1790 (WebKit::WebPage::performDefaultBehaviorForKeyEvent):
1791 * WebProcess/WebPage/win/WebPageWin.cpp:
1792 (WebKit::logicalScroll):
1793 (WebKit::WebPage::performDefaultBehaviorForKeyEvent):
1795 2010-12-13 Brian Weinstein <bweinstein@apple.com>
1797 Reviewed by Darin Adler.
1799 WebKit2: Focusing Web Inspector window doesn't focus contents on Windows
1800 https://bugs.webkit.org/show_bug.cgi?id=50947
1801 <rdar://problem/8762468>
1803 When we get the notification that the inspector window has focused, focus the inner inspector view.
1805 * UIProcess/WebInspectorProxy.h:
1806 * UIProcess/win/WebInspectorProxyWin.cpp:
1807 (WebKit::WebInspectorProxy::onSetFocusEvent): Set the focus of the inspector view, because that is what
1808 needs to be focused in the inspector window.
1810 2010-12-13 Dan Bernstein <mitz@apple.com>
1814 * WebProcess/Downloads/mac/DownloadMac.mm:
1815 (WebKit::originatingURLFromBackForwardList):
1817 2010-12-13 Balazs Kelemen <kbalazs@webkit.org>
1819 Unreviewed trivial build fix (linux, 64 bit, gcc-4.5.1)
1821 * WebProcess/WebCoreSupport/WebChromeClient.cpp:
1822 (WebKit::WebChromeClient::exceededDatabaseQuota):
1823 Don't use unsigned long long as alias for uint64_t.
1825 2010-12-13 Anders Carlsson <andersca@apple.com>
1827 Reviewed by John Sullivan.
1829 Crash when clicking a download link that targets a new tab
1830 https://bugs.webkit.org/show_bug.cgi?id=50935
1831 <rdar://problem/8760572>
1833 Check for a null history item.
1835 * WebProcess/Downloads/mac/DownloadMac.mm:
1836 (WebKit::originatingURLFromBackForwardList):
1838 2010-12-13 Andras Becsi <abecsi@webkit.org>
1840 Reviewed by Csaba Osztrogonác.
1842 [Qt][WK2] Fix build if WebKitTools are not available
1843 https://bugs.webkit.org/show_bug.cgi?id=50242
1845 * DerivedSources.pro: Remove dependency to WebKitTools.
1846 * Scripts/generate-forwarding-headers.pl: Moved from WebKitTools/Scripts/generate-forwarding-headers.pl.
1848 2010-12-13 Csaba Osztrogonác <ossy@webkit.org>
1852 * WebKit2.pro: Remove non-existant Shared/DrawingAreaBase.h from build system.
1854 2010-10-28 MORITA Hajime <morrita@google.com>
1856 Reviewed by Ojan Vafai.
1858 spellcheck does not check pasted text
1859 https://bugs.webkit.org/show_bug.cgi?id=40092
1861 Added a stub implememntation.
1863 * WebProcess/WebCoreSupport/WebEditorClient.cpp:
1864 (WebKit::WebEditorClient::requestCheckingOfString):
1865 * WebProcess/WebCoreSupport/WebEditorClient.h:
1867 2010-12-12 Brian Weinstein <bweinstein@apple.com>
1869 Reviewed by Tim Hatcher.
1871 WebKit2: Implement WebInspector::localizedStringsURL on Windows
1872 https://bugs.webkit.org/show_bug.cgi?id=50896
1874 Find the localized strings file using CFBundleCopyResourceURL.
1876 * WebProcess/WebPage/win/WebInspectorWin.cpp:
1877 (WebKit::WebInspector::localizedStringsURL):
1879 2010-12-12 Sam Weinig <sam@webkit.org>
1881 Reviewed by Anders Carlsson.
1883 Give LogTextInput a sensible flag value.
1885 * Platform/Logging.cpp:
1887 2010-12-12 Sam Weinig <sam@webkit.org>
1889 Reviewed by Anders Carlsson.
1891 Remove incorrect assertion that has been firing in the API tester.
1893 * UIProcess/WebDatabaseManagerProxy.cpp:
1894 (WebKit::WebDatabaseManagerProxy::~WebDatabaseManagerProxy):
1896 2010-12-12 Sam Weinig <sam@webkit.org>
1898 Reviewed by Anders Carlsson.
1900 Disable WebKit2 logging by default.
1901 https://bugs.webkit.org/show_bug.cgi?id=50878
1903 * Platform/Logging.cpp:
1904 (initializeLogChannelsIfNecessary):
1906 2010-12-11 Brian Weinstein <bweinstein@apple.com>
1908 Reviewed by Sam Weinig.
1910 Web Inspector: Make inspector on Windows show and be usable in WebKit2
1911 https://bugs.webkit.org/show_bug.cgi?id=50877
1913 Hook up the unimplemented methods in WebInspectorProxyWin to get the web inspector
1914 showing and usable in WebKit2 on Windows.
1916 * UIProcess/WebInspectorProxy.cpp:
1917 (WebKit::WebInspectorProxy::WebInspectorProxy): Initialize Windows-specific variables to 0.
1918 * UIProcess/WebInspectorProxy.h:
1919 * UIProcess/win/WebInspectorProxyWin.cpp:
1920 (WebKit::WebInspectorProxy::registerInspectorViewWindowClass): Sets up the inspector view class.
1921 (WebKit::WebInspectorProxy::InspectorViewWndProc): Calls through to the WebInspectorProxy's non-static
1923 (WebKit::WebInspectorProxy::wndProc): Handles WM_SIZE, WM_CLOSE, and WM_GETMINMAXINFO, the rest go to
1925 (WebKit::WebInspectorProxy::onSizeEvent): Resize the WKView that has the inspector page to match the
1926 outer window that was just resized.
1927 (WebKit::WebInspectorProxy::onMinMaxInfoEvent): Set the minimum size the window can be resized to.
1928 (WebKit::WebInspectorProxy::onCloseEvent): Hide the window, and call WebInspectorProxy::close.
1929 (WebKit::WebInspectorProxy::platformCreateInspectorPage): Create a WKView and return its page.
1930 (WebKit::WebInspectorProxy::platformOpen): Create an HWND for the inspector, put the inspector's WKView
1931 inside of it, and show the window.
1932 (WebKit::WebInspectorProxy::platformClose): Destroy the inspector's window (which destroys the child WKView),
1933 and 0 out instance variables.
1934 (WebKit::WebInspectorProxy::inspectorPageURL): Finds inspector/inspector.html in the WebKit bundle.
1936 2010-12-12 Balazs Kelemen <kbalazs@webkit.org>
1938 Reviewed by Andreas Kling.
1940 [Qt][WK2] Crash in WebPage constructor.
1941 https://bugs.webkit.org/show_bug.cgi?id=50892
1943 * WebProcess/qt/WebProcessQt.cpp:
1944 (WebKit::WebProcess::platformInitializeWebProcess):
1945 Disable runtime enabled features that have no WebKit2 implementation yet.
1947 2010-12-10 Jon Honeycutt <jhoneycutt@apple.com>
1949 Select menus with short option titles do not paint properly
1950 https://bugs.webkit.org/show_bug.cgi?id=50860
1951 <rdar://problem/8660807>
1953 The backing stores used for painting the popup menu items were only as
1954 wide as the widest option title, but the popup window that we create is
1955 at least as wide as the <select> element. This adjusts the backing
1956 stores to be at least as wide as the <select>, as well.
1958 Reviewed by Sam Weinig.
1960 * UIProcess/win/WebPopupMenuProxyWin.cpp:
1961 (WebKit::WebPopupMenuProxyWin::paint):
1962 Paint using the width of the backing store.
1964 * WebProcess/WebCoreSupport/WebPopupMenu.cpp:
1965 (WebKit::WebPopupMenu::show):
1966 Pass the page coordinates of the <select> element to
1967 setUpPlatformData().
1969 * WebProcess/WebCoreSupport/WebPopupMenu.h:
1970 Added new parameter to setUpPlatformData().
1972 * WebProcess/WebCoreSupport/mac/WebPopupMenuMac.mm:
1973 (WebKit::WebPopupMenu::setUpPlatformData):
1976 * WebProcess/WebCoreSupport/qt/WebPopupMenuQt.cpp:
1977 (WebKit::WebPopupMenu::setUpPlatformData):
1980 * WebProcess/WebCoreSupport/win/WebPopupMenuWin.cpp:
1981 (WebKit::WebPopupMenu::setUpPlatformData):
1982 Fixed a typo in a comment. Adjust the backing store size to be at least
1983 as wide as the <select> element, and use that width when painting the
1984 items to the backing store.
1986 2010-12-11 Csaba Osztrogonác <ossy@webkit.org>
1988 Unreviewed Qt buildfix after r73808.
1990 WebKit2: Need a WebKit2 equivalent of the WebKit1 WebDatabaseManager
1991 https://bugs.webkit.org/show_bug.cgi?id=50606
1993 * DerivedSources.pro:
1995 2010-12-11 Sheriff Bot <webkit.review.bot@gmail.com>
1997 Unreviewed, rolling out r73834.
1998 http://trac.webkit.org/changeset/73834
1999 https://bugs.webkit.org/show_bug.cgi?id=50866
2001 It broke Qt-WebKit2 build, because of missing WK2_DIR variable
2002 (Requested by Ossy on #webkit).
2006 2010-12-10 Siddharth Mathur <siddharth.mathur@nokia.com>
2008 Reviewed by Eric Seidel.
2010 [Qt][WK2] Make WebKit2 static library compile on Symbian
2011 https://bugs.webkit.org/show_bug.cgi?id=50861
2015 2010-12-10 Sam Weinig <sam@webkit.org>
2017 Reviewed by Anders Carlsson.
2019 Ensure that we are not getting too many wheel events
2020 <rdar://problem/7881465>
2022 Add simple coalescing of wheel events being sent to the WebProcess. This
2023 adds two models, one which drops interim events and one which merges events
2024 together. For now, we are using the simpler dropping model.
2026 * Shared/WebEvent.h:
2027 (WebKit::WebEvent::modifiers):
2028 * UIProcess/WebPageProxy.cpp:
2029 (WebKit::WebPageProxy::WebPageProxy):
2030 (WebKit::coalesceWheelEvents):
2031 (WebKit::WebPageProxy::handleWheelEvent):
2032 (WebKit::WebPageProxy::didReceiveEvent):
2033 * UIProcess/WebPageProxy.h:
2035 2010-12-10 Anders Carlsson <andersca@apple.com>
2037 Reviewed by John Sullivan.
2039 Make WKContextGetStatistics gather global statistics
2040 https://bugs.webkit.org/show_bug.cgi?id=50850
2042 Change WKContextGetStatistics to work on all objects in the process, and
2043 make it more robust by incrementing/decrementing the counts in the constructor
2044 and destructor respectively.
2046 Also, rename WKContextGetStatistics to WKContextGetGlobalStatistics to better match
2047 what it's actually doing.
2049 * UIProcess/API/C/WKContext.cpp:
2050 (WKContextGetStatistics):
2051 * UIProcess/API/C/WKContextPrivate.h:
2052 * UIProcess/API/mac/WKView.mm:
2053 (-[WKView initWithFrame:pageNamespaceRef:pageGroupRef:]):
2054 (-[WKView dealloc]):
2055 * UIProcess/WebContext.cpp:
2056 (WebKit::WebContext::statistics):
2057 * UIProcess/WebContext.h:
2058 * UIProcess/WebFrameProxy.cpp:
2059 (WebKit::WebFrameProxy::WebFrameProxy):
2060 (WebKit::WebFrameProxy::~WebFrameProxy):
2061 * UIProcess/WebPageNamespace.cpp:
2062 * UIProcess/WebPageNamespace.h:
2063 * UIProcess/WebPageProxy.cpp:
2064 (WebKit::WebPageProxy::WebPageProxy):
2065 (WebKit::WebPageProxy::~WebPageProxy):
2066 * UIProcess/WebPageProxy.h:
2068 2010-12-10 Brian Weinstein <bweinstein@apple.com>
2070 Reviewed by Darin Adler.
2072 WebKit2: Context menu support on Windows
2073 <https://bugs.webkit.org/show_bug.cgi?id=50514>
2075 Implment showing of the context menu on Windows for WebKit2, and calling through to
2076 WebPageProxy::contextMenuItemSelected.
2078 * UIProcess/win/WebContextMenuProxyWin.cpp:
2079 (WebKit::WebContextMenuProxyWin::WebContextMenuProxyWin): Initialize the member variables.
2080 (WebKit::WebContextMenuProxyWin::populateMenu): Iterate over the vector of WebContextMenuItemData
2081 that was passed in, adding the menu items and recursively calling back into this function to populate
2082 any submenus that are needed. This function also sets up the map from action identifierss to WebContextMenuItemData,
2083 to use to find the WebContextMenuItemData from a selected menu item.
2084 (WebKit::WebContextMenuProxyWin::showContextMenu): Destroy any menu we have already created, populate the menu
2085 to show, and show the context menu. Once TrackPopupMenuEx returns, it returns identifier of the selected menu item.
2086 Look up that identifier in the map we created, and tell the WebPageProxy that a context menu item was selected.
2087 (WebKit::WebContextMenuProxyWin::hideContextMenu): Destroy the HMENU if it is non-null, and clear the identifier map.
2088 * UIProcess/win/WebContextMenuProxyWin.h:
2089 (WebKit::WebContextMenuProxyWin::create): Call through to the constructor, and change the arguments that it takes.
2090 * UIProcess/win/WebView.cpp:
2091 (WebKit::WebView::createContextMenuProxy): Call with the correct arguments.
2093 2010-12-10 Jessie Berlin <jberlin@apple.com>
2095 Qt Build Fix. Unreviewed.
2098 Add the Messages.h and MessageReceivers.h.
2100 2010-12-10 Jessie Berlin <jberlin@apple.com>
2102 Reviewed by Adam Roben and Sam Weinig.
2104 WebKit2: Need a WebKit2 equivalent of the WebKit1 WebDatabaseManager
2105 https://bugs.webkit.org/show_bug.cgi?id=50606
2107 Add a WebDatabaseManagerProxy owned by the WebContext.
2109 Expose API (similar to the WebKit1 API) to get a list of origins for which there are
2110 Databases, delete all the databases for a given origin, and delete all the databases.
2112 Add WebDatabaseManager and WebDatabaseManagerProxy as messages receivers.
2113 * DerivedSources.make:
2114 * Platform/CoreIPC/MessageID.h:
2116 Add the WebDatabaseManagerProxy as a UIProcess type (DatabaseManager).
2117 * Shared/API/c/WKBase.h:
2118 * Shared/APIObject.h:
2119 * UIProcess/API/C/WKAPICast.h:
2121 * UIProcess/API/C/WKContext.cpp:
2122 (WKContextGetDatabaseManager):
2123 Expose API to get the DatabaseManager.
2124 * UIProcess/API/C/WKContext.h:
2126 * UIProcess/API/C/WKDatabaseManager.cpp: Added.
2127 (WKDatabaseManagerGetTypeID):
2128 (WKDatabaseManagerGetDatabaseOrigins):
2129 (callGetDatabaseOriginsBlockBlockAndDispose):
2130 (WKDatabaseManagerGetDatabaseOrigins_b):
2131 (WKDatabaseManagerDeleteDatabasesForOrigin):
2132 (WKDatabaseManagerDeleteAllDatabases):
2133 * UIProcess/API/C/WKDatabaseManager.h: Added.
2135 * UIProcess/WebContext.cpp:
2136 (WebKit::WebContext::WebContext):
2137 Create the WebDatabaseManagerProxy.
2138 (WebKit::WebContext::processDidClose):
2139 Invalidate the WebDatabaseManagerProxy.
2140 (WebKit::WebContext::didReceiveMessage):
2141 Forward messages to the WebDatabaseManagerProxy.
2142 * UIProcess/WebContext.h:
2143 (WebKit::WebContext::databaseManagerProxy):
2145 * UIProcess/WebDatabaseManagerProxy.cpp: Added.
2146 (WebKit::WebDatabaseManagerProxy::create):
2147 (WebKit::WebDatabaseManagerProxy::WebDatabaseManagerProxy):
2148 (WebKit::WebDatabaseManagerProxy::~WebDatabaseManagerProxy):
2149 (WebKit::WebDatabaseManagerProxy::invalidate):
2150 Invalidate the map of callbacks for getDatabaseOrigins.
2151 (WebKit::WebDatabaseManagerProxy::getDatabaseOrigins):
2152 Store the callback and send the request for the origins which have databases to the
2154 (WebKit::WebDatabaseManagerProxy::didGetDatabaseOrigins):
2155 Call the callback function with the SecurityOrigins created from the identifiers received.
2156 (WebKit::WebDatabaseManagerProxy::deleteDatabasesForOrigin):
2157 If the origin exists, send the message on to the WebProcess to delete the databases
2158 associated with that origin.
2159 (WebKit::WebDatabaseManagerProxy::deleteAllDatabases):
2160 Send the message to the WebProcess to delete all the databases.
2161 * UIProcess/WebDatabaseManagerProxy.h: Added.
2162 (WebKit::WebDatabaseManagerProxy::type):
2163 * UIProcess/WebDatabaseManagerProxy.messages.in: Added.
2165 * UIProcess/WebPageProxy.cpp:
2166 Move invalidateCallbackMap from here ...
2167 * UIProcess/GenericCallback.h:
2168 (WebKit::invalidateCallbackMap):
2169 .. to here so that it can be used elsewhere (e.g. by WebDatabaseManagerProxy).
2171 * UIProcess/WebProcessProxy.cpp:
2172 (WebKit::WebProcessProxy::didReceiveMessage):
2173 Forward on all messages destined for the WebDatabaseManagerProxy to the WebContext.
2175 * WebProcess/WebCoreSupport/WebDatabaseManager.cpp:
2176 (WebKit::WebDatabaseManager::didReceiveMessage):
2177 (WebKit::WebDatabaseManager::getDatabaseOrigins):
2178 Send an array of the identifiers for the SecurityOrigins for which there are databases to
2180 (WebKit::WebDatabaseManager::deleteDatabasesForOrigin):
2181 If the SecurityOrigin with that identifier exists, tell the DatabaseTracker to delete the
2182 databases for that origin.
2183 (WebKit::WebDatabaseManager::deleteAllDatabases):
2184 Tell the DatabaseTracker to delete the databases for that origin.
2185 * WebProcess/WebCoreSupport/WebDatabaseManager.h:
2186 * WebProcess/WebCoreSupport/WebDatabaseManager.messages.in: Added.
2187 * WebProcess/WebProcess.cpp:
2188 (WebKit::WebProcess::didReceiveMessage):
2191 Add WKDatabaseManager.cpp/.h and WebDatabaseManagerProxy.cpp/.h
2192 * WebKit2.xcodeproj/project.pbxproj:
2193 Ditto, also add WebDatabaseManagerProxy.messages.in and WebDatabaseManager.messages.in.
2194 * win/WebKit2.vcproj:
2196 * win/WebKit2Generated.make:
2197 Make sure WKDatabaseManager.h is copied into WebKitBuild on Windows.
2199 2010-12-10 Ada Chan <adachan@apple.com>
2201 Reviewed by Anders Carlsson.
2203 Implement Download::start() and Download::startWithHandle() on Windows.
2204 https://bugs.webkit.org/show_bug.cgi?id=50844
2206 * WebProcess/Downloads/Download.h:
2207 * WebProcess/Downloads/cf/DownloadCFNet.cpp:
2208 (WebKit::Download::start): Create a CFURLDownloadRef and schedule it.
2209 (WebKit::Download::startWithHandle): Create a CFURLDownloadRef with the loading connection
2210 retrieved from the ResourceHandle.
2211 (WebKit::Download::platformInvalidate):
2212 (WebKit::downloadFromClientInfo):
2213 (WebKit::didStartCallback):
2214 (WebKit::willSendRequestCallback):
2215 (WebKit::didReceiveAuthenticationChallengeCallback):
2216 (WebKit::didReceiveResponseCallback):
2217 (WebKit::willResumeWithResponseCallback):
2218 (WebKit::didReceiveDataCallback):
2219 (WebKit::shouldDecodeDataOfMIMETypeCallback):
2220 (WebKit::decideDestinationWithSuggestedObjectNameCallback):
2221 (WebKit::didCreateDestinationCallback):
2222 (WebKit::didFinishCallback):
2223 (WebKit::didFailCallback):
2225 2010-12-10 Enrica Casucci <enrica@apple.com>
2227 Windows build fix. Unreviewed.
2229 Adding a dummy synchronous message for platforms
2230 that don't have any.
2232 * WebProcess/WebPage/WebPage.cpp:
2233 (WebKit::WebPage::dummy):
2234 * WebProcess/WebPage/WebPage.h:
2235 * WebProcess/WebPage/WebPage.messages.in:
2237 2010-12-09 Brian Weinstein <bweinstein@apple.com>
2239 Reviewed by Adam Roben.
2241 Prep for WebKit2: Context menu support on Windows
2242 https://bugs.webkit.org/show_bug.cgi?id=50514
2244 Update WebKit2 to call the correct code when CROSS_PLATFORM_CONTEXT_MENUS is set.
2246 * Shared/WebContextMenuItemData.cpp:
2247 (WebKit::WebContextMenuItemData::WebContextMenuItemData): Add a branch based on whether or not
2248 CROSS_PLATFORM_CONTEXT_MENUS is set.
2249 * WebProcess/WebCoreSupport/WebContextMenuClient.cpp:
2250 (WebKit::WebContextMenuClient::customizeMenu): Define different functions based on
2251 whether or not CROSS_PLATFORM_CONTEXT_MENUS. Both of these are stubs, so functionality
2252 doesn't need to be shared.
2253 * WebProcess/WebCoreSupport/WebContextMenuClient.h: Define different functions based on
2254 whether or not CROSS_PLATFORM_CONTEXT_MENUS.
2255 * WebProcess/WebPage/WebContextMenu.cpp:
2256 (WebKit::WebContextMenu::show): Add a branch based on whether or not
2257 CROSS_PLATFORM_CONTEXT_MENUS is set.
2259 2010-12-09 Enrica Casucci <enrica@apple.com>
2261 Reviewed by Alexey Proskuryakov.
2263 Implement IME support for Mac.
2264 <rdar://problem/7660589> WebKit2: Implement IME support for Mac.
2265 https://bugs.webkit.org/show_bug.cgi?id=50788
2267 This patch addes support for input methods in WebKit2.
2268 In order to support IME, it was necessary to add synchronous calls from the UIProcess
2269 to the WebProcess. These calls all have a timeout of 1 second.
2270 The current implementation still uses the NSTextInput protocol, but the plan is to move
2271 to the NSTextInputClient protocol. This has not been done yet for ease of comparison with
2272 WebKit. attributedSubstringFromRange is the only method that has not been implemented, because
2273 I have not yet decided what is the best way to send an NSAttributedString across the process
2276 * Platform/CoreIPC/HandleMessage.h:
2277 (CoreIPC::callMemberFunction): Added template for member function.
2278 with four reply arguments.
2279 * Scripts/webkit2/messages.py: Added CompositionUnderline and relevant header.
2280 * Shared/WebCoreArgumentCoders.h:
2281 (CoreIPC::): Added encoder/decoder for CompositionUnderline.
2282 * UIProcess/API/mac/PageClientImpl.h: Added parameters to interceptKeyEvent and selectionChanged.
2283 * UIProcess/API/mac/PageClientImpl.mm:
2284 (WebKit::PageClientImpl::selectionChanged): Added parameters.
2285 (WebKit::PageClientImpl::interceptKeyEvent): Added parameters.
2286 * UIProcess/API/mac/WKView.mm:
2287 (-[WKView initWithFrame:pageNamespaceRef:pageGroupRef:]): Added initialization of new private members.
2288 (-[WKView insertText:]):
2289 (-[WKView _selectionChanged:isEditable:isPassword:hasMarkedText:range:]): Added parameters.
2290 (-[WKView _interceptKeyEvent:hasComposition:start:end:lines:WebCore::]): Added parameters.
2291 (-[WKView keyDown:]): Modified to reset state on each keyDown.
2292 (-[WKView selectedRange]): Added.
2293 (-[WKView hasMarkedText]): Added.
2294 (-[WKView unmarkText]): Added.
2295 (-[WKView validAttributesForMarkedText]): Added.
2296 (extractUnderlines): Added.
2297 (-[WKView setMarkedText:selectedRange:]): Added.
2298 (-[WKView markedRange]): Added.
2299 (-[WKView attributedSubstringFromRange:]): Added.
2300 (-[WKView characterIndexForPoint:]): Added.
2301 (-[WKView firstRectForCharacterRange:]): Added.
2302 (-[WKView conversationIdentifier]): Added.
2303 * UIProcess/API/mac/WKViewInternal.h: Added parameters to _interceptKeyEvent and _selectionChanged.
2304 * UIProcess/PageClient.h: Added parameters to interpretKeyEvent and selectionChanged.
2305 * UIProcess/WebPageProxy.cpp:
2306 (WebKit::WebPageProxy::getMarkedRange): Added.
2307 (WebKit::WebPageProxy::characterIndexForPoint): Added.
2308 (WebKit::WebPageProxy::firstRectForCharacterRange): Added.
2309 (WebKit::WebPageProxy::interpretKeyEvent): Additional parameters.
2310 (WebKit::WebPageProxy::didSelectionChange): Additional parameters for Mac platform.
2311 * UIProcess/WebPageProxy.h: Added new methods and parameters to didSelectionChange
2312 and interpretKeyEvent.
2313 * UIProcess/WebPageProxy.messages.in: Added parameters to interpretKeyEvent and selectionChanged messages.
2314 * UIProcess/WebProcessProxy.h:
2315 (WebKit::WebProcessProxy::sendSync): Added support for synchronous messages.
2316 The default timeout is 1 second.
2317 * WebProcess/WebCoreSupport/WebEditorClient.cpp: respondToChangedSelection is now
2318 only for non Mac platform.
2319 * WebProcess/WebCoreSupport/mac/WebEditorClientMac.mm:
2320 (WebKit::WebEditorClient::respondToChangedSelection): Added implementation for Mac platform.
2321 * WebProcess/WebPage/WebPage.cpp:
2322 (WebKit::WebPage::didReceiveSyncMessage): Added.
2323 * WebProcess/WebPage/WebPage.h: Added new methods and support for synchronous messages.
2324 * WebProcess/WebPage/WebPage.messages.in: Added new messages.
2325 * WebProcess/WebPage/mac/WebPageMac.mm:
2326 (WebKit::WebPage::interceptEditingKeyboardEvent): Added parameters.
2327 (WebKit::WebPage::convertRangeToPlatformRange): Added.
2328 (WebKit::WebPage::getMarkedRange): Added.
2329 (WebKit::characterRangeAtPoint): Added.
2330 (WebKit::WebPage::characterIndexForPoint): Added.
2331 (WebKit::convertToRange): Added.
2332 (WebKit::WebPage::firstRectForCharacterRange): Added.
2333 * WebProcess/WebProcess.cpp:
2334 (WebKit::WebProcess::didReceiveSyncMessage): Added.
2335 * WebProcess/WebProcess.h: Added didReceiveSyncMessage.
2337 2010-12-10 Jocelyn Turcotte <jocelyn.turcotte@nokia.com>
2339 Reviewed by Kenneth Rohde Christiansen.
2341 [Qt][WK2] Add the QWKContext API class to wrap the WebContext.
2342 https://bugs.webkit.org/show_bug.cgi?id=50750
2344 * UIProcess/API/qt/WKView.h:
2345 * UIProcess/API/qt/qgraphicswkview.cpp:
2346 (QGraphicsWKView::QGraphicsWKView):
2347 Change the WKPageNamespaceRef argument to QWKContext*
2348 * UIProcess/API/qt/qgraphicswkview.h:
2349 * UIProcess/API/qt/qwkcontext.cpp: Added.
2350 * UIProcess/API/qt/qwkcontext.h: Added.
2351 * UIProcess/API/qt/qwkcontext_p.h: Added.
2352 * UIProcess/API/qt/qwkpage.cpp:
2353 (QWKPagePrivate::QWKPagePrivate):
2355 Change the WKPageNamespaceRef argument to QWKContext*
2356 * UIProcess/API/qt/qwkpage.h:
2357 * UIProcess/API/qt/qwkpage_p.h:
2360 2010-12-10 Kimmo Kinnunen <kimmo.t.kinnunen@nokia.com>
2362 Reviewed by Kenneth Rohde Christiansen.
2364 Flush IPC connection send buffer after each message.
2366 [Qt] [WK2] IPC messages are not sent until send buffer fills up
2367 https://bugs.webkit.org/show_bug.cgi?id=50667
2369 * Platform/CoreIPC/qt/ConnectionQt.cpp:
2370 (CoreIPC::Connection::sendOutgoingMessage):
2372 2010-12-09 Jocelyn Turcotte <jocelyn.turcotte@nokia.com>
2374 Reviewed by Kenneth Rohde Christiansen.
2376 [Qt][WK2] Use a single QNetworkAccessManager per web process.
2377 https://bugs.webkit.org/show_bug.cgi?id=50757
2379 This allows a better management of network resources and the use
2380 of global cookie jar and disk cache across all frames.
2382 * WebProcess/WebCoreSupport/qt/WebFrameNetworkingContext.cpp:
2383 (WebCore::WebFrameNetworkingContext::WebFrameNetworkingContext):
2384 (WebCore::WebFrameNetworkingContext::networkAccessManager):
2385 * WebProcess/WebCoreSupport/qt/WebFrameNetworkingContext.h:
2386 * WebProcess/WebProcess.cpp:
2387 (WebKit::WebProcess::WebProcess):
2388 (WebKit::WebProcess::initializeWebProcess):
2389 (WebKit::WebProcess::shutdownIfPossible):
2390 * WebProcess/WebProcess.h:
2391 (WebKit::WebProcess::networkAccessManager):
2392 * WebProcess/mac/WebProcessMac.mm:
2393 (WebKit::WebProcess::platformInitializeWebProcess):
2394 (WebKit::WebProcess::platformShutdown):
2395 * WebProcess/qt/WebProcessQt.cpp:
2396 (WebKit::WebProcess::platformInitializeWebProcess):
2397 (WebKit::WebProcess::platformShutdown):
2398 * WebProcess/win/WebProcessWin.cpp:
2399 (WebKit::WebProcess::platformInitializeWebProcess):
2400 (WebKit::WebProcess::platformShutdown):
2402 2010-12-09 Mark Rowe <mrowe@apple.com>
2404 Fix the 32-bit build.
2406 * Shared/cf/ArgumentCodersCF.cpp:
2407 (CoreIPC::sizeForNumberType):
2409 2010-12-09 Maciej Stachowiak <mjs@apple.com>
2411 Reviewed by Brady Eidson.
2413 WebKit2: Control-click doesn't invoke context menu
2414 https://bugs.webkit.org/show_bug.cgi?id=50793
2415 <rdar://problem/8664800>
2417 * WebProcess/WebPage/WebPage.cpp:
2418 (WebKit::isContextClick): New helper function - on Mac, not only right clicks
2419 but also control-left-clicks are context clicks.
2420 (WebKit::handleMouseEvent): Use above.
2422 2010-12-09 Anders Carlsson <andersca@apple.com>
2426 * Scripts/webkit2/messages.py:
2427 DrawingAreaInfo is a struct.
2429 * Shared/WebPreferencesStore.cpp:
2430 (WebKit::valueForKey):
2431 Move valueForKey above code that uses it.
2433 * UIProcess/mac/WebInspectorProxyMac.mm:
2434 (-[WebInspectorProxyObjCAdapter windowWillClose:]):
2435 Remove trailing semicolon.
2437 2010-12-09 Timothy Hatcher <timothy@apple.com>
2439 Add support for transparent WebKit2 WKViews.
2441 https://webkit.org/b/50785
2443 Reviewed by Anders Carlsson.
2445 * Shared/WebPageCreationParameters.cpp:
2446 (WebKit::WebPageCreationParameters::encode): Encode drawsBackground and drawsTransparentBackground.
2447 (WebKit::WebPageCreationParameters::decode): Decode drawsBackground and drawsTransparentBackground.
2448 * Shared/WebPageCreationParameters.h:
2449 * UIProcess/API/mac/WKView.h:
2450 * UIProcess/API/mac/WKView.mm:
2451 (-[WKView setDrawsBackground:]): Added.
2452 (-[WKView drawsBackground]): Added.
2453 (-[WKView setDrawsTransparentBackground:]): Added.
2454 (-[WKView drawsTransparentBackground]): Added.
2455 (-[WKView drawRect:]): Only fill the background if the WebProcess isn't valid and drawsBackground.
2456 Use white or clear based on setDrawsTransparentBackground.
2457 (-[WKView isOpaque]): Return drawsBackground.
2458 * UIProcess/WebPageProxy.cpp:
2459 (WebKit::WebPageProxy::WebPageProxy): Initialize m_drawsBackground and m_drawsTransparentBackground.
2460 (WebKit::WebPageProxy::setDrawsBackground): Added. Send a SetDrawsBackground message.
2461 (WebKit::WebPageProxy::setDrawsTransparentBackground): Added. Send a SetDrawsTransparentBackground message.
2462 (WebKit::WebPageProxy::creationParameters): Set drawsBackground and drawsTransparentBackground.
2463 * UIProcess/WebPageProxy.h:
2464 (WebKit::WebPageProxy::drawsBackground): Added. Return m_drawsBackground.
2465 (WebKit::WebPageProxy::drawsTransparentBackground): Added. Return m_drawsTransparentBackground.
2466 * UIProcess/mac/ChunkedUpdateDrawingAreaProxyMac.mm:
2467 (WebKit::ChunkedUpdateDrawingAreaProxy::platformPaint): Use the copy blend mode when drawing a background.
2468 (WebKit::ChunkedUpdateDrawingAreaProxy::drawUpdateChunkIntoBackingStore): Use the copy blend mode to replace existing content.
2469 * WebProcess/WebCoreSupport/WebFrameLoaderClient.cpp:
2470 (WebKit::WebFrameLoaderClient::transitionToCommittedForNewPage): Setup the new view's background color and transparent flag.
2471 * WebProcess/WebPage/WebPage.cpp:
2472 (WebKit::WebPage::WebPage): Initialize m_drawsBackground and m_drawsTransparentBackground.
2473 (WebKit::WebPage::setDrawsBackground): Added. Propagate the flag to the FrameViews.
2474 (WebKit::WebPage::setDrawsTransparentBackground): Added. Propagate the background color to the FrameViews.
2475 * WebProcess/WebPage/WebPage.h:
2476 (WebKit::WebPage::drawsBackground): Added. Return m_drawsBackground.
2477 (WebKit::WebPage::drawsTransparentBackground): Added. Return m_drawsTransparentBackground.
2478 * WebProcess/WebPage/WebPage.messages.in: Added SetDrawsBackground and SetDrawsTransparentBackground.
2480 2010-12-09 Anders Carlsson <andersca@apple.com>
2482 Reviewed by Sam Weinig.
2484 Cannot use NSKeyedArchiver in WK2 for ResourceResponses
2485 https://bugs.webkit.org/show_bug.cgi?id=50792
2486 <rdar://problem/8741799>
2488 When encoding, first convert the requests and responses to the serializable dictionary representation
2489 and use the newly added CF CoreIPC encoders. When decoding, do the opposite.
2491 * Shared/mac/WebCoreArgumentCodersMac.mm:
2492 (CoreIPC::encodeResourceRequest):
2493 (CoreIPC::decodeResourceRequest):
2494 (CoreIPC::encodeResourceResponse):
2495 (CoreIPC::decodeResourceResponse):
2497 2010-12-09 Anders Carlsson <andersca@apple.com>
2499 Reviewed by Sam Weinig.
2501 Add CoreIPC coders for CF types
2502 https://bugs.webkit.org/show_bug.cgi?id=50791
2504 * Platform/CoreIPC/ArgumentDecoder.h:
2505 (CoreIPC::ArgumentDecoder::decodeEnum):
2506 * Platform/CoreIPC/ArgumentEncoder.h:
2507 (CoreIPC::ArgumentEncoder::encodeEnum):
2508 * Shared/cf/ArgumentCodersCF.cpp: Added.
2509 (CoreIPC::tokenNullTypeRef):
2510 (CoreIPC::typeFromCFTypeRef):
2513 (CoreIPC::sizeForNumberType):
2514 * Shared/cf/ArgumentCodersCF.h: Added.
2515 * WebKit2.xcodeproj/project.pbxproj:
2517 2010-12-09 Brady Eidson <beidson@apple.com>
2519 Reviewed by Sam Weinig.
2521 <rdar://problem/8749750> and https://bugs.webkit.org/show_bug.cgi?id=50786
2522 WK2 authentication never consults WebCore session credential storage.
2524 * WebProcess/WebCoreSupport/WebFrameLoaderClient.cpp:
2525 (WebKit::WebFrameLoaderClient::shouldUseCredentialStorage): Since we don't need to expose this as
2526 API at this time, always return true.
2528 2010-12-09 Sam Weinig <weinig@apple.com>
2530 Reviewed by Alexey Proskuryakov.
2532 WebKit2: Add support for access keys
2533 https://bugs.webkit.org/show_bug.cgi?id=49832
2535 * WebProcess/WebPage/WebPage.cpp:
2536 (WebKit::handleKeyEvent): Match windows WebKit and call
2537 the event handler's for handleAccessKey function for
2538 system keys. This will never be hit on the Mac.
2540 2010-12-09 Darin Adler <darin@apple.com>
2544 * WebProcess/WebCoreSupport/qt/WebContextMenuClientQt.cpp: Include "NotImplemented.h".
2546 2010-12-09 Steve Falkenburg <sfalken@apple.com>
2550 * WebProcess/WebCoreSupport/win/WebContextMenuClientWin.cpp:
2552 2010-12-09 Brady Eidson <beidson@apple.com>
2554 Reviewed by Anders Carlsson.
2556 <rdar://problem/8613779> and https://bugs.webkit.org/show_bug.cgi?id=50777
2557 WebKit2 ContextMenuClient support
2559 Implement google search in a cross platform manner, and add a FIXME for download support:
2560 * WebProcess/WebCoreSupport/WebContextMenuClient.cpp:
2561 (WebKit::WebContextMenuClient::downloadURL):
2562 (WebKit::WebContextMenuClient::searchWithGoogle):
2564 Mac implementations for speaking and searching:
2565 * WebProcess/WebCoreSupport/mac/WebContextMenuClientMac.mm: Added.
2566 (WebKit::WebContextMenuClient::lookUpInDictionary): Add a FIXME for now.
2567 (WebKit::WebContextMenuClient::isSpeaking):
2568 (WebKit::WebContextMenuClient::speak):
2569 (WebKit::WebContextMenuClient::stopSpeaking):
2570 (WebKit::WebContextMenuClient::searchWithSpotlight):
2572 Stubs for Win and Qt:
2573 * WebProcess/WebCoreSupport/qt/WebContextMenuClientQt.cpp: Added.
2574 (WebKit::WebContextMenuClient::lookUpInDictionary):
2575 (WebKit::WebContextMenuClient::isSpeaking):
2576 (WebKit::WebContextMenuClient::speak):
2577 (WebKit::WebContextMenuClient::stopSpeaking):
2578 * WebProcess/WebCoreSupport/win/WebContextMenuClientWin.cpp: Added.
2579 (WebKit::WebContextMenuClient::lookUpInDictionary):
2580 (WebKit::WebContextMenuClient::isSpeaking):
2581 (WebKit::WebContextMenuClient::speak):
2582 (WebKit::WebContextMenuClient::stopSpeaking):
2584 Project file stuffs:
2586 * WebKit2.xcodeproj/project.pbxproj:
2587 * win/WebKit2.vcproj:
2589 2010-12-09 Anders Carlsson <andersca@apple.com>
2591 Reviewed by Sam Weinig.
2593 Don't leak the PDFDocument
2594 https://bugs.webkit.org/show_bug.cgi?id=50771
2596 * UIProcess/API/mac/PDFViewController.mm:
2597 (WebKit::PDFViewController::setPDFDocumentData):
2599 2010-12-09 Anders Carlsson <andersca@apple.com>
2601 Reviewed by Sam Weinig.
2603 Add a basic implementation of PDF support on Mac
2604 https://bugs.webkit.org/show_bug.cgi?id=50768
2606 * UIProcess/API/mac/PDFViewController.h:
2607 * UIProcess/API/mac/PDFViewController.mm: Added.
2608 (-[WKPDFView initWithFrame:PDFViewController:WebKit::]):
2609 Setup the view hierarchy.
2611 (-[WKPDFView invalidate]):
2612 Set the controller to null.
2614 (-[WKPDFView pdfView]):
2615 Return the PDF view.
2617 (WebKit::PDFViewController::create):
2618 (WebKit::PDFViewController::PDFViewController):
2619 Create a WKPDFView and insert it as a subview of the WKView.
2621 (WebKit::PDFViewController::~PDFViewController):
2622 Remove the WKPDFView from the view hierarchy and invalidate it.
2624 (WebKit::convertPostScriptDataSourceToPDF):
2625 Convert the data in the data reference to PDF and return it as a CFDataRef.
2627 (WebKit::PDFViewController::setPDFDocumentData):
2628 Create a PDFDocument and set it on the PDF view.
2630 (WebKit::PDFViewController::pdfDocumentClass):
2631 (WebKit::PDFViewController::pdfPreviewViewClass):
2632 (WebKit::PDFViewController::pdfKitBundle):
2633 Add soft-linking helper functions.
2635 * UIProcess/API/mac/PageClientImpl.mm:
2636 (WebKit::PageClientImpl::didCommitLoadForMainFrame):
2637 (WebKit::PageClientImpl::didFinishLoadingDataForCustomRepresentation):
2638 Call the WKView methods.
2640 * UIProcess/API/mac/WKView.mm:
2641 (-[WKView _setPageHasCustomRepresentation:]):
2642 Create a PDF view controller if necessary.
2644 (-[WKView _didFinishLoadingDataForCustomRepresentation:CoreIPC::]):
2645 Pass the data along to the PDF view controller.
2647 * WebKit2.xcodeproj/project.pbxproj:
2650 2010-12-09 Anders Carlsson <andersca@apple.com>
2652 Reviewed by Sam Weinig.
2654 Add support for custom representation
2655 https://bugs.webkit.org/show_bug.cgi?id=50767
2657 * Shared/WebProcessCreationParameters.cpp:
2658 (WebKit::WebProcessCreationParameters::encode):
2659 (WebKit::WebProcessCreationParameters::decode):
2660 * Shared/WebProcessCreationParameters.h:
2661 Add mimeTypesWithCustomRepresentation and encode and decode accordingly.
2663 * UIProcess/API/mac/PageClientImpl.h:
2664 * UIProcess/API/mac/PageClientImpl.mm:
2665 (WebKit::PageClientImpl::didCommitLoadForMainFrame):
2666 (WebKit::PageClientImpl::didFinishLoadingDataForCustomRepresentation):
2667 Add empty stubs for now.
2669 * UIProcess/API/qt/qwkpage.cpp:
2670 (QWKPagePrivate::didCommitLoadForMainFrame):
2671 (QWKPagePrivate::didFinishLoadingDataForCustomRepresentation):
2672 * UIProcess/API/qt/qwkpage_p.h:
2675 * UIProcess/PageClient.h:
2676 Add new functions for custom representations.
2678 * UIProcess/WebFrameProxy.cpp:
2679 (WebKit::WebFrameProxy::canShowMIMEType):
2680 Check that the mime type is not null.
2682 * UIProcess/WebPageProxy.cpp:
2683 (WebKit::WebPageProxy::didCommitLoadForFrame):
2684 This now takes an additional frameHasCustomRepresentation parameter.
2685 Call the page client function.
2687 (WebKit::WebPageProxy::didFinishLoadingDataForCustomRepresentation):
2688 Call the page client function.
2690 * UIProcess/WebPageProxy.messages.in:
2691 Change DidCommitLoadForFrame message, add DidFinishLoadingDataForCustomRepresentation message.
2693 * UIProcess/mac/WebContextMac.mm:
2694 (WebKit::WebContext::platformInitializeWebProcess):
2695 We want to use custom representations for PDF and PostScript MIME types.
2697 * UIProcess/win/WebView.cpp:
2698 (WebKit::WebView::didCommitLoadForMainFrame):
2699 (WebKit::WebView::didFinishLoadingDataForCustomRepresentation):
2700 * UIProcess/win/WebView.h:
2703 * WebProcess/WebCoreSupport/WebFrameLoaderClient.cpp:
2704 (WebKit::WebFrameLoaderClient::WebFrameLoaderClient):
2705 Initialize m_frameHasCustomRepresentation.
2707 (WebKit::WebFrameLoaderClient::hasHTMLView):
2708 The frame has a HTML view unless it has a custom representation.
2710 (WebKit::WebFrameLoaderClient::dispatchDidCommitLoad):
2711 Pass along whether the frame has a custom representation.
2713 (WebKit::WebFrameLoaderClient::committedLoad):
2714 Don't send data back to WebCore if the frame has a custom representation.
2716 (WebKit::WebFrameLoaderClient::finishedLoading):
2717 Send all the data to the UI process.
2719 (WebKit::WebFrameLoaderClient::transitionToCommittedForNewPage):
2720 Update the m_frameHasCustomRepresentation state based on the MIME type.
2722 * WebProcess/WebCoreSupport/WebFrameLoaderClient.h:
2723 (WebKit::WebFrameLoaderClient::frameHasCustomRepresentation):
2726 * WebProcess/WebPage/mac/ChunkedUpdateDrawingAreaMac.cpp:
2727 (WebKit::ChunkedUpdateDrawingArea::paintIntoUpdateChunk):
2728 Don't do any painting if the main frame has a custom representation.
2730 * WebProcess/WebProcess.cpp:
2731 (WebKit::WebProcess::initializeWebProcess):
2732 Add all the MIME types with custom representations.
2734 * WebProcess/WebProcess.h:
2735 (WebKit::WebProcess::shouldUseCustomRepresentationForMIMEType):
2738 2010-12-09 Maciej Stachowiak <mjs@apple.com>
2740 Reviewed by Dan Bernstein.
2742 Implement "Use Selection for Find" in WebKit2
2743 https://bugs.webkit.org/show_bug.cgi?id=50737
2744 <rdar://problem/8564881>
2746 * UIProcess/API/mac/WKView.mm: Add support for the takeFindStringFromSelection:
2747 selector as a command.
2749 2010-12-09 Brady Eidson <beidson@apple.com>
2751 Reviewed by Maciej Stachowiak.
2753 <rdar://problem/7660733> and https://bugs.webkit.org/show_bug.cgi?id=50191
2754 WebKit2 Authentication Support
2756 Implement authentication-related coders:
2757 * Shared/WebCoreArgumentCoders.h:
2759 Allow the ResourceResponse coders to handle null responses:
2760 * Shared/mac/WebCoreArgumentCodersMac.mm:
2761 (CoreIPC::encodeResourceResponse):
2762 (CoreIPC::decodeResourceResponse):
2764 Add new API and Impl casts for ProtectionSpace and Credential enums:
2765 * UIProcess/API/C/WKAPICast.h:
2767 (WebKit::toCredentialPersistence):
2769 Move the DecisionListener to be accessed off the challenge itself, and fill in other
2771 * UIProcess/API/C/WKAuthenticationChallenge.cpp:
2772 (WKAuthenticationChallengeGetDecisionListener):
2773 (WKAuthenticationChallengeGetProtectionSpace):
2774 (WKAuthenticationChallengeGetProposedCredential):
2775 (WKAuthenticationChallengeGetPreviousFailureCount):
2776 * UIProcess/API/C/WKAuthenticationChallenge.h:
2777 * UIProcess/Authentication/AuthenticationChallengeProxy.cpp:
2778 (WebKit::AuthenticationChallengeProxy::~AuthenticationChallengeProxy):
2779 (WebKit::AuthenticationChallengeProxy::proposedCredential):
2780 (WebKit::AuthenticationChallengeProxy::protectionSpace):
2781 * UIProcess/Authentication/AuthenticationChallengeProxy.h:
2782 (WebKit::AuthenticationChallengeProxy::previousFailureCount):
2784 Fill in some credential API:
2785 * UIProcess/API/C/WKCredential.cpp:
2786 (WKCredentialCreate):
2787 (WKCredentialCopyUser):
2788 * UIProcess/API/C/WKCredential.h:
2789 * UIProcess/API/C/WKCredentialTypes.h: Added.
2790 * UIProcess/Authentication/WebCredential.cpp:
2791 (WebKit::WebCredential::WebCredential):
2792 (WebKit::WebCredential::user):
2793 * UIProcess/Authentication/WebCredential.h:
2794 (WebKit::WebCredential::create):
2796 Fill in some protection space API:
2797 * UIProcess/API/C/WKProtectionSpace.cpp:
2798 (WKProtectionSpaceCopyHost):
2799 (WKProtectionSpaceGetPort):
2800 (WKProtectionSpaceCopyRealm):
2801 (WKProtectionSpaceGetIsProxy):
2802 (WKProtectionSpaceGetServerType):
2803 (WKProtectionSpaceGetReceivesCredentialSecurely):
2804 (WKProtectionSpaceGetAuthenticationScheme):
2805 * UIProcess/API/C/WKProtectionSpace.h:
2806 * UIProcess/API/C/WKProtectionSpaceTypes.h: Added.
2807 * UIProcess/Authentication/WebProtectionSpace.cpp:
2808 (WebKit::WebProtectionSpace::WebProtectionSpace):
2809 (WebKit::WebProtectionSpace::host):
2810 (WebKit::WebProtectionSpace::port):
2811 (WebKit::WebProtectionSpace::realm):
2812 (WebKit::WebProtectionSpace::isProxy):
2813 (WebKit::WebProtectionSpace::serverType):
2814 (WebKit::WebProtectionSpace::receivesCredentialSecurely):
2815 (WebKit::WebProtectionSpace::authenticationScheme):
2816 * UIProcess/Authentication/WebProtectionSpace.h:
2818 Change the authentication challenge callback to reflect the new ownership of
2819 the DecisionListener:
2820 * UIProcess/API/C/WKPage.h:
2821 * UIProcess/WebLoaderClient.cpp:
2822 (WebKit::WebLoaderClient::didReceiveAuthenticationChallengeInFrame):
2823 * UIProcess/WebLoaderClient.h:
2824 * UIProcess/WebPageProxy.cpp:
2825 (WebKit::WebPageProxy::didReceiveAuthenticationChallenge):
2828 * WebKit2.xcodeproj/project.pbxproj:
2829 * win/WebKit2.vcproj:
2830 * win/WebKit2Generated.make:
2832 2010-12-08 Sam Weinig <sam@webkit.org>
2834 Reviewed by Geoffrey "Error" Garen.
2836 Fix typo: Diplaying -> Displaying
2838 * UIProcess/API/C/WKFrame.cpp:
2839 (WKFrameIsDisplayingStandaloneImageDocument):
2840 (WKFrameIsDisplayingMarkupDocument):
2841 * UIProcess/API/C/WKFrame.h:
2842 * UIProcess/WebFrameProxy.cpp:
2843 (WebKit::WebFrameProxy::canProvideSource):
2844 (WebKit::WebFrameProxy::isDisplayingStandaloneImageDocument):
2845 (WebKit::WebFrameProxy::isDisplayingMarkupDocument):
2846 * UIProcess/WebFrameProxy.h:
2848 2010-12-08 Sam Weinig <sam@webkit.org>
2850 Reviewed by Gavin Barraclough.
2852 Add WebKit2 Preference for TabsToLinks behavior.
2853 <rdar://problem/8664263>
2855 * Shared/WebPreferencesStore.h:
2856 * UIProcess/API/C/WKPreferences.cpp:
2857 (WKPreferencesSetTabsToLinks):
2858 (WKPreferencesGetTabsToLinks):
2859 * UIProcess/API/C/WKPreferences.h:
2860 * WebProcess/WebCoreSupport/WebChromeClient.cpp:
2861 (WebKit::WebChromeClient::tabsToLinks):
2862 * WebProcess/WebPage/WebPage.cpp:
2863 (WebKit::WebPage::WebPage):
2864 (WebKit::WebPage::updatePreferences):
2865 * WebProcess/WebPage/WebPage.h:
2866 (WebKit::WebPage::tabsToLinks):
2868 2010-12-08 Benjamin Poulain <benjamin.poulain@nokia.com>
2870 Reviewed by Andreas Kling.
2872 WebTouchEvent::isTouchEventType() does not take into account the type TouchCancel
2873 https://bugs.webkit.org/show_bug.cgi?id=50680
2875 Add the missing type check to WebTouchEvent::isTouchEventType().
2877 * Shared/WebTouchEvent.cpp:
2878 (WebKit::WebTouchEvent::isTouchEventType):
2880 2010-12-08 Sam Weinig <sam@webkit.org>
2882 Reviewed by Darin Adler.
2884 Need a way to get a WKBundleFrameRef from JS HTMLIFrameElement
2885 https://bugs.webkit.org/show_bug.cgi?id=50726
2887 Adds WKBundleNodeHandleCopyDocumentFrame, WKBundleNodeHandleCopyHTMLFrameElementContentFrame
2888 and WKBundleNodeHandleCopyHTMLIFrameElementContentFrame, to handle the document, <frame>
2891 * WebProcess/InjectedBundle/API/c/WKBundleNodeHandle.cpp:
2892 (WKBundleNodeHandleCopyDocumentFrame):
2893 (WKBundleNodeHandleCopyHTMLFrameElementContentFrame):
2894 (WKBundleNodeHandleCopyHTMLIFrameElementContentFrame):
2895 * WebProcess/InjectedBundle/API/c/WKBundleNodeHandlePrivate.h:
2896 * WebProcess/InjectedBundle/DOM/InjectedBundleNodeHandle.cpp:
2897 (WebKit::InjectedBundleNodeHandle::copyDocumentFrame):
2898 (WebKit::InjectedBundleNodeHandle::copyHTMLFrameElementContentFrame):
2899 (WebKit::InjectedBundleNodeHandle::copyHTMLIFrameElementContentFrame):
2900 * WebProcess/InjectedBundle/DOM/InjectedBundleNodeHandle.h:
2902 2010-12-08 Sam Weinig <sam@webkit.org>
2904 Reviewed by Gavin Barraclough.
2906 Need a WebKit2 way to test whether a frame is displaying a standalone image
2907 <rdar://problem/8443059>
2908 WebKit2: Need a way to test whether a page or frame is showing HTML content
2909 <rdar://problem/8642563>
2911 Add WKFrameIsDiplayingStandaloneImageDocument and WKFrameIsDiplayingMarkupDocument.
2913 * UIProcess/API/C/WKFrame.cpp:
2914 (WKFrameIsDiplayingStandaloneImageDocument):
2915 (WKFrameIsDiplayingMarkupDocument):
2916 * UIProcess/API/C/WKFrame.h:
2917 * UIProcess/WebFrameProxy.cpp:
2918 (WebKit::WebFrameProxy::canProvideSource): This now just calls isDiplayingMarkupDocument.
2919 (WebKit::WebFrameProxy::isDiplayingStandaloneImageDocument):
2920 (WebKit::WebFrameProxy::isDiplayingMarkupDocument):
2921 * UIProcess/WebFrameProxy.h:
2923 2010-12-08 Anders Carlsson <andersca@apple.com>
2925 Reviewed by Darin Adler.
2927 WebFrameProxy::canShowMIMEType should return true for PDF MIME types in the main frame
2928 https://bugs.webkit.org/show_bug.cgi?id=50724
2930 * UIProcess/WebContext.cpp:
2931 (WebKit::WebContext::pdfAndPostScriptMIMETypes):
2932 * UIProcess/WebContext.h:
2933 * UIProcess/WebFrameProxy.cpp:
2934 (WebKit::WebFrameProxy::canShowMIMEType):
2936 2010-12-08 Brian Weinstein <bweinstein@apple.com>
2938 Reviewed by Brady Eidson.
2940 WebMenuTarget implemented in both WebKit and WebKit2
2941 https://bugs.webkit.org/show_bug.cgi?id=50665
2942 <rdar://problem/8742640>
2944 Rename WebMenuTarget to WKMenuTarget to prevent this warning and stay consistent with
2945 other WebKit2 namings.
2947 * UIProcess/mac/WebContextMenuProxyMac.mm:
2948 (+[WKMenuTarget sharedMenuTarget]):
2949 (WebKit::nsMenuItemVector):
2950 (WebKit::WebContextMenuProxyMac::showContextMenu):
2952 2010-12-08 Anders Carlsson <andersca@apple.com>
2954 Reviewed by Sam Weinig.
2956 Move canShowMIMEType to Frame
2957 https://bugs.webkit.org/show_bug.cgi?id=50723
2959 * UIProcess/API/C/WKFrame.cpp:
2960 (WKFrameCanShowMIMEType):
2961 * UIProcess/API/C/WKFrame.h:
2962 * UIProcess/API/C/WKPage.cpp:
2963 * UIProcess/API/C/WKPage.h:
2964 * UIProcess/WebFrameProxy.cpp:
2965 (WebKit::WebFrameProxy::canShowMIMEType):
2966 * UIProcess/WebFrameProxy.h:
2968 2010-12-08 Sam Weinig <sam@webkit.org>
2970 Reviewed by Oliver Hunt.
2972 Rename WKPreferencesGetFTPDirectoryTemplatePath to WKPreferencesCopyFTPDirectoryTemplatePath
2973 since it copies the value.
2975 * UIProcess/API/C/WKPreferences.cpp:
2976 (WKPreferencesCopyFTPDirectoryTemplatePath):
2977 * UIProcess/API/C/WKPreferencesPrivate.h:
2979 2010-12-08 Sam Weinig <sam@webkit.org>
2981 Reviewed by Brady Eidson.
2983 WebKit2: Can't open ftp directory
2984 <rdar://problem/8489321>
2986 * Shared/WebPreferencesStore.h:
2987 * UIProcess/API/C/WKPreferences.cpp:
2988 (WKPreferencesSetForceFTPDirectoryListings):
2989 (WKPreferencesGetForceFTPDirectoryListings):
2990 (WKPreferencesSetFTPDirectoryTemplatePath):
2991 (WKPreferencesGetFTPDirectoryTemplatePath):
2992 * UIProcess/API/C/WKPreferencesPrivate.h:
2993 * WebProcess/WebPage/WebPage.cpp:
2994 (WebKit::WebPage::updatePreferences):
2995 Pipe through the FTP directory listing preferences.
2997 2010-12-08 Chris Marrin <cmarrin@apple.com>
2999 Reviewed by Simon Fraser.
3001 Share code between Mac (CA) and Windows (CACF) GraphicsLayer implementations
3002 https://bugs.webkit.org/show_bug.cgi?id=49388
3004 Fixes a build failure because WebChromeClient.cpp uses WebCore::Cursor.
3005 This patch adds an include of QuartzCore/CATransform3D, which includes
3006 a file that has a 'Cursor' object defined. So I had to qualify the
3007 use of Cursor in WebChromeClient.cpp.
3009 * WebProcess/WebCoreSupport/WebChromeClient.cpp:
3010 (WebKit::WebChromeClient::setCursor):
3012 2010-12-07 Brian Weinstein <bweinstein@apple.com>
3014 Reviewed by John Sullivan.
3016 Layering Violation in ContextMenu - member variable of type HitTestResult
3017 https://bugs.webkit.org/show_bug.cgi?id=50586
3019 Update users of ContextMenu and ContextMenuController to match where the new functions
3022 * Shared/WebContextMenuItemData.cpp:
3023 (WebKit::WebContextMenuItemData::WebContextMenuItemData): Remove the call to checkOrEnableItem, that call will be made when
3024 the ContextMenuItem is added to the ContextMenu through the ContextMenuController.
3025 * WebProcess/WebPage/WebContextMenu.cpp:
3026 (WebKit::WebContextMenu::show):
3028 2010-12-08 Jessie Berlin <jberlin@apple.com>
3030 Reviewed by Adam Roben.
3032 WebKit2: Implement WebChromeClient::exceededDatabaseQuota
3033 https://bugs.webkit.org/show_bug.cgi?id=50656
3035 The exceededDatabaseQuota call from the WebProcess to the UIProcess needs to be synchronous
3036 because the new quota is checked directly after exceededDatabaseQuota returns in order to
3037 determine if the new Database can be created.
3039 Pass all of the details from the WebProcess to the UIProcess in order to inform the
3040 decision in the UIProcess about the new quota. In WebKit1, these details were
3041 fetched through an additional call to the API detailsForDatabase (which is infeasible in
3042 WebKit2 since exceededDatabaseQuota is a synchronous call).
3044 * Platform/CoreIPC/HandleMessage.h:
3045 (CoreIPC::callMemberFunction):
3046 Add a version that takes 7 parameters.
3048 * UIProcess/API/C/WKPage.h:
3050 * UIProcess/API/qt/qwkpage.cpp:
3052 Indicate that exceededDatabaseQuota is not implemented.
3054 * UIProcess/WebPageProxy.cpp:
3055 (WebKit::WebPageProxy::exceededDatabaseQuota):
3056 Call the UIClient's exceededDatabaseQuota
3057 * UIProcess/WebPageProxy.h:
3058 * UIProcess/WebPageProxy.messages.in:
3060 * UIProcess/WebUIClient.cpp:
3061 (WebKit::WebUIClient::exceededDatabaseQuota):
3062 If the client does not implement exceededDatabaseQuota, return a the current quota.
3063 * UIProcess/WebUIClient.h:
3065 * WebProcess/WebCoreSupport/WebChromeClient.cpp:
3066 (WebKit::WebChromeClient::exceededDatabaseQuota):
3067 Send a synchronous message to the UIProcess to ask for the new quota for the origin for the
3070 2010-12-07 Anders Carlsson <andersca@apple.com>
3072 Reviewed by Sam Weinig.
3074 fast/loader/empty-embed-src-attribute.html asserts in debug builds
3075 https://bugs.webkit.org/show_bug.cgi?id=50643
3077 Just always ignore attempts to load requests with empty URLs.
3079 * WebProcess/WebCoreSupport/WebFrameLoaderClient.cpp:
3080 (WebKit::WebFrameLoaderClient::dispatchDecidePolicyForNavigationAction):
3082 2010-12-07 Jessie Berlin <jberlin@apple.com>
3084 Build fix. Unreviewed.
3087 Added WebDatabaseManagerQt.cpp.
3088 * WebProcess/WebCoreSupport/qt/WebDatabaseManagerQt.cpp: Added.
3089 (WebKit::WebDatabaseManager::databaseDirectory):
3090 Added a FIXME to implement and return an empty string.
3092 2010-12-07 Darin Adler <darin@apple.com>
3094 Get a bit closer to making Qt WebKit2 compile again.
3096 * WebKit2.pro: Add the WebDatabaseManager source files.
3097 Still missing: The Qt version of the databaseDirectory function.
3099 2010-12-07 Jessie Berlin <jberlin@apple.com>
3101 Reviewed by Darin Adler.
3103 WebKit2: Need to set the location of the Databases directory when the WebProcess is initialized
3104 https://bugs.webkit.org/show_bug.cgi?id=50604
3106 * WebProcess/WebCoreSupport/WebDatabaseManager.cpp: Added.
3107 (WebKit::WebDatabaseManager::shared):
3108 (WebKit::WebDatabaseManager::WebDatabaseManager):
3109 Initialize the DatabaseTracker with the Database directory.
3110 * WebProcess/WebCoreSupport/WebDatabaseManager.h: Added.
3111 * WebProcess/WebCoreSupport/mac/WebDatabaseManagerMac.mm: Added.
3112 (WebKit::WebDatabaseManager::databaseDirectory):
3113 Copied from WebKitInitializeDatabasesIfNecessary in WebKit/mac/Storage/WebDatabaseManager.mm.
3114 * WebProcess/WebCoreSupport/win/WebDatabaseManagerWin.cpp: Added.
3115 (WebKit::WebDatabaseManager::databaseDirectory):
3116 Copied from WebKitInitializeWebDatabasesIfNecessary in WebKit/win/WebDatabaseManager.cpp.
3118 * WebProcess/WebProcess.cpp:
3119 (WebKit::WebProcess::WebProcess):
3120 Make sure that the Databases directory has been set by calling WebDatabaseManager::shared().
3122 * WebKit2.xcodeproj/project.pbxproj:
3123 Add WebDatabaseManager.cpp/.h/Mac.cpp
3124 * win/WebKit2.vcproj:
3125 Add WebDatabaseManager.cpp/.h/Win.cpp
3127 2010-12-06 Darin Adler <darin@apple.com>
3129 Reviewed by Sam Weinig.
3131 Pass security origin to make local file decision correctly
3132 https://bugs.webkit.org/show_bug.cgi?id=48603
3134 * WebProcess/Plugins/PluginView.cpp:
3135 (WebKit::PluginView::loadURL): Pass security origin.
3136 * WebProcess/WebCoreSupport/WebFrameLoaderClient.cpp:
3137 (WebKit::WebFrameLoaderClient::dispatchCreatePage): Ditto.
3139 2010-12-06 Simon Fraser <simon.fraser@apple.com>
3141 Reviewed by Sam Weinig.
3143 Fix two WebKit2 prefs issues.
3145 * Shared/WebPreferencesStore.h: Include font-family preferences
3146 in the FOR_EACH_WEBKIT_STRING_PREFERENCE macro, actually propagating
3147 font family prefs to WebCore settings.
3149 * UIProcess/WebPageGroup.cpp:
3150 (WebKit::WebPageGroup::WebPageGroup):
3151 (WebKit::WebPageGroup::~WebPageGroup): Add and remove the WebPageGroup
3152 from the preference object it creates. This allows preference changes
3153 to actually be propagated to the web process.
3155 2010-12-06 Anders Carlsson <andersca@apple.com>
3157 Reviewed by Sam Weinig.
3159 The plug-in process crashes if it can't load the plug-in module
3160 https://bugs.webkit.org/show_bug.cgi?id=50601
3161 <rdar://problem/8692654>
3163 * PluginProcess/PluginControllerProxy.cpp:
3164 (WebKit::PluginControllerProxy::initialize):
3165 Handle m_plugin being 0.
3167 * PluginProcess/PluginProcess.cpp:
3168 (WebKit::PluginProcess::netscapePluginModule):
3169 Create the plug-in module if it doesn't exist.
3171 (WebKit::PluginProcess::initialize):
3172 Store the plug-in path.
3174 * PluginProcess/PluginProcess.h:
3175 * WebProcess/Plugins/Netscape/NetscapePlugin.cpp:
3176 (WebKit::NetscapePlugin::create):
3177 Return null if the plug-in module doesn't exist.
3179 * WebProcess/Plugins/Netscape/NetscapePlugin.h:
3180 * WebProcess/WebPage/WebPage.cpp:
3181 (WebKit::WebPage::createPlugin):
3184 2010-12-06 Anders Carlsson <andersca@apple.com>
3186 Reviewed by Sam Weinig.
3188 WebProcess crash in NPRemoteObjectMap::invalidate when closing tab
3189 https://bugs.webkit.org/show_bug.cgi?id=50597
3190 <rdar://problem/8655584>
3192 When invalidating the NPRemoteObjectMap, we don't want NPObjectMessageReceiver to
3193 release all objects NPObjects blindly because NPJSObjects have already been deallocated by the plug-in view.
3195 This is not an ideal solution; an ideal solution would involve NPJSObjects notifying any NPObjectMessageReceiver objects
3196 that the NPJSObject is being destroyed. The NPObjectMessageReceiver could then simply null out the NPObject pointer.
3198 * Shared/Plugins/NPObjectMessageReceiver.cpp:
3199 (WebKit::NPObjectMessageReceiver::NPObjectMessageReceiver):
3200 (WebKit::NPObjectMessageReceiver::~NPObjectMessageReceiver):
3201 * Shared/Plugins/NPObjectMessageReceiver.h:
3202 * Shared/Plugins/NPRemoteObjectMap.cpp:
3203 (WebKit::NPRemoteObjectMap::NPRemoteObjectMap):
3204 (WebKit::NPRemoteObjectMap::invalidate):
3205 * Shared/Plugins/NPRemoteObjectMap.h:
3206 (WebKit::NPRemoteObjectMap::isInvalidating):
3208 2010-12-06 Sam Weinig <sam@webkit.org>
3210 Reviewed by Anders Carlsson.
3212 Generalize didChangeLocationWithinPageForFrame for all same document navigations
3213 https://bugs.webkit.org/show_bug.cgi?id=50584
3215 - Rename didChangeLocationWithinPageForFrame callbacks to didSameDocumentNavigationForFrame
3216 - Add WKSameDocumentNavigationType to didChangeLocationWithinPageForFrame.
3217 - Call didSameDocumentNavigationForFrame for HTML session state changes.
3219 * Shared/API/c/WKPageLoadTypes.h: Added.
3220 * Shared/API/c/WKSharedAPICast.h:
3222 Moved WKFrameNavigationType here from WKPage.h and add WKSameDocumentNavigationType.
3224 * Shared/SameDocumentNavigationType.h: Added.
3225 * UIProcess/API/C/WKAPICast.h:
3226 Moved WKFrameNavigationType conversion from here.
3228 * UIProcess/API/C/WKPage.h:
3229 * UIProcess/API/qt/qwkpage.cpp:
3233 * UIProcess/WebFrameProxy.cpp:
3234 (WebKit::WebFrameProxy::didSameDocumentNavigation):
3235 * UIProcess/WebFrameProxy.h:
3236 * UIProcess/WebLoaderClient.cpp:
3237 (WebKit::WebLoaderClient::didSameDocumentNavigationForFrame):
3238 * UIProcess/WebLoaderClient.h:
3239 * UIProcess/WebPageProxy.cpp:
3240 (WebKit::WebPageProxy::didSameDocumentNavigationForFrame):
3241 * UIProcess/WebPageProxy.h:
3242 * UIProcess/WebPageProxy.messages.in:
3243 * WebProcess/InjectedBundle/API/c/WKBundlePage.h:
3244 * WebProcess/InjectedBundle/InjectedBundlePageLoaderClient.cpp:
3245 (WebKit::InjectedBundlePageLoaderClient::didSameDocumentNavigationForFrame):
3246 * WebProcess/InjectedBundle/InjectedBundlePageLoaderClient.h:
3247 Pipe new name through.
3249 * WebProcess/WebCoreSupport/WebFrameLoaderClient.cpp:
3250 (WebKit::WebFrameLoaderClient::dispatchDidChangeLocationWithinPage):
3251 (WebKit::WebFrameLoaderClient::dispatchDidPushStateWithinPage):
3252 (WebKit::WebFrameLoaderClient::dispatchDidReplaceStateWithinPage):
3253 (WebKit::WebFrameLoaderClient::dispatchDidPopStateWithinPage):
3254 Call didChangeLocationWithinPageForFrame for session state changes.
3257 * WebKit2.xcodeproj/project.pbxproj:
3258 * win/WebKit2.vcproj:
3259 * win/WebKit2Generated.make:
3262 2010-12-06 Jessie Berlin <jberlin@apple.com>
3264 Reviewed by Dan Bernstein.
3266 WebKit2: Expose the preference to enable or disable HTML5 Databases.
3267 https://bugs.webkit.org/show_bug.cgi?id=50411
3269 * Shared/WebPreferencesStore.h:
3270 Make the preference to enable HTML5 Databases default ot true.
3272 * UIProcess/API/C/WKPreferences.cpp:
3273 (WKPreferencesSetDatabasesEnabled):
3274 (WKPreferencesGetDatabasesEnabled):
3275 * UIProcess/API/C/WKPreferences.h:
3277 * WebProcess/WebPage/WebPage.cpp:
3278 (WebKit::WebPage::updatePreferences):
3279 Set AbstractDatabase::isAvailable (mimicking how the preference is set in WebKit1).
3281 2010-12-06 Mark Rowe <mrowe@apple.com>
3285 * WebProcess/Plugins/Netscape/mac/NetscapePluginMac.mm:
3286 (WebKit::NetscapePlugin::platformHandleKeyboardEvent): Wrap Carbon-specific code in #ifndef NP_NO_CARBON.
3288 2010-12-06 Anders Carlsson <andersca@apple.com>
3290 Reviewed by Adam Roben.
3292 Add a shim for GetCurrentEventButtonState
3293 https://bugs.webkit.org/show_bug.cgi?id=50583
3295 * PluginProcess/mac/PluginProcessMac.mm:
3296 (WebKit::getCurrentEventButtonState):
3297 Get the event button state from the plug-in.
3299 (WebKit::PluginProcess::initializeShim):
3300 Add new shim callback.
3302 * PluginProcess/mac/PluginProcessShim.cpp:
3303 (WebKit::shimGetCurrentEventButtonState):
3306 * PluginProcess/mac/PluginProcessShim.h:
3307 * WebProcess/Plugins/Netscape/NetscapePlugin.h:
3308 * WebProcess/Plugins/Netscape/mac/NetscapePluginMac.mm:
3309 (WebKit::NetscapePlugin::buttonState):
3310 Return the button state.
3312 (WebKit::NetscapePlugin::platformHandleMouseEvent):
3313 Update the button state. Also, make sure to actually pass the modifiers to NPP_HandleEvent.
3316 2010-12-06 Anders Carlsson <andersca@apple.com>
3318 Reviewed by Adam Roben.
3320 Add a shim for IsWindowActive
3321 https://bugs.webkit.org/show_bug.cgi?id=50582
3323 * PluginProcess/mac/PluginProcessMac.mm:
3324 (WebKit::isWindowActive):
3325 Get the NetscapePlugin from the WindowRef and check if the plug-in's window is active.
3327 (WebKit::PluginProcess::initializeShim):
3328 * PluginProcess/mac/PluginProcessShim.cpp
3329 (WebKit::shimIsWindowActive):
3330 Call isWindowActive. If it returns true, return the result value. Otherwise, call the real
3331 IsWindowActive function.
3333 * PluginProcess/mac/PluginProcessShim.h:
3334 * WebProcess/Plugins/Netscape/NetscapePlugin.cpp:
3335 (WebKit::NetscapePlugin::NetscapePlugin):
3336 Initialize m_isWindowactive.
3338 * WebProcess/Plugins/Netscape/NetscapePlugin.h:
3339 (WebKit::NetscapePlugin::isWindowActive):
3340 Return whether the window is active.
3342 * WebProcess/Plugins/Netscape/mac/NetscapePluginMac.mm:
3343 (WebKit::windowMap):
3344 (WebKit::NetscapePlugin::platformPostInitialize):
3345 (WebKit::NetscapePlugin::platformDestroy):
3346 (WebKit::NetscapePlugin::netscapePluginFromWindow):
3347 Add a mapping between windows and the corresponding NetscapePlugin objects.
3349 (WebKit::NetscapePlugin::windowFocusChanged):
3350 Update the window focus member variable.
3352 2010-12-06 Anders Carlsson <andersca@apple.com>
3354 Reviewed by Dan Bernstein.
3356 REGERSSION (r73310?): Contents of <select> popup menus are upside-down on Windows
3357 https://bugs.webkit.org/show_bug.cgi?id=50544
3358 <rdar://problem/8732336>
3360 * Shared/BackingStore.cpp:
3361 * Shared/BackingStore.h:
3362 * Shared/cairo/BackingStoreCairo.cpp:
3363 Remove BackingStore::createFlippedGraphicsContext.
3365 * WebProcess/WebCoreSupport/win/WebPopupMenuWin.cpp:
3366 (WebKit::WebPopupMenu::setUpPlatformData):
3367 Don't create a flipped graphics context.
3369 2010-12-06 Anders Carlsson <andersca@apple.com>
3371 Reviewed by Dan Bernstein.
3373 REGRESSION: Text in Find indicator is vertically flipped
3374 https://bugs.webkit.org/show_bug.cgi?id=50524
3375 <rdar://problem/8732978>
3377 Don't flip the graphics context.
3379 * UIProcess/FindIndicator.cpp:
3380 (WebKit::FindIndicator::draw):
3382 2010-12-03 Anders Carlsson <andersca@apple.com>
3384 Reviewed by Sam Weinig.
3386 Dispatch keyboard events in the Carbon event model
3387 https://bugs.webkit.org/show_bug.cgi?id=50503
3389 * Shared/WebEvent.h:
3390 (WebKit::WebKeyboardEvent::macCharCode):
3391 * Shared/WebKeyboardEvent.cpp:
3392 (WebKit::WebKeyboardEvent::WebKeyboardEvent):
3393 (WebKit::WebKeyboardEvent::encode):
3394 (WebKit::WebKeyboardEvent::decode):
3395 Add macCharCode field.
3397 * Shared/mac/WebEventFactory.mm:
3398 (WebKit::WebEventFactory::createWebKeyboardEvent):
3399 * Shared/qt/WebEventFactoryQt.cpp:
3400 (WebKit::WebEventFactory::createWebKeyboardEvent):
3401 * Shared/win/WebEventFactory.cpp:
3402 (WebKit::WebEventFactory::createWebKeyboardEvent):
3403 Pass along the Mac char code.
3405 * WebProcess/Plugins/Netscape/mac/NetscapePluginMac.mm:
3406 (WebKit::NetscapePlugin::platformHandleKeyboardEvent):
3407 Convert the event to a Carobn event.
3409 2010-12-03 John Sullivan <sullivan@apple.com>
3411 Reviewed by Adam Roben.
3413 https://bugs.webkit.org/show_bug.cgi?id=50504
3414 Expose some more WebCore settings in WebKit2 preferences
3416 * Shared/WebPreferencesStore.h:
3417 Changed name of existing FOR_EACH_WEBKIT_STRING_PREFERENCE macro to
3418 FOR_EACH_WEBKIT_FONT_FAMILY_PREFERENCE since it was all about platform-specific
3419 font families, and I'm now introducing a non-platform-spacific string, and
3420 I didn't want to put the new preference in two platform-specific lists. Then
3421 added a new FOR_EACH_WEBKIT_STRING_PREFERENCE to hold the new preference. Note
3422 that the other preferences exposed in this patch were already declared here.
3424 * UIProcess/API/C/WKPreferences.cpp:
3425 (WKPreferencesSetDefaultFontSize):
3427 (WKPreferencesGetDefaultFontSize):
3429 (WKPreferencesSetDefaultFixedFontSize):
3431 (WKPreferencesGetDefaultFixedFontSize):
3433 (WKPreferencesSetDefaultTextEncodingName):
3435 (WKPreferencesCopyDefaultTextEncodingName):
3438 * UIProcess/API/C/WKPreferences.h:
3439 Declare new wrappers.
3441 2010-12-05 Adam Roben <aroben@apple.com>
3443 Windows production build fix
3445 Put spaces after trailing backslashes when setting
3446 %WebKitVSPropsRedirectionDir%. According to MSDN
3447 <http://msdn.microsoft.com/en-us/library/2kzfk8c7(v=VS.80).aspx>:
3449 A backslash ( \ ) followed by a newline character is interpreted as
3450 a space in the command; use a backslash at the end of a line to
3451 continue a command onto the next line. NMAKE interprets the
3452 backslash literally if any other character, including a space or
3453 tab, follows the backslash.
3457 2010-12-04 Sam Weinig <sam@webkit.org>
3459 Reviewed by Jon Honeycutt.
3461 WebKit2: Need client functions to notify app when the url changes due to a fragment navigation
3462 https://bugs.webkit.org/show_bug.cgi?id=50511
3464 Pipe didChangeLocationWithinPageForFrame up through the UIProcess to the WKPageLoadClient,
3465 updating the WebFrameProxy's URL on the way.
3467 Test: PageLoadDidChangeLocationWithinPageForFrame
3469 * UIProcess/API/C/WKPage.h:
3470 * UIProcess/API/qt/qwkpage.cpp:
3472 * UIProcess/WebFrameProxy.cpp:
3473 (WebKit::WebFrameProxy::didChangeURLWithoutNavigation):
3474 * UIProcess/WebFrameProxy.h:
3475 * UIProcess/WebLoaderClient.cpp:
3476 (WebKit::WebLoaderClient::didChangeLocationWithinPageForFrame):
3477 * UIProcess/WebLoaderClient.h:
3478 * UIProcess/WebPageProxy.cpp:
3479 (WebKit::WebPageProxy::didChangeLocationWithinPageForFrame):
3480 * UIProcess/WebPageProxy.h:
3481 * UIProcess/WebPageProxy.messages.in:
3482 * WebProcess/InjectedBundle/API/c/WKBundlePage.h:
3483 * WebProcess/InjectedBundle/InjectedBundlePageLoaderClient.cpp:
3484 (WebKit::InjectedBundlePageLoaderClient::didChangeLocationWithinPageForFrame):
3485 (WebKit::InjectedBundlePageLoaderClient::didDisplayInsecureContentForFrame):
3486 (WebKit::InjectedBundlePageLoaderClient::didRunInsecureContentForFrame):
3487 * WebProcess/InjectedBundle/InjectedBundlePageLoaderClient.h:
3488 * WebProcess/WebCoreSupport/WebFrameLoaderClient.cpp:
3489 (WebKit::WebFrameLoaderClient::dispatchDidCancelClientRedirect): Fix typo.
3490 (WebKit::WebFrameLoaderClient::dispatchDidChangeLocationWithinPage):
3492 2010-12-03 Timothy Hatcher <timothy@apple.com>
3494 Make the Web Inspector window show and be usable on Mac.
3496 https://webkit.org/b/50490
3498 Reviewed by Sam Weinig.
3500 * UIProcess/WebInspectorProxy.cpp:
3501 (WebKit::WebInspectorProxy::invalidate): Call platformClose.
3502 (WebKit::WebInspectorProxy::didLoadInspectorPage): Call platformOpen.
3503 (WebKit::WebInspectorProxy::didClose): Call platformClose.
3504 * UIProcess/WebInspectorProxy.h:
3505 * UIProcess/WebInspectorProxy.messages.in: Added DidClose.
3506 * UIProcess/mac/WebInspectorProxyMac.mm:
3507 (-[WebInspectorProxyObjCAdapter initWithWebInspectorProxy:]): Added.
3508 (-[WebInspectorProxyObjCAdapter windowWillClose:]): Added. Call WebInspectorProxy::close.
3509 (WebKit::WebInspectorProxy::platformOpen): Added.
3510 (WebKit::WebInspectorProxy::platformClose): Added.
3511 * UIProcess/qt/WebInspectorProxyQt.cpp:
3512 (WebKit::WebInspectorProxy::platformOpen): Added stub.
3513 (WebKit::WebInspectorProxy::platformClose): Added stub.
3514 * UIProcess/win/WebInspectorProxyWin.cpp:
3515 (WebKit::WebInspectorProxy::platformOpen): Added stub.
3516 (WebKit::WebInspectorProxy::platformClose): Added stub.
3517 * WebProcess/WebCoreSupport/WebInspectorClient.cpp:
3518 (WebKit::WebInspectorClient::sendMessageToFrontend): Added more null checks to avoid a crash.
3519 * WebProcess/WebCoreSupport/WebInspectorFrontendClient.cpp:
3520 (WebKit::WebInspectorFrontendClient::closeWindow): Call WebInspector::didClose.
3521 (WebKit::WebInspectorFrontendClient::disconnectFromBackend): Ditto.
3522 (WebKit::WebInspectorFrontendClient::sendMessageToBackend): Removed. This does not need to be
3523 implemented by our subclass since we are in a single process.
3524 * WebProcess/WebCoreSupport/WebInspectorFrontendClient.h: Removed sendMessageToBackend.
3525 * WebProcess/WebPage/WebInspector.cpp:
3526 (WebKit::WebInspector::didClose): Added. Send a DidClose message to the UI process.
3527 * WebProcess/WebPage/WebInspector.h:
3529 2010-12-03 Anders Carlsson <andersca@apple.com>
3531 Reviewed by Sam Weinig and Dan Bernstein.
3533 Clean up the BackingStore implementation
3534 https://bugs.webkit.org/show_bug.cgi?id=50498
3536 * Shared/BackingStore.cpp:
3537 (WebKit::BackingStore::create):
3538 (WebKit::BackingStore::createSharable):
3539 (WebKit::BackingStore::resize):
3540 Use new numBytesForSize helper function.
3542 (WebKit::BackingStore::createFlippedGraphicsContext):
3543 Make this function platform independent.
3545 * Shared/BackingStore.h:
3546 (WebKit::BackingStore::numBytesForSize):
3547 Given a size, return the number of bytes needed for it.
3549 (WebKit::BackingStore::sizeInBytes):
3552 * Shared/cg/BackingStoreCG.cpp:
3553 (WebKit::BackingStore::paint):
3554 Don't use CGBitmapContextCreateImage; it creates an extra copy of the image data.
3556 * Shared/qt/BackingStoreQt.cpp:
3557 Remove createFlippedGraphicsContext.
3559 2010-12-03 Siddharth Mathur <siddharth.mathur@nokia.com>
3561 Reviewed by Laszlo Gombos.
3563 [Qt] [WK2] Build system improvements for non-Unix targets
3564 https://bugs.webkit.org/show_bug.cgi?id=50257
3566 * DerivedSources.pro:
3567 Fix dir seperator errors on Windows build host. Thanks to Laszlo Gombos.
3569 2010-12-03 Sam Weinig <sam@webkit.org>
3571 Reviewed by Maciej Stachowiak.
3573 Enable <a ping> for Mac/Windows/WebKit2 builds
3574 <rdar://problem/8504473>
3575 https://bugs.webkit.org/show_bug.cgi?id=50488
3577 * Shared/WebPreferencesStore.h:
3578 * UIProcess/API/C/WKPreferences.cpp:
3579 (WKPreferencesSetHyperlinkAuditingEnabled):
3580 (WKPreferencesGetHyperlinkAuditingEnabled):
3581 * UIProcess/API/C/WKPreferences.h:
3582 Add "HyperlinkAuditing" preference and enabled it by default.
3584 2010-12-03 Brady Eidson <beidson@apple.com>
3586 Reviewed by good sense in fixing builds.
3588 Export the 4 new API headers I added today.
3590 * WebKit2.xcodeproj/project.pbxproj:
3592 2010-12-03 Brady Eidson <beidson@apple.com>
3594 Reviewed by Sam Weinig.
3596 <rdar://problem/8725679> and https://bugs.webkit.org/show_bug.cgi?id=50482
3597 Crash trying to empty caches with no WebProcess.
3599 * Shared/WebProcessCreationParameters.h: Add the "clear this cache" flags.
3601 * UIProcess/WebContext.cpp:
3602 (WebKit::WebContext::WebContext):
3603 (WebKit::WebContext::ensureWebProcess): If either of the clear cache flags are set when a new WebProcess is
3604 created, include those flags in the parameters.
3605 (WebKit::WebContext::clearResourceCaches): If the current process isn't valid, flag this action to be done later.
3606 (WebKit::WebContext::clearApplicationCache): Ditto.
3607 * UIProcess/WebContext.h:
3609 * WebProcess/WebProcess.cpp:
3610 (WebKit::WebProcess::initializeWebProcess): Clear the caches if told to.
3612 2010-12-03 Sam Weinig <sam@webkit.org>
3614 Reviewed by Gavin Barraclough.
3616 Fix failing API test. The default san serif font on the mac
3617 should be Helvetica, not Courier.
3619 * Shared/WebPreferencesStore.h:
3621 2010-12-03 Jia Pu <jpu@apple.com>
3623 Reviewed by Darin Adler.
3625 Need to move all code that applies correction into correction panel callback.
3626 https://bugs.webkit.org/show_bug.cgi?id=50426
3627 <rdar://problem/8720832>
3629 Adopted new signature of dismissCorrectionPanel.
3631 * WebProcess/WebCoreSupport/WebEditorClient.h:
3632 * WebProcess/WebCoreSupport/mac/WebEditorClientMac.mm:
3633 (WebKit::WebEditorClient::dismissCorrectionPanel):
3635 2010-12-03 Jessie Berlin <jberlin@apple.com>
3637 Windows build fix. Unreviewed.
3639 * win/WebKit2Generated.make:
3640 Add the new API files from http://trac.webkit.org/changeset/73281.
3642 2010-12-03 Brady Eidson <beidson@apple.com>
3644 Reviewed by Anders Carlsson.
3646 Groundwork for <rdar://problem/7660733> and https://bugs.webkit.org/show_bug.cgi?id=50191
3647 WebKit2 Authentication Support
3649 With this patch in place, authentication challenges are sent up from WebCore and shipped over the IPC layer.
3650 Client apps can implement the related client methods to attempt to continue without credentials or cancel a
3653 There's not yet API to inspect a challenge or create a credential to use in reply - that will come later.
3655 Build-system changes:
3656 * DerivedSources.make:
3657 * DerivedSources.pro:
3659 * WebKit2.xcodeproj/project.pbxproj:
3660 * win/WebKit2.vcproj:
3661 * win/WebKit2Common.vsprops:
3663 Messages and casts for IPC and APIs:
3664 * Platform/CoreIPC/MessageID.h:
3665 * Shared/API/c/WKBase.h:
3666 * Shared/APIObject.h:
3667 * Shared/WebCoreArgumentCoders.h:
3668 * UIProcess/API/C/WKAPICast.h:
3669 * WebProcess/WebProcess.cpp:
3670 (WebKit::WebProcess::didReceiveMessage):
3672 Stub out the AuthenticationChallenge class family:
3673 * UIProcess/API/C/WKAuthenticationChallenge.cpp: Added.
3674 (WKAuthenticationChallengeGetTypeID):
3675 * UIProcess/API/C/WKAuthenticationChallenge.h: Added.
3676 * UIProcess/API/C/WKCredential.cpp: Added.
3677 (WKCredentialGetTypeID):
3678 * UIProcess/API/C/WKCredential.h: Added.
3679 * UIProcess/API/C/WKProtectionSpace.cpp: Added.
3680 (WKProtectionSpaceGetTypeID):
3681 * UIProcess/API/C/WKProtectionSpace.h: Added.
3683 Add an Authentication listener for the client app to respond to:
3684 * UIProcess/API/C/WKAuthenticationDecisionListener.cpp: Added.
3685 (WKAuthenticationDecisionListenerGetTypeID):
3686 (WKAuthenticationDecisionListenerUseCredential):
3687 (WKAuthenticationDecisionListenerCancel):
3688 * UIProcess/API/C/WKAuthenticationDecisionListener.h: Added.
3690 Add Authentication related methods to the page loader client:
3691 * UIProcess/API/C/WKPage.h:
3693 Add empty implementations of the new API objects:
3694 * UIProcess/Authentication: Added.
3695 * UIProcess/Authentication/AuthenticationChallengeProxy.cpp: Added.
3696 (WebKit::AuthenticationChallengeProxy::AuthenticationChallengeProxy):
3697 (WebKit::AuthenticationChallengeProxy::~AuthenticationChallengeProxy):
3698 (WebKit::AuthenticationChallengeProxy::useCredential):
3699 (WebKit::AuthenticationChallengeProxy::cancel):
3700 * UIProcess/Authentication/AuthenticationChallengeProxy.h: Added.
3701 (WebKit::AuthenticationChallengeProxy::create):
3702 (WebKit::AuthenticationChallengeProxy::listener):
3703 (WebKit::AuthenticationChallengeProxy::type):
3705 * UIProcess/Authentication/WebCredential.cpp: Added.
3706 (WebKit::WebCredential::core):
3707 * UIProcess/Authentication/WebCredential.h: Added.
3708 (WebKit::WebCredential::create):
3709 (WebKit::WebCredential::type):
3710 * UIProcess/Authentication/WebProtectionSpace.cpp: Added.
3711 (WebKit::WebProtectionSpace::WebProtectionSpace):
3712 * UIProcess/Authentication/WebProtectionSpace.h: Added.
3713 (WebKit::WebProtectionSpace::create):
3714 (WebKit::WebProtectionSpace::type):
3716 Add implementation of the Authentication decision listener:
3717 * UIProcess/Authentication/AuthenticationDecisionListener.cpp: Added.
3718 (WebKit::AuthenticationDecisionListener::AuthenticationDecisionListener):
3719 (WebKit::AuthenticationDecisionListener::useCredential):
3720 (WebKit::AuthenticationDecisionListener::cancel):
3721 (WebKit::AuthenticationDecisionListener::detachChallenge):
3722 * UIProcess/Authentication/AuthenticationDecisionListener.h: Added.
3723 (WebKit::AuthenticationDecisionListener::create):
3724 (WebKit::AuthenticationDecisionListener::type):
3726 WebPage and PageLoaderClient glue:
3727 * UIProcess/WebLoaderClient.cpp:
3728 (WebKit::WebLoaderClient::canAuthenticateAgainstProtectionSpaceInFrame):
3729 (WebKit::WebLoaderClient::didReceiveAuthenticationChallengeInFrame):
3730 * UIProcess/WebLoaderClient.h:
3731 * UIProcess/WebPageProxy.cpp:
3732 (WebKit::WebPageProxy::canAuthenticateAgainstProtectionSpaceInFrame):
3733 (WebKit::WebPageProxy::didReceiveAuthenticationChallenge):
3734 * UIProcess/WebPageProxy.h:
3735 * UIProcess/WebPageProxy.messages.in:
3737 Add a manager to map the actual platform authentication challenges to a challenge ID,
3738 as at least some platforms require the object identity to persist:
3739 * WebProcess/Authentication: Added.
3740 * WebProcess/Authentication/AuthenticationManager.cpp: Added.
3741 (WebKit::generateAuthenticationChallengeID):
3742 (WebKit::AuthenticationManager::shared):
3743 (WebKit::AuthenticationManager::AuthenticationManager):
3744 (WebKit::AuthenticationManager::didReceiveMessage):
3745 (WebKit::AuthenticationManager::didReceiveAuthenticationChallenge):
3746 (WebKit::AuthenticationManager::useCredentialForChallenge):
3747 (WebKit::AuthenticationManager::continueWithoutCredentialForChallenge):
3748 (WebKit::AuthenticationManager::cancelChallenge):
3749 * WebProcess/Authentication/AuthenticationManager.h: Added.
3750 * WebProcess/Authentication/AuthenticationManager.messages.in: Added.
3752 Hand off Authentication challenges to the manager to be sent over IPC:
3753 * WebProcess/WebCoreSupport/WebFrameLoaderClient.cpp:
3754 (WebKit::WebFrameLoaderClient::dispatchDidReceiveAuthenticationChallenge):
3755 (WebKit::WebFrameLoaderClient::canAuthenticateAgainstProtectionSpace):
3757 * UIProcess/API/qt/qwkpage.cpp:
3759 2010-12-03 Anders Carlsson <andersca@apple.com>
3761 Reviewed by Dan Bernstein.
3763 Flip the destination context when painting a backing store into the destination
3764 https://bugs.webkit.org/show_bug.cgi?id=50491
3766 * Shared/cg/BackingStoreCG.cpp:
3767 (WebKit::BackingStore::paint):
3769 2010-12-03 Anders Carlsson <andersca@apple.com>
3771 Reviewed by Dan Bernstein.
3773 The chunked update drawing area is flipped twice when drawing
3774 https://bugs.webkit.org/show_bug.cgi?id=50465
3775 <rdar://problem/8726836>
3777 * UIProcess/mac/ChunkedUpdateDrawingAreaProxyMac.mm:
3778 (WebKit::ChunkedUpdateDrawingAreaProxy::platformPaint):
3779 (WebKit::ChunkedUpdateDrawingAreaProxy::drawUpdateChunkIntoBackingStore):
3780 Flip the destination contexts, thus unflipping them. (Turns out two wrongs make a right here).
3782 2010-12-03 Jessie Berlin <jberlin@apple.com>
3784 Reviewed by Sam Weinig.
3786 Need a WebKit2 Equivalent of WebSecurityOrigin
3787 https://bugs.webkit.org/show_bug.cgi?id=50170
3789 * Shared/API/c/WKBase.h:
3790 Add the WKSecurityOriginRef typedef.
3792 * Shared/APIObject.h:
3793 Add the SecurityOrigin type as a Shared type.
3795 * Shared/API/c/WKSharedAPICast.h::
3796 Add the mapping between WKSecurityOriginRef and WebSecurityOrigin.
3798 * UIProcess/API/C/WKSecurityOrigin.cpp: Added.
3799 (WKSecurityOriginGetTypeID):
3800 (WKSecurityOriginCreate):
3801 (WKSecurityOriginGetProtocol):
3802 (WKSecurityOriginGetHost):
3803 (WKSecurityOriginGetPort):
3804 * UIProcess/API/C/WKSecurityOrigin.h: Added.
3806 * UIProcess/WebSecurityOrigin.h: Added.
3807 (WebKit::WebSecurityOrigin::create):
3808 Create based on the database identifier, which contains the protocol, host and port.
3809 (WebKit::WebSecurityOrigin::protocol):
3810 (WebKit::WebSecurityOrigin::host):
3811 (WebKit::WebSecurityOrigin::port):
3812 (WebKit::WebSecurityOrigin::databaseIdentifier):
3813 (WebKit::WebSecurityOrigin::WebSecurityOrigin):
3814 (WebKit::WebSecurityOrigin::type):
3817 Add WKSecurityOrigin.cpp/.h.
3819 * WebKit2.xcodeproj/project.pbxproj:
3820 * win/WebKit2.vcproj:
3821 Add the WebSecurityOrigin.h and WKSecurityOrigin.cpp/.h.
3823 * win/WebKit2Generated.make:
3824 Make sure WKSecurityOrigin.h file gets copied over to the WebKitBuild directory on Windows.
3826 2010-12-02 Laszlo Gombos <laszlo.1.gombos@nokia.com>
3828 Reviewed by Csaba Osztrogonác.
3830 [Qt] Fix compilation with !ENABLE(OFFLINE_WEB_APPLICATIONS) and
3831 !ENABLE(TILED_BACKING_STORE) for WebKit2
3832 https://bugs.webkit.org/show_bug.cgi?id=50071
3834 Add appropriate guards. No functional change if guards are set.
3836 * UIProcess/API/qt/qwkpage.cpp:
3837 (QWKPage::setActualVisibleContentsRect):
3838 * UIProcess/TiledDrawingAreaProxy.cpp:
3839 * UIProcess/qt/TiledDrawingAreaProxyQt.cpp:
3840 * UIProcess/qt/TiledDrawingAreaTileQt.cpp:
3841 * UIProcess/qt/WebContextQt.cpp:
3842 (WebKit::WebContext::applicationCacheDirectory):
3843 * WebProcess/WebProcess.cpp:
3844 (WebKit::WebProcess::initializeWebProcess):
3846 2010-12-02 Sam Weinig <sam@webkit.org>
3850 * UIProcess/API/qt/qwkpreferences.cpp:
3851 (QWKPreferencesPrivate::createPreferences):
3853 2010-12-02 Sam Weinig <sam@webkit.org>
3855 Reviewed by Anders Carlsson.
3857 WebKit2 Preferences should be held off the PageGroup, not the Context
3858 https://bugs.webkit.org/show_bug.cgi?id=50414
3860 - In addition, this now makes the preference held off the PageGroup have
3861 the identifier of the PageGroup and autosave to disk (only on the mac
3863 - Adds ability to create an arbitrary preference that can be autosaved
3864 via a new WKPreferencesCreateWithIdentifier function.
3866 * UIProcess/API/C/WKContext.cpp:
3867 * UIProcess/API/C/WKContext.h:
3868 Remove preference related code.
3870 * UIProcess/API/C/WKPageGroup.cpp:
3871 (WKPageGroupSetPreferences):
3872 (WKPageGroupGetPreferences):
3873 * UIProcess/API/C/WKPageGroup.h:
3874 Add getter/setter for preferences.
3876 * UIProcess/API/C/WKPreferences.cpp:
3877 (WKPreferencesCreateWithIdentifier):
3878 * UIProcess/API/C/WKPreferences.h:
3879 Add WKPreferencesCreateWithIdentifier and remove WKPreferencesCreateCopy which is
3882 * UIProcess/WebContext.cpp:
3883 (WebKit::WebContext::WebContext):
3884 (WebKit::WebContext::~WebContext):
3885 * UIProcess/WebContext.h:
3886 Remove preference related code.
3888 * UIProcess/WebPageGroup.cpp:
3889 (WebKit::WebPageGroup::WebPageGroup):
3890 (WebKit::WebPageGroup::addPage):
3891 (WebKit::WebPageGroup::removePage):
3892 (WebKit::WebPageGroup::setPreferences):
3893 (WebKit::WebPageGroup::preferences):
3894 (WebKit::WebPageGroup::preferencesDidChange):
3895 * UIProcess/WebPageGroup.h:
3896 Add preference and page tracking.
3898 * UIProcess/WebPageNamespace.cpp:
3899 * UIProcess/WebPageNamespace.h:
3900 Remove preference change notification code.
3902 * UIProcess/WebPageProxy.cpp:
3903 (WebKit::WebPageProxy::WebPageProxy):
3904 (WebKit::WebPageProxy::~WebPageProxy):
3905 Add/remove self from page group set.
3907 (WebKit::WebPageProxy::preferencesDidChange):
3908 (WebKit::WebPageProxy::creationParameters):
3909 Get preferences from the pageGroup.
3911 * UIProcess/WebPreferences.cpp:
3912 (WebKit::WebPreferences::WebPreferences):
3913 (WebKit::WebPreferences::addPageGroup):
3914 (WebKit::WebPreferences::removePageGroup):
3915 (WebKit::WebPreferences::update):
3916 * UIProcess/WebPreferences.h:
3917 (WebKit::WebPreferences::create):
3918 Change to track page groups instead of contexts.
3920 * UIProcess/mac/WebPreferencesMac.mm:
3921 (WebKit::makeKey): Add ".WebKit2" prefix for keys.
3923 2010-12-02 Anders Carlsson <andersca@apple.com>
3925 Reviewed by Sam Weinig.
3927 Flash videos on YouTube flicker
3928 https://bugs.webkit.org/show_bug.cgi?id=50409
3929 <rdar://problem/8668757>
3931 When painting from a backing store, we need to add the source location
3932 to the destination point.
3934 * WebProcess/Plugins/PluginProxy.cpp:
3935 (WebKit::PluginProxy::paint):
3936 (WebKit::PluginProxy::update):
3938 2010-12-02 Sam Weinig <sam@webkit.org>
3940 Reviewed by Anders Carlsson.
3942 WebKit2 needs API to turn on popup blocking
3943 https://bugs.webkit.org/show_bug.cgi?id=50407
3945 Pipe-through a preference for javascript being able to open
3946 windows without user gesture.
3948 * Shared/WebPreferencesStore.h:
3949 * UIProcess/API/C/WKPreferences.cpp:
3950 (WKPreferencesSetJavaScriptCanOpenWindowsAutomatically):
3951 (WKPreferencesGetJavaScriptCanOpenWindowsAutomatically):
3952 * UIProcess/API/C/WKPreferences.h:
3953 * WebProcess/WebPage/WebPage.cpp:
3954 (WebKit::WebPage::updatePreferences):
3956 2010-12-02 Anders Carlsson <andersca@apple.com>
3958 Reviewed by Sam Weinig.
3960 Plug-ins should be able to update the mouse cursor
3961 https://bugs.webkit.org/show_bug.cgi?id=50399
3963 Call WKEnableSettingCursorWhenInBackground.
3965 * PluginProcess/mac/PluginProcessMainMac.mm:
3966 (WebKit::PluginProcessMain):
3968 2010-12-02 Sam Weinig <sam@webkit.org>
3970 Reviewed by Anders Carlsson.
3972 https://bugs.webkit.org/show_bug.cgi?id=50368
3973 Overhaul WebKit2 preferences code
3975 - Reduces the number of places you have to touch to add a new preference
3976 (From 9 down to 4, but with a bit of elbow grease, we should get that
3978 - Add hooks so that platforms can initialize the preferences based on an
3979 identifier. This is currently only used on the Mac to initialize a
3980 preference store from NSUserDefaults and autosave the changes to disk.
3981 It is not yet enabled due to no way to set the identifier from client
3984 * Shared/WebPageCreationParameters.cpp:
3985 Add necessary #include of WebCoreArgumentCoders.h which is now needed
3986 due to cleanup in WebPreferencesStore.h.
3988 * Shared/WebPreferencesStore.cpp:
3989 (WebKit::WebPreferencesStore::WebPreferencesStore):
3990 (WebKit::WebPreferencesStore::encode):
3991 (WebKit::WebPreferencesStore::decode):
3992 (WebKit::defaultValueForKey):
3993 (WebKit::setValueForKey):
3994 (WebKit::valueForKey):
3995 (WebKit::WebPreferencesStore::setStringValueForKey):
3996 (WebKit::WebPreferencesStore::getStringValueForKey):
3997 (WebKit::WebPreferencesStore::setBoolValueForKey):
3998 (WebKit::WebPreferencesStore::getBoolValueForKey):
3999 (WebKit::WebPreferencesStore::setUInt32ValueForKey):
4000 (WebKit::WebPreferencesStore::getUInt32ValueForKey):
4001 * Shared/WebPreferencesStore.h:
4002 Complete overhaul of this class to store the preferences as
4003 a set of HashMaps and use macros to define the keys and default
4006 * UIProcess/API/C/WKPreferences.cpp:
4007 (WKPreferencesGetFontSmoothingLevel):
4008 Add cast to keep conversion function working.
4010 * UIProcess/WebPreferences.cpp:
4011 (WebKit::WebPreferences::WebPreferences): Add identifier constructor.
4012 (WebKit::WebPreferences::updateStringValueForKey):
4013 (WebKit::WebPreferences::updateBoolValueForKey):
4014 (WebKit::WebPreferences::updateUInt32ValueForKey):
4015 Add type based updaters. These currently give hooks to the platform and
4016 call the generic update, but in the future, we can use this to optimize
4017 updating preferences to not send the entire store for each change.
4019 * UIProcess/WebPreferences.h:
4020 Generate the getters and setters via macro instantiation.
4022 * UIProcess/cf/WebPreferencesCF.cpp: Added.
4023 (WebKit::WebPreferences::platformInitializeStore):
4024 (WebKit::WebPreferences::platformUpdateStringValueForKey):
4025 (WebKit::WebPreferences::platformUpdateBoolValueForKey):
4026 (WebKit::WebPreferences::platformUpdateUInt32ValueForKey):
4029 * UIProcess/mac/WebPreferencesMac.mm: Added.
4031 (WebKit::setStringValueIfInUserDefaults):
4032 (WebKit::setBoolValueIfInUserDefaults):
4033 (WebKit::setUInt32ValueIfInUserDefaults):
4034 (WebKit::WebPreferences::platformInitializeStore):
4035 (WebKit::WebPreferences::platformUpdateStringValueForKey):
4036 (WebKit::WebPreferences::platformUpdateBoolValueForKey):
4037 (WebKit::WebPreferences::platformUpdateUInt32ValueForKey):
4038 Use the platform hooks to initialize and update the store from
4041 * UIProcess/qt/WebPreferencesQt.cpp: Added.
4042 (WebKit::WebPreferences::platformInitializeStore):
4043 (WebKit::WebPreferences::platformUpdateStringValueForKey):
4044 (WebKit::WebPreferences::platformUpdateBoolValueForKey):
4045 (WebKit::WebPreferences::platformUpdateUInt32ValueForKey):
4048 * WebProcess/WebPage/WebPage.cpp:
4049 (WebKit::WebPage::updatePreferences):
4050 * WebProcess/WebPage/win/WebPageWin.cpp:
4051 (WebKit::WebPage::platformPreferencesDidChange):
4052 Update to pull the value using the new type based getters.
4055 * WebKit2.xcodeproj/project.pbxproj:
4056 * win/WebKit2.vcproj:
4059 2010-12-02 Steve Falkenburg <sfalken@apple.com>
4063 * WebProcess/WebKitMain.cpp:
4064 (enableDataExecutionPrevention):
4066 2010-11-30 Amruth Raj <amruthraj@motorola.com> and Ravi Kasibhatla <ravi.kasibhatla@motorola.com>
4068 Reviewed by Martin Robinson.
4070 [GTK] Implement RunLoop, WorkQueue, Connection classes for WebKit2
4071 https://bugs.webkit.org/show_bug.cgi?id=48507
4073 * Platform/CoreIPC/Connection.h: UNIX_X11 specific changes for GTK port.
4074 (CoreIPC::Connection::messageProcessingCompleted):
4075 * Platform/CoreIPC/gtk: Added.
4076 * Platform/CoreIPC/gtk/ConnectionGtk.cpp: Added. Connection class implementation for GTK port (UNIX_X11 specific).
4077 (CoreIPC::readBytesFromSocket):
4078 (CoreIPC::writeBytesToSocket):
4079 (CoreIPC::Connection::platformInitialize):
4080 (CoreIPC::Connection::platformInvalidate):
4081 (CoreIPC::Connection::processCompletedMessage):
4082 (CoreIPC::Connection::readEventHandler):
4083 (CoreIPC::Connection::open):
4084 (CoreIPC::Connection::platformCanSendOutgoingMessages):
4085 (CoreIPC::Connection::sendOutgoingMessage):
4086 * Platform/PlatformProcessIdentifier.h: UNIX_X11 specific changes for GTK port.
4087 * Platform/RunLoop.h: GTK port specific changes.
4088 * Platform/WorkQueue.h: GTK port specific changes.
4089 * Platform/gtk/RunLoopGtk.cpp: Added. Runs an event loop using GMainLoop and handles the incoming messages.
4091 (RunLoop::~RunLoop):
4093 (RunLoop::mainLoop):
4095 (RunLoop::queueWork):
4097 (RunLoop::TimerBase::TimerBase):
4098 (RunLoop::TimerBase::~TimerBase):
4099 (RunLoop::TimerBase::resetTimerSource):
4100 (RunLoop::TimerBase::oneShotTimerFired):
4101 (RunLoop::TimerBase::repeatingTimerFired):
4102 (RunLoop::TimerBase::start):
4103 (RunLoop::TimerBase::stop):
4104 (RunLoop::TimerBase::isActive):
4105 * Platform/gtk/WorkQueueGtk.cpp: Added. Creates a thread and polls on a given fd using GIOChannel.
4106 Dispatches the obtained messages to RunLoop's GMainLoop.
4107 (WorkQueue::EventSource::EventSource):
4108 (WorkQueue::EventSource::dispatchSource):
4109 (WorkQueue::EventSource::performWorkOnce):
4110 (WorkQueue::EventSource::performWork):
4111 (WorkQueue::EventSource::deleteEventSource):
4112 (WorkQueue::platformInitialize):
4113 (WorkQueue::platformInvalidate):
4114 (WorkQueue::startWorkQueueThread):
4115 (WorkQueue::workQueueThreadBody):
4116 (WorkQueue::registerEventSourceHandler):
4117 (WorkQueue::unregisterEventSourceHandler):
4118 (WorkQueue::scheduleWork):
4120 2010-12-02 Steve Falkenburg <sfalken@apple.com>
4122 Reviewed by Adam Roben.
4124 Move enableExecutionPrevention to WebKitMain
4125 https://bugs.webkit.org/show_bug.cgi?id=50392
4127 * WebProcess/WebKitMain.cpp:
4128 (enableDataExecutionPrevention):
4130 * WebProcess/win/WebProcessMainWin.cpp:
4131 (WebKit::WebProcessMain):
4133 2010-12-02 Steve Falkenburg <sfalken@apple.com>
4135 Reviewed by Adam Roben.
4137 Enable DEP at runtime to allow for compatibility with older versions of ATL
4138 https://bugs.webkit.org/show_bug.cgi?id=50378
4140 * WebProcess/win/WebProcessMainWin.cpp:
4141 (WebKit::enableDataExecutionPrevention):
4142 (WebKit::WebProcessMain):
4143 * win/WebKit2WebProcessCommon.vsprops:
4145 2010-12-01 Sam Weinig <sam@webkit.org>
4149 * WebProcess/Plugins/Netscape/mac/NetscapePluginMac.mm:
4150 (WebKit::NetscapePlugin::windowAndViewFramesChanged):
4152 2010-12-01 Anders Carlsson <andersca@apple.com>
4154 Reviewed by Sam Weinig.
4156 Give the fake Carbon window the right bounds
4157 https://bugs.webkit.org/show_bug.cgi?id=50361
4159 * PluginProcess/PluginControllerProxy.cpp:
4160 (WebKit::PluginControllerProxy::windowAndViewFramesChanged):
4161 * PluginProcess/PluginControllerProxy.h:
4162 * PluginProcess/PluginControllerProxy.messages.in:
4163 * UIProcess/API/mac/WKView.mm:
4164 (-[WKView _updateWindowAndViewFrames]):
4165 Pass both the window frame and view frame along.
4167 (-[WKView renewGState]):
4168 Call _updateWindowAndViewFrames.
4170 * UIProcess/WebPageProxy.cpp:
4171 (WebKit::WebPageProxy::windowAndViewFramesChanged):
4172 Pass both the window frame and view frame along.
4174 * UIProcess/WebPageProxy.h:
4175 * WebProcess/Plugins/Netscape/NetscapePlugin.h:
4176 * WebProcess/Plugins/Netscape/mac/NetscapePluginMac.mm:
4177 (WebKit::NetscapePlugin::platformPostInitialize):
4178 We don't want a title bar in our fake window.
4180 (WebKit::computeFakeWindowBoundsRect):
4181 Compute the fake window bounds.
4183 (WebKit::NetscapePlugin::windowAndViewFramesChanged):
4184 Update the fake window bounds.
4186 * WebProcess/Plugins/Plugin.h:
4187 * WebProcess/Plugins/PluginProxy.cpp:
4188 (WebKit::PluginProxy::windowAndViewFramesChanged):
4189 * WebProcess/Plugins/PluginProxy.h:
4190 * WebProcess/Plugins/PluginView.cpp:
4191 (WebKit::PluginView::windowAndViewFramesChanged):
4192 (WebKit::PluginView::initializePlugin):
4193 * WebProcess/Plugins/PluginView.h:
4194 * WebProcess/WebPage/WebPage.cpp:
4195 (WebKit::WebPage::windowAndViewFramesChanged):
4196 * WebProcess/WebPage/WebPage.h:
4197 (WebKit::WebPage::windowFrameInScreenCoordinates):
4198 (WebKit::WebPage::viewFrameInWindowCoordinates):
4199 * WebProcess/WebPage/WebPage.messages.in:
4200 Pass both the window frame and view frame along.
4202 2010-12-01 Jia Pu <jpu@apple.com>
4204 Reviewed by Darin Adler.
4206 Support multiple correction candidates panel for misspelled word on Mac OS X.
4207 https://bugs.webkit.org/show_bug.cgi?id=50137
4208 <rdar://problem/8568059>
4210 Adopted new function signatures defined in base class.
4212 * WebProcess/WebCoreSupport/WebEditorClient.cpp:
4213 (WebKit::WebEditorClient::getGuessesForWord):
4214 * WebProcess/WebCoreSupport/WebEditorClient.h:
4215 * WebProcess/WebCoreSupport/mac/WebEditorClientMac.mm:
4216 (WebKit::WebEditorClient::showCorrectionPanel):
4218 2010-12-01 Simon Fraser <simon.fraser@apple.com>
4220 Reviewed by John Sullivan.
4222 Hit testing broken on sibling views of the WKView
4223 <rdar://problem/8718397>
4225 Make sure that hitView is not null when comparing with the
4228 * UIProcess/API/mac/WKView.mm:
4229 (-[WKView hitTest:]):
4231 2010-12-01 Anders Carlsson <andersca@apple.com>
4233 Reviewed by Sam Weinig.
4235 Implement the remaining PluginController/Plugin member functions
4236 https://bugs.webkit.org/show_bug.cgi?id=50356
4238 * PluginProcess/PluginControllerProxy.cpp:
4239 (WebKit::PluginControllerProxy::cancelStreamLoad):
4240 (WebKit::PluginControllerProxy::cancelManualStreamLoad):
4241 (WebKit::PluginControllerProxy::setStatusbarText):
4242 (WebKit::PluginControllerProxy::pluginProcessCrashed):
4243 (WebKit::PluginControllerProxy::frameDidFinishLoading):