Re: [android-developers] Re: App Widget fails to be added, "thanks" to customized platform

2011-08-31 Thread Dianne Hackborn
Start with the app widget sample in API demos.  If this isn't working, your
"customized platform" is broken.

On Wed, Aug 31, 2011 at 6:03 PM, eagle  wrote:

> Sorry for my English... What i mean is that, when i switch to
> customized platform and are not using the private functions, the
> program doesn't work (Even a "Hello" app widget program doesn't work).
> The app widget with a configuration activity won't be added, while the
> app widget without configuration activity works.
>
>
> On Sep 1, 12:51 am, Dianne Hackborn  wrote:
> > On Tue, Aug 30, 2011 at 10:17 PM, eagle  wrote:
> > > But the problem is that,  even I didn't use these private functions,
> > > it didn't work.
> >
> > The article you linked is purely and solely about using internal
> functions.
> >  If you are not using it and still having your problem, why did you
> mention
> > it?
> >
> > Also it is going to help a lot if you post more about what your actual
> > problem is.  What is the stack crawl of the crash?  What are you trying
> to
> > do, and what is the undesired behavior you are getting?
> >
> > --
> > 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
>



-- 
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] Read meta data from large video file

2011-08-31 Thread Naveen
Hello Android developer,

I have a video file which containing  meta data. i want to retrieve
the meta data from this video particular position of file video.


Please refer me perfect link. or coding stubs which will be best for
handle large video file also.

Thanks
NaVi

-- 
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: Removing unused resources.

2011-08-31 Thread Zsolt Vasvari
Sure, delete the resource and see if the project still compiles or
not.

On Sep 1, 1:45 pm, Akhilesh Mani  wrote:
> I am looking for an efficient way to find out if a resource (mostly a
> drawable) is used in java or in an XML file.The problem is, that on my
> current project the drawables are changed often and now I have some
> drawables, which might never be used.Is there a tool/way to find those
> unused drawables without search each filename in the whole project?
>
> Best Regards.
>
> Mani.

-- 
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 installer strange issue

2011-08-31 Thread Sudha
What I understood from your reply is that
if you press "OPEN" new instaces of teh appln willbe getting created
and if you press "DONE" and then start the app from menu , the appln
should resume ?

-- 
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] AVD Emulator

2011-08-31 Thread Perry168
Hi!
When the AVD emulator can emulate over 1024M memory!

-- 
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: APK signing and certificate for production device

2011-08-31 Thread C++ Narayanan
Pratik,
well signing your application is only for the purpose of security
while uploading it on android market!
 once you have genrate ur "private keystore" , u have to signed ur
application with that "private keystore" to publish it on android
market
 once publish that apk and later if u redesigned or made change in
your app source code and want replace the app in the market u have to
use the same "private keystore" without that same keystore u cannt
change or modify the application thats the only purpose of it! as far
as i know

-- 
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] Removing unused resources.

2011-08-31 Thread Akhilesh Mani
I am looking for an efficient way to find out if a resource (mostly a
drawable) is used in java or in an XML file.The problem is, that on my
current project the drawables are changed often and now I have some
drawables, which might never be used.Is there a tool/way to find those
unused drawables without search each filename in the whole project?

Best Regards.

Mani.

-- 
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: APK signing and certificate for production device

2011-08-31 Thread Pratik Prajapati
Can any one provide some inputs?

On Wed, Aug 31, 2011 at 9:15 AM, Pratik Prajapati <
pratik.prajap...@gmail.com> wrote:

> Dear All,
>
> For production of the device, android APKs needs to be signed. I have
> created keystore as explained in
> http://developer.android.com/guide/publishing/app-signing.html and signed
> my APKs with that keystore.
>
> I am doing it for eclair.
>
> I need to know following things.
>
> (1) Do I need to sign the andoird framework build as well, apart from APKs
> that I'll provide in my production device? the older guidelines say it.
> http://www.kandroid.org/online-pdk/guide/release_keys.html
>
> (2) Is there any difference between APK signing and APK certificate?
>
> (3) Any thing else I need to do for signing and certificate?
>
> Thanks in advance.
>
> Regards,
> Pratik
>
>


-- 
Kind Regards,
Pratik Prajapati

-- 
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 installer strange issue

2011-08-31 Thread rich friedel
It is per design. You should call finish() on your activity in your 
onDestroy() method.

Again, I highly recommend you familiarize yourself with the Activity class 
and its lifecycle. 
http://developer.android.com/reference/android/app/Activity.html

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

[android-developers] Re: Android installer strange issue

2011-08-31 Thread Sudha
But,
When you install and press "done" instead of "open"
and repeat this testing, the activity will resume form the place you
pressed menu button.
only when you press "open" and repeat it wont resume,it will restart.

So its not as per design I guess.else teh application should have
behaved the same way in both the scenarios.

-- 
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] Anyone notice app usage down since early July for High Maturity apps?

2011-08-31 Thread pawpaw17
Hi Guys,

I have an app that has been in the Market since June 2009. I had been
seeing a steady build of users and pageviews for many months, but in
July the trend reversed and I'm down almost 20% both for visitors and
pageviews since then. Some of my users told me the app seemed the
"disappear" from the market - I think google twiddled with the default
maturity filter for some versions of the market, and users - without
knowing it - all of a sudden were filtering for "Everyone" rather than
'All Apps". This might have been fixed now, but I'm not sure.

Anyway, my app might be just sucking wind right now, but I wonder if
any of you have noticed a similar trend since early July.

Thanks!

pawpaw17

-- 
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] Help! Application crash while scrolling in listview

2011-08-31 Thread photon
Hello,

I have a weird problem with listview, while using simplecursor
adapter. Here is the error

08-31 21:50:14.540: INFO/dalvikvm(12195): Uncaught exception thrown by
finalizer (will be discarded):
08-31 21:50:14.540: INFO/dalvikvm(12195):
java.lang.IllegalStateException: Binder has been finalized!
08-31 21:50:14.540: INFO/dalvikvm(12195): at
android.os.BinderProxy.transact(Native Method)
08-31 21:50:14.540: INFO/dalvikvm(12195): at
android.database.BulkCursorProxy.close(BulkCursorNative.java:289)
08-31 21:50:14.540: INFO/dalvikvm(12195): at
android.database.BulkCursorToCursorAdaptor.close(BulkCursorToCursorAdaptor.java:
141)
08-31 21:50:14.540: INFO/dalvikvm(12195): at
android.database.CursorWrapper.close(CursorWrapper.java:43)
08-31 21:50:14.540: INFO/dalvikvm(12195): at
android.content.ContentResolver
$CursorWrapperInner.close(ContentResolver.java:1575)
08-31 21:50:14.540: INFO/dalvikvm(12195): at
android.content.ContentResolver
$CursorWrapperInner.finalize(ContentResolver.java:1586)
08-31 21:50:14.540: INFO/dalvikvm(12195): at
dalvik.system.NativeStart.run(Native Method)

I have runQueryOnBackgroundThread implemented in my cursorAdapter,
which is invoked by the Filter.filter method call from the activity.
So I dont have any reference of the cursor in my activity. Everytime I
query I understand I get cursor changed callback in my cursor adapter,
which extends SimpleCursorAdapter

Here is how it looks

public void changeCursor(Cursor cursor) {
Log.d(TAG, "Cursor changed ...  "+ cursor);
if (cursor != null) {
setLoading(false);
}
super.changeCursor(cursor);
initSectionHeaders(cursor);
notifyDataSetChanged();
}

runQueryOnBackgroundThread just returns a cursor from a query.

Am I missing something, should the cursor be closed or managed
anywhere? Any help on the leads would greatly help. 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] Re: use listview get web data

