[android-developers] Re: Android 4.1 Jelly Bean GIF Images Not Showing?

2012-07-04 Thread Subramanya Somayaji
We have no Idea What are the webkit changes,updates in Jeallybean!! 

-- 
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 4.1 Jelly Bean GIF Images Not Showing?

2012-07-04 Thread Zsolt Vasvari
And we have no idea why you mention Webkit.  

On Wednesday, July 4, 2012 2:03:29 PM UTC+8, Subramanya Somayaji wrote:

 We have no Idea What are the webkit changes,updates in Jeallybean!! 

-- 
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] GooglePlayStore

2012-07-04 Thread baturanija1
Hey,people
i made an app and i would like to place it on PlayStore.APP is free
and i search on internet where to place app, and it shows me an
informations that i have to pay 25 $ to place an appIs it true or
i did not understand that story?If its not please sent me a link
with location where could i put my free app..Thanks people for sharing
knowledge :)

-- 
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] Broadcast receiver starts a new thread, do I need to kill it?

2012-07-04 Thread romdroid


Am Mittwoch, 4. Juli 2012 06:31:54 UTC+2 schrieb TreKing:

 On Fri, Jun 22, 2012 at 1:29 PM, Justin Robinson wrote:

 Is this thread killed after 10 secs along with the broadcast receiver or 
 do I need to kill it manually?


 I don't know about after 10 secs (not sure where you got that number, 
 but yes, once the Thread is done executing, the system takes care of it. 
 I'm not even sure how you would kill it manually.

I guess he means the lifetime of the BroadcastReceiver itself... 


 Besides that, the use of your thread in your snippet is quite useless. 
 Your two lines of code don't need to run in a separate thread.

100% agree. 



 -
 TreKing http://sites.google.com/site/rezmobileapps/treking - Chicago 
 transit tracking app for Android-powered devices



-- 
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] GooglePlayStore

2012-07-04 Thread Francisco M. Marzoa Alonso
It is a one time fee to be registered on Google Play, so you must pay it.
On Jul 4, 2012 8:59 AM, baturanija1 jadrankobodiroga1...@gmail.com
wrote:

 Hey,people
 i made an app and i would like to place it on PlayStore.APP is free
 and i search on internet where to place app, and it shows me an
 informations that i have to pay 25 $ to place an appIs it true or
 i did not understand that story?If its not please sent me a link
 with location where could i put my free app..Thanks people for sharing
 knowledge :)

 --
 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 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: How much time take for Google certification for apps

2012-07-04 Thread Ali Chousein
1. Prepare your app for release: 
http://developer.android.com/tools/publishing/preparing.html 

2. Follow the Publishing Checklist: 
http://developer.android.com/distribute/googleplay/publish/preparing.html 

3. Within some hours you'll see your app on Google Play Store. You don't 
see it immediately, probably because it takes some time to refresh the 
related servers. 

- 
Ali Chousein 
https://play.google.com/store/apps/details?id=com.apps.social_nav 
https://play.google.com/store/apps/details?id=com.apps.weather_buddy 
http://www.paygol.com/android/implementation 

-- 
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: NFC game

2012-07-04 Thread iconapp 2010
Is any one kbnow about GAE bigtable database and RFId
 UID .. plz explain me in detail

On Tue, Jun 26, 2012 at 6:23 PM, iconapp 2010 iconapp2...@gmail.com wrote:

 Hi Android developers, i m working on NFC hunter game on android, can any
 one tel me What kind of nfc tag is used in android how i should deploy in
 android. Brief description about that and if possible any samples for it..



 Thank u




-- 
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] Any Good UI books or online resource?

2012-07-04 Thread Michael Leung
Any books with a lot of example codes.

On Wed, Jul 4, 2012 at 2:24 PM, TreKing treking...@gmail.com wrote:

 On Tue, Jul 3, 2012 at 7:54 PM, Michael Leung michaelchi...@gmail.comwrote:

   I wish to improve my Android UI skills,Any Good UI books or online
 resource you can recommend?


 http://developer.android.com/design/index.html


 -
 TreKing http://sites.google.com/site/rezmobileapps/treking - Chicago
 transit tracking app for Android-powered devices

  --
 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




-- 
Regards,
Michael Leung
http://www.itblogs.info - My IT Blog
http://diary.skynovel.info - My Blog
http://www.michaelleung.info - My Homepage

-- 
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] MemoryFile - ParcelFileDescriptor

2012-07-04 Thread rtindru
I have an application that needs to Base64 decode on the fly a bitmap image 
 render it on the ImageView.
I am using a custom content provider to do this. When the openFile method 
is called - I in this case chose to use a normal non-encoded file for 
testing purpose.
Now I create a MemoryFile from the imagefile (after decoding)  have to 
return a ParcelFileDescriptor of the MemoryFile.

I tried reflection  got the FileDescriptor of the MemoryFile but am unable 
to get the ParcelFileDescriptor from the FileDescriptor
I tried the dup, adoptFD methods but the ParcelFileDescriptor was invalid.
Kindly help me out here.
Cheers
Indru

public ParcelFileDescriptor openFile(Uri uri, String mode)
throws FileNotFoundException {
File openFile = new File(uri.toString());
try {
MemoryFile file = new MemoryFile(null, (int) openFile.length());
ParcelFileDescriptor pfd = ParcelFileDescriptor.open(openFile, 
ParcelFileDescriptor.MODE_READ_ONLY);
AutoCloseInputStream in = new AutoCloseInputStream(pfd);
byte[] buffer = new byte[in.available()];
//Should do decoding here - skipped to test the code
in.read(buffer, 0, buffer.length);
file.writeBytes(buffer, 0, 0, buffer.length);
Method getFileDescriptorMethod = file.getClass().getMethod(
getFileDescriptor);
FileDescriptor out = (FileDescriptor) getFileDescriptorMethod
.invoke(file);
// I have the FD, now how to return a PFD?? Any ideas? dup  adoptFD dont 
work - the PFD is invalid.

-- 
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] Re: Android Text To Speech

2012-07-04 Thread Deepa M
Sir,how to
1. generate the wav file and use the MediaPlayer
2. through media player you can pause and play from you desire position

On Tue, Jul 3, 2012 at 11:18 AM, Deepa M deepam8...@gmail.com wrote:

 Sir,
 i am using Second option
 in that i am  not enable to  pause particular position,
 I am using Buffer reader


 On Mon, Jul 2, 2012 at 6:50 PM, Juned Khan jkhan6...@gmail.com wrote:


 this may help you
 http://stackoverflow.com/questions/6222823/text-to-speech-in-android

 Thanks
 Juned Khan

  --
 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




 --
 Thanks Regards
 Deepa M





-- 
Thanks Regards
Deepa M

-- 
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] GooglePlayStore

2012-07-04 Thread Jadranko Bodiroga
then nothing.. i am a poor..

-- 
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] Adding dividers between items on an Action Bar

2012-07-04 Thread mscwd
Simple question, I just cant find a definitive answer for this.

I have several menu options presented in a drop down list (items are given 
the showAsAction value: collapseActionView) the remaining action items are 
displayed as icons (items are given the showAsAction value: always).

I want to draw a divider between the icons which are always visible and the 
the overflow menu dropdown button.

If you look in the top right of this screen grab you can see the divider 
appearing between the drop down icon and other icons:
http://www.droid-life.com/wp-content/uploads/2011/10/screen_20111023_0800.png
 

I currently inflate my menu from an xml file, as explained here: 
http://developer.android.com/guide/topics/ui/actionbar.html#ActionItems

Thanks in advance

-- 
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] how to change background of an overflow menuitem

2012-07-04 Thread marcin kolonko
i have a native actionbar on a 4.0.4 android phone in the actionbar i have 
some menuitems hidden in an overflow menu.

the pressed/focussed state of my actionbar buttons have a custom color, 
that i would like to use as well on the listitems in the overflow menu.

that's what i'm talking about:
i would like to change the blue background to something different.

what style do i have to override? it seems i can't find the appropriate 
style.

i use a modified Theme that overrides *Theme.Holo.Light.DarkActionBar *i 
found every possible style - but none works on the overflow menu list.

thx

-- 
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] GooglePlayStore

2012-07-04 Thread Michael Leung
That is only for developers.

On Wed, Jul 4, 2012 at 6:21 PM, Jadranko Bodiroga 
jadrankobodiroga1...@gmail.com wrote:

 then nothing.. i am a poor..

  --
 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




-- 
Regards,
Michael Leung
http://www.itblogs.info - My IT Blog
http://diary.skynovel.info - My Blog
http://www.michaelleung.info - My Homepage

-- 
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] Re: Android Text To Speech

2012-07-04 Thread Rocky
My assumption, i'm not sure -

1. you need to move from that activity with finish()


@*Override
*

*public* *void* onPause() {

*super*.onPause();

*try* {

// Stop talking when we lose focus

*if* (*tts* != *null*) {

*tts*.stop();

ttsActive = *false*;

}

} *catch* (*Exception* e) {

}

}

@*Override
*

*public* *void* onResume() {

*super*.onResume();

// Create our text to speech object.

*tts* = *new* *TextToSpeech*(*getApplicationContext*(), *this*);

*Intent* i = *getIntent*();

*smsString* = i.getStringExtra(smsString);

*System*.out.println(from tts = + *smsString*);

*tts* = *new* *TextToSpeech*(*getApplicationContext*(), *this*);

}

@*Override
*

