[android-developers] Re: Failed to fetch URL https://dl-ssl.google.com/android/repository/repository.xml

2009-11-02 Thread cj
Ran into the same exact problem w/Ubuntu 9.10 on x86_64.  Here's what
I did to
fix/work-around it.

I changed the *cfg file as you had done, downloaded the android-sdk-
rev3_linux.tgz,
extracted it, changed the path in my .bashrc, went into it's tools
directory and ran
'android update sdk' instead of just 'android'.  It launched the GUI &
asked for
acceptance of the license & after accepting, it installed without a
problem.
Hope that helps.


//
On Oct 30, 1:13 pm, Hans  wrote:
> Adding sdkman.force.http=true to ~/.android/androidtool.cfg allowed me
> to retrieve the Sites, Packages, and Archives via the Android SDK and
> AVD Manager.
>
> However, when I select, for example, "SDK Platform Android 2.0, API 5,
> revision 1", and click "Install Selected" (button), nothing happens.
>
> I am running onUbuntuversion9.10x64 (released version).  The
> machine has 4GB RAM.  JDK 6-15-1, via the Synaptic Package Manager, is
> installed (along with the dependencies).
>
> On Oct 29, 1:24 pm, Xavier Ducrohet  wrote:
>
> > On Wed, Oct 28, 2009 at 9:23 PM, orange80  wrote:
>
> > > We already know about that... our problem is that the "force http"
> > > workaround DOES NOT work for us either.
>
> > which, frankly, is mind boggling.
> > Can you give me the exact output of the status window in the SDK
> > Manager when you try to update from the repository?
>
> > Also, can you tell me which JDK you are using, OS config, etc..
>
> > thanks!
> > Xav
>
> > --
> > Xavier Ducrohet
> > Android SDK Tech Lead
> > Google Inc.
>
> > Please do not send me questions directly. 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] how to remove an application?

2009-06-10 Thread CJ

suppose i have re-compiled the whole operation system and installed A
hardware (not g1), where am i supposed to be looking at if i want to
monitor/remove/block/disable all the applications on the device? any
system level api? any advice will be appreciated.
thx

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



[android-developers] Google Maps Mapview Memory Leak

2011-06-02 Thread CJ
http://code.google.com/p/android/issues/detail?id=2181

Does someone know any solution for the Googe Maps Mapview Memory Leak?

-- 
You received this message because you are subscribed to the Google
Groups "Android Developers" group.
To post to this group, send email to android-developers@googlegroups.com
To unsubscribe from this group, 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] LinearLayout button mistery

2012-07-18 Thread CJ
Hi, I have this layout I have been using across the code.
The display is good on my phone, tablet, emulators but I have 1 user that 
show me an alignment problem.
The strange thing was, the other dialog button has no alignment issues and 
the code are the same except text.

How it look for everyone else:
https://fbcdn-sphotos-a.akamaihd.net/hphotos-ak-ash3/560976_3068299686679_313198814_n.jpg
 

How it look for that 1 user and only this dialog
https://fbcdn-sphotos-a.akamaihd.net/hphotos-ak-ash4/309468_3068299926685_474928927_n.jpg
 

What is the issue?
The code:

http://schemas.android.com/apk/res/android";
android:id="@+id/dpwd"
android:layout_width="fill_parent"
android:layout_height="fill_parent"
android:orientation="vertical" >
















-- 
You received this message because you are subscribed to the Google
Groups "Android Developers" group.
To post to this group, send email to android-developers@googlegroups.com
To unsubscribe from this group, 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] LinearLayout button mistery

2012-07-18 Thread CJ
Hi, the strange thing was that the very same user can display a similar 
dialog with no problem. Code is the same except text wording, the OK and 
Cancel display with no alignment issue.

On Thursday, 19 July 2012 02:32:53 UTC+8, Kostya Vasilyev wrote:
>
> Your layout uses fixed width (100dp) for the buttons, which appears to not 
> be sufficient on the second screen ("Can/cel").
>
> The messed up vertical alignment might be a side effect of that.
>
> Consider using wrap_content or at least increasing the fixed widths.
>
> -- K
>
> 2012/7/18 CJ 
>
>> Hi, I have this layout I have been using across the code.
>> The display is good on my phone, tablet, emulators but I have 1 user that 
>> show me an alignment problem.
>> The strange thing was, the other dialog button has no alignment issues 
>> and the code are the same except text.
>>
>> How it look for everyone else:
>>
>> https://fbcdn-sphotos-a.akamaihd.net/hphotos-ak-ash3/560976_3068299686679_313198814_n.jpg
>>  
>>
>> How it look for that 1 user and only this dialog
>>
>> https://fbcdn-sphotos-a.akamaihd.net/hphotos-ak-ash4/309468_3068299926685_474928927_n.jpg
>>  
>>
>> What is the issue?
>> The code:
>> 
>> http://schemas.android.com/apk/res/android";
>> android:id="@+id/dpwd"
>> android:layout_width="fill_parent"
>> android:layout_height="fill_parent"
>> android:orientation="vertical" >
>>
>> > android:id="@+id/TextView_Pwd1"
>> android:layout_width="wrap_content"
>> android:layout_height="wrap_content"
>> android:text="@string/password1"
>> android:textStyle="bold" >
>> 
>>
>> > android:id="@+id/EditText_Pwd1"
>> android:layout_width="fill_parent"
>> android:layout_height="wrap_content"
>> android:inputType="textPassword"
>> android:maxLength="20"
>> android:maxLines="1" >
>> 
>>
>> > android:layout_width="fill_parent"
>> android:layout_height="fill_parent"
>> android:orientation="horizontal" >
>>
>> > android:id="@+id/Button_DPwd"
>> android:layout_width="100dp"
>> android:layout_height="wrap_content"
>> android:text="@string/ok" />
>>
>> > android:id="@+id/Button_DPwdCancel"
>> android:layout_width="100dp"
>> android:layout_height="wrap_content"
>> android:text="@string/cancel" />
>> 
>>
>> 
>>
>>  -- 
>> You received this message because you are subscribed to the Google
>> Groups "Android Developers" group.
>> To post to this group, send email to android-developers@googlegroups.com
>> To unsubscribe from this group, 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 setting invalid APN the only way to disable mobile network connection?

2012-07-31 Thread CJ
Hi,

I have been googling for a while able the best or right way to 
disable/enable mobile network.

I tried the following code which is all over Stackoverflow and is working 
fine for gingerbread and higher:

private void setMobileDataEnabled(Context context, boolean enabled)
throws Exception {
final ConnectivityManager conman = (ConnectivityManager) context
.getSystemService(Context.CONNECTIVITY_SERVICE);
final Class conmanClass = Class.forName(conman.getClass().getName());
final Field iConnectivityManagerField = conmanClass
.getDeclaredField("mService");
iConnectivityManagerField.setAccessible(true);
final Object iConnectivityManager = iConnectivityManagerField
.get(conman);
final Class iConnectivityManagerClass = Class
.forName(iConnectivityManager.getClass().getName());
final Method setMobileDataEnabledMethod = iConnectivityManagerClass
.getDeclaredMethod("setMobileDataEnabled", Boolean.TYPE);
setMobileDataEnabledMethod.setAccessible(true);

setMobileDataEnabledMethod.invoke(iConnectivityManager, enabled);
}

Somehow I didn't find a way to do the same thing for Android 2.2 and below. 
Many mentioned to change the APN name to something invalid like what app 
APNDroid did but is that the only way?

-- 
You received this message because you are subscribed to the Google
Groups "Android Developers" group.
To post to this group, send email to android-developers@googlegroups.com
To unsubscribe from this group, 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] Is setting invalid APN the only way to disable mobile network connection?

2012-07-31 Thread CJ
Hi, I am working on a app to automate some setting eg. to perform certain 
action such as disable mobile data when battery is low or night mode etc.
There are app in the market that able to disable/enable mobile data 
connection like SmartAction and a few more. I also dislike the alter APN 
method so I am looking for better alternatives.

On Tuesday, 31 July 2012 23:14:41 UTC+8, Robert Greenwalt wrote:
>
> Apps won't be able to alter the APN database after Honeycomb or perhaps 
> ICS.  The User can disable data from settings.  Why does an application 
> need to disable data?
>
>
> On Tue, Jul 31, 2012 at 8:03 AM, CJ wrote:
>
>> Hi,
>>
>> I have been googling for a while able the best or right way to 
>> disable/enable mobile network.
>>
>> I tried the following code which is all over Stackoverflow and is working 
>> fine for gingerbread and higher:
>>
>> private void setMobileDataEnabled(Context context, boolean enabled)
>> throws Exception {
>> final ConnectivityManager conman = (ConnectivityManager) context
>>  .getSystemService(Context.CONNECTIVITY_SERVICE);
>> final Class conmanClass = Class.forName(conman.getClass().getName());
>>  final Field iConnectivityManagerField = conmanClass
>> .getDeclaredField("mService");
>> iConnectivityManagerField.setAccessible(true);
>>  final Object iConnectivityManager = iConnectivityManagerField
>> .get(conman);
>> final Class iConnectivityManagerClass = Class
>>  .forName(iConnectivityManager.getClass().getName());
>> final Method setMobileDataEnabledMethod = iConnectivityManagerClass
>>  .getDeclaredMethod("setMobileDataEnabled", Boolean.TYPE);
>> setMobileDataEnabledMethod.setAccessible(true);
>>
>> setMobileDataEnabledMethod.invoke(iConnectivityManager, enabled);
>> }
>>
>> Somehow I didn't find a way to do the same thing for Android 2.2 and 
>> below. Many mentioned to change the APN name to something invalid like what 
>> app APNDroid did but is that the only way?
>>  
>> -- 
>> You received this message because you are subscribed to the Google
>> Groups "Android Developers" group.
>> To post to this group, send email to android-developers@googlegroups.com
>> To unsubscribe from this group, 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] Is setting invalid APN the only way to disable mobile network connection?