2011-08-31 Thread Kavekkb
public class Tab1Activity extends Activity implements
OnClickListener{

private Button get;
private TextView tv;
private DefaultHttpClient client;
private HttpPost request2;
private HttpResponse response;
private ListView listview1;

public void onCreate(Bundle savedInstanceState) {

super.onCreate(savedInstanceState);
setContentView(R.layout.tab1main);



tv = (TextView)findViewById(R.id.tv);
client = new DefaultHttpClient();
request2 = new HttpPost();



try {

 List nameValuePairs = new
ArrayList(2);
 request2.setEntity(new 
UrlEncodedFormEntity(nameValuePairs));
 request2.setURI(new URI("http://172.16.152.152:8081/dking/
not_returnt.php"));

response = client.execute(request2);

HttpEntity entity = response.getEntity();

byte[] buf = new byte[5000];
BufferedInputStream bin = new
BufferedInputStream(entity.getContent());
bin.read(buf);
bin.close();

String result = new String(buf);


tv.append(result);



} catch (URISyntaxException e) {
// TODO Auto-generated catch block
e.printStackTrace();
} catch (ClientProtocolException e) {
// TODO Auto-generated catch block
e.printStackTrace();
} catch (IOException e) {
// TODO Auto-generated catch block
e.printStackTrace();
}
}


public void onClick(View v) {
}
}


this is my source code
but I don't know how to put data in listview

-- 
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: use listview get web data

2011-08-31 Thread Kavekkb
public class Tab1Activity extends Activity implements
OnClickListener{

private Button get;
private TextView tv;
private DefaultHttpClient client;
private HttpPost request2;
private HttpResponse response;
private ListView listview1;

public void onCreate(Bundle savedInstanceState) {

super.onCreate(savedInstanceState);
setContentView(R.layout.tab1main);

tv = (TextView)findViewById(R.id.tv);
client = new DefaultHttpClient();
request2 = new HttpPost();

try {

 List nameValuePairs = new
ArrayList(2);
 request2.setEntity(new 
UrlEncodedFormEntity(nameValuePairs));
 request2.setURI(new URI("http://172.16.152.152:8081/dking/
not_returnt.php"));

response = client.execute(request2);

HttpEntity entity = response.getEntity();

byte[] buf = new byte[5000];
BufferedInputStream bin = new
BufferedInputStream(entity.getContent());
bin.read(buf);
bin.close();

String result = new String(buf);

tv.append(result);

} catch (URISyntaxException e) {
// TODO Auto-generated catch block
e.printStackTrace();
} catch (ClientProtocolException e) {
// TODO Auto-generated catch block
e.printStackTrace();
} catch (IOException e) {
// TODO Auto-generated catch block
e.printStackTrace();
}
}




this is my source code
data don't put in listview..

-- 
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: App Widget fails to be added, "thanks" to customized platform

2011-08-31 Thread eagle
Sorry for my English... What i mean is that, when i switch to
customized platform and are not using the private functions, the
program doesn't work (Even a "Hello" app widget program doesn't work).
The app widget with a configuration activity won't be added, while the
app widget without configuration activity works.


On Sep 1, 12:51 am, Dianne Hackborn  wrote:
> On Tue, Aug 30, 2011 at 10:17 PM, eagle  wrote:
> > But the problem is that,  even I didn't use these private functions,
> > it didn't work.
>
> The article you linked is purely and solely about using internal functions.
>  If you are not using it and still having your problem, why did you mention
> it?
>
> Also it is going to help a lot if you post more about what your actual
> problem is.  What is the stack crawl of the crash?  What are you trying to
> do, and what is the undesired behavior you are getting?
>
> --
> 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] Re: onLocationChange never get called

2011-08-31 Thread gjs
Hi,

If the gps is blinking it is waiting for a first fix, go outside in
clear sky and wait for a few minutes for a fix. It also helps if the
device has a working internet connection to reduce time to first fix.

Regards

On Aug 31, 5:32 pm, Bipin Sutariya  wrote:
> Has any one have any solution for this? Its bit urgent.
>
> On Aug 28, 5:09 pm, Sumedh  wrote:
>
>
>
>
>
>
>
> > Hi,
> > I m also trying to do the same application.
> > And managed to get lat-lon,date ,time. But this code works on
> > emulator(eclipse)
> > when i install the same apk on android phone it doesn,t work
>
> > my code is:
> > public class TestBroadcastActivity extends Activity implements
> > LocationListener
> > {
> >         private LocationManager myManager;
> >         private LocationListener loc;
> >     private TextView tv;
> >     @Override
> >     public void onCreate(Bundle savedInstanceState)
> >     {
> >         super.onCreate(savedInstanceState);
> >         setContentView(R.layout.main);
>
> >         tv = (TextView) findViewById(R.id.TextView01);
>
> >        myManager =
> > (LocationManager)this.getSystemService(Context.LOCATION_SERVICE);
>
> >         myManager.requestLocationUpdates(myManager.GPS_PROVIDER, 3000,
> > 0, locationListener);
> >     }
> >      LocationListener locationListener = new LocationListener()
> >     {
> >     public void onLocationChanged(Location location)
> >     {
> >                 try
> >                 {
> >                 String s = "";
> >                 s += "\tTime: "+location.getTime() + "\n";
> >                 s += "\tLatitude:  " + location.getLatitude()  + "\n";
> >                 s += "\tLongitude: " + location.getLongitude() + "\n";
> >                 s += "\tAccuracy:  " + location.getAccuracy()  + "\n";
> >                 tv.setText(s);
> >                 }
> >                 catch (Exception e)
> >                 {
> >                         System.out.println("Exception-->"+e);
> >                 }
> >     }
>
> >     public void onStatusChanged(String provider, int status, Bundle
> > extras) {}
> >     public void onProviderEnabled(String provider) {}
> >     public void onProviderDisabled(String provider) {}
>
> >     };
>
> >         public void onLocationChanged(Location location) {}
> >         public void onProviderDisabled(String provider) {}
> >         public void onProviderEnabled(String provider) {}
> >         public void onStatusChanged(String provider, int status, Bundle
> > extras) {}
>
> > }
>
> > On Aug 28, 1:38 pm,BipinSutariya wrote:
>
> > > OK one change Toast.makeText requires show() method to show toast. I
> > > added it and still onLocationChange not called.
>
> > > On Aug 28, 1:32 pm,BipinSutariya wrote:
>
> > > > Hi,
>
> > > > I am trying to develop application in which i need current lat/lang.
> > > > However onLocationChange method never get called.
>
> > > > Following is my code, and note that i have given all required
> > > > permission like android.permission.ACCESS_COARSE_LOCATION,
> > > > android.permission.ACCESS_FINE_LOCATION, android.permission.INTERNET
> > > > in manifest file. I can see gps icon on status bar that keep blinking
> > > > to find location, but never get success.
>
> > > > Can any one please help me on this.
>
> > > > public class LocationServiceActivity extends Activity implements
> > > > LocationListener{
> > > >     /** Called when the activity is first created. */
> > > >     @Override
> > > >     public void onCreate(Bundle savedInstanceState) {
> > > >         super.onCreate(savedInstanceState);
> > > >         setContentView(R.layout.main);
>
> > > >         LocationManager lm =
> > > > (LocationManager)this.getSystemService(Context.LOCATION_SERVICE);
>
> > > >         Boolean isGPSEnabled =
> > > > lm.isProviderEnabled(LocationManager.GPS_PROVIDER);
> > > >         Boolean isNetworkEnabled =
> > > > lm.isProviderEnabled(LocationManager.NETWORK_PROVIDER);
>
> > > >         if(isGPSEnabled)
> > > >         {
> > > >                 lm.requestLocationUpdates(LocationManager.GPS_PROVIDER, 
> > > > 0, 0,
> > > > this);
> > > >         }
> > > >         else if(isNetworkEnabled)
> > > >         {
> > > >                 
> > > > lm.requestLocationUpdates(LocationManager.NETWORK_PROVIDER,
> > > > 0, 0, this);
> > > >         }
> > > >         else
> > > >         {
> > > >                 Toast.makeText(this, "NO SERVICE ENABLED", 5000);
> > > >         }
>
> > > >     }
>
> > > >     public void onLocationChanged(Location location) {
> > > >         Toast.makeText(this, location.getLatitude()+"---
>
> > > > >"+location.getLongitude(), 5000);
>
> > > >     }
> > > >     public void onProviderDisabled(String provider) {
> > > >         // TODO Auto-generated method stub
>
> > > >     }
> > > >     public void onProviderEnabled(String provider) {
> > > >         // TODO Auto-generated method stub
>
> > > >     }
> > > >     public void onStatusChanged(String provider, int status, Bundle
> > > > extras) {
> 

[android-developers] Re: How to P2P between with the phone and reader?

2011-08-31 Thread nadam
See 
http://groups.google.com/group/android-developers/browse_frm/thread/8afb4b3dff5461f7

On 31 Aug, 03:43, xiaodai  wrote:
> Can you tell me how to enter NFC state for the Reader??
> On 8月29日, 下午11时14分, rich friedel  wrote:
>
>
>
>
>
>
>
> > Check out the NFCDemo sample code to get 
> > started...http://developer.android.com/resources/samples/NFCDemo/index.html

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


[android-developers] Re: AbsoluteLayout

2011-08-31 Thread nadam
Once you publish the app on the Android Market you will get complaints
from people who have devices with other screen resolutions. Then you
can go back to Eclipse and see exactly where the problems are since
those classes are crossed out.

To prevent these complaints read 
http://developer.android.com/guide/practices/screens_support.html

On 31 Aug, 03:49, bob  wrote:
> Am I a naughty boy for wanting to use AbsoluteLayout?
>
> I have an iPhone app that needs conversion to Android ASAP.
>
> Also, is there a way to make Eclipse stop crossing out my layout code?
>
> Here's what Eclipse did:
>
> https://sites.google.com/site/coolfonne/_/rsrc/1314755045012/abs/abs.png

-- 
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 populate a gridview with data from a table (SQLite)?

2011-08-31 Thread Dalton Cézane
Hello again. I want to thank the helping... with ListView it worked... I do
not know why, in the same way, my app did not work with GridView. But, in
future I think it will be easier for understand...

Thank you.

On Wed, Aug 31, 2011 at 5:23 PM, Michael Banzon  wrote:

> On Wed, Aug 31, 2011 at 10:19 PM, TreKing  wrote:
> > On Wed, Aug 31, 2011 at 3:11 PM, Dalton Cézane 
> > wrote:
> >>>
> >>> Is your getView() even called?
> >>
> >> I do not know where to call it, because all samples I've seen do not
> call
> >> it explicitly... Can you help with this?
>
> When using ListView you need to set the adapter on the view.
>
> --
> 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
>



-- 
===
Dalton Cézane - Smarteju Tecnologia
Especialista em Ciência da Computação (UFCG)
Bacharel em Ciência da Computação (UFCG)
Técnico em Informática (ETER)

-- 
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: two icons for the same app

2011-08-31 Thread Streets Of Boston
Look at your AndroidManifest.xml file.
If you have *two * items whose intent filters look like this:





then that's one too many (if you don't want two of them).

If you have only one activity with that intent-filter, then i'm not sure 
what is causing your 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] two icons for the same app

2011-08-31 Thread TreKing
On Wed, Aug 31, 2011 at 4:58 PM, john brown wrote:

> The first time I noticed the second icon was after I included a
> second activity that displays a WebView.
>

Did you mark this Activity to have the "LAUNCHER" flag?

-
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] how many threads does android browser generate?

2011-08-31 Thread Dianne Hackborn
I really don't know what you are trying to get at.  As I said, as far as I
know browser CPU use is generally pretty single-threaded -- the DOM
rendering and JavaScript interpreter all need to run in the same thread.
 Just creating more threads doesn't magically allow this work to be spread
across them.

And again, Gingerbread was not written for multi-core CPUs.  In fact if you
try to run stock GB on a multi-core CPU you will be extremely unstable
because there are many things not working correctly for SMP, especially ARM
SMP.  So it doesn't make sense to ask questions about how stock GB runs on
multi-core, because it just doesn't.

If you are wondering about a particular phone someone has released with GB,
you will need to talk with that manufacturer, because they will have needed
to do some work to have GB run on a multi-core CPU.

On Wed, Aug 31, 2011 at 2:09 PM, Jack Harvard wrote:

> Thanks for your reply, Dianne. If I run the Android browser as my only
> application in Gingerbread on a quad-core smartphone, and the page to be
> loaded is stored locally in memory (no network delay etc, in this case, the
> browser is single-threaded only as no network connection?), I wouldn't see
> any performance scaling (or worse, as the OS may move the threads to another
> core less busy in a circle) from a single-core smartphone, everything else
> being the same?
>
> On 31 Aug 2011, at 21:00, Dianne Hackborn wrote:
>
> > Gingerbread isn't designed for multi-core CPUs.  The browser doesn't try
> to create threads to use multiple CPUs, it creates threads to have multiple
> network connections.
> >
> > Besides networking, browsers are pretty intrinsically single-threaded
> anyway.  The complicated stuff all needs to run in one thread: DOM
> rendering, JavaScript, etc.
> >
> > On Wed, Aug 31, 2011 at 12:08 PM, Jack Harvard 
> wrote:
> > I want to understand how many threads Gingerbread generates in order to
> understand how the browser performance scale with multicores? For example,
> if  "a few " means 2, that means 4 cores wouldn't scale the browser
> performance by anywhere close to 4 times. I understand that Gingerbread
> doesn't officially support SMP, sometimes browser does crash on multicore
> platforms, it's not a problem for me though.
> >
> > On 31 Aug 2011, at 18:57, Dianne Hackborn wrote:
> >
> > > Oh and Gingerbread wasn't designed to run on anything but single CPU
> systems, so that's irrelevant to the question of the base platform.  Of
> course people shipping Android modify it in various ways, and the browser is
> often one of the things they modify.
> > >
> > > On Wed, Aug 31, 2011 at 10:57 AM, Dianne Hackborn 
> wrote:
> > > A few.  Why? :)
> > >
> > >
> > > On Wed, Aug 31, 2011 at 10:40 AM, Jack Harvard 
> wrote:
> > > Wondering how many threads does android browser generate? Suppose it's
> Gingerbread running on a dual-core or quad-core ARM processor.
> > >
> > > --
> > > 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.
> > >
> > >
> > >
> > >
> > > --
> > > 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
> >
> > --
> > 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: plea

[android-developers] two icons for the same app

2011-08-31 Thread john brown
I have an application that I "install" via the Eclipse IDE toolbar
icon "run package.name.app". My phone shows two icons for this app.
(only one icon until recently) The icons look identical but the name
is long and I cannot see the end of either icon labels. Even if I
uninstall the app via Settings > Applications > Manage Applications,
the next time I run it from Eclipse, the two icons are both there
again. The app is only listed one time under Manage Applications. The
first time I noticed the second icon was after I included a second
activity that displays a WebView. Everything seems to work OK. I can
launch the second activity and close it just fine.

Why do I have two icons? (I did not include code because I do not know
which code might be relevant.)

Thanks, John Brown

-- 
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 many threads does android browser generate?

2011-08-31 Thread Jack Harvard
Thanks for your reply, Dianne. If I run the Android browser as my only 
application in Gingerbread on a quad-core smartphone, and the page to be loaded 
is stored locally in memory (no network delay etc, in this case, the browser is 
single-threaded only as no network connection?), I wouldn't see any performance 
scaling (or worse, as the OS may move the threads to another core less busy in 
a circle) from a single-core smartphone, everything else being the same? 

On 31 Aug 2011, at 21:00, Dianne Hackborn wrote:

> Gingerbread isn't designed for multi-core CPUs.  The browser doesn't try to 
> create threads to use multiple CPUs, it creates threads to have multiple 
> network connections.
> 
> Besides networking, browsers are pretty intrinsically single-threaded anyway. 
>  The complicated stuff all needs to run in one thread: DOM rendering, 
> JavaScript, etc. 
> 
> On Wed, Aug 31, 2011 at 12:08 PM, Jack Harvard  wrote:
> I want to understand how many threads Gingerbread generates in order to 
> understand how the browser performance scale with multicores? For example, if 
>  "a few " means 2, that means 4 cores wouldn't scale the browser performance 
> by anywhere close to 4 times. I understand that Gingerbread doesn't 
> officially support SMP, sometimes browser does crash on multicore platforms, 
> it's not a problem for me though.
> 
> On 31 Aug 2011, at 18:57, Dianne Hackborn wrote:
> 
> > Oh and Gingerbread wasn't designed to run on anything but single CPU 
> > systems, so that's irrelevant to the question of the base platform.  Of 
> > course people shipping Android modify it in various ways, and the browser 
> > is often one of the things they modify.
> >
> > On Wed, Aug 31, 2011 at 10:57 AM, Dianne Hackborn  
> > wrote:
> > A few.  Why? :)
> >
> >
> > On Wed, Aug 31, 2011 at 10:40 AM, Jack Harvard  
> > wrote:
> > Wondering how many threads does android browser generate? Suppose it's 
> > Gingerbread running on a dual-core or quad-core ARM processor.
> >
> > --
> > 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.
> >
> >
> >
> >
> > --
> > 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
> 
> --
> 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

-- 
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 populate a gridview with data from a table (SQLite)?

2011-08-31 Thread Michael Banzon
On Wed, Aug 31, 2011 at 10:19 PM, TreKing  wrote:
> On Wed, Aug 31, 2011 at 3:11 PM, Dalton Cézane 
> wrote:
>>>
>>> Is your getView() even called?
>>
>> I do not know where to call it, because all samples I've seen do not call
>> it explicitly... Can you help with this?

When using ListView you need to set the adapter on the view.

-- 
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 populate a gridview with data from a table (SQLite)?

2011-08-31 Thread TreKing
On Wed, Aug 31, 2011 at 3:11 PM, Dalton Cézane wrote:

> Is your getView() even called?
>
>
> I do not know where to call it, because all samples I've seen do not call
> it explicitly... Can you help with this?
>

Right, the system calls it for you when it needs to. I mean confirm that
this is happening. A break point or log message would do it.

-
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] How to populate a gridview with data from a table (SQLite)?