*public* *void* onDestroy() {

*super*.onDestroy();

*try* {

// We're closing down so kill it with fire.

*if* (*tts* != *null*) {

*tts*.shutdown();

*tts* = *null*;

}

// powerLock.release();

} *catch* (*Exception* e) {

}

}



you need to call onPause() as above, may it will work.





On Wed, Jul 4, 2012 at 1:50 PM, Deepa M deepam8...@gmail.com wrote:


 Sir,how to
  1. generate the wav file and use the MediaPlayer
 2. through media player you can pause and play from you desire position

  On Tue, Jul 3, 2012 at 11:18 AM, Deepa M deepam8...@gmail.com wrote:

 Sir,
 i am using Second option
 in that i am  not enable to  pause particular position,
 I am using Buffer reader


 On Mon, Jul 2, 2012 at 6:50 PM, Juned Khan jkhan6...@gmail.com wrote:


 this may help you
 http://stackoverflow.com/questions/6222823/text-to-speech-in-android

 Thanks
 Juned Khan

 --
 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




 --
 Thanks Regards
 Deepa M





 --
 Thanks Regards
 Deepa M


 --
 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




-- 
Thanks  Regards

Rakesh Kumar Jha
Android Developer, Trainer and Mentor
Bangalore
Skype - rkjhaw
(O) +918050753516
(R) +919886336619

-- 
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] samsung galaxy s2

2012-07-04 Thread ala hammad
hello all,
i want to ask which emulator use to test galaxy s2 ??
or what configuration use to test it ...

thanks

-- 
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] Issues extending ListView in Android

2012-07-04 Thread Alex Belyaev
 

I have encountered several issues while extending ListView widget. 
According to the sources, we have the following inheritance chain: 

CustomListView-ListView-AbsListView-ViewGroup...

I'm trying to override layoutChildren() method and here comes the first 
issue. After calling super.layoutChildren() program execution comes to the 
point, where obtainView() method of the 
AbsListView.javahttp://grepcode.com/file_/repository.grepcode.com/java/ext/com.google.android/android/2.3.7_r1/android/widget/AbsListView.java/?v=sourceabstract
 class should be called from 
ListView.javahttp://grepcode.com/file_/repository.grepcode.com/java/ext/com.google.android/android/4.0.3_r1/android/widget/ListView.java/?v=sourceclass.
 
obtainView() method has default access modifier, as a result, I should not 
have an ability to override it in my CustomListView class, since 
AbsListViewbelongs to the different package. But, if I place 
obtainView() method in CustomListView class, it works! So my first question 
is, why does this happen? The second question is very similar to the first 
one. We have two methods (attachViewToParent() and addViewInLayout()) in 
the ViewGroup class. Both of them have protected access modifier, thus, it 
is possible to override them. But if I place this methods in 
CustomListViewclass, this doesn't work for me. 

So the question is, why?

-- 
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: need help in compiling source code

2012-07-04 Thread Bhanushali Ashwin N
Hi lambu0594,

I am facing the same issue while building for android ICS for device Huawei 
U8818.
Have you solved issue?
please help me I am googling for 15 days but nothing found.
Thanks.

On Wednesday, 11 January 2012 12:04:51 UTC+5:30, lambu0594 wrote:

 while compiling ice cream sandwich for vision i get the following 
 error 
 make: *** No rule to make target `out/target/product/vision/obj/ 
 STATIC_LIBRARIES/lib_driver_cmd_wext_intermediates/ 
 lib_driver_cmd_wext.a', needed by `out/target/product/vision/obj/ 
 EXECUTABLES/wpa_supplicant_intermediates/LINKED/wpa_supplicant'.  Stop 

 please 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

Re: [android-developers] samsung galaxy s2

2012-07-04 Thread TreKing
On Wed, Jul 4, 2012 at 4:23 AM, ala hammad 3la2.7am...@gmail.com wrote:

 i want to ask which emulator use to test galaxy s2 ?? or what
 configuration use to test it ...


Google for that device's specs, then set up an AVD that matches ...

-
TreKing http://sites.google.com/site/rezmobileapps/treking - Chicago
transit tracking app for Android-powered devices

-- 
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] Abnormal behavior of media scanner when I renamed a folder which have some media files.

2012-07-04 Thread Mark Murphy
First, I would use MediaScannerConnection instead of that broadcast.

Second, I think you have to recursively scan all of the contents --
from other reports I have seen, it appears that you can only scan
files, not folders.

On Wed, Jul 4, 2012 at 12:03 AM, Hyuck hyuckmin.k...@gmail.com wrote:
 Thank you for your interest.

 after I renamed a folder. I did re-scanning by sending broadcast intent as
 below.

  Context applicationContext =
 MyApplication.getInstance().getApplicationContext();

  applicationContext.sendBroadcast(new
 Intent(Intent.ACTION_MEDIA_SCANNER_SCAN_FILE,

 and then, delete former folder name in database as below.

 public boolean deleteFolder(String folderPath){



  boolean isSuccessful = false;

  Cursor cursor = null;

  String selection;



  DELETE_FOLDER : {

 //1. Get folder '_id' list.(with duplicated one).

 ArrayListInteger folderIdList = new
 ArrayListInteger();



String[] projection = {

 FileSchema.Columns._ID

};

 selection = FileSchema.Columns.DATA +  = \ +
 folderPath + \;

 cursor = SqliteWrapper.query(getContext(),
 getContentResolver(), FileSchema.getContentUri(external), projection,
 selection, null, null);

 if(cursor != null  cursor.moveToFirst() 
 cursor.getCount()  0){

   int dataIndex = cursor.getColumnIndex(FileSchema.Columns._ID);

do {

folderIdList.add(cursor.getInt(dataIndex));

} while ( cursor.moveToNext() );

cursor.close();

 } else {

isSuccessful = false;

break DELETE_FOLDER;

 }



 //2. Delete folders in DB.

 while ( folderIdList.isEmpty() == false ) {

int folderId = folderIdList.remove(0);

  int numberOfDeleted =
 SqliteWrapper.delete(getContext(), getContentResolver(),
 FileSchema.getContentUri(external),
 _id=\+Integer.toString(folderId)+\, null);

  if (numberOfDeleted  0) {

 isSuccessful = false;

 break DELETE_FOLDER;

  }

   }

 //3. Delete files in DB.

 selection = FileSchema.Columns.DATA +  LIKE \ +
 folderPath + /%\;

 int numberOfDeleted = SqliteWrapper.delete(getContext(),
 getContentResolver(), FileSchema.getContentUri(external), selection,
 null);

 if(numberOfDeleted  0){

isSuccessful = false;

break DELETE_FOLDER;

 }



 //4. Success!

 isSuccessful = true;

 break DELETE_FOLDER;

  }



  return isSuccessful;

 }



 On Wednesday, July 4, 2012 1:58:22 AM UTC+9, Mark Murphy (a Commons Guy)
 wrote:

 How did you do the re-scanning?

 On Tue, Jul 3, 2012 at 12:53 PM, Hyuck hyuckmin.k...@gmail.com wrote:
  Hi All,
 
  I have develop a kind of file manager app. recently, I have met a
  strange
  behavior of media scanner.
  There was a folder(A) with some media files in it. and I renamed the
  folder
  name to B.
  However, after a re-scanning , there is still folder A, and the folder
  have
  media files which have 0bytes.
  is there anyone who have this kind of problem? if so, please give me
  some
  advise. it would be much appreciated.
 
  Hyuck.
 
  --
  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



 --
 Mark Murphy (a Commons Guy)
 http://commonsware.com | http://github.com/commonsguy
 http://commonsware.com/blog | http://twitter.com/commonsguy

 _The Busy Coder's Guide to Android Development_ Version 3.7 Available!

 --
 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



-- 
Mark Murphy (a Commons Guy)
http://commonsware.com | http://github.com/commonsguy
http://commonsware.com/blog | http://twitter.com/commonsguy

Android Training... At Your Office: http://commonsware.com/training

-- 
You received this message because you are subscribed to 

Re: [android-developers] Re: need help in compiling source code

2012-07-04 Thread Mark Murphy
This list is for developing apps with the Android SDK, not for
compiling the Android source code. Please visit
http://source.android.com for source code questions.

On Wed, Jul 4, 2012 at 5:43 AM, Bhanushali Ashwin N
mailbhanushaliash...@gmail.com wrote:
 Hi lambu0594,

 I am facing the same issue while building for android ICS for device Huawei
 U8818.
 Have you solved issue?
 please help me I am googling for 15 days but nothing found.
 Thanks.

 On Wednesday, 11 January 2012 12:04:51 UTC+5:30, lambu0594 wrote:

 while compiling ice cream sandwich for vision i get the following
 error
 make: *** No rule to make target `out/target/product/vision/obj/
 STATIC_LIBRARIES/lib_driver_cmd_wext_intermediates/
 lib_driver_cmd_wext.a', needed by `out/target/product/vision/obj/
 EXECUTABLES/wpa_supplicant_intermediates/LINKED/wpa_supplicant'.  Stop

 please 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



-- 
Mark Murphy (a Commons Guy)
http://commonsware.com | http://github.com/commonsguy
http://commonsware.com/blog | http://twitter.com/commonsguy

Android Training... At Your Office: http://commonsware.com/training

-- 
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] How to use google static maps in android

2012-07-04 Thread Remo
Hi all,

  In my Android application I want to use google static maps, and I
want to display markers at my current location.

Please help me, its urgent

Thanks
Remo

-- 
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] GooglePlayStore

2012-07-04 Thread Michael Banzon
Depending on what your app is and who you made it for - you can
distribute it using mail and/or direct download. This will need
special configuration on the devices to allow running your app.