2012-07-31 Thread CJ
The permission needed is 
Android 2.3 and above can do that with the code I supply. I am asking a 
question how to do it for version below 2.3.

Many apps are doing it, the most popular one I mentioned was JuiceDefender:
http://maketecheasier.com/increase-phones-battery-life-with-juicedefender-android/2011/02/25
 

On Wednesday, 1 August 2012 00:28:33 UTC+8, Robert Greenwalt wrote:
>
> How to do the permission?  That's not your issue - the platform needs to 
> do it.
>
> How to turn data on/off?  It looks like you'll need a mix of methods. 
>  You're using undocumented methods from the past and present and they may 
> change in the future.  You can do different things dependent on the version 
> of the platform.
>
>
> On Tue, Jul 31, 2012 at 9:18 AM, wrote:
>
>> Yes, the next qns is how to do it...
>>
>> On Wed, Aug 1, 2012 at 12:14 AM, Robert Greenwalt 
>> wrote:
>>
>>> If the app is granted permission by the user it would be ok.  And apps 
>>> that do intelligent things in this area may be useful and welcome.  Without 
>>> permission limits though, yeah this could be a problem.
>>>  
>>>
>>> On Tue, Jul 31, 2012 at 9:04 AM, Nick Kralevich  wrote:
>>>
>>>>  
>>>> Hmm  From the platform's point of view, this sounds like a denial 
>>>> of service attack against other applications on the device. One 
>>>> application 
>>>> shouldn't be able to interfere with another application's network 
>>>> connectivity without the user being involved.
>>>>
>>>> -- Nick
>>>>
>>>>
>>>> On Tue, Jul 31, 2012 at 8:26 AM, CJ wrote:
>>>>
>>>>> Hi, I am working on a app to automate some setting eg. to perform 
>>>>> certain action such as disable mobile data when battery is low or night 
>>>>> mode etc.
>>>>> There are app in the market that able to disable/enable mobile data 
>>>>> connection like SmartAction and a few more. I also dislike the alter APN 
>>>>> method so I am looking for better alternatives.
>>>>>
>>>>> On Tuesday, 31 July 2012 23:14:41 UTC+8, Robert Greenwalt wrote:
>>>>>
>>>>>> Apps won't be able to alter the APN database after Honeycomb or 
>>>>>> perhaps ICS.  The User can disable data from settings.  Why does an 
>>>>>> application need to disable data?
>>>>>>
>>>>>>
>>>>>> On Tue, Jul 31, 2012 at 8:03 AM, CJ wrote:
>>>>>>
>>>>>> Hi,
>>>>>>>
>>>>>>> I have been googling for a while able the best or right way to 
>>>>>>> disable/enable mobile network.
>>>>>>>
>>>>>>> I tried the following code which is all over Stackoverflow and is 
>>>>>>> working fine for gingerbread and higher:
>>>>>>>
>>>>>>> private void setMobileDataEnabled(Context context, boolean enabled)
>>>>>>> throws Exception {
>>>>>>>  final ConnectivityManager conman = (ConnectivityManager) context
>>>>>>>  .getSystemService(Context.**CONNECTIVITY_SERVICE);
>>>>>>> final Class conmanClass = Class.forName(conman.getClass(**
>>>>>>> ).getName());
>>>>>>>  final Field iConnectivityManagerField = conmanClass
>>>>>>> .getDeclaredField("mService");
>>>>>>> iConnectivityManagerField.**setAccessible(true);
>>>>>>>  final Object iConnectivityManager = iConnectivityManagerField
>>>>>>> .get(conman);
>>>>>>> final Class iConnectivityManagerClass = Class
>>>>>>>  .forName(iConnectivityManager.**getClass().getName());
>>>>>>> final Method setMobileDataEnabledMethod = iConnectivityManagerClass
>>>>>>>  .getDeclaredMethod("**setMobileDataEnabled", Boolean.TYPE);
>>>>>>> setMobileDataEnabledMethod.**setAccessible(true);
>>>>>>>
>>>>>>> setMobileDataEnabledMethod.**invoke(iConnectivityManager, enabled);
>>>>>>> }
>>>>>>>
>>>>>>> Somehow I didn't find a way to do the same thing for Android 2.2 and 
>>>>>>> below. Many mentioned to change the APN name to something invalid like 
>>>>>>> what 
>>>>>>> app APNDroid did

Re: [android-developers] Is setting invalid APN the only way to disable mobile network connection?

2012-07-31 Thread CJ
Hi, I understand. There are many popular app that automate system task with 
big user base.
APNDroid, JuiceDefender, Motorola SmartAction etc so many. So likely there 
is no answer other than using what APNDroid is using and it is likely going 
to be future version proof.

On Wednesday, 1 August 2012 02:59:45 UTC+8, Kristopher Micinski wrote:
>
> This goes in the category of "apps modifying the system." 
>
> Your app shouldn't be able to modify the system.  While this sounds 
> funny, it's true.  Sure, you can write such apps and hack around 
> things below 2.3.3, but do you really expect your app will really be 
> used for that long, then? 
>
> kris 
>
> On Tue, Jul 31, 2012 at 12:38 PM, CJ wrote: 
> > The permission needed is  > android:name="android.permission.CHANGE_NETWORK_STATE"/> 
> > Android 2.3 and above can do that with the code I supply. I am asking a 
> > question how to do it for version below 2.3. 
> > 
> > Many apps are doing it, the most popular one I mentioned was 
> JuiceDefender: 
> > 
> http://maketecheasier.com/increase-phones-battery-life-with-juicedefender-android/2011/02/25
>  
> > 
> > On Wednesday, 1 August 2012 00:28:33 UTC+8, Robert Greenwalt wrote: 
> >> 
> >> How to do the permission?  That's not your issue - the platform needs 
> to 
> >> do it. 
> >> 
> >> How to turn data on/off?  It looks like you'll need a mix of methods. 
> >> You're using undocumented methods from the past and present and they 
> may 
> >> change in the future.  You can do different things dependent on the 
> version 
> >> of the platform. 
> >> 
> >> 
> >> On Tue, Jul 31, 2012 at 9:18 AM, wrote: 
> >>> 
> >>> Yes, the next qns is how to do it... 
> >>> 
> >>> On Wed, Aug 1, 2012 at 12:14 AM, Robert Greenwalt <
> rgreenw...@google.com> 
> >>> wrote: 
> >>>> 
> >>>> If the app is granted permission by the user it would be ok.  And 
> apps 
> >>>> that do intelligent things in this area may be useful and welcome. 
>  Without 
> >>>> permission limits though, yeah this could be a problem. 
> >>>> 
> >>>> 
> >>>> On Tue, Jul 31, 2012 at 9:04 AM, Nick Kralevich  
> wrote: 
> >>>>> 
> >>>>> 
> >>>>> Hmm  From the platform's point of view, this sounds like a 
> denial 
> >>>>> of service attack against other applications on the device. One 
> application 
> >>>>> shouldn't be able to interfere with another application's network 
> >>>>> connectivity without the user being involved. 
> >>>>> 
> >>>>> -- Nick 
> >>>>> 
> >>>>> 
> >>>>> On Tue, Jul 31, 2012 at 8:26 AM, CJ wrote: 
> >>>>>> 
> >>>>>> Hi, I am working on a app to automate some setting eg. to perform 
> >>>>>> certain action such as disable mobile data when battery is low or 
> night mode 
> >>>>>> etc. 
> >>>>>> There are app in the market that able to disable/enable mobile data 
> >>>>>> connection like SmartAction and a few more. I also dislike the 
> alter APN 
> >>>>>> method so I am looking for better alternatives. 
> >>>>>> 
> >>>>>> On Tuesday, 31 July 2012 23:14:41 UTC+8, Robert Greenwalt wrote: 
> >>>>>>> 
> >>>>>>> Apps won't be able to alter the APN database after Honeycomb or 
> >>>>>>> perhaps ICS.  The User can disable data from settings.  Why does 
> an 
> >>>>>>> application need to disable data? 
> >>>>>>> 
> >>>>>>> 
> >>>>>>> On Tue, Jul 31, 2012 at 8:03 AM, CJ wrote: 
> >>>>>>> 
> >>>>>>>> Hi, 
> >>>>>>>> 
> >>>>>>>> I have been googling for a while able the best or right way to 
> >>>>>>>> disable/enable mobile network. 
> >>>>>>>> 
> >>>>>>>> I tried the following code which is all over Stackoverflow and is 
> >>>>>>>> working fine for gingerbread and higher: 
> >>>>>>>> 
> >>>>>>>> private void setMobileDataEnabled(Context context, boolean 
> enabled)

Re: [android-developers] Is setting invalid APN the only way to disable mobile network connection?

2012-08-01 Thread CJ
Thanks everyone, I managed to do it without change APN setting and I have 
tested it from Android 1.5/1.6/2.1/2.2/2.3/4.0/4/1 and is all good.
Cheers.

