Looking for developers who love to write

by fpc0 » Wed, 30 Jun 2010 02:52:43 GMT


Sponsored Links
 We are launching a new mobile dev news portal and are looking for
developers of all platforms who would like to write feature articles,
tips, tricks and howtos for other developers. There will be a rev
share and plug as compensation. If interested and you would like to
know more please email d...@mobilemag.com

--



Other Threads

1. onKeyDown

Can someone tell me why the onKeyDown event never gets called here?
(even when a key is pressed)


import android.app.Activity;
import android.content.Context;
import android.graphics.Bitmap;
import android.graphics.BitmapFactory;
import android.graphics.Canvas;
import android.graphics.Color;
import android.os.Bundle;
import android.view.Display;
import android.view.KeyEvent;
import android.view.View;
import android.view.Window;
import android.view.WindowManager;

public class Tutorial2D extends Activity {

        public int ctr = 0;
        Bitmap bkGround;
        Bitmap _scratch;


        /** Called when the activity is first created. */
        @Override
        public void onCreate(Bundle savedInstanceState) {
                super.onCreate(savedInstanceState);

                requestWindowFeature(Window.FEATURE_NO_TITLE);
                setContentView(new Panel(this));
                bkGround = BitmapFactory.decodeResource(getResources(),
                                R.drawable.background_ocean);

                Display display = ((WindowManager)
getSystemService(Context.WINDOW_SERVICE))
                                .getDefaultDisplay();

                int wid = display.getWidth();
                int height = display.getHeight();

                bkGround = bkGround.createScaledBitmap(bkGround, wid, height, 
true);

                _scratch = BitmapFactory.decodeResource(getResources(),
R.drawable.icon);


        }

        class Panel extends View {
                public Panel(Context context) {
                        super(context);
                }


            @Override
            public boolean onKeyDown(int keyCode, KeyEvent msg) {
                        return false;
               // return thread.doKeyDown(keyCode, msg);
            }





                @Override
                public void onDraw(Canvas canvas) {

                        canvas.drawBitmap(bkGround, 0, 0, null);

                //      canvas.drawBitmap(_scratch, ctr % 200, 10, null);



                        ctr++;

                        invalidate();
                }
        }

}

-- 

2. Sample SoftKeyboard

Hi All,

I am using the sample soft keyboard source code available from the SDK
samples to write my own keyboard.

For my keyboard, instead of alphabets I am having words. E.g "Insert".
When user clicks this the word "Insert" will be inserted into the
respective field.

Under qwerty.xml, I can change the wordings of the keyboard, but how
to insert a word instead of a letter? Currently they are specifying
unicode to insert this.

Any idea how to modify to insert word instead of a alphabet?

Thanks In Advance,
Perumal

-- 

3. onConfigurationChanged call back is not getting called?

4. Android Newby here

5. URLClassLoader to load an Android application components dynamically

6. Final Class and Android Compatibility [CTS]

7. Android WhiteBoxTesting