If you wish to distribute your app to a few (more local) devices you
could simply connect the devices to the computer and start running the
app directly on the devices (like when debugging on a real device).

On Wed, Jul 4, 2012 at 10:21 AM, Jadranko Bodiroga
jadrankobodiroga1...@gmail.com wrote:
 then nothing.. i am a poor..

 --
 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



-- 
Michael Banzon
http://michaelbanzon.com/

-- 
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] How to use google static maps in android

2012-07-04 Thread Henry Addo
You might want to use ImageView --
http://developer.android.com/reference/android/widget/ImageView.html and
the static map API
https://developers.google.com/maps/documentation/staticmaps/

Henry!
--
Be the change you want to see ~ Mahatma Gandhi. So stop complaining :-).
Website: http://www.addhen.org/



On Wed, Jul 4, 2012 at 10:59 AM, Remo crajesh2...@gmail.com wrote:

 Hi all,

   In my Android application I want to use google static maps, and I
 want to display markers at my current location.

 Please help me, its urgent

 Thanks
 Remo

 --
 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 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] How to use google static maps in android

2012-07-04 Thread Rakesh Rajput
Dear Remo

1.remove overlay image
2.remove current lat lon inside your code


On Wed, Jul 4, 2012 at 5:07 PM, Henry Addo add...@gmail.com wrote:

 You might want to use ImageView --
 http://developer.android.com/reference/android/widget/ImageView.html and
 the static map API
 https://developers.google.com/maps/documentation/staticmaps/

 Henry!
 --
 Be the change you want to see ~ Mahatma Gandhi. So stop complaining :-).
 Website: http://www.addhen.org/



 On Wed, Jul 4, 2012 at 10:59 AM, Remo crajesh2...@gmail.com wrote:

 Hi all,

   In my Android application I want to use google static maps, and I
 want to display markers at my current location.

 Please help me, its urgent

 Thanks
 Remo

 --
 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 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




-- 
@@@Rakesh Rajput@@@

-- 
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] How to use google static maps in android

2012-07-04 Thread arun kumar
http://android-coding.blogspot.in/2011/06/using-itemizedoverlay-to-add-marker-on.html

On Wed, Jul 4, 2012 at 5:31 PM, Rakesh Rajput rakeshrajput...@gmail.comwrote:

 Dear Remo

 1.remove overlay image
 2.remove current lat lon inside your code



 On Wed, Jul 4, 2012 at 5:07 PM, Henry Addo add...@gmail.com wrote:

 You might want to use ImageView --
 http://developer.android.com/reference/android/widget/ImageView.html and
 the static map API
 https://developers.google.com/maps/documentation/staticmaps/

 Henry!
 --
 Be the change you want to see ~ Mahatma Gandhi. So stop complaining :-).
 Website: http://www.addhen.org/



 On Wed, Jul 4, 2012 at 10:59 AM, Remo crajesh2...@gmail.com wrote:

 Hi all,

   In my Android application I want to use google static maps, and I
 want to display markers at my current location.

 Please help me, its urgent

 Thanks
 Remo

 --
 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 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




 --
 @@@Rakesh Rajput@@@


  --
 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




-- 
WITH REGARDS
ARUN KUMAR P D
+91-9994794759

-- 
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] Android Carousel

2012-07-04 Thread Jorge Gil Royo
Usando el emulador 4.x funciona correctamente.

Cuando uso el teléfono móvil no aparece ningún mensaje en el LogCat que
contenga información acerca del carrusel.

Es la primera vez que me sucede algo tan raro.

Gracias!

2012/7/2 TreKing treking...@gmail.com

 On Fri, Jun 29, 2012 at 6:26 AM, Jorge Gil Royo jorgeg...@gmail.comwrote:

 But when I test the application on a mobile phone (Android 4.x) the
 carousel works correctly, but no buttons appear.


 And if you test on the 4.X emulator?


  Does anyone know why it happens?
 Does anyone know how to fix it?


 Your question is extremely vague. How about some screenshots? Anything in
 the LogCat that looks useful?


 -
 TreKing http://sites.google.com/site/rezmobileapps/treking - Chicago
 transit tracking app for Android-powered devices

  --
 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 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] Android Carousel

2012-07-04 Thread Jorge Gil Royo
Using the emulator 4.x working properly.

When I use the phone there is no message in the logcat containing
information about the carousel.

Is the first time something happens to me so strange.

Thank you!

2012/7/4 Jorge Gil Royo jorgeg...@gmail.com

 Usando el emulador 4.x funciona correctamente.

 Cuando uso el teléfono móvil no aparece ningún mensaje en el LogCat que
 contenga información acerca del carrusel.

 Es la primera vez que me sucede algo tan raro.

 Gracias!


 2012/7/2 TreKing treking...@gmail.com

 On Fri, Jun 29, 2012 at 6:26 AM, Jorge Gil Royo jorgeg...@gmail.comwrote:

 But when I test the application on a mobile phone (Android 4.x) the
 carousel works correctly, but no buttons appear.


 And if you test on the 4.X emulator?


  Does anyone know why it happens?
 Does anyone know how to fix it?


 Your question is extremely vague. How about some screenshots? Anything in
 the LogCat that looks useful?


 -
 TreKing http://sites.google.com/site/rezmobileapps/treking - Chicago
 transit tracking app for Android-powered devices

  --
 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 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] How to use google static maps in android

2012-07-04 Thread Remo
Hi Rakesh,

Can You please share the any sample code for static map

Thanks
Remo

On Wednesday, July 4, 2012 5:31:44 PM UTC+5:30, Rakesh Rajput wrote:

 Dear Remo

 1.remove overlay image 
 2.remove current lat lon inside your code


 On Wed, Jul 4, 2012 at 5:07 PM, Henry Addo add...@gmail.com wrote:

 You might want to use ImageView -- 
 http://developer.android.com/reference/android/widget/ImageView.html and 
 the static map API 
 https://developers.google.com/maps/documentation/staticmaps/

 Henry!
 --
 Be the change you want to see ~ Mahatma Gandhi. So stop complaining :-).
 Website: http://www.addhen.org/



 On Wed, Jul 4, 2012 at 10:59 AM, Remo crajesh2...@gmail.com wrote:

 Hi all,

   In my Android application I want to use google static maps, and I
 want to display markers at my current location.

 Please help me, its urgent

 Thanks
 Remo

 --
 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 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




 -- 
 @@@Rakesh Rajput@@@



-- 
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] How to use google static maps in android

2012-07-04 Thread Remo
Hi Henry,

Can You please share the any sample code for static map

Thanks
Remo

On Wednesday, July 4, 2012 5:07:14 PM UTC+5:30, eyedol wrote:

 You might want to use ImageView -- 
 http://developer.android.com/reference/android/widget/ImageView.html and 
 the static map API 
 https://developers.google.com/maps/documentation/staticmaps/

 Henry!
 --
 Be the change you want to see ~ Mahatma Gandhi. So stop complaining :-).
 Website: http://www.addhen.org/



 On Wed, Jul 4, 2012 at 10:59 AM, Remo crajesh2...@gmail.com wrote:

 Hi all,

   In my Android application I want to use google static maps, and I
 want to display markers at my current location.

 Please help me, its urgent

 Thanks
 Remo

 --
 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 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] Re: Getting action bar height while minSdkVersion is 7

2012-07-04 Thread limtc
I finally solved my problem in not doing the onTouchEvent on the activity, 
but on individual views - thus removed the need to check for Action Bar 
height.

Thanks for everybody who helps!

-- 
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] play youtube video in webview using iframe?

2012-07-04 Thread Hitendrasinh Gohil
Hi,

I am trying to play youtube video in webview by following embed code. Video 
thumbnail is shown but when i click on that nothing is played.

iframe class=youtube-player type=text/html width=640 height=385 
src=http://www.youtube.com/embed/*VIDEO_ID*; frameborder=0
/iframe

I have tested it with samsung galaxy tab(3.2) which has a flash support.
can anybody tell me what could be problem?

-- 
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] GooglePlayStore

2012-07-04 Thread Umesh Gupta
What app yo have developed I am looking for apps to buy.

Thanks

Umesh

On Wed, Jul 4, 2012 at 12:27 PM, baturanija1 jadrankobodiroga1...@gmail.com
 wrote:

 Hey,people
 i made an app and i would like to place it on PlayStore.APP is free
 and i search on internet where to place app, and it shows me an
 informations that i have to pay 25 $ to place an appIs it true or
 i did not understand that story?If its not please sent me a link
 with location where could i put my free app..Thanks people for sharing
 knowledge :)

 --
 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 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] Re: HELP! Google removed my app with millions of users!

2012-07-04 Thread Tiago Mesquita
I use your app and i don't see any problem with it..

Cordialmente, *Regards**,*
Tiago Mesquita A. Cunha.
-  Sun Certified Programmer for the Java Platform, SE 6
-  Oracle Certified Professional, Java EE 5 Web Component Developer




