2

I am making a launcher for android, where it is only usable in landscape. Half of the screen is buttons, not apps, but buttons, and half is simply some clocks and stuff. I want my buttons to glow for like for a second or something once i touch them, which is followed by an animation to show a different screen. I only need help with the glow. Please help me and thanks so much!

This is my xml:

<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
xmlns:tools="http://schemas.android.com/tools"
android:id="@+id/mainLayout"
android:layout_width="match_parent"
android:layout_height="match_parent"
android:background="@drawable/wallpaper" >

<LinearLayout
    android:layout_width="wrap_content"
    android:layout_height="match_parent" >

</LinearLayout>


<GridView
    android:id="@+id/gridView1"
    android:layout_width="284dp"
    android:layout_height="wrap_content"
    android:numColumns="3" >

</GridView>

I would also like to know how i can add the imagebuttons to my gridview

my java code:

package com.mysoftware.mysoftwareos.launcher;

import android.app.Activity;
import android.os.Bundle;
import android.view.KeyEvent;
import android.view.View;
import android.view.View.OnClickListener;
import android.widget.LinearLayout;

public class MainActivity extends Activity implements OnClickListener {
LinearLayout mainLayout;
@Override
public void onCreate(Bundle savedInstanceState) {
    super.onCreate(savedInstanceState);
    setContentView(R.layout.activity_main);

    //Import views
    mainLayout = (LinearLayout)findViewById(R.id.mainLayout);

    //Setup onClickListener for the buttons

}
@Override
public boolean onKeyDown(int KeyCode, KeyEvent event) {
    if ((KeyCode == KeyEvent.KEYCODE_BACK)) {
        //Do nothing to prevent the back button to kill the launcher
        return true;
    }
    return super.onKeyDown(KeyCode, event);
}
public void onClick(View src) {
    switch(src.getId()) {
    }
}
}
user1446632
  • 417
  • 2
  • 9
  • 24
  • I recommend you create a base glow animation and apply the animation to any views you wanted to. You will also might check this link: http://goo.gl/Zy5uN – Thiago M Rocha Oct 04 '12 at 18:57
  • Yeah, but the problem is that i have NO idea on how to create an animation or apply it, the website you linked to was just tons of code and i have no idea of what to look for – user1446632 Oct 04 '12 at 19:13
  • Plz read [this](http://stackoverflow.com/questions/10580052/how-to-make-glow-effect-in-my-images) link I have tried this code and is working.Let me know if yu are facing any issue – user1720927 Oct 04 '12 at 19:54

0 Answers0