[android-developers] Android Intent setSelector

2014-11-21 Thread LiTTle


Why when I use setSelector method it returns neither Camera activities nor 
Gallery Activities.I have the following code:

protected void onCreate(Bundle savedInstanceState) {
super.onCreate(savedInstanceState);
setContentView(R.layout.activity_main);

Intent camera= new Intent(android.media.action.IMAGE_CAPTURE);

Intent gallery = new Intent();  
gallery.setAction(android.content.Intent.ACTION_VIEW);  
gallery.setType(image/*);
gallery.setFlags(Intent.FLAG_ACTIVITY_NEW_TASK);

camera.setSelector(gallery);

startActivity(camera);}

According to Android's reference API *If the selector is set, it will be 
used when trying to find entities that can handle the Intent, instead of 
the main contents of the Intent.*

I thought that I will get a dialog that opens the gallery instead of 
camera. But, instead of these I got a dialog that returns arbitrary 
applications/activities, such as *Call Settings*, *Network Settings*, *SIM 
Toolkit*, etc.

When I remove the camera.setSelector(gallery); method everything works like 
a charm, but when I use camera.setSelector(gallery); method it returns 
neither Camera activities nor Gallery Activities.
Could somebody explain me why I got a dialog with these arbitrary 
activities instead of appropriate?

I don't want to remove the camera.setSelector(gallery); because I am trying 
to understand how it works!

-- 
You received this message because you are subscribed to the Google
Groups Android Developers group.
To post to this group, send email to android-developers@googlegroups.com
To unsubscribe from this group, send email to
android-developers+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/android-developers?hl=en
--- 
You received this message because you are subscribed to the Google Groups 
Android Developers group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to android-developers+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


[android-developers] ListView problem while scrolling

2012-09-01 Thread LiTTle
Hi everyone,

I am trying 4 days to solve this problem. I am trying to create the 
following feature:
I have a ListView that the user can select an item. When the user selects 
the item the text will turn to pink. The ListView shows 6 items at once. 
You have to scroll to see other 6 and go on.
But there is a problem:
When i scroll the ListView the item No8, No15,... are pink too! 
Any help, ideas (even if you think you are wrong) are welcomed. I am 
freaking out more and more every day.
Thanks a lot for your time spent reading my issue!

Here is the code inside for my adapter:

public class MyListAdapter extends ArrayAdapterString {

private Context ctx;
private String[] values;
private ArrayListString mData =new ArrayListString();
private ViewHolder holder=null;
private LayoutInflater inflater;
 public MyListAdapter(Context context, int textViewResourceId, String[] 
values) {
super(context, textViewResourceId, values);

ctx = context;
inflater = (LayoutInflater) ctx
.getSystemService(Context.LAYOUT_INFLATER_SERVICE);
this.values = values;
for (int i = 0; i  values.length; i++) {
addItem(values[i]);
}
}
 public void addItem(final String item) {
mData.add(item);
notifyDataSetChanged();
}
 @Override
public String getItem(int position) {
return mData.get(position);
}

@Override
public long getItemId(int position) {
return position;
}

@Override
public int getCount() {
// TODO Auto-generated method stub
return mData.size();
}

/* (non-Javadoc)
 * @see android.widget.ArrayAdapter#getView(int, android.view.View, 
android.view.ViewGroup)
 */
@Override
public View getView(int position, View convertView, ViewGroup parent) {
 
if(convertView==null){
convertView = inflater.inflate(R.layout.list_item, parent, false);
holder = new ViewHolder();
holder.textView = 
(TextView)convertView.findViewById(R.id.item_textView);
convertView.setTag(holder);
 }
else{
holder = (ViewHolder)convertView.getTag();
}
holder.textView.setText(mData.get(position));
holder.textView.setOnClickListener(new OnClickListener() {

@Override
public void onClick(View view) {
for(int i=0; igetCount(); i++){
 }
((ViewHolder)view.getTag()).textView.setTextColor(ctx.getResources().
getColor(R.color.pink));
}
});
return convertView;
}
 public static class ViewHolder {
public TextView textView;
}

}
///

-- 
You received this message because you are subscribed to the Google
Groups Android Developers group.
To post to this group, send email to android-developers@googlegroups.com
To unsubscribe from this group, send email to
android-developers+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/android-developers?hl=en

Re: [android-developers] ListView problem while scrolling

2012-09-01 Thread LiTTle
I cannot believe it that is was a simple line! Thank you very much. I feel 
much more relaxed now.

-- 
You received this message because you are subscribed to the Google
Groups Android Developers group.
To post to this group, send email to android-developers@googlegroups.com
To unsubscribe from this group, send email to
android-developers+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/android-developers?hl=en

[android-developers] Re: ListView problem while scrolling

2012-09-01 Thread LiTTle
It is me again!!! When I select the first item and then I did everything 
Mr. Mark Murphy said when I scroll down and then come back to the top, the 
first item is black again instead of pink? Is there any way to store this 
option (for example selected=true) and repaint the same object as pink the 
next time I come across with this item?

-- 
You received this message because you are subscribed to the Google
Groups Android Developers group.
To post to this group, send email to android-developers@googlegroups.com
To unsubscribe from this group, send email to
android-developers+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/android-developers?hl=en

[android-developers] StaleDataException occur when running on Ice Cream sandwich?

2012-07-23 Thread Little Charm
Hello 

I have a problem with my application that is working on previous version 
Android when resuming the application. I have used managedQuery and I knew 
that it was being deprecated but since I want to target for older version 
as well.  

Everything works fine if I am not click back or moving the application or 
activity to the background and resuming the application again. When I am 
going to resume the activity  either click on back button or bring it 
forward the application from background, the application closed and the 
error saying StaleDataException and saying that I am attempting to access 
the cursor the is already been closed.

I have a gridview that is loaded the data using CursorAdapter to populate 
the thumbnail images. When I looked at it , I have not closed the 
managedQuery myself. so why does it have no problem on older version but in 
ice cream sandwich OS.

-- 
You received this message because you are subscribed to the Google
Groups Android Developers group.
To post to this group, send email to android-developers@googlegroups.com
To unsubscribe from this group, send email to
android-developers+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/android-developers?hl=en

[android-developers] Android Source Code

2012-02-17 Thread LiTTle
Hello everyone,

I have downloaded (I think so) the source code from the built-in
applications of Android 4. I have already download the source code
from the appropriate branch Android 4.0.3_r1 (I cannot remember
exactly). I want to change a little bit the Home application! I took
the whole folder Launcher2 from the packages/apps/. I imported to
the eclipse as a new project! And a lot of errors appeared (undeclared
variables, undefined methods, etc). How the source is built? With
errors?

Is there any way to edit the applications that come with the Android
platform? I have started to believe that the Android project is not as
open as it is said to be!

-- 
You received this message because you are subscribed to the Google
Groups Android Developers group.
To post to this group, send email to android-developers@googlegroups.com
To unsubscribe from this group, send email to
android-developers+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/android-developers?hl=en


[android-developers] Get Key events from anywhere

2011-11-24 Thread LiTTle
Hi,

I would like to run my application using a key press (hardware
button) shortcut or run it when I unlock my phone! Is it possible to
get key events anytime by using a Receiver or a Service?

The best thing I achieved is with USER_PRESENT but it is not what I
want!

Thanks for your time spent reading my question!

-- 
You received this message because you are subscribed to the Google
Groups Android Developers group.
To post to this group, send email to android-developers@googlegroups.com
To unsubscribe from this group, send email to
android-developers+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/android-developers?hl=en


[android-developers] Re: Break the execution

2011-09-29 Thread LiTTle
I don't understand your question very much but I think that you could
add break;

Could you explain better what do you mean, because someone will read
this conversation in the future for help.

-- 
You received this message because you are subscribed to the Google
Groups Android Developers group.
To post to this group, send email to android-developers@googlegroups.com
To unsubscribe from this group, send email to
android-developers+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/android-developers?hl=en


[android-developers] Re: Android autogenerated R file

2011-09-02 Thread LiTTle
As I have read xml parsers load all the content to the memory. Our
purpose is to put all Patra's shops in this application. Patra has
approximately 1 shops! Each shop has street,telephone,fax etc
(have 8 parts of data) so whole data will be 8! It is really big
xml to load to memory and also it is harder to maintain the data!

Indicator Veritatis, do you speak greek?Are you from Greece?

-- 
You received this message because you are subscribed to the Google
Groups Android Developers group.
To post to this group, send email to android-developers@googlegroups.com
To unsubscribe from this group, send email to
android-developers+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/android-developers?hl=en


[android-developers] Re: Android autogenerated R file

2011-09-02 Thread LiTTle
There 2 reasons I didn't use database:

1. I cannot imagine a helpful scheme of tables to use!

2. I want my colleagues to have the ability to add new shops easily!
It's easier to tell them to do some copy-paste work. In case I use db
they have to download a db browser, execute any sql command (if
needed) etc.

My current design is:
assets
   Category_Car
  Rent.xml
  Repair.xml
   Category_Education
  Libraries.xml

It is working just fine! Any idea about a db scheme is accepted! I
hope that I don't waste your time.

-- 
You received this message because you are subscribed to the Google
Groups Android Developers group.
To post to this group, send email to android-developers@googlegroups.com
To unsubscribe from this group, send email to
android-developers+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/android-developers?hl=en


[android-developers] Re: Android autogenerated R file

2011-09-02 Thread LiTTle
Nikolay I cannot understand!
Could you be more specific about pre-GB devices,512, IIRC?
Or could you send me a link to read the whole article/document?

-- 
You received this message because you are subscribed to the Google
Groups Android Developers group.
To post to this group, send email to android-developers@googlegroups.com
To unsubscribe from this group, send email to
android-developers+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/android-developers?hl=en


[android-developers] Android autogenerated R file

2011-09-01 Thread LiTTle
Hi,

I found a way to call the variables from R file which are generated
automatically without using their names but through a for block. I
believe that the algorithm is something like that. I don't say that
this is the algorithm but I imagine it!

///
items = array of variables;
i=0;
for ( file: xml_files ){
  items[i] = read the first item from file;
  i++;
}

sort items;
for (item:items){
  write to R file the contents of xml file where the item variable
exists
}

/
And now a little (actually I mean a lot) of my code. 2 xml files are
following (zzzShops_18_29.xml,
zzzShops_18_28.xml).
  zzzShops_18_29.xml  /
?xml version=1.0 encoding=utf-8?
resources
!-- Write the shops using alphabetical order to this array--
!-- Change the value Shops_XX_XX_count @ GuideActivity if the string
arrays
here (and to every zzzShops_XX_XX.xml file) get
increased or
decreased.  --
string-array name=aaaShops_18_29_name
itemValue_Name/item!-- 0 --
/string-array
string-array name=aaaShops_18_29_street
itemValue_Street/item!-- 0 --
/string-array
string-array name=aaaShops_18_29_tel
itemValue_Tel/item!-- 0 --
/string-array
string-array name=aaaShops_18_29_mob
itemValue_Mob/item!-- 0 --
/string-array
string-array name=aaaShops_18_29_fax
itemValue_Fax/item!-- 0 --
/string-array
string-array name=aaaShops_18_29_site
itemValue_Site/item!-- 0 --
/string-array
string-array name=aaaShops_18_29_email
itemValue_Email/item!-- 0 --
/string-array
string-array name=aaaShops_18_29_map
itemx,x/item!-- 0 --
/string-array
/resources
/
  zzzShops_18_28.xml  /
?xml version=1.0 encoding=utf-8?
resources
!-- Write the shops using alphabetical order to this array--
!-- Change the value Shops_XX_XX_count @ GuideActivity if the string
arrays
here (and to every zzzShops_XX_XX.xml file) get
increased or
decreased.  --
string-array name=aaaShops_18_28_name
itemValue_Name/item!-- 0 --
/string-array
string-array name=aaaShops_18_28_street
itemValue_Street/item!-- 0 --
/string-array
string-array name=aaaShops_18_28_tel
itemValue_Tel/item!-- 0 --
/string-array
string-array name=aaaShops_18_28_mob
itemValue_Mob/item!-- 0 --
/string-array
string-array name=aaaShops_18_28_fax
itemValue_Fax/item!-- 0 --
/string-array
string-array name=aaaShops_18_28_site
itemValue_Site/item!-- 0 --
/string-array
string-array name=aaaShops_18_28_email
itemValue_Email/item!-- 0 --
/string-array
string-array name=aaaShops_18_28_map
itemx,x/item!-- 0 --
/string-array
/resources
//
The contents of the R file depending on the previous files are:
/
public static final int aaaShops_18_28_email=0x7f04018b;
/**  0
 */
public static final int aaaShops_18_28_fax=0x7f040189;
/**  0
 */
public static final int aaaShops_18_28_map=0x7f04018c;
/**  0
 */
public static final int aaaShops_18_28_mob=0x7f040188;
/**  ?-?? / ??
 Write the shops using alphabetical order to this array
 Change the value Shops_XX_XX_count @ GuideActivity if the string
arrays
here (and to every zzzShops_XX_XX.xml file) get
increased or
decreased.
 0
 */
public static final int aaaShops_18_28_name=0x7f040185;
/**  0
 */
public static final int aaaShops_18_28_site=0x7f04018a;
/**  0
 */
public static final int aaaShops_18_28_street=0x7f040186;
/**  0
 */
public static final int aaaShops_18_28_tel=0x7f040187;
/**  0
 */
public static final int aaaShops_18_29_email=0x7f040193;
/**  0
 */
public static final int aaaShops_18_29_fax=0x7f040191;
/**  0
 */
public static final int aaaShops_18_29_map=0x7f040194;
/**  0
 */
public static final int aaaShops_18_29_mob=0x7f040190;
/**  ?-?? / ???
 Write the shops using alphabetical order to this array
 Change the value Shops_XX_XX_count @ GuideActivity if the string
arrays
here (and to every zzzShops_XX_XX.xml file) get
increased or
decreased.
 0
 */
public static final int aaaShops_18_29_name=0x7f04018d;
/**  0
 */
public static final int aaaShops_18_29_site=0x7f040192;
/**  0
 */
public static final int

[android-developers] Re: Android autogenerated R file

2011-09-01 Thread LiTTle
I can parse the variables I want from the R file without knowing the
name of every variable!
I could build an array that contains the variables!

-- 
You received this message because you are subscribed to the Google
Groups Android Developers group.
To post to this group, send email to android-developers@googlegroups.com
To unsubscribe from this group, send email to
android-developers+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/android-developers?hl=en


[android-developers] Re: Android autogenerated R file

2011-09-01 Thread LiTTle
In the future maybe I am going to use a lot of string (specials for
me) elements (now I use only 249 variables). But the problem is if I
want to call every string I have to create over 100 'if' blocks. One
'if' block is going to be inside the other. But, now I know that the
variable I want is the 31st for example, so I say to my code int
varWanted=R.array.Var0+31.

Without using this:
if(selected==0){
get this
}

if(selected==31){
get this
}
.
and go on with 'if' blocks until 249

And I want to use the xml file to reduce the size of the final
runnable file.

-- 
You received this message because you are subscribed to the Google
Groups Android Developers group.
To post to this group, send email to android-developers@googlegroups.com
To unsubscribe from this group, send email to
android-developers+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/android-developers?hl=en


[android-developers] Re: Android autogenerated R file

2011-09-01 Thread LiTTle
I am using this xml file for array. Thanks for the conversation!
Here is the whole problem. We have this website www.patra-city-guide.gr.
Here we have some categories with subcategories with shops (31 for
now). Every shop has address,site,mail etc.

So actually I need an array that have these shops depending on
category. For example
show me the address from the first shop from the first subcategory
from the second subcategory!

And the R file is the faster because I tell: var
street=R.array.FirstStreetShop+10
and the value returned to me in no time!

If I use simple xml file it will be a big one and it will take a lot
of time.

Do you have any good idea? I'm out of ideas that's why I catch the R
file!!!

-- 
You received this message because you are subscribed to the Google
Groups Android Developers group.
To post to this group, send email to android-developers@googlegroups.com
To unsubscribe from this group, send email to
android-developers+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/android-developers?hl=en


[android-developers] Re: Android autogenerated R file

2011-09-01 Thread LiTTle
My answer is never uploaded!

-- 
You received this message because you are subscribed to the Google
Groups Android Developers group.
To post to this group, send email to android-developers@googlegroups.com
To unsubscribe from this group, send email to
android-developers+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/android-developers?hl=en


[android-developers] Re: Android autogenerated R file

2011-09-01 Thread LiTTle
I am going to use multiple xml files with simple parsers or database.
In the back side of my mind I know that's bad. But I wanted to ask if
this is accepted.
I thought that maybe it is a feature that Google let it happen. That's
all.
Thanks again everyone.

-- 
You received this message because you are subscribed to the Google
Groups Android Developers group.
To post to this group, send email to android-developers@googlegroups.com
To unsubscribe from this group, send email to
android-developers+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/android-developers?hl=en


[android-developers] Android R file question

2011-08-28 Thread LiTTle
Hi all,

I am working in a project which is going to be at the android market.
I want to have good reviews and no uninstalls from the users. My
application has 17 categories. Each category has subcategories( from 5
to 42 subcategory items). I used xml array file. The R file is updated
and I found this:
-each entry gets a hexadecimal number.
-first hexadecimal number is the variable which is first in
alphabetical order.

So I decided to create a 'for' block to access every R variable, by
increasing the hexadecimal number. Is it possible this or R file
creates another variables during the runtime?

For example instead of R.array.var1 I will use 0x7f040015.

-- 
You received this message because you are subscribed to the Google
Groups Android Developers group.
To post to this group, send email to android-developers@googlegroups.com
To unsubscribe from this group, send email to
android-developers+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/android-developers?hl=en


[android-developers] Android Start up

2011-05-11 Thread LiTTle
Hi everyone,

I am new in android development. I am coming from J2ME. I am trying to
build my first Android application. The application is Hello World
as it is described at Google's guidelines. I use Eclipse Editor to
create the application and I followed the steps as Pro Android 2
said. The preblems are the following:
1). Android emulator starts with the delay of 7 minutes!!! I use my
netbook to create the app. Is it normal this delay?
2). Apart from this delay, after the emulator starts successfully my
application is never executed!!!