2012/7/3 CVP chri...@gmail.com

 Alarm Clock Plus (the free version). I also just called the user support
 line, which the tech couldn't really help, but said he would forward the
 information to the dev team email. Nothing I didn't do, but maybe it will
 carry more weight coming internally?


 On Tuesday, July 3, 2012 4:18:36 PM UTC-4, Kristopher Micinski wrote:

 You still haven't said the name of the app, if you're a fairly famous
 app, I'd be surprised if the Google Play folks didn't respond quickly
 to you!, At the very least, if you have millions of downloads, other
 developers here will test your app and confirm or deny whether the ban
 was completely unfounded...

 kris

 On Tue, Jul 3, 2012 at 4:14 PM, CVP wrote:
  Pretty much the same place. Down by the bottom.
 
 
  On Tuesday, July 3, 2012 2:19:19 PM UTC-4, FiltrSoft wrote:
 
  Wow, where exactly do you have your ads?  I have ads at the very
 bottom of
  my app, wonder if Google would consider that placement that would
 cause
  users to accidentally click on them, since they are near the phone's
  hardware buttons?
 
  They really need to be more specific when they ban apps, because
 there's
  so much room for interpretation.  On top of that, it's extremely
 difficult
  to contact anyone at Google.
 
  Sometimes I feel I should only develop web-based mobile apps.  Too
 much
  Big Brother with native apps.
 
  On Tuesday, July 3, 2012 10:08:33 AM UTC-4, CVP wrote:
 
  I'm really looking for help from anyone, but I really need to get in
  contact with someone from google...
 
  Without warning, a few days ago my long standing successful app was
  removed from the play store. The app has been around for over 2 years
 now
  and has around 1.5 million active users, and nearly 5 million
 downloads.
  It's been in the top 5 of its category for well over a year. It has
 over
  65,000 ratings with an average of 4.6/5.
 
  The email I received said that the app was removed because Google
 says
  Violation of one or more of the following provisions of the Content
 Policy:
  spam, intellectual property, and impersonation or deceptive behavior
 and
  more specifically because core features of your application causes
 users to
  accidentally click on advertisements
 
  First of all, the ads are hardly accidentally clicked... The highest
  average click rate I've ever gotten was 0.8%. Even still I've read
 over the
  Content Policy as well as the Distribution Agreement and neither call
 out
  specific ad placement rules, guidelines, or suggestions. The ad
 placements
  are also similar to hundreds of other most popular apps...
 
  I'm more than happy to upload a compliant version of the
 application
  putting the advertisements in whatever position is deemed acceptable
 by
  Google. I'm not unethical or a con-artist, I'm a recent college grad
 from a
  smaller town after all... Re-releasing the application under another
 package
  name would be unfair to the 1.5 million active users out there as
 they
  wouldn't get the update notification or keep their settings.
 
  --
  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 android-developers@googlegroups.com
  To unsubscribe from this group, send email to
  android-developers+**unsubscr...@googlegroups.comandroid-developers%2bunsubscr...@googlegroups.com
  For more options, visit this group at
  http://groups.google.com/**group/android-developers?hl=enhttp://groups.google.com/group/android-developers?hl=en

  --
 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 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] How to get handle for cut copy paste menus from the system genereted action bar in android

2012-07-04 Thread Mark Murphy
On Wed, Jul 4, 2012 at 9:38 AM, Bunty syed itsmeatfo...@gmail.com wrote:
 Whenever  there is long press or double tap on some text in edit text,action
 bar is coming with some options like cut,copy ,etc..

 Is there any callback method tat gets called when some menu in the action
 bar is clicked so that I can handle them...

For your own app's EditText widgets, you can call
setCustomSelectionActionModeCallback() to add your own stuff to the
action mode.

 Actually, I want to handle cut copy paste  share menu items actions in all
 System generated menu so I am looking for some android provided callbacks
 for all of them..

Fortunately, this is not possible, for obvious security and privacy
reasons. You are welcome to make your own Android mod and install that
custom firmware on your own Android device that has this capability,
if you so choose.

-- 
Mark Murphy (a Commons Guy)
http://commonsware.com | http://github.com/commonsguy
http://commonsware.com/blog | http://twitter.com/commonsguy

Android Training... At Your Office: http://commonsware.com/training

-- 
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] play youtube video in webview using iframe?

2012-07-04 Thread Hitendrasinh Gohil
any help,pls?

On Wed, Jul 4, 2012 at 6:36 PM, Hitendrasinh Gohil hitendrasin...@gmail.com
 wrote:

 Hi,

 I am trying to play youtube video in webview by following embed code.
 Video thumbnail is shown but when i click on that nothing is played.

 iframe class=youtube-player type=text/html width=640 height=385
 src=http://www.youtube.com/embed/*VIDEO_ID*; frameborder=0
 /iframe

 I have tested it with samsung galaxy tab(3.2) which has a flash support.
 can anybody tell me what could be problem?

 --
 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




-- 
regards,
Hitendrasinh Gohil

-- 
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] How to get handle for cut copy paste menus from the system genereted action bar in android

2012-07-04 Thread Bunty syed
is there any way to remove or block the system generated Menus

On 4 July 2012 19:16, Mark Murphy mmur...@commonsware.com wrote:

 On Wed, Jul 4, 2012 at 9:38 AM, Bunty syed itsmeatfo...@gmail.com wrote:
  Whenever  there is long press or double tap on some text in edit
 text,action
  bar is coming with some options like cut,copy ,etc..
 
  Is there any callback method tat gets called when some menu in the action
  bar is clicked so that I can handle them...

 For your own app's EditText widgets, you can call
 setCustomSelectionActionModeCallback() to add your own stuff to the
 action mode.

  Actually, I want to handle cut copy paste  share menu items actions in
 all
  System generated menu so I am looking for some android provided callbacks
  for all of them..

 Fortunately, this is not possible, for obvious security and privacy
 reasons. You are welcome to make your own Android mod and install that
 custom firmware on your own Android device that has this capability,
 if you so choose.

 --
 Mark Murphy (a Commons Guy)
 http://commonsware.com | http://github.com/commonsguy
 http://commonsware.com/blog | http://twitter.com/commonsguy

 Android Training... At Your Office: http://commonsware.com/training

 --
 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 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] How to get handle for cut copy paste menus from the system genereted action bar in android

2012-07-04 Thread Mark Murphy
On Wed, Jul 4, 2012 at 10:09 AM, Bunty syed itsmeatfo...@gmail.com wrote:
 is there any way to remove or block the system generated Menus

For your own app, perhaps, but certainly not for the whole system.

-- 
Mark Murphy (a Commons Guy)
http://commonsware.com | http://github.com/commonsguy
http://commonsware.com/blog | http://twitter.com/commonsguy

Android Training... At Your Office: http://commonsware.com/training

-- 
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] How to get handle for cut copy paste menus from the system genereted action bar in android

2012-07-04 Thread Bunty syed
For action bar ,
I got a callback public void onActionModeStarted(ActionMode mode)  where I
remove cut copy paste menus

But for attached screenshot edit button, I am not able to get any callback.

Do u know any callback which is called on invoking tat menu 

On 4 July 2012 19:42, Mark Murphy mmur...@commonsware.com wrote:

 On Wed, Jul 4, 2012 at 10:09 AM, Bunty syed itsmeatfo...@gmail.com
 wrote:
  is there any way to remove or block the system generated Menus

 For your own app, perhaps, but certainly not for the whole system.

 --
 Mark Murphy (a Commons Guy)
 http://commonsware.com | http://github.com/commonsguy
 http://commonsware.com/blog | http://twitter.com/commonsguy

 Android Training... At Your Office: http://commonsware.com/training

 --
 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 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 4.1 Jelly Bean GIF Images Not Showing?

2012-07-04 Thread Josh F.
It is definitely nothing to do with WebKit or the browser or similar, this 
is a standard image view in a game trying to load a simple GIF with 
transparency.  An interesting update: After updating to the latest build 
tooks and setting the target SDK all the way up to 16 (for 4.1) the images 
now show as just all black.  Without any word from anyone from 
Google/Android, I'm gong to just go ahead and replace everything with PNG 
files which are all slightly larger than my GIF files which will be a 
memory hit, but I don't see any alternative if I want a fix done this week.

On Tuesday, July 3, 2012 11:47:04 PM UTC-7, Zsolt Vasvari wrote:

 And we have no idea why you mention Webkit.  

 On Wednesday, July 4, 2012 2:03:29 PM UTC+8, Subramanya Somayaji wrote:

 We have no Idea What are the webkit changes,updates in Jeallybean!! 



-- 
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] How to get handle for cut copy paste menus from the system genereted action bar in android

2012-07-04 Thread Mark Murphy
On Wed, Jul 4, 2012 at 10:26 AM, Bunty syed itsmeatfo...@gmail.com wrote:
 For action bar ,
 I got a callback public void onActionModeStarted(ActionMode mode)  where I
 remove cut copy paste menus

 But for attached screenshot edit button, I am not able to get any callback.

 Do u know any callback which is called on invoking tat menu 

It might be a context menu (see onCreateContextMenu()), but on some
devices, the device manufacturer has replaced the context menu with
their own thing. It is not possible for you block cut/copy/paste
across all devices, even for your own app.

-- 
Mark Murphy (a Commons Guy)
http://commonsware.com | http://github.com/commonsguy
http://commonsware.com/blog | http://twitter.com/commonsguy

Android Training... At Your Office: http://commonsware.com/training

-- 
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] distinct with ContentResolver

2012-07-04 Thread Live Happy
how i can add ' distinct' to contentResolver query i tried to use it by
projection

String[] projection = new String[]{

DISTINCT + Columns.types
};
but it return error unknown columns in projection
and i found an answer suggesting the use of a specified uri and
matcher and queryBuilder.setDistinct(true)
but how to use that uri in the first place?
can anyone help me with that and thanks in advance

-- 
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] Samsung Galaxy S III and NFC

2012-07-04 Thread Cadu Silvestre
Hi guys,

