I have issue with spanish characters in java string. I have a content
RSS feed and when i try to transform it to java object using
InputStreamReader, I get outputs like cómo which should be cómo.
This is happening with other spanish characters like
á = á é = é í = à ó = ó ú = ú
and more..
Thank you. Will try 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
I am sure this is easy, but can't find solution for this.
My app structure is something like this:
HomeActivity subActivity subSubActivity subSubSubActivity
On each activity (except home) in top left corner I have Home Icon
which creates new Intent and starts home activity with StartActivity.
I would like to have onZoomListener on my MapView.
The code below is what I have done. It registers if zoom buttons are
tapped. Since all new phones now supports pinch to zoom, this is
useless. Does anybody have idea how to do real onZoomListener? Thanks.
OnZoomListener listener = new
I had to subclass MapView and override dispatchDraw
Here is the code:
int oldZoomLevel=-1;
@Override
public void dispatchDraw(Canvas canvas) {
super.dispatchDraw(canvas);
if (getZoomLevel() != oldZoomLevel) {
I am working on an Android app that already exists on iPhone.
In the app, there is a Map activity that has (I counted) around 800
markers in four groups marked by drawable in four different colors.
Each group can be turned on or off. Information about markers I have
inside List. I create a
You are right about populate() calls. I've picked up implementation of
ItemizedOverlay from some online example and didn't question its
validity. Now, when I pay attention, It makes sense what you said.
The posted code is run only when user touch an option to do so.
Thanks a lot TreKing...
--
Kostya, I tried to do as you suggested. and non of it worked.
1) Don't want to add my header view into list's parent. It simply
doesn't achieve what I want to do.
I would like to add it to the parent that holds list view items. I
have parent available in adapter's GetView method. When I tried to
Thanks, I tried this. I got ClassCastException when
adapter.notifyDataSetChanged() was executed.
Thanks anyway.
--
You received this message because you are subscribed to the Google
Groups Android Developers group.
To post to this group, send email to android-developers@googlegroups.com
To
I would like to add Top Margin on the first item in the ListView. Is
that possible? Or, how can I reference first list item in the List
View?
I tried
lv = (ListView)getListView();
View myRowItem = lv.getChildAt(0);
This probably doesn't work because at the moment I executed it, list
items
Can you please explain how to add topMargin to listView item at
position 0?
For example, I can add topPadding on first item using parameter
position. Test if position is equal 0, add padding, if not, remove
padding. (I sort of not like this, but it seems it is the only way)
The thing is, I cannot
a header view. In that
case, set android:paddingBottom on the header view.
-- Kostya
14.12.2010 20:27, bobetko пишет:
I would like to add Top Margin on the first item in the ListView. Is
that possible? Or, how can I reference first list item in the List
View?
I tried
lv
Here is my GetView method.
public View getView(int position, View convertView, ViewGroup parent)
{
LinearLayout.LayoutParams lp = new LinearLayout.LayoutParams(
LayoutParams.WRAP_CONTENT,
LayoutParams.WRAP_CONTENT);
lp.topMargin =
Is it gone or actually it never appeared because it was not approved.
Is there some moderation process behind the scene? If it is, I would
love to be let known that my question is thrown into junk.
This is really annoying. It happened to me before.
I actually thought I was drunk or so, so maybe I
Groups doesn't find the message:
http://groups.google.com/group/android-developers
-- Kostya
12.12.2010 18:13, bobetko пишет:
Is it gone or actually it never appeared because it was not approved.
Is there some moderation process behind the scene? If it is, I would
love to be let known
I thought about that. But, then another question come to my mind.
Why wouldn't I always use SharedPreferences to save my activity state?
For example:
I passed groupID and itemID values into activity. In onCreate, I save
both values to SharedPreferences.
Latter, when activity is restarted (for any
Thanks Dianne,
I've look at logs and my app is crashing because my RowID value is
null. RowID is record ID that is needed to query sqlite database.
I could post here all my code, but I doubt it would be very useful...
I'll try explaining better with some code snippets:
This is what I execute
Sorry. Yes. You are right. onCreate runs first, then onResume next. (I
am still learning about Android activity cycle :-)
Here is my onResume method that handle this data that comes from
Twitter.
See lines 5 and 6. If 6 is true I am extracting token and secret and
saving them to SharedPreferences.
In my app at some point I am making oAuth request to authorize user
with Twitter. App opens WebView in which user enter his credentials.
Upon user pressing Allow button, twitter sends Intent (which
contains token and secret) back to my app so user can start when he/
she left of. The problem is my
I have added a view to the header of my ListView by following way:
ListView lv = (ListView)getListView();
View TopSearch = (View) View.inflate(this, R.layout.search,
null);
lv.addHeaderView(TopSearch, null, false);
And everything is fine until I make changes to data
Here it is:
12-10 11:35:28.111: ERROR/AndroidRuntime(25364): FATAL EXCEPTION: main
12-10 11:35:28.111: ERROR/AndroidRuntime(25364):
java.lang.ClassCastException: android.widget.HeaderViewListAdapter
12-10 11:35:28.111: ERROR/AndroidRuntime(25364): at
, the code doesn't produce any error if I comment 2
lines where I add header view.
Thanks,
On Dec 10, 11:42 am, TreKing treking...@gmail.com wrote:
On Fri, Dec 10, 2010 at 10:37 AM, bobetko bobe...@gmail.com wrote:
Any suggestions?
When do you set your adapter
line 130 is this:
((Filterable) adapter).getFilter().filter(s);
--
You received this message because you are subscribed to the Google
Groups Android Developers group.
To post to this group, send email to android-developers@googlegroups.com
To unsubscribe from this group, send email to
I call setHeaderView in onCreate, before I set myAdapter.
--
You received this message because you are subscribed to the Google
Groups Android Developers group.
To post to this group, send email to android-developers@googlegroups.com
To unsubscribe from this group, send email to
Yes. myAdapter implements Fliterable
--
You received this message because you are subscribed to the Google
Groups Android Developers group.
To post to this group, send email to android-developers@googlegroups.com
To unsubscribe from this group, send email to
Thank you very much Kostya.
--
You received this message because you are subscribed to the Google
Groups Android Developers group.
To post to this group, send email to android-developers@googlegroups.com
To unsubscribe from this group, send email to
I don't understand why this peace of code is not working. OnlyDelete
and Return keys are detected. Listener doesn't fire for any other key.
My device is Nexus One.
I tried to override activity's OnKeyDown method and that's even worse.
The only detected button was hardware back button.
I am
The server app was written for iPhone witch maybe handle some things
differently. As a message terminator server app author used OK
sequence (I will ask him why), so I definitely couldn't use
readLine(). It turned out there was more then one problem. In line 4,
I had to replace all characters
Yes, my ELV is backed by BaseExpandableListAdapter.
I had this code in my app:
ListView lv;
lv = getExpandableListView();
This worked, but I was not able to see all available methods for
myExpandableListView.
Thanks a lot.
--
You received this message because you are subscribed to the Google
I am trying to write client for Android which is supposed to
communicate with PC server application on local network.
Server app is written by my friend in C#. Currently there is an iPhone
app that is using this server application with no problems.
I have very simple code for TCP client:
1.
And one more thing,
Encoding.UTF8 is used. Not sure if that might be important.
--
You received this message because you are subscribed to the Google
Groups Android Developers group.
To post to this group, send email to android-developers@googlegroups.com
To unsubscribe from this group, send
I tried:
input.read();
I also tried to read Reader the same way:
Reader in = new InputStreamReader(s.getInputStream());
in.read();
Out of desperation I tried to recompile to 2.2 (now is 2.1).
--
You received this message because you are subscribed to the Google
Groups Android Developers group.
In my app I have nice ExpandableListView. I would like sometime,
depending of situation, to expand some or all groups.
I would also like to be able to remove/hide groups, expand all and
basically have (visually) ExpandableListView without groups.
I looked at all available methods for
I have ScrollView with RelativeLayout as a child of ScrollView.
I am trying through JAVA code to set Layout_Gravity to CENTER so my
RelativeLayout is centered (horizontally and vertically) in the middle
of ScrollView (that covers whole screen). This works fine in XML and
produces desired result,
I will reply to myself on this one...
I learned that if I set my list's layout_height to WRAP_CONTENT, the
problem is no more. Wonder why?
--
You received this message because you are subscribed to the Google
Groups Android Developers group.
To post to this group, send email to
I tried another approach. I defined my RelativeLayout in XML exactly
the way I liked it. Then I used inflater and dynamically added my
RelativeLayout to ScrollView
It didn't work. It simply ignored all my XML settings. For example,
it fully filled the parent (ScrollView) even though I explicitly
I wouldn't bet my life on this, but I think in Android case, carriers
are those who take 30%, not Google. So, that's why I think Google
doesn't care about all these new Android Markets.
--
You received this message because you are subscribed to the Google
Groups Android Developers group.
To post
Not sure I understand. My RelativeLayout is enclosed in ScrollView and
ScrollView doesn't have gravity property.
--
You received this message because you are subscribed to the Google
Groups Android Developers group.
To post to this group, send email to android-developers@googlegroups.com
To
Thank You Kostya,
I did as you said and it works. Here is what I have done:
RelativeLayout myRelativeLayout = new RelativeLayout(this);
myRelativeLayout.setGravity(Gravity.CENTER_HORIZONTAL);
ScrollView.LayoutParams myRelativeLayoutParams = new
ScrollView.LayoutParams(
I am using setViewValue method of ShowViewBinder to access image
inside row of listView.
The idea is to load image from internet and display it inside row of
listView.
To load image, I am starting new image loader thread, but what I
discovered when debugging this code, for each row I am actually
I am trying to place my custom map (overlay) over Google map.
For example, my MapView will be positioned to look at some building. I
want to load custom image(s) that will show building's floor plan.
Want to be able to pan and zoom, and place markers (for example, Room
1, Room 2, etc...), in other
I was hoping to use MapView in my application. It seems I will have to
come up with something else. Thanks for quick reply.
--
You received this message because you are subscribed to the Google
Groups Android Developers group.
To post to this group, send email to
I am using example for creating custom dialogs on dev.android.com.
See code below.
The problem is that second line is crashing application (fore close)
## Context mContext = getApplicationContext();
I can make dialog to work if I replace line with
## Context mContext = this;
My
43 matches
Mail list logo