2011-08-31 Thread Dalton Cézane
On Wed, Aug 31, 2011 at 5:15 PM, Mark Murphy wrote:

> On Wed, Aug 31, 2011 at 4:11 PM, Dalton Cézane 
> wrote:
> > I do not know where to call it, because all samples I've seen do not call
> it
> > explicitly...
>
> You don't call it. GridView does.
>

It was what I understood about the samples. But I do not know how the
GridView does that and why it is not happening in my app.


>
> >> Have you tried simplifying your getView() to just return a TextView with
> >> some hard coded values, to make sure that part works?
> >
> > Not yet... I will try too...
>
> You might consider starting with a ListView. GridView is not
> significantly different from ListView in terms of how it interacts
> with adapters, and there are many more samples demonstrating ListView.
> Once you have a custom Adapter working with a ListView,
> convert it to a GridView.
>

I will try now with a ListView...


>
> --
> Mark Murphy (a Commons Guy)
> http://commonsware.com | http://github.com/commonsguy
> http://commonsware.com/blog | http://twitter.com/commonsguy
>
> Android Training in Oslo: http://bit.ly/fjBo24
>
> --
> 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
>



-- 
===
Dalton Cézane - Smarteju Tecnologia
Especialista em Ciência da Computação (UFCG)
Bacharel em Ciência da Computação (UFCG)
Técnico em Informática (ETER)

-- 
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 populate a gridview with data from a table (SQLite)?

2011-08-31 Thread Mark Murphy
On Wed, Aug 31, 2011 at 4:11 PM, Dalton Cézane  wrote:
> I do not know where to call it, because all samples I've seen do not call it
> explicitly...

You don't call it. GridView does.

>> Have you tried simplifying your getView() to just return a TextView with
>> some hard coded values, to make sure that part works?
>
> Not yet... I will try too...

You might consider starting with a ListView. GridView is not
significantly different from ListView in terms of how it interacts
with adapters, and there are many more samples demonstrating ListView.
Once you have a custom Adapter working with a ListView,
convert it to a GridView.

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

Android Training in Oslo: http://bit.ly/fjBo24

-- 
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] Handling Adjacent Fragments in ViewPager Contributing to Options Menu

2011-08-31 Thread Jake Wharton
Excellent. I'm looking forward to it. Thanks for your reply!

-- 
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 populate a gridview with data from a table (SQLite)?

2011-08-31 Thread Dalton Cézane
On Wed, Aug 31, 2011 at 3:45 PM, TreKing  wrote:

> On Wed, Aug 31, 2011 at 1:37 PM, Dalton Cézane wrote:
>
>> But I can not see the gridview on the display...
>
>
> Is your getView() even called?


I do not know where to call it, because all samples I've seen do not call it
explicitly... Can you help with this?


> Have you confirmed it's actually on the screen and sized to be visible?
> (Put some funky colors on it or something)
>

I modified the height to 150dp and now I can see the space between the other
components... but without data in the grid...


> Have you tried simplifying your getView() to just return a TextView with
> some hard coded values, to make sure that part works?
>

Not yet... I will try too...


>
> P.S. - there's no reason to be setting the convertView if it's null 
>
>
>
> -
> 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
>



-- 
===
Dalton Cézane - Smarteju Tecnologia
Especialista em Ciência da Computação (UFCG)
Bacharel em Ciência da Computação (UFCG)
Técnico em Informática (ETER)

-- 
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 many threads does android browser generate?

2011-08-31 Thread Dianne Hackborn
Gingerbread isn't designed for multi-core CPUs.  The browser doesn't try to
create threads to use multiple CPUs, it creates threads to have multiple
network connections.

Besides networking, browsers are pretty intrinsically single-threaded
anyway.  The complicated stuff all needs to run in one thread: DOM
rendering, JavaScript, etc.

On Wed, Aug 31, 2011 at 12:08 PM, Jack Harvard wrote:

> I want to understand how many threads Gingerbread generates in order to
> understand how the browser performance scale with multicores? For example,
> if  "a few " means 2, that means 4 cores wouldn't scale the browser
> performance by anywhere close to 4 times. I understand that Gingerbread
> doesn't officially support SMP, sometimes browser does crash on multicore
> platforms, it's not a problem for me though.
>
> On 31 Aug 2011, at 18:57, Dianne Hackborn wrote:
>
> > Oh and Gingerbread wasn't designed to run on anything but single CPU
> systems, so that's irrelevant to the question of the base platform.  Of
> course people shipping Android modify it in various ways, and the browser is
> often one of the things they modify.
> >
> > On Wed, Aug 31, 2011 at 10:57 AM, Dianne Hackborn 
> wrote:
> > A few.  Why? :)
> >
> >
> > On Wed, Aug 31, 2011 at 10:40 AM, Jack Harvard 
> wrote:
> > Wondering how many threads does android browser generate? Suppose it's
> Gingerbread running on a dual-core or quad-core ARM processor.
> >
> > --
> > 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.
> >
> >
> >
> >
> > --
> > 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
>
> --
> 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

Re: [android-developers] how many threads does android browser generate?

2011-08-31 Thread Jack Harvard
I want to understand how many threads Gingerbread generates in order to 
understand how the browser performance scale with multicores? For example, if  
"a few " means 2, that means 4 cores wouldn't scale the browser performance by 
anywhere close to 4 times. I understand that Gingerbread doesn't officially 
support SMP, sometimes browser does crash on multicore platforms, it's not a 
problem for me though.

On 31 Aug 2011, at 18:57, Dianne Hackborn wrote:

> Oh and Gingerbread wasn't designed to run on anything but single CPU systems, 
> so that's irrelevant to the question of the base platform.  Of course people 
> shipping Android modify it in various ways, and the browser is often one of 
> the things they modify.
> 
> On Wed, Aug 31, 2011 at 10:57 AM, Dianne Hackborn  wrote:
> A few.  Why? :)
> 
> 
> On Wed, Aug 31, 2011 at 10:40 AM, Jack Harvard  wrote:
> Wondering how many threads does android browser generate? Suppose it's 
> Gingerbread running on a dual-core or quad-core ARM processor.
> 
> --
> 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.
> 
> 
> 
> 
> -- 
> 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

-- 
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: HTTP - Check whether server is up & running?

2011-08-31 Thread blake
Maybe you could try a "HEAD" request for a well known page?


-blake
Programming Android, FTW!
http://oreilly.com/catalog/0636920010364


On Aug 31, 11:00 am, TreKing  wrote:
> On Wed, Aug 31, 2011 at 12:59 PM, TreKing  wrote:
> > If it doesn't, it's probably not.
>
> Also, there are error codes servers respond with you can check.
>
> -
> 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] How to populate a gridview with data from a table (SQLite)?

2011-08-31 Thread TreKing
On Wed, Aug 31, 2011 at 1:37 PM, Dalton Cézane wrote:

> But I can not see the gridview on the display...


Is your getView() even called?
Have you confirmed it's actually on the screen and sized to be visible? (Put
some funky colors on it or something)
Have you tried simplifying your getView() to just return a TextView with
some hard coded values, to make sure that part works?

P.S. - there's no reason to be setting the convertView if it's null 

-
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] Re: How to 'delete' allocated class by 'new'??

2011-08-31 Thread Streets Of Boston
As other have stated, Java Objects are garbage collected:

If an Object cannot be reached (from any of the current threads' 
stack-frames or from the heap), directly or indirectly, i.e. there is no 
path to the Object, then this Object can be garbage collected. 
It is impossible to 'delete' an Object in Java.

You can help (just 'help', not force) the garbage collector along a little, 
by setting references to null ("b = null;" in the above examples). However, 
this hardly helps the garbage collector at all. It's not of much use.

You can call System.gc() to indicate that the garbage collector should run 
a.s.a.p. Again, this may or may not work, since calling 'gc()' is only a 
hint. The actual behavior may vary.

If you're dealing with bitmaps, calling bitmap.recycle() may work for you to 
free up memory. Be careful doing this. Make sure other parts of your code 
don't still have a reference to this and use the now recycled bitmap,.

My answer is another question to you:
*Why do you want to know this?*

-- 
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 populate a gridview with data from a table (SQLite)?

2011-08-31 Thread Dalton Cézane
On Tue, Aug 30, 2011 at 11:10 PM, TreKing  wrote:

> On Tue, Aug 30, 2011 at 5:45 PM, Dalton Cézane wrote:
>
>> Yes, do you want I put here all links I read before?
>>
>
> No, but an indication of what you have already tried and what exactly
> you're having trouble with helps.
>
>
>> --> Most of them that I've seen (or all) have examples populating a
>> gridview with some kind of list (String generally).
>>
>
> Right - that's the basic concept. Once you have that, extending your list
> to display an arbitrary view is fairly straightforward.
>
>
>> But I didnt see a good sample (for me - I am new with android)  reading a
>> table and populating the gridview with these data.
>>
>
> Which is it you need help with: the reading of a table or the populating
> the gridview?
> Also: what have you already tried?


My problem is to populate the gridview. I already saw through the debugger
that my code is reading the data correctly from the table, but when the
activity is started, the gridview do not display nothing.

My getView() method is:

public View getView(int position, View convertView, ViewGroup parent) {
// TODO Auto-generated method stub

TextView label = (TextView)convertView;
if (convertView == null) {
convertView = new TextView(this.context);
label = (TextView) convertView;
}
label.setText((getDataFromTable().get(position)).toString()); //the
geDataFromTable() returns a list with the data from the table (tested
observing the debugger)

return(convertView);
}

In my activity I have:

...
ColetaDatabaseAdapter adapter = new ColetaDatabaseAdapter(this,
R.layout.data_display);

GridView g = (GridView) findViewById(R.id.grid);
g.setAdapter(adapter);
...

But I can not see the gridview on the display...

Thanks.


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



-- 
===
Dalton Cézane - Smarteju Tecnologia
Especialista em Ciência da Computação (UFCG)
Bacharel em Ciência da Computação (UFCG)
Técnico em Informática (ETER)

-- 
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] UI design pattern

2011-08-31 Thread Igor Nesralla Ribeiro
Hi,

 

I'm looking for something article or any information about best way to
implement UI design pattern for login screens on tablets(honeycomb) !!

 

Thanks in advance !

 

Igor Nesralla Ribeiro

 

-- 
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 'delete' allocated class by 'new'??