Is there anyone over there using Galaxy S III for NFC tests and research?

We've been using Google Nexus S and it works (kind of) fine with Google and 
NXP NFC APIs. I'd like to hear from you what are your experiences with NFC 
in Galaxy SIII.

Thanks!

-- 
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] Re: Problem optimizing views for having a fast scroll

2012-07-04 Thread jean-francois garreau
I finally found the source of all my GC ! it comes from my activity xml 
layout... Indeed for my expandView, I use this : 

  ExpandableListView
   android:id=@+id/resultListResult
   android:layout_width=fill_parent
   android:layout_height=fill_parent
   android:cacheColorHint=# 
   /

And if I remove this : android:cacheColorHint=#  the animation is 
very smooth !

Thanks for your help
   

Le mardi 3 juillet 2012 13:23:24 UTC+2, Kostya Vasilyev a écrit :

 A custom view, assuming it's at the root of your item layout, is just as 
 good as a view holder.

 Here is what you can do:

 - Override onFinishInflate in your item layout root view
 - Call this.findViewById to find children
 - Store them as member variables
 - Access in the adapter's getView, like itemView.mText1, itemView.mText2 
 -- rather than doing itemView.findViewById(...)

 -- K

 2012/7/3 jean-francois garreau jean.francois.garr...@gmail.com

 I already saw that presentation and I can't use the ViewHolder pattern 
 because i need a customView. 

 So I'm looking for a way to optimize my CustomView because I don't know 
 what I'm doing wrong with this view that causing thoses GC



-- 
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] application launching process...?

2012-07-04 Thread Abhilash baddam
Thanks Kris for the reply, could you please provide me some useful links
for the same.

On Mon, Jul 2, 2012 at 12:45 AM, Kristopher Micinski krismicin...@gmail.com
 wrote:

 On Sun, Jul 1, 2012 at 2:30 PM, Abhilash baddam
 abhilash.androiddevelo...@gmail.com wrote:
  Hi,
 
  After switching on the mobile(after booting process) all the
  applications will be loaded like System apps, 3rd party apps etc...
  how these apps are loading means I want to know the way, procedure or
  process for this. Can anyone suggest me any websites or docs to know
  these things.

 It's not just understanding the boot process, which is fairly
 traditional Linux stuff, but also understanding that you're sitting on
 top of the zygote process, package manager (routing intents), and
 other android-y topics...

 I've actually heard good things about this book...
 http://shop.oreilly.com/product/0636920021094.do

 kris

 --
 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 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] Abnormal behavior of media scanner when I renamed a folder which have some media files.

2012-07-04 Thread Hyuck
Thank you Murphy.
 
I'm going to try your way. hope it works as we expect. 

On Wednesday, July 4, 2012 7:38:53 PM UTC+9, Mark Murphy (a Commons Guy) 
wrote:

 First, I would use MediaScannerConnection instead of that broadcast. 

 Second, I think you have to recursively scan all of the contents -- 
 from other reports I have seen, it appears that you can only scan 
 files, not folders. 

 On Wed, Jul 4, 2012 at 12:03 AM, Hyuck hyuckmin.k...@gmail.com wrote: 
  Thank you for your interest. 
  
  after I renamed a folder. I did re-scanning by sending broadcast intent 
 as 
  below. 
  
   Context applicationContext = 
  MyApplication.getInstance().getApplicationContext(); 
  
   applicationContext.sendBroadcast(new 
  Intent(Intent.ACTION_MEDIA_SCANNER_SCAN_FILE, 
  
  and then, delete former folder name in database as below. 
  
  public boolean deleteFolder(String folderPath){ 
  
  
  
   boolean isSuccessful = false; 
  
   Cursor cursor = null; 
  
   String selection; 
  
  
  
   DELETE_FOLDER : { 
  
  //1. Get folder '_id' list.(with duplicated one). 
  
  ArrayListInteger folderIdList = new 
  ArrayListInteger(); 
  
  
  
 String[] projection = { 
  
  FileSchema.Columns._ID 
  
 }; 
  
  selection = FileSchema.Columns.DATA +  = \ + 
  folderPath + \; 
  
  cursor = SqliteWrapper.query(getContext(), 
  getContentResolver(), FileSchema.getContentUri(external), projection, 
  selection, null, null); 
  
  if(cursor != null  cursor.moveToFirst()  
  cursor.getCount()  0){ 
  
int dataIndex = 
 cursor.getColumnIndex(FileSchema.Columns._ID); 
  
 do { 
  
 folderIdList.add(cursor.getInt(dataIndex)); 
  
 } while ( cursor.moveToNext() ); 
  
 cursor.close(); 
  
  } else { 
  
 isSuccessful = false; 
  
 break DELETE_FOLDER; 
  
  } 
  
  
  
  //2. Delete folders in DB. 
  
  while ( folderIdList.isEmpty() == false ) { 
  
 int folderId = folderIdList.remove(0); 
  
   int numberOfDeleted = 
  SqliteWrapper.delete(getContext(), getContentResolver(), 
  FileSchema.getContentUri(external), 
  _id=\+Integer.toString(folderId)+\, null); 
  
   if (numberOfDeleted  0) { 
  
  isSuccessful = false; 
  
  break DELETE_FOLDER; 
  
   } 
  
} 
  
  //3. Delete files in DB. 
  
  selection = FileSchema.Columns.DATA +  LIKE \ + 
  folderPath + /%\; 
  
  int numberOfDeleted = 
 SqliteWrapper.delete(getContext(), 
  getContentResolver(), FileSchema.getContentUri(external), selection, 
  null); 
  
  if(numberOfDeleted  0){ 
  
 isSuccessful = false; 
  
 break DELETE_FOLDER; 
  
  } 
  
  
  
  //4. Success! 
  
  isSuccessful = true; 
  
  break DELETE_FOLDER; 
  
   } 
  
  
  
   return isSuccessful; 
  
  } 
  
  
  
  On Wednesday, July 4, 2012 1:58:22 AM UTC+9, Mark Murphy (a Commons Guy) 
  wrote: 
  
  How did you do the re-scanning? 
  
  On Tue, Jul 3, 2012 at 12:53 PM, Hyuck hyuckmin.k...@gmail.com 
 wrote: 
   Hi All, 
   
   I have develop a kind of file manager app. recently, I have met a 
   strange 
   behavior of media scanner. 
   There was a folder(A) with some media files in it. and I renamed the 
   folder 
   name to B. 
   However, after a re-scanning , there is still folder A, and the 
 folder 
   have 
   media files which have 0bytes. 
   is there anyone who have this kind of problem? if so, please give me 
   some 
   advise. it would be much appreciated. 
   
   Hyuck. 
   
   -- 
   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 
  
  
  
  -- 
  Mark Murphy (a Commons Guy) 
  http://commonsware.com | http://github.com/commonsguy 
  http://commonsware.com/blog | http://twitter.com/commonsguy 
  
  _The Busy Coder's Guide to Android Development_ Version 3.7 Available! 
  
  -- 
  You received this message because you are subscribed to the Google 
  Groups Android Developers group. 
  To post to this group, 

[android-developers] Re: Issues extending ListView in Android

2012-07-04 Thread G. Blake Meike


On Wednesday, July 4, 2012 2:29:56 AM UTC-7, Alex Belyaev wrote:

 I have encountered several issues while extending ListView widget. 
 According to the sources, we have the following inheritance chain: 

 CustomListView-ListView-AbsListView-ViewGroup...

 I'm trying to override layoutChildren() method and here comes the first 
 issue. After calling super.layoutChildren() program execution comes to 
 the point, where obtainView() method of the 
 AbsListView.javahttp://grepcode.com/file_/repository.grepcode.com/java/ext/com.google.android/android/2.3.7_r1/android/widget/AbsListView.java/?v=sourceabstract
  class should be called from 
 ListView.javahttp://grepcode.com/file_/repository.grepcode.com/java/ext/com.google.android/android/4.0.3_r1/android/widget/ListView.java/?v=sourceclass.
  
 obtainView() method has default access modifier, as a result, I should 
 not have an ability to override it in my CustomListView class, since 
 AbsListView belongs to the different package. But, if I place 
 obtainView()method in 
 CustomListView class, it works!  So my first question is, why does this 
 happen? 

I think you are mistaken in your understanding of what happens when you 
define obtainView in the subclass.  You, absolutely can create a method 
with that name.  The new method does not override the the base class 
method, it hides it.
The base class method is not visible from the subclass: super.obtainView is 
a compile error from the new class.  Using the @Override tag will help 
identify problems like this.
 

 The second question is very similar to the first one. We have two methods (
 attachViewToParent() and addViewInLayout()) in the ViewGroup class. Both 
 of them have protected access modifier, thus, it is possible to override 
 them. But if I place this methods in CustomListView class, this doesn't 
 work for me.

 So the question is, why?

This one I don't understand.  That seems like it should work.  Can you give 
more details.

G. Blake Meike
Marakana

The second edition of Programming Android is now on-line:
http://shop.oreilly.com/product/0636920023005.do
 

-- 
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: Any Good UI books or online resource?

2012-07-04 Thread G. Blake Meike
Since you asked:  Programming Android has a two chapters describing, in 
some detail, how Android UI components work.

G. Blake Meike
Marakana

The second edition of Programming Android is now on-line:
http://shop.oreilly.com/product/0636920023005.do


On Tuesday, July 3, 2012 5:54:24 PM UTC-7, Michael Leung wrote:

 Hi,
   I wish to improve my Android UI skills,Any Good UI books or online 
 resource you can recommend?
 Thanks!

 -- 
 Regards,
 Michael Leung
 http://www.itblogs.info - My IT Blog
 http://diary.skynovel.info - My Blog
 http://www.michaelleung.info - My Homepage
 https://play.google.com/store/apps/details?id=com.advgen.AdvNetInfoPro


  

-- 
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: Broadcast receiver starts a new thread, do I need to kill it?

2012-07-04 Thread G. Blake Meike
If there's a reason to do this asynchronously, you should do it with an 
AsyncTask.  On the other hand, I'm with Justin wondering why you want it 
done asynchronously, at all...

G. Blake Meike
Marakana

The second edition of Programming Android is now on-line:
http://shop.oreilly.com/product/0636920023005.do


On Friday, June 22, 2012 11:29:04 AM UTC-7, Justin Robinson wrote:

 Every 30 seconds my broadcast receiver starts a service thread like this:

 Thread t = new Thread(){
 @Override
 public void run(){
 Intent intent = new Intent(context, AlarmService.class);
 context.startService(intent);
 }
 };
 t.start();

 Is this thread killed after 10 secs along with the broadcast receiver or 
 do I need to kill it manually?


-- 
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] Re: Issues extending ListView in Android

2012-07-04 Thread Gergely Juhász
If you really what to modify the source code of the ListView (I dont
known why you want) grab the source code and copy to your project. For
instance here is the latest public version of the class:
https://github.com/android/platform_frameworks_base/blob/master/core/java/android/widget/ListView.java

On 4 July 2012 19:07, G. Blake Meike blake.me...@gmail.com wrote:


 On Wednesday, July 4, 2012 2:29:56 AM UTC-7, Alex Belyaev wrote:

 I have encountered several issues while extending ListView widget.
 According to the sources, we have the following inheritance chain:

 CustomListView-ListView-AbsListView-ViewGroup...

 I'm trying to override layoutChildren() method and here comes the first
 issue. After calling super.layoutChildren() program execution comes to the
 point, where obtainView() method of the AbsListView.java abstract class
 should be called from ListView.java class. obtainView() method has default
 access modifier, as a result, I should not have an ability to override it in
 my CustomListView class, since AbsListView belongs to the different package.
 But, if I place obtainView() method in CustomListView class, it works!  So
 my first question is, why does this happen?

 I think you are mistaken in your understanding of what happens when you
 define obtainView in the subclass.  You, absolutely can create a method with
 that name.  The new method does not override the the base class method, it
 hides it.
 The base class method is not visible from the subclass: super.obtainView is
 a compile error from the new class.  Using the @Override tag will help
 identify problems like this.


 The second question is very similar to the first one. We have two methods
 (attachViewToParent() and addViewInLayout()) in the ViewGroup class. Both of
 them have protected access modifier, thus, it is possible to override them.
 But if I place this methods in CustomListView class, this doesn't work for
 me.

 So the question is, why?

 This one I don't understand.  That seems like it should work.  Can you give
 more details.

 G. Blake Meike
 Marakana

 The second edition of Programming Android is now on-line:
 http://shop.oreilly.com/product/0636920023005.do


 --
 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 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] Showing a confirm dialog from the PreferenceAcivity

