2008-09-23 Tor Arne Vestbø <tavestbo@trolltech.com>
[WebKit-https.git] / WebKit / qt / ChangeLog
1 2008-09-23  Tor Arne Vestbø  <tavestbo@trolltech.com>
2
3         Reviewed by Simon.
4
5         Remove deprecated JS Qt bindings object call/construct code and fix autotests
6
7         * tests/qwebframe/tst_qwebframe.cpp:
8
9 2008-09-16  Alp Toker  <alp@nuanti.com>
10
11         Prospective Qt build fix. ScrollBar.h -> Scrollbar.h
12
13         * Api/qwebframe.cpp:
14         * Api/qwebpage.cpp:
15
16 2008-09-15  Eli Fidler  <eli@staikos.net>
17
18         Reviewed by Simon.
19
20         Yahoo assumes non-RFC compliant HTTP redirect behaviour. QtWebKit is (more)
21         compliant, so broken. I think the Yahoo-assumed behaviour is real-world standard.
22
23         Basically, Yahoo's login procedure for flickr looks like this:
24         1. load flickr.com, click "sign in"
25         2. this is a Yahoo page with a form
26         (https://login.yahoo.com/config/login?.src=flickr...)
27         when you click the "Sign In" button, the form submits to a yahoo.com POST URL
28         3. The POST returns with a 302 (redirect) to another yahoo.com URL
29         4. If you POST the redirected Location:, it all breaks. Yahoo assumes you will
30         convert the method to GET, which works fine but is definitely not
31         RFC-compliant. It would be compliant for 303, and the RFC says that many
32         implementations treat 302 and 303 the same way (for HTTP/1.0 compliance), but
33         converting to GET is explicitly wrong for 302.
34
35         * Api/qwebnetworkinterface.cpp:
36         (QWebNetworkManager::started):
37
38 2008-09-15  Tor Arne Vestbø  <tavestbo@trolltech.com>
39
40         Reviewed by Simon.
41
42         Make QtInstance::create() private and fix caching
43
44         * Api/qwebframe.cpp:
45         (QWebFrame::addToJavaScriptWindowObject):
46
47 2008-09-11  Tor Arne Vestbø  <tavestbo@trolltech.com>
48
49         Rubber-stamped by Simon.
50
51         Prevent leaking pages and frames in QWebKit autotest
52
53         * tests/qwebpage/tst_qwebpage.cpp:
54
55 2008-09-11  Tor Arne Vestbø  <tavestbo@trolltech.com>
56
57         Reviewed by Simon
58
59         Fix QtWebKit autotest
60
61         * tests/qwebpage/tst_qwebpage.cpp:
62         (tst_QWebPage::userStyleSheet):
63
64 2008-09-09  Joerg Bornemann  <joerg.bornemann@trolltech.com>
65
66         Reviewed by Simon.
67
68         Added missing WebCore prefix to ResourceRequest
69
70         This is needed for Windows/CE compilation where there is a conflict
71         with a global ResourceRequest type. Elsewhere in this file ResourceRequest
72         is also prefixed with WebCore::
73
74         * Api/qwebframe.cpp:
75         (QWebFrame::QWebFrame):
76
77 2008-09-07  Cameron Zwarich  <cwzwarich@uwaterloo.ca>
78
79         Reviewed by Maciej Stachowiak.
80
81         Bug 20704: Replace the KJS namespace
82         <https://bugs.webkit.org/show_bug.cgi?id=20704>
83
84         Rename the KJS namespace to JSC.
85
86         * Api/qwebframe.cpp:
87         (QWebFrame::addToJavaScriptWindowObject):
88         (QWebFrame::evaluateJavaScript):
89
90 2008-09-04  Tor Arne Vestbø  <tavestbo@trolltech.com>
91
92         Reviewed by Simon
93
94         Fix the QtWebKit build to match changes in r36016
95
96         * Api/qwebframe.cpp:
97         (QWebFrame::addToJavaScriptWindowObject):
98
99 2008-09-04  Tor Arne Vestbø  <tavestbo@trolltech.com>
100
101         Reviewed by Simon.
102
103         Re-enable support for user stylesheets in QtWebKit
104         
105         QtWebKit now follows the FRAME_LOADS_USER_STYLESHEET
106         code path, which allows us to keep API support for
107         loading user style sheets from remote URLs.
108         
109         As part of the change UserStyleSheetLoader.cpp/h was
110         moved from WebCore/loader/mac to WebCore/loader.
111
112         * tests/qwebpage/tst_qwebpage.cpp:
113         (tst_QWebPage::userStyleSheet):
114
115 2008-08-29  Holger Hans Peter Freyther  <zecke@selfish.org>
116
117         Reviewed by Eric Seidel.
118
119         [janitor/qt] Start replacing port specific getters with the generic native getter
120         To get the native presentation of an image we currently have platform
121         specific #ifdef's and a generic getter using NativeImagePtr. This patch
122         extends this to the ImageBuffer and updates the Qt platform to get rid
123         of the special #ifdefs.
124
125         https://bugs.webkit.org/attachment.cgi?id=22861
126
127         * Api/qwebframe.cpp:
128         (QWebHitTestResultPrivate::QWebHitTestResultPrivate):
129         * Api/qwebhistory.cpp:
130         * Api/qwebsettings.cpp:
131         (QWebSettings::iconForUrl):
132
133 2008-08-29  Holger Hans Peter Freyther  <zecke@selfish.org>
134
135         Reviewed by Simon.
136
137         Catch up with the introduction of PageGroup in r30840. Enable tracking of
138         visited links, enable this in QWebPage next to the other WebCore init call.
139         Calling this more than once is no issue and a cheap operation, we also do not
140         reset the state. When clearing the history of a page, clear the link state.
141
142         * Api/qwebhistory.cpp:
143         (QWebHistory::clear):
144         * Api/qwebhistoryinterface.cpp:
145         (QWebHistoryInterface::setDefaultInterface):
146         * Api/qwebpage.cpp:
147         (QWebPagePrivate::QWebPagePrivate):
148
149 2008-08-29  Holger Hans Peter Freyther  <zecke@selfish.org>
150
151         Reviewed by Simon.
152
153         Revert revision 34348 which removed the global historyContains() function.
154
155         This function was needed to implement the public API of QWebHistoryInterface
156         and will be used again in the near future.
157
158         * Api/qwebhistoryinterface.cpp:
159         (WebCore::historyContains):
160
161 2008-08-27  Erik Bunce  <elbunce@thehive.com>
162
163         Reviewed by Eric Seidel.
164
165         https://bugs.webkit.org/show_bug.cgi?id=20223
166
167         Add QWebPage::contentsChanged() signal to notify of content changes.
168
169         * Api/qwebpage.cpp:
170         * Api/qwebpage.h:
171         * WebCoreSupport/EditorClientQt.cpp:
172         (WebCore::EditorClientQt::respondToChangedContents):
173
174 2008-08-27  Brady Eidson  <beidson@apple.com>
175
176         Reviewed by Anders
177
178         <rdar://problem/6134133> - Crash when loading large movie as a standalone document
179
180         * WebCoreSupport/FrameLoaderClientQt.cpp:
181         (WebCore::FrameLoaderClientQt::pluginWillHandleLoadError): Stubbed for now
182         * WebCoreSupport/FrameLoaderClientQt.h:
183
184 2008-08-25  Holger Hans Peter Freyther  <zecke@selfish.org>
185
186         Reviewed by Simon.
187
188         [inspector] Emit signals from attachWindow and detachWindow in the Qt platform
189         Allow the user of the API to honor the attachWindow and detachWindow
190         requests and attach the QWebPage/QWebView wherever it is wanted. This needs
191         some more API in QWebPage to be properly exposed.
192
193         * WebCoreSupport/InspectorClientQt.cpp:
194         (WebCore::InspectorClientQt::createPage):
195         (WebCore::InspectorClientQt::attachWindow):
196         (WebCore::InspectorClientQt::detachWindow):
197         * WebCoreSupport/InspectorClientQt.h:
198
199 2008-08-19  Alexey Proskuryakov  <ap@webkit.org>
200
201         Reviewed by Geoff Garen.
202
203         Bring back shared JSGlobalData and implicit locking, because too many clients rely on it.
204
205         * Api/qwebframe.cpp:
206         (QWebFrame::addToJavaScriptWindowObject):
207
208 2008-08-15  Håvard Wall  <hwall@trolltech.com>
209
210         Reviewed by Simon.
211
212         Fixes: compile with QT_NO_UNDOCOMMAND/STACK
213         
214
215         * Api/qwebpage.cpp:
216         (SetCursorEvent::SetCursorEvent):
217         (QWebPagePrivate::createContextMenu):
218         (QWebPage::action):
219         * Api/qwebpage.h:
220         * Api/qwebpage_p.h:
221         * WebCoreSupport/EditCommandQt.cpp:
222         (EditCommandQt::EditCommandQt):
223         * WebCoreSupport/EditCommandQt.h:
224         * WebCoreSupport/EditorClientQt.cpp:
225         (dumpPath):
226         (WebCore::EditorClientQt::shouldInsertText):
227         (WebCore::EditorClientQt::shouldChangeSelectedRange):
228         (WebCore::EditorClientQt::isEditable):
229         (WebCore::EditorClientQt::registerCommandForUndo):
230         (WebCore::EditorClientQt::clearUndoRedoOperations):
231         (WebCore::EditorClientQt::canUndo):
232         (WebCore::EditorClientQt::canRedo):
233         (WebCore::EditorClientQt::undo):
234         (WebCore::EditorClientQt::redo):
235         (WebCore::EditorClientQt::shouldInsertNode):
236
237 2008-08-15  Håvard Wall  <hwall@trolltech.com>
238
239         Reviewed by Simon.
240
241         Fixes: compile with QT_NO_STYLE_STYLESHEET
242         
243
244         * WebCoreSupport/FrameLoaderClientQt.cpp:
245         (WebCore::FrameLoaderClientQt::postProgressFinishedNotification):
246         (WebCore::FrameLoaderClientQt::createPlugin):
247
248 2008-08-15  Håvard Wall  <hwall@trolltech.com>
249
250         Reviewed by Simon.
251
252         Fixes: compile with QT_NO_SHORTCUT
253         
254
255         * Api/qwebpage.cpp:
256         (QWebPagePrivate::mouseMoveEvent):
257         (QWebPagePrivate::mouseReleaseEvent):
258         (QWebPagePrivate::dragMoveEvent):
259
260 2008-08-15  Håvard Wall  <hwall@trolltech.com>
261
262         Reviewed by Simon.
263
264         Fixes:    compile with QT_NO_CONTEXTMENU
265         
266
267         * Api/qwebpage.cpp:
268         (editorCommandForWebActions):
269         (QWebPagePrivate::QWebPagePrivate):
270         (QWebPagePrivate::createMainFrame):
271         (QWebPagePrivate::updateEditorActions):
272         (QWebPage::setEditable):
273         * Api/qwebpage.h:
274         * Api/qwebpage_p.h:
275         * Api/qwebview.cpp:
276         * Api/qwebview.h:
277
278 2008-08-15  Håvard Wall  <hwall@trolltech.com>
279
280         Reviewed by Simon.
281
282         Fixes: compile with QT_NO_WHEELEVENT
283         
284
285         * Api/qwebpage.cpp:
286         (QWebPagePrivate::updateEditorActions):
287         (QWebPage::event):
288         * Api/qwebpage_p.h:
289         * Api/qwebview.cpp:
290         * Api/qwebview.h:
291
292 2008-08-15  Håvard Wall  <hwall@trolltech.com>
293
294         Reviewed by Simon.
295
296         Fixes: compile with QT_NO_PRINTER
297         
298
299         * Api/qwebframe.cpp:
300         (QWebFrame::print):
301         * Api/qwebframe.h:
302
303 2008-08-15  David Boddie  <dboddie@trolltech.com>
304
305         Reviewed by Simon.
306
307         Doc: Added documentation for default property values.
308         
309
310         * Api/qwebpage.cpp:
311         (QWebPagePrivate::keyPressEvent):
312         (QWebPage::triggerAction):
313         (QWebPage::acceptNavigationRequest):
314         (QWebPage::action):
315         * Api/qwebview.cpp:
316
317 2008-08-15  David Boddie  <dboddie@trolltech.com>
318
319         Reviewed by Simon.
320
321         Doc: Renamed snippets that appear in the code directory.
322         
323
324         * Api/qwebview.cpp:
325         (QWebView::event):
326         (QWebView::print):
327
328 2008-08-12  Timothy Hatcher  <timothy@apple.com>
329
330         Add a stub for InspectorClient::setAttachedWindowHeight.
331
332         * WebCoreSupport/InspectorClientQt.cpp:
333         (WebCore::InspectorClientQt::setAttachedWindowHeight):
334         Call notImplemented().
335         * WebCoreSupport/InspectorClientQt.h:
336
337 2008-08-13  Ariya Hidayat  <ariya.hidayat@trolltech.com>
338
339         Reviewed by Simon.
340
341         Use full-page zoom in QtLauncher.
342
343         * QtLauncher/main.cpp:
344         (MainWindow::zoomIn):
345         (MainWindow::zoomOut):
346         (MainWindow::resetZoom):
347         (MainWindow::setupUI):
348
349 2008-08-13  Ariya Hidayat  <ariya.hidayat@trolltech.com>
350
351         Reviewed by Simon.
352
353         Fix linking with QtWebKit.
354
355         * Api/qwebframe.h: remove non-existing function/property.
356
357 2008-08-13  Simon Hausmann  <hausmann@webkit.org>
358
359         Reviewed by Holger.
360
361         Based on patch by Siraj razick <siraj.razick@collabora.co.uk>
362
363         https://bugs.webkit.org/show_bug.cgi?id=19125
364
365         Added functions to get/set the zoom factor.
366
367         Added a QWebFrame/QWebView::zoomFactor as well as a boolean
368         ZoomTextOnly attribute in QWebSettings.
369
370         * Api/qwebframe.cpp:
371         (QWebFrame::setZoomFactor):
372         (QWebFrame::zoomFactor):
373         * Api/qwebframe.h:
374         * Api/qwebsettings.cpp:
375         (QWebSettingsPrivate::apply):
376         (QWebSettings::QWebSettings):
377         * Api/qwebsettings.h:
378         * Api/qwebview.cpp:
379         (QWebView::setZoomFactor):
380         (QWebView::zoomFactor):
381         * Api/qwebview.h:
382
383 2008-08-13  Simon Hausmann  <hausmann@webkit.org>
384
385         Reviewed by Lars.
386
387         Fix QWebFrame::setHtml() not setting the new contents immediately.
388
389         Added a setter to the DocumentLoader to toggle the deferred loading of the main
390         resource when it comes from substitute data.
391
392         Disable deferred loading of the main resource when we have valid substitute data,
393         as used by QWebFrame::setHtml.
394
395         * WebCoreSupport/FrameLoaderClientQt.cpp:
396         (WebCore::FrameLoaderClientQt::download):
397
398 2008-08-13  Simon Hausmann  <hausmann@webkit.org>
399
400         Rubber-stamped by Holger.
401
402         Fix QWebPage::isModified().
403
404         isModified() would return true after loading a new page or it would continue to
405         return true after undoing modifications. Fix this by eliminating the
406         QWebPagePrivate::modified variable and use the undoStack's canUndo() property
407         instead.
408
409         https://bugs.webkit.org/show_bug.cgi?id=19252
410
411         * Api/qwebpage.cpp:
412         (QWebPage::action):
413         * Api/qwebpage_p.h:
414         * WebCoreSupport/EditorClientQt.cpp:
415         (WebCore::EditorClientQt::respondToChangedContents):
416
417 2008-08-13  David Boddie  <dboddie@trolltech.com>
418
419         Reviewed by Simon.
420
421         Updated docs with the signal emission behavior of urlChanged()
422
423         * Api/qwebframe.cpp:
424
425 2008-08-13  Ariya Hidayat  <ariya.hidayat@trolltech.com>
426
427         Reviewed by Simon.
428
429         Fix Ctrl+Y to work again when editing text in contextEditable mode.
430
431         This fixes regression in LayoutTests/editing/pasteboard/emacs-cntl-y-001.html
432
433         * WebCoreSupport/EditorClientQt.cpp:
434         (WebCore::EditorClientQt::handleKeyboardEvent):
435
436 2008-08-13  Thiago Macieira  <tjmaciei@trolltech.com>
437
438         Reviewed by Simon.
439
440         Fix encoding of [ and ] in the host part of the URL
441
442         Until QUrl is fixed (making QUrl's tolerant parser more tolerant), we have to
443         add this workaround to the QUrl <> WebCore::KURL conversion operator so that it
444         doesn't encode [ and ] when they are found in the host part. That is, the
445         following URL:
446         http://[::1]/
447         is valid and should not be reencoded to:
448         http://%5b::1%5d/
449
450         This change adds the automatic test for it.
451
452         * tests/qwebframe/tst_qwebframe.cpp:
453
454 2008-08-12  Urs Wolfer  <uwolfer@kde.org>
455
456         Reviewed by Simon.
457
458         https://bugs.webkit.org/show_bug.cgi?id=20357
459
460         Fix crash in QWebPage in case contextMenuEvent has been overwritten
461         because context menu has the view as parent and thus is deleted too early.
462
463         Add testcase for this crash.
464
465         * Api/qwebpage_p.h:
466         * tests/qwebpage/tst_qwebpage.cpp:
467         (tst_QWebPage::contextMenuCrash):
468
469 2008-08-07  Simon Hausmann  <hausmann@webkit.org>
470
471         Rubber-stamped by Lars.
472
473         Added API tests for QWebPage/QWebFrame based on QTestLib.
474
475         * tests/qwebframe/qwebframe.pro: Added.
476         * tests/qwebframe/tst_qwebframe.cpp: Added.
477         * tests/qwebpage/qwebpage.pro: Added.
478         * tests/qwebpage/tst_qwebpage.cpp: Added.
479         * tests/tests.pro: Added.
480
481 2008-08-06  Benjamin C Meyer  <ben@meyerhome.net>
482
483         Reviewed by Simon.
484
485         During the drag operation only accept the event if the action is not ignore action.
486
487         * Api/qwebpage.cpp:
488         (QWebPagePrivate::dragEnterEvent):
489         (QWebPagePrivate::dragMoveEvent):
490         (QWebPagePrivate::dropEvent):
491
492 2008-08-06  Ariya Hidayat  <ariya.hidayat@trolltech.com>
493
494         Fix the Qt build due to recent ScriptController refactoring.
495
496         * Api/qwebframe.cpp:
497         (QWebFrame::addToJavaScriptWindowObject):
498
499 2008-08-05  Tor Arne Vestbø  <tavestbo@trolltech.com>
500
501         Reviewed by Simon.
502
503         Move event handling of the return-key from EditorClientQt to QWebPage.
504         
505         https://bugs.webkit.org/show_bug.cgi?id=20191
506         
507         This is a first step in refactoring the big switch block
508         in EditorClientQt::handleKeyboardEvent to using WebActions
509         instead.
510         
511         The new logic uses two new StandardKeys from QKeySequence:
512         
513         - InsertParagraphSeparator
514         - InsertLineSeparator
515         
516         Which translate to the commands InsertNewline and InsertLineBreak
517         respectivly. On Windows/X11 pressing the shift modifier will invoke
518         the latter action. For Mac this is triggered by pressing the meta
519         modifier (Ctrl).
520         
521         Initial patch by: Erik Bunce
522
523         * Api/qwebpage.cpp:
524         (editorActionForKeyEvent):
525         * Api/qwebpage.h:
526         * WebCoreSupport/EditorClientQt.cpp:
527         (WebCore::EditorClientQt::handleKeyboardEvent):
528
529 2008-08-04  Erik Bunce  <elbunce@thehive.com>
530
531         Reviewed by Simon.
532
533         https://bugs.webkit.org/show_bug.cgi?id=20221
534
535         Add updateAction() support to ToggleBold, ToggleItalic, and ToggleUnderline.
536         Add lookup table for mapping web actions to editor commands.
537
538         * Api/qwebpage.cpp:
539         (editorCommandForWebActions):
540         (QWebPagePrivate::updateAction):
541         (QWebPagePrivate::updateEditorActions):
542         (QWebPage::triggerAction):
543         (QWebPage::setEditable):
544
545 2008-08-03  Ariya Hidayat  <ariya.hidayat@trolltech.com>
546
547         Reviewed by Simon.
548
549         A bunch of improvements to the QtLauncher.
550
551         Among others:
552         - Unify and unclutter the toolbar, use menu for addition actions
553         - Simplify URL edit, just use QLineEdit (no fancy close button etc)
554         - Guess the URL from the command line so now we can run ./QtLauncher www.google.com
555         - Shortcut keys for most actions
556         - Simple autocomplete for the URL edit
557         - Actions for zooming, New Window and Close Window
558         - Show Format menu only when the content is set to editable
559
560         * QtLauncher/main.cpp:
561         (MainWindow::MainWindow):
562         (MainWindow::webPage):
563         (MainWindow::changeLocation):
564         (MainWindow::loadFinished):
565         (MainWindow::showLinkHover):
566         (MainWindow::newWindow):
567         (MainWindow::zoomIn):
568         (MainWindow::zoomOut):
569         (MainWindow::resetZoom):
570         (MainWindow::print):
571         (MainWindow::setEditable):
572         (MainWindow::dumpHtml):
573         (MainWindow::setupUI):
574         (main):
575
576 2008-08-04  Erik Bunce  <elbunce@thehive.com>
577
578         Reviewed by Simon.
579
580         https://bugs.webkit.org/show_bug.cgi?id=20198
581
582         Allow Copy key sequence to work in non-editable areas.
583
584         * Api/qwebpage.cpp:
585         (QWebPagePrivate::keyPressEvent):
586
587 2008-07-31  Erik Bunce  <elbunce@thehive.com>
588
589         Reviewed by Simon.
590
591         Make sure edit actions get updated when the contents change.
592
593         * WebCoreSupport/EditorClientQt.cpp:
594         (WebCore::EditorClientQt::respondToChangedContents):
595
596 2008-07-31  Erik Bunce  <elbunce@thehive.com>
597
598         Reviewed by Simon.
599
600         Add simple edit test abilities to QtLauncher.
601
602         * QtLauncher/main.cpp:
603         (MainWindow::MainWindow):
604         (MainWindow::setEditable):
605         (MainWindow::dumpHtml):
606
607 2008-07-31  Alexey Proskuryakov  <ap@webkit.org>
608
609         Rubber-stamped by Maciej.
610
611         Eliminate JSLock (it was already disabled, removing the stub implementaion and all
612         call sites now).
613
614         * Api/qwebframe.cpp:
615         (QWebFrame::addToJavaScriptWindowObject):
616
617 2008-07-27  David Kilzer  <ddkilzer@apple.com>
618
619         Fix Qt build failure.
620
621         * Api/qwebframe.h:
622         (QWebFrame::setScrollOffset): Make argument const.
623
624 2008-07-26  Marc Ordinas i Llopis  <marc.ordinasillopis@collabora.co.uk>
625
626         Reviewed by Simon Hausmann.
627
628         https://bugs.webkit.org/show_bug.cgi?id=20010
629         [Qt] Add API access to scrolling
630
631         * Api/qwebframe.cpp: Added access to a frame scroll offset.
632         (QWebFrame::scroll):
633         (QWebFrame::scrollOffset):
634         (QWebFrame::setScrollOffset):
635         * Api/qwebframe.h:
636
637 2008-07-26  Daniel Jalkut  <jalkut@red-sweater.com>
638
639         Build fix.  Adjust to updated WebCore FrameLoader method names & signatures.
640
641         * Api/qwebpage.cpp:
642         (QWebPage::triggerAction):
643         * WebCoreSupport/FrameLoaderClientQt.cpp:
644         (WebCore::FrameLoaderClientQt::createFrame):
645
646 2008-07-25  Joerg Bornemann  <joerg.bornemann@trolltech.com>
647
648         Reviewed by Simon.
649
650         Compile with QT_NO_PRINTER.
651
652         * QtLauncher/main.cpp:
653         (MainWindow::MainWindow):
654
655 2008-07-24  Tor Arne Vestbø  <tavestbo@trolltech.com>
656
657         Reviewed by Simon
658
659         Don't insert text on keyDown event in EditorClientQt.
660
661         * WebCoreSupport/EditorClientQt.cpp:
662         (WebCore::EditorClientQt::handleKeyboardEvent):
663
664 2008-07-04  Benjamin C Meyer  <ben@meyerhome.net>
665
666         Reviewed by Simon.
667
668         Update the webkit version in the QtWebKit useragent string to match trunk
669
670         * Api/qwebpage.cpp:
671
672 2008-07-02  Simon Hausmann  <hausmann@webkit.org>
673
674         Build fix.
675
676         * Api/qwebpage.cpp:
677         (QWebPage::triggerAction): The signature of setBaseWritingDirection
678         changed to take an enum instead of a string.
679
680 2008-07-01  Alexey Proskuryakov  <ap@webkit.org>
681
682         Reviewed by Darin Adler.
683
684         Disable JSLock for per-thread contexts.
685
686         * Api/qwebframe.cpp:
687         (QWebFrame::addToJavaScriptWindowObject):
688         Pass a parameter (false) to JSLock to indicate that WebKit doesn't need locking.
689         Include JSLock.h, as it is no longer brought in implicitly.
690
691 2008-07-01  Tor Arne Vestbø  <tavestbo@trolltech.com>
692
693         Reviewed by Simon.
694
695         Don't show the tooltip instantly in the QtLauncher.
696         
697         Let the QWebView handle tooltips by itself, so we get
698         the expected delay as everywhere else.
699
700         * QtLauncher/main.cpp:
701
702 2008-06-30  Simon Hausmann  <hausmann@webkit.org>
703
704         Rubber-stamped by Niko.
705
706         Removed the obsolete and unmaintained WebKitPart. The integration of
707         QtWebKit into KDE is now done in the webkitkde component inside KDE.
708
709         * WebKitPart/WebKitFactory.cpp: Removed.
710         * WebKitPart/WebKitFactory.h: Removed.
711         * WebKitPart/WebKitPart.cpp: Removed.
712         * WebKitPart/WebKitPart.desktop: Removed.
713         * WebKitPart/WebKitPart.h: Removed.
714         * WebKitPart/WebKitPart.rc: Removed.
715         * WebKitPart/WebKitPartBrowser.rc: Removed.
716         * WebKitPart/WebKitPartBrowserExtension.cpp: Removed.
717         * WebKitPart/WebKitPartBrowserExtension.h: Removed.
718         * WebKitPart/WebKitPartClient.cpp: Removed.
719         * WebKitPart/WebKitPartClient.h: Removed.
720         * WebKitPart/WebKitPartInterface.cpp: Removed.
721         * WebKitPart/WebKitPartInterface.h: Removed.
722         * WebKitPart/org.kde.WebKitPart.xml: Removed.
723
724 2008-06-24  Simon Hausmann  <hausmann@webkit.org>
725
726         Fix the Qt build, added missing include for RuntimeObjectImp.
727
728         * Api/qwebframe.cpp:
729
730 2008-06-23  Benjamin C Meyer  <ben@meyerhome.net>
731
732         Reviewed by Simon.
733
734         Add function to retrieve the standard context menu
735
736 2008-06-20  Marc Ordinas i Llopis  <marc.ordinasillopis@collabora.co.uk>
737
738         Reviewed by Simon.
739
740         https://bugs.webkit.org/show_bug.cgi?id=19082
741         [Qt] Full-page plugins not activated
742
743         * WebCoreSupport/FrameLoaderClientQt.cpp:
744         (WebCore::FrameLoaderClientQt::committedLoad): Re-check if there's a
745         plugin present, as it can be created during the function.
746
747 2008-06-20  Marco Barisione  <marco.barisione@collabora.co.uk>
748
749         Reviewed by Simon.
750
751         https://bugs.webkit.org/show_bug.cgi?id=19082
752         [Qt] Full-page plugins not activated
753
754         * WebCoreSupport/FrameLoaderClientQt.cpp:
755         (WebCore::FrameLoaderClientQt::canShowMIMEType): Return true if the
756         MIME type is supported by a plugin.
757
758 2008-06-18  Alexey Proskuryakov  <ap@webkit.org>
759
760         Reviewed by Darin Adler.
761
762         Prepare JavaScript heap for being per-thread.
763
764         * Api/qwebframe.cpp:
765         (QWebFrame::addToJavaScriptWindowObject): Trying not to break the build.
766
767 2008-06-18  Julien Chaffraix  <jchaffraix@webkit.org>
768
769         Qt Build fix after r34627.
770
771         * WebCoreSupport/FrameLoaderClientQt.cpp:
772         (WebCore::FrameLoaderClientQt::createPlugin):
773
774 2008-06-15  Darin Adler  <darin@apple.com>
775
776         - give Frame object functions shorter names: scriptProxy() -> script(),
777           selectionController() -> selection(), animationController() -> animation()
778
779         * Api/qwebframe.cpp:
780         (QWebFrame::evaluateJavaScript):
781         * Api/qwebpage.cpp:
782         (QWebPagePrivate::focusInEvent):
783         (QWebPagePrivate::focusOutEvent):
784         (QWebPage::inputMethodQuery):
785         * WebCoreSupport/EditorClientQt.cpp:
786         (WebCore::EditorClientQt::handleKeyboardEvent):
787
788 2008-06-15  Darin Adler  <darin@apple.com>
789
790         - new names for more JavaScriptCore files
791
792         * WebKit_pch.h:
793
794 2008-06-15  Darin Adler  <darin@apple.com>
795
796         - new names for a few key JavaScriptCore files
797
798         * Api/qwebframe.cpp:
799
800 2008-06-14  Darin Adler  <darin@apple.com>
801
802         Rubber stamped by Sam.
803
804         - new names for kjs_binding.h and kjs_proxy.h
805
806         * Api/qwebframe.cpp:
807         (QWebFrame::evaluateJavaScript):
808         * WebKit_pch.h:
809
810 2008-06-14  Darin Adler  <darin@apple.com>
811
812         - fix build
813
814         * Api/qwebframe.cpp:
815         (QWebFramePrivate::init): Added a missing semicolon.
816
817 2008-06-14  Darin Adler  <darin@apple.com>
818
819         Reviewed by Sam.
820
821         - more https://bugs.webkit.org/show_bug.cgi?id=17257
822           start ref counts at 1 instead of 0 for speed
823
824         * Api/qwebframe.cpp:
825         (QWebFramePrivate::init): Use create instead of new.
826         * WebCoreSupport/FrameLoaderClientQt.cpp:
827         (WebCore::FrameLoaderClientQt::createDocumentLoader): Ditto.
828
829 2008-06-13  Darin Adler  <darin@apple.com>
830
831         - try to fix build
832
833         * WebCoreSupport/FrameLoaderClientQt.h: Add missing argument.
834
835 2008-06-13  Darin Adler  <darin@apple.com>
836
837         Reviewed by John Sullivan.
838
839         - updated for addition of FormState argument to action policy functions
840
841         * WebCoreSupport/FrameLoaderClientQt.cpp:
842         (WebCore::FrameLoaderClientQt::dispatchDecidePolicyForNewWindowAction):
843         (WebCore::FrameLoaderClientQt::dispatchDecidePolicyForNavigationAction):
844
845 2008-06-11  Ariya Hidayat  <ariya.hidayat@trolltech.com>
846
847         Reviewed by Simon.
848
849         Fix left-click and middle-click mouse event are not properly accepted.
850         
851         When copying or pasting text using left or middle-click, the event must be
852         accepted so that it will not be potentially processed further by the parent
853         and/or sub-classed widget.
854         
855
856         * Api/qwebpage.cpp:
857         (QWebPagePrivate::mouseReleaseEvent):
858
859 2008-06-11  Ariya Hidayat  <ariya.hidayat@trolltech.com>
860
861         Reviewed by Simon.
862
863         Fix input element does not accept character typed in using AltGr.
864
865         EditorClient is modified to catch AltGr and Ctrl+Alt key combination.
866         This fixes http://trolltech.com/developer/task-tracker/index_html?id=207050&method=entry
867
868         * WebCoreSupport/EditorClientQt.cpp:
869         (WebCore::EditorClientQt::handleKeyboardEvent):
870
871 2008-05-26  Jonathon Jongsma  <jonathon.jongsma@collabora.co.uk>
872
873         Reviewed by Simon.
874
875         https://bugs.webkit.org/show_bug.cgi?id=19323
876
877         Implemented the QWebPage::editable property.
878
879         Small documentation fixes by Simon.
880
881         * Api/qwebpage.cpp:
882         (QWebPagePrivate::QWebPagePrivate):
883         (QWebPage::setEditable):
884         (QWebPage::isEditable):
885         * Api/qwebpage.h:
886         * Api/qwebpage_p.h: implement the editable property and add API so that
887         applications can switch edit mode on and off for a particular QWebPage
888         * WebCoreSupport/EditorClientQt.cpp: retrieve editable property from the
889         QWebPage instead of always returning false
890
891 2008-06-09  Tor Arne Vestbø  <tavestbo@trolltech.com>
892
893         Reviewed by Simon
894
895         Make sure web action in context menus have the right enablement,
896         while not messing up other web actions not included in the menu.
897
898         * Api/qwebpage.cpp:
899         (QWebPagePrivate::createContextMenu):
900         (QWebPage::updatePositionDependentActions):
901         * Api/qwebpage_p.h:
902
903 2008-06-09  Benjamin C Meyer  <ben@meyerhome.net>
904
905         Reviewed by Simon
906
907         Add Shift-Space shortcut to go up one screen, the opposite of Space
908         which goes down one screen.
909
910         * Api/qwebpage.cpp:
911         (QWebPagePrivate::handleScrolling):
912
913 2008-06-04  Tor Arne Vestbø  <tavestbo@trolltech.com>
914
915         Reviewed by Simon.
916
917         Fix a failing assertion when calling QWebFrame::evaluateJavaScript.
918
919         The starting line number has to be 1 instead of 0.
920
921         * Api/qwebframe.cpp:
922         (QWebFrame::evaluateJavaScript):
923
924 2008-06-03  Jonathon Jongsma  <jonathon.jongsma@collabora.co.uk>
925
926         Reviewed by Darin Adler.
927
928         * Api/qwebhistoryinterface.cpp: Remove WebCore::historyContains().  This
929         function is not used anywhere internally and is only a convenience
930         function that can still be accomplished using
931         QWebHistoryInterface::historyContains();
932
933 2008-05-29  Kavindra Devi Palaraja  <kdpalara@trolltech.com>
934
935         Reviewed by Simon.
936
937         Doc: Mention the requirement of a QApplication with QtWebKit
938         
939
940         * Api/qwebview.cpp:
941
942 2008-05-29  David Boddie  <dboddie@trolltech.com>
943
944         Reviewed by Simon.
945
946         Some clarifications for the documentation.
947         
948
949         * Api/qwebpage.cpp:
950         * Api/qwebpluginfactory.cpp:
951
952 2008-05-27  Ariya Hidayat  <ariya.hidayat@trolltech.com>
953
954         Reviewed by Simon.
955
956         Fix web inspector does not returns its state properly after its window is minimized.
957
958         As hinted by Holger, InspectorClientView::hideEvent is not needed.
959         This fixes bug https://bugs.webkit.org/show_bug.cgi?id=18967
960
961         * WebCoreSupport/InspectorClientQt.cpp:
962
963 2008-05-21  Siraj Razick  <siraj.razick@collabora.co.uk>
964
965         Reviewed by Simon.
966
967         Add <param name="classid"/> support for application/x-qt-object plugins
968
969         * WebCoreSupport/FrameLoaderClientQt.cpp:
970         (WebCore::FrameLoaderClientQt::createPlugin):
971
972 2008-05-13  Andy Shaw  <andy@trolltech.com>
973
974         Reviewed by Simon.
975
976         Fixes: QWebHistory::forward() should go forwards and not back
977
978         * Api/qwebhistory.cpp:
979
980 2008-05-12  Alexey Proskuryakov  <ap@webkit.org>
981
982         Roll out recent  threading changes (r32807, r32810, r32819, r32822) to simplify
983         SquirrelFish merging.
984
985         * Api/qwebframe.cpp:
986         (QWebFrame::addToJavaScriptWindowObject):
987
988 2008-05-09  Thiago Macieira  <tjmaciei@trolltech.com>
989
990         Reviewed by Simon.
991
992         Fix bad includes in QtWebKit public headers.
993         
994         Make sure to include qglobal.h using the QtCore prefix so that an explicit
995         include/QtCore is not needed in the application's build system. Also make sure
996         that qwebsettings.h includes the local qwebkitglobal.h.
997         
998
999         * Api/qwebkitglobal.h:
1000         * Api/qwebsettings.h:
1001
1002 2008-05-08  Marc Ordinas i Llopis  <marc.ordinasillopis@collabora.co.uk>
1003
1004         Reviewed by Simon.
1005
1006         https://bugs.webkit.org/show_bug.cgi?id=18935
1007
1008         Based on work by Sriram Neelakandan for the Gtk port.
1009
1010         * WebCoreSupport/FrameLoaderClientQt.cpp: Initialize
1011         m_hasSentResponseToPlugin.
1012         (WebCore::FrameLoaderClientQt::FrameLoaderClientQt):
1013         (WebCore::FrameLoaderClientQt::redirectDataToPlugin):
1014
1015 2008-05-08  Warwick Allison  <warwick@trolltech.com>
1016
1017         Reviewed by Simon.
1018
1019         Fixes: WebKit expects initial input method state to be *disabled*.
1020         
1021         At least QWS does not need the initial input method state to be forced to
1022         enabled, but other platforms (esp. X11) do. Until fixed/tested on those
1023         platforms, this is specific to QWS.
1024         
1025
1026         * Api/qwebview.cpp:
1027         (QWebView::QWebView):
1028
1029 2008-05-06  Simon Hausmann  <hausmann@webkit.org>
1030
1031         Reviewed by Holger.
1032
1033         Fix logic error in QWebHitTestResult::isNull().
1034
1035         * Api/qwebframe.cpp:
1036
1037 2008-05-02  Benjamin Meyer  <bmeyer@trolltech.com>
1038
1039         Reviewed by Simon.
1040
1041         Doc: Mention that you have to enable plugins in QWebSettings for them to work.
1042
1043         * Api/qwebpage.cpp:
1044
1045 2008-05-02  Simon Hausmann  <hausmann@webkit.org>
1046
1047         Fix the Qt build, ExecState is required here.
1048
1049         * Api/qwebframe.cpp:
1050         (QWebFrame::addToJavaScriptWindowObject):
1051
1052 2008-05-01  Marc Ordinas i Llopis  <marc.ordinasillopis@collabora.co.uk>
1053
1054         Reviewed by Alp Toker.
1055         Qt parts OK'ed by Simon Hausmann.
1056
1057         https://bugs.webkit.org/show_bug.cgi?id=14750
1058         Added support for NPAPI plugins on Gtk and Qt-x11 ports.
1059
1060         * WebCoreSupport/FrameLoaderClientQt.cpp:
1061         (WebCore::FrameLoaderClientQt::FrameLoaderClientQt):
1062         (WebCore::FrameLoaderClientQt::finishedLoading):
1063         (WebCore::FrameLoaderClientQt::setMainDocumentError):
1064         (WebCore::FrameLoaderClientQt::committedLoad):
1065         (WebCore::FrameLoaderClientQt::objectContentType):
1066         (WebCore::FrameLoaderClientQt::createPlugin):
1067         (WebCore::FrameLoaderClientQt::redirectDataToPlugin):
1068         * WebCoreSupport/FrameLoaderClientQt.h:
1069
1070 2008-04-30  Julien Chaffraix  <jchaffraix@webkit.org>
1071
1072         Qt 4.3 build fix.
1073
1074         Fixes a brace error that made Qt 4.4 build but not Qt 4.3.
1075  
1076         * Api/qwebview.cpp:
1077         (QWebView::event):
1078
1079 2008-04-30  Tor Arne Vestbø  <tavestbo@trolltech.com>
1080
1081         Reviewed by Simon.
1082
1083         In focusIn and focusOut event always update the active state of the
1084         focus controller. Fixes ~400 failing layout tests due to missing
1085         editing callbacks that relied on the correct focus.
1086
1087         * Api/qwebpage.cpp:
1088         (QWebPagePrivate::focusInEvent):
1089         (QWebPagePrivate::focusOutEvent):
1090
1091 2008-04-29  Lincoln Ramsay  <lincoln.ramsay@trolltech.com>
1092
1093         Reviewed by Simon.
1094
1095         Fix compilation with QT_NO_PRINTER
1096         
1097
1098         * Api/qwebview.cpp:
1099         (QWebView::print):
1100
1101 2008-04-29  Ariya Hidayat  <ariya.hidayat@trolltech.com>
1102
1103         Reviewed by Simon.
1104
1105         Ensure that relative URL is converted to absolute URL.
1106         
1107         This is necessary because loading a relative URL is not really supported
1108         (the web page may load, but the subsequent URLs for images and links will
1109         not be resolved properly).
1110         This also fixes https://bugs.webkit.org/show_bug.cgi?id=18484
1111         
1112
1113         * Api/qwebframe.cpp:
1114         (ensureAbsoluteUrl):
1115         (QWebFrame::setUrl):
1116         (QWebFrame::load):
1117
1118 2008-04-29  Ariya Hidayat  <ariya.hidayat@trolltech.com>
1119
1120         Reviewed by Simon.
1121
1122         Simplification of Qt Launcher (no animation and use standard progress bar widget)
1123         
1124         Status bar shows the hovered link without any animation. Progress bar just uses the standard QProgressBar (no custom widget). The launcher is leaner and faster to use under the debugger and/or valgrind.
1125         
1126
1127         * QtLauncher/main.cpp:
1128         (MainWindow::MainWindow):
1129
1130 2008-04-29  Ariya Hidayat  <ariya.hidayat@trolltech.com>
1131
1132         Reviewed by Simon.
1133
1134         Update the cursor when the frame/page loading is finished.
1135         
1136         This fixes https://bugs.webkit.org/show_bug.cgi?id=18712
1137         
1138
1139         * WebCoreSupport/FrameLoaderClientQt.cpp:
1140         (WebCore::FrameLoaderClientQt::postProgressFinishedNotification):
1141         (WebCore::FrameLoaderClientQt::setMainFrameDocumentReady):
1142
1143 2008-04-29  Simon Hausmann  <shausman@trolltech.com>
1144
1145         Reviewed by Holger.
1146
1147         Fixes: QWebPage::acceptNavigationRequest not being called / linkClicked() not being emitted when clicking on <a href="..." target="_blank"> kind of links.
1148         
1149         Call QWebPage::acceptNavigationRequest when the creation of a new window with
1150         URL is requested. The frame pointer is set to null in this case.
1151         
1152
1153         * Api/qwebpage.cpp:
1154         (QWebPage::setViewportSize):
1155         * WebCoreSupport/FrameLoaderClientQt.cpp:
1156         (WebCore::FrameLoaderClientQt::startDownload):
1157         (WebCore::FrameLoaderClientQt::createFrame):
1158
1159 2008-04-29  Holger Hans Peter Freyther  <zecke@selfish.org>
1160
1161         Reviewed by Simon.
1162
1163         Use the WebCore facility to do the scrolling. Move some code around.
1164
1165         * Api/qwebpage.cpp:
1166         (QWebPagePrivate::keyPressEvent):
1167         (QWebPagePrivate::shortcutOverrideEvent):
1168         (QWebPagePrivate::handleScrolling):
1169         * Api/qwebpage_p.h:
1170
1171 2008-04-29  Ariya Hidayat  <ariya.hidayat@trolltech.com>
1172
1173         Reviewed by Simon.
1174
1175         fix potential crash when loading image(s)
1176
1177         Crash may occur. If compiled with 4.3, the variable is not initialized.
1178
1179         * Api/qwebpage.cpp:
1180         (QWebPagePrivate::QWebPagePrivate):
1181
1182 2008-04-29  Holger Hans Peter Freyther  <zecke@selfish.org>
1183
1184         Reviewed by Simon.
1185
1186         Calling QWebView::setCursor will override the WebCore Cursor.
1187         Calling QWebView::setCursor will override the WebCore Cursor using
1188         QWidget::unsetCursor will revert to the WebCore Cursor.
1189
1190         For detecting the unset we have to compare the shape of the
1191         cursor to the default arrow. Qt::WA_SetCursor can not be used
1192         as it is set unconditionally but conditionally removed.
1193
1194         Calling QWidget::setCursor will immediately send the CursorChange
1195         event. We listen to this event to decide if we currently use a
1196         WebCore cursor, got a cursor from outside, or revert to the default.
1197
1198         This should be race free and work reliable, the manual test for this
1199         is WebCore/manual-tests/cursor.html
1200
1201         * Api/qwebpage.cpp:
1202         (SetCursorEvent::SetCursorEvent):
1203         * Api/qwebpage_p.h:
1204         * Api/qwebview.cpp:
1205         (QWebViewPrivate::QWebViewPrivate):
1206         (QWebViewPrivate::setCursor):
1207         (QWebView::QWebView):
1208         (QWebView::event):
1209
1210 2008-04-29  Kavindra Devi Palaraja  <kdpalara@trolltech.com>
1211
1212         Reviewed by Simon.
1213
1214         Documentation fixes:
1215
1216         - Fixed a qdoc warning
1217         - Mention that fav icons can be of arbitrary size
1218         - Fix signature of QWebPage::acceptNavigationRequest show in the documentation
1219
1220         * Api/qwebframe.cpp:
1221         * Api/qwebpage.cpp:
1222         * Api/qwebpage.h:
1223         * Api/qwebsettings.cpp:
1224         * Api/qwebview.cpp:
1225
1226 2008-04-28  Tor Arne Vestbø  <tavestbo@trolltech.com>
1227
1228         Reviewed by Simon.
1229
1230         Fix QWebView::loadFinished isn't always emitted
1231
1232         Replaced loadDone() with loadFinished(bool) and moved the signals for progress
1233         tracking (start, progres, and finish) to the page instead of the frame. This
1234         ensures that we emit loadFinished even when a subframe started the actual load.
1235
1236         This causes a few regressions in the layout tests that we for now accept for
1237         the sake of the correct API. Layout tests we can fix any time though, including
1238         patch release, the API however we can't change anymore in patch releases.
1239
1240         * Api/qwebframe.cpp:
1241         * Api/qwebframe.h:
1242         * Api/qwebpage.cpp:
1243         (QWebPage::totalBytes):
1244         * Api/qwebpage.h:
1245         * Api/qwebview.cpp:
1246         (QWebView::setPage):
1247         * Api/qwebview.h:
1248         * QtLauncher/main.cpp:
1249         (MainWindow::MainWindow):
1250         * WebCoreSupport/FrameLoaderClientQt.cpp:
1251         (drtDescriptionSuitableForTestResult):
1252         (WebCore::FrameLoaderClientQt::FrameLoaderClientQt):
1253         (WebCore::FrameLoaderClientQt::setFrame):
1254         (WebCore::FrameLoaderClientQt::transitionToCommittedFromCachedPage):
1255         (WebCore::FrameLoaderClientQt::transitionToCommittedForNewPage):
1256         (WebCore::FrameLoaderClientQt::willChangeTitle):
1257         (WebCore::FrameLoaderClientQt::createDocumentLoader):
1258         (WebCore::FrameLoaderClientQt::download):
1259         (WebCore::FrameLoaderClientQt::dispatchDecidePolicyForNavigationAction):
1260         * WebCoreSupport/FrameLoaderClientQt.h:
1261
1262 2008-04-28  Kavindra Devi Palaraja  <kdpalara@trolltech.com>
1263
1264         Reviewed by Simon.
1265
1266         Added more documentation for QWebSettings, QWebPluginFactory and QWebFrame
1267
1268         * Api/qwebframe.cpp:
1269         * Api/qwebpluginfactory.cpp:
1270         * Api/qwebsettings.cpp:
1271         (QWebSettings::QWebSettings):
1272         (QWebSettings::setUserStyleSheetUrl):
1273         (QWebSettings::iconForUrl):
1274         (QWebSettings::webGraphic):
1275         (QWebSettings::maximumPagesInCache):
1276         (QWebSettings::setFontFamily):
1277         (QWebSettings::resetFontFamily):
1278         (QWebSettings::testAttribute):
1279         (QWebSettings::resetAttribute):
1280
1281 2008-04-28  Ariya Hidayat  <ahidayat@trolltech.com>
1282
1283         Reviewed by Simon.
1284
1285         Fix document/frame title not reset when loading a new URI
1286         
1287         We should assume first the frame has no title. If it has, then the dispatchDidReceiveTitle()
1288         will be called very soon with the correct title.
1289         This properly resets the title when we navigate to a URI without a title.
1290         
1291
1292         * WebCoreSupport/FrameLoaderClientQt.cpp:
1293
1294 2008-04-28  David Boddie  <dboddie@trolltech.com>
1295
1296         Reviewed by Simon.
1297
1298         Minor documentation changes.
1299
1300         * Api/qwebview.cpp:
1301
1302 2008-04-28  Tor Arne Vestbø  <tavestbo@trolltech.com>
1303
1304         Reviewed by Simon.
1305
1306         Prevent middle-click from triggering open URL from clipboard when the event has already been accepted.
1307         
1308
1309         * Api/qwebpage.cpp:
1310         (QWebPagePrivate::mouseMoveEvent):
1311         (QWebPagePrivate::mousePressEvent):
1312         (QWebPagePrivate::mouseDoubleClickEvent):
1313         (QWebPagePrivate::mouseTripleClickEvent):
1314         (QWebPagePrivate::mouseReleaseEvent):
1315
1316 2008-04-28  Tor Arne Vestbø  <tavestbo@trolltech.com>
1317
1318         Reviewed by Simon.
1319
1320         Fix scrollbar behavior in QtWebKit to match QScrollBar.
1321         
1322         Right click context menu is now supported, along with
1323         middle click to center slider thumb over mouse cursor.
1324         
1325
1326         * Api/qwebpage.cpp:
1327         (QWebPage::linkDelegationPolicy):
1328
1329 2008-04-28  Tor Arne Vestbø  <tavestbo@trolltech.com>
1330
1331         Reviewed by Simon.
1332
1333         Implemented channel-based logging for QtWebKit.
1334
1335         Comma-separated log channels are read from the QT_WEBKIT_LOG environment variable.
1336         Warnings for notImplemented() is still output by default, but can be disabled
1337         by setting DISABLE_NI_WARNINGS=1.
1338
1339         * Api/qwebpage.cpp:
1340         (QWebPagePrivate::QWebPagePrivate):
1341
1342 2008-04-28  Simon Hausmann  <shausman@trolltech.com>
1343
1344         Rubber-stamped by Lars
1345
1346         Removed setHtml(const QByteArray &) overload as it breaks the common use of the setHtml() API.
1347
1348         * Api/qwebframe.cpp:
1349         * Api/qwebframe.h:
1350         * Api/qwebview.cpp:
1351         * Api/qwebview.h:
1352
1353 2008-04-28  Kavindra Devi Palaraja  <kdpalara@trolltech.com>
1354
1355         Reviewed by Simon.
1356
1357         Doc - adding more documentation to QWebFrame, QWebPage and QWebView
1358         
1359
1360         * Api/qwebframe.cpp:
1361         * Api/qwebpage.cpp:
1362         * Api/qwebview.cpp:
1363         (QWebView::stop):
1364         (QWebView::back):
1365         (QWebView::changeEvent):
1366
1367 2008-04-28  Simon Hausmann  <shausman@trolltech.com>
1368
1369         Reviewed by Holger.
1370
1371         Fixes: Popups/Context menu in WebKit appearing at the wrong location when embedded in the graphics view or using multiple screens
1372         
1373         Give the popups the right parent widget and the right coordinates relative within the parent.
1374         
1375
1376         * Api/qwebpage.cpp:
1377
1378 2008-04-28  Benjamin Meyer  <bmeyer@trolltech.com>
1379
1380         Reviewed by Simon.
1381
1382         Doc: Add see also's (and a few minor whitespace/typo corrections)
1383         
1384
1385         * Api/qwebframe.cpp:
1386         (QWebFrame::~QWebFrame):
1387         (QWebFrame::setHtml):
1388         (QWebFrame::setContent):
1389         (QWebFrame::parentFrame):
1390         (QWebFrame::childFrames):
1391         (QWebFrame::setScrollBarValue):
1392         (QWebFrame::scrollBarValue):
1393         (QWebFrame::scrollBarMaximum):
1394         (QWebFrame::scrollBarMinimum):
1395         (QWebFrame::render):
1396         (QWebFrame::pos):
1397         (QWebFrame::geometry):
1398         (QWebFrame::print):
1399         (QWebFrame::evaluateJavaScript):
1400         * Api/qwebpage.cpp:
1401         (QWebPagePrivate::mousePressEvent):
1402         (QWebPagePrivate::mouseDoubleClickEvent):
1403         (QWebPage::~QWebPage):
1404         (QWebPage::javaScriptPrompt):
1405         (openNewWindow):
1406         (QWebPage::setViewportSize):
1407         (QWebPage::acceptNavigationRequest):
1408         (QWebPage::action):
1409         (QWebPage::userAgentForUrl):
1410         (QWebPagePrivate::_q_onLoadProgressChanged):
1411         * Api/qwebview.cpp:
1412         (QWebView::event):
1413
1414 2008-04-28  Kavindra Devi Palaraja  <kdpalara@trolltech.com>
1415
1416         Reviewed by Simon.
1417
1418         Submitting more documentation for QWebPage
1419         
1420
1421         * Api/qwebpage.cpp:
1422
1423 2008-04-28  Lincoln Ramsay  <lincoln.ramsay@trolltech.com>
1424
1425         Reviewed by Simon.
1426
1427         Compile when QT_NO_CLIPBOARD is defined.
1428         
1429
1430         * Api/qwebpage.cpp:
1431         (QWebPage::triggerAction):
1432
1433 2008-04-28  David Boddie  <dboddie@trolltech.com>
1434
1435         Reviewed by Simon.
1436
1437         Minor documentation fix.
1438         
1439
1440         * Api/qwebhistory.cpp:
1441
1442 2008-04-28  Holger Hans Peter Freyther  <zecke@selfish.org>
1443
1444         Reviewed by Simon.
1445
1446         Implement QWebPage::createPlugin
1447         
1448         The code is coming from the demo browser and needed here
1449         for some manual tests.
1450         
1451
1452         * QtLauncher/QtLauncher.pro:
1453         * QtLauncher/main.cpp:
1454         (WebPage::createPlugin):
1455
1456 2008-04-28  Simon Hausmann  <hausmann@webkit.org>
1457
1458         Qt/Win build fix. Include config.h to get the implicit MathExtras.h
1459         inclusion correct with regards to rand_s.
1460
1461         * Api/qwebhistory.cpp:
1462
1463 2008-04-28  Tor Arne Vestbø  <tavestbo@trolltech.com>
1464
1465         Reviewed by Simon.
1466
1467         https://bugs.webkit.org/show_bug.cgi?id=18713
1468
1469         Fix scrollbar painting issues in QtWebKit.
1470
1471         Hovering and click-draging outside of the scrollbar would
1472         produce unexpected and inconcistent results. We also didn't
1473         pass on leave-events to the underlying WebKit code, which
1474         was nessecary to implement the paint fix.
1475
1476         Note: The event handling of the Leave event should be moved
1477         out of QWebView::event() and into a proper override for 4.5.
1478
1479         * Api/qwebpage.cpp:
1480         (QWebPagePrivate::leaveEvent):
1481         * Api/qwebpage_p.h:
1482         * Api/qwebview.cpp:
1483         (QWebView::event):
1484
1485 2008-04-25  Benjamin Meyer  <bmeyer@trolltech.com>
1486
1487         Reviewed by Simon, Holger.
1488
1489         Fixed focus handling when a node is focused while the corresponding QWebPage does not have the focus.
1490
1491         * Correctly de- and reactivate the focused frame in focusOut/focusInEvent
1492         without telling the focus controller. We don't want to change the focused frame
1493         - the controller has to remember it in fact - but instead just deactivate the
1494         frame for correct painting as RenderTheme::isFocused() uses the activation
1495         state of the frame.
1496
1497         * Api/qwebpage.cpp:
1498         (QWebPagePrivate::focusInEvent):
1499         (QWebPagePrivate::focusOutEvent):
1500
1501 2008-04-25  Kavindra Devi Palaraja  <kdpalara@trolltech.com>
1502
1503         Reviewed by Simon.
1504
1505         completed documentation for the Detailed Description section for QWebView
1506         
1507
1508         * Api/qwebview.cpp:
1509
1510 2008-04-25  Denis Dzyubenko  <denis.dzyubenko@trolltech.com>
1511
1512         Reviewed by Simon.
1513
1514         Fixed the way QWebHistory works - when you call back(), forward() or goToItem() functions it changes the current item in history *and* loads the corresponding page.
1515         
1516
1517         * Api/qwebhistory.cpp:
1518         (QWebHistory::back):
1519         (QWebHistory::forward):
1520         (QWebHistory::goToItem):
1521
1522 2008-04-25  Tor Arne Vestbø  <tavestbo@trolltech.com>
1523
1524         Reviewed by Simon.
1525
1526         Fix resubmit of HTML forms when initially denied by QWebPage::acceptNavigationRequest().
1527         
1528
1529         * WebCoreSupport/FrameLoaderClientQt.cpp:
1530         (WebCore::FrameLoaderClientQt::createFrame):
1531
1532 2008-04-25  Simon Hausmann  <hausmann@webkit.org>
1533
1534         Reviewed by Holger.
1535
1536         When pressing backspace in a line edit in a webpage we should not go back to the previous page.
1537         
1538         The shortcut for back on Windows is backspace. Implemented shortcut override
1539         handling in QWebView/QWebPage to prevent this.
1540         
1541
1542         * Api/qwebpage.cpp:
1543         (QWebPagePrivate::wheelEvent):
1544         (editorActionForKeyEvent):
1545         (QWebPagePrivate::keyPressEvent):
1546         (QWebPagePrivate::inputMethodEvent):
1547         (QWebPagePrivate::shortcutOverrideEvent):
1548         (QWebPage::event):
1549         * Api/qwebpage_p.h:
1550         * Api/qwebview.cpp:
1551         (QWebView::event):
1552
1553 2008-04-25  Ariya Hidayat  <ariya.hidayat@trolltech.com>
1554
1555         Reviewed by Simon.
1556
1557         Fix triple-clicking does not work in a web page
1558         
1559
1560         * Api/qwebpage.cpp:
1561         (QWebPagePrivate::updateEditorActions):
1562         (QWebPagePrivate::timerEvent):
1563         (QWebPagePrivate::mousePressEvent):
1564         (QWebPagePrivate::mouseDoubleClickEvent):
1565         (QWebPage::undoStack):
1566         * Api/qwebpage_p.h:
1567
1568 2008-04-25  Benjamin Meyer  <bmeyer@trolltech.com>
1569
1570         Reviewed by Simon.
1571
1572         When pressing Ctrl-Up the keyboard modifiers could include other modifiers
1573         
1574
1575         * Api/qwebpage.cpp:
1576         (QWebPagePrivate::keyPressEvent):
1577
1578 2008-04-25  Tor Arne Vestbø  <tavestbo@trolltech.com>
1579
1580         Reviewed by Simon.
1581
1582         Fix handling of Javascript's confirm() function in QtWebKit.
1583         
1584
1585         * Api/qwebpage.cpp:
1586
1587 2008-04-25  Kavindra Devi Palaraja  <kdpalara@trolltech.com>
1588
1589         Reviewed by Simon.
1590
1591         Doc - added a screenshot, flowchart, and a snippet to the QWebView documentation to improve clarity
1592         
1593
1594         * Api/qwebview.cpp:
1595
1596 2008-04-25  Benjamin Meyer  <bmeyer@trolltech.com>
1597
1598         Reviewed by Simon.
1599
1600         QWebPage: missing signal when window.print() is requested from javascript
1601         
1602
1603         * Api/qwebpage.cpp:
1604         * Api/qwebpage.h:
1605         * WebCoreSupport/ChromeClientQt.cpp:
1606
1607 2008-04-25  Benjamin Meyer  <bmeyer@trolltech.com>
1608
1609         Reviewed by Simon.
1610
1611         Fixes: "Save Image" action wasn't doing anything.
1612         
1613
1614         * Api/qwebpage.cpp:
1615         (QWebPage::triggerAction):
1616
1617 2008-04-25  Benjamin Meyer  <bmeyer@trolltech.com>
1618
1619         Reviewed by Simon.
1620
1621         Apply key event changes to the current frame, not the main frame.
1622         
1623         Example: hitting space bar should scroll current frame, not the main frame
1624         which doesn't even have a scrollbar.
1625         
1626
1627         * Api/qwebpage.cpp:
1628         (QWebPagePrivate::keyPressEvent):
1629
1630 2008-04-25  Benjamin Meyer  <bmeyer@trolltech.com>
1631
1632         Reviewed by Simon.
1633
1634         Fixes: QWebFrame crash when fetching the icon
1635
1636         Just call QWebSettings::iconForUrl to not duplicate code and obey the mutex lock.
1637
1638         * Api/qwebframe.cpp:
1639
1640 2008-04-25  Warwick Allison  <warwick@trolltech.com>
1641
1642         Reviewed by Simon.
1643
1644         Fixes: Scrollbars did not report correct maximum.
1645
1646         * Api/qwebframe.cpp:
1647
1648 2008-04-25  David Boddie <dboddie@trolltech.com>
1649
1650         Reviewed by Simon.
1651
1652         Documentation updates for some of the QWeb classes
1653
1654         * Api/qwebframe.cpp:
1655         * Api/qwebhistory.cpp:
1656         * Api/qwebsettings.cpp:
1657         * Api/qwebview.cpp:
1658
1659 2008-04-25  Holger Hans Peter Freyther  <zecke@selfish.org>
1660
1661         Reviewed by Simon.
1662
1663         Implement dumping of resource load callbacks to pass http/tests/xmlhttprequest/abort-should-cancel-load.html
1664         
1665         Similar to Editing and Frameloading we do the dumping within WebCore
1666         
1667
1668         * WebCoreSupport/FrameLoaderClientQt.cpp:
1669         (qt_dump_frame_loader):
1670         (qt_dump_resource_load_callbacks):
1671         (drtDescriptionSuitableForTestResult):
1672         (WebCore::FrameLoaderClientQt::dispatchDidFailLoading):
1673         (WebCore::FrameLoaderClientQt::dispatchDidLoadResourceFromMemoryCache):
1674         (WebCore::FrameLoaderClientQt::dispatchDecidePolicyForMIMEType):
1675
1676 2008-04-24  Anders Carlsson  <andersca@apple.com>
1677
1678         Reviewed by Sam.
1679
1680         Change some String arguments to be const references instead.
1681
1682         * WebCoreSupport/EditorClientQt.cpp:
1683         (WebCore::EditorClientQt::shouldInsertText):
1684         * WebCoreSupport/EditorClientQt.h:
1685
1686 2008-04-24  Holger Hans Peter Freyther  <zecke@selfish.org>
1687
1688         Reviewed by Simon.
1689
1690         Cosmetic changes to make the code more readable.
1691         -Early exit if we don't have a webview
1692         -handle the empty tooltip and non-empty tooltip case separately
1693         
1694
1695         * WebCoreSupport/ChromeClientQt.cpp:
1696         (WebCore::ChromeClientQt::setToolTip):
1697         (WebCore::ChromeClientQt::print):
1698
1699 2008-04-24  Paul Olav Tvete  <paul@trolltech.com>
1700
1701         Reviewed by Simon.
1702
1703         Automatically wrap tooltip text and hide a shown tooltip when it is empty.
1704
1705         QWidget::setTooltip("") will still show the old tooltip for up to 10 seconds.
1706         Workaround as discussed with Matthias.
1707
1708         * WebCoreSupport/ChromeClientQt.cpp:
1709         (WebCore::ChromeClientQt::setToolTip):
1710
1711 2008-04-24  Holger Hans Peter Freyther  <zecke@selfish.org>
1712
1713         Reviewed by Simon.
1714
1715         Allow to disable caching completeley by calling setObjectCacheCapacities(0, 0, 0)
1716
1717         * Api/qwebsettings.cpp:
1718         (QWebSettings::setObjectCacheCapacities):
1719
1720 2008-04-24  Benjamin Meyer  <bmeyer@trolltech.com>
1721
1722         Reviewed by Simon.
1723
1724         Improve keyboard scrolling
1725         
1726         Match Down/Up keys scroll distance with Safari (i.e. faster) and add Home and End shortcuts to scroll to the top/botom.
1727         
1728
1729         * Api/qwebpage.cpp:
1730         (QWebPagePrivate::keyPressEvent):
1731
1732 2008-04-24  Olivier Goffart  <ogoffart@trolltech.com>
1733
1734         Reviewed by Simon.
1735
1736         Fix various compiler warnings in the Qt port.
1737
1738         * Api/qwebframe.cpp:
1739         (QWebFrame::print):
1740         * Api/qwebsettings.cpp:
1741         (graphics):
1742         * WebCoreSupport/FrameLoaderClientQt.cpp:
1743         (WebCore::FrameLoaderClientQt::createPlugin):
1744
1745 2008-04-24  Tor Arne Vestbø  <tavestbo@trolltech.com>
1746
1747         Reviewed by Simon.
1748
1749         Cleaned up copyright headers (removed misplaced class descriptions and
1750         fixed inconsistent whitespace and indentation).
1751
1752         * Api/qwebframe.cpp:
1753         * Api/qwebframe.h:
1754         * Api/qwebframe_p.h:
1755         * Api/qwebhistory.cpp:
1756         * Api/qwebhistory.h:
1757         * Api/qwebhistory_p.h:
1758         * Api/qwebhistoryinterface.cpp:
1759         * Api/qwebhistoryinterface.h:
1760         * Api/qwebkitglobal.h:
1761         * Api/qwebnetworkinterface.cpp:
1762         * Api/qwebnetworkinterface.h:
1763         * Api/qwebnetworkinterface_p.h:
1764         * Api/qwebpage.cpp:
1765         * Api/qwebpage.h:
1766         * Api/qwebpage_p.h:
1767         * Api/qwebpluginfactory.cpp:
1768         * Api/qwebpluginfactory.h:
1769         * Api/qwebsettings.cpp:
1770         * Api/qwebsettings.h:
1771         * Api/qwebview.h:
1772         * QtLauncher/main.cpp:
1773
1774 2008-04-24  Tor Arne Vestbø  <tavestbo@trolltech.com>
1775
1776         Reviewed by Simon.
1777
1778         Added basic URL guessing to QtLauncher (same as in the demo browser).
1779         
1780
1781         * QtLauncher/main.cpp:
1782         (MainWindow::changeLocation):
1783         (MainWindow::guessUrlFromString):
1784
1785 2008-04-24  Benjamin Meyer  <bmeyer@trolltech.com>
1786
1787         Reviewed by Simon Hausmann <hausmann@webkit.org>.
1788
1789         Prevent double deletions of the default web interface.
1790         
1791
1792         * Api/qwebhistoryinterface.cpp:
1793         (gCleanupInterface):
1794         (QWebHistoryInterface::QWebHistoryInterface):
1795
1796 2008-04-23  Simon Hausmann  <hausmann@webkit.org>
1797
1798         Fix compilation against Qt 4.3
1799
1800         * Api/qwebpage.cpp:
1801         (QWebPage::userAgentForUrl):
1802         * QtLauncher/main.cpp:
1803         (main):
1804
1805 2008-04-23  Holger Hans Peter Freyther  <zecke@selfish.org>
1806
1807         Reviewed by Simon.
1808
1809         * Make sure the "Inspect Element" item gets added to the ContextMenu, a call
1810         to ContextMenu::populate() is not adding it, the ContextMenuController does
1811         add it after the call to populate(). Do that as well.
1812         
1813
1814         * Api/qwebpage.cpp:
1815         (QWebPage::updatePositionDependentActions):
1816
1817 2008-04-23  Simon Hausmann  <hausmann@webkit.org>
1818
1819         Reviewed by Holger.
1820
1821         Fix crashes on window.close().
1822
1823         We should not delete the QWebPage object in the ChromeClient but leave it up to
1824         the application when and whether to delete a browser window. For this we now
1825         emit the windowCloseRequested() signal.
1826
1827         Done with Tor Arne.
1828
1829         * Api/qwebpage.cpp:
1830         * Api/qwebpage.h:
1831         * QtLauncher/main.cpp:
1832         (MainWindow::MainWindow):
1833         * WebCoreSupport/ChromeClientQt.cpp:
1834
1835 2008-04-23  Simon Hausmann  <hausmann@webkit.org>
1836
1837         Reviewed by Holger.
1838
1839         Fix parsing of external scripts/stylesheets when using setHtml(const QString &html).
1840
1841         We used to pass the html string to the frameloader in utf-16, which also meant that the default
1842         encoding of external scripts/stylesheets became utf-16. That doesn't make sense, so assume utf-8
1843         by default. This is now also documented.
1844
1845         * Api/qwebframe.cpp:
1846         (QWebFrame::setHtml):
1847         * Api/qwebview.cpp:
1848
1849 2008-04-23  Benjamin Meyer  <bmeyer@trolltech.com>
1850
1851         Reviewed by Simon.
1852
1853         Fixes background color propagation when using a custom QWebPage
1854         
1855         Set the palette in setPage(), not during the creation on-demand.
1856         
1857
1858         * Api/qwebview.cpp:
1859         (QWebView::page):
1860         (QWebView::setPage):
1861
1862 2008-04-23  Benjamin Meyer  <bmeyer@trolltech.com>
1863
1864         Reviewed by Simon.
1865
1866         Fix the user agent on the mac to be BSD4
1867         
1868         Put Q_OS_DARWIN before Q_OS_BSD4 sense they are both defined on the mac
1869         
1870
1871         * Api/qwebpage.cpp:
1872         (QWebPage::userAgentForUrl):
1873
1874 2008-04-23  Simon Hausmann  <shausman@trolltech.com>
1875
1876         Reviewed by Holger.
1877
1878         Added missing copyright notice.
1879         Small fixes to the documentation.
1880
1881         * Api/qwebpluginfactory.cpp:
1882
1883 2008-04-23  Zack Rusin  <zack@tungstengraphics.com>
1884
1885         Reviewed by Simon.
1886
1887         Added a contentsSize() property.
1888
1889         * Api/qwebframe.cpp:
1890         (QWebFrame::contentsSize):
1891         (QWebFrame::hitTestContent):
1892         * Api/qwebframe.h:
1893
1894 2008-04-22  Benjamin Meyer  <bmeyer@trolltech.com>
1895
1896         Reviewed by Simon.
1897
1898         Fixes: QWebPage's QNetworkManager's can be shared among webpages.
1899
1900         Don't force the deletion of the object, but let QObject take care of it.
1901
1902         * Api/qwebpage.cpp:
1903
1904 2008-04-22  Simon Hausmann  <hausmann@webkit.org>
1905
1906         Reviewed by Holger.
1907
1908         Documentation for QWebPluginFactory and documentation updates for QWebPage.
1909
1910         * Api/qwebpage.cpp:
1911         (QWebPage::setLinkDelegationPolicy):
1912         (QWebPage::linkDelegationPolicy):
1913         (QWebPage::swallowContextMenuEvent):
1914         (QWebPage::updatePositionDependentActions):
1915         (QWebPage::extension):
1916         (QWebPage::networkAccessManager):
1917         * Api/qwebpluginfactory.cpp:
1918         (QWebPluginFactory::QWebPluginFactory):
1919         (QWebPluginFactory::~QWebPluginFactory):
1920         (QWebPluginFactory::refreshPlugins):
1921
1922 2008-04-22  Simon Hausmann  <hausmann@webkit.org>
1923
1924         Reviewed by Holger.
1925
1926         Added QWebPage::swallowContextMenuEvent and QWebPage::updatePositionDependentActions.
1927         
1928
1929         * Api/qwebpage.cpp:
1930         (QWebPagePrivate::QWebPagePrivate):
1931         (QWebPagePrivate::mouseReleaseEvent):
1932         (QWebPage::setLinkDelegationPolicy):
1933         (QWebPage::linkDelegationPolicy):
1934         (QWebPage::swallowContextMenuEvent):
1935         (QWebPage::updatePositionDependentActions):
1936         * Api/qwebpage.h:
1937         * Api/qwebpage_p.h:
1938         * Api/qwebview.cpp:
1939         (QWebView::event):
1940
1941 2008-04-22  Simon Hausmann  <hausmann@webkit.org>
1942
1943         Reviewed by Holger.
1944
1945         Added Extension APIs for QWebPage.
1946
1947         * Api/qwebpage.cpp:
1948         (QWebPage::setLinkDelegationPolicy):
1949         (QWebPage::linkDelegationPolicy):
1950         (QWebPage::extension):
1951         * Api/qwebpage.h:
1952         * Api/qwebpluginfactory.cpp:
1953         (QWebPluginFactory::extension):
1954
1955 2008-04-22  Tor Arne Vestbø  <tavestbo@trolltech.com>
1956
1957         Reviewed by Simon.
1958
1959         Emit loadProgress() signal on loadStarted().
1960         
1961
1962         * WebCoreSupport/FrameLoaderClientQt.cpp:
1963         (WebCore::FrameLoaderClientQt::postProgressEstimateChangedNotification):
1964
1965 2008-04-22  Zack Rusin  <zack@kde.org>
1966
1967         Reviewed by Simon.
1968
1969         Fix background propagation from the QWebView's palette.
1970
1971         The background brush of the palette needs to be propagated to the WebCore::FrameView.
1972
1973         * Api/qwebframe.cpp:
1974         (QWebFramePrivate::updateBackground):
1975         * Api/qwebframe_p.h:
1976         * Api/qwebpage.cpp:
1977         (QWebPagePrivate::dropEvent):
1978         (QWebPage::setPalette):
1979         * Api/qwebpage.h:
1980         * Api/qwebpage_p.h:
1981         * Api/qwebview.cpp:
1982         (QWebView::page):
1983         (QWebView::changeEvent):
1984         * Api/qwebview.h:
1985         * WebCoreSupport/FrameLoaderClientQt.cpp:
1986
1987 2008-04-22  Benjamin Meyer  <bmeyer@trolltech.com>
1988
1989         Reviewed by Simon.
1990
1991         Fix maps.google.com
1992
1993         We have to include a version in the Safari tag in the user-agent.
1994
1995         * Api/qwebpage.cpp:
1996         (QWebPage::userAgentForUrl):
1997
1998 2008-04-22  Tor Arne Vestbø  <tavestbo@trolltech.com>
1999
2000         Reviewed by Simon.
2001
2002         Add visual focusing hint for clear button and
2003         change focus to web page after user enters new URL.
2004
2005         * QtLauncher/main.cpp:
2006         (ClearButton::paintEvent):
2007         (MainWindow::changeLocation):
2008
2009 2008-04-22  Simon Hausmann  <hausmann@webkit.org>
2010
2011         Reviewed by Holger.
2012
2013         Added QWebFrame::hitTestContent() and QWebHitTestResult.
2014
2015         * Api/qwebframe.cpp:
2016         (QWebFrame::hitTestContent):
2017         (QWebFrame::event):
2018         (QWebHitTestResult::QWebHitTestResult):
2019         (QWebHitTestResultPrivate::QWebHitTestResultPrivate):
2020         (QWebHitTestResult::operator=):
2021         (QWebHitTestResult::~QWebHitTestResult):
2022         (QWebHitTestResult::isNull):
2023         (QWebHitTestResult::pos):
2024         (QWebHitTestResult::title):
2025         (QWebHitTestResult::linkText):
2026         (QWebHitTestResult::linkUrl):
2027         (QWebHitTestResult::linkTitle):
2028         (QWebHitTestResult::linkTargetFrame):
2029         (QWebHitTestResult::alternateText):
2030         (QWebHitTestResult::imageUrl):
2031         (QWebHitTestResult::pixmap):
2032         (QWebHitTestResult::isContentEditable):
2033         (QWebHitTestResult::isContentSelected):
2034         (QWebHitTestResult::frame):
2035         * Api/qwebframe.h:
2036         * Api/qwebframe_p.h:
2037         (QWebHitTestResultPrivate::QWebHitTestResultPrivate):
2038         * Api/qwebpage.cpp:
2039         (QWebPagePrivate::contextMenuEvent):
2040         (QWebPage::triggerAction):
2041         * Api/qwebpage.h:
2042         * Api/qwebpage_p.h:
2043
2044 2008-04-22  Simon Hausmann  <hausmann@webkit.org>
2045
2046         Reviewed by Holger.
2047
2048         Don't crash if an input method query is done without a page.
2049         
2050
2051         * Api/qwebview.cpp:
2052         (QWebView::inputMethodQuery):
2053
2054 2008-04-22  Simon Hausmann  <hausmann@webkit.org>
2055
2056         Reviewed by Holger.
2057
2058         Added re-implementations of QObject::event for future safety.
2059         
2060         This makes it easier to fix bugs with the event handling even in patch releases
2061         and is a general style we follow in Qt.
2062         
2063
2064         * Api/qwebframe.cpp:
2065         * Api/qwebframe.h:
2066         * Api/qwebview.cpp:
2067         (QWebView::event):
2068         * Api/qwebview.h:
2069
2070 2008-04-22  Benjamin Meyer  <bmeyer@trolltech.com>
2071
2072         Reviewed by Simon.
2073
2074         Fix construction of the user agent.
2075         
2076         The user-agent is now composed of
2077         * the platform and subplatform
2078         * the Qt version or application name and version (if set)
2079         * the locale
2080         * the SSL settings
2081         
2082
2083         * Api/qwebpage.cpp:
2084         (QWebPage::networkAccessManager):
2085         (QWebPage::setPluginFactory):
2086         (QWebPage::pluginFactory):
2087         (QWebPage::userAgentForUrl):
2088         * QtLauncher/main.cpp:
2089
2090 2008-04-22  Thiago Macieira  <tjmaciei@trolltech.com>
2091
2092         Reviewed by Simon.
2093
2094         Fixes: Pedantic compilation fix
2095
2096         Don't put semi-colons after braces closing namespaces.
2097
2098         * Api/qwebsettings.h:
2099
2100 2008-04-21  Simon Hausmann  <hausmann@webkit.org>
2101
2102         Reviewed by Lars.
2103
2104         Changed the return type of QWebFrame::evaluateJavaScript from a QString to a QVariant.
2105
2106         * Api/qwebframe.cpp:
2107         (QWebFrame::evaluateJavaScript):
2108         * Api/qwebframe.h:
2109
2110 2008-04-21  Simon Hausmann  <hausmann@webkit.org>
2111
2112         Reviewed by Holger.
2113
2114         Fixes redundant "Fonts" submenu in default lineedits that has only disabled items.
2115
2116         Don't show sub-menus that have only actions that are disabled.
2117
2118         * Api/qwebpage.cpp:
2119         (QWebPagePrivate::createContextMenu):
2120
2121 2008-04-21  Kavindra Devi Palaraja <kdpalara@trolltech.com>.
2122
2123         Reviewed by Simon.
2124
2125         Lots of documentation fixes, fixed all qdoc warnings.
2126
2127         * Api/qwebframe.cpp:
2128         (QWebFrame::setTextSizeMultiplier):
2129         * Api/qwebhistoryinterface.cpp:
2130         (gCleanupInterface):
2131         (QWebHistoryInterface::QWebHistoryInterface):
2132         (QWebHistoryInterface::~QWebHistoryInterface):
2133         * Api/qwebpage.cpp:
2134         (QWebPage::inputMethodQuery):
2135         (QWebPage::view):
2136         (QWebPage::javaScriptConsoleMessage):
2137         (QWebPage::javaScriptAlert):
2138         (QWebPage::javaScriptConfirm):
2139         (QWebPage::javaScriptPrompt):
2140         (QWebPage::viewportSize):
2141         (QWebPage::acceptNavigationRequest):
2142         (QWebPage::action):
2143         (QWebPage::event):
2144         (QWebPage::focusNextPrevChild):
2145         (QWebPage::setForwardUnsupportedContent):
2146         (QWebPage::setLinkDelegationPolicy):
2147         (QWebPage::findText):
2148         (QWebPage::settings):
2149         (QWebPage::networkProxy):
2150         (QWebPage::setNetworkAccessManager):
2151         * Api/qwebpage.h:
2152         * Api/qwebsettings.cpp:
2153         (QWebSettings::QWebSettings):
2154         (QWebSettings::setIconDatabasePath):
2155         (QWebSettings::iconForUrl):
2156         (QWebSettings::fontFamily):
2157         * Api/qwebview.cpp:
2158         (QWebView::load):
2159         * Api/qwebview.h:
2160
2161 2008-04-21  Marius Bugge Monsen  <mmonsen@trolltech.com>
2162
2163         Reviewed by Simon.
2164
2165         Fix compile failure on solaris-cc
2166
2167         * Api/qwebpage.h: Removed trailing semicolons and moved the private
2168         d-pointer to not confuse the compiler
2169
2170 2008-04-21  Holger Hans Peter Freyther  <holger.freyther@trolltech.com>
2171
2172         Reviewed by Simon.
2173
2174         Build fix for Qt 4.3
2175
2176         * When building WebCore/internal make sure the QT_[BEGIN,END]_NAMESPACE is
2177         always defined. Do this by adding defines to the compiler line
2178         * For users of our API this is not feasible. Every public header file should
2179         include qwebkitglobal.h. Define the QT_BEGIN_NAMESPACE and QT_END_NAMESPACE
2180         when we are building everything < 4.4.0 and don't have them defined.
2181
2182         * Api/qwebkitglobal.h:
2183
2184 2008-04-21  Holger Hans Peter Freyther  <holger.freyther@trolltech.com>
2185
2186         Reviewed by Simon.
2187
2188         * Initialize the WebGraphics with the one found in WebCore
2189         
2190
2191         * Api/qwebsettings.cpp:
2192         (QWebSettingsPrivate::apply):
2193
2194 2008-04-21  Holger Hans Peter Freyther  <holger.freyther@trolltech.com>
2195
2196         Reviewed by Simon.
2197
2198         * Allow TextAreas to be resized.
2199         * No QWebSettings for this is introduced.
2200         
2201
2202         * Api/qwebsettings.cpp:
2203         (QWebSettingsPrivate::apply):
2204
2205 2008-04-21  Simon Hausmann  <shausman@trolltech.com>
2206
2207         Reviewed by Holger.
2208
2209         Fixes: QWebView::url property behaviour strange in designer
2210
2211         Added QWebView/QWebFrame::setUrl, which unlike load() clears the view immediately, schedules a load of the url but also makes sure url() returns the set url. This setter is now also used for the url property.
2212
2213         * Api/qwebframe.cpp:
2214         (QWebFrame::setUrl):
2215         * Api/qwebframe.h:
2216         * Api/qwebview.cpp:
2217         (QWebView::setUrl):
2218         * Api/qwebview.h:
2219
2220 2008-04-21  Andre Poenitz  <andre.poenitz@trolltech.com>
2221
2222         Reviewed by Simon Hausmann <hausmann@webkit.org>.
2223
2224         Fix compilation with Qt namespaces
2225
2226         * Api/qwebframe.cpp:
2227         (QWebFrame::print):
2228         * Api/qwebview.h:
2229
2230 2008-04-21  Simon Hausmann  <hausmann@webkit.org>
2231
2232         Reviewed by Holger.
2233
2234         When printing on high resolution printers we need to scale the painter accordingly (for now).
2235
2236         * Api/qwebframe.cpp:
2237         (QWebFrame::print):
2238
2239 2008-04-21  Simon Hausmann  <hausmann@webkit.org>
2240
2241         Reviewed by Holger.
2242
2243         Provide a print preview in the QtLauncher
2244
2245         * QtLauncher/main.cpp:
2246         (MainWindow::MainWindow):
2247         (MainWindow::showLinkHover):
2248         (MainWindow::print):
2249
2250 2008-04-20  Simon Hausmann  <hausmann@webkit.org>
2251
2252         Reviewed by Alp Toker.
2253
2254         Share the printing code between the Gtk and the Qt port
2255         and added printing to the Qt WebKit API.
2256
2257         * Api/qwebframe.cpp:
2258         (QWebFrame::print):
2259         * Api/qwebframe.h:
2260         * Api/qwebview.cpp:
2261         (QWebView::print):
2262         * Api/qwebview.h:
2263
2264 2008-04-19  Julien Chaffraix  <jchaffraix@webkit.org>
2265
2266         Qt build fix (renderer() -> contentRenderer()).
2267
2268         * Api/qwebframe.cpp:
2269         (QWebFrame::renderTreeDump):
2270         (QWebFrame::render):
2271
2272 2008-04-18  Simon Hausmann  <hausmann@webkit.org>
2273
2274         Reviewed by Holger.
2275
2276         Many API changes and additions after a full review with Jasmin Blanchette <jasmin@trolltech.com>
2277
2278         The diff is too big to mention the changes individually, but most of the changes were of cosmetic
2279         nature where methods or enums have been renamed or prefixed/suffixed according to the consistency
2280         rules of the Qt API.
2281
2282         * Api/qwebframe.cpp:
2283         (QWebFrame::addToJavaScriptWindowObject):
2284         (QWebFrame::toHtml):
2285         (QWebFrame::toPlainText):
2286         (QWebFrame::icon):
2287         (QWebFrame::setContent):
2288         (QWebFrame::setScrollBarPolicy):
2289         (QWebFrame::render):
2290         (QWebFrame::setTextSizeMultiplier):
2291         (QWebFrame::textSizeMultiplier):
2292         (QWebFrame::pos):
2293         * Api/qwebframe.h:
2294         * Api/qwebhistory.cpp:
2295         * Api/qwebhistory.h:
2296         * Api/qwebpage.cpp:
2297         (QWebPagePrivate::QWebPagePrivate):
2298         (QWebPagePrivate::~QWebPagePrivate):
2299         (QWebPagePrivate::acceptNavigationRequest):
2300         (webActionForContextMenuAction):
2301         (QWebPagePrivate::updateAction):
2302         (QWebPagePrivate::keyPressEvent):
2303         (QWebPage::view):
2304         (QWebPage::javaScriptPrompt):
2305         (QWebPage::createWindow):
2306         (QWebPage::triggerAction):
2307         (QWebPage::setViewportSize):
2308         (QWebPage::acceptNavigationRequest):
2309         (QWebPage::action):
2310         (QWebPage::focusNextPrevChild):
2311         (QWebPage::setForwardUnsupportedContent):
2312         (QWebPage::forwardUnsupportedContent):
2313         (QWebPage::setLinkDelegationPolicy):
2314         (QWebPage::findText):
2315         (QWebPage::networkAccessManager):
2316         (QWebPageContext::imageUrl):
2317         (QWebPageContext::image):
2318         * Api/qwebpage.h:
2319         * Api/qwebpage_p.h:
2320         * Api/qwebsettings.cpp:
2321         (QWebSettingsPrivate::apply):
2322         (QWebSettings::QWebSettings):
2323         (QWebSettings::setIconDatabasePath):
2324         (QWebSettings::iconDatabasePath):
2325         (QWebSettings::clearIconDatabase):
2326         (QWebSettings::iconForUrl):
2327         (QWebSettings::setWebGraphic):
2328         (QWebSettings::fontFamily):
2329         (QWebSettings::setAttribute):
2330         (QWebSettings::testAttribute):
2331         (QWebSettings::resetAttribute):
2332         * Api/qwebsettings.h:
2333         * Api/qwebview.cpp:
2334         (QWebView::setPage):
2335         (QWebView::icon):
2336         (QWebView::setTextSizeMultiplier):
2337         (QWebView::textSizeMultiplier):
2338         (QWebView::findText):
2339         (QWebView::reload):
2340         (QWebView::mouseMoveEvent):
2341         * Api/qwebview.h:
2342         * QtLauncher/main.cpp:
2343         (MainWindow::MainWindow):
2344         (main):
2345         * WebCoreSupport/ChromeClientQt.cpp:
2346         (WebCore::ChromeClientQt::ChromeClientQt):
2347         (WebCore::ChromeClientQt::setWindowRect):
2348         (WebCore::ChromeClientQt::toolbarsVisible):
2349         (WebCore::ChromeClientQt::setStatusbarVisible):
2350         (WebCore::ChromeClientQt::statusbarVisible):
2351         (WebCore::ChromeClientQt::setScrollbarsVisible):
2352         (WebCore::ChromeClientQt::setResizable):
2353         (WebCore::ChromeClientQt::scrollBackingStore):
2354         (WebCore::ChromeClientQt::mouseDidMoveOverElement):
2355         (WebCore::ChromeClientQt::setToolTip):
2356         * WebCoreSupport/ChromeClientQt.h:
2357         * WebCoreSupport/FrameLoaderClientQt.cpp:
2358         (WebCore::FrameLoaderClientQt::setFrame):
2359         (WebCore::FrameLoaderClientQt::didPerformFirstNavigation):
2360         (WebCore::FrameLoaderClientQt::setMainDocumentError):
2361         (WebCore::FrameLoaderClientQt::dispatchDidFailLoading):
2362         (WebCore::FrameLoaderClientQt::createFrame):
2363         (WebCore::FrameLoaderClientQt::objectContentType):
2364         * WebCoreSupport/FrameLoaderClientQt.h:
2365         * WebCoreSupport/InspectorClientQt.cpp:
2366
2367 2008-04-18  Simon Hausmann  <hausmann@webkit.org>
2368
2369         Reviewed by Holger.
2370
2371         Added QWebView::find/QWebFrame::find.
2372
2373         * Api/qwebpage.cpp:
2374         (QWebPage::focusNextPrevChild):
2375         (QWebPage::find):
2376         * Api/qwebpage.h:
2377         * Api/qwebview.cpp:
2378         (QWebView::find):
2379         * Api/qwebview.h:
2380
2381 2008-04-15  Ariya Hidayat  <ariya.hidayat@trolltech.com>
2382
2383         Reviewed by Simon.
2384
2385         fix potential crash when loading image(s)
2386
2387         Crash may occur. If compiled with 4.3, the variable is not initialized.
2388         This fix solves https://bugs.webkit.org/show_bug.cgi?id=17174
2389
2390         * Api/qwebpage.cpp:
2391         (QWebPagePrivate::QWebPagePrivate):
2392
2393 2008-04-15  Simon Hausmann  <hausmann@webkit.org>
2394
2395         Reviewed by Holger.
2396
2397         Update the micro focus for input methods as soon as the composition mode changes
2398         or the caret/selection changes.
2399         
2400
2401         * Api/qwebpage.cpp:
2402         * Api/qwebpage.h:
2403         * Api/qwebview.cpp:
2404         (QWebView::setPage):
2405         * WebCoreSupport/EditorClientQt.cpp:
2406         (WebCore::EditorClientQt::respondToChangedSelection):
2407         (WebCore::EditorClientQt::setInputMethodState):
2408
2409 2008-04-15  Simon Hausmann  <hausmann@webkit.org>
2410
2411         Reviewed by Holger.
2412
2413         Don't use QDir, QString or any locale sensitive function before constructing Q(Core)Application,
2414         it yields undefined behaviour or wrong default codec initialization.
2415         
2416
2417         * QtLauncher/main.cpp:
2418         (WebPage::createWindow):
2419
2420 2008-04-15  Olivier Goffart  <ogoffart@trolltech.com>
2421
2422         Reviewed by Simon.
2423
2424         Fixes: copy to clipboard when selecting, and paste when clicking with the middle button
2425
2426         * Api/qwebpage.cpp:
2427         (QWebPagePrivate::mouseReleaseEvent): If the clipboard supports
2428         selections then we support copy & paste into the selection.
2429
2430 2008-04-15  Michael Brasser  <michael.brasser@trolltech.com>
2431
2432         Reviewed by Simon.
2433
2434         Add basic input method support.
2435         
2436
2437         * Api/qwebpage.cpp:
2438         (QWebPagePrivate::dropEvent):
2439         (QWebPagePrivate::inputMethodEvent):
2440         (QWebPage::inputMethodQuery):
2441         (QWebPage::event):
2442         * Api/qwebpage.h:
2443         * Api/qwebpage_p.h:
2444         * Api/qwebview.cpp:
2445         (QWebView::QWebView):
2446         (QWebView::inputMethodQuery):
2447         (QWebView::inputMethodEvent):
2448         * Api/qwebview.h:
2449         * WebCoreSupport/EditorClientQt.cpp:
2450         (WebCore::EditorClientQt::setInputMethodState):
2451
2452 2008-04-15  Simon Hausmann  <hausmann@webkit.org>
2453
2454         Reviewed by Holger.
2455
2456         Added (QWebFrame|QWebView)::textZoomFactor.
2457         
2458
2459         * Api/qwebframe.cpp:
2460         (QWebFrame::setTextZoomFactor):
2461         (QWebFrame::textZoomFactor):
2462         * Api/qwebframe.h:
2463         * Api/qwebview.cpp:
2464         (QWebView::setTextZoomFactor):
2465         (QWebView::textZoomFactor):
2466         * Api/qwebview.h:
2467
2468 2008-04-15  Michael Brasser  <michael.brasser@trolltech.com>
2469
2470         Reviewed by Simon.
2471
2472         Added simple scrolling API to QWebFrame.
2473         
2474         The intent is that it works similar to QAbstractScrollArea.
2475         
2476
2477         * Api/qwebframe.cpp:
2478         (QWebFrame::setScrollBarValue):
2479         (QWebFrame::scrollBarValue):
2480         (QWebFrame::scrollBarMaximum):
2481         (QWebFrame::scrollBarMinimum):
2482         * Api/qwebframe.h:
2483
2484 2008-04-15  Olivier Goffart  <ogoffart@trolltech.com>
2485
2486         Reviewed by Holger.
2487
2488         Fixes: implement the OpenFrameInNewWindow action.
2489         
2490
2491         * Api/qwebpage.cpp:
2492         (QWebPage::triggerAction):
2493
2494 2008-04-15  Andre Poenitz  <andre.poenitz@trolltech.com>
2495
2496         Reviewed by Simon.
2497
2498         Fix compilation with Qt namespaces
2499
2500         Qt can be configured to have all of its classes inside a specified namespaces.
2501         This is for example used in plugin/component environments like Eclipse.
2502
2503         This change makes it possible to let the Qt port compile against a namespaced
2504         Qt by the use of macros Qt provides to properly forward declare Qt classes in
2505         the namespace.
2506
2507         * Api/qwebframe.h:
2508         * Api/qwebpage.h:
2509         * Api/qwebpage_p.h:
2510         * Api/qwebpluginfactory.h:
2511         * Api/qwebsettings.h:
2512         * Api/qwebview.h:
2513
2514 2008-04-05  Olivier Goffart  <ogoffart@trolltech.com>
2515
2516         Reviewed by Holger.
2517
2518         Fixes: Right clicking an image and choosing "copy image" doesnt put anything in the clipboard.
2519         
2520
2521         * Api/qwebpage.cpp:
2522         (QWebPage::triggerAction):
2523
2524 2008-04-05  Olivier Goffart  <ogoffart@trolltech.com>
2525
2526         Reviewed by Simon.
2527
2528         Fixes: Right click, and "Open image" open the link instead of the image.
2529         
2530
2531         * Api/qwebpage.cpp:
2532
2533 2008-04-05  Benjamin Meyer  <bmeyer@trolltech.com>
2534
2535         Reviewed by Simon.
2536
2537         Added doc stub for QWebSettings so class docs are generated
2538         
2539
2540         * Api/qwebsettings.cpp:
2541         (QWebSettings::QWebSettings):
2542
2543 2008-04-05  Holger Hans Peter Freyther  <holger.freyther@trolltech.com>
2544
2545         Reviewed by Simon.
2546
2547         * Propose the addition of updateRequest and scrollRequest to the QWebPage.
2548         
2549         * The question is if these signals belong to QWebPage or  QWebFrame.
2550         -It is more easy to have them in QWebPage because ScrollView is invoking
2551         the ChromeClient with the right coordinates
2552         -On the other hand someone wants to render frames separately. But this is partly
2553         doomed as you can have overlapping frames and what you paint would not relate to
2554         what you normally see on webpages.
2555         
2556
2557         * Api/qwebpage.cpp:
2558         * Api/qwebpage.h:
2559         * WebCoreSupport/ChromeClientQt.cpp:
2560         (WebCore::ChromeClientQt::scrollBackingStore):
2561         (WebCore::ChromeClientQt::mouseDidMoveOverElement):
2562
2563 2008-04-03  Simon Hausmann  <hausmann@webkit.org>
2564
2565         Reviewed by Mark Rowe.
2566
2567         Roll out r31599 and r31605 again after discussion with Mark Rowe.
2568
2569         * Api/qwebframe.cpp:
2570         (QWebFrame::icon):
2571         * Api/qwebsettings.cpp:
2572         (QWebSettings::iconForUrl):
2573
2574 2008-04-03  Holger Hans Peter Freyther  <holger.freyther@trolltech.com>
2575
2576         Reviewed by Simon.
2577
2578         * Change IconDatabase::iconForPageURL to return more information. E.g. if
2579         an image has been found, or if the loading of an image has been scheduled.
2580         * Update FrameLoader to use another method to trigger reading from disk
2581         * Update the QWebFrame and QWebSettings
2582
2583         * Api/qwebframe.cpp:
2584         (QWebFrame::icon):
2585         * Api/qwebsettings.cpp:
2586         (QWebSettings::iconForUrl):
2587
2588 2008-04-03  Holger Hans Peter Freyther  <holger.freyther@trolltech.com>
2589
2590         Reviewed by Simon.
2591
2592         * Safari is using the IconDatabase the following way (assumption). Before they
2593         call iconDatabase()->open they "retain" all URLs they are interested in, these
2594         could come from the history.
2595         * When opening the iconDatabase() a thread will be started that is going to import
2596         the URLs, all none manually retained URLs are scheduled for removal. The removal
2597         is going to happen when the next icon gets stored in the database.
2598         * We do not have any IconDatabase code, we can not retain the URLs before opening the
2599         database. To disable the automatic pruning of the icons we will ask the IconDatabase
2600         to delay this operation. This means our IconDatabase, when used, will grow, so we should
2601         try to have a IconDatabase class in 4.4.
2602         * The only way to counter the growth is a call to QWebSettings::clearIconDatabase
2603         
2604
2605         * Api/qwebsettings.cpp:
2606         (QWebSettings::clearIconDatabase):
2607         * Api/qwebsettings.h:
2608
2609 2008-04-03  Benjamin Meyer  <bmeyer@trolltech.com>
2610
2611         Reviewed by Simon.
2612
2613         Add a way to get the site icon for a url
2614         static QPixmap iconForUrl(const QUrl &url);
2615         
2616
2617         * Api/qwebsettings.cpp:
2618         (QWebSettings::iconForUrl):
2619         * Api/qwebsettings.h:
2620
2621 2008-04-03  Holger Hans Peter Freyther  <holger.freyther@trolltech.com>
2622
2623         Reviewed by Simon.
2624
2625         * Update the Copyright info in QWebSettings
2626         
2627
2628         * Api/qwebsettings.cpp:
2629         * Api/qwebsettings.h:
2630
2631 2008-04-03  Holger Hans Peter Freyther  <holger.freyther@trolltech.com>
2632
2633         Reviewed by Simon.
2634
2635         * The isEmpty check is not needed anymore with the earlier backport
2636         
2637
2638         * Api/qwebframe.cpp:
2639         (QWebFrame::icon):
2640
2641 2008-04-03  Holger Hans Peter Freyther  <holger.freyther@trolltech.com>
2642
2643         Reviewed by Simon.
2644
2645         * For the http tests we need the output of the FrameLoaderClient. The QtWebKit API
2646         is not exporting enough to create the output in DRT itself. Settle with the approach
2647         Lars has taken for the Editing support and add branches to our FrameLoaderClient code.
2648         * run-webkit-tests http/tests(/loading) can now be executed.
2649         * For tests in loading/ directories we are going to throw away the dirty
2650         QWebPage to start with something clean.
2651         
2652
2653         * WebCoreSupport/FrameLoaderClientQt.cpp:
2654         (qt_dump_frame_loader):
2655         (drtDescriptionSuitableForTestResult):
2656         (WebCore::FrameLoaderClientQt::dispatchDidReceiveServerRedirectForProvisionalLoad):
2657         (WebCore::FrameLoaderClientQt::dispatchDidCancelClientRedirect):
2658         (WebCore::FrameLoaderClientQt::dispatchWillPerformClientRedirect):
2659         (WebCore::FrameLoaderClientQt::dispatchDidChangeLocationWithinPage):
2660         (WebCore::FrameLoaderClientQt::dispatchWillClose):
2661         (WebCore::FrameLoaderClientQt::dispatchDidStartProvisionalLoad):
2662         (WebCore::FrameLoaderClientQt::dispatchDidReceiveTitle):
2663         (WebCore::FrameLoaderClientQt::dispatchDidCommitLoad):
2664         (WebCore::FrameLoaderClientQt::dispatchDidFinishDocumentLoad):
2665         (WebCore::FrameLoaderClientQt::dispatchDidFinishLoad):
2666         (WebCore::FrameLoaderClientQt::registerForIconNotification):
2667         (WebCore::FrameLoaderClientQt::setMainDocumentError):
2668         (WebCore::FrameLoaderClientQt::dispatchDecidePolicyForNavigationAction):
2669
2670 2008-04-02  Holger Hans Peter Freyther  <holger.freyther@trolltech.com>
2671
2672         Reviewed by Simon.
2673
2674         * Export the PageCache and Cache capacity call one to one. This is only there
2675         to allow the QtLauncher to play with caching.
2676         * TODO: make API decisions and consider following the windows Api to set a WebCacheModel
2677         and determine certain values automatically.
2678         
2679
2680         * Api/qwebsettings.cpp:
2681         (QWebSettings::setPageCacheCapacity):
2682         (QWebSettings::setObjectCacheCapacities):
2683         * Api/qwebsettings.h:
2684         * QtLauncher/main.cpp:
2685
2686 2008-04-02  Holger Hans Peter Freyther  <holger.freyther@trolltech.com>
2687
2688         Reviewed by Simon.
2689
2690         Prepapre everything for enabling the PageCache for the Qt Platform:
2691         * Claim that we can cache pages
2692         * Create the FrameView FrameLoaderClientQt::transitionToCommittedForNewPage using
2693         the initial size of the viewport and stop creating it in the QWebFramePrivate::init
2694         
2695         Differences to the Windows port:
2696         * attachToWindow/detachFromWindow is not called and is not (yet) part
2697         of Widget/ScrollView of the Qt platform. We might need that for plugin
2698         support in the future.
2699         * We store the margin's and scrolling flag inside QWebFrame and use it when
2700         creating the FrameView.
2701         
2702         What is missing:
2703         * API to call pageCache()->setCapacity(XYZ);
2704         
2705
2706         * Api/qwebframe.cpp:
2707         (QWebFramePrivate::init):
2708         * Api/qwebframe_p.h:
2709         (QWebFramePrivate::QWebFramePrivate):
2710         * Api/qwebpage.cpp:
2711         (QWebPagePrivate::createMainFrame):
2712         * WebCoreSupport/FrameLoaderClientQt.cpp:
2713         (WebCore::FrameLoaderClientQt::transitionToCommittedForNewPage):
2714         (WebCore::FrameLoaderClientQt::blockedError):
2715
2716 2008-04-02  Holger Hans Peter Freyther  <holger.freyther@trolltech.com>
2717
2718         Reviewed by Simon.
2719
2720         * For the PageCache support we do not want to create a FrameView in the constructor
2721         of QWebFrame. In QWegPage::viewportSize() we currently call mainFrame() and that will
2722         create a QWebFrame if no mainFrame is present and this gets called when we try to
2723         create a FrameView...
2724         * Keep a copy of the initial viewportSize around and use it if we do not have a Frame
2725         or FrameView.
2726         
2727
2728         * Api/qwebpage.cpp:
2729         (QWebPagePrivate::QWebPagePrivate):
2730         (QWebPage::triggerAction):
2731         * Api/qwebpage_p.h:
2732
2733 2008-04-02  Holger Hans Peter Freyther  <holger.freyther@trolltech.com>
2734
2735         Reviewed by Simon.
2736
2737         * Always return true in FrameLoaderClientQt::shouldGoToHistoryItem, like the windows port
2738
2739         * WebCoreSupport/FrameLoaderClientQt.cpp:
2740         (WebCore::):
2741
2742 2008-04-02  Holger Hans Peter Freyther  <holger.freyther@trolltech.com>
2743
2744         Reviewed by Simon.
2745
2746         * Attempt to make the m_webFrame null pointer checking consistent. Always check for
2747         m_webFrame. It should get set by the QWebFrame with the FramerLoaderClientQt::setFrame
2748         call and should stay valid until the destruction of the QWebFrame.
2749         * Currently the same checking is not needed for m_frame as it will only set to 0 in
2750         FrameLoaderClientQt::frameLoaderDestroyed and should be not 0 because of the setFrame
2751         initialisation.
2752         
2753
2754         * WebCoreSupport/FrameLoaderClientQt.cpp:
2755         (WebCore::FrameLoaderClientQt::dispatchDidReceiveTitle):
2756         (WebCore::FrameLoaderClientQt::setMainDocumentError):
2757         (WebCore::FrameLoaderClientQt::dispatchDidReceiveContentLength):
2758         (WebCore::FrameLoaderClientQt::objectContentType):
2759         (WebCore::FrameLoaderClientQt::createPlugin):
2760
2761 2008-04-01  Holger Hans Peter Freyther  <holger.freyther@trolltech.com>
2762
2763         Reviewed by Simon.
2764
2765         * Get the RefCounting of WebCore::Frame right and make sure that both QWebFrame
2766         and WebCore::Frame get destroyed if we leave site with subframes and on the
2767         end of the application.
2768         * Use adoptRef in FrameLoaderClientQt::createFrame to get the refs right for subframes. We
2769         do not want to add an extra reference. Without this we are leaking subframes.
2770         * Assume that the lifetime of a Frame and FrameLoader are the same, when the Frame is gone
2771         we want to destroy the QWebFrame (e.g. on a page with subframes). Add delete m_webFrame
2772         in the frameLoaderDestroyed method to do that.
2773         * If we happen to delete the QWebFrame before the FrameLoaderClientQt we set m_webFrame to
2774         zero in the FrameLoaderClientQt to avoid bad things.
2775         
2776
2777         * Api/qwebframe.cpp:
2778         (QWebFrame::~QWebFrame):
2779         * WebCoreSupport/FrameLoaderClientQt.cpp:
2780         (WebCore::FrameLoaderClientQt::shouldGoToHistoryItem):
2781         (WebCore::FrameLoaderClientQt::objectContentType):
2782         * WebCoreSupport/FrameLoaderClientQt.h:
2783
2784 2008-04-01  Holger Hans Peter Freyther  <holger.freyther@trolltech.com>
2785
2786         Reviewed by Simon.
2787
2788         * Do not save a RefPtr to the frame. The FrameLoaderClient, Frame and
2789         QWebFrame should have the same lifetime everything else is a leak
2790         or issue.
2791
2792         * Api/qwebframe.cpp:
2793         (QWebFramePrivate::init):
2794         * Api/qwebframe_p.h:
2795         * WebCoreSupport/FrameLoaderClientQt.cpp:
2796
2797 2008-04-01  Holger Hans Peter Freyther  <holger.freyther@trolltech.com>
2798
2799         Reviewed by Simon.
2800
2801         * Do not store the QWebFrame associated with a ScrollView/FrameView
2802         in the WebCore::Widget.
2803         * Instead of asking the Widget for the QWebFrame use the QWebFramePrivate::core
2804         and QWebFramePrivate::kit function to convert from and to QWebFrame.
2805         
2806
2807         * Api/qwebframe.cpp:
2808         (QWebFramePrivate::init):
2809         * Api/qwebpage.cpp:
2810         (QWebPagePrivate::createMainFrame):
2811
2812 2008-04-01  Holger Hans Peter Freyther  <holger.freyther@trolltech.com>
2813
2814         Reviewed by Simon.
2815
2816         * Do not store the FrameView in the QWebFrame and cope with the situation when
2817         a WebCore::Frame has no WebCore::FrameView.
2818         
2819
2820         * Api/qwebframe.cpp:
2821         (QWebFramePrivate::init):
2822         (QWebFramePrivate::horizontalScrollBar):
2823         (QWebFramePrivate::verticalScrollBar):
2824         (QWebFrame::innerText):
2825         (QWebFrame::renderTreeDump):
2826         (QWebFrame::setVerticalScrollBarPolicy):
2827         (QWebFrame::setHorizontalScrollBarPolicy):
2828         (QWebFrame::render):
2829         (QWebFrame::layout):
2830         (QWebFrame::pos):
2831         * Api/qwebframe_p.h:
2832         (QWebFramePrivate::QWebFramePrivate):
2833         * Api/qwebpage.cpp:
2834         (QWebPagePrivate::updateEditorActions):
2835         (QWebPagePrivate::mouseMoveEvent):
2836         (QWebPagePrivate::mousePressEvent):
2837         (QWebPagePrivate::mouseDoubleClickEvent):
2838         (QWebPagePrivate::contextMenuEvent):
2839         (QWebPagePrivate::wheelEvent):
2840         (QWebPage::triggerAction):
2841         * WebCoreSupport/FrameLoaderClientQt.cpp:
2842
2843 2008-04-01  Holger Hans Peter Freyther  <holger.freyther@trolltech.com>
2844
2845         Reviewed by Simon.
2846
2847         * Change the order of the methods to match with the FrameLoaderClient.h to ease
2848         removing methods in the future.
2849
2850         * WebCoreSupport/FrameLoaderClientQt.h:
2851
2852 2008-04-01  Holger Hans Peter Freyther  <holger.freyther@trolltech.com>
2853
2854         Reviewed by Simon.
2855
2856         * Remove virtuals in the FrameLoaderClientQt that don't exist in the base class.
2857
2858         * WebCoreSupport/FrameLoaderClientQt.cpp:
2859         (WebCore::FrameLoaderClientQt::detachedFromParent4):
2860         * WebCoreSupport/FrameLoaderClientQt.h:
2861
2862 2008-03-25  Brady Eidson  <beidson@apple.com>
2863
2864         Reviewed by Darin
2865
2866         Remove newly obsolete FrameLoaderClient methods
2867
2868         * WebCoreSupport/FrameLoaderClientQt.cpp:
2869         * WebCoreSupport/FrameLoaderClientQt.h:
2870
2871 2008-03-22  Mark Rowe  <mrowe@apple.com>
2872
2873         Qt build fix.
2874
2875         * WebCoreSupport/FrameLoaderClientQt.cpp:
2876         (WebCore::):
2877
2878 2008-03-18  Simon Hausmann  <hausmann@webkit.org>
2879
2880         Reviewed by Holger.
2881
2882         Fix the Qt build. Don't return void in non-void functions.
2883
2884         * Api/qwebpluginfactory.cpp:
2885         (QWebPluginFactory::extension):
2886
2887 2008-03-16  Thiago Macieira  <thiago.macieira@trolltech.com>
2888
2889         Reviewed by Simon.
2890
2891         Don't use RefPtr in classes you haven't seen the implementation of.
2892         
2893         Forward-declaration and declaration of RefPtr<Foo> is ok. But you
2894         cannot *use* said objects until Foo is defined. This is true even for
2895         initialisation with a 0.
2896         
2897         Seems the HP aCC compiler is more strict here than gcc.
2898
2899         * Api/qwebframe_p.h:
2900
2901 2008-03-14  Simon Hausmann  <hausmann@webkit.org>
2902
2903         Fix the Qt build.
2904
2905         * Api/qwebframe.cpp:
2906         (QWebFrame::setHtml):
2907         (QWebFrame::setContent):
2908
2909 2008-03-13  Simon Hausmann  <hausmann@webkit.org>
2910
2911         Fix the Qt build.
2912
2913         * Api/qwebframe.cpp:
2914         (QWebFrame::addToJSWindowObject):
2915
2916 2008-03-12  Simon Hausmann  <hausmann@webkit.org>
2917
2918         Fix compilation against Qt 4.3
2919
2920         * Api/qwebpage.cpp:
2921         * Api/qwebpage.h:
2922         * Api/qwebpage_p.h:
2923
2924 2008-03-11  Rodney Dawes  <dobey@wayofthemonkey.com>
2925
2926         Fix the Qt build.
2927
2928         * WebCoreSupport/FrameLoaderClientQt.cpp:
2929         (FrameLoaderClientQt::CreatePlugin):
2930
2931 2008-03-11  Simon Hausmann  <hausmann@webkit.org>
2932
2933         Fix the Qt build (silly typo).
2934
2935         * QtLauncher/main.cpp:
2936         (MainWindow::MainWindow):
2937
2938 2008-03-11  Tor Arne Vestbø  <tavestbo@trolltech.com>
2939
2940         Reviewed by Simon.
2941
2942         Moved obscuring progress bar to the lower right corner.
2943
2944         * QtLauncher/main.cpp:
2945         (MainWindow::MainWindow):
2946         (MainWindow::resizeEvent):
2947
2948 2008-03-11  Tor Arne Vestbø  <tavestbo@trolltech.com>
2949
2950         Reviewed by Simon.
2951
2952         Added reload action and grouped stop and reload actions together.
2953
2954         * QtLauncher/main.cpp:
2955         (MainWindow::MainWindow):
2956
2957 2008-03-11  Holger Hans Peter Freyther  <holger.freyther@trolltech.com>
2958
2959         Reviewed by Simon.
2960
2961         * Set a Icon on the QAction if we have one.
2962
2963         * Api/qwebpage.cpp:
2964         (QWebPage::action):
2965
2966 2008-03-11  Simon Hausmann  <hausmann@webkit.org>
2967
2968         Fix the Qt build.
2969
2970         * Api/qwebframe.cpp:
2971         (QWebFrame::addToJSWindowObject):
2972
2973 2008-03-07  Simon Hausmann  <hausmann@webkit.org>
2974
2975         Reviewed by Darin Adler.
2976
2977         Done with Lars.
2978
2979         Replaced the QWebObjectPlugin interfaces with QWebPluginFactory.
2980
2981         * Api/qwebnetworkinterface.cpp:
2982         (QWebNetworkManager::add):
2983         (QWebNetworkManager::cancel):
2984         (QWebNetworkManager::started):
2985         (QWebNetworkManager::data):
2986         (QWebNetworkManager::finished):
2987         * Api/qwebnetworkinterface_p.h:
2988         (QWebNetworkJobPrivate::QWebNetworkJobPrivate):
2989         * Api/qwebobjectplugin.cpp: Removed.
2990         * Api/qwebobjectplugin.h: Removed.
2991         * Api/qwebobjectplugin_p.h: Removed.
2992         * Api/qwebobjectpluginconnector.cpp: Removed.
2993         * Api/qwebobjectpluginconnector.h: Removed.
2994         * Api/qwebpage.cpp:
2995         (QWebPagePrivate::QWebPagePrivate):
2996         (QWebPage::setPluginFactory):
2997         (QWebPage::pluginFactory):
2998         * Api/qwebpage.h:
2999         * Api/qwebpage_p.h:
3000         * Api/qwebpluginfactory.cpp: Added.
3001         (QWebPluginFactory::QWebPluginFactory):
3002         (QWebPluginFactory::~QWebPluginFactory):
3003         (QWebPluginFactory::refreshPlugins):
3004         (QWebPluginFactory::extension):
3005         * Api/qwebpluginfactory.h: Added.
3006         (MimeType::):
3007         * WebCoreSupport/FrameLoaderClientQt.cpp:
3008         (WebCore::FrameLoaderClientQt::objectContentType):
3009         (WebCore::FrameLoaderClientQt::createPlugin):
3010
3011 2008-03-07  Simon Hausmann  <hausmann@webkit.org>
3012
3013         Fix the Qt build.
3014
3015         * Api/qwebframe.cpp:
3016
3017 2008-03-04  Sam Weinig  <sam@webkit.org>
3018
3019         Reviewed by Mark Rowe.
3020
3021         - Remove all unnecessary includes of JSDOMWindowBase.h, we prefer including
3022           JSDOMWindow.h
3023
3024         * Api/qwebframe.cpp:
3025         (QWebFrame::addToJSWindowObject):
3026
3027 2008-03-04  Mark Rowe  <mrowe@apple.com>
3028
3029         Another go at fixing the Qt build.
3030
3031         * Api/qwebframe.cpp:
3032         (QWebFrame::addToJSWindowObject):
3033
3034 2008-02-24  Darin Adler  <darin@apple.com>
3035
3036         Reviewed by Sam.
3037
3038         - remove separate client calls for "standard" and "reload' history
3039
3040         * WebCoreSupport/FrameLoaderClientQt.cpp:
3041         (WebCore::FrameLoaderClientQt::updateGlobalHistory):
3042         * WebCoreSupport/FrameLoaderClientQt.h:
3043
3044 2008-02-24  Darin Adler  <darin@apple.com>
3045
3046         - another try at fixing the build
3047
3048         * Api/qwebframe.cpp:
3049         (QWebFrame::load): Replace new FormData with FormData::create.
3050
3051 2008-02-22  Sam Weinig  <sam@webkit.org>
3052
3053         Fix Qt build.
3054
3055         * Api/qwebhistoryinterface.cpp:
3056
3057 2008-02-22  Sam Weinig  <sam@webkit.org>
3058
3059         Rubber-stamped by Adam Roben.
3060
3061         Rid the project of the Devil known as DeprecatedString!
3062
3063         * Api/qwebhistory.cpp:
3064         * Api/qwebhistoryinterface.cpp:
3065
3066 2008-02-18  Darin Adler  <darin@apple.com>
3067
3068         Reviewed by Sam.
3069
3070         * Api/qwebnetworkinterface.cpp:
3071         (QWebNetworkRequestPrivate::init): Removed use of DeprecatedString.
3072
3073 2008-01-24  David Boddie  <dboddie@trolltech.com>
3074
3075         Reviewed by Simon.
3076
3077         Documentation tidying.
3078         
3079
3080         * Api/qwebframe.cpp:
3081         * Api/qwebhistoryinterface.cpp:
3082         * Api/qwebview.cpp:
3083
3084 2008-01-24  Jarek Kobus  <jkobus@trolltech.com>
3085
3086         Reviewed by Simon.
3087
3088         Text for translations were used wrongly as comments
3089         
3090
3091         * WebCoreSupport/FrameLoaderClientQt.cpp:
3092         (WebCore::):
3093         (WebCore::FrameLoaderClientQt::cannotShowURLError):
3094         (WebCore::FrameLoaderClientQt::interruptForPolicyChangeError):
3095         (WebCore::FrameLoaderClientQt::cannotShowMIMETypeError):
3096         (WebCore::FrameLoaderClientQt::fileDoesNotExistError):
3097         (WebCore::FrameLoaderClientQt::shouldFallBack):
3098
3099 2008-01-24  Holger Hans Peter Freyther  <holger.freyther@trolltech.com>
3100
3101         Reviewed by Simon.
3102
3103         * We have a KURL->QUrl conversion on KURL itself, make use of it.
3104         * This conversion is supposed to be loss-free
3105         
3106
3107         * Api/qwebframe.cpp:
3108
3109 2008-01-23  Holger Hans Peter Freyther  <holger.freyther@trolltech.com>
3110
3111         * Rubber stamped by Simon
3112
3113         * Fix leaking of sub frames (WebCore::Frame). We keep one reference too many.
3114         This was found while working on the page-cache, other ports are not affected.
3115
3116         * WebCoreSupport/FrameLoaderClientQt.cpp:
3117         (WebCore::FrameLoaderClientQt::createFrame):
3118
3119 2008-01-23  Rohan McGovern  <rohan.mcgovern@trolltech.com>
3120
3121         Reviewed by Simon Hausmann <hausmann@webkit.org>.
3122
3123         Fix Qtopia compilation with QT_NO_TOOLTIP
3124         
3125
3126         * WebCoreSupport/ChromeClientQt.cpp:
3127         (WebCore::ChromeClientQt::print):
3128
3129 2008-01-23  Geir Vattekar  <gvatteka@trolltech.com>
3130
3131         Reviewed by Simon.
3132
3133         Doc: Replaced \code with snippets in the docs
3134         
3135
3136         * Api/qwebview.cpp:
3137
3138 2008-01-23  Benjamin Meyer  <bmeyer@trolltech.com>
3139
3140         Reviewed by Simon.
3141
3142         Tweak key presses even to match commonly expected behavior
3143         - space key == page down
3144         - page down moved down not a page, but slightly less then a page so you don't loose your spot when reading.
3145         - Use font height rather then a hard coded "10" for left, right, up, down
3146         - Ctrl-Up moves to the top of the page
3147         - Ctrl-Down move to the bottom of the page
3148         - Backspace == GoBack
3149         - Shift-Backspace == GoForward
3150         
3151
3152         * Api/qwebpage.cpp:
3153         (dropActionToDragOp):
3154         (dragOpToDropAction):
3155         (QWebPagePrivate::keyPressEvent):
3156
3157 2008-01-23  Simon Hausmann  <hausmann@webkit.org>
3158
3159         Reviewed by Lars.
3160
3161         Implemented FrameLoaderClient::startDownload() and FrameLoaderClient::download().
3162         
3163         Added two signals to QWebPage to handle downloading of links and handling of
3164         unsupported content.
3165         
3166
3167         * Api/qwebpage.cpp:
3168         (QWebPage::triggerAction):
3169         * Api/qwebpage.h:
3170         * WebCoreSupport/FrameLoaderClientQt.cpp:
3171         (WebCore::FrameLoaderClientQt::download):
3172         (WebCore::FrameLoaderClientQt::assignIdentifierToInitialRequest):
3173         (WebCore::FrameLoaderClientQt::dispatchDecidePolicyForMIMEType):
3174         (WebCore::FrameLoaderClientQt::dispatchDecidePolicyForNewWindowAction):
3175         (WebCore::FrameLoaderClientQt::willUseArchive):
3176
3177 2008-01-22  Lars Knoll  <lars@trolltech.com>
3178
3179         Reviewed by Simon.
3180
3181         setup a family for cursive and fantasy fonts as well.
3182         
3183
3184         * Api/qwebsettings.cpp:
3185         (QWebSettings::QWebSettings):
3186
3187 2008-01-22  Benjamin Meyer  <bmeyer@trolltech.com>
3188
3189         Reviewed by Simon.
3190
3191         Implement ChromeClientQt::setToolTip
3192         Implement ChromeClientQt::mouseDidMoveOverElement
3193         
3194
3195         * Api/qwebpage.cpp:
3196         * Api/qwebpage_p.h:
3197         * WebCoreSupport/ChromeClientQt.cpp:
3198         (WebCore::ChromeClientQt::ChromeClientQt):
3199         (WebCore::ChromeClientQt::focus):
3200         (WebCore::ChromeClientQt::mouseDidMoveOverElement):
3201         (WebCore::ChromeClientQt::setToolTip):
3202         (WebCore::ChromeClientQt::print):
3203         * WebCoreSupport/ChromeClientQt.h:
3204
3205 2008-01-21  Darin Adler  <darin@apple.com>
3206
3207         Reviewed by John Sullivan.
3208
3209         - updated for changes to ChromeClient database functions
3210
3211         * WebCoreSupport/ChromeClientQt.cpp:
3212         (WebCore::ChromeClientQt::exceededDatabaseQuota):
3213         * WebCoreSupport/ChromeClientQt.h:
3214
3215 2008-01-21  Benjamin Meyer  <bmeyer@trolltech.com>
3216
3217         Reviewed by Simon.
3218
3219         Change QWebHistoryInterface::addHistoryEntry() from const to non-const
3220         
3221
3222         * Api/qwebhistoryinterface.h:
3223
3224 2008-01-21  Adam Treat  <treat@kde.org>
3225
3226         Reviewed by Simon.
3227
3228         * Don't leak the d-pointer in QWebSettings.
3229         
3230
3231         * Api/qwebsettings.cpp:
3232         (QWebSettings::~QWebSettings):
3233
3234 2008-01-21  Simon Hausmann  <hausmann@webkit.org>
3235
3236         Reviewed by Holger.
3237
3238         Update the WebKit version number from WebKit/win/WebKit.vcproj/VERSION.
3239         
3240         This has the fortunate side-effect that gmail sends us sensible HTML/JS again :)
3241         
3242
3243         * Api/qwebpage.cpp:
3244
3245 2008-01-21  Simon Hausmann  <hausmann@webkit.org>
3246
3247         Reviewed by Holger.
3248
3249         Fix focus chain handling and cycling through focusable objects (links) using tab/backtab.
3250         
3251         * Fix GraphicsContext::drawFocusRing to also draw single focus rects.
3252         * Implemented QWebPage::focusNextPrevChild by sending fake tab/shift-tab events
3253         and make the return value depend on whether we successfully determined a focusable
3254         node or not.
3255         * Changed QWebView::focusNextPrevChild() to call the base QWidget implementation correctly
3256         if we could not handle the focus chain ourselves.
3257         * Changed the focus policy of QWebView to correctly use WheelFocus instead of ClickFocus.
3258         * Made ChromeClientQt::canTakeFocus() and takeFocus() dummy method since they are only
3259         used to control the situation of stepping out of the focus chain inside the page.
3260         * Made inclusion of links in the focus chain configurable through QWebSettings::LinksIncludedInFocusChain.
3261         The layout tests expect this to be disabled but for the user it seems sensible to have it
3262         on by default, hence the default in qwebsettings.cpp
3263         
3264
3265         * Api/qwebpage.cpp:
3266         (QWebPage::focusNextPrevChild):
3267         * Api/qwebsettings.cpp:
3268         (QWebSettings::QWebSettings):
3269         * Api/qwebsettings.h:
3270         * Api/qwebview.cpp:
3271         (QWebView::QWebView):
3272         (QWebView::focusNextPrevChild):
3273         * WebCoreSupport/ChromeClientQt.cpp:
3274         (WebCore::ChromeClientQt::canTakeFocus):
3275         (WebCore::ChromeClientQt::takeFocus):
3276
3277 2008-01-18  Simon Hausmann  <hausmann@webkit.org>
3278
3279         Reviewed by Holger.
3280
3281         Coding style fixes and added a comment about the include order.
3282
3283         * WebKit_pch.h:
3284
3285 2008-01-18  Marius Storm-Olsen  <marius@trolltech.com>
3286
3287         Reviewed by Simon Hausmann <hausmann@webkit.org>.
3288
3289         Add use of precompiled header, when building inside Qt.
3290         
3291         Compiling WebKit was taking forever; 17 minutes on my machine for _one_ build! Adding the PCH at least brings it down to 12 minutes for one build, for me.
3292         
3293
3294         * WebKit_pch.h: Added.
3295
3296 2008-01-18  Holger Hans Peter Freyther  <holger.freyther@trolltech.com>
3297
3298         Reviewed by Simon.
3299
3300         * Ask the WebCore::IconDatabase only if our URL is not empty. Otherwise
3301         we will see a crash in a HashSet.
3302         * It is crashing there because the StringImpl of an empty String is 0.
3303         * We avoid this crash by checking for isEmpty() in WebKit as there is no
3304         use to ask the iconDatabase for an empty string. We will fallback to the
3305         defaultIcon.
3306         
3307
3308         * Api/qwebframe.cpp:
3309         (QWebFrame::icon):
3310
3311 2008-01-17  Simon Hausmann  <hausmann@webkit.org>
3312
3313         Reviewed by Holger.
3314
3315         Minor documentation fixes
3316         
3317
3318         * Api/qwebframe.cpp:
3319         * Api/qwebview.cpp:
3320
3321 2008-01-17  Simon Hausmann  <shausman@trolltech.com>
3322
3323         Reviewed by Lars.
3324
3325         Fix form elements not focusing correctly after the qt widget lost its focus.
3326         
3327         When receiving a focus out event notify the focus controller. Otherwise its
3328         m_focusedFrame variable remains unchanged and setFocusedFrame on a focusIn
3329         event shortcuts and doesn't call setActive(true).
3330         
3331
3332         * Api/qwebpage.cpp:
3333
3334 2008-01-17  Simon Hausmann  <shausman@trolltech.com>
3335
3336         Reviewed by Holger.
3337
3338         Lots of updates to the documentation.
3339         
3340
3341         * Api/qwebframe.cpp:
3342         * Api/qwebhistory.cpp:
3343         * Api/qwebpage.cpp:
3344         (QWebPagePrivate::dropEvent):
3345         (QWebPage::history):
3346         (openNewWindow):
3347         (QWebPage::triggerAction):
3348         (QWebPage::viewportSize):
3349         (QWebPage::navigationRequested):
3350         (QWebPage::action):
3351         (QWebPage::event):
3352         (QWebPageContext::targetFrame):
3353         * Api/qwebpage.h:
3354         * Api/qwebview.cpp:
3355
3356 2008-01-17  Simon Hausmann  <shausman@trolltech.com>
3357
3358         Reviewed by Lars.
3359
3360         Added a urlChanged signals to QWebFrame and QWebView.
3361         
3362
3363         * Api/qwebframe.cpp:
3364         * Api/qwebframe.h:
3365         * Api/qwebview.cpp:
3366         (QWebView::setPage):
3367         * Api/qwebview.h:
3368         * WebCoreSupport/FrameLoaderClientQt.cpp:
3369
3370 2008-01-17  Simon Hausmann  <shausman@trolltech.com>
3371
3372         Reviewed by Lars.
3373
3374         Fixed docs and sanity checks in QWebSettings::setIconDatabaseEnabled
3375         
3376
3377         * Api/qwebsettings.cpp:
3378         (QWebSettings::setIconDatabaseEnabled):
3379
3380 2008-01-17  Simon Hausmann  <shausman@trolltech.com>
3381
3382         Reviewed by Lars.
3383
3384         Added QWebView::createWindow() which is forwarded from QWebPage::createWindow() for convenience.
3385         
3386
3387         * Api/qwebpage.cpp:
3388         (QWebPage::createWindow):
3389         * Api/qwebview.cpp:
3390         (QWebView::createWindow):
3391         * Api/qwebview.h:
3392
3393 2008-01-17  Lars Knoll  <lars@trolltech.com>
3394
3395         Reviewed by Lars.
3396
3397         add a 0 pointer check.
3398
3399         Fixes a crash in the demo web browser.
3400
3401         * WebCoreSupport/FrameLoaderClientQt.cpp:
3402         (WebCore::FrameLoaderClientQt::dispatchDecidePolicyForMIMEType):
3403
3404 2008-01-17  Simon Hausmann  <hausmann@webkit.org>
3405
3406         Reviewed by Holger.
3407
3408         Fix QWebFrame::title().
3409         
3410         For the titleChanged() signal we use the documentloader's title. For the property we have to use the same
3411         instead of Document::title() as the latter is not trimmed and not suited for a window caption.
3412         
3413
3414         * Api/qwebframe.cpp:
3415         (QWebFrame::title):
3416
3417 2008-01-17  Simon Hausmann  <hausmann@webkit.org>
3418
3419         Reviewed by Maciej, Lars, Holger.
3420
3421         http://bugs.webkit.org/show_bug.cgi?id=16589
3422
3423         Add a document parameter to WebCore::cookies, setCookies and cookiesEnabled.
3424
3425         * Api/qwebnetworkinterface.cpp:
3426         (QWebNetworkRequestPrivate::init):
3427         (QWebNetworkManager::started):
3428
3429 2008-01-17  Warwick Allison  <warwick@trolltech.com>
3430
3431         Reviewed by Simon Hausmann <hausmann@webkit.org>.
3432
3433         Follow QWidget::keyPressEvent advice and call parents.
3434         
3435         Without this, Back does not work in Qtopia, for example.
3436         
3437
3438         * Api/qwebview.cpp:
3439         (QWebView::keyPressEvent):
3440         (QWebView::keyReleaseEvent):
3441
3442 2008-01-17  Simon Hausmann  <hausmann@webkit.org>
3443
3444         Reviewed by Lars.
3445
3446         Fix compilation against Qt 4.3 after the recent KURL <> QUrl conversion fixes.
3447
3448         * Api/qwebnetworkinterface.cpp:
3449         (QWebNetworkManager::started):
3450
3451 2008-01-17  Simon Hausmann  <shausman@trolltech.com>
3452
3453         Reviewed by Holger.
3454
3455         Fix compilation against Qt 4.4 without files that are specific for the Qt 4.3 build.
3456         
3457
3458         * Api/qwebframe.cpp:
3459         * Api/qwebpage.cpp:
3460         * WebCoreSupport/FrameLoaderClientQt.cpp:
3461
3462 2008-01-17  Lincoln Ramsay  <lincoln.ramsay@trolltech.com>
3463
3464         Reviewed by Simon Hausmann <hausmann@webkit.org>.
3465
3466         Fixes compilation with QT_NO_DRAGANDDROP
3467         
3468
3469         * Api/qwebpage.cpp:
3470         (QWebPage::event):
3471         * Api/qwebview.cpp:
3472         (QWebView::dragEnterEvent):
3473         (QWebView::dragLeaveEvent):
3474         (QWebView::dragMoveEvent):
3475         (QWebView::dropEvent):
3476
3477 2008-01-17  Simon Hausmann  <hausmann@webkit.org>
3478
3479         Reviewed by Lars.
3480
3481         Fix compilation, removed obsolete privateBrowsingEnabled() method.
3482
3483         * WebCoreSupport/FrameLoaderClientQt.cpp:
3484
3485 2008-01-16  Lars Knoll  <lars@trolltech.com>
3486
3487         Reviewed by Simon Hausmann <simon.hausmann@trolltech.com>.
3488
3489         Removed a whole bunch of notImplemented() warnings.
3490         
3491         I don't want to hide the real warnings in lots of things that
3492         I am by now pretty certain we won't need.
3493         
3494
3495         * WebCoreSupport/FrameLoaderClientQt.cpp:
3496         (WebCore::FrameLoaderClientQt::dispatchWillSubmitForm):
3497         (WebCore::FrameLoaderClientQt::canShowMIMEType):
3498
3499 2008-01-16  Simon Hausmann  <hausmann@webkit.org>
3500
3501         Reviewed by Holger.
3502
3503         Fix crash when bringing up the context menu on maps.google.com.
3504         
3505         If the website provides its own context menu then we don't have a ContextMenu pointer.
3506         
3507
3508         * Api/qwebpage.cpp:
3509         (QWebPagePrivate::contextMenuEvent):
3510
3511 2008-01-16  Simon Hausmann  <hausmann@webkit.org>
3512
3513         Reviewed by Holger.
3514
3515         Don't crash when receiving all sorts of events on a default constructed QWebView without a page.
3516
3517         * Api/qwebview.cpp:
3518         (QWebView::mouseMoveEvent):
3519         (QWebView::mousePressEvent):
3520         (QWebView::mouseDoubleClickEvent):
3521         (QWebView::mouseReleaseEvent):
3522         (QWebView::contextMenuEvent):
3523         (QWebView::wheelEvent):
3524         (QWebView::keyPressEvent):
3525         (QWebView::keyReleaseEvent):
3526         (QWebView::focusInEvent):
3527         (QWebView::focusOutEvent):
3528         (QWebView::dragEnterEvent):
3529         (QWebView::dragLeaveEvent):
3530         (QWebView::dragMoveEvent):
3531         (QWebView::dropEvent):
3532         (QWebView::focusNextPrevChild):
3533
3534 2008-01-16  Simon Hausmann  <hausmann@webkit.org>
3535
3536         Reviewed by Lars.
3537
3538         Made the url property read-write.
3539
3540         * Api/qwebview.h:
3541
3542 2008-01-16  Simon Hausmann  <hausmann@webkit.org>
3543
3544         Reviewed by Lars.
3545
3546         Don't crash when showing a default initialized QWebView that has no page/frame yet.
3547
3548         * Api/qwebview.cpp:
3549         (QWebView::paintEvent):
3550
3551 2008-01-16  Holger Freyther  <holger.freyther@trolltech.com>
3552
3553         Reviewed by Simon.
3554
3555         Change hoveringOverLink implementation to have less issues.
3556         
3557         * Currently we only compare a pointer. In the worst case we
3558         could delete the Element we have pointed to and a new one
3559         gets the same address. But even if that doesn't happen the
3560         WebCore::Element is mutable and JavaScript could change the
3561         URL, Title or Content. So we have to compare all these three
3562         attributes.
3563         * This does not seem to be a performance impact.
3564         
3565
3566         * Api/qwebpage.cpp:
3567         (QWebPagePrivate::mouseMoveEvent):
3568         * Api/qwebpage_p.h:
3569
3570 2008-01-16  Holger Freyther  <holger.freyther@trolltech.com>
3571
3572         Reviewed by Simon.
3573
3574         * Move the hoverElement from QWebFrame to QWebPage. As it is
3575         only used there.
3576         
3577
3578         * Api/qwebframe_p.h:
3579         (QWebFramePrivate::QWebFramePrivate):
3580         * Api/qwebpage.cpp:
3581         (QWebPagePrivate::mouseMoveEvent):
3582         * Api/qwebpage_p.h:
3583
3584 2008-01-16  Holger Freyther  <holger.freyther@trolltech.com>
3585
3586         Reviewed by Simon.
3587
3588         EventHandler changes/fixes in QWebPage:
3589         -mouse{Press,Move,Release}Event:
3590         Send the event always to the mainFrame of the QWebPage.
3591         
3592         -contextMenuEvent, key{Press,Release}Event:
3593         Send the event to the focused frame.
3594         
3595         This is following the Windows port and fixes a issue with the
3596         Web Inspector where we were sending the events to a wrong frame.
3597         
3598         It is guaranteed that the mainFrame will always have an eventHandler
3599         and frameView set. There is no need to check for this in QWebPage.
3600         
3601
3602         * Api/qwebframe.cpp:
3603         (QWebFramePrivate::init):
3604         * Api/qwebframe_p.h:
3605         (QWebFramePrivate::QWebFramePrivate):
3606         * Api/qwebpage.cpp:
3607         (QWebPagePrivate::updateEditorActions):
3608         (QWebPagePrivate::mouseMoveEvent):
3609         (QWebPagePrivate::mousePressEvent):
3610         (QWebPagePrivate::mouseDoubleClickEvent):
3611         (QWebPagePrivate::mouseReleaseEvent):
3612         (QWebPagePrivate::contextMenuEvent):
3613         (QWebPagePrivate::wheelEvent):
3614         (QWebPagePrivate::keyPressEvent):
3615         (QWebPagePrivate::keyReleaseEvent):
3616         (QWebPagePrivate::focusInEvent):
3617         * Api/qwebpage_p.h:
3618
3619 2008-01-16  Holger Freyther  <holger.freyther@trolltech.com>
3620
3621         Reviewed by Simon.
3622
3623         * Add core and kit functions to QWebFramePrivate to convert from
3624         QWebFrame to WebCore::Frame and vice versa.
3625         
3626
3627         * Api/qwebframe.cpp:
3628         (QWebFramePrivate::core):
3629         (QWebFramePrivate::kit):
3630         * Api/qwebframe.h:
3631         * Api/qwebframe_p.h:
3632
3633 2008-01-16  Lars Knoll  <lars@trolltech.com>
3634
3635         Reviewed by Simon.
3636
3637         add conversion methods from and to QUrl to KURL.
3638         
3639         Use them in the places I found at the moment. Fixes a bug
3640         where form data was encoded twice.
3641         Also fix QWebSettings to take a QUrl for the user style sheet
3642         location.
3643         
3644
3645         * Api/qwebframe.cpp:
3646         (QWebFrame::load):
3647         * Api/qwebpage.cpp:
3648         (QWebPage::createPlugin):
3649         (frameLoadRequest):
3650         (QWebPage::triggerAction):
3651         * Api/qwebsettings.cpp:
3652         (QWebSettingsPrivate::apply):
3653         * Api/qwebsettings.h:
3654         * WebCoreSupport/ChromeClientQt.cpp:
3655         (WebCore::ChromeClientQt::createWindow):
3656         (WebCore::ChromeClientQt::show):
3657
3658 2008-01-16  Holger Hans Peter Freyther  <holger.freyther@trolltech.com>
3659
3660         Reviewed by Lars.
3661
3662         * Make the InspectorClientView inherit from QWebView instead of QWidget. This
3663         way paintEvent, mouse{Press,Release}Event and other events get forwarded to
3664         the QWebPage/WebInspector automatically.
3665         
3666
3667         * WebCoreSupport/InspectorClientQt.cpp:
3668         (WebCore::InspectorClientWebPage::createWindow):
3669         (WebCore::InspectorClientView::InspectorClientView):
3670
3671 2008-01-10  Maciej Stachowiak  <mjs@apple.com>
3672
3673         Reviewed by Sam.
3674
3675         - remove SecurityOriginData and fold its functionality into SecurityOrigin
3676
3677         * WebCoreSupport/ChromeClientQt.cpp:
3678         (WebCore::ChromeClientQt::requestQuotaIncreaseForNewDatabase):
3679         (WebCore::ChromeClientQt::requestQuotaIncreaseForDatabaseOperation):
3680         * WebCoreSupport/ChromeClientQt.h:
3681
3682 2008-01-10  Lars Knoll  <lars@trolltech.com>
3683
3684         Reviewed by Simon.
3685
3686         document QWebHistory
3687         
3688
3689         * Api/qwebhistory.cpp:
3690         (QWebHistoryItem::QWebHistoryItem):
3691         (QWebHistoryItem::operator=):
3692         (QWebHistoryItem::~QWebHistoryItem):
3693         (QWebHistoryItem::originalUrl):
3694         (QWebHistoryItem::currentUrl):
3695         (QWebHistoryItem::title):
3696         (QWebHistoryItem::icon):
3697         (QWebHistory::canGoBack):
3698         (QWebHistory::canGoForward):
3699         (QWebHistory::goBack):
3700         (QWebHistory::goForward):
3701         (QWebHistory::goToItem):
3702         * Api/qwebhistory.h:
3703
3704 2008-01-10  Simon Hausmann  <hausmann@webkit.org>
3705
3706         Reviewed by Lars.
3707
3708         Make the reset() functions not do anything on the default QWebSettings object.
3709         
3710
3711         * Api/qwebsettings.cpp:
3712         (QWebSettings::resetFontSize):
3713         (QWebSettings::resetFontFamily):
3714         (QWebSettings::clearAttribute):
3715
3716 2008-01-10  Lars Knoll  <lars@trolltech.com>
3717
3718         Reviewed by Simon.
3719
3720         rename QWebPageHistory to QWebHistory.
3721         
3722
3723         * Api/qwebhistory.cpp: Added.
3724         (QWebHistoryItem::QWebHistoryItem):
3725         (QWebHistoryItem::operator=):
3726         (QWebHistoryItem::~QWebHistoryItem):
3727         (QWebHistoryItem::originalUrl):
3728         (QWebHistoryItem::currentUrl):
3729         (QWebHistoryItem::title):
3730         (QWebHistoryItem::lastVisited):
3731         (QWebHistoryItem::icon):
3732         (QWebHistory::QWebHistory):
3733         (QWebHistory::~QWebHistory):
3734         (QWebHistory::clear):
3735         (QWebHistory::items):
3736         (QWebHistory::backItems):
3737         (QWebHistory::forwardItems):
3738         (QWebHistory::canGoBack):
3739         (QWebHistory::canGoForward):
3740         (QWebHistory::goBack):
3741         (QWebHistory::goForward):
3742         (QWebHistory::goToItem):
3743         (QWebHistory::backItem):
3744         (QWebHistory::currentItem):
3745         (QWebHistory::forwardItem):
3746         (QWebHistory::itemAtIndex):
3747         * Api/qwebhistory.h: Added.
3748         * Api/qwebhistory_p.h: Added.
3749         (QWebHistoryItemPrivate::QWebHistoryItemPrivate):
3750         (QWebHistoryItemPrivate::~QWebHistoryItemPrivate):
3751         (QWebHistoryPrivate::QWebHistoryPrivate):
3752         (QWebHistoryPrivate::~QWebHistoryPrivate):
3753         * Api/qwebpage.cpp:
3754         (QWebPagePrivate::QWebPagePrivate):
3755         * Api/qwebpage.h:
3756         * Api/qwebpage_p.h:
3757         * Api/qwebpagehistory.cpp: Removed.
3758         * Api/qwebpagehistory.h: Removed.
3759         * Api/qwebpagehistory_p.h: Removed.
3760         * Api/qwebview.cpp:
3761         *