On Wednesday, 1 August 2012 14:57:28 UTC+8, Dan wrote:
>
>
>
> On Tuesday, July 31, 2012 11:59:45 AM UTC-7, Kristopher Micinski wrote:
>>
>> This goes in the category of "apps modifying the system." 
>>
>> Your app shouldn't be able to modify the system.  
>> ...
>>
>
>
> Why?  If I want an app that turns off the data connection on a timer
> function or reading location manager information or I just don't like
> digging through a settings menu, why should I be at the mercy of an
> OEM's implementation?
>
> And if turning off the APN is "not good" why are there APIs that let
> you catch the NEW_OUTGOING_CALL intent and consume it so
> the call isn't dialed, or the incoming SMS messages, or holding a
> wake lock. 
>
>

-- 
You received this message because you are subscribed to the Google
Groups "Android Developers" group.
To post to this group, send email to android-developers@googlegroups.com
To unsubscribe from this group, 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] Question on service and broadcastreceiver

2012-08-06 Thread CJ
Hi,

If an app has a background service and broadcastreceiver, when the app is 
uninstalled or upgraded will the service/broadcastreceiver be removed 
accordingly?
If yes, then it is good. If not, do we need to manage them during app 
version upgrade?

Thanks.

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

Re: [android-developers] Question on service and broadcastreceiver

2012-08-07 Thread CJ
Cool!

On Tuesday, 7 August 2012 14:59:36 UTC+8, Bharath Smitha wrote:
>
>
>
> On Tue, Aug 7, 2012 at 12:26 PM, CJ wrote:
>
>> Hi,
>>
>> If an app has a background service and broadcastreceiver, when the app is 
>> uninstalled or upgraded will the service/broadcastreceiver be removed 
>> accordingly?
>> If yes, then it is good. If not, do we need to manage them during app 
>> version upgrade?
>>
>> Thanks.
>>
>> -
>
>
> yes definitely...
>
>

-- 
You received this message because you are subscribed to the Google
Groups "Android Developers" group.
To post to this group, send email to android-developers@googlegroups.com
To unsubscribe from this group, 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] Back button show old removed dialog

2012-08-07 Thread CJ
Hi,

My app display a dialog and base on user input I remove the dialog and 
redisplay it to refresh some new values.
This works ok but I realise if user press back button it will reopen the 
previously opened dialog with old value.
How can I totally remove the dialog?

Thanks.

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

Re: [android-developers] Back button show old removed dialog

2012-08-07 Thread CJ
Hi Treking,

Absolutely. I am facing some weird issue. Firstly, I am able to launch 
instant of my app I put a Toast inside onCreate() and it get called if I 
launch the app twice. I don't know why this happen and I tried on emulator 
different version and real phone.

After some gooling, someone mentioned to put this in onCreate() and I tried 
it seems to work:

if (!isTaskRoot()) {
isStart = false;
final Intent intent = getIntent();
final String intentAction = intent.getAction(); 
if (intent.hasCategory(Intent.CATEGORY_LAUNCHER) && intentAction != 
null && intentAction.equals(Intent.ACTION_MAIN)) {
Log.w(APP_TAG, "Main Activity is not the root.  Finishing Main 
Activity instead of launching.");
finish();
return;   
}
}

I also realized if I started my app and display dialog(a) and then 
dialog(b), if I start the app again with the abovementioned fix it will 
display where I left off which is dialog(b). Now, if I do a screen 
orientation change, it actually display dialog(a) instead of dialog(a) 
instead of dialog(b) which is before the screen orientation change. So I 
think it is no exactly the dialog problem but some problem with the setting 
or activity.

This is my 3rd Android app, I see nothing unusual in my code. Any 
suggestion what to investigate or which part of the code I can post here 
for assistant.

As for dialog, nothing unusual:
@Override
protected Dialog onCreateDialog(int id) {
switch (id) {
case SELECTION_DIALOG_ID:
LayoutInflater inflater_selectionDialog = (LayoutInflater) 
getSystemService(Context.LAYOUT_INFLATER_SERVICE);
final View layout_selectionDialog = inflater_selectionDialog
.inflate(R.layout.selection,
(ViewGroup) findViewById(R.id.selection));
AlertDialog.Builder builder_selectionDialog = new AlertDialog.Builder(
this);

// Usual stuff here...

// Configure Dialog Content
builder_selectionDialog.setView(layout_selectionDialog);
// Now configure the AlertDialog
builder_selectionDialog.setTitle(R.string.selection_dialog_title);
AlertDialog selectionDialog = builder_selectionDialog.create();
// For ICS to fillparent
WindowManager.LayoutParams lp_selectionDialog = new 
WindowManager.LayoutParams();
lp_selectionDialog.copyFrom(selectionDialog.getWindow()
.getAttributes());
lp_selectionDialog.width = WindowManager.LayoutParams.FILL_PARENT;
lp_selectionDialog.height = WindowManager.LayoutParams.FILL_PARENT;
selectionDialog.show();
selectionDialog.getWindow().setAttributes(lp_selectionDialog);
// For ICS to fillparent
//return selectionDialog;
break;
break;

default:
break;
}
return null;
}



public void onCreate(Bundle savedInstanceState) {
super.onCreate(savedInstanceState);
setContentView(R.layout.main);
mainContext = this;
// The following is to prevent the same app to launch 
twice, why? I have no answer.
if (!isTaskRoot()) {
final Intent intent = getIntent();
final String intentAction = intent.getAction(); 
if (intent.hasCategory(Intent.CATEGORY_LAUNCHER) && intentAction != 
null && intentAction.equals(Intent.ACTION_MAIN)) {
Log.w(APP_TAG, "Main Activity is not the root.  Finishing Main 
Activity instead of launching.");
finish();
return;   
}
}
Button okButton = (Button) findViewById(R.id.ok_button);
okButton.setOnClickListener((OnClickListener) this); 
}


public void onClick(View v) {
showDialog(SELECTION_DIALOG_ID);
}

@Override
public void onResume() {
super.onResume();
}


-- 
You received this message because you are subscribed to the Google
Groups "Android Developers" group.
To post to this group, send email to android-developers@googlegroups.com
To unsubscribe from this group, 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: Back button show old removed dialog

2012-08-07 Thread CJ
"I am able to launch multiple instant of my app" - I mean..

-- 
You received this message because you are subscribed to the Google
Groups "Android Developers" group.
To post to this group, send email to android-developers@googlegroups.com
To unsubscribe from this group, 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: Back button show old removed dialog

2012-08-07 Thread CJ
Remove dialog is usual stuff: 

MainActivity.this.removeDialog(SELECTION_DIALOG_ID);

-- 
You received this message because you are subscribed to the Google
Groups "Android Developers" group.
To post to this group, send email to android-developers@googlegroups.com
To unsubscribe from this group, 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: Back button show old removed dialog

2012-08-07 Thread CJ
Another strange thing, why do I have extra AndroidManifest.xml in 
bin/res

-- 
You received this message because you are subscribed to the Google
Groups "Android Developers" group.
To post to this group, send email to android-developers@googlegroups.com
To unsubscribe from this group, 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: Back button show old removed dialog

2012-08-07 Thread CJ
Another strange thing, why do I have extra AndroidManifest.xml in /bin  

-- 
You received this message because you are subscribed to the Google
Groups "Android Developers" group.
To post to this group, send email to android-developers@googlegroups.com
To unsubscribe from this group, 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: Back button show old removed dialog

2012-08-07 Thread CJ
Ok, I solved the dialog issue by return selectionDialog; instead of break;
>
> As for why I can launch multiple instant of the same app I still have no 
answer but have to use the "!isTaskRoot()" fixes.

-- 
You received this message because you are subscribed to the Google
Groups "Android Developers" group.
To post to this group, send email to android-developers@googlegroups.com
To unsubscribe from this group, 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: Back button show old removed dialog

2012-08-07 Thread CJ
Treking, many thanks as usual.

How can this happen? When an app has already launch, it will not restart 
onCreate() but onResume().
My app is starting onCreate() everytime, I have to put that isTaskRoot() to 
fix it. Never happen in my other app.
You mean this is normal?

Cheers.

On Wednesday, 8 August 2012 00:32:37 UTC+8, TreKing wrote:
>
> On Tue, Aug 7, 2012 at 8:28 AM, CJ wrote:
>
>> As for why I can launch multiple instant of the same app I still have no 
>> answer
>
>
> That's how Android works. If your app is started by different means (like 
> from the Launcher or from a notification or another app starts it) it 
> starts a new instance. If you don't want this behavior, use the correct 
> flags when launching the Activity.
>
>
> -
> TreKing <http://sites.google.com/site/rezmobileapps/treking> - Chicago 
> transit tracking app for Android-powered devices
>
>

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

Re: [android-developers] Re: Back button show old removed dialog

2012-08-07 Thread CJ
Yes, not normal at all and adding android:launchMode="singleTop" didn't 
help.
I read about the prob/solution here:  
http://stackoverflow.com/questions/4341600/how-to-prevent-multiple-instances-of-an-activity-when-it-is-launched-with-differ
 

I don't why this happen to this app and not my other app. The proposed 
solution doesn't solved the issue.


 












-- 
You received this message because you are subscribed to the Google
Groups "Android Developers" group.
To post to this group, send email to android-developers@googlegroups.com
To unsubscribe from this group, 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: Back button show old removed dialog

2012-08-07 Thread CJ
Hi Treking,

Really nothing unusual. I just launch it normally pressing home button to 
load the already loaded app or click the app icon etc.
I confirmed this behavior by adding a Toast message in onCreate() and it 
get called every time and of course if I press the back button, I can see 
it going reverse etc.

Stackoverflow said it's a bug and I googled and saw some similar situation. 
If it is, there might be something that trigger this and if we know we can 
prevent 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] Re: Back button show old removed dialog

