Android Open Source - android-bluetooth-mouse Mouse View

From Project

Back to project page android-bluetooth-mouse.


The source code is released under:

MIT License

If you think the Android project android-bluetooth-mouse listed in this page is inappropriate, such as containing malicious code/tools or violating the copyright, please email info at java2s dot com, thanks.

Java Source Code

package org.hbabcock.adbtm;
/* w  w  w.j  av  a 2 s  .  c  om*/
import android.content.Context;
import android.util.AttributeSet;
import android.util.Log;
import android.view.View;

public class MouseView extends View {
  private static final boolean DEBUG = true;
    private static final String TAG = "MouseView";

    public int height = 0;
  public int width = 0;

  public MouseView(Context context, AttributeSet attrs) {
    super(context, attrs);
    protected void onSizeChanged(int new_width, int new_height, int xOld, int yOld)
      super.onSizeChanged(new_width, new_height, xOld, yOld);
      width = new_width;
      height = new_height;

      if (DEBUG) Log.i(TAG, "onSizeChanged," + width + "," + height);    


Java Source Code List