e2d32a1a21e13928f8706964e7d77affb3c876e7
[WebKit-https.git] / Source / WebKit / blackberry / ChangeLog
1 2012-03-12  Andy Chen  <andchen@rim.com>
2
3         [Blackberry] Make the process of marking all matches interruptible and asynchronous for find-in-page
4         https://bugs.webkit.org/show_bug.cgi?id=80831
5
6         Reviewed by Antonio Gomes.
7
8         * WebKitSupport/InPageSearchManager.cpp:
9         (BlackBerry::WebKit::InPageSearchManager::DeferredScopeStringMatches::DeferredScopeStringMatches):
10         (BlackBerry::WebKit::InPageSearchManager::DeferredScopeStringMatches::doTimeout):
11         (BlackBerry::WebKit::InPageSearchManager::InPageSearchManager):
12         (BlackBerry::WebKit::InPageSearchManager::~InPageSearchManager):
13         (BlackBerry::WebKit::InPageSearchManager::findNextString):
14         (BlackBerry::WebKit::InPageSearchManager::shouldSearchForText):
15         (BlackBerry::WebKit::InPageSearchManager::findAndMarkText):
16         (BlackBerry::WebKit::InPageSearchManager::clearTextMatches):
17         (BlackBerry::WebKit::InPageSearchManager::frameUnloaded):
18         (BlackBerry::WebKit::InPageSearchManager::scopeStringMatches):
19         (BlackBerry::WebKit::InPageSearchManager::scopeStringMatchesSoon):
20         (BlackBerry::WebKit::InPageSearchManager::callScopeStringMatches):
21         (BlackBerry::WebKit::InPageSearchManager::cancelPendingScopingEffort):
22         * WebKitSupport/InPageSearchManager.h:
23
24 2012-03-09  Jon Lee  <jonlee@apple.com>
25
26         Rename NotificationPresenter to NotificationClient
27         https://bugs.webkit.org/show_bug.cgi?id=80488
28         <rdar://problem/10965558>
29
30         Reviewed by Kentaro Hara.
31
32         Refactor to use renamed WebCore::NotificationClient.
33         * WebCoreSupport/NotificationPresenterImpl.cpp:
34         (WebCore::NotificationPresenterImpl::instance):
35         (WebCore::NotificationPresenterImpl::show):
36         (WebCore::NotificationPresenterImpl::checkPermission):
37         * WebCoreSupport/NotificationPresenterImpl.h:
38         (NotificationPresenterImpl):
39
40 2012-03-09  Charles Wei  <charles.wei@torchmobile.com.cn>
41
42         [BlackBerry] Web Notification not working after rebase
43         https://bugs.webkit.org/show_bug.cgi?id=80690
44
45         Reviewed by George Staikos.
46
47         1. NotificationPresenterImpl should be in namespace WebCore
48         2. Need to connect NotificationPresenterImpl to webcore the new way:
49            WebCore::provideNotification(Page*, NotificationPresenter*)
50         3. Remove the old way of connecting the Notification:
51            ChromeClientBlackBerry::notificationPresenter()
52
53         * Api/WebPage.cpp:
54         (BlackBerry::WebKit::WebPagePrivate::init):
55         * WebCoreSupport/ChromeClientBlackBerry.cpp:
56         (WebCore):
57         * WebCoreSupport/ChromeClientBlackBerry.h:
58         (ChromeClientBlackBerry):
59         * WebCoreSupport/NotificationPresenterImpl.cpp:
60         * WebCoreSupport/NotificationPresenterImpl.h:
61
62 2012-03-08  Mike Fenton  <mifenton@rim.com>
63
64         [BlackBerry] Always use the current focused node when processing focus changes
65         https://bugs.webkit.org/show_bug.cgi?id=80594
66
67         Reviewed by Antonio Gomes.
68
69         Guard against toRange or fromRange being null when called
70         as part of a clear event.
71
72         * WebCoreSupport/EditorClientBlackBerry.cpp:
73         (WebCore::EditorClientBlackBerry::shouldChangeSelectedRange):
74
75 2012-03-08  Yong Li  <yoli@rim.com>
76
77         [BlackBerry] Block file-to-file access by default
78         https://bugs.webkit.org/show_bug.cgi?id=80605
79
80         Reviewed by Rob Buis.
81
82         Turn off allowFileAccessFromFileURLs() by default.
83
84         * Api/WebPage.cpp:
85         (BlackBerry::WebKit::WebPagePrivate::init):
86
87 2012-03-08  Mike Fenton  <mifenton@rim.com>
88
89         [BlackBerry] Always use the current focused node when processing focus changes
90         https://bugs.webkit.org/show_bug.cgi?id=80594
91
92         Reviewed by Antonio Gomes.
93
94         Update InputHandler focused node handling to strictly use
95         the currently focused node.  This prevents a handling loop
96         when JS is modifying the focus and we get a late notification
97         of a past change from ChromeClientBlackBerry with the previously
98         unfocused node.
99
100         * WebCoreSupport/ChromeClientBlackBerry.cpp:
101         (WebCore::ChromeClientBlackBerry::focusedNodeChanged):
102         * WebCoreSupport/EditorClientBlackBerry.cpp:
103         (WebCore::EditorClientBlackBerry::shouldChangeSelectedRange):
104         (WebCore::EditorClientBlackBerry::setInputMethodState):
105         * WebKitSupport/InputHandler.cpp:
106         (BlackBerry::WebKit::InputHandler::focusedNodeChanged):
107         * WebKitSupport/InputHandler.h:
108
109 2012-03-07  Jacky Jiang  <zhajiang@rim.com>
110
111         [BlackBerry] WebKit rendering problem when show/hide VKB
112         https://bugs.webkit.org/show_bug.cgi?id=80448
113         RIM PR: 141727
114
115         Reviewed by Antonio Gomes.
116
117         When setting viewport size, layout happens inside
118         WebPagePrivate::setDefaultLayoutSize(), in this way, the layout is
119         outside of the code path of "needsLayout" so that the contents are
120         not rendered into the backing store. This is a regression of r108718,
121         switch back to do the layout inside the public API
122         WebPage::setDefaultLayoutSize().
123
124         We haven't upstreamed the manual tests directory yet, therefore,
125         the new manual test case will be upstreamed later.
126
127         * Api/WebPage.cpp:
128         (BlackBerry::WebKit::WebPagePrivate::setDefaultLayoutSize):
129         (BlackBerry::WebKit::WebPage::setDefaultLayoutSize):
130
131 2012-03-06  Lianghui Chen  <liachen@rim.com>
132
133         [BlackBerry] Set correct ResourceRequest target type.
134         https://bugs.webkit.org/show_bug.cgi?id=80430
135
136         Reviewed by Rob Buis.
137
138         Removed unused code in dispatchWillSendRequest(). These codes are too
139         late as the target type has already been referred to when calling
140         ResourceRequest::initializePlatformRequest().
141
142         * WebCoreSupport/FrameLoaderClientBlackBerry.cpp:
143         (WebCore::FrameLoaderClientBlackBerry::dispatchWillSendRequest):
144
145 2012-03-06  Lianghui Chen  <liachen@rim.com>
146
147         [BlackBerry] Remove unused and unneeded WebPageClient::downloadRequested(NetworkRequest&)
148         https://bugs.webkit.org/show_bug.cgi?id=80438
149
150         Reviewed by Antonio Gomes.
151
152         * Api/WebPageClient.h:
153
154 2012-03-06  Jakob Petsovits  <jpetsovits@rim.com>
155
156         [BlackBerry] Don't suspend accel comp when backgrounding a page.
157         https://bugs.webkit.org/show_bug.cgi?id=80369
158         RIM PR: 137609
159
160         Reviewed by Adam Treat.
161
162         Just because the page is in the background doesn't mean
163         it's invisible, doesn't mean it won't have to be redrawn
164         at some point - on rotation, for instance.
165
166         We still suspend accelerated compositing on setVisible(false).
167
168         * Api/WebPage.cpp:
169         (BlackBerry::WebKit::WebPage::notifyPageBackground):
170         (BlackBerry::WebKit::WebPage::notifyPageForeground):
171
172 2012-03-06  Jonathan Dong  <jonathan.dong@torchmobile.com.cn>
173
174         [BlackBerry] function rename issue after MediaPlayerPrivateBlackBerry.[cpp\h] upstream
175         https://bugs.webkit.org/show_bug.cgi?id=80377
176
177         Reviewed by Rob Buis.
178
179         As some of the function names changed in class MediaPlayerPrivate
180         with the upstream of MediaPlayerPrivateBlackBerry.[cpp|h], we
181         should update WebKit/blackberry/Api/WebPage.cpp which uses these
182         functions accordingly.
183         Renamed functions in class MediaPlayerPrivate:
184         windowGet() -> getWindow()
185         windowPositionGet() -> getWindowPosition()
186         mmrContextNameGet() -> mmrContextName()
187
188         * Api/WebPage.cpp:
189         (BlackBerry::WebKit::WebPagePrivate::enterFullscreenForNode):
190
191 2012-03-05  Eli Fidler  <efidler@rim.com>
192
193         The minimum font size WebSetting should actually change the LOGICAL font size in WebCore.
194         https://bugs.webkit.org/show_bug.cgi?id=80312
195         RIM PR: 139874
196
197         Reviewed by George Staikos.
198
199         * Api/WebPage.cpp:
200         (BlackBerry::WebKit::WebPagePrivate::didChangeSettings):
201
202 2012-03-05  Jakob Petsovits  <jpetsovits@rim.com>
203
204         Make accelerated compositing work again with direct rendering.
205         https://bugs.webkit.org/show_bug.cgi?id=80181
206         RIM PR: 139110
207
208         Reviewed by Antonio Gomes.
209         Internally reviewed by Arvid Nilsson.
210
211         The significant amount of refactoring and optimization work
212         that has gone into accelerated compositing missed out on
213         some of the code paths that are being used in direct rendering.
214
215         Animations were relying on blitVisibleContents() only (which
216         is a no-op in direct rendering mode). There were early returns
217         which are suitable to determine whether screen contents need
218         to be updated at all; however, when we're already forcing a
219         re-render then those checks would cause the composition surface
220         not to appear at all, or avoid drawing new animation frames.
221
222         We went through dispatchMessage(), potentially causing
223         mismatches between rendered (but not yet posted) back content
224         and layers composited on top of it. As we're rendering onto
225         the sole target surface (the window) directly and posting
226         from the same thread, we have to wait for compositing on the
227         UI thread to finish before posting the window.
228
229         In turn, this patch combines both drawSubLayers() and
230         blendCompositingSurface() calls into one method, reducing
231         the number of messages to the UI thread within
232         renderDirectToWindow() to one.
233
234         blendCompositingMessage() in renderDirectToScreen() was called
235         with contents coordinates rather than viewport coordinates.
236         That caused some of the composited content to be cut off when
237         the scroll position wasn't (0, 0).
238
239         We called copyPreviousContentsToBackSurfaceOfWindow() twice for
240         one frame, in both renderDirectToWindow() and invalidateWindow().
241         Only one of those (the latter one) is necessary.
242
243         * Api/BackingStore.cpp:
244         (BlackBerry::WebKit::BackingStorePrivate::BackingStorePrivate):
245         (BlackBerry::WebKit::BackingStorePrivate::renderDirectToWindow):
246         (BlackBerry::WebKit::BackingStorePrivate::drawSubLayers):
247         (WebKit):
248         (BlackBerry::WebKit::BackingStorePrivate::drawAndBlendLayersForDirectRendering):
249         * Api/BackingStore.h:
250         (WebKit):
251         * Api/BackingStore_p.h:
252         (BackingStorePrivate):
253         (BlackBerry::WebKit::BackingStorePrivate::isDirectRenderingAnimationMessageScheduled):
254         (BlackBerry::WebKit::BackingStorePrivate::setDirectRenderingAnimationMessageScheduled):
255         * Api/WebPage_p.h:
256         (BlackBerry::WebKit::WebPagePrivate::isAcceleratedCompositingActive):
257         (WebPagePrivate):
258         * WebKitSupport/WebPageCompositor.cpp:
259         (BlackBerry::WebKit::WebPageCompositor::WebPageCompositor):
260         (BlackBerry::WebKit::WebPageCompositor::~WebPageCompositor):
261         (BlackBerry::WebKit::WebPageCompositor::drawLayers):
262         (BlackBerry::WebKit::WebPageCompositor::animationTimerFired):
263         * WebKitSupport/WebPageCompositor.h:
264         (WebPageCompositor):
265
266 2012-03-05  George Staikos  <gstaikos@rim.com>
267
268         [BlackBerry] DOMSupport visibleSelectionForRangeInputElement incorrectly dereferences a null range.
269         https://bugs.webkit.org/show_bug.cgi?id=80274
270
271         Reviewed by Antonio Gomes.
272
273         A null range can be returned so we should not blindly deref it.
274         Reviewed Internally by Mike Fenton.
275
276         * WebKitSupport/DOMSupport.cpp:
277         (BlackBerry::WebKit::DOMSupport::visibleSelectionForRangeInputElement):
278
279 2012-03-04  Jonathan Dong  <jonathan.dong@torchmobile.com.cn>
280
281         [BlackBerry] upstream CredentialManager and CredentialTransformData implementation
282         https://bugs.webkit.org/show_bug.cgi?id=80107
283
284         Reviewed by Antonio Gomes.
285
286         Initial upstream of CredentialManager.[h|cpp] and
287         CredentialTransformData.[h|cpp].
288         No new test.
289
290         * WebCoreSupport/CredentialManager.cpp: Added.
291         (WebCore):
292         (WebCore::CredentialManager::CredentialManager):
293         (WebCore::CredentialManager::autofillAuthenticationChallenge):
294         (WebCore::CredentialManager::autofillPasswordForms):
295         (WebCore::CredentialManager::saveCredentialIfConfirmed):
296         * WebCoreSupport/CredentialManager.h: Added.
297         (WebKit):
298         (WebCore):
299         (CredentialManager):
300         * WebCoreSupport/CredentialTransformData.cpp: Added.
301         (WebCore::CredentialTransformData::CredentialTransformData):
302         (WebCore):
303         (WebCore::CredentialTransformData::url):
304         (WebCore::CredentialTransformData::credential):
305         (WebCore::CredentialTransformData::setCredential):
306         (WebCore::CredentialTransformData::findPasswordFormFields):
307         * WebCoreSupport/CredentialTransformData.h: Added.
308         (WebCore):
309         (CredentialTransformData):
310         (WebCore::CredentialTransformData::isValid):
311         (WebCore::CredentialTransformData::protectionSpace):
312
313 2012-03-04  Antonio Gomes  <agomes@rim.com>
314
315         [BlackBerry] Fixed positioned element not correctly positioned after orientation change, when viewport metatag is used
316         https://bugs.webkit.org/show_bug.cgi?id=80228
317         PR #138865
318
319         Reviewed by George Staikos.
320
321         Viewport size changes in two main scenarios:
322         - orientation changes;
323         - virtual keyboard pop up/hide.
324
325         When we are setting a new viewport size, we need to
326         update the FixedReportedSize of the mainframe. This size
327         is used to return innerWidth|Heigth as well as to calculate
328         the fixed position elements height relative to the RenderView [1].
329
330         [1] RenderBox::containingBlockLogicalHeightForPositioned.
331
332         When we are rotating, we need to delay setting the new FixedReportedSize
333         till we layout and are able to figure out the new contents size. At this
334         time we call setFixedReportedSize, but we do not reposition the fixed elemts
335         afterwards.
336
337         Patch adds a call to FrameView::repaintFixedElementsAfterScrolling, after
338         setting the new size.
339
340         Source/WebKit/blackberry:
341         * Api/WebPage.cpp:
342         (BlackBerry::WebKit::WebPagePrivate::setViewportSize):
343
344 2012-03-02  Mike Fenton  <mifenton@rim.com>
345
346         [BlackBerry] Expose WebInspector state to client and clean up WebSettings
347         https://bugs.webkit.org/show_bug.cgi?id=80177
348
349         Reviewed by Antonio Gomes.
350
351         Expose the Web Inspector state to WebPage client's and
352         re-order initialization of WebSettings to be alphabetical
353         matching their definitions.
354
355         * Api/WebPage.cpp:
356         (BlackBerry::WebKit::WebPage::isWebInspectorEnabled):
357         * Api/WebPage.h:
358         * Api/WebSettings.cpp:
359         (BlackBerry::WebKit::WebSettings::standardSettings):
360
361 2012-03-02  Arvid Nilsson  <anilsson@rim.com>
362
363         Accelerated compositing: Checkerboard never goes away
364         https://bugs.webkit.org/show_bug.cgi?id=79020
365         RIM PR #134164
366
367         Reviewed by Adam Treat.
368
369         Checkerboard appears in accelerated compositing layers when there's no
370         texture for (part of) a layer. The layer renderer queues up some render
371         jobs and schedules a commit to make the WebKit thread process those
372         jobs. Render jobs performed during commit cause texture upload jobs to
373         be scheduled on the UI thread. Texture uploads are performed when next
374         drawing the layers.
375
376         Unfortunately, sometimes commit operation happens without a subsequent
377         call draw the layers.
378
379         In order to implement one-shot drawing sync, I added a call to
380         commitRootLayerIfNeeded() in BackingStore::renderContents(), and
381         I was lucky that most of the time, renderContents() is followed by
382         blit(Visible)Contents() which in turn draws the layers.
383         However, render is not always followed by a blit, for example when
384         rendering offscreen tiles in BackingStore::renderOnIdle(), and in
385         direct rendering mode.
386
387         Fixed by making sure that every call to commitRootLayerIfNeeded() that
388         returns true is followed by a call to drawLayersOnCommit(), unless a
389         blit was requested already.
390
391         Also tweak the logic for one-shot drawing sync to make the code in
392         drawLayersOnCommit() reusable outside of rootLayerCommitTimerFired().
393
394         * Api/BackingStore.cpp:
395         (BlackBerry::WebKit::BackingStorePrivate::BackingStorePrivate):
396         (BlackBerry::WebKit::BackingStorePrivate::renderOnTimer):
397         (BlackBerry::WebKit::BackingStorePrivate::renderOnIdle):
398         (BlackBerry::WebKit::BackingStorePrivate::willFireTimer):
399         (BlackBerry::WebKit::BackingStorePrivate::renderDirectToWindow):
400         (BlackBerry::WebKit::BackingStorePrivate::render):
401         (BlackBerry::WebKit::BackingStorePrivate::blitVisibleContents):
402         (BlackBerry::WebKit::BackingStorePrivate::blitContents):
403         (BlackBerry::WebKit::BackingStorePrivate::renderContents):
404         (WebKit):
405         (BlackBerry::WebKit::BackingStorePrivate::drawLayersOnCommitIfNeeded):
406         * Api/BackingStore_p.h:
407         (BackingStorePrivate):
408         (BlackBerry::WebKit::BackingStorePrivate::willDrawLayersOnCommit):
409
410 2012-03-02  Adam Treat  <atreat@rim.com>
411
412         https://bugs.webkit.org/show_bug.cgi?id=80161
413         PR: 141157
414
415         BlackBerryPlatformScreen.h API has been updated.  Reflect those
416         changes in our usage.
417
418         Reviewed by Antonio Gomes.
419         Internally reviewed by Jakob Petsovits.
420
421         * Api/BackingStore.cpp:
422         (BlackBerry::WebKit::BackingStorePrivate::tileWidth):
423         (BlackBerry::WebKit::BackingStorePrivate::tileHeight):
424         * Api/WebPage.cpp:
425         (BlackBerry::WebKit::WebPagePrivate::init):
426         (BlackBerry::WebKit::WebPagePrivate::transformedViewportSize):
427         (BlackBerry::WebKit::WebPagePrivate::fixedLayoutSize):
428         (BlackBerry::WebKit::WebPagePrivate::recomputeVirtualViewportFromViewportArguments):
429         (BlackBerry::WebKit::WebPagePrivate::setDefaultLayoutSize):
430         (BlackBerry::WebKit::WebPagePrivate::defaultMaxLayoutSize):
431         * WebCoreSupport/FrameLoaderClientBlackBerry.cpp:
432         (WebCore::FrameLoaderClientBlackBerry::restoreViewState):
433         * WebKitSupport/SurfacePool.cpp:
434         (BlackBerry::WebKit::createCompositingSurface):
435
436 2012-03-02  Konrad Piascik  <kpiascik@rim.com>
437
438         [BlackBerry] Set the devicePixelRatio from the results of computeViewportAttributes
439         https://bugs.webkit.org/show_bug.cgi?id=80160
440
441         Reviewed by Antonio Gomes.
442
443         Tested by going to layout test fast/viewport/viewport-95.html and viewport-93.html
444         Previously when executing window.devicePixelRatio these two pages returned 1 now
445         they report the devicePixelRatio returned by computeViewportAttributes.
446
447         * Api/WebPage.cpp:
448         (BlackBerry::WebKit::WebPagePrivate::recomputeVirtualViewportFromViewportArguments):
449
450 2012-03-02  Jacky Jiang  <zhajiang@rim.com>
451
452         Fix a warning in InputHandler::learnText()
453         https://bugs.webkit.org/show_bug.cgi?id=80049
454
455         Reviewed by Antonio Gomes.
456
457         Fix a warning of the comparison "textInField.length() <=
458         MaxLearnTextDataSize" in InputHandler::learnText().
459
460         Rubber-stamped internally by Mike Fenton.
461
462         * WebKitSupport/InputHandler.cpp:
463         (BlackBerry::WebKit::InputHandler::learnText):
464
465 2012-03-01  Andy Chen  <andchen@rim.com>
466
467         [BlackBerry] Implement features for find-in-page
468         https://bugs.webkit.org/show_bug.cgi?id=79820
469
470         Reviewed by Antonio Gomes.
471
472         - Make it be able to search text around the whole page instead of single frame.
473         - Make it be able to start new search from active selection and last active match.
474
475         No new tests as this patch doesn't change behavior.
476
477         * Api/WebPage.cpp:
478         (BlackBerry::WebKit::WebPagePrivate::frameUnloaded):
479         * Api/WebPage_p.h:
480         * WebCoreSupport/FrameLoaderClientBlackBerry.cpp:
481         (WebCore::FrameLoaderClientBlackBerry::dispatchWillClose):
482         (WebCore::FrameLoaderClientBlackBerry::detachedFromParent2):
483         * WebKitSupport/DOMSupport.cpp:
484         (BlackBerry::WebKit::DOMSupport::incrementFrame):
485         * WebKitSupport/DOMSupport.h:
486         * WebKitSupport/InPageSearchManager.cpp:
487         (BlackBerry::WebKit::InPageSearchManager::findNextString):
488         (BlackBerry::WebKit::InPageSearchManager::shouldSearchForText):
489         (BlackBerry::WebKit::InPageSearchManager::findAndMarkText):
490         (BlackBerry::WebKit::InPageSearchManager::setMarkerActive):
491         (BlackBerry::WebKit::InPageSearchManager::frameUnloaded):
492         * WebKitSupport/InPageSearchManager.h:
493         * WebKitSupport/InputHandler.cpp:
494         (BlackBerry::WebKit::InputHandler::frameUnloaded):
495         * WebKitSupport/InputHandler.h:
496
497 2012-03-01  Charles Wei  <charles.wei@torchmobile.com.cn>
498
499         [BlackBerry] Web Notification crashes the browser.
500         https://bugs.webkit.org/show_bug.cgi?id=79897
501
502         Reviewed by Antonio Gomes.
503
504         The reason of the crash is that it still uses the iterator
505         after been removed from the container, which invalidates the
506         iterator. 
507         We should stop processing after we have found the element
508         and removed from the container through the iterator.
509
510         This patch only fixes the crash issue, but not any notification
511         functionality issue, which is tracked seperatly.
512
513         Test case: http://sandbox.gtaero.net/chrome/notifications.php
514
515         * WebCoreSupport/NotificationPresenterImpl.cpp:
516         (WebKit::NotificationPresenterImpl::onPermission):
517         (WebKit::NotificationPresenterImpl::notificationClicked):
518
519 2012-03-01  Mike Fenton  <mifenton@rim.com>
520
521         Autocomplete attribute should apply to textarea's.
522         https://bugs.webkit.org/show_bug.cgi?id=79929
523
524         Reviewed by Antonio Gomes.
525
526         Add local static Qualified name for autocorrect attribute.
527
528         * WebKitSupport/DOMSupport.cpp:
529         (BlackBerry::WebKit::DOMSupport::elementSupportsAutocorrect):
530
531 2012-02-29  Mike Fenton  <mifenton@rim.com>
532
533         Autocomplete attribute should apply to textarea's.
534         https://bugs.webkit.org/show_bug.cgi?id=79929
535
536         Reviewed by Antonio Gomes.
537
538         Allow the autocomplete attribute to bubble back to the form setting.
539
540         Expand support to include checking autocorrect, autocomplete and
541         name/id matching to text areas.
542
543         Reviewed internally by Nima Ghanavatian and Gen Mak.
544
545         * WebKitSupport/DOMSupport.cpp:
546         (BlackBerry::WebKit::DOMSupport::elementSupportsAutocorrect):
547         (BlackBerry::WebKit::DOMSupport::elementSupportsAutocomplete):
548         (BlackBerry::WebKit::DOMSupport::elementAttributeState):
549         * WebKitSupport/DOMSupport.h:
550         * WebKitSupport/InputHandler.cpp:
551         (BlackBerry::WebKit::inputStyle):
552
553 2012-02-29  Max Feil  <mfeil@rim.com>
554
555         [BlackBerry] Add support for FLAC audio and OGG/Vorbis audio
556         https://bugs.webkit.org/show_bug.cgi?id=79519
557
558         Reviewed by Antonio Gomes.
559
560         * Api/WebSettings.cpp:
561         (BlackBerry::WebKit::mimeTypeAssociationMap):
562
563 2012-02-28  Konrad Piascik  <kpiascik@rim.com>
564
565         [BlackBerry] Change the API to use std::string
566         https://bugs.webkit.org/show_bug.cgi?id=79818
567
568         Reviewed by Antonio Gomes.
569
570         * Api/WebPage.cpp:
571         (BlackBerry::WebKit::WebPage::dispatchInspectorMessage):
572         * Api/WebPage.h:
573
574 2012-02-28  Jacky Jiang  <zhajiang@rim.com>
575
576         [BlackBerry] x86 build fix after cleaning up WebPage.cpp
577         https://bugs.webkit.org/show_bug.cgi?id=79814
578
579         Reviewed by Antonio Gomes.
580
581         x86 build fix, keep WebPage::destroyWebPageCompositor() method where it
582         was which was outside of USE(ACCELERATED_COMPOSITING).
583
584         * Api/WebPage.cpp:
585         (BlackBerry::WebKit::WebPage::destroyWebPageCompositor):
586         (WebKit):
587
588 2012-02-28  Mike Fenton  <mifenton@rim.com>
589
590         [BlackBerry] Remove unused focusedNodeChange notifications from the Chrome client.
591         https://bugs.webkit.org/show_bug.cgi?id=79794
592
593         Reviewed by Rob Buis.
594
595         Remove unused notification for focusedNodeChanged.
596
597         Internally reviewed by Gen Mak.
598
599         * Api/WebPageClient.h:
600         * WebCoreSupport/ChromeClientBlackBerry.cpp:
601         (WebCore::ChromeClientBlackBerry::focusedNodeChanged):
602
603 2012-02-27  Jacky Jiang  <zhajiang@rim.com>
604
605         [BlackBerry] Upstream BlackBerry API web page related files
606         https://bugs.webkit.org/show_bug.cgi?id=74380
607
608         Reviewed by Antonio Gomes.
609
610         Clean up WebPage.{h, cpp} and WebPage_p.h.
611         - Remove WebPage::mainFrame() as it is bad to expose WebCore::Frame in
612           the public API, adapt to the change by adding a new method
613           WebPagePrivate::core(Const WebPage*) and expose it to
614           DumpRenderTreeSupport.
615         - Rename WebPage::spellCheckingEnabled to
616           WebPage::setSpellCheckingEnabled.
617         - Remove unused WebPage::focusNodeRect().
618         - Remove extra blank lines.
619         - Put WebPage methods and their associated WebPagePrivate methods
620           together.
621
622         No new tests as this patch doesn't change behavior.
623
624         * Api/WebPage.cpp:
625         (BlackBerry::WebKit::WebPage::WebPage):
626         (WebKit):
627         (BlackBerry::WebKit::WebPage::~WebPage):
628         (BlackBerry::WebKit::WebPagePrivate::core):
629         (BlackBerry::WebKit::WebPage::load):
630         (BlackBerry::WebKit::WebPage::loadExtended):
631         (BlackBerry::WebKit::WebPage::loadFile):
632         (BlackBerry::WebKit::WebPage::download):
633         (BlackBerry::WebKit::WebPage::loadString):
634         (BlackBerry::WebKit::WebPage::executeJavaScript):
635         (BlackBerry::WebKit::WebPage::executeJavaScriptInIsolatedWorld):
636         (BlackBerry::WebKit::WebPage::stopLoading):
637         (BlackBerry::WebKit::WebPage::prepareToDestroy):
638         (BlackBerry::WebKit::WebPage::setScrollPosition):
639         (BlackBerry::WebKit::WebPage::scrollBy):
640         (BlackBerry::WebKit::WebPage::notifyInRegionScrollStatusChanged):
641         (BlackBerry::WebKit::WebPage::zoomToFitScale):
642         (BlackBerry::WebKit::WebPage::initialScale):
643         (BlackBerry::WebKit::WebPage::maximumScale):
644         (BlackBerry::WebKit::WebPage::scrollPosition):
645         (BlackBerry::WebKit::WebPage::viewportSize):
646         (BlackBerry::WebKit::WebPage::activeNodeContext):
647         (BlackBerry::WebKit::WebPage::assignFocus):
648         (BlackBerry::WebKit::WebPage::blockZoomAnimationFinished):
649         (BlackBerry::WebKit::WebPage::onInputLocaleChanged):
650         (BlackBerry::WebKit::WebPage::setScreenOrientation):
651         (BlackBerry::WebKit::WebPage::applyPendingOrientationIfNeeded):
652         (BlackBerry::WebKit::WebPage::setViewportSize):
653         (BlackBerry::WebKit::WebPage::setDefaultLayoutSize):
654         (BlackBerry::WebKit::WebPage::setScrollOriginPoint):
655         (BlackBerry::WebKit::WebPage::textEncoding):
656         (BlackBerry::WebKit::WebPage::forcedTextEncoding):
657         (BlackBerry::WebKit::WebPage::setForcedTextEncoding):
658         (BlackBerry::WebKit::WebPage::setSpellCheckingEnabled):
659         (BlackBerry::WebKit::parentLayer):
660         (BlackBerry::WebKit::WebPagePrivate::inRegionScrollableAreasForPoint):
661         (BlackBerry::WebKit::WebPage::destroyWebPageCompositor):
662         * Api/WebPage.h:
663         (WebCore):
664         (WebKit):
665         * Api/WebPage_p.h:
666         (WebCore):
667         (WebKit):
668         * WebKitSupport/DumpRenderTreeSupport.cpp:
669         (DumpRenderTreeSupport::corePage):
670         (DumpRenderTreeSupport::numberOfPendingGeolocationPermissionRequests):
671         (DumpRenderTreeSupport::resetGeolocationMock):
672         (DumpRenderTreeSupport::setMockGeolocationError):
673         (DumpRenderTreeSupport::setMockGeolocationPermission):
674         (DumpRenderTreeSupport::setMockGeolocationPosition):
675         (DumpRenderTreeSupport::scalePageBy):
676         * WebKitSupport/DumpRenderTreeSupport.h:
677         (WebCore):
678         (DumpRenderTreeSupport):
679
680 2012-02-27  Mike Fenton  <mifenton@rim.com>
681
682         [BlackBerry] Selection handling should be entirely directional
683         https://bugs.webkit.org/show_bug.cgi?id=79692
684
685         Reviewed by Antonio Gomes.
686
687         Make all VisibleSelections directional.
688
689         * WebKitSupport/SelectionHandler.cpp:
690         (BlackBerry::WebKit::SelectionHandler::updateOrHandleInputSelection):
691         (BlackBerry::WebKit::SelectionHandler::setSelection):
692
693 2012-02-27  Ed Baker  <edbaker@rim.com>
694
695         [BlackBerry] Dragging a selection handle outside of the content bounding box does not update the selection range correctly
696         https://bugs.webkit.org/show_bug.cgi?id=78608
697
698         Ensure that when selection handles leave the content bounding box that
699         the handle not being dragged remains fixed. Do not apply padding to a
700         direction that would cause the selection to shrink when performing the
701         handle direction detection.
702
703         Reviewed by Antonio Gomes.
704
705         * WebKitSupport/DOMSupport.cpp:
706         (BlackBerry::WebKit::DOMSupport::convertPointToFrame):
707         * WebKitSupport/DOMSupport.h:
708         * WebKitSupport/SelectionHandler.cpp:
709         (BlackBerry::WebKit::clamp):
710         (BlackBerry::WebKit::directionalVisiblePositionAtExtentOfBox):
711         (BlackBerry::WebKit::SelectionHandler::extendSelectionToFieldBoundary):
712         (BlackBerry::WebKit::SelectionHandler::setSelection):
713         (BlackBerry::WebKit::SelectionHandler::clipPointToVisibleContainer):
714         * WebKitSupport/SelectionHandler.h:
715
716 2012-02-27  Leo Yang  <leo.yang@torchmobile.com.cn>
717
718         [BlackBerry] Upstream accelerated compositing helper class
719         https://bugs.webkit.org/show_bug.cgi?id=78448
720
721         Reviewed by Antonio Gomes.
722
723         Initial upstream, no new tests.
724
725         * WebKitSupport/FrameLayers.cpp: Added.
726         * WebKitSupport/FrameLayers.h: Added.
727
728 2012-02-26  Hajime Morrita  <morrita@chromium.org>
729
730         Move ChromeClient::showContextMenu() to ContextMenuClient
731         https://bugs.webkit.org/show_bug.cgi?id=79427
732
733         Reviewed by Adam Barth.
734
735         * WebCoreSupport/ChromeClientBlackBerry.h:
736         (ChromeClientBlackBerry):
737
738 2012-02-24  Mike Fenton  <mifenton@rim.com>
739
740         [BlackBerry] Eliminate excessive BlackBerry::Platform use in InputHandler
741         https://bugs.webkit.org/show_bug.cgi?id=79393
742
743         Reviewed by Antonio Gomes.
744
745         Cleanup usage of BlackBerry::Platform in InputHandler.
746
747         * WebKitSupport/InputHandler.cpp:
748         (BlackBerry::WebKit::convertStringToWchar):
749         (BlackBerry::WebKit::convertStringToWcharVector):
750         (BlackBerry::WebKit::convertSpannableStringToString):
751         (BlackBerry::WebKit::InputHandler::learnText):
752         (BlackBerry::WebKit::InputHandler::setElementUnfocused):
753         (BlackBerry::WebKit::InputHandler::shouldAcceptInputFocus):
754         (BlackBerry::WebKit::InputHandler::setElementFocused):
755         (BlackBerry::WebKit::InputHandler::nodeTextChanged):
756         (BlackBerry::WebKit::InputHandler::ensureFocusTextElementVisible):
757         (BlackBerry::WebKit::InputHandler::frameUnloaded):
758         (BlackBerry::WebKit::InputHandler::selectionChanged):
759         (BlackBerry::WebKit::InputHandler::setSelection):
760         (BlackBerry::WebKit::InputHandler::handleKeyboardInput):
761         (BlackBerry::WebKit::InputHandler::deleteTextRelativeToCursor):
762         (BlackBerry::WebKit::InputHandler::deleteText):
763         (BlackBerry::WebKit::InputHandler::spannableTextInRange):
764         (BlackBerry::WebKit::InputHandler::setComposingRegion):
765         (BlackBerry::WebKit::InputHandler::finishComposition):
766         (BlackBerry::WebKit::InputHandler::setText):
767         (BlackBerry::WebKit::InputHandler::setTextAttributes):
768         (BlackBerry::WebKit::InputHandler::setRelativeCursorPosition):
769         (BlackBerry::WebKit::InputHandler::setSpannableTextAndRelativeCursor):
770         (BlackBerry::WebKit::InputHandler::setComposingText):
771         (BlackBerry::WebKit::InputHandler::commitText):
772
773 2012-02-24  Mike Fenton  <mifenton@rim.com>
774
775         [BlackBerry] Eliminate excessive BlackBerry::Platform use in SelectionHandler.
776         https://bugs.webkit.org/show_bug.cgi?id=79391
777
778         Reviewed by Antonio Gomes.
779
780         Clean up usage of BlackBerry::Platform in SelectionHandler and
781         explicitly define what namespace to use for ambiguous objects like
782         IntRect and IntPoint.
783
784         * WebKitSupport/SelectionHandler.cpp:
785         (BlackBerry::WebKit::SelectionHandler::cancelSelection):
786         (BlackBerry::WebKit::SelectionHandler::getConsolidatedRegionOfTextQuadsForSelection):
787         (BlackBerry::WebKit::visiblePositionForPointIgnoringClipping):
788         (BlackBerry::WebKit::directionOfPointRelativeToRect):
789         (BlackBerry::WebKit::SelectionHandler::shouldUpdateSelectionOrCaretForPoint):
790         (BlackBerry::WebKit::SelectionHandler::setCaretPosition):
791         (BlackBerry::WebKit::directionalVisiblePositionAtExtentOfBox):
792         (BlackBerry::WebKit::pointIsOutsideOfBoundingBoxInDirection):
793         (BlackBerry::WebKit::SelectionHandler::extendSelectionToFieldBoundary):
794         (BlackBerry::WebKit::SelectionHandler::updateOrHandleInputSelection):
795         (BlackBerry::WebKit::SelectionHandler::clipPointToFocusNode):
796         (BlackBerry::WebKit::SelectionHandler::setSelection):
797         (BlackBerry::WebKit::SelectionHandler::selectAtPoint):
798         (BlackBerry::WebKit::SelectionHandler::selectObject):
799         (BlackBerry::WebKit::comparePointsToReferencePoint):
800         (BlackBerry::WebKit::minXMinYCorner):
801         (BlackBerry::WebKit::maxXMinYCorner):
802         (BlackBerry::WebKit::minXMaxYCorner):
803         (BlackBerry::WebKit::maxXMaxYCorner):
804         (BlackBerry::WebKit::caretLocationForRect):
805         (BlackBerry::WebKit::caretComparisonPointForRect):
806         (BlackBerry::WebKit::adjustCaretRects):
807         (BlackBerry::WebKit::SelectionHandler::clipRegionToVisibleContainer):
808         (BlackBerry::WebKit::referencePoint):
809         (BlackBerry::WebKit::SelectionHandler::selectionPositionChanged):
810         (BlackBerry::WebKit::SelectionHandler::caretPositionChanged):
811         (BlackBerry::WebKit::SelectionHandler::selectionContains):
812
813 2012-02-24  Shinya Kawanaka  <shinyak@chromium.org>
814
815         SpellCheckRequest needs to know the context where the spellcheck happened.
816         https://bugs.webkit.org/show_bug.cgi?id=79320
817
818         Reviewed by Hajime Morita.
819
820         * WebCoreSupport/EditorClientBlackBerry.cpp:
821         (WebCore::EditorClientBlackBerry::requestCheckingOfString):
822         * WebCoreSupport/EditorClientBlackBerry.h:
823         (EditorClientBlackBerry):
824
825 2012-02-24  Charles Wei  <charles.wei@torchmobile.com.cn>
826
827         [BlackBerry] Anchor mailto: with target set won't launch Messaging application when clicked
828         https://bugs.webkit.org/show_bug.cgi?id=79318
829
830         Need to give the client a chance to decide how to handle the new window request.
831
832         Reviewed by Rob Buis.
833
834         * WebCoreSupport/FrameLoaderClientBlackBerry.cpp:
835         (WebCore::FrameLoaderClientBlackBerry::dispatchDecidePolicyForNewWindowAction):
836
837 2012-02-23  Mike Fenton  <mifenton@rim.com>
838
839         [BlackBerry] Selection handler has compile failure with logs enabled.
840         https://bugs.webkit.org/show_bug.cgi?id=79392
841
842         Reviewed by Antonio Gomes.
843
844         Build Fix.  Update log to avoid usage of toString which was removed.
845
846         * WebKitSupport/SelectionHandler.cpp:
847         (BlackBerry::WebKit::SelectionHandler::selectionPositionChanged):
848
849 2012-02-19  Antonio Gomes  <agomes@rim.com>
850
851         Fat fingers - Add a clearer way to distinguish the node we want (shadow or non-shadow)
852         https://bugs.webkit.org/show_bug.cgi?id=79256
853         PR #127814 / MKS_2587410
854
855         Reviewed by Rob Buis.
856
857         Patch adds a cleaner way for call sites of FatFingersResult to
858         query for the appropriated target node: shadow or non-shadow DOM nodes.
859
860         It also renames FatFingersResults::validNode to ::node, assuming
861         that "invalid" nodes are not applicable in any context.
862
863         * Api/WebPage.cpp:
864         (BlackBerry::WebKit::WebPagePrivate::clearDocumentData):
865         (BlackBerry::WebKit::WebPagePrivate::contextNode):
866         (BlackBerry::WebKit::WebPagePrivate::handleMouseEvent):
867         * WebKitSupport/FatFingers.h:
868         (FatFingersResult):
869         (BlackBerry::WebKit::FatFingersResult::node):
870         (BlackBerry::WebKit::FatFingersResult::nodeAsElementIfApplicable):
871         * WebKitSupport/SelectionHandler.cpp:
872         (BlackBerry::WebKit::SelectionHandler::selectAtPoint):
873         * WebKitSupport/TouchEventHandler.cpp:
874         (BlackBerry::WebKit::TouchEventHandler::touchHoldEvent):
875         (BlackBerry::WebKit::TouchEventHandler::handleTouchPoint):
876
877 2012-02-23  Jacky Jiang  <zhajiang@rim.com>
878
879         [BlackBerry] Upstream BlackBerry API web page related files
880         https://bugs.webkit.org/show_bug.cgi?id=74380
881
882         Reviewed by Antonio Gomes.
883
884         Initial upstream, no new tests.
885
886         * Api/WebPage.cpp: Added.
887         * Api/WebPage.h: Added.
888         * Api/WebPage_p.h: Added.
889
890 2012-02-23  Leo Yang  <leo.yang@torchmobile.com.cn>
891
892         [BlackBerry] Remove unused ChromeClientBlackBerry::platformCompositingWindow(), platformWindow() and WebPageClient::compositingWindow()
893         https://bugs.webkit.org/show_bug.cgi?id=78681
894
895         Reviewed by Antonio Gomes.
896
897         * Api/WebPageClient.h:
898         * WebCoreSupport/ChromeClientBlackBerry.cpp:
899         (WebCore):
900         * WebCoreSupport/ChromeClientBlackBerry.h:
901         (ChromeClientBlackBerry):
902
903 2012-02-23  Leo Yang  <leo.yang@torchmobile.com.cn>
904
905         [BlackBerry] Upstream GLES2Context.{h, cpp}
906         https://bugs.webkit.org/show_bug.cgi?id=79196
907
908         Reviewed by Rob Buis.
909
910         Initial upstream, no new tests.
911
912         * WebKitSupport/GLES2Context.cpp: Added.
913         * WebKitSupport/GLES2Context.h: Added.
914
915 2012-02-23  Mike Fenton  <mifenton@rim.com>
916
917         [BlackBerry] InputHandler requires cleanup of Navigation Mode handling.
918         https://bugs.webkit.org/show_bug.cgi?id=79366
919
920         Reviewed by Rob Buis.
921
922         Cleanup InputHandler navigation based code.
923
924         1) Remove the concept of NavigationMode and replace it
925            with simple showKeyboard calls.
926
927         2) Remove navigation move events and replace with standard
928            key events.
929
930         3) Standardize function/variable names and remove obsolete
931            functions.
932
933         * Api/WebPageClient.h:
934         * WebKitSupport/InputHandler.cpp:
935         (BlackBerry::WebKit::InputHandler::InputHandler):
936         (BlackBerry::WebKit::InputHandler::nodeFocused):
937         (BlackBerry::WebKit::InputHandler::setElementUnfocused):
938         (BlackBerry::WebKit::InputHandler::setElementFocused):
939         (BlackBerry::WebKit::InputHandler::ensureFocusTextElementVisible):
940         (BlackBerry::WebKit::InputHandler::setDelayKeyboardVisibilityChange):
941         (BlackBerry::WebKit::InputHandler::processPendingKeyboardVisibilityChange):
942         (BlackBerry::WebKit::InputHandler::notifyClientOfKeyboardVisibilityChange):
943         * WebKitSupport/InputHandler.h:
944         (InputHandler):
945         * WebKitSupport/SelectionHandler.cpp:
946         (BlackBerry::WebKit::SelectionHandler::setCaretPosition):
947         (BlackBerry::WebKit::SelectionHandler::updateOrHandleInputSelection):
948         * WebKitSupport/TouchEventHandler.cpp:
949         (BlackBerry::WebKit::TouchEventHandler::touchEventCancel):
950         (BlackBerry::WebKit::TouchEventHandler::handleTouchPoint):
951
952 2012-02-21  Ryosuke Niwa  <rniwa@webkit.org>
953
954         Remove the remaining uses of CSSStyleDeclaration in Editor
955         https://bugs.webkit.org/show_bug.cgi?id=78939
956
957         Reviewed by Enrica Casucci.
958
959         * WebCoreSupport/EditorClientBlackBerry.cpp:
960         (WebCore::EditorClientBlackBerry::shouldApplyStyle):
961         * WebCoreSupport/EditorClientBlackBerry.h:
962         (EditorClientBlackBerry):
963
964 2012-02-22  Mike Fenton  <mifenton@rim.com>
965
966         [BlackBerry] InputHandler has signed vs unsigned comparison.
967         https://bugs.webkit.org/show_bug.cgi?id=79261
968
969         Fix warning by casting the unsigned int to an int.
970
971         Reviewed by Rob Buis.
972
973         * WebKitSupport/InputHandler.cpp:
974         (BlackBerry::WebKit::InputHandler::rectForCaret):
975
976 2012-02-22  Ryosuke Niwa  <rniwa@webkit.org>
977
978         Remove the remaining uses of CSSStyleDeclaration in Editor
979         https://bugs.webkit.org/show_bug.cgi?id=78939
980
981         Reviewed by Enrica Casucci.
982
983         * WebCoreSupport/EditorClientBlackBerry.cpp:
984         (WebCore::EditorClientBlackBerry::shouldApplyStyle):
985         * WebCoreSupport/EditorClientBlackBerry.h:
986         (EditorClientBlackBerry):
987
988 2012-02-18  Antonio Gomes  <agomes@rim.com>
989
990         Fat fingers - cache the first rect-based hit test so we do not need to do it again
991         https://bugs.webkit.org/show_bug.cgi?id=79115
992
993         Reviewed by Adam Treat.
994
995         Our FatFingers implementation runs currently in two phases:
996         the first checks for the elements intrinsically clickable;
997         the second checks for elements made clickable by the page
998         (for example, a div with a onclick event listener attached to it).
999         For each phase, we perform a rect hittest, which is not needed since
1000         the result of each is the same.
1001
1002         Patch introduces a caching mechanism so we avoid on rect hittest:
1003         when the first phase runs, it caches each nodeset per document in
1004         a hashmap. This second phase works with the cached results.
1005
1006         No behavioral change, but performance is better since we
1007         avoid one (possibly expensive) rect hittest.
1008
1009         I measured the performance gain on https://www.kvd.se/, and we
1010         save up to 0.04 seconds, by caching and re-using the results.
1011
1012         * WebKitSupport/FatFingers.cpp:
1013         (BlackBerry::WebKit::dumpHitTestResult):
1014         (BlackBerry::WebKit::FatFingers::findBestPoint):
1015         (BlackBerry::WebKit::FatFingers::findIntersectingRegions):
1016         (BlackBerry::WebKit::FatFingers::cachingStrategy):
1017         (WebKit):
1018         (BlackBerry::WebKit::FatFingers::getNodesFromRect):
1019         * WebKitSupport/FatFingers.h:
1020
1021 2012-02-20  Antonio Gomes  <agomes@rim.com>
1022
1023         All default video/audio control elements should be rect-hit testable (Part II)
1024         PR #139518 / MKS_3005538
1025
1026         Reviewed by George Staikos.
1027
1028         Add HTMLInputElement::isMediaControlElement as a criteria
1029         to consider a element as clickable.
1030
1031         Note that is should be only used while in the "ClickableByDefault"
1032         phase of FatFingers.
1033
1034         * WebKitSupport/FatFingers.cpp:
1035         (BlackBerry::WebKit::FatFingers::isElementClickable):
1036
1037 2012-02-16  Antonio Gomes  <agomes@rim.com>
1038
1039         [BlackBerry] Implemented a way to defer client navigation change client notifications
1040         https://bugs.webkit.org/show_bug.cgi?id=78848
1041
1042         Reviewed by Rob Buis.
1043
1044         Currently we postpone touch_down till touch_up if user touches
1045         the screen and an input field has the WebKit focus. This is done
1046         so we can scroll the page without hidding the vkb needlessly.
1047
1048         However, it breaks the conversion of touch to mouse events
1049         if an input field has the focus in the following scenario:
1050         an <input type=text> is focused and an user grab and-drag
1051         a <input type=range> knob/slide. It does not work until the
1052         user unfocuses the currently focused edit field.
1053
1054         Patch introduces a way to unfocus a currently focused input field,
1055         without requesting the client to show or hide the virtual keyboard
1056         right way. Instead it gets a delayed notification of the vkb mode requested
1057         at either touch_released/mouse_up or touch_cancel time.
1058
1059         For now, due to content side issues with major web sites,
1060         only delay navigation mode notification changes if we are not dealing with
1061         input modes.
1062
1063         * WebKitSupport/InputHandler.cpp:
1064         (BlackBerry::WebKit::InputHandler::InputHandler):
1065         (BlackBerry::WebKit::InputHandler::nodeFocused):
1066         (BlackBerry::WebKit::InputHandler::setElementFocused):
1067         (BlackBerry::WebKit::InputHandler::setNavigationMode):
1068         (WebKit):
1069         (BlackBerry::WebKit::InputHandler::setDelayClientNotificationOfNavigationModeChange):
1070         (BlackBerry::WebKit::InputHandler::processPendingClientNavigationModeChangeNotification):
1071         (BlackBerry::WebKit::InputHandler::notifyClientOfNavigationModeChange):
1072         (BlackBerry::WebKit::InputHandler::willOpenPopupForNode):
1073         (BlackBerry::WebKit::InputHandler::setPopupListIndexes):
1074         (BlackBerry::WebKit::InputHandler::spannableTextInRange):
1075         (BlackBerry::WebKit::InputHandler::removeComposedText):
1076         (BlackBerry::WebKit::InputHandler::firstSpanInString):
1077         (BlackBerry::WebKit::InputHandler::setText):
1078         (BlackBerry::WebKit::InputHandler::setRelativeCursorPosition):
1079         * WebKitSupport/InputHandler.h:
1080         (InputHandler):
1081
1082 2012-02-16  Antonio Gomes  <agomes@rim.com>
1083
1084         Crash @WebPagePrivate::enqueueRenderingOfClippedContentOfScrollableNodeAfterInRegionScrolling MKS_2986818
1085         https://bugs.webkit.org/show_bug.cgi?id=78845
1086
1087         Reviewed by Rob Buis.
1088
1089         We were trying to operate on a cached Node when its page/frame/document
1090         were gone to PageCache already. To avoid such problems, lets clean up
1091         any document data we have cached when the Frame goes into the cache.
1092
1093         * WebCoreSupport/FrameLoaderClientBlackBerry.cpp:
1094         (WebCore::FrameLoaderClientBlackBerry::didSaveToPageCache):
1095         (WebCore):
1096         * WebCoreSupport/FrameLoaderClientBlackBerry.h:
1097         (FrameLoaderClientBlackBerry):
1098
1099 2012-02-16  Antonio Gomes  <agomes@rim.com>
1100
1101         [BlackBerry] Upstream touch handling related classes
1102         https://bugs.webkit.org/show_bug.cgi?id=78509
1103
1104         Reviewed by Adam Treat and Rob Buis.
1105
1106         FatFingers is the class responsible to the whole touch
1107         accuracy of the BlackBerry port. Initial upstream.
1108
1109         * WebKitSupport/FatFingers.cpp: Added.
1110         (WebKit):
1111         (BlackBerry::WebKit::FatFingers::fingerRectForPoint):
1112         (BlackBerry::WebKit::hasMousePressListener):
1113         (BlackBerry::WebKit::FatFingers::isElementClickable):
1114         (BlackBerry::WebKit::isFieldWithText):
1115         (BlackBerry::WebKit::distanceBetweenPoints):
1116         (BlackBerry::WebKit::compareDistanceBetweenPoints):
1117         (BlackBerry::WebKit::isValidFrameOwner):
1118         (BlackBerry::WebKit::FatFingers::FatFingers):
1119         (BlackBerry::WebKit::FatFingers::~FatFingers):
1120         (BlackBerry::WebKit::FatFingers::findBestPoint):
1121         (BlackBerry::WebKit::FatFingers::checkFingerIntersection):
1122         (BlackBerry::WebKit::FatFingers::findIntersectingRegions):
1123         (BlackBerry::WebKit::FatFingers::checkForClickableElement):
1124         (BlackBerry::WebKit::FatFingers::checkForText):
1125         (BlackBerry::WebKit::FatFingers::getPaddings):
1126         (BlackBerry::WebKit::FatFingers::nodesFromRect):
1127         (BlackBerry::WebKit::FatFingers::getRelevantInfoFromPoint):
1128         (BlackBerry::WebKit::FatFingers::setSuccessfulFatFingersResult):
1129         * WebKitSupport/FatFingers.h: Added.
1130         (WebCore):
1131         (WebKit):
1132         (FatFingersResult):
1133         (BlackBerry::WebKit::FatFingersResult::FatFingersResult):
1134         (BlackBerry::WebKit::FatFingersResult::reset):
1135         (BlackBerry::WebKit::FatFingersResult::originPosition):
1136         (BlackBerry::WebKit::FatFingersResult::adjustedPosition):
1137         (BlackBerry::WebKit::FatFingersResult::positionWasAdjusted):
1138         (BlackBerry::WebKit::FatFingersResult::isTextInput):
1139         (BlackBerry::WebKit::FatFingersResult::isValid):
1140         (BlackBerry::WebKit::FatFingersResult::validNode):
1141         (BlackBerry::WebKit::FatFingersResult::nodeAsElementIfApplicable):
1142         (FatFingers):
1143
1144 2012-02-16  Antonio Gomes  <agomes@rim.com>
1145
1146         [BlackBerry] Upstream touch handling related classes
1147         https://bugs.webkit.org/show_bug.cgi?id=78509
1148
1149         Reviewed by Adam Treat.
1150
1151         Initial upstream of the Blackberry specific single touch event
1152         handler class.
1153
1154         * blackberry/WebKitSupport/TouchEventHandler.cpp: Added.
1155         (WebKit):
1156         (BlackBerry::WebKit::hasMouseMoveListener):
1157         (BlackBerry::WebKit::hasTouchListener):
1158         (BlackBerry::WebKit::elementExpectsMouseEvents):
1159         (BlackBerry::WebKit::shouldConvertTouchToMouse):
1160         (BlackBerry::WebKit::TouchEventHandler::TouchEventHandler):
1161         (BlackBerry::WebKit::TouchEventHandler::~TouchEventHandler):
1162         (BlackBerry::WebKit::TouchEventHandler::shouldSuppressMouseDownOnTouchDown):
1163         [BlackBerry] Upstream touch handling related classes
1164         https://bugs.webkit.org/show_bug.cgi?id=78509
1165
1166         Reviewed by Rob Buis.
1167
1168         InRegionScrollableArea specializes the BlackBerry specific ScrollViewBase,
1169         working as a read-only wrapper object for a scrollable areas in the page.
1170         It is used in our client side to control in-region scrolling (scrollable boxes,
1171         inner frames, etc).
1172
1173         Initial upstream.
1174
1175         * WebKitSupport/InRegionScrollableArea.cpp: Added.
1176         (WebKit):
1177         (BlackBerry::WebKit::InRegionScrollableArea::InRegionScrollableArea):
1178         (BlackBerry::WebKit::InRegionScrollableArea::calculateMinimumScrollPosition):
1179         (BlackBerry::WebKit::InRegionScrollableArea::calculateMaximumScrollPosition):
1180         (BlackBerry::WebKit::InRegionScrollableArea::layer):
1181         (BlackBerry):
1182         * WebKitSupport/InRegionScrollableArea.h: Added.
1183         (WebCore):
1184         (WebKit):
1185         (InRegionScrollableArea):
1186
1187 2012-02-16  Antonio Gomes  <agomes@rim.com>
1188
1189         (BlackBerry::WebKit::TouchEventHandler::touchEventCancel):
1190         (BlackBerry::WebKit::TouchEventHandler::touchHoldEvent):
1191         (BlackBerry::WebKit::TouchEventHandler::handleTouchPoint):
1192         (BlackBerry::WebKit::TouchEventHandler::spellCheck):
1193         (BlackBerry::WebKit::TouchEventHandler::handleFatFingerPressed):
1194         (BlackBerry::WebKit::elementForTapHighlight):
1195         (BlackBerry::WebKit::TouchEventHandler::drawTapHighlight):
1196         * blackberry/WebKitSupport/TouchEventHandler.h: Added.
1197         (WebCore):
1198         (WebKit):
1199         (TouchEventHandler):
1200         (BlackBerry::WebKit::TouchEventHandler::lastFatFingersResult):
1201         (BlackBerry::WebKit::TouchEventHandler::resetLastFatFingersResult):
1202