Generic physical phone key to SDL key remapper, only dialog is implemented - it's not saved and not working yet

This commit is contained in:
pelya
2010-12-07 20:05:52 +02:00
parent dfb09282c8
commit 3dd4da9b0b
7 changed files with 114 additions and 15 deletions

View File

@@ -278,7 +278,12 @@ public class MainActivity extends Activity {
if( !downloader.DownloadComplete )
onStop();
}
return true;
else
if( keyRemapTool != null )
{
keyRemapTool.onKeyEvent(keyCode);
}
return true;
}
@Override
@@ -302,8 +307,8 @@ public class MainActivity extends Activity {
if( _btn != null )
return _btn.dispatchTouchEvent(ev);
else
if( _touchMeasurementTool != null )
_touchMeasurementTool.onTouchEvent(ev);
if( touchMeasurementTool != null )
touchMeasurementTool.onTouchEvent(ev);
return true;
}
@@ -369,7 +374,8 @@ public class MainActivity extends Activity {
private FrameLayout _videoLayout = null;
private EditText _screenKeyboard = null;
private boolean sdlInited = false;
public Settings.TouchMeasurementTool _touchMeasurementTool = null;
public Settings.TouchEventsListener touchMeasurementTool = null;
public Settings.KeyEventsListener keyRemapTool = null;
boolean _isPaused = false;
}