PS: The code sample I use is the example with the TextView (http://
developer.android.com/resources/tutorials/hello-world.html)

-- 
You received this message because you are subscribed to the Google
Groups Android Developers group.
To post to this group, send email to android-developers@googlegroups.com
To unsubscribe from this group, send email to
android-developers+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/android-developers?hl=en


[android-developers] Text will not draw properly

2011-03-18 Thread Little Coding Fox
I'm drawing text to a canvas, but the text is not rendered properly
into the bitmap. I create a GL Texture and render it to the screen
with a full-screen quad. This is the result: http://i56.tinypic.com/259lthw.png

Here's the code I'm using:

Bitmap me = Bitmap.createBitmap(320, 80, Bitmap.Config.ARGB_);
Canvas canvas = new Canvas(me);
me.eraseColor(0);
Paint p = new Paint();
p.setTextSize(16);
p.setColor(Color.BLUE);
canvas.drawText(ABCDEFGHIJKLMNOPQRSTUVWXYZ, 0, 30, p);

Then I create the texture with:

int[] textureHolder = new int[1];

gl.glGenTextures(1, textureHolder, 0);
textureID = textureHolder[0];
gl.glBindTexture(GL10.GL_TEXTURE_2D, textureID);
GLUtils.texImage2D(GL10.GL_TEXTURE_2D, 0, me, 0);

