[BlackBerry] Upstream ChromeClientBlackBerry.{h, cpp}

https://bugs.webkit.org/show_bug.cgi?id=77843

Reviewed by Rob Buis.

Initial upstream, no new tests.

* blackberry/WebCoreSupport/ChromeClientBlackBerry.cpp: Added.
* blackberry/WebCoreSupport/ChromeClientBlackBerry.h: Added.


git-svn-id: http://svn.webkit.org/repository/webkit/trunk@107033 268f45cc-cd09-0410-ab3c-d52691b4dbfc
parent d6dd62fb
2012-02-07 Leo Yang <leo.yang@torchmobile.com.cn>
[BlackBerry] Upstream ChromeClientBlackBerry.{h, cpp}
https://bugs.webkit.org/show_bug.cgi?id=77843
Reviewed by Rob Buis.
Initial upstream, no new tests.
* blackberry/WebCoreSupport/ChromeClientBlackBerry.cpp: Added.
* blackberry/WebCoreSupport/ChromeClientBlackBerry.h: Added.
2012-02-07 Rob Buis <rbuis@rim.com>
[BlackBerry] Upstream DumpRenderTreeSupport
......
/*
* Copyright (C) 2009, 2010, 2011, 2012 Research In Motion Limited. All rights reserved.
*
* This library is free software; you can redistribute it and/or
* modify it under the terms of the GNU Lesser General Public
* License as published by the Free Software Foundation; either
* version 2 of the License, or (at your option) any later version.
*
* This library is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
* Lesser General Public License for more details.
*
* You should have received a copy of the GNU Lesser General Public
* License along with this library; if not, write to the Free Software
* Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
*/
#ifndef ChromeClientBlackBerry_h
#define ChromeClientBlackBerry_h
#include "ChromeClient.h"
namespace BlackBerry {
namespace WebKit {
class WebPagePrivate;
}
}
namespace WebCore {
class ChromeClientBlackBerry : public ChromeClient {
public:
ChromeClientBlackBerry(BlackBerry::WebKit::WebPagePrivate*);
virtual void chromeDestroyed();
virtual void* webView() const { return 0; };
virtual void setWindowRect(const FloatRect&);
virtual FloatRect windowRect();
virtual FloatRect pageRect();
virtual float scaleFactor();
virtual void focus();
virtual void unfocus();
virtual bool canTakeFocus(FocusDirection);
virtual void takeFocus(FocusDirection);
virtual void focusedNodeChanged(Node*);
virtual void focusedFrameChanged(Frame*);
virtual bool shouldForceDocumentStyleSelectorUpdate();
virtual Page* createWindow(Frame*, const FrameLoadRequest&, const WindowFeatures&, const NavigationAction&);
virtual void show();
virtual bool canRunModal();
virtual void runModal();
virtual void setToolbarsVisible(bool);
virtual bool toolbarsVisible();
virtual void setStatusbarVisible(bool);
virtual bool statusbarVisible();
virtual void setScrollbarsVisible(bool);
virtual bool scrollbarsVisible();
virtual void setMenubarVisible(bool);
virtual bool menubarVisible();
virtual void setResizable(bool);
virtual void addMessageToConsole(MessageSource, MessageType, MessageLevel, const String& message, unsigned int lineNumber, const String& sourceID);
virtual bool canRunBeforeUnloadConfirmPanel();
virtual bool runBeforeUnloadConfirmPanel(const String&, Frame*);
virtual void closeWindowSoon();
virtual void runJavaScriptAlert(Frame*, const String&);
virtual bool runJavaScriptConfirm(Frame*, const String&);
virtual bool runJavaScriptPrompt(Frame*, const String&, const String&, String&);
virtual void setStatusbarText(const String&);
virtual bool shouldInterruptJavaScript();
virtual KeyboardUIMode keyboardUIMode();
virtual IntRect windowResizerRect() const;
virtual void invalidateWindow(const IntRect&, bool);
virtual void invalidateContentsAndWindow(const IntRect&, bool);
virtual void invalidateContentsForSlowScroll(const IntSize&, const IntRect&, bool, const ScrollView*);
virtual void scroll(const IntSize&, const IntRect&, const IntRect&);
virtual void scrollableAreasDidChange();
virtual IntPoint screenToWindow(const IntPoint&) const;
virtual IntRect windowToScreen(const IntRect&) const;
virtual void contentsSizeChanged(Frame*, const IntSize&) const;
virtual void scrollRectIntoView(const IntRect&, const ScrollView*) const;
virtual void mouseDidMoveOverElement(const HitTestResult&, unsigned int);
virtual void setToolTip(const String&, TextDirection);
#if ENABLE(EVENT_MODE_METATAGS)
virtual void didReceiveCursorEventMode(Frame*, CursorEventMode) const;
virtual void didReceiveTouchEventMode(Frame*, TouchEventMode) const;
#endif
virtual void dispatchViewportPropertiesDidChange(const ViewportArguments&) const;
virtual bool shouldRubberBandInDirection(ScrollDirection) const { return true; }
virtual void numWheelEventHandlersChanged(unsigned) { }
virtual void print(Frame*);
virtual void exceededDatabaseQuota(Frame*, const String&);
virtual void requestGeolocationPermissionForFrame(Frame*, Geolocation*);
virtual void cancelGeolocationPermissionRequestForFrame(Frame*, Geolocation*);
virtual void runOpenPanel(Frame*, PassRefPtr<FileChooser>);
virtual void loadIconForFiles(const Vector<String>&, FileIconLoader*);
virtual void setCursor(const Cursor&);
virtual void setCursorHiddenUntilMouseMoves(bool) { }
virtual void formStateDidChange(const Node*);
virtual void scrollbarsModeDidChange() const;
virtual PlatformPageClient platformPageClient() const;
#if ENABLE(TOUCH_EVENTS)
virtual void needTouchEvents(bool);
#endif
#if ENABLE(INPUT_COLOR)
void openColorChooser(ColorChooser*, const Color&) { }
void cleanupColorChooser(ColorChooser*) { }
void setSelectedColorInColorChooser(ColorChooser*, const Color&) { }
#endif
virtual void reachedMaxAppCacheSize(int64_t spaceNeeded);
virtual void reachedApplicationCacheOriginQuota(SecurityOrigin*, int64_t) { }
virtual void layoutUpdated(Frame*) const;
virtual void overflowExceedsContentsSize(Frame*) const;
virtual void didDiscoverFrameSet(Frame*) const;
virtual int reflowWidth() const;
virtual void chooseIconForFiles(const Vector<String>&, FileChooser*);
virtual bool supportsFullscreenForNode(const Node*);
virtual void enterFullscreenForNode(Node*);
virtual void exitFullscreenForNode(Node*);
#if ENABLE(WEBGL)
virtual void requestWebGLPermission(Frame*);
#endif
#if ENABLE(NOTIFICATIONS)
virtual NotificationPresenter* notificationPresenter() const;
#endif
#if ENABLE(SVG)
virtual void didSetSVGZoomAndPan(Frame*, unsigned short zoomAndPan);
#endif
virtual bool selectItemWritingDirectionIsNatural();
virtual bool selectItemAlignmentFollowsMenuWritingDirection();
virtual PassRefPtr<PopupMenu> createPopupMenu(PopupMenuClient*) const;
virtual PassRefPtr<SearchPopupMenu> createSearchPopupMenu(PopupMenuClient*) const;
virtual void showContextMenu() { }
#if USE(ACCELERATED_COMPOSITING)
virtual void attachRootGraphicsLayer(Frame*, GraphicsLayer*);
virtual void setNeedsOneShotDrawingSynchronization();
virtual void scheduleCompositingLayerSync();
virtual bool allowsAcceleratedCompositing() const;
#endif
virtual void* platformWindow() const;
virtual void* platformCompositingWindow() const;
BlackBerry::WebKit::WebPagePrivate* webPagePrivate() const { return m_webPagePrivate; }
private:
BlackBerry::WebKit::WebPagePrivate* m_webPagePrivate;
};
} // WebCore
#endif // ChromeClientBlackBerry_h
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment