History

Merge branch 'ui-refactor' into m_and_m

Brad Davis committed 11 years ago

Commit fbdb9b12 parents 1ff8c67 9fbd5d731 files · +419 −323Browse files

Showing the changes to interface/src/Application.cpp (1 of 31 files). Show all

Unified · Split

interface/src/Application.cpp+10−4
@@ -84,7 +84,6 @@ · 83 unmodified lines
8484 #include <TextRenderer.h>
8585 #include <UserActivityLogger.h>
8686 #include <UUID.h>
87−#include <OAuthNetworkAccessManager.h>
8887 #include <MessageDialog.h>
8988
9089 #include <SceneScriptingInterface.h>
@@ -1101,6 +1100,11 @@ void Application::keyPressEvent(QKeyEvent* event) { · 1010 unmodified lines
11011100 bool isKeypad = event->modifiers().testFlag(Qt::KeypadModifier);
11021101 switch (event->key()) {
11031102 break;
1103+ case Qt::Key_Enter:
1104+ case Qt::Key_Return:
1105+ Menu::getInstance()->triggerOption(MenuOption::AddressBar);
1106+ break;
1107+
11041108 case Qt::Key_L:
11051109 if (isShifted && isMeta) {
11061110 Menu::getInstance()->triggerOption(MenuOption::Log);
@@ -1533,9 +1537,11 @@ void Application::mouseReleaseEvent(QMouseEvent* event, unsigned int deviceID) { · 426 unmodified lines
15331537 }
15341538
15351539 void Application::touchUpdateEvent(QTouchEvent* event) {
1536− TouchEvent thisEvent(*event, _lastTouchEvent);
1537− _controllerScriptingInterface.emitTouchUpdateEvent(thisEvent); // send events to any registered scripts
1538− _lastTouchEvent = thisEvent;
1540+ if (event->type() == QEvent::TouchUpdate) {
1541+ TouchEvent thisEvent(*event, _lastTouchEvent);
1542+ _controllerScriptingInterface.emitTouchUpdateEvent(thisEvent); // send events to any registered scripts
1543+ _lastTouchEvent = thisEvent;
1544+ }
15391545
15401546 // if one of our scripts have asked to capture this event, then stop processing it
15411547 if (_controllerScriptingInterface.isTouchCaptured()) {