me.recycle();

If i use a shorter string like 123, nothing shows up. If i set the
coords to 0, 0, barely anything shows up. Does anyone have any idea
what i could be doing wrong?

-- 
You received this message because you are subscribed to the Google
Groups Android Developers group.
To post to this group, send email to android-developers@googlegroups.com
To unsubscribe from this group, send email to
android-developers+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/android-developers?hl=en


[android-developers] onDraw method of CustomView do not redraw Canvas.

2010-11-17 Thread little boy
I made CustomView like under code.
---
public class CustomView extends View{

protected void onDraw(Canvas canvas){
   //  Do somthing like drawing Canvas and some logic in NDK

}

}
-

and I made layout.xml file like that.
--
LinearLayout
  xmlns:android=http://schemas.android.com/apk/res/android;
  xmlns:ui=http://schemas.android.com/apk/res/
org.sugang.android.priv.keyboard
  android:layout_width=fill_parent
  android:layout_height=fill_parent android:orientation=vertical
Button android:text=button android:id=@+id/Button
android:layout_width=wrap_content
android:layout_height=wrap_content/Button

  EditText android:text= android:id=@+id/EditText01
android:layout_width=wrap_content
android:layout_height=wrap_content android:inputType=none /
EditText

  com.my.CustomView android:id=@+id/customView
