Change Tizen version in the default User Agent.
[framework/web/webkit-efl.git] / Source / WebKit2 / UIProcess / efl / WebPageProxyEfl.cpp
1 /*
2  * Copyright (C) 2011 Samsung Electronics
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 #include "config.h"
27 #include "WebPageProxy.h"
28
29 #include "EwkViewImpl.h"
30 #include "NativeWebKeyboardEvent.h"
31 #include "NotImplemented.h"
32 #include "PageClientImpl.h"
33 #include "WebPageMessages.h"
34 #include "WebProcessProxy.h"
35
36 #include <sys/utsname.h>
37
38 #if OS(TIZEN)
39 #include "DrawingAreaMessages.h"
40
41 #if ENABLE(TIZEN_CSS_OVERFLOW_SCROLL_ACCELERATION_ON_UI_SIDE)
42 #include "LayerTreeCoordinatorProxy.h"
43 #endif
44 #include "NativeWebKeyboardEvent.h"
45 #include "WebImage.h"
46 #include "WebPageMessages.h"
47 #include "WebProcessProxy.h"
48 #include <WebCore/IntSize.h>
49 #if ENABLE(TIZEN_CONTEXT_MENU_WEBKIT_2)
50 #include "WebContextMenuProxy.h"
51 #include "ewk_view_private.h"
52 #endif
53
54 #define MESSAGE_CHECK(assertion) MESSAGE_CHECK_BASE(assertion, m_process->connection())
55
56 #if ENABLE(TIZEN_LINK_MAGNIFIER)
57 #include "LinkMagnifierProxy.h"
58 #endif
59
60 #if ENABLE(TIZEN_SCREEN_READER)
61 #include "ScreenReaderProxy.h"
62 #include "ewk_view_private.h"
63 #endif
64
65 #if ENABLE(TIZEN_CSP)
66 #include <WebCore/ContentSecurityPolicy.h>
67 #endif
68
69 using namespace WebCore;
70 #endif
71
72 namespace WebKit {
73
74 Evas_Object* WebPageProxy::viewWidget()
75 {
76     return static_cast<PageClientImpl*>(m_pageClient)->viewImpl()->view();
77 }
78
79 String WebPageProxy::standardUserAgent(const String& applicationNameForUserAgent)
80 {
81 #if OS(TIZEN)
82     return String::fromUTF8("Mozilla/5.0 (Linux; Tizen 2.2; sdk) AppleWebKit/537.3 (KHTML, like Gecko) Version/2.2 Mobile Safari/537.3");
83 #endif
84
85     WTF::String platform;
86     WTF::String version;
87     WTF::String osVersion;
88
89 #if PLATFORM(X11)
90     platform = "X11";
91 #else
92     platform = "Unknown";
93 #endif
94     version = makeString(String::number(WEBKIT_USER_AGENT_MAJOR_VERSION), '.',
95                          String::number(WEBKIT_USER_AGENT_MINOR_VERSION), '+');
96     struct utsname name;
97     if (uname(&name) != -1)
98         osVersion = WTF::String(name.sysname) + " " + WTF::String(name.machine);
99     else
100         osVersion = "Unknown";
101
102     if (applicationNameForUserAgent.isEmpty())
103         return makeString("Mozilla/5.0 (", platform, "; ", osVersion, ") AppleWebKit/", version,
104                " (KHTML, like Gecko) Version/5.0 Safari/", version);
105
106     return makeString("Mozilla/5.0 (", platform, "; ", osVersion, ") AppleWebKit/", version,
107            " (KHTML, like Gecko) Version/5.0 Safari/", version, applicationNameForUserAgent);
108 }
109
110 void WebPageProxy::getEditorCommandsForKeyEvent(Vector<WTF::String>& commandsList)
111 {
112     notImplemented();
113 }
114
115 void WebPageProxy::saveRecentSearches(const String&, const Vector<String>&)
116 {
117     notImplemented();
118 }
119
120 void WebPageProxy::loadRecentSearches(const String&, Vector<String>&)
121 {
122     notImplemented();
123 }
124
125 void WebPageProxy::setThemePath(const String& themePath)
126 {
127     process()->send(Messages::WebPage::SetThemePath(themePath), m_pageID, 0);
128 }
129
130 #if ENABLE(TIZEN_CUSTOM_HEADERS)
131 void WebPageProxy::addCustomHeader(const String& name, const String& value)
132 {
133     if (name.isEmpty())
134         return;
135
136     if (value.isEmpty())
137         return;
138
139     if (!isValid())
140         return;
141
142     process()->send(Messages::WebPage::AddCustomHeader(name, value), m_pageID);
143 }
144
145 void WebPageProxy::removeCustomHeader(const String& name)
146 {
147     if (name.isEmpty())
148         return;
149
150     if (!isValid())
151         return;
152
153     process()->send(Messages::WebPage::RemoveCustomHeader(name), m_pageID);
154 }
155
156 void WebPageProxy::clearCustomHeaders()
157 {
158     if (!isValid())
159         return;
160
161     process()->send(Messages::WebPage::ClearCustomHeaders(), m_pageID);
162 }
163 #endif
164
165 #if OS(TIZEN)
166 bool WebPageProxy::scrollMainFrameBy(const IntSize& scrollOffset)
167 {
168 #if ENABLE(TIZEN_WEBKIT2_TILED_BACKING_STORE)
169     return static_cast<PageClientImpl*>(m_pageClient)->scrollBy(scrollOffset);
170 #else
171     if (!isValid())
172         return false;
173
174     process()->send(Messages::WebPage::ScrollMainFrameBy(scrollOffset), m_pageID);
175     return true;
176 #endif
177 }
178
179 void WebPageProxy::scrollMainFrameTo(const IntPoint& scrollPosition)
180 {
181 #if ENABLE(TIZEN_WEBKIT2_TILED_BACKING_STORE)
182     static_cast<PageClientImpl*>(m_pageClient)->scrollTo(scrollPosition);
183 #else
184     if (!isValid())
185         return;
186
187     process()->send(Messages::WebPage::ScrollMainFrameTo(scrollPosition), m_pageID);
188 #endif
189 }
190
191 void WebPageProxy::didChangeScrollPositionForMainFrame(const IntPoint& scrollPosition)
192 {
193 #if !ENABLE(TIZEN_WEBKIT2_TILED_BACKING_STORE)
194     m_scrollPosition = scrollPosition;
195 #endif
196 }
197
198 void WebPageProxy::didChangeContentsSize(const IntSize& size)
199 {
200     if (m_contentsSize == size)
201         return;
202
203     m_contentsSize = size;
204     m_pageClient->didChangeContentsSize(size);
205 }
206
207 PassRefPtr<WebImage> WebPageProxy::createSnapshot(const IntRect& rect, float scaleFactor)
208 {
209     if (!isValid())
210         return 0;
211
212     ShareableBitmap::Handle snapshotHandle;
213     // Do not wait for more than a second (arbitrary) for the WebProcess to get the snapshot so
214     // that the UI Process is not permanently stuck waiting on a potentially crashing Web Process.
215     static const double createSnapshotSyncMessageTimeout = 1.0;
216 #if ENABLE(TIZEN_WEBKIT2_TILED_BACKING_STORE)
217     float baseScaleFactor = static_cast<PageClientImpl*>(m_pageClient)->scaleFactor();
218     scaleFactor = scaleFactor * baseScaleFactor;
219
220     IntRect visibleContentRect = static_cast<PageClientImpl*>(m_pageClient)->visibleContentRect();
221     IntRect scaledRect = rect;
222     scaledRect.move(visibleContentRect.x(), visibleContentRect.y());
223     scaledRect.scale(1/baseScaleFactor);
224     process()->sendSync(Messages::WebPage::CreateSnapshot(scaledRect, scaleFactor), Messages::WebPage::CreateSnapshot::Reply(snapshotHandle), m_pageID, createSnapshotSyncMessageTimeout);
225 #else
226     process()->sendSync(Messages::WebPage::CreateSnapshot(rect, scaleFactor), Messages::WebPage::CreateSnapshot::Reply(snapshotHandle), m_pageID, createSnapshotSyncMessageTimeout);
227 #endif
228     if (snapshotHandle.isNull())
229         return 0;
230     return WebImage::create(ShareableBitmap::create(snapshotHandle));
231 }
232
233 #if ENABLE(TIZEN_WEBKIT2_FORM_DATABASE)
234 void WebPageProxy::textChangeInTextField(const String& name, const String& value)
235 {
236     static_cast<PageClientImpl*>(m_pageClient)->textChangeInTextField(name, value);
237 }
238 #endif
239
240 #if ENABLE(TIZEN_ISF_PORT)
241 int WebPageProxy::getCursorOffset()
242 {
243     if (!isValid())
244         return 0;
245
246     int offset = 0;
247     process()->sendSync(Messages::WebPage::GetCursorOffset(), Messages::WebPage::GetCursorOffset::Reply(offset), m_pageID);
248     return offset;
249 }
250
251 void WebPageProxy::getSurroundingTextAndCursorOffset(String& text, int& offset)
252 {
253     if (!isValid())
254         return;
255
256     process()->sendSync(Messages::WebPage::GetSurroundingTextAndCursorOffset(), Messages::WebPage::GetSurroundingTextAndCursorOffset::Reply(text, offset), m_pageID);
257 }
258
259 IntRect WebPageProxy::getSelectionRect(bool isOnlyEditable)
260 {
261     IntRect rect;
262     process()->sendSync(Messages::WebPage::GetSelectionRect(isOnlyEditable), Messages::WebPage::GetSelectionRect::Reply(rect), m_pageID);
263     return rect;
264 }
265
266 void WebPageProxy::deleteSurroundingText(int offset, int count)
267 {
268     if (!isValid())
269         return;
270
271     process()->send(Messages::WebPage::DeleteSurroundingText(offset, count), m_pageID);
272 }
273
274 void WebPageProxy::didCancelComposition()
275 {
276     m_didCancelCompositionFromWebProcess = true;
277     InputMethodContextEfl* inputMethodContext = static_cast<PageClientImpl*>(m_pageClient)->viewImpl()->inputMethodContext();
278     if (inputMethodContext)
279         inputMethodContext->resetIMFContext();
280     m_didCancelCompositionFromWebProcess = false;
281 }
282
283 void WebPageProxy::removeInputMethodContext(uintptr_t id)
284 {
285     InputMethodContextEfl* inputMethodContext = static_cast<PageClientImpl*>(m_pageClient)->viewImpl()->inputMethodContext();
286     if (!inputMethodContext)
287         return;
288
289     inputMethodContext->removeIMFContext(id);
290 }
291 #endif // #if ENABLE(TIZEN_ISF_PORT)
292
293 void WebPageProxy::requestUpdateFormNavigation()
294 {
295     if (!isValid())
296         return;
297
298     process()->send(Messages::WebPage::RequestUpdateFormNavigation(), m_pageID);
299 }
300
301 void WebPageProxy::moveFocus(int newIndex)
302 {
303     if (!isValid())
304         return;
305
306     process()->send(Messages::WebPage::MoveFocus(newIndex), m_pageID);
307 }
308
309 void WebPageProxy::updateFormNavigation(int length, int offset)
310 {
311     static_cast<PageClientImpl*>(m_pageClient)->updateFormNavigation(length, offset);
312 }
313
314 #if ENABLE(TIZEN_REDUCE_KEY_LAGGING)
315 Eina_Bool WebPageProxy::pageContentResumeTimerFired(void* data)
316 {
317     static_cast<WebPageProxy*>(data)->resumeActiveDOMObjectsAndAnimations();
318     static_cast<WebPageProxy*>(data)->m_pageContentResumeTimer = 0;
319     return ECORE_CALLBACK_CANCEL;
320 }
321 #endif
322
323 #if ENABLE(TIZEN_TEXT_CARET_HANDLING_WK2)
324 void WebPageProxy::setCaretPosition(const WebCore::IntPoint& pos)
325 {
326     if (!isValid())
327         return;
328
329     process()->send(Messages::WebPage::SetCaretPosition(pos), m_pageID);
330 }
331
332 void WebPageProxy::getCaretPosition(WebCore::IntRect& rect)
333 {
334     if (!isValid())
335         return;
336
337     process()->sendSync(Messages::WebPage::GetCaretPosition(), Messages::WebPage::GetCaretPosition::Reply(rect), m_pageID);
338 }
339 #endif
340
341 #if ENABLE(TIZEN_PLUGIN_CUSTOM_REQUEST)
342 void WebPageProxy::processPluginCustomRequest(const String& request, const String& msg)
343 {
344     if (String("requestKeyboard,plugin") == request) {
345         bool active = false;
346         if (String("show") == msg)
347             active = true;
348 #if ENABLE(TIZEN_ISF_PORT)
349         m_editorState = EditorState();
350         m_editorState.isContentEditable = active;
351         m_pageClient->updateTextInputState();
352 #endif
353     }
354 #if ENABLE(TIZEN_JSBRIDGE_PLUGIN)
355     else if (String("requestToNative,json") == request)
356         m_tizenClient.processJSBridgePlugin(this, request, msg);
357 #endif
358 }
359 #endif
360
361
362 #if ENABLE(TIZEN_INPUT_TAG_EXTENSION) || ENABLE(TIZEN_WEBKIT2_FORM_DATABASE)
363 void WebPageProxy::setFocusedInputElementValue(const String& inputValue)
364 {
365     if (!isValid())
366         return;
367
368     process()->send(Messages::WebPage::SetFocusedInputElementValue(inputValue), m_pageID);
369 }
370
371 String WebPageProxy::getFocusedInputElementValue()
372 {
373     if (!isValid())
374         return String();
375
376     String inputValue;
377     process()->sendSync(Messages::WebPage::GetFocusedInputElementValue(), Messages::WebPage::GetFocusedInputElementValue::Reply(inputValue), m_pageID);
378     return inputValue;
379 }
380 #endif
381
382 #if ENABLE(TIZEN_DATALIST_ELEMENT)
383 Vector<String> WebPageProxy::getFocusedInputElementDataList()
384 {
385     if (!isValid())
386         return Vector<String>();
387
388     Vector<String> optionList;
389     process()->sendSync(Messages::WebPage::GetFocusedInputElementDataList(), Messages::WebPage::GetFocusedInputElementDataList::Reply(optionList), m_pageID);
390     return optionList;
391 }
392 #endif
393
394 void WebPageProxy::focusedNodeChanged(const IntRect& focusedNodeRect)
395 {
396     static_cast<PageClientImpl*>(m_pageClient)->setFocusedNodeRect(focusedNodeRect);
397 }
398
399 void WebPageProxy::initializeTizenClient(const WKPageTizenClient* client)
400 {
401     m_tizenClient.initialize(client);
402 }
403
404 #if ENABLE(TIZEN_WEBKIT2_HIT_TEST)
405 WebHitTestResult::Data WebPageProxy::hitTestResultAtPoint(const IntPoint& point, int hitTestMode)
406 {
407     WebHitTestResult::Data hitTestResultData;
408     if (!isValid())
409         return hitTestResultData;
410
411     process()->sendSync(Messages::WebPage::HitTestResultAtPoint(point, hitTestMode),
412                         Messages::WebPage::HitTestResultAtPoint::Reply(hitTestResultData), m_pageID);
413
414     return hitTestResultData;
415 }
416 #endif
417
418 #if ENABLE(TIZEN_CONTEXT_MENU_WEBKIT_2)
419 void WebPageProxy::hideContextMenu()
420 {
421     if (m_activeContextMenu)
422         m_activeContextMenu->hideContextMenu();
423 }
424
425 String WebPageProxy::contextMenuAbsoluteLinkURLString()
426 {
427     if (!m_activeContextMenu)
428         return String();
429
430     return m_activeContextMenuHitTestResultData.absoluteLinkURL;
431 }
432
433 String WebPageProxy::contextMenuAbsoluteImageURLString()
434 {
435     if (!m_activeContextMenu)
436         return String();
437
438     return m_activeContextMenuHitTestResultData.absoluteImageURL;
439 }
440 #endif
441
442 #if ENABLE(TIZEN_WEBKIT2_CLIPBOARD_HELPER)
443 void WebPageProxy::pasteContextMenuSelected()
444 {
445     static_cast<PageClientImpl*>(m_pageClient)->pasteContextMenuSelected();
446 }
447
448 void WebPageProxy::didSelectPasteMenuFromContextMenu(const String& data, const String& type)
449 {
450     if (!isValid())
451         return;
452
453 #if ENABLE(TIZEN_CLIPBOARD) || ENABLE(TIZEN_PASTEBOARD)
454     process()->send(Messages::WebPage::SetClipboardDataForPaste(data, type), m_pageID);
455 #endif
456     WebContextMenuItemData item(ActionType, ContextMenuItemTagPaste, String("Paste"), true, false);
457     process()->send(Messages::WebPage::DidSelectItemFromActiveContextMenu(item), m_pageID);
458 }
459 #endif
460
461 #if ENABLE(TIZEN_CLIPBOARD) || ENABLE(TIZEN_PASTEBOARD)
462 void WebPageProxy::setClipboardData(const String& data, const String& type)
463 {
464     static_cast<PageClientImpl*>(m_pageClient)->setClipboardData(data, type);
465 }
466
467 void WebPageProxy::clearClipboardData()
468 {
469     static_cast<PageClientImpl*>(m_pageClient)->clearClipboardData();
470 }
471 #endif
472
473 #if ENABLE(TIZEN_WEBKIT2_CONTEXT_MENU_CLIPBOARD)
474 void WebPageProxy::executePasteFromClipboardItem(const String& data, const String& type)
475 {
476     if (!isValid())
477         return;
478
479 #if ENABLE(TIZEN_CLIPBOARD) || ENABLE(TIZEN_PASTEBOARD)
480     process()->send(Messages::WebPage::SetClipboardDataForPaste(data, type), m_pageID);
481 #endif
482     process()->send(Messages::WebPage::ExecuteEditCommandWithArgument("Paste", data), m_pageID);
483 }
484
485 void WebPageProxy::clipboardContextMenuSelected()
486 {
487     static_cast<PageClientImpl*>(m_pageClient)->clipboardContextMenuSelected();
488 }
489 #endif
490
491 #if ENABLE(TIZEN_REMOTE_WEB_INSPECTOR)
492 uint32_t WebPageProxy::startInspectorServer(uint32_t port)
493 {
494     if (!isValid())
495         return 0;
496
497     uint32_t assignedPort = 0;
498     process()->sendSync(Messages::WebPage::StartInspectorServer(port), Messages::WebPage::StartInspectorServer::Reply(assignedPort), m_pageID);
499     return assignedPort;
500 }
501
502 bool WebPageProxy::stopInspectorServer()
503 {
504     if (!isValid())
505         return false;
506
507     bool result = false;
508     process()->sendSync(Messages::WebPage::StopInspectorServer(), Messages::WebPage::StopInspectorServer::Reply(result), m_pageID);
509     return result;
510 }
511 #endif
512
513 #if ENABLE(TIZEN_MOBILE_WEB_PRINT)
514 void WebPageProxy::createPagesToPDF(const IntSize& surfaceSize, const IntSize& contentsSize, const String& fileName)
515 {
516     process()->send(Messages::WebPage::CreatePagesToPDF(surfaceSize, contentsSize, fileName), m_pageID);
517 }
518 #endif
519
520 #if ENABLE(TIZEN_WEB_STORAGE)
521 #if ENABLE(TIZEN_WEBKIT2_NUMBER_TYPE_SUPPORT)
522 void WebPageProxy::getWebStorageQuotaBytes(PassRefPtr<WebStorageQuotaCallback> prpCallback)
523 {
524     RefPtr<WebStorageQuotaCallback> callback = prpCallback;
525     if (!isValid()) {
526         callback->invalidate();
527         return;
528     }
529
530     uint64_t callbackID = callback->callbackID();
531     m_quotaCallbacks.set(callbackID, callback.get());
532     process()->send(Messages::WebPage::GetStorageQuotaBytes(callbackID), m_pageID);
533 }
534
535 void WebPageProxy::didGetWebStorageQuotaBytes(const uint32_t quota, uint64_t callbackID)
536 {
537     RefPtr<WebStorageQuotaCallback> callback = m_quotaCallbacks.take(callbackID);
538     if (!callback) {
539         // FIXME: Log error or assert.
540         // this can validly happen if a load invalidated the callback, though
541         return;
542     }
543
544     m_quotaCallbacks.remove(callbackID);
545
546     RefPtr<WebUInt32> uint32Object = WebUInt32::create(quota);
547     callback->performCallbackWithReturnValue(uint32Object.release().leakRef());
548 }
549 #endif
550
551 void WebPageProxy::setWebStorageQuotaBytes(uint32_t quota)
552 {
553     if (!isValid())
554         return;
555
556     process()->send(Messages::WebPage::SetStorageQuotaBytes(quota), m_pageID, 0);
557 }
558 #endif
559
560 void WebPageProxy::scale(double scaleFactor, const IntPoint& origin)
561 {
562 #if ENABLE(TIZEN_WEBKIT2_TILED_BACKING_STORE)
563     static_cast<PageClientImpl*>(m_pageClient)->scaleContents(scaleFactor, origin);
564 #else
565     scalePage(scaleFactor, origin);
566 #endif
567 }
568
569 void WebPageProxy::scaleImage(double scaleFactor, const IntPoint& origin)
570 {
571 #if ENABLE(TIZEN_WEBKIT2_TILED_BACKING_STORE)
572     static_cast<PageClientImpl*>(m_pageClient)->scaleImage(scaleFactor, origin);
573 #else
574     scalePage(scaleFactor, origin);
575 #endif
576 }
577
578 double WebPageProxy::scaleFactor()
579 {
580 #if ENABLE(TIZEN_WEBKIT2_TILED_BACKING_STORE)
581     return static_cast<PageClientImpl*>(m_pageClient)->scaleFactor();
582 #else
583     return pageScaleFactor();
584 #endif
585 }
586
587 #if ENABLE(TIZEN_ORIENTATION_EVENTS)
588 void WebPageProxy::sendOrientationChangeEvent(int orientation)
589 {
590     process()->send(Messages::WebPage::SendOrientationChangeEvent(orientation), m_pageID, 0);
591 }
592 #endif
593
594 void WebPageProxy::suspendPainting()
595 {
596     if (!isValid())
597         return;
598
599     process()->send(Messages::DrawingArea::SuspendPainting(), m_pageID);
600 }
601
602 void WebPageProxy::resumePainting()
603 {
604     if (!isValid())
605         return;
606
607     process()->send(Messages::DrawingArea::ResumePainting(), m_pageID);
608 }
609
610 void WebPageProxy::suspendJavaScriptAndResource()
611 {
612     if (!isValid())
613         return;
614
615     process()->send(Messages::WebPage::SuspendJavaScriptAndResources(), m_pageID);
616 }
617
618 void WebPageProxy::resumeJavaScriptAndResource()
619 {
620     if (!isValid())
621         return;
622
623     process()->send(Messages::WebPage::ResumeJavaScriptAndResources(), m_pageID);
624 }
625
626 void WebPageProxy::suspendAnimations()
627 {
628     if (!isValid())
629         return;
630
631     process()->send(Messages::WebPage::SuspendAnimations(), m_pageID);
632 }
633
634 void WebPageProxy::resumeAnimations()
635 {
636     if (!isValid())
637         return;
638
639     process()->send(Messages::WebPage::ResumeAnimations(), m_pageID);
640 }
641
642 #if ENABLE(TIZEN_PLUGIN_SUSPEND_RESUME)
643 void WebPageProxy::suspendPlugin()
644 {
645     if (!isValid())
646         return;
647
648     process()->send(Messages::WebPage::SuspendPlugin(), m_pageID);
649 }
650
651 void WebPageProxy::resumePlugin()
652 {
653     if (!isValid())
654         return;
655
656     process()->send(Messages::WebPage::ResumePlugin(), m_pageID);
657 }
658 #endif
659
660 #if ENABLE(TIZEN_WEBKIT2_TILED_AC)
661 void WebPageProxy::purgeBackingStoresOfInactiveView()
662 {
663     if (!isValid() || isViewVisible())
664         return;
665
666     process()->send(Messages::LayerTreeCoordinator::PurgeBackingStores(), m_pageID);
667 }
668 #endif
669
670 #if ENABLE(TIZEN_CSS_OVERFLOW_SCROLL_ACCELERATION)
671 bool WebPageProxy::scrollOverflow(const FloatPoint& offset)
672 {
673     if (!isValid())
674         return false;
675
676 #if ENABLE(TIZEN_CSS_OVERFLOW_SCROLL_ACCELERATION_ON_UI_SIDE)
677     if (static_cast<PageClientImpl*>(m_pageClient)->isScrollableLayerFocused())
678         return drawingArea()->layerTreeCoordinatorProxy()->setOffsetForFocusedScrollingContentsLayer(offset);
679 #endif
680     if (static_cast<PageClientImpl*>(m_pageClient)->isScrollableNodeFocused()) {
681         bool scrolled = false;
682         process()->sendSync(Messages::WebPage::ScrollOverflow(offset), Messages::WebPage::ScrollOverflow::Reply(scrolled), m_pageID);
683         return scrolled;
684     }
685
686     return false;
687 }
688
689 bool WebPageProxy::setPressedNodeAtPoint(const IntPoint& point, bool checkOverflowLayer, WebLayerID& webLayerID)
690 {
691     if (!isValid())
692         return false;
693
694     bool pressed = false;
695     process()->sendSync(Messages::WebPage::SetPressedNodeAtPoint(point, checkOverflowLayer), Messages::WebPage::SetPressedNodeAtPoint::Reply(pressed, webLayerID), m_pageID);
696
697     return pressed;
698 }
699
700 void WebPageProxy::setOverflowResult(bool pressed, uint32_t webLayerID)
701 {
702     static_cast<PageClientImpl*>(m_pageClient)->setOverflowResult(pressed, webLayerID);
703 }
704 #endif
705
706 void WebPageProxy::executeEditCommandWithArgument(const String& commandName, const String& argument)
707 {
708     if (!isValid())
709         return;
710
711     DEFINE_STATIC_LOCAL(String, ignoreSpellingCommandName, ("ignoreSpelling"));
712     if (commandName == ignoreSpellingCommandName)
713         ++m_pendingLearnOrIgnoreWordMessageCount;
714
715     process()->send(Messages::WebPage::ExecuteEditCommandWithArgument(commandName, argument), m_pageID);
716 }
717
718 void WebPageProxy::replyJavaScriptAlert()
719 {
720     if (!m_alertReply)
721         return;
722
723     m_alertReply->send();
724     m_alertReply = nullptr;
725 #if ENABLE(TIZEN_WEBKIT2_NOTIFY_POPUP_REPLY_STATUS)
726     m_uiClient.notifyPopupReplyWaitingState(this, false);
727 #endif
728 #if ENABLE(TIZEN_WEBKIT2_ROTATION_WHILE_JAVASCRIPT_POPUP)
729     process()->connection()->setForcelySetAllAsyncMessagesToDispatchEvenWhenWaitingForSyncReply(false);
730 #endif
731 }
732
733 void WebPageProxy::replyJavaScriptConfirm(bool result)
734 {
735     if (!m_confirmReply)
736         return;
737
738     m_confirmReply->send(result);
739     m_confirmReply = nullptr;
740 #if ENABLE(TIZEN_WEBKIT2_NOTIFY_POPUP_REPLY_STATUS)
741     m_uiClient.notifyPopupReplyWaitingState(this, false);
742 #endif
743 #if ENABLE(TIZEN_WEBKIT2_ROTATION_WHILE_JAVASCRIPT_POPUP)
744     process()->connection()->setForcelySetAllAsyncMessagesToDispatchEvenWhenWaitingForSyncReply(false);
745 #endif
746 }
747
748 void WebPageProxy::replyJavaScriptPrompt(const String& result)
749 {
750     if (!m_promptReply)
751         return;
752
753     m_promptReply->send(result);
754     m_promptReply = nullptr;
755 #if ENABLE(TIZEN_WEBKIT2_NOTIFY_POPUP_REPLY_STATUS)
756     m_uiClient.notifyPopupReplyWaitingState(this, false);
757 #endif
758 #if ENABLE(TIZEN_WEBKIT2_ROTATION_WHILE_JAVASCRIPT_POPUP)
759     process()->connection()->setForcelySetAllAsyncMessagesToDispatchEvenWhenWaitingForSyncReply(false);
760 #endif
761 }
762
763 #if ENABLE(TIZEN_SUPPORT_BEFORE_UNLOAD_CONFIRM_PANEL)
764 void WebPageProxy::replyBeforeUnloadConfirmPanel(bool result)
765 {
766     if (!m_beforeUnloadConfirmPanelReply)
767         return;
768
769     m_beforeUnloadConfirmPanelReply->send(result);
770     m_beforeUnloadConfirmPanelReply = nullptr;
771 #if ENABLE(TIZEN_WEBKIT2_ROTATION_WHILE_JAVASCRIPT_POPUP)
772     process()->connection()->setForcelySetAllAsyncMessagesToDispatchEvenWhenWaitingForSyncReply(false);
773 #endif
774 }
775 #endif
776
777 #if ENABLE(TIZEN_ON_AUTHENTICATION_REQUESTED)
778 void WebPageProxy::replyReceiveAuthenticationChallengeInFrame(bool result)
779 {
780     if (!m_AuthReply)
781         return;
782
783     m_AuthReply->send(result);
784     m_AuthReply = nullptr;
785 }
786 #endif
787
788 #if ENABLE(TIZEN_CERTIFICATE_HANDLING)
789 void WebPageProxy::replyPolicyForCertificateError(bool result)
790 {
791     if (!m_allowedReply)
792         return;
793
794     m_allowedReply->send(result);
795     m_allowedReply = nullptr;
796 }
797 #endif
798
799 #if PLUGIN_ARCHITECTURE(X11)
800 void WebPageProxy::createPluginContainer(uint64_t& windowID)
801 {
802     notImplemented();
803 }
804
805 void WebPageProxy::windowedPluginGeometryDidChange(const WebCore::IntRect& frameRect, const WebCore::IntRect& clipRect, uint64_t windowID)
806 {
807     notImplemented();
808 }
809 #endif
810
811 void WebPageProxy::didRenderFrame()
812 {
813     static_cast<PageClientImpl*>(m_pageClient)->didRenderFrame();
814 }
815
816 void WebPageProxy::setBackgroundColor(double red, double green, double blue, double alpha)
817 {
818     static_cast<PageClientImpl*>(m_pageClient)->setBackgroundColor(red, green, blue, alpha);
819 }
820
821 #if ENABLE(TIZEN_WEBKIT2_TILED_AC)
822 bool WebPageProxy::makeContextCurrent()
823 {
824     return static_cast<PageClientImpl*>(m_pageClient)->makeContextCurrent();
825 }
826 #endif
827
828 #if ENABLE(TIZEN_ICON_DATABASE)
829 void WebPageProxy::didReceiveIcon()
830 {
831     static_cast<PageClientImpl*>(m_pageClient)->didReceiveIcon();
832 }
833 #endif
834
835 #if ENABLE(TIZEN_MULTIPLE_SELECT)
836 void WebPageProxy::valueChangedForPopupMenuMultiple(WebPopupMenuProxy*, Vector<int32_t> newSelectedIndex)
837 {
838     process()->send(Messages::WebPage::DidChangeSelectedIndexForActivePopupMenuMultiple(newSelectedIndex), m_pageID);
839 }
840 #endif
841
842 #if ENABLE(TIZEN_WEBKIT2_HISTORICAL_RESTORE_VISIBLE_CONTENT_RECT)
843 void WebPageProxy::pageDidRequestRestoreVisibleContentRect(const IntPoint& point, float scale)
844 {
845     m_pageClient->pageDidRequestRestoreVisibleContentRect(point, scale);
846 }
847 #endif
848
849 #if ENABLE(TIZEN_OFFLINE_PAGE_SAVE)
850 void WebPageProxy::saveSerializedHTMLDataForMainPage(const String& serializedData, const String& fileName)
851 {
852     static_cast<PageClientImpl*>(m_pageClient)->saveSerializedHTMLDataForMainPage(serializedData, fileName);
853 }
854
855 void WebPageProxy::saveSubresourcesData(Vector<WebSubresourceTizen> subresourceData)
856 {
857     static_cast<PageClientImpl*>(m_pageClient)->saveSubresourcesData(subresourceData);
858 }
859
860 void WebPageProxy::startOfflinePageSave(String subresourceFolderName)
861 {
862     if (!isValid())
863         return;
864
865     process()->send(Messages::WebPage::StartOfflinePageSave(subresourceFolderName), m_pageID);
866 }
867 #endif
868
869 #if ENABLE(TIZEN_WEBKIT2_TEXT_SELECTION)
870 bool WebPageProxy::selectClosestWord(const IntPoint& point, bool isStartedTextSelectionFromOutside)
871 {
872     if (!isValid())
873         return false;
874
875     bool result = false;
876     process()->sendSync(Messages::WebPage::SelectClosestWord(point, isStartedTextSelectionFromOutside), Messages::WebPage::SelectClosestWord::Reply(result), m_pageID);
877     return result;
878 }
879
880 bool WebPageProxy::setLeftSelection(const IntPoint& point)
881 {
882     if (!isValid())
883         return false;
884
885     bool result = false;
886     process()->sendSync(Messages::WebPage::SetLeftSelection(point), Messages::WebPage::SetLeftSelection::Reply(result), m_pageID);
887     return result;
888 }
889
890 bool WebPageProxy::setRightSelection(const IntPoint& point)
891 {
892     if (!isValid())
893         return false;
894
895     bool result;
896     process()->sendSync(Messages::WebPage::SetRightSelection(point), Messages::WebPage::SetRightSelection::Reply(result), m_pageID);
897     return result;
898 }
899
900 bool WebPageProxy::getSelectionHandlers(IntRect& leftRect, IntRect& rightRect)
901 {
902     if (!isValid())
903         return false;
904
905     bool result = false;
906     process()->sendSync(Messages::WebPage::GetSelectionHandlers(), Messages::WebPage::GetSelectionHandlers::Reply(leftRect, rightRect), m_pageID);
907     if (!leftRect.size().isZero() || !rightRect.size().isZero())
908         result = true;
909
910     return result;
911 }
912
913 String WebPageProxy::getSelectionText()
914 {
915     String ret;
916     if (!isValid())
917         return ret;
918
919     process()->sendSync(Messages::WebPage::GetSelectionText(), Messages::WebPage::GetSelectionText::Reply(ret), m_pageID);
920     return ret;
921 }
922
923 bool WebPageProxy::selectionRangeClear()
924 {
925     if (!isValid())
926         return false;
927
928     bool result = false;
929     process()->sendSync(Messages::WebPage::SelectionRangeClear(), Messages::WebPage::SelectionRangeClear::Reply(result), m_pageID);
930     return result;
931 }
932
933 bool WebPageProxy::scrollContentByCharacter(const IntPoint& point, SelectionDirection direction)
934 {
935     if (!isValid())
936         return false;
937
938     bool result = false;
939     process()->sendSync(Messages::WebPage::ScrollContentByCharacter(point, direction), Messages::WebPage::ScrollContentByCharacter::Reply(result), m_pageID);
940     return result;
941 }
942
943 bool WebPageProxy::scrollContentByLine(const IntPoint& point, SelectionDirection direction)
944 {
945     if (!isValid())
946         return false;
947
948     bool result = false;
949     process()->sendSync(Messages::WebPage::ScrollContentByLine(point, direction), Messages::WebPage::ScrollContentByLine::Reply(result), m_pageID);
950     return result;
951 }
952 #endif
953
954 #if ENABLE(TIZEN_LINK_MAGNIFIER)
955 void WebPageProxy::getLinkMagnifierRect(const WebCore::IntPoint& position, const WebCore::IntSize& size)
956 {
957     process()->send(Messages::WebPage::GetLinkMagnifierRect(position, size), m_pageID);
958 }
959
960 void WebPageProxy::didGetLinkMagnifierRect(const IntPoint& position, const IntRect& rect)
961 {
962     if (!rect.isEmpty())
963         LinkMagnifierProxy::linkMagnifier().show(EwkViewImpl::fromEvasObject(viewWidget()), position, rect);
964     else
965         openLink(position);
966 }
967
968 void WebPageProxy::openLink(const IntPoint& position)
969 {
970 #if ENABLE(GESTURE_EVENTS)
971     IntPoint globalPosition(EwkViewImpl::fromEvasObject(viewWidget())->transformToScreen().mapPoint(position));
972     WebGestureEvent gesture(WebEvent::GestureSingleTap, position, globalPosition, WebEvent::Modifiers(0), ecore_time_get());
973     handleGestureEvent(gesture);
974 #endif
975 }
976 #endif
977
978 #if ENABLE(TIZEN_SCREEN_READER)
979 void WebPageProxy::raiseTapEvent(const IntPoint& position)
980 {
981 #if ENABLE(GESTURE_EVENTS)
982     IntPoint globalPosition = EwkViewImpl::fromEvasObject(viewWidget())->transformToScreen().mapPoint(position);
983     process()->send(Messages::WebPage::RaiseTapEvent(position, globalPosition), m_pageID);
984 #else
985     UNUSED_PARAM(position);
986 #endif
987 }
988
989 bool WebPageProxy::moveScreenReaderFocus(bool forward)
990 {
991     bool result;
992     process()->sendSync(Messages::WebPage::MoveScreenReaderFocus(forward), Messages::WebPage::MoveScreenReaderFocus::Reply(result), m_pageID);
993     return result;
994 }
995
996 void WebPageProxy::moveScreenReaderFocusByPoint(const IntPoint& point)
997 {
998     process()->send(Messages::WebPage::MoveScreenReaderFocusByPoint(point), m_pageID);
999 }
1000
1001 void WebPageProxy::recalcScreenReaderFocusRect()
1002 {
1003     if (!ScreenReaderProxy::screenReader().isEnabled())
1004         return;
1005
1006     process()->send(Messages::WebPage::RecalcScreenReaderFocusRect(), m_pageID);
1007 }
1008
1009 void WebPageProxy::clearScreenReader()
1010 {
1011     process()->send(Messages::WebPage::ClearScreenReader(), m_pageID);
1012 }
1013
1014 void WebPageProxy::didScreenReaderFocusRectChanged(const IntRect& rect)
1015 {
1016 #if ENABLE(TIZEN_WEBKIT2_FOCUS_RING)
1017     FocusRing* focusRing = ewkViewGetFocusRing(viewWidget());
1018     if (!focusRing)
1019         return;
1020
1021     if (!rect.isEmpty())
1022         focusRing->show(rect);
1023     else
1024         focusRing->hide(false);
1025 #else
1026     UNUSED_PARAM(rect);
1027 #endif
1028 }
1029
1030 void WebPageProxy::didScreenReaderTextChanged(const String& text)
1031 {
1032     ScreenReaderProxy::screenReader().setText(text);
1033 }
1034 #endif
1035
1036 #if ENABLE(TIZEN_CSP)
1037 void WebPageProxy::setContentSecurityPolicy(const String& policy, WebCore::ContentSecurityPolicy::HeaderType type)
1038 {
1039     process()->send(Messages::WebPage::SetContentSecurityPolicy(policy, type), m_pageID);
1040 }
1041 #endif
1042
1043 #if ENABLE(TIZEN_APPLICATION_CACHE)
1044 void WebPageProxy::requestApplicationCachePermission(uint64_t frameID, const String& originIdentifier, PassRefPtr<Messages::WebPageProxy::RequestApplicationCachePermission::DelayedReply> allow)
1045 {
1046     WebFrameProxy* frame = process()->webFrame(frameID);
1047     MESSAGE_CHECK(frame);
1048
1049     // Since requestApplicationCachePermission() can spin a nested run loop we need to turn off the responsiveness timer.
1050     process()->responsivenessTimer()->stop();
1051
1052     m_applicationCacheReply = allow;
1053 #if ENABLE(TIZEN_WEBKIT2_ROTATION_WHILE_JAVASCRIPT_POPUP)
1054     process()->connection()->setForcelySetAllAsyncMessagesToDispatchEvenWhenWaitingForSyncReply(true);
1055 #endif
1056     RefPtr<WebSecurityOrigin> origin = WebSecurityOrigin::createFromDatabaseIdentifier(originIdentifier);
1057
1058     if (!m_tizenClient.decidePolicyForApplicationCachePermissionRequest(this, origin.get(), frame))
1059         replyApplicationCachePermission(true);
1060 }
1061
1062 void WebPageProxy::replyApplicationCachePermission(bool allow)
1063 {
1064     if (!m_applicationCacheReply)
1065         return;
1066
1067     m_applicationCacheReply->send(allow);
1068     m_applicationCacheReply = nullptr;
1069 #if ENABLE(TIZEN_WEBKIT2_ROTATION_WHILE_JAVASCRIPT_POPUP)
1070     process()->connection()->setForcelySetAllAsyncMessagesToDispatchEvenWhenWaitingForSyncReply(false);
1071 #endif
1072 }
1073 #endif
1074
1075 #if ENABLE(TIZEN_INDEXED_DATABASE)
1076 void WebPageProxy::exceededIndexedDatabaseQuota(uint64_t frameID, const String& originIdentifier, int64_t currentUsage, PassRefPtr<Messages::WebPageProxy::ExceededIndexedDatabaseQuota::DelayedReply> reply)
1077 {
1078     WebFrameProxy* frame = process()->webFrame(frameID);
1079     MESSAGE_CHECK(frame);
1080
1081     // Since exceededIndexedDatabaseQuota() can spin a nested run loop we need to turn off the responsiveness timer.
1082     process()->responsivenessTimer()->stop();
1083
1084     m_exceededIndexedDatabaseQuotaReply = reply;
1085 #if ENABLE(TIZEN_WEBKIT2_ROTATION_WHILE_JAVASCRIPT_POPUP)
1086     process()->connection()->setForcelySetAllAsyncMessagesToDispatchEvenWhenWaitingForSyncReply(true);
1087 #endif
1088
1089     RefPtr<WebSecurityOrigin> origin = WebSecurityOrigin::createFromDatabaseIdentifier(originIdentifier);
1090
1091     if (!m_tizenClient.exceededIndexedDatabaseQuota(this, origin.get(), currentUsage, frame))
1092         replyExceededIndexedDatabaseQuota(false);
1093 }
1094
1095 void WebPageProxy::replyExceededIndexedDatabaseQuota(bool allow)
1096 {
1097     if (!m_exceededIndexedDatabaseQuotaReply)
1098         return;
1099
1100     m_exceededIndexedDatabaseQuotaReply->send(allow);
1101     m_exceededIndexedDatabaseQuotaReply = nullptr;
1102 #if ENABLE(TIZEN_WEBKIT2_ROTATION_WHILE_JAVASCRIPT_POPUP)
1103     process()->connection()->setForcelySetAllAsyncMessagesToDispatchEvenWhenWaitingForSyncReply(false);
1104 #endif
1105 }
1106 #endif
1107
1108 #if ENABLE(TIZEN_SQL_DATABASE)
1109 void WebPageProxy::replyExceededDatabaseQuota(bool allow)
1110 {
1111     if (!m_exceededDatabaseQuotaReply) {
1112         TIZEN_LOGE("m_exceededDatabaseQuotaReply does not exist");
1113         return;
1114     }
1115
1116     m_exceededDatabaseQuotaReply->send(allow);
1117     m_exceededDatabaseQuotaReply = nullptr;
1118 #if ENABLE(TIZEN_WEBKIT2_ROTATION_WHILE_JAVASCRIPT_POPUP)
1119     process()->connection()->setForcelySetAllAsyncMessagesToDispatchEvenWhenWaitingForSyncReply(false);
1120 #endif
1121 }
1122 #endif
1123
1124 #if ENABLE(TIZEN_FILE_SYSTEM)
1125 void WebPageProxy::exceededLocalFileSystemQuota(uint64_t frameID, const String& originIdentifier, int64_t currentUsage, PassRefPtr<Messages::WebPageProxy::ExceededLocalFileSystemQuota::DelayedReply> reply)
1126 {
1127     WebFrameProxy* frame = process()->webFrame(frameID);
1128     MESSAGE_CHECK(frame);
1129
1130     // Since exceededLocalFileSystemQuota() can spin a nested run loop we need to turn off the responsiveness timer.
1131     process()->responsivenessTimer()->stop();
1132     m_exceededLocalFileSystemQuotaReply = reply;
1133 #if ENABLE(TIZEN_WEBKIT2_ROTATION_WHILE_JAVASCRIPT_POPUP)
1134     process()->connection()->setForcelySetAllAsyncMessagesToDispatchEvenWhenWaitingForSyncReply(true);
1135 #endif
1136
1137     RefPtr<WebSecurityOrigin> origin = WebSecurityOrigin::createFromDatabaseIdentifier(originIdentifier);
1138
1139     if (!m_tizenClient.exceededLocalFileSystemQuota(this, origin.get(), currentUsage, frame))
1140         replyExceededLocalFileSystemQuota(false);
1141 }
1142
1143 void WebPageProxy::replyExceededLocalFileSystemQuota(bool allow)
1144 {
1145     if (!m_exceededLocalFileSystemQuotaReply)
1146         return;
1147
1148     m_exceededLocalFileSystemQuotaReply->send(allow);
1149     m_exceededLocalFileSystemQuotaReply = nullptr;
1150 #if ENABLE(TIZEN_WEBKIT2_ROTATION_WHILE_JAVASCRIPT_POPUP)
1151     process()->connection()->setForcelySetAllAsyncMessagesToDispatchEvenWhenWaitingForSyncReply(false);
1152 #endif
1153 }
1154 #endif
1155
1156 #endif // #if OS(TIZEN)
1157
1158 void WebPageProxy::handleInputMethodKeydown(bool& handled)
1159 {
1160 #if ENABLE(TIZEN_WEBKIT2_ROTATION_WHILE_JAVASCRIPT_POPUP)
1161     handled = m_keyEventQueue.first().forwardedEvent.isFiltered();
1162 #else
1163     handled = m_keyEventQueue.first().isFiltered();
1164 #endif
1165 }
1166
1167 void WebPageProxy::confirmComposition(const String& compositionString)
1168 {
1169     if (!isValid())
1170         return;
1171
1172 #if ENABLE(TIZEN_ISF_PORT)
1173     if (m_didCancelCompositionFromWebProcess)
1174         return;
1175 #endif
1176
1177     process()->send(Messages::WebPage::ConfirmComposition(compositionString), m_pageID, 0);
1178 }
1179
1180 void WebPageProxy::setComposition(const String& compositionString, Vector<WebCore::CompositionUnderline>& underlines, int cursorPosition)
1181 {
1182     if (!isValid())
1183         return;
1184
1185 #if ENABLE(TIZEN_REDUCE_KEY_LAGGING)
1186     // Suspend layout&paint at the key input, and resume layout&paint after 150 ms.
1187     suspendActiveDOMObjectsAndAnimations();
1188     if (m_pageContentResumeTimer)
1189         ecore_timer_del(m_pageContentResumeTimer);
1190     m_pageContentResumeTimer = ecore_timer_add(150.0/1000.0, pageContentResumeTimerFired, this);
1191 #endif
1192
1193     process()->send(Messages::WebPage::SetComposition(compositionString, underlines, cursorPosition), m_pageID, 0);
1194 }
1195
1196 void WebPageProxy::cancelComposition()
1197 {
1198     if (!isValid())
1199         return;
1200
1201     process()->send(Messages::WebPage::CancelComposition(), m_pageID, 0);
1202 }
1203
1204 #if ENABLE(TIZEN_USE_SETTINGS_FONT)
1205 void WebPageProxy::useSettingsFont()
1206 {
1207     process()->send(Messages::WebPage::UseSettingsFont(), m_pageID, 0);
1208 }
1209 #endif
1210
1211 #if ENABLE(TIZEN_WEBKIT2_NOTIFY_SUSPEND_BY_REMOTE_WEB_INSPECTOR)
1212 void WebPageProxy::setContentSuspendedByInspector(bool isSuspended)
1213 {
1214     m_contentSuspendedByInspector = isSuspended;
1215 }
1216 #endif
1217
1218 } // namespace WebKit