2012-07-04 Thread Simon Giddings
Within my preferences I give the user control over my image cache, 
including the ability to empty the cache.

However, I want the user to confirm the emptying of the cache (to avoid 
mistakes).
We are supposed to use dialog fragments now instead of dialog builders as 
these are depreciated (as far as I understand).

How can I then show a confirmation dialog in this case ?

-- 
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] Showing a confirm dialog from the PreferenceAcivity

2012-07-04 Thread Gergely Juhász
Here is any example about showing an alert with dialog fragment.
http://developer.android.com/reference/android/app/DialogFragment.html
(Alert Dialog section)

On 4 July 2012 19:36, Simon Giddings mr.s.giddi...@gmail.com wrote:
 Within my preferences I give the user control over my image cache, including
 the ability to empty the cache.

 However, I want the user to confirm the emptying of the cache (to avoid
 mistakes).
 We are supposed to use dialog fragments now instead of dialog builders as
 these are depreciated (as far as I understand).

 How can I then show a confirmation dialog in this case ?

 --
 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 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] Showing a confirm dialog from the PreferenceAcivity

2012-07-04 Thread Gergely Juhász
sorry, an

On 4 July 2012 19:39, Gergely Juhász jg.sv...@gmail.com wrote:
 Here is any example about showing an alert with dialog fragment.
 http://developer.android.com/reference/android/app/DialogFragment.html
 (Alert Dialog section)

 On 4 July 2012 19:36, Simon Giddings mr.s.giddi...@gmail.com wrote:
 Within my preferences I give the user control over my image cache, including
 the ability to empty the cache.

 However, I want the user to confirm the emptying of the cache (to avoid
 mistakes).
 We are supposed to use dialog fragments now instead of dialog builders as
 these are depreciated (as far as I understand).

 How can I then show a confirmation dialog in this case ?

 --
 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 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 2.1update-1 image for emulator?

2012-07-04 Thread Francisco M. Marzoa Alonso
Hi there,

I have a recurrent Outofmemory crash when loading a Bitmap that is
making me crazy. Its occurs mostly on Android 2.1-update1 devices -about
92% of crashes occurs with some device with that Android version-.

Is there any manner to run this version on the emulator, so I have any
chance to solve it?

BTW, I have reduced a lot the memory consumption of my application even
substituting bitmaps by graphic primitives drawn on the fly. I am pretty
sure that it has no memory leaks, 100% of the crashes occurs without a
low memory condition, I recycle every single bitmap I use when I do not
need it for a long time, loading it again from disk when needed... also
I have tested it with several different physical devices and emulators,
including Android 2.1 version, and it does not crashes never with those...

So I am pretty sure that it is not a problem with my code itself, so I
rather like to have the chance of debugging it within a 2.1-update1
device to have a chance of create a workaround, if it is possible.
Though not 100%, I think an emulator instance running a 2.1update-1
image may help (or may not, at all, but I have not too much things to
try yet...)

Thanks a lot in advance,

-- 
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] gingerbread... man!

2012-07-04 Thread bob
So, I tried running the function listenUsingInsecureRfcommWithServiceRecord 
on an Android 2.3.5 device.  It popped up a dialog asking to accept some 5 
or 6 digit pin.  It's not supposed to do that, right?  It just works on my 
Ice Cream Sandwich.  Has anyone seen this on Android 2.3.5?

-- 
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] Re: Android LifeCycle and Singleton Instances

2012-07-04 Thread Dianne Hackborn
Note that some details of the lifecycle have changed, as described in the
docs:
http://developer.android.com/reference/android/app/Activity.html#ActivityLifecycle


Specifically, if you target SDK 11 or later, then onSaveInstanceState()
will be called before onStop() (not onPause()), and the activity's process
is not killable until it is stopped.

Also, something that I should make clear in the documentation, when the
screen is turned off the foreground activity is stopped, not just paused.
 And as of JB it remains stopped until the user leaves the lock screen;
prior to that it was resumed as soon as the screen turns on.

Some answers to the specific quoted questions:

On Jun 4, 10:20 am, DulcetTone dulcett...@gmail.com wrote:
  The Activity documentation does not clearly indicate the difference
  between an activity being paused versus being stopped.   Is a paused
  activity one which has 1 or more pixels obscured by another, and a
  stopped activity one that has zero visible pixels?


An activity is stopped some time after it is no longer visible to the user.
 This is also the point where its window surface is removed, so it would be
impossible for it to be seen on screen.  (You should not, however, make any
assumptions about the relationship between window state changes and
activity state changes.  They are run by different parts of the system,
which do not try to synchronize with each other.)

There is no strong guarantee about how soon after an activity is no longer
visible that its onStop() will be called -- if the current foreground
activity is taking a long time to go idle, for example, the stop of older
activities will be delayed.


  I have never found just where the the interrelationships between
  finish() and state diagram paths toward pause/stop and the use of the
  back  button or home button are detailed.


finish() isn't a state, it is a command to completely finish the activity.

finish(): remove the activity from the activity stack, the user an no
longer return to it.
onDestroy(): this activity client-side instance is being destroyed for some
reason.  It may be due to it being finished (you can tell with
isFinishing()), it may be due to a configuration change, or something else.

Note that you can *not* rely on finding out if your activity has been
finished by calling isFinishing() -- there are many situations where an
activity gets finished but its client-side instance is no longer around to
tell, so it just gets removed from the stack.  That is why there is no
onFinish() callback, it would not be possible to give useful guarantees
about when it is called.


  There seems to be no direct means by which my app (or do I mean my
  task?) can know when one of its activities is active versus not.  This
  has confused me for one and a half years (it matters when you make an
  app that has a voice user interface and want the recognition to be
  stopped when the user presses home, but not when he presses back on
  an activity that returns another of your app's activities to the
  fore).  It gets worse in that starting a new activity does not deliver
  you an Activity instance immediately, making instance counting
  difficult.


One way you can approach this is by having singleton to keep track of your
global behavior, and have each activity tell it when it is resumed and
paused.  Or, if you have a part of your UI that is so closely entwined,
really do consider using fragments.

 I have resisted using the manifest flags for singletop et al
  entirely, as several readings of their description have not conveyed a
  clear understanding.


singleTop just means that if you have activity A and B on your stack, and
someone calls startActivity() in a way that would put another B on top of
the existing B on your stack, then instead the current B's onNewIntent()
will be called.