android:layout_width=fill_parent
android:layout_height=fill_parent 
  /com.my.CustomView 
/LinearLayout
-

when button is clicked, click event set some text to EditText01.
then onDraw method of CustomView is called.
I think that onDraw method can be called ,as setText method can chang
size of EditText01 and CustomView can be moved.
but When I click button and EditText01 size do not chang, onDraw
method is called.
besides, onDraw method do not redraw Canvas in NDK.
some logic in NDK work correctly.
I want to all or nothing.(some logic and redrawing Canvas work or
anything do not work)

I think that onDraw must not be called, when position is not changed.
Unfortunately onDraw is called.

How can I protect onDraw is called?

How can I get if CustomView posion be changed or not?
if I know that postion is not changed in onDraw of CustomView, I will
protect some logic in NDK.



-- 
You received this message because you are subscribed to the Google
Groups Android Developers group.
To post to this group, send email to android-developers@googlegroups.com
To unsubscribe from this group, send email to
android-developers+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/android-developers?hl=en


[android-developers] Favor From a Developer With a Samsung Moment

2010-03-24 Thread Little Killers
The game crashes when it starts on this phone and only this phone very
odd

Can some one with a Samsung Moment Down load our app Bad-A** Game Lite
and connect it to the debugger and give us the stacktrace.

