, Lo'oris loo...@gmail.com wrote:
On Apr 15, 11:42 pm, Bob Kerns r...@acm.org wrote:
I'm afraid that nobody is going to help you, because you don't give
enough context to indicate just what tool is giving this message.
I don't understand, I told I got this message compiling with ant (ant
I am confused.
JSON does not have a date format. And you do not show any JSON code!
Just what is your question?
On Apr 16, 5:26 am, Maxood maqs...@salsoft.net wrote:
I do not know the reason why am i getting same values of different
JSON date values. Here is my code for parsing date values in
You have a few options. You can ask the view for the position of the
selected item (getSelectedItemPosition()), or the ID you associated
with that item (getSelectedItemId()), or register listener with
setOnItemSelectedListener().
You can get the associated item with getSelectedItem(). You can get
There's nothing to fix; that is what is supposed to happen.
Even if it WERE called immediately -- you'd not see any updates to the
view until onTouchEvent() exits.
You'll need to allow the rest of the system to run between steps of
your animation. I'm not sure what to suggest for your tile
I understand, and completely concur with, this decision.
However, this leaves a major unfilled hole, that is limiting how
developers can cooperate.
Basically -- an application cannot depend on a service, provider, or
other component that it needs being present, unless it provides it
itself.
Not quite the only way, actually.
But it does depend on loading the class that defines the fields AFTER
you get your hands on the context.
What you can do is to save that context in a static (non-final) field,
in a different class.
Then, in the class with your fields, you include a static
information in e.g. the blue channel and you'll see what I want to
do.
On 12 Apr, 21:38, Bob Kerns r...@acm.org wrote:
And just what useful visual result do you want to happen as a result?
OR makes sense for black and white, not forcolor.
Or are you using the graphics processor for something
I'm afraid that nobody is going to help you, because you don't give
enough context to indicate just what tool is giving this message.
You should be working entirely in UTF-8, never ASCII. So you need to
figure out what tool is working in ASCII, and make it use UTF-8.
But first you have to which
I'd bet that 100 microseconds exceeds the resolution of the Android
scheduler. If you actually need that much synchronization of action, I
think you're out of luck. If you just need that small a skew between
timestamp sources, I'm not sure.
I'm have no experience with IEEE-1588. However,
It looks to me like you're making the classic beginner mistake -- one
that even bites experienced database programmers if we're at all
inattentive...
Cursors start out positioned *before* the first row. You have to
actually position them to the first row before you try to access data.
I believe your problem is that you don't declare the permissions with
the permission/ tag in the Application1 manifest.
To verify this, I created two apps, with your manifests. I changed the
package name from 'com.android' to 'com.example', because you
shouldn't be using com.android, but
Of course, you should use something other than @string/hello as the
descriptions! It insists on a resource, and I just grabbed those.
On Apr 14, 12:53 am, Bob Kerns r...@acm.org wrote:
I believe your problem is that you don't declare the permissions with
the permission/ tag in the Application1
You get your ClientProviderClient like this:
Uri uri = Uri.parse(content://com.sabretch.colorEyeD/
yourtable);
ContentProviderClient cpc =
getContentResolver().acquireContentProviderClient(uri);
(This only uses the authority part of the Uri --
I can't quite see how you're doing MVC here. I see a view, and I see a
Game class which looks a bit like it might be a model? Where's the
controller?
Generally, in MVC, the view registers its interest in the state of the
model via the Observer pattern. Thus, the model has no knowledge of
the
You can't run your own code during installation. You'll need to do
this on first run. The best place to do this is in the onCreate()
method of your application class.
You can record that you've initialized in a SharedPreference, or you
can check the filesystem, to see if it's in the desired
I don't have a solution, but I have a couple of recommendations --
either of which would avoid the problem.
#1 - don't use object serialization. Convert to an XML or JSON
representation instead. XML in particular would be preferred if you're
going to store these for an extended time.
#2 -- don't
I think you must be misreading the documentation. If so, let's see if
this makes it more clear:
Variables are not objects. Variables refer to objects.
So when the documentation says you can't reuse an async task, it means
you can only run that OBJECT once.
But if you create a NEW instance (as
,
Randika
On Apr 14, 1:09 pm, Bob Kerns r...@acm.org wrote:
You get your ClientProviderClient like this:
Uri uri = Uri.parse(content://com.sabretch.colorEyeD/
yourtable);
ContentProviderClient cpc =
getContentResolver().acquireContentProviderClient(uri
This is rather complex, so it's going to be a bit tricky to answer,
I'm afraid.
It does sound like you've dealt with a lot of the harder issues. I'm
not sure exactly what you mean when you say flavor you want to
build. Build as in -- produce a .apk, or do you mean Eclipse build,
putting the
(cur.moveToNext());
}
}
can u give me any suggestion
Regards,
saikiran
On Apr 14, 12:53 pm, Bob Kerns r...@acm.org wrote:
I believe your problem is that you don't declare the permissions with
the permission/ tag in the Application1 manifest.
To verify this, I created two apps
It is often better to insert all the data and THEN create the indexes.
I couldn't tell you about Sqlite.
You may want to create the primary index, but create all the other
indexes later.
On Apr 12, 5:33 pm, Zsolt Vasvari zvasv...@gmail.com wrote:
No, database writing is extremely slow
There are a few exceptions.
First, let's distinguish between a service which continuously runs, vs
one for which there is a continuing need.
You NEVER want a service to be continually running, or even frequently
running. You'd even strongly prefer to not have it maintain a process.
My own app
My impression, not well investigated, is that your service is NOT
likely to be killed while it is actually running on the main thread
doing processing. I'm guessing you're doing this on a separate thread?
Your process may be killed, but is less likely to be killed, if you
start the service, and
I had various issues with progress bars -- sliders in my case -- and
even replaced ListView with my own implementation. But I have a guess
what my problem was, and of my own making.
Just for illustration purposes, here's my code replacing ListView:
ViewGroup sliders =
[Message delayed due to technical difficulties..]
raqz and I have been discussing this off-list, so just to sync things
up a bit...
Raqz asked me about JSON -- possibly in response to your suggestion.
It's a good suggestion to consider. I tend to suggest XML by default,
because it's more
Well, it would sure help if you didn't assassinate the process the
service is running in! You do not want to call System.exit().
Now, one thing to realize about Android is that processes are killed
when not needed -- or sometimes even when needed -- and then restarted
later, re-creating the
And just what useful visual result do you want to happen as a result?
OR makes sense for black and white, not for color.
Or are you using the graphics processor for something other than
actual graphics?
On Apr 12, 3:30 am, Kaj Bjurman kaj.bjur...@gmail.com wrote:
Hi,
Is it in some way
HTTPS will not, under any circumstance, let you get access to header
or content information from other applications. This would be a
security violation of the highest order! Like steal all your money
security violation. Like steal your identity security violation.
You can use various protocol
Actually, Android omits a LOT of the standard J2SE JDK -- though
nothing that would impact a JSON parser.
But the usual JSON parser is built into Android. Just do new
org.json.JSONObject(json string)
On Apr 12, 2:33 am, vworld4u vworl...@gmail.com wrote:
You can use JSON Parser readily
You can also use XmlSerializer to serialize a DOM, together with about
a page of code to walk the DOM.
That's a whole lot more painful than it ought to be, but it's better
than writing XML tags yourself, which if you find yourself doing,
you're doing something wrong.
On Apr 12, 5:57 am, Mark
No, we're not arguing semantics, we're agreeing. We were both
responding to Miguel. (You did leave out being blocked in an IO call,
but that's a minor detail).
On Apr 10, 6:56 pm, Robert Green rbgrn@gmail.com wrote:
Bob,
Perhaps we're just arguing semantics. I was simply saying that you
to
sleep to maintain a constant rate, and is quite efficient.
I've achieved a smooth display, and the physics progresses a step at
each game loop iteration.
This has worked well for me.
On Sat, Apr 10, 2010 at 12:57 PM, Bob Kerns r...@acm.org wrote:
If a thread is hogging the CPU
intervals).
On Apr 10, 7:25 pm, Jason LeBlanc jasonalebl...@gmail.com wrote:
Since process != application.. just what are the distinctions?
On Fri, Apr 9, 2010 at 5:06 PM, Bob Kerns r...@acm.org wrote:
Just to point out a couple more things here.
1) a Service's lifetime is NOT, in general
Just what are you trying to achieve?
If you're actually wanting a hash map, efficiently populated on class
loading, then Streets of Boston's approach won't help you -- nor will
aapt.
To do what you actually ask for, you could write an XSLT script to
generate the necessary java code.
One of the
If a thread is hogging the CPU, it is *BY DEFINITION* not idle. And
vice versa.
An idle thread will be waiting on something. Either a synchronization
lock, or an object using wait(), or some blocking IO call. This may be
buried inside some other code, of course.
I would suggest wondering why you
You may want to pause at this point, and consider whether this is
REALLY what you want to do.
There are major limitations involved with using object serialization
this way, that affect you both now and in the future, and you have to
think VERY carefully about the implications of both.
The object
.
That definitely looks like the certificate to me, not that I'm a
certificate expert.
I'm still wondering how the maps API does it. If it's something that
they're keeping secret, fair enough I guess, would've been nice. But
still an interesting problem.
On Apr 6, 12:10 am, Bob Kerns r...@acm.org
every time.
On Apr 10, 5:56 am, Bob Kerns r...@acm.org wrote:
Your abuse of global variables (i.e. with the static keyword) is
giving you memory leaks.
On Apr 9, 9:58 am, Gubatron gubat...@gmail.com wrote:
Here's a static wrapper I implemented to get and set properties real
I'm not wrong. But it seems you aren't wrong either!
I was consulting the source. It's definitely a CheckedTextView. I just
confirmed it with the Hierarchy Viewer; there's no discrepancy.
But I definitely see the radio button icon.
Here's what's going on:
The layout:
CheckedTextView
How do you know you lifted them in the same order you put them down?
Give your description, I'd expect to see both orders.
There are known limitations of the multitouch implementation on all
the Android phones out there now. But this doesn't seem to me to be
one.
Try carefully putting one finger
Just to clarify/avoid a possible misunderstanding
If you are using a WebView to do your album, rather than building it
out of Android's widgets (as Nick suggests), then you CAN, of course,
use CSS.
The Android UI toolkit supports styles and themes, which act somewhat
like CSS, but with a
I hope you realize that the service won't actually start until *after*
the method on the main thread that started it exits. This is true even
if you start up another thread to start the service. Starting the
service -- even an IntentService -- requires that the main thread be
free. (It's somewhat
Gravity gives you one frame of reference -- and the compass gives you
another.
If you're just spinning, this is enough to give you 3D orientation.
However, it is trickier if you are also accelerating. Let's say you
accelerate horizontally at 1G. To the sensors, that will look the same
as
The Nyquist theorem states that you need to sample at least 2x the
frequency you are sampling to be able to capture it. However, you'll
also get various spurious beat signals which can be large compared to
the actual signal if you try to push too close to that 2x. That is, if
you sample 1 Hz
But he says he's using a content URI? As in going through a content
provider?
I think we need more information.
BTW, it *is* possible to read another app's DB directly, if you sign
both with the same cert and give them the same userid. But that's
probably not what he wants to do here...
On Apr
Your abuse of global variables (i.e. with the static keyword) is
giving you memory leaks.
On Apr 9, 9:58 am, Gubatron gubat...@gmail.com wrote:
Here's a static wrapper I implemented to get and set properties real
easy
package gubatron.android.util;
import java.util.Arrays;
import
Just to point out a couple more things here.
1) a Service's lifetime is NOT, in general, the same as an
Application's lifetime. A service can be deleted when it's not in
active use by any activity or intent. This can save memory.
2) Under some circumstances, more than one application may be
Then I think this simplifies the advice we should give you.
If you don't know enough about threading to know what a lock is, you
should avoid threading for now. It'll be too much to learn at once,
and you won't be able to do a good job of either learning about
threading, or applying it.
I think
Try:
1) Refreshing the project, and rebuilding.
2) Cleaning the project, and rebuilding.
3) closing and reopening the project, and rebuilding
4) deleting the project (but not deleting the files -- that's a
checkbox on the project deletion confirmation dialog), and re-
importing it as an
Think of it this way -- there is no such thing as pass-by-value in
Java, and no such thing as references, either. Everything is
equivalent to a pointer, except there is NO pointer arithmetic, and no
- operator, that role being handled by '.', so it LOOKS like a
reference with C++ eyes.
To add to
heard of the single choice
layout that displays a radio button on every list item. But my guess
is that most people who have done any work with ListViews are at least
aware of this very basic and useful feature.
On Apr 7, 11:35 am, Bob Kerns r...@acm.org wrote:
Perhaps -- but since I don't
It looks to me like they may be doing this to the apps they offer on
their site. It might even be with permission -- though if the OP was
complaining of their doing it to one of his apps, I guess not.
HOWEVER -- as a developer, I can find no way to list my paid app on
their site. This makes me
Another approach, which may have benefits beyond the configuration
change issue, is to make your service only tear down the expensive
resource after a delay. Then, if you reconnect before that timeout,
you can simply reuse the resource. So if you exit and come back soon
into your app, for example,
I'm a bit puzzled why the other respondents didn't pick up this, maybe
I missed something in the discussion?
But anyway, the basic flaw in your strategy is reading it all into
memory at once. There's no need to do so, and that is ALWAYS going to
impose a limit on the size of file you can handle,
Apology definitely accepted.
Just to illustrate the difficulty -- and why I don't fault you for
failing to be clear:
None off my car radios EVER had lights that lit up for the buttons.
They had buttons that would stay depressed. To set a station, you'd
tune to the station, and then PULL OUT the
any action.
I guess this is the flipside of playing on an open platform.. focus on
building a better product and worry less about the bottom-feeders.
-g
On Apr 8, 8:43 am, Michael MacDonald googlec...@antlersoft.com
wrote:
On 04/08/10 08:23, Bob Kerns wrote: HOWEVER -- as a developer, I
my lawyer personally contact
you. As this is a violation of more than one law, regardless of my
past, this is wrong. It was sold to a guy out of Sweden. What he did
or does with it is out of my control.
Please remove my contact info.
On Apr 8, 8:07 pm, Bob Kerns r...@acm.org wrote:
Well
. Don' post info if
it is outdated, just by looking at it you can ell. Check whois.net and
you can see it was updated daily and is not associated with me.
On Apr 8, 9:47 pm, Bob Kerns r...@acm.org wrote:
The public record claims you are. If you are not, then you have a
problem
This doesn't save you from ANY of the complexities of the activity
lifecycles.
It only removes SOME of the reasons you'll transition through them.
You should still code for the lifecycle.
It makes your job harder, because not only to you get to debug your
current problem -- you lose an easy way
I've been meaning to ask about this...
When I try to run procrank on my device, a Nexus One, I get an error
that libpagemap.so is not found (and indeed, it's nowhere on my
device).
Is this not present by default in non-debug builds? Is there some way
I could obtain it?
While I'm at it, when the
Perhaps -- but since I don't really understand the question, perhaps
question quality had something to do with it?
The radio button. What radio button?
What's a a simple_list_item_single_choice layout?
These things probably seem obvious to you, but they're not to me. So I
can only guess at the
I would guess that you failed to supply two arguments to Log.d(tag,
message), or that you aren't looking for the message using logcat,
but expecting it to show up somewhere else.
Otherwise, your question is too unclear to answer. You CAN use sockets
to communicate with your computer. That, or any
Actually, you CAN send email silently. You can send email from any
device capable of an outbound TCP connection on the SMTP port.
You can even send it as coming from the user's account. Or, you can
pretend to be Obama, or your favorite rock star.
You just can't get the built-in email application
Just a few comments, from someone who's been releasing software for
nearly 30 years.
I don't recommend releasing software from an IDE, because you don't
have enough control over IDE settings and behavior.
That setting you tweak today for this or that test, may make it into
the product as a
ArrayList would be a better choice; Vector has extraneous method
synchronization.
But either one suffers from the problem that you'll need to store
Integer objects rather than int values, which will cause GC. That
should not be a problem here, I just point it out as a difference from
using an
at 8:08 PM, Bob Kerns r...@acm.org wrote:
It looks like you are trying to access the connection before the
onBind() method is called?
You should NOT be sleeping the thread. You should be returning, and
then picking up your work once onBind() is called.
You're actually blocking the service
I've been holding off on replying to this only because I haven't fully
collected my thoughts. I hope to write up my recommendations for build
approaches, especially for free/paid apps, before really wrapping my
mind around it.
But since that's taking me a while, I thought I should chime in, yes,
TreKing -- He doesn't understand what a debug build is. The flag
indicates that the DEVICE, not your APPLICATION is a debug build.
HeHe -- That's why you can't get at it with Config.DEBUG -- you'd need
to reflash your device. You don't make this in Eclipse -- or at least
not using the SDK.
What
Well, first, there's likely to be no MD5 hash involved at all. DSA
with SHA-1 would be the default signature type now, I believe.
Hashcode would not be secure. That is, you can construct an alternate
app+signature that would produce the same hash code. That may be good
enough for you, but I would
Actually, the explanation here is incorrect.
You CAN cast from Integer to int, or Double to double, or Boolean to
boolean. In fact, the compiler will even do it for you these days.
However, those are specific cases of related types.
There is no relationship whatsoever between the types Bitmap
I didn't suggest writing any Java code. I didn't suggest writing any
ant tasks in Java.
I said to create an antlib (though I should have said library of ant
definitions to be used with include/), which is entirely in XML.
That's part of why I suggested this approach, as it would avoid the
need
Your application is ALWAYS going to see Config.DEBUG as FALSE. You
seem stuck on that. Config.DEBUG has nothing to do with your
application whatsoever. It has to do with your device.
I need to get breakfast, I'm getting grumpy. In addition to the link I
sent you, look at this link (which is
The println in question is inside Log.d, which you are calling
incorrectly. The first argument is an identifier tag; the second
should be your message string.
I don't really recommend catching exceptions this way, and only
printing the message. Especially since the message can be null -- at
least
to achieve
the purpose and i also have to look outside of Eclipse IDE and my code
to find my machine gun. please forget my problem and have a nice
breakfast :) thanks anyway for your comments.
On Apr 5, 9:49 am, Bob Kerns r...@acm.org wrote:
Your application is ALWAYS going to see Config.DEBUG
I'm afraid you'll have to remove yourself from the list; we can't do
it for you. Go to the group website and unsubscribe yourself there.
http://groups.google.com/group/android-developers/subscribe
On Apr 5, 6:56 am, Shirley Mara www.shirley75@gmail.com wrote:
não quero receber mais essas
are
pretty deep. Let's just say it's never been made practical and
robust.
On Apr 5, 11:20 am, ko5tik kpriblo...@yahoo.com wrote:
On Apr 5, 6:09 pm, Bob Kerns r...@acm.org wrote:
Hashcode would not be secure. That is, you can construct an alternate
app+signature that would produce the same hash code
It looks like you are trying to access the connection before the
onBind() method is called?
You should NOT be sleeping the thread. You should be returning, and
then picking up your work once onBind() is called.
You're actually blocking the service from running until you do return,
since it needs
You don't generally have to use your ISP's DNS servers, you can use
any DNS servers you want.
I use OpenDNS myself, and ignore Comcast's.
However, occasionally some firewall or other security software will
block DNS to other servers. So this is worth a try.
On Apr 5, 4:03 pm, Brion Emde
In addition to this fine reason, using the provided symbol will allow
the compiler to catch any typos, while simultaneously making it clear
that you are using a standard value, and allowing you to see the
documentation for that value with the mouse.
It's a big win all around.
On Apr 4, 5:09 am,
I should have said to opt for the simplest thing that actually works!
Or, to put it another way, as simple as possible, but no simpler.
(Neither phrase is mine, but I can't recall the correct attributions.)
For the fastest result, I'd start off with both listeners. The network
will nearly always
If Jason's suggestion of pushing it to a server is inadequate, you can
buffer events, and only write them out once a minute or 10 minutes or
something. This will put an upper bound on the number of writes
performed.
You can combine the approaches, and push to the server, and only write
to the
You know, I've always considered these responses to cross-posting to a
relevant forum or two to be rude. And I've been doing this longer than
there's been anything called Usenet or groups or forums, so this isn't
some newbie comment.
Traditionally, a cross-post to a small number (2, perhaps 3) of
...
I'm quite suspicious thinking both My projects AND microsoft + google
+ linux developers all get it so wrong...
Emmanuelhttp://androidblogger.blogspot.com/http://www.alocaly.com/
On Apr 1, 6:28 pm, Bob Kerns r...@acm.org wrote:
My first response was to say OF COURSE YOU CAN
:27 pm, Bob Kerns r...@acm.org wrote:
I'm a bit puzzled at your response, as you seem to be addressing C/C++
rather than Java? I've probably contributed to the confusion by
talking a little bit about C++ vs C. Perhaps you intend your response
to just refer to some aspect of those remarks
That's not the problem, he's reporting a compiler error. (He may yet
have that problem downstream of this one).
Darshan, what you've written is not valid Java syntax.
You mean one of these two constructors
ComponentName(string, string)
or
ComponentName(context, class).
What you've supplied as
I don't think you're saving anything significant.
It takes only a tiny bit of energy -- VERY tiny -- to register a
listener.
The things that will make a difference are keeping the various
components awake and powered up. For example, keeping the processor
awake and running, or keeping the GPS
Often you won't. Then someday you will, and won't know what happened
to you!
Sometimes, the context you need has to be the current activity -- and
it won't be.
And even worse -- sometimes the context won't even be for your current
application -- but rather, the first application that started in
I've wondered about this, and don't have any definitive answer to
this.
However, there are several factors involved. Flash memory involves
rewriting entire chunks of data, often larger than a single block,
when a single block is written. This can affect how often a given
location is written.
On Mon, Mar 22, 2010 at 8:44 PM, Bob Kerns r...@acm.org wrote:
What does it mean to block an incoming call?
My guess is it just not ring.
In that case, it may simply mute the ringer, and register a
PhoneStateListener with the TelephonyManager. If it likes the number
in onCallStatechanged
!
Emmanuelhttp://androidblogger.blogspot.com/http://www.alocaly.com/
On Mar 30, 12:36 pm, Bob Kerns r...@acm.org wrote:
You do not do that in Java.
I suggest you should not do that in C++, as there are better ways to
do it.
I suggest you do not use C.
On Mar 30, 2:57 am, Dilip
There is no such thing as a self-closing XML tag.
The two lines below -- original and your SHOULD BE version -- are
100% equivalent, and parsers will not distinguish between them.
The standard is at:
http://www.w3.org/TR/2006/REC-xml11-20060816/
if you'd like to verify.
HTML is a different
If you don't specify in the manifest that the components should have
different process names, they'll be in the same process.
You can even put components from different .apk's into the same
process by giving them the same process name -- so long as they're
signed by the same cert. Or maybe the
Server. This allows automatic version stamping for the about screen--
though does not yet modify the version name/number in the manifest.
On Mar 30, 9:42 am, Bob Kerns r...@acm.org wrote:
You can download a Java decompiler and investigate yourself. I suggest
this one:http
It's a good pattern, but I've found some exceptions. For example, the
theme I wanted to apply to my PreferenceActivity wouldn't take effect
unless I put it before the superclass's onCreate().
To avoid future compatibility issues, the contract really needs to be
documented.
I've submitted an
How ironic, a black-hat SEO link spammer nicely self-referentially
documenting what he's doing.
Fortunately, Google is putting the rel='nofollow' attribute on the
link, so it won't actually affect the page rank. I hope everyone who
mirrors this list does the same, because we shouldn't be
I've contacted them, and gotten a response, basically asking that
their support address be removed from the list.
I've pointed out that there's no way for us to do that, and they
should do so. I've also pointed out that their auto-reply thing should
not be sending an auto-reply to messages that
Be liberal in what you accept, and conservative in what you send.
may be Jon Postel's most famous quote, but it is not his best
contribution to the internet.
It seemed like a good idea at the time, when the number of senders and
the complexity were both low.
Experience has taught us that being
You do not do that in Java.
I suggest you should not do that in C++, as there are better ways to
do it.
I suggest you do not use C.
On Mar 30, 2:57 am, Dilip Dilip dileep2m...@gmail.com wrote:
Hi All,
How to do conditional compilation in JAVA.
something like in C, C++ :
#ifdef
generally do not WANT conditional
compilation, as it would make your code break when you moved it to
another environment.
This isn't an issue for C++ or C because the compiled files aren't
portable anyway.
On Mar 30, 3:36 am, Bob Kerns r...@acm.org wrote:
You do not do that in Java.
I suggest
You can download a Java decompiler and investigate yourself. I suggest
this one:
http://java.decompiler.free.fr/?q=jdgui
You'll see that it does indeed optimize when it can.
However, unlike a C file which gets linked into a .so or .dll or an
executable, Java classes may be combined in different
501 - 600 of 886 matches
Mail list logo