[WK2] Support multiple URLs for WebApp meta tag
[framework/web/webkit-efl.git] / Source / WebKit2 / WebProcess / WebPage / WebPage.h
1 /*
2  * Copyright (C) 2010, 2011 Apple Inc. All rights reserved.
3  *
4  * Redistribution and use in source and binary forms, with or without
5  * modification, are permitted provided that the following conditions
6  * are met:
7  * 1. Redistributions of source code must retain the above copyright
8  *    notice, this list of conditions and the following disclaimer.
9  * 2. Redistributions in binary form must reproduce the above copyright
10  *    notice, this list of conditions and the following disclaimer in the
11  *    documentation and/or other materials provided with the distribution.
12  *
13  * THIS SOFTWARE IS PROVIDED BY APPLE INC. AND ITS CONTRIBUTORS ``AS IS''
14  * AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO,
15  * THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
16  * PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL APPLE INC. OR ITS CONTRIBUTORS
17  * BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR
18  * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF
19  * SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS
20  * INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN
21  * CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE)
22  * ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF
23  * THE POSSIBILITY OF SUCH DAMAGE.
24  */
25
26 #ifndef WebPage_h
27 #define WebPage_h
28
29 #include "APIObject.h"
30 #include "DrawingArea.h"
31 #include "FindController.h"
32 #include "GeolocationPermissionRequestManager.h"
33 #include "ImageOptions.h"
34 #include "ImmutableArray.h"
35 #if ENABLE(CONTEXT_MENUS)
36 #include "InjectedBundlePageContextMenuClient.h"
37 #endif
38 #include "InjectedBundlePageDiagnosticLoggingClient.h"
39 #include "InjectedBundlePageEditorClient.h"
40 #include "InjectedBundlePageFormClient.h"
41 #include "InjectedBundlePageFullScreenClient.h"
42 #include "InjectedBundlePageLoaderClient.h"
43 #include "InjectedBundlePagePolicyClient.h"
44 #include "InjectedBundlePageResourceLoadClient.h"
45 #include "InjectedBundlePageUIClient.h"
46 #include "MessageSender.h"
47 #include "TapHighlightController.h"
48 #include "Plugin.h"
49 #include "SandboxExtension.h"
50 #include "ShareableBitmap.h"
51 #include "WebHitTestResult.h"
52 #include "WebUndoStep.h"
53 #include <WebCore/DictationAlternative.h>
54 #include <WebCore/DragData.h>
55 #include <WebCore/Editor.h>
56 #include <WebCore/FrameLoaderTypes.h>
57 #include <WebCore/IntRect.h>
58 #include <WebCore/Page.h>
59 #if ENABLE(PAGE_VISIBILITY_API)
60 #include <WebCore/PageVisibilityState.h>
61 #endif
62 #include <WebCore/PlatformScreen.h>
63 #include <WebCore/ScrollTypes.h>
64 #include <WebCore/WebCoreKeyboardUIMode.h>
65 #include <wtf/HashMap.h>
66 #include <wtf/OwnPtr.h>
67 #include <wtf/PassRefPtr.h>
68 #include <wtf/RefPtr.h>
69 #include <wtf/text/WTFString.h>
70
71 #if PLATFORM(QT)
72 #include "ArgumentCodersQt.h"
73 #include "QtNetworkAccessManager.h"
74 #include "QtNetworkReply.h"
75 #include "QtNetworkReplyData.h"
76 #include "QtNetworkRequestData.h"
77 #include <QNetworkReply>
78 #include <QNetworkRequest>
79 #endif
80
81 #if PLATFORM(GTK)
82 #include "ArgumentCodersGtk.h"
83 #include "WebPageAccessibilityObject.h"
84 #include "WebPrintOperationGtk.h"
85 #endif
86
87 #if ENABLE(TOUCH_EVENTS)
88 #include <WebCore/PlatformTouchEvent.h>
89 #endif
90
91 #if PLATFORM(MAC)
92 #include "DictionaryPopupInfo.h"
93 #include "LayerHostingContext.h"
94 #include <wtf/RetainPtr.h>
95 OBJC_CLASS NSDictionary;
96 OBJC_CLASS NSObject;
97 OBJC_CLASS WKAccessibilityWebPageObject;
98 #endif
99
100 #if ENABLE(TIZEN_PAGE_VISIBILITY_API)
101 #include <WebCore/PageVisibilityState.h>
102 #endif
103
104 #if ENABLE(TIZEN_CUSTOM_HEADERS)
105 #include <WebCore/HTTPHeaderMap.h>
106 #endif
107
108 #if ENABLE(TIZEN_DATALIST_ELEMENT)
109 #include "HTMLDataListElement.h"
110 #endif
111
112 #if ENABLE(TIZEN_DRAG_SUPPORT)
113 #include "ArgumentCodersTizen.h"
114 #endif
115
116 #if ENABLE(TIZEN_SCREEN_READER)
117 #include "ScreenReader.h"
118 #endif
119
120 namespace CoreIPC {
121     class ArgumentDecoder;
122     class Connection;
123     class MessageID;
124 }
125
126 namespace WebCore {
127     class GraphicsContext;
128     class Frame;
129     class FrameView;
130     class HTMLPlugInElement;
131     class KeyboardEvent;
132     class Page;
133     class PrintContext;
134     class Range;
135     class ResourceRequest;
136     class SharedBuffer;
137     class VisibleSelection;
138     struct KeypressCommand;
139
140 #if ENABLE(TIZEN_DATALIST_ELEMENT)
141     class HTMLDataListElement;
142 #endif
143 }
144
145 namespace WebKit {
146
147 class DrawingArea;
148 class InjectedBundleBackForwardList;
149 class NotificationPermissionRequestManager;
150 class PageOverlay;
151 class PluginView;
152 class SessionState;
153 class WebColorChooser;
154 class WebContextMenu;
155 class WebContextMenuItemData;
156 class WebEvent;
157 class WebFrame;
158 class WebFullScreenManager;
159 class WebImage;
160 class WebInspector;
161 class WebInspectorClient;
162 class WebKeyboardEvent;
163 class WebMouseEvent;
164 class WebNotificationClient;
165 class WebOpenPanelResultListener;
166 class WebPageGroupProxy;
167 class WebPopupMenu;
168 class WebWheelEvent;
169 struct AttributedString;
170 struct EditorState;
171 struct PrintInfo;
172 struct WebPageCreationParameters;
173 struct WebPreferencesStore;
174
175 #if ENABLE(WEB_INTENTS)
176 struct IntentData;
177 #endif
178
179 #if ENABLE(GESTURE_EVENTS)
180 class WebGestureEvent;
181 #endif
182
183 #if ENABLE(TOUCH_EVENTS)
184 class WebTouchEvent;
185 #endif
186
187 #if ENABLE(TIZEN_MEDIA_STREAM)
188 class UserMediaPermissionRequestManager;
189 class WebUserMediaClient;
190 #endif
191
192 #if ENABLE(TIZEN_ISF_PORT)
193 class NativeWebKeyboardEvent;
194 #endif
195
196 class WebPage : public APIObject, public CoreIPC::MessageSender<WebPage> {
197 public:
198     static const Type APIType = TypeBundlePage;
199
200     static PassRefPtr<WebPage> create(uint64_t pageID, const WebPageCreationParameters&);
201     virtual ~WebPage();
202
203     // Used by MessageSender.
204     CoreIPC::Connection* connection() const;
205     uint64_t destinationID() const { return pageID(); }
206
207     void close();
208
209     WebCore::Page* corePage() const { return m_page.get(); }
210     uint64_t pageID() const { return m_pageID; }
211
212     void setSize(const WebCore::IntSize&);
213     const WebCore::IntSize& size() const { return m_viewSize; }
214     WebCore::IntRect bounds() const { return WebCore::IntRect(WebCore::IntPoint(), size()); }
215     
216     InjectedBundleBackForwardList* backForwardList();
217     DrawingArea* drawingArea() const { return m_drawingArea.get(); }
218
219     WebPageGroupProxy* pageGroup() const { return m_pageGroup.get(); }
220
221     void scrollMainFrameIfNotAtMaxScrollPosition(const WebCore::IntSize& scrollOffset);
222
223     void scrollBy(uint32_t scrollDirection, uint32_t scrollGranularity);
224
225     void centerSelectionInVisibleArea();
226
227 #if PLATFORM(EFL)
228     void confirmComposition(const String& compositionString);
229     void setComposition(const WTF::String& compositionString, const WTF::Vector<WebCore::CompositionUnderline>& underlines, uint64_t cursorPosition);
230 #if ENABLE(TIZEN_TEXT_CARET_HANDLING_WK2)
231     bool setCaretPosition(const WebCore::IntPoint&);
232     void getCaretPosition(WebCore::IntRect&);
233 #endif
234 #if ENABLE(TIZEN_ISF_PORT)
235     void updateCursorOffset();
236     void didCancelComposition(WebCore::Node*);
237
238     void getCursorOffset(int&);
239     void getSurroundingTextAndCursorOffset(String&, int&);
240     void getSelectionRect(bool, WebCore::IntRect&);
241     void deleteSurroundingText(int, int);
242 #endif
243     void scrollMainFrameBy(const WebCore::IntSize&);
244     void scrollMainFrameTo(const WebCore::IntPoint&);
245     void createSnapshot(const WebCore::IntRect, float, ShareableBitmap::Handle&);
246     void requestUpdateFormNavigation();
247     void moveFocus(int newIndex);
248 #if ENABLE(TIZEN_MOBILE_WEB_PRINT)
249         void createPagesToPDF(const WebCore::IntSize&, const WebCore::IntSize&, const String&);
250 #endif
251 #if ENABLE(TIZEN_WEBKIT2_HIT_TEST)
252     void hitTestResultAtPoint(const WebCore::IntPoint&, int hitTestMode, WebHitTestResult::Data&);
253 #endif
254
255 #if ENABLE(TIZEN_WEB_STORAGE)
256     void getStorageQuotaBytes(uint64_t callbackID);
257     void setStorageQuotaBytes(uint32_t quota);
258 #endif
259
260 #if ENABLE(TIZEN_CLIPBOARD) || ENABLE(TIZEN_PASTEBOARD)
261     void setClipboardDataForPaste(const String& data, const String& type);
262 #endif
263
264     void suspendJavaScriptAndResources();
265     void resumeJavaScriptAndResources();
266 #if ENABLE(TIZEN_SYNC_REQUEST_ANIMATION_FRAME)
267     void suspendAnimationController();
268     void resumeAnimationController();
269 #endif
270 #if ENABLE(TIZEN_PLUGIN_SUSPEND_RESUME)
271     void suspendPlugin();
272     void resumePlugin();
273 #endif
274 #endif
275 #if ENABLE(TIZEN_WEBKIT2_REMOTE_WEB_INSPECTOR)
276     void startInspectorServer(uint32_t port,  uint32_t& assignedPort);
277     void stopInspectorServer(bool& result);
278 #endif
279 #if ENABLE(TIZEN_ORIENTATION_EVENTS)
280     void sendOrientationChangeEvent(int orientation);
281 #endif
282
283 #if ENABLE(INSPECTOR)
284     WebInspector* inspector();
285 #endif
286
287 #if ENABLE(FULLSCREEN_API)
288     WebFullScreenManager* fullScreenManager();
289 #endif
290
291     // -- Called by the DrawingArea.
292     // FIXME: We could genericize these into a DrawingArea client interface. Would that be beneficial?
293     void drawRect(WebCore::GraphicsContext&, const WebCore::IntRect&);
294 #if ENABLE(TIZEN_WEBKIT2_TEXT_SELECTION)
295     void selectClosestWord(const WebCore::IntPoint&, bool isStartedTextSelectionFromOutside, bool& result);
296     void setLeftSelection(const WebCore::IntPoint&, bool& result);
297     void setRightSelection(const WebCore::IntPoint&, bool& result);
298     void getSelectionHandlers(WebCore::IntRect& leftRect, WebCore::IntRect& rightRect);
299     void getSelectionText(String& result);
300     void selectionRangeClear(bool& result);
301     void selectionClearAllSelection(WebCore::Frame* frame);
302 #endif
303
304 #if ENABLE(TIZEN_OFFLINE_PAGE_SAVE)
305     void startOfflinePageSave(String subresourceFolderName);
306 #endif
307
308 #if ENABLE(TIZEN_WEBKIT2_CONTEXT_MENU_TEXT_SELECTION_MODE)
309     void selectLink(WebCore::IntPoint positionForSelection, bool& result);
310 #endif
311
312     void drawPageOverlay(WebCore::GraphicsContext&, const WebCore::IntRect&);
313     void layoutIfNeeded();
314 #if ENABLE(TIZEN_RECORDING_SURFACE_SET)
315     void recordingSurfaceSetEnableSet(bool enable);
316     void recordingSurfaceSetEnableURL(const String&);
317
318     bool recordingSurfaceEnabled() { return m_recordingSurfaceSetEnable; }
319
320     void setRecordingSurfaceLoadStart(bool enable) { m_recordingSurfaceSetLoadStart = enable; }
321     bool recordingSurfaceLoadStart() { return m_recordingSurfaceSetLoadStart; }
322
323     void setRecordingSurfaceLoadFinish(bool enable) { m_recordingSurfaceSetLoadFinished = enable; }
324     bool recordingSurfaceLoadFinish() { return m_recordingSurfaceSetLoadFinished; }
325 #endif
326
327     // -- Called from WebCore clients.
328 #if PLATFORM(MAC)
329     bool handleEditingKeyboardEvent(WebCore::KeyboardEvent*, bool saveCommands);
330 #elif !PLATFORM(GTK)
331     bool handleEditingKeyboardEvent(WebCore::KeyboardEvent*);
332 #endif
333
334     void show();
335     String userAgent() const { return m_userAgent; }
336     WebCore::IntRect windowResizerRect() const;
337     WebCore::KeyboardUIMode keyboardUIMode();
338
339     WebUndoStep* webUndoStep(uint64_t);
340     void addWebUndoStep(uint64_t, WebUndoStep*);
341     void removeWebEditCommand(uint64_t);
342     bool isInRedo() const { return m_isInRedo; }
343
344     void setActivePopupMenu(WebPopupMenu*);
345
346 #if ENABLE(INPUT_TYPE_COLOR)
347     WebColorChooser* activeColorChooser() const { return m_activeColorChooser; }
348     void setActiveColorChooser(WebColorChooser*);
349     void didChooseColor(const WebCore::Color&);
350     void didEndColorChooser();
351 #endif
352
353     WebOpenPanelResultListener* activeOpenPanelResultListener() const { return m_activeOpenPanelResultListener.get(); }
354     void setActiveOpenPanelResultListener(PassRefPtr<WebOpenPanelResultListener>);
355
356     // -- Called from WebProcess.
357     void didReceiveMessage(CoreIPC::Connection*, CoreIPC::MessageID, CoreIPC::ArgumentDecoder*);
358     void didReceiveSyncMessage(CoreIPC::Connection*, CoreIPC::MessageID, CoreIPC::ArgumentDecoder*, OwnPtr<CoreIPC::ArgumentEncoder>&);
359
360     // -- InjectedBundle methods
361 #if ENABLE(CONTEXT_MENUS)
362     void initializeInjectedBundleContextMenuClient(WKBundlePageContextMenuClient*);
363 #endif
364     void initializeInjectedBundleEditorClient(WKBundlePageEditorClient*);
365     void initializeInjectedBundleFormClient(WKBundlePageFormClient*);
366     void initializeInjectedBundleLoaderClient(WKBundlePageLoaderClient*);
367     void initializeInjectedBundlePolicyClient(WKBundlePagePolicyClient*);
368     void initializeInjectedBundleResourceLoadClient(WKBundlePageResourceLoadClient*);
369     void initializeInjectedBundleUIClient(WKBundlePageUIClient*);
370 #if ENABLE(FULLSCREEN_API)
371     void initializeInjectedBundleFullScreenClient(WKBundlePageFullScreenClient*);
372 #endif
373     void initializeInjectedBundleDiagnosticLoggingClient(WKBundlePageDiagnosticLoggingClient*);
374
375 #if ENABLE(CONTEXT_MENUS)
376     InjectedBundlePageContextMenuClient& injectedBundleContextMenuClient() { return m_contextMenuClient; }
377 #endif
378     InjectedBundlePageEditorClient& injectedBundleEditorClient() { return m_editorClient; }
379     InjectedBundlePageFormClient& injectedBundleFormClient() { return m_formClient; }
380     InjectedBundlePageLoaderClient& injectedBundleLoaderClient() { return m_loaderClient; }
381     InjectedBundlePagePolicyClient& injectedBundlePolicyClient() { return m_policyClient; }
382     InjectedBundlePageResourceLoadClient& injectedBundleResourceLoadClient() { return m_resourceLoadClient; }
383     InjectedBundlePageUIClient& injectedBundleUIClient() { return m_uiClient; }
384     InjectedBundlePageDiagnosticLoggingClient& injectedBundleDiagnosticLoggingClient() { return m_logDiagnosticMessageClient; }
385 #if ENABLE(FULLSCREEN_API)
386     InjectedBundlePageFullScreenClient& injectedBundleFullScreenClient() { return m_fullScreenClient; }
387 #endif
388
389     void setUnderlayPage(PassRefPtr<WebPage> underlayPage) { m_underlayPage = underlayPage; }
390
391     bool findStringFromInjectedBundle(const String&, FindOptions);
392
393     WebFrame* mainWebFrame() const { return m_mainFrame.get(); }
394
395     WebCore::Frame* mainFrame() const; // May return 0.
396     WebCore::FrameView* mainFrameView() const; // May return 0.
397
398     PassRefPtr<Plugin> createPlugin(WebFrame*, WebCore::HTMLPlugInElement*, const Plugin::Parameters&);
399
400     EditorState editorState() const;
401
402     String renderTreeExternalRepresentation() const;
403     uint64_t renderTreeSize() const;
404     void setPaintedObjectsCounterThreshold(uint64_t);
405
406     void setTracksRepaints(bool);
407     bool isTrackingRepaints() const;
408     void resetTrackedRepaints();
409     PassRefPtr<ImmutableArray> trackedRepaintRects();
410
411     void executeEditingCommand(const String& commandName, const String& argument);
412     bool isEditingCommandEnabled(const String& commandName);
413     void clearMainFrameName();
414     void sendClose();
415
416     double textZoomFactor() const;
417     void setTextZoomFactor(double);
418     double pageZoomFactor() const;
419     void setPageZoomFactor(double);
420     void setPageAndTextZoomFactors(double pageZoomFactor, double textZoomFactor);
421     void windowScreenDidChange(uint64_t);
422     void setViewMode(WebCore::Page::ViewMode);
423
424     void scalePage(double scale, const WebCore::IntPoint& origin);
425     double pageScaleFactor() const;
426
427     void setUseFixedLayout(bool);
428     bool useFixedLayout() const { return m_useFixedLayout; }
429     void setFixedLayoutSize(const WebCore::IntSize&);
430
431     void setPaginationMode(uint32_t /* WebCore::Page::Pagination::Mode */);
432     void setPaginationBehavesLikeColumns(bool);
433     void setPageLength(double);
434     void setGapBetweenPages(double);
435
436     bool drawsBackground() const { return m_drawsBackground; }
437     bool drawsTransparentBackground() const { return m_drawsTransparentBackground; }
438
439     void stopLoading();
440     void stopLoadingFrame(uint64_t frameID);
441     void setDefersLoading(bool deferLoading);
442
443 #if USE(ACCELERATED_COMPOSITING)
444     void enterAcceleratedCompositingMode(WebCore::GraphicsLayer*);
445     void exitAcceleratedCompositingMode();
446 #endif
447
448     void addPluginView(PluginView*);
449     void removePluginView(PluginView*);
450
451 #if PLATFORM(MAC)
452     LayerHostingMode layerHostingMode() const { return m_layerHostingMode; }
453     void setLayerHostingMode(LayerHostingMode);
454
455     bool windowIsVisible() const { return m_windowIsVisible; }
456     void updatePluginsActiveAndFocusedState();
457     const WebCore::IntRect& windowFrameInScreenCoordinates() const { return m_windowFrameInScreenCoordinates; }
458     const WebCore::IntRect& viewFrameInWindowCoordinates() const { return m_viewFrameInWindowCoordinates; }
459 #elif PLATFORM(WIN)
460     HWND nativeWindow() const { return m_nativeWindow; }
461 #endif
462
463     bool windowIsFocused() const;
464     bool windowAndWebPageAreFocused() const;
465     void installPageOverlay(PassRefPtr<PageOverlay>);
466     void uninstallPageOverlay(PageOverlay*, bool fadeOut);
467     bool hasPageOverlay() const { return m_pageOverlay; }
468     WebCore::IntPoint screenToWindow(const WebCore::IntPoint&);
469     WebCore::IntRect windowToScreen(const WebCore::IntRect&);
470
471     PassRefPtr<WebImage> snapshotInViewCoordinates(const WebCore::IntRect&, ImageOptions);
472     PassRefPtr<WebImage> scaledSnapshotInViewCoordinates(const WebCore::IntRect&, double scaleFactor, ImageOptions);
473     PassRefPtr<WebImage> snapshotInDocumentCoordinates(const WebCore::IntRect&, ImageOptions);
474     PassRefPtr<WebImage> scaledSnapshotInDocumentCoordinates(const WebCore::IntRect&, double scaleFactor, ImageOptions);
475
476     static const WebEvent* currentEvent();
477
478     FindController& findController() { return m_findController; }
479 #if ENABLE(TOUCH_EVENTS) && PLATFORM(QT)
480     TapHighlightController& tapHighlightController() { return m_tapHighlightController; }
481 #endif
482
483 #if ENABLE(GEOLOCATION)
484     GeolocationPermissionRequestManager& geolocationPermissionRequestManager() { return m_geolocationPermissionRequestManager; }
485 #endif
486
487     NotificationPermissionRequestManager* notificationPermissionRequestManager();
488 #if ENABLE(TIZEN_MEDIA_STREAM)
489     UserMediaPermissionRequestManager* userMediaPermissionRequestManager();
490 #endif
491     void pageDidScroll();
492 #if USE(TILED_BACKING_STORE)
493     void pageDidRequestScroll(const WebCore::IntPoint&);
494
495 #if ENABLE(TIZEN_WEBKIT2_HISTORICAL_RESTORE_VISIBLE_CONTENT_RECT)
496     void pageDidRequestRestoreVisibleContentRect(const WebCore::IntPoint&, float);
497 #endif
498
499     void setFixedVisibleContentRect(const WebCore::IntRect&);
500     void setResizesToContentsUsingLayoutSize(const WebCore::IntSize&);
501     void resizeToContentsIfNeeded();
502     void sendViewportAttributesChanged();
503     void setViewportSize(const WebCore::IntSize&);
504     WebCore::IntSize viewportSize() const { return m_viewportSize; }
505
506 #if ENABLE(TIZEN_WEBKIT2_TILED_BACKING_STORE)
507     WebCore::IntSize contentsSize() const;
508 #endif
509
510 #endif
511
512 #if ENABLE(CONTEXT_MENUS)
513     WebContextMenu* contextMenu();
514 #endif
515     
516     bool hasLocalDataForURL(const WebCore::KURL&);
517     String cachedResponseMIMETypeForURL(const WebCore::KURL&);
518     String cachedSuggestedFilenameForURL(const WebCore::KURL&);
519     PassRefPtr<WebCore::SharedBuffer> cachedResponseDataForURL(const WebCore::KURL&);
520
521     static bool canHandleRequest(const WebCore::ResourceRequest&);
522
523     class SandboxExtensionTracker {
524     public:
525         ~SandboxExtensionTracker();
526
527         void invalidate();
528
529         void beginLoad(WebFrame*, const SandboxExtension::Handle& handle);
530         void willPerformLoadDragDestinationAction(PassRefPtr<SandboxExtension> pendingDropSandboxExtension);
531         void didStartProvisionalLoad(WebFrame*);
532         void didCommitProvisionalLoad(WebFrame*);
533         void didFailProvisionalLoad(WebFrame*);
534
535     private:
536         void setPendingProvisionalSandboxExtension(PassRefPtr<SandboxExtension>);
537
538         RefPtr<SandboxExtension> m_pendingProvisionalSandboxExtension;
539         RefPtr<SandboxExtension> m_provisionalSandboxExtension;
540         RefPtr<SandboxExtension> m_committedSandboxExtension;
541     };
542
543     SandboxExtensionTracker& sandboxExtensionTracker() { return m_sandboxExtensionTracker; }
544
545 #if PLATFORM(EFL)
546     void setThemePath(const String&);
547 #endif
548
549 #if PLATFORM(QT)
550     void setComposition(const String& text, Vector<WebCore::CompositionUnderline> underlines, uint64_t selectionStart, uint64_t selectionEnd, uint64_t replacementRangeStart, uint64_t replacementRangeEnd);
551     void confirmComposition(const String& text, int64_t selectionStart, int64_t selectionLength);
552     void cancelComposition();
553 #endif
554
555 #if PLATFORM(MAC)
556     void registerUIProcessAccessibilityTokens(const CoreIPC::DataReference& elemenToken, const CoreIPC::DataReference& windowToken);
557     WKAccessibilityWebPageObject* accessibilityRemoteObject();
558     WebCore::IntPoint accessibilityPosition() const { return m_accessibilityPosition; }    
559     
560     void sendComplexTextInputToPlugin(uint64_t pluginComplexTextInputIdentifier, const String& textInput);
561
562     void setComposition(const String& text, Vector<WebCore::CompositionUnderline> underlines, uint64_t selectionStart, uint64_t selectionEnd, uint64_t replacementRangeStart, uint64_t replacementRangeEnd, EditorState& newState);
563     void confirmComposition(EditorState& newState);
564     void cancelComposition(EditorState& newState);
565     void insertText(const String& text, uint64_t replacementRangeStart, uint64_t replacementRangeEnd, bool& handled, EditorState& newState);
566     void getMarkedRange(uint64_t& location, uint64_t& length);
567     void getSelectedRange(uint64_t& location, uint64_t& length);
568     void getAttributedSubstringFromRange(uint64_t location, uint64_t length, AttributedString&);
569     void characterIndexForPoint(const WebCore::IntPoint point, uint64_t& result);
570     void firstRectForCharacterRange(uint64_t location, uint64_t length, WebCore::IntRect& resultRect);
571     void executeKeypressCommands(const Vector<WebCore::KeypressCommand>&, bool& handled, EditorState& newState);
572     void readSelectionFromPasteboard(const WTF::String& pasteboardName, bool& result);
573     void getStringSelectionForPasteboard(WTF::String& stringValue);
574     void getDataSelectionForPasteboard(const WTF::String pasteboardType, SharedMemory::Handle& handle, uint64_t& size);
575     void shouldDelayWindowOrderingEvent(const WebKit::WebMouseEvent&, bool& result);
576     void acceptsFirstMouse(int eventNumber, const WebKit::WebMouseEvent&, bool& result);
577     bool performNonEditingBehaviorForSelector(const String&);
578     void insertDictatedText(const String& text, uint64_t replacementRangeStart, uint64_t replacementRangeEnd, const Vector<WebCore::DictationAlternative>& dictationAlternativeLocations, bool& handled, EditorState& newState);
579 #elif PLATFORM(WIN)
580     void confirmComposition(const String& compositionString);
581     void setComposition(const WTF::String& compositionString, const WTF::Vector<WebCore::CompositionUnderline>& underlines, uint64_t cursorPosition);
582     void firstRectForCharacterInSelectedRange(const uint64_t characterPosition, WebCore::IntRect& resultRect);
583     void getSelectedText(WTF::String&);
584
585     void gestureWillBegin(const WebCore::IntPoint&, bool& canBeginPanning);
586     void gestureDidScroll(const WebCore::IntSize&);
587     void gestureDidEnd();
588
589 #elif PLATFORM(GTK)
590     void updateAccessibilityTree();
591     bool handleMousePressedEvent(const WebCore::PlatformMouseEvent&);
592 #if USE(TEXTURE_MAPPER_GL)
593     void widgetMapped(int64_t nativeWindowHandle);
594 #endif
595 #endif
596
597     void setCompositionForTesting(const String& compositionString, uint64_t from, uint64_t length);
598     bool hasCompositionForTesting();
599     void confirmCompositionForTesting(const String& compositionString);
600
601     // FIXME: This a dummy message, to avoid breaking the build for platforms that don't require
602     // any synchronous messages, and should be removed when <rdar://problem/8775115> is fixed.
603     void dummy(bool&);
604
605 #if PLATFORM(MAC)
606     void performDictionaryLookupForSelection(DictionaryPopupInfo::Type, WebCore::Frame*, const WebCore::VisibleSelection&);
607
608     bool isSpeaking();
609     void speak(const String&);
610     void stopSpeaking();
611
612     bool isSmartInsertDeleteEnabled() const { return m_isSmartInsertDeleteEnabled; }
613 #endif
614
615 #if ENABLE(WEB_INTENTS)
616     void deliverIntentToFrame(uint64_t frameID, const IntentData&);
617 #endif
618
619     void replaceSelectionWithText(WebCore::Frame*, const String&);
620     void clearSelection();
621
622 #if ENABLE(DRAG_SUPPORT)
623 #if PLATFORM(WIN)
624     void performDragControllerAction(uint64_t action, WebCore::IntPoint clientPosition, WebCore::IntPoint globalPosition, uint64_t draggingSourceOperationMask, const WebCore::DragDataMap&, uint32_t flags);
625 #elif PLATFORM(QT) || PLATFORM(GTK)
626     void performDragControllerAction(uint64_t action, WebCore::DragData);
627 #else
628 #if ENABLE(TIZEN_DRAG_SUPPORT)
629     void performDragControllerAction(uint64_t action, WebCore::DragData);
630 #else
631     void performDragControllerAction(uint64_t action, WebCore::IntPoint clientPosition, WebCore::IntPoint globalPosition, uint64_t draggingSourceOperationMask, const WTF::String& dragStorageName, uint32_t flags, const SandboxExtension::Handle&, const SandboxExtension::HandleArray&);
632 #endif
633 #endif
634     void dragEnded(WebCore::IntPoint clientPosition, WebCore::IntPoint globalPosition, uint64_t operation);
635
636     void willPerformLoadDragDestinationAction();
637     void mayPerformUploadDragDestinationAction();
638 #endif // ENABLE(DRAG_SUPPORT)
639
640     void beginPrinting(uint64_t frameID, const PrintInfo&);
641     void endPrinting();
642     void computePagesForPrinting(uint64_t frameID, const PrintInfo&, uint64_t callbackID);
643 #if PLATFORM(MAC) || PLATFORM(WIN)
644     void drawRectToPDF(uint64_t frameID, const PrintInfo&, const WebCore::IntRect&, uint64_t callbackID);
645     void drawPagesToPDF(uint64_t frameID, const PrintInfo&, uint32_t first, uint32_t count, uint64_t callbackID);
646 #elif PLATFORM(GTK)
647     void drawPagesForPrinting(uint64_t frameID, const PrintInfo&, uint64_t callbackID);
648 #endif
649
650 #if ENABLE(TIZEN_SUPPORT_WEBAPP_META_TAG)
651     void getWebAppCapable(uint64_t callbackID);
652     void getWebAppIconURL(uint64_t callbackID);
653     void getWebAppIconURLs(uint64_t callbackID);
654 #endif
655
656     void setMediaVolume(float);
657
658     bool mainFrameHasCustomRepresentation() const;
659
660     void didChangeScrollOffsetForMainFrame();
661
662     void mainFrameDidLayout();
663
664     bool canRunBeforeUnloadConfirmPanel() const { return m_canRunBeforeUnloadConfirmPanel; }
665     void setCanRunBeforeUnloadConfirmPanel(bool canRunBeforeUnloadConfirmPanel) { m_canRunBeforeUnloadConfirmPanel = canRunBeforeUnloadConfirmPanel; }
666
667     bool canRunModal() const { return m_canRunModal; }
668     void setCanRunModal(bool canRunModal) { m_canRunModal = canRunModal; }
669
670     void runModal();
671
672     void setDeviceScaleFactor(float);
673     float deviceScaleFactor() const;
674
675     void setMemoryCacheMessagesEnabled(bool);
676
677     void forceRepaintWithoutCallback();
678
679     void unmarkAllMisspellings();
680     void unmarkAllBadGrammar();
681 #if PLATFORM(MAC) && __MAC_OS_X_VERSION_MIN_REQUIRED >= 1070
682     void handleAlternativeTextUIResult(const String&);
683 #endif
684
685     // For testing purpose.
686     void simulateMouseDown(int button, WebCore::IntPoint, int clickCount, WKEventModifiers, double time);
687     void simulateMouseUp(int button, WebCore::IntPoint, int clickCount, WKEventModifiers, double time);
688     void simulateMouseMotion(WebCore::IntPoint, double time);
689
690 #if ENABLE(CONTEXT_MENUS)
691     void contextMenuShowing() { m_isShowingContextMenu = true; }
692 #endif
693
694 #if PLATFORM(QT)
695     void registerApplicationScheme(const String& scheme);
696     void applicationSchemeReply(const QtNetworkReplyData&);
697     void receivedApplicationSchemeRequest(const QNetworkRequest&, QtNetworkReply*);
698     void setUserScripts(const Vector<String>&);
699 #endif
700     void wheelEvent(const WebWheelEvent&);
701 #if ENABLE(GESTURE_EVENTS)
702     void gestureEvent(const WebGestureEvent&);
703 #endif
704
705     void numWheelEventHandlersChanged(unsigned);
706     void recomputeShortCircuitHorizontalWheelEventsState();
707
708     bool willGoToBackForwardItemCallbackEnabled() const { return m_willGoToBackForwardItemCallbackEnabled; }
709
710 #if ENABLE(PAGE_VISIBILITY_API)
711     void setVisibilityState(int visibilityState, bool isInitialState);
712 #endif
713
714 #if ENABLE(TIZEN_INPUT_TAG_EXTENSION) || ENABLE(TIZEN_WEBKIT2_FORM_DATABASE)
715     void setFocusedInputElementValue(const String& inputValue);
716     void getFocusedInputElementValue(String& inputValue);
717 #endif
718
719 #if ENABLE(TIZEN_DATALIST_ELEMENT)
720     void getFocusedInputElementDataList(Vector<String>&);
721 #endif
722
723 #if ENABLE(TIZEN_CSS_OVERFLOW_SCROLL_ACCELERATION)
724     void scrollOverflow(const WebCore::FloatPoint&, bool& scrolled);
725     void setPressedNodeAtPoint(const WebCore::IntPoint&, bool checkOverflowLayer, bool& pressed, uint32_t& id);
726 #endif
727
728 #if ENABLE(TIZEN_CSS_OVERFLOW_SCROLL_ACCELERATION_ON_UI_SIDE)
729     void scrollOverflowWithTrajectoryVector(const WebCore::FloatPoint&);
730 #endif
731
732 #if ENABLE(TIZEN_CUSTOM_HEADERS)
733     void addCustomHeader(const String& name, const String& value);
734     void removeCustomHeader(const String& name);
735     void clearCustomHeaders();
736     WebCore::HTTPHeaderMap customHeaders();
737 #endif
738
739 #if ENABLE(TIZEN_WEBKIT2_GET_TEXT_STYLE_FOR_SELECTION)
740     void getTextStyleStateForSelection();
741 #endif
742
743 #if PLATFORM(GTK) && USE(TEXTURE_MAPPER_GL)
744     uint64_t nativeWindowHandle() { return m_nativeWindowHandle; }
745 #endif
746
747 #if ENABLE(TIZEN_MULTIPLE_SELECT)
748     void didChangeSelectedIndexForActivePopupMenuMultiple(Vector<int32_t>);
749 #endif
750
751 #if ENABLE(TIZEN_LINK_MAGNIFIER)
752     void getLinkMagnifierRect(const WebCore::IntPoint&, const WebCore::IntSize&);
753 #endif
754
755 #if ENABLE(TIZEN_SCREEN_READER)
756     void raiseTapEvent(const WebCore::IntPoint&, const WebCore::IntPoint&);
757     void moveScreenReaderFocus(bool, bool&);
758     void moveScreenReaderFocusByPoint(const WebCore::IntPoint&);
759     void recalcScreenReaderFocusRect();
760     void updateScreenReaderFocus(WebCore::RenderObject*);
761     void clearScreenReader();
762 #endif
763
764 #if ENABLE(TIZEN_WEBKIT2_POPUP_INTERNAL)
765     void notifyTransitionToCommitted(bool);
766 #endif
767
768 #if ENABLE(TIZEN_CSP)
769     void setContentSecurityPolicy(const String& policy, uint32_t headerType);
770 #endif
771
772 #if ENABLE(TIZEN_INDEXED_DATABASE)
773     void setIndexedDatabaseDirectory(const String& path);
774 #endif
775
776 #if ENABLE(TIZEN_WEB_STORAGE)
777     void setLocalStorageDirectory(const String& path);
778 #endif
779
780 private:
781     WebPage(uint64_t pageID, const WebPageCreationParameters&);
782
783     virtual Type type() const { return APIType; }
784
785     void platformInitialize();
786
787     void didReceiveWebPageMessage(CoreIPC::Connection*, CoreIPC::MessageID, CoreIPC::ArgumentDecoder*);
788     void didReceiveSyncWebPageMessage(CoreIPC::Connection*, CoreIPC::MessageID, CoreIPC::ArgumentDecoder*, OwnPtr<CoreIPC::ArgumentEncoder>&);
789
790 #if !PLATFORM(MAC)
791     static const char* interpretKeyEvent(const WebCore::KeyboardEvent*);
792 #endif
793     bool performDefaultBehaviorForKeyEvent(const WebKeyboardEvent&);
794
795 #if PLATFORM(MAC)
796     bool executeKeypressCommandsInternal(const Vector<WebCore::KeypressCommand>&, WebCore::KeyboardEvent*);
797 #endif
798
799     String sourceForFrame(WebFrame*);
800
801     void loadData(PassRefPtr<WebCore::SharedBuffer>, const String& MIMEType, const String& encodingName, const WebCore::KURL& baseURL, const WebCore::KURL& failingURL);
802
803     bool platformHasLocalDataForURL(const WebCore::KURL&);
804
805     // Actions
806     void tryClose();
807     void loadURL(const String&, const SandboxExtension::Handle&);
808     void loadURLRequest(const WebCore::ResourceRequest&, const SandboxExtension::Handle&);
809     void loadHTMLString(const String& htmlString, const String& baseURL);
810     void loadAlternateHTMLString(const String& htmlString, const String& baseURL, const String& unreachableURL);
811     void loadPlainTextString(const String&);
812     void loadWebArchiveData(const CoreIPC::DataReference&);
813 #if OS(TIZEN)
814     void loadContentsbyMimeType(const CoreIPC::DataReference&, const String& mimeType, const String& encoding, const String& baseURL);
815 #endif
816     void linkClicked(const String& url, const WebMouseEvent&);
817     void reload(bool reloadFromOrigin, const SandboxExtension::Handle&);
818     void goForward(uint64_t);
819     void goBack(uint64_t);
820     void goToBackForwardItem(uint64_t);
821     void tryRestoreScrollPosition();
822     void setActive(bool);
823     void setFocused(bool);
824     void setInitialFocus(bool forward, bool isKeyboardEventValid, const WebKeyboardEvent&);
825     void setWindowResizerSize(const WebCore::IntSize&);
826     void setIsInWindow(bool);
827     void validateCommand(const String&, uint64_t);
828     void executeEditCommand(const String&);
829 #if OS(TIZEN)
830     void executeEditCommandWithArgument(const String& command, const String& argument);
831 #endif
832
833     void mouseEvent(const WebMouseEvent&);
834     void mouseEventSyncForTesting(const WebMouseEvent&, bool&);
835     void wheelEventSyncForTesting(const WebWheelEvent&, bool&);
836 #if ENABLE(TIZEN_ISF_PORT)
837     void keyEvent(const NativeWebKeyboardEvent&);
838 #else
839     void keyEvent(const WebKeyboardEvent&);
840 #endif
841     void keyEventSyncForTesting(const WebKeyboardEvent&, bool&);
842 #if ENABLE(TOUCH_EVENTS)
843     void touchEvent(const WebTouchEvent&);
844     void touchEventSyncForTesting(const WebTouchEvent&, bool& handled);
845 #if PLATFORM(QT)
846     void highlightPotentialActivation(const WebCore::IntPoint&, const WebCore::IntSize& area);
847 #endif
848 #endif
849 #if ENABLE(CONTEXT_MENUS)
850     void contextMenuHidden() { m_isShowingContextMenu = false; }
851 #endif
852
853     static void scroll(WebCore::Page*, WebCore::ScrollDirection, WebCore::ScrollGranularity);
854     static void logicalScroll(WebCore::Page*, WebCore::ScrollLogicalDirection, WebCore::ScrollGranularity);
855
856     uint64_t restoreSession(const SessionState&);
857     void restoreSessionAndNavigateToCurrentItem(const SessionState&);
858
859     void didRemoveBackForwardItem(uint64_t);
860
861     void setWillGoToBackForwardItemCallbackEnabled(bool enabled) { m_willGoToBackForwardItemCallbackEnabled = enabled; }
862     
863     void setDrawsBackground(bool);
864     void setDrawsTransparentBackground(bool);
865
866     void viewWillStartLiveResize();
867     void viewWillEndLiveResize();
868
869     void getContentsAsString(uint64_t callbackID);
870 #if ENABLE(MHTML)
871     void getContentsAsMHTMLData(uint64_t callbackID, bool useBinaryEncoding);
872 #endif
873     void getMainResourceDataOfFrame(uint64_t frameID, uint64_t callbackID);
874     void getResourceDataFromFrame(uint64_t frameID, const String& resourceURL, uint64_t callbackID);
875     void getRenderTreeExternalRepresentation(uint64_t callbackID);
876     void getSelectionOrContentsAsString(uint64_t callbackID);
877     void getSourceForFrame(uint64_t frameID, uint64_t callbackID);
878     void getWebArchiveOfFrame(uint64_t frameID, uint64_t callbackID);
879     void runJavaScriptInMainFrame(const String&, uint64_t callbackID);
880     void forceRepaint(uint64_t callbackID);
881
882     void preferencesDidChange(const WebPreferencesStore&);
883     void platformPreferencesDidChange(const WebPreferencesStore&);
884     void updatePreferences(const WebPreferencesStore&);
885
886     void didReceivePolicyDecision(uint64_t frameID, uint64_t listenerID, uint32_t policyAction, uint64_t downloadID);
887     void setUserAgent(const String&);
888     void setCustomTextEncodingName(const String&);
889     void suspendActiveDOMObjectsAndAnimations();
890     void resumeActiveDOMObjectsAndAnimations();
891
892 #if PLATFORM(MAC)
893     void performDictionaryLookupAtLocation(const WebCore::FloatPoint&);
894     void performDictionaryLookupForRange(DictionaryPopupInfo::Type, WebCore::Frame*, WebCore::Range*, NSDictionary *options);
895
896     void setWindowIsVisible(bool windowIsVisible);
897     void windowAndViewFramesChanged(const WebCore::IntRect& windowFrameInScreenCoordinates, const WebCore::IntRect& viewFrameInWindowCoordinates, const WebCore::IntPoint& accessibilityViewCoordinates);
898
899     RetainPtr<PDFDocument> pdfDocumentForPrintingFrame(WebCore::Frame*);
900     void computePagesForPrintingPDFDocument(uint64_t frameID, const PrintInfo&, Vector<WebCore::IntRect>& resultPageRects);
901     void drawRectToPDFFromPDFDocument(CGContextRef, PDFDocument *, const PrintInfo&, const WebCore::IntRect&);
902     void drawPagesToPDFFromPDFDocument(CGContextRef, PDFDocument *, const PrintInfo&, uint32_t first, uint32_t count);
903 #endif
904
905     void unapplyEditCommand(uint64_t commandID);
906     void reapplyEditCommand(uint64_t commandID);
907     void didRemoveEditCommand(uint64_t commandID);
908
909     void findString(const String&, uint32_t findOptions, uint32_t maxMatchCount);
910     void findStringMatches(const String&, uint32_t findOptions, uint32_t maxMatchCount);
911     void getImageForFindMatch(uint32_t matchIndex);
912     void selectFindMatch(uint32_t matchIndex);
913     void hideFindUI();
914     void countStringMatches(const String&, uint32_t findOptions, uint32_t maxMatchCount);
915
916 #if PLATFORM(QT) || OS(TIZEN)
917     void findZoomableAreaForPoint(const WebCore::IntPoint&, const WebCore::IntSize& area);
918 #endif
919
920     void didChangeSelectedIndexForActivePopupMenu(int32_t newIndex);
921     void setTextForActivePopupMenu(int32_t index);
922
923 #if PLATFORM(GTK)
924     void failedToShowPopupMenu();
925 #endif
926 #if PLATFORM(QT)
927     void hidePopupMenu();
928     void selectedIndex(int32_t newIndex);
929 #endif
930
931     void didChooseFilesForOpenPanel(const Vector<String>&);
932     void didCancelForOpenPanel();
933 #if ENABLE(WEB_PROCESS_SANDBOX)
934     void extendSandboxForFileFromOpenPanel(const SandboxExtension::Handle&);
935 #endif
936
937     void didReceiveGeolocationPermissionDecision(uint64_t geolocationID, bool allowed);
938
939     void didReceiveNotificationPermissionDecision(uint64_t notificationID, bool allowed);
940 #if ENABLE(TIZEN_MEDIA_STREAM)
941     void didReceiveUserMediaPermissionDecision(uint64_t userMediaID, bool allowed);
942 #endif
943
944     void advanceToNextMisspelling(bool startBeforeSelection);
945     void changeSpellingToWord(const String& word);
946 #if USE(APPKIT)
947     void uppercaseWord();
948     void lowercaseWord();
949     void capitalizeWord();
950 #endif
951
952 #if PLATFORM(MAC)
953     void setSmartInsertDeleteEnabled(bool isSmartInsertDeleteEnabled) { m_isSmartInsertDeleteEnabled = isSmartInsertDeleteEnabled; }
954 #endif
955
956 #if ENABLE(CONTEXT_MENUS)
957     void didSelectItemFromActiveContextMenu(const WebContextMenuItemData&);
958 #endif
959
960     void changeSelectedIndex(int32_t index);
961     void setCanStartMediaTimerFired();
962
963     static bool platformCanHandleRequest(const WebCore::ResourceRequest&);
964 #if ENABLE(TIZEN_NATIVE_MEMORY_SNAPSHOT)
965     void dumpMemorySnapshot();
966 #endif
967     OwnPtr<WebCore::Page> m_page;
968     RefPtr<WebFrame> m_mainFrame;
969     RefPtr<InjectedBundleBackForwardList> m_backForwardList;
970
971     RefPtr<WebPageGroupProxy> m_pageGroup;
972
973     String m_userAgent;
974
975     WebCore::IntSize m_viewSize;
976     OwnPtr<DrawingArea> m_drawingArea;
977
978     HashSet<PluginView*> m_pluginViews;
979
980     bool m_useFixedLayout;
981
982     bool m_drawsBackground;
983     bool m_drawsTransparentBackground;
984
985     bool m_isInRedo;
986     bool m_isClosed;
987
988     bool m_tabToLinks;
989 #if ENABLE(TIZEN_CUSTOM_HEADERS)
990     WebCore::HTTPHeaderMap m_customHeaders;
991 #endif
992
993 #if PLATFORM(MAC)
994     // Whether the containing window is visible or not.
995     bool m_windowIsVisible;
996
997     // Whether smart insert/delete is enabled or not.
998     bool m_isSmartInsertDeleteEnabled;
999
1000     // The frame of the containing window in screen coordinates.
1001     WebCore::IntRect m_windowFrameInScreenCoordinates;
1002
1003     // The frame of the view in window coordinates.
1004     WebCore::IntRect m_viewFrameInWindowCoordinates;
1005
1006     // The accessibility position of the view.
1007     WebCore::IntPoint m_accessibilityPosition;
1008     
1009     // The layer hosting mode.
1010     LayerHostingMode m_layerHostingMode;
1011
1012     RetainPtr<WKAccessibilityWebPageObject> m_mockAccessibilityElement;
1013
1014     WebCore::KeyboardEvent* m_keyboardEventBeingInterpreted;
1015
1016 #elif PLATFORM(WIN)
1017     // Our view's window (in the UI process).
1018     HWND m_nativeWindow;
1019
1020     RefPtr<WebCore::Node> m_gestureTargetNode;
1021 #elif PLATFORM(GTK)
1022     WebPageAccessibilityObject* m_accessibilityObject;
1023
1024 #if USE(TEXTURE_MAPPER_GL)
1025     // Our view's window in the UI process.
1026     uint64_t m_nativeWindowHandle;
1027 #endif
1028 #endif
1029     
1030     WebCore::RunLoop::Timer<WebPage> m_setCanStartMediaTimer;
1031
1032     HashMap<uint64_t, RefPtr<WebUndoStep> > m_undoStepMap;
1033
1034     WebCore::IntSize m_windowResizerSize;
1035
1036 #if ENABLE(CONTEXT_MENUS)
1037     InjectedBundlePageContextMenuClient m_contextMenuClient;
1038 #endif
1039     InjectedBundlePageEditorClient m_editorClient;
1040     InjectedBundlePageFormClient m_formClient;
1041     InjectedBundlePageLoaderClient m_loaderClient;
1042     InjectedBundlePagePolicyClient m_policyClient;
1043     InjectedBundlePageResourceLoadClient m_resourceLoadClient;
1044     InjectedBundlePageUIClient m_uiClient;
1045 #if ENABLE(FULLSCREEN_API)
1046     InjectedBundlePageFullScreenClient m_fullScreenClient;
1047 #endif
1048     InjectedBundlePageDiagnosticLoggingClient m_logDiagnosticMessageClient;
1049
1050 #if USE(TILED_BACKING_STORE)
1051     WebCore::IntSize m_viewportSize;
1052 #endif
1053
1054     FindController m_findController;
1055 #if ENABLE(TOUCH_EVENTS) && PLATFORM(QT)
1056     TapHighlightController m_tapHighlightController;
1057 #endif
1058     RefPtr<PageOverlay> m_pageOverlay;
1059
1060     RefPtr<WebPage> m_underlayPage;
1061
1062 #if ENABLE(INSPECTOR)
1063     RefPtr<WebInspector> m_inspector;
1064 #endif
1065 #if ENABLE(FULLSCREEN_API)
1066     RefPtr<WebFullScreenManager> m_fullScreenManager;
1067 #endif
1068     RefPtr<WebPopupMenu> m_activePopupMenu;
1069 #if ENABLE(CONTEXT_MENUS)
1070     RefPtr<WebContextMenu> m_contextMenu;
1071 #endif
1072 #if ENABLE(INPUT_TYPE_COLOR)
1073     WebColorChooser* m_activeColorChooser;
1074 #endif
1075     RefPtr<WebOpenPanelResultListener> m_activeOpenPanelResultListener;
1076     RefPtr<NotificationPermissionRequestManager> m_notificationPermissionRequestManager;
1077 #if ENABLE(TIZEN_MEDIA_STREAM)
1078     RefPtr<UserMediaPermissionRequestManager> m_userMediaPermissionRequestManager;
1079 #endif
1080
1081 #if ENABLE(GEOLOCATION)
1082     GeolocationPermissionRequestManager m_geolocationPermissionRequestManager;
1083 #endif
1084
1085     OwnPtr<WebCore::PrintContext> m_printContext;
1086 #if PLATFORM(GTK)
1087     RefPtr<WebPrintOperationGtk> m_printOperation;
1088 #endif
1089
1090     SandboxExtensionTracker m_sandboxExtensionTracker;
1091     uint64_t m_pageID;
1092
1093     RefPtr<SandboxExtension> m_pendingDropSandboxExtension;
1094     Vector<RefPtr<SandboxExtension> > m_pendingDropExtensionsForFileUpload;
1095
1096     bool m_canRunBeforeUnloadConfirmPanel;
1097
1098     bool m_canRunModal;
1099     bool m_isRunningModal;
1100
1101     bool m_cachedMainFrameIsPinnedToLeftSide;
1102     bool m_cachedMainFrameIsPinnedToRightSide;
1103     bool m_canShortCircuitHorizontalWheelEvents;
1104     unsigned m_numWheelEventHandlers;
1105
1106     unsigned m_cachedPageCount;
1107
1108 #if ENABLE(CONTEXT_MENUS)
1109     bool m_isShowingContextMenu;
1110 #endif
1111     
1112     bool m_willGoToBackForwardItemCallbackEnabled;
1113
1114 #if PLATFORM(WIN)
1115     bool m_gestureReachedScrollingLimit;
1116 #endif
1117
1118 #if PLATFORM(QT)
1119     HashMap<String, QtNetworkReply*> m_applicationSchemeReplies;
1120 #endif
1121 #if ENABLE(PAGE_VISIBILITY_API)
1122     WebCore::PageVisibilityState m_visibilityState;
1123 #endif
1124 #if ENABLE(TIZEN_RECORDING_SURFACE_SET)
1125     bool m_recordingSurfaceSetEnable;
1126     bool m_recordingSurfaceSetLoadStart;
1127     bool m_recordingSurfaceSetLoadFinished;
1128     bool m_recordingSurfaceSetSettings;
1129 #endif
1130 #if ENABLE(TIZEN_SYNC_REQUEST_ANIMATION_FRAME)
1131     bool m_suspendedAnimationController;
1132 #endif
1133
1134     WebInspectorClient* m_inspectorClient;
1135
1136 #if ENABLE(TIZEN_SCREEN_READER)
1137     OwnPtr<ScreenReader> m_screenReader;
1138 #endif
1139
1140 #if ENABLE(TIZEN_ISF_PORT)
1141     bool m_isSettingComposition;
1142 #endif
1143 };
1144
1145 #if ENABLE(TIZEN_NATIVE_MEMORY_SNAPSHOT)
1146 void dumpMemorySnapshot();
1147 #endif
1148
1149 } // namespace WebKit
1150
1151 #endif // WebPage_h