Thanks a bunch!!!
Chad

-- 
You received this message because you are subscribed to the Google
Groups Android Developers group.
To post to this group, send email to android-developers@googlegroups.com
To unsubscribe from this group, send email to
android-developers+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/android-developers?hl=en

To unsubscribe from this group, send email to 
android-developers+unsubscribegooglegroups.com or reply to this email with the 
words REMOVE ME as the subject.


[android-developers] Prepare failed in MediaRecorder

2009-07-06 Thread Jack Little

Hello,
I am trying to develop an appliacation with Android 1.5(cupcake_r1)
for a week
but always get an error reported in prepare of MediaRecorder.
Can anybody help me to figure out the problem I got in the code
below:

PS. In order to figure out the problem, I suppressed the audio
recording, and
the SDcard is installed in the phone. Thanks for your help!

in \packages\apps\Camera\src\com\android\camera\VideoCamera.java

in method initializeVideo()
{
   mMediaRecorder = new MediaRecorder();
if (DEBUG_SUPPRESS_AUDIO_RECORDING) {
Log.v(TAG, DEBUG_SUPPRESS_AUDIO_RECORDING is true.); //
this will be done!
} else {
mMediaRecorder.setAudioSource
(MediaRecorder.AudioSource.MIC);
}
mMediaRecorder.setVideoSource
(MediaRecorder.VideoSource.CAMERA);
mMediaRecorder.setOutputFormat
(MediaRecorder.OutputFormat.THREE_GPP);
mMediaRecorder.setMaxDuration(MAX_RECORDING_DURATION_MS);
if (mStorageStatus != STORAGE_STATUS_OK) {
mMediaRecorder.setOutputFile(/dev/null);
} else {
if (mCameraVideoFileDescriptor != null) {
mMediaRecorder.setOutputFile
(mCameraVideoFileDescriptor);
} else {
createVideoPath();
mMediaRecorder.setOutputFile(mCameraVideoFilename);
}
}

boolean videoQualityHigh = getBooleanPreference
(CameraSettings.KEY_VIDEO_QUALITY,
CameraSettings.DEFAULT_VIDEO_QUALITY_VALUE);

if (intent.hasExtra(MediaStore.EXTRA_VIDEO_QUALITY)) {
int extraVideoQuality = intent.getIntExtra
(MediaStore.EXTRA_VIDEO_QUALITY, 0);
videoQualityHigh = (extraVideoQuality  0);
}

mMediaRecorder.setVideoFrameRate(15);
if (videoQualityHigh) {
mMediaRecorder.setVideoSize(320,240);
} else {
mMediaRecorder.setVideoSize(176,144);
}
mMediaRecorder.setVideoEncoder
(MediaRecorder.VideoEncoder.H263);
if (!DEBUG_SUPPRESS_AUDIO_RECORDING) {
mMediaRecorder.setAudioEncoder
(MediaRecorder.AudioEncoder.AMR_NB);
}
mMediaRecorder.setPreviewDisplay(mSurfaceHolder.getSurface());

long remaining = getAvailableStorage();

try {
mMediaRecorder.setMaxFileSize(remaining -
LOW_STORAGE_THRESHOLD / 4);
} catch (RuntimeException exception) {
   }

try {
mMediaRecorder.prepare();
} catch (IOException exception) {
Log.e(TAG, prepare failed for  + mCameraVideoFilename);
releaseMediaRecorder();
return false;
}
mMediaRecorderRecording = false;

if (!mIsVideoCaptureIntent  !mThumbController.isUriValid())
{
updateLastVideo();
}

if (!mIsVideoCaptureIntent) {
mThumbController.updateDisplayIfNeeded();
}

return true;
}