-- 
Dianne Hackborn
Android framework engineer
hack...@android.com

Note: please don't send private questions to me, as I don't have time to
provide private support, and so won't reply to such e-mails.  All such
questions should be posted on public forums, where I and others can see and
answer them.

-- 
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] distinct with ContentResolver

2012-07-04 Thread Dianne Hackborn
The ContentResolver query() API is very specifically intended to not be a
full SQL query interface.  If you have a specific kind of query you want to
do, in your ContentProvider implementation add a new URI to the set you
match that builds that query with the given arguments.

On Wed, Jul 4, 2012 at 7:44 AM, Live Happy livehap...@gmail.com wrote:

 how i can add ' distinct' to contentResolver query i tried to use it by
 projection

 String[] projection = new String[]{



 DISTINCT + Columns.types
 };
 but it return error unknown columns in projection


 and i found an answer suggesting the use of a specified uri and matcher and 
 queryBuilder.setDistinct(true)
 but how to use that uri in the first place?
 can anyone help me with that and thanks in advance

  --
 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




-- 
Dianne Hackborn
Android framework engineer
hack...@android.com

Note: please don't send private questions to me, as I don't have time to
provide private support, and so won't reply to such e-mails.  All such
questions should be posted on public forums, where I and others can see and
answer them.

-- 
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] Custom Input Devices

2012-07-04 Thread Dritan
Hello,

I didn't know where to post this question, in kernel, platform, building... 
so I decided to post it here maybe it'll get some attention.

I have been able to create a custom input device that can be seen on all 
android devices as a mouse + keyboard combo straight through Bluetooth via 
HID profiles on input device. My needs have expanded and broadened to 
slightly more than just keyboard + mouse combo; I am looking to send bytes 
that identify my custom device as a touch device that can issue touch 
events on command (such as by moving a joystick).

I've looked at http://source.android.com/tech/input/touch-devices.html that 
defines the classification of touch devices, however, the instructions are 
not very clear.
For instance, *All built-in touch devices should have input device 
configuration files.* does this mean that the Android device recognizing 
my custom device needs to be rooted? The Touch Devices page explains about 
devices being classified as touch-devices but there is no clear indication 
that one must have root access to an Android device in order to achieve 
this feat.

There is yet another quote following the bolded quote above, If no input 
device configuration file is present, the system will choose a default 
configuration that is appropriate for typical general-purpose touch 
peripherals such as external USB or Bluetooth HID touch screens or touch 
pads. These defaults are not designed for built-in touch screens and will 
most likely result in incorrect behavior..
  - Does this mean that Android actually *does* support touch devices 
defined through HID but will most likely result in incorrect behaviour? 
If so, does anyone know the default bytes that Android responds to as touch 
events? 
Has anyone any experience with this? Would it be possible for an input 
device to *send* the a virtual key map upon connecting with Android?   

I'd really appreciate your help in this, I've been working at it for a 
while now and I cannot afford to root all Android devices that should see 
my input device.
Thank you for your time in advance.
Dritan

-- 
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] Volume Button Source Code: Where do I find it?

2012-07-04 Thread Cythes
Where with in the android source code(files) would I go about finding the 
volume button codes? I am looking to write a patch for an app I am working 
on. 

-- 
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] About the APIs protected by Android permissons

2012-07-04 Thread M

Is there any source or document about which APIs protected by Android
permissions?  namely, API vs Android permission mapping.

Thanks.

-- 
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] GooglePlayStore

2012-07-04 Thread Francisco M. Marzoa Alonso
You should expect to recover those $25 from your application income soon.

Anyway there are alternative markets that does not need to pay such fee.
You may try Slideme and google a bit on alternatives to Google Play. Amazon
is also free the first year, but it is limited to USA market.

On Jul 4, 2012 10:23 AM, Jadranko Bodiroga jadrankobodiroga1...@gmail.com
wrote:

 then nothing.. i am a poor..

 --
 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 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: how to check API usage information in apk file?

2012-07-04 Thread M
no, I mean what api calls are used by one andorid app?

Any method to obtain such information from apk file?

Thanks.

On Jun 19, 5:53 pm, Kristopher Micinski krismicin...@gmail.com
wrote:
 what APIs do you mean?  It uses the Android API, most likely ... Do
 you mean what API *level*?

 kris



 On Tue, Jun 19, 2012 at 8:34 PM, michael xuetao@gmail.com wrote:
  Hi, all,

  Given an apk file, how to check what APIs are used by this apk file?

  Thanks.

  --
  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 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: how to share the audio played on android device to multiple audio devices

2012-07-04 Thread Doug
An app can't know exactly what is being played on the device in a general 
sense, unless it is the app playing the audio, and it is generating the raw 
PCM to send to an AudioTrack.

Doug

On Tuesday, June 26, 2012 4:09:04 AM UTC-7, kuldeep wrote:

 I am planning to implement a simple application that will share the 
 current audio being played on android device, to be played on another 
 android device. It will be a great help if anyone can tell me how to 
 copy the audio out buffer so that I can share same audio track that is 
 running on the first Android device. Please reply to me with all your 
 suggestions and implementation details

-- 
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: GridLayout Text Clipping using Support Library

2012-07-04 Thread Renan Mobile
I came here to say. THANK YOU!  That's really works

Em quinta-feira, 19 de abril de 2012 13h03min43s UTC-3, Scott Olcott 
escreveu:

 Thanks to this 
 https://groups.google.com/d/msg/android-developers/QgN2B9CdQOo/0xdpwulIdCcJfrom
  Tor Norbe I was able to figure out how to get this working.  I think 
 then main issue that was causing this to not work was I wasn't using the 
 right namespace which should be  xmlns:app=
 http://schemas.android.com/apk/res-auto;. 

 Here is an example that now works:

 ?xml version=1.0 encoding=utf-8?

 android.support.v7.widget.GridLayout xmlns:android=
 http://schemas.android.com/apk/res/android;

   xmlns:app=http://schemas.android.com/apk/res-auto;

   android:layout_width=match_parent

   android:layout_height=match_parent

   app:columnCount=2

   app:useDefaultMargins=true 

   TextView

 app:layout_column=0

 app:layout_gravity=left

 app:layout_row=0

 android:text=Label /

   TextView

 android:layout_width=0dp

 app:layout_column=1

 app:layout_gravity=fill_horizontal

 app:layout_row=0

 android:text=test test test test test test test test test test test 
 test test test test test test test /

 /android.support.v7.widget.GridLayout

 On Thursday, April 12, 2012 9:27:53 AM UTC-6, Scott Olcott wrote:

 Where are you finding the documentation?  The only documentation I have 
 seen is for the GridLayout that comes with ICS.  There is no javadocs for 
 any of the classes under android.support.v7.  There is no source for them 
 in AOSP or any samples that use them that I can find anywhere.

 On Tuesday, April 10, 2012 2:18:02 PM UTC-6, Dave Rozsnyai wrote:

 Same here. GridLayout library hasn't been user friendly. The 
 documentation doesn't make any note of the fact that you need to use 
 your own namespace for columnCount if you are targeting 4.0 and now 
 this... I would advise people to use something else unless then really 
 need the grid. 

 On Apr 10, 9:55 am, Scott Olcott scottolc...@gmail.com wrote: 
  This is happening on Gingerbread and ICS.  When will the source for 
 the 
  support library GridLayout be available in AOSP?  Currently there is 
 no way 
  to debug what is happening because there is no source available. 
  
  
  
  
  
  
  
  On Monday, April 9, 2012 11:28:46 AM UTC-6, Romain Guy (Google) wrote: 
  
   You set the width of GridLayout to wrap_content so it will extend 
 as 
   far as its content can go. 
  
   On Mon, Apr 9, 2012 at 10:24 AM, Scott Olcott  wrote: 
I am using the GridLayout that is in r7 of the support library.  I 
 am 
   having 
an issue with text being clipped at the edge of the screen instead 
 of 
   being 
wrapped.  Here is a layout that reproduces the issue. 
  
android.support.v7.widget.GridLayout 
xmlns:android=http://schemas.android.com/apk/res/android; 
 android:layout_width=wrap_content 
 android:layout_height=wrap_content  
  
TextView 
  android:minWidth=100dp 
  android:text=test123 / 
  
TextView 
android:text=test test test test tes test tes test test 
 test 
   test 
test test test / 
/android.support.v7.widget.GridLayout 
  
When using the ICS version of GridLayout I can just add 
android:layout_width=0dp and 
 android:layout_gravity=fill_horizontal 
   to 
the TextView and it wraps the text instead clipping.  However when 
 I try 
that using the support library GridView the whole TextView 
 disappears.  I 
attached a screenshot from the Graphic Layout view in Eclipse that 
demonstrates what is happening.  It looks like the second TextView 
 is not 
inheriting it's size from it's container but is the same width as 
 the 
device. 
  
Is there a different way to get this to work correctly? 
  
-- 
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 
  
   -- 
   Romain Guy 
   Android framework engineer 
   romain...@android.com



-- 
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] TransactionTooLargeException exception calling queryIntentActivities()

2012-07-04 Thread Bryan Ashby


On Tuesday, July 3, 2012 9:57:15 AM UTC-6, Mark Murphy (a Commons Guy) 
wrote:

 Well, I'd at least consider adding MATCH_DEFAULT_ONLY on the 
 queryIntentActivities() call, if you are building a launcher-type app. 

 Beyond that, I'm not sure if by default you get everything in the GET_ 
 series of flags -- if so, that might be the source of your woe, and 
 expressly listing the GET_ flags you really need might help. 