2012-08-08 Thread CJ
:) I read it was reported 3 years ago and still happens sometime.

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

[android-developers] Get notification status from other apps

2012-08-30 Thread CJ
Hi, I just did some Googling but did not find any answer.
In Android SDK, is there a possibility to detect what notification is 
active in the notification bar?

Eg. My app is call "MyApp" and when a 3rd party "NotMyApp-A", "NotMyApp-B" 
fires 2 notification is there ways to detect them in my app?

-- 
You received this message because you are subscribed to the Google
Groups "Android Developers" group.
To post to this group, send email to android-developers@googlegroups.com
To unsubscribe from this group, 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] Recording system calls

2012-05-20 Thread CJ
Hi,
  Could someone tell me what is the best way to record system calls in
an android emulator?

-- 
You received this message because you are subscribed to the Google
Groups "Android Developers" group.
To post to this group, send email to android-developers@googlegroups.com
To unsubscribe from this group, 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: Get notification status from other apps

2012-09-03 Thread CJ
I see. Then is it possible to:
1. List out installed app that uses Notification?
2. List out app that are active running?

-- 
You received this message because you are subscribed to the Google
Groups "Android Developers" group.
To post to this group, send email to android-developers@googlegroups.com
To unsubscribe from this group, 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 switch gmail account attached to the gphone?

2009-01-05 Thread CJ

what i understand is there must be an gmail account attached to a
gphone. my question is how to switch it to another gmail account and
how to do so programmatically.
thx
--~--~-~--~~~---~--~~
You received this message because you are subscribed to the Google
Groups "Android Developers" group.
To post to this group, send email to android-developers@googlegroups.com
To unsubscribe from this group, send email to
android-developers-unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/android-developers?hl=en
-~--~~~~--~~--~--~---



[android-developers] how can BroadcastReceiver do managedquery?

2009-01-06 Thread CJ

it seems to do a query, i have to have an activity. but, what i have
for now is a BroadcastReceiver. how should i redesign my application?
because i did not intend to start any activity in my
BroadcastReceiver.
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] application removal notification

2009-01-15 Thread CJ

my application is a client running on the android. i need to know some
infomation about the installation or the removal of my application.
to be more specific, the server needs to be informed upon the
application removal.
is it possible?
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: application removal notification

2009-01-15 Thread CJ

anybody can help?


On Jan 15, 2:12 pm, CJ  wrote:
> my application is a client running on the android. i need to know some
> infomation about the installation or theremovalof my application.
> to be more specific, the server needs to be informed upon the
> applicationremoval.
> is it possible?
> 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] problem with binding to a service from a BroadcastReceiver

2009-01-20 Thread CJ

my idea was quite simple, it includes an activity, a
BroadcastReceiver, and a local service.
i try to bind to the service from either the activity or the
BroadcastReceiver.
the problem is:
if i call binding from the activity, everything looks fine.
but, if i call binding from the BroadcastReceiver, it always come back
with an exception (security not allowed, smth like that).

can anybody help? btw, because this is a loal service, i did not
define any permission in the manifest.xml. should i?

many thanks
CJ
--~--~-~--~~~---~--~~
You received this message because you are subscribed to the Google
Groups "Android Developers" group.
To post to this group, send email to android-developers@googlegroups.com
To unsubscribe from this group, 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] Quartile scorings

2008-09-26 Thread CJ

Hi, guys
I did not realize until now that I can get a better reply than "you
lost" after submitting my application. Can anybody tell me how? coz
apparently I missed such a chance in May.
I know this group might not be the best place to ask this question.
But, I cannot find a better one.
Thanks
CJ
--~--~-~--~~~---~--~~
You received this message because you are subscribed to the Google
Groups "Android Developers" group.
To post to this group, send email to android-developers@googlegroups.com
To unsubscribe from this group, send email to
[EMAIL PROTECTED]
For more options, visit this group at
http://groups.google.com/group/android-developers?hl=en
-~--~~~~--~~--~--~---



[android-developers] help needed on webservice (ksoap2)

2008-10-17 Thread CJ

Hi, guys
finally i gave up on trying it by myself. i am dying for help. plz
thanks
CJ

my situation is pretty simple. i have a webservice set up using php
under apache.

i have ksoap2-android-full-2.1.2.jar imported in eclipse.

on android client,
i havein the manifest file

http://schemas.android.com/apk/res/android";
  package="com.my.application.stupid.android"
  android:versionCode="1"
  android:versionName="1.0.0">


..

in the code, i have
String SOAP_ACTION = "helloWorld";
String METHOD_NAME = "sayhi";
String NAMESPACE = "http://192.168.0.50:9090/";;
String URL = "http://192.168.0.50:9090/server.php";;

SoapObject request = new SoapObject(NAMESPACE, METHOD_NAME);

SoapSerializationEnvelope envelope = new
SoapSerializationEnvelope(SoapEnvelope.VER11);
envelope.setOutputSoapObject(request);
AndroidHttpTransport androidHttpTransport = new
AndroidHttpTransport(URL);
try {
androidHttpTransport.call(SOAP_ACTION, envelope);
} catch(Exception E) {
}


the code always come back with a running error (NOT AN EXCEPTION) and
the application quits with information on the emulator screen:
sorry, the application has stopped unexpectedly. plz try again.

in debug mode, i see
com.sun.jdi.InvocationException occurred invoking method.
java.lang.reflect.InvocationTargetException

but, they are not caught by my catch statement.




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



[android-developers] Re: help needed on webservice (ksoap2)

2008-10-17 Thread CJ
in wireshark, i did not find any traffic sent out to the service
server. so, my guess is it did not get sent out at all.