2011-08-31 Thread Nick Risaro
On Wed, Aug 31, 2011 at 6:40 AM, Build account wrote:

> Hi,
>
> Thank you very much to let me know clearly.
> I tired to use your code snippet, but counldn't get sure.
>
> Another question here,
> If I use below code
> 
> String a = new String("test");
> String b = a;
>
> b = null;
>
> 
> In this case,
> the variable 'a' still allocated? Am I right? As long as I keep
> original variable?
>

Yes

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

2011-08-31 Thread Luis Ramirez
If nothing else works try a factory reset.
On Aug 30, 2011 6:22 PM, "gaby debro"  wrote:
> Hello help me I can't install any aplication in ma G1 after
> downloading it always says unsuccess
>
> --
> 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] Is there any oauth2 lib that implemnt client side flow for both facebook and google?

2011-08-31 Thread Alexey Zakharov
Is there any oauth2 lib that implemnt client side flow for both facebook and 
google?

-- 
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] HTTP - Check whether server is up & running?

2011-08-31 Thread TreKing
On Wed, Aug 31, 2011 at 12:59 PM, TreKing  wrote:

> If it doesn't, it's probably not.


Also, there are error codes servers respond with you can check.

-
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] Re: postDelayed vs. post

2011-08-31 Thread Dianne Hackborn
You should be concerned with much more than having the ANR dialog.  The ANR
dialog happens after *5 seconds*.  That is an insanely long amount of time,
well into the broken range.  200ms is a very long time for normal things on
the UI thread -- that is well into the territory of causing obvious glitches
and laggy response in the UI.

On Wed, Aug 31, 2011 at 10:18 AM, Dmitry Golubovsky wrote:

> Dianne,
>
> Thanks for your quick reply.
>
> On Aug 31, 12:28 pm, Dianne Hackborn  wrote:
> > On Wed, Aug 31, 2011 at 9:16 AM, Dmitry Golubovsky  >wrote:
> >
> > > Q1: Is post(action) equivalent to postDelayed(action, 0)?
> >
> > Yes.
>
> OK, may I suggest that this be reflected in the reference?
>
>
> > > what combinations of N and T ranges (including T = 0) are acceptable
> > > to make sure the view remains responsive to touch and other user-
> > > generated events, and "force close/wait" dialog does not appear?
> >
> > It will remain responsive because older messages are processes before
> newer
> > messages, so you can't starve other messages from the queue by re-posting
> a
> > message when you handle it, even with no delay.
>
> OK, so there are no specific priorities on user-generated vs. posted
> events.
>
> > the user is in your app, if using a delay of 20ms means you are keeping
> the
> > CPU running at near 100%, are going to much more quickly drain the
> battery
> > (and the user will see this in the battery use report).
>
> I posted much simplified code. This is the same Smalltalk VM port that
> I mentioned several times in the NDK group.
>
> The VM has an interval timer (which is N in my example), and when it
> expires inside the native code, the VM saves its state and returns to
> the Java UI code. Or otherwise it may return if there is nothing to
> process (no input events). If return happened by timer, the VM will be
> reentered ASAP (that is, after T in my example). Otherwise it may not
> be reentered until another user event is registered. That is, zero-or-
> near-delays between entering native code do not happen 100% of the
> time.
>
> All I am concerned about is not to have the "non-responding" dialog
> and buffer pending events within the application.
>
> Your explanation is very helpful.
>
> Thanks again.
>
> --
> 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

Re: [android-developers] HTTP - Check whether server is up & running?

2011-08-31 Thread TreKing
On Wed, Aug 31, 2011 at 12:53 PM, dillipk  wrote:

> How do I check whether server is up and running or available?
>

If your request succeeds, it's available. If it doesn't, it's probably not.

-
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] how many threads does android browser generate?

2011-08-31 Thread Dianne Hackborn
Oh and Gingerbread wasn't designed to run on anything but single CPU
systems, so that's irrelevant to the question of the base platform.  Of
course people shipping Android modify it in various ways, and the browser is
often one of the things they modify.

On Wed, Aug 31, 2011 at 10:57 AM, Dianne Hackborn wrote:

> A few.  Why? :)
>
>
> On Wed, Aug 31, 2011 at 10:40 AM, Jack Harvard wrote:
>
>> Wondering how many threads does android browser generate? Suppose it's
>> Gingerbread running on a dual-core or quad-core ARM processor.
>>
>> --
>> 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.
>
>


-- 
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] how many threads does android browser generate?

2011-08-31 Thread Dianne Hackborn
A few.  Why? :)

On Wed, Aug 31, 2011 at 10:40 AM, Jack Harvard wrote:

> Wondering how many threads does android browser generate? Suppose it's
> Gingerbread running on a dual-core or quad-core ARM processor.
>
> --
> 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] HTTP - Check whether server is up & running?

2011-08-31 Thread dillipk
Hello,
   My app makes frequent HTTP request to a server.   How do I check
whether server is up and running or available?


Thanks in advance..

-DK

-- 
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 many threads does android browser generate?

2011-08-31 Thread Jack Harvard
Wondering how many threads does android browser generate? Suppose it's 
Gingerbread running on a dual-core or quad-core ARM processor.

-- 
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: postDelayed vs. post

2011-08-31 Thread Dmitry Golubovsky
Dianne,

Thanks for your quick reply.

On Aug 31, 12:28 pm, Dianne Hackborn  wrote:
> On Wed, Aug 31, 2011 at 9:16 AM, Dmitry Golubovsky 
> wrote:
>
> > Q1: Is post(action) equivalent to postDelayed(action, 0)?
>
> Yes.

OK, may I suggest that this be reflected in the reference?


> > what combinations of N and T ranges (including T = 0) are acceptable
> > to make sure the view remains responsive to touch and other user-
> > generated events, and "force close/wait" dialog does not appear?
>
> It will remain responsive because older messages are processes before newer
> messages, so you can't starve other messages from the queue by re-posting a
> message when you handle it, even with no delay.

OK, so there are no specific priorities on user-generated vs. posted
events.

> the user is in your app, if using a delay of 20ms means you are keeping the
> CPU running at near 100%, are going to much more quickly drain the battery
> (and the user will see this in the battery use report).

I posted much simplified code. This is the same Smalltalk VM port that
I mentioned several times in the NDK group.

The VM has an interval timer (which is N in my example), and when it
expires inside the native code, the VM saves its state and returns to
the Java UI code. Or otherwise it may return if there is nothing to
process (no input events). If return happened by timer, the VM will be
reentered ASAP (that is, after T in my example). Otherwise it may not
be reentered until another user event is registered. That is, zero-or-
near-delays between entering native code do not happen 100% of the
time.

All I am concerned about is not to have the "non-responding" dialog
and buffer pending events within the application.

Your explanation is very helpful.

Thanks again.

-- 
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] Google map working on one mobile and not on another

2011-08-31 Thread TreKing
On Wed, Aug 31, 2011 at 11:43 AM, Bipin Sutariya
wrote:

> Can any one point it our what probebly issue can be?


You either installed different version of the app OR one has internet
connection and the other doesn't.

-
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] How to make horizontalScrollView to start from right side....

2011-08-31 Thread TreKing
On Wed, Aug 31, 2011 at 1:41 AM, Daniel Szasz  wrote:

> How can I align them to the right side (make it RTL)...
>

Check the properties in Eclipse - somewhere there should be an alignment
property.

-
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] Re: App Widget fails to be added, "thanks" to customized platform

2011-08-31 Thread Dianne Hackborn
On Tue, Aug 30, 2011 at 10:17 PM, eagle  wrote:

> But the problem is that,  even I didn't use these private functions,
> it didn't work.
>

The article you linked is purely and solely about using internal functions.
 If you are not using it and still having your problem, why did you mention
it?

Also it is going to help a lot if you post more about what your actual
problem is.  What is the stack crawl of the crash?  What are you trying to
do, and what is the undesired behavior you are getting?

-- 
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] Re: i have problem about listview adding can any one help me?

2011-08-31 Thread TreKing
On Wed, Aug 31, 2011 at 5:03 AM, Tawisak Ruksuwan <
tawisak.ruksu...@gmail.com> wrote:

> this page can run but i want call public class MyCustomAdapter
> extends BaseAdapter for  show data from layout item
> How can i do?
>

Your question makes little sense.

-
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

[android-developers] javascript call from intent browser

2011-08-31 Thread ag
Need a help on Android .Hope you can help us on this .

>From our application we are opening the browser using intent.

Here is the code


Uri uri = Uri

.parse(“http://
www.google.com”);

Intent internetIntent
= new Intent(Intent.ACTION_VIEW, uri);
 
internetIntent.setComponent(new ComponentName(
 
"com.android.browser",
 
"com.android.browser.BrowserActivity"));

 
internetIntent.setFlags(Intent.FLAG_ACTIVITY_BROUGHT_TO_FRONT);

 
startActivity(internetIntent);


We are setting the flag  FLAG_ACTIVITY_BROUGHT_TO_FRONT in the Intent
so that next time if we open the browser from our application then it
should bring the same tab in front instead of creating another
instance as the application id is the same and it is working fine

Issue is we need to call the JavaScript function defined in the
webpage .How can we call the javascript function using the intent
browser
>From webview you can do that but we are not able to use the webview as
it doesn’t fully support the html 5

Thanks
-ag


-- 
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 ImageView Bring to front on touch event of ImageView?

2011-08-31 Thread TreKing
On Wed, Aug 31, 2011 at 2:03 AM, Dipak Keshariya
wrote:

>  I have two Image View in two different layout,
> the one Image View is on Another Image View and I am using Relative
> Layout & the Both Image View size is Wrap Content But the Problem is
> If i am Click on ImageView2 that time the Imageview2 is displayed on
> the Imageview1 and If i am Click on ImageView1 that time the
> Imageview1 is displayed on the Imageview2 I am Using Bring to Front
> Method but This is Not Working.Sorry for bad English
> Communication.Please Help Me.
>

That was a bit hard to follow - maybe if you post your layout someone can
determine your issue.

-
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

[android-developers] Google map working on one mobile and not on another

2011-08-31 Thread Bipin Sutariya
HI All,

I am developing one app which have google map to show.

My issue is it is showing fine on Samsung Galaxy mobile but map is not
showing on HTC mobile.

Can any one point it our what probebly issue can be?

On HTC mobile it is jut showing blank page with grid. While on Samsung
mobile it is showing as expected.

Regards,
Bipin

-- 
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: App Widget fails to be added, "thanks" to customized platform

2011-08-31 Thread TreKing
On Wed, Aug 31, 2011 at 12:17 AM, eagle  wrote:

> But the problem is that,  even I didn't use these private functions, it
> didn't work.
>

I think you need to clarify your issue, because originally you said: "But
when i switched to the standard platform, it worked
perfectly."

-
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] postDelayed vs. post

2011-08-31 Thread Dianne Hackborn
On Wed, Aug 31, 2011 at 9:16 AM, Dmitry Golubovsky wrote:

> Q1: Is post(action) equivalent to postDelayed(action, 0)?
>

Yes.


> Q2: If a view implements a never stopping cycle like this, depending
> on two time parameters, N and T:
>
>public void timerEvent() {
>final class Timer implements Runnable {
>public void run() {
>timerEvent();
>}
>}
>native_code(); // guaranteed to run no
> longer than N msecs
>postDelayed(new Timer(), T);
>}
>
> what combinations of N and T ranges (including T = 0) are acceptable
> to make sure the view remains responsive to touch and other user-
> generated events, and "force close/wait" dialog does not appear?
>

It will remain responsive because older messages are processes before newer
messages, so you can't starve other messages from the queue by re-posting a
message when you handle it, even with no delay.

More important is balancing CPU use with what you are trying to do.

At 60fps one frame is 20ms, so it generally isn't useful to have a delay
smaller than that.  At the same time, if this is going on the entire time
the user is in your app, if using a delay of 20ms means you are keeping the
CPU running at near 100%, are going to much more quickly drain the battery
(and the user will see this in the battery use report).

-- 
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] Re: help with spinners from preferences

