webengine/osswebengine/WebKit/s60/webview/WebView.h
changeset 5 10e98eab6f85
parent 1 7c90e6132015
child 10 a359256acfc6
equal deleted inserted replaced
1:7c90e6132015 5:10e98eab6f85
    20 #define WEBKITVIEW_H
    20 #define WEBKITVIEW_H
    21 
    21 
    22 //  INCLUDES
    22 //  INCLUDES
    23 #include <e32std.h>
    23 #include <e32std.h>
    24 #include <eikscrlb.h>
    24 #include <eikscrlb.h>
    25 #include "platform/Shared.h"
    25 #include "platform\Shared.h"
    26 #include "BrCtlDefs.h"
    26 #include "BrCtlDefs.h"
    27 #include "PageScaler.h"
    27 #include "PageScaler.h"
    28 #include "Timer.h"
    28 #include "Timer.h"
    29 #include "MemoryManager.h"
    29 #include "MemoryManager.h"
    30 
    30 
    62 class MWidgetCallback;
    62 class MWidgetCallback;
    63 class WebTabbedNavigation;
    63 class WebTabbedNavigation;
    64 class WebPageZoomHandler;
    64 class WebPageZoomHandler;
    65 class WebPointerEventHandler;
    65 class WebPointerEventHandler;
    66 class WebPageFullScreenHandler;
    66 class WebPageFullScreenHandler;
       
    67 class WebFrameView;
       
    68 class WebFrameBridge;
    67 
    69 
    68 class WebView : public CEikBorderedControl, public WebCore::Shared<WebView>, private MPageScalerCallback, public MOOMStopper
    70 class WebView : public CEikBorderedControl, public WebCore::Shared<WebView>, private MPageScalerCallback, public MOOMStopper
    69     {
    71     {
    70     public:
    72     public:
    71         /**
    73         /**
   182         bool isSmallPage();
   184         bool isSmallPage();
   183         void willSubmitForm(WebCore::FormState* formState);
   185         void willSubmitForm(WebCore::FormState* formState);
   184 
   186 
   185         PluginPlayer* pluginPlayer() { return m_pluginplayer; }
   187         PluginPlayer* pluginPlayer() { return m_pluginplayer; }
   186         void closePluginPlayer();
   188         void closePluginPlayer();
   187         void openPluginPlayer(PluginWin* plugin);
   189         void openPluginPlayerL(PluginWin* plugin);
   188 
   190 
   189         void setAccessPointId(TUint32 apid) {m_apid = apid;}
   191         void setAccessPointId(TUint32 apid) {m_apid = apid;}
   190         TUint32 accessPointId() { return m_apid; }
   192         TUint32 accessPointId() { return m_apid; }
   191 
   193 
   192         CWidgetExtension* createWidgetExtension(MWidgetCallback &aWidgetCallback);
   194         CWidgetExtension* createWidgetExtension(MWidgetCallback &aWidgetCallback);
   382         * @return
   384         * @return
   383         */
   385         */
   384         TBool TouchScrolling() ;
   386         TBool TouchScrolling() ;
   385 
   387 
   386         CCoeControl& PageControlView();
   388         CCoeControl& PageControlView();
   387         void notifyPlugins(TBool focus);
       
   388 
   389 
   389      protected: // From CCoeControl
   390      protected: // From CCoeControl
   390 
   391 
   391         /**
   392         /**
   392         * FocusChanged
   393         * FocusChanged
   452         bool handleMinimapNavigation();
   453         bool handleMinimapNavigation();
   453         bool handleKeyNavigation(const TKeyEvent& keyevent, TEventCode eventcode, WebCore::Frame* frame);
   454         bool handleKeyNavigation(const TKeyEvent& keyevent, TEventCode eventcode, WebCore::Frame* frame);
   454         bool handleInputElement(const TKeyEvent& keyevent, TEventCode eventcode, WebCore::Frame* frame);
   455         bool handleInputElement(const TKeyEvent& keyevent, TEventCode eventcode, WebCore::Frame* frame);
   455         bool handleEventKeyL(const TKeyEvent& keyevent, TEventCode eventcode, WebCore::Frame* frame);
   456         bool handleEventKeyL(const TKeyEvent& keyevent, TEventCode eventcode, WebCore::Frame* frame);
   456         void setFocusedNode(WebCore::Frame* frame);
   457         void setFocusedNode(WebCore::Frame* frame);
   457         void sendMouseEventToEngine(TPointerEvent::TType eventType, TPoint pos, WebCore::Frame* frame);
   458 
   458         bool handleEventKeyUp(const TKeyEvent& keyevent, TEventCode eventcode, WebCore::Frame* frame);
   459         bool handleEventKeyUp(const TKeyEvent& keyevent, TEventCode eventcode, WebCore::Frame* frame);
   459         bool handleEditable(const TKeyEvent& keyevent, TEventCode eventcode, WebCore::Frame* frame );
   460         bool handleEditable(const TKeyEvent& keyevent, TEventCode eventcode, WebCore::Frame* frame );
   460         bool isNaviKey(const TKeyEvent& keyevent);
   461         bool isNaviKey(const TKeyEvent& keyevent);
   461     public:
   462     public:
       
   463         void sendMouseEventToEngine(TPointerEvent::TType eventType, TPoint pos, WebCore::Frame* frame);
   462         void fepTimerFired(WebCore::Timer<WebView>*);
   464         void fepTimerFired(WebCore::Timer<WebView>*);
   463         void fepVKBTimerFired(WebCore::Timer<WebView>*);
   465         void fepVKBTimerFired(WebCore::Timer<WebView>*);
   464         bool isClosing() const { return m_isClosing; }
   466         bool isClosing() const { return m_isClosing; }
   465         void synchRequestPending(bool);
   467         void synchRequestPending(bool);
   466         bool isSynchRequestPending() const { return m_synchRequestPending; }
   468         bool isSynchRequestPending() const { return m_synchRequestPending; }
   467 
   469 
   468         void setPluginFullscreen(bool val) { m_pluginFullscreen = val; }
       
   469         bool isPluginFullscreen() { return m_pluginFullscreen; }
       
   470         void setPluginActivated(bool option) {m_pluginActivated = option;}
       
   471         TInt getWidgetId();
   470         TInt getWidgetId();
       
   471         void focusedElementChanged(WebCore::Element* element);
       
   472         void windowObjectCleared() const;
       
   473 
   472     private:
   474     private:
   473         WebCore::Page* m_page;
   475         WebCore::Page*          m_page;
   474         CBrCtl* m_brctl;
   476         WebFrameView*           m_frameView;
       
   477         WebFrameBridge*         m_bridge;
       
   478         CBrCtl*                 m_brctl;
   475         RRegion                 m_repaints;
   479         RRegion                 m_repaints;
   476         CPeriodic*              m_repainttimer;
   480         CPeriodic*              m_repainttimer;
   477         WebCoreGraphicsContext* m_webcorecontext;   // owned
   481         WebCoreGraphicsContext* m_webcorecontext;   // owned
   478         CFbsBitmapDevice*       m_bitmapdevice;     // onwed
   482         CFbsBitmapDevice*       m_bitmapdevice;     // onwed
   479         TRect                   m_offscreenrect;
   483         TRect                   m_offscreenrect;
   542         bool m_viewIsFastScrolling;
   546         bool m_viewIsFastScrolling;
   543         TPoint* m_ptrbuffer;
   547         TPoint* m_ptrbuffer;
   544 
   548 
   545         // synchronous requests
   549         // synchronous requests
   546         bool                m_synchRequestPending;
   550         bool                m_synchRequestPending;
   547         bool                m_pluginFullscreen;
       
   548         //Indicates any plugin is activated/deactivated
   551         //Indicates any plugin is activated/deactivated
   549         bool                m_pluginActivated;
       
   550         bool                m_showCursor;
   552         bool                m_showCursor;
   551         bool                m_allowRepaints;
   553         bool                m_allowRepaints;
   552     };
   554     };
   553 
   555 
   554 #endif
   556 #endif