// Path: java/anyremote/client/android/util/InfoMessage.java
// public class InfoMessage {
// 	public int id;
// 	public int stage;
// }
// 
// Path: java/anyremote/client/android/util/ProtocolMessage.java
// public class ProtocolMessage {
// 	public static final int FULL     = 0;
// 	public static final int FIRST    = 1;
// 	public static final int INTERMED = 2;
// 	public static final int LAST     = 3;
// 	
// 	public int id;
// 	public int stage;
// 	public Vector tokens;
// }


import android.content.Context;
import android.content.Intent;
import android.os.Bundle;
import android.os.Handler;
import android.widget.EditText;
import android.widget.Toast;
import android.widget.ToggleButton;
import android.text.Editable;
import android.text.InputType;
import android.text.TextWatcher;
import android.view.KeyEvent;
import android.view.MenuItem;
import android.view.View;
import android.view.WindowManager;
import android.view.inputmethod.BaseInputConnection;
import android.view.inputmethod.EditorInfo;
import android.view.inputmethod.InputConnection;
import android.view.inputmethod.InputMethodManager;
import anyremote.client.android.util.InfoMessage;
import anyremote.client.android.util.ProtocolMessage;
                    //imm.toggleSoftInputFromWindow(kView.getApplicationWindowToken(), InputMethodManager.SHOW_FORCED, 0);
                }
            }
        );*/
   }

    @Override
    protected void onStop() {
        log("onStop");
        super.onStop();
    }

    @Override
    protected void onDestroy() {
        log("onDestroy");
        anyRemote.protocol.removeMessageHandler(hdlLocalCopy);
        super.onDestroy();
    }

    @Override
    protected void onUserLeaveHint() {
        log("onUserLeaveHint");
        // no time to sending events
        // commandAction(anyRemote.protocol.context.getString(R.string.disconnect_item));
        if (!exiting && anyRemote.protocol.messageQueueSize() == 0) {
            log("onUserLeaveHint - make disconnect");
            anyRemote.protocol.disconnect(false);
        }
    }
    
// Path: java/anyremote/client/android/util/InfoMessage.java
// public class InfoMessage {
// 	public int id;
// 	public int stage;
// }
// 
// Path: java/anyremote/client/android/util/ProtocolMessage.java
// public class ProtocolMessage {
// 	public static final int FULL     = 0;
// 	public static final int FIRST    = 1;
// 	public static final int INTERMED = 2;
// 	public static final int LAST     = 3;
// 	
// 	public int id;
// 	public int stage;
// 	public Vector tokens;
// }


// Path: java/anyremote/client/android/KeyboardScreen.java
import android.content.Context;
import android.content.Intent;
import android.os.Bundle;
import android.os.Handler;
import android.widget.EditText;
import android.widget.Toast;
import android.widget.ToggleButton;
import android.text.Editable;
import android.text.InputType;
import android.text.TextWatcher;
import android.view.KeyEvent;
import android.view.MenuItem;
import android.view.View;
import android.view.WindowManager;
import android.view.inputmethod.BaseInputConnection;
import android.view.inputmethod.EditorInfo;
import android.view.inputmethod.InputConnection;
import android.view.inputmethod.InputMethodManager;
import anyremote.client.android.util.InfoMessage;
import anyremote.client.android.util.ProtocolMessage;

                    //imm.toggleSoftInputFromWindow(kView.getApplicationWindowToken(), InputMethodManager.SHOW_FORCED, 0);
                }
            }
        );*/
   }

    @Override
    protected void onStop() {
        log("onStop");
        super.onStop();
    }

    @Override
    protected void onDestroy() {
        log("onDestroy");
        anyRemote.protocol.removeMessageHandler(hdlLocalCopy);
        super.onDestroy();
    }

    @Override
    protected void onUserLeaveHint() {
        log("onUserLeaveHint");
        // no time to sending events
        // commandAction(anyRemote.protocol.context.getString(R.string.disconnect_item));
        if (!exiting && anyRemote.protocol.messageQueueSize() == 0) {
            log("onUserLeaveHint - make disconnect");
            anyRemote.protocol.disconnect(false);
        }
    }
    
    public void handleEvent(InfoMessage data) {