2011-08-31 Thread erik wagner
I apologize that the code appeared to be/was unformatted, it looked
fine on my end.

Thanks for the tip.  That is exactly what I was trying to hodgepodge
together.  Much appreciated.

Erik Wagner

On Aug 31, 10:59 am, TreKing  wrote:
> On Tue, Aug 30, 2011 at 7:50 PM, erik wagner wrote:
>
> > I have a preference screen where a edit text brings up a spinner,
> > the result from the spinner needs to get to the edit text on the preference
> > screen and the value from the edit text needs to then get back to the main
> > activity.
>
> I didn't look over your giant blob of foreign, unformatted code, but you
> should not neither either a spinner or edit text in a preference actiivty,
> unless you have your terms mixed up.
>
> All you should really need is a list 
> preference.http://developer.android.com/reference/android/preference/ListPrefere...
>
> ---­--
> 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


[android-developers] Re: Develop for Google Plus

2011-08-31 Thread TP
Agree.  Love to see Google+ API download option from SDK addon too.I am 
sure it is in the plan and just take time, to develop, test, etc.

I certainly don't mind seeing the Facebook, twitter as part of SDK addon 
options also. 
Not sure if it is limit to "partner" only or open to competitors. 

-Tony




-- 
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] postDelayed vs. post

2011-08-31 Thread Dmitry Golubovsky
Hi,

Q1: Is post(action) equivalent to postDelayed(action, 0)?

Q2: If a view implements a never stopping cycle like this, depending
on two time parameters, N and T:

public void timerEvent() {
final class Timer implements Runnable {
public void run() {
timerEvent();
}
}
native_code(); // guaranteed to run no
longer than N msecs
postDelayed(new Timer(), T);
}

what combinations of N and T ranges (including T = 0) are acceptable
to make sure the view remains responsive to touch and other user-
generated events, and "force close/wait" dialog does not appear?

I currently set N to 200msec max. Any lower bound on T?

In other words, if T = 0 and a touch event arrived while in native
code, will it be processed by the view at all, or is it necessary to
have T > 0 to guarantee that touch event will be processed?

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] APK signing and certificate for production device

2011-08-31 Thread Pratik Prajapati
Dear All,

For production of the device, android APKs needs to be signed. I have
created keystore as explained in
http://developer.android.com/guide/publishing/app-signing.html and signed my
APKs with that keystore.

I am doing it for eclair.

I need to know following things.

(1) Do I need to sign the andoird framework build as well, apart from APKs
that I'll provide in my production device? the older guidelines say it.
http://www.kandroid.org/online-pdk/guide/release_keys.html

(2) Is there any difference between APK signing and APK certificate?

(3) Any thing else I need to do for signing and certificate?

Thanks in advance.

Regards,
Pratik

-- 
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] Http Connection

2011-08-31 Thread TreKing
On Mon, Aug 29, 2011 at 11:35 PM, amit das wrote:

> a.HttpURLConnection ( package java.net)
> b.HttpClient ( package org.apache)
>
> Please suggest me which option i take and why.
>

http://tinyurl.com/3dd75se

-
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] MapView OverlayItem

2011-08-31 Thread TreKing
On Wed, Aug 31, 2011 at 12:56 AM, Stefan S  wrote:

> So han can I listen to the onTap Event in the MapActivity-Class?


Create your own callback.

-
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] help with spinners from preferences

2011-08-31 Thread TreKing
On Tue, Aug 30, 2011 at 7:50 PM, erik wagner wrote:

> I have a preference screen where a edit text brings up a spinner,
> the result from the spinner needs to get to the edit text on the preference
> screen and the value from the edit text needs to then get back to the main
> activity.
>

I didn't look over your giant blob of foreign, unformatted code, but you
should not neither either a spinner or edit text in a preference actiivty,
unless you have your terms mixed up.

All you should really need is a list preference.
http://developer.android.com/reference/android/preference/ListPreference.html

-
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

[android-developers] Emulator Bootloop

2011-08-31 Thread Roger Heim
Every once in a while an emulator image would hang while booting and
simply repeat the following in the logcat:
08-31 11:47:51.839: DEBUG/AndroidRuntime(1134): >>
AndroidRuntime START <<
08-31 11:47:51.850: DEBUG/AndroidRuntime(1134): CheckJNI is ON
08-31 11:47:51.960: DEBUG/AndroidRuntime(1134): --- registering native
functions ---
08-31 11:47:52.050: ERROR/JNIHelp(1134): Native registration unable to
find class 'android/util/FloatMath'
08-31 11:47:52.050: ERROR/AndroidRuntime(1134): Unable to register all
android natives
08-31 11:47:52.070: INFO/ServiceManager(28): service
'media.audio_flinger' died
08-31 11:47:52.070: INFO/ServiceManager(28): service 'media.player'
died
08-31 11:47:52.070: INFO/ServiceManager(28): service 'media.camera'
died
08-31 11:47:52.070: INFO/ServiceManager(28): service
'media.audio_policy' died
08-31 11:47:52.509: INFO/(1135): ServiceManager: 0xacd0
08-31 11:47:52.509: DEBUG/AudioHardwareInterface(1135):
setMode(NORMAL)
08-31 11:47:52.509: INFO/CameraService(1135): CameraService started:
pid=1135
08-31 11:47:52.519: INFO/AudioFlinger(1135): AudioFlinger's thread
0xb3f0 ready to run


The class mentioned by 'Native registration unable to find class '...'
is always different but always seems to be a core part of Android.
When one avd goes bad like this, other avd's based on the same
platform version still work fine. Restarting the avd with wipe data
does no good. The only way to deal with it is to delete the avd and
recreate it.

Does anyone else see this? It's very annoying to have to stop and
recreate the avd.

Roger

-- 
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 open 3G data call settings dialog]

2011-08-31 Thread rich friedel


uh please unsubscribe me from this group

This is awesome check it out... 
 

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

As for your original question
Using the standard SDK you cannot directly control the enabling and 
disabling of WiFi.

I don't know what you are talking about with the 3G stuff.

-- 
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: Is there guide-line to use TCP port.

2011-08-31 Thread blake
IANA, the Internet Assigned Number Authority, owns port numbers.
There's a list here:

http://www.iana.org/assignments/service-names-port-numbers/service-names-port-numbers.xml

You can apply for a well known port if you need.  More likely, though,
you would just use something that isn't already assigned...

-blake
Programming Android, FTW!
 http://oreilly.com/catalog/0636920010364

On Aug 30, 9:24 pm, hans  wrote:
> Hi.
> I know some TCP Ports are already registered.(i.e. 8080)
> I need to develope a application using static port not variable port.
> What port of number would be appropriate ?
> Is there a rule in order to use port?

-- 
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 read data from external device using android USB Host Api ?

2011-08-31 Thread Sam
Hello ,

I've written an app to connect an USB Device and read data from
external usb device to my android USB Host 3.1 root tab device.
i used http://developer.android.com/guide/topics/usb/host.html android
USB Host Api. But every time read data value got
zero value in every byte from external device.

can anyone send me demo or proper documentation how to read data from
external device ?
any encoding require for reading data ?

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] Re: How to 'delete' allocated class by 'new'??

2011-08-31 Thread blake
I think what Damien is trying to tell you is that you are asking the
wrong question.  There is no way, in Java, to force the "deallocation"
of a specific object.  If you remove all references to it, it is, as
far as your program is concerned, gone.  Is there a reason that you
would care whether about whether it exists or not?

-blake
Programming Android, FTW!
 http://oreilly.com/catalog/0636920010364


On Aug 31, 2:40 am, Build account  wrote:
> Hi,
>
> Thank you very much to let me know clearly.
> I tired to use your code snippet, but counldn't get sure.
>
> Another question here,
> If I use below code
> 
> String a = new String("test");
> String b = a;
>
> b = null;
>
> 
> In this case,
> the variable 'a' still allocated? Am I right? As long as I keep
> original variable?
>
> On Aug 31, 1:51 pm, Damien Cooke  wrote:
>
>
>
>
>
>
>
> > Hi Build Account,
>
> > Java, the language that Android is programmed in, is garbage collected.  So 
> > all you need to do is let the run time know you are finished with the 
> > object you created.
>
> > for example:
>
> >         //create the object
> >         String language = new String("Java");
>
> >         //use the Object
> >         Log.i("TEST", "Language used is: "+language);
>
> >         //destroy the object
> >         language = null;
>
> > regards
> > Damien
>
> > On 31/08/2011, at 1:14 AM, Build account wrote:
>
> > > Hello all.
>
> > > I'm looking for explictic method to erase object from memory space
> > > wich allocated by 'new' keyword.
>
> > > But the syntax "delete object;" telling me an error that "delete
> > > cannot be resolved".
>
> > > How can I do? I don't believe there is no such kind of 'delete'
> > > method..
>
> > > Please advice 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-Hide quoted text -
>
> > - Show quoted text -

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

2011-08-31 Thread rich friedel


Am I a naughty boy for wanting to use AbsoluteLayout? 

Not if you need it... do you *really* need it or will RelativeLayout work 
better?
Here is a good article discussing this topic...
http://developer.android.com/resources/articles/layout-tricks-efficiency.html

 Also, is there a way to make Eclipse stop crossing out my layout code? 

Don't use depreciated classes, methods, etc...

Also, understand that ALL iPhones have, more or less, a fixed screen 
size/density. With Android you might have one device where the screen 
density is small and one where it is huge. Imagine what you app will look 
like on not only a very low end device (MetroPcs Huwai Ascend) or on a 10+" 
tablet. Will it look the same, or as 'the same' as you can get?

-- 
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 installer strange issue

2011-08-31 Thread rich friedel
That is how it is designed to work.

Read up on the Activity Lifecycle 
http://developer.android.com/reference/android/app/Activity.html#ActivityLifecycle

-- 
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: UI fragment from one apk inside an activity of another APK on HC

2011-08-31 Thread blake
A fragment can't be referenced outside it's Activity/APK.  It's just
like any other class: it is local to its application.

The only way to publish behavior between applications is to use
Intents.

-blake



On Aug 30, 11:12 pm, vellanki  wrote:
> Hi
> This is regarding usage of a UI fragment from one apk inside an
> activity of another APK on HC.
>
> We have 2 different APK.
>
> APk1
> -       Activity 1
> o       Fragment 1
>
> APK2
> -       Activity1
> o       Fragment 2
>
> What we want to achieve?
>
> APk1
> -       Activity 1
> o       Fragment 2    // basically launching the Fragment 2 in the activity
> 1 on APK 1
>
> Thanks
> Siva

-- 
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: Crash after adding buttons

2011-08-31 Thread Dubler
there was error in main.xml :) thx all

-- 
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-discuss] Re: Embedding a Project made form Adobe FLEX inside an android project in Eclipse.Is it possible?

2011-08-31 Thread rich friedel

>
> Oopss sooryits me Saurabh...my sis was using the same account..
>
lol
 

> Well you pasted teh gogole link..thanks any ways ..have tried it enough 
> ..but will surely look with your keywords.

Yeah try that first Adobe link. I read through it and it looked like what 
you needed.

-- 
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-discuss] Re: Embedding a Project made form Adobe FLEX inside an android project in Eclipse.Is it possible?

2011-08-31 Thread s.rawat
Oopss sooryits me Saurabh...my sis was using the same account..
Well you pasted teh gogole link..thanks any ways ..have tried it enough
..but will surely look with your keywords.
Rgds,
Saurabh

"..pain is temporary.quitting lasts forever.."



On Wed, Aug 31, 2011 at 8:07 PM, rich friedel wrote:

> Dude! Why is your alias 'Jessica'???
>
> http://www.google.com/search?q=android+development+adding+flex+to+apk
>
> --
> You received this message because you are subscribed to the Google Groups
> "Android Discuss" group.
> To view this discussion on the web visit
> https://groups.google.com/d/msg/android-discuss/-/BHGJUVPS0D8J.
> To post to this group, send email to android-disc...@googlegroups.com.
> To unsubscribe from this group, send email to
> android-discuss+unsubscr...@googlegroups.com.
> For more options, visit this group at
> http://groups.google.com/group/android-discuss?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: Embedding a Project made form Adobe FLEX inside an android project in Eclipse.Is it possible?

