Services are a mechanism for doing tasks that take a long time (among
another things). Based on this, the result of a service doing something
is typically available after a delay, so services are asynchronous by
their nature.
If you have a piece of code that you wish to run synchronously, just
call that code directly (remembering to avoid code that can lead to ANRs).
The only time I can see synchronous start / bind could be useful is
updating an Activity with the current state of some process managed by a
service.
But even this case should work pretty well, because at the time onCreate
is called (and presumable, that's where service start / bind is called),
the activity is not fully visible yet (since its content view is only
specified inside onCreate).
-- Kostya
03.11.2010 0:30, jotobjects пишет:
On Nov 2, 1:33 pm, Frank Weiss<[email protected]> wrote:
GUI Programming 101
All GUIs I've seen use an event queue. This is one of the biggest prardigm
shifts to overcome for someone who is used to sequential, non-GUI
applications.
The Service object by definition has nothing to with GUI programming,
but you sort of have the right idea.
--
Kostya Vasilyev -- WiFi Manager + pretty widget -- http://kmansoft.wordpress.com
--
You received this message because you are subscribed to the Google
Groups "Android Developers" group.
To post to this group, send email to [email protected]
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