1 2005-05-17 Chris Blumenberg <cblu@apple.com>
3 Fixed: <rdar://problem/4119282> clicking a link in an RTF file opens the link with NSWorkspace without the usual security checks or WebView delegate control
7 * WebCoreSupport.subproj/WebBridge.m:
8 (-[WebBridge loadURL:referrer:reload:userGesture:target:triggeringEvent:form:formValues:]): pass the passed referrer to canLoadURL::: not [self referrer]
9 (-[WebBridge postWithURL:referrer:target:data:contentType:triggeringEvent:form:formValues:]): ditto
10 * WebView.subproj/WebTextView.m:
11 (-[WebTextView clickedOnLink:atIndex:]): call the loadURL bridge method so that security checks are made, command/option clicks work, policy delegate is consulted etc.
13 2005-05-17 Chris Blumenberg <cblu@apple.com>
15 Fixed: <rdar://problem/4120255> web archives on remote servers can be viewed directly (with major security issues); should download instead
19 * WebView.subproj/WebBaseResourceHandleDelegate.h:
20 * WebView.subproj/WebMainResourceClient.m:
21 (-[WebMainResourceClient continueAfterContentPolicy:response:]): if the WebKit client has chosen to "use" a remote web archive, stop the load with an error
23 2005-05-16 Darin Adler <darin@apple.com>
25 - attempt to get things building under "Saffron" development tools
27 * WebKit.pbproj/project.pbxproj: Use BUILT_PRODUCTS_DIR instead of SYMROOT.
29 2005-05-13 John Sullivan <sullivan@apple.com>
33 - fixed <rdar://problem/4093306> Safari crashes if Esc key is held down during series
34 of authentication sheets
36 * Panels.subproj/WebAuthenticationPanel.m:
37 (-[WebAuthenticationPanel cancel:]):
38 retain and autorelease self. This is a workaround for an AppKit key-handling issue, which I wrote up as:
39 <rdar://problem/4118422> Key-down events can be sent to a closed window if a key is kept pressed down
41 2005-05-12 John Sullivan <sullivan@apple.com>
45 - rolled in changes from experimental-ui-branch to support resizable textareas
46 and find-as-you-type and confirming unsubmitted form changes. The files/functions
47 modified are listed just below. After that are the ChangeLog comments from the branch.
49 * WebCoreSupport.subproj/WebBridge.m:
50 (-[WebBridge textDidChange:]):
51 * WebView.subproj/WebFormDelegate.h:
52 * WebView.subproj/WebFormDelegate.m:
53 (-[WebFormDelegate textDidChange:inFrame:]):
54 * WebView.subproj/WebHTMLView.m:
55 (-[WebHTMLView maintainsInactiveSelection]):
56 (-[WebHTMLView searchFor:direction:caseSensitive:wrap:]):
57 (-[WebHTMLView _searchFor:direction:caseSensitive:wrap:findInSelection:]):
58 * WebView.subproj/WebView.m:
59 (-[WebView _searchFor:direction:caseSensitive:wrap:findInSelection:]):
60 (-[WebView searchFor:direction:caseSensitive:wrap:]):
61 (-[WebView makeTextStandardSize:]):
62 (-[WebView maintainsInactiveSelection]):
63 * WebView.subproj/WebViewPrivate.h:
65 2005-04-18 John Sullivan <sullivan@apple.com>
67 WebKit support for notifying a form delegate when a
68 textarea's contents have changed (as opposed to a
69 textfield, which was already handled).
73 * WebView.subproj/WebFormDelegate.h:
74 * WebView.subproj/WebFormDelegate.m:
75 (-[WebFormDelegate textDidChange:inFrame:]):
76 new form delegate method
78 * WebCoreSupport.subproj/WebBridge.m:
79 (-[WebBridge textDidChange:]):
80 new method, calls through to form delegate
82 2005-04-11 John Sullivan <sullivan@apple.com>
84 Fixed inability to wrap around in Find in Page
86 * WebView.subproj/WebView.m:
87 (-[WebView _searchFor:direction:caseSensitive:wrap:findInSelection:]):
88 changed wrapFlag from NO to YES on two lines (copy/paste error)
90 2005-04-07 John Sullivan <sullivan@apple.com>
92 WebKit support for find-as-you-type. Needed an additional parameter on
93 a method from WebDocumentSearching protocol. Since that's a public protocol,
94 I couldn't just add the parameter. For now I hacked it with an undeclared
95 internal method that's discovered via respondsToSelector. Probably the right
96 long-term approach is to deprecate the WebDocumentSearching protocol and introduce
97 a replacement that has a more flexible set of parameters for possible future
100 Reviewed by Dave Hyatt.
102 * WebView.subproj/WebHTMLView.m:
103 (-[WebHTMLView searchFor:direction:caseSensitive:wrap:]):
104 now calls new one-more-parameter version passing NO for new parameter to match old behavior
105 (-[WebHTMLView _searchFor:direction:caseSensitive:wrap:findInSelection:]):
106 new method, adds findInSelection parameter and passes it through to bridge
108 * WebView.subproj/WebView.m:
109 (-[WebView searchFor:direction:caseSensitive:wrap:]):
110 now calls new one-more-parameter version passing NO for new parameter to match old behavior
111 (-[WebView _searchFor:direction:caseSensitive:wrap:findInSelection:]):
112 new method, adds findInSelection parameter and passes it through
114 2005-04-07 John Sullivan <sullivan@apple.com>
116 WebKit support to allow clients to control whether the selection is still
117 drawn when the first responder is elsewhere. Formerly this was hardwired
118 to be true only when -[WebView isEditable] was true.
122 * WebView.subproj/WebHTMLView.m:
123 (-[WebHTMLView maintainsInactiveSelection]):
124 check [WebView maintainsInactiveSelection] rather than just [WebView isEditable]
126 * WebView.subproj/WebViewPrivate.h:
127 * WebView.subproj/WebView.m:
128 (-[WebView maintainsInactiveSelection]):
129 new method for clients to override, returns -[self isEditable]
132 2005-05-10 John Sullivan <sullivan@apple.com>
136 - WebKit support for <rdar://problem/3795701> Menu item/keyboard shortcut to
137 restore text zoom to normal
139 * WebView.subproj/WebView.m:
140 (-[WebView validateUserInterfaceItem:]):
141 validate makeTextStandardSize by calling canMakeTextStandardSize
142 (-[WebView canMakeTextStandardSize]):
143 new method, returns YES unless text size multiplier is currently 1
144 (-[WebView makeTextStandardSize:]):
145 new method, sets text size multiplier to 1
147 * WebView.subproj/WebViewPrivate.h:
148 add makeTextStandardSize: and canMakeTextStandardSize to pending public category
150 2005-05-10 John Sullivan <sullivan@apple.com>
154 - fixed <rdar://problem/4067981> Mail places RTF flavor before RTFD flavor when dragging
155 mixed image/text content.
157 * WebView.subproj/WebHTMLView.m:
158 (+[WebHTMLView _selectionPasteboardTypes]):
159 put RTFD type before RTF type in array of types to declare
161 2005-05-09 Chris Blumenberg <cblu@apple.com>
163 Turned assertion into error message to prevent crash when encountering this bug:
164 <rdar://problem/4067625> connection:willCacheResponse: is called inside of [NSURLConnection initWithRequest:delegate:]
166 * WebView.subproj/WebBaseResourceHandleDelegate.h:
167 * WebView.subproj/WebBaseResourceHandleDelegate.m:
168 (-[WebBaseResourceHandleDelegate loadWithRequest:]): set flag to track when we're initializing the connection
169 (-[WebBaseResourceHandleDelegate connection:willCacheResponse:]): log error
171 2005-05-09 Darin Adler <darin@apple.com>
173 * Makefile.am: Don't set up PBXIntermediatesDirectory explicitly;
174 Not needed to make builds work, spews undesirable error messages too.
176 2005-05-06 Darin Adler <darin@apple.com>
180 - make building multiple trees with make work better
182 * Makefile.am: Set up Xcode build directory before invoking xcodebuild.
184 2005-05-04 Darin Adler <darin@apple.com>
186 Reviewed by Dave Hyatt.
190 * WebKit.pbproj/project.pbxproj: Set deployment target to 10.3 in the build styles.
191 When built without a build style (by Apple B&I) we want to get the target from the
192 environment. But when built with a build style (by Safari engineers and others), we want
193 to use 10.3. Because our deployment target was not set, we ran into this bug:
195 <rdar://problem/4108717> CTFontGetGlyphWithName doesn't work with some strings
197 * Makefile.am: Took out extra parameters that make command-line building different from
198 Xcode building. Now that this is fixed, you should not get a full rebuild if you switch
199 from command line to Xcode or back.
201 2005-05-04 Chris Blumenberg <cblu@apple.com>
204 <rdar://problem/4078417> REGRESSION (125-412): MLB gameday page doesn't update (Flash)
205 <rdar://problem/4072280> XMLHttpRequest calls onReadyStateChange callback with bogus status value
209 Our WebKit-level caching of subresources "dumbed-down" information held in NSURLResponse. This caused some loads to lack response headers and thus disabling cache directives. Status codes were also not retained and this caused XMLHttpRequest to fail frequently. The fix is to have WebResource retain the NSURLResponse and to use the NSURLResponse when we decide to load from WebResources.
211 * WebCoreSupport.subproj/WebBridge.m:
212 (-[WebBridge objectLoadedFromCacheWithURL:response:data:]): call new [WebResource _initWithData:URL:response:]
213 * WebView.subproj/WebBaseResourceHandleDelegate.m:
214 (-[WebBaseResourceHandleDelegate _canUseResourceWithResponse:]): new, checks response cache directives
215 (-[WebBaseResourceHandleDelegate loadWithRequest:]): call _canUseResourceWithResponse:
216 (-[WebBaseResourceHandleDelegate saveResource]): call new [WebResource _initWithData:URL:response:]
217 * WebView.subproj/WebResource.m:
218 (-[WebResourcePrivate dealloc]):
219 (-[WebResource initWithData:URL:MIMEType:textEncodingName:frameName:]): call renamed _initWithData:URL:MIMEType:textEncodingName:frameName:response:copyData:
220 (-[WebResource initWithCoder:]): decode the NSURLReponse
221 (-[WebResource encodeWithCoder:]): encode the NSURLReponse
222 (-[WebResource _initWithData:URL:MIMEType:textEncodingName:frameName:response:copyData:]): take the NSURLReponse
223 (-[WebResource _initWithData:URL:response:]): new
224 (-[WebResource _initWithPropertyList:]): decode the NSURLReponse
225 (-[WebResource _propertyListRepresentation]): encode the NSURLReponse
226 (-[WebResource _response]): return ivar if we have one
227 * WebView.subproj/WebResourcePrivate.h:
229 2005-05-03 David Hyatt <hyatt@apple.com>
231 Fix object element support so that fallback content works. With this change Safari passes the Acid2 test.
235 * WebCoreSupport.subproj/WebBridge.m:
236 (-[WebBridge determineObjectFromMIMEType:URL:]):
237 * WebView.subproj/WebDataSource.m:
238 (-[WebDataSource _receivedMainResourceError:complete:]):
239 * WebView.subproj/WebMainResourceClient.m:
240 (-[WebMainResourceClient continueAfterContentPolicy:response:]):
242 2005-05-03 Darin Adler <darin@apple.com>
244 * WebView.subproj/WebUIDelegate.h: Fixed incorrect comment.
247 2005-05-01 Darin Adler <darin@apple.com>
249 - move to Xcode native targets and stop checking in generated files
251 * WebKit.pbproj/project.pbxproj: Updated to use native targets and generate all the generated
252 files, so we don't have to check them in any more.
253 * Info.plist: Added. Native targets use a separate file for this.
255 * Plugins.subproj/npapi.m: Fixed import statement to get npapi.h from <WebKit/> rather than current directory.
257 * Makefile.am: Removed timestamp cleaning rules since we don't use it any more.
259 * .cvsignore: Removed various timestamp files.
261 * DOM.subproj/DOM-compat.h: Removed.
262 * DOM.subproj/DOM.h: Removed.
263 * DOM.subproj/DOMCSS.h: Removed.
264 * DOM.subproj/DOMCore.h: Removed.
265 * DOM.subproj/DOMEvents.h: Removed.
266 * DOM.subproj/DOMExtensions.h: Removed.
267 * DOM.subproj/DOMHTML.h: Removed.
268 * DOM.subproj/DOMPrivate.h: Removed.
269 * DOM.subproj/DOMRange.h: Removed.
270 * DOM.subproj/DOMStylesheets.h: Removed.
271 * DOM.subproj/DOMTraversal.h: Removed.
272 * DOM.subproj/DOMViews.h: Removed.
273 * Plugins.subproj/WebScriptObject.h: Removed.
274 * Plugins.subproj/npapi.h: Removed.
275 * Plugins.subproj/npruntime.h: Removed.
276 * copy-webcore-files-to-webkit: Removed.
277 * embed-frameworks.sh: Removed.
278 * force-clean-timestamp: Removed.
280 2005-04-28 Darin Adler <darin@apple.com>
284 - fixed problems preventing us from compiling with gcc 4.0
286 * WebKit.pbproj/project.pbxproj: Removed -fobjc-exceptions because I can't figure out an easy
287 way to pass it only when compiling Objective-C/C++. Removed -Wmissing-prototypes from
288 WARNING_CPLUSPLUSFLAGS since it's now a C-only warning.
290 * History.subproj/WebHistoryItem.m: (-[WebHistoryItem pageCache]): Changed return type
291 to match the declaration.
292 * WebCoreSupport.subproj/WebBridge.m: (-[WebBridge _retrieveKeyboardUIModeFromPreferences:]):
293 Fixed a BOOL that should have been a Boolean.
294 * WebCoreSupport.subproj/WebTextRenderer.m: Removed redundant copy of ROUND_TO_INT, also in
296 (-[WebTextRenderer _computeWidthForSpace]): Had to add cast because of difference in type of
297 ROUND_TO_INT vs. CEIL_TO_INT.
298 (pathFromFont): Added a cast to convert UInt8 * to char *.
299 * WebView.subproj/WebFrameView.m:
300 (-[WebFrameView _setDocumentView:]): Fixed parameter type to match the declaration.
301 (-[WebFrameView documentView]): Fixed return type to match the declaration.
302 * WebView.subproj/WebHTMLView.m:
303 (-[WebHTMLView _startDraggingImage:at:operation:event:sourceIsDHTML:DHTMLWroteData:]):
304 Initialized a variable to quiet an incorrect gcc 4.0 uninitialized variable warning.
305 (-[WebHTMLView deleteToMark:]): Switched from @try style to NS_DURING style of exception handler
306 because we can't pass -fobjc-exceptions just to Objective-C at the moment (see above).
307 (-[WebHTMLView selectToMark:]): Ditto.
308 (-[WebHTMLView swapWithMark:]): Ditto.
310 2005-04-27 John Sullivan <sullivan@apple.com>
312 Reviewed by Dave Harrison.
314 - fixed <rdar://problem/3547489> pop-up window blocking preference and
315 menu item can easily get out of sync.
317 * WebView.subproj/WebPreferences.m:
318 (-[WebPreferences _setStringValue:forKey:]):
319 save local value before setting value in NSUserDefaults, so clients reacting to NSUserDefaults
320 change notification but calling back on WebPreferences API will see the updated value.
321 (-[WebPreferences _setIntegerValue:forKey:]):
323 (-[WebPreferences _setBoolValue:forKey:]):
326 2005-04-26 Richard Williamson <rjw@apple.com>
328 Fixed <rdar://problem/4098713> Scripting API is incompatible with Mozilla
332 * Plugins.subproj/npfunctions.h:
333 * Plugins.subproj/npruntime.h:
335 2005-04-26 Darin Adler <darin@apple.com>
339 - fixed <rdar://problem/3655817> please add support for mouse wheel events and the onmousewheel handler
341 * WebView.subproj/WebHTMLView.m: (-[WebHTMLView scrollWheel:]): Call sendScrollWheelEvent: method
342 instead of the old scrollOverflowWithScrollWheelEvent: (just a name change).
344 2005-04-18 Darin Adler <darin@apple.com>
348 - fixed <rdar://problem/4092614> REGRESSION (Tiger): progressively loaded background images "scroll around" instead of just appearing
350 * WebCoreSupport.subproj/WebImageData.m:
351 (-[WebImageData _imageSourceOptions]): Moved a global inside this function, since it's only used here.
352 (-[WebImageData _cacheImages:allImages:]): Fixed a sizeof that was getting the size of the wrong thing.
353 (-[WebImageData _isSizeAvailable]): Used calloc in a more consistent way.
354 (drawPattern): Removed an unneeded cast.
355 (-[WebImageData tileInRect:fromPoint:context:]): Here's the actual bug fix. Don't use the image size
356 when deciding whether the image needs to be tiled as a pattern nor when creating the pattern: in both
357 cases, use the tile size. The old way was wrong, and the new way works perfectly. Also removed uneeded
358 error message when the image is not yet loaded enough to create a CGImageRef for it -- it's fine to
359 draw nothing in that case.
361 2005-04-14 John Sullivan <sullivan@apple.com>
365 * WebView.subproj/WebBaseResourceHandleDelegate.m:
366 (-[WebBaseResourceHandleDelegate connection:willCacheResponse:]):
367 Beefed up assertion that's been bugging me and Chris to include
368 the two troublemaking values.
370 2005-04-05 David Hyatt <hyatt@apple.com>
372 Fix for 4077106, wheel scroll amount smaller in Tiger. All along wheeling should have been 4x the default
373 line height of 10 (just as arrow keys did). Scroll arrows should have done this too for scroll views (they did
374 already for overflow sections). This patch puts the override into the scrollview itself, and removes the
375 multipliers in the private frame methods.
379 * WebView.subproj/WebFrameView.m:
380 (-[WebFrameView _verticalKeyboardScrollDistance]):
381 (-[WebFrameView initWithFrame:]):
382 (-[WebFrameView _horizontalKeyboardScrollDistance]):
386 2005-03-31 Chris Blumenberg <cblu@apple.com>
388 Fixed: <rdar://problem/4070729> REGRESSION (125-311, Panther-only?): Safari crashes while reloading "My eBay" page
392 * WebView.subproj/WebBaseResourceHandleDelegate.m:
393 (-[WebBaseResourceHandleDelegate resourceData]): retain and autorelease resourceData since releaseResources (which releases resourceData) may be called before the caller of this method has an opporuntity to retain the returned data
399 2005-03-23 Richard Williamson <rjw@apple.com>
401 Use Patti Yeh's hack to determine the appropriate rectangle
402 to place the "associated word" window.
403 If there is no marked text firstRectForCharacterRange: will
404 use the selected range to determine the returned rectangle,
405 ignoring the input range. This is the fix from
406 4029491 that I previously backed out.
410 * WebView.subproj/WebHTMLView.m:
411 (-[WebHTMLView firstRectForCharacterRange:]):
413 2005-03-23 Richard Williamson <rjw@apple.com>
415 Fixed <rdar://problem/4062490> REGRESSION (WebKit-408): no subresources reported in Activity window after going back at hrweb.apple.com
417 Stop collecting subresource responses after the document
418 had loaded, not after it has been opened.
422 * WebView.subproj/WebFrame.m:
423 (-[WebFrame _setState:]):
424 (-[WebFrame _opened]):
426 2005-03-21 Maciej Stachowiak <mjs@apple.com>
430 <rdar://problem/4051145> The QuickTime Cocoa plug-in needs an SPI that it can call to check for URL policy
432 * Plugins.subproj/WebPluginContainerCheck.h: Added.
433 * Plugins.subproj/WebPluginContainerCheck.m: Added this new helper class to encapsulate
434 an async plugin navigation check.
435 (+[WebPluginContainerCheck checkWithRequest:target:resultObject:selector:controller:]): Convenience allocator that gives autoreleased value.
436 (-[WebPluginContainerCheck initWithRequest:target:resultObject:selector:controller:]): Initializer.
437 (-[WebPluginContainerCheck finalize]): Just assert that we're done, it would
438 be bad to deallocate this object while request is still outstanding.
439 (-[WebPluginContainerCheck dealloc]): Ditto.
440 (-[WebPluginContainerCheck _continueWithPolicy:]): Method to continue after async
442 (-[WebPluginContainerCheck _isDisallowedFileLoad]): Do "file: URL from remote content"
444 (-[WebPluginContainerCheck _actionInformationWithURL:]): Helper to make action
446 (-[WebPluginContainerCheck _askPolicyDelegate]): Call policy delegate to let
447 the app decide if this load is allowed.
448 (-[WebPluginContainerCheck start]): Start the check.
449 (-[WebPluginContainerCheck cancel]): Cancel a check in progress.
450 * Plugins.subproj/WebPluginController.h:
451 * Plugins.subproj/WebPluginController.m:
452 (-[WebPluginController initWithDocumentView:]): Initialize new _checksInProgress field.
453 (-[WebPluginController _webPluginContainerCancelCheckIfAllowedToLoadRequest:]): Implement
455 (-[WebPluginController _cancelOutstandingChecks]): New helper to make sure to cancel
456 all outstanding requests when destroying all plugins.
457 (-[WebPluginController destroyAllPlugins]): Call above helper.
458 (-[WebPluginController _webPluginContainerCheckIfAllowedToLoadRequest:inFrame:resultObject:selector:]): Implement this new plug-in SPI method.
459 (-[WebPluginController bridge]): New helper method.
460 (-[WebPluginController webView]): New helper method.
461 * WebView.subproj/WebPolicyDelegatePrivate.h: Add new navigation
462 type WebNavigationTypePlugInRequest.
463 * WebKit.pbproj/project.pbxproj: Add new files.
464 * WebView.subproj/WebDefaultPolicyDelegate.m:
465 (-[WebDefaultPolicyDelegate webView:decidePolicyForNavigationAction:request:frame:decisionListener:]): Don't open externally on a plug-in request.
467 2005-03-23 Richard Williamson <rjw@apple.com>
469 Fixed <rdar://problem/4053515> REGRESSION (Mail): Kotoeri input method reconversion does not work in WebViews
471 We now use actual document NSRanges to represent both marked text
472 ranges and selection ranges.
474 Reviewed by Ken Kocienda.
476 * WebView.subproj/WebHTMLView.m:
477 (-[WebHTMLView validAttributesForMarkedText]):
478 (-[WebHTMLView firstRectForCharacterRange:]):
479 (-[WebHTMLView selectedRange]):
480 (-[WebHTMLView markedRange]):
481 (-[WebHTMLView _selectMarkedText]):
482 (-[WebHTMLView setMarkedText:selectedRange:]):
486 2005-03-22 Darin Adler <darin@apple.com>
488 * English.lproj/StringsNotToBeLocalized.txt: Updated for recent changes.
492 2005-03-20 Maciej Stachowiak <mjs@apple.com>
496 <rdar://problem/4060020> Add stub version of security SPI for QuickTime plug-in so QuickTime team has something to compile and link against
498 * Plugins.subproj/WebPluginContainerPrivate.h: Added.
499 * Plugins.subproj/WebPluginController.m:
500 (-[WebPluginController _webPluginContainerCheckIfAllowedToLoadRequest:inFrame:resultObject:selector:]):
501 (-[WebPluginController _webPluginContainerCancelCheckIfAllowedToLoadRequest:]):
502 * WebKit.pbproj/project.pbxproj:
504 2005-03-19 David Harrison <harrison@apple.com>
508 <rdar://problem/4059479> Misspelling underline does underline the whole word, could go farther to the right
510 * WebCoreSupport.subproj/WebTextRenderer.m:
511 (-[WebTextRenderer misspellingLinePatternGapWidth]):
512 (-[WebTextRenderer drawLineForMisspelling:withWidth:]):
513 Consider that the last pixel in the underline dot pattern is transparent.
515 2005-03-19 Darin Adler <darin@apple.com>
517 Reviewed by Maciej (a while back).
519 - fixed <rdar://problem/4059323> local-file security check is allowing plug-in streams, but must not
521 * Plugins.subproj/WebNetscapePluginStream.m:
522 (-[WebNetscapePluginStream initWithRequest:pluginPointer:notifyData:sendNotification:]):
523 Roll out change I made on 3-13. That change is needed for subresource, but not for plug-in streams.
524 For plug-in streams it's too risky, and leaves a serious security hole open.
526 2005-03-19 Darin Adler <darin@apple.com>
528 Reviewed by Ken and John.
530 - fixed <rdar://problem/4059123> REGRESSION (402-403): deleteWordForward: and deleteWordBackward: start deleting single characters after the first delete
532 * WebView.subproj/WebHTMLView.m: (-[WebHTMLView _deleteWithDirection:granularity:killRing:isTypingAction:]):
533 Fixed backwards logic in here and added missing check. Set action to one of the two typing actions only
534 if isTypingAction is YES.
536 2005-03-19 David Harrison <harrison@apple.com>
538 Reviewed by me (written by Patti Yeh).
540 <rdar://problem/4029491> <TCIM> CangJie: the candidate window appears at the top left hand corner during typing in Mail and iChat
542 * WebView.subproj/WebHTMLView.m:
543 (-[WebHTMLView firstRectForCharacterRange:]):
544 Use selected range if there is no marked range.
548 2005-03-18 David Harrison <harrison@apple.com>
552 <rdar://problem/3584942> AX: Safari Accessibility parent-child mismatch
554 * WebView.subproj/WebFrameView.m:
555 (-[WebFrameView webCoreBridge]):
556 New to conform to WebCoreBridgeHolder protocol.
558 2005-03-18 Richard Williamson <rjw@apple.com>
560 Fixed <rdar://problem/4057004> Data from XMLHTTPRequest is never dealloced
562 WebDataSource keeps an array of all the NSURLResponses associated
563 with the load for a page. This is used to playback delegate messages
564 when loading from the page cache. However, after the document
565 has completed it's initial load, we continue to keep track of responses.
566 So, this has the consequence of keeping all the responses for a page
567 around for the life of the page. NSURLResponses are now very
568 heavy. They indirectly reference the resource data (via the
569 download assessment dictionary). This fix will keep
570 references to responses around for those resources loaded during initial
571 page load, but not after that point.
575 * WebView.subproj/WebDataSource.m:
576 (-[WebDataSource _addResponse:]):
577 (-[WebDataSource _stopRecordingResponses]):
578 * WebView.subproj/WebDataSourcePrivate.h:
579 * WebView.subproj/WebFrame.m:
580 (-[WebFrame _opened]):
582 2005-03-18 Ken Kocienda <kocienda@apple.com>
588 <rdar://problem/4053729> Copy/paste of page with frames into Blot or Mail does nothing and loses insertion point
590 * WebView.subproj/WebHTMLView.m:
591 (-[WebHTMLView _selectedArchive]): Wrap frameset documents in an iframe, so they can be pasted into
592 existing documents which will have a body or frameset of their own.
596 2005-03-17 Richard Williamson <rjw@apple.com>
598 Fixed <rdar://problem/4055562> REGRESSION (Tiger): Safari doesn't draw progressively-loaded JPEGs (www.theregister.co.uk, www.titantalk.com)
600 Anothe side effect of lazy loading of image meta data. We now
601 don't cache image size until size meta data is actually available.
605 * WebCoreSupport.subproj/WebImageData.m:
606 (-[WebImageData size]):
608 2005-03-16 David Harrison <harrison@apple.com>
612 <rdar://problem/4048506> Deleting from beginning of editable div deletes other document elements
614 Also changed WebCore.
616 * WebView.subproj/WebHTMLView.m:
617 (-[WebHTMLView _shouldDeleteRange:]):
618 Added call to new bridge method canDeleteRange.
620 2005-03-16 Ken Kocienda <kocienda@apple.com>
626 <rdar://problem/4042935> undo doesn't work properly during inline input
628 * WebView.subproj/WebHTMLView.m:
629 (-[WebHTMLView setMarkedText:selectedRange:]): Call new -[WebCoreBridge replaceMarkedTextWithText:] instead of
630 -[WebCoreBridge replaceSelectionWithText:selectReplacement:smartReplace:]. The former call was just added in
631 order to provide a better mapping of international text input onto the typing command/undo design.
633 2005-03-15 Richard Williamson <rjw@apple.com>
635 Fixed <rdar://problem/4040321> Exception: Someone's trying to encode a WebDataRequestParameters instance
637 If client mutates request use new Foundation SPI to address remove applewebdata properties from request.
639 Reviewed by Ken Kocienda.
641 * WebView.subproj/WebBaseResourceHandleDelegate.m:
642 (-[WebBaseResourceHandleDelegate willSendRequest:redirectResponse:]):
643 * WebView.subproj/WebDataProtocol.h:
644 * WebView.subproj/WebDataProtocol.m:
645 (+[NSURLRequest _webDataRequestPropertyKey]):
647 2005-03-15 Ken Kocienda <kocienda@apple.com>
653 <rdar://problem/4052642> Each delete keystroke is in its own undo group; not included in undo group with other typing
655 Calling -[WebCore setSelectedDOMRange:range affinity:] had the result of "closing" any active set of typing
656 keystrokes grouped together in a single undo operation. My change on 27 Jan to route delete keystrokes
657 through _deleteRange:killRing:... made this feature regress. Previous to that change, the backwards delete
658 key went through separate code that is no longer in the tree that did not set the selection in the way
661 The solution is to add an extra argument to the set-selection call. The WebCoreBridge now offers this method:
662 -[WebCore setSelectedDOMRange:range affinity:closeTyping:]. Now, callers must indicate whether setting the
663 selection will act to close typing or not. The code changes below all add this new argument with the
664 appropriate value for closeTyping.
666 * WebView.subproj/WebHTMLView.m:
667 (-[WebHTMLView _deleteRange:killRing:prepend:smartDeleteOK:deletionAction:]): Passes NO for closeTyping when
668 deletionAction is deleteKeyAction or forwardDeleteKeyAction; YES when deleteSelectionAction.
669 (-[WebHTMLView _expandSelectionToGranularity:]): Passes YES for closeTyping.
670 (-[WebHTMLView selectToMark:]): Passes YES for closeTyping.
671 (-[WebHTMLView swapWithMark:]): Passes YES for closeTyping.
672 (-[WebHTMLView transpose:]): Passes YES for closeTyping.
673 (-[WebHTMLView _selectMarkedText]): Passes NO for closeTyping.
674 (-[WebHTMLView _selectRangeInMarkedText:]): Passes NO for closeTyping.
675 * WebView.subproj/WebView.m:
676 (-[WebView setSelectedDOMRange:affinity:]): Passes YES for closeTyping.
678 2005-03-14 Richard Williamson <rjw@apple.com>
680 Fix <rdar://problem/4051389> 8A413: gifs animating too fast
684 Match Mozilla's policy for minimum frame duration, which is somewhat odd:
686 <= 0.01 sec use .1 sec, otherwise use specified duration.
688 * WebCoreSupport.subproj/WebImageData.m:
689 (-[WebImageData _frameDurationAt:]):
691 2005-03-14 Darin Adler <darin@apple.com>
693 Reviewed by Harrison.
695 - fixed <rdar://problem/4049776> Seed: Mail: Disable spellcheck leaves red artifacts
697 * WebView.subproj/WebFrameInternal.h: Added _unmarkAllMisspellings.
698 * WebView.subproj/WebFrame.m: (-[WebFrame _unmarkAllMisspellings]): Added.
699 Calls unmarkAllMisspellings on the bridge and self and all subframes.
701 * WebView.subproj/WebView.m: (-[WebView setContinuousSpellCheckingEnabled:]):
702 Call _unmarkAllMisspellings on the main frame when turning continuous spell checking off.
704 2005-03-14 Richard Williamson <rjw@apple.com>
706 Fixed <rdar://problem/4027928> Tiger_8A394:Acrobat crashes while tried to remove the subscription errors by clicking on "Would you like to remove the subscription" from Tracker details view pane
708 The Acrobat application triggers loads of new documents in it's policy delegate. This
709 ultimately causes the WebHTMLView to be released before their event handlers have
710 returned. To bullet proof against this case we retain/release self before passing
711 the event on for further handling.
715 * WebView.subproj/WebHTMLView.m:
716 (-[WebHTMLView _updateMouseoverWithEvent:]):
717 (-[WebHTMLView scrollWheel:]):
718 (-[WebHTMLView mouseDown:]):
719 (-[WebHTMLView mouseDragged:]):
720 (-[WebHTMLView mouseUp:]):
721 (-[WebHTMLView keyDown:]):
722 (-[WebHTMLView keyUp:]):
723 (-[WebHTMLView performKeyEquivalent:]):
725 2005-03-14 Vicki Murley <vicki@apple.com>
727 - roll out the fix for 4040321, since it is still pending CCC review.
729 2005-03-10 Richard Williamson <rjw@apple.com>
731 Fixed <rdar://problem/4040321> Exception: Someone's trying to encode a WebDataRequestParameters instance
735 If a delegate returns a mutated applewebdata: request in it's willSendRequest:
736 method, we don't load using the WebDataRequest. Instead we do a normal load.
737 Unfortunately, if the request they return is mutated *copy* of the applewebdata:
738 request it will hold the applewebdata: special properties. These properties
739 will be encoded into the cache. They should not be. So, to fix, we sanitize the
740 request, by removing the special properties from the request.
742 Note that we had to dig into the private guts of NSURLRequest because there is
743 no public mechanism to remove properties from a request, see 4046775.
745 * WebView.subproj/WebBaseResourceHandleDelegate.m:
746 (-[WebBaseResourceHandleDelegate willSendRequest:redirectResponse:]):
747 * WebView.subproj/WebDataProtocol.h:
748 * WebView.subproj/WebDataProtocol.m:
749 (-[NSURLRequest _webDataRequestExternalRequest]):
750 (-[NSURLRequest _webDataRequestSanitize]):
754 2005-03-13 Darin Adler <darin@apple.com>
756 Reviewed by Ken and Maciej.
758 - fixed <rdar://problem/4049040> REGRESSION (403-405): security check prevents user stylesheet from loading (Dictionary.app doesn't work at all!)
760 * Plugins.subproj/WebNetscapePluginStream.m: (-[WebNetscapePluginStream initWithRequest:pluginPointer:notifyData:sendNotification:]):
761 Allow plug-in subresource streams to load with any URL, ignoring the "canLoadURL" method's restriction (only
762 file URLs can load other file URLs), which now applies only to main resources, like web pages in frames or
763 object tags and plug-in main resources.
765 * WebCoreSupport.subproj/WebBridge.m:
766 (-[WebBridge startLoadingResource:withURL:customHeaders:]): Allow subresources to load with any URL, as above.
767 This allows things like images, stylesheets, and JavaScript to be loaded without the "canLoadURL" method's
769 (-[WebBridge startLoadingResource:withURL:customHeaders:postData:]): Ditto.
770 (-[WebBridge syncLoadResourceWithURL:customHeaders:postData:finalURL:responseHeaders:statusCode:]): Ditto.
772 2005-03-10 Richard Williamson <rjw@apple.com>
774 Fixed <rdar://problem/4040321> Exception: Someone's trying to encode a WebDataRequestParameters instance
778 If a delegate returns a mutated applewebdata: request in it's willSendRequest:
779 method, we don't load using the WebDataRequest. Instead we do a normal load.
780 Unfortunately, if the request they return is mutated *copy* of the applewebdata:
781 request it will hold the applewebdata: special properties. These properties
782 will be encoded into the cache. They should not be. So, to fix, we sanitize the
783 request, by removing the special properties from the request.
785 Note that we had to dig into the private guts of NSURLRequest because there is
786 no public mechanism to remove properties from a request, see 4046775.
788 * WebView.subproj/WebBaseResourceHandleDelegate.m:
789 (-[WebBaseResourceHandleDelegate willSendRequest:redirectResponse:]):
790 * WebView.subproj/WebDataProtocol.h:
791 * WebView.subproj/WebDataProtocol.m:
792 (-[NSURLRequest _webDataRequestExternalRequest]):
793 (-[NSURLRequest _webDataRequestSanitize]):
797 2005-03-10 Maciej Stachowiak <mjs@apple.com>
801 <rdar://problem/4046510> REGRESSION (TOT): All Flash and Shockwave plugin-based web content missing
803 * Plugins.subproj/WebNetscapePluginStream.m:
804 (-[WebNetscapePluginStream initWithRequest:pluginPointer:notifyData:sendNotification:]):
806 2005-03-10 John Sullivan <sullivan@apple.com>
810 - fixed <rdar://problem/4045843> Going back/forward to error page
811 hits assertion in -[WebDataSource(WebPrivate) _setData:]
813 * WebView.subproj/WebDataSource.m:
814 (-[WebDataSource _setData:]):
815 Removed bogus assertion
817 2005-03-09 Deborah Goldsmith <goldsmit@apple.com>
821 - fixed <rdar://problem/3997044> default encoding for non-Latin incorrect
823 * WebKit/WebView.subproj/WebPreferences.m: (+[WebPreferences _systemCFStringEncoding]):
824 Call __CFStringGetUserDefaultEncoding to get region, and TECGetWebTextEncodings to get
825 the first encoding to determine the default encoding.
827 2005-03-09 Darin Adler <darin@apple.com>
831 - fixed <rdar://problem/4034175> REGRESSION (Mail): Can't use any font with style Light/Condensed/Semibold/Extrabold, etc
833 * WebView.subproj/WebHTMLView.m:
834 (-[WebHTMLView _styleFromFontAttributes:]): Use a constant instead of hard-coded weight for clarity.
835 (-[WebHTMLView _originalFontA]): Ditto.
836 (-[WebHTMLView _originalFontB]): Ditto.
837 (-[WebHTMLView _addToStyle:fontA:fontB:]): Add code to detect the case where the family name is not good enough
838 to specify the font precisely. In that case, use the Postscript font name instead. Also change variable names
839 so it's easier to understand the method.
841 2005-03-06 Maciej Stachowiak <mjs@apple.com>
845 <rdar://problem/4005575> Arbitrary file disclosure vulnerability due to ability to load local html from remote content
847 * Plugins.subproj/WebBaseNetscapePluginView.m:
848 (-[WebBaseNetscapePluginView requestWithURLCString:]):
849 * Plugins.subproj/WebNetscapePluginEmbeddedView.m:
850 (-[WebNetscapePluginEmbeddedView didStart]):
851 * Plugins.subproj/WebNetscapePluginStream.m:
852 (-[WebNetscapePluginStream initWithRequest:pluginPointer:notifyData:sendNotification:]):
853 * WebCoreSupport.subproj/WebBridge.m:
854 (-[WebBridge createWindowWithURL:frameName:]):
855 (-[WebBridge startLoadingResource:withURL:customHeaders:]):
856 (-[WebBridge startLoadingResource:withURL:customHeaders:postData:]):
857 (-[WebBridge syncLoadResourceWithURL:customHeaders:postData:finalURL:responseHeaders:statusCode:]):
858 (-[WebBridge loadURL:referrer:reload:userGesture:target:triggeringEvent:form:formValues:]):
859 (-[WebBridge postWithURL:referrer:target:data:contentType:triggeringEvent:form:formValues:]):
860 (-[WebBridge createChildFrameNamed:withURL:referrer:renderPart:allowsScrolling:marginWidth:marginHeight:]):
861 (-[WebBridge viewForPluginWithURL:attributeNames:attributeValues:MIMEType:]):
862 * WebView.subproj/WebFrame.m:
863 (-[WebFrame _loadURL:referrer:intoChild:]):
864 * WebView.subproj/WebFramePrivate.h:
866 2005-03-09 Richard Williamson <rjw@apple.com>
868 Fixed <rdar://problem/4032938> Safari: text layout for MS P Gothic font is corrupted
870 The AppKit and ATS reports that MS P Gothic is fixed pitch. It is
871 not! This is another case of "fixed pitch" being wrong. I've
872 coalesced all the special cases into our isFontFixedPitch:, and
873 used a dictionary to improve speed. No performance regression.
877 * WebCoreSupport.subproj/WebTextRenderer.m:
878 (-[WebTextRenderer _computeWidthForSpace]):
879 * WebCoreSupport.subproj/WebTextRendererFactory.m:
880 (-[WebTextRendererFactory clearCaches]):
881 (-[WebTextRendererFactory isFontFixedPitch:]):
883 2005-03-09 Darin Adler <darin@apple.com>
887 <rdar://problem/4040388> REGRESSION (172-173): nonrepro crash in -[NSString(WebNSURLExtras) _web_isUserVisibleURL]
889 * Misc.subproj/WebNSURLExtras.m:
890 (-[NSString _web_isUserVisibleURL]): Fixed some pointer expressions that didn't include the index in the expression.
891 (readIDNScriptWhiteListFile): Removed NSLog statements in here since we decided they aren't useful and they will
892 write some messages on Tiger.
894 2005-03-09 Darin Adler <darin@apple.com>
896 * DOM.subproj/DOMPrivate.h: Checked in file copied from WebCore.
898 2005-03-08 Richard Williamson <rjw@apple.com>
900 Fixed <rdar://problem/4036949> many JPEG images fail to incremental-load due to change in ImageIO JPEG header parsing (to be fixed in WebKit)
901 Fixed <rdar://problem/4042570> Need to check image properties for presence of width/height properties
903 ImageIO-55 changed how image properties are created. They
904 are now created incrementally. So we need "re-get" the image
905 properties if the properties we care about (width/height) aren't
906 in the property dictionary.
910 * WebCoreSupport.subproj/WebImageData.h:
911 * WebCoreSupport.subproj/WebImageData.m:
912 (-[WebImageData init]):
913 (-[WebImageData fileProperties]):
914 (-[WebImageData propertiesAtIndex:]):
915 (-[WebImageData _isSizeAvailable]):
916 (-[WebImageData incrementalLoadWithBytes:length:complete:callback:]):
917 (-[WebImageData size]):
919 2005-03-08 John Sullivan <sullivan@apple.com>
921 A couple of tweaks to the previous patch, from Darin's review.
923 * Misc.subproj/WebNSPasteboardExtras.m:
924 (_writableTypesForImageWithoutArchive):
925 remove unnecessary _web prefix
926 (_writableTypesForImageWithArchive):
928 (+[NSPasteboard _web_writableTypesForImageIncludingArchive:]):
929 use mutableCopy rather than initWithArray:, and adjust for name changes
931 2005-03-08 John Sullivan <sullivan@apple.com>
935 - fixed <rdar://problem/4031826> REGRESSION (Mail): standalone images from
936 Safari can't be pasted into Mail (WebKit part of fix)
938 We were always declaring webarchive-related pasteboard types, even in the standalone
939 image cases where we had no webarchive. Unfortunately, the WebView pasteboard-related
940 API doesn't prevent this kind of thing from happening, because the code that
941 declares the types isn't guaranteed to be anywhere near the code that writes
944 After this fix, I discovered that pasting standalone images into Mail still doesn't
945 work right, but the remaining issues seem to be entirely in Mail. I wrote up 4041671
948 * Misc.subproj/WebNSPasteboardExtras.h:
949 (+[NSPasteboard _web_writableTypesForImageIncludingArchive:]):
950 Added boolean parameter; clients must specify whether or not there's an
951 archive involved, because the array of types is different if there is.
953 * Misc.subproj/WebNSPasteboardExtras.m:
954 (_web_writableTypesForImageWithoutArchive):
955 new static function, constructs (once) and returns the array of types
956 for images that don't have archives
957 (_web_writableTypesForImageWithArchive):
958 new static function, constructs (once) and returns the array of types
959 for images that do have archives
960 (+[NSPasteboard _web_writableTypesForImageIncludingArchive:]):
961 added boolean parameter, now calls one of the two new static functions
963 (-[NSPasteboard _web_writeImage:URL:title:archive:types:]):
964 added asserts that we aren't declaring the archive types if we don't have archive data
966 (-[NSPasteboard _web_declareAndWriteDragImage:URL:title:archive:source:]):
967 updated to pass parameter to _web_writableTypesForImageIncludingArchive:
969 * WebView.subproj/WebDefaultContextMenuDelegate.m:
970 (-[WebDefaultUIDelegate copyImageToClipboard:]):
971 updated to pass parameter to _web_writableTypesForImageIncludingArchive:
973 * WebView.subproj/WebImageView.m:
974 (-[WebImageView copy:]):
975 updated to pass parameter to _web_writableTypesForImageIncludingArchive:
977 * WebView.subproj/WebView.m:
978 (-[WebView pasteboardTypesForElement:]):
979 updated to pass parameter to _web_writableTypesForImageIncludingArchive:
981 2005-03-07 Richard Williamson <rjw@apple.com>
983 More bullet proofing for <rdar://problem/4038304> CrashTracer: ....9 crashes at com.apple.WebKit: -[WebTextRenderer initWithFont:usingPrinterFont:] + 840
985 Protect against removal of Times and Times New Roman from
986 system. If these fonts are removed attempt to get system font
987 instead of FATAL_ALWAYS.
991 * WebCoreSupport.subproj/WebTextRenderer.m:
992 (-[WebTextRenderer initWithFont:usingPrinterFont:]):
996 2005-03-06 Darin Adler <darin@apple.com>
998 - fixed obvious mistake in IDN script code (luckily it hasn't been in a submission yet!)
1000 * Misc.subproj/WebNSURLExtras.m: (readIDNScriptWhiteListFile): Use "index" to index into the array,
1001 not "script", which is the script number, not the 32-bit-word index.
1003 2005-03-05 Kevin Decker <kdecker@apple.com>
1007 Fixed: <rdar://problem/4038529> Infinite progress bar loading webcams and other sites that use multipart/x-mixed-replace
1009 The previous patch I landed prevented us from loading multipart/x-mixed-replace but did not always update the progress bar accordingly.
1010 This stops websites from having seemingly infinite progress in the browser UI.
1012 * WebCoreSupport.subproj/WebSubresourceClient.m:
1013 (-[WebSubresourceClient didReceiveResponse:]): If this is "multipart/x-mixed-replace", remove the WebBaseResourceHandleDelegate client from
1014 the datasource's subresource array, otherwise -[WebDataSource isLoading] incorrectly returns YES. Also it's possible at this point in
1015 time we're done loading now (loaded everything else except for the multipart/x-mixed-replace content) so go ahead and check to see if
1016 in fact we're complete.
1017 * WebView.subproj/WebMainResourceClient.m:
1018 (-[WebMainResourceClient connection:didReceiveResponse:]): ditto
1020 2005-03-05 Richard Williamson <rjw@apple.com>
1022 Fixed panther build problem. Shouldn't include
1023 changes for 3968753 on panther.
1027 * WebView.subproj/WebView.m:
1028 (-[WebView _commonInitializationWithFrameName:groupName:]):
1030 2005-03-05 Darin Adler <darin@apple.com>
1034 - fixed <rdar://problem/4034603> REGRESSION (185-188): RadarWeb can't send enclosures anymore
1036 * WebView.subproj/WebFormDataStream.m:
1037 (closeCurrentStream): Release currentData when closing the stream.
1038 (advanceCurrentStream): Set up and retain currentData when the current stream is reading that data, so the
1039 data won't be released while in use.
1040 (formCreate): Initialize currentData to NULL.
1042 - fixed <rdar://problem/4037562> Tiger8A402: Help Viewer crashed when viewing help for iChat (infinite recursion in WebView)
1044 * WebView.subproj/WebView.m: (-[WebView _responderValidateUserInterfaceItem:]):
1045 Check for the case where we ourselves are the responder. This avoids an infinite loop.
1046 The actual code to perform operations avoids this with a global variable, but this lighter weight
1047 solution is sufficient here because validate operations don't call through to the next responder.
1049 2005-03-04 Richard Williamson <rjw@apple.com>
1051 Fixed <rdar://problem/3968753> REGRESSION: Poor performance with differing multiple animated GIFs (was fast in Panther)
1053 Disable coalesced updates (in CG). This restores the
1056 Reviewed by David Harrison.
1058 * WebView.subproj/WebView.m:
1059 (-[WebView _commonInitializationWithFrameName:groupName:]):
1061 2005-03-04 Adele Amchan <adele@apple.com>
1065 * English.lproj/StringsNotToBeLocalized.txt: added new strings "text/x-vcf" and "text/x-csv" to the list
1067 2005-03-04 Adele Amchan <adele@apple.com>
1071 Fix for <rdar://problem/4032982> Sun iPlanet app: not able to import AddressBook CSV format addresses properly
1072 Fix for <rdar://problem/4032985> Sun iPlanet app: not able to import vCard format addresses properly
1074 * WebView.subproj/WebTextView.m:
1075 (+[WebTextView unsupportedTextMIMETypes]): added "text/x-csv" and "text/x-vcf" to the list of MIME types that our text view doesn't handle
1077 2005-03-04 Darin Adler <darin@apple.com>
1081 - fixed <rdar://problem/4036817> REGRESSION: ctrl-y broken when a line + carriage return cut
1083 * WebView.subproj/WebHTMLView.m:
1084 (-[WebHTMLView _deleteRange:killRing:prepend:smartDeleteOK:deletionAction:]): Merged _handleKillRing behavior
1085 into this function, since there's now a more-complicated way the startNewKillRingSequence boolean needs to
1086 be handled. Set the startNewKillRingSequence boolean after the entire process so changing the selection before
1087 and during the editing dosn't clear it. Also change "isTypingAction" parameter to "deletionAction" so we can
1088 handle forward delete with this method.
1089 (-[WebHTMLView _deleteSelection]): Pass deleteSelectionAction for action rather than NO for isTypingAction,
1090 which is the way to say the same thing using the new parameter.
1091 (-[WebHTMLView _deleteWithDirection:granularity:killRing:isTypingAction:]): Refactor to use the _deleteRange
1092 method above. Also calls _shouldDeleteRange: for the pre-existing selection case; not doing that before was
1094 (-[WebHTMLView deleteToMark:]): Pass deleteSelectionAction for action rather than NO for isTypingAction,
1095 which is the way to say the same thing using the new parameter.
1097 2005-03-04 Darin Adler <darin@apple.com>
1101 - fixed <rdar://problem/4020413> REGRESSION (Mail): can't use fonts with names that start with "#" in Mail (Korean fonts)
1103 * WebView.subproj/WebHTMLView.m:
1104 (-[WebHTMLView _styleFromFontAttributes:]): Quote font name when calling setFontFamily.
1105 (-[WebHTMLView _addToStyle:fontA:fontB:]): Ditto.
1107 2005-03-04 Darin Adler <darin@apple.com>
1111 - fixed <rdar://problem/3965666> IDN spoofing vulnerability caused by Unicode characters that look like ASCII characters
1113 * Misc.subproj/WebNSURLExtras.m:
1114 (readIDNScriptWhiteListFile): Added. Reads file and parses script names.
1115 (readIDNScriptWhiteList): Added. Calls readIDNScriptWhiteList on each of the white list locations in succession.
1116 (allCharactersInIDNScriptWhiteList): Renamed from containsPossibleLatinLookalikes and changed sense.
1117 Now calls readIDNScriptWhiteList first time, and then uses the read-in list to check the scripts.
1118 (-[NSString _web_mapHostNameWithRange:encode:makeString:]): Call allCharactersInIDNScriptWhiteList instead of
1119 containsPossibleLatinLookalikes.
1120 * Resources/IDNScriptWhiteList.txt: Added.
1121 * WebKit.pbproj/project.pbxproj: Added IDNScriptWhiteList.txt file.
1123 * Misc.subproj/WebKitLocalizableStrings.m: Removed. This is simply unused.
1124 * English.lproj/StringsNotToBeLocalized.txt: Updated for recent changes.
1126 2005-03-04 Darin Adler <darin@apple.com>
1130 - fixed <rdar://problem/3937667> REGRESSION (Mail): Zooming a window from titlebar button doesn't paint newly-exposed portions of window
1132 * WebView.subproj/WebHTMLView.m: (-[WebHTMLView _recursiveDisplayAllDirtyWithLockFocus:visRect:]):
1133 Re-set-up the visRect if the bounds changes due to layout.
1137 2005-03-03 Jens Alfke <jens@apple.com>
1141 <rdar://problem/3991818> REGRESSION: Images scale while loading
1142 The code could crop an image when not all the scanlines were available yet, and it could crop when only a sub-rect of the image was to be drawn; but if it had to do both at once, it got the coordinates wrong. Fixed that.
1144 * WebCoreSupport.subproj/WebImageData.m:
1145 (-[WebImageData incrementalLoadWithBytes:length:complete:callback:]):
1147 2005-03-01 David Hyatt <hyatt@apple.com>
1149 Fix for 3841186, scrollbar shows up disabled when it should not appear at all. Make sure updateScrollers
1150 is never allowed to be re-entrant from any call point by moving the guard inside the function itself.
1152 Reviewed by John Sullivan
1154 * WebView.subproj/WebDynamicScrollBarsView.m:
1155 (-[WebDynamicScrollBarsView updateScrollers]):
1156 (-[WebDynamicScrollBarsView reflectScrolledClipView:]):
1158 2005-03-02 Chris Blumenberg <cblu@apple.com>
1160 Fixed: <rdar://problem/4029010> Expose method to retrieve drag image for WebView's selection
1162 Reviewed by sullivan.
1164 * WebView.subproj/WebHTMLView.m:
1165 (-[WebHTMLView _startDraggingImage:at:operation:event:sourceIsDHTML:DHTMLWroteData:]): call _selectionDraggingImage
1166 (-[WebHTMLView _selectionDraggingImage]): new SPI for Mail, factored from previous method
1167 (-[WebHTMLView _selectionDraggingRect]): new SPI for Mail
1168 * WebView.subproj/WebHTMLViewPrivate.h:
1170 2005-03-02 John Sullivan <sullivan@apple.com>
1174 - fixed <rdar://problem/4023337> Safari stops loading any page (-[NSCFDictionary setObject:forKey:]:
1175 attempt to insert nil key)
1177 It is very likely that the exception being hit is caused by the same problem as WebFoundation
1178 bug 4018486. This change makes the code robust against this kind of problem regardless.
1180 * WebView.subproj/WebBaseResourceHandleDelegate.m:
1181 (-[WebBaseResourceHandleDelegate saveResource]):
1182 Don't call addSubresource if newly-created resource is nil (but do assert on debug builds).
1183 Also assert that originalURL and MIMEType are not nil.
1185 * WebView.subproj/WebDataSource.m:
1186 (-[WebDataSource addSubresource:]):
1187 Don't add nil subresource to dictionary, but do assert on debug builds.
1191 2005-03-01 John Sullivan <sullivan@apple.com>
1195 - fixed <rdar://problem/3987482> Format>Style>Italic is not enabled when a
1196 compose window is empty (works in Blot)
1198 * WebView.subproj/WebHTMLView.m:
1199 (-[WebHTMLView becomeFirstResponder]):
1200 call _updateFontPanel here so NSFontManager knows the right font for the menu
1201 items and the font panel
1203 2005-03-01 David Harrison <harrison@apple.com>
1207 <rdar://problem/3915560> Mail would like an SPI to enable "smart" text paste/drop
1209 * WebView.subproj/WebHTMLView.m:
1210 (-[WebHTMLView _smartDeleteRangeForProposedRange:]):
1211 (-[WebHTMLView _smartInsertForString:replacingRange:beforeString:afterString:]):
1214 2005-02-28 John Sullivan <sullivan@apple.com>
1218 - WebKit part of fix for <rdar://problem/4023490> REGRESSION (125-185): Tabbing through links
1219 on frameset page gets stuck at end (tivofaq.com)
1221 This tab-to-links stuff has been in shaky condition ever since AppKit futzed with
1222 tabbing behavior in Tiger to add support for including the toolbar in the key loop.
1223 I made some changes months ago to compensate for that, but some cases, such as this
1224 one, still weren't fixed.
1226 * WebCoreSupport.subproj/WebBridge.m:
1227 (-[WebBridge _nextKeyViewOutsideWebFrameViewsWithValidityCheck:]):
1228 new bottleneck method, extracted from nextKeyViewOutsideWebFrameViews; handles
1229 nextKeyView or nextValidKeyView depending on parameter.
1230 (-[WebBridge nextKeyViewOutsideWebFrameViews]):
1231 now calls extracted method
1232 (-[WebBridge nextValidKeyViewOutsideWebFrameViews]):
1233 new method, calls new bottleneck method
1235 * WebView.subproj/WebHTMLView.m:
1236 (-[WebHTMLView nextValidKeyView]):
1237 when we're stuck at the end of a nextKeyView chain inside a nexted frame, use
1238 nextValidKeyViewOutsideWebFrameViews. Make sure we don't end up looking inside
1239 the web frame views while doing this.
1241 2005-02-25 Darin Adler <darin@apple.com>
1245 - fixed <rdar://problem/4025088> window onblur and onfocus don't fire when text field has focus
1247 * WebView.subproj/WebHTMLView.m:
1248 (-[WebHTMLView updateFocusState]): Renamed from updateFocusDisplay. Added call to setWindowHasFocus: method.
1249 (-[WebHTMLView viewDidMoveToWindow]): Call method by new name.
1250 (-[WebHTMLView windowDidBecomeKey:]): Ditto.
1251 (-[WebHTMLView windowDidResignKey:]): Ditto.
1252 (-[WebHTMLView becomeFirstResponder]): Ditto.
1253 (-[WebHTMLView resignFirstResponder]): Ditto.
1257 2005-02-25 Richard Williamson <rjw@apple.com>
1259 Fixed <rdar://problem/4000962> 8A375: Help Viewer displays voiced sound and semi-voiced characters strangely (characters don't seem to be composed)
1261 Added special case for voiced marks.
1265 * WebCoreSupport.subproj/WebTextRenderer.m:
1266 (widthForNextCharacter):
1268 2005-02-25 Darin Adler <darin@apple.com>
1272 - fixed <rdar://problem/4019823> Seed: Control-Y doesn't work
1274 * WebView.subproj/WebHTMLView.m:
1275 (-[WebHTMLView _deleteWithDirection:granularity:killRing:isTypingAction:]): Call _handleKillRing
1276 after setting the selection, since it uses the selection to get the text.
1277 (-[WebHTMLView _insertText:selectInsertedText:]): Check for empty string to avoid an assertion
1278 on the other side of the bridge when you yank the empty string.
1280 2005-02-24 Richard Williamson <rjw@apple.com>
1282 Fixed <rdar://problem/3382926> Bidi neutrals at RTL/LTR boundaries not handled correctly.
1284 If directionality is specified use that as initial directionality,
1285 rather than neutral directionality.
1289 * WebCoreSupport.subproj/WebTextRenderer.m:
1290 (widthForNextCharacter):
1292 2005-02-24 Adele Amchan <adele@apple.com>
1296 Fix for <rdar://problem/4023393> Safari crashed in khtml::RenderObject::repaintAfterLayoutIfNeeded(QRect const&, QRect const&)
1298 We were crashing after hitting PageDown when viewing a pdf because
1299 WebKit was calling over to WebCore to scroll overflow areas.
1300 Since this only needs to be done if we're dealing with a WebHTMLView,
1301 I added a wrapper function to check the documentView before calling
1304 * WebView.subproj/WebFrameView.m:
1305 (-[WebFrameView _scrollOverflowInDirection:granularity:]): added wrapper function that checks if documentView is a WebHTMLView
1306 (-[WebFrameView scrollToBeginningOfDocument:]): uses new wrapper function now
1307 (-[WebFrameView scrollToEndOfDocument:]): uses new wrapper function now
1308 (-[WebFrameView _pageVertically:]): uses new wrapper function now
1309 (-[WebFrameView _pageHorizontally:]): uses new wrapper function now
1310 (-[WebFrameView _scrollLineVertically:]): uses new wrapper function now
1311 (-[WebFrameView _scrollLineHorizontally:]): uses new wrapper function now
1313 2005-02-24 Richard Williamson <rjw@apple.com>
1315 Fixed <rdar://problem/3985889> REGRESSION (125-180): setting <img> src to GIF that already animated does not animate; just shows final frame
1319 * WebCoreSupport.subproj/WebImageData.h:
1320 * WebCoreSupport.subproj/WebImageData.m:
1321 (-[WebImageData resetAnimation]):
1322 * WebCoreSupport.subproj/WebImageRenderer.m:
1323 (-[WebImageRenderer resetAnimation]):
1324 (-[WebInternalImage resetAnimation]):
1325 (-[WebImageRenderer drawImageInRect:fromRect:compositeOperator:context:]):
1327 2005-02-24 Kevin Decker <kdecker@apple.com>
1331 Fixed <rdar://problem/3962401> Don't load multipart/x-mixed-replace content to prevent memory leak
1333 Since we're not going to fix <rdar://problem/3087535> for Tiger, we should not load multipart/x-mixed-replace content. Pages with such content contain what is essentially an infinite load and therefore may leak.
1335 * WebView.subproj/WebMainResourceClient.m:
1336 (-[WebMainResourceClient connection:didReceiveResponse:]): Disabled loading of multipart/x-mixed-replace content until we fully implement server side push.
1337 * WebCoreSupport.subproj/WebSubresourceClient.m:
1338 (-[WebSubresourceClient didReceiveResponse:]): Ditto. Same exact thing for sub resources.
1341 2005-02-23 John Sullivan <sullivan@apple.com>
1345 - fixed <rdar://problem/4021370> REGRESSION (Tiger): WebKit part of fix for
1346 shift-tab on tivofaq doing the wrong thing
1348 * WebView.subproj/WebFrameView.m:
1349 (-[WebFrameView becomeFirstResponder]):
1350 If our previousValidKeyView is nil or self (same as nil modulo AppKit oddness),
1351 look out of the box and get the previousValidKeyView of our webview.
1353 2005-02-23 Darin Adler <darin@apple.com>
1357 - fixed <rdar://problem/4010196> REGRESSION (125-186+): 8-character timestamps in gmail wrap to 2 lines (width:8ex; font-size:80%)
1359 * WebCoreSupport.subproj/WebTextRenderer.m: (-[WebTextRenderer xHeight]): Return the maximum
1360 of the "x" height and width. Comment in the code explains why in more detail.
1362 2005-02-22 Richard Williamson <rjw@apple.com>
1364 Fixed <rdar://problem/3937203> when a div adds a scrollbar (overflow:auto) we do not get regions
1366 Compare regions after automatice scroll regions have been
1371 * WebCoreSupport.subproj/WebBridge.h:
1372 * WebCoreSupport.subproj/WebBridge.m:
1373 (-[WebBridge dealloc]):
1374 (-[WebBridge _compareDashboardRegions:]):
1375 (-[WebBridge dashboardRegionsChanged:]):
1377 2005-02-22 Richard Williamson <rjw@apple.com>
1379 Fixed <rdar://problem/4012463> Dashboard widgets don't work with authenticating proxies
1381 Added new SPI for dashboard that just calls default delegate
1386 * WebView.subproj/WebView.m:
1387 (-[WebView handleAuthenticationForResource:challenge:fromDataSource:]):
1388 * WebView.subproj/WebViewPrivate.h:
1390 2005-02-22 Chris Blumenberg <cblu@apple.com>
1394 * WebCoreSupport.subproj/WebBridge.m:
1395 (-[WebBridge issuePasteAndMatchStyleCommand]): support for new "PasteAndMatchStyle" exec command
1399 2005-02-21 David Harrison <harrison@apple.com>
1403 <rdar://problem/3943090> REGRESSION (Mail): Spelling underline incompletely erased following certain steps
1405 * WebCoreSupport.subproj/WebTextRenderer.m:
1406 (-[WebTextRenderer misspellingLineThickness]):
1407 (-[WebTextRenderer misspellingLinePatternWidth]):
1408 Replaced #defines with these methods, so others can get the same info.
1410 (-[WebTextRenderer drawLineForMisspelling:withWidth:]):
1411 Keep underline within originally specified bounds.
1414 2005-02-21 Darin Adler <darin@apple.com>
1418 - fixed <rdar://problem/4016358> don't ever display IDN URLs with characters from "possible Latin look-alike" scripts
1420 * Misc.subproj/WebNSURLExtras.m:
1421 (containsPossibleLatinLookalikes): Added.
1422 (-[NSString _web_mapHostNameWithRange:encode:makeString:]): Call containsPossibleLatinLookalikes, and if true,
1423 don't decode the host name.
1425 2005-02-19 Kevin Decker <kdecker@apple.com>
1429 Fixed <rdar://problem/4010765> Flash player can be used to arbitrarily open popup windows without user permission
1431 Our window.open() policy is to refuse the <script>window.open(...)</script> case and allow the inline the <a href="javascript:window.open('foo')> case. Clever advertisers at some point realized that by executing their Javascript through the Flash plugin, Safari would always treat their code as the inline case, and thus, they were able to work around our popup blocker.
1433 * Plugins.subproj/WebBaseNetscapePluginView.h: Addded currentEventIsUserGesture boolean ivar.
1434 * Plugins.subproj/WebBaseNetscapePluginView.m:
1435 (-[WebBaseNetscapePluginView sendEvent:]): If at any point the user clicks or presses a key from within a plugin, set the currentEventIsUserGesture flag to true. This is important to differentiate legitimate window.open() calls originating from plugins; we still want to allow those.
1436 (-[WebBaseNetscapePluginView initWithFrame:]): In our asynchronous load, pass along currentEventIsUserGesture to the PluginRequest.
1437 (-[WebBaseNetscapePluginView evaluateJavaScriptPluginRequest:]): Inform WebCore if this was a user originated gesture when calling executeScript().
1438 (-[WebBaseNetscapePluginView loadRequest:inTarget:withNotifyData:sendNotification:]):
1439 (-[WebPluginRequest initWithRequest:frameName:notifyData:sendNotification:didStartFromUserGesture:]):
1440 (-[WebPluginRequest isCurrentEventUserGesture]): Added.
1442 2005-02-18 Chris Blumenberg <cblu@apple.com>
1444 Fixed: <rdar://problem/3945271> REGRESSION (Mail): pasted plain text should pick up typing style instead of being unstyled
1446 Reviewed by kocienda.
1448 * WebView.subproj/WebDataSource.m:
1449 (-[WebDataSource _replaceSelectionWithArchive:selectReplacement:]): pass NO for matchStyle to replaceSelection
1450 * WebView.subproj/WebHTMLView.m:
1451 (-[WebHTMLView _documentFragmentFromPasteboard:allowPlainText:chosePlainText:]): return new chosePlainText parameter
1452 (-[WebHTMLView _pasteWithPasteboard:allowPlainText:]): pass chosePlainText for matchStyle to replaceSelection
1453 (-[WebHTMLView concludeDragForDraggingInfo:actionMask:]): ditto
1455 2005-02-17 Richard Williamson <rjw@apple.com>
1457 Removed code that should not have been checked in from
1460 * WebCoreSupport.subproj/WebTextRendererFactory.m:
1461 (-[WebTextRendererFactory isFontFixedPitch:]):
1463 2005-02-17 Richard Williamson <rjw@apple.com>
1465 Fixed <rdar://problem/3999467> when Osaka-Mono is specified as fixed width font, Osaka used instead
1467 Fixed w/o introducing a performance regression.
1469 Reviewed by Vicki (and earlier by Dave Harrison).
1471 * WebCoreSupport.subproj/WebTextRenderer.m:
1472 (-[WebTextRenderer _computeWidthForSpace]):
1473 (widthForNextCharacter):
1474 * WebCoreSupport.subproj/WebTextRendererFactory.h:
1475 * WebCoreSupport.subproj/WebTextRendererFactory.m:
1476 (-[NSFont _web_isFakeFixedPitch]):
1477 (-[WebTextRendererFactory isFontFixedPitch:]):
1478 (-[WebTextRendererFactory fontWithFamily:traits:size:]):
1480 2005-02-17 Richard Williamson <rjw@apple.com>
1482 Fixed <rdar://problem/3959304> PDF in img tag is not rendered correctly anymore
1484 We were incorrectly adding image position when flipping coordinates.
1486 Reviewed by David Harrison.
1488 * WebCoreSupport.subproj/WebImageData.m:
1489 (-[WebImageData _PDFDrawFromRect:toRect:operation:alpha:flipped:context:]):
1491 2005-02-17 Richard Williamson <rjw@apple.com>
1493 Fixed <rdar://problem/4007262> Seed: Flight tracker scrolling moves to the left
1495 Added SPI for dashboard to disable wheel scrolling of the WebClipView.
1500 * WebView.subproj/WebClipView.m:
1501 (-[WebClipView _focusRingVisibleRect]):
1502 (-[WebClipView scrollWheel:]):
1503 * WebView.subproj/WebView.m:
1504 (-[WebViewPrivate init]):
1505 (-[WebView drawRect:]):
1506 (-[WebView _dashboardBehavior:]):
1507 * WebView.subproj/WebViewInternal.h:
1508 * WebView.subproj/WebViewPrivate.h:
1512 2005-02-17 Vicki Murley <vicki@apple.com>
1514 - roll out this change, since it causes a 1.5% performance regression
1516 2005-02-15 Richard Williamson <rjw@apple.com>
1518 Fixed <rdar://problem/3999467> when Osaka-Mono is specified as fixed width font, Osaka used instead
1520 Lie about Osaka-Mono. Treat it as fixed pitch, even though,
1521 strictly speaking it isn't. (Similar to what we do with
1524 Reviewed by David Harrison.
1526 * WebCoreSupport.subproj/WebTextRenderer.m:
1527 (-[WebTextRenderer _computeWidthForSpace]):
1528 * WebCoreSupport.subproj/WebTextRendererFactory.h:
1529 * WebCoreSupport.subproj/WebTextRendererFactory.m:
1530 (-[NSFont _web_isFakeFixedPitch]):
1531 (-[WebTextRendererFactory isFontFixedPitch:]):
1532 (-[WebTextRendererFactory fontWithFamily:traits:size:]):
1534 2005-02-17 John Sullivan <sullivan@apple.com>
1538 - fixed <rdar://problem/3997185> The Web view on .Mac Prefs caused System Prefs
1539 to lockup (resolved by re-boot only)
1541 * WebCoreSupport.subproj/WebBridge.m:
1542 (-[WebBridge nextKeyViewOutsideWebFrameViews]):
1543 Don't allow recursion here; assert on debug build, return nil on deployment. I
1544 couldn't get my machine into a state to repro this problem (and neither could the
1545 originator), but it's obvious from the stack crawl that this method was recursing
1546 when it shouldn't have.
1548 2005-02-16 John Sullivan <sullivan@apple.com>
1550 Written by Darin, reviewed by me.
1552 - WebKit part of fix for <rdar://problem/4007384>
1553 FILTER: Bookmark of RSS with Japanese search word & multiple RSS pages loses filter
1555 * DOM.subproj/DOMPrivate.h:
1556 updated this file, which is a copy of the WebCore version
1558 2005-02-16 Richard Williamson <rjw@apple.com>
1560 Fixed <rdar://problem/3966973> Tiger 8A357: Binary Compatiblity: frequent Webstractor.app crashes [WebImageData _nextFrame]
1562 Webstractor.app was playing tricks to create thumbnails of
1563 pages. This caused the 'focusView' to be incorrect during
1564 animated GIF frame rendering.
1568 * WebCoreSupport.subproj/WebImageRenderer.m:
1569 (-[WebImageRenderer _startOrContinueAnimationIfNecessary]):
1571 2005-02-16 Vicki Murley <vicki@apple.com>
1573 Reviewed by me, code change by Darin.
1575 - fixed the build on Panther
1577 * WebView.subproj/WebFormDataStream.m: (webSetHTTPBody):
1578 Added a Panther-specific code path that just loads all the data into one big
1579 NSData object. This means that bug 3686434 won't be fixed on SUPanWheat; we'll
1580 still load the file into memory before sending it to the server on Panther.
1582 2005-02-15 Richard Williamson <rjw@apple.com>
1584 Fixed <rdar://problem/3998368> Tiger8A376: WebTextRenderer assertion failure in Safari while browsing news.bbc.co.uk
1586 Removed use of FATAL_ALWAYS from getUncachedWidth(). It's unclear
1587 why we would trigger the FATAL_ALWAYS. In the past we've seen
1588 the message triggered because of corrupt fonts. Anyway, in this
1589 particular case, we will now return 0 for the character width,
1590 rather than exiting.
1592 Reviewed by David Harrison.
1594 * WebCoreSupport.subproj/WebTextRenderer.m:
1597 2005-02-15 Richard Williamson <rjw@apple.com>
1599 Fixed <rdar://problem/3999467> when Osaka-Mono is specified as fixed width font, Osaka used instead
1601 Lie about Osaka-Mono. Treat it as fixed pitch, even though,
1602 strictly speaking it isn't. (Similar to what we do with
1605 Reviewed by David Harrison.
1607 * WebCoreSupport.subproj/WebTextRenderer.m:
1608 (-[WebTextRenderer _computeWidthForSpace]):
1609 * WebCoreSupport.subproj/WebTextRendererFactory.h:
1610 * WebCoreSupport.subproj/WebTextRendererFactory.m:
1611 (-[NSFont _web_isFakeFixedPitch]):
1612 (-[WebTextRendererFactory isFontFixedPitch:]):
1613 (-[WebTextRendererFactory fontWithFamily:traits:size:]):
1615 2005-02-14 Darin Adler <darin@apple.com>
1619 - fixed <rdar://problem/3686434> Safari uses too much RAM on file upload, leading to malloc errors and crashes (HP printers)
1621 * WebView.subproj/WebFormDataStream.h: Added webSetHTTPBody, which creates and connects an appropriate
1622 stream to an NSMutableURLRequest.
1623 * WebView.subproj/WebFormDataStream.m: Added implementation here.
1625 * WebCoreSupport.subproj/WebBridge.m:
1626 (-[WebBridge syncLoadResourceWithURL:customHeaders:postData:finalURL:responseHeaders:statusCode:]):
1628 * WebCoreSupport.subproj/WebSubresourceClient.m:
1629 (+[WebSubresourceClient startLoadingResource:withURL:customHeaders:postData:referrer:forDataSource:]):
1631 * WebView.subproj/WebFrame.m:
1632 (-[WebFrame _loadItem:withLoadType:]): Use webSetHTTPBody.
1633 (-[WebFrame _postWithURL:referrer:target:data:contentType:triggeringEvent:form:formValues:]): Ditto.
1635 * English.lproj/StringsNotToBeLocalized.txt: Updated for this change and other recent changes.
1637 2005-02-11 Richard Williamson <rjw@apple.com>
1639 Fixed <rdar://problem/4002505> 8A378: Endlessly animating gif's on http://www.entropy.ch
1641 If animated images had no loop count property we were incorrectly
1642 looping forver. Note, that in the course of fixing this bug
1643 I found that ImageIO is incorrectly NOT reporting the loop count
1644 for a whole class of animated GIFs.
1646 Reviewed by Ken Kocienda.
1648 * WebCoreSupport.subproj/WebImageData.m:
1649 (-[WebImageData _repetitionCount]):
1653 2005-02-11 Vicki Murley <vicki@apple.com>
1657 - fix deployment build on Panther
1659 * WebView.subproj/WebHTMLView.m:
1660 (-[WebHTMLView changeBaseWritingDirection:]): ifdef out NSWritingDirectionNatural
1661 (-[WebHTMLView toggleBaseWritingDirection:]): fix a spacing issue
1663 2005-02-10 David Harrison <harrison@apple.com>
1665 Reviewed by Richard.
1667 <rdar://problem/3991652> REGRESSION (Mail): Deleting entire line in reply deletes extra blank line and moves insertion point
1669 * WebView.subproj/WebHTMLView.m:
1670 (-[WebHTMLView _deleteRange:killRing:prepend:smartDeleteOK:isTypingAction:]):
1671 (-[WebHTMLView _startDraggingImage:at:operation:event:sourceIsDHTML:DHTMLWroteData:]):
1672 (-[WebHTMLView _deleteWithDirection:granularity:killRing:isTypingAction:]):
1673 (-[WebHTMLView selectToMark:]):
1674 (-[WebHTMLView swapWithMark:]):
1675 (-[WebHTMLView transpose:]):
1676 (-[WebHTMLView _selectMarkedText]):
1677 (-[WebHTMLView _selectRangeInMarkedText:]):
1678 Adopt new default affinity of NSSelectionAffinityDownstream as of <rdar://problem/3937447>.
1680 2005-02-10 Darin Adler <darin@apple.com>
1682 Reviewed by Harrison.
1684 - fixed <rdar://problem/4002084> Setting ResourceLoadDelegate to nil can cause a crash
1686 * WebView.subproj/WebView.m: (-[WebView _cacheResourceLoadDelegateImplementations]):
1687 Set booleans to either YES or NO, rather than setting them only in the YES case.
1689 2005-02-10 Darin Adler <darin@apple.com>
1691 Reviewed by Harrison.
1693 - fixed <rdar://problem/3991225> Format->Style->Underline menu item does not get checked when selected text is underlined
1695 * WebView.subproj/WebHTMLView.m:
1696 (-[WebHTMLView validateUserInterfaceItem:]): Added tons of additional cases in here for all the
1697 "action" style methods in this class that don't always want to be valid. For the ones where state
1698 makes sense, added the state-checking code too for the menu item case.
1699 (-[WebHTMLView ignoreSpelling:]): Removed unnecessary "editable text only" check since this command
1700 would work fine on a non-editable selection.
1701 (-[WebHTMLView swapWithMark:]): Ditto.
1702 (-[WebHTMLView changeBaseWritingDirection:]): Added. Like toggle, but based on the sender's tag.
1704 2005-02-08 Darin Adler <darin@apple.com>
1706 "Reviewed" by Richard (he told me the file was obsolete).
1708 - got rid of an obsolete file
1710 * Plugins.subproj/npsap.h: Removed.
1711 * copy-webcore-files-to-webkit: Removed npsap.h.
1713 2005-02-09 Richard Williamson <rjw@apple.com>
1715 Fixed <rdar://problem/4000073> non-screen font error on www.worldofwarcraft.com
1717 Reviewed by John Sullivan.
1719 * WebCoreSupport.subproj/WebTextRenderer.m:
1720 (-[WebTextRenderer _smallCapsFont]):
1724 2005-02-07 Chris Blumenberg <cblu@apple.com>
1726 Fixed: <rdar://problem/3993354> Safari claims to put RTFD on the pasteboard, but doesn't, in some cases
1730 * WebView.subproj/WebHTMLView.m:
1731 (-[WebHTMLView _stripAttachmentCharactersFromAttributedString:]): moved
1732 (-[WebHTMLView _writeSelectionWithPasteboardTypes:toPasteboard:cachedAttributedString:]): take cachedAttributedString parameter in case the attributed string was gotten already
1733 (-[WebHTMLView _writeSelectionToPasteboard:]): omit RTFD from the types list when there are no attachments
1735 2005-02-07 David Harrison <harrison@apple.com>
1739 <rdar://problem/3990693> REGRESSION (8A373): ctrl-k now deletes just one character instead of line
1741 * WebView.subproj/WebHTMLView.m:
1742 (-[WebHTMLView _deleteWithDirection:granularity:killRing:isTypingAction:]):
1743 Set the selection so that deleteKeyPressedWithSmartDelete knows what to delete.
1745 2005-02-06 Darin Adler <darin@apple.com>
1749 - fixed <rdar://problem/3963166> PDFView SPI print method is being deprecated, moving to PDFDocument; please update WebKit
1751 * WebView.subproj/WebPDFView.m: (-[WebPDFView printOperationWithPrintInfo:]): Target the document instead of the view.
1753 * English.lproj/StringsNotToBeLocalized.txt: Updated for recent changes and also moved one translation to be a file-specific
1754 item rather than a file-independent one.
1756 2005-02-05 Chris Blumenberg <cblu@apple.com>
1758 Fixed: <rdar://problem/3991974> REGRESSION: www.jabra.com world location screen does not work
1762 * WebCoreSupport.subproj/WebBridge.m:
1763 (-[WebBridge viewForPluginWithURL:attributeNames:attributeValues:MIMEType:]): use the baseURL from the bridge rather than from the response
1765 2005-02-04 Chris Blumenberg <cblu@apple.com>
1767 Fixed: <rdar://problem/3802781> rtf->html pasteboard conversion using xhtml
1769 Reviewed by kocienda.
1771 * WebView.subproj/WebHTMLView.m:
1772 (+[WebHTMLView _excludedElementsForAttributedStringConversion]): new
1773 (-[WebHTMLView _documentFragmentFromPasteboard:allowPlainText:]): call _excludedElementsForAttributedStringConversion
1775 2005-02-04 Chris Blumenberg <cblu@apple.com>
1777 Fixed: <rdar://problem/3832973> copy text from PowerPoint, paste into Blot (or presumably Mail) and get a single missing image icon
1781 * WebView.subproj/WebHTMLView.m:
1782 (-[WebHTMLView _documentFragmentFromPasteboard:allowPlainText:]): prefer RTF and RTFD over images just as NSTextView does
1784 2005-02-03 Chris Blumenberg <cblu@apple.com>
1786 Fixed: <rdar://problem/3555137> REGRESSION (125-173): Flash animation can erase parts of chrome (bookmarks bar & tab bar)
1788 convertRect:toView: returns incorrect results inside of viewWillMoveToWindow: with a nil window. Workaround this by catching this case.
1792 * Plugins.subproj/WebBaseNetscapePluginView.m:
1793 (-[WebBaseNetscapePluginView superviewsHaveSuperviews]): new
1794 (-[WebBaseNetscapePluginView saveAndSetPortStateForUpdate:]): clip out the plug-in view when superviewsHaveSuperviews returns NO
1796 2005-02-03 Chris Blumenberg <cblu@apple.com>
1798 Fixed: <rdar://problem/3893513> Sun iPlanet app: when saving to a file it brings up a window with the thing to be saved instead
1802 * WebView.subproj/WebTextView.m:
1803 (+[WebTextView unsupportedTextMIMETypes]): added "text/ldif" to the list of MIME types that our text view doesn't handle
1807 2005-02-03 Chris Blumenberg <cblu@apple.com>
1809 * English.lproj/StringsNotToBeLocalized.txt: updated
1811 2005-02-03 Chris Blumenberg <cblu@apple.com>
1813 Fixed: <rdar://problem/3989611> Evite style "add vCalendar to calendar" do not work
1817 * WebView.subproj/WebTextView.m:
1818 (+[WebTextView unsupportedTextMIMETypes]): added "text/x-vcalendar" to the list of MIME types our text view doesn't handle
1820 2005-02-03 Vicki Murley <vicki@apple.com>
1824 - fix deployment build breakage on Panther
1826 * WebView.subproj/WebHTMLView.m:
1827 (-[WebHTMLView toggleBaseWritingDirection:]):
1829 2005-02-02 John Sullivan <sullivan@apple.com>
1833 - WebKit part of fix for <rdar://problem/3980651> REGRESSION (125-180): Huge number of pages printed from certain page,
1836 This also fixes the problems with printing from GMail, yay!
1838 * WebView.subproj/WebHTMLView.m:
1839 (-[WebHTMLView _setPrinting:minimumPageWidth:maximumPageWidth:adjustViewSize:]):
1840 Don't adjust margins for header/footer here, because this is called for each subframe.
1841 (-[WebHTMLView knowsPageRange:]):
1842 Do adjust margins for header/footer here (analogous to WebTextView and WebImageView).
1843 Also, round the page height to an integer here (noticed in passing).
1845 2005-02-02 Chris Blumenberg <cblu@apple.com>
1847 Fixed: <rdar://problem/3986546> Cut, delete, and paste menu items are active when a image is opened in window
1851 * WebView.subproj/WebView.m:
1852 (-[WebView _responderValidateUserInterfaceItem:]): new, has the responder validate the item
1853 (-[WebView validateUserInterfaceItem:]): call VALIDATE for each repsonder selector using FOR_EACH_RESPONDER_SELECTOR macro
1854 (-[WebView _performResponderOperation:with:]): call factored out method _responderForResponderOperations
1855 (-[WebView _responderForResponderOperations]): new, code from _performResponderOperation:with:
1857 2005-02-02 Chris Blumenberg <cblu@apple.com>
1859 Fixed: <rdar://problem/3983628> control-click on WebView is not selecting the word under the cursor (Mail, non-editable WebView)
1863 * WebCoreSupport.subproj/WebBridge.m:
1864 (-[WebBridge selectWordBeforeMenuEvent]): new
1865 * WebView.subproj/WebView.m:
1866 (-[WebView _selectWordBeforeMenuEvent]): new SPI
1867 (-[WebView _setSelectWordBeforeMenuEvent:]): new SPI
1868 * WebView.subproj/WebViewInternal.h:
1869 * WebView.subproj/WebViewPrivate.h:
1871 2005-02-02 Chris Blumenberg <cblu@apple.com>
1873 Fixed: <rdar://problem/3986013> Assertion failure going back after page load error (no apparent problem in nondebug build)
1877 * WebView.subproj/WebDataSource.m:
1878 (-[WebDataSource _setPrimaryLoadComplete:]): don't set the data source data when the main client is nil
1880 2005-02-02 Ken Kocienda <kocienda@apple.com>
1886 <rdar://problem/3823109> WebKit should support -toggleBaseWritingDirection: (bidi editing support)
1888 * WebView.subproj/WebHTMLView.m:
1889 (-[WebHTMLView _applyParagraphStyleToSelection:withUndoAction:]): New function that calls through to
1890 new feature that allows callers to force all properties in a style to be applied as block styles.
1891 (-[WebHTMLView _alignSelectionUsingCSSValue:withUndoAction:]): Removed FIXME comment for something that has been fixed.
1892 (-[WebHTMLView toggleBaseWritingDirection:]): Implemented.
1894 2005-02-01 Richard Williamson <rjw@apple.com>
1896 Fixed <rdar://problem/3977727> WebKit should use new SPI to support faster GIF rendering
1898 Note: This REQUIRES build >= 3A362 when building on Tiger.
1902 * WebCoreSupport.subproj/WebImageData.m:
1903 (-[WebImageData _imageSourceOptions]):
1907 2005-02-01 Richard Williamson <rjw@apple.com>
1909 Added new SPI for <rdar://problem/3967063> need spi on WebView to turn of lcd text for Dashboard
1913 * WebCoreSupport.subproj/WebTextRenderer.m:
1915 * WebView.subproj/WebView.m:
1916 (-[WebView drawRect:]):
1917 (-[WebView _dashboardBehavior:]):
1918 (+[WebView _setShouldUseFontSmoothing:]):
1919 (+[WebView _shouldUseFontSmoothing]):
1920 * WebView.subproj/WebViewInternal.h:
1921 * WebView.subproj/WebViewPrivate.h:
1923 2005-01-31 Chris Blumenberg <cblu@apple.com>
1925 Fixed: <rdar://problem/3949806> REGRESSION: Source window fails to refresh correctly on reload
1927 The data method was being called on WebDataSource before the data was set. This fix makes WebDataSource set the data before releasing the main client instead of waiting for the main client to set it when it is dealloced.
1931 * WebView.subproj/WebDataSource.m:
1932 (-[WebDataSource _setData:]): moved within file
1933 (-[WebDataSource _setPrimaryLoadComplete:]): call _setData: with the data from the main client before letting go of the main client
1934 * WebView.subproj/WebDataSourcePrivate.h:
1935 * WebView.subproj/WebMainResourceClient.m:
1936 (-[WebMainResourceClient releaseResources]): removed call to _setData: since the data source may need the data before releaseResources is called
1938 2005-01-31 Chris Blumenberg <cblu@apple.com>
1940 Fixed: <rdar://problem/3946285> Seed: Safari crashed by selecting all at internet-moebel.com
1944 * WebView.subproj/WebHTMLView.m:
1945 (-[WebHTMLView _hitViewForEvent:]): new, factored hit test hack to this method
1946 (-[WebHTMLView _updateMouseoverWithEvent:): call _hitViewForEvent:
1947 (-[WebHTMLView acceptsFirstMouse:]): call _setMouseDownEvent: and _isSelectionEvent: on the hit HTMLView or else when it's asked to drag it will assert
1948 (-[WebHTMLView shouldDelayWindowOrderingForEvent:]): ditto
1950 2005-01-31 David Harrison <harrison@apple.com>
1954 <rdar://problem/3961239> AX Setting AXFocused on AXScrollArea of AXWebArea will cause keyboard selection change
1956 * WebView.subproj/WebHTMLView.m:
1957 (-[WebHTMLView maintainsInactiveSelection]):
1958 Keep the selection when the new first respomder is our own scrollview, in both editable and non-editaqble content.
1960 2005-01-31 Jens Alfke <jens@apple.com>
1964 - Fixed <rdar://problem/3903199> REGRESSION: Large background patterns slide around while loading
1966 * WebCoreSupport.subproj/WebImageData.m:
1968 (-[WebImageData tileInRect:fromPoint:context:]):
1970 2005-01-30 Darin Adler <darin@apple.com>
1974 - fixed <rdar://problem/3965265> Safari displays HTML as source when default encoding is Hebrew (due to direction overrides added by encoding converter)
1976 * WebView.subproj/WebPreferencesPrivate.h: Added _systemCFStringEncoding, and changed
1977 _setInitialDefaultTextEncodingToSystemEncoding to be a class method.
1978 * WebView.subproj/WebPreferences.m:
1979 (+[WebPreferences _systemCFStringEncoding]): Added. New SPI to be used by Safari. Broken out of
1980 _setInitialDefaultTextEncodingToSystemEncoding, but also added cases for MacArabic and MacHebrew.
1981 (+[WebPreferences _setInitialDefaultTextEncodingToSystemEncoding]): Refactor to use _systemCFStringEncoding.
1983 2005-01-28 Jens Alfke <jens@apple.com>
1985 Reviewed by Richard.
1987 <rdar://problem/3727680> printing some page with WebKit generates a PDF with a 1x1 image with soft mask (causes Acrobat to hang during print spooling)
1989 Detect 1x1 images, extract and cache color of single pixel, reduce draw and tile operations to a color fill (or to a no-op if the pixel is clear.)
1991 * WebCoreSupport.subproj/WebImageData.h:
1992 * WebCoreSupport.subproj/WebImageData.m:
1993 (-[WebImageData _invalidateImages]):
1994 (-[WebImageData _checkSolidColor:]):
1995 (-[WebImageData _cacheImages:allImages:]):
1996 (-[WebImageData _fillSolidColorInRect:compositeOperation:context:]):
1997 (-[WebImageData tileInRect:fromPoint:context:]):
1999 2005-01-28 David Harrison <harrison@apple.com>
2003 <rdar://problem/3584942> AX: Safari Accessibility parent-child mismatch
2005 Use AppKit SPI _accessibilityParentForSubview to return KWQAccObject parent of AppKit AX object.
2007 * WebView.subproj/WebHTMLView.m:
2008 (-[WebHTMLView _accessibilityParentForSubview:]):
2011 2005-01-28 Chris Blumenberg <cblu@apple.com>
2013 WebKit side of: <rdar://problem/3951283> can view pages from the back/forward cache that should be disallowed by Parental Controls
2017 * WebView.subproj/WebDefaultPolicyDelegate.m:
2018 (-[WebDefaultPolicyDelegate webView:shouldGoToHistoryItem:]): new private delegate method
2019 * WebView.subproj/WebFrame.m:
2020 (-[WebFrame _goToItem:withLoadType:]): call new delegate method
2021 * WebView.subproj/WebPolicyDelegatePrivate.h:
2023 2005-01-26 Maciej Stachowiak <mjs@apple.com>
2025 Reviewed by Darin, Hyatt and Ken.
2027 <rdar://problem/3790449> REGRESSION (Mail): underline behavior is flaky because of how CSS handles text-decoration
2029 * WebView.subproj/WebHTMLView.m:
2030 (-[WebHTMLView _styleFromFontAttributes:]): Use new -khtml-text-decorations-in-effect
2032 (-[WebHTMLView _styleForAttributeChange:]): likewise
2033 (-[WebHTMLView underline:]): likewise
2035 2005-01-27 Ken Kocienda <kocienda@apple.com>
2039 * WebView.subproj/WebHTMLView.m:
2040 (-[WebHTMLView _handleKillRing:prepend:]): New helper function. Code factored out from
2041 _deleteRange:killRing:prepend:smartDeleteOK:isTypingAction:.
2042 (-[WebHTMLView _deleteRange:killRing:prepend:smartDeleteOK:isTypingAction:]): No longer takes
2043 unused preflight argument. Now takes new isTypingAction argument. Uses isTypingAction to
2044 determine which flavor of delete command to call.
2045 (-[WebHTMLView _deleteSelection]): No longer passes unused preflight argument. Now passes new isTypingAction argument.
2046 (-[WebHTMLView _deleteWithDirection:granularity:killRing:isTypingAction:]): Rearranged code to call
2047 correct flavor of delete command, based on whether typing should be preserved. Some other cleanups.
2048 (-[WebHTMLView deleteForward:]): Add _isEditable check.
2049 (-[WebHTMLView deleteBackward:]): Now calls _deleteWithDirection instead of having unique behavior different
2050 from forward delete.
2051 (-[WebHTMLView deleteWordForward:]): Add new isTypingAction flag to _deleteWithDirection call.
2052 (-[WebHTMLView deleteWordBackward:]): Ditto.
2053 (-[WebHTMLView deleteToBeginningOfLine:]): Ditto.
2054 (-[WebHTMLView deleteToEndOfLine:]): Ditto.
2055 (-[WebHTMLView deleteToBeginningOfParagraph:]): Ditto.
2056 (-[WebHTMLView deleteToEndOfParagraph:]): Ditto.
2057 (-[WebHTMLView deleteToMark:]): Ditto.
2061 2005-01-27 Chris Blumenberg <cblu@apple.com>
2063 Fixed: <rdar://problem/3973272> REGRESSION: Safari uses QT plugin to display PNG images
2067 * Plugins.subproj/WebBasePluginPackage.m: use renamed QT bundle ID
2069 2005-01-26 Darin Adler <darin@apple.com>
2073 - fixed <rdar://problem/3829517> WebView still draws white when setDrawsBackground set to NO and no content loaded yet
2075 * WebView.subproj/WebFrameView.m: (-[WebFrameView drawRect:]): Check drawsBackground, and don't
2076 draw the white "no document" background if it's NO. This fixes things for frames with no document.
2077 * WebView.subproj/WebImageView.m: (-[WebImageView drawRect:]): Same as above. This fixes things
2078 for frames with just an image.
2079 * WebView.subproj/WebFrame.m: (-[WebFrame _updateDrawsBackground]): Call setDrawsBackground: on the
2080 document view if it implements it. This fixes things for frames with plain text.
2082 2005-01-25 John Sullivan <sullivan@apple.com>
2086 - WebKit part of fix for: <rdar://problem/3970670> Text context menu
2087 in WebKit needs "Look Up in Dictionary" item
2089 * WebView.subproj/WebDefaultContextMenuDelegate.m:
2090 (localizedMenuTitleFromAppKit):
2091 return English string in the case where AppKit bundle is found but doesn't
2092 contain the expected string. This case will be hit by people testing with
2094 (-[WebDefaultUIDelegate menuItemWithTag:]):
2095 create Look Up in Dictionary item
2096 (-[WebDefaultUIDelegate contextMenuItemsForElement:]):
2097 add Look Up in Dictionary item and separator
2098 (-[WebDefaultUIDelegate editingContextMenuItemsForElement:]):
2101 * WebView.subproj/WebHTMLView.m:
2102 (-[WebHTMLView _lookUpInDictionaryFromMenu:]):
2103 new method, handles bringing up the Dictionary window. Includes FIXMEs
2104 for a couple of the known loose ends.
2105 (-[WebHTMLView validateUserInterfaceItem:]):
2106 handle Look Up in Dictionary item like the other new items
2108 * WebView.subproj/WebUIDelegatePrivate.h:
2109 added SPI constant for Look Up in Dictionary menu item
2111 2005-01-24 Maciej Stachowiak <mjs@apple.com>
2113 Fixed Panther build (missing ifdef)
2115 * WebView.subproj/WebDefaultContextMenuDelegate.m:
2117 2005-01-24 John Sullivan <sullivan@apple.com>
2121 - WebKit part of fix for <rdar://problem/3960231> Text context menu in WebKit needs Spotlight and Google items
2123 * WebView.subproj/WebDefaultContextMenuDelegate.m:
2124 (localizedMenuTitleFromAppKit):
2125 new function, gets localized string from AppKit so we can avoid adding localized
2126 strings to WebKit at this late date in Tiger. Returns the non-localized English
2127 string if we can't find the localized string in AppKit.
2128 (-[WebDefaultUIDelegate menuItemWithTag:]):
2129 handle the two new menu items by tag name
2130 (-[WebDefaultUIDelegate contextMenuItemsForElement:]):
2131 add menu items for Search in Google and Search in Spotlight to selected-text menu item
2132 for the noneditable case
2133 (-[WebDefaultUIDelegate editingContextMenuItemsForElement:]):
2134 add menu items for Search in Google and Search in Spotlight to selected-text menu item
2135 for the editable case
2137 * WebView.subproj/WebHTMLView.m:
2138 (-[WebHTMLView _searchWithGoogleFromMenu:]):
2139 implement this menu item action method, using same method name and implementation as NSTextView
2140 (-[WebHTMLView _searchWithSpotlightFromMenu:]):
2141 implement this menu item action method, using same basic implementation as NSTextView
2142 (-[WebHTMLView validateUserInterfaceItem:]):
2143 validate new menu items
2145 * WebView.subproj/WebUIDelegatePrivate.h:
2146 define new tags for new menu items
2148 * English.lproj/StringsNotToBeLocalized.txt:
2149 updated for these changes
2151 2005-01-24 Darin Adler <darin@apple.com>
2153 * WebView.subproj/WebDataSource.m: (+[WebDataSource _repTypesAllowImageTypeOmission:]):
2154 Do the same check as for view types, so the representation types are consistent.
2156 2005-01-24 Darin Adler <darin@apple.com>
2160 - fixed <rdar://problem/3791158> REGRESSION (Mail): copyFont: and pasteFont: copy and paste only the NSFont, not other attributes
2162 * WebView.subproj/WebHTMLView.m: (-[WebHTMLView _styleFromFontAttributes:]): Added the last
2163 few loose ends here: strikethrough and underline.
2165 - fixed <rdar://problem/3967393> add a user default that lets you turn off WebKit PDF support
2167 * WebView.subproj/WebFrameView.m: (+[WebFrameView _viewTypesAllowImageTypeOmission:]):
2168 Leave the PDF-handling classes out of the dictionary if the secret default is set.
2170 * English.lproj/StringsNotToBeLocalized.txt: Updated for recent changes.
2172 2005-01-20 Darin Adler <darin@apple.com>
2174 Reviewed by Kristin Forster.
2176 - fixed <rdar://problem/3964972> update _initWithCGSEvent:eventRef: call in mouse moved workaround (breaks cursors in Carbon WebKit applications)
2178 * Carbon.subproj/HIWebView.m: (MouseMoved): Instead of munging the event record's window number directly
2179 before calling _initWithCGSEvent, on Tiger we call _eventRelativeToWindow on the event after creating it.
2180 Also added a check so that with Macromedia Contribute's workaround in place we don't do anything at all
2181 to the event. Tested with both Contribute and CarbonWeb.
2183 * English.lproj/StringsNotToBeLocalized.txt: Update for recent changes.
2185 2005-01-20 Richard Williamson <rjw@apple.com>
2187 Fixed <rdar://problem/3815672> REGRESSION (Mail): Japanese text cannot be made bold
2189 The AppKit's font substitution API doesn't match font traits!
2190 It only find fonts that contain the appropriate glyphs. This
2191 patch attempts to find the best variation within a family.
2195 * WebCoreSupport.subproj/WebTextRenderer.m:
2196 (-[WebTextRenderer _substituteFontForString:families:]):
2200 2005-01-20 Ken Kocienda <kocienda@apple.com>
2206 <rdar://problem/3786659> REGRESSION (Mail): editable WebViews don't work with "size up" and "size down" NSFontManager changes
2208 * WebView.subproj/WebHTMLView.m:
2209 (-[WebHTMLView _addToStyle:fontA:fontB:]): This is the WebKit side of the fix. Replaced unimplemented code blocks
2210 with FIXME's in them for make bigger and make smaller with real working code.
2212 2005-01-19 David Hyatt <hyatt@apple.com>
2214 Fix for 3513067, spaces being lost when RTL text is rendered. Make sure not to allow hangers or spaces
2219 * WebCoreSupport.subproj/WebTextRenderer.m:
2220 (-[WebTextRenderer _createATSUTextLayoutForRun:style:]):
2222 2005-01-19 Darin Adler <darin@apple.com>
2226 - fixed <rdar://problem/3962559> stopAnimationsInView leaks after cvs-base
2228 * WebCoreSupport.subproj/WebImageData.m: (+[WebImageData stopAnimationsInView:]): add a release
2230 2005-01-19 Chris Blumenberg <cblu@apple.com>
2232 Fixed: <rdar://problem/3961809> plug-in code attempts to load empty URL
2236 * Plugins.subproj/WebNetscapePluginEmbeddedView.m:
2237 (-[WebNetscapePluginEmbeddedView didStart]): don't start load if URL is empty
2239 2005-01-17 Darin Adler <darin@apple.com>
2241 * DOM.subproj/DOMPrivate.h: Check in generated file.
2243 2005-01-17 Darin Adler <darin@apple.com>
2245 Reviewed by John and Richard.
2247 - fixed <rdar://problem/3907453> printing a multi-page PDF document from Safari doesn't produce correct output
2249 * WebView.subproj/WebFrameViewPrivate.h: Added.
2250 * WebView.subproj/WebFrameView.m:
2251 (-[WebFrameView canPrintHeadersAndFooters]): Added. Returnes NO for documents that can't print headers or footers,
2252 and delegates to the document view to answer the question. Defaults to NO, since only a view that actively does
2253 the work is compatible with our header and footer code.
2254 (-[WebFrameView printOperationWithPrintInfo:]): Added. Returns an NSPrintOperation set up for printing. The reason
2255 we return this rather than an NSView is that in the PDFView case, the print info is changed around before creating
2256 the NSPrintOperation, and also the PDFKit SPI works this way.
2258 * WebView.subproj/WebHTMLView.m: (-[WebHTMLView canPrintHeadersAndFooters]): Added. Returns YES.
2259 * WebView.subproj/WebImageView.m: (-[WebImageView canPrintHeadersAndFooters]): Ditto.
2260 * WebView.subproj/WebTextView.m: (-[WebTextView canPrintHeadersAndFooters]): Ditto.
2262 * WebView.subproj/WebPDFView.m:
2263 (-[WebPDFView canPrintHeadersAndFooters]): Added. Returns NO.
2264 (-[WebPDFView printOperationWithPrintInfo:]): Added. Calls getPrintOperationForPrintInfo: autoRotate:YES on the PDFView.
2266 * WebKit.pbproj/project.pbxproj: Added WebFrameViewPrivate.h as a new private header.
2268 2005-01-13 Chris Blumenberg <cblu@apple.com>
2270 Fixed: <rdar://problem/3932107> Safari does not load QT Cocoa plug-in if the WebPluginMIMETypes key is not in the info.plist
2272 Fixing this bug required that we allow WebKit plug-ins (as well as Netscape plug-ins) support BP_CreatePluginMIMETypesPreferences
2273 which allows plug-ins create an auxiliary MIME types file.
2277 * Plugins.subproj/WebBasePluginPackage.h:
2278 * Plugins.subproj/WebBasePluginPackage.m:
2279 (+[WebBasePluginPackage preferredLocalizationName]): moved from WebNetscapePluginPackage
2280 (-[WebBasePluginPackage pListForPath:createFile:]): ditto
2281 (-[WebBasePluginPackage getPluginInfoFromPLists]): ditto
2282 (-[WebBasePluginPackage isLoaded]): return isLoaded ivar
2283 (-[WebBasePluginPackage load]): if loaded, get BP_CreatePluginMIMETypesPreferences symbol
2284 * Plugins.subproj/WebNetscapePluginPackage.h:
2285 * Plugins.subproj/WebNetscapePluginPackage.m:
2286 (-[WebNetscapePluginPackage load]): call super when done so BP_CreatePluginMIMETypesPreferences can be initialized
2287 * Plugins.subproj/WebPluginPackage.m:
2288 (-[WebPluginPackage initWithPath:]): call getPluginInfoFromPLists
2289 (-[WebPluginPackage load]): call super when done so BP_CreatePluginMIMETypesPreferences can be initialized
2291 2005-01-13 Richard Williamson <rjw@apple.com>
2293 Fixed <rdar://problem/3952809> WebJavaPlugIn.h comments need method name corrected (webPlugInCallJava)
2297 * Plugins.subproj/WebJavaPlugIn.h:
2301 2005-01-13 Vicki Murley <vicki@apple.com>
2305 - fix <rdar://problem/3946836> Safari about box lists 2004 instead of 2005
2307 * WebKit.pbproj/project.pbxproj: bump "2004" to "2005"
2309 2005-01-13 Richard Williamson <rjw@apple.com>
2311 Fixed <rdar://problem/3951911> REGRESSION: Animated GIF images with loop counts no longer update
2313 Draw last image after animation loop terminates. (We
2314 were drawing the image at index+1, which doesn't exist!)
2318 * WebCoreSupport.subproj/WebImageData.m:
2319 (-[WebImageData _nextFrame:]):
2321 2005-01-13 Richard Williamson <rjw@apple.com>
2323 Fixed <rdar://problem/3952084> REGRESSION: Links at projectseven.com now draw and update incorrectly during hover
2325 Turn off use of new CGContextStrokeLineSegments API. We should
2326 turn back on when 3952944 is fixed.
2330 * WebCoreSupport.subproj/WebTextRenderer.m:
2331 (-[WebTextRenderer drawLineForCharacters:yOffset:width:color:thickness:]):
2333 2005-01-13 Chris Blumenberg <cblu@apple.com>
2335 Fixed: <rdar://problem/3937663> repro assertion failure and crash dragging image that has PDF source
2339 * Misc.subproj/WebNSViewExtras.m:
2340 (-[NSView _web_dragImage:rect:event:pasteboard:source:offset:]): if [WebImageRenderer image] returns nil, fallback to code that uses a file icon as the drag image
2341 * WebCoreSupport.subproj/WebImageRendererFactory.m:
2342 (-[WebImageRendererFactory supportedMIMETypes]): removed code that omits PDF and PostScript from the list since this omission is only needed in WebImageView
2343 * WebView.subproj/WebImageView.m:
2344 (+[WebImageView supportedImageMIMETypes]): added code that omits PDF and PostScript since we don't want WebImageView to render these types
2346 2005-01-10 Maciej Stachowiak <mjs@apple.com>
2350 <rdar://problem/3758033> REGRESSION (Mail): Support attributes in marked text (International input)
2352 * WebCoreSupport.subproj/WebTextRenderer.m:
2353 (-[WebTextRenderer drawLineForCharacters:yOffset:width:color:thickness:]): Changed to support
2354 underline thickness. Also added a bit of a hack here to move thickness 2 underlines down by
2355 .5 pixels, since the rendering engine can't give a fractional pixel offset.
2356 * WebView.subproj/WebHTMLView.m:
2357 (-[WebHTMLView validAttributesForMarkedText]): Support underline, underline color and marked
2358 clause attributes. Others that NSText supports are unimplemented for now.
2359 (-[WebHTMLView firstRectForCharacterRange:]): Remove needless logging.
2360 (-[WebHTMLView unmarkText]): Updated for new WebCore SPI.
2361 (-[WebHTMLView _extractAttributes:ranges:fromAttributedString:]): New method to pull the attributes
2362 and ranges out of an attributed string.
2363 (-[WebHTMLView setMarkedText:selectedRange:]): Extract attributes and pass to WebCore.
2364 (-[WebHTMLView insertText:]): Add comment noting that we don't really handle attributed strings
2367 2005-01-12 Darin Adler <darin@apple.com>
2371 - fixed <rdar://problem/3848257> WebView will draw more than AppKit asks it to, so views behind won't redraw enough (transparent WebView)
2373 * WebView.subproj/WebHTMLView.m:
2374 (-[WebHTMLView _propagateDirtyRectsToOpaqueAncestors]): As recommended by Troy Stephens, do the
2375 layouts here in this call, since it's before propagating the dirty rects to our ancestors.
2376 This fixes the bug, but we only do it if the WebView is not opaque, because otherwise we can
2377 optimize by only doing layouts you really need, and doing them later on is safe because we
2378 know we don't need to draw any of the views behind us.
2379 (-[WebHTMLView _layoutIfNeeded]): Added. Factored out from the method below.
2380 (-[WebHTMLView _web_layoutIfNeededRecursive]): Added. Like the other "layout if needed" call,
2382 (-[WebHTMLView _web_layoutIfNeededRecursive:testDirtyRect:]): Factored out the guts into the
2383 _layoutIfNeeded method above. Otherwise unchanged.
2384 (-[NSView _web_layoutIfNeededRecursive]): Added.
2386 * WebView.subproj/WebFrame.m: (-[WebFrame _updateDrawsBackground]): Call setDrawsBackground:NO
2387 on the scroll view when changing the frame to no longer be in "draws background" mode. This
2388 is needed because the frame manages the "draws background" mode of the scroll view. It won't
2389 have any effect if you call setDrawsBackground:NO before starting to use a WebView, but without
2390 it calling setDrawsBackground:NO later won't have an immediate effect (easily visible in Safari).
2391 This was hidden before because the HTML view was filling with transparent color, which blew away
2392 the fill that was done by NSScrollView.
2394 - fixed <rdar://problem/3921129> reproducible crash at www.funnychristmas.com in CFSet manipulation in WebImageData
2396 * WebCoreSupport.subproj/WebImageData.m:
2397 (-[WebImageData _imageSourceOptions]): Changed types so we don't need a cast.
2398 (+[WebImageData stopAnimationsInView:]): Instead of building a set of sets, by putting in the sets with addObject,
2399 build a single set using unionSet, and then iterate the objects instead of having to iterate the sets and then the
2400 objects in each set. The old code ended up sharing the sets with the live code, when the whole idea was to gather
2401 all the renderers because the process of stopping modifies the active sets.
2403 2005-01-12 Richard Williamson <rjw@apple.com>
2405 Fixed <rdar://problem/3926825> Safari ignores GIF loop count
2407 Get loop count from file properties, not image properties.
2409 Reviewed by Ken Kocienda.
2411 * WebCoreSupport.subproj/WebImageData.h:
2412 * WebCoreSupport.subproj/WebImageData.m:
2413 (-[WebImageData _commonTermination]):
2414 (-[WebImageData fileProperties]):
2415 (-[WebImageData _floatProperty:type:at:]):
2416 (-[WebImageData _floatFileProperty:type:]):
2417 (-[WebImageData _repetitionCount]):
2419 2005-01-11 Chris Blumenberg <cblu@apple.com>
2421 Fixed: <rdar://problem/3934749> assertion failure in WebBaseNetscapePluginView loading movie
2425 * Plugins.subproj/WebBaseNetscapePluginView.m:
2426 (-[WebBaseNetscapePluginView start]): call canStart before asserting about the webView
2428 2005-01-11 John Sullivan <sullivan@apple.com>
2432 - fixed <rdar://problem/3446838> REGRESSION (Mail): text decorations don't print
2433 (e.g. <strike>, underline)
2435 * WebCoreSupport.subproj/WebTextRenderer.m:
2436 (-[WebTextRenderer drawLineForCharacters:yOffset:withWidth:withColor:]):
2437 This bottleneck routine for drawing a line was setting the linewidth to 0 when
2438 the graphics context was not drawing to the screen. Thus, no lines. Now links
2439 are underlined when printing from Safari (as well as Mail).
2441 2005-01-11 Richard Williamson <rjw@apple.com>
2443 Fixed 3949145. CG has a much faster API for drawing lines.
2444 Switched over to that new API (CGContextStrokeLineSegments).
2446 Reviewed by John Sullivan.
2448 * WebCoreSupport.subproj/WebTextRenderer.m:
2449 (-[WebTextRenderer drawLineForCharacters:yOffset:withWidth:withColor:]):
2451 2005-01-10 Chris Blumenberg <cblu@apple.com>
2453 Fixed: <rdar://problem/3948862> REGRESSION: missing images when RTFD is pasted into editable WebView
2455 This problem occurred because we were creating image elements before creating corresponding image resources. The fix is to have AppKit call us back to create the resources before it creates the elements.
2459 * WebView.subproj/WebHTMLView.m:
2460 (-[WebHTMLView _documentFragmentFromPasteboard:allowPlainText:]): don't deal with subresources since that's now done by the following method
2461 (-[WebHTMLView resourceForData:preferredFilename:]): new handler method called by AppKit
2465 2005-01-06 David Harrison <harrison@apple.com>
2467 Reviewed by Dave Hyatt
2469 <rdar://problem/3588548> AX: tabbing does not work correctly with the screen reader and a focused link; need AXFocusedUIElement to work.
2471 * WebView.subproj/WebHTMLView.m:
2472 (-[WebHTMLView accessibilityFocusedUIElement]):
2473 Implement this so that AppKit can use it from NSAccessibilityHandleFocusChanged.
2475 2005-01-05 Chris Blumenberg <cblu@apple.com>
2477 Fixed: <rdar://problem/3936865> REGRESSION: canvas.drawImage no longer scales properly
2481 * WebCoreSupport.subproj/WebImageData.m: use the height of the inRect instead of the fromRect when setting the origin of the context
2483 2005-01-04 Chris Blumenberg <cblu@apple.com>
2485 Fixed: <rdar://problem/3928329> WebKit should pass nil for "language" to checkSpellingOfString:
2487 Reviewed by kocienda.
2489 * WebView.subproj/WebHTMLView.m:
2490 (-[WebHTMLView _isSelectionMisspelled]): pass nil not @"" for language
2492 2004-12-21 Maciej Stachowiak <mjs@apple.com>
2496 <rdar://problem/3888931> frame naming allows malicious site to bring up a window when you click on a link in another
2498 Implement a security check on name frame visbility. This is the
2499 same rule as mozilla. You can only target frames by name if you
2500 are in the same window, have the same domain as the frame or an
2501 ancestor, or if it's a top level window have the same domain as
2504 * WebView.subproj/WebFrame.m:
2505 (-[WebFrame _shouldAllowAccessFrom:]):
2506 (-[WebFrame _descendantFrameNamed:sourceFrame:]):
2507 (-[WebFrame findFrameNamed:]):
2508 * WebView.subproj/WebFramePrivate.h:
2509 * WebView.subproj/WebView.m:
2510 (-[WebView _findFrameInThisWindowNamed:sourceFrame:]):
2511 (-[WebView _findFrameNamed:sourceFrame:]):
2512 * WebView.subproj/WebViewPrivate.h:
2518 2004-12-20 Richard Williamson <rjw@apple.com>
2520 Add call to new API. ImageIO deprecated some older (although
2521 quite new!) API. This caused us to fail to build on 337 or later.
2523 Developers wanting to build on older versions of Tiger must define
2524 USE_DEPRECATED_IMAGESOURCE_API in WebImageData.m.
2528 * WebCoreSupport.subproj/WebImageData.m:
2529 (-[WebImageData propertiesAtIndex:]):
2531 2004-12-20 Richard Williamson <rjw@apple.com>
2533 Don't call Tiger SPI on Panther.
2537 * WebCoreSupport.subproj/WebTextRendererFactory.m:
2538 (+[WebTextRendererFactory createSharedFactory]):
2540 2004-12-20 Richard Williamson <rjw@apple.com>
2542 Fixed <rdar://problem/3884448> WebKit should turn on CG local font cache
2544 Enable mutli-tier font caching. We should see a performance boost with this
2549 * WebCoreSupport.subproj/WebTextRendererFactory.m:
2550 (+[WebTextRendererFactory createSharedFactory]):
2552 2004-12-20 Richard Williamson <rjw@apple.com>
2554 Fix image decoding to separately decode image meta data from actual image bits. I
2555 incorrectly consolidated decode of meta data and image bits resulting in a huge
2556 performance regression.
2558 Double size of WebCore cache on lower end machines. On the PLT run on machines with
2559 256MB of memory, too many images were being evicted, causing a re-decode on the PLT.
2560 Upping the lower limit of the cache size ensure that no images are evicted (this
2561 goes hand-in-hand with the change to the minimum object size from 32K to 40K).
2565 * WebCoreSupport.subproj/WebImageData.h:
2566 * WebCoreSupport.subproj/WebImageData.m:
2567 (+[WebImageData initialize]):
2568 (-[WebImageData _commonTermination]):
2569 (-[WebImageData _invalidateImages]):
2570 (-[WebImageData _invalidateImageProperties]):
2571 (-[WebImageData imageAtIndex:]):
2572 (-[WebImageData propertiesAtIndex:]):
2573 (-[WebImageData _cacheImages:allImages:]):
2574 (-[WebImageData decodeData:isComplete:callback:]):
2575 (-[WebImageData incrementalLoadWithBytes:length:complete:callback:]):
2576 * WebView.subproj/WebPreferences.m:
2577 (+[WebPreferences initialize]):
2579 2004-12-20 Richard Williamson <rjw@apple.com>
2581 Fixed build problem caused by change to ImageIO API.
2585 * WebCoreSupport.subproj/WebImageData.m:
2587 2004-12-19 Darin Adler <darin@apple.com>
2591 - some garbage collection fixes
2593 * Misc.subproj/WebNSObjectExtras.h: (WebCFAutorelease): Replaced the old WebNSRetainCFRelease with this
2594 much-easier-to-understand function cribbed from what David Harrison did in WebCore.
2596 * Misc.subproj/WebKitNSStringExtras.m: (+[NSString _web_encodingForResource:]): Use CFRelease here to
2597 get rid of an unnecessary use of WebNSRetainCFRelease.
2598 * Misc.subproj/WebNSURLExtras.m:
2599 (+[NSURL _web_URLWithData:relativeToURL:]): Use WebCFAutorelease instead of WebNSRetainCFRelease and autorelease.
2600 (-[NSURL _web_URLWithLowercasedScheme]): Ditto.
2601 (-[NSString _web_mapHostNameWithRange:encode:makeString:]): Use WebCFAutorelease here; the old code would not
2602 work correctly under GC.
2603 * Plugins.subproj/WebNetscapePluginPackage.m: (+[WebNetscapePluginPackage preferredLocalizationName]):
2604 Use WebCFAutorelease here; the old code would not work correctly under GC.
2606 2004-12-18 Chris Blumenberg <cblu@apple.com>
2608 Fixed: <rdar://problem/3766915> PDF content needs search to work
2610 Reviewed by kevin, john.
2612 * WebView.subproj/WebPDFView.m:
2613 (-[WebPDFView searchFor:direction:caseSensitive:wrap:]): implemented
2614 (-[WebPDFView takeFindStringFromSelection:]): new
2615 (-[WebPDFView jumpToSelection:]): new
2616 (-[WebPDFView validateUserInterfaceItem:]): new
2618 2004-12-17 Richard Williamson <rjw@apple.com>
2620 Make image decoding as lazy as possible for non threaded case; in some cases
2621 can avoid unnecessary decoding work.
2625 * WebCoreSupport.subproj/WebImageData.h:
2626 * WebCoreSupport.subproj/WebImageData.m:
2627 (-[WebImageData imageAtIndex:]):
2628 (-[WebImageData propertiesAtIndex:]):
2629 (-[WebImageData incrementalLoadWithBytes:length:complete:callback:]):
2631 2004-12-16 John Sullivan <sullivan@apple.com>
2635 One of the assertions from my previous checkin fired, so
2636 I made this code more robust.
2638 * WebCoreSupport.subproj/WebBridge.m:
2639 (-[WebBridge _preferences]):
2640 new helper method, returns global preferences if webView is nil,
2641 otherwise returns webView's preferences
2642 (-[WebBridge getObjectCacheSize]):
2643 use new helper method, remove now-unnecessary assert
2644 (-[WebBridge _retrieveKeyboardUIModeFromPreferences:]):
2647 2004-12-16 John Sullivan <sullivan@apple.com>
2651 - fixed <rdar://problem/3913523> Mail needs SPI for adding tooltips to links
2652 - cleaned up some calls to +[WebPreferences standardPreferences] that should
2653 have been using -[WebView preferences]
2655 This adds a (currently SPI-only) new feature that shows the URL of the link
2656 under the mouse in a toolTip. I tested this in Safari, but we're adding this
2657 feature for Mail, and Safari won't use it (unless of course you know the
2658 magic defaults command)
2660 * Plugins.subproj/WebBaseNetscapePluginView.m:
2661 (-[WebBaseNetscapePluginView start]):
2662 use -[WebView preferences] instead of +[WebPreferences standardPreferences]
2664 * WebCoreSupport.subproj/WebBridge.m:
2665 (-[WebBridge getObjectCacheSize]):
2667 (-[WebBridge _retrieveKeyboardUIModeFromPreferences:]):
2670 * WebView.subproj/WebBaseResourceHandleDelegate.m:
2671 (-[WebBaseResourceHandleDelegate willCacheResponse:]):
2674 * WebView.subproj/WebFrame.m:
2675 (-[WebFrame _transitionToCommitted:]):
2677 (-[WebFrame _loadItem:withLoadType:]):
2680 * WebView.subproj/WebHTMLViewInternal.h:
2681 private struct now keeps ivar for cached value of showsURLsInToolTips
2682 so it doesn't have look it up in preferences a zillion times
2684 * WebView.subproj/WebHTMLView.m:
2685 (-[WebHTMLView _updateMouseoverWithEvent:]):
2686 if private->showsURLsInToolTips is true, set the toolTip from the URL.
2687 Fall back to showing the title attribute in case some element has a title
2688 attribute but no URL.
2689 (-[WebHTMLView _mayStartDragAtEventLocation:]):
2690 use -[WebView preferences] instead of +[WebPreferences standardPreferences]
2691 (-[WebHTMLView _resetCachedWebPreferences:]):
2692 get a fresh value for private->showsURLsInToolTips
2693 (-[WebHTMLView initWithFrame:]):
2694 call _resetCachedWebPreferences the first time, and listen for WebPreferencesChanged notifications
2695 (-[WebHTMLView _handleStyleKeyEquivalent:]):
2696 use -[WebView preferences] instead of +[WebPreferences standardPreferences]
2698 * WebView.subproj/WebPreferenceKeysPrivate.h:
2699 added WebKitShowsURLsInToolTipsPreferenceKey
2701 * WebView.subproj/WebPreferences.m:
2702 (+[WebPreferences initialize]):
2703 initialize WebKitShowsURLsInToolTipsPreferenceKey to 0
2704 (-[WebPreferences showsURLsInToolTips]):
2705 return WebKitShowsURLsInToolTipsPreferenceKey value
2706 (-[WebPreferences setShowsURLsInToolTips:]):
2707 set WebKitShowsURLsInToolTipsPreferenceKey value
2709 * WebView.subproj/WebPreferencesPrivate.h:
2710 add declarations for showsURLsInToolTips and setter
2712 * WebView.subproj/WebTextView.m:
2713 (-[WebTextView _preferences]):
2714 new helper method that gets preferences from webView if there is a webView,
2715 otherwise gets global preferences
2716 (-[WebTextView setFixedWidthFont]):
2717 use new helper method rather than always using global preferences
2718 (-[WebTextView initWithFrame:]):
2719 observe WebPreferencesChangedNotification instead of unnecessarily general
2720 NSUserDefaultsChangedNotification
2722 2004-12-14 John Sullivan <sullivan@apple.com>
2726 - rest of WebKit fix for <rdar://problem/3790011> undoable operations all say "Undo"
2727 in the menu, no specific action names
2729 I only know of one loose end currently, which I wrote up as <rdar://problem/3920971> Edit menu
2730 says "Undo Change Attributes" when it should say "Undo Set Color", from font panel
2732 * WebView.subproj/WebHTMLView.m:
2733 (-[WebHTMLView concludeDragForDraggingInfo:actionMask:]):
2734 use WebUndoActionSetColor when dragging color swatch
2735 (-[WebHTMLView _applyStyleToSelection:withUndoAction:]):
2736 new WebUndoAction parameter, passed across bridge
2737 (-[WebHTMLView _toggleBold]):
2738 use WebUndoActionSetFont
2739 (-[WebHTMLView _toggleItalic]):
2740 use WebUndoActionSetFont
2741 (-[WebHTMLView pasteFont:]):
2742 use WebUndoActionPasteFont
2743 (-[WebHTMLView changeFont:]):
2744 use WebUndoActionSetFont
2745 (-[WebHTMLView changeAttributes:]):
2746 use WebUndoActionChangeAttributes
2747 (-[WebHTMLView _undoActionFromColorPanelWithSelector:]):
2748 new method, returns WebUndoActionSetBackgroundColor or WebUndoActionSetColor
2749 (-[WebHTMLView _changeCSSColorUsingSelector:inRange:]):
2750 now calls _undoActionFromColorPanelWithSelector
2751 (-[WebHTMLView changeColor:]):
2752 use WebUndoActionSetColor
2753 (-[WebHTMLView _alignSelectionUsingCSSValue:withUndoAction:]):
2754 new WebUndoAction parameter, passed through
2755 (-[WebHTMLView alignCenter:]):
2756 use WebUndoActionCenter
2757 (-[WebHTMLView alignJustified:]):
2758 use WebUndoActionJustify
2759 (-[WebHTMLView alignLeft:]):
2760 use WebUndoActionAlignLeft
2761 (-[WebHTMLView alignRight:]):
2762 use WebUndoActionAlignRight
2763 (-[WebHTMLView subscript:]):
2764 use WebUndoActionAlignSubscript
2765 (-[WebHTMLView superscript:]):
2766 use WebUndoActionAlignSuperscript
2767 (-[WebHTMLView unscript:]):
2768 use WebUndoActionAlignUnscript
2769 (-[WebHTMLView underline:]):
2770 use WebUndoActionAlignUnderline
2772 * WebView.subproj/WebView.m:
2773 (-[WebView setTypingStyle:]):
2774 pass WebUndoActionUnspecified through as new parameter since we don't have any more specific info
2775 (-[WebView applyStyle:]):
2778 2004-12-14 Richard Williamson <rjw@apple.com>
2780 Helper method to get URL of plugin view.
2784 * Misc.subproj/WebNSViewExtras.m:
2785 (-[NSView _webViewURL]):
2787 2004-12-14 Vicki Murley <vicki@apple.com>
2791 <rdar://problem/3855573> Remove reference to "WebScriptMethods" from WebScriptObject.h comments
2793 * Plugins.subproj/WebPlugin.h: changed instances of "WebScriptMethods" to "WebScripting" in this
2794 file as well, as requested in the bug report
2796 2004-12-13 Maciej Stachowiak <mjs@apple.com>
2800 <rdar://problem/3912488> Mail throws an exception after backspacing "away" inline input
2802 * WebView.subproj/WebHTMLView.m:
2803 (-[WebHTMLView setMarkedText:selectedRange:]): Don't try to set a selection if
2804 we end up with no marked text, since that case fails and is unnecessary.
2806 2004-12-14 John Sullivan <sullivan@apple.com>
2810 - WebKit part of plumbing of fix for <rdar://problem/3790011> undoable operations all say "Undo" in the menu,
2811 no specific action names
2813 * WebCoreSupport.subproj/WebBridge.m:
2814 (-[WebBridge nameForUndoAction:]):
2815 renamed from setUndoActionNamePlaceholder, replaced arbitrary integers with enum values, and
2816 handled new "unspecified" case as a fallback
2818 2004-12-13 Richard Williamson <rjw@apple.com>
2820 Fixed <rdar://problem/3887767> LiveConnect doesn't propagate Java exceptions back to JavaScript (prevents security suite from running)
2824 * Plugins.subproj/WebJavaPlugIn.h:
2826 2004-12-13 John Sullivan <sullivan@apple.com>
2830 - fixed <rdar://problem/3744583> Safari can not quit when a webpage has a login sheet
2831 that can't be cancelled.
2833 The proper fix for this would be to change the class of the NSPanel in the nib file.
2834 But since this would require a localization change, I did a run-time hack instead.
2835 I'll file a bug about fixing this when we're out of localization freeze.
2837 * Panels.subproj/WebAuthenticationPanel.m:
2838 (-[WebAuthenticationPanel replacePanelWithSubclassHack]):
2839 new method, creates a new panel that is identical to the original one except that
2840 it's our subclass, and moves all the subviews of the original panel into the new one.
2841 (-[WebAuthenticationPanel loadNib]):
2842 call replacePanelWithSubclassHack
2843 (-[NonBlockingPanel _blocksActionWhenModal:]):
2844 only method of new NSPanel subclass; overrides this SPI to allow the user to quit
2845 when one of these panels/sheets is on-screen
2847 2004-12-10 Richard Williamson <rjw@apple.com>
2849 Fixed <rdar://problem/3898708> REGRESSION (8A314-8A317): World Clock's short hand not displayed (ImageIO problem with PDF?)
2850 Fixed <rdar://problem/3914012> use CG directly for pdf images not ImageIO
2852 Create a PDF document and draw that instead of using ImageIO to create a rasterized image.
2856 * WebCoreSupport.subproj/WebImageData.h:
2857 * WebCoreSupport.subproj/WebImageData.m:
2858 (-[WebImageData setIsPDF:]):
2859 (-[WebImageData isPDF]):
2860 (-[WebImageData dealloc]):
2861 (-[WebImageData decodeData:isComplete:callback:]):
2862 (-[WebImageData incrementalLoadWithBytes:length:complete:callback:]):
2863 (-[WebImageData size]):
2864 (-[WebImageData animate]):
2865 (-[WebImageData _createPDFWithData:]):
2866 (-[WebImageData _PDFDocumentRef]):
2867 (-[WebImageData _PDFDrawInContext:]):
2868 (-[WebImageData _PDFDrawFromRect:toRect:operation:alpha:flipped:context:]):
2869 * WebCoreSupport.subproj/WebImageRenderer.h:
2870 * WebCoreSupport.subproj/WebImageRenderer.m:
2871 (-[WebImageRenderer size]):
2872 (-[WebImageRenderer incrementalLoadWithBytes:length:complete:callback:]):
2873 (-[WebImageRenderer drawImageInRect:fromRect:compositeOperator:context:]):
2876 2004-12-10 John Sullivan <sullivan@apple.com>
2880 - fixed <rdar://problem/3855127> Error while printing w/o sheet, then window is left in a bad state,
2881 if there's no default printer set
2883 * WebView.subproj/WebHTMLView.m:
2884 (-[WebHTMLView beginDocument]):
2885 Our implementation of knowsPageRange puts the WebHTMLView into a special "printing mode". We must
2886 exit the "printing mode" to return to normal behavior. This is normally done in endDocument.
2887 However, it turns out that if there's an exception in [super beginDocument], then endDocument
2888 will not be called (lame-o AppKit API). So, we handle that case by catching the exception and
2889 exiting the "printing mode" in beginDocument when it occurs.
2891 2004-12-09 Richard Williamson <rjw@apple.com>
2893 Fixed <rdar://problem/3905789> Burn Disc image vibrates rapidly
2895 Restrict our support for animated images to GIF. We used to
2896 use presence of more than one image in a resource to determine
2897 if an image should be animated. This caused us to animate icns!
2898 If we ever support any other animated image formats we'll have
2903 * WebCoreSupport.subproj/WebImageData.h:
2904 * WebCoreSupport.subproj/WebImageData.m:
2905 (-[WebImageData shouldAnimate]):
2906 * WebCoreSupport.subproj/WebImageRenderer.m:
2907 (-[WebImageRenderer _startOrContinueAnimationIfNecessary]):
2909 2004-12-09 Richard Williamson <rjw@apple.com>
2911 Make WebPluginDatabase.h private (Dashboard needs SPI).
2913 * WebKit.pbproj/project.pbxproj:
2917 2004-12-09 Chris Blumenberg <cblu@apple.com>
2919 Workaround for this exception being raised during download:
2920 [WebDownload connection:willStopBufferingData:]: selector not recognized
2924 * Misc.subproj/WebDownload.m:
2925 (-[WebDownload connection:willStopBufferingData:]): implement this method so no exception is raised. It is a bug in Foundation that this method is being called, but it's too late to fix Foundation since it has already been submitted this week. This workaround will prevent any problems from affecting users.
2927 2004-12-08 Richard Williamson <rjw@apple.com>
2929 Fixed <rdar://problem/3911719> REGRESSION: Images no longer scale vertically
2930 Account for scaling correctly when taking into account progressively
2933 Also added implementation of repetition count for animated GIF images.
2934 Also replaced strings with new constants from CFImageProperties.h
2936 Also fixed possible problem with -(NSSize)size implementation,
2937 relevant to Panther only.
2941 * WebCoreSupport.subproj/WebImageData.m:
2942 (-[WebImageData _floatProperty:type:at:]):
2943 (-[WebImageData _frameDurationAt:]):
2944 (-[WebImageData _repetitionCount]):
2945 * WebCoreSupport.subproj/WebImageRenderer.m:
2946 (-[WebImageRenderer size]):
2948 2004-12-08 Chris Blumenberg <cblu@apple.com>
2950 Removed NPN wrappers since these no longer need to be defined to make the QT plug-in work
2951 since 3828925 has been fixed.
2955 * Plugins.subproj/WebNetscapePluginPackage.m:
2956 (-[WebNetscapePluginPackage load]): use under-bar symbols since non-under-bar wrappers have been removed
2957 * Plugins.subproj/npapi.m: removed NPN wrappers
2958 * WebKit.exp: removed symbols
2960 2004-12-08 Ken Kocienda <kocienda@apple.com>
2964 * WebView.subproj/WebHTMLView.m:
2965 (-[WebHTMLView drawRect:]): Work around for this bug:
2966 <rdar://problem/3908282> REGRESSION (Mail): No drag image dragging selected text in Blot and Mail
2967 The reason for the workaround is that this method is called explicitly from the code
2968 to generate a drag image, and at that time, getRectsBeingDrawn:count: will return a zero count.
2969 This code change uses the passed-in rect when the count is zero.
2971 2004-12-07 Administrator <cblu@apple.com>
2973 Support for fix for:
2974 <rdar://problem/3734309> Safari doesn't open folders in title bar menu with non-Roman names using Cmd+click
2978 * Misc.subproj/WebNSURLExtras.h:
2979 * Misc.subproj/WebNSURLExtras.m:
2980 (+[NSURL _web_URLWithUserTypedString:relativeToURL:]): renamed to take relativeToURL parameter
2981 (+[NSURL _web_URLWithUserTypedString:]): call _web_URLWithUserTypedString:relativeToURL: with nil for URL
2983 2004-12-07 Richard Williamson <rjw@apple.com>
2985 Fixed <rdar://problem/3905564> REGRESSION (Tiger); in History menu, pixel size appears but is wrong for standalone images in Safari.
2989 * WebCoreSupport.subproj/WebImageRenderer.m:
2990 (-[WebImageRenderer size]):
2992 2004-12-07 Richard Williamson <rjw@apple.com>
2994 Support threaded image decoding on machines w/ >= 2 CPUs.
2996 Reviewed by Maciej and Chris.
2998 * Misc.subproj/WebKitSystemBits.h:
2999 * Misc.subproj/WebKitSystemBits.m:
3000 (WebSystemMainMemory):
3002 * WebCoreSupport.subproj/WebImageData.h:
3003 * WebCoreSupport.subproj/WebImageData.m:
3004 (+[WebImageData initialize]):
3005 (-[WebImageData init]):
3006 (-[WebImageData _commonTermination]):
3007 (-[WebImageData dealloc]):
3008 (-[WebImageData _invalidateImages]):
3009 (-[WebImageData _imageSourceOptions]):
3010 (-[WebImageData imageAtIndex:]):
3011 (-[WebImageData propertiesAtIndex:]):
3012 (-[WebImageData _createImages]):
3013 (-[WebImageData decodeData:isComplete:callback:]):
3014 (-[WebImageData incrementalLoadWithBytes:length:complete:callback:]):
3016 (-[WebImageData tileInRect:fromPoint:context:]):
3017 (-[WebImageData isNull]):
3018 (-[WebImageData size]):
3019 (-[WebImageData _frameDurationAt:]):
3020 (-[WebImageData _frameDuration]):
3021 (+[WebImageData stopAnimationsInView:]):
3022 (-[WebImageData addAnimatingRenderer:inView:]):
3023 (-[WebImageData removeAnimatingRenderer:]):
3024 * WebCoreSupport.subproj/WebImageDecodeItem.h: Added.
3025 * WebCoreSupport.subproj/WebImageDecodeItem.m: Added.
3026 (+[WebImageDecodeItem decodeItemWithImage:data:isComplete:callback:]):
3027 (-[WebImageDecodeItem initWithImage:data:isComplete:callback:]):
3028 (-[WebImageDecodeItem finalize]):
3029 (-[WebImageDecodeItem dealloc]):
3030 * WebCoreSupport.subproj/WebImageDecoder.h: Added.
3031 * WebCoreSupport.subproj/WebImageDecoder.m: Added.
3032 (decoderNotifications):
3033 (+[WebImageDecoder initialize]):
3034 (+[WebImageDecoder notifyMainThread]):
3035 (+[WebImageDecoder sharedDecoder]):
3036 (+[WebImageDecoder performDecodeWithImage:data:isComplete:callback:]):
3037 (+[WebImageDecoder imageDecodesPending]):
3038 (+[WebImageDecoder decodeComplete:status:]):
3039 (-[WebImageDecoder init]):
3040 (-[WebImageDecoder dealloc]):
3041 (-[WebImageDecoder finalize]):
3042 (-[WebImageDecoder removeItem]):
3043 (-[WebImageDecoder addItem:]):
3044 (-[WebImageDecoder decodeItem:]):
3046 (startDecoderThread):
3047 * WebCoreSupport.subproj/WebImageRenderer.m:
3048 (-[WebImageRenderer initWithData:MIMEType:]):
3049 (-[WebImageRenderer initWithContentsOfFile:]):
3050 (-[WebImageRenderer incrementalLoadWithBytes:length:complete:callback:]):
3051 (-[WebInternalImage incrementalLoadWithBytes:length:complete:callback:]):
3052 * WebKit.pbproj/project.pbxproj:
3053 * WebView.subproj/WebImageRepresentation.m:
3054 (-[WebImageRepresentation receivedData:withDataSource:]):
3055 (-[WebImageRepresentation receivedError:withDataSource:]):
3056 (-[WebImageRepresentation finishedLoadingWithDataSource:]):
3058 2004-12-07 Chris Blumenberg <cblu@apple.com>
3060 Fix for performance regression.
3064 * WebCoreSupport.subproj/WebBridge.m:
3065 (-[WebBridge objectLoadedFromCacheWithURL:response:data:]): construct the WebResource without copying the data
3067 2004-12-07 Chris Blumenberg <cblu@apple.com>
3069 Fixed: <rdar://problem/3909243> REGRESSION: large standalone images stop loading part way through
3073 * WebView.subproj/WebBaseResourceHandleDelegate.h:
3074 * WebView.subproj/WebMainResourceClient.m:
3075 (-[WebMainResourceClient addData:]): call super so it buffers the data
3077 2004-12-06 Richard Williamson <rjw@apple.com>
3079 Use the AppKit's font rendering mode. This fixes 3905347, but we still need to track down
3080 and resolve why metrics have changed for Courier. This may be caused by changes in
3085 * WebCoreSupport.subproj/WebTextRenderer.m:
3086 (_AppkitGetCGRenderingMode):
3090 2004-12-06 Chris Blumenberg <cblu@apple.com>
3092 Forgot to commit copied header.
3094 * DOM.subproj/DOMPrivate.h:
3096 2004-12-06 Chris Blumenberg <cblu@apple.com>
3098 Fixed: <rdar://problem/3907381> NSURLConnection and WebKit buffer 2 copies of incoming data
3102 * WebView.subproj/WebBaseResourceHandleDelegate.h:
3103 * WebView.subproj/WebBaseResourceHandleDelegate.m:
3104 (+[WebBaseResourceHandleDelegate initialize]): cache check to see if Foundation supports access to its buffered data
3105 (-[WebBaseResourceHandleDelegate addData:]): don't buffer data if Foundation is buffering it for us
3106 (-[WebBaseResourceHandleDelegate saveResource]): when creating a WebResource, pass NO for copyData since we know it won't be mutated
3107 (-[WebBaseResourceHandleDelegate resourceData]): return the buffered data from the connection if it supports it
3108 (-[WebBaseResourceHandleDelegate willStopBufferingData:]): make a mutable copy of the data from NSURLConnection so we can continue buffering
3109 (-[WebBaseResourceHandleDelegate willCacheResponse:]): removed optimization that used the cached response data to save the resource since that is obsolete by this change
3110 (-[WebBaseResourceHandleDelegate connection:willStopBufferingData:]): new callback from NSURLConnection, informs us that NSURLConnection has given up buffering
3111 * WebView.subproj/WebDataSource.m:
3112 (-[WebDataSource _receivedData:]): removed buffering code since that's done by NSURLConnection and the main client
3113 (-[WebDataSource _setData:]): removed unnecessary cast since the resourceData ivar is now an NSData instead of NSMutableData
3114 (-[WebDataSource data]): return resourceData ivar, else return the resourceData from the main client
3115 * WebView.subproj/WebDataSourcePrivate.h:
3116 * WebView.subproj/WebMainResourceClient.m:
3117 (-[WebMainResourceClient releaseResources]): store resourceData on the data source so it can continue to have data after the main client has gone away
3118 (-[WebMainResourceClient connection:didReceiveData:lengthReceived:]):don't call [dataSource data] just to get the length of data received since [dataSource data] can now cause data to be copied
3119 (-[WebMainResourceClient connectionDidFinishLoading:]): ditto
3120 * WebView.subproj/WebResource.m:
3121 (-[WebResource initWithData:URL:MIMEType:textEncodingName:frameName:]): call following method with YES for copyData
3122 (-[WebResource _initWithData:URL:MIMEType:textEncodingName:frameName:copyData:]): new initializer, allows caller to choose whether or not the data is copied
3123 * WebView.subproj/WebResourcePrivate.h:
3125 2004-12-06 Richard Williamson <rjw@apple.com>
3127 Fixed <rdar://problem/3903749> REGRESSION (8A321): WebKit gets incorrect glyph metrics due to change in how AppKit uses CGFont
3129 Use CGFontRef direction when both getting font metrics and drawing
3130 glyphs, instead on depending on [NSFont set].
3134 * WebCoreSupport.subproj/WebTextRenderer.m:
3138 2004-12-06 Ken Kocienda <kocienda@apple.com>
3140 Reviewed by Harrison
3144 <rdar://problem/3906930> Hitting return key in editable content inserts br elements instead of blocks
3146 * WebView.subproj/WebHTMLView.m:
3147 (-[WebHTMLView insertNewline:]): One-line change to call insert-block rather than insert-br method
3150 2004-12-04 Darin Adler <darin@apple.com>
3154 - fixed <rdar://problem/3846079> assertion failure in WebHTMLView(WebPrivate) removeTrackingRect at boots.com
3155 - fixed <rdar://problem/3857737> REGRESSION (165-166): clicking in a text field that's scrolled to the right causes it to scroll all the way left
3156 - fixed <rdar://problem/3861952> REGRESSION (165-166): selection is cleared when you start to scroll a frame
3158 * WebView.subproj/WebHTMLViewInternal.h: Added handlingMouseDown flag.
3159 * WebView.subproj/WebHTMLView.m:
3160 (-[WebHTMLView _addTrackingRect:owner:userData:assumeInside:useTrackingNum:]): Allow passing in a
3161 tracking number of 0, which means no existing tracking number.
3162 (-[WebHTMLView _addTrackingRects:owner:userDataList:assumeInsideList:trackingNums:count:]): Ditto.
3163 (-[WebHTMLView removeTrackingRect:]): Allow removing a tracking number of 0, which is a no-op.
3164 (-[WebHTMLView _removeTrackingRects:count:]): Ditto.
3165 (-[WebHTMLView acceptsFirstResponder]): Changed check to use handlingMouseDown flag instead of mouseDownEvent
3166 field since that field is set up too early in the mouse down event handling process.
3167 (-[WebHTMLView mouseDown:]): Added code to set handlingMouseDown flag.
3169 - fixed part of <rdar://problem/3829808> Safari crashes when adding a DOM node that was removed from an XMLHTTP request result
3171 * WebCoreSupport.subproj/WebBridge.m:
3172 (-[WebBridge syncLoadResourceWithURL:customHeaders:postData:finalURL:responseHeaders:statusCode:]):
3173 Changed code around so that it won't try to create a WebResource when the load fails.
3175 - moved next/previous links into private structure with the rest of WebFrame fields
3176 (We have a rule against putting new fields into obejcts that are part of our public API.)
3178 * WebView.subproj/WebFrame.h: Remove _nextSibling and _previousSibling.
3179 * WebView.subproj/WebFramePrivate.h: Added nextSibling and previousSibling fields to private class.
3180 * WebView.subproj/WebFrame.m: Got rid of some tabs in this file.
3181 (-[WebFrame _addChild:]): Changed code to use fields inside _private.
3182 (-[WebFrame _removeChild:]): Ditto.
3183 (-[WebFrame _nextFrameWithWrap:]): Ditto.
3184 (-[WebFrame _previousFrameWithWrap:]): Ditto.
3186 2004-12-04 Chris Blumenberg <cblu@apple.com>
3189 <rdar://problem/3685766> WebDataSource is missing subresources when they use cached WebCore data
3190 <rdar://problem/3722434> REGRESSION?: Assertion failure trying to drag image in iframe (itapema.sc.gov.br)
3191 <rdar://problem/3903173> REGRESSION (172-TOT): assertion failure and crash in slotAllData logging into hotmail account
3192 <rdar://problem/3902749> REGRESSION (Tiger): missing image symbol does not appear
3194 Reviewed by darin, rjw, kocienda.
3196 * WebCoreSupport.subproj/WebBridge.m:
3197 (-[WebBridge objectLoadedFromCacheWithURL:response:data:]):
3198 (-[WebBridge syncLoadResourceWithURL:customHeaders:postData:finalURL:responseHeaders:statusCode:]):
3199 * WebCoreSupport.subproj/WebSubresourceClient.m:
3200 (-[WebSubresourceClient didFinishLoading]):
3201 * WebView.subproj/WebFrame.m:
3202 (-[WebFrame _opened]):
3203 (-[WebFrame _internalLoadDelegate]):
3204 (-[WebFrame _sendResourceLoadDelegateMessagesForURL:response:length:]):
3205 * WebView.subproj/WebFrameInternal.h:
3207 2004-12-04 Darin Adler <darin@apple.com>
3211 - fixed remaining bit of <rdar://problem/3814237> REGRESSION (Mail): Copy/paste style does not set color in Mail compose window
3213 * WebView.subproj/WebHTMLView.m: (-[WebHTMLView _styleFromFontAttributes:]): When translating from
3214 an attribute dictionary to a CSS declaration, treat missing values according to the defaults defined
3215 in <AppKit/NSAttributedString.h>. Before the code was treating them as "no change", which is incorrect.
3217 * English.lproj/StringsNotToBeLocalized.txt: Add a string from the above change.
3221 2004-12-03 Ken Kocienda <kocienda@apple.com>
3225 Roll out some recent changes by Chris that caused a performance regression.
3226 Fix is in hand, but it is a little risky this close to a submission. So,
3227 we have decided to roll back the change with the regression and roll in
3228 the new code after we submit.
3230 * WebCoreSupport.subproj/WebBridge.m:
3231 (-[WebBridge objectLoadedFromCacheWithURL:response:size:]):
3232 (-[WebBridge syncLoadResourceWithURL:customHeaders:postData:finalURL:responseHeaders:statusCode:]):
3233 * WebCoreSupport.subproj/WebSubresourceClient.m:
3234 (-[WebSubresourceClient didFinishLoading]):
3235 * WebView.subproj/WebFrame.m:
3236 (-[WebFrame _opened]):
3237 (-[WebFrame _internalLoadDelegate]):
3238 * WebView.subproj/WebFrameInternal.h:
3240 2004-12-02 Richard Williamson <rjw@apple.com>
3242 Fixed <rdar://problem/3841332> REGRESSION (125.9-167u): repro crash in -[KWQPageState invalidate] involving .Mac images
3244 Ensure that the document is cleared when leaving a non-HTML page. This ensures that
3245 the b/f cache won't incorrectly trash the previous state when restoring.
3249 * WebView.subproj/WebFrame.m:
3250 (-[WebFrame _setState:]):
3252 2004-12-02 Ken Kocienda <kocienda@apple.com>
3256 <rdar://problem/3748323> Problem with -[WebView editableDOMRangeForPoint:] (-isFlipped not taken into account?)
3257 <rdar://problem/3852590> REGRESSION (Mail): Dropped content appears in wrong place if Mail message is scrolled down
3259 When implementing drag and drop, moveDragCaretToPoint: and editableDOMRangeForPoint: are used in
3260 concert to track the mouse and determine a drop location, respectively. However, moveDragCaretToPoint:
3261 did a conversion of the passed-in point to the document view's coordinate space, whereas
3262 editableDOMRangeForPoint: did not. Now it does.
3264 Note that I will need to coordinate with Grant to have him roll out some code in Mail that
3265 attempts to work around this problem (unsuccessfully), and actually manages to block the
3266 real fix (which needs to be in WebKit).
3268 * WebView.subproj/WebView.m:
3269 (-[WebView editableDOMRangeForPoint:]): Convert the passed-in point to the document view's coordinate space.
3271 2004-12-02 Richard Williamson <rjw@apple.com>
3273 Fixed <rdar://problem/3895810> FATAL ERROR: <WebTextRenderer: 0x9328a20> unable to initialize with font "Times-Roman 16.00 pt. S ....
3275 We have a hack to replace Times with Times New Roman if we fail
3276 to setup Times. If we then fail to setup Times New Roman we
3277 don't attempt to further fallback to the system font. Added
3278 that additional fallback.
3282 * WebCoreSupport.subproj/WebTextRenderer.m:
3283 (+[WebTextRenderer webFallbackFontFamily]):
3284 (-[WebTextRenderer initWithFont:usingPrinterFont:]):
3286 2004-12-02 Richard Williamson <rjw@apple.com>
3288 Fixed build problem on Tiger8A821. Private macro and function
3289 we were using have been deprecated,
3293 * WebCoreSupport.subproj/WebTextRenderer.m:
3294 (-[WebTextRenderer initWithFont:usingPrinterFont:]):
3296 2004-12-01 Chris Blumenberg <cblu@apple.com>
3298 Fixed: <rdar://problem/3879870> Flash Player unable to stop data stream from continuing to download by returning -1 from NPP_Write
3299 Also improved and cleaned-up the plug-in stream termination code.
3303 * Plugins.subproj/WebBaseNetscapePluginStream.h:
3304 * Plugins.subproj/WebBaseNetscapePluginStream.m:
3305 (+[WebBaseNetscapePluginStream reasonForError:]): return NPRES_DONE for a nil error
3306 (-[WebBaseNetscapePluginStream _pluginCancelledConnectionError]): new, factored out from other methods
3307 (-[WebBaseNetscapePluginStream errorForReason:]): new
3308 (-[WebBaseNetscapePluginStream dealloc]): release MIME type
3309 (-[WebBaseNetscapePluginStream setMIMEType:]): new
3310 (-[WebBaseNetscapePluginStream startStreamResponseURL:expectedContentLength:lastModifiedDate:MIMEType:]): call setMIMEType so we can use it in _pluginCancelledConnectionError, call renamed methods
3311 (-[WebBaseNetscapePluginStream _destroyStream]): prepended underscore, replaced some early returns with asserts as the callers are now smarter
3312 (-[WebBaseNetscapePluginStream _destroyStreamWithReason:]): prepended underscore, only call _destroyStream if there is an error or if the load is complete and there is no more data to be streamed
3313 (-[WebBaseNetscapePluginStream cancelLoadWithError:]): new, overridden by subclasses to cancel the actual NSURLConnection
3314 (-[WebBaseNetscapePluginStream destroyStreamWithError:]): new, calls _destroyStreamWithReason
3315 (-[WebBaseNetscapePluginStream finishedLoadingWithData:]): call renamed methods
3316 (-[WebBaseNetscapePluginStream _deliverData]): prepended underscore, call cancelLoadAndDestroyStreamWithError if NPP_Write returns a negative number
3317 * Plugins.subproj/WebBaseNetscapePluginView.m:
3318 (-[WebBaseNetscapePluginView destroyStream:reason:]): call cancelLoadAndDestroyStreamWithError
3319 * Plugins.subproj/WebNetscapePluginRepresentation.m:
3320 (-[WebNetscapePluginRepresentation receivedError:withDataSource:]): call destroyStreamWithError
3321 (-[WebNetscapePluginRepresentation cancelLoadWithError:]): new, override method, tell the data source to stop loading
3322 * Plugins.subproj/WebNetscapePluginStream.m:
3323 (-[WebNetscapePluginStream cancelLoadWithError:]): new, override method, tell the loader to stop
3324 (-[WebNetscapePluginStream stop]): call cancelLoadAndDestroyStreamWithError
3325 (-[WebNetscapePluginConnectionDelegate isDone]): new
3326 (-[WebNetscapePluginConnectionDelegate didReceiveResponse:]): call cancelLoadAndDestroyStreamWithError
3327 (-[WebNetscapePluginConnectionDelegate didFailWithError:]): call destroyStreamWithError
3329 2004-12-01 Kevin Decker <kdecker@apple.com>
3331 Reviewed by Harrison.
3333 Fixed: <rdar://problem/3228878> potential performance problem in finding in large framesets
3335 Got rid of O(N^2) conditions in _nextSibling and _previousSibling of where we were looking up self in the parent array of frames.
3337 * WebView.subproj/WebFrame.h: Added two new pointers, one for the previous kid and one for the next kid
3338 * WebView.subproj/WebFrame.m:
3339 (-[WebFrame _addChild:]): Updates the previous frame and the next frame after this child
3340 (-[WebFrame _removeChild:]): ditto
3341 (-[WebFrame _nextSibling]): just return the pointer now
3342 (-[WebFrame _previousSibling]): ditto
3344 2004-11-30 Chris Blumenberg <cblu@apple.com>
3347 <rdar://problem/3685766> WebDataSource is missing subresources when they use cached WebCore data
3348 <rdar://problem/3722434> REGRESSION?: Assertion failure trying to drag image in iframe (itapema.sc.gov.br)
3352 * WebCoreSupport.subproj/WebBridge.m:
3353 (-[WebBridge objectLoadedFromCacheWithURL:response:data:]): renamed to pass all data for the resource, moved delegate code to new method
3354 (-[WebBridge syncLoadResourceWithURL:customHeaders:postData:finalURL:responseHeaders:statusCode:]): call renamed method
3355 * WebCoreSupport.subproj/WebSubresourceClient.m:
3356 (-[WebSubresourceClient didFinishLoading]): call renamed method
3357 * WebView.subproj/WebFrame.m:
3358 (-[WebFrame _opened]): call _sendResourceLoadDelegateMessagesForURL:response:length:, not objectLoadedFromCacheWithURL:response:data:
3359 (-[WebFrame _internalLoadDelegate]):
3360 (-[WebFrame _sendResourceLoadDelegateMessagesForURL:response:length:]): moved from objectLoadedFromCacheWithURL:response:data:
3361 * WebView.subproj/WebFrameInternal.h:
3363 2004-11-29 Darin Adler <darin@apple.com>
3367 - worked around bug in Panther where NSScroller calls _destinationFloatValueForScroller: on superview
3368 without first checking if it's implemented
3370 * WebView.subproj/WebHTMLView.m: (-[WebHTMLView _destinationFloatValueForScroller:]):
3371 Implemented. Calls floatValue on the scroller.
3373 * English.lproj/StringsNotToBeLocalized.txt: Update for recent changes.
3375 2004-11-23 Chris Blumenberg <cblu@apple.com>
3377 Fixed: <rdar://problem/3890944> disable icon database for Dashboard
3381 * Misc.subproj/WebIconDatabase.h:
3382 * Misc.subproj/WebIconDatabase.m:
3383 (-[WebIconDatabase init]): don't create dictionaries if disabled
3384 (-[WebIconDatabase iconForURL:withSize:cache:]): return default icon if disabled
3385 (-[WebIconDatabase iconURLForURL:]): return nil if disabled
3386 (-[WebIconDatabase retainIconForURL:]): return if disabled
3387 (-[WebIconDatabase releaseIconForURL:]): ditto
3388 (-[WebIconDatabase delayDatabaseCleanup]): ditto
3389 (-[WebIconDatabase allowDatabaseCleanup]): ditto
3390 (-[WebIconDatabase _isEnabled]): new
3391 (-[WebIconDatabase _setIcon:forIconURL:]): assert if called when disabled, moved to own category implementation
3392 (-[WebIconDatabase _setHaveNoIconForIconURL:]): ditto
3393 (-[WebIconDatabase _setIconURL:forURL:]): ditto
3394 (-[WebIconDatabase _createFileDatabase]): tweak
3395 (-[WebIconDatabase _applicationWillTerminate:]): moved out of public code
3396 * Misc.subproj/WebIconDatabasePrivate.h:
3397 * Misc.subproj/WebIconLoader.m:
3398 * WebView.subproj/WebDataSource.m:
3399 (-[WebDataSource _updateIconDatabaseWithURL:]): assert if called when icon DB is disabled
3400 (-[WebDataSource _loadIcon]): don't load icon if icon DB is disabled
3402 2004-11-22 David Hyatt <hyatt@apple.com>
3404 Make sure the WebCore cache grows at 512mb and at 1024mb exactly.
3408 * WebCoreSupport.subproj/WebBridge.m:
3409 (-[WebBridge getObjectCacheSize]):
3411 2004-11-22 Richard Williamson <rjw@apple.com>
3413 Fixed <rdar://problem/3891737> WebPreferences do not work if they are set before set on the WebView
3415 John found this problem and suggested the fix.
3417 Reviewed by John Louch.
3419 * WebView.subproj/WebView.m:
3420 (-[WebView setPreferences:]):
3422 2004-11-22 Ken Kocienda <kocienda@apple.com>
3424 Reviewed by Harrison
3426 * WebCoreSupport.subproj/WebBridge.m:
3427 (-[WebBridge canPaste]): Call WebView _canPaste.
3428 * WebView.subproj/WebView.m:
3429 (-[WebView _canPaste]): Try to forward to document view's implementation. Only WebHTMLView
3430 answers right now. Returns NO otherwise.
3431 * WebView.subproj/WebViewInternal.h: Add _canPaste method to WebView.
3433 2004-11-22 Maciej Stachowiak <mjs@apple.com>
3435 Back out the window closing fix, it seems to be causing crashes.
3437 * WebView.subproj/WebFrame.m:
3438 (-[WebFrame _detachFromParent]):
3440 2004-11-20 Maciej Stachowiak <mjs@apple.com>
3444 <rdar://problem/3710101> _web_userVisibleString makes URL autocomplete roughly 2x slower
3446 * Misc.subproj/WebNSURLExtras.h:
3447 * Misc.subproj/WebNSURLExtras.m:
3448 (-[NSString _web_isUserVisibleURL]): New SPI to check if a URL
3449 string is already in user-visible form (i.e. converting it to an
3450 NSURL and then back via _web_userVisibleString would not change
3453 2004-11-19 Maciej Stachowiak <mjs@apple.com>
3457 <rdar://problem/3190977> closing window with many tabs in it can be quite slow
3459 * WebView.subproj/WebFrame.m:
3460 (-[WebFrame _detachFromParent]): autorelease bridge instead of releasing it,
3461 to make window and tab closing more responsive - this way the deallocation happens
3462 after the windoow or tab appears to close.
3466 2004-11-19 Chris Blumenberg <cblu@apple.com>
3468 Fixed: <rdar://problem/3880387> REGRESSION: www.shockplay.com site gives "Unexpected server response"
3472 * Plugins.subproj/WebBaseNetscapePluginView.m:
3473 (-[NSData _web_locationAfterFirstBlankLine]): support both formats ("\r\n\n" and "\r\n\r\n") for separating header data from body data because Shockwave still sends the prior format
3475 2004-11-19 Ken Kocienda <kocienda@apple.com>
3477 Reviewed by Harrison
3481 <rdar://problem/3655241> setTypingStyle: does not set the real typing style, and typingStyle does not return it
3483 * WebCoreSupport.subproj/WebBridge.m:
3484 (-[WebBridge respondToChangedContents]): No longer call through to WebKit to set the typing style. The call
3485 was part of the misguided use of the setTypingStyle: and typingStyle as a cache of what was stored on