2011-08-31 Thread rich friedel
Dude! Why is your alias 'Jessica'???

http://www.google.com/search?q=android+development+adding+flex+to+apk

-- 
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] layout's views drawing

2011-08-31 Thread Stanley Orlenko aka Smith
hi
FrameLayout contains 2 views.
frameLayout.add(view1);
frameLayout.add(view2);

view2 extends GLSurfaceView. view2 is curling page (like a page in a
book), when user is curling page view2 view1 should appears under
view2 (like next page in a book). view2 - current page, view1 - next
page.
There is problem. Sometimes view1 appears on the screen before view2
on a very short period of time and then view2 appears, it looks like a
blink. Sometimes when user is curling view2 view1 has not yet been
drawn and appears after some period of time, it looks like delay.
If I understand correctly sometimes firstly android draws view1, and
sometimes firstly android draws view2. How can I solve this problem?
Layout should appears only when view2 has been drawn and view1 should
appears immediately after user starts curling view2

Also I have a suspicious that android starts drawing view1 only when
user starts curling view2 because of view1 appears on the screen. but
if view1 is complex view with a lot of custom elements it will take a
time to draw it, as result delay...
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] Re: [android-discuss] Re: How to:Hyperlink Inside the Dialogue Box Message

2011-08-31 Thread s.rawat
Thankx it worked , also i have to add this line -->

*text.setMovementMethod(LinkMovementMethod.getInstance());*

Rgds*,*
saurabh

"..pain is temporary.quitting lasts forever.."



On Wed, Aug 31, 2011 at 7:11 PM, Chris  wrote:

>
>
> On Wednesday, August 31, 2011 4:00:48 AM UTC-4, softy wrote:
>>
>> Hi,
>> How can I make a text clickable(hyperlinked) in the dialogue box.
>>
>
> Something like:
>
> StringBuilder msg = new StringBuilder();
> msg.append("http://www.google.com";);
> final SpannableString string = new SpannableString(msg);
> Linkify.addLinks(string, Linkify.WEB_URLS);
> myTextView.setText(string);
>
> --
> You received this message because you are subscribed to the Google Groups
> "Android Discuss" group.
> To view this discussion on the web visit
> https://groups.google.com/d/msg/android-discuss/-/C-imYVRHQrQJ.
> To post to this group, send email to android-disc...@googlegroups.com.
> To unsubscribe from this group, send email to
> android-discuss+unsubscr...@googlegroups.com.
> For more options, visit this group at
> http://groups.google.com/group/android-discuss?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: Please point a noob in the right direction.

2011-08-31 Thread rich friedel
btw I forgot to put the super call in the onStart() method... so it should 
look like this instead:

@Override

public void onStart() {

super.onStart();

Button toggleButton = (Button)findViewById( R.id.toggleButton );


toggleButton.setOnClickListener( new View.OnClickListener() {


public void onClick( View v ) {

// Do some click stuff here...

}

} );

}

 

-- 
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: Please point a noob in the right direction.

2011-08-31 Thread rich friedel
Hello, and I hope you are having fun learning! :)

I took your code and quickly cleaned it up for you. I didn't test it so I 
don't know if anything i've done helped. BUT you had a lot of stuff in there 
that I would be surprised if it even compiled. I wrote comments explaining 
my changes...

Hope it helps

private AudioManager mAudioManager;

private boolean  mPhoneIsSilent;


// Use something else besides a reserved word for naming your fields, 
methods, classes, etc...

// Also you don't need this boolean. You can simply use 'false' or 
'true'

// private boolean False;


/** Called when the activity is first created. */

@Override

public void onCreate( Bundle savedInstanceState ) {

super.onCreate( savedInstanceState );

setContentView( R.layout.main );


mAudioManager = (AudioManager)getSystemService( AUDIO_SERVICE );

checkIfPhoneIsSilent();


// You can wrap your listener with a method however, I find it is 
better to init my

// listeners in the onStart method. See the Activity lifecycle

// Example below in the onStart() method...

// setButtonClickListner();


Log.d( "SilentModeApp", "This is a test" );

}


@Override

public void onStart() {

Button toggleButton = (Button)findViewById( R.id.toggleButton );


toggleButton.setOnClickListener( new View.OnClickListener() {


public void onClick( View v ) {

// Do some click stuff here...

}

} );

}


// I have no idea why this is here??? You perform the check in your 
checkIfPhoneIsSilent()

// {if (mPhoneIsSilent)

// {

// mAudioManager

// .setRingerMode(AudioManager.RINGER_MODE_NORMAL);

//

// mPhoneIsSilent = False;

// }

// else

// {

// mAudioManager

// .setRingerMode(AudioManager.RINGER_MODE_SILENT);

// boolean True = false;

// mPhoneIsSilent = True;

// }


/**

 * Toggles the UI images from silent to normal and vice versa.

 */

void toggleUi() {

ImageView imageView = (ImageView)findViewById( R.id.phone_icon );

Drawable newPhoneImage;


if( mPhoneIsSilent ) {

newPhoneImage = getResources().getDrawable( 
R.drawable.phone_silent );

} else {

newPhoneImage = getResources().getDrawable( R.drawable.phone_on 
);

}

imageView.setImageDrawable( newPhoneImage );

}


/**

 * Checks to see if your phone is currently in silent mode

 * 

 */

private void checkIfPhoneIsSilent() {

int ringerMode = mAudioManager.getRingerMode();

if( ringerMode == AudioManager.RINGER_MODE_SILENT ) {

mPhoneIsSilent = true;

} else {

mPhoneIsSilent = false;

}

}


protected void onResume() {

super.onResume();

checkIfPhoneIsSilent();

toggleUi();

}

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

2011-08-31 Thread Chi Kit Leung
Yes, that is a good article.
Thanks!
I think that is worth to read!

On Wed, Aug 31, 2011 at 1:27 AM, iñaki  wrote:

> Hi Suresh, this article is very good:
>
> http://android.cyrilmottier.com/?p=454
> Enjoy it
>
>
> On 30 August 2011 17:22, suresh achari  wrote:
>
>> thank you dude for your replay
>>
>> i need help on listview design i want to display list of customer details
>>
>> please give style code for listview
>>
>>
>> On Tue, Aug 30, 2011 at 8:19 PM, Appaholics wrote:
>>
>>> There is no best design. You want help, be accurate. You want code from
>>> someone else, pay them. A lot.
>>>
>>> On Tue, Aug 30, 2011 at 8:15 PM, suresh wrote:
>>>
 hi guys

 please send code for android best design. am a android developer and i
 designed one app but my manager compring design with iphone . so
 please give me best design so i can design better than iphone .
 please.

 --
 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
>>>
>>>
>>>
>>>
>>> --
>>> --
>>> Raghav Sood
>>> CEO/Founder/Owner/Dictator/Tyrant at Appaholics (Basically all titles
>>> required to have complete control)
>>> http://www.raghavsood.com/
>>> https://market.android.com/developer?pub=Appaholics
>>> http://www.appaholics.in/
>>>
>>>  --
>>> 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
>>
>>
>>
>>
>> --
>> Suresh.K
>>
>> --
>> 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
>



-- 
Regards,
Michael Leung
http://www.itblogs.info
http://www.michaelleung.info

-- 
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 code for capturing continious images

2011-08-31 Thread Chi Kit Leung
Using a while loop, then using
takePicture(Camera.ShutterCallback
 shutter, 
Camera.PictureCallback
 raw, 
Camera.PictureCallback
 jpeg) in camera object

It may help.
I have not tried that at all, I did the research on API doc, that may help.
On Wed, Aug 31, 2011 at 9:40 PM, Appaholics wrote:

> What have you tried so far? Nobody is going to give you free code.
>
>
> On Wed, Aug 31, 2011 at 3:43 PM, chadnan gupta 
> wrote:
>
>> Hi..
>>
>> I need some android code which can capture continuous images.
>> My app is like
>>
>> There is a start button , when ever it is is clicked , the camera starts
>> capturing images for at least 1 mins . after 1 mins the camera should stop .
>> and the images will be shown in the gallary
>>
>> --
>> 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
>
>
>
>
> --
> --
> Raghav Sood
> CEO/Founder/Owner/Dictator/Tyrant at Appaholics (Basically all titles
> required to have complete control)
> http://www.raghavsood.com/
> https://market.android.com/developer?pub=Appaholics
> http://www.appaholics.in/
>
>  --
> 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
http://www.michaelleung.info

-- 
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:Hyperlink Inside the Dialogue Box Message

2011-08-31 Thread Chris


On Wednesday, August 31, 2011 4:00:48 AM UTC-4, softy wrote:
>
> Hi, 
> How can I make a text clickable(hyperlinked) in the dialogue box.
>

Something like:

StringBuilder msg = new StringBuilder();
msg.append("http://www.google.com";);
final SpannableString string = new SpannableString(msg);
Linkify.addLinks(string, Linkify.WEB_URLS);
myTextView.setText(string); 

-- 
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] Fragment Pager Support sample

2011-08-31 Thread Mark Murphy
You need to add the Android Compatibility Library to your project.

On Wed, Aug 31, 2011 at 9:18 AM, Harald  wrote:
> I am trying to run the sample "Fragment Pager Support" but I get the
> error:
> "The import com.example.android.supportv4.R cannot be resolved"
> at this line:
> import com.example.android.supportv4.R;
>
> any ideas?
>
> --
> 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

Warescription: Three Android Books, Plus Updates, One Low Price!

-- 
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] Fragment Pager Support sample

2011-08-31 Thread Harald
I am trying to run the sample "Fragment Pager Support" but I get the
error:
"The import com.example.android.supportv4.R cannot be resolved"
at this line:
import com.example.android.supportv4.R;

any ideas?

-- 
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] NFC with the Nexus S and ACR122 Reader

2011-08-31 Thread Heiko Witte
Hi,

I have been working on a small project that involved using a Nexus S and 
ACR122 for P2P NFC communication. I wrote a small blog post about how to get 
everything running:

http://hwit.bitstacks.com/2011/08/31/nfc-with-the-nexus-s-and-acr122-reader

Please leave a comment if you have corrections or suggestions.

Regards
Heiko

-- 
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: Can't get same log as other testers.

2011-08-31 Thread Mark Murphy
On Wed, Aug 31, 2011 at 8:24 AM, cellurl  wrote:
> I mean, is there any more logging info available other than Eclipse/
> Logcat?

They gave you LogCat output.

> Is there a way to get more verbose logging?

They appear to have only given you warnings and errors. There are
other logging levels that they did not supply you.

> Perhaps Amazon has
> their own test/plugin/whoknows??

They appear to have broken firmware, considering that
com.android.internal.app.ResolverActivity is part of the operating
system and therefore should not need to be registered in the manifest:

http://www.google.com/codesearch#cZwlSNS7aEw/frameworks/base/core/java/com/android/internal/app/ResolverActivity.java

If they are going to hand you crash logs with no means of reproducing
whatever they created, that's not going to be especially useful.

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

Warescription: Three Android Books, Plus Updates, One Low Price!

-- 
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: Can't get same log as other testers.

2011-08-31 Thread cellurl
I mean, is there any more logging info available other than Eclipse/
Logcat? Is there a way to get more verbose logging? Perhaps Amazon has
their own test/plugin/whoknows??

Any guidance appreciated.
-cellurl


-- 
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 open 3G data call settings dialog]

2011-08-31 Thread Munkhbayar G
uh please unsubscribe me from this group

On Sun, Aug 28, 2011 at 7:54 PM, GMR  wrote:

> Hello buddies.
>
> I am currently developing a app which requires either the WiFi
> connectivity or 3G connectivity .
>
> When the device has no active connectivity, the users would be
> prompted a dialog with 2 buttons.
> One is for enabling WiFi connectivity. Another is for 3G connectivity.
>
> When the WiFi button is clicked. I could initiate the WiFi
> connectivity activity like below:
>
>  Intent intent = new
> Intent(android.provider.Settings.ACTION_NETWORK_OPERATOR_SETTINGS);
>  context.startActivity(intent);
>
> But I couldn't initiate the dialogs "3G data call settings dialog"
> when the 3G button is clicked.
>
> Is there any way to do that like above for WiFi?
>
> I've seen some app doing both like I say, So I hope to do so
>
> Best regards
>
> --
> 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] Live Video Streaming