Thanks, I'll try the GET_* flags -- there are quite a few bits of 
information I can possibly trim out that way. Do you know of a way to 
measure the difference in underlying IPC payload sizes?


 Basically, TransactionTooLargeException means you're trying to 
 retrieve  1MB (IIRC) from a foreign process. In this case, the user 
 has too many apps installed, presumably. 


This is why I think Google needs to do the underlying work in batches or 
otherwise overcome the 1M limitation. This is happening on regular user 
devices.

Bryan

-- 
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] Re: how to check API usage information in apk file?

2012-07-04 Thread Rushyang Darji
Hello Michael,
I'm just a beginner in Android Application Development. And pardon me if I
understood your question incorrectly. But, I suppose you want to check
either which API level is there or you want to check which function call
did the developer make to achieve some task.

For both of them, you could sure decompile the APK and view the source
code, understand it and fetch the information you need.

Now, if you want to read the .java source code directly, there are some
tool you will need. Just follow the steps below carefully.

1) If you are using windows based OS, you will need to rename that APK
extension to .zip. And extract that file. If you're using Linux, that APK
file should automatically appear for extraction in packages like File
Roller.

2) After extraction, there should be file with the extension .dex, which is
Dalvik VM Dex file. You will need a tool called Dex2Jar to convert it
into JAR file format. I can't provide you that cause I don't know which OS
you're using. But as per your OS you could google it and I reckon finding
it should be hard.

3) After conversion to JAR file format, you will need Java Decompiler to
view them as java files directly. This way you could view the source code
directly and try to understand which function or method did they use.

4) Of course, from above all steps, you won't be able to understand the
entry point of the application because you won't be able to view the XML
file yet.
For viewing the XML file you will need APKTOOL. I suspect for the
beginners it is tough, so I'll explain it in more detail.
Apktool need to be input /system/framework/framework-res.apk file first.
Know the maxsdkversion of that apk file, suppose its 15 then start Android
Emulator with Android 4.0.3 and pull that file from adb.
Give that framework-res.apk file as its input by
`apktool if framework-res.apk`
and then
`apktool d YOUR_APK_FILENAME_HERE.apk`

it will extract that apk file in smali codes and viewable XML file format.
Again, this XML files are necessary to view the entry point into that
application such as manifest.xml and UI from layout file.

I hope that will fill your needs.

regards,
Rushyang Darji
rushyangda...@gmail.com



On Thu, Jul 5, 2012 at 1:40 AM, M xuetao@gmail.com wrote:

 no, I mean what api calls are used by one andorid app?

 Any method to obtain such information from apk file?

 Thanks.

 On Jun 19, 5:53 pm, Kristopher Micinski krismicin...@gmail.com
 wrote:
  what APIs do you mean?  It uses the Android API, most likely ... Do
  you mean what API *level*?
 
  kris
 
 
 
  On Tue, Jun 19, 2012 at 8:34 PM, michael xuetao@gmail.com wrote:
   Hi, all,
 
   Given an apk file, how to check what APIs are used by this apk file?
 
   Thanks.
 
   --
   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 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 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] About the APIs protected by Android permissons

2012-07-04 Thread Kristopher Micinski
android-permissions.org has a mapping, but it's old / out of date.
The developers of the paper haven't released the tool, though
theoretically the analysis has been done for other versions of the
platform...

You can also try to ask about specific permissions...

kris

On Wed, Jul 4, 2012 at 4:00 PM, M xuetao@gmail.com wrote:

 Is there any source or document about which APIs protected by Android
 permissions?  namely, API vs Android permission mapping.

 Thanks.

 --
 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 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] Simulating power button press from an android application

2012-07-04 Thread Ashwani Kumar
Hi, 
i am trying to invoke the switch off dialog box that appears when we 
press power button. But i want to accomplish this task from an android 
application or a Junit test case. I will choose the most feasible approach 
in this case. I have been trying to do this but was not able to succeed. I 
am trying to use the following five approaches:
First approach:
===
  long eventTime = SystemClock.uptimeMillis(); boolean
 * dispateched = launcherButtonWInst.dispatchKeyEvent(new
 * KeyEvent(eventTime, eventTime, KeyEvent.ACTION_DOWN,
 * KeyEvent.KEYCODE_POWER, 0, 0, 0, 0, 0) );
 * Log.i(LOG_TAG,String.valueOf(dispateched)); boolean
 * dispateched2=launcherButtonWInst.dispatchKeyEvent(new
 * KeyEvent(eventTime+2000, eventTime+2000, 
KeyEvent.ACTION_UP,
 * KeyEvent.KEYCODE_POWER, 0, 0, 0, 0, 0) );
 * Log.i(LOG_TAG,String.valueOf(dispateched2));
===

Second apporach:
=
private void generateKeys() {
// Obtain the WindowManager system service interface
IBinder wmbinder = ServiceManager.getService(window);
Log.d(LOG_TAG, WindowManager:  + wmbinder);
IWindowManager wm = IWindowManager.Stub.asInterface(wmbinder);
keyUpDown(wm, KeyEvent.KEYCODE_POWER);
}

private void keyUpDown(IWindowManager wm, int keycode) {
try {
Log.d(LOG_TAG, keyDown:  + keycode);
wm.injectKeyEvent(new KeyEvent(KeyEvent.ACTION_DOWN, keycode), 
true);
Log.d(LOG_TAG, keyUp:  + keycode);
wm.injectKeyEvent(new KeyEvent(KeyEvent.ACTION_UP, keycode), 
true);
} catch (RemoteException e) {
// TODO Auto-generated catch block
Log.e(ERROR!, e.toString());
e.printStackTrace();
}
}


Third approach:

Instrumentation inst = new Instrumentation();
inst.sendKeyDownUpSync(KeyEvent.KEYCODE_POWER);
==

Fourth approach:
==
try {
// long now =SystemClock.uptimeMillis();
// KeyEvent down = new KeyEvent(now, now,
// KeyEvent.ACTION_DOWN, KeyEvent.KEYCODE_POWER, 0);
//
// Log.d( LOG_TAG,down.toString() );
// KeyEvent up = new KeyEvent(now+2000, now+2000,
// KeyEvent.ACTION_UP, KeyEvent.KEYCODE_POWER, 0);
// Log.d( LOG_TAG,up.toString() );
// 
(IWindowManager.Stub.asInterface(ServiceManager.getService(window))).injectKeyEvent(down,
// true);
// try {
// Thread.sleep(2000);
// } catch (InterruptedException e) {
// // TODO Auto-generated catch block
// e.printStackTrace();
// }
// 
(IWindowManager.Stub.asInterface(ServiceManager.getService(window))).injectKeyEvent(up,
// true);
// } catch (RemoteException e) {
// Log.d(LOGTAG,
// SendKeyEvent exception:+e.getMessage());
// }


Fifth approach:

try {
Context mContext = getBaseContext();
Dialog dialog=new Dialog(mContext);

dialog.getWindow().setType(WindowManager.LayoutParams.TYPE_SYSTEM_ALERT);
ShutdownThread.shutdown(mContext, true);

} catch (Exception e) {
Log.e(ERROR!!!, e.toString());
e.printStackTrace();
}
===

But none of them is working for me. The fifth approach is invoking 
shutdown() method of ShutdownThread class. But it gives me following error:
07-05 10:18:21.489: W/System.err(709): 
android.view.WindowManager$BadTokenException: Unable to add window 
android.view.ViewRootImpl$W@4104d798 -- permission denied for this window 
type
07-05 10:18:21.499: W/System.err(709): at 
android.view.ViewRootImpl.setView(ViewRootImpl.java:537)
07-05 10:18:21.499: W/System.err(709): at 
android.view.WindowManagerImpl.addView(WindowManagerImpl.java:301)
07-05 10:18:21.499: W/System.err(709): at 
android.view.WindowManagerImpl.addView(WindowManagerImpl.java:215)
07-05 10:18:21.499: 

[android-developers] How to get size of FrameLayout in my app?

2012-07-04 Thread hktsang
Dear all,

I've a problem by getting the width of FrameLayout in my app. when I use 
fl.getWidth();  {fl is already assign to FrameLayout}
the result is 0. Can anyone teach me something about that?

Thanks,

HK Tsang
 

-- 
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] Re: how to check API usage information in apk file?

2012-07-04 Thread Kristopher Micinski
No, there's no simple way to do it, you have to disassemble it and go
through it's dex..

Why would you want to know this?  Maybe we can suggest a better alternative.

kris

On Wed, Jul 4, 2012 at 4:10 PM, M xuetao@gmail.com wrote:
 no, I mean what api calls are used by one andorid app?

 Any method to obtain such information from apk file?

 Thanks.

 On Jun 19, 5:53 pm, Kristopher Micinski krismicin...@gmail.com
 wrote:
 what APIs do you mean?  It uses the Android API, most likely ... Do
 you mean what API *level*?

 kris



 On Tue, Jun 19, 2012 at 8:34 PM, michael xuetao@gmail.com wrote:
  Hi, all,

  Given an apk file, how to check what APIs are used by this apk file?

  Thanks.

  --
  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 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 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] Call the functions of *.SO from JAVA

2012-07-04 Thread chainz roid
Hi everyone

   I'm working in ICS and I'm developing own android device. Well i 
have vcfsclint.so file its contains more functions.(Ex. EnrollUser, 
IdentifUser etc,..) I want to call this functions from my java application. 

  Regarding this where i have to add this .SO file and how can i 
call those function from my java application any one can suggest 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