android-2.1-eclair

How to decrease the size of image displayed on radio button in android without using new image

喜你入骨 提交于 2019-12-01 08:35:36
问题 I have designed an activity in which i have two radio button but those size are more than enough i want to decrease it i am using text size that decreases only text if layout size is decrease that decrease only view not radio button circle <RadioGroup android:id="@+id/RG1" android:layout_width="wrap_content" android:layout_height="wrap_content" android:orientation="horizontal" > <RadioButton android:id="@+id/N" android:layout_width="wrap_content" android:layout_height="30dip" android:text=

Android:Translation and Rotation Animation simultaneously

半城伤御伤魂 提交于 2019-11-30 13:39:58
I want to show two animation simultaneously programatically not in XML file.It should ROTATE and TRANSLATE how can I do that? Please suggest me some way?????? Here is ma code:> ImageView snowImg1 = (ImageView) findViewById(R.id.snowimg1); snowImg1.setVisibility(0); ImageView snowImg2 = (ImageView) findViewById(R.id.snowimg2); snowImg2.setVisibility(0); ImageView snowImg3 = (ImageView) findViewById(R.id.snowimg3); snowImg3.setVisibility(0); ImageView snowImg4 = (ImageView) findViewById(R.id.snowimg4); snowImg4.setVisibility(0); ImageView snowImg6 = (ImageView) findViewById(R.id.snowimg6);

Android start activity on Menu Item selection

蹲街弑〆低调 提交于 2019-11-30 09:08:49
I have 2 classes. One will be a basic instructions screen and on that screen it will have a menu that will let you go to the other class. The other class is a MapActivity. I believe the problem is that its not finding the other class. I've tried a few different ways of declaring the intent to find the class. This is the latest thing I've tried: @Override public boolean onCreateOptionsMenu(Menu menu){ MenuInflater inflater = getMenuInflater(); inflater.inflate(R.menu.mainmenu, menu); return true; } @Override public boolean onOptionsItemSelected(MenuItem item){ switch(item.getItemId()){ case R

Android:Translation and Rotation Animation simultaneously

旧时模样 提交于 2019-11-29 19:06:55
问题 I want to show two animation simultaneously programatically not in XML file.It should ROTATE and TRANSLATE how can I do that? Please suggest me some way?????? Here is ma code:> ImageView snowImg1 = (ImageView) findViewById(R.id.snowimg1); snowImg1.setVisibility(0); ImageView snowImg2 = (ImageView) findViewById(R.id.snowimg2); snowImg2.setVisibility(0); ImageView snowImg3 = (ImageView) findViewById(R.id.snowimg3); snowImg3.setVisibility(0); ImageView snowImg4 = (ImageView) findViewById(R.id

how can I pass a variable into a new Runnable declaration? [duplicate]

不羁的心 提交于 2019-11-29 02:28:32
问题 This question already has answers here : How can I pass a parameter to a Java Thread? (18 answers) Closed 2 years ago . I have the following : Runnable done = new Runnable() { public void run() { System.out.println("Hello"); } }; And then in my Android activity I'll call something like : runOnUIThread(done); Which I then call. However, I want that "Hello" not to be hardcoded, so I can pass it in. Otherwise I'll have to have one of these declarations for every String I want to print. (This is

How can I force a GridView to use the whole screen (regardless of display size)?

ε祈祈猫儿з 提交于 2019-11-28 09:24:11
I've got the following layout file, which has a GridView and an ImageView behind that as the background. <?xml version="1.0" encoding="utf-8"?> <FrameLayout xmlns:android="http://schemas.android.com/apk/res/android" android:layout_width="fill_parent" android:layout_height="fill_parent" android:background="#FFFFFF"> <ImageView android:layout_width="wrap_content" android:layout_height="wrap_content" android:layout_gravity="bottom|right" android:layout_marginRight="-70dp" android:layout_marginBottom="-50dp" android:src="@drawable/s_background"/> <LinearLayout xmlns:android="http://schemas.android