[android-developers] Digest for android-developers@googlegroups.com - 25 Messages in 19 Topics

Group: http://groups.google.com/group/android-developers/topics

    Paul <pmmenneg@gmail.com> Jan 31 12:48PM -0800 ^
    It looks like Android is still using the default color state list for
    the button. I've never used a state list for a button, but maybe
    capturing the android:state_selected state might help?


    DulcetTone <dulcettone@gmail.com> Jan 31 12:13PM -0800 ^
    I tried using this with id=0, and no icon was placed in the status
    I switched to using a string resource ID and it worked.
    The documentation for the notification system seems to welcome us to
    use any value unique to our app.


    TreKing <trekingapp@gmail.com> Jan 31 02:40PM -0600 ^

    > I tried using this with id=0, and no icon was placed in the status bar.
    > I switched to using a string resource ID and it worked.
    You didn't change anything else? I use 0 as an ID just fine.
    > The documentation for the notification system seems to welcome us to use
    > any value unique to our app.
    TreKing <http://sites.google.com/site/rezmobileapps/treking> - Chicago
    transit tracking app for Android-powered devices


    Paul <pmmenneg@gmail.com> Jan 31 12:35PM -0800 ^
    You might also be able to scroll the text by restricting the ellipsize
    the text by setting properties of the TextView to:
    I do this with an EditText and it works perfectly.


    Streets Of Boston <flyingdutchie@gmail.com> Jan 31 07:59AM -0800 ^
    Hi Dianne,
    I haven't made an apk yet (i can't send you our entire app, my boss
    would kill me :-)), but when i do send the apk-sample, where do i send
    it? To your e-mail address?
    On Jan 29, 10:23 pm, Streets Of Boston <flyingdutc...@gmail.com>


    Dianne Hackborn <hackbod@android.com> Jan 31 11:20AM -0800 ^
    Yeah just send it to me e-mail address. Thanks!
    On Mon, Jan 31, 2011 at 7:59 AM, Streets Of Boston
    Dianne Hackborn
    Android framework engineer
    Note: please don't send private questions to me, as I don't have time to
    provide private support, and so won't reply to such e-mails. All such
    questions should be posted on public forums, where I and others can see and
    answer them.


    Streets Of Boston <flyingdutchie@gmail.com> Jan 31 12:30PM -0800 ^
    Email is on its way.
    Thank you!


    TreKing <trekingapp@gmail.com> Jan 31 11:59AM -0600 ^

    > I assumed a problem with the installation and asked the user to
    > uninstall and reinstall a new compilation I sent him; no change.
    Did you get more information like Phone model and android version? I
    wouldn't be surprised if this is a side-effect of a custom rom - especially
    when it's a lone user reporting it.
    Besides that, I would try just replacing your function call with the
    contents of the function itself and log everything: including the current
    value of "this", as crazy as it sounds.
    TreKing <http://sites.google.com/site/rezmobileapps/treking> - Chicago
    transit tracking app for Android-powered devices


    TomTasche <tomtasche@gmail.com> Jan 31 10:11AM -0800 ^
    One of my users reported something similar a few months ago and told
    me it was due to bad permissions. Maybe your user should try to
    uninstall and install the app again.
    Good luck


    TreKing <trekingapp@gmail.com> Jan 31 12:23PM -0600 ^

    > Maybe your user should try to uninstall and install the app again.
    On Mon, Jan 31, 2011 at 3:59 AM, mot12 <martin.hunke@gmail.com> wrote:
    TreKing <http://sites.google.com/site/rezmobileapps/treking> - Chicago
    transit tracking app for Android-powered devices


    mot12 <martin.hunke@gmail.com> Jan 31 12:18PM -0800 ^
    Thanks for the input.
    This guy has a G1 with standard Android 1.6. If he had a custom ROM, I
    would not waste time debugging it.
    However, you both bring up something interesting here: custom ROMs and
    permissions. I have two other users with two different custom ROMs and
    my app can't save anything in shared_prefs on those phones. The app
    doesn't crash but the settings file in /data/data/<package>/
    shared_prefs never gets written.
    Seems unrelated until they reported that the same code worked fine
    with my com....gentlealarmbeta packer, it just doesn't work with the
    com.....gentlealarm package.
    Uninstall and reinstall have not been fruitful. I wonder if after
    uninstallation there's any trace left of the app that I could manually
    @TreKing: That seems like a worthwhile attempt. I will report back
    what I find. Thanks.


    H <me@howardb.com> Jan 31 10:40AM -0800 ^
    My desktop doesn't have wireless or any other network other than the one
    ethernet cable. I also run rrdtool on my pc so can confirm that the ethernet
    connection is constantly active and online. So although Varun's issue may
    have been triggered by the wireless swapping over, I think there is still a
    genuine underlying issue.


    TjerkW <tjerkw@gmail.com> Jan 31 10:27AM -0800 ^
    @davemac could you share your copy somehow? A lot of people cannot
    test against honeycomb now.


    Pent <tasker@dinglisch.net> Jan 31 10:02AM -0800 ^
    > I just discovered that removing theNexusSbattery for about a minute
    > is enough to restore theUSBfunctionality.  (Compared to swapping
    > phones at BestBuy, removing the battery is a great convenience. :*)
    Thanks for the battery tip.
    I just got an S and had the 'where's the USB gone' problem straight
    out of the box
    (and after the charge naturally...)
    Nothing registered by the linux kernel at all, though the phone showed
    Fixed by battery pull-out, hope it's not going to happen much it's a
    bit tricky getting the cover off the S I think.


    saex <elpablosaez@gmail.com> Jan 31 10:02AM -0800 ^
    0 down vote favorite
    i'm encodding images with Base64 into Strings, and i am uploading
    these images into a remote database, in a row of the table USER. That
    row is TEXT, because i dont know if there is anothr String type with
    more space than TEXT.
    When i store very small images, with 5 or 10 KB of space, they store
    OK, and when i get these images back from the sql DB into my app, i
    can decode them into BitMap and show them into a ImageView.
    THE PROBLEM: When i store images with for example 110 KB of space, i
    think they doesn't store OK in the TEXT row of my table USER in the
    SQL DB, because when i try to decode them, i got an error, they can't
    be decoded, but i dont know why, because the decode function of Base64
    simply returns null when he can't decode.
    There is a way to solve it?
    How munch KB can have a image to be stored into the row of a databse?
    The better option for the row is to be TEXT ? or there is another Type
    that can store more higher Strings?


    TreKing <trekingapp@gmail.com> Jan 31 12:01PM -0600 ^

    > I get a Runtime exception when my wait lock gets expired
    And the runtime exception thrown and the stack trace is what exactly?
    TreKing <http://sites.google.com/site/rezmobileapps/treking> - Chicago
    transit tracking app for Android-powered devices


    TreKing <trekingapp@gmail.com> Jan 31 11:56AM -0600 ^

    > I developed an application using Phonegap for Multiple screen support
    > Problem: for multiple screen support how to make a common css file.
    Try asking on Phonegap's forums (if they have any) or other groups dedicated
    to that utility.
    TreKing <http://sites.google.com/site/rezmobileapps/treking> - Chicago
    transit tracking app for Android-powered devices


    "A. Elk" <lancaster.dambusters@gmail.com> Jan 31 09:15AM -0800 ^
    You might use Monkey to test that your app handles only certain
    keystrokes, handles only keystrokes sent in a certain order, and
    doesn't crash if it gets anything else. For touch events, you could
    use it to test that random touches or gestures don't do something
    unexpected in your application. As the Dev Guide topic says, Monkey is
    for "stress-testing" your application.
    MonkeyRunner provides limited scripting and control capabilities, so
    that you can write Python scripts to run test suites. The Froyo Dev
    Guide describes MonkeyRunner in some detail. You have to know Python
    in order to use it. You can send keystrokes and touch events to
    control the UI, but to send touch events you have to know the screen
    coordinates where you want the touch to occur. That means that you'll
    need to do some work by hand first, to figure out those coordinates.
    As far as I know, MonkeyRunner can't do gestures.
    Robotium is in Java only. It's like JUnit. You write something that
    looks like a Java program. The Robotium runner interprets it as a
    sequence of steps to run. There's documentation online; you should
    Google "Robotium".
    Suspend/restart could mean many things. You may or may not be able to
    test those functions automatically. In general, you can't easily test
    something that requires turning off the device.
    File copying from the network could be done in MonkeyRunner. It really
    depends on what you're trying to do. Since MonkeyRunner is essentially
    a Python module, you can write any Python program you want and add
    MonkeyRunner to it. Python can do just about anything you can think
    Python can accept user input.
    Unfortunately, I don't have the time to teach you Python or Java. This
    forum really isn't appropriate for that.


    lou <louis.coquio@wopata.com> Jan 31 09:04AM -0800 ^
    Hi !
    I'm trying to insert an image in my application.
    This image don't cover all the screen, so I have to scale it.
    My problem :
    I want the picture to cover the all screen, stay scaled and be cropped
    at the right of the screen. Consequently we don't see the right part
    of the picture.
    It looks like a "rightCrop" ( or an "alignLeft" ).
    I tried "center", but the picture is too short and don't cover the
    entire screen, and the other scaling mode don't seems to resolve this
    How can I do that, please ?
    Thanks a lot.


    saex <elpablosaez@gmail.com> Jan 31 08:58AM -0800 ^
    i am picking images on my app with android, and showing them on a
    ImageView of my layout, and sometimes i got an exception
    `java.lang.OutOfMemoryError: bitmap size exceeds VM budget`. This
    happens when the photos are higher than 500kb.
    then, what i want to do is to allow the user only to select photos of
    maximum 500kb. And if the user selects a photo Higher than 500kb,
    then, my app should show a toast telling the user that only can select
    photos of max 500kb.... ¿how to do it?
    this is my code:
    changeImageButton.setOnClickListener(new OnClickListener() {
    public void onClick(View v) {
    Intent i = new Intent(Intent.ACTION_PICK,

    startActivityForResult(i, ACTIVITY_SELECT_IMAGE);
    protected void onActivityResult(int requestCode, int resultCode,
    Intent imageReturnedIntent) {
    super.onActivityResult(requestCode, resultCode,
    switch(requestCode) {
    case 1:
    if(resultCode == RESULT_OK){
    Uri selectedImage = imageReturnedIntent.getData();
    String[] filePathColumn =
    Cursor cursor =
    getContentResolver().query(selectedImage, filePathColumn, null, null,
    int columnIndex =
    String filePath = cursor.getString(columnIndex);
    selectedPhoto =

    80, 80, false));
    profileImage is a ImageView of my layout. and i use scaled butmap to
    resice the image to 80x80
    please give me some help to do that, im searching on google and i
    can't find nothing


    webmonkey <webmonkey18@gmail.com> Jan 31 08:39AM -0800 ^
    Just as I suspected there is a bug in Honeycomb that allows me to work
    around not having a setHasAlpha function.
    Using the new inMutable option in BitmapFactory.Options I can decode a
    dummy JPG and because it is a JPG the opaque hint is set. Now whatever
    set function you call on the bitmap, the opaque flag is never cleared
    and so it optimizes the drawing. It is rather silly though that I have
    to do it this way.
    I also wonder how the Android team is going to fix the actual "bug" in
    Honeycomb. There are four ways as I see it:
    1) When inMutable is set it always clears the opaque hint. This would
    be dumb because it assumes the worst case scenario.
    2) For every set function check if it has transparent values so it can
    clear the opaque flag. Lots of work and not very fast
    3) Add a XRGB_8888 Config. Not sure what kind of work is involved
    4) Make the setHasAlpha public. This would be the easiest
    solution :-)


    Ajmer Singh <ajmersingh09@gmail.com> Jan 31 09:13PM +0530 ^
    Hi All,
    I am working on the app which require me to add effects to an image taken
    from camera.Please any body let me know how can to get started for this
    particular requirement.Is there any library to do so.
    Thanks and Regards
    Ajmer Singh


    TreKing <trekingapp@gmail.com> Jan 31 09:20AM -0600 ^

    > An activity can restrict to portrait view. But how do i restrict a
    > wallpaper from being displayed in landscape mode (?)
    I don't know, may not be possible.
    > So, I would like it not to be displayed on devices supporting landscape
    > mode on home screen, and those are mainly with the devices with hard
    > keyboard support.
    Why not make your wallpaper adapt to support landscape? You're cutting out A
    LOT of users for what on the surface appears to a minimal problem.
    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
For more options, visit this group at

No comments:

Post a Comment