WebCore: Update WebKitSystemInterface for <rdar://problem/7237059>.
[WebKit-https.git] / WebKit / mac / ChangeLog
1 2009-12-18  Sam Weinig  <sam@webkit.org>
2
3         Reviewed by Anders Carlsson.
4
5         Update WebKitSystemInterface for <rdar://problem/7237059>.        
6
7         * WebCoreSupport/WebSystemInterface.m:
8         (InitWebCoreSystemInterface):
9
10 2009-12-18  Adam Roben  <aroben@apple.com>
11
12         Add #includes needed after WebCore clean-up
13
14         Rubber-stamped by Anders Carlsson.
15
16         Fixes <http://webkit.org/b/32718>.
17
18         * WebView/WebFrame.mm:
19         * WebView/WebFrameView.mm:
20         * WebView/WebView.mm:
21
22 2009-12-17  Adam Roben  <aroben@apple.com>
23
24         Mac build fix
25
26         * WebView/WebVideoFullscreenController.mm: Added now-needed #import.
27
28 2009-12-13  Sam Weinig  <sam@webkit.org>
29
30         Reviewed by Dan Bernstein.
31
32         Fix for https://bugs.webkit.org/show_bug.cgi?id=32499
33         Add client based Geolocation provider
34
35         Add first cut of a client based Geolocation provider. This is guarded by
36         ENABLE(CLIENT_BASED_GEOLOCATION) and is off by default for now. This adds a
37         GeolocationControllerClient interface that no-one currently implements,
38         but will in a subsequent patch.
39
40         * WebView/WebView.mm:
41         (-[WebView _commonInitializationWithFrameName:groupName:usesDocumentViews:]):
42
43 2009-12-10  Jon Honeycutt  <jhoneycutt@apple.com>
44
45         Mac build fix. Unreviewed.
46
47         Re-adds code that was mistakenly removed from my last patch.
48
49         * WebCoreSupport/WebPluginHalterClient.mm:
50         Add necessary #import.
51
52         * WebView/WebDelegateImplementationCaching.h:
53         Declare a new overload of CallUIDelegateReturningBoolean.
54
55         * WebView/WebDelegateImplementationCaching.mm:
56         (CallDelegateReturningBoolean):
57         Add a new overload with different arguments.
58         (CallUIDelegateReturningBoolean):
59         Ditto.
60
61 2009-12-10  Jon Honeycutt  <jhoneycutt@apple.com>
62
63         Pass more information about a plug-in to the PluginHalterDelegate
64
65         Reviewed by Adam Roben.
66
67         * Plugins/WebBaseNetscapePluginView.mm:
68         (WebHaltablePlugin::isWindowed):
69         Return false - the Mac doesn't really have windowed plug-ins.
70         (WebHaltablePlugin::pluginName):
71         Return the name from the plug-in package.
72
73         * WebCoreSupport/WebPluginHalterClient.h:
74         Update for new parameters.
75
76         * WebCoreSupport/WebPluginHalterClient.mm:
77         (WebPluginHalterClient::shouldHaltPlugin):
78         Ditto; pass them when making the delegate call.
79
80         * WebView/WebUIDelegatePrivate.h:
81         Update for new parameters.
82
83 2009-12-08  Simon Fraser  <simon.fraser@apple.com>
84
85         Reviewed by Dan Bernstein.
86
87         <rdar://problem/7295070> WebKit video fullscreen keeps playing after closing the window
88         
89         Fix a leak of the QTMovieView when exiting fullscreen video, and remove the
90         old workaround.
91
92         * WebView/WebVideoFullscreenController.mm:
93         (-[WebVideoFullscreenController windowDidLoad]): Set the movie view as the contentView directly.
94         (-[WebVideoFullscreenController setMediaElement:WebCore::]): Cast the contentView to a movie view.
95         (-[WebVideoFullscreenController windowDidExitFullscreen]): Remove the old workaround.
96
97 2009-12-08  Dmitry Titov  <dimich@chromium.org>
98
99         Rubber-stamped by David Levin.
100
101         Revert and reopen "Add asserts to RefCounted to make sure ref/deref happens on the right thread."
102         It may have caused massive increase of reported leaks on the bots.
103         https://bugs.webkit.org/show_bug.cgi?id=31639
104
105         * ForwardingHeaders/wtf/ThreadVerifier.h: Removed.
106
107 2009-12-08  Dmitry Titov  <dimich@chromium.org>
108
109         Reviewed by Darin Adler.
110
111         Add asserts to RefCounted to make sure ref/deref happens on the right thread.
112         https://bugs.webkit.org/show_bug.cgi?id=31639
113
114         * ForwardingHeaders/wtf/ThreadVerifier.h: Added.
115
116 2009-12-07  Dmitry Titov  <dimich@chromium.org>
117
118         Rubber-stamped by Darin Adler.
119
120         Remove ENABLE_SHARED_SCRIPT flags
121         https://bugs.webkit.org/show_bug.cgi?id=32245
122         This patch was obtained by "git revert" command and then un-reverting of ChangeLog files.
123
124         * Configurations/FeatureDefines.xcconfig:
125
126 2009-12-07  Simon Fraser  <simon.fraser@apple.com>
127
128         Reviewed by Darin Adler.
129
130         <rdar://problem/7450481> One compositing test keeps DRT in "compositing mode", breaks repaint tests
131
132         The counter that WebView used to keep track of the number of enclosed WebHTMLViews using
133         accelerated compositing was hard to manage, and maintained incorrectly in a number of cases.
134         This caused one compositing test make DumpRenderTree think that all subsequent tests
135         were compositing too.
136         
137         Replace this counter with notifications, which are only fired if a client (DRT) requests them. The
138         notification informs the client that a WebHTMLView entered compositing mode (or an already-
139         compositing WebHTML was added); it does not say when a view becomes uncomposited, or all
140         compositing subviews were removed, since this is tricky to get right.
141         
142         Change -[WebView _isUsingAcceleratedCompositing] to manually walk the frames, and
143         return YES if any document view is composited.
144
145         * WebKit.exp:
146         * WebView/WebHTMLView.mm:
147         (-[WebHTMLView close]):
148         (-[WebHTMLView viewDidMoveToSuperview]):
149         (-[WebHTMLView attachRootLayer:]):
150         (-[WebHTMLView detachRootLayer]):
151         * WebView/WebView.mm:
152         (+[WebView automaticallyNotifiesObserversForKey:]):
153         (-[WebView _postsAcceleratedCompositingNotifications]):
154         (-[WebView _setPostsAcceleratedCompositingNotifications:]):
155         (-[WebView _isUsingAcceleratedCompositing]):
156         * WebView/WebViewData.h:
157         * WebView/WebViewInternal.h:
158         * WebView/WebViewPrivate.h:
159
160 2009-12-07  Gavin Barraclough  <barraclough@apple.com>
161
162         Reviewed by Oliver Hunt.
163
164         https://bugs.webkit.org/show_bug.cgi?id=32184
165         Handle out-of-memory conditions with JSC Ropes with a JS exception, rather than crashing.
166         Switch from using fastMalloc to tryFastMalloc, pass an ExecState to record the exception on.
167
168         * WebView/WebView.mm:
169         (aeDescFromJSValue):
170
171 2009-12-07  Nikolas Zimmermann  <nzimmermann@rim.com>
172
173         Reviewed by Holger Hans Peter Freyther.
174
175         Turn on (SVG) Filters support, by default.
176         https://bugs.webkit.org/show_bug.cgi?id=32224
177
178         * Configurations/FeatureDefines.xcconfig: Enable FILTERS build flag.
179
180 2009-12-03  Brady Eidson  <beidson@apple.com>
181
182         Reviewed by Sam Weinig.
183
184         <rdar://problem/7214236> and http://webkit.org/b/32052 - Implement HTML5 state object history API
185
186         * WebCoreSupport/WebFrameLoaderClient.h:
187         * WebCoreSupport/WebFrameLoaderClient.mm:
188         (WebFrameLoaderClient::dispatchDidPushStateWithinPage):
189         (WebFrameLoaderClient::dispatchDidReplaceStateWithinPage):
190         (WebFrameLoaderClient::dispatchDidPopStateWithinPage):
191         * WebView/WebDelegateImplementationCaching.h:
192         * WebView/WebFrameLoadDelegatePrivate.h:
193         * WebView/WebView.mm:
194         (-[WebView _cacheFrameLoadDelegateImplementations]):
195
196 2009-12-03  Pavel Feldman  <pfeldman@dhcp-172-28-174-220.spb.corp.google.com>
197
198         Reviewed by Timothy Hatcher.
199
200         Web Inspector: Simplify the settings support in inspector controller.
201
202         https://bugs.webkit.org/show_bug.cgi?id=32076
203
204         * WebCoreSupport/WebInspectorClient.h:
205         * WebCoreSupport/WebInspectorClient.mm:
206         (-[WebInspectorWindowController showWindow:]):
207         (-[WebInspectorWindowController attach]):
208         (-[WebInspectorWindowController detach]):
209
210 2009-12-03  Ben Murdoch  <benm@google.com>
211
212         Reviewed by Brady Eidson.
213
214         [Android] notifyHistoryItemChanged() should pass a pointer to the HistoryItem that changed.
215         https://bugs.webkit.org/show_bug.cgi?id=31915
216
217         * History/WebHistoryItem.mm:
218         (WKNotifyHistoryItemChanged): Update WKNotifyHistoryItemChanged() to add the new HistoryItem parameter added in the WebCore portion of this patch.
219         * History/WebHistoryItemInternal.h: ditto.
220
221 2009-12-03  Ben Murdoch  <benm@google.com>
222
223         Reviewed by Brady Eidson.
224
225         [Android] The FrameLoaderClient is unaware of BackForwardList changes.
226         https://bugs.webkit.org/show_bug.cgi?id=31914
227
228         * WebCoreSupport/WebFrameLoaderClient.h:
229         * WebCoreSupport/WebFrameLoaderClient.mm:
230         (WebFrameLoaderClient::dispatchDidAddBackForwardItem): Add an empty implementation. Method added to FrameLoaderClient by Android (see bug).
231         (WebFrameLoaderClient::dispatchDidRemoveBackForwardItem): ditto.
232         (WebFrameLoaderClient::dispatchDidChangeBackForwardIndex): ditto.
233
234 2009-12-02  Dan Bernstein  <mitz@apple.com>
235
236         Reviewed by Mark Rowe.
237
238         Fix a mistake in the previous change
239
240         * WebView/WebView.mm:
241         (+[WebView _viewClass:andRepresentationClass:forMIMEType:allowingPlugins:]):
242         Make sure to include the image types’ view and representation classes
243         even when plug-ins are not allowed.
244
245 2009-12-02  Dan Bernstein  <mitz@apple.com>
246
247         Reviewed by Anders Carlsson.
248
249         Fixed <rdar://problem/7254127> WebKit can load plug-ins even when
250         plug-ins are disabled
251
252         Ensure that the shared WebPluginDatabase is not instantiated if no
253         WebViews are used that have plug-ins enabled.
254
255         * DefaultDelegates/WebDefaultPolicyDelegate.m:
256         (-[WebDefaultPolicyDelegate webView:decidePolicyForMIMEType:request:frame:decisionListener:]):
257         Call -[WebView _canShowMIMEType:] on the WebView instead of calling the
258         class method.
259
260         * WebCoreSupport/WebFrameLoaderClient.mm:
261         (WebFrameLoaderClient::canShowMIMEType): Ditto.
262         (WebFrameLoaderClient::transitionToCommittedForNewPage): Call
263         -[WebFrameView _viewClassForMIMEType:] on the WebView instead of calling
264         the class method.
265         (WebFrameLoaderClient::objectContentType): Ditto.
266
267         * WebView/WebDataSource.mm:
268         (+[WebDataSource _representationClassForMIMEType:allowingPlugins:]):
269         Added the allowPlugins parameter, which is passed through to
270         +[WebView _viewClass:andRepresentationClass:forMIMEType:allowingPlugins:].
271         (-[WebDataSource _makeRepresentation]): Pass an allowPlugins value
272         based on the WebView’s preferences.
273
274         * WebView/WebFrameView.mm:
275         (-[WebFrameView _makeDocumentViewForDataSource:]): Call
276         -[WebFrameView _viewClassForMIMEType:] instead of calling the class
277         method.
278         (+[WebFrameView _viewClassForMIMEType:allowingPlugins:]): Added the
279         allowPlugins parameter, which is passed through to
280         +[WebView _viewClass:andRepresentationClass:forMIMEType:allowingPlugins:].
281         (-[WebFrameView _viewClassForMIMEType:]): Added. Passes an allowPlugins
282         value based on the WebView’s preferences.
283
284         * WebView/WebFrameViewInternal.h:
285         * WebView/WebView.mm:
286         (+[WebView _viewClass:andRepresentationClass:forMIMEType:allowingPlugins:]):
287         Added the allowPlugins parameter. If false, skip the instantiation of
288         the shared WebPluginDatabase.
289         (-[WebView _viewClass:andRepresentationClass:forMIMEType:]): Pass an
290         allowPlugins value based on the WebView’s preferences.
291         (+[WebView _canShowMIMEType:allowingPlugins:]): Passes allowPlugins to
292         +_viewClass:andRepresentationClass:forMIMEType:allowingPlugins:.
293         (+[WebView canShowMIMEType:]): Changed to pass YES to
294         +_canShowMIMEType:allowingPlugins:.
295         (-[WebView _canShowMIMEType:]): Added. Passes an allowPlugins value
296         based on the WebView’s preferences.
297         (-[WebView _pluginForMIMEType:]): Return nil if plug-ins are disabled.
298         (-[WebView _pluginForExtension:]): Ditto.
299         (-[WebView _isMIMETypeRegisteredAsPlugin:]): Return NO if plug-ins are
300         disabled.
301         * WebView/WebViewInternal.h:
302
303 2009-12-02  Timothy Hatcher  <timothy@apple.com>
304
305         Fixes a crash when scrolling a frame that goes away mid-scroll.
306
307         <rdar://problem/7400263>
308
309         Reviewed by John Sullivan.
310
311         * WebView/WebDynamicScrollBarsView.mm:
312         (-[WebDynamicScrollBarsView scrollWheel:]): Retain self incase the last
313         reference is released when calling super.
314
315 2009-11-13  Timothy Hatcher  <timothy@apple.com>
316
317         Migrate DOMHTMLInputElementPrivate.h as a private header.
318
319         Reviewed by Darin Adler.
320
321         * MigrateHeaders.make:
322
323 2009-12-01  Nikolas Zimmermann  <nzimmermann@rim.com>
324
325         Reviewed by Simon Fraser.
326
327         Add SVG animation test framework with 'snapshot' functionality
328         https://bugs.webkit.org/show_bug.cgi?id=31897
329
330         Add API used by the new 'sampleSVGAnimationForElementAtTime' DRT method,
331         forwarding the call to SVGDocumentExtensions, if SVG is enabled.
332
333         Implemented just like the existing pauseAnimation* methods for CSS animations.
334
335         * WebView/WebFrame.mm:
336         (-[WebFrame _pauseSVGAnimation:onSMILNode:atTime:]):
337         * WebView/WebFramePrivate.h:
338
339 2009-12-01  Sam Weinig  <sam@webkit.org>
340
341         Reviewed by Mark Rowe.
342
343         Simplify [WebView userAgentForURL:].  No need to call into helper function.
344
345         * WebCoreSupport/WebFrameLoaderClient.mm:
346         (WebFrameLoaderClient::userAgent):
347         * WebView/WebView.mm:
348         (-[WebView userAgentForURL:]):
349         * WebView/WebViewInternal.h:
350
351 2009-11-24  Gavin Barraclough  <barraclough@apple.com>
352
353         Reviewed by Geoff Garen.
354
355         Bug 31859 - Make world selection for JSC IsolatedWorlds automagical.
356
357         WebCore presently has to explicitly specify the world before entering into JSC,
358         which is a little fragile (particularly since property access via a
359         getter/setter might invoke execution). Instead derive the current world from
360         the lexical global object.
361
362         Since WebCore no longer needs to explicitly specify the world on entry to JSC DebuggerCallFrame::evaluate can be called directly.
363
364         * WebView/WebScriptDebugDelegate.mm:
365         (-[WebScriptCallFrame evaluateWebScript:]):
366
367 2009-11-24  Dmitry Titov  <dimich@chromium.org>
368
369         Reviewed by Eric Seidel.
370
371         Add ENABLE_SHARED_SCRIPT feature define and flag for build-webkit
372         https://bugs.webkit.org/show_bug.cgi?id=31444
373
374         * Configurations/FeatureDefines.xcconfig:
375
376 2009-11-24  Alexey Proskuryakov  <ap@apple.com>
377
378         Reviewed by Brady Eidson.
379
380         https://bugs.webkit.org/show_bug.cgi?id=31844
381         SocketStreamHandleCFNet should support CONNECT proxy credentials
382
383         * WebCoreSupport/WebSystemInterface.m: (InitWebCoreSystemInterface): Add WKSI methods.
384
385 2009-11-23  Simon Fraser  <simon.fraser@apple.com>
386
387         Reviewed by Dan Bernstein.
388
389         DocumentMarkers need to be educated about transforms
390         https://bugs.webkit.org/show_bug.cgi?id=31751
391         
392         Find highlight is incorrect with transforms
393         <rdar://problem/6358394>
394         
395         Allow callers to specify that Frame::selectionTextRects() takes transforms into account
396         when computing the set of rects that encompass a selection. For transformed elemenets, the
397         selection rect will be the bounding box of the selected content.
398         
399         Fix DocumentMarkers to cache rects in absolute coordinates, rather than painting coordinates.
400         
401         * WebView/WebHTMLView.mm:
402         (-[WebHTMLView selectionTextRects]):
403         Pass RespectTransforms to get a list of rects with transforms taken into account.
404
405 2009-11-23  Kevin Decker  <kdecker@apple.com>
406
407         Reviewed by Adam Roben.
408         
409         <rdar://problem/7401503>
410         
411         Added a workaround for plug-ins not drawing immediately.
412         
413         * Plugins/WebBaseNetscapePluginView.mm: Added new constant.
414         (-[WebBaseNetscapePluginView _clearSubstituteImage]): Added.
415         (-[WebBaseNetscapePluginView resumeFromHalt]): Call above new method.
416
417 2009-11-20  Dave Hyatt  <hyatt@apple.com>
418
419         Reviewed by Darin Adler.
420
421         Make sure to export WebSerializedJSValue.
422
423         * WebKit.exp:
424
425 2009-11-20  Dave Hyatt  <hyatt@apple.com>
426
427         Reviewed by Oliver Hunt and Jon Honeycutt.
428
429         Add support for WebSerializedJSValue to WebKit.  This object wraps the SerializedScriptValue functionality in WebCore
430         and exposes the ability to do JS value serialization/deserialization to WebKit clients.
431
432         * WebView/WebSerializedJSValue.h: Added.
433         * WebView/WebSerializedJSValue.mm: Added.
434         (-[WebSerializedJSValue initWithValue:context:]):
435         (-[WebSerializedJSValue deserialize:]):
436         (-[WebSerializedJSValue dealloc]):
437
438 2009-11-20  Chris Fleizach  <cfleizach@apple.com>
439
440         Reviewed by Beth Dakin.
441
442         WAI-ARIA: add support for 'math' role
443         https://bugs.webkit.org/show_bug.cgi?id=31706
444
445         * WebCoreSupport/WebViewFactory.mm:
446         (-[WebViewFactory AXARIAContentGroupText:]):
447
448 2009-11-19  Eric Carlson  <eric.carlson@apple.com>
449
450         Reviewed by Dan Bernstein.
451
452         <rdar://problem/7035231>
453         Support closed caption in <video> element
454
455         * WebCoreSupport/WebSystemInterface.m:
456         (InitWebCoreSystemInterface):
457             Add QTMovieHasClosedCaptions and QTMovieSetShowClosedCaptions.
458
459         * WebCoreSupport/WebViewFactory.mm:
460         (-[WebViewFactory localizedMediaControlElementString:]):
461         (-[WebViewFactory localizedMediaControlElementHelpText:]):
462             Add accessibility help strings for media controller closed caption button.
463
464 2009-11-18  Michelangelo De Simone  <micdesim@gmail.com>
465
466         Reviewed by Darin Adler.
467
468         Fix for <https://bugs.webkit.org/show_bug.cgi?id=27959>.
469         Support for validationMessage attribute, as per HTML5 specs.
470
471         * WebCoreSupport/WebViewFactory.mm:
472         (-[WebViewFactory validationMessageValueMissingText]):
473         (-[WebViewFactory validationMessageTypeMismatchText]):
474         (-[WebViewFactory validationMessagePatternMismatchText]):
475         (-[WebViewFactory validationMessageTooLongText]):
476         (-[WebViewFactory validationMessageRangeUnderflowText]):
477         (-[WebViewFactory validationMessageRangeOverflowText]):
478         (-[WebViewFactory validationMessageStepMismatchText]):
479
480 2009-11-18  Sam Weinig  <sam@webkit.org>
481
482         Reviewed by Anders Carlsson.
483
484         Make the Mac Geolocation API async.
485
486         * WebCoreSupport/WebChromeClient.mm:
487         (WebChromeClient::requestGeolocationPermissionForFrame):
488         (-[WebGeolocationPolicyListener initWithGeolocation:]):
489         (-[WebGeolocationPolicyListener allow]):
490         (-[WebGeolocationPolicyListener deny]):
491         Add WebGeolocationPolicyListener implementation of the new WebGeolocationPolicyListener
492         protocol and use if to implement requestGeolocationPermissionForFrame using the new async
493         API.
494         
495         * WebCoreSupport/WebGeolocation.mm: Removed.
496         * WebCoreSupport/WebGeolocationInternal.h: Removed.
497         * WebCoreSupport/WebGeolocationMock.mm: Remove bogus include.
498         * WebCoreSupport/WebGeolocationPrivate.h: Removed.
499         * WebView/WebUIDelegatePrivate.h: Remove requestGeolocationPermission and add
500         WebGeolocationPolicyListener protocol and decidePolicyForGeolocationRequestFromOrigin delegate
501         method.
502
503 2009-11-18  Chris Marrin  <cmarrin@apple.com>
504
505         Reviewed by Simon Fraser.
506
507         Add Preferences for WebKitShowDebugBorders and WebKitShowRepaintCounter
508         https://bugs.webkit.org/show_bug.cgi?id=31601
509
510         These are used to debug accelerated compositing layers
511
512         * WebView/WebPreferenceKeysPrivate.h:
513         * WebView/WebPreferences.mm:
514         (+[WebPreferences initialize]):
515         (-[WebPreferences showDebugBorders]):
516         (-[WebPreferences setShowDebugBorders:]):
517         (-[WebPreferences showRepaintCounter]):
518         (-[WebPreferences setShowRepaintCounter:]):
519         * WebView/WebPreferencesPrivate.h:
520         * WebView/WebView.mm:
521         (-[WebView _preferencesChangedNotification:]):
522
523 2009-11-17  Pavel Feldman  <pfeldman@chromium.org>
524
525         Reviewed by Timothy Hatcher.
526
527         Web Inspector: Make DRT show web inspector for tests in inspector/ folder.
528         - Updated DRT to show/close inspector for all tests under /inspector
529         - Introduced LayoutTestController::setTimelineProfilingEnabled and
530           WebInspector::setTimelineProfilingEnabled beside setJavaScriptProfilingEnabled
531         - Removed reload on each inspector test
532         - Renamed fast/inspector to fast/inspector-support in order not to trigger
533         inspector for those.
534         - Reimplemented timeline tests in order to get rid of reload there.
535         - Moved tests that don't require harness into the fast group.
536
537         https://bugs.webkit.org/show_bug.cgi?id=31472
538
539         * WebInspector/WebInspector.h:
540         * WebInspector/WebInspector.mm:
541         (-[WebInspector isTimelineProfilingEnabled]):
542         (-[WebInspector setTimelineProfilingEnabled:]):
543
544 2009-11-14  Chris Fleizach  <cfleizach@apple.com>
545
546         Reviewed by Darin Adler.
547
548         Need to implement ARIA role="directory"
549         https://bugs.webkit.org/show_bug.cgi?id=31516
550
551         Fix a spelling error in the comment of a localized (accessibility) string.
552
553         * WebCoreSupport/WebViewFactory.mm:
554         (-[WebViewFactory AXARIAContentGroupText:]):
555
556 2009-11-14  Eric Carlson  <eric.carlson@apple.com>
557
558         Reviewed by Oliver Hunt.
559
560         <rdar://problem/7287487> 
561         Do not use QuickTime version to detect media controller theme
562
563         * WebCoreSupport/WebSystemInterface.m:
564         (InitWebCoreSystemInterface): Initialize wkMediaControllerThemeAvailable.
565
566 2009-11-13  Adam Roben  <aroben@apple.com>
567
568         Tell the WebFrameLoadDelegate when window objects in isolated worlds
569         are cleared
570
571         Fixes <http://webkit.org/b/31124>.
572
573         Reviewed by Dave Hyatt.
574
575         * WebCoreSupport/WebFrameLoaderClient.h:
576         * WebCoreSupport/WebFrameLoaderClient.mm:
577         (WebFrameLoaderClient::dispatchDidClearWindowObjectInWorld):
578         Replaced windowObjectCleared with this function. If the delegate
579         implements it, call
580         -webView:didClearWindowObjectForFrame:inScriptWorld:. Otherwise, if
581         the passed-in world is the mainThreadNormalWorld(), call
582         -webView:didClearWindowObject:forFrame:.
583
584         * WebView/WebDelegateImplementationCaching.h: Added a new entry in the
585         frame load delegate implementation cache for the new delegate method.
586
587         * WebView/WebFrameLoadDelegatePrivate.h:
588         * WebView/WebScriptWorld.mm:
589         (allWorlds): Added. Returns a HashMap of all the WebScriptWorlds in
590         existence.
591         (-[WebScriptWorld initWithWorld:]): Add ourselves to allWorlds().
592         (-[WebScriptWorld dealloc]): Remove ourselves from allWorlds().
593         (+[WebScriptWorld findOrCreateWorld:]): Returns the existing
594         WebScriptWorld for this DOMWrapperWorld, or a new one if one doesn't
595         already exist.
596
597         * WebView/WebScriptWorldInternal.h: Declared +findOrCreateWorld:.
598
599         * WebView/WebView.mm:
600         (-[WebView _cacheFrameLoadDelegateImplementations]): Cache the
601         implementation of the new frame load delegate method.
602
603 2009-11-13  Adam Roben  <aroben@apple.com>
604
605         Finish replacing worldIDs with world objects
606
607         The only remaining use of worldIDs was in a method only used by DRT
608         for the isolated worlds tests.
609
610         Fixes <http://webkit.org/b/31414> Replace worldIDs with world objects
611
612         Reviewed by Mark Rowe.
613
614         * WebView/WebFrame.mm:
615         (-[WebFrame _stringByEvaluatingJavaScriptFromString:withGlobalObject:inScriptWorld:]):
616         * WebView/WebFramePrivate.h:
617         Renamed from
618         _stringByEvaluatingJavaScriptInIsolatedWorld:WithGobalObject:FromString:.
619         Now takes a WebScriptWorld instead of a worldID, so we don't need to
620         maintain a map of worldID -> world anymore.
621
622 2009-11-12  Dan Bernstein  <mitz@apple.com>
623
624         Reviewed by Adele Peterson.
625
626         When exiting full-screen video, rather than resetting the system UI
627         mode, restore it to what it was when full-screen mode was entered.
628
629         * WebView/WebVideoFullscreenController.h: Cleaned up style, removed
630         unnecessary imports, and added _savedUIMode and _savedUIOptions ivars.
631         * WebView/WebVideoFullscreenController.mm:
632         (-[WebVideoFullscreenController delegate]): Cleaned up style.
633         (-[WebVideoFullscreenController setDelegate:]): Ditto.
634         (-[WebVideoFullscreenController windowDidExitFullscreen]): Restore the
635         system UI mode.
636         (-[WebVideoFullscreenController windowDidEnterFullscreen]): Save the
637         system UI mode.
638         * WebView/WebView.mm: Added now-necessary import.
639
640 2009-11-12  Shinichiro Hamaji  <hamaji@chromium.org>
641
642         Reviewed by Darin Adler.
643
644         externalRepresentation should take Frame as the argument
645         https://bugs.webkit.org/show_bug.cgi?id=31393
646
647         No new tests as this is just a refactoring.
648
649         * Misc/WebCoreStatistics.mm:
650         (-[WebFrame renderTreeAsExternalRepresentation]):
651
652 2009-11-12  Adam Roben  <aroben@apple.com>
653
654         Replace worldIDs with world objects
655
656         WebScriptWorld is the new object that represents a world.  The only
657         place worldID is still used is in -[WebFrame
658         _stringByEvaluatingJavaScriptInIsolatedWorld:WithGlobalObject:FromString:],
659         but that will change soon.
660
661         Part of <http://webkit.org/b/31414> Implement new SPI for dealing with
662         user scripts/stylesheets and isolated worlds
663
664         Reviewed by Sam Weinig.
665
666         * WebKit.exp: Export WebScriptWorld.
667
668         * WebView/WebFrame.mm:
669         (-[WebFrame _stringByEvaluatingJavaScriptInIsolatedWorld:WithGlobalObject:FromString:]):
670         Moved the bizarre world caching/creation logic that DRT depends on
671         here from the findWorld function in ScriptController.cpp. Updated to
672         use ScriptController::executeScriptInWorld instead of
673         ScriptController::executeScriptInIsolatedWorld.
674         (-[WebFrame _contextForWorld:]): Renamed from contextForWorldID:. Now
675         takes a WebScriptWorld.
676
677         * WebView/WebFramePrivate.h: Replaced contextForWorldID: with
678         _contextForWorld:.
679
680         * WebView/WebScriptWorld.h: Added.
681         * WebView/WebScriptWorld.mm: Added.
682         (-[WebScriptWorld initWithWorld:]): Store the passed-in world in our
683         _private member.
684         (-[WebScriptWorld init]): Create a new DOMWrapperWorld and pass it to
685         -initWithWorld:.
686         (-[WebScriptWorld dealloc]): Release _private.
687         (+[WebScriptWorld standardWorld]): Returns a shared instance that
688         represents WebCore's mainThreadNormalWorld().
689         (+[WebScriptWorld world]): Returns a new instance.
690         (core): Returns the DOMWrapperWorld for this WebScriptWorld.
691
692         * WebView/WebScriptWorldInternal.h: Added.
693
694         * WebView/WebView.mm:
695         (+[WebView _addUserScriptToGroup:world:source:url:whitelist:blacklist:injectionTime:]):
696         (+[WebView _addUserStyleSheetToGroup:world:source:url:whitelist:blacklist:]):
697         (+[WebView _removeUserScriptFromGroup:world:url:]):
698         (+[WebView _removeUserStyleSheetFromGroup:world:url:]):
699         (+[WebView _removeUserScriptsFromGroup:world:]):
700         (+[WebView _removeUserStyleSheetsFromGroup:world:]):
701         * WebView/WebViewPrivate.h:
702         Changed these functions to take a WebScriptWorld instead of a worldID.
703
704 2009-11-12  Chris Fleizach  <cfleizach@apple.com>
705
706         Reviewed by Darin Adler.
707
708         ARIA: add alert type roles
709         https://bugs.webkit.org/show_bug.cgi?id=31392
710
711         * WebCoreSupport/WebViewFactory.mm:
712         (-[WebViewFactory AXARIAContentGroupText:]):
713
714 2009-11-10  Daniel Bates  <dbates@webkit.org>
715
716         Reviewed by Oliver Hunt.
717
718         https://bugs.webkit.org/show_bug.cgi?id=30754
719
720         Removed method draggedImage:movedTo:
721
722         * WebView/WebFrame.mm:
723         * WebView/WebFrameInternal.h:
724         * WebView/WebHTMLView.mm:
725
726 2009-11-10  Beth Dakin  <bdakin@apple.com>
727
728         Reviewed by Darin Adler.
729
730         Small WebKit part of:
731         Fix for <rdar://problem/7059710> 
732         -and corresponding-
733         https://bugs.webkit.org/show_bug.cgi?id=31196 Implement -webkit-
734         color-correction for CSS colors
735
736         * Misc/WebKitNSStringExtras.mm:
737         (-[NSString _web_drawAtPoint:font:textColor:]): setFillColor now 
738         requires callers to pass a ColorSpace.
739
740 2009-11-10  Dan Bernstein  <mitz@apple.com>
741
742         Reviewed by Eric Carlson and Darin Adler.
743
744         WebKit part of making full-screen video pause during scrubbing.
745
746         * WebView/WebVideoFullscreenHUDWindowController.h: Added _isScrubbing
747         ivar.
748         * WebView/WebVideoFullscreenHUDWindowController.mm:
749         (-[WebVideoFullscreenHUDWindowController dealloc]): Assert that
750         _isScrubbing is NO.
751         (-[WebVideoFullscreenHUDWindowController endScrubbing]): Call
752         HTMLMediaElement::endScrubbing().
753         (-[WebVideoFullscreenHUDWindowController timelinePositionChanged:]):
754         If scrubbing has just begun, call HTMLMediaElement::beginScrubbing()
755         and schedule -endScrubbing to be called when mouse tracking ends.
756
757 2009-11-09  Mark Mentovai  <mark@chromium.org>
758
759         Reviewed by Dan Bernstein.
760
761         Track "can have scrollbar" state within FrameView independently of the
762         individual scrollbar states in ScrollView.
763
764         rdar://problem/7215132, https://bugs.webkit.org/show_bug.cgi?id=29167
765         REGRESSION (r48064): mint.com loses scrollbars after coming out of
766         edit mode.
767
768         rdar://problem/7314421, https://bugs.webkit.org/show_bug.cgi?id=30517
769         REGRESSION (r48064): Extra scroll bars in GarageBand Lesson Store.
770
771         Test: fast/overflow/scrollbar-restored.html
772
773         * WebView/WebFrameView.mm:
774         (-[WebFrameView _install]):
775
776 2009-11-08  Dan Bernstein  <mitz@apple.com>
777
778         Reviewed by Eric Carlson.
779
780         Made the full-screen video HUD appear when playback stops, such as when
781         the end of the video is reached.
782
783         * WebView/WebVideoFullscreenHUDWindowController.h: Cleaned up.
784         * WebView/WebVideoFullscreenHUDWindowController.mm:
785         (-[WebVideoFullscreenHUDWindowController scheduleTimeUpdate]): Updated
786         for the renaming of -updateRate to -updatePlayButton.
787         (-[WebVideoFullscreenHUDWindowController updatePlayButton]): Renamed
788         -updateRate to this.
789         (-[WebVideoFullscreenHUDWindowController updateRate]): This method now
790         responds to changes to the playback rate by updating the play button
791         and showing or hiding the HUD as necessary.
792         (-[WebVideoFullscreenHUDWindowController togglePlaying:]): Now only
793         toggles playing. UI updates are driven by -updateRate being called.
794         (-[WebVideoFullscreenHUDWindowController playing]): Cleaned up.
795
796 2009-11-02  Eric Carlson  <eric.carlson@apple.com>
797
798         Reviewed by John Sullivan and Mark Rowe.
799
800         <rdar://problem/7356733> Voiceover does not read correct media controller time values
801
802         * WebCoreSupport/WebViewFactory.mm:
803         (-[WebViewFactory localizedMediaTimeDescription:]):
804
805 2009-11-02  Dan Bernstein  <mitz@apple.com>
806
807         Reviewed by Anders Carlsson.
808
809         Made the remaining time display show negative zero at the end of the
810         video.
811
812         Made other cleanup.
813
814         * WebView/WebVideoFullscreenHUDWindowController.h: Reverted the types of
815         _timeline and _volumeSlider to the more generic NSControl.
816         * WebView/WebVideoFullscreenHUDWindowController.mm:
817         (-[WebVideoFullscreenHUDWindowController scheduleTimeUpdate]): Cleaned
818         up style.
819         (-[WebVideoFullscreenHUDWindowController windowDidLoad]): Added an
820         assertion that the cast to NSButton * is legal. Removed casts.
821         (-[WebVideoFullscreenHUDWindowController updateTime]): Use
822         -setValue:forKey: instead of an NSSlider method.
823         (timeToString): Changed to support only non-negative values and
824         simplified.
825         (-[WebVideoFullscreenHUDWindowController remainingTimeText]): Always
826         prepend a “-” to the time.
827
828 2009-11-02  Dan Bernstein  <mitz@apple.com>
829
830         Reviewed by John Sullivan.
831
832         WebKit part of making the appearance of the full-screen video HUD match
833         QuickTime Player X’s HUD.
834
835         * WebView/WebVideoFullscreenHUDWindowController.h: Removed unnecessary
836         #import statements, cleaned up style, and changed _timeline,
837         _volumeSlider and _playButton to have more specific types.
838         * WebView/WebVideoFullscreenHUDWindowController.mm: Updated #import
839         statements.
840         (webkit_CGFloor): Added this helper function.
841         (-[WebVideoFullscreenHUDWindowController init]): Cleaned up style.
842         (createTimeTextField): Changed to use the bold system font.
843         (-[WebVideoFullscreenHUDWindowController windowDidLoad]): Changed the
844         subviews’ metrics and the text fields’ text alignment.
845         (-[WebVideoFullscreenHUDWindowController updateTime]): Avoid conversion
846         from double to float.
847         (stringToTimeTextAttributed): Removed this useless function that
848         returned an NSAttributedString masquerading as an NSString.
849         (-[WebVideoFullscreenHUDWindowController remainingTimeText]): Removed
850         call to stringToTimeTextAttributed().
851         (-[WebVideoFullscreenHUDWindowController elapsedTimeText]): Ditto.
852
853 2009-11-02  Chris Fleizach  <cfleizach@apple.com>
854
855         Reviewed by Beth Dakin.
856
857         Support ARIA "tab" roles
858         https://bugs.webkit.org/show_bug.cgi?id=30842
859
860         * WebCoreSupport/WebViewFactory.mm:
861         (-[WebViewFactory AXARIAContentGroupText:]):
862
863 2009-11-01  Dan Bernstein  <mitz@apple.com>
864
865         Reviewed by Mark Rowe.
866
867         Made the space bar toggle playing state in full-screen video when
868         modifier keys are down. Made it do so without highlighting the
869         Play/Pause button.
870
871         * WebView/WebVideoFullscreenHUDWindowController.mm:
872         (-[WebVideoFullscreenHUDWindowController keyDown:]):
873
874 2009-11-01  Dan Bernstein  <mitz@apple.com>
875
876         Reviewed by Mark Rowe.
877
878         Made the full-screen video HUD respond to the up and down arrow keys by
879         increasing and decreasing the volume by 1/10 of the range or, when
880         combined with the Option key, all the way up or down.
881
882         Made the volume buttons in the full-screen video HUD match the behavior
883         of their equivalents in the QuickTime Player HUD by turning the volume
884         all the way up or down.
885
886         Made the volume slider update immediately when the keyboard or volume
887         buttons are used to change the volume, rather than at the nearest 1/4
888         second interval.
889
890         Made the elapsed and remaining time displays update immediately when the
891         play head is dragged across the timeline, rather than at 1/4 second
892         intervals.
893
894         * WebView/WebVideoFullscreenHUDWindowController.mm:
895         (-[WebVideoFullscreenHUDWindowController keyDown:]): Handle the up and
896         down arrow keys.
897         (-[WebVideoFullscreenHUDWindowController windowDidLoad]): Changed the
898         actions of the volume up and volume down buttons.
899         (-[WebVideoFullscreenHUDWindowController setCurrentTime:]): Call
900         -updateTime.
901         (-[WebVideoFullscreenHUDWindowController setVolumeToZero:]): Added this
902         action for the volume down button.
903         (-[WebVideoFullscreenHUDWindowController setVolumeToMaximum:]): Added
904         this action for the volume up button.
905         (-[WebVideoFullscreenHUDWindowController decrementVolume]): No longer
906         and action method.
907         (-[WebVideoFullscreenHUDWindowController incrementVolume]): Ditto.
908         (-[WebVideoFullscreenHUDWindowController setVolume:]): Call
909         -updateVolume.
910
911 2009-10-30  Evan Stade  <estade@chromium.org>
912
913         Reviewed by David Levin.
914
915         Notify the chrome when the focused node has changed.
916         https://bugs.webkit.org/show_bug.cgi?id=30832
917
918         Added stub implementation for new ChromeClient function.
919
920         * WebCoreSupport/WebChromeClient.h:
921         * WebCoreSupport/WebChromeClient.mm:
922         (WebChromeClient::focusedNodeChanged):
923
924 2009-10-30  Roland Steiner  <rolandsteiner@chromium.org>
925
926         Reviewed by Eric Seidel.
927
928         Remove ENABLE_RUBY guards as discussed with Dave Hyatt and Maciej Stachowiak.
929
930         Bug 28420 -  Implement HTML5 <ruby> rendering
931         (https://bugs.webkit.org/show_bug.cgi?id=28420)
932
933         No new tests (no functional change).
934
935         * Configurations/FeatureDefines.xcconfig:
936
937 2009-10-29  Mark Rowe  <mrowe@apple.com>
938
939         Reviewed by Oliver Hunt.
940
941         Validate the stopSpeaking: selector so that is not always enabled when a WebView is first responder.
942
943         * WebView/WebHTMLView.mm:
944         (-[WebHTMLView validateUserInterfaceItemWithoutDelegate:]):
945
946 2009-10-29  Anders Carlsson  <andersca@apple.com>
947
948         Reviewed by Sam Weinig.
949
950         https://bugs.webkit.org/show_bug.cgi?id=30932
951         <rdar://problem/7350269>
952         
953         REGRESSION: Crash when turning on Private Browsing on site with flash.
954         
955         Null check setValue.
956         
957         * Plugins/WebNetscapePluginView.mm:
958         (-[WebNetscapePluginView privateBrowsingModeDidChange]):
959
960 2009-10-29  Eric Carlson  <eric.carlson@apple.com>
961
962         Reviewed by Kevin Decker.
963
964         Refactor some duplicate plug-in clean up code into shared functions.
965
966         * Plugins/WebPluginController.mm:
967         (-[WebPluginController stopOnePlugin:]): New, stop a plug-in.
968         (-[WebPluginController destroyOnePlugin:]): New, destroy plug-in.
969         (-[WebPluginController stopAllPlugins]): Call stopOnePlugin.
970         (-[WebPluginController destroyPlugin:]): Call stopOnePlugin and destroyOnePlugin.
971         (-[WebPluginController destroyAllPlugins]): Call destroyOnePlugin.
972
973 2009-10-28  Eric Carlson  <eric.carlson@apple.com>
974
975         Reviewed by Simon Fraser.
976
977         <rdar://problem/7303145> 
978         Can't exit full screen mode or restart movie after pressing command -R.
979
980         * WebView/WebVideoFullscreenController.mm:
981         (-[WebVideoFullscreenController _requestExit]): 
982             New, call media element's exitFullscreen method.
983         (-[WebVideoFullscreenController requestExitFullscreenWithAnimation:]): 
984             Call mediaElement->exitFullscreen() after a delay as it turns around and calls
985             WebVideoFullscreenController:exitFullscreen.
986
987         * WebView/WebVideoFullscreenHUDWindowController.h:
988         * WebView/WebVideoFullscreenHUDWindowController.mm:
989         (-[WebVideoFullscreenHUDWindow resignFirstResponder]):
990             New, don't give up responder status.
991         (-[WebVideoFullscreenHUDWindow performKeyEquivalent:]):
992             New, block all command key events.
993         (-[WebVideoFullscreenHUDWindowController exitFullscreen:]):
994             Remember when we are in the process of exiting fullscreen, don't allow recursion.
995
996         * WebView/WebView.mm:
997         (-[WebView _exitFullscreen]):
998             Early return if fullscreen controller is nil.
999
1000         * WebView/WebWindowAnimation.h: 
1001             Correct comment about _window retain status.
1002         * WebView/WebWindowAnimation.m:
1003         (-[WebWindowScaleAnimation dealloc]):
1004             Don't release _window, we never reatained it.
1005
1006 2009-10-27  Shinichiro Hamaji  <hamaji@chromium.org>
1007
1008         Reviewed by Darin Adler.
1009
1010         Provide a way to get counter values with layoutTestContoller
1011         https://bugs.webkit.org/show_bug.cgi?id=30555
1012
1013         Add counterValueForElement in WebFrame to call WebCore::counterValueForElement.
1014
1015         * Misc/WebCoreStatistics.h:
1016         * Misc/WebCoreStatistics.mm:
1017         (-[WebFrame counterValueForElement:]):
1018
1019 2009-10-27  Geoffrey Garen  <ggaren@apple.com>
1020
1021         Reviewed by Sam Weinig.
1022
1023         Updated for refactoring in the date code.
1024
1025         * WebView/WebView.mm:
1026         (aeDescFromJSValue): Since we just want a number of milliseconds, do that
1027         instead of something more complicated.
1028
1029 2009-10-26  Sam Weinig  <sam@webkit.org>
1030
1031         Reviewed by Anders Carlsson.
1032
1033         Move some WebView event handling code into its own file, WebViewEventHandling.mm
1034
1035         * WebView/WebView.mm:
1036         (-[WebView _close]):
1037         (-[WebView _selectedOrMainFrame]):
1038         * WebView/WebViewEventHandling.mm: Added.
1039         (-[WebView _closingEventHandling]):
1040         (-[WebView _setMouseDownEvent:]):
1041         (-[WebView mouseDown:]):
1042         (-[WebView mouseUp:]):
1043         (+[WebView _updateMouseoverWithEvent:]):
1044         (-[WebView _updateMouseoverWithFakeEvent]):
1045         (_updateMouseoverWithEvent:fakeEvent::if):
1046         (-[WebView _stopAutoscrollTimer]):
1047         (-[WebView _setToolTip:]):
1048         * WebView/WebViewInternal.h:
1049
1050 2009-10-26  Simon Fraser  <simon.fraser@apple.com>
1051
1052         Reviewed by Sam Weinig.
1053
1054         <rdar://problem/6988966> Hardware layers do not show up in page snapshots
1055
1056         * WebView/WebHTMLViewPrivate.h:
1057         * WebView/WebHTMLView.mm:
1058         (-[WebHTMLView _compositingLayersHostingView]):
1059         Add a private method that returns the NSView used to host compositing layers.
1060         
1061 2009-10-23  Mark Rowe  <mrowe@apple.com>
1062
1063         Fix engineering builds in the mysterious future.
1064
1065         * Configurations/DebugRelease.xcconfig:
1066
1067 2009-10-23  Gavin Barraclough  <barraclough@apple.com>
1068
1069         Reviewed by Geoff Garen.
1070
1071         https://bugs.webkit.org/show_bug.cgi?id=30729
1072         Provide private API to request the global context for a specific world.
1073         Used to initialize parameters on the global object.
1074
1075         * WebView/WebFramePrivate.h:
1076         * WebView/WebFrame.mm:
1077         (-[WebFrame contextForWorldID:]):
1078
1079 2009-10-22  Eric Carlson  <eric.carlson@apple.com>
1080
1081         Reviewed by John Sullivan.
1082
1083         <rdar://problem/7322847>
1084         Pressing space bar key in full screen mode should pause movie but doesn't
1085
1086         * WebView/WebVideoFullscreenHUDWindowController.mm:
1087         (-[WebVideoFullscreenHUDWindowController keyDown:]):  New, toggle playback on space key.
1088         (-[WebVideoFullscreenHUDWindowController windowDidLoad]): Play button action is now called togglePlaying.
1089         (-[WebVideoFullscreenHUDWindowController togglePlaying:]): Rename from playingChanged.
1090
1091 2009-10-22  Gavin Barraclough  <barraclough@apple.com>
1092
1093         Reviewed by NOBODY (build fix).
1094         Build fix following bug #30696.
1095
1096         * Plugins/Hosted/NetscapePluginInstanceProxy.mm:
1097         (WebKit::NetscapePluginInstanceProxy::getWindowNPObject):
1098         (WebKit::NetscapePluginInstanceProxy::evaluate):
1099         (WebKit::NetscapePluginInstanceProxy::invoke):
1100         (WebKit::NetscapePluginInstanceProxy::invokeDefault):
1101         (WebKit::NetscapePluginInstanceProxy::construct):
1102         (WebKit::NetscapePluginInstanceProxy::getProperty):
1103         (WebKit::NetscapePluginInstanceProxy::setProperty):
1104         (WebKit::NetscapePluginInstanceProxy::removeProperty):
1105         (WebKit::NetscapePluginInstanceProxy::hasProperty):
1106         (WebKit::NetscapePluginInstanceProxy::hasMethod):
1107         (WebKit::NetscapePluginInstanceProxy::enumerate):
1108
1109 2009-10-16  Gavin Barraclough  <barraclough@apple.com>
1110
1111         Reviewed by Sam Weinig & Geoff Garen.
1112
1113         https://bugs.webkit.org/show_bug.cgi?id=30696
1114         Update to incorporate support for IsolatedWorlds in JSC bindings.
1115
1116         * WebView/WebFrame.mm:
1117         (-[WebFrame _attachScriptDebugger]):
1118         (-[WebFrame _stringByEvaluatingJavaScriptFromString:forceUserGesture:]):
1119         (-[WebFrame globalContext]):
1120         * WebView/WebScriptDebugDelegate.mm:
1121         (-[WebScriptCallFrame evaluateWebScript:]):
1122         * WebView/WebView.mm:
1123         (-[WebView aeDescByEvaluatingJavaScriptFromString:]):
1124
1125 2009-10-22  Eric Carlson  <eric.carlson@apple.com>
1126
1127         Reviewed by Dan Bernstein & Simon Fraser.
1128
1129         <rdar://problem/7297717>
1130         https://bugs.webkit.org/show_bug.cgi?id=30323
1131         Play/pause button in full-screen video controller does not reflect current state
1132
1133         * WebView/WebVideoFullscreenController.mm:
1134         (-[WebVideoFullscreenController setMediaElement:WebCore::]): Register for QTMovieRateDidChangeNotification
1135         (-[WebVideoFullscreenController rateChanged:]): Call HUD controller when rate changes.
1136
1137         * WebView/WebVideoFullscreenHUDWindowController.h:
1138         * WebView/WebVideoFullscreenHUDWindowController.mm:
1139         (-[WebVideoFullscreenHUDWindowController scheduleTimeUpdate]): Call updateRate so play button
1140         reflects playback state.
1141         (-[WebVideoFullscreenHUDWindowController updateRate]): New, set play button state according to
1142         movie state.
1143         (-[WebVideoFullscreenHUDWindowController playingChanged:]): Only call [self playing] once.
1144
1145 2009-10-21  John Sullivan  <sullivan@apple.com>
1146
1147         Rubber-stamped by Dan Bernstein.
1148
1149         * WebView/WebDynamicScrollBarsView.h:
1150         Corrected a couple of long-obsolete comments regarding Safari's use of this class.
1151
1152 2009-10-20  Dan Bernstein  <mitz@apple.com>
1153
1154         Rubber-stamped by Mark Rowe.
1155
1156         <rdar://problem/7319749> REGRESSION(r49806): Contextual Menu items missing
1157         https://bugs.webkit.org/show_bug.cgi?id=30568
1158
1159         Revert accidental change from r49806.
1160
1161         * WebCoreSupport/WebContextMenuClient.mm:
1162         (WebContextMenuClient::getCustomMenuFromDefaultItems):
1163
1164 2009-10-20  Fumitoshi Ukai  <ukai@chromium.org>
1165
1166         Reviewed by David Levin.
1167
1168         Removed WebSocket runtime settings.
1169         https://bugs.webkit.org/show_bug.cgi?id=29896
1170
1171         WebSocket runtime configuration is supported by chromium/v8 only.
1172
1173         * WebView/WebPreferenceKeysPrivate.h:
1174         * WebView/WebPreferences.mm:
1175         (+[WebPreferences initialize]):
1176         * WebView/WebPreferencesPrivate.h:
1177         * WebView/WebView.mm:
1178         (-[WebView _preferencesChangedNotification:]):
1179
1180 2009-10-19  Nate Chapin  <japhet@chromium.org>
1181
1182         Reviewed by Alexey Proskuryakov.
1183
1184         Update call to loadFrameRequest to match new parameters.
1185
1186         * WebView/WebPDFView.mm:
1187         (-[WebPDFView PDFViewWillClickOnLink:withURL:]): Update call to loadFrameRequest.
1188
1189 2009-10-19  David Kilzer  <ddkilzer@apple.com>
1190
1191         Documentation fix for -[NSObject(WebResourceLoadDelegate) webView:resource:willSendRequest:redirectResponse:fromDataSource:]
1192
1193         Reviewed by Dan Bernstein.
1194
1195         * WebView/WebResourceLoadDelegate.h: Prepended "webView:" to the
1196         @method declaration of
1197         -webView:resource:willSendRequest:redirectResponse:fromDataSource:
1198         which was absent before r3953 and was missed during the great
1199         documentation clean up of r4269.
1200
1201 2009-10-19  Anders Carlsson  <andersca@apple.com>
1202
1203         Fix build.
1204
1205         * Plugins/WebNetscapePluginView.mm:
1206         (-[WebNetscapePluginView saveAndSetNewPortStateForUpdate:]):
1207
1208 2009-10-19  Dan Bernstein  <mitz@apple.com>
1209
1210         Reviewed by Anders Carlsson.
1211
1212         Split assertions of conjunctions into separate statements or remove
1213         redundant assertions.
1214
1215         * Plugins/Hosted/NetscapePluginHostProxy.mm:
1216         (WebKit::NetscapePluginHostProxy::deadNameNotificationCallback):
1217         * Plugins/Hosted/WebHostedNetscapePluginView.mm:
1218         (-[WebHostedNetscapePluginView setAttributeKeys:andValues:]):
1219         (-[WebHostedNetscapePluginView _webPluginContainerCancelCheckIfAllowedToLoadRequest:]):
1220         * Plugins/WebBaseNetscapePluginView.mm:
1221         (-[WebBaseNetscapePluginView halt]):
1222         (-[WebBaseNetscapePluginView resumeFromHalt]):
1223         * Plugins/WebNetscapePluginView.mm:
1224         (-[WebNetscapePluginView saveAndSetNewPortStateForUpdate:]):
1225         (-[WebNetscapePluginView _webPluginContainerCancelCheckIfAllowedToLoadRequest:]):
1226         * WebCoreSupport/WebContextMenuClient.mm:
1227         (WebContextMenuClient::getCustomMenuFromDefaultItems):
1228         * WebCoreSupport/WebEditorClient.mm:
1229         (WebEditorClient::checkGrammarOfString):
1230         (WebEditorClient::checkTextOfParagraph):
1231         * WebView/WebTextCompletionController.mm:
1232         (-[WebTextCompletionController _reflectSelection]):
1233
1234 2009-10-18  Mark Rowe  <mrowe@apple.com>
1235
1236         Reviewed by Dan Bernstein.
1237
1238         <rdar://problem/7309062> Crashes in WebCore::DocumentLoader::isStopping below WebKit::NetscapePluginInstanceProxy::loadRequest.
1239
1240         * Plugins/Hosted/NetscapePluginInstanceProxy.mm:
1241         (WebKit::NetscapePluginInstanceProxy::loadRequest): Null-check the DocumentLoader before deferencing it.
1242
1243 2009-10-16  Kevin Decker  <kdecker@apple.com>
1244
1245         Reviewed by Jon Honeycutt.
1246
1247         <rdar://problem/7304575>
1248         
1249         * Plugins/WebBaseNetscapePluginView.h: Added new boolean ivar and -hasBeenHalted instance method.
1250         * Plugins/WebBaseNetscapePluginView.mm:
1251         (-[WebBaseNetscapePluginView halt]):Update _hasBeenHalted.
1252         (-[WebBaseNetscapePluginView hasBeenHalted]): Added.
1253         * WebView/WebView.mm:
1254         (+[WebView _hasPluginForNodeBeenHalted:]): Checks to see if a plug-in node's been halted.
1255         * WebView/WebViewPrivate.h: Added -_hasPluginForNodeBeenHalted method.
1256
1257 2009-10-16  Kevin Decker  <kdecker@apple.com>
1258
1259         Reviewed by Anders Carlson.
1260
1261         Small code cleanup
1262         
1263         * Plugins/WebBaseNetscapePluginView.mm:
1264         (WebHaltablePlugin::halt): Just call -[WebBaseNetscapePluginView halt].
1265         (WebHaltablePlugin::restart): Just call -[WebBaseNetscapePluginView resumeFromHalt]
1266         (-[WebBaseNetscapePluginView halt]): 
1267         (-[WebBaseNetscapePluginView resumeFromHalt]):
1268         * WebView/WebView.mm:
1269         (_pluginViewForNode): Added a check if a render is a widget. This prevents a later assertion.
1270
1271 2009-10-16  Kevin Decker  <kdecker@apple.com>
1272
1273         Reviewed by Anders Carlson.
1274
1275         Last part of:
1276         <rdar://problem/7273354>
1277
1278         * WebView/WebView.mm: 
1279         (_pluginViewForNode): Added with code extracted from _isNodeHaltedPlugin
1280         (+[WebView _isNodeHaltedPlugin:]): Made this a class method.
1281         (+[WebView _restartHaltedPluginForNode:]): Added. Restarts a plug-in
1282         * WebView/WebViewPrivate.h: Added +_restartHaltedPluginForNode to header.
1283
1284 2009-10-16  Kevin Decker  <kdecker@apple.com>
1285
1286         Reviewed by Anders.
1287
1288         <rdar://problem/7273354> 
1289
1290         * Plugins/WebBaseNetscapePluginView.h: Added _isHalted ivar and three new methods: -halt, -resumeFromHalt, and -isHalted
1291         * Plugins/WebBaseNetscapePluginView.mm:
1292         (WebHaltablePlugin::halt): Call -halt instead of -stop.  
1293         (WebHaltablePlugin::restart):Call -resumeFromHalt instead of -start. 
1294         (-[WebBaseNetscapePluginView halt]): Added. Stop the plug-in, update _isHalted.
1295         (-[WebBaseNetscapePluginView resumeFromHalt]): Added. Start the plug-in, update _isHalted.
1296         (-[WebBaseNetscapePluginView isHalted]): Added.
1297         * WebView/WebView.mm:
1298         (-[WebView _isNodeHaltedPlugin:]): Added. Queries a DOMNode to determine if it's a halted plug-in.
1299         * WebView/WebViewPrivate.h: Added _isNodeHaltedPlugin.
1300
1301 2009-10-15  Eric Carlson  <eric.carlson@apple.com>
1302
1303         Reviewed by Adele Peterson.
1304
1305         <rdar://problem/7306052> Fullscreen max/min volume buttons non-functional
1306
1307         * WebView/WebVideoFullscreenHUDWindowController.mm:
1308         (-[WebVideoFullscreenHUDWindowController windowDidLoad]): Set volume buttons target and action.
1309         (-[WebVideoFullscreenHUDWindowController decrementVolume:]): New, decrement the volume by 10%.
1310         (-[WebVideoFullscreenHUDWindowController incrementVolume:]): New, increment the volume by 10%.
1311
1312 2009-10-15  Eric Carlson  <eric.carlson@apple.com>
1313
1314         Reviewed by Simon Fraser.
1315
1316         <rdar://problem/7295738> No way to mute/unmute a movie in full screen video mode
1317
1318         * WebView/WebVideoFullscreenHUDWindowController.mm:
1319         (-[WebVideoFullscreenHUDWindowController setVolume:]): Unmute movie before changing volume.
1320
1321 2009-10-14  Kevin Decker  <kdecker@apple.com>
1322
1323         Unbreak the world.
1324         
1325         * Plugins/WebBaseNetscapePluginView.mm:
1326         (WebHaltablePlugin::restart):
1327
1328 2009-10-14  Kevin Decker  <kdecker@apple.com>
1329
1330         Reviewed by Anders Carlsson and Jon Honeycutt
1331
1332         <rdar://problem/7304295> snapshots of halted plug-ins are missing
1333         
1334         * Plugins/WebBaseNetscapePluginView.mm: Move bodies of WebHaltablePlugin virtual functions from WebHaltablePlugin class definition.
1335         (WebHaltablePlugin::halt): Provide a substitute image to the RenderWidget for the plug-in view.
1336         (WebHaltablePlugin::restart): Clear the substitute image.
1337
1338 2009-10-13  Dave Hyatt  <hyatt@apple.com>
1339
1340         Reviewed by Adam Roben.
1341
1342         Change the order of arguments on some methods.  Split removal for user stylesheets and script into
1343         separate functions based off the type of object being removed.
1344
1345         * WebView/WebView.mm:
1346         (+[WebView _addUserScriptToGroup:worldID:source:url:whitelist:blacklist:injectionTime:]):
1347         (+[WebView _addUserStyleSheetToGroup:worldID:source:url:whitelist:blacklist:]):
1348         (+[WebView _removeUserScriptFromGroup:worldID:url:]):
1349         (+[WebView _removeUserStyleSheetFromGroup:worldID:url:]):
1350         (+[WebView _removeUserScriptsFromGroup:worldID:]):
1351         (+[WebView _removeUserStyleSheetsFromGroup:worldID:]):
1352         * WebView/WebViewPrivate.h:
1353
1354 2009-10-13  Anders Carlsson  <andersca@apple.com>
1355
1356         Reviewed by Sam Weinig.
1357
1358         <rdar://problem/6660507> Add "privacy mode" to Netscape Plug-in API
1359
1360         Listen for WebPreferences notifications and update the _isPrivateBrowsingEnabled ivar 
1361         when the value changes. Also call -[WebBaseNetscapePluginView privateBrowsingModeDidChange] when the
1362         value changes. In process this just calls NPP_SetValue, and OOP it sends a MIG message to the plug-in host.
1363         
1364         * Plugins/Hosted/NetscapePluginHostManager.h:
1365         * Plugins/Hosted/NetscapePluginHostManager.mm:
1366         (WebKit::NetscapePluginHostManager::instantiatePlugin):
1367         * Plugins/Hosted/NetscapePluginInstanceProxy.h:
1368         * Plugins/Hosted/NetscapePluginInstanceProxy.mm:
1369         (WebKit::NetscapePluginInstanceProxy::privateBrowsingModeDidChange):
1370         * Plugins/Hosted/WebHostedNetscapePluginView.mm:
1371         (-[WebHostedNetscapePluginView createPlugin]):
1372         (-[WebHostedNetscapePluginView privateBrowsingModeDidChange]):
1373         * Plugins/Hosted/WebKitPluginHost.defs:
1374         * Plugins/WebBaseNetscapePluginView.h:
1375         * Plugins/WebBaseNetscapePluginView.mm:
1376         (-[WebBaseNetscapePluginView privateBrowsingModeDidChange]):
1377         (-[WebBaseNetscapePluginView viewDidMoveToWindow]):
1378         (-[WebBaseNetscapePluginView preferencesHaveChanged:]):
1379         * Plugins/WebNetscapePluginView.mm:
1380         (-[WebNetscapePluginView privateBrowsingModeDidChange]):
1381         (-[WebNetscapePluginView getVariable:value:]):
1382
1383 2009-10-12  Simon Fraser  <simon.fraser@apple.com>
1384
1385         Reviewed by Darin Adler.
1386
1387         Video keeps playing after going fullscreen, then closing window
1388         https://bugs.webkit.org/show_bug.cgi?id=30164
1389         
1390         Clear the QTMovie on the QTMovieView when coming out of fullscreen,
1391         to fix issue where the underlying movie keeps playing.
1392
1393         * WebView/WebVideoFullscreenController.mm:
1394         (-[WebVideoFullscreenController windowDidExitFullscreen]):
1395
1396 2009-10-11  Dan Bernstein  <mitz@apple.com>
1397
1398         Reviewed by Darin Adler.
1399
1400         <rdar://problem/7294267> REGRESSION (r48492): Gmail voice and video chat
1401         doesn’t work
1402         https://bugs.webkit.org/show_bug.cgi?id=30295
1403
1404         Test: plugins/setProperty.html
1405
1406         * Plugins/Hosted/ProxyInstance.mm:
1407         (WebKit::ProxyInstance::setFieldValue): Fixed a typo. The function
1408         should return early if m_instanceProxy is null.
1409
1410 2009-10-09  Adam Barth  <abarth@webkit.org>
1411
1412         Reviewed by Darin Adler.
1413
1414         Factor HistoryController out of FrameLoader
1415         https://bugs.webkit.org/show_bug.cgi?id=30246
1416
1417         Update API call.
1418
1419         * WebCoreSupport/WebFrameLoaderClient.mm:
1420         (WebFrameLoaderClient::restoreViewState):
1421         * WebView/WebView.mm:
1422         (-[WebView _loadBackForwardListFromOtherView:]):
1423
1424 2009-10-09  Mark Rowe  <mrowe@apple.com>
1425
1426         Reviewed by Brady Eidson.
1427
1428         <rdar://problem/7290671> Crash after navigating away from a page with subframe containing plug-in
1429
1430         At the time that -stop is called on a WebBaseNetscapePluginView that is contained within a subframe
1431         the WebFrame's data source has been zeroed out.  This was causing -[WebBaseNetscapePluginView webFrame]
1432         to return nil during -stop, preventing the plug-in view from unregistering itself from the PluginHalter.
1433         We fix this by having -webFrame retrieve the frame directly rather than retrieving it from the data source.
1434
1435         * Plugins/WebBaseNetscapePluginView.mm:
1436         (-[WebBaseNetscapePluginView dataSource]): Get the data source from the WebFrame.
1437         (-[WebBaseNetscapePluginView webFrame]): Get the Frame directly from the element's document rather
1438         than taking a windy route through the WebDataSource.
1439
1440 2009-10-09  Brady Eidson  <beidson@apple.com>
1441
1442         Reviewed by Dan Bernstein.
1443
1444         Add SPI to specifically enable visited link tracking.
1445
1446         * History/WebHistory.mm:
1447         (+[WebHistory _setVisitedLinkTrackingEnabled:]):
1448         * History/WebHistoryPrivate.h:
1449
1450 2009-10-08  Jon Honeycutt  <jhoneycutt@apple.com>
1451
1452         Remove the WebKitPluginHalterEnabledPreferenceKey in favor of checking
1453         for the existence of a PluginHalterDelegate.
1454
1455         Reviewed by Dan Bernstein.
1456
1457         * WebCoreSupport/WebPluginHalterClient.h:
1458         Add declaration for new function.
1459
1460         * WebCoreSupport/WebPluginHalterClient.mm:
1461         (WebPluginHalterClient::enabled):
1462         Check whether the UIDelegate responds to shouldHaltPlugin.
1463
1464         * WebView/WebPreferenceKeysPrivate.h:
1465         Remove the "enabled" preference key.
1466
1467         * WebView/WebPreferences.mm:
1468         (+[WebPreferences initialize]):
1469         Remove the initialization of the pref.
1470
1471         * WebView/WebPreferencesPrivate.h:
1472         Remove the getter/setter for this pref.
1473
1474         * WebView/WebView.mm:
1475         (-[WebView _preferencesChangedNotification:]):
1476         Remove propagation of the pref. 
1477
1478 2009-10-08  Adam Barth  <abarth@webkit.org>
1479
1480         Reviewed by Eric Seidel.
1481
1482         Move executeScript from FrameLoader to ScriptController
1483         https://bugs.webkit.org/show_bug.cgi?id=30200
1484
1485         Update API call.
1486
1487         * WebView/WebFrame.mm:
1488         (-[WebFrame _stringByEvaluatingJavaScriptFromString:forceUserGesture:]):
1489         * WebView/WebView.mm:
1490         (-[WebView aeDescByEvaluatingJavaScriptFromString:]):
1491
1492 2009-10-08  Brady Eidson  <beidson@apple.com>
1493
1494         Reviewed by Dan Bernstein.
1495
1496         Ask the History Delegate to populate the visited links hash.
1497         <rdar://problem/7285293> and https://webkit.org/b/29904
1498
1499         * History/WebHistory.mm:
1500         (+[WebHistory _removeAllVisitedLinks]):
1501         * History/WebHistoryPrivate.h:
1502         * WebCoreSupport/WebChromeClient.mm:
1503         (WebChromeClient::populateVisitedLinks):
1504         * WebView/WebDelegateImplementationCaching.h:
1505         * WebView/WebDelegateImplementationCaching.mm:
1506         (CallHistoryDelegate):
1507         * WebView/WebHistoryDelegate.h:
1508         * WebView/WebView.mm:
1509         (-[WebView _cacheHistoryDelegateImplementations]):
1510         (-[WebView addVisitedLinks:]):
1511         * WebView/WebViewPrivate.h:
1512
1513 2009-10-08  Anders Carlsson  <andersca@apple.com>
1514
1515         Reviewed by Sam Weinig.
1516
1517         Remove the shouldLoadMediaElementURL implementation.
1518
1519         * WebCoreSupport/WebFrameLoaderClient.h:
1520         * WebCoreSupport/WebFrameLoaderClient.mm:
1521         * WebView/WebPolicyDelegatePrivate.h:
1522
1523 2009-10-07  Simon Fraser  <simon.fraser@apple.com>
1524
1525         Re-land 49269-49271 since reverting them did not fix the tests.
1526
1527         * WebView/WebHTMLView.mm:
1528         (-[WebHTMLView drawRect:]):
1529
1530 2009-10-07  Simon Fraser  <simon.fraser@apple.com>
1531
1532         Revert 49269-49271 to see if it fixes test failures on SnowLeopard that do not
1533         reproduce locally.
1534
1535         * WebView/WebHTMLView.mm:
1536         (-[WebHTMLView drawRect:]):
1537
1538 2009-10-07  Adam Barth  <abarth@webkit.org>
1539
1540         Reviewed by Darin Adler.
1541
1542         Factor PolicyChecker out of FrameLoader
1543         https://bugs.webkit.org/show_bug.cgi?id=30155
1544
1545         Move the policy callback to the policy object.
1546
1547         * WebCoreSupport/WebFrameLoaderClient.mm:
1548         (WebFrameLoaderClient::dispatchWillSubmitForm):
1549         (WebFrameLoaderClient::receivedPolicyDecison):
1550
1551 2009-10-07  Brady Eidson  <beidson@apple.com>
1552
1553         Reviewed by Darin Adler.
1554
1555         Send title changes to the global history delegate.
1556         <rdar://problem/7285293> and https://webkit.org/b/29904
1557
1558         * WebCoreSupport/WebFrameLoaderClient.mm:
1559         (WebFrameLoaderClient::setTitle):
1560         * WebView/WebDelegateImplementationCaching.h:
1561         * WebView/WebHistoryDelegate.h:
1562         * WebView/WebView.mm:
1563         (-[WebView _cacheHistoryDelegateImplementations]):
1564
1565 2009-10-07  Darin Adler  <darin@apple.com>
1566
1567         Reviewed by John Sullivan.
1568
1569         Make the setMetadataURL function foolproof by having it remove user info
1570         https://bugs.webkit.org/show_bug.cgi?id=30178
1571         rdar://problem/6544670
1572
1573         * Misc/WebNSFileManagerExtras.m:
1574         (-[NSFileManager _webkit_setMetadataURL:referrer:atPath:]):
1575         Call _web_URLByRemovingUserInfo on the passed in URL string after converting
1576         it to a URL, and then convert it back to a string.
1577
1578         * Misc/WebNSURLExtras.h: Added _web_URLByRemovingUserInfo.
1579         * Misc/WebNSURLExtras.mm: Removed unused WebKitURLComponents struct.
1580         (-[NSURL _web_URLByTruncatingOneCharacterBeforeComponent:]): Renamed to be
1581         clearer on what this does.
1582         (-[NSURL _webkit_URLByRemovingFragment]): Changed to call new name.
1583         (-[NSURL _webkit_URLByRemovingResourceSpecifier]): Ditto.
1584         (-[NSURL _web_URLByRemovingComponentAndSubsequentCharacter:]): Added.
1585         (-[NSURL _web_URLByRemovingUserInfo]): Added.
1586
1587 2009-10-07  Simon Fraser  <simon.fraser@apple.com>
1588
1589         Make Dan Bernstein happy.
1590
1591         * WebView/WebHTMLView.mm:
1592         (-[WebHTMLView drawRect:]):
1593
1594 2009-10-07  Simon Fraser  <simon.fraser@apple.com>
1595
1596         Reviewed by Dan Bernstein.
1597
1598         Avoid Obj-C message dispatch when possible by storing accessed objects
1599         in local variables.
1600
1601         * WebView/WebHTMLView.mm:
1602         (-[WebHTMLView drawRect:]):
1603
1604 2009-10-07  Simon Fraser  <simon.fraser@apple.com>
1605
1606         Reviewed by Dan Bernstein.
1607
1608         Animation stalls for a few seconds partway through
1609         https://bugs.webkit.org/show_bug.cgi?id=30182
1610         
1611         Make sure that we only call -disableScreenUpdatesUntilFlush when a window
1612         update is actually going to happen, otherwise screen updates are disabled
1613         for too long.
1614
1615         * WebView/WebHTMLView.mm:
1616         (-[WebHTMLView drawRect:]):
1617
1618 2009-10-06  Pavel Feldman  <pfeldman@chromium.org>
1619
1620         Reviewed by Timothy Hatcher.
1621
1622         Web Inspector: default to an attached inspector window on Windows (as on Mac).
1623
1624         https://bugs.webkit.org/show_bug.cgi?id=30134
1625
1626         * WebCoreSupport/WebInspectorClient.mm:
1627         (-[WebInspectorWindowController showWindow:]):
1628
1629 2009-10-06  Adam Barth  <abarth@webkit.org>
1630
1631         Reviewed by Eric Seidel.
1632
1633         Move FrameLoader::canLoad to SecurityOrigin
1634         https://bugs.webkit.org/show_bug.cgi?id=30111
1635
1636         * Plugins/Hosted/HostedNetscapePluginStream.mm:
1637         (WebKit::HostedNetscapePluginStream::HostedNetscapePluginStream):
1638         * Plugins/Hosted/NetscapePluginInstanceProxy.mm:
1639         (WebKit::NetscapePluginInstanceProxy::loadRequest):
1640         * Plugins/WebBaseNetscapePluginStream.mm:
1641         (WebNetscapePluginStream::WebNetscapePluginStream):
1642         * Plugins/WebNetscapePluginView.mm:
1643         (-[WebNetscapePluginView loadRequest:inTarget:withNotifyData:sendNotification:]):
1644         * Plugins/WebPluginContainerCheck.mm:
1645         (-[WebPluginContainerCheck _isForbiddenFileLoad]):
1646         * WebView/WebFrame.mm:
1647         (-[WebFrame _allowsFollowingLink:]):
1648
1649 2009-10-06  Adam Barth  <abarth@webkit.org>
1650
1651         Reviewed by Eric Seidel.
1652
1653         Move setLocalLoadPolicy and friends to SecurityOrigin
1654         https://bugs.webkit.org/show_bug.cgi?id=30110
1655
1656         Call the new API.
1657
1658         * WebView/WebView.mm:
1659         (-[WebView _commonInitializationWithFrameName:groupName:usesDocumentViews:]):
1660
1661 2009-10-06  Simon Fraser  <simon.fraser@apple.com>
1662
1663         Reviewed by Mark Rowe.
1664
1665         accessibility/media-element.html crashes (and has incorrect result)
1666         https://bugs.webkit.org/show_bug.cgi?id=30108
1667
1668         Fix up the accessibilty label for the newly added fullscreen button,
1669         and update the test result accordingly.
1670
1671         * WebCoreSupport/WebViewFactory.mm:
1672         (-[WebViewFactory localizedMediaControlElementString:]):
1673         Handle "ControlsPanel" which is just an empty container, to avoid
1674         asserting in debug builds.
1675
1676 2009-10-06  Daniel Bates  <dbates@webkit.org>
1677
1678         Reviewed by Eric Seidel.
1679
1680         https://bugs.webkit.org/show_bug.cgi?id=30107
1681         
1682         Fixes an issue where the Mac build does return the correct drop effect
1683         with respect to the HTML 5 specification when effectAllowed == "none".
1684         
1685         Currently, when effectAllowed == "none" and dropEffect == "copy" or 
1686         dropEffect == "move" the resulting drop effect is "copy" and "move",
1687         respectively. However, the HTML 5 specification states that regardless
1688         of the specified dropEffect, when effectAllowed == "none" the resulting
1689         drop effect should be "none".
1690
1691         * WebView/WebHTMLView.mm:
1692         (-[WebHTMLView draggingSourceOperationMaskForLocal:]):
1693
1694 2009-10-06  Pavel Feldman  <pfeldman@chromium.org>
1695
1696         Reviewed by Timothy Hatcher.
1697
1698         Web Inspector: close inspector client view on
1699         InspectorController::close API call.
1700
1701         In order to run batch web inspector layout tests (and not affect 
1702         subsequent tests) we should close inspector client's view upon
1703         InspectorController::close API call.
1704
1705         https://bugs.webkit.org/show_bug.cgi?id=30009
1706
1707         * WebCoreSupport/WebInspectorClient.mm:
1708         (WebInspectorClient::createPage):
1709
1710 2009-10-05  Dan Bernstein  <mitz@apple.com>
1711
1712         Rubber-stamped by Mark Rowe.
1713
1714         Moved a WebPluginHalterClient out of the WebCore namesapce.
1715
1716         * WebCoreSupport/WebPluginHalterClient.h:
1717
1718 2009-10-05  Kevin Decker  <kdecker@apple.com>
1719
1720         Reviewed by Dan Bernstein.
1721
1722         Added new PluginHalter client, delegate and few more WebPreferences keys.
1723
1724         * WebView/WebPreferenceKeysPrivate.h: Added two new keys.
1725         * WebView/WebPreferences.mm:
1726         (+[WebPreferences initialize]): Initialize newly added key.
1727         (-[WebPreferences pluginAllowedRunTime]): Added.
1728         (-[WebPreferences setPluginAllowedRunTime:]): Added.
1729         * WebView/WebPreferencesPrivate.h: Added above two methods.
1730         * WebView/WebUIDelegatePrivate.h: Added shouldHaltPlugin delegate.
1731         * WebView/WebView.mm:
1732         (-[WebView _commonInitializationWithFrameName:groupName:usesDocumentViews:]):
1733         Setup a new WebPluginHalterClient.
1734         (-[WebView _preferencesChangedNotification:]): Update WebCore settings accordingly.
1735         * WebCoreSupport/WebPluginHalterClient.h: Added.
1736         * WebCoreSupport/WebPluginHalterClient.mm: Added.
1737         (WebPluginHalterClient::WebPluginHalterClient):
1738         (WebPluginHalterClient::shouldHaltPlugin): Added, invoke the delegate.
1739
1740 2009-10-05  Simon Fraser  <simon.fraser@apple.com>
1741
1742         More build fixes for Tiger.
1743
1744         * WebView/WebVideoFullscreenController.mm:
1745
1746 2009-10-05  Simon Fraser  <simon.fraser@apple.com>
1747
1748         More build fixes for Tiger.
1749
1750         * WebView/WebVideoFullscreenController.mm:
1751         (-[WebVideoFullscreenWindow animationDidEnd:]):
1752         * WebView/WebWindowAnimation.m:
1753
1754 2009-10-05  Simon Fraser  <simon.fraser@apple.com>
1755
1756         More build fixes for Tiger.
1757
1758         * WebView/WebVideoFullscreenController.mm:
1759         * WebView/WebVideoFullscreenHUDWindowController.mm:
1760         (-[WebVideoFullscreenHUDWindow initWithContentRect:styleMask:backing:defer:]):
1761         (-[WebVideoFullscreenHUDWindowController scheduleTimeUpdate]):
1762         (-[WebVideoFullscreenHUDWindowController fadeWindowIn]):
1763         (-[WebVideoFullscreenHUDWindowController fadeWindowOut]):
1764         (-[WebVideoFullscreenHUDWindowController closeWindow]):
1765
1766 2009-10-05  Simon Fraser  <simon.fraser@apple.com>
1767
1768         Build fixes for Tiger.
1769
1770         * WebView/WebVideoFullscreenHUDWindowController.h:
1771         * WebView/WebVideoFullscreenHUDWindowController.mm:
1772         (-[WebVideoFullscreenHUDWindow initWithContentRect:styleMask:backing:defer:]):
1773         (-[WebVideoFullscreenHUDWindowController dealloc]):
1774         (-[WebVideoFullscreenHUDWindowController closeWindow]):
1775         (-[WebVideoFullscreenHUDWindowController windowDidLoad]):
1776
1777 2009-10-05  Simon Fraser  <simon.fraser@apple.com>
1778
1779         Build fix. If you call Node::hasTagName(), you also have to include Element.h.
1780
1781         * WebCoreSupport/WebChromeClient.mm:
1782
1783 2009-10-05  Pierre d'Herbemont  <pdherbemont@webkit.org>
1784
1785         Reviewed by Simon Fraser
1786         
1787         Support fullscreen in MediaPlayer (Mac)
1788         https://bugs.webkit.org/show_bug.cgi?id=26742
1789
1790         Add a fullscreen button to the <video> controller if the media engine,
1791         and the theme have support for fullscreen, and can show appropriate controls.
1792         Clicking the button calls through the ChromeClient to the WebVideoFullscreenController
1793         in WebKit to do a nice animation to fullscreen, with a custom controller.
1794
1795         * WebCoreSupport/WebChromeClient.h:
1796         * WebCoreSupport/WebChromeClient.mm:
1797         (WebChromeClient::supportsFullscreenForNode):
1798         (WebChromeClient::enterFullscreenForNode):
1799         (WebChromeClient::exitFullscreenForNode):
1800         New methods to ask whether fullscreen is possible for a given node, and
1801         notifications on enterying and exiting fullscreen.
1802         
1803         * WebView/WebVideoFullscreenController.h: Added.
1804         * WebView/WebVideoFullscreenController.mm: Added.
1805         WebVideoFullscreenController is responsible for creating the fullscreen window,
1806         and coordinating the various animations when going fullscreen.
1807
1808         * WebView/WebVideoFullscreenHUDWindowController.h: Added.
1809         * WebView/WebVideoFullscreenHUDWindowController.mm: Added.
1810         This class manages the heads-up display (HUD) control bar.
1811
1812         * WebView/WebView.mm:
1813         (-[WebView _close]):
1814         Make sure we come out of fullscreen if the WebView is torn down (e.g. if
1815         you close a background window).
1816
1817         (-[WebView _enterFullscreenForNode:WebCore::]):
1818         Make a WebVideoFullscreenController and tell is to start to go fullscreen.
1819         
1820         (-[WebView _exitFullscreen]):
1821         Tell the WebVideoFullscreenController to come out of fullscreen, and clean up.
1822         
1823         * WebView/WebViewData.h:
1824         * WebView/WebViewData.mm:
1825         (-[WebViewPrivate dealloc]):
1826         (-[WebViewPrivate finalize]):
1827         * WebView/WebViewInternal.h:
1828         Keep a pointer to the WebVideoFullscreenController.
1829         
1830         * WebView/WebWindowAnimation.h: Added.
1831         * WebView/WebWindowAnimation.m: Added.
1832         (WebWindowAnimationDurationFromDuration):
1833         (scaledRect):
1834         (squaredDistance):
1835         Handle the animations used during the transitition to fullscreen.
1836
1837 2009-10-05  Anders Carlsson  <andersca@apple.com>
1838
1839         Reviewed by Kevin Decker.
1840        
1841         WebKit side of <rdar://problem/7179166>
1842        
1843         * Plugins/Hosted/NetscapePluginInstanceProxy.h:
1844         Add an m_pluginIsWaitingForDraw member variable.
1845         
1846         * Plugins/Hosted/NetscapePluginInstanceProxy.mm:
1847         (WebKit::NetscapePluginInstanceProxy::NetscapePluginInstanceProxy):
1848         Initialize m_pluginIsWaitingForDraw.
1849         
1850         (WebKit::NetscapePluginInstanceProxy::invalidateRect):
1851         Set m_pluginIsWaitingForDraw to true.
1852         
1853         (WebKit::NetscapePluginInstanceProxy::didDraw):
1854         If m_pluginIsWaitingForDraw is true, call _WKPHPluginInstanceDidDraw.
1855         
1856         * Plugins/Hosted/WebHostedNetscapePluginView.mm:
1857         (-[WebHostedNetscapePluginView drawRect:]):
1858         Call didDraw.
1859         
1860         * Plugins/Hosted/WebKitPluginHost.defs:
1861         Add PHPluginInstanceDidDraw.
1862
1863 2009-10-02  Chris Marrin  <cmarrin@apple.com>
1864
1865         Reviewed by Adele Peterson.
1866
1867         Add functionality to pause/throttle CSS transitions/animations in a WebView
1868         https://bugs.webkit.org/show_bug.cgi?id=29942
1869
1870         Added both a setter and getter function
1871
1872         * WebView/WebView.mm:
1873         (-[WebView cssAnimationsSuspended]):
1874         (-[WebView setCSSAnimationsSuspended:]):
1875         * WebView/WebViewData.h:
1876         * WebView/WebViewData.mm:
1877         (-[WebViewPrivate init]):
1878         * WebView/WebViewPrivate.h:
1879
1880 2009-10-04  Kevin Decker  <kdecker@apple.com>
1881
1882         Reviewed by Sam Weinig.
1883
1884         <rdar://problem/7273363> Plug-ins should use PluginHalter
1885         
1886         * Plugins/WebBaseNetscapePluginView.h: Add WebHaltablePlugin forward declare and _haltable ivar.
1887         * Plugins/WebBaseNetscapePluginView.mm:
1888         (WebHaltablePlugin::WebHaltablePlugin): Added.
1889         (WebHaltablePlugin::halt): New method that stops a plug-in.
1890         (WebHaltablePlugin::restart): New method that starts a plug-in.
1891         (WebHaltablePlugin::node): Added. Provides the DOMNode corresponding to the plug-in in WebBaseNetscapePluginView.
1892         (-[WebBaseNetscapePluginView initWithFrame:pluginPackage:URL:baseURL:MIMEType:attributeKeys:attributeValues:loadManually:element:WebCore::]):
1893         Initialize new _haltable ivar.
1894         (-[WebBaseNetscapePluginView start]): Call the page's didStartPlugin() upon starting a plug-in.
1895         (-[WebBaseNetscapePluginView stop]): Call the page's didStopPlugin() upon stopping a plug-in.
1896
1897 2009-10-05  Pavel Feldman  <pfeldman@chromium.org>
1898
1899         Reviewed by Timothy Hatcher.
1900
1901         Web Inspector: add testing harness for Web Inspector.
1902
1903         https://bugs.webkit.org/show_bug.cgi?id=30010
1904
1905         * WebInspector/WebInspector.mm:
1906         (-[WebInspector evaluateInFrontend:callId:script:]):
1907         * WebInspector/WebInspectorPrivate.h: Added.
1908
1909 2009-10-04  Kevin Decker  <kdecker@apple.com>
1910
1911         Reviewed by Cameron Zwarich.
1912
1913         * WebView/WebPreferenceKeysPrivate.h: Added new key.
1914         * WebView/WebPreferences.mm:
1915         (+[WebPreferences initialize]): Leave plug-in halting disabled by default.
1916         (-[WebPreferences pluginHalterEnabled]): Added.
1917         (-[WebPreferences setPluginHalterEnabled:]): Ditto.
1918         * WebView/WebPreferencesPrivate.h: Added above new methods. 
1919
1920 2009-10-02  Dave Hyatt  <hyatt@apple.com>
1921
1922         Reviewed by Adam Roben.
1923
1924         Add support for blacklist patterns to user stylesheets and scripts in addition to whitelist patterns.
1925
1926         * WebView/WebView.mm:
1927         (toStringVector):
1928         (+[WebView _addUserScriptToGroup:source:url:worldID:whitelist:blacklist:injectionTime:]):
1929         (+[WebView _addUserStyleSheetToGroup:source:url:worldID:whitelist:blacklist:]):
1930         * WebView/WebViewPrivate.h:
1931
1932 2009-10-01  Mark Rowe  <mrowe@apple.com>
1933
1934         Fix the Tiger build.  Don't unconditionally enable 3D canvas as it is not supported on Tiger.
1935
1936         * Configurations/FeatureDefines.xcconfig:
1937
1938 2009-10-01  Chris Marrin  <cmarrin@apple.com>
1939
1940         Reviewed by Oliver Hunt.
1941
1942         Turn on ENABLE_3D_CANVAS in TOT
1943         https://bugs.webkit.org/show_bug.cgi?id=29906
1944
1945         * Configurations/FeatureDefines.xcconfig:
1946         * WebView/WebPreferenceKeysPrivate.h:
1947         * WebView/WebPreferences.mm:
1948         (+[WebPreferences initialize]):
1949         (-[WebPreferences webGLEnabled]):
1950         (-[WebPreferences setWebGLEnabled:]):
1951         * WebView/WebPreferencesPrivate.h:
1952         * WebView/WebView.mm:
1953         (-[WebView _preferencesChangedNotification:]):
1954
1955 2009-09-30  Sam Weinig  <sam@webkit.org>
1956
1957         Reviewed by Dan Bernstein.
1958
1959         Fix for <rdar://problem/7259706>
1960         Need WebKit API or SPI on Mac and Windows to test whether it's safe to load a page in a new tab/window
1961
1962         * WebView/WebFrame.mm:
1963         (-[WebFrame _allowsFollowingLink:]):
1964         * WebView/WebFramePrivate.h:
1965
1966 2009-09-30  Dave Hyatt  <hyatt@apple.com>
1967
1968         Reviewed by Adam Roben.
1969
1970         Add the ability to remove user stylesheets and scripts by URL.
1971
1972         * WebView/WebView.mm:
1973         (+[WebView _removeUserContentFromGroup:url:worldID:]):
1974         * WebView/WebViewPrivate.h:
1975
1976 2009-09-29  Brady Eidson  <beidson@apple.com>
1977
1978         Rubberstamped by Dan Bernstein.
1979
1980         Fix license and some sorting in new files.
1981
1982         * WebView/WebHistoryDelegate.h:
1983         * WebView/WebNavigationData.h:
1984         * WebView/WebNavigationData.mm:
1985
1986 2009-09-29  Brady Eidson  <beidson@apple.com>
1987
1988         Reviewed by John Sullivan.
1989
1990         WebKit Mac API should provide a delegate interface for global history.
1991         <rdar://problem/7042773> and https://webkit.org/b/29904
1992
1993         * WebView/WebHistoryDelegate.h: Added. New interface for WebKit clients to implement to manage 
1994           their own global history store.
1995
1996         Object to store all of the bits of data relevant to a page visit:
1997         * WebView/WebNavigationData.h: Added.
1998         * WebView/WebNavigationData.mm: Added.
1999         (-[WebNavigationDataPrivate dealloc]):
2000         (-[WebNavigationData initWithURLString:title:originalRequest:response:hasSubstituteData:clientRedirectSource:]):
2001         (-[WebNavigationData url]):
2002         (-[WebNavigationData title]):
2003         (-[WebNavigationData originalRequest]):
2004         (-[WebNavigationData response]):
2005         (-[WebNavigationData hasSubstituteData]):
2006         (-[WebNavigationData clientRedirectSource]):
2007         (-[WebNavigationData dealloc]):
2008
2009         * WebCoreSupport/WebFrameLoaderClient.mm:
2010         (WebFrameLoaderClient::updateGlobalHistory): If the delegate exists, don't use the built-in WebHistory.
2011           If the implementation for this method exists, call it.
2012         (WebFrameLoaderClient::updateGlobalHistoryRedirectLinks): Ditto
2013
2014         * WebView/WebDelegateImplementationCaching.h:
2015         * WebView/WebDelegateImplementationCaching.mm:
2016         (WebViewGetHistoryDelegateImplementations):
2017         (CallHistoryDelegate):
2018
2019         * WebView/WebView.mm:
2020         (-[WebView _cacheHistoryDelegateImplementations]):
2021         (-[WebView setHistoryDelegate:]):
2022         (-[WebView historyDelegate]):
2023         * WebView/WebViewData.h:
2024         * WebView/WebViewPrivate.h:
2025
2026 2009-09-29  Kenneth Russell  <kbr@google.com>
2027
2028         Reviewed by Dimitri Glazkov.
2029
2030         Add support for run-time flag for 3D canvas
2031         https://bugs.webkit.org/show_bug.cgi?id=29826
2032
2033         * WebView/WebView.mm:
2034         (-[WebView _preferencesChangedNotification:]): Enable experimental
2035         WebGL flag when 3D_CANVAS is enabled in the build.
2036
2037 2009-09-28  Fumitoshi Ukai  <ukai@chromium.org>
2038
2039         Reviewed by Eric Seidel.
2040
2041         Add experimentalWebSocketsEnabled in WebPreferences.
2042         https://bugs.webkit.org/show_bug.cgi?id=28941
2043
2044         * WebView/WebPreferenceKeysPrivate.h:
2045         * WebView/WebPreferences.mm:
2046         (+[WebPreferences initialize]):
2047         (-[WebPreferences experimentalWebSocketsEnabled]):
2048         (-[WebPreferences setExperimentalWebSocketsEnabled:]):
2049         * WebView/WebPreferencesPrivate.h:
2050         * WebView/WebView.mm:
2051         (-[WebView _preferencesChangedNotification:]):
2052
2053 2009-09-28  Dan Bernstein  <mitz@apple.com>
2054
2055         Reviewed by Anders Carlsson.
2056
2057         <rdar://problem/7240911> REGRESSION (r48586): Crash occurs when loading
2058         a PDF
2059
2060         CGPDFObjectRef is not a CFTypeRef, and cannot be retained or released.
2061         Its lifetime is managed by its container. Just use a Vector to store
2062         CGPDFObjectRefs, relying on the CGPDFDocument to keep them alive.
2063
2064         * WebView/WebPDFDocumentExtras.mm:
2065         (appendValuesInPDFNameSubtreeToVector):
2066         (getAllValuesInPDFNameTree):
2067         (web_PDFDocumentAllScripts):
2068
2069 2009-09-24  Jon Honeycutt  <jhoneycutt@apple.com>
2070
2071         Reviewed by Alice Liu.
2072
2073         * WebView/WebView.mm:
2074         (-[WebView _commonInitializationWithFrameName:groupName:usesDocumentViews:]):
2075         Pass 0 for new Page constructor argument.
2076
2077 2009-09-14  John Gregg  <johnnyg@google.com>
2078
2079         Reviewed by Eric Seidel.
2080
2081         isEnabled switch for notifications (experimental) in Page Settings
2082         https://bugs.webkit.org/show_bug.cgi?id=28930
2083
2084         Adds support for the experimentalNotificationsEnabled flag in Settings
2085         through WebPreferencesPrivate.
2086
2087         * WebView/WebPreferenceKeysPrivate.h:
2088         * WebView/WebPreferences.mm:
2089         (+[WebPreferences initialize]):
2090         (-[WebPreferences experimentalNotificationsEnabled]):
2091         (-[WebPreferences setExperimentalNotificationsEnabled:]):
2092         * WebView/WebPreferencesPrivate.h:
2093         * WebView/WebView.mm:
2094         (-[WebView _preferencesChangedNotification:]):
2095
2096 2009-09-23  Geoffrey Garen  <ggaren@apple.com>
2097
2098         Reviewed by Sam Weinig.
2099
2100         Updated for a WebCore rename.
2101
2102         * WebView/WebFrame.mm:
2103         (-[WebFrame _cacheabilityDictionary]):
2104
2105 2009-09-23  Darin Adler  <darin@apple.com>
2106
2107         Reviewed by Dan Bernstein.
2108
2109         Speed up access to history items by caching date computation.
2110
2111         * History/WebHistory.mm:
2112         (getDayBoundaries): Refactored from timeIntervalForBeginningOfDay.
2113         Returns the beginning of the day that the passed time is within and
2114         the beginning of the next day.
2115         (beginningOfDay): Added. Uses getDayBoundaries so it can be fast for
2116         multiple dates within the same day, which is the common case.
2117         (dateKey): Added. Calls beginningOfDay and converts to an integer.
2118         (-[WebHistoryPrivate findKey:forDay:]): Changed to call dateKey
2119         insetad of timeIntervalForBeginningOfDay.
2120
2121 2009-09-23  David Kilzer  <ddkilzer@apple.com>
2122
2123         Move definition of USE(PLUGIN_HOST_PROCESS) from WebKitPrefix.h to Platform.h
2124
2125         Reviewed by Mark Rowe.
2126
2127         * WebKitPrefix.h: Removed definition of
2128         WTF_USE_PLUGIN_HOST_PROCESS.
2129
2130 2009-09-22  Timothy Hatcher  <timothy@apple.com>
2131
2132         Prevent scrolling multiple frames during latched wheel events.
2133
2134         Reviewed by Anders Carlsson.
2135
2136         * WebView/WebDynamicScrollBarsView.h:
2137         * WebView/WebDynamicScrollBarsView.mm:
2138         (-[WebDynamicScrollBarsView scrollWheel:]):
2139
2140 2009-09-22  Dan Bernstein  <mitz@apple.com>
2141
2142         Reviewed by John Sullivan.
2143
2144         <rdar://problem/7240911> REGRESSION (r48586): Crash occurs when loading
2145         a PDF
2146
2147         * WebView/WebPDFDocumentExtras.mm:
2148         (addWebPDFDocumentExtras): Made methodList static, because
2149         class_addMethods() doesn't copy it.
2150
2151 2009-09-21  Dan Bernstein  <mitz@apple.com>
2152
2153         Attempt to fix the Tiger build
2154
2155         * WebView/WebPDFDocumentExtras.mm:
2156         (addWebPDFDocumentExtras):
2157
2158 2009-09-21  Dan Bernstein  <mitz@apple.com>
2159
2160         Attempt to fix the Tiger build
2161
2162         * WebView/WebPDFDocumentExtras.mm:
2163         (web_PDFDocumentAllScripts):
2164         (addWebPDFDocumentExtras):
2165
2166 2009-09-21  Dan Bernstein  <mitz@apple.com>
2167
2168         Attempt to fix the Tiger build
2169
2170         * WebView/WebPDFDocumentExtras.mm:
2171         * WebView/WebPDFRepresentation.mm:
2172
2173 2009-09-21  Dan Bernstein  <mitz@apple.com>
2174
2175         Attempt to fix the Leopard and Tiger builds
2176
2177         * WebView/WebPDFDocumentExtras.mm:
2178
2179 2009-09-21  Dan Bernstein  <mitz@apple.com>
2180
2181         Reviewed by Anders Carlsson.
2182
2183         <rdar://problem/4137135> iFrame with PDF not being handled correctly on
2184         usps.com
2185         https://bugs.webkit.org/show_bug.cgi?id=4151
2186
2187         * WebView/WebJSPDFDoc.h: Added.
2188         * WebView/WebJSPDFDoc.mm: Added.
2189         (jsPDFDocInitialize): Retains the WebDataSource.
2190         (jsPDFDocFinalize): Releases the WebDataSource.
2191         (jsPDFDocPrint): Call the WebUIDelegate method -webView:printFrameView:
2192         with the PDF document's view.
2193         (makeJSPDFDoc): Makes and returns a JavaScript Doc instance that wraps
2194         the WebDataSource.
2195         * WebView/WebPDFDocumentExtras.h: Added.
2196         * WebView/WebPDFDocumentExtras.mm: Added.
2197         (appendValuesInPDFNameSubtreeToArray): Traverses a subtree of a PDF name
2198         tree and adds all values in the subtree to an array.
2199         (allValuesInPDFNameTree): Returns an array with all of the values in a
2200         PDF name tree.
2201         (web_PDFDocumentAllScripts): This is the implementation of -[PDFDocument
2202         _web_allScripts]. It gets all values in the document-level "JavaScript"
2203         name tree, which are action dictionaries, and returns an array of the
2204         actions' scripts.
2205         (addWebPDFDocumentExtras): Adds the -_web_allScripts method to
2206         PDFDocument.
2207         * WebView/WebPDFRepresentation.h:
2208         * WebView/WebPDFRepresentation.m: Removed.
2209         * WebView/WebPDFRepresentation.mm: Copied from WebKit/mac/WebView/WebPDFRepresentation.m.
2210         (+[WebPDFRepresentation initialize]): Added. Calls
2211         addWebPDFDocumentExtras().
2212         (-[WebPDFRepresentation finishedLoadingWithDataSource:]): Get the
2213         scripts from the PDF document, create a JavaScript Doc object for the
2214         document, and a JavaScript execution context, then execute every script
2215         in the context, with the Doc object as "this".
2216
2217 2009-09-17  Simon Fraser  <simon.fraser@apple.com>
2218
2219         Reviewed by Dave Hyatt.
2220
2221         Compositing layers are incorrectly positioned after scrolling with position:fixed
2222         https://bugs.webkit.org/show_bug.cgi?id=29262
2223         
2224         When scrolling a page with compositing layers inside a position:fixed element,
2225         we need to update the compositing layer positions when the scroll position changes.
2226
2227         * WebView/WebHTMLView.mm:
2228         (-[WebHTMLView _frameOrBoundsChanged]):
2229         Call the new FrameView::scrollPositionChanged() method rather than sending the
2230         scroll event directly.
2231
2232 2009-09-17  Kenneth Rohde Christiansen  <kenneth@webkit.org>
2233
2234         Reviewed by Simon Hausmann.
2235
2236         Make PlatformWindow return something else than PlatformWidget
2237         https://bugs.webkit.org/show_bug.cgi?id=29085
2238
2239         Reflect the rename of platformWindow and it's return type.
2240
2241         * WebCoreSupport/WebChromeClient.h:
2242         * WebCoreSupport/WebChromeClient.mm:
2243         (WebChromeClient::platformPageClient):
2244
2245 2009-09-17  Anders Carlsson  <andersca@apple.com>
2246
2247         Reviewed by Oliver Hunt.
2248
2249         <rdar://problem/7007541> 
2250         CrashTracer: 4800+ crashes in Safari at com.apple.WebKit • WTF::HashTableIterator...
2251
2252         Add null checks for m_instanceProxy (It will be null when a plug-in has crashed).
2253         
2254         * Plugins/Hosted/ProxyInstance.mm:
2255         (WebKit::ProxyInstance::invoke):
2256         (WebKit::ProxyInstance::supportsInvokeDefaultMethod):
2257         (WebKit::ProxyInstance::supportsConstruct):
2258         (WebKit::ProxyInstance::getPropertyNames):
2259         (WebKit::ProxyInstance::methodsNamed):
2260         (WebKit::ProxyInstance::fieldNamed):
2261         (WebKit::ProxyInstance::fieldValue):
2262         (WebKit::ProxyInstance::setFieldValue):
2263         (WebKit::ProxyInstance::invalidate):
2264
2265 2009-09-16  Simon Fraser  <simon.fraser@apple.com>
2266
2267         Reviewed by Dan Bernstein.
2268
2269         Work around a bug in AppKit on Leopard which causes compositing layers to jitter, and
2270         become misplaced when the WebHTMLView is resized or scrolled sometimes.
2271         <rdar://problem/7071636>
2272         
2273         The previous fix didn't fix the case where the layers jiggle when resizing the docked
2274         inspector when the view size is over 2048px tall, on Leopard.
2275
2276         * WebView/WebHTMLView.mm:
2277         (-[WebHTMLView _updateLayerHostingViewPosition]):
2278
2279 2009-09-16  Simon Fraser  <simon.fraser@apple.com>
2280
2281         Reviewed by Oliver Hunt.
2282
2283         Work around a bug in AppKit on Leopard which causes compositing layers to jitter, and
2284         become misplaced when the WebHTMLView is resized or scrolled sometimes.
2285         <rdar://problem/7071636>
2286         
2287         We call an internal AppKit method to make sure the layer geometry is updated correctly.
2288
2289         * WebView/WebHTMLView.mm:
2290         (-[WebHTMLView _updateLayerHostingViewPosition]):
2291
2292 2009-09-15  Simon Fraser  <simon.fraser@apple.com>
2293
2294         Reviewed by Dan Bernstein.
2295
2296         Fixed position elements flash when CSS transforms are applied on page > 2048px tall
2297         https://bugs.webkit.org/show_bug.cgi?id=27272
2298         
2299         Update the previous workaround for misplaced compositing layers, which used a 4096px
2300         threshold, to 2048px since that's the GPU max texture size on some older hardware.
2301
2302         * WebView/WebHTMLView.mm:
2303         (-[WebHTMLView _updateLayerHostingViewPosition]):
2304
2305 2009-09-15  Alex Milowski  <alex@milowski.com>
2306
2307         Reviewed by Tor Arne Vestbø.
2308
2309         Added the ENABLE_MATHML to the feaure defines
2310
2311         * Configurations/FeatureDefines.xcconfig:
2312
2313 2009-09-15  Mark Rowe  <mrowe@apple.com>
2314
2315         Reviewed by Anders Carlsson.
2316
2317         <rdar://problem/7224378> REGRESSION(r48360): Dragging a tab with a plug-in out of a window, the plug-in gets slow and confused
2318
2319         In r48360, the fix for <rdar://problem/7090444>, I neglected to consider the case where the plug-in had already been started and
2320         -start would do an early-return rather than calling -restartTimers and -addWindowObservers itself.
2321
2322         * Plugins/WebBaseNetscapePluginView.mm:
2323         (-[WebBaseNetscapePluginView viewDidMoveToWindow]): Reinstate the call to -restartTimers and -addWindowObservers, but guard them
2324         with a check that the view is still in the window.
2325
2326 2009-09-14  Brady Eidson  <beidson@apple.com>
2327
2328         Reviewed by Alexey Proskuryakov.
2329
2330         Safari 4 cannot be used to update firmware on Linksys routers.
2331         <rdar://problem/7174050> and https://bugs.webkit.org/show_bug.cgi?id=29160
2332
2333         Adopt the new WebCore::CredentialStorage in WebKit/Mac.
2334
2335         * Misc/WebDownload.mm:
2336         (-[WebDownloadInternal download:didReceiveAuthenticationChallenge:]):
2337         * Plugins/WebBaseNetscapePluginView.mm:
2338         (WebKit::getAuthenticationInfo):
2339
2340 2009-09-12  Mark Rowe  <mrowe@apple.com>
2341
2342         Reviewed by Anders Carlsson.
2343
2344         Fix <rdar://problem/7090444> Crashes in-[WebBaseNetscapePluginView stop] handling NSWindowWillCloseNotification.
2345
2346         It's not valid to call -addWindowObservers when the view is not in a window, but this can happen when -start
2347         initializes a plug-in and the plug-in removes itself from the document during initialization.  -viewDidMoveToWindow
2348         calls -start and then calls -addWindowObservers without ensuring that the view is still in a window.
2349
2350         If -[WebBaseNetscapePluginView addWindowObservers] is incorrectly called when the view is not in a window, it will
2351         observe NSWindowWillCloseNotification on all windows.  This unexpected observer registration is not balanced by an
2352         unregistration so the notification can be delivered after the view is deallocated, causing the crash seen in
2353         <rdar://problem/7090444>.
2354
2355         * Plugins/WebBaseNetscapePluginView.mm:
2356         (-[WebBaseNetscapePluginView start]): Only call -updateAndSetWindow if we still have a current window.
2357         (-[WebBaseNetscapePluginView viewDidMoveToWindow]): Remove unnecessary calls to -restartTimers and -addWindowObservers
2358         from -[WebBaseNetscapePluginView viewDidMoveToWindow].  They are already called from within -start with the extra benefit
2359         of ensuring that the view is still in a window when they are called.
2360
2361 2009-09-11  Mark Rowe  <mrowe@apple.com>
2362
2363         Reviewed by Jon Honeycutt.
2364
2365         Fix <rdar://problem/7145242> Crashes inside WTF::HashTable below NetscapePluginInstanceProxy::disconnectStream
2366
2367         * Plugins/Hosted/HostedNetscapePluginStream.mm:
2368         (WebKit::HostedNetscapePluginStream::cancelLoad): Canceling the load can result in calling through to disconnectStream.
2369         If the plug-in instance holds the last reference to the plug-in stream this will result in the stream being deallocated.
2370         This leads to HostedNetscapePluginStream::cancelLoad's call to disconnectStream being passed a deallocated stream object.
2371         Since the stream was already disconnected by the call to cancel there's no need to call disconnectStream a second time.
2372
2373 2009-09-11  Eric Seidel  <eric@webkit.org>
2374
2375         No review, rolling out r48229.
2376         http://trac.webkit.org/changeset/48229
2377
2378         * WebView/WebFrame.mm:
2379         (-[WebFrame _dragSourceMovedTo:]):
2380
2381 2009-09-10  Mark Rowe  <mrowe@apple.com>
2382
2383         Rubber-stamped by Sam Weinig.
2384
2385         Update JavaScriptCore and WebKit's FeatureDefines.xcconfig so that they are in sync with WebCore as they need to be.
2386
2387         * Configurations/FeatureDefines.xcconfig:
2388
2389 2009-09-09  Jens Alfke  <snej@chromium.org>
2390
2391         Reviewed by Eric Seidel.
2392
2393         Initialize DataTransfer's effectAllowed and dropEffect properties correctly
2394         according to HTML5 spec (sec. 7.9.2-7.9.3).
2395         https://bugs.webkit.org/show_bug.cgi?id=26700
2396
2397         * WebView/WebFrame.mm:
2398         (-[WebFrame _dragSourceMovedTo:]):
2399             Pass current drag operation (if known) to EventHandler::dragSourceMovedTo().
2400
2401 2009-09-09  Dave Hyatt  <hyatt@apple.com>
2402
2403         Reviewed by Adam Roben.
2404
2405         https://bugs.webkit.org/show_bug.cgi?id=29102, add support for user stylesheet injection.  This is similar
2406         to user script injection but allows for user stylesheets to be added.  The stylesheets are applied immediately
2407         to all Frames in the PageGroup.
2408
2409         Added userscripts/simple-stylesheet.html test case.
2410
2411         * WebView/WebView.mm:
2412         (+[WebView _addUserStyleSheetToGroup:source:url:worldID:patterns:]):
2413         * WebView/WebViewPrivate.h:
2414
2415 2009-09-07  Steve Block  <steveblock@google.com>
2416
2417         Reviewed by Adam Barth.
2418
2419         Adds a mock Geolocation service. This will be used to provide predictable behavior of the
2420         Geolocation API for use in LayoutTests. Later changes will integrate the the mock
2421         Geolocation service with DumpRenderTree.
2422         https://bugs.webkit.org/show_bug.cgi?id=28264
2423
2424         * WebCoreSupport/WebGeolocationMockPrivate.h: Added.
2425         * WebCoreSupport/WebGeolocationMock.mm: Added.
2426         (+[WebGeolocationMock setError:code:]): Added. Used by DumpRender tree to configure the mock Geolocation service.
2427         (+[WebGeolocationMock setPosition:latitude:longitude:accuracy:]): Added. Used by DumpRender tree to configure the mock Geolocation service.
2428         * WebKit.exp: Modified. Exports WebGeolocationMock.
2429
2430 2009-09-07  Drew Wilson  <atwilson@google.com>
2431
2432         Reviewed by David Levin.
2433
2434         Enable SHARED_WORKERS by default.
2435         https://bugs.webkit.org/show_bug.cgi?id=28959
2436
2437         * Configurations/FeatureDefines.xcconfig:
2438
2439 2009-09-06  Cameron McCormack  <cam@mcc.id.au>
2440
2441         Reviewed by Eric Seidel.
2442
2443         Drop <definition-src> support
2444         https://bugs.webkit.org/show_bug.cgi?id=28991
2445
2446         * MigrateHeaders.make: Remove reference to ObjC definition-src
2447         binding class.
2448
2449 2009-09-04  Mark Mentovai  <mark@chromium.org>
2450
2451         Reviewed by Dave Hyatt.
2452
2453         https://bugs.webkit.org/show_bug.cgi?id=28614
2454
2455         Account for scrollbar state changes that occur during layout.
2456
2457         * WebView/WebDynamicScrollBarsView.mm:
2458         (-[WebDynamicScrollBarsView updateScrollers]):
2459
2460         Perform a layout prior to checking whether the scrollbar modes are
2461         off, on, or automatic.  The modes may change during layout.
2462
2463         * WebView/WebFrameView.mm:
2464         (-[WebFrameView _install]):
2465
2466         Eliminate duplicated (and incorrect) scrollbar mode tracking between
2467         FrameView and ScrollView.
2468
2469 2009-09-03  Dave Hyatt  <hyatt@apple.com>
2470
2471         Reviewed by Adam Roben.
2472
2473         https://bugs.webkit.org/show_bug.cgi?id=28890, make simple user script injection work.
2474         
2475         This patch adds new API for adding and removing user scripts from page groups.  User scripts
2476         are bundled together in isolated worlds (you can have multiple scripts together in the same
2477         world).
2478
2479         Added userscripts/ directory for holding new tests (along with a simple test of script injection).
2480
2481         * WebView/WebView.mm:
2482         (+[WebView _addUserScriptToGroup:source:url:worldID:patterns:injectionTime:]):
2483         (+[WebView _removeUserContentFromGroup:worldID:]):
2484         (+[WebView _removeAllUserContentFromGroup:]):
2485         * WebView/WebViewPrivate.h:
2486
2487 2009-09-04  Adam Barth  <abarth@webkit.org>
2488
2489         Reviewed by Eric Seidel.
2490
2491         https://bugs.webkit.org/show_bug.cgi?id=24696
2492
2493         Plumb mixed content notifications to WebFrameLoadDelegatePrivate.
2494
2495         * WebCoreSupport/WebFrameLoaderClient.mm:
2496         (WebFrameLoaderClient::didDisplayInsecureContent):
2497         (WebFrameLoaderClient::didRunInsecureContent):
2498         * WebView/WebDelegateImplementationCaching.h:
2499         * WebView/WebFrameLoadDelegatePrivate.h: Added.
2500
2501 2009-09-03  Adam Barth  <abarth@webkit.org>
2502
2503         Unreviewed build fix.
2504
2505         Change notImplemented() to a FIXME.
2506
2507         * WebCoreSupport/WebFrameLoaderClient.mm:
2508         (WebFrameLoaderClient::didDisplayInsecureContent):
2509         (WebFrameLoaderClient::didRunInsecureContent):
2510
2511 2009-09-03  Adam Barth  <abarth@webkit.org>
2512
2513         Reviewed by eric@webkit.org.
2514
2515         https://bugs.webkit.org/show_bug.cgi?id=24696
2516
2517         Plumb mixed content notifications to WebFrameLoadDelegatePrivate.
2518
2519         * WebCoreSupport/WebFrameLoaderClient.mm:
2520         (WebFrameLoaderClient::didDisplayInsecureContent):
2521         (WebFrameLoaderClient::didRunInsecureContent):
2522         * WebView/WebDelegateImplementationCaching.h:
2523         * WebView/WebFrameLoadDelegatePrivate.h: Added.
2524
2525 2009-09-03  Adam Barth  <abarth@webkit.org>
2526
2527         Reviewed by Eric Seidel.
2528
2529         https://bugs.webkit.org/show_bug.cgi?id=24696
2530
2531         Stub implementations of mixed content methods of FrameLoaderClient. 
2532
2533         * WebCoreSupport/WebFrameLoaderClient.h:
2534         * WebCoreSupport/WebFrameLoaderClient.mm:
2535         (WebFrameLoaderClient::didDisplayInsecureContent):
2536         (WebFrameLoaderClient::didRunInsecureContent):
2537
2538 2009-09-02  Brady Eidson  <beidson@apple.com>
2539
2540         Reviewed by Darin Adler.
2541
2542         More partial work towards "Page Cache should support pages with Frames"
2543         https://bugs.webkit.org/show_bug.cgi?id=13631
2544
2545         * WebView/WebHTMLView.mm:
2546         (-[WebHTMLView _topHTMLView]): Rework the ASSERT in this method to reflect the
2547           reality of calling this method for pages currently in the PageCache.
2548
2549 2009-08-31  Dimitri Glazkov  <dglazkov@chromium.org>
2550
2551     Reverting http://trac.webkit.org/changeset/47904, because it caused
2552     layout test failure.
2553
2554 2009-08-31  Alexey Proskuryakov  <ap@webkit.org>
2555
2556         Reviewed by Darin Adler.
2557
2558         https://bugs.webkit.org/show_bug.cgi?id=28852
2559         Rename KURL single argument constructor to avoid confusion
2560
2561         * WebView/WebScriptDebugger.mm: (toNSURL): Adapt to the change.
2562
2563 2009-08-31  Mark Mentovai  <mark@chromium.org>
2564
2565         Reviewed by Dave Hyatt.
2566
2567         https://bugs.webkit.org/show_bug.cgi?id=28614
2568
2569         Perform a layout prior to checking whether the scrollbar modes are
2570         off, on, or automatic.  The modes may change during layout.
2571
2572         * WebView/WebDynamicScrollBarsView.mm:
2573         (-[WebDynamicScrollBarsView updateScrollers]):
2574
2575 2009-08-28  Chris Fleizach  <cfleizach@apple.com>
2576
2577         Reviewed by John Sullivan.
2578
2579         update-webkit-localizable-strings script can no longer complete
2580         https://bugs.webkit.org/show_bug.cgi?id=28792
2581
2582         * WebCoreSupport/WebViewFactory.mm:
2583         (-[WebViewFactory AXARIAContentGroupText:]):
2584
2585 2009-08-28  Gustavo Noronha Silva  <gustavo.noronha@collabora.co.uk>
2586
2587         Reviewed by Holger Freyther.
2588
2589         https://bugs.webkit.org/show_bug.cgi?id=25889
2590         [GTK] scrollbar policy for main frame is not implementable
2591
2592         Add empty implementation for new ChromeClient method.
2593
2594         * WebCoreSupport/WebChromeClient.h:
2595         (WebChromeClient::scrollbarsModeDidChange):
2596
2597 2009-08-25  Eric Carlson  <eric.carlson@apple.com>
2598
2599         Reviewed by Oliver Hunt.
2600
2601         <video> and <audio> controller should be accessible
2602         https://bugs.webkit.org/show_bug.cgi?id=28081
2603
2604         * WebCoreSupport/WebViewFactory.mm:
2605         (-[WebViewFactory localizedMediaControlElementString:]):
2606         (-[WebViewFactory localizedMediaControlElementHelpText:]):
2607         (-[WebViewFactory localizedMediaTimeDescription:]):
2608             New.
2609
2610 2009-08-24  Simon Fraser  <simon.fraser@apple.com>
2611
2612         Reviewed by NOBODY (build fix)
2613
2614         Turn off ENABLE_3D_CANVAS in the xconfig files.
2615
2616         * Configurations/FeatureDefines.xcconfig:
2617
2618 2009-08-22  Adam Barth  <abarth@webkit.org>
2619
2620         Revert 47684.  We're going to do this later once clients have had a
2621         chance to opt into the setting they like.
2622
2623         * Misc/WebKitVersionChecks.h:
2624         * WebView/WebPreferences.mm:
2625         (+[WebPreferences initialize]):
2626
2627 2009-08-22  Adam Barth  <abarth@webkit.org>
2628
2629         Reviewed by Eric Seidel.
2630
2631         Don't let local files access web URLs
2632         https://bugs.webkit.org/show_bug.cgi?id=28480
2633
2634         * Misc/WebKitVersionChecks.m:
2635         * WebView/WebPreferences.mm:
2636         (+[WebPreferences initialize]):
2637
2638 2009-08-21  Anders Carlsson  <andersca@apple.com>
2639
2640         Reviewed by Darin Adler.
2641
2642         <rdar://problem/7162480>
2643         Sometimes WebKit does not layout correctly when a WebView is embedded in an HICocoaView
2644         
2645         Add a null check for the current context when reflectScrolledClipView: is called from outside a 
2646         draw operation.
2647         
2648         * WebView/WebDynamicScrollBarsView.mm:
2649         (-[WebDynamicScrollBarsView reflectScrolledClipView:]):
2650
2651 2009-08-20  Chris Fleizach  <cfleizach@apple.com>
2652
2653         Reviewed by Darin Adler.
2654
2655         Enable various "grouping" ARIA roles
2656         https://bugs.webkit.org/show_bug.cgi?id=28486
2657
2658         * WebCoreSupport/WebViewFactory.mm:
2659         (-[WebViewFactory AXARIAContentGroupText:]):
2660
2661 2009-08-19  Mark Rowe  <mrowe@apple.com>
2662
2663         Reviewed by Dan Bernstein.
2664
2665         Fix <http://webkit.org/b/28484> Plug-in-related leaks seen on the build bot
2666
2667         When the plug-in data is being loaded manually there is a reference cycle between the
2668         NetscapePluginInstanceProxy and the HostedNetscapePluginStream.  We need to explicitly
2669         break the reference cycle in NetscapePluginInstanceProxy::cleanup so that both objects
2670         will be destroyed.
2671
2672         Take the opportunity to add RefCountedLeakCounter support to HostedNetscapePluginStream
2673         and NetscapePluginInstanceProxy to simplify tracking down leaks of these objects in the future.
2674
2675         * Plugins/Hosted/HostedNetscapePluginStream.h:
2676         * Plugins/Hosted/HostedNetscapePluginStream.mm:
2677         (WebKit::HostedNetscapePluginStream::HostedNetscapePluginStream):
2678         (WebKit::HostedNetscapePluginStream::~HostedNetscapePluginStream):
2679         * Plugins/Hosted/NetscapePluginInstanceProxy.mm:
2680         (WebKit::NetscapePluginInstanceProxy::NetscapePluginInstanceProxy):
2681         (WebKit::NetscapePluginInstanceProxy::~NetscapePluginInstanceProxy):
2682         (WebKit::NetscapePluginInstanceProxy::cleanup): Clear m_manualStream to break the reference
2683         cycle.
2684
2685 2009-08-19  Aaron Boodman  <aa@chromium.org>
2686
2687         Reviewed by David Levin.
2688
2689         https://bugs.webkit.org/show_bug.cgi?id=24853: Provide a way for WebKit clients to
2690         specify a more granular policy for cross-origin XHR access.
2691
2692         * WebView/WebView.mm: Add SPI to manipulate origin access whitelists.
2693         (+[WebView _whiteListAccessFromOrigin:destinationProtocol:destinationHost:allowDestinationSubdomains:]): Ditto.
2694         (+[WebView _resetOriginAccessWhiteLists]): Ditto.
2695         * WebView/WebViewPrivate.h: Ditto.
2696
2697 2009-08-18  Anders Carlsson  <andersca@apple.com>
2698
2699         Reviewed by Adele Peterson.
2700
2701         Mac specific part of
2702         
2703         <rdar://problem/7135588> HTMLMediaElement should ask WebPolicyLoadDelegate before loading resource
2704
2705         * WebCoreSupport/WebFrameLoaderClient.h:
2706         * WebCoreSupport/WebFrameLoaderClient.mm:
2707         Implement shouldLoadMediaElementURL by asking the policy delegate.
2708         
2709         * WebView/WebPolicyDelegatePrivate.h:
2710         Add new delegate method, remove some unused cruft.
2711
2712 2009-08-18  Drew Wilson  <atwilson@google.com>
2713
2714         Reviewed by Eric Seidel.
2715
2716         Need to extend DumpRenderTree to expose number of worker threads.
2717         https://bugs.webkit.org/show_bug.cgi?id=28292
2718
2719         * WebKit.exp:
2720         Exported WebWorkersPrivate so DumpRenderTree can access it.
2721         * Workers/WebWorkersPrivate.h: Added.
2722         * Workers/WebWorkersPrivate.mm: Added.
2723         (+[WebWorkersPrivate workerThreadCount]):
2724         Added WebWorkersPrivate::workerThreadCount() API for DumpRenderTree.
2725
2726 2009-08-17  Darin Adler  <darin@apple.com>
2727
2728         Reviewed by Sam Weinig.
2729
2730         Use a HashMap instead of a list of if statements for the command
2731         name exception map.
2732
2733         * WebView/WebHTMLView.mm:
2734         (createSelectorExceptionMap): Added.
2735         (commandNameForSelector): Use createSelectorExceptionMap.
2736
2737 2009-08-16  David Kilzer  <ddkilzer@apple.com>
2738
2739         <http://webkit.org/b/28366> WebHTMLViewInternal.h: add @class CALayer declaration
2740
2741         Reviewed by Simon Fraser.
2742
2743         Without WebKitPrefix.h, the missing @class CALayer declaration
2744         causes a compile-time error.
2745
2746         * WebView/WebHTMLViewInternal.h: Added @class CALayer
2747         declaration with USE(ACCELERATED_COMPOSITING).
2748
2749 2009-08-16  David Kilzer  <ddkilzer@apple.com>
2750
2751         <http://webkit.org/b/28355> Replace MAX()/MIN() macros with type-safe std::max()/min() templates
2752
2753         Reviewed by Dan Bernstein.
2754
2755         * Plugins/WebBaseNetscapePluginStream.mm: Added using std::min
2756         statement.
2757         (WebNetscapePluginStream::deliverData): Changed MIN() to min().
2758         Changed C-style cast to a static_cast.
2759         * Plugins/WebNetscapePluginView.mm: Added using std::min
2760         statement.
2761         (-[WebNetscapePluginView _postURL:target:len:buf:file:notifyData:sendNotification:allowHeaders:]):
2762         Changed MIN() to min().  Changed C-style cast to a static_cast.
2763         * WebView/WebHTMLView.mm: Added using std::max statement.
2764         (-[WebHTMLView _dragImageForURL:withLabel:]): Changed MAX() to
2765         max().
2766         (-[WebHTMLView _scaleFactorForPrintOperation:]): Ditto.
2767         * WebView/WebTextCompletionController.mm: Added using std::max
2768         and using std::min statements.
2769         (-[WebTextCompletionController _placePopupWindow:]): Changed
2770         type of maxWidth variable from float to CGFloat to prevent a
2771         type mismatch on x86_64.  Changed MAX() to max() and MIN() to
2772         min().  Added static_cast for a constant value since CGFloat is
2773         defined as a float on i386 and as a double on x86_64.
2774
2775 2009-08-15  Adam Bergkvist  <adam.bergkvist@ericsson.com>
2776
2777         Reviewed by Sam Weinig.
2778
2779         Added ENABLE_EVENTSOURCE flag.
2780         https://bugs.webkit.org/show_bug.cgi?id=14997
2781
2782         * Configurations/FeatureDefines.xcconfig:
2783
2784 2009-08-14  Mark Rowe  <mrowe@apple.com>
2785
2786         Build fix.
2787
2788         * Plugins/Hosted/NetscapePluginInstanceProxy.mm:
2789         (WebKit::NetscapePluginInstanceProxy::enumerate):  Add the necessary .get() calls.
2790
2791 2009-08-14  Brady Eidson  <beidson@apple.com>
2792
2793         Reviewed by Anders Carlsson.
2794
2795         <rdar://problem/7091546> - Assertion failure in plugins/return-error-from-new-stream-doesnt-invoke-destroy-stream.html 
2796         on 64-bit SnowLeopard
2797
2798         * Plugins/Hosted/HostedNetscapePluginStream.mm:
2799         (WebKit::HostedNetscapePluginStream::cancelLoad): Since this might be called while the FrameLoader is switching DocumentLoaders
2800           during the brief moment where there is no activeDocumentLoader(), accept and handle a validly null DocumentLoader.
2801
2802 2009-08-14  Mark Rowe  <mrowe@apple.com>
2803
2804         Reviewed by Brady Eidson.
2805
2806         Fix leaks of NSNumber and NSMutableArray objects seen during layout tests.
2807
2808         * Plugins/Hosted/NetscapePluginInstanceProxy.mm:
2809         (WebKit::NetscapePluginInstanceProxy::enumerate): Don't leak an NSMutableArray that we allocate.
2810
2811 2009-08-14  Mark Rowe  <mrowe@apple.com>
2812
2813         Reviewed by Anders Carlsson.
2814
2815         Fix leaks of HostedNetscapePluginStream and NetscapePlugInStreamLoader objects seen during layout tests.
2816
2817         * Plugins/Hosted/HostedNetscapePluginStream.mm:
2818         (WebKit::HostedNetscapePluginStream::didFail): Disconnect the stream from the plug-in instance proxy
2819         when the load fails.
2820
2821 2009-08-13  Darin Adler  <darin@apple.com>
2822
2823         * Plugins/Hosted/NetscapePluginInstanceProxy.mm: Updated includes.
2824         * WebView/WebScriptDebugger.mm: Ditto.
2825
2826 2009-08-12  Mark Rowe  <mrowe@apple.com>
2827
2828         Reviewed by Kevin Decker.
2829
2830         <rdar://problem/6017913> Replace use of HISearchWindowShow in -[WebView _searchWithSpotlightFromMenu].
2831
2832         * WebView/WebView.mm:
2833         (-[WebView _searchWithSpotlightFromMenu:]): Use -[NSWorkspace showSearchResultsForQueryString:] post-Leopard.
2834
2835 2009-08-12  Greg Bolsinga  <bolsinga@apple.com>
2836
2837         Reviewed by Eric Seidel.
2838
2839         Add delegate methods about focus and blur and state change
2840         https://bugs.webkit.org/show_bug.cgi?id=27153
2841         
2842         Have ObjC delegate methods match C++ method names in the ChromeClient.
2843
2844         * WebCoreSupport/WebChromeClient.mm:
2845         (WebChromeClient::formDidFocus):
2846         (WebChromeClient::formDidBlur):
2847         * WebView/WebUIDelegatePrivate.h:
2848
2849 2009-08-11  John Gregg  <johnnyg@google.com>
2850
2851         Reviewed by Maciej Stachowiak.
2852
2853         Desktop Notifications API
2854         https://bugs.webkit.org/show_bug.cgi?id=25643
2855
2856         Adds ENABLE_NOTIFICATION flag.
2857
2858         * Configurations/FeatureDefines.xcconfig:
2859
2860 2009-08-11  Anders Carlsson  <andersca@apple.com>
2861
2862         Reviewed by Sam Weinig.
2863
2864         Remove dead declarations.
2865         
2866         * WebView/WebViewInternal.h:
2867
2868 2009-08-11  Dmitry Titov  <dimich@chromium.org>
2869
2870         Reviewed by Adam Roben.
2871
2872         Originally implemented by Glenn Wilson <gwilson@chromium.org>.
2873
2874         Added new methods for overriding default WebPreference values
2875         and for resetting preferences to their defaults.
2876         See https://bugs.webkit.org/show_bug.cgi?id=20534
2877
2878         * WebView/WebPreferences.mm:
2879         (-[WebPreferences _setPreferenceForTestWithValue:withKey:]): added.
2880         * WebView/WebPreferencesPrivate.h: same.
2881
2882 2009-08-09  Nikolas Zimmermann  <nikolas.zimmermann@torchmobile.com>
2883
2884         Reviewed by George Staikos.
2885
2886         [WML] Deck access control is completly broken
2887         https://bugs.webkit.org/show_bug.cgi?id=27721
2888
2889         Synchronize WebFrameLoadType with FrameLoadType enum. Append 'WebFrameLoadTypeBackWMLDeckNotAccessible'.
2890
2891         * WebView/WebFramePrivate.h:
2892
2893 2009-08-07  Simon Fraser  <simon.fraser@apple.com>
2894
2895         Fix the build on 10.6.
2896
2897         * WebView/WebHTMLView.mm:
2898         (-[WebHTMLView attachRootLayer:]):
2899
2900 2009-08-07  Simon Fraser  <simon.fraser@apple.com>
2901
2902         Fix a stylistic nit related to the location of the *, which, for some
2903         ridiculous reason, WebKit style dictates to be different between Objective-C and C++.
2904         
2905         * WebView/WebDynamicScrollBarsView.mm:
2906         (-[WebDynamicScrollBarsView reflectScrolledClipView:]):
2907
2908 2009-08-07  Simon Fraser  <simon.fraser@apple.com>
2909
2910         Reviewed by Dan Bernstein.
2911
2912         Work around an issue on Leopard where composited layers are misplaced and squished when the page
2913         gets over 4096px tall.
2914         https://bugs.webkit.org/show_bug.cgi?id=27272
2915         <rdar://problem/7067892> [Leopard] Composisted layers are misplaced and squished on on long pages
2916         <rdar://problem/7068252> [Leopard] When switching to a tab with HW layers, they fade in
2917
2918         * WebView/WebDynamicScrollBarsView.mm:
2919         (-[WebDynamicScrollBarsView reflectScrolledClipView:]):
2920         Call -_updateLayerHostingViewPosition after scrolling.
2921         
2922         * WebView/WebHTMLView.mm:
2923         (-[WebHTMLView _frameOrBoundsChanged]):
2924         Call -_updateLayerHostingViewPosition after the view changes size.
2925
2926         (-[WebHTMLView attachRootLayer:]):
2927         Turn off default animations, to avoid animations of sublayer transform, and fading-in
2928         when tab switching.
2929         
2930         * WebView/WebHTMLViewInternal.h:
2931         (-[WebHTMLView _updateLayerHostingViewPosition]):
2932         New method that constrains the height of the layer-hosting view to a max height
2933         of 4096px, and compensates for the height restriction by placing the layer-hosting
2934         view at the top of the visible part of the WebHTMLView, and adjusting the position
2935         of the hosted layers via sublayer transform.
2936
2937 2009-08-07  Anders Carlsson  <andersca@apple.com>
2938
2939         Fix Tiger build.
2940         
2941         * WebView/WebRenderNode.mm:
2942         (-[WebRenderNode _initWithCoreFrame:]):
2943
2944 2009-08-07  Anders Carlsson  <andersca@apple.com>
2945
2946         Reviewed by Timothy Hatcher and Sam Weinig.
2947
2948         Change WebRenderNode to take a WebFrame instead of a WebFrameView.
2949         
2950         * WebView/WebRenderNode.h:
2951         * WebView/WebRenderNode.mm:
2952         (-[WebRenderNode _initWithName:position:rect:coreFrame:children:]):
2953         (copyRenderNode):
2954         (-[WebRenderNode _initWithCoreFrame:]):
2955         (-[WebRenderNode initWithWebFrame:]):
2956
2957 2009-08-06  Anders Carlsson  <andersca@apple.com>
2958
2959         Reviewed by Darin Adler and Dan Bernstein.
2960
2961         * WebCoreSupport/WebFrameLoaderClient.mm:
2962         (WebFrameLoaderClient::hasHTMLView):
2963         Always return true when we're in viewless mode.
2964
2965 2009-08-06  Anders Carlsson  <andersca@apple.com>
2966
2967         Remove WebGraphicsExtras.h include.
2968         
2969         * Plugins/WebNetscapePluginView.mm:
2970
2971 2009-08-06  Anders Carlsson  <andersca@apple.com>
2972
2973         Reviewed by Sam Weinig.
2974
2975         Remove WebGraphicsExtras, it is no longer used.
2976
2977         * Misc/WebGraphicsExtras.c: Removed.
2978         * Misc/WebGraphicsExtras.h: Removed.
2979
2980 2009-08-06  Chris Marrin  <cmarrin@apple.com>
2981
2982         Reviewed by David Hyatt.
2983
2984         Added ENABLE_3D_CANVAS flag to build, default to off
2985
2986         * Configurations/FeatureDefines.xcconfig:
2987
2988 2009-08-04  Michael Nordman  <michaeln@google.com>
2989
2990         Reviewed by Alexey Proskuryakov.
2991
2992         https://bugs.webkit.org/show_bug.cgi?id=27821
2993
2994         Mods to keep up with ApplicationCacheHost refactoring.
2995
2996         * WebView/WebDataSource.mm:
2997         (-[WebDataSource _transferApplicationCache:]):
2998
2999 2009-07-30  Darin Adler  <darin@apple.com>
3000
3001         Reviewed by David Levin.
3002
3003         Use checked casts for render tree
3004         https://bugs.webkit.org/show_bug.cgi?id=23522
3005
3006         * Misc/WebNSAttributedStringExtras.mm:
3007         (fileWrapperForElement):
3008         * Misc/WebNSPasteboardExtras.mm:
3009         (imageFromElement):
3010         (-[NSPasteboard _web_declareAndWriteDragImageForElement:URL:title:archive:source:]):
3011         * WebView/WebFrame.mm:
3012         (-[WebFrame _computePageRectsWithPrintWidthScaleFactor:printHeight:]):
3013         (-[WebFrame _accessibilityTree]):
3014         * WebView/WebRenderNode.mm:
3015         (copyRenderNode):
3016         Use checked casts.
3017
3018 2009-07-31  Simon Fraser  <simon.fraser@apple.com>
3019
3020         Reviewed by Anders Carlsson.
3021         
3022         Accelerated animations stutter on pages with lots of animations and 3d transforms
3023         https://bugs.webkit.org/show_bug.cgi?id=27884
3024         
3025         This patch changes the strategy for synchronizing painting view the view,
3026         and compositing layer updates. Previously the strategy was to disable screen
3027         updates between the time we updated the layer tree, and painted the view. That
3028         left screen updates disabled for too long (hundreds of milliseconds) in some
3029         cases, causing animation stutter.
3030         
3031         The new strategy is to batch up changes to the CA layer tree, and commit them
3032         all at once just before painting happens (referred to as a "sync" in the code).
3033         GraphicsLayerCA now keeps a bitmask of changed properties, and then migrates
3034         the values stored in GraphicsLayer into the CA layer tree at commit time.
3035         
3036         Compositing layers are then synced in FrameView::paintContents(). However, not
3037         all style/layout changes will result in painting; to deal with style changes that
3038         touch only compositing properties, we set up a runloop observer that takes care
3039         of comitting layer changes when no painting happens.
3040
3041         * WebCoreSupport/WebChromeClient.h:
3042         * WebCoreSupport/WebChromeClient.mm:
3043         (WebChromeClient::scheduleCompositingLayerSync):
3044         scheduleViewUpdate() renamed to syncCompositingStateRecursive()
3045         
3046         * WebView/WebView.mm:
3047         (-[WebView _close]):
3048         (-[WebView _clearLayerSyncLoopObserver]):
3049         "viewUpdateRunLoopObserver" is now "layerSyncLoopObserver".
3050
3051         (-[WebView _syncCompositingChanges]):
3052         Helper method that calls syncCompositingStateRecursive() on the FrameView.
3053         
3054         (layerSyncRunLoopObserverCallBack):
3055         (-[WebView _scheduleCompositingLayerSync]):
3056         This is all about layer sycning now. Also, the run loop observer is repeating,
3057         because it has to keep firing until syncCompositingStateRecursive() says that it
3058         has completed.
3059         
3060         * WebView/WebViewData.h:
3061         "viewUpdateRunLoopObserver" is now "layerSyncLoopObserver".
3062
3063         * WebView/WebViewInternal.h:
3064         _scheduleViewUpdate is now _scheduleCompositingLayerSync
3065
3066 2009-07-30  Michael Nordman  <michaeln@google.com>
3067
3068         Reviewed by Darin Fisher.
3069
3070         https://bugs.webkit.org/show_bug.cgi?id=27821
3071
3072         Mods to keep up with ApplicationCacheHost refactoring.
3073
3074         * WebView/WebDataSource.mm:
3075         (-[WebDataSource _transferApplicationCache:]):
3076
3077 2009-07-29  David Kilzer  <ddkilzer@apple.com>
3078
3079         <http://webkit.org/b/27788> Don't export WebPluginController.h as a private header
3080
3081         Reviewed by Mark Rowe.
3082
3083         * Plugins/WebPluginController.h: Changed #import of
3084         WebPluginContainerCheck.h to use a framework-style include in
3085         case other platforms wish to export WebPluginController.h as a
3086         private header.
3087
3088 2009-07-29  Kevin McCullough  <kmccullough@apple.com>
3089
3090         Reviewed by Darin Adler.
3091
3092         Added foundation work to allow a testing infrastructure for the Web
3093         Inspector.
3094
3095         * WebCoreSupport/WebInspectorClient.h:
3096         * WebCoreSupport/WebInspectorClient.mm:
3097         (WebInspectorClient::inspectorWindowObjectCleared): Send the delegate
3098         callback.
3099         * WebView/WebDelegateImplementationCaching.h:
3100         * WebView/WebView.mm:
3101         (-[WebView _cacheFrameLoadDelegateImplementations]):
3102         * WebView/WebViewPrivate.h: The delegate SPI.
3103
3104 2009-07-27  Mark Rowe  <mrowe@apple.com>
3105
3106         Reviewed by Darin Adler.
3107
3108         <rdar://problem/7091036> REGRESSION: Microsoft Messenger crashes during file send/receive due to use of WebKit on non-main thread
3109
3110         In some situations Microsoft Messenger can attempt to manipulate the DOM from a secondary thread while
3111         updating its file transfer progress bar.  This results in corruption of WebCore data structures that is
3112         quickly followed by a crash.  We can work around this by having -[WebFrame DOMDocument] return nil when
3113         called from a secondary thread by Microsoft Messenger, which has the effect of turning its attempts at
3114         DOM manipulation in to no-ops.
3115
3116         * WebView/WebFrame.mm:
3117         (needsMicrosoftMessengerDOMDocumentWorkaround):
3118         (-[WebFrame DOMDocument]):
3119
3120 2009-07-27  Alexey Proskuryakov  <ap@webkit.org>
3121
3122         Reviewed by Darin Adler.
3123
3124         https://bugs.webkit.org/show_bug.cgi?id=27735
3125         Give a helpful name to JSLock constructor argument
3126
3127         * Misc/WebCoreStatistics.mm:
3128         (+[WebCoreStatistics javaScriptObjectsCount]):
3129         (+[WebCoreStatistics javaScriptGlobalObjectsCount]):
3130         (+[WebCoreStatistics javaScriptProtectedObjectsCount]):
3131         (+[WebCoreStatistics javaScriptProtectedGlobalObjectsCount]):
3132         (+[WebCoreStatistics javaScriptProtectedObjectTypeCounts]):
3133         (+[WebCoreStatistics shouldPrintExceptions]):
3134         (+[WebCoreStatistics setShouldPrintExceptions:]):
3135         (+[WebCoreStatistics memoryStatistics]):
3136         (+[WebCoreStatistics javaScriptReferencedObjectsCount]):
3137         * Plugins/Hosted/NetscapePluginInstanceProxy.mm:
3138         (WebKit::NetscapePluginInstanceProxy::evaluate):
3139         (WebKit::NetscapePluginInstanceProxy::invoke):
3140         (WebKit::NetscapePluginInstanceProxy::invokeDefault):
3141         (WebKit::NetscapePluginInstanceProxy::construct):
3142         (WebKit::NetscapePluginInstanceProxy::getProperty):
3143         (WebKit::NetscapePluginInstanceProxy::setProperty):
3144         (WebKit::NetscapePluginInstanceProxy::removeProperty):
3145         (WebKit::NetscapePluginInstanceProxy::hasMethod):
3146         (WebKit::NetscapePluginInstanceProxy::enumerate):
3147         (WebKit::NetscapePluginInstanceProxy::addValueToArray):
3148         * Plugins/WebBaseNetscapePluginStream.mm:
3149         (WebNetscapePluginStream::wantsAllStreams):
3150         * Plugins/WebNetscapePluginView.mm:
3151         (-[WebNetscapePluginView sendEvent:isDrawRect:]):
3152         (-[WebNetscapePluginView setWindowIfNecessary]):
3153         (-[WebNetscapePluginView createPluginScriptableObject]):
3154         (-[WebNetscapePluginView evaluateJavaScriptPluginRequest:]):
3155         (-[WebNetscapePluginView webFrame:didFinishLoadWithReason:]):
3156         (-[WebNetscapePluginView loadPluginRequest:]):
3157         (-[WebNetscapePluginView _printedPluginBitmap]):
3158         * Plugins/WebPluginController.mm:
3159         (+[WebPluginController plugInViewWithArguments:fromPluginPackage:]):
3160         (-[WebPluginController startAllPlugins]):
3161         (-[WebPluginController stopAllPlugins]):
3162         (-[WebPluginController addPlugin:]):
3163         (-[WebPluginController destroyPlugin:]):
3164         (-[WebPluginController destroyAllPlugins]):
3165         * WebView/WebFrame.mm:
3166         (-[WebFrame _stringByEvaluatingJavaScriptFromString:forceUserGesture:]):
3167         * WebView/WebScriptDebugDelegate.mm:
3168         (-[WebScriptCallFrame scopeChain]):
3169         (-[WebScriptCallFrame evaluateWebScript:]):
3170         * WebView/WebView.mm:
3171         (-[WebView aeDescByEvaluatingJavaScriptFromString:]):
3172
3173 2009-07-24  Darin Adler  <darin@apple.com>
3174
3175         Reviewed by Mark Rowe.
3176
3177         REGRESSION (r46298): Exception after clicking on Bookmarks button in the Bookmarks Bar
3178         https://bugs.webkit.org/show_bug.cgi?id=27667
3179
3180         * WebCoreSupport/WebFrameLoaderClient.mm:
3181         (WebFrameLoaderClient::transitionToCommittedForNewPage): Moved the code to set the
3182         title here. This is late enough that both the view and representation exist.
3183
3184         * WebView/WebDataSource.mm:
3185         (-[WebDataSource _makeRepresentation]): Removed the code to set the title from here.
3186         It's a bit too early.
3187
3188 2009-07-24  Andrei Popescu  <andreip@google.com>
3189
3190         Reviewed by Anders Carlsson.
3191
3192         ApplicationCache should have size limit
3193         https://bugs.webkit.org/show_bug.cgi?id=22700
3194
3195         Adds the WebApplicationCache class that is
3196         used by the DumpRenderTree test application to
3197         configure the Application Cache maximum size.
3198
3199         * WebCoreSupport/WebApplicationCache.h: Added.
3200         * WebCoreSupport/WebApplicationCache.mm: Added.
3201         * WebCoreSupport/WebChromeClient.h:
3202         * WebCoreSupport/WebChromeClient.mm:
3203         (WebChromeClient::reachedMaxAppCacheSize):
3204         Adds empty implementation of the reachedMaxAppCacheSize callback.
3205         * WebKit.exp:
3206
3207 2009-07-23  Darin Adler  <darin@apple.com>
3208
3209         * WebView/WebDataSource.mm:
3210         (-[WebDataSource _makeRepresentation]): Landed a comment I forgot last time.
3211
3212 2009-07-23  Darin Adler  <darin@apple.com>
3213
3214         Reviewed by Brady Eidson.
3215
3216         URL appears in back/forward button menu instead of title for items with custom representation
3217         https://bugs.webkit.org/show_bug.cgi?id=27586
3218         rdar://problem/5060337
3219
3220         The problem is that DocumentLoader expects to store a title, but for custom representations
3221         it is never passed to the document loader.
3222
3223         * WebView/WebDataSource.mm:
3224         (-[WebDataSource _makeRepresentation]): Added a call to DocumentLoader::setTitle.
3225         Works as long as the title does not change during the document's lifetime, which
3226         is good enough for the simple cases in Safari.
3227
3228 2009-07-20  Darin Adler  <darin@apple.com>
3229
3230         Reviewed by Dan Bernstein.
3231
3232         REGRESSION (r39185): Safari adds ".jpeg" extension to images that already have ".JPG" extension
3233         https://bugs.webkit.org/show_bug.cgi?id=27472
3234
3235         * WebView/WebHTMLView.mm:
3236         (matchesExtensionOrEquivalent): Changed category method into a C function.
3237         Made it require the leading dot when checking for the extension and do it
3238         in a non-case-sensitive way.
3239         (-[WebHTMLView namesOfPromisedFilesDroppedAtDestination:]): Changed to call
3240         the function.
3241
3242 2009-07-21  Roland Steiner  <rolandsteiner@google.com>
3243
3244         Reviewed by David Levin.
3245
3246         Add ENABLE_RUBY to list of build options
3247         https://bugs.webkit.org/show_bug.cgi?id=27324
3248
3249         * Configurations/FeatureDefines.xcconfig: Added flag ENABLE_RUBY.
3250
3251 2009-07-17  Brian Weinstein  <bweinstein@apple.com>
3252
3253         Reviewed by Adam Roben.
3254
3255         Fix of <rdar://problem/5712795> Win: Cannot change the height of the docked Web Inspector (14272)
3256         https://bugs.webkit.org/show_bug.cgi?id=14272
3257         
3258         Removed size calculation code from [WebInspectorWindowController setInitialAttachedHeight] into
3259         InspectorController.cpp to make it cross platform, and use InspectorController to store the 
3260         user's preferred size for an attached window, instead of NSUserDefaults.
3261
3262         * WebCoreSupport/WebInspectorClient.mm:
3263         (-[WebInspectorWindowController showWindow:]):
3264         (-[WebInspectorWindowController setAttachedWindowHeight:]):
3265
3266 2009-07-16  Fumitoshi Ukai  <ukai@chromium.org>
3267
3268         Reviewed by David Levin.
3269
3270         Add --web-sockets flag and ENABLE_WEB_SOCKETS define.
3271         https://bugs.webkit.org/show_bug.cgi?id=27206
3272         
3273         Add ENABLE_WEB_SOCKETS
3274
3275         * Configurations/FeatureDefines.xcconfig: add ENABLE_WEB_SOCKETS
3276
3277 2009-07-16  Xiaomei Ji  <xji@chromium.org>
3278
3279         Reviewed by Darin Adler.
3280
3281         Fix tooltip does not get its directionality from its element's directionality.
3282         https://bugs.webkit.org/show_bug.cgi?id=24187
3283
3284         Per mitz's suggestion in comment #6, while getting the plain-text 
3285         title, we also get the directionality of the title. How to handle 
3286         the directionality is up to clients. Clients could ignore it, 
3287         or use attribute or unicode control characters to display the title
3288         as what they want.
3289
3290         * Misc/WebElementDictionary.mm:
3291         (-[WebElementDictionary _spellingToolTip]): Change spellingToolTip caller due to signature change.
3292         (-[WebElementDictionary _title]): Change title caller due to signature change.
3293         * WebCoreSupport/WebChromeClient.h: Add directionality as 2nd parameter to setToolTip().
3294         * WebCoreSupport/WebChromeClient.mm:
3295         (WebChromeClient::setToolTip): Add directionality as 2nd parameter to setToopTip() (without handling it yet).
3296
3297 2009-07-15  Darin Adler  <darin@apple.com>
3298
3299         Reviewed by Sam Weinig.
3300
3301         Renamed parseURL to deprecatedParseURL.
3302
3303         * DOM/WebDOMOperations.mm:
3304         (-[DOMDocument URLWithAttributeString:]): Renamed.
3305         * WebCoreSupport/WebFrameLoaderClient.mm:
3306         (WebFrameLoaderClient::createPlugin): Renamed.
3307
3308 2009-07-15  Brady Eidson  <beidson@apple.com>
3309
3310         Reviewed by Dan Bernstein.
3311
3312         https://bugs.webkit.org/show_bug.cgi?id=27304
3313         WebKit should provide usage and eligibility information about the page cache.
3314
3315         * Misc/WebCoreStatistics.h:
3316         * Misc/WebCoreStatistics.mm:
3317         (+[WebCoreStatistics numberCachedPages]):
3318         (+[WebCoreStatistics numberCachedFrames]):
3319         (+[WebCoreStatistics numberAutoreleasedPages]):
3320         * WebKit.exp:
3321
3322         * WebView/WebFrame.mm:
3323         (-[WebFrame _cacheabilityDictionary]): Returns a dictionary with all the data about
3324           why the frame is not cacheable. If the frame *is* cacheable, the dictionary is
3325           empty.
3326         * WebView/WebFramePrivate.h:
3327
3328 2009-07-13  Simon Fraser  <simon.fraser@apple.com>
3329
3330         Reviewed by Dan Bernstein, Adam Roben.
3331
3332         "Unrecognized selector" console log when the Safari 4 Welcome page navigates to Top Sites.
3333         <rdar://problem/6994893
3334
3335         attachRootGraphicsLayer() should not assume that the frameView's documentView
3336         is a WebHTMLView.
3337         
3338         * WebCoreSupport/WebChromeClient.mm:
3339         (WebChromeClient::attachRootGraphicsLayer):
3340
3341 2009-07-13  Anders Carlsson  <andersca@apple.com>
3342
3343         Reviewed by Darin Adler and Kevin Decker.
3344
3345         <rdar://problem/7053687> Core Animation plug-ins continue to grow larger and larger when opening new tabs (32 bit-only)
3346
3347         * Plugins/Hosted/WebHostedNetscapePluginView.mm:
3348         (-[WebHostedNetscapePluginView setLayer:]):
3349         Add a FIXME.
3350         
3351         * Plugins/WebNetscapePluginView.mm:
3352         (-[WebNetscapePluginView setLayer:]):
3353         Make sure to set the size of the layer before changing the autoresizing mask so it won't grow everytime it's inserted
3354         into the layer tree.
3355
3356 2009-07-13  Greg Bolsinga  <bolsinga@apple.com>
3357
3358         Reviewed by Simon Fraser.
3359
3360         Correct these delegate methods' declarations by adding parameter names.
3361
3362         * WebView/WebUIDelegatePrivate.h:
3363
3364 2009-07-13  Drew Wilson  <atwilson@google.com>
3365
3366         Reviewed by David Levin.
3367
3368         Add ENABLE(SHARED_WORKERS) flag and define SharedWorker APIs
3369         https://bugs.webkit.org/show_bug.cgi?id=26932
3370
3371         Added ENABLE(SHARED_WORKERS) flag (disabled by default).
3372
3373         * Configurations/FeatureDefines.xcconfig:
3374
3375 2009-07-12  Keishi Hattori  <casey.hattori@gmail.com>
3376
3377         Reviewed by Timothy Hatcher.
3378
3379         Refactor ConsoleMessage to add MessageType attribute.
3380         https://bugs.webkit.org/show_bug.cgi?id=20625
3381
3382         * WebCoreSupport/WebChromeClient.h:
3383         * WebCoreSupport/WebChromeClient.mm:
3384         (WebChromeClient::addMessageToConsole):
3385
3386 2009-07-11  Simon Fraser  <simon.fraser@apple.com>
3387
3388         Enable support for accelerated compositing and 3d transforms on Leopard.
3389         <https://bugs.webkit.org/show_bug.cgi?id=20166>
3390         <rdar://problem/6120614>
3391
3392         Reviewed by Oliver Hunt.
3393
3394         * Configurations/FeatureDefines.xcconfig:
3395
3396 2009-07-10  David Kilzer  <ddkilzer@apple.com>
3397
3398         Bug 27007: Build fixes when ICONDATABASE is disabled
3399
3400         <https://bugs.webkit.org/show_bug.cgi?id=27007>
3401
3402         Reviewed by Sam Weinig.
3403
3404         * Misc/WebIconDatabase.mm:
3405         (defaultClient): Return 0 if ICONDATABASE is disabled.
3406         * WebCoreSupport/WebFrameLoaderClient.mm:
3407         (WebFrameLoaderClient::dispatchDidReceiveIcon): Commented out
3408         the body of the method if ICONDATABASE is disabled.
3409         (WebFrameLoaderClient::registerForIconNotification): Ditto.
3410         * WebCoreSupport/WebIconDatabaseClient.mm: Added #if
3411         ENABLE(ICONDATABASE)/#endif guard to source.
3412         * WebView/WebView.mm:
3413         (-[WebView setFrameLoadDelegate:]): Wrapped code that starts the
3414         icon database machinery in #if ENABLE(ICONDATABASE)/#endif.
3415         (-[WebView _registerForIconNotification:]): Wrapped method in
3416         #if ENABLE(ICONDATABASE)/#endif guard.
3417         (-[WebView _dispatchDidReceiveIconFromWebFrame:]): Ditto.
3418         * WebView/WebViewInternal.h: Wrapped methods in #if
3419         ENABLE(ICONDATABASE)/#endif guard.
3420         (-[WebView _registerForIconNotification:]):
3421         (-[WebView _dispatchDidReceiveIconFromWebFrame:]):
3422
3423 2009-07-10  Simon Fraser  <simon.fraser@apple.com>
3424
3425         Reviewed by John Sullivan.
3426
3427         Flashing as hardware layers are created and destroyed in some content
3428         <rdar://problem/7032246>
3429         
3430         There's a window of time between the end of one runloop cycle, after CA layers changes
3431         have been committed, and the window display at the start of the next cycle when 
3432         CA may push updates to the screen before AppKit has drawn the view contents. If
3433         we know that we need to do drawing synchronization (which we do when content moves
3434         between a layer and the view), then we need to call -disableScreenUpdatesUntilFlush
3435         from the existing runloop observer that is set up when layers need repainting to
3436         ensure that layer updates don't reach the screen before view-based painting does.
3437
3438         * WebView/WebHTMLView.mm:
3439         (-[WebHTMLView drawRect:]):
3440         Tweak the comments
3441         
3442         * WebView/WebView.mm:
3443         (viewUpdateRunLoopObserverCallBack):
3444         (-[WebView _scheduleViewUpdate]):
3445         Add a big comment to explain the timing of things.
3446         Call -disableScreenUpdatesUntilFlush when the view _needsOneShotDrawingSynchronization.
3447
3448  2009-07-09  Brian Weinstein  <bweinstein@apple.com>
3449  
3450          Reviewed by Tim Hatcher.
3451 2009-07-10  Adam Barth  <abarth@webkit.org>
3452
3453         Reviewed by Sam Weinig with the power of Grayskull.
3454
3455         Enable XSSAuditor by default.
3456
3457         * WebView/WebPreferences.mm:
3458         (+[WebPreferences initialize]):
3459
3460 2009-07-10  Greg Bolsinga  <bolsinga@apple.com>
3461
3462         Reviewed by Antti Koivisto.
3463
3464         Add delegate methods about focus and blur and state change
3465         https://bugs.webkit.org/show_bug.cgi?id=27153
3466
3467         Call the appropriate private delegate methods from the ChromeClient.
3468         
3469         * WebCoreSupport/WebChromeClient.h:
3470         * WebCoreSupport/WebChromeClient.mm:
3471         (WebChromeClient::formStateDidChange):
3472         (WebChromeClient::formDidFocus):
3473         (WebChromeClient::formDidBlur):
3474         * WebView/WebUIDelegatePrivate.h:
3475
3476 2009-07-09  Brian Weinstein  <bweinstein@apple.com>
3477
3478         Reviewed by Tim Hatcher.
3479
3480         https://bugs.webkit.org/show_bug.cgi?id=27141
3481         
3482         Updated WebInspectorClient to use Web Inspector Preferences to remember whether or not it should be 
3483         docked or a free window instead of NSUserDefaults it used to have.
3484
3485         * WebCoreSupport/WebInspectorClient.mm:
3486         (-[WebInspectorWindowController init]):
3487         (-[WebInspectorWindowController showWindow:]):
3488         (-[WebInspectorWindowController attach]):
3489         (-[WebInspectorWindowController detach]):
3490
3491 2009-07-09  Drew Wilson  <atwilson@google.com>
3492
3493         Reviewed by Alexey Proskuryakov.
3494
3495         https://bugs.webkit.org/show_bug.cgi?id=26903
3496
3497         Turned on CHANNEL_MESSAGING by default because the MessageChannel API
3498         can now be implemented for Web Workers and is reasonably stable.
3499
3500         * Configurations/FeatureDefines.xcconfig:
3501
3502 2009-07-09  Darin Adler  <darin@apple.com>
3503
3504         Reviewed by Adele Peterson and Dan Bernstein.
3505
3506         <rdar://problem/7024972> Cannot set font to Helvetica Neue Light in Mail compose window
3507
3508         No regression test because this only affects the font panel.
3509
3510         * WebView/WebHTMLView.mm:
3511         (-[WebHTMLView _addToStyle:fontA:fontB:]): Fix code that detects whether the font would
3512         survive a round trip by using the weight corresponding to "bold" or "normal" rather than
3513         the actual weight number.
3514
3515 2009-07-09  Beth Dakin and Jon Honeycutt <bdakin@apple.com>
3516
3517         Reviewed by Dave Hyatt.
3518
3519         Make Widget RefCounted to fix:
3520
3521         <rdar://problem/7038831> REGRESSION (TOT): In Mail, a crash occurs 
3522         at WebCore::Widget::afterMouseDown() after clicking To Do's close 
3523         box
3524         <rdar://problem/6978804> WER #16: Repro Access Violation in 
3525         WebCore::PluginView::bindingInstance (1310178023)
3526         -and-
3527         <rdar://problem/6991251> WER #13: Crash in WebKit!
3528         WebCore::PluginView::performRequest+203 (1311461169) 
3529
3530         * WebCoreSupport/WebFrameLoaderClient.h:
3531         * WebCoreSupport/WebFrameLoaderClient.mm:
3532         (WebFrameLoaderClient::createPlugin):
3533
3534 2009-07-09  Sam Weinig  <sam@webkit.org>
3535
3536         Reviewed by Steve Falkenburg.
3537
3538         Roll out r43848. The quirk is no longer necessary.
3539
3540         * WebView/WebView.mm:
3541         (-[WebView WebCore::_userAgentForURL:WebCore::]):
3542
3543 2009-07-09  Alexey Proskuryakov  <ap@webkit.org>
3544
3545         Reviewed by Geoff Garen.
3546
3547         <rdar://problem/6921671> Visit count shouldn't be incremented by redirects.
3548
3549         * WebCoreSupport/WebFrameLoaderClient.mm: (WebFrameLoaderClient::updateGlobalHistory):
3550         Do not increase visit count if there is a redirect source. As a result, only pages that were
3551         explicitly visited by the user (by typing a URL, choosing one from bookmarks, or clicking
3552         a link) will be counted.
3553
3554         * History/WebHistory.mm:
3555         (-[WebHistoryPrivate visitedURL:withTitle:increaseVisitCount:]):
3556         (-[WebHistory _visitedURL:withTitle:method:wasFailure:increaseVisitCount:]):
3557         * History/WebHistoryInternal.h:
3558         * History/WebHistoryItem.mm:
3559         (-[WebHistoryItem _visitedWithTitle:increaseVisitCount:]):
3560         * History/WebHistoryItemInternal.h:
3561         Marshal this new argument all the way down to WebCore.
3562
3563 2009-07-08  Greg Bolsinga  <bolsinga@apple.com>
3564
3565         Reviewed by Darin Adler.
3566
3567         Add -[WebView _isProcessingUserGesture]
3568         https://bugs.webkit.org/show_bug.cgi?id=27084
3569
3570         Add -_isProcessingUserGesture that calls into WebCore::FrameLoader::isProcessingUserGesture()
3571         so that WebView code can determine if a user gesture is in progress.
3572
3573         * WebView/WebView.mm:
3574         (-[WebView _isProcessingUserGesture]):
3575         * WebView/WebViewPrivate.h:
3576
3577 2009-07-07  Anders Carlsson  <andersca@apple.com>
3578
3579         Reviewed by Sam Weinig.
3580
3581         - Fix <rdar://problem/6544693>.
3582         
3583         For Flash, don't cache which methods or fields in an object are missing, since they can
3584         be added at any time.
3585         
3586         * Plugins/Hosted/NetscapePluginHostManager.mm:
3587         (WebKit::NetscapePluginHostManager::hostForPackage):
3588         * Plugins/Hosted/NetscapePluginHostProxy.h:
3589         (WebKit::NetscapePluginHostProxy::shouldCacheMissingPropertiesAndMethods):
3590         * Plugins/Hosted/NetscapePluginHostProxy.mm:
3591         (WebKit::NetscapePluginHostProxy::NetscapePluginHostProxy):
3592         * Plugins/Hosted/ProxyInstance.mm:
3593         (WebKit::ProxyInstance::methodsNamed):
3594         (WebKit::ProxyInstance::fieldNamed):
3595
3596 2009-07-06  David Kilzer  <ddkilzer@apple.com>
3597
3598         Bug 27006: Build fix when MAC_JAVA_BRIDGE is disabled
3599
3600         <https://bugs.webkit.org/show_bug.cgi?id=27006>
3601
3602         Reviewed by Darin Adler.
3603
3604         * WebCoreSupport/WebFrameLoaderClient.mm:
3605         (WebFrameLoaderClient::createJavaAppletWidget): Wrap contents of
3606         the method in #if ENABLE(MAC_JAVA_BRIDGE)/#endif and return 0
3607         when this feature is disabled.
3608
3609 2009-07-06  David Kilzer  <ddkilzer@apple.com>