2011-08-31 Thread mohana priya
I am new to android.I need to know how to code for rtmp client in
android for video live streaming.Any one tell me the idea how to 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


Re: [android-developers] ListView Data disappears

2011-08-31 Thread Appaholics
Try adding breakpoints and log messages to find out at which line or method
your listview is cleared.

Thanks

On Wed, Aug 31, 2011 at 3:28 PM, RobinDroid  wrote:

> Dear All,
>
> I have a listview  with checkbox.
> I have a menu which makes the list hide/unhide the checkbox.
> When i hit my menu 3 to 4 times with hide and unhide the checkbox, the
> data in listview disappears?
> Why is this happening?
>
> --
> 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




-- 
--
Raghav Sood
CEO/Founder/Owner/Dictator/Tyrant at Appaholics (Basically all titles
required to have complete control)
http://www.raghavsood.com/
https://market.android.com/developer?pub=Appaholics
http://www.appaholics.in/

-- 
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 code for capturing continious images

2011-08-31 Thread Appaholics
What have you tried so far? Nobody is going to give you free code.

On Wed, Aug 31, 2011 at 3:43 PM, chadnan gupta wrote:

> Hi..
>
> I need some android code which can capture continuous images.
> My app is like
>
> There is a start button , when ever it is is clicked , the camera starts
> capturing images for at least 1 mins . after 1 mins the camera should stop .
> and the images will be shown in the gallary
>
> --
> 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




-- 
--
Raghav Sood
CEO/Founder/Owner/Dictator/Tyrant at Appaholics (Basically all titles
required to have complete control)
http://www.raghavsood.com/
https://market.android.com/developer?pub=Appaholics
http://www.appaholics.in/

-- 
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 change form Popup-Edit to View??

2011-08-31 Thread Hadas
Bc"d
Hi,
How I can to change this popup window Example to View pop up  Without
TextView?

final FrameLayout fl = new FrameLayout(this);
final EditText input = new EditText(this);

AlertDialog.Builder builder = new 
AlertDialog.Builder(this);
builder.setMessage("Pleace press on START TEST with this
parameters");

//("Pressure: " + testParams[1] + "  " + "Touch Object: 
" +
testParams[4]);
input.setGravity(Gravity.CENTER);

fl.addView(input, new
FrameLayout.LayoutParams(FrameLayout.LayoutParams.FILL_PARENT,
FrameLayout.LayoutParams.WRAP_CONTENT));

input.setText("Parameters");
new AlertDialog.Builder(this)
.setView(fl)
.setTitle("Please press on test with this 
parameters")
.setPositiveButton("OK", new 
DialogInterface.OnClickListener(){
@Override
public void onClick(DialogInterface d, 
int which) {
d.dismiss();

Toast.makeText(AutomaticTestActivity.this, "Value: " +
input.getText().toString(), Toast.LENGTH_LONG).show();
}
})
.setNegativeButton("Cancel", new 
DialogInterface.OnClickListener()
{
@Override
public void onClick(DialogInterface d, 
int which) {
d.dismiss();
}
}).create().show();

Thanks
Hadas Mobile

-- 
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: Implementing onShowCustomView on Android 3.1 throws in HTML5VideoFullScreen

2011-08-31 Thread novemberox
I also found, that enabling hardware acceleration fix issue with
playing embedded video. Full screen still doesn't work.

On 29 Sie, 21:34, novemberox  wrote:
> A tip would be useful :)
>
> I tried to find Google browser sources in Android 3.1, but I'm not
> quite sure if sources 
> here:http://android.git.kernel.org/?p=platform/packages/apps/Browser.git;a...
> are the sources used in 3.1.
>
> On 27 Sie, 22:28, novemberox  wrote:
>
>
>
>
>
>
>
> > Hi,
>
> > I'm trying to play video in html on fullscreen. When I click on
> > fullscreen button in video method onShowCustomView is fired. Here is
> > my implementation:
>
> >         public void onShowCustomView(View view, CustomViewCallback callback)
> > {
> >                 super.onShowCustomView(view, callback);
> >                 if (view instanceof FrameLayout) {
> >                         customComponenet.addView(view, new 
> > FrameLayout.LayoutParams(
> >                                         ViewGroup.LayoutParams.FILL_PARENT,
> > ViewGroup.LayoutParams.FILL_PARENT,
> >                                         Gravity.CENTER));
> >                         customComponenet.setVisibility(View.VISIBLE);
> >                 }
> >         }
> > Where customComponenet is FrameLayout placed on top of my current
> > layout. Wideo is playing good, it's visibile and everything seams to
> > be ok but it throws:
> > 08-27 22:16:07.520: ERROR/AndroidRuntime(7235): FATAL EXCEPTION: main
> > 08-27 22:16:07.520: ERROR/AndroidRuntime(7235):
> > java.lang.NullPointerException
> > 08-27 22:16:07.520: ERROR/AndroidRuntime(7235):     at
> > android.webkit.HTML5VideoFullScreen.switchProgressView(HTML5VideoFullScreen 
> > .java:
> > 320)
> > 08-27 22:16:07.520: ERROR/AndroidRuntime(7235):     at
> > android.webkit.HTML5VideoView.setPlayerBuffering(HTML5VideoView.java:
> > 319)
> > 08-27 22:16:07.520: ERROR/AndroidRuntime(7235):     at
> > android.webkit.HTML5VideoView.start(HTML5VideoView.java:85)
> > 08-27 22:16:07.520: ERROR/AndroidRuntime(7235):     at
> > android.webkit.HTML5VideoViewProxy
> > $VideoPlayer.onPrepared(HTML5VideoViewProxy.java:257)
> > 08-27 22:16:07.520: ERROR/AndroidRuntime(7235):     at
> > android.webkit.HTML5VideoViewProxy.onPrepared(HTML5VideoViewProxy.java:
> > 278)
> > 08-27 22:16:07.520: ERROR/AndroidRuntime(7235):     at
> > android.webkit.HTML5VideoView.onPrepared(HTML5VideoView.java:265)
> > 08-27 22:16:07.520: ERROR/AndroidRuntime(7235):     at
> > android.webkit.HTML5VideoFullScreen.onPrepared(HTML5VideoFullScreen.java:
> > 164)
> > 08-27 22:16:07.520: ERROR/AndroidRuntime(7235):     at
> > android.media.MediaPlayer$EventHandler.handleMessage(MediaPlayer.java:
> > 1456)
> > 08-27 22:16:07.520: ERROR/AndroidRuntime(7235):     at
> > android.os.Handler.dispatchMessage(Handler.java:99)
> > 08-27 22:16:07.520: ERROR/AndroidRuntime(7235):     at
> > android.os.Looper.loop(Looper.java:132)
> > 08-27 22:16:07.520: ERROR/AndroidRuntime(7235):     at
> > android.app.ActivityThread.main(ActivityThread.java:4028)
> > 08-27 22:16:07.520: ERROR/AndroidRuntime(7235):     at
> > java.lang.reflect.Method.invokeNative(Native Method)
> > 08-27 22:16:07.520: ERROR/AndroidRuntime(7235):     at
> > java.lang.reflect.Method.invoke(Method.java:491)
> > 08-27 22:16:07.520: ERROR/AndroidRuntime(7235):     at
> > com.android.internal.os.ZygoteInit
> > $MethodAndArgsCaller.run(ZygoteInit.java:844)
> > 08-27 22:16:07.520: ERROR/AndroidRuntime(7235):     at
> > com.android.internal.os.ZygoteInit.main(ZygoteInit.java:602)
> > 08-27 22:16:07.520: ERROR/AndroidRuntime(7235):     at
> > dalvik.system.NativeStart.main(Native Method)
>
> > What am I doing wrong?
>
> > My WebView settings:
> >         webView.getSettings().setJavaScriptEnabled(true);
> >         webView.getSettings().setPluginState(PluginState.ON);
> >         webView.getSettings().setDomStorageEnabled(true);
> >         webView.getSettings().setDatabasePath("/data/data/" +
> > App.class.getPackage().getName() + "/databases");
> >         webView.getSettings().setSupportZoom(false);
>
> > I'm testing on Galaxy Tab 10.1, on default browser this is working
> > just fine. I can switch to fullscreen. Moreover in my app when I play
> > video embeded I can hear only sound and see status bar below area
> > where video should be, while on browser I can see video both embeded
> > in WebView and on fullscreen.

-- 
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] Update UI from Service

2011-08-31 Thread Chirag Raval
Thanks Mark Murphy 

On Wed, Aug 31, 2011 at 3:05 PM, Mark Murphy wrote:

> On Wed, Aug 31, 2011 at 5:05 AM, Chirag Raval
>  wrote:
> > Can any one help me to update UI from Service ?
> >
> > Here in my application i created one service, from my service i want
> > to update a textview which is in my Main Activity ?
> >
> > How can i change that textview's value from my service ?
>
> You send a message from the service to the activity, and the activity
> updates the TextView. Whether you do this via binding and the listener
> pattern, or ordered broadcasts
> (
> http://commonsware.com/blog/2010/08/11/activity-notification-ordered-broadcast.html
> ),
> or a Messenger object passed as an Intent extra, or a PendingIntent
> from createPendingResult(), or something else, is up to you and would
> depend a bit on the service in question.
>
> --
> Mark Murphy (a Commons Guy)
> http://commonsware.com | http://github.com/commonsguy
> http://commonsware.com/blog | http://twitter.com/commonsguy
>
> Warescription: Three Android Books, Plus Updates, One Low Price!
>
> --
> 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 code for capturing continious images

2011-08-31 Thread chadnan gupta
Hi..

I need some android code which can capture continuous images.
My app is like

There is a start button , when ever it is is clicked , the camera starts
capturing images for at least 1 mins . after 1 mins the camera should stop .
and the images will be shown in the gallary

-- 
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 UI components/widgets library

2011-08-31 Thread DroidUX DevTeam
Introducing DroidUX, the first Android UI components/widgets library.

DroidUX is the first professional UI/UX component library for
Android.  DroidUX helps you build high quality and beautiful user
interface fast and easy.  Building UI conforming to the Android design
pattern is just a snap. In few lines of code you will have your
application up and running with the Action Bar, Dashboard, and Quick
Actions widgets.  To deliver more exciting and high end user
experience, you can use the GalleryFlow, Wheel, Editor, and other
widgets that are designed and implemented with high quality codes for
beauty and performance.

Using DroidUX widgets is no different than the stock widgets.  You can
use them via xml layout or use it programmatically with your codes.
The difference is that using DroidUX component library, your complex
UI becomes so simple to implement.  You don't need to reinvent the
wheel.  We do the dirty things, you just plug them into your apps, and
boost the usability and performance of your apps, making your apps
stand above the fray.

Take your app to the next level.  Deliver high end mobile experience
using the DroidUX(tm) UI/UX component library.

To see the DroidUX widgets in action, download the DroidUX API Demo
app in Android Market at 
https://market.android.com/details?id=com.droidux.components.demo

To download the FREE trial packs, please visit our website at
http://www.droidux.com.

Happy developing !!!

DroidUX DevTeam

-- 
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: i have problem about listview adding can any one help me?

2011-08-31 Thread Tawisak Ruksuwan
this page can run but i want call public class MyCustomAdapter extends
BaseAdapter

for  show data from layout item
How can i do?