On Oct 17, 12:05 pm, "shailesh prakash" <[EMAIL PROTECTED]> wrote:
> It works fine on mine service using java, hope php has similar
> implementation. See this may be error due to some semantic mistake.
> also check for wsdl with the browser. Those are some mistake I have
> done earlier. But I go with the original j2me jar. On that implement
> extra classes of ksoap2-android-full-2.1.2(two class in transport
> package), add commons-httpclient-3.1.jar.
>
> Thread t = new Thread()
>                                 {
>                                         private static final String 
> SOAP_ACTION = "add";
>                                         private static final String 
> METHOD_NAME = "add";
>                                         private static final String NAMESPACE 
> = "http://wtp.mycomp.com";;
>                                         private static final String URL =
> "http://192.168.1.101:8080/Axis2ServiceServer/services/CalculatorService";;
>                                         Integer a = null;
>                                         Integer b = null;
>
>                                         @Override
>                                         public void run()
>                                         {
>                                                 String stA = ((EditText)
> findViewById(R.id.EditText01)).getText().toString();
>                                                 String stB = ((EditText)
> findViewById(R.id.EditText02)).getText().toString();
>                                                 SoapSerializationEnvelope 
> envelope = null;
>                                                 try
>                                                 {
>                                                         a = 
> Integer.valueOf(stA);
>                                                         b = 
> Integer.valueOf(stB);
>                                                         SoapObject request = 
> new SoapObject(NAMESPACE,METHOD_NAME);
>                                                         
> request.addProperty("a", a);
>                                                         
> request.addProperty("b", b);
>                                                         envelope = new 
> SoapSerializationEnvelope(SoapEnvelope.VER11);
>                                                         
> envelope.setOutputSoapObject(request);
>                                                         AndroidHttpTransport 
> androidHttpTransport = new
> AndroidHttpTransport(URL);
>                                                         
> androidHttpTransport.call(SOAP_ACTION, envelope);
>                                                         Object result = 
> envelope.getResponse();
>                                                         KSoapClient.res = 
> result.toString();
>                                                 }
>                                                 catch (NumberFormatException 
> nfe)
>                                                 {
>                                                         KSoapClient.res = 
> "Only Integer numbers ";
>                                                         Log.e("Input Error: 
> ", nfe.getMessage());
>                                                 }
>                                                 catch (SoapFault sf)
>                                                 {
>                                                         Log.e("Service 
> Response Error, "+ sf.faultcode+":",
> sf.faultstring);
>                                                 }
>                                                 catch (IOException ioe)
>                                                 {
>                                                         Log.e("Service 
> Response Error: ", ioe.getMessage());
>                                                 }
>                                                 catch (XmlPullParserException 
> xppe)
>                                                 {
>                                                         Log.e("Service 
> Response Error: ", xppe.getMessage());
>                                                 }
>                                         }
>                                 };
>                                 t.start();
>
>
>
> On Fri, Oct 17, 2008 at 8:57 PM, CJ <[EMAIL PROTECTED]> wrote:
>
> > Hi, guys
> > finally i gave up on tryin

[android-developers] Re: call a soap web service from an android application

2008-10-17 Thread CJ
go get this
http://www.tuxpan.com/android-soap/android-ksoap2-build.zip

On Oct 17, 11:25 am, opengl es <[EMAIL PROTECTED]> wrote:
> Hi,
>
> I can't find AndroidHttpTransport...
> (I'm using android-sdk-windows-1.0_r1)
>
> Franck
>
> On Oct 17, 6:26 am, "shailesh prakash" <[EMAIL PROTECTED]> wrote:
>
>
>
> > Hi christian110011,
>
> > for kSOAP, you have to do something like this :
> > // you have to download ksoap for j2me and extend it's
> > org.ksoap2.transport.Transport  and implement ServiceConnection, coz
> > it is built
> > // for j2me not Android, you can eaisly find these two on other android 
> > group
>
> > Thread t = new Thread()
> >                                 {
> >                                         private static final String 
> > SOAP_ACTION = "addition";
> >                                         private static final String 
> > METHOD_NAME = "addition";
> >                                         private static final String 
> > NAMESPACE = "http://ws.apache.org/axis2";;
>
> >                                         // This is for service
> > deployed on Tomcat, for JBOSS Android is not working on my emulator
>
> >                                         private static final String URL =
> > "http://yourIP:8080/Axis2ServiceServer/services/CalcService";;
> >                                         Integer a = null;
> >                                         Integer b = null;
>
> >                                         @Override
> >                                         public void run()
> >                                         {
> >                                                 String stA = ((EditText)
> > findViewById(R.id.EditText01)).getText().toString();
> >                                                 String stB = ((EditText)
> > findViewById(R.id.EditText02)).getText().toString();
> >                                                 SoapSerializationEnvelope 
> > envelope = null;
> >                                                 try
> >                                                 {
> >                                                         a = 
> > Integer.valueOf(stA);
> >                                                         b = 
> > Integer.valueOf(stB);
> >                                                         SoapObject request 
> > = new SoapObject(NAMESPACE,METHOD_NAME);
> >                                                         
> > request.addProperty("a", a);
> >                                                         
> > request.addProperty("b", b);
> >                                                         envelope = new 
> > SoapSerializationEnvelope(SoapEnvelope.VER11);
> >                                                         
> > envelope.setOutputSoapObject(request);
> >                                                         
> > AndroidHttpTransport androidHttpTransport = new
> > AndroidHttpTransport(URL);
> >                                                         
> > androidHttpTransport.call(SOAP_ACTION, envelope);
> >                                                         Object result = 
> > envelope.getResponse();
> >                                                         KSoapClient.res = 
> > result.toString();
> >                                                 }
> >                                                 catch 
> > (NumberFormatException nfe)
> >                                                 {
> >                                                         KSoapClient.res = 
> > "Only Integer numbers ";
> >                                                         Log.e("Input Error: 
> > ", nfe.getMessage());
> >                                                 }
> >                                                 catch (SoapFault sf)
> >                                                 {
> >                                                         Log.e("Service 
> > Response Error, "+ sf.faultcode+":",
> > sf.faultstring);
> >                                                 }
> >                                                 catch (IOException ioe)
> >                                                 {
> >                                                         Log.e("Service 
> > Response Error: ", ioe.getMessage());
> >                                                 }
> >                                                 catch 
> > (XmlPullParserException xppe)
> >                                                 {
> >                                                         Log.e("Service 
> > Response Error: ", xppe.getMessage());
> >                                                 }
> >                                         }
> >                                 };
> >                                 t.start();
>
> > And if you like to create your own SOAP Engine(Custom Parser will do),
> > you may do,
>
> >     public String serviceResponse(String a , String b)
> >     {
> >         String s=null;
> >     

[android-developers] install application from sdcard, how?!

2008-10-31 Thread CJ

so, now, i have my apk i copied from my desktop sitting on the sdcard.
i just cannot find a way to install it on the g1. i am sure there
going to be plenty customers asking this question.
the problem is, i don't know the answer for them. for me, i can use
adb, or simply load it on my server and download it from the server
using g1 brower.
but, it is not simple for a customer.
can anybody show me how to do it?

thanks

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



[android-developers] why would android call oncreate when flipping the keyboard

2008-10-31 Thread CJ

i just realized that whenever i flip the keyboard, the function
oncreate is called, which means it is like closing my the application
and start a brand new one? is it weird to you guys? and how to disable
this feature?
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
[EMAIL PROTECTED]
For more options, visit this group at
http://groups.google.com/group/android-developers?hl=en
-~--~~~~--~~--~--~---



[android-developers] sdk activity life cycle picture inaccurate?

2008-11-06 Thread CJ

according to the picture, for an regular activity, if onstop is called
and ondestory is not called, there are only two ways to go: oncreate
or onrestart. which means, if oncreate is called, the PROCESS is
killed.

here is my application: the activity starts a thread that runs in th
background. then, i press the home key on the phone and click on my
application icon again. according to the debugger, th oncreate is
called which means the process has been killed. but, the debugger also
shows that the thread has never been killed which also means the
process has never been killed.

does it suggest that the red box saying process is killed does not
necessarily happen every time?

can anybody explain?

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
[EMAIL PROTECTED]
For more options, visit this group at
http://groups.google.com/group/android-developers?hl=en
-~--~~~~--~~--~--~---



[android-developers] Re: Notifications from file system

2008-11-06 Thread CJ

anybody has an example?


On Sep 17, 5:02 pm, hackbod <[EMAIL PROTECTED]> wrote:
> TheFileObserverclass allows you to monitor filesystem changes:
>
> http://code.google.com/android/reference/android/os/FileObserver.html
>
> It does need to be better documented, but it works. :)
>
> On Sep 17, 2:56 am, indra <[EMAIL PROTECTED]> wrote:
>
>
>
> > Hi,
>
> > Is there any way out by which we can get the change/modify
> > notifications on file system.
> > I want to get notifications from SD CARD, like we do on the databases
> > applying ContentObservers.
> > Pls help.
>
> > Thanks and Regards,
> > Indra- 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
[EMAIL PROTECTED]
For more options, visit this group at
http://groups.google.com/group/android-developers?hl=en
-~--~~~~--~~--~--~---



[android-developers] Re: Intercept Call

2008-11-06 Thread CJ

i don't think that is going to happen.

On Nov 6, 8:57 am, "BrunoZP.com" <[EMAIL PROTECTED]> wrote:
> Hi,
>
> How can I intercept a user call, change it number and dial again ?
> Any example code ??
>
> For example: The user dial 32546048 and press send, my application get
> this number, cancel the dialing, change this number to
> 3*2*5*4*6*0*4*8* and then dial !
>
> This needs to happen automatically, without the need of confirmations
> and other things..
>
> 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
[EMAIL PROTECTED]
For more options, visit this group at
http://groups.google.com/group/android-developers?hl=en
-~--~~~~--~~--~--~---



[android-developers] my application is trying to replace "Android System"

2009-01-27 Thread CJ

after i got my application ready, i put it on my web server, then i
got a big problem.
i played around and finally find out couple facts between using edge
(not 3g) and wifi to download my file
1. the size different. if i use wifi, the downloaded file is 59k which
is correct, the one from edge is only 53k.
2. when i try to install them, the wifi one is just fine. but the edge
one shows it is trying to replace Android System. and of course, the
installation failed.

can anybody help?
thank a ton


also shown in this link
http://groups.google.com/group/android-beginners/browse_thread/thread/4f82b29159a341fe
--~--~-~--~~~---~--~~
You received this message because you are subscribed to the Google
Groups "Android Developers" group.
To post to this group, send email to android-developers@googlegroups.com
To unsubscribe from this group, 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 pass object as a parameter when starting a service

2009-02-03 Thread CJ

Here I have a broadcastreceiver where i need to start a service. but,
the service need an object from this broadcastreceiver in order to
function. so, far, i have not found a solution.
Can anybody help me out?
thx
--~--~-~--~~~---~--~~
You received this message because you are subscribed to the Google
Groups "Android Developers" group.
To post to this group, send email to android-developers@googlegroups.com
To unsubscribe from this group, send email to
android-developers-unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/android-developers?hl=en
-~--~~~~--~~--~--~---



[android-developers] Re: how to pass object as a parameter when starting a service

2009-02-03 Thread CJ

any hints?

On Feb 3, 10:53 am, CJ  wrote:
> Here I have a broadcastreceiver where i need to start a service. but,
> the service need an object from this broadcastreceiver in order to
> function. so, far, i have not found a solution.
> Can anybody help me out?
> thx
--~--~-~--~~~---~--~~
You received this message because you are subscribed to the Google
Groups "Android Developers" group.
To post to this group, send email to android-developers@googlegroups.com
To unsubscribe from this group, send email to
android-developers-unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/android-developers?hl=en
-~--~~~~--~~--~--~---



[android-developers] Re: a receiver for outgoing sms and email?

2009-02-16 Thread CJ

i need this functionality three.
anybody?

On Feb 6, 9:42 pm, Oscar A  wrote:
> Hi
> I would also like to know if that is possible have tried a number of
> solutions without success. Have managed to Receive incoming sms but
> outgoing is still a difficulty for me.
>
> Would be grate if there where some sort of ACTION_NEW_OUTGOING_SMS
> (Broadcast Action: An outgoing sms is about to be sent) like the
> ACTION_NEW_OUTGOING_CALL that I use to monitor, modify, and abort
> outgoing calls.
>
> The Intent will have the receivers phone numbers attached and once the
> broadcast is finished, the "resultData" is used as the actual number
> to send the SMS to.
>
> Then we can implement an BroadcastReceiver abort an SMS like
>
> //Abort SMS
> setResultData(null);
>
> Suggested Permissions
> You must hold the PROCESS_OUTGOING_SMS  permission to receive this
> Intent.
>
> ...Until something like this is included in the API does anyone know a
> work around?
>
> Best Regards
> /Oscar Ahttp://drunkblocker.appspot.com
>
> On Feb 5, 6:00 am, Dietrich Ayala  wrote:
>
>
>
> > i figured out how to listen for outgoing calls. however, i can't find
> > any docs or code samples for making a Receiver that catches outgoing
> > sms or email.
>
> > is that possible?
>
> > thanks!
>
> > -dietrich- 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] it seems nobody here answer questions regarding mms

2009-02-23 Thread CJ

there are so many mms related questions unanswerd on this forum. it
looks to me that even a common mms query won't work. the most
ridiculous thing is the sender/receiver address won't show up in such
a query. i don't feel that is the way it is supposed to be.
can any google employee give us a break?
thx
--~--~-~--~~~---~--~~
You received this message because you are subscribed to the Google
Groups "Android Developers" group.
To post to this group, send email to android-developers@googlegroups.com
To unsubscribe from this group, send email to
android-developers-unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/android-developers?hl=en
-~--~~~~--~~--~--~---



[android-developers] Re: it seems nobody here answer questions regarding mms

2009-02-23 Thread CJ

as a matter of fact, i do need a real expert's expert. the reason is
so obvious that if i have enough time and energy, i can be an expert
in many things. but because i don't have them, i come here for
opinions and help. if some kind of experts only say, check your own, i
would suggest them to remain silence.

On Feb 23, 9:13 pm, Dianne Hackborn  wrote:
> You don't need a Google employee, you should have the full source available
> to look at.
>
> On Mon, Feb 23, 2009 at 5:51 PM, CJ  wrote:
>
> > there are so many mms related questions unanswerd on this forum. it
> > looks to me that even a common mms query won't work. the most
> > ridiculous thing is the sender/receiver address won't show up in such
> > a query. i don't feel that is the way it is supposed to be.
> > can any google employee give us a break?
> > thx
>
> --
> 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.  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: it seems nobody here answer questions regarding mms

2009-02-24 Thread CJ

I believe I did mention the problem I met even though I didn't make it
very clear. If I have to be more specific, here it is
a query liks this
Cursor  c = this.getContentResolver().query(Uri.parse("content://
mms/"),null,null,null,null);
returns the following columns
   // These constants are used to construct union queries across the
// MMS and SMS base tables.

// These are the columns that appear in both the MMS ("pdu") and
// SMS ("sms") message tables.
private static final String[] MMS_SMS_COLUMNS =
{ BaseColumns._ID, Mms.DATE, Mms.READ, Mms.THREAD_ID };

// These are the columns that appear only in the MMS message
// table.
private static final String[] MMS_ONLY_COLUMNS = {
Mms.CONTENT_CLASS, Mms.CONTENT_LOCATION, Mms.CONTENT_TYPE,
Mms.DELIVERY_REPORT, Mms.EXPIRY, Mms.MESSAGE_CLASS,
Mms.MESSAGE_ID,
Mms.MESSAGE_SIZE, Mms.MESSAGE_TYPE, Mms.MESSAGE_BOX,
Mms.PRIORITY,
Mms.READ_STATUS, Mms.RESPONSE_STATUS, Mms.RESPONSE_TEXT,
Mms.RETRIEVE_STATUS, Mms.RETRIEVE_TEXT_CHARSET,
Mms.REPORT_ALLOWED,
Mms.READ_REPORT, Mms.STATUS, Mms.SUBJECT, Mms.SUBJECT_CHARSET,
Mms.TRANSACTION_ID, Mms.MMS_VERSION };

there is no address regardless of the body of mms.

i am not sure if it is intended to be this way or not. but, either
way, that was my question. HOW TO get more info out of the query like
sms does?

also, i didn't mean to hurt anybody's feelings here. i know somebody
here such as Ms. Hackborn might be working hard to solve issues like
this one. but, i do wish to arouse center people's attention.

FYI, if you do a search with a keyword MMS like what I did, you might
realize it too.

P.S.
http://groups.google.com/group/android-developers/browse_thread/thread/802bf6dad154efe2/8f40dd4bf4454345?lnk=gst&q=mms#8f40dd4bf4454345
http://groups.google.com/group/android-developers/browse_thread/thread/5aeb72b2ef2c8b79/3e40785883a7d6d0?lnk=gst&q=mms#3e40785883a7d6d0
http://groups.google.com/group/android-developers/browse_thread/thread/239c6248ad7fdf6b/6eb488c3610462a3?lnk=gst&q=mms#6eb488c3610462a3
http://groups.google.com/group/android-developers/browse_thread/thread/62c8e713525f595b/a87b1916e158389d?lnk=gst&q=mms#a87b1916e158389d
http://groups.google.com/group/android-developers/browse_thread/thread/e3efcedeadb23ee5/37b2747ed1335d3d?lnk=gst&q=mms#37b2747ed1335d3d





On Feb 23, 10:11 pm, Mark Murphy  wrote:
> CJwrote:
> > as a matter of fact, i do need a real expert's expert. the reason is
> > so obvious that if i have enough time and energy, i can be an expert
> > in many things. but because i don't have them, i come here for
> > opinions and help. if some kind of experts only say, check your own, i
> > would suggest them to remain silence.
>
> You did not ask a question in your original post other than "can any
> google employee give us a break?", which is not really a useful question.
>
> Furthermore, you did not provide any source code and error messages to
> demonstrate whatever problem you may be experiencing with MMS.
>
> If you are unable or unwilling to ask questions and provide information
> to help us understand the questions, nobody can provide you with much
> help. In that case, Ms. Hackborn's answer remains the best advice anyone
> can give you: if you have questions regarding the MMS implementation,
> look at the source code and see if you can find your answers yourself.
>
> Now, even if you ask a focused question and ensure we can understand
> what is happening in your code, whether or not anyone can help you is
> another matter. The fact that "there are so many mms related questions
> unanswerd [sic] on this forum" suggests there are a shortage of experts
> working in this area.
>
> So, the choice is yours: follow Ms. Hackborn's advice, or ask a focused
> question and hope for the best.
>
> --
> Mark Murphy (a Commons Guy)http://commonsware.com
> _The Busy Coder's Guide to Android Development_ Version 2.0 Published!
--~--~-~--~~~---~--~~
You received this message because you are subscribed to the Google
Groups "Android Developers" group.
To post to this group, send email to android-developers@googlegroups.com
To unsubscribe from this group, 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 this still true?

2008-03-28 Thread CJ

Hi, guys
I saw this statement in the forum which was posted in Jan08
*quote: The current SDK doesn't have complete support for
orientations, and definitely not orientation switching while running.
*
First of all, is it still true?
Also, can anybody give a reference?
Thanks
CJ
--~--~-~--~~~---~--~~
You received this message because you are subscribed to the Google
Groups "Android Developers" group.
To post to this group, send email to android-developers@googlegroups.com
To unsubscribe from this group, send email to
[EMAIL PROTECTED]
Announcing the new M5 SDK!
http://android-developers.blogspot.com/2008/02/android-sdk-m5-rc14-now-available.html
For more options, visit this group at
http://groups.google.com/group/android-developers?hl=en
-~--~~~~--~~--~--~---



[android-developers] Re: Programmatically disable app optmization for my app

2016-07-27 Thread cj
Hi Fiona,

Did you receive any feedback regarding this situation? I'm working on an 
instant messaging app and have the same issues (delayed or dropped 
notifications).

Regards,
CJ

On Friday, April 29, 2016 at 12:39:36 PM UTC+2, Fiona wrote:
>
> Hi,
> I'm developing a communications app that relies on prompt notification 
> deliveries.
> I've noticed that Samsung automatically optimizes my app, which means 
> notification delivery is delayed. I've seen that some other apps are not 
> automatically optimized.
> Is there a way to prevent my app being optimized by default?
>
> Thanks
>

-- 
This communication and the information it contains are intended for the
person/s or organization/s named above and for no other person/s or
organization/s. As the content of this communication may contain
confidential, legally privileged and protected information, any unauthorized
use, copying or disclosure of any part of this communication may be
unlawful. If you have received this communication in error, please return to
the sender and delete the original from your system.

-- 
You received this message because you are subscribed to the Google Groups 
"Android Developers" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to android-developers+unsubscr...@googlegroups.com.
To post to this group, send email to android-developers@googlegroups.com.
Visit this group at https://groups.google.com/group/android-developers.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/android-developers/6eddc972-a42f-4aa2-a908-610d6c256ed0%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


[android-developers] Unzip code not working any more

2016-02-10 Thread CJ
Hi, what is wrong with this code? It seems to be broken in the newer 
version of Android.

---
public static final void unzip(File zip, File extractTo) throws 
IOException {
ZipFile archive = new ZipFile(zip);
Enumeration e = archive.entries();
while (e.hasMoreElements()) {
ZipEntry entry = (ZipEntry) e.nextElement();
//ZipEntry entry = e.nextElement();
File file = new File(extractTo, entry.getName());
if (entry.isDirectory() && !file.exists()) {
file.mkdirs();
} else {
if (!file.getParentFile().exists()) {
file.getParentFile().mkdirs();
}
InputStream in = archive.getInputStream(entry);
BufferedOutputStream out = new BufferedOutputStream(new 
FileOutputStream(file));

byte[] buffer = new byte[2048];
int read;

while (-1 != (read = in.read(buffer))) {
out.write(buffer, 0, read);
out.flush();
}
in.close();
out.close();
}
}
}

-- 
You received this message because you are subscribed to the Google Groups 
"Android Developers" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to android-developers+unsubscr...@googlegroups.com.
To post to this group, send email to android-developers@googlegroups.com.
Visit this group at https://groups.google.com/group/android-developers.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/android-developers/d93a8e20-e5bc-4bed-b07f-ab4ed492edc9%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


[android-developers] Google Maps API - Route Points - GPS-Data

2010-12-15 Thread CJ
Hi guys,
I’m a German student and I’m working on a little Android project. At
the moment I am trying desperately to get information about a route
(start->finish) with Google Maps API.
I would need the route as a string filled with points of the route
(GPS-Data) so I can calculate the distance from every single point to
a fixed other Location.
Can anybody help me or give me an advice?
Thank you very much! I would really appreciate it!
Bye
CJ

-- 
You received this message because you are subscribed to the Google
Groups "Android Developers" group.
To post to this group, send email to android-developers@googlegroups.com
To unsubscribe from this group, 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 Maps API - Getting GPS data ??

2010-12-15 Thread CJ
Hi guys,
I’m a student and I’m working on a little Android project. At the
moment I am trying desperately to get information about a route (start-
>finish) with Google Maps API.
I would need the route as a string filled with points of the route
(GPS-Data) so I can calculate the distance from every single point to
a fixed other Location.
Can anybody help me or give me an advice?
Thank you very much! I would really appreciate it!
Bye
CJ

-- 
You received this message because you are subscribed to the Google
Groups "Android Developers" group.
To post to this group, send email to android-developers@googlegroups.com
To unsubscribe from this group, 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: Google Maps API - Getting GPS data ??

2010-12-17 Thread CJ
Thanks for your answer, GPS Breadcrumbing seems to be really
interesting but unfortunatelly that's not what I'm working on.

The key to my project is to compare every point of a route (maybe all
points of the showed Google Maps API Polyline) and its GPS data to a
certain fixed location. That means that I could ask for route
information between to cities and then calculate the distance to my
actual location (GPS date from smartphone) at every point of the route
(that way I know where the best place to meet/join).

Unfortunatelly I have problems getting the GPS-data from Google Maps
API !

Can you/anybody help me?

Thanks a lot !!

Bye ;-)



On 15 Dez., 14:38, Spiral123  wrote:
> It sounds like you are working on GPS Breadcrumbing.
>
> If you take a snapshot of Latitude, Longitude (optionally Altitude) at
> defined time intervals during your trip you will be able to calculate
> Bearing, Velocity between points and distance of each point to a fixed
> other location using the handy functions built into the Location
> class..assuming that you just need distances calculated 'as the
> crow flies' rather than directional information.
>
> Personally I'd store it in a JSON array because the information is
> sequential in nature so a SQL database may be overkill.
>
> So.search the web for GPS and Breadcrumbing, look into the Android
> Location class and learn how to use JSON.
>
> Does that help?
>
> On Dec 15, 6:26 am, CJ  wrote:
>
> > Hi guys,
> > I’m a student and I’m working on a little Android project. At the
> > moment I am trying desperately to get information about a route 
> > (start->finish) with Google Maps API.
>
> > I would need the route as a string filled with points of the route
> > (GPS-Data) so I can calculate the distance from every single point to
> > a fixed other Location.
> > Can anybody help me or give me an advice?
> > Thank you very much! I would really appreciate it!
> > Bye
> > CJ

-- 
You received this message because you are subscribed to the Google
Groups "Android Developers" group.
To post to this group, send email to android-developers@googlegroups.com
To unsubscribe from this group, 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: Google Maps API - Getting GPS data ??

2010-12-17 Thread CJ
Thanks a lot. That is really helpful for me and gives me a lot of
safety for my project.

But I just stumbled over the following:
http://code.google.com/intl/en/apis/maps/documentation/directions/

At Directions Responses --> JSON
  "overview_polyline": {
  "points":
There I could get an code, in which the route points should be found??

Do you think it would be possible with the following "recipe" to get
the GPS-data ???
http://code.google.com/intl/en/apis/maps/documentation/utilities/polylinealgorithm.html

Thank you very much!


On 17 Dez., 16:47, JP  wrote:
> The Google Maps API does not offer the structured data that you are
> looking for (that I am aware of).
> This is not stashed away somewhere on the device, it isn't available.
> The data exchange between the client and the Maps server side is based
> on rastered (bitmap) map tiles. You'll have to find another source.
> You could see if you have more luck if you base your project on
> another map provider, Open Street Maps (OSM) comes to mind. I haven't
> used them on Android, but they may offer the structured data you are
> looking for. There is an open source project on Google Code that uses
> OSM based on recreated API calls of the Android Maps API, the link is
> burried on this list somewhere.
>
> If you're not bound to Android, and considering this is a student
> project, you should check out Maemo Mapper. Last time I checked it was
> open sourced under GPL, and it uses vector, i.e. structured data that
> you can access to run your algorithms on. If you are allowed to do
> this, and assuming proper attribution, I suppose, you could fork off
> Maemo Mapper and implement your project that way.
>
> Hope this helps.
>
> On Dec 17, 4:17 am, CJ  wrote:
>
> > Thanks for your answer, GPS Breadcrumbing seems to be really
> > interesting but unfortunatelly that's not what I'm working on.
>
> > The key to my project is to compare every point of a route (maybe all
> > points of the showed Google Maps API Polyline) and its GPS data to a
> > certain fixed location. That means that I could ask for route
> > information between to cities and then calculate the distance to my
> > actual location (GPS date from smartphone) at every point of the route
> > (that way I know where the best place to meet/join).
>
> > Unfortunatelly I have problems getting the GPS-data from Google Maps
> > API !
>
> > Can you/anybody help me?
>
> > Thanks a lot !!
>
> > Bye ;-)
>
> > On 15 Dez., 14:38, Spiral123  wrote:
>
> > > It sounds like you are working on GPS Breadcrumbing.
>
> > > If you take a snapshot of Latitude, Longitude (optionally Altitude) at
> > > defined time intervals during your trip you will be able to calculate
> > > Bearing, Velocity between points and distance of each point to a fixed
> > > other location using the handy functions built into the Location
> > > class..assuming that you just need distances calculated 'as the
> > > crow flies' rather than directional information.
>
> > > Personally I'd store it in a JSON array because the information is
> > > sequential in nature so a SQL database may be overkill.
>
> > > So.search the web for GPS and Breadcrumbing, look into the Android
> > > Location class and learn how to use JSON.
>
> > > Does that help?
>
> > > On Dec 15, 6:26 am, CJ  wrote:
>
> > > > Hi guys,
> > > > I’m a student and I’m working on a little Android project. At the
> > > > moment I am trying desperately to get information about a route 
> > > > (start->finish) with Google Maps API.
>
> > > > I would need the route as a string filled with points of the route
> > > > (GPS-Data) so I can calculate the distance from every single point to
> > > > a fixed other Location.
> > > > Can anybody help me or give me an advice?
> > > > Thank you very much! I would really appreciate it!
> > > > Bye
> > > > CJ

-- 
You received this message because you are subscribed to the Google
Groups "Android Developers" group.
To post to this group, send email to android-developers@googlegroups.com
To unsubscribe from this group, 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 mdm is possible in android

2010-11-08 Thread CJ
i cannot find any info on mdm. can anybody give a hint? how does
airwatch do it?
thx

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


[android-developers] Several Overlays on Mapview

2011-03-19 Thread CJ
Hi guys,

I am pretty new to Android and have a problem. I am working on a
navigation app and found a source I am working with for getting a
route by start and end location (here: 
http://code.google.com/p/j2memaprouteprovider/w/list).

Now I am trying to add several overlays like circles or even several
routes, but I doesn't work. Only the route provided is shown alone on
the mapvier. Here's the part of my activity code.


List mapOverlaysMarkerStart =
APTester1StartMAP.getOverlays();
Drawable drawable =
this.getResources().getDrawable(R.drawable.pushpin);
HelloItemizedOverlay itemizedoverlay = new
HelloItemizedOverlay(drawable,this);

GeoPoint point = new GeoPoint(start_lat_int,start_lon_int);
OverlayItem overlayitemStart = new OverlayItem(point, "abc", "123");

GeoPoint point2 = new GeoPoint(dest_lat_int, dest_lon_int);
OverlayItem overlayitemDest = new OverlayItem(point2, "cde", "456");



itemizedoverlay.addOverlay(overlayitemStart);
itemizedoverlay.addOverlay(overlayitemDest);

mapOverlaysMarkerStart.add(itemizedoverlay);



String url2 = RoadProvider
.getUrl(48.365647, 10.889969, 
48.003063, 11.355514);
//.getUrl(start_lat, start_lon, 
dest_lat, dest_lon);
InputStream is2 = getConnection(url2);
mRoad = RoadProvider.getRoute(is2);
mHandler.sendEmptyMessage(0);



__



There's always only one route shown, and not all together and I don't
know why. Unfortunatelly I am not familiar with canvas and overlays.

It woud be great if someone could take a look at the
j2memaprouteprovider code and help me out!!!

So long

ChrO

-- 
You received this message because you are subscribed to the Google
Groups "Android Developers" group.
To post to this group, send email to android-developers@googlegroups.com
To unsubscribe from this group, 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] Several Overlays on Mapview

2011-03-19 Thread CJ
Hi guys,

I am pretty new to Android and have a problem. I am working on a
navigation app and found a source I am working with for getting a
route by start and end location (here: 
http://code.google.com/p/j2memaprouteprovider/w/list).

Now I am trying to add several overlays like circles or even several
routes, but I doesn't work. Only the route provided is shown alone on
the mapvier. Here's the part of my activity code.


List mapOverlaysMarkerStart =
APTester1StartMAP.getOverlays();
Drawable drawable =
this.getResources().getDrawable(R.drawable.pushpin);
HelloItemizedOverlay itemizedoverlay = new
HelloItemizedOverlay(drawable,this);

GeoPoint point = new GeoPoint(start_lat_int,start_lon_int);
OverlayItem overlayitemStart = new OverlayItem(point, "abc", "123");

GeoPoint point2 = new GeoPoint(dest_lat_int, dest_lon_int);
OverlayItem overlayitemDest = new OverlayItem(point2, "cde", "456");



itemizedoverlay.addOverlay(overlayitemStart);
itemizedoverlay.addOverlay(overlayitemDest);

mapOverlaysMarkerStart.add(itemizedoverlay);



String url2 = RoadProvider
.getUrl(48.365647, 10.889969, 
48.003063, 11.355514);
//.getUrl(start_lat, start_lon, 
dest_lat, dest_lon);
InputStream is2 = getConnection(url2);
mRoad = RoadProvider.getRoute(is2);
mHandler.sendEmptyMessage(0);



__



There's always only one route shown, and not all together and I don't
know why. Unfortunatelly I am not familiar with canvas and overlays.

It woud be great if someone could take a look at the
j2memaprouteprovider code and help me out!!!

So long

ChrO

-- 
You received this message because you are subscribed to the Google
Groups "Android Developers" group.
To post to this group, send email to android-developers@googlegroups.com
To unsubscribe from this group, 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] I need advice from the Android developers community regarding a web link I am using within my App

2012-09-19 Thread Chris CJ
Hey Guys

I have pointed a part of my app at a publicly available webpage, however 
"the owner" of the web page has contacted me and asked me to cease pointing 
people to his web page.  My question is.is this considered to be 
illegal?  I believe it is commonly called 'web scraping', where you use a 
link to another web site/page within your website/page or in this case I 
have a button in my app that points to his webpage.  Your thoughts 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

[android-developers] Re: adb push hosts file into /system/etc/ - No space left on device error

2010-05-03 Thread CJ Bilkins
"Probably the reason why it's not working is that the /system
partition
is mounted read-only for obvious (security) reasons."

This may be true, but according to the adb command [
http://android-dls.com/wiki/index.php?title=ADB ]  You should be able
to get around this by remounting.  Relevant:

"adb remount  - remounts the /system partition on the
device read-write"

However, I've done that and I'm still receiving:

failed to copy './hosts' to '/system/etc/hosts': Out of memory

I, like the rest, am simply trying to test a local website on
android.  Is editing the hosts file not the recommended approach for
testing dev stage websites on android?  I'm open to suggestions for a
better way

On Mar 23, 3:47 am, Marek Pola  wrote:
> Hello,
>
> Probably the reason why it's not working is that the /system partition
> is mounted read-only for obvious (security) reasons. You need to
> remount it. Search on this mail list for the exact commands.
>
> But why do you need to edit the hosts file? Can't you use DNS to find
> the IP address of your host?
>
> Regards
> Marek
>
> On Mar 22, 5:04 am, Tushneem  wrote:
>
> > I am trying to edit the hosts file to access rest services in my local
> > network. Using adb pull I am able to get the hosts file for the
> > emulator and edit it. However I get the error "No space left on
> > device" when I do an adb push.
>
> > Does anyone know how to resolve this issue? Can we increase the space
> > for /system? If so how? Are there any other easier ways to access
> > local area network (without creating a DNS server).
>
> > 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: adb push hosts file into /system/etc/ - No space left on device error

2010-05-03 Thread CJ Bilkins
It seems my post from yesterday never showed up so I'm going to give
it another shot.  I'm also having this problem, I can find no way to
edit the hosts file on an android virtual device.  According to the
docs adb remount is supposed to put /system into read-write mode --
which it may be doing -- but I'm still getting an Out of Space
error.

It looks like I'm going to have to setup a DNS server just so I can
test a website unless someone has a better suggestion that I may be
overlooking.



On Mar 23, 1:27 pm, Antonin Hildebrand 
wrote:
> I have exactly the same problem:
>
> ~/android-sdk/platforms/android-7 ➔ adb remount
> remount succeeded
> ~/android-sdk/platforms/android-7 ➔ adb push /etc/hosts /system/etc/
> hosts
> failed to copy '/etc/hosts' to '/system/etc/hosts': No space left on
> device
>
> The reason why I need to use my local hosts file is simply because I'm
> running local server which needs to be accessed by android emulator.
> Not that uncommon setup I guess. I wonder why it is not working out of
> the box.
>
> Any help greatly appreciated. Thanks
> Antonin
>
> On Mar 23, 8:47 am, Marek Pola  wrote:
>
> > Hello,
>
> > Probably the reason why it's not working is that the /system partition
> > is mounted read-only for obvious (security) reasons. You need to
> > remount it. Search on this mail list for the exact commands.
>
> > But why do you need to edit the hosts file? Can't you use DNS to find
> > the IP address of your host?
>
> > Regards
> > Marek
>
> > On Mar 22, 5:04 am, Tushneem  wrote:
>
> > > I am trying to edit the hosts file to access rest services in my local
> > > network. Using adb pull I am able to get the hosts file for the
> > > emulator and edit it. However I get the error "Nospacelefton
> > >device" when I do an adb push.
>
> > > Does anyone know how to resolve this issue? Can we increase thespace
> > > for /system? If so how? Are there any other easier ways to access
> > > local area network (without creating a DNS server).
>
> > > thanks

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


Re: [android-developers] how to get info from a clicked textView?

2012-05-08 Thread Shah Faizal CJ
set on click listener to the text  that enough

On 5/8/12, Andreas Bratfisch  wrote:
> Simply implement a ArrayList with all your TextViews included,
> ArrayLists does have fast access through Iterators, this is the way
> as GridViews are working with. In your TableView add the TextViews
> with the index parameter and get the TextView with the index.
> Give your TextView the index key as tag and later you know what index
> you have to get from your ArrayList.
>
> Another idea i have is to implement a ArrayAdapter, its the same way.
>
> Its a idea only, no clue if its fast enough ;)
>
>
> -Ursprüngliche Nachricht-
> From: Eran
> Sent: Monday, May 07, 2012 6:14 PM
> To: Android Developers
> Subject: [android-developers] how to get info from a clicked textView?
>
> i set up a TagActivity that has 4 tags, each tag sets the content of
> a large tableView that holds about 15 textViews
>
> Im trying to find a way to get the tag info aswell as the textView
> info as a return String
> now i can basicly compare all of the 60 ids one by one, but it seems
> too long. is there any other way?
> there was no getText from the selected view, and i cant do much with
> the id unless i compare it to the r.id
>
> so how can i know which textView i'v clicked?
>
> --
> You received this message because you are subscribed to the Google
> Groups "Android Developers" group.
> To post to this group, send email to android-developers@googlegroups.com
> To unsubscribe from this group, send email to
> android-developers+unsubscr...@googlegroups.com
> For more options, visit this group at
> http://groups.google.com/group/android-developers?hl=en
>
> --
> You received this message because you are subscribed to the Google
> Groups "Android Developers" group.
> To post to this group, send email to android-developers@googlegroups.com
> To unsubscribe from this group, send email to
> android-developers+unsubscr...@googlegroups.com
> For more options, visit this group at
> http://groups.google.com/group/android-developers?hl=en

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


Re: [android-developers] Re: setting context menu for a button

2012-05-09 Thread Shah Faizal CJ
button.setonclicklistener(new onclicklister()
{
onclick()
{
openContextMenu(this);
}
})



On 5/9/12, Jason Teagle  wrote:
>>I tried as the same in the example defined here . but didn't get the
>>menu displayed .
>>
>>did not work - i am not getting the conext menu at all after clicking
>>button .
>
> OK. At this point I would recommend (for test purposes) you leave your
> existing project alone, start a new project with a new activity, add one
> button to the layout, and try adding the necessary code to add and show the
> context menu to the button. If it still doesn't work in a fresh project
> (which should be nice and small since it only has the one button and handler
> in it), then post your code here for us to look at.
>
>
> --
> You received this message because you are subscribed to the Google
> Groups "Android Developers" group.
> To post to this group, send email to android-developers@googlegroups.com
> To unsubscribe from this group, 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 can I Destroy activity

2012-05-15 Thread Shah Faizal CJ
over ride on back pressed method.
inside call the finish() method.


On 5/15/12, Narendra Singh Rathore  wrote:
> Even, when you are giving case R.id.bBack, it simply means, you are
> clicking back button.
>
> so you don't have to call setOnClickListener on the button further.
>
> NSR.
>
> --
> You received this message because you are subscribed to the Google
> Groups "Android Developers" group.
> To post to this group, send email to android-developers@googlegroups.com
> To unsubscribe from this group, 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