webengine/osswebengine/WebCore/platform/symbian/WidgetSymbian.cpp
changeset 15 60c5402cb945
parent 0 dd21522fd290
child 25 0ed94ceaa377
equal deleted inserted replaced
11:c8a366e56285 15:60c5402cb945
    22 #include "Widget.h"
    22 #include "Widget.h"
    23 #include "WebCoreWidget.h"
    23 #include "WebCoreWidget.h"
    24 #include "IntRect.h"
    24 #include "IntRect.h"
    25 #include "IntPoint.h"
    25 #include "IntPoint.h"
    26 #include "Cursor.h"
    26 #include "Cursor.h"
       
    27 #include "Event.h"
       
    28 #include "EventNames.h"
       
    29 #include "KeyboardEvent.h"
    27 
    30 
    28 namespace WebCore {
    31 namespace WebCore {
    29 
    32 using namespace EventNames;
    30 static bool deferFirstResponderChanges;
    33 static bool deferFirstResponderChanges;
    31 static Widget *deferredFirstResponder;
    34 static Widget *deferredFirstResponder;
    32 
    35 
    33 class WidgetPrivate
    36 class WidgetPrivate
    34     {
    37     {
   237     {
   240     {
   238     if (getView())
   241     if (getView())
   239         return getView()->isFocusable();
   242         return getView()->isFocusable();
   240     return false;
   243     return false;
   241     }
   244     }
       
   245 
       
   246 void Widget::handleEvent(Event* event) 
       
   247 { 
       
   248     if (event->type() == keydownEvent && event->isKeyboardEvent()) {
       
   249         KeyboardEvent* kevt = static_cast<KeyboardEvent*>(event);
       
   250         if (kevt->keyIdentifier() == "Enter") {
       
   251             MWebCoreWidget* view = getView();
       
   252             if(view && view->isObjectView()) {
       
   253                 view->activate();
       
   254             }
       
   255         }
       
   256     }
   242 }
   257 }
       
   258 
       
   259 }