2011/8/31, RobinDroid :
> Where is the problem?
>
> On Aug 31, 2:09 pm, Jhew SAN  wrote:
>> package com.cityweather;
>>
>> import java.io.FileInputStream;
>> import java.io.FileOutputStream;
>> import java.io.IOException;
>> import java.io.InputStreamReader;
>> import java.io.OutputStreamWriter;
>> import java.net.MalformedURLException;
>> import java.net.URL;
>> import java.util.ArrayList;
>>
>> import javax.xml.parsers.ParserConfigurationException;
>> import javax.xml.parsers.SAXParser;
>> import javax.xml.parsers.SAXParserFactory;
>>
>> import org.xml.sax.InputSource;
>> import org.xml.sax.SAXException;
>> import org.xml.sax.XMLReader;
>>
>> import com.cityweather.OZWFGoogleWeatherAPIData;
>> import com.cityweather.OZWFXMLHandler;
>>
>> import android.app.Activity;
>> import android.app.AlertDialog;
>> import android.app.ListActivity;
>> import android.content.Context;
>> import android.content.DialogInterface;
>> import android.content.Intent;
>> import android.os.Bundle;
>> import android.util.Log;
>> import android.view.LayoutInflater;
>> import android.view.View;
>> import android.view.View.OnClickListener;
>> import android.view.ViewGroup;
>> import android.widget.ArrayAdapter;
>> import android.widget.AutoCompleteTextView;
>> import android.widget.BaseAdapter;
>> import android.widget.Button;
>> import android.widget.EditText;
>> import android.widget.ListView;
>> import android.widget.TextView;
>> import android.widget.Toast;
>>
>> public class MyLocationActivity extends ListActivity implements
>> OnClickListener {
>>
>> TextView selection;
>> EditText et;
>> AutoCompleteTextView at;
>> String data[]={};
>>
>> public static int state = 0;
>> public static String city = "";
>> static final String[] COUNTRIES = new String[] {
>>
>> "Harare","Lusaka","Kampala","Tunis","Mbabane","Paramaribo","Khartoum","Pret
>> oria","Mogadishu","Freetown","Victoria","Dakar","Kigali","Abuja","Niamey","
>> Wimdhoek","Maputo","Rabat","Port
>> Louis","Bamako","Lilongwe","Antananarivo","Tripoli","Monrovia","Maseru","Ta
>> rawa","Nairobi","Bissau","Conakry","Accra","Banjul","Libreville","Asmara","
>> Malabo","Cairo","Djibouti","Brazzaville","Moroni","Bangul","Praia","Yaounde
>> ","Bujumbura","Ouagadougou","Garborone","Porto-Novo","Algiers","Hanoi","Tas
>> hkent","Ashkhabad","Bangkok","Dushanbe","Taipei","Colombo","Singapore","Man
>> ila","Islamabad","Kathmandu","Yangon","Ulaanbaatar","Male","Kuala
>> Lumpur","Vientiane","Bishkek","Seoul","Pyongyang","Astana","Tokyo","Jakarta
>> ","New
>> Delhi","Beijing","Phnom Penh","Manama","Baku","Yerevan","Kabul","Kamphaeng
>> Phet","Chiang Rai","Chiang Mai","Tak","Nan"
>> ,"Phichit","Phitsanulok","Phetchabun","Phrae","Mae Hong
>> Son","Lampang","Sukhothai","Uttaradit"
>> ,"Phayao","Chanthaburi","Chon Buri","Chai Nat","Trat","Nakhon
>> Nayok","Nakhon
>> Pathom","Nonthaburi"
>> ,"Pathum Thani","Prachuap Khiri Khan","Prachin
>> Buri","Phetchaburi","Rayong","Ratchaburi","Lop Buri"
>> ,"Samut Prakan","Samut Songkhram","Samut Sakhon","Saraburi","Sing
>> Buri","Suphan Buri"
>> ,"Ang Thong","Sa Kaeo","Kalasin","Chaiyaphum","Yasothon","Maha
>> Sarakham","Loei","Si Sa Ket"
>> ,"Nong Khai","Udon Thani","Ubon Ratchathani","Mukdahan","Amnat
>> Charoen","Nong Bua Lam Phu"
>> ,"Krabi","Trang","Nakhon Si
>> Thammarat","Narathiwat","Pattani","Phuket","Phatthalung"
>> ,"Yala","Songkhla","Satun","Surat Thani"
>> ,""};
>>
>> public void onCreate(Bundle icicle) {
>>
>> super.onCreate(icicle);
>> //WriteSettings(this, "Skopje");
>>
>> data = ReadSettings(this).trim().split(",");
>>
>> data[data.length-1]=data[data.length-1].trim();
>> //Log.v("datodeka", data[30].toString());
>> setContentView(R.layout.lview);
>> setListAdapter(new ArrayAdapter(this,
>> android.R.layout.simple_list_item_1, data));
>> selection = (TextView) findViewById(R.id.selection);
>> //selection.setText(ReadSettings(this));
>> // button
>> // Button del = (Button)findViewById(R.id.btDel);
>> // del.setOnClickListener(new View.OnClickListener() {
>> //
>> // @Override
>> // public void onClick(View v) {
>> // // TODO Auto-generated method stub
>> // Intent intent = new Intent(MyLocationActivity.this,PEdit.class);
>> // startActivity(intent);
>> // }
>> // });
>>
>> Button btnAdd = (Button) findViewById(R.id.btnAdd);
>> btnAdd.setOnClickListener(this);
>>
>> }
>>
>> public class MyCustomAdapter extends BaseAdapter
>> {
>> private ArrayList mData = new ArrayList();
>> private LayoutInflater mInflater;
>> public MyCustomAdapter(Activity context,String c)
>> {
>> mInflater =
>> (LayoutInflater)getSystemService(Context.LAYOUT_INFLATER_SERVICE);
>>
>> }
>>
>> public void addItem(final String item)
>> {
>> mData.add(item);
>> notifyDataSetChanged();}
>>
>> @Override
>> public int getCount() {
>> // TODO Auto-generated method stub
>> return mData.size();
>>
>> }
>>
>> @Override
>> public Object getItem(int positio

[android-developers] Re: i have problem about listview adding can any one help me?

2011-08-31 Thread RobinDroid
Where is the problem?

On Aug 31, 2:09 pm, Jhew SAN  wrote:
> package com.cityweather;
>
> import java.io.FileInputStream;
> import java.io.FileOutputStream;
> import java.io.IOException;
> import java.io.InputStreamReader;
> import java.io.OutputStreamWriter;
> import java.net.MalformedURLException;
> import java.net.URL;
> import java.util.ArrayList;
>
> import javax.xml.parsers.ParserConfigurationException;
> import javax.xml.parsers.SAXParser;
> import javax.xml.parsers.SAXParserFactory;
>
> import org.xml.sax.InputSource;
> import org.xml.sax.SAXException;
> import org.xml.sax.XMLReader;
>
> import com.cityweather.OZWFGoogleWeatherAPIData;
> import com.cityweather.OZWFXMLHandler;
>
> import android.app.Activity;
> import android.app.AlertDialog;
> import android.app.ListActivity;
> import android.content.Context;
> import android.content.DialogInterface;
> import android.content.Intent;
> import android.os.Bundle;
> import android.util.Log;
> import android.view.LayoutInflater;
> import android.view.View;
> import android.view.View.OnClickListener;
> import android.view.ViewGroup;
> import android.widget.ArrayAdapter;
> import android.widget.AutoCompleteTextView;
> import android.widget.BaseAdapter;
> import android.widget.Button;
> import android.widget.EditText;
> import android.widget.ListView;
> import android.widget.TextView;
> import android.widget.Toast;
>
> public class MyLocationActivity extends ListActivity implements
> OnClickListener {
>
> TextView selection;
> EditText et;
> AutoCompleteTextView at;
> String data[]={};
>
> public static int state = 0;
> public static String city = "";
> static final String[] COUNTRIES = new String[] {
>
> "Harare","Lusaka","Kampala","Tunis","Mbabane","Paramaribo","Khartoum","Pret 
> oria","Mogadishu","Freetown","Victoria","Dakar","Kigali","Abuja","Niamey"," 
> Wimdhoek","Maputo","Rabat","Port
> Louis","Bamako","Lilongwe","Antananarivo","Tripoli","Monrovia","Maseru","Ta 
> rawa","Nairobi","Bissau","Conakry","Accra","Banjul","Libreville","Asmara"," 
> Malabo","Cairo","Djibouti","Brazzaville","Moroni","Bangul","Praia","Yaounde 
> ","Bujumbura","Ouagadougou","Garborone","Porto-Novo","Algiers","Hanoi","Tas 
> hkent","Ashkhabad","Bangkok","Dushanbe","Taipei","Colombo","Singapore","Man 
> ila","Islamabad","Kathmandu","Yangon","Ulaanbaatar","Male","Kuala
> Lumpur","Vientiane","Bishkek","Seoul","Pyongyang","Astana","Tokyo","Jakarta 
> ","New
> Delhi","Beijing","Phnom Penh","Manama","Baku","Yerevan","Kabul","Kamphaeng
> Phet","Chiang Rai","Chiang Mai","Tak","Nan"
> ,"Phichit","Phitsanulok","Phetchabun","Phrae","Mae Hong
> Son","Lampang","Sukhothai","Uttaradit"
> ,"Phayao","Chanthaburi","Chon Buri","Chai Nat","Trat","Nakhon Nayok","Nakhon
> Pathom","Nonthaburi"
> ,"Pathum Thani","Prachuap Khiri Khan","Prachin
> Buri","Phetchaburi","Rayong","Ratchaburi","Lop Buri"
> ,"Samut Prakan","Samut Songkhram","Samut Sakhon","Saraburi","Sing
> Buri","Suphan Buri"
> ,"Ang Thong","Sa Kaeo","Kalasin","Chaiyaphum","Yasothon","Maha
> Sarakham","Loei","Si Sa Ket"
> ,"Nong Khai","Udon Thani","Ubon Ratchathani","Mukdahan","Amnat
> Charoen","Nong Bua Lam Phu"
> ,"Krabi","Trang","Nakhon Si
> Thammarat","Narathiwat","Pattani","Phuket","Phatthalung"
> ,"Yala","Songkhla","Satun","Surat Thani"
> ,""};
>
> public void onCreate(Bundle icicle) {
>
> super.onCreate(icicle);
> //WriteSettings(this, "Skopje");
>
> data = ReadSettings(this).trim().split(",");
>
> data[data.length-1]=data[data.length-1].trim();
> //Log.v("datodeka", data[30].toString());
> setContentView(R.layout.lview);
> setListAdapter(new ArrayAdapter(this,
> android.R.layout.simple_list_item_1, data));
> selection = (TextView) findViewById(R.id.selection);
> //selection.setText(ReadSettings(this));
> // button
> // Button del = (Button)findViewById(R.id.btDel);
> // del.setOnClickListener(new View.OnClickListener() {
> //
> // @Override
> // public void onClick(View v) {
> // // TODO Auto-generated method stub
> // Intent intent = new Intent(MyLocationActivity.this,PEdit.class);
> // startActivity(intent);
> // }
> // });
>
> Button btnAdd = (Button) findViewById(R.id.btnAdd);
> btnAdd.setOnClickListener(this);
>
> }
>
> public class MyCustomAdapter extends BaseAdapter
> {
> private ArrayList mData = new ArrayList();
> private LayoutInflater mInflater;
> public MyCustomAdapter(Activity context,String c)
> {
> mInflater =
> (LayoutInflater)getSystemService(Context.LAYOUT_INFLATER_SERVICE);
>
> }
>
> public void addItem(final String item)
> {
> mData.add(item);
> notifyDataSetChanged();}
>
> @Override
> public int getCount() {
> // TODO Auto-generated method stub
> return mData.size();
>
> }
>
> @Override
> public Object getItem(int position) {
> // TODO Auto-generated method stub
> return mData.get(position);
>
> }
>
> @Override
> public long getItemId(int position) {
> // TODO Auto-generated method stub
> return position;
>
> }
>
> @Override
> public View getView(int position, View convertView, ViewGroup parent) {
> // TODO Auto

[android-developers] ListView Data disappears

2011-08-31 Thread RobinDroid
Dear All,

I have a listview  with checkbox.
I have a menu which makes the list hide/unhide the checkbox.
When i hit my menu 3 to 4 times with hide and unhide the checkbox, the
data in listview disappears?
Why is this happening?

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


  1   2   >