and the logcat shows below:

I/ActivityManager(   85): Starting activity: Intent
{ action=android.intent.action.MAIN categories=
{android.intent.category.LAUNCHER} flags=0x1020 comp=
{com.android.camera/com.android.camera.VideoCamera} }
I/ActivityManager(   85): Start proc com.android.camera for activity
com.android.camera/.VideoCamera: pid=279 uid=1 gids={1006, 2001,
3003}
D/dalvikvm(   85): GC freed 7528 objects / 374056 bytes in 680ms
I/WindowManager(   85): Setting rotation to 1, animFlags=0
I/WindowManager(   85): Config changed: { scale=1.0 imsi=0/0
locale=en_US touch=3 key=2/1/2 nav=3 orien=2 }
I/ARMAssembler(   85): generated
scanline__0077:03010104_0004_ [ 22 ipp] (41 ins) at
[0x21eb98:0x21ec3c] in 427246 ns
W/WindowManager(   85): performLayoutAndPlaceSurfacesLocked called
while in layout
W/WindowManager(   85): performLayoutAndPlaceSurfacesLocked called
while in layout
I/ARMAssembler(   85): generated
scanline__0077:03545404_0004_ [ 47 ipp] (67 ins) at
[0x18c230:0x18c33c] in 610351 ns
D/StatusBar(   85): updateResources
D/LocationManager(  279): Constructor: service =
android.location.ilocationmanager$stub$pr...@4360c228
V/ImageManager(  279): storage state is mounted
V/ImageManager(  279): storage writable is true
V/videocamera(  279): initializeVideo
V/videocamera(  279): Releasing media recorder.
V/videocamera(  279): SurfaceHolder is null
I/VideoPreview(  279):  setting size: 320x240
I/VideoPreview(  279): ar 1.334 setting size: 320x240
V/videocamera(  279): stopVideoRecording
V/videocamera(  279): initializeVideo
V/videocamera(  279): Releasing media recorder.
V/MediaRecorder(  279): constructor
V/PVMediaRecorder(   55): constructor
V/AuthorDriver(   55): InitializeForThread
V/AuthorDriver(   55): OMX_Init
V/AuthorDriver(   55): Create author ...
V/MediaRecorder(  279): doCleanUp
V/MediaRecorder(  279): setListener
V/videocamera(  279): DEBUG_SUPPRESS_AUDIO_RECORDING is true.
V/MediaRecorder(  279): setVideoSource(1)
V/MediaRecorder(  279): Call init() since the media 

[android-developers] market upload issues

2009-01-28 Thread little boy

hai friends,

 I have one problem when uploading my application to
market.when i am uploading, it shows The certificate that signed this
apk is not valid until future,create a new certificate.Anyone please
help me.I created a key using keytool and signed using jarsigner.still
i am getting this prolem.I specified validity as 2 days.Please
help me.


--~--~-~--~~~---~--~~
You received this message because you are subscribed to the Google
Groups Android Developers group.
To post to this group, send email to android-developers@googlegroups.com
To unsubscribe from this group, send email to
android-developers-unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/android-developers?hl=en
-~--~~~~--~~--~--~---