1 2011-01-24 Anders Carlsson <andersca@apple.com>
3 Reviewed by Dan Bernstein.
5 Reset the page scale factor on standard frame loads
6 https://bugs.webkit.org/show_bug.cgi?id=53058
7 <rdar://problem/8908844>
9 * UIProcess/WebPageProxy.cpp:
10 (WebKit::WebPageProxy::scaleWebView):
11 Don't set m_viewScaleFactor here. It will be set in viewScaleFactorDidChange.
13 (WebKit::WebPageProxy::viewScaleFactorDidChange):
14 Update m_viewScaleFactor.
16 * UIProcess/WebPageProxy.h:
17 Add viewScaleFactorDidChange.
19 * UIProcess/WebPageProxy.messages.in:
20 Add ViewScaleFactorDidChange message.
22 * WebProcess/WebCoreSupport/WebFrameLoaderClient.cpp:
23 (WebKit::WebFrameLoaderClient::dispatchDidCommitLoad):
26 (WebKit::WebFrameLoaderClient::restoreViewState):
27 Inform the UI process about the new view scale factor.
29 * WebProcess/WebPage/WebPage.cpp:
30 (WebKit::WebPage::scaleWebView):
31 Send a ViewScaleFactorDidChange message.
33 2011-01-24 Maciej Stachowiak <mjs@apple.com>
35 Reviewed by Anders Carlsson.
37 Use designated temp directory for the database for WebKit2
38 https://bugs.webkit.org/show_bug.cgi?id=53052
40 Add the API necessary to support this. Database path is now
41 determined on the UI process side and passed to the Web process.
42 Reviewed by Anders Carlsson.
45 * Shared/WebProcessCreationParameters.cpp:
46 (WebKit::WebProcessCreationParameters::encode):
47 (WebKit::WebProcessCreationParameters::decode):
48 * Shared/WebProcessCreationParameters.h:
49 * UIProcess/API/C/WKContext.cpp:
50 (WKContextSetDatabaseDirectory):
51 * UIProcess/API/C/WKContextPrivate.h:
52 * UIProcess/WebContext.cpp:
53 (WebKit::WebContext::ensureWebProcess):
54 (WebKit::WebContext::databaseDirectory):
55 * UIProcess/WebContext.h:
56 (WebKit::WebContext::setDatabaseDirectory):
57 * UIProcess/mac/WebContextMac.mm:
58 (WebKit::WebContext::platformDefaultDatabaseDirectory):
59 * UIProcess/qt/WebContextQt.cpp:
60 (WebKit::WebContext::platformDefaultDatabaseDirectory):
61 * UIProcess/win/WebContextWin.cpp:
62 (WebKit::WebContext::platformDefaultDatabaseDirectory):
64 * WebKit2.xcodeproj/project.pbxproj:
65 * WebProcess/WebCoreSupport/WebDatabaseManager.cpp:
66 (WebKit::WebDatabaseManager::initialize):
67 (WebKit::WebDatabaseManager::WebDatabaseManager):
68 * WebProcess/WebCoreSupport/WebDatabaseManager.h:
69 * WebProcess/WebCoreSupport/gtk/WebDatabaseManagerGtk.cpp: Removed.
70 * WebProcess/WebCoreSupport/mac/WebDatabaseManagerMac.mm: Removed.
71 * WebProcess/WebCoreSupport/qt/WebDatabaseManagerQt.cpp: Removed.
72 * WebProcess/WebCoreSupport/win/WebDatabaseManagerWin.cpp: Removed.
73 * WebProcess/WebProcess.cpp:
74 (WebKit::WebProcess::WebProcess):
75 (WebKit::WebProcess::initializeWebProcess):
76 * WebProcess/com.apple.WebProcess.sb:
77 * WebProcess/mac/WebProcessMac.mm:
78 (WebKit::initializeSandbox):
81 2011-01-24 Brent Fulgham <bfulgham@webkit.org>
85 * win/WebKit2.vcproj: Don't build the CG Utilities when building
88 2011-01-24 Anders Carlsson <andersca@apple.com>
90 Reviewed by John Sullivan.
92 Don't use the timeout checker for non-user-interaction messages
93 https://bugs.webkit.org/show_bug.cgi?id=53046
95 * UIProcess/ChunkedUpdateDrawingAreaProxy.cpp:
96 (WebKit::ChunkedUpdateDrawingAreaProxy::didSetSize):
97 (WebKit::ChunkedUpdateDrawingAreaProxy::sendSetSize):
98 * UIProcess/LayerBackedDrawingAreaProxy.cpp:
99 (WebKit::LayerBackedDrawingAreaProxy::sizeDidChange):
100 (WebKit::LayerBackedDrawingAreaProxy::didSetSize):
102 2011-01-24 Adam Roben <aroben@apple.com>
104 Windows Production build fix
106 * win/WebKit2.make: Update for move of WebKit2 into Source.
108 2011-01-24 Jessie Berlin <jberlin@apple.com>
110 Reviewed by Adam Roben.
112 WebKit2: LayoutTests: The UNIMPLEMENTED warnings in TextCheckerWin should be disabled
113 https://bugs.webkit.org/show_bug.cgi?id=53029
115 * UIProcess/win/TextCheckerWin.cpp:
116 Disable the warnings for this file.
118 2011-01-24 Anders Carlsson <andersca@apple.com>
120 Reviewed by Sam Weinig.
122 Wait for half a second if we're asked to paint when receiving a DidSetSize message
123 https://bugs.webkit.org/show_bug.cgi?id=53028
125 * UIProcess/DrawingAreaProxyImpl.cpp:
126 (WebKit::DrawingAreaProxyImpl::paint):
128 2011-01-24 Anders Carlsson <andersca@apple.com>
130 Reviewed by Sam Weinig.
132 Implement forceRedisplay in the new drawing area
133 https://bugs.webkit.org/show_bug.cgi?id=53026
135 * WebProcess/WebPage/DrawingAreaImpl.cpp:
136 (WebKit::DrawingAreaImpl::forceRepaint):
137 * WebProcess/WebPage/DrawingAreaImpl.h:
139 2011-01-24 Anders Carlsson <andersca@apple.com>
141 Reviewed by Sam Weinig.
143 Fill unpainted rects with the background color.
144 https://bugs.webkit.org/show_bug.cgi?id=53025
146 * UIProcess/API/mac/WKView.mm:
147 (drawPageBackground):
148 Add new helper function.
150 (-[WKView drawRect:]):
151 Iterate over the unpainted rects and fill them with the background color.
153 2011-01-24 Dan Bernstein <mitz@apple.com>
155 Reviewed by John Sullivan.
157 WebKit2 version of <rdar://problem/6097826> Mail's cursor does not become a resize cursor when moving mouse from scrolled email to the horizontal splitter
159 * UIProcess/API/mac/PageClientImpl.mm:
160 (WebKit::PageClientImpl::setCursor): If the current cursor comes from a cursor rect, do not override it.
162 2011-01-24 Balazs Kelemen <kbalazs@webkit.org>
164 Rubber-stamped by Csaba Osztrogonác.
168 * UIProcess/Launcher/qt/ProcessLauncherQt.cpp:
169 (WebKit::ProcessLauncher::launchProcess): Move the bracket to the right place.
171 2011-01-24 Kimmo Kinnunen <kimmo.t.kinnunen@nokia.com>
173 Reviewed by Kenneth Rohde Christiansen.
175 [Qt] Remove CleanupHandler by passing file descriptors.
177 Deleting files in signal handler of UI process is not a good idea,
178 because the memory where filenames are stored might not be valid
181 To avoid the need of using signal handlers for cleanup,
183 1) Avoid passing filenames between processes, pass fds
184 2) When mmap'ing files, delete them immediately after
185 opening and mmap'ing them.
186 3) Pass sockets with fds during fork+exec instead of
187 passing them via the filesystem.
188 4) Use mmap'ed files for implementation of SharedMemory.
189 QSharedMemory does not support cleanup correctly.
192 - Move MappedMemory to SharedMemory, make UpdateChunk use this.
193 - Implement CoreIPC::Attachment using mmaped files.
194 - Send messages using datagram socket. This solution works
195 similiarly to Mach ports on Mac.
196 - Send big messages out-of-line and thus avoid increasing
198 - Remove MemoryMappedPool and rely on libc/kernel caching
200 - Unmap memory areas after use.
201 - When UI process crashes, kill the web process using SIGKILL.
202 This is possible again because cleanup handler is not needed.
204 [WK2][Qt] Multiple problems with MemoryMappedPool
205 https://bugs.webkit.org/show_bug.cgi?id=51984
207 * Platform/CoreIPC/Attachment.cpp:
208 (CoreIPC::Attachment::Attachment):
209 * Platform/CoreIPC/Attachment.h:
210 (CoreIPC::Attachment::size):
211 (CoreIPC::Attachment::releaseFileDescriptor):
212 (CoreIPC::Attachment::fileDescriptor):
213 * Platform/CoreIPC/Connection.h:
214 * Platform/CoreIPC/qt/ConnectionQt.cpp:
215 (CoreIPC::MessageInfo::MessageInfo):
216 (CoreIPC::MessageInfo::setMessageBodyOOL):
217 (CoreIPC::MessageInfo::isMessageBodyOOL):
218 (CoreIPC::MessageInfo::bodySize):
219 (CoreIPC::MessageInfo::messageID):
220 (CoreIPC::MessageInfo::attachmentCount):
221 (CoreIPC::Connection::platformInitialize):
222 (CoreIPC::Connection::platformInvalidate):
223 (CoreIPC::SocketNotifierDisableGuard::SocketNotifierDisableGuard):
224 (CoreIPC::SocketNotifierDisableGuard::~SocketNotifierDisableGuard):
225 (CoreIPC::Connection::readyReadHandler):
226 (CoreIPC::Connection::open):
227 (CoreIPC::Connection::platformCanSendOutgoingMessages):
228 (CoreIPC::Connection::sendOutgoingMessage):
229 * Platform/SharedMemory.h:
230 * Platform/WorkQueue.h:
231 * Platform/qt/MappedMemoryPool.cpp: Removed.
232 * Platform/qt/MappedMemoryPool.h: Removed.
233 * Platform/qt/SharedMemoryQt.cpp:
234 (WebKit::SharedMemory::Handle::Handle):
235 (WebKit::SharedMemory::Handle::~Handle):
236 (WebKit::SharedMemory::Handle::isNull):
237 (WebKit::SharedMemory::Handle::encode):
238 (WebKit::SharedMemory::Handle::decode):
239 (WebKit::SharedMemory::Handle::releaseToAttachment):
240 (WebKit::SharedMemory::Handle::adoptFromAttachment):
241 (WebKit::SharedMemory::create):
242 (WebKit::accessModeMMap):
243 (WebKit::SharedMemory::~SharedMemory):
244 (WebKit::accessModeFile):
245 (WebKit::SharedMemory::createHandle):
246 * Platform/qt/WorkQueueQt.cpp:
247 (WorkQueue::registerSocketEventHandler):
248 * Shared/qt/UpdateChunk.cpp:
249 (WebKit::UpdateChunk::UpdateChunk):
250 (WebKit::UpdateChunk::~UpdateChunk):
251 (WebKit::UpdateChunk::encode):
252 (WebKit::UpdateChunk::decode):
253 (WebKit::UpdateChunk::createImage):
254 * Shared/qt/UpdateChunk.h:
255 * UIProcess/Launcher/ProcessLauncher.h:
256 * UIProcess/Launcher/qt/ProcessLauncherQt.cpp:
257 (WebKit::QtWebProcess::QtWebProcess):
258 (WebKit::QtWebProcess::setupChildProcess):
259 (WebKit::ProcessLauncher::launchProcess):
260 (WebKit::ProcessLauncher::platformInvalidate):
261 * UIProcess/Launcher/qt/ThreadLauncherQt.cpp:
262 (WebKit::webThreadBody):
263 (WebKit::ThreadLauncher::createWebThread):
265 * WebProcess/qt/WebProcessMainQt.cpp:
266 (WebKit::WebProcessMainQt):
268 2011-01-24 Andras Becsi <abecsi@webkit.org>
270 Reviewed by Csaba Osztrogonác.
272 [Qt] Move project files into Source
273 https://bugs.webkit.org/show_bug.cgi?id=52891
275 * DerivedSources.pro:
279 2011-01-23 Damian Kaleta <dkaleta@apple.com>
281 Reviewed by Kevin Decker.
283 <rdar://problem/8905171>
284 https://bugs.webkit.org/show_bug.cgi?id=52985
286 * UIProcess/WebPageProxy.cpp:
287 (WebKit::WebPageProxy::scaleWebView): Eliminated early return inside WebPageProxy::scaleWebView, making it
288 consistent with WebKit1.
290 2011-01-23 Alexey Proskuryakov <ap@apple.com>
292 Reviewed by Dan Bernstein.
294 https://bugs.webkit.org/show_bug.cgi?id=52968
295 Use a separate NSView for printing
297 Also addresses <rdar://problem/8900148> Improper check for
298 -[NSGraphicsContext currentContextDrawingToScreen]
300 * UIProcess/API/mac/WKPrintingView.h: Added.
301 * UIProcess/API/mac/WKPrintingView.mm: Added.
302 (-[WKPrintingView initWithFrameProxy:]):
303 (-[WKPrintingView isFlipped]):
304 (-[WKPrintingView _adjustPrintingMarginsForHeaderAndFooter]):
305 (-[WKPrintingView knowsPageRange:]):
306 (-[WKPrintingView _recursiveDisplayRectIfNeededIgnoringOpacity:isVisibleRect:rectIsVisibleRectForView:topView:]):
307 (-[WKPrintingView drawPageBorderWithSize:]):
308 (-[WKPrintingView _provideTotalScaleFactorForPrintOperation:]):
309 (-[WKPrintingView rectForPage:]):
310 * UIProcess/API/mac/WKView.mm:
311 (-[WKView drawRect:]):
312 (-[WKView canChangeFrameLayout:]):
313 (-[WKView printOperationWithPrintInfo:forFrame:]):
314 * WebKit2.xcodeproj/project.pbxproj:
315 Moved printing code to a separate view, simplifying as appropriate. The view is currently not
316 referenced by anything in WebKit2 directly, being owned by NSPrintOperation.
318 2011-01-22 Anders Carlsson <andersca@apple.com>
320 Reviewed by Sam Weinig.
322 Transparent windows with compositing WebKit2 content show garbage
323 https://bugs.webkit.org/show_bug.cgi?id=52966
324 <rdar://problem/8765051>
326 * UIProcess/mac/LayerBackedDrawingAreaProxyMac.mm:
327 (WebKit::LayerBackedDrawingAreaProxy::paint):
328 If the WKView should draw transparent background, do so.
330 2011-01-22 Anders Carlsson <andersca@apple.com>
332 Reviewed by Sam Weinig.
334 Add an asynchronous WKPageForceRepaint
335 https://bugs.webkit.org/show_bug.cgi?id=52964
336 <rdar://problem/8898527>
338 * UIProcess/API/C/WKPage.cpp:
339 (WKPageForceRepaint):
340 Call WebPageProxy::forceRepaint.
342 * UIProcess/API/C/WKPage.h:
343 Add WKPageForceRepaint.
345 * UIProcess/GenericCallback.h:
346 Add a "generic" VoidCallback class.
348 * UIProcess/WebPageProxy.cpp:
349 (WebKit::WebPageProxy::forceRepaint):
350 Insert the callback in the m_voidCallbacks map and send a forceRepaint message.
352 (WebKit::WebPageProxy::voidCallback):
353 Call the right void callback.
355 (WebKit::WebPageProxy::processDidCrash):
356 Invalidate m_voidCallbacks.
358 * UIProcess/WebPageProxy.messages.in:
359 Add a VoidCallback message.
361 * WebProcess/WebPage/ChunkedUpdateDrawingArea.cpp:
362 (WebKit::ChunkedUpdateDrawingArea::forceRepaint):
365 * WebProcess/WebPage/ChunkedUpdateDrawingArea.h:
368 * WebProcess/WebPage/WebPage.cpp:
369 (WebKit::WebPage::forceRepaint):
370 Call forceRepaint on the drawing area.
372 * WebProcess/WebPage/WebPage.messages.in:
373 Add a ForceRepaint message.
375 2011-01-21 Nikolas Zimmermann <nzimmermann@rim.com>
377 Reviewed by Dirk Schulze.
379 Introduce FontMetrics abstraction
380 https://bugs.webkit.org/show_bug.cgi?id=51456
382 * WebProcess/WebCoreSupport/win/WebPopupMenuWin.cpp: Use FontMetrics instead of Font to access the metrics.
383 (WebKit::WebPopupMenu::setUpPlatformData):
385 2011-01-22 Alexey Proskuryakov <ap@apple.com>
387 Reviewed by Dan Bernstein.
389 https://bugs.webkit.org/show_bug.cgi?id=52950
390 Leak in WebPage::drawRectToPDF
392 * WebProcess/WebPage/WebPage.cpp: (WebKit::WebPage::drawRectToPDF): Use RetainPtr here, too.
394 2011-01-22 Alexey Proskuryakov <ap@apple.com>
396 Reviewed by Dan Bernstein.
398 https://bugs.webkit.org/show_bug.cgi?id=52951
399 WebKit2 generates a bad PDF for cross process messaging
401 * UIProcess/API/mac/WKView.mm:
402 (-[WKView _recursiveDisplayRectIfNeededIgnoringOpacity:isVisibleRect:rectIsVisibleRectForView:topView:]):
403 Use a correct offset when flipping.
405 2011-01-21 Alexey Proskuryakov <ap@apple.com>
407 Reviewed by Dan Bernstein.
409 https://bugs.webkit.org/show_bug.cgi?id=52943
410 Objective-C files should use #import, not #include
412 * UIProcess/API/C/WebKit2.h: This is an interesting one, because it's cross-platform, and
413 there is more than one WKView.h.
415 * Platform/mac/ModuleMac.mm:
416 * Platform/mac/RunLoopMac.mm:
417 * PluginProcess/mac/PluginControllerProxyMac.mm:
418 * PluginProcess/mac/PluginProcessMac.mm:
419 * PluginProcess/mac/PluginProcessMainMac.mm:
420 * Shared/API/c/mac/WKCertificateInfoMac.mm:
421 * Shared/API/c/mac/WKURLRequestNS.mm:
422 * Shared/API/c/mac/WKURLResponseNS.mm:
423 * Shared/Plugins/Netscape/mac/NetscapePluginModuleMac.mm:
424 * Shared/mac/PlatformCertificateInfo.mm:
425 * Shared/mac/SandboxExtensionMac.mm:
426 * Shared/mac/WebCoreArgumentCodersMac.mm:
427 * Shared/mac/WebMemorySampler.mac.mm:
428 * Shared/mac/WebURLRequestMac.mm:
429 * Shared/mac/WebURLResponseMac.mm:
430 * UIProcess/API/mac/FindIndicatorWindow.mm:
431 * UIProcess/API/mac/WKTextInputWindowController.mm:
432 * UIProcess/Launcher/mac/ProcessLauncherMac.mm:
433 * UIProcess/Launcher/mac/ThreadLauncherMac.mm:
434 * UIProcess/Plugins/mac/PluginInfoStoreMac.mm:
435 * UIProcess/Plugins/mac/PluginProcessProxyMac.mm:
436 * UIProcess/mac/BackingStoreMac.mm:
437 * UIProcess/mac/ChunkedUpdateDrawingAreaProxyMac.mm:
438 * UIProcess/mac/LayerBackedDrawingAreaProxyMac.mm:
439 * UIProcess/mac/TextCheckerMac.mm:
440 * UIProcess/mac/WebContextMac.mm:
441 * UIProcess/mac/WebContextMenuProxyMac.mm:
442 * UIProcess/mac/WebPageProxyMac.mm:
443 * UIProcess/mac/WebPopupMenuProxyMac.mm:
444 * UIProcess/mac/WebPreferencesMac.mm:
445 * WebProcess/Downloads/mac/DownloadMac.mm:
446 * WebProcess/Plugins/Netscape/mac/NetscapePluginMac.mm:
447 * WebProcess/Plugins/Netscape/mac/PluginProxyMac.mm:
448 * WebProcess/WebCoreSupport/mac/WebContextMenuClientMac.mm:
449 * WebProcess/WebCoreSupport/mac/WebDatabaseManagerMac.mm:
450 * WebProcess/WebCoreSupport/mac/WebEditorClientMac.mm:
451 * WebProcess/WebCoreSupport/mac/WebErrorsMac.mm:
452 * WebProcess/WebCoreSupport/mac/WebPopupMenuMac.mm:
453 * WebProcess/WebPage/mac/LayerBackedDrawingAreaMac.mm:
454 * WebProcess/WebPage/mac/WebPageMac.mm:
455 * WebProcess/mac/WebProcessMac.mm:
457 2011-01-21 Mark Rowe <mrowe@apple.com>
459 Reviewed by Sam Weinig.
461 Fix the WebKit2 build with clang.
463 * Scripts/webkit2/messages.py: Add some more structs to the list.
464 * UIProcess/DrawingAreaProxy.h: Forward-declare UpdateInfo as a class.
465 * UIProcess/TextChecker.h: Forward-declare TextCheckerState as a struct.
466 * UIProcess/WebPageProxy.h: Forward-declare ContextMenuState as a struct.
467 * UIProcess/mac/TextCheckerMac.mm: Fix the type of the string constants so that they can be passed to
468 functions expecting NSString* without generating warnings.
469 * WebProcess/WebPage/DrawingArea.h: Forward-declare WebPageCreationParameters as a struct.
470 * WebProcess/WebPage/DrawingAreaImpl.h: Forward-declare UpdateInfo as a class.
471 * WebProcess/WebPage/WebPage.cpp:
472 (WebKit::WebPage::getResourceDataFromFrame): Add parens around the assignment in the condition of
473 the if statement to suppress a warning.
475 2011-01-21 Brian Weinstein <bweinstein@apple.com>
477 Reviewed by Adam Roben.
479 WebKit2: Need API to stop loading a WKFrame
480 https://bugs.webkit.org/show_bug.cgi?id=52925
482 * UIProcess/API/C/WKFrame.cpp:
483 (WKFrameStopLoading): Call through to WebFrameProxy::stopLoading.
484 * UIProcess/API/C/WKFrame.h:
485 * UIProcess/WebFrameProxy.cpp:
486 (WebKit::WebFrameProxy::stopLoading): Send a message to the WebProcess to stop loading the frame
487 with the passed in ID.
488 * UIProcess/WebFrameProxy.h:
489 * WebProcess/WebPage/WebPage.cpp:
490 (WebKit::WebPage::stopLoadingFrame): Call stopForUserCancel on the passed-in frame.
491 * WebProcess/WebPage/WebPage.h:
492 * WebProcess/WebPage/WebPage.messages.in: Add StopLoadingFrame.
494 2011-01-21 Brady Eidson <beidson@apple.com>
496 Reviewed by Adam Roben.
498 <rdar://problem/8894125> and https://bugs.webkit.org/show_bug.cgi?id=52916
499 Expose "suggested filename" for a resource based on its resource response.
502 * WebProcess/InjectedBundle/API/c/WKBundleFrame.cpp:
503 (WKBundleFrameCopySuggestedFilenameForResourceURL):
504 * WebProcess/InjectedBundle/API/c/WKBundleFrame.h:
507 * WebProcess/WebPage/WebFrame.cpp:
508 (WebKit::WebFrame::suggestedFilenameForResourceURL): See if the DocumentLoader has
509 a resource for this URL and, if so, return the response's suggested filename.
510 * WebProcess/WebPage/WebFrame.h:
512 2011-01-21 Anders Carlsson <andersca@apple.com>
514 Reviewed by Dan Bernstein.
516 DrawingAreaProxyImpl::paint should return the unpainted region
517 https://bugs.webkit.org/show_bug.cgi?id=52918
519 * UIProcess/API/mac/WKView.mm:
520 (-[WKView drawRect:]):
521 Add unpaintedRegion parameter.
523 * UIProcess/BackingStore.h:
524 (WebKit::BackingStore::size):
527 * UIProcess/DrawingAreaProxyImpl.cpp:
528 (WebKit::DrawingAreaProxyImpl::paint):
529 Initialize the unpainted region to the dirty region, then subtract the painted region.
531 2011-01-21 Anders Carlsson <andersca@apple.com>
533 Reviewed by Dan Bernstein and Maciej Stachowiak.
535 Fix for <rdar://problem/8896057>
537 Give the Web Process access to the PubSub agent.
539 * WebProcess/com.apple.WebProcess.sb:
541 2011-01-21 Sam Weinig <sam@webkit.org>
543 Reviewed by Anders Carlsson.
545 Part 2 of "Cleanup Scrollbar/ScrollbarClient relationship"
546 https://bugs.webkit.org/show_bug.cgi?id=52779
548 Rename ScrollbarClient -> ScrollableArea.
550 * UIProcess/win/WebPopupMenuProxyWin.cpp:
551 (WebKit::WebPopupMenuProxyWin::onMouseWheel):
552 (WebKit::WebPopupMenuProxyWin::scrollToRevealSelection):
553 * UIProcess/win/WebPopupMenuProxyWin.h:
555 2011-01-21 Adam Roben <aroben@apple.com>
557 Update for WKCACFLayerRenderer -> CACFLayerView rename
559 Fixes <http://webkit.org/b/52898> WKCACFLayerRenderer sounds like a render object, but isn't
561 Reviewed by Simon Fraser.
563 * WebProcess/WebPage/win/LayerBackedDrawingAreaWin.cpp: Just removed all the unnecessary
566 2011-01-20 Darin Adler <darin@apple.com>
568 Reviewed by Dan Bernstein.
570 WebKit2: Implement showModalDialog
571 https://bugs.webkit.org/show_bug.cgi?id=52855
573 * Shared/WebPageCreationParameters.h: Added canRunModal.
575 * UIProcess/API/C/WKPage.h: Added a runModal function pointer to
576 WKPageUIClient. Also removed a lot of redundant typedefs and added
577 a new one, WKPageCallback, for callbacks without arguments or return
580 * UIProcess/API/qt/qwkpage.cpp:
581 (QWKPage::QWKPage): Added a runModal function pointer of 0.
583 * UIProcess/WebPageProxy.cpp:
584 (WebKit::WebPageProxy::creationParameters): Set canRunModal
585 based on return value of WebUIClient::canRunModal.
587 * UIProcess/WebPageProxy.h: Added runModal.
588 Calls WebUIClient::runModal.
590 * UIProcess/WebPageProxy.messages.in: Added RunModal message.
591 Also removed the periods from the phrases in the comments
592 as Maciej requested a while back.
594 * UIProcess/WebUIClient.cpp:
595 (WebKit::WebUIClient::canRunModal): Added. Returns true or false
596 based on whether a runModal function was supplied in the
597 WKPageUIClient structure.
598 (WebKit::WebUIClient::runModal): Added. Calls the runModal
599 function from the WKPageUIClient structure.
600 * UIProcess/WebUIClient.h: Declared the above functions.
602 * WebProcess/WebCoreSupport/WebChromeClient.cpp:
603 (WebKit::WebChromeClient::canRunModal): Call through to WebPage.
604 (WebKit::WebChromeClient::runModal): Ditto.
606 * WebProcess/WebPage/WebPage.cpp:
607 (WebKit::WebPage::WebPage): Initialize m_canRunModal based on the
608 creation parameters. Initialize m_isRunningModal to false.
609 (WebKit::WebPage::close): Stop the nested run loop if we are running modal.
610 (WebKit::WebPage::runModal): Send a message to ask the UI process to run
611 modal and then start a nested run loop. It gets stopped when the page is closed.
612 * WebProcess/WebPage/WebPage.h: Defined the canRunModal function
613 and declared the runModal function.
615 2011-01-20 Alexey Proskuryakov <ap@apple.com>
617 Reviewed by Darin Adler.
619 https://bugs.webkit.org/show_bug.cgi?id=52849
620 Make window.print work with WebKit2
622 * UIProcess/API/qt/qwkpage.cpp:
624 * UIProcess/WebPageProxy.cpp:
625 (WebKit::WebPageProxy::printFrame):
626 * UIProcess/WebPageProxy.h:
627 * UIProcess/WebPageProxy.messages.in:
628 * UIProcess/WebUIClient.cpp:
629 (WebKit::WebUIClient::printFrame):
630 * UIProcess/WebUIClient.h:
631 * WebProcess/WebCoreSupport/WebChromeClient.cpp:
632 (WebKit::WebChromeClient::print):
633 Just pass through deelagte call to a WebKit2 client.
635 * UIProcess/API/C/WKPage.h: Also added "Callback" suffix to other printing related function
638 2011-01-20 Anders Carlsson <andersca@apple.com>
640 Reviewed by Darin Adler.
642 Keep track of the latest update timestamp in the backing store
643 https://bugs.webkit.org/show_bug.cgi?id=52848
645 * Shared/UpdateInfo.h:
646 (WebKit::UpdateInfo::UpdateInfo):
647 Initialize timestamp to 0.
649 * UIProcess/BackingStore.cpp:
650 (WebKit::BackingStore::BackingStore):
651 Initialize m_latestUpdateTimestamp to 0.
653 (WebKit::BackingStore::incorporateUpdate):
654 If the update is too old, discard it. Otherwise, create a bitmap
655 and pass it to platformIncorporateUpdate. Finally update the timestamp.
657 * UIProcess/BackingStore.h:
658 Add m_latestUpdateTimestamp.
660 * UIProcess/mac/BackingStoreMac.mm:
661 (WebKit::BackingStore::platformIncorporateUpdate):
662 Update now that we are already given the shareable bitmap.
664 2011-01-20 Beth Dakin <bdakin@apple.com>
666 Reviewed by Geoffrey Garen.
668 Fix for <rdar://problem/8890255>
670 Allow WebKitSystemInterface to draw scrollbars
672 * WebProcess/WebCoreSupport/mac/WebSystemInterface.mm:
673 (InitWebCoreSystemInterface):
675 2011-01-20 Sam Weinig <sam@webkit.org>
677 Reviewed by Dave Hyatt.
679 Cleanup Scrollbar/ScrollbarClient relationship
680 https://bugs.webkit.org/show_bug.cgi?id=52779
682 * UIProcess/win/WebPopupMenuProxyWin.cpp:
683 (WebKit::WebPopupMenuProxyWin::scrollPosition):
684 (WebKit::WebPopupMenuProxyWin::setScrollOffset):
685 (WebKit::WebPopupMenuProxyWin::scrollTo):
686 (WebKit::WebPopupMenuProxyWin::onMouseWheel):
687 (WebKit::WebPopupMenuProxyWin::scrollToRevealSelection):
688 * UIProcess/win/WebPopupMenuProxyWin.h:
689 (WebKit::WebPopupMenuProxyWin::verticalScrollbar):
691 2011-01-20 Anders Carlsson <andersca@apple.com>
693 Reviewed by Adam Roben.
695 Add a timestamp to UpdateInfo
696 https://bugs.webkit.org/show_bug.cgi?id=52844
698 * Shared/UpdateInfo.cpp:
699 (WebKit::UpdateInfo::encode):
700 (WebKit::UpdateInfo::decode):
701 * Shared/UpdateInfo.h:
702 * WebProcess/WebPage/DrawingAreaImpl.cpp:
703 (WebKit::DrawingAreaImpl::setSize):
704 (WebKit::DrawingAreaImpl::display):
706 2011-01-20 Anders Carlsson <andersca@apple.com>
708 Reviewed by Beth Dakin.
710 Add Connection::waitForAndDispatchImmediately
711 https://bugs.webkit.org/show_bug.cgi?id=52841
713 * Platform/CoreIPC/Connection.h:
714 (CoreIPC::Connection::waitForAndDispatchImmediately):
716 2011-01-20 Kevin Decker <kdecker@apple.com>
718 Reviewed by Anders Carlsson.
720 <rdar://problem/8880689> need a way to obtain the rendered rectangle for box elements
721 https://bugs.webkit.org/show_bug.cgi?id=52823
723 * WebProcess/InjectedBundle/API/c/WKBundleNodeHandle.cpp:
724 (WKBundleNodeHandleGetRenderRect): Added new method that will return a rendered rectangle for box elements
725 * WebProcess/InjectedBundle/API/c/WKBundleNodeHandlePrivate.h: Ditto.
726 * WebProcess/InjectedBundle/DOM/InjectedBundleNodeHandle.cpp: Ditto.
727 (WebKit::InjectedBundleNodeHandle::renderRect): Ditto.
728 * WebProcess/InjectedBundle/DOM/InjectedBundleNodeHandle.h: Ditto.
730 2011-01-20 Kimmo Kinnunen <kimmo.t.kinnunen@nokia.com>
732 Reviewed by Andreas Kling.
734 Remove null ptr deref that happens when reattaching to
737 Implement didRelaunchProcess that sets the drawing area size
738 after the drawing area is re-instantiated.
740 [Qt][WK2] Null ptr deref in UI process after web process has crashed
741 https://bugs.webkit.org/show_bug.cgi?id=52796
743 * UIProcess/API/qt/qgraphicswkview.cpp:
744 (QGraphicsWKView::QGraphicsWKView):
745 * UIProcess/API/qt/qwkpage.cpp:
746 (QWKPagePrivate::QWKPagePrivate):
747 (QWKPagePrivate::init):
748 (QWKPagePrivate::createDrawingAreaProxy):
749 (QWKPagePrivate::didRelaunchProcess): Reset drawing area size after crash.
750 * UIProcess/API/qt/qwkpage_p.h:
752 2011-01-20 Maciej Stachowiak <mjs@apple.com>
754 Reviewed by Adam Roben.
756 WebKitTestRunner needs to support layoutTestController.evaluateScriptInIsolatedWorld
757 https://bugs.webkit.org/show_bug.cgi?id=42327
759 Added a new API call, WKBundleFrameForJavaScriptContext, that gets the WKBundleFrameRef
760 that corresponds to a JSContextRef (or null if none).
762 * WebProcess/InjectedBundle/API/c/WKBundleFrame.cpp:
763 (WKBundleFrameForJavaScriptContext): Simple wrapper, defers to a WebFrame
765 * WebProcess/InjectedBundle/API/c/WKBundleFrame.h:
766 * WebProcess/WebPage/WebFrame.cpp:
767 (WebKit::WebFrame::frameForContext): Follow the maze of twisty pointers.
768 * WebProcess/WebPage/WebFrame.h:
770 2011-01-20 Alejandro G. Castro <alex@igalia.com>
772 Fix compilation error in GTK WebKit2.
774 * Platform/CoreIPC/gtk/ConnectionGtk.cpp:
775 (CoreIPC::readBytesFromSocket):
776 (CoreIPC::writeBytesToSocket):
778 2011-01-20 Zoltan Horvath <zoltan@webkit.org>
780 Reviewed by Csaba Osztrogonác.
782 Refactoring of the custom allocation framework
783 https://bugs.webkit.org/show_bug.cgi?id=49897
785 Inheriting from FastAllocBase can result in objects getting larger (bug #33896, #46589).
786 The modification replaces Noncopyable and FastAllocBase classes and these inherits with their
787 equivalent macro implementation at the necessary places.
789 2011-01-19 Simon Fraser <simon.fraser@apple.com>
791 Fix the WebKit2 build.
793 * WebProcess/WebPage/mac/LayerBackedDrawingAreaMac.mm:
794 (WebKit::LayerBackedDrawingArea::syncCompositingLayers):
796 2011-01-19 Brian Weinstein <bweinstein@apple.com>
798 Reviewed by Darin Adler.
800 WebKit2: Need API to get the parent frame of a frame
801 https://bugs.webkit.org/show_bug.cgi?id=52774
803 Add the API to get the parent frame of a frame.
805 * UIProcess/API/C/WKFrame.cpp:
806 (WKFrameGetParentFrame):
807 * UIProcess/API/C/WKFrame.h:
809 2011-01-19 Enrica Casucci <enrica@apple.com>
811 Reviewed by Darin Adler.
813 WebKit2: add support for drag and drop
814 https://bugs.webkit.org/show_bug.cgi?id=52343
815 <rdar://problem/7660558>
817 This patch contains the remaining work to support drag and drop on Mac.
818 I've added a PasteboardTypes class to encapsulate all the pasteboard formats
819 supported for drag and drop.
820 In this implementation we don't support the promised types, since I could not
821 find an efficient way to do this across processes.
822 The bulk of the patch consists in creating a shareable bitmap for the drag image,
823 pass its handle to the UI process and create a new NSImage from it to be given to
825 I've added the missing implementation of the methods in the drag client to hook
826 up the placement of the data in the pasteboard.
828 * Shared/mac/PasteboardTypes.h: Added.
829 * Shared/mac/PasteboardTypes.mm: Added.
830 (WebKit::PasteboardTypes::forEditing):
831 (WebKit::PasteboardTypes::forURL):
832 (WebKit::PasteboardTypes::forImages):
833 (WebKit::PasteboardTypes::forImagesWithArchive):
834 * UIProcess/API/mac/PageClientImpl.h:
835 * UIProcess/API/mac/PageClientImpl.mm:
836 (WebKit::PageClientImpl::setDragImage): Added.
837 * UIProcess/API/mac/WKView.mm:
838 (-[WKView _registerDraggedTypes]): Refactored to use the new PasteboardTypes class.
839 (-[WKView initWithFrame:contextRef:pageGroupRef:]):
840 (-[WKView _setMouseDownEvent:]):
841 (-[WKView _mouseHandler:]):
842 (-[WKView mouseDown:]):
843 (-[WKView mouseUp:]):
844 (-[WKView mouseDragged:]):
845 (-[WKView draggedImage:endedAt:operation:]):
846 (-[WKView draggingEntered:]):
847 (-[WKView _setDragImage:at:linkDrag:]):
848 * UIProcess/API/mac/WKViewInternal.h:
849 * UIProcess/PageClient.h:
850 * UIProcess/WebPageProxy.cpp:
851 (WebKit::WebPageProxy::setDragImage):
852 (WebKit::WebPageProxy::dragEnded):
853 * UIProcess/WebPageProxy.h:
854 * UIProcess/WebPageProxy.messages.in:
855 * WebKit2.xcodeproj/project.pbxproj:
856 * WebProcess/WebCoreSupport/WebDragClient.cpp:
857 * WebProcess/WebCoreSupport/WebDragClient.h:
858 * WebProcess/WebCoreSupport/mac/WebDragClientMac.mm: Added.
859 (WebKit::fontFromNSFont):
860 (WebKit::WebDragClient::startDrag): Added implementation.
861 (WebKit::WebDragClient::createDragImageForLink): Ditto.
862 (WebKit::writeURL): Helper function.
863 (WebKit::writeImage): Helper function.
864 (WebKit::WebDragClient::declareAndWriteDragImage): Added implementation.
865 * WebProcess/WebPage/WebPage.cpp:
866 (WebKit::WebPage::dragEnded):
867 * WebProcess/WebPage/WebPage.h:
868 * WebProcess/WebPage/WebPage.messages.in:
870 2011-01-19 Anders Carlsson <andersca@apple.com>
872 Reviewed by Dan Bernstein.
874 Put the deprecated Connection member functions next to eachother
875 https://bugs.webkit.org/show_bug.cgi?id=52767
877 * Platform/CoreIPC/Connection.h:
878 (CoreIPC::Connection::sendSync):
879 (CoreIPC::Connection::send):
881 2011-01-19 Anders Carlsson <andersca@apple.com>
883 Reviewed by Sam Weinig.
885 When resizing, the web process should repaint the page
886 https://bugs.webkit.org/show_bug.cgi?id=52764
888 * UIProcess/DrawingAreaProxyImpl.cpp:
889 (WebKit::DrawingAreaProxyImpl::didSetSize):
890 Incorporate the update.
892 (WebKit::DrawingAreaProxyImpl::incorporateUpdate):
893 Return early if the update bounds rect is empty. This can happen if painting is
894 disabled and we get a DidSetSize message.
896 * WebProcess/WebPage/DrawingAreaImpl.cpp:
897 (WebKit::DrawingAreaImpl::setSize):
898 If painting is disabled, just send back an empty UpdateInfo struct. Otherwise,
899 paint and fill in the UpdateInfo struct.
901 (WebKit::DrawingAreaImpl::display):
902 Assert that painting is not disabled.
904 2011-01-19 Alexey Proskuryakov <ap@apple.com>
906 Reviewed by Darin Adler.
908 https://bugs.webkit.org/show_bug.cgi?id=52739
909 Make it possible for a WebKit2 client to print headers and footers
911 * UIProcess/API/C/WKPage.h:
912 * UIProcess/WebPageProxy.cpp:
913 (WebKit::WebPageProxy::headerHeight):
914 (WebKit::WebPageProxy::footerHeight):
915 (WebKit::WebPageProxy::drawHeader):
916 (WebKit::WebPageProxy::drawFooter):
917 * UIProcess/WebPageProxy.h:
918 * UIProcess/WebUIClient.cpp:
919 (WebKit::WebUIClient::headerHeight):
920 (WebKit::WebUIClient::footerHeight):
921 (WebKit::WebUIClient::drawHeader):
922 (WebKit::WebUIClient::drawFooter):
923 * UIProcess/WebUIClient.h:
924 Pass UIClient calls through.
926 * UIProcess/API/mac/WKView.mm:
927 (currentPrintOperationScale): A helper to extract scale factor from the current NSPrintOperation.
928 (-[WKView _adjustPrintingMarginsForHeaderAndFooter]): Copied from WebKit1. Change current
929 print info to account for header and footer height as provided by the client.
930 (-[WKView knowsPageRange:]): Call -[self _adjustPrintingMarginsForHeaderAndFooter].
931 (-[WKView drawPageBorderWithSize:]): When AppKit asks to print page border, call the client
932 to do that. Code adapted form WebKit1.
934 * UIProcess/API/qt/qwkpage:
935 (QWKPage::QWKPage): Added zeroes for new WKPageUIClient members to avoid breaking the build.
937 2011-01-19 Jessie Berlin <jberlin@apple.com>
939 Reviewed by Darin Adler.
941 Crash in WebDatabaseManagerProxy::getDatabaseOrigins when called after the WebProcess has
943 https://bugs.webkit.org/show_bug.cgi?id=52730
945 WebDatabaseManagerProxy::invalidate was setting m_webContext to 0, and invalidate gets
946 called in WebContext::processDidClose. However, m_webContext is only set in the
947 constructor, which is only called from the constructor of WebContext, so attempting to send
948 a message to any new WebProcess after the first one died was causing a null deref.
950 This patch moves setting m_webcontext into clearContext and clearContext is only called in
951 the WebContext destructor.
953 This patch also adds checks for a valid WebProcessProxy before attempting to send messages to
954 the WebProcessProxy so that if the WebProcess has died and has not been revived, it does not
955 attempt to dereference a null WebProcessProxy.
957 * UIProcess/WebContext.cpp:
958 (WebKit::WebContext::~WebContext):
959 Call WebDatabaseManagerProxy::clearContext.
960 * UIProcess/WebContext.h:
961 (WebKit::WebContext::hasValidProcess):
962 Make this method public so that it can be called from WebDatabaseManagerProxy.
964 * UIProcess/WebDatabaseManagerProxy.cpp:
965 (WebKit::WebDatabaseManagerProxy::getDatabasesByOrigin):
966 If there isn't a valid process, invalidate the callback and return early.
967 (WebKit::WebDatabaseManagerProxy::getDatabaseOrigins):
969 (WebKit::WebDatabaseManagerProxy::deleteDatabaseWithNameForOrigin):
970 If tehre isn't a valid process return early.
971 (WebKit::WebDatabaseManagerProxy::deleteDatabasesForOrigin):
973 (WebKit::WebDatabaseManagerProxy::deleteAllDatabases):
975 (WebKit::WebDatabaseManagerProxy::setQuotaForOrigin):
977 (WebKit::WebDatabaseManagerProxy::invalidate):
978 Move setting m_webContext to 0 from here ...
979 * UIProcess/WebDatabaseManagerProxy.h:
980 (WebKit::WebDatabaseManagerProxy::clearContext):
983 2011-01-19 Anders Carlsson <andersca@apple.com>
985 Reviewed by Sam Weinig.
987 Suspend/resume painting as the WKView visibility changes
988 https://bugs.webkit.org/show_bug.cgi?id=52738
990 * UIProcess/DrawingAreaProxy.h:
991 (WebKit::DrawingAreaProxy::visibilityDidChange):
992 Add new member function. It should really be pure virtual once setPageIsVisible
995 * UIProcess/DrawingAreaProxyImpl.cpp:
996 (WebKit::DrawingAreaProxyImpl::visibilityDidChange):
997 Send SuspendPainting/ResumePainting messages based on whether the view is visible or not.
999 (WebKit::DrawingAreaProxyImpl::setPageIsVisible):
1000 Make this a stub; it should really be removed.
1002 * UIProcess/WebPageProxy.cpp:
1003 (WebKit::WebPageProxy::viewStateDidChange):
1004 Call visibilityDidChange.
1006 * UIProcess/WebPageProxy.h:
1007 (WebKit::WebPageProxy::isViewVisible):
1010 * WebProcess/WebPage/DrawingArea.messages.in:
1011 Add SuspendPainting and ResumePainting messages.
1013 * WebProcess/WebPage/DrawingAreaImpl.cpp:
1014 (WebKit::DrawingAreaImpl::DrawingAreaImpl):
1015 Initialize m_isPaintingSuspended.
1017 (WebKit::DrawingAreaImpl::suspendPainting):
1018 Set m_isPaintingSuspended to true and stop the display timer.
1020 (WebKit::DrawingAreaImpl::resumePainting):
1021 Set m_isPaintingSuspended to false.
1023 (WebKit::DrawingAreaImpl::scheduleDisplay):
1024 (WebKit::DrawingAreaImpl::display):
1025 Bail if m_isPaintingSuspended is true.
1027 2011-01-19 Andreas Kling <kling@webkit.org>
1029 Reviewed by Simon Hausmann.
1031 [Qt][WK2] Implement formatLocalizedString() for Qt.
1033 * WebProcess/WebCoreSupport/WebPlatformStrategies.cpp:
1034 (WebKit::formatLocalizedString):
1036 2011-01-19 Chris Marrin <cmarrin@apple.com>
1038 Reviewed by Simon Fraser.
1040 WK2 - Multiple crashes in PlatformCALayer::replaceSublayer
1041 https://bugs.webkit.org/show_bug.cgi?id=52695
1043 Added a hostingLayer as the parent of the existing drawingLayer.
1044 The hostingLayer is now the root which is passed to the
1045 remote context. It never changes except to track the size
1046 of the window. The backingLayer is now a child of the
1047 hostingLayer, which allow it to switch between tiled and
1050 I also now give back accurate settings for debug borders and
1053 * WebProcess/WebPage/LayerBackedDrawingArea.cpp:
1054 (WebKit::LayerBackedDrawingArea::LayerBackedDrawingArea):
1055 (WebKit::LayerBackedDrawingArea::setSize):
1056 (WebKit::LayerBackedDrawingArea::showDebugBorders):
1057 (WebKit::LayerBackedDrawingArea::showRepaintCounter):
1058 * WebProcess/WebPage/LayerBackedDrawingArea.h:
1059 * WebProcess/WebPage/mac/LayerBackedDrawingAreaMac.mm:
1060 (WebKit::LayerBackedDrawingArea::platformInit):
1061 (WebKit::LayerBackedDrawingArea::attachCompositingContext):
1062 (WebKit::LayerBackedDrawingArea::syncCompositingLayers):
1064 2011-01-19 Anders Carlsson <andersca@apple.com>
1066 Reviewed by Sam Weinig.
1068 Send a new SetSize message if the size differs from the current size
1069 https://bugs.webkit.org/show_bug.cgi?id=52728
1071 * UIProcess/DrawingAreaProxy.h:
1072 (WebKit::DrawingAreaProxy::didSetSize):
1073 Add UpdateInfo parameter.
1075 * UIProcess/DrawingAreaProxy.messages.in:
1076 Add UpdateInfo parameter to the DidSetSize message.
1078 * UIProcess/DrawingAreaProxyImpl.cpp:
1079 (WebKit::DrawingAreaProxyImpl::didSetSize):
1080 If the view size differs from the current size send another SetSize message.
1082 * UIProcess/DrawingAreaProxyImpl.h:
1083 Add UpdateInfo parameter to didSetSize.
1085 * WebProcess/WebPage/DrawingAreaImpl.cpp:
1086 (WebKit::DrawingAreaImpl::setSize):
1087 The DidSetSize message now takes an UpdateInfo parameter.
1089 2011-01-19 Anders Carlsson <andersca@apple.com>
1091 Reviewed by Darin Adler.
1093 Throttle sending of SetSize messages
1094 https://bugs.webkit.org/show_bug.cgi?id=52727
1096 * UIProcess/DrawingAreaProxyImpl.cpp:
1097 (WebKit::DrawingAreaProxyImpl::DrawingAreaProxyImpl):
1098 Initialize m_isWaitingForDidSetSize to false.
1100 (WebKit::DrawingAreaProxyImpl::didSetSize):
1101 Null out the backing store.
1103 (WebKit::DrawingAreaProxyImpl::sendSetSize):
1104 If m_isWaitingForDidSetSize is true, do nothing. Otherwise, set m_isWaitingForDidSetSize
1105 to true and send a SetSize message.
1107 * UIProcess/DrawingAreaProxyImpl.h:
1108 Add m_isWaitingForDidSetSize.
1110 2011-01-19 Anders Carlsson <andersca@apple.com>
1112 Reviewed by Darin Adler.
1114 Pass WebPageCreationParameters to DrawingArea::create
1115 https://bugs.webkit.org/show_bug.cgi?id=52726
1117 * WebProcess/WebPage/DrawingArea.cpp:
1118 (WebKit::DrawingArea::create):
1119 * WebProcess/WebPage/DrawingArea.h:
1120 * WebProcess/WebPage/DrawingAreaImpl.cpp:
1121 (WebKit::DrawingAreaImpl::create):
1122 (WebKit::DrawingAreaImpl::DrawingAreaImpl):
1123 * WebProcess/WebPage/DrawingAreaImpl.h:
1124 * WebProcess/WebPage/WebPage.cpp:
1125 (WebKit::WebPage::WebPage):
1126 (WebKit::WebPage::changeAcceleratedCompositingMode):
1128 2011-01-19 Csaba Osztrogonác <ossy@webkit.org>
1130 Reviewed by Laszlo Gombos and Tor Arne Vestbø.
1132 [Qt] Remove unnecessary "../Source" from paths
1133 after moving source files into Source is finished.
1135 * DerivedSources.pro:
1138 2011-01-18 Maciej Stachowiak <mjs@apple.com>
1140 Reviewed by Sam Weinig.
1142 WebKitTestRunner should track loading more like DumpRenderTree
1143 https://bugs.webkit.org/show_bug.cgi?id=52692
1145 Relax the message check in didSaveFrameToPageCache a bit more, since
1146 layout tests were still hitting the old one.
1148 * UIProcess/WebPageProxy.cpp:
1149 (WebKit::isDisconnectedFrame):
1150 (WebKit::WebPageProxy::didSaveFrameToPageCache):
1152 2011-01-18 Brady Eidson <beidson@apple.com>
1154 Reviewed by Darin Adler.
1156 <rdar://problem/8860833> and https://bugs.webkit.org/show_bug.cgi?id=52599
1157 UIProcess crash in WebPageProxy::reattachToWebProcess when web process crashes with a new tab/window.
1159 * UIProcess/WebPageProxy.cpp:
1160 (WebKit::WebPageProxy::reattachToWebProcessWithItem): Null check item *both* places it is used.
1162 2011-01-18 Brady Eidson <beidson@apple.com>
1164 Reviewed by Maciej Stachowiak.
1166 <rdar://problem/8752200> and https://bugs.webkit.org/show_bug.cgi?id=52664
1167 Need WebKit2 API to asynchronously get the resource data for a URL
1169 Rename WKFrameGetMainResourceDataFunction to WKFrameGetResourceDataFunction, and add
1170 new API to get a resource by URL:
1171 * UIProcess/API/C/WKFrame.cpp:
1172 (WKFrameGetMainResourceData):
1173 (WKFrameGetResourceData):
1174 (callGetResourceDataBlockAndDispose):
1175 (WKFrameGetMainResourceData_b):
1176 (WKFrameGetResourceData_b):
1177 * UIProcess/API/C/WKFrame.h:
1179 Implement the new API in the UIProcess side:
1180 * UIProcess/WebFrameProxy.cpp:
1181 (WebKit::WebFrameProxy::getResourceData):
1182 * UIProcess/WebFrameProxy.h:
1183 * UIProcess/WebPageProxy.cpp:
1184 (WebKit::WebPageProxy::getResourceDataFromFrame):
1185 * UIProcess/WebPageProxy.h:
1187 Have the WebProcess get the data and call back to the UIProcess:
1188 * WebProcess/WebPage/WebPage.cpp:
1189 (WebKit::WebPage::getResourceDataFromFrame):
1190 * WebProcess/WebPage/WebPage.h:
1191 * WebProcess/WebPage/WebPage.messages.in:
1193 2011-01-18 Anders Carlsson <andersca@apple.com>
1195 Reviewed by Dan Bernstein.
1197 Make PageClientImpl::scrollView do hardware blitting
1198 https://bugs.webkit.org/show_bug.cgi?id=52689
1200 * UIProcess/API/mac/PageClientImpl.mm:
1201 (WebKit::PageClientImpl::scrollView):
1202 Clip the scroll rect and scroll the view.
1204 * UIProcess/DrawingAreaProxyImpl.cpp:
1205 (WebKit::DrawingAreaProxyImpl::incorporateUpdate):
1206 Scroll before painting.
1208 2011-01-18 Anders Carlsson <andersca@apple.com>
1210 Reviewed by Darin Adler.
1212 Artifacts when scrolling with new drawing area
1213 https://bugs.webkit.org/show_bug.cgi?id=52682
1215 * WebProcess/WebCoreSupport/WebChromeClient.cpp:
1216 (WebKit::WebChromeClient::scroll):
1217 When scrolling, we want the intersection of the scroll rect and clip rect.
1219 2011-01-18 Anders Carlsson <andersca@apple.com>
1221 Reviewed by Darin Adler.
1223 Use a CGLayer for the backing store when possible
1224 https://bugs.webkit.org/show_bug.cgi?id=52679
1226 * UIProcess/mac/BackingStoreMac.mm:
1227 (WebKit::BackingStore::paint):
1228 If there is a layer, paint it into the given context.
1230 (WebKit::BackingStore::backingStoreContext):
1231 If we can get the containing window graphics context, use it to create a
1232 CGLayer that we'll use for the backing store.
1234 (WebKit::BackingStore::scroll):
1235 Paint the layer into itself.
1237 * UIProcess/mac/WebPageProxyMac.mm:
1238 (WebKit::WebPageProxy::containingWindowGraphicsContext):
1239 Call the page client.
1241 2011-01-18 Anders Carlsson <andersca@apple.com>
1243 Reviewed by Dan Bernstein.
1245 Pass the web page proxy to BackingStore::create
1246 https://bugs.webkit.org/show_bug.cgi?id=52673
1248 * UIProcess/BackingStore.cpp:
1249 (WebKit::BackingStore::create):
1250 Add WebPageProxy parameter.
1252 (WebKit::BackingStore::BackingStore):
1253 Add WebPageProxy parameter.
1255 * UIProcess/BackingStore.h:
1256 Add WebPageProxy member variable.
1258 * UIProcess/DrawingAreaProxyImpl.cpp:
1259 (WebKit::DrawingAreaProxyImpl::incorporateUpdate):
1260 Pass the web page proxy when creating the backing store.
1262 * UIProcess/mac/BackingStoreMac.mm:
1263 (WebKit::BackingStore::backingStoreContext):
1264 Set the default blend mode.
1266 2011-01-18 Anders Carlsson <andersca@apple.com>
1268 Reviewed by Darin Adler.
1270 Factor code to create the backing store bitmap context out into a new function
1271 https://bugs.webkit.org/show_bug.cgi?id=52670
1273 * UIProcess/BackingStore.h:
1274 * UIProcess/mac/BackingStoreMac.mm:
1275 (WebKit::BackingStore::backingStoreContext):
1276 Create the backing store context.
1278 (WebKit::BackingStore::incorporateUpdate):
1279 Call backingStoreContext.
1281 (WebKit::BackingStore::scroll):
1282 Assert that the context is not null.
1284 2011-01-18 Anders Carlsson <andersca@apple.com>
1286 Reviewed by Dan Bernstein.
1288 Add PageClientImpl::containingWindowGraphicsContext
1289 https://bugs.webkit.org/show_bug.cgi?id=52666
1291 * UIProcess/API/mac/PageClientImpl.h:
1292 * UIProcess/API/mac/PageClientImpl.mm:
1293 (WebKit::PageClientImpl::containingWindowGraphicsContext):
1294 * UIProcess/PageClient.h:
1295 * UIProcess/WebPageProxy.h:
1297 2011-01-18 Damian Kaleta <dkaleta@apple.com>
1299 Reviewed by Sam Weinig.
1301 WK2 methods WKPageScaleWebView and WKPageGetViewScaleFactor need to have consistent names
1302 https://bugs.webkit.org/show_bug.cgi?id=52647
1304 * UIProcess/API/C/WKPage.cpp:
1305 (WKPageSetScaleFactor):
1306 (WKPageGetScaleFactor):
1307 * UIProcess/API/C/WKPage.h:
1309 2011-01-18 Anders Carlsson <andersca@apple.com>
1311 Reviewed by Dan Bernstein.
1313 Ask the web page proxy to scroll the view when needed
1314 https://bugs.webkit.org/show_bug.cgi?id=52665
1316 * UIProcess/DrawingAreaProxyImpl.cpp:
1317 (WebKit::DrawingAreaProxyImpl::incorporateUpdate):
1318 * UIProcess/WebPageProxy.cpp:
1319 (WebKit::WebPageProxy::scrollView):
1320 * UIProcess/WebPageProxy.h:
1322 2011-01-18 Anders Carlsson <andersca@apple.com>
1326 * UIProcess/win/WebView.cpp:
1327 (WebKit::WebView::scrollView):
1329 2011-01-18 Anders Carlsson <andersca@apple.com>
1331 Reviewed by Sam Weinig.
1333 Add PageClient::scrollView
1334 https://bugs.webkit.org/show_bug.cgi?id=52663
1336 * UIProcess/API/mac/PageClientImpl.h:
1337 * UIProcess/API/mac/PageClientImpl.mm:
1338 (WebKit::PageClientImpl::scrollView):
1339 * UIProcess/API/qt/qwkpage.cpp:
1340 (QWKPagePrivate::scrollView):
1341 * UIProcess/API/qt/qwkpage_p.h:
1342 * UIProcess/PageClient.h:
1343 * UIProcess/win/WebView.cpp:
1344 (WebKit::PageClientImpl::scrollView):
1345 * UIProcess/win/WebView.h:
1347 2011-01-18 Anders Carlsson <andersca@apple.com>
1349 Reviewed by Sam Weinig.
1351 Rename scrollDelta to scrollOffset everywhere.
1353 * Shared/UpdateInfo.cpp:
1354 (WebKit::UpdateInfo::encode):
1355 (WebKit::UpdateInfo::decode):
1356 * Shared/UpdateInfo.h:
1357 * UIProcess/BackingStore.h:
1358 * UIProcess/mac/BackingStoreMac.mm:
1359 (WebKit::BackingStore::incorporateUpdate):
1360 (WebKit::BackingStore::scroll):
1361 * WebProcess/WebCoreSupport/WebChromeClient.cpp:
1362 (WebKit::WebChromeClient::scroll):
1363 (WebKit::WebChromeClient::delegatedScrollRequested):
1364 * WebProcess/WebCoreSupport/WebChromeClient.h:
1365 * WebProcess/WebPage/ChunkedUpdateDrawingArea.cpp:
1366 (WebKit::ChunkedUpdateDrawingArea::scroll):
1367 * WebProcess/WebPage/ChunkedUpdateDrawingArea.h:
1368 * WebProcess/WebPage/DrawingArea.h:
1369 * WebProcess/WebPage/DrawingAreaImpl.cpp:
1370 (WebKit::DrawingAreaImpl::scroll):
1371 (WebKit::DrawingAreaImpl::display):
1372 * WebProcess/WebPage/DrawingAreaImpl.h:
1373 * WebProcess/WebPage/LayerBackedDrawingArea.cpp:
1374 (WebKit::LayerBackedDrawingArea::scroll):
1375 * WebProcess/WebPage/LayerBackedDrawingArea.h:
1377 2011-01-18 Anders Carlsson <andersca@apple.com>
1379 Reviewed by Sam Weinig.
1381 Get and paint each individual rect in -[WKView drawRect:]
1382 https://bugs.webkit.org/show_bug.cgi?id=52660
1384 * UIProcess/API/mac/WKView.mm:
1385 (-[WKView drawRect:]):
1387 2011-01-18 Anders Carlsson <andersca@apple.com>
1389 Reviewed by Darin Adler.
1391 Assertion when loading two URLs in quick succession
1392 https://bugs.webkit.org/show_bug.cgi?id=52649
1393 <rdar://problem/8764645>
1395 If beginLoad is called twice without didStartProvisionalLoad being called in between,
1396 m_pendingProvisionalSandboxExtension would be non-null and an assert would fire.
1398 * WebProcess/WebPage/WebPage.cpp:
1399 (WebKit::WebPage::SandboxExtensionTracker::beginLoad):
1400 Instead of asserting that m_pendingProvisionalSandboxExtension is null, invalidate it
1401 if it is not null, since that's valid.
1403 2011-01-18 Anders Carlsson <andersca@apple.com>
1405 Reviewed by Sam Weinig.
1407 Implement NPN_PopUpContextMenu
1408 https://bugs.webkit.org/show_bug.cgi?id=52646
1409 <rdar://problem/8735616>
1411 * WebProcess/Plugins/Netscape/NetscapeBrowserFuncs.cpp:
1412 (WebKit::NPN_PopUpContextMenu):
1413 Call NetscapePlugin::popUpContextMenu.
1415 * WebProcess/Plugins/Netscape/NetscapePlugin.cpp:
1416 (WebKit::NetscapePlugin::NetscapePlugin):
1417 Initialize m_currentMouseEvent.
1419 * WebProcess/Plugins/Netscape/NetscapePlugin.h:
1420 Add m_currentMouseEvent.
1422 * WebProcess/Plugins/Netscape/mac/NetscapePluginMac.mm:
1423 (WebKit::NetscapePlugin::popUpContextMenu):
1424 Convert the coordinates from the current mouse event to screen coordinates and call
1427 (WebKit::NetscapePlugin::platformHandleMouseEvent):
1428 Update m_currentMouseEvent.
1430 2011-01-18 Jessie Berlin <jberlin@apple.com>
1432 Reviewed by Darin Adler.
1434 WebKit2: Do not assert that the provisional and committed URLs cannot be empty/null
1435 https://bugs.webkit.org/show_bug.cgi?id=52641
1437 * UIProcess/WebFrameProxy.cpp:
1438 (WebKit::WebFrameProxy::didStartProvisionalLoad):
1439 (WebKit::WebFrameProxy::didCommitLoad):
1440 (WebKit::WebFrameProxy::didFinishLoad):
1442 2011-01-18 Anders Carlsson <andersca@apple.com>
1444 Reviewed by Sam Weinig.
1446 ASSERT in plug-in code when going to youtube
1447 https://bugs.webkit.org/show_bug.cgi?id=52638
1449 * PluginProcess/PluginControllerProxy.cpp:
1450 (WebKit::PluginControllerProxy::paintEntirePlugin):
1451 Don't try to paint the plug-in if the plug-in frame is empty.
1453 2011-01-18 Anders Carlsson <andersca@apple.com>
1455 Reviewed by Dan Bernstein.
1457 Plug-in hosting WebProcess instances appear in Activity Monitor as WebProcess
1458 https://bugs.webkit.org/show_bug.cgi?id=52635
1459 <rdar://problem/8731337>
1461 * PluginProcess/PluginProcess.cpp:
1462 (WebKit::PluginProcess::initialize):
1463 Call platformInitialize.
1465 * PluginProcess/PluginProcess.h:
1466 Add platformInitialize.
1468 * PluginProcess/mac/PluginProcessMac.mm:
1469 (WebKit::PluginProcess::platformInitialize):
1470 Set the compositing render server port and the visible application name.
1472 * Shared/Plugins/PluginProcessCreationParameters.cpp:
1473 (WebKit::PluginProcessCreationParameters::encode):
1474 (WebKit::PluginProcessCreationParameters::decode):
1475 Encode/decode the parent process name.
1477 * Shared/Plugins/PluginProcessCreationParameters.h:
1478 Add parentProcessName.
1480 * Shared/WebProcessCreationParameters.cpp:
1481 (WebKit::WebProcessCreationParameters::encode):
1482 (WebKit::WebProcessCreationParameters::decode):
1483 Encode/decode the parent process name.
1485 * Shared/WebProcessCreationParameters.h:
1486 Add parentProcessName.
1488 * UIProcess/Launcher/mac/ProcessLauncherMac.mm:
1489 (WebKit::ProcessLauncher::launchProcess):
1490 Don't pass the parent process name here.
1492 * UIProcess/Plugins/mac/PluginProcessProxyMac.mm:
1493 (WebKit::PluginProcessProxy::platformInitializePluginProcess):
1494 Set the visible name.
1496 * UIProcess/mac/WebContextMac.mm:
1497 (WebKit::WebContext::platformInitializeWebProcess):
1498 Pass along the parent process name.
1500 * WebProcess/mac/WebProcessMac.mm:
1501 (WebKit::WebProcess::platformInitializeWebProcess):
1502 Set the visible name.
1504 * WebProcess/mac/WebProcessMainMac.mm:
1505 (WebKit::WebProcessMain):
1506 Don't set the visible name here. It's done in platformInitializeWebProcess.
1508 2011-01-18 Balazs Kelemen <kbalazs@webkit.org>
1510 Reviewed by Csaba Osztrogonác.
1512 [Qt][WK2] Not implemented warnings should not break layout tests
1513 https://bugs.webkit.org/show_bug.cgi?id=52616
1515 * WebKit2Prefix.h: Define DISABLE_NOT_IMPLEMENTED_WARNINGS on Qt.
1517 2011-01-17 Jon Honeycutt <jhoneycutt@apple.com>
1519 Windows build fix. Unreviewed.
1521 * Shared/PrintInfo.cpp:
1522 Use #include, not #import.
1524 2011-01-17 Alexey Proskuryakov <ap@apple.com>
1526 Actually wrote a FIXME promised for a review comment.
1528 * UIProcess/API/mac/WKView.mm:
1529 (-[WKView _recursiveDisplayRectIfNeededIgnoringOpacity:isVisibleRect:rectIsVisibleRectForView:topView:]):
1531 2011-01-17 Alexey Proskuryakov <ap@apple.com>
1533 Reviewed by Anders Carlsson and Darin Adler.
1535 https://bugs.webkit.org/show_bug.cgi?id=52595
1536 Make basic printing work in WebKit2
1538 * Shared/WebPreferencesStore.h:
1539 * UIProcess/API/C/WKPreferences.cpp:
1540 (WKPreferencesSetShouldPrintBackgrounds):
1541 (WKPreferencesGetShouldPrintBackgrounds):
1542 * UIProcess/API/C/WKPreferences.h:
1543 Implement a preference for printing backgrounds.
1545 * Shared/PrintInfo.cpp: Added.
1546 (WebKit::PrintInfo::encode):
1547 (WebKit::PrintInfo::decode):
1548 * Shared/PrintInfo.h: Added.
1549 * Shared/mac/PrintInfoMac.mm: Added.
1550 (WebKit::PrintInfo::PrintInfo):
1551 A new class for passing page setup information down to the web process.
1553 * WebKit2.xcodeproj/project.pbxproj:
1556 * win/WebKit2.vcproj:
1559 * Scripts/webkit2/messages.py: Added PrintInfo.h to a list of structs.
1561 * UIProcess/API/mac/WKView.mm:
1562 (WKViewData): Cache page count and geometry.
1563 (WebFrameWrapper): Added a wrapper class for adding a WebFrameProxy to an NSDictionary.
1564 (-[WKView drawRect:]): Added logging.
1565 (setFrameBeingPrinted): Store a frame into NSPrintOperation's NSPrintInfo, so that all
1566 methods invoked for this operation would know what's being printed.
1567 (frameBeingPrinted): Retrieve this data.
1568 (-[WKView printOperationWithPrintInfo:forFrame:]): Create a print operation that's appropriate
1570 (-[WKView knowsPageRange:]): Ask the web process.
1571 (-[WKView _recursiveDisplayRectIfNeededIgnoringOpacity:isVisibleRect:rectIsVisibleRectForView:topView:]):
1572 Take over printing, because I couldn't make drawRect: work correctly with WebKit custom fit
1573 to page implementation.
1574 (-[WKView _provideTotalScaleFactorForPrintOperation:]): Help AppKit clip correctly.
1575 (-[WKView rectForPage:]): Return a pre-calculated rect.
1577 * UIProcess/WebPageProxy.h: Added m_isInPrintingMode to track whether the web page is in
1578 printing mode. The UI process controls that.
1580 * UIProcess/WebPageProxy.cpp:
1581 (WebKit::WebPageProxy::WebPageProxy): Initialize m_isInPrintingMode.
1582 (WebKit::WebPageProxy::beginPrinting): Change printing mode in web process if the value changes.
1583 (WebKit::WebPageProxy::endPrinting): Ditto.
1584 (WebKit::WebPageProxy::computePagesForPrinting): Ask the web process about output page geometry.
1585 (WebKit::WebPageProxy::drawRectToPDF): Ask the web process about printed page data.
1587 * WebProcess/WebPage/WebPage.cpp:
1588 (WebKit::WebPage::close): Delete m_printContext while there is still a Frame pointer.
1589 (WebKit::WebPage::updatePreferences): Pass through ShouldPrintBackgrounds.
1590 (WebKit::WebPage::beginPrinting): Switch into printing mode (or update parameters if we're
1591 already in printing mode).
1592 (WebKit::WebPage::endPrinting): Delete m_printContext, implicitly calling end().
1593 (WebKit::WebPage::computePagesForPrinting): Make sure that we're in printing mode, and
1595 (WebKit::WebPage::drawRectToPDF): Added a CG specific function to create a PDF document out
1596 of a page rect. It should really work for onscreen content, but we only need it for printing.
1598 * WebProcess/WebPage/WebPage.h:
1600 * WebProcess/WebPage/WebPage.messages.in: Added BeginPrinting, EndPrinting,
1601 ComputePagesForPrinting and DrawRectToPDF.
1603 2011-01-17 Tony Gentilcore <tonyg@chromium.org>
1605 Reviewed by Alexey Proskuryakov.
1607 Fix some headers with missing or misspelled #ifndef guards
1608 https://bugs.webkit.org/show_bug.cgi?id=52545
1610 * Shared/UserMessageCoders.h:
1611 * WebProcess/InjectedBundle/DOM/InjectedBundleNodeHandle.h:
1612 * WebProcess/InjectedBundle/InjectedBundleUserMessageCoders.h:
1613 * WebProcess/WebProcessMain.h:
1615 2011-01-17 Alexey Proskuryakov <ap@apple.com>
1619 * Platform/Logging.cpp:
1621 2011-01-17 Alexey Proskuryakov <ap@apple.com>
1623 Reviewed by Dan Bernstein.
1625 https://bugs.webkit.org/show_bug.cgi?id=52592
1626 Add a logging channel for WKView
1628 * Platform/Logging.cpp:
1629 * Platform/Logging.h:
1631 2011-01-17 Anders Carlsson <andersca@apple.com>
1633 Reviewed by Sam Weinig.
1635 Factor bitmap context drawing code out into a shared function
1636 https://bugs.webkit.org/show_bug.cgi?id=52589
1638 * Platform/cg/CGUtilities.h: Added.
1639 * Platform/cg/CGUtilities.cpp: Added.
1640 (WebKit::paintBitmapContext):
1641 New function that will paint a bitmap context into a CGContext.
1643 * Shared/cg/ShareableBitmapCG.cpp:
1644 (WebKit::ShareableBitmap::paint):
1645 Use paintBitmapContext.
1647 * UIProcess/mac/BackingStoreMac.mm:
1648 (WebKit::BackingStore::paint):
1649 (WebKit::BackingStore::scroll):
1650 Use paintBitmapContext.
1652 * WebKit2.xcodeproj/project.pbxproj:
1653 * win/WebKit2.vcproj:
1654 * win/WebKit2Common.vsprops:
1655 Add CGUtilities.{cpp|h}.
1657 2011-01-17 Dan Bernstein <mitz@apple.com>
1659 Rubber-stamped by Mark Rowe.
1661 Update xcodeproj svn:ignore to include xcuserdata.
1663 * WebKit2.xcodeproj: Modified property svn:ignore.
1665 2011-01-17 Alexey Proskuryakov <ap@apple.com>
1667 Fixing a typo from a bad merge.
1669 * UIProcess/API/mac/WKView.mm: (-[WKView canChangeFrameLayout:]):
1671 2011-01-17 Alexey Proskuryakov <ap@apple.com>
1673 Reviewed by John Sullivan.
1675 https://bugs.webkit.org/show_bug.cgi?id=52590
1676 Should pass a frame into -[WKView canPrintHeadersAndFooters]
1678 * UIProcess/API/mac/WKView.h:
1679 * UIProcess/API/mac/WKView.mm: (-[WKView canChangeFrameLayout:]): Also, renamed the method
1680 to canChangeFrameLayout.
1682 2011-01-17 Anders Carlsson <andersca@apple.com>
1684 Reviewed by Sam Weinig.
1686 Implement scrolling support
1687 https://bugs.webkit.org/show_bug.cgi?id=52502
1689 * Shared/UpdateInfo.cpp:
1690 (WebKit::UpdateInfo::encode):
1691 (WebKit::UpdateInfo::decode):
1692 * Shared/UpdateInfo.h:
1693 Add scrollRect and scrollDelta member variables.
1695 * UIProcess/BackingStore.h:
1696 Add scroll member function.
1698 * UIProcess/DrawingAreaProxyImpl.cpp:
1699 (WebKit::DrawingAreaProxyImpl::incorporateUpdate):
1700 Repaint the scroll rect. Force a display of the view when the update info contains a scroll rect.
1702 * UIProcess/mac/BackingStoreMac.mm:
1703 (WebKit::BackingStore::incorporateUpdate):
1706 (WebKit::BackingStore::scroll):
1707 Paint the backing store into itself.
1709 * WebProcess/WebPage/DrawingAreaImpl.cpp:
1710 (WebKit::DrawingAreaImpl::display):
1711 Pass the scroll information in the update info.
1713 2011-01-17 Andrey Kosyakov <caseq@chromium.org>
1715 Unreviewed. Fixed malformed reference to WebKitVSPropsRedirectionDir that broke win build.
1717 * win/WebKit2.vcproj:
1718 * win/WebKit2GeneratedCommon.vsprops:
1719 * win/WebKit2WebProcess.vcproj:
1721 2011-01-17 Pavel Feldman <pfeldman@chromium.org>
1723 Reviewed by Yury Semikhatsky.
1725 Web Inspector: simplify debugger enabling routine.
1726 https://bugs.webkit.org/show_bug.cgi?id=52472
1728 * WebProcess/WebPage/WebInspector.cpp:
1729 (WebKit::WebInspector::startJavaScriptDebugging):
1731 2011-01-17 Balazs Kelemen <kbalazs@webkit.org>
1733 Reviewed by Andreas Kling.
1735 [Qt][WK2] Crash due to double destruction of QSharedMemory
1736 https://bugs.webkit.org/show_bug.cgi?id=52569
1738 Avoid deleting the QSharedMemory twice.
1739 * Platform/qt/SharedMemoryQt.cpp:
1740 (WebKit::SharedMemory::~SharedMemory):
1741 * Shared/qt/CleanupHandler.cpp:
1742 Renamed m_inDeleteObjects to m_hasStartedDeleting and
1743 added a getter for it.
1744 (WebKit::CleanupHandler::CleanupHandler):
1745 (WebKit::CleanupHandler::deleteObjects):
1746 * Shared/qt/CleanupHandler.h:
1747 (WebKit::CleanupHandler::unmark):
1748 (WebKit::CleanupHandler::hasStartedDeleting):
1750 2011-01-15 Adam Barth <abarth@webkit.org>
1752 Rubber-stamped by Eric Seidel.
1754 Move WebKit2 into Source
1755 https://bugs.webkit.org/show_bug.cgi?id=52438
1757 * DerivedSources.pro:
1761 * win/WebKit2.vcproj:
1762 * win/WebKit2WebProcess.vcproj:
1764 2011-01-14 Yuzo Fujishima <yuzo@google.com>
1766 Reviewed by Antti Koivisto.
1768 Rename cache() to memoryCache()
1769 https://bugs.webkit.org/show_bug.cgi?id=52433
1771 * WebProcess/WebProcess.cpp:
1772 (WebKit::WebProcess::shutdownIfPossible):
1773 (WebKit::WebProcess::didClose):
1774 * WebProcess/mac/WebProcessMac.mm:
1775 (WebKit::WebProcess::platformSetCacheModel):
1776 * WebProcess/win/WebProcessWin.cpp:
1777 (WebKit::WebProcess::platformSetCacheModel):
1779 2011-01-13 Geoffrey Garen <ggaren@apple.com>
1781 Reviewed by Oliver Hunt.
1783 Split out a MarkedSpace strategy object from Heap.
1784 https://bugs.webkit.org/show_bug.cgi?id=52421
1786 * Shared/mac/WebMemorySampler.mac.mm:
1787 (WebKit::WebMemorySampler::sampleWebKit): Updated for class move.
1789 2011-01-14 Anders Carlsson <andersca@apple.com>
1791 Reviewed by Dan Bernstein.
1793 Add a new PageClient::displayView function and expose it on WebPageProxy
1794 https://bugs.webkit.org/show_bug.cgi?id=52500
1796 * UIProcess/API/mac/PageClientImpl.h:
1797 * UIProcess/API/mac/PageClientImpl.mm:
1798 (WebKit::PageClientImpl::displayView):
1799 * UIProcess/API/qt/qwkpage.cpp:
1800 (QWKPagePrivate::displayView):
1801 * UIProcess/API/qt/qwkpage_p.h:
1802 * UIProcess/PageClient.h:
1803 * UIProcess/WebPageProxy.cpp:
1804 (WebKit::WebPageProxy::displayView):
1805 * UIProcess/WebPageProxy.h:
1806 * UIProcess/win/WebView.cpp:
1807 (WebKit::WebView::displayView):
1808 * UIProcess/win/WebView.h:
1810 2011-01-14 Anders Carlsson <andersca@apple.com>
1812 Reviewed by Sam Weinig.
1814 Implement the "should paint bounds instead of indiviual rects" algorithm from WebKit1
1815 https://bugs.webkit.org/show_bug.cgi?id=52499
1817 * WebProcess/WebPage/DrawingAreaImpl.cpp:
1818 (WebKit::shouldPaintBoundsRect):
1819 Port code from -[WebView _mustDrawUnionedRect:singleRects:count:].
1821 (WebKit::DrawingAreaImpl::display):
1822 If shouldPaintBoundsRect returns true, clear the rects vector and append the bounds rect.
1824 2011-01-14 Brian Weinstein <bweinstein@apple.com>
1826 Reviewed by Geoff Garen.
1828 ShouldLoadResourceForFrame should use strings, not URLs.
1829 https://bugs.webkit.org/show_bug.cgi?id=52476
1831 * WebProcess/InjectedBundle/API/c/WKBundlePage.h:
1832 * WebProcess/InjectedBundle/InjectedBundlePageLoaderClient.cpp:
1833 (WebKit::InjectedBundlePageLoaderClient::shouldLoadResourceForFrame): Pass resourceURL as a string instead of
1834 a URL, and rename from subresourceURL to resourceURL.
1836 2011-01-14 Anders Carlsson <andersca@apple.com>
1838 Reviewed by Sam Weinig.
1840 Fix for <rdar://problem/8711576> The web process should be able to read resources from the UI process.
1842 Based on a patch by Ivan Krstić. This also makes the NSURLCache path a sandbox parameter.
1844 * Shared/WebProcessCreationParameters.cpp:
1845 (WebKit::WebProcessCreationParameters::encode):
1846 (WebKit::WebProcessCreationParameters::decode):
1847 Encode and decode the uiProcessBundleResourcePath member variable.
1849 * Shared/WebProcessCreationParameters.h:
1850 Add uiProcessBundleResourcePath member variable.
1852 * UIProcess/mac/WebContextMac.mm:
1853 (WebKit::WebContext::platformInitializeWebProcess):
1854 Set the uiProcessBundleResourcePath member variable.
1856 * WebProcess/com.apple.WebProcess.sb:
1857 Allow read-only access to UI_PROCESS_BUNDLE_RESOURCE_DIR and all subdirectories.
1859 * WebProcess/mac/WebProcessMac.mm:
1860 (WebKit::initializeSandbox):
1861 When initializing the sandbox, pass UI_PROCESS_BUNDLE_RESOURCE_DIR.
1863 (WebKit::WebProcess::platformInitializeWebProcess):
1864 Remove the code that would consume a sandbox extension for the url cache path.
1866 2011-01-14 Anders Carlsson <andersca@apple.com>
1868 Reviewed by Sam Weinig.
1870 Delay initializing the sandbox until we get the InitializeWebProcess message.
1872 * WebProcess/mac/WebProcessMac.mm:
1873 (WebKit::initializeSandbox):
1874 (WebKit::WebProcess::platformInitializeWebProcess):
1875 * WebProcess/mac/WebProcessMainMac.mm:
1876 (WebKit::WebProcessMain):
1878 2011-01-14 Laszlo Gombos <laszlo.1.gombos@nokia.com>
1880 Reviewed by Kenneth Rohde Christiansen.
1882 Align import/export directives
1883 https://bugs.webkit.org/show_bug.cgi?id=52208
1885 * Shared/API/c/WKBase.h: Align import/export directives with
1886 JavaScriptCore/API/JSBase.h.
1888 2011-01-14 Pavel Feldman <pfeldman@chromium.org>
1890 Reviewed by Yury Semikhatsky.
1892 Web Inspector: extract InspectorSettings from InspectorState,
1894 https://bugs.webkit.org/show_bug.cgi?id=52429
1896 * WebProcess/WebCoreSupport/WebInspectorClient.cpp:
1898 2011-01-13 Enrica Casucci <enrica@apple.com>
1900 Reviewed by Darin Adler.
1902 WebKit2: Add support for drag and drop
1903 https://bugs.webkit.org/show_bug.cgi?id=52343
1904 <rdar://problem/7660558>
1906 This patch contains the changes required to support dropping content
1907 in WebKit on the Mac. The DragData class has been extended to provide
1908 additional context from the application (keyboard state, modal windows, etc.)
1909 as well as information of the drag pasteboard being used.
1910 The support for WebKit as drag source will be added with a separate patch.
1912 * Shared/DragControllerAction.h: Added.
1913 * UIProcess/API/mac/WKView.mm:
1914 Added implemention of the methods required to add suport for a drop target.
1915 To maintain asynchronous communication with the WebProcess, we always return
1916 the previous calculated value for the drag operation.
1917 (-[WKView _registerDraggedTypes]):
1918 (-[WKView initWithFrame:contextRef:pageGroupRef:]):
1919 (-[WKView applicationFlags:]):
1920 (-[WKView draggingEntered:]):
1921 (-[WKView draggingUpdated:]):
1922 (-[WKView draggingExited:]):
1923 (-[WKView prepareForDragOperation:]):
1924 (-[WKView performDragOperation:]):
1925 * UIProcess/WebPageProxy.cpp:
1926 (WebKit::WebPageProxy::WebPageProxy):
1927 (WebKit::WebPageProxy::performDragControllerAction):
1928 (WebKit::WebPageProxy::didPerformDragControllerAction):
1929 * UIProcess/WebPageProxy.h:
1930 (WebKit::WebPageProxy::dragOperation):
1931 (WebKit::WebPageProxy::resetDragOperation):
1932 * UIProcess/WebPageProxy.messages.in:
1933 * WebKit2.xcodeproj/project.pbxproj:
1934 * WebProcess/WebCoreSupport/WebDragClient.cpp:
1935 (WebKit::WebDragClient::willPerformDragDestinationAction):
1936 (WebKit::WebDragClient::willPerformDragSourceAction):
1937 (WebKit::WebDragClient::actionMaskForDrag):
1938 (WebKit::WebDragClient::dragSourceActionMaskForPoint):
1939 (WebKit::WebDragClient::startDrag):
1940 * WebProcess/WebPage/WebPage.cpp:
1941 (WebKit::WebPage::performDragControllerAction):
1942 * WebProcess/WebPage/WebPage.h:
1943 * WebProcess/WebPage/WebPage.messages.in:
1945 2011-01-13 Dan Bernstein <mitz@apple.com>
1947 Reviewed by John Sullivan.
1949 Incorrect assertion in DrawingAreaImpl::scroll()
1950 https://bugs.webkit.org/show_bug.cgi?id=52376
1952 * WebProcess/WebPage/DrawingAreaImpl.cpp:
1953 (WebKit::DrawingAreaImpl::scroll): Changed to take the fast path if the rects have the same area.
1954 This made the assertion valid, but I removed it anyway.
1956 2011-01-12 Balazs Kelemen <kbalazs@webkit.org>
1960 Getting rid of the unused 'viewportSize' argument in QWKPagePrivate:init.
1961 The argument is unused since http://trac.webkit.org/changeset/75468.
1963 * UIProcess/API/qt/qgraphicswkview.cpp:
1964 (QGraphicsWKView::QGraphicsWKView):
1965 * UIProcess/API/qt/qwkpage.cpp:
1966 (QWKPagePrivate::init):
1967 * UIProcess/API/qt/qwkpage_p.h:
1969 2011-01-12 Anders Carlsson <andersca@apple.com>
1971 Reviewed by Sam Weinig.
1973 Implement DrawingAreaImpl::scroll
1974 https://bugs.webkit.org/show_bug.cgi?id=52346
1976 * WebProcess/WebPage/DrawingAreaImpl.cpp:
1977 (WebKit::DrawingAreaImpl::scroll):
1978 If there is already an active scroll, compute the area of both scroll rects and
1979 invalidate the smallest one. Compute a new dirty region if necessary and also
1980 add the scroll repaint region to the dirty region.
1982 (WebKit::DrawingAreaImpl::display):
1983 Reset the scroll area and scroll delta.
1985 * WebProcess/WebPage/DrawingAreaImpl.h:
1986 Add scroll area and scroll delta member variables.
1988 2011-01-12 Anders Carlsson <andersca@apple.com>
1990 Reviewed by Dan Bernstein.
1993 https://bugs.webkit.org/show_bug.cgi?id=52344
1995 * Platform/Region.cpp:
1996 (WebKit::Region::Shape::move):
1997 (WebKit::Region::move):
1998 Change Region::move to take an IntSize.
2000 * Platform/Region.h:
2001 (WebKit::intersect):
2004 Add convenience functions.
2006 2011-01-12 Ryosuke Niwa <rniwa@webkit.org>
2008 Unreviewed Qt build fix for r75661
2010 * Shared/WebEvent.h: Don't declare phase() on non-Mac platforms.
2012 2011-01-12 Beth Dakin <bdakin@apple.com>
2014 Reviewed by Anders Carlsson.
2016 Add-on for https://bugs.webkit.org/show_bug.cgi?id=52309
2017 Expose fixed layout through WebKit SPI
2019 <rdar://problem/8844464>
2021 And now with getters!
2022 * UIProcess/API/C/WKPage.cpp:
2023 (WKPageUseFixedLayout):
2024 (WKPageFixedLayoutSize):
2025 * UIProcess/API/C/WKPage.h:
2026 * UIProcess/WebPageProxy.h:
2027 (WebKit::WebPageProxy::useFixedLayout):
2028 (WebKit::WebPageProxy::fixedLayoutSize):
2030 2011-01-12 Sam Weinig <sam@webkit.org>
2032 Reviewed by Anders Carlsson.
2034 https://bugs.webkit.org/show_bug.cgi?id=52337
2035 PlatformWheelEvent should know about the scroll phase on the Mac
2037 Add a phase parameter on Mac WebWheelEvent and pipe it down to PlatformWheelEvent.
2039 * Shared/WebEvent.h:
2040 (WebKit::WebWheelEvent::phase):
2041 * Shared/WebEventConversion.cpp:
2042 (WebKit::WebKit2PlatformWheelEvent::WebKit2PlatformWheelEvent):
2043 * Shared/WebWheelEvent.cpp:
2044 (WebKit::WebWheelEvent::WebWheelEvent):
2045 (WebKit::WebWheelEvent::encode):
2046 (WebKit::WebWheelEvent::decode):
2047 * Shared/mac/WebEventFactory.mm:
2048 (WebKit::phaseForEvent):
2049 (WebKit::WebEventFactory::createWebWheelEvent):
2051 2011-01-12 Anders Carlsson <andersca@apple.com>
2053 Reviewed by Sam Weinig.
2055 Get rid of an unneeded parameter from DrawingArea::scroll
2056 https://bugs.webkit.org/show_bug.cgi?id=52336
2058 * WebProcess/WebCoreSupport/WebChromeClient.cpp:
2059 (WebKit::WebChromeClient::scroll):
2060 * WebProcess/WebCoreSupport/WebChromeClient.h:
2061 * WebProcess/WebPage/ChunkedUpdateDrawingArea.cpp:
2062 (WebKit::ChunkedUpdateDrawingArea::scroll):
2063 * WebProcess/WebPage/ChunkedUpdateDrawingArea.h:
2064 * WebProcess/WebPage/DrawingArea.h:
2065 * WebProcess/WebPage/DrawingAreaImpl.cpp:
2066 (WebKit::DrawingAreaImpl::scroll):
2067 * WebProcess/WebPage/DrawingAreaImpl.h:
2068 * WebProcess/WebPage/LayerBackedDrawingArea.cpp:
2069 (WebKit::LayerBackedDrawingArea::scroll):
2070 * WebProcess/WebPage/LayerBackedDrawingArea.h:
2071 * WebProcess/WebPage/TiledDrawingArea.cpp:
2072 (WebKit::TiledDrawingArea::scroll):
2073 * WebProcess/WebPage/TiledDrawingArea.h:
2075 2011-01-12 Anders Carlsson <andersca@apple.com>
2077 Reviewed by Sam Weinig.
2079 Get the new drawing area painting to the screen
2080 https://bugs.webkit.org/show_bug.cgi?id=52331
2082 * UIProcess/DrawingAreaProxyImpl.cpp:
2083 (WebKit::DrawingAreaProxyImpl::incorporateUpdate):
2084 Call setViewNeedsDisplay on all the update rects.
2086 * UIProcess/WebPageProxy.cpp:
2087 (WebKit::WebPageProxy::setViewNeedsDisplay):
2088 Call through to the page client.
2090 (WebKit::WebPageProxy::processDidCrash):
2091 Null out the drawing area proxy.
2093 * UIProcess/mac/BackingStoreMac.mm:
2094 (WebKit::BackingStore::paint):
2097 2011-01-12 Anders Carlsson <andersca@apple.com>
2099 Reviewed by Sam Weinig.
2101 More work on getting the drawing area proxy to paint
2102 https://bugs.webkit.org/show_bug.cgi?id=52328
2104 * UIProcess/API/mac/WKView.mm:
2105 (-[WKView drawRect:]):
2106 Handle the new drawing area.
2108 * UIProcess/BackingStore.cpp:
2109 (WebKit::BackingStore::BackingStore):
2110 Assert that the size isn't empty.
2112 * UIProcess/BackingStore.h:
2113 * UIProcess/mac/BackingStoreMac.mm:
2114 (WebKit::BackingStore::incorporateUpdate):
2115 Paint all update rects into the bitmap context.
2117 * WebProcess/WebPage/DrawingAreaImpl.cpp:
2118 (WebKit::DrawingAreaImpl::display):
2119 Create a handle so the shareable bitmap will actually be transferred over.
2121 2011-01-12 Anders Carlsson <andersca@apple.com>
2125 * UIProcess/DrawingAreaProxyImpl.cpp:
2126 (WebKit::DrawingAreaProxyImpl::incorporateUpdate):
2128 2011-01-12 Anders Carlsson <andersca@apple.com>
2130 Reviewed by Sam Weinig.
2132 Begin stubbing out some more BackingStore member functions
2133 https://bugs.webkit.org/show_bug.cgi?id=52323
2135 * UIProcess/BackingStore.cpp:
2136 (WebKit::BackingStore::~BackingStore):
2137 This was accidentally made into a constructor; it should be a destructor.
2139 * UIProcess/DrawingAreaProxyImpl.cpp:
2140 (WebKit::DrawingAreaProxyImpl::paint):
2141 Call the backing store.
2143 (WebKit::DrawingAreaProxyImpl::update):
2144 Incorporate the update.
2146 (WebKit::DrawingAreaProxyImpl::incorporateUpdate):
2147 Create the backing store if needed and incorporate the update.
2149 * UIProcess/mac/BackingStoreMac.mm: Added.
2150 (WebKit::BackingStore::platformInitialize):
2151 Create a bitmap context.
2153 (WebKit::BackingStore::paint):
2154 (WebKit::BackingStore::incorporateUpdate):
2157 * WebKit2.xcodeproj/project.pbxproj:
2158 Add BackingStoreMac.mm
2160 2011-01-12 Beth Dakin <bdakin@apple.com>
2162 Reviewed by Anders Carlsson.
2164 Fix for https://bugs.webkit.org/show_bug.cgi?id=52309 Expose
2165 fixed layout through WebKit SPI
2167 <rdar://problem/8844464>
2169 Store useFixedLayout and fixedLayoutSize in the
2170 WebPageCreationParameters and the WebPageProxy.
2171 * Shared/WebPageCreationParameters.cpp:
2172 (WebKit::WebPageCreationParameters::encode):
2173 (WebKit::WebPageCreationParameters::decode):
2174 * Shared/WebPageCreationParameters.h:
2175 * UIProcess/API/C/WKPage.cpp:
2176 (WKPageSetUseFixedLayout):
2177 (WKPageSetFixedLayoutSize):
2178 * UIProcess/API/C/WKPage.h:
2179 * UIProcess/WebPageProxy.cpp:
2180 (WebKit::WebPageProxy::WebPageProxy):
2181 (WebKit::WebPageProxy::setUseFixedLayout):
2182 (WebKit::WebPageProxy::setFixedLayoutSize):
2183 (WebKit::WebPageProxy::creationParameters):
2184 * UIProcess/WebPageProxy.h:
2185 * WebProcess/WebPage/WebPage.cpp:
2186 (WebKit::WebPage::setUseFixedLayout):
2187 (WebKit::WebPage::setFixedLayoutSize):
2188 * WebProcess/WebPage/WebPage.h:
2189 * WebProcess/WebPage/WebPage.messages.in:
2191 2011-01-12 Anders Carlsson <andersca@apple.com>
2193 Reviewed by Beth Dakin.
2195 Add BackingStore class
2196 https://bugs.webkit.org/show_bug.cgi?id=52318
2198 * UIProcess/BackingStore.cpp: Added.
2199 (WebKit::BackingStore::create):
2200 (WebKit::BackingStore::BackingStore):
2201 * UIProcess/BackingStore.h: Added.
2202 * WebKit2.xcodeproj/project.pbxproj:
2204 2011-01-12 Brady Eidson <beidson@apple.com>
2206 Reviewed by Sam Weinig.
2208 <rdar://problem/8837307>, <rdar://problem/8637038>, and https://bugs.webkit.org/show_bug.cgi?id=52248
2209 Back/forward list recovery after a WebProcess crash is crashy itself.
2211 Add an isEmpty() accessor so the WebProcess knows if it is actually restoring a session:
2212 * Shared/SessionState.cpp:
2213 (WebKit::SessionState::isEmpty):
2214 * Shared/SessionState.h:
2216 Keep track of the highest used itemID so a relaunched WebProcess can later be informed:
2217 * Shared/WebBackForwardListItem.cpp:
2218 (WebKit::WebBackForwardListItem::WebBackForwardListItem):
2219 (WebKit::WebBackForwardListItem::highedUsedItemID):
2220 * Shared/WebBackForwardListItem.h:
2221 * WebProcess/WebPage/WebBackForwardListProxy.cpp:
2222 (WebKit::generateHistoryItemID):
2223 (WebKit::WebBackForwardListProxy::setHighestItemIDFromUIProcess):
2224 (WebKit::WebBackForwardListProxy::addItemFromUIProcess): Remove a now-invalid ASSERT, as the UIProcess
2225 now tells the WebProcess that a previous WebProcess created.
2226 * WebProcess/WebPage/WebBackForwardListProxy.h:
2228 Encode/decode data relevant to restoring a session on WebPage creation:
2229 * Shared/WebPageCreationParameters.cpp:
2230 (WebKit::WebPageCreationParameters::encode):
2231 (WebKit::WebPageCreationParameters::decode):
2232 * Shared/WebPageCreationParameters.h:
2234 If the WebProcess has crashed since the last load, change reload and the various back/forward APIs to
2235 update the current back/forward item (if necessary) then relaunch the process:
2236 * UIProcess/WebPageProxy.cpp:
2237 (WebKit::WebPageProxy::reattachToWebProcessWithItem):
2238 (WebKit::WebPageProxy::reattachToWebProcess): Renamed from "relaunch()" and made private.
2239 (WebKit::WebPageProxy::initializeWebPage):
2240 (WebKit::WebPageProxy::loadURL):
2241 (WebKit::WebPageProxy::loadURLRequest):
2242 (WebKit::WebPageProxy::reload):
2243 (WebKit::WebPageProxy::goForward):
2244 (WebKit::WebPageProxy::goBack):
2245 (WebKit::WebPageProxy::goToBackForwardItem):
2246 (WebKit::WebPageProxy::creationParameters):
2247 * UIProcess/WebPageProxy.h:
2249 Rename "RestoreSession" to "RestoreSessionAndNavigateToCurrentItem"
2250 * WebProcess/WebPage/WebPage.messages.in:
2251 * UIProcess/cf/WebPageProxyCF.cpp:
2252 (WebKit::WebPageProxy::restoreFromSessionStateData):
2254 Restore a session on page creation if the parameters include it:
2255 * WebProcess/WebPage/WebPage.cpp:
2256 (WebKit::WebPage::WebPage): Call restoreSession if session state exists.
2257 (WebKit::WebPage::restoreSessionAndNavigateToCurrentItem):
2258 (WebKit::WebPage::restoreSession):
2259 * WebProcess/WebPage/WebPage.h:
2261 2011-01-12 Anders Carlsson <andersca@apple.com>
2263 Reviewed by Sam Weinig.
2265 Send Update and DidUpdate messages
2266 https://bugs.webkit.org/show_bug.cgi?id=52316
2268 * UIProcess/DrawingAreaProxy.h:
2269 (WebKit::DrawingAreaProxy::update):
2272 * UIProcess/DrawingAreaProxy.messages.in:
2275 * UIProcess/DrawingAreaProxyImpl.cpp:
2276 (WebKit::DrawingAreaProxyImpl::update):
2277 Just send back a DidUpdate message.
2279 * WebProcess/WebPage/DrawingArea.h:
2280 (WebKit::DrawingArea::didUpdate):
2283 * WebProcess/WebPage/DrawingArea.messages.in:
2284 Add DidUpdate message.
2286 * WebProcess/WebPage/DrawingAreaImpl.cpp:
2287 (WebKit::DrawingAreaImpl::didUpdate):
2290 (WebKit::DrawingAreaImpl::display):
2291 Send an Update message.
2293 2011-01-12 Anders Carlsson <andersca@apple.com>
2295 Reviewed by Sam Weinig.
2297 Make the new drawing area actually draw something
2298 https://bugs.webkit.org/show_bug.cgi?id=52314
2300 * Shared/UpdateInfo.cpp:
2301 (WebKit::UpdateInfo::encode):
2302 (WebKit::UpdateInfo::decode):
2303 Encode and decode newly added fields.
2305 * Shared/UpdateInfo.h:
2306 Add a vector of update rects and a handle for the sharable bitmap.
2308 * WebProcess/WebPage/DrawingAreaImpl.cpp:
2309 (WebKit::DrawingAreaImpl::display):
2310 Get the individual rects from the region and paint them into the shareable bitmap.
2312 * WebProcess/WebPage/WebPage.cpp:
2313 (WebKit::WebPage::mainFrameHasCustomRepresentation):
2314 * WebProcess/WebPage/WebPage.h:
2315 Add helper function.
2317 * WebProcess/WebPage/mac/ChunkedUpdateDrawingAreaMac.cpp:
2318 (WebKit::ChunkedUpdateDrawingArea::paintIntoUpdateChunk):
2319 Use helper function.
2321 2011-01-12 Anders Carlsson <andersca@apple.com>
2323 Reviewed by Sam Weinig.
2325 Add UpdateInfo class
2326 https://bugs.webkit.org/show_bug.cgi?id=52306
2328 * Shared/UpdateInfo.cpp: Added.
2329 (WebKit::UpdateInfo::encode):
2330 (WebKit::UpdateInfo::decode):
2331 * Shared/UpdateInfo.h: Added.
2332 (WebKit::UpdateInfo::UpdateInfo):
2333 * WebKit2.xcodeproj/project.pbxproj:
2335 2011-01-12 Anders Carlsson <andersca@apple.com>
2337 Reviewed by Sam Weinig.
2339 More work on the new drawing area implementation
2340 https://bugs.webkit.org/show_bug.cgi?id=52302
2342 * Platform/Region.cpp:
2343 (WebKit::Region::Shape::segments_end):
2344 segments_end could end up returning an iterator that is one element past the Vector data, so
2345 we can't use operator[] since that will assert.
2347 * WebProcess/WebPage/DrawingAreaImpl.cpp:
2348 (WebKit::DrawingAreaImpl::DrawingAreaImpl):
2349 Initialize the timer.
2351 (WebKit::DrawingAreaImpl::setNeedsDisplay):
2352 Unite the rect with the dirty region and schedule a display.
2354 (WebKit::DrawingAreaImpl::setSize):
2355 Tell the web page to resize.
2357 (WebKit::DrawingAreaImpl::scheduleDisplay):
2358 Start a display timer if needed.
2360 (WebKit::DrawingAreaImpl::display):
2363 2011-01-12 Brent Fulgham <bfulgham@webkit.org>
2365 Unreviewed build fix after r75527. Rename 'BackingStoreCairo.cpp'
2366 to 'ShareableBitmapCairo.cpp' to match VS project changes.
2368 * Shared/cairo/BackingStoreCairo.cpp: Removed.
2369 * Shared/cairo/ShareableBitmapCairo.cpp: Copied from Shared/cairo/BackingStoreCairo.cpp.
2371 2011-01-11 Jeff Miller <jeffm@apple.com>
2373 Reviewed by John Sullivan.
2375 WebKit2: "Webpages not responding" dialog appears when <select> popup menu is showing
2376 https://bugs.webkit.org/show_bug.cgi?id=52242
2378 * UIProcess/WebPageProxy.cpp:
2379 (WebKit::WebPageProxy::showPopupMenu):
2380 On Windows, stop the responsiveness timer before calling showPopupMenu().
2382 2011-01-11 Maciej Stachowiak <mjs@apple.com>
2384 Reviewed by Anders Carlsson.
2386 UIProcess kills the WebProcess sometimes when detached frames exist
2387 https://bugs.webkit.org/show_bug.cgi?id=52227
2389 * UIProcess/WebPageProxy.cpp:
2390 (WebKit::WebPageProxy::didSaveFrameToPageCache): Don't consider the message invalid
2391 if it came in for a detached frame.
2393 2011-01-11 Anders Carlsson <andersca@apple.com>
2397 * WebKit2.xcodeproj/project.pbxproj:
2399 2011-01-11 Anders Carlsson <andersca@apple.com>
2401 Reviewed by Sam Weinig.
2403 Add a Region class which represents a graphical region
2404 https://bugs.webkit.org/show_bug.cgi?id=52255
2406 * Platform/Region.cpp: Added.
2407 (WebKit::Region::Region):
2408 (WebKit::Region::rects):
2409 (WebKit::Region::Shape::Shape):
2410 (WebKit::Region::Shape::appendSpan):
2411 (WebKit::Region::Shape::canCoalesce):
2412 (WebKit::Region::Shape::appendSpans):
2413 (WebKit::Region::Shape::appendSegment):
2414 (WebKit::Region::Shape::spans_begin):
2415 (WebKit::Region::Shape::spans_end):
2416 (WebKit::Region::Shape::segments_begin):
2417 (WebKit::Region::Shape::segments_end):
2418 (WebKit::Region::Shape::dump):
2419 (WebKit::Region::Shape::bounds):
2420 (WebKit::Region::Shape::move):
2421 (WebKit::Region::Shape::swap):
2422 (WebKit::Region::Shape::shapeOperation):
2423 (WebKit::Region::Shape::UnionOperation::trySimpleOperation):
2424 (WebKit::Region::Shape::unionShapes):
2425 (WebKit::Region::Shape::IntersectOperation::trySimpleOperation):
2426 (WebKit::Region::Shape::intersectShapes):
2427 (WebKit::Region::Shape::SubtractOperation::trySimpleOperation):
2428 (WebKit::Region::Shape::subtractShapes):
2429 (WebKit::Region::dump):
2430 (WebKit::Region::intersect):
2431 (WebKit::Region::unite):
2432 (WebKit::Region::subtract):
2433 (WebKit::Region::move):
2434 * Platform/Region.h: Added.
2435 (WebKit::Region::bounds):
2436 (WebKit::Region::isEmpty):
2437 (WebKit::Region::Span::Span):
2438 (WebKit::Region::Shape::isEmpty):
2439 * WebKit2.xcodeproj/project.pbxproj:
2441 2011-01-11 Anders Carlsson <andersca@apple.com>
2443 Reviewed by Darin Adler.
2445 Add DidSetSize message
2446 https://bugs.webkit.org/show_bug.cgi?id=52254
2448 * DerivedSources.make:
2449 Add DrawingAReaProxy.messages.in.
2451 * Platform/CoreIPC/MessageID.h:
2452 Add DrawingAreaProxy message class.
2454 * UIProcess/DrawingAreaProxy.h:
2455 (WebKit::DrawingAreaProxy::didSetSize):
2456 Add CoreIPC message handler function.
2458 * UIProcess/DrawingAreaProxy.messages.in: Added.
2460 * UIProcess/DrawingAreaProxyImpl.cpp:
2461 (WebKit::DrawingAreaProxyImpl::didSetSize):
2464 * UIProcess/WebPageProxy.cpp:
2465 (WebKit::WebPageProxy::didReceiveMessage):
2466 Handle DrawingAreaProxy messages.
2468 * WebKit2.xcodeproj/project.pbxproj:
2471 * WebProcess/WebPage/DrawingAreaImpl.cpp:
2472 (WebKit::DrawingAreaImpl::setSize):
2473 Send a DidSetSize message for now.
2475 2011-01-11 Sam Weinig <sam@webkit.org>
2477 Reviewed by Anders Carlsson.
2479 Fix spelling mistake. Sharable -> Shareable.
2481 * Shared/API/c/WKImage.h:
2482 * Shared/API/c/WKSharedAPICast.h:
2483 (WebKit::toImageOptions):
2484 * Shared/ImageOptions.h:
2485 * Shared/WebImage.cpp:
2486 (WebKit::WebImage::create):
2488 2011-01-11 Anders Carlsson <andersca@apple.com>
2490 Reviewed by Sam Weinig.
2493 https://bugs.webkit.org/show_bug.cgi?id=52247
2495 * DerivedSources.make:
2496 Add DrawingArea.messages.in
2498 * Platform/CoreIPC/MessageID.h:
2499 Add DrawingArea message class.
2501 * UIProcess/DrawingAreaProxyImpl.cpp:
2502 (WebKit::DrawingAreaProxyImpl::sizeDidChange):
2505 (WebKit::DrawingAreaProxyImpl::sendSetSize):
2506 Send a SetSize message.
2508 * UIProcess/DrawingAreaProxyImpl.h:
2509 Add setSize override.
2511 * WebKit2.xcodeproj/project.pbxproj:
2514 * WebProcess/WebPage/DrawingArea.h:
2515 (WebKit::DrawingArea::setSize):
2516 Add setSize member function.
2518 * WebProcess/WebPage/DrawingArea.messages.in: Added.
2520 * WebProcess/WebPage/DrawingAreaImpl.cpp:
2521 * WebProcess/WebPage/DrawingAreaImpl.h:
2524 * WebProcess/WebPage/WebPage.cpp:
2525 (WebKit::WebPage::didReceiveMessage):
2526 Handle drawing area messages.
2528 2011-01-11 Anders Carlsson <andersca@apple.com>
2530 Reviewed by Sam Weinig.
2532 Replace ASSERTs with FIXMEs.
2534 * UIProcess/DrawingAreaProxyImpl.cpp:
2535 (WebKit::DrawingAreaProxyImpl::sizeDidChange):
2536 (WebKit::DrawingAreaProxyImpl::setPageIsVisible):
2538 2011-01-11 Anders Carlsson <andersca@apple.com>
2540 Reviewed by Sam Weinig.
2542 Add DrawingAreaImpl skeleton class
2543 https://bugs.webkit.org/show_bug.cgi?id=52246
2545 * UIProcess/API/mac/WKView.mm:
2546 (useNewDrawingArea):
2547 New function which controls which drawing area to use, through an environment variable.
2549 (-[WKView drawRect:]):
2550 Bail if we're using the new drawing area (for now).
2552 (-[WKView WebKit::]):
2553 Create a DrawingAreaProxyImpl when asked to.
2555 * WebKit2.xcodeproj/project.pbxproj:
2558 * WebProcess/WebPage/DrawingArea.cpp:
2559 (WebKit::DrawingArea::create):
2560 Create a DrawingAreaImpl when asked to.
2562 * WebProcess/WebPage/DrawingAreaImpl.cpp: Added.
2563 * WebProcess/WebPage/DrawingAreaImpl.h: Added.
2564 Add DrawingAreaImpl class.
2566 2011-01-11 Anders Carlsson <andersca@apple.com>
2568 Reviewed by Sam Weinig.
2570 Add Mac-only DrawingAreaProxyImpl class skeleton
2571 https://bugs.webkit.org/show_bug.cgi?id=52243
2573 This is the proxy side of a new drawing area implementation. This is Mac only for now
2574 while the design is being fleshed out.
2576 * Shared/DrawingAreaInfo.h:
2577 * UIProcess/API/mac/WKView.mm:
2578 (-[WKView _switchToDrawingAreaTypeIfNecessary:DrawingAreaInfo::]):
2579 * UIProcess/DrawingAreaProxyImpl.cpp: Added.
2580 (WebKit::DrawingAreaProxyImpl::create):
2581 (WebKit::DrawingAreaProxyImpl::DrawingAreaProxyImpl):
2582 (WebKit::DrawingAreaProxyImpl::~DrawingAreaProxyImpl):
2583 (WebKit::DrawingAreaProxyImpl::didReceiveMessage):
2584 (WebKit::DrawingAreaProxyImpl::didReceiveSyncMessage):
2585 (WebKit::DrawingAreaProxyImpl::paint):
2586 (WebKit::DrawingAreaProxyImpl::sizeDidChange):
2587 (WebKit::DrawingAreaProxyImpl::setPageIsVisible):
2588 (WebKit::DrawingAreaProxyImpl::attachCompositingContext):
2589 (WebKit::DrawingAreaProxyImpl::detachCompositingContext):
2590 * UIProcess/DrawingAreaProxyImpl.h: Added.
2591 * WebKit2.xcodeproj/project.pbxproj:
2592 * WebProcess/WebPage/DrawingArea.cpp:
2593 (WebKit::DrawingArea::create):
2595 2011-01-11 Anders Carlsson <andersca@apple.com>
2599 * WebProcess/WebCoreSupport/win/WebPopupMenuWin.cpp:
2600 (WebKit::WebPopupMenu::setUpPlatformData):
2602 2011-01-11 Anders Carlsson <andersca@apple.com>
2604 Reviewed by Sam Weinig.
2606 Rename ShareableBitmap::createSharable to createShareable
2607 https://bugs.webkit.org/show_bug.cgi?id=52234
2609 * Shared/ShareableBitmap.cpp:
2610 (WebKit::ShareableBitmap::createShareable):
2611 * Shared/ShareableBitmap.h:
2612 * Shared/WebImage.cpp:
2613 (WebKit::WebImage::create):
2614 * WebProcess/Plugins/PluginProxy.cpp:
2615 (WebKit::PluginProxy::geometryDidChange):
2616 * WebProcess/WebCoreSupport/win/WebPopupMenuWin.cpp:
2617 (WebKit::WebPopupMenu::setUpPlatformData):
2618 * WebProcess/WebPage/FindController.cpp:
2619 (WebKit::FindController::updateFindIndicator):
2621 2011-01-11 Anders Carlsson <andersca@apple.com>
2623 Reviewed by Sam Weinig.
2625 Rename BackingStore to ShareableBitmap
2626 https://bugs.webkit.org/show_bug.cgi?id=52228
2629 * PluginProcess/PluginControllerProxy.cpp:
2630 (WebKit::PluginControllerProxy::geometryDidChange):
2631 * PluginProcess/PluginControllerProxy.h:
2632 * Shared/API/c/cg/WKImageCG.cpp:
2633 (WKImageCreateCGImage):
2634 * Shared/BackingStore.cpp: Removed.
2635 * Shared/BackingStore.h: Removed.
2636 * Shared/PlatformPopupMenuData.cpp:
2637 (WebKit::PlatformPopupMenuData::decode):
2638 * Shared/PlatformPopupMenuData.h:
2639 * Shared/ShareableBitmap.cpp: Copied from WebKit2/Shared/BackingStore.cpp.
2640 (WebKit::ShareableBitmap::create):
2641 (WebKit::ShareableBitmap::createSharable):
2642 (WebKit::ShareableBitmap::createHandle):
2643 (WebKit::ShareableBitmap::ShareableBitmap):
2644 (WebKit::ShareableBitmap::~ShareableBitmap):
2645 (WebKit::ShareableBitmap::resize):
2646 (WebKit::ShareableBitmap::data):
2647 * Shared/ShareableBitmap.h: Copied from WebKit2/Shared/BackingStore.h.
2648 * Shared/UserMessageCoders.h:
2649 (WebKit::UserMessageEncoder::baseEncode):
2650 (WebKit::UserMessageDecoder::baseDecode):
2651 * Shared/WebImage.cpp:
2652 (WebKit::WebImage::create):
2653 (WebKit::WebImage::WebImage):
2654 (WebKit::WebImage::~WebImage):
2655 (WebKit::WebImage::size):
2656 * Shared/WebImage.h:
2657 (WebKit::WebImage::bitmap):
2658 * Shared/cairo/BackingStoreCairo.cpp:
2659 (WebKit::ShareableBitmap::createGraphicsContext):
2660 (WebKit::ShareableBitmap::paint):
2661 * Shared/cg/BackingStoreCG.cpp: Removed.
2662 * Shared/cg/ShareableBitmapCG.cpp: Copied from WebKit2/Shared/cg/BackingStoreCG.cpp.
2663 (WebKit::ShareableBitmap::createGraphicsContext):
2664 (WebKit::ShareableBitmap::paint):
2665 * Shared/gtk/BackingStoreGtk.cpp: Removed.
2666 * Shared/gtk/ShareableBitmapGtk.cpp: Copied from WebKit2/Shared/gtk/BackingStoreGtk.cpp.
2667 (WebKit::ShareableBitmap::createGraphicsContext):
2668 (WebKit::ShareableBitmap::paint):
2669 * Shared/qt/BackingStoreQt.cpp: Removed.
2670 * Shared/qt/ShareableBitmapQt.cpp: Copied from WebKit2/Shared/qt/BackingStoreQt.cpp.
2671 (WebKit::ShareableBitmap::createGraphicsContext):
2672 (WebKit::ShareableBitmap::paint):
2673 * UIProcess/FindIndicator.cpp:
2674 (WebKit::FindIndicator::create):
2675 (WebKit::FindIndicator::FindIndicator):
2676 * UIProcess/FindIndicator.h:
2677 (WebKit::FindIndicator::contentImage):
2679 * WebKit2.xcodeproj/project.pbxproj:
2680 * WebProcess/Plugins/PluginProxy.cpp:
2681 (WebKit::PluginProxy::geometryDidChange):
2682 * WebProcess/Plugins/PluginProxy.h:
2683 * WebProcess/WebPage/FindController.cpp:
2684 (WebKit::FindController::updateFindIndicator):
2685 * WebProcess/WebPage/WebPage.cpp:
2686 (WebKit::WebPage::snapshotInViewCoordinates):
2687 (WebKit::WebPage::snapshotInDocumentCoordinates):
2688 * win/WebKit2.vcproj:
2690 2011-01-11 John Sullivan <sullivan@apple.com>
2692 Reviewed by Anders Carlsson.
2694 [WKView setFrameSize:] derefs _page->drawingArea() without null check
2695 <https://bugs.webkit.org/show_bug.cgi?id=52231>
2697 * UIProcess/API/mac/WKView.mm:
2698 (-[WKView setFrameSize:]):
2699 Null check drawingArea(). This is OK because if it doesn't exist then it will be
2700 created later with the correct initial size.
2702 2011-01-07 Enrica Casucci <enrica@apple.com>
2704 Reviewed by Alexey Proskuryakov.
2706 Paste and drag and drop use different code paths to interact with the pasteboard.
2707 https://bugs.webkit.org/show_bug.cgi?id=52093
2708 The change consists in a refactoring of the code to have only one class that
2709 deals with the pasteboard on Mac.
2711 * WebProcess/WebCoreSupport/WebEditorClient.h:
2712 * WebProcess/WebCoreSupport/mac/WebEditorClientMac.mm: Added two methods to provide to WebCore functionality
2713 exposed by NSURLExtras.
2714 (WebKit::WebEditorClient::canonicalizeURL):
2715 (WebKit::WebEditorClient::canonicalizeURLString):
2717 2011-01-11 Jessie Berlin <jberlin@apple.com>
2719 Reviewed by Anders Carlsson and Sam Weinig.
2721 Fix crash on launch on Windows.
2723 * UIProcess/win/WebView.cpp:
2724 (WebKit::WebView::onSizeEvent):
2725 The drawing area is no longer initialized before the WebView is created and the first
2726 onSize is receieved.
2728 2011-01-11 Anders Carlsson <andersca@apple.com>
2730 Reviewed by Dan Bernstein.
2732 Automatically reinitialize the web page on relaunch
2733 https://bugs.webkit.org/show_bug.cgi?id=52224
2734 <rdar://problem/8765695>
2736 * UIProcess/API/mac/WKView.mm:
2737 (-[WKView _didRelaunchProcess]):
2738 Remove call to reinitializeWebPage.
2740 * UIProcess/WebPageProxy.cpp:
2741 (WebKit::WebPageProxy::relaunch):
2742 Call initializeWebPage().
2744 (WebKit::WebPageProxy::initializeWebPage):
2745 Assert that the web page is valid here.
2747 * UIProcess/WebPageProxy.h:
2748 Remove reinitializeWebPage.
2750 * UIProcess/win/WebView.cpp:
2751 (WebKit::WebView::didRelaunchProcess):
2752 Remove call to reinitializeWebPage.
2754 2011-01-10 Anders Carlsson <andersca@apple.com>
2756 Reviewed by Sam Weinig.
2758 Pass the view size to the DrawingAreaProxy constructor
2759 https://bugs.webkit.org/show_bug.cgi?id=52189
2761 * UIProcess/DrawingAreaProxy.cpp:
2762 (WebKit::DrawingAreaProxy::DrawingAreaProxy):
2763 * UIProcess/WebPageProxy.cpp:
2764 (WebKit::WebPageProxy::viewSize):
2765 * UIProcess/WebPageProxy.h:
2767 2011-01-11 Sam Weinig <sam@webkit.org>
2769 Roll r75460 back in with build fix.
2771 2011-01-11 Anders Carlsson <andersca@apple.com>
2773 Reviewed by Andreas Kling.
2775 Work towards having the WebPageProxy decide when to create the DrawingAreaProxy
2776 https://bugs.webkit.org/show_bug.cgi?id=52184
2778 Qt part made my Balazs Kelemen.
2780 * UIProcess/API/mac/PageClientImpl.h:
2781 * UIProcess/API/mac/PageClientImpl.mm:
2782 (WebKit::PageClientImpl::createDrawingAreaProxy):
2783 Call -[WKView _createDrawingAreaProxy].
2785 (WebKit::PageClientImpl::setViewNeedsDisplay):
2786 Call setNeedsDisplayInRect on the WKView.
2788 * UIProcess/API/mac/WKView.mm:
2789 (-[WKView initWithFrame:contextRef:pageGroupRef:]):
2790 No need to set the drawing area proxy anymore.
2792 (-[WKView _createDrawingAreaProxy]):
2793 Create a chunked update drawing area proxy for now.
2795 * UIProcess/API/qt/qgraphicswkview.cpp:
2796 Added a QGraphicsItem* member that is initialized in init to the accociated view.
2797 Implement the new functions. This is a temporary solution, in the long term the view
2798 and the page should be decoupled.
2799 (QGraphicsWKView::QGraphicsWKView):
2800 * UIProcess/API/qt/qwkpage.cpp:
2801 (QWKPagePrivate::QWKPagePrivate):
2802 (QWKPagePrivate::init):
2803 (QWKPagePrivate::createDrawingAreaProxy):
2804 (QWKPagePrivate::setViewNeedsDisplay):
2805 * UIProcess/API/qt/qwkpage.h:
2806 * UIProcess/API/qt/qwkpage_p.h:
2808 * UIProcess/PageClient.h:
2809 Add new pure virtual member functions.
2811 * UIProcess/WebPageProxy.cpp:
2812 (WebKit::WebPageProxy::initializeWebPage):
2813 (WebKit::WebPageProxy::reinitializeWebPage):
2814 Set the new drawing area proxy.
2816 * UIProcess/win/WebView.cpp:
2817 (WebKit::WebView::WebView):
2818 No need to set the drawing area proxy anymore.
2820 (WebKit::WebView::createDrawingAreaProxy):
2821 Create a chunked update drawing area proxy for now.
2823 (WebKit::WebView::setViewNeedsDisplay):
2824 Invalidate the window.
2826 2011-01-11 Adam Roben <aroben@apple.com>
2828 Fix a typo in a comment
2830 * WebProcess/WebCoreSupport/WebPlatformStrategies.cpp:
2832 2011-01-10 Sheriff Bot <webkit.review.bot@gmail.com>
2834 Unreviewed, rolling out r75460.
2835 http://trac.webkit.org/changeset/75460
2836 https://bugs.webkit.org/show_bug.cgi?id=52191
2838 It broke Qt-WK2 build (Requested by Ossy on #webkit).
2840 * Shared/API/c/WKBase.h:
2841 * Shared/APIObject.h:
2842 * UIProcess/API/C/WKAPICast.h:
2843 * UIProcess/API/C/WKGeolocationPermissionRequest.cpp: Removed.
2844 * UIProcess/API/C/WKGeolocationPermissionRequest.h: Removed.
2845 * UIProcess/API/C/WKPage.h:
2846 * UIProcess/API/C/WebKit2.h:
2847 * UIProcess/API/qt/qwkpage.cpp:
2849 * UIProcess/GeolocationPermissionRequestManagerProxy.cpp: Removed.
2850 * UIProcess/GeolocationPermissionRequestManagerProxy.h: Removed.
2851 * UIProcess/GeolocationPermissionRequestProxy.cpp: Removed.
2852 * UIProcess/GeolocationPermissionRequestProxy.h: Removed.
2853 * UIProcess/WebPageProxy.cpp:
2854 (WebKit::WebPageProxy::WebPageProxy):
2855 (WebKit::WebPageProxy::close):
2856 (WebKit::WebPageProxy::processDidCrash):
2857 * UIProcess/WebPageProxy.h:
2858 * UIProcess/WebPageProxy.messages.in:
2859 * UIProcess/WebUIClient.cpp:
2860 * UIProcess/WebUIClient.h:
2862 * WebKit2.xcodeproj/project.pbxproj:
2863 * WebProcess/Geolocation/GeolocationPermissionRequestManager.cpp: Removed.
2864 * WebProcess/Geolocation/GeolocationPermissionRequestManager.h: Removed.
2865 * WebProcess/Geolocation/WebGeolocationManager.cpp:
2866 * WebProcess/Geolocation/WebGeolocationManager.h:
2867 * WebProcess/WebCoreSupport/WebGeolocationClient.cpp:
2868 (WebKit::WebGeolocationClient::requestPermission):
2869 (WebKit::WebGeolocationClient::cancelPermissionRequest):
2870 * WebProcess/WebCoreSupport/WebGeolocationClient.h:
2871 * WebProcess/WebPage/WebPage.cpp:
2872 (WebKit::WebPage::WebPage):
2873 * WebProcess/WebPage/WebPage.h:
2874 * WebProcess/WebPage/WebPage.messages.in:
2875 * win/WebKit2.vcproj:
2876 * win/WebKit2Generated.make:
2878 2011-01-10 Csaba Osztrogonác <ossy@webkit.org>
2880 Unreviewed, rolling out r75459
2881 http://trac.webkit.org/changeset/75459
2883 Work towards having the WebPageProxy decide when to create the DrawingAreaProxy
2884 https://bugs.webkit.org/show_bug.cgi?id=52184
2886 * UIProcess/API/mac/PageClientImpl.h:
2887 * UIProcess/API/mac/PageClientImpl.mm:
2888 * UIProcess/API/mac/WKView.mm:
2889 * UIProcess/API/mac/WKViewInternal.h:
2890 * UIProcess/API/qt/qwkpage.cpp:
2891 * UIProcess/API/qt/qwkpage_p.h:
2892 * UIProcess/PageClient.h:
2893 * UIProcess/WebPageProxy.cpp:
2894 (WebKit::WebPageProxy::initializeWebPage):
2895 (WebKit::WebPageProxy::reinitializeWebPage):
2896 * UIProcess/win/WebView.cpp:
2897 (WebKit::WebView::WebView):
2898 * UIProcess/win/WebView.h:
2900 2011-01-10 Anders Carlsson <andersca@apple.com>
2902 Reviewed by Sam Weinig.
2904 Remove size parameter to WebPageProxy::initializeWebPage
2905 https://bugs.webkit.org/show_bug.cgi?id=52188
2907 * UIProcess/API/mac/WKView.mm:
2908 (-[WKView initWithFrame:contextRef:pageGroupRef:]):
2909 * UIProcess/API/qt/qwkpage.cpp:
2910 (QWKPagePrivate::init):
2911 * UIProcess/WebPageProxy.cpp:
2912 (WebKit::WebPageProxy::initializeWebPage):
2913 * UIProcess/WebPageProxy.h:
2914 * UIProcess/win/WebView.cpp:
2915 (WebKit::WebView::WebView):
2917 2011-01-10 Anders Carlsson <andersca@apple.com>
2919 Didn't mean to land this.
2921 * UIProcess/WebPageProxy.cpp:
2922 (WebKit::WebPageProxy::initializeWebPage):
2923 * UIProcess/WebPageProxy.h:
2925 2011-01-10 Anders Carlsson <andersca@apple.com>
2927 Reviewed by Sam Weinig.
2929 WebPageProxy::creationParameters no longer needs to take a size
2930 https://bugs.webkit.org/show_bug.cgi?id=52187
2932 WebPageProxy::creationParameters can just ask the page client for the view size now.
2934 * UIProcess/WebInspectorProxy.cpp:
2935 (WebKit::WebInspectorProxy::createInspectorPage):
2936 * UIProcess/WebPageProxy.cpp:
2937 (WebKit::WebPageProxy::initializeWebPage):
2938 (WebKit::WebPageProxy::reinitializeWebPage):
2939 (WebKit::WebPageProxy::createNewPage):
2940 (WebKit::WebPageProxy::creationParameters):
2941 * UIProcess/WebPageProxy.h:
2943 2011-01-10 Anders Carlsson <andersca@apple.com>
2945 Reviewed by Sam Weinig.
2947 Pass information about the view in the WebPageCreationParameters
2948 https://bugs.webkit.org/show_bug.cgi?id=52186
2950 * Shared/WebPageCreationParameters.cpp:
2951 (WebKit::WebPageCreationParameters::encode):
2952 (WebKit::WebPageCreationParameters::decode):
2953 Encode and decode the state flags.
2955 * Shared/WebPageCreationParameters.h:
2956 Add new state flags.
2958 * UIProcess/WebPageProxy.cpp:
2959 (WebKit::WebPageProxy::creationParameters):
2960 Initialize the state flags.
2962 * WebProcess/WebPage/WebPage.cpp:
2963 (WebKit::WebPage::WebPage):
2964 Update the page state from the state flags.
2966 2011-01-10 Sam Weinig <sam@webkit.org>
2968 Reviewed by Anders Carlsson.
2970 Make Geolocation features work in WebKit2
2971 https://bugs.webkit.org/show_bug.cgi?id=52078
2973 Step 2 - Add support for requesting and granting permission for geolocation.
2975 * Shared/API/c/WKBase.h:
2976 * Shared/APIObject.h:
2977 * UIProcess/API/C/WebKit2.h:
2978 * UIProcess/API/C/WKAPICast.h:
2979 * UIProcess/API/C/WKGeolocationPermissionRequest.cpp: Added.
2980 * UIProcess/API/C/WKGeolocationPermissionRequest.h: Added.
2981 Add new API type, WKGeolocationPermissionRequestRef.
2983 * UIProcess/API/C/WKPage.h:
2984 Add new UIClient function for requesting permission.
2986 * UIProcess/API/qt/qwkpage.cpp:
2988 Stub out the UIClient.
2990 * UIProcess/GeolocationPermissionRequestManagerProxy.cpp: Added.
2991 * UIProcess/GeolocationPermissionRequestManagerProxy.h: Added.
2992 * UIProcess/GeolocationPermissionRequestProxy.cpp: Added.
2993 * UIProcess/WebPageProxy.cpp:
2994 * UIProcess/WebPageProxy.h:
2995 * UIProcess/WebPageProxy.messages.in:
2996 * UIProcess/WebUIClient.cpp:
2997 * UIProcess/WebUIClient.h:
2998 * WebProcess/Geolocation/GeolocationPermissionRequestManager.cpp: Added.
2999 * WebProcess/Geolocation/GeolocationPermissionRequestManager.h: Added.
3000 * WebProcess/Geolocation/WebGeolocationManager.cpp:
3001 * WebProcess/Geolocation/WebGeolocationManager.h:
3002 * WebProcess/WebCoreSupport/WebGeolocationClient.cpp:
3003 * WebProcess/WebCoreSupport/WebGeolocationClient.h:
3004 * WebProcess/WebPage/WebPage.cpp:
3005 (WebKit::WebPage::WebPage):
3006 (WebKit::WebPage::didReceiveGeolocationPermissionDecision):
3007 * WebProcess/WebPage/WebPage.h:
3008 (WebKit::WebPage::geolocationPermissionRequestManager):
3009 * WebProcess/WebPage/WebPage.messages.in:
3010 Track the permission request through both sides of the process divide.
3013 * WebKit2.xcodeproj/project.pbxproj:
3014 * win/WebKit2.vcproj:
3015 * win/WebKit2Generated.make:
3018 2011-01-10 Anders Carlsson <andersca@apple.com>
3020 Reviewed by Sam Weinig.
3022 Work towards having the WebPageProxy decide when to create the DrawingAreaProxy
3023 https://bugs.webkit.org/show_bug.cgi?id=52184
3025 * UIProcess/API/mac/PageClientImpl.h:
3026 * UIProcess/API/mac/PageClientImpl.mm:
3027 (WebKit::PageClientImpl::createDrawingAreaProxy):
3028 Call -[WKView _createDrawingAreaProxy].
3030 (WebKit::PageClientImpl::setViewNeedsDisplay):
3031 Call setNeedsDisplayInRect on the WKView.
3033 * UIProcess/API/mac/WKView.mm:
3034 (-[WKView initWithFrame:contextRef:pageGroupRef:]):
3035 No need to set the drawing area proxy anymore.
3037 (-[WKView _createDrawingAreaProxy]):
3038 Create a chunked update drawing area proxy for now.
3040 * UIProcess/API/qt/qwkpage.cpp:
3041 (QWKPagePrivate::createDrawingAreaProxy):
3042 (QWKPagePrivate::setViewNeedsDisplay):
3045 * UIProcess/PageClient.h:
3046 Add new pure virtual member functions.
3048 * UIProcess/WebPageProxy.cpp:
3049 (WebKit::WebPageProxy::initializeWebPage):
3050 (WebKit::WebPageProxy::reinitializeWebPage):
3051 Set the new drawing area proxy.
3053 * UIProcess/win/WebView.cpp:
3054 (WebKit::WebView::WebView):
3055 No need to set the drawing area proxy anymore.
3057 (WebKit::WebView::createDrawingAreaProxy):
3058 Create a chunked update drawing area proxy for now.
3060 (WebKit::WebView::setViewNeedsDisplay):
3061 Invalidate the window.
3063 2011-01-10 Anders Carlsson <andersca@apple.com>
3065 Fix Windows build again.
3067 * UIProcess/win/WebView.cpp:
3068 (WebKit::WebView::isViewWindowActive):
3070 2011-01-10 Anders Carlsson <andersca@apple.com>
3074 * UIProcess/win/WebView.cpp:
3075 (WebKit::WebView::onShowWindowEvent):
3077 2011-01-10 Anders Carlsson <andersca@apple.com>
3079 Reviewed by Sam Weinig.
3081 Use a pull model for view state changes
3082 https://bugs.webkit.org/show_bug.cgi?id=52175
3084 Instead of having the WKView call setFocused, setActive etc on the WebPageProxy, the
3085 WKView now simply informs the WebPageProxy what has changed, using the WebPageProxy::viewStateDidChange
3086 function. The WebPageProxy can then fetch the relevant information using newly added PageClient functions.
3088 * UIProcess/API/mac/PageClientImpl.h:
3089 * UIProcess/API/mac/PageClientImpl.mm:
3090 (WebKit::PageClientImpl::viewSize):
3091 (WebKit::PageClientImpl::isViewWindowActive):
3092 (WebKit::PageClientImpl::isViewFocused):
3093 (WebKit::PageClientImpl::isViewVisible):
3094 (WebKit::PageClientImpl::isViewInWindow):
3095 * UIProcess/API/mac/WKView.mm:
3096 (-[WKView initWithFrame:contextRef:pageGroupRef:]):
3097 (-[WKView becomeFirstResponder]):
3098 (-[WKView resignFirstResponder]):
3099 (-[WKView viewDidMoveToWindow]):
3100 (-[WKView _windowDidBecomeKey:]):
3101 (-[WKView _windowDidResignKey:]):
3102 (-[WKView viewDidHide]):
3103 (-[WKView viewDidUnhide]):
3104 (-[WKView _isFocused]):
3105 (-[WKView _didRelaunchProcess]):
3106 * UIProcess/API/mac/WKViewInternal.h:
3107 * UIProcess/API/qt/qgraphicswkview.cpp:
3108 (QGraphicsWKView::focusInEvent):
3109 (QGraphicsWKView::focusOutEvent):
3110 * UIProcess/API/qt/qwkpage.cpp:
3111 (QWKPagePrivate::QWKPagePrivate):
3112 (QWKPagePrivate::viewSize):
3113 (QWKPagePrivate::isViewWindowActive):
3114 (QWKPagePrivate::isViewFocused):
3115 (QWKPagePrivate::isViewVisible):
3116 (QWKPagePrivate::isViewInWindow):
3117 * UIProcess/API/qt/qwkpage_p.h:
3118 * UIProcess/PageClient.h:
3119 * UIProcess/WebContext.cpp:
3120 (WebKit::WebContext::createWebPage):
3121 * UIProcess/WebContext.h:
3122 * UIProcess/WebPageProxy.cpp:
3123 (WebKit::WebPageProxy::create):
3124 (WebKit::WebPageProxy::WebPageProxy):
3125 (WebKit::WebPageProxy::viewStateDidChange):
3126 * UIProcess/WebPageProxy.h:
3127 * UIProcess/WebProcessProxy.cpp:
3128 (WebKit::WebProcessProxy::createWebPage):
3129 * UIProcess/WebProcessProxy.h:
3130 * UIProcess/win/WebView.cpp:
3131 (WebKit::WebView::WebView):
3132 (WebKit::WebView::onSetFocusEvent):
3133 (WebKit::WebView::onKillFocusEvent):
3134 (WebKit::WebView::onShowWindowEvent):
3135 (WebKit::WebView::updateActiveState):
3136 (WebKit::WebView::viewSize):
3137 (WebKit::WebView::isViewWindowActive):
3138 (WebKit::WebView::isViewFocused):
3139 (WebKit::WebView::isViewVisible):
3140 (WebKit::WebView::isViewInWindow):
3141 (WebKit::WebView::didRelaunchProcess):
3142 (WebKit::WebView::setIsInWindow):
3143 * UIProcess/win/WebView.h:
3145 2011-01-10 Adam Roben <aroben@apple.com>
3147 Don't pass a reference type to va_start
3149 C++ says this results in undefined behavior:
3151 The restrictions that ISO C places on the second parameter to the
3152 va_start() macro in header <stdarg.h> are different in this
3153 International Standard. The parameter parmN is the identifier of
3154 the rightmost parameter in the variable parameter list of the
3155 function definition (the one just before the ...).221) If the
3156 parameter parmN is declared with a function, array, or reference
3157 type, or with a type that is not compatible with the type that
3158 results when passing an argument for which there is no parameter,
3159 the behavior is undefined.
3161 Fixes <http://webkit.org/b/52168> Title of standalone image document
3162 includes bogus image dimensions
3164 Rubber-stamped by Eric Seidel.
3166 * WebProcess/WebCoreSupport/WebPlatformStrategies.cpp:
3167 (WebKit::formatLocalizedString): Don't use a reference type for
3170 2011-01-10 Siddharth Mathur <siddharth.mathur@nokia.com>
3172 Reviewed by Eric Seidel.
3174 Support for ARM's RVCT(ARMCC) compiler in import/export directives
3175 https://bugs.webkit.org/show_bug.cgi?id=52146
3177 * Shared/API/c/WKBase.h:
3179 2011-01-10 Sam Weinig <sam@webkit.org>
3183 * WebProcess/WebPage/WebPage.cpp:
3184 (WebKit::WebPage::WebPage):
3186 2011-01-10 Sam Weinig <sam@webkit.org>
3188 Reviewed by Anders Carlsson.
3190 Make Geolocation features work in WebKit2
3191 https://bugs.webkit.org/show_bug.cgi?id=52078
3193 Step 1 - Add enough support to get position data from a provider.
3194 This does not include permission support.
3196 * Platform/CoreIPC/HandleMessage.h:
3197 Add #include of Arguments.h for CoreIPC::In and Out definitions.
3199 * Platform/CoreIPC/MessageID.h:
3200 Add new message types.
3202 * Shared/API/c/WKBase.h:
3203 * Shared/APIObject.h:
3206 * Shared/WebGeolocationPosition.cpp: Added.
3207 * Shared/WebGeolocationPosition.h: Added.
3208 Internal position representation.
3210 * UIProcess/API/C/WKAPICast.h:
3211 Add casts for new API types.
3213 * UIProcess/API/C/WKContext.cpp:
3214 * UIProcess/API/C/WKContext.h:
3215 * UIProcess/API/C/WKGeolocationManager.cpp: Added.
3216 * UIProcess/API/C/WKGeolocationManager.h: Added.
3217 * UIProcess/API/C/WKGeolocationPosition.cpp: Added.
3218 * UIProcess/API/C/WKGeolocationPosition.h: Added.
3219 * UIProcess/API/C/WebKit2.h:
3220 Add API to provide and control geolocation data.
3222 * UIProcess/WebContext.cpp:
3223 (WebKit::WebContext::WebContext):
3224 (WebKit::WebContext::~WebContext):
3225 (WebKit::WebContext::processDidClose):
3226 (WebKit::WebContext::didReceiveMessage):
3227 * UIProcess/WebContext.h:
3228 (WebKit::WebContext::geolocationManagerProxy):
3229 * UIProcess/WebGeolocationManagerProxy.cpp: Added.
3230 (WebKit::WebGeolocationManagerProxy::create):
3231 (WebKit::WebGeolocationManagerProxy::WebGeolocationManagerProxy):
3232 (WebKit::WebGeolocationManagerProxy::~WebGeolocationManagerProxy):
3233 (WebKit::WebGeolocationManagerProxy::invalidate):
3234 (WebKit::WebGeolocationManagerProxy::initializeProvider):
3235 (WebKit::WebGeolocationManagerProxy::providerDidChangePosition):
3236 (WebKit::WebGeolocationManagerProxy::providerDidFailToDeterminePosition):
3237 (WebKit::WebGeolocationManagerProxy::didReceiveMessage):
3238 (WebKit::WebGeolocationManagerProxy::startUpdating):
3239 (WebKit::WebGeolocationManagerProxy::stopUpdating):
3240 * UIProcess/WebGeolocationManagerProxy.h: Added.
3241 (WebKit::WebGeolocationManagerProxy::clearContext):
3242 (WebKit::WebGeolocationManagerProxy::type):
3243 * UIProcess/WebGeolocationManagerProxy.messages.in: Added.
3244 * UIProcess/WebGeolocationProvider.cpp: Added.
3245 (WebKit::WebGeolocationProvider::startUpdating):
3246 (WebKit::WebGeolocationProvider::stopUpdating):
3247 * UIProcess/WebGeolocationProvider.h: Added.
3248 * UIProcess/WebProcessProxy.cpp:
3249 (WebKit::WebProcessProxy::didReceiveMessage):
3250 * WebProcess/Geolocation: Added.
3251 * WebProcess/Geolocation/WebGeolocationManager.cpp: Added.
3252 (WebKit::WebGeolocationManager::WebGeolocationManager):
3253 (WebKit::WebGeolocationManager::~WebGeolocationManager):
3254 (WebKit::WebGeolocationManager::didReceiveMessage):
3255 (WebKit::WebGeolocationManager::registerWebPage):
3256 (WebKit::WebGeolocationManager::unregisterWebPage):
3257 (WebKit::WebGeolocationManager::didChangePosition):
3258 (WebKit::WebGeolocationManager::didFailToDeterminePosition):
3259 * WebProcess/Geolocation/WebGeolocationManager.h: Added.
3260 * WebProcess/Geolocation/WebGeolocationManager.messages.in: Added.
3261 * WebProcess/WebCoreSupport/WebGeolocationClient.cpp: Added.
3262 (WebKit::WebGeolocationClient::geolocationDestroyed):
3263 (WebKit::WebGeolocationClient::startUpdating):
3264 (WebKit::WebGeolocationClient::stopUpdating):
3265 (WebKit::WebGeolocationClient::setEnableHighAccuracy):
3266 (WebKit::WebGeolocationClient::lastPosition):
3267 (WebKit::WebGeolocationClient::requestPermission):
3268 (WebKit::WebGeolocationClient::cancelPermissionRequest):
3269 * WebProcess/WebCoreSupport/WebGeolocationClient.h: Added.
3270 (WebKit::WebGeolocationClient::WebGeolocationClient):
3271 * WebProcess/WebPage/WebPage.cpp:
3272 (WebKit::WebPage::WebPage):
3273 * WebProcess/WebProcess.cpp:
3274 (WebKit::WebProcess::WebProcess):
3275 (WebKit::WebProcess::didReceiveMessage):
3276 * WebProcess/WebProcess.h:
3277 (WebKit::WebProcess::geolocationManager):
3278 Pipe geolocation positions/errors from the UIProcess to the WebProcess.
3280 * DerivedSources.make:
3281 * DerivedSources.pro:
3283 * WebKit2.xcodeproj/project.pbxproj:
3284 * win/WebKit2.vcproj:
3285 * win/WebKit2Common.vsprops:
3286 * win/WebKit2Generated.make:
3289 2011-01-10 Martin Robinson <mrobinson@igalia.com>
3291 GTK+ build fix. Continue to fix 'make dist.'
3293 * GNUmakefile.am: Remove more non-existent files from the WebKit2 build.
3295 2011-01-10 Alejandro G. Castro <alex@igalia.com>
3297 Reviewed by Martin Robinson.
3299 [GTK] Remove webkit2 files that are still not added to the
3300 repository from the makefile
3301 https://bugs.webkit.org/show_bug.cgi?id=52145
3303 This change is required for the release, we can add the lines
3304 again to the makefiles with the patches adding the files.
3308 2011-01-10 Andreas Kling <kling@webkit.org>
3310 Reviewed by Simon Hausmann.
3312 [Qt] [WK2] MiniBrowser does not load pages opened in new windows
3313 https://bugs.webkit.org/show_bug.cgi?id=52111
3315 * UIProcess/API/qt/qwkpage.cpp:
3316 (QWKPage::context): Implement this method.
3318 2011-01-09 Dan Bernstein <mitz@apple.com>
3320 Reviewed by Simon Fraser.
3322 <rdar://problem/8839498> Assertion failure in KURL::KURL when calling WKURLRequestCreateWithWKURL with a non-parsed URL
3323 https://bugs.webkit.org/show_bug.cgi?id=52132
3325 * Shared/API/c/WKURLRequest.cpp:
3326 (WKURLRequestCreateWithWKURL): Parse the URL.
3327 * Shared/WebString.h: Fixed a comment.
3328 * Shared/WebURL.h: Ditto.
3330 2011-01-09 Amruth Raj <amruthraj@motorola.com> and Ravi Phaneendra Kasibhatla <ravi.kasibhatla@motorola.com>
3332 Reviewed by Martin Robinson.
3334 Changes to add Process Launcher and Thread Launcher implementation to the WebKit2 GTK port.
3335 The main() implementation for WebKitWebProcess binary to launch Web process from UI process.
3336 https://bugs.webkit.org/show_bug.cgi?id=48511
3338 * UIProcess/Launcher/gtk: Added.
3339 * UIProcess/Launcher/gtk/ProcessLauncherGtk.cpp: Added. GTK (UNIX_X11 specific) implementation
3340 (WebKit::ProcessLauncher::launchProcess):
3341 (WebKit::ProcessLauncher::terminateProcess):
3342 (WebKit::ProcessLauncher::platformInvalidate):
3343 * UIProcess/Launcher/gtk/ThreadLauncherGtk.cpp: Added. Stubbed implementation for GTK port. Yet to implement.
3344 (WebKit::ThreadLauncher::createWebThread):
3345 * WebProcess/gtk: Added.
3346 * WebProcess/gtk/WebProcessGtk.cpp: Added. The stubbed implementations of virtual functions of WebProcess.h for GTK port.
3347 (WebKit::WebProcess::platformSetCacheModel):
3348 (WebKit::WebProcess::platformClearResourceCaches):
3349 (WebKit::WebProcess::platformInitializeWebProcess):
3350 (WebKit::WebProcess::platformShutdown):
3351 * WebProcess/gtk/WebProcessMainGtk.cpp: Added. The WebProcessMain call which initiates the Web Process for GTK port.
3352 (WebKit::WebProcessMainGtk):
3353 * WebProcess/gtk/WebProcessMainGtk.h: Added. The WebProcessMain declaration for Web Process for GTK port.
3354 * gtk/MainGtk.cpp: Added. The main function implementation for binary WebKitWebProcess.
3357 2011-01-07 Amruth Raj <amruthraj@motorola.com> and Ravi Phaneendra Kasibhatla <ravi.kasibhatla@motorola.com>
3359 Reviewed by Martin Robinson.
3361 [GTK] WebKit2 GNUmakefile is out of date from trunk
3362 https://bugs.webkit.org/show_bug.cgi?id=51883
3364 * GNUmakefile.am: Updated sources list as per latest revision
3365 * Platform/gtk/RunLoopGtk.cpp:
3366 (RunLoop::TimerBase::start):
3367 * Platform/gtk/WorkQueueGtk.cpp:
3368 (WorkQueue::scheduleWorkAfterDelay):
3369 * Shared/gtk/BackingStoreGtk.cpp:
3370 (WebKit::BackingStore::paint):
3371 * WebProcess/InjectedBundle/gtk/InjectedBundleGtk.cpp:
3372 (WebKit::InjectedBundle::load):
3373 * WebProcess/Plugins/Netscape/gtk/NetscapePluginGtk.cpp:
3374 (WebKit::NetscapePlugin::platformInvalidate):
3376 2011-01-08 Dan Bernstein <mitz@apple.com>
3378 Reviewed by Sam Weinig.
3380 <rdar://problem/8812759> In WebKit2, PDF view settings (mode and scale) do not stick
3381 https://bugs.webkit.org/show_bug.cgi?id=52118
3383 * Shared/WebPreferencesStore.cpp:
3384 (WebKit::WebPreferencesStore::encode): Encode the double values map.
3385 (WebKit::WebPreferencesStore::decode): Decode the double values map.
3386 (WebKit::defaultValueForKey): Added double instance.
3387 (WebKit::WebPreferencesStore::setDoubleValueForKey): Added.
3388 (WebKit::WebPreferencesStore::getDoubleValueForKey): Added.
3389 * Shared/WebPreferencesStore.h: Added PDFScaleFactor and PDFDisplayMode preferences.
3390 * UIProcess/API/mac/PDFViewController.mm:
3391 (-[WKPDFView initWithFrame:PDFViewController:WebKit::]): Initialize the _pdfViewController ivar.
3392 (-[WKPDFView invalidate]): Changed 'nil' to '0' in assignment to a non-Objective-C pointer.
3393 (-[WKPDFView setDocument:]): Added.
3394 (-[WKPDFView _applyPDFPreferences]): Added.
3395 (-[WKPDFView _updatePreferences:]): Added.
3396 (-[WKPDFView _updatePreferencesSoon]): Added.
3397 (-[WKPDFView _scaleOrDisplayModeOrPageChanged:]): Added.
3398 (-[WKPDFView viewDidMoveToWindow]): Added. Starts observing the PDF view for changes to scale
3400 (-[WKPDFView viewWillMoveToWindow:]): Added. Stops observing for changes.
3401 (WebKit::PDFViewController::setPDFDocumentData): Changed to call throguh -[WKPDFView setDocument:].
3402 * UIProcess/WebPreferences.cpp:
3403 (WebKit::WebPreferences::updateDoubleValueForKey): Added.
3404 * UIProcess/WebPreferences.h:
3405 * UIProcess/cf/WebPreferencesCF.cpp:
3406 (WebKit::WebPreferences::platformUpdateDoubleValueForKey): Added empty implementation.
3407 * UIProcess/gtk/WebPreferencesGtk.cpp:
3408 (WebKit::WebPreferences::platformUpdateDoubleValueForKey): Added stub.
3409 * UIProcess/mac/WebPreferencesMac.mm:
3410 (WebKit::setDoubleValueIfInUserDefaults): Added.
3411 (WebKit::WebPreferences::platformUpdateDoubleValueForKey): Added.
3412 * UIProcess/qt/WebPreferencesQt.cpp:
3413 (WebKit::WebPreferences::platformUpdateDoubleValueForKey): Added.
3415 2011-01-08 Dan Bernstein <mitz@apple.com>
3417 Reviewed by Maciej Stachowiak.
3419 In WebKit2, page zooming does not work with PDF
3420 https://bugs.webkit.org/show_bug.cgi?id=52113
3422 * UIProcess/API/C/WKPage.cpp:
3423 (WKPageSupportsTextZoom): Added. Returns whether the page currently supports text-only zoom.
3424 * UIProcess/API/C/WKPage.h:
3425 * UIProcess/API/mac/PDFViewController.h: Made pdfDocumentClass() private and declared new
3427 * UIProcess/API/mac/PDFViewController.mm:
3428 (WebKit::PDFViewController::zoomFactor): Added.
3429 (WebKit::PDFViewController::setZoomFactor): Added.
3430 * UIProcess/API/mac/PageClientImpl.h:
3431 * UIProcess/API/mac/PageClientImpl.mm:
3432 (WebKit::PageClientImpl::customRepresentationZoomFactor): Added. Calls through to the WKView.
3433 (WebKit::PageClientImpl::setCustomRepresentationZoomFactor): Ditto.
3434 * UIProcess/API/mac/WKView.mm:
3435 (-[WKView _customRepresentationZoomFactor]): Added. Calls through to the PDFViewController.
3436 (-[WKView _setCustomRepresentationZoomFactor:]): Ditto.
3437 * UIProcess/API/mac/WKViewInternal.h:
3438 * UIProcess/API/qt/qwkpage_p.h:
3439 (QWKPagePrivate::customRepresentationZoomFactor): Added.
3440 (QWKPagePrivate::setCustomRepresentationZoomFactor): Added.
3441 * UIProcess/PageClient.h:
3442 * UIProcess/WebPageProxy.cpp:
3443 (WebKit::WebPageProxy::WebPageProxy): Coding style fix.
3444 (WebKit::WebPageProxy::supportsTextZoom): Added. Returns false if the main frame has a custom
3445 representation or is a standalone image, true otherwise.
3446 (WebKit::WebPageProxy::setTextZoomFactor): Bail out if the main frame has a custom representation.
3447 (WebKit::WebPageProxy::pageZoomFactor): If the main frame has a custom representation, get the
3448 zoom factor from the page client.
3449 (WebKit::WebPageProxy::setPageZoomFactor): If the main frame has a custom representation, have
3450 the client set the zoom factor.
3451 (WebKit::WebPageProxy::setPageAndTextZoomFactors): Ditto.
3452 * UIProcess/WebPageProxy.h:
3453 (WebKit::WebPageProxy::textZoomFactor): Changed to return 1 if the main frame has a custom
3455 * UIProcess/win/WebView.cpp:
3456 (WebKit::WebView::customRepresentationZoomFactor): Added.
3457 (WebKit::WebView::setCustomRepresentationZoomFactor): Added.
3458 * UIProcess/win/WebView.h:
3460 2011-01-08 Jeff Miller <jeffm@apple.com>
3462 Reviewed by Jon Honeycutt.
3464 Add WKBundleFrameGetVisibleContentBounds().
3465 https://bugs.webkit.org/show_bug.cgi?id=52089
3467 * WebProcess/InjectedBundle/API/c/WKBundleFrame.cpp:
3468 (WKBundleFrameGetVisibleContentBounds):
3469 * WebProcess/InjectedBundle/API/c/WKBundleFrame.h:
3470 Added WKBundleFrameGetVisibleContentBounds().
3472 2011-01-08 Balazs Kelemen <kbalazs@webkit.org>
3474 Reviewed by Kenneth Rohde Christiansen.
3476 [Qt][WK2] QWKView does not propagate show and hide events to the drawing area
3477 https://bugs.webkit.org/show_bug.cgi?id=52108
3479 * UIProcess/API/qt/qgraphicswkview.cpp:
3480 (QGraphicsWKView::event): Call setPageIsVisible on the drawing area
3481 if the event is Show or Hide.
3483 2011-01-08 Laszlo Gombos <laszlo.1.gombos@nokia.com>
3485 Reviewed by Kenneth Rohde Christiansen.
3487 [Qt][Symbian] Make sure WebKit headers are included before platform headers on Symbian
3488 https://bugs.webkit.org/show_bug.cgi?id=31273
3490 On Symbian PREPEND_INCLUDEPATH is the best way to make sure that WebKit headers
3491 are included before platform headers. On all other platforms continue to use
3492 INCLUDEPATH (as before).
3496 2011-01-08 Csaba Osztrogonác <ossy@webkit.org>
3498 [Qt][WK2] Unreviewed buildfix after r75313.
3500 * Scripts/generate-forwarding-headers.pl:
3502 2011-01-08 Adam Barth <abarth@webkit.org>
3504 Moving WebCore changes the layout of the Qt build directory as well,
3505 which means we need to change where we look for these generated files.
3507 * DerivedSources.pro:
3509 2011-01-07 Adam Barth <abarth@webkit.org>
3511 Rubber-stamped by Eric Seidel.
3513 Move WebCore to Source
3514 https://bugs.webkit.org/show_bug.cgi?id=52050
3518 2011-01-07 Stephanie Lewis <slewis@apple.com>
3520 Reviewed by Geoff Garen.
3522 <rdar://problem/8649617> Migrate memory tracking from Safari to WebKit
3523 https://bugs.webkit.org/show_bug.cgi?id=50799 Add Memory Sampler to WebKit
3525 Add a sampler for printing off process memory statistics.
3526 This tool can track:
3529 - FastMalloc allocations bytes (in use or committed)
3531 - Garbage collector heap bytes (in use or committed)
3532 - Stack bytes (committed only!)
3533 - JIT Code bytes (committed only!)
3535 - In use bytes for the following zones:
3536 * Default zone (in use or committed)
3537 * DispCon zone (in use or committed)
3538 * Purgable zone (in use or committed)
3540 - Resident size memory (RSIZE)
3542 Data collected is dumped to a temporary file.
3544 Create a sandbox for a temporary file.
3545 * Shared/SandboxExtension.h:
3546 (WebKit::SandboxExtension::createHandleForTemporaryFile):
3547 * Shared/mac/SandboxExtensionMac.mm:
3548 (WebKit::SandboxExtension::createHandleForTemporaryFile):
3550 Memory Sampler files
3552 * Shared/WebMemorySampler.cpp: Added.
3553 (WebKit::WebMemorySampler::shared):
3554 (WebKit::WebMemorySampler::WebMemorySampler):
3555 (WebKit::WebMemorySampler::start):
3556 (WebKit::WebMemorySampler::initializeTimers):
3557 (WebKit::WebMemorySampler::stop):
3558 (WebKit::WebMemorySampler::isRunning):
3559 (WebKit::WebMemorySampler::initializeTempLogFile):
3560 (WebKit::WebMemorySampler::initializeSandboxedLogFile):
3561 (WebKit::WebMemorySampler::writeHeaders):
3562 (WebKit::WebMemorySampler::sampleTimerFired):
3563 (WebKit::WebMemorySampler::stopTimerFired):
3564 (WebKit::WebMemorySampler::appendCurrentMemoryUsageToFile):
3565 * Shared/WebMemorySampler.h: Added.
3566 * Shared/mac/WebMemorySampler.mac.mm: Added.
3567 (WebKit::WebMemorySampler::sampleSystemMalloc):
3568 (WebKit::WebMemorySampler::sampleProcessCommittedBytes):
3569 (WebKit::WebMemorySampler::processName):
3570 (WebKit::WebMemorySampler::sampleWebKit):
3572 API to start and stop UIProcess and WebProcess sampling.
3574 * UIProcess/API/C/WKContext.cpp:
3575 (WKContextStartMemorySampler):
3576 (WKContextStopMemorySampler):
3577 * UIProcess/API/C/WKContext.h:
3579 Send messages to WebProcess to start and stop memory sampling.
3581 * UIProcess/WebContext.cpp:
3582 (WebKit::WebContext::WebContext):
3583 (WebKit::WebContext::processDidFinishLaunching):
3584 (WebKit::WebContext::startMemorySampler):
3585 (WebKit::WebContext::stopMemorySampler):
3586 * UIProcess/WebContext.h:
3587 * WebKit2.xcodeproj/project.pbxproj:
3588 * WebProcess/WebProcess.cpp:
3589 (WebKit::WebProcess::startMemorySampler):
3590 (WebKit::WebProcess::stopMemorySampler):
3591 * WebProcess/WebProcess.h:
3592 * WebProcess/WebProcess.messages.in:
3594 2011-01-07 Jessie Berlin <jberlin@apple.com>
3596 Reviewed by Dan Bernstein.
3598 WebKit2: Need WKBundleFrameCopyProvisionalURL
3599 https://bugs.webkit.org/show_bug.cgi?id=52083
3601 * WebProcess/InjectedBundle/API/c/WKBundleFrame.cpp:
3602 (WKBundleFrameCopyProvisionalURL):
3603 * WebProcess/InjectedBundle/API/c/WKBundleFrame.h:
3604 * WebProcess/WebPage/WebFrame.cpp:
3605 (WebKit::WebFrame::provisionalURL):
3606 Grab the URL from the provisional document loader.
3607 * WebProcess/WebPage/WebFrame.h:
3609 2011-01-07 James Robinson <jamesr@chromium.org>
3611 Revert "Implement mozilla's animationTime property"
3612 https://bugs.webkit.org/show_bug.cgi?id=51952
3614 This approach isn't quite right.
3616 * WebProcess/WebPage/ChunkedUpdateDrawingArea.cpp:
3617 (WebKit::ChunkedUpdateDrawingArea::display):
3618 (WebKit::ChunkedUpdateDrawingArea::setSize):
3619 * WebProcess/WebPage/WebPage.cpp:
3620 (WebKit::WebPage::drawRect):
3621 * WebProcess/WebPage/mac/LayerBackedDrawingAreaMac.mm:
3622 (WebKit::LayerBackedDrawingArea::syncCompositingLayers):
3624 2011-01-07 Amruth Raj <amruthraj@motorola.com> and Ravi Phaneendra Kasibhatla <ravi.kasibhatla@motorola.com>
3626 Reviewed by Martin Robinson.
3628 [GTK] WebKit2 GNUmakefile is out of date from trunk
3629 Adding new stub files for compiling on latest revision
3630 https://bugs.webkit.org/show_bug.cgi?id=51883
3632 * UIProcess/gtk: Added.
3633 * UIProcess/gtk/TextCheckerGtk.cpp: Added.
3634 (WebKit::TextChecker::state):
3635 (WebKit::TextChecker::isContinuousSpellCheckingAllowed):
3636 (WebKit::TextChecker::setContinuousSpellCheckingEnabled):
3637 (WebKit::TextChecker::setGrammarCheckingEnabled):
3638 (WebKit::TextChecker::uniqueSpellDocumentTag):
3639 (WebKit::TextChecker::closeSpellDocumentWithTag):
3640 (WebKit::TextChecker::checkTextOfParagraph):
3641 (WebKit::TextChecker::updateSpellingUIWithMisspelledWord):
3642 (WebKit::TextChecker::getGuessesForWord):
3643 (WebKit::TextChecker::learnWord):