[android-developers] Digest for android-developers@googlegroups.com - 16 Messages in 12 Topics

Comments: (0)

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

    Moutaz Alazab <azabkont@gmail.com> Oct 01 10:49AM +1000  

    Hello Everyone,
     
    Is there any automatic method for downloading Android applications from
    Google market directly to my PC, I want to do some static analysis on them?
     
    I need to collect a large dataset for some research.
     
    Many thank you in advance for explanation.

     

    bob <bob@coolfone.net> Sep 30 04:44PM -0700  

    I saw this in styles.xml:
     
    <item name="android:background">?android:attr/editTextBackground</item>
     
    Is there a way to figure out exactly what ?android:attr/editTextBackground
    is?
     
    Is that a nine-patch somewhere?
     
    Thanks.

     

    TreKing <trekingapp@gmail.com> Sep 30 04:47PM -0500  


    > i have attached the sample picture any idea how to create that .
    > i want to add text inside button image dynamically .
     
     
    That's just a TextView with a custom, stretchable background. Look up PNG9.
     
    -------------------------------------------------------------------------------------------------
    TreKing <http://sites.google.com/site/rezmobileapps/treking> - Chicago
    transit tracking app for Android-powered devices

     

    TimeManx <shubhadeepc@gmail.com> Sep 30 11:19AM -0700  

    I'm having a very hard time figuring this out. I'm using a SurfaceView to display the camera preview using camera.setPreviewDisplay(surfaceview).
     
    But I can't figure out how to get the frame rate. I've tried using the Camera.PreviewCallback interface but it seems it's onPreviewCallback() method calls lag behind the actual preview. In other words, even with a smooth preview I only get about 15 calls to onPreviewCallback().
     
    Is there any way to get the frame rate directly from the camera? Maybe there's an NDK solution?

     

    Piren <gpiren@gmail.com> Sep 29 11:53PM -0700  

    As far as i know, it's not the device, it's the OS. It fails on 4.2 and
    above.
     
    On Sunday, September 29, 2013 8:25:40 PM UTC+3, Harri Smått wrote:

     

    elio <elio.francesconi@gmail.com> Sep 30 09:24AM -0700  

    Thanks guys,
    I confirm Nexus 4 is the only one with version 4.3 installed.
    On Monday, September 30, 2013 8:53:16 AM UTC+2, Piren wrote:

     

    Larry Meadors <larry.meadors@gmail.com> Sep 30 09:07AM -0600  

    Ahoj Honza,
     
    Yes - sorry for not posting an eventual resolution here.
     
    For me, the simple change that made it work was replacing "http://"
    with "widevine://" in the URL to stream.
     
    So instead of "http://blah.com/foo.wmv", try "widevine://blah.com/foo.wmv".
     
    Larry
     

     

    TobyKaos <aubrun.thibaut@chaos-interactive.com> Sep 30 06:56AM -0700  

    Hello,
     
    I read in doc that we cannot reuse product ID. But even if we delete
    product and recreate it with a differente product type?

     

    "A.F." <trikkuz@gmail.com> Sep 30 03:08AM -0700  

    Some month ago an user wrote a comment on play store for my app. It says it
    doesn't work anymore in his city.
    I replied politely that there apparently were no problems for his city, and
    I ask him to give more infos.
     
    Now he changes his mind, and wrote "great app!". So, how can I remove my
    reply? It doesn't make any sense...
    I can only change it, but it seems there's no way to remove.

     

    Piren <gpiren@gmail.com> Sep 30 06:56AM -0700  

    Change it to say thanks :)
     
    On Monday, September 30, 2013 1:08:17 PM UTC+3, A.F. wrote:

     

    Kostya Vasilyev <kmansoft@gmail.com> Sep 30 01:02PM +0400  

    Just to follow up: building the query myself didn't help.
     
    android.database.sqlite.SQLiteException: no such table: me (code 1): ,
    while compiling: SELECT _id, generation, [snip], op_hide, misc_flags
    *FROM me age WHERE* folder_id = ? AND [condition here]
     
    The query string is built in my Java code, and then passed to db.rawQuery.
     
    The "FROM me age WHERE" reads "FROM message WHERE" at that time, then
    apparently gets corrupted inside system code, again, just in a slightly
    different place.
     
    I still don't know what makes this one query more special than the others,
    oh well.
     
    -- K
     
     
     
    2013/9/29 Kostya Vasilyev <kmansoft@gmail.com>
     

     

    Piren <gpiren@gmail.com> Sep 30 06:56AM -0700  

    bizarre... seems like you should file a bug report.
     
    On Monday, September 30, 2013 12:02:31 PM UTC+3, Kostya Vasilyev wrote:

     

    "A.F." <trikkuz@gmail.com> Sep 30 03:15AM -0700  

    I guess you have to create widget using the right context.
     
    I use a ContextThemeWrapper to show a dark popup also if app has a light
    theme:
     
    popupContext = new ContextThemeWrapper(this, R.style.AppThemeDark);
    AlertDialog.Builder b = new AlertDialog.Builder(popupContext);
    ...
    ...
    ...
    b.show();
     
     
    Il giorno domenica 29 settembre 2013 05:56:15 UTC+2, bob ha scritto:

     

    Alexander Osmanov <alex.osmanov.88@gmail.com> Sep 30 12:15PM +0400  

    Thank you guys for your replies. I still have no clear understanding of how
    to handle this problem more efficiently but at least now I am sure it's not
    entirely myself missing something important.
     
    Still I refuse to believe there is no one that ever faced the same problem
    in android developers world, so I would really appreciate if someone anyone
    described how they managed to handle it gracefully. I also have a question
    with 100 rep bounty on SO:
    http://stackoverflow.com/questions/18899870/android-appengine-endpoints-auth-and-inapp-billing
    just
    in case.
     
     
     
    --
    Best regards,
    AlexO

     

    Piren <gpiren@gmail.com> Sep 30 12:20AM -0700  

    onDraw should be the proper indicator of when you should update your view
    (though it will be called for any update to your view, not only just when
    the background changes).
    I'm not sure there's even a way to distinguish who's "responsible" for the
    refresh - your own changes or background changes.
     
    You can however try to figure out yourself if the background changed enough
    to warrant an update - compare the previous background image to the
    current, you can allow some percentage of acceptable difference between the
    images to lower the amount of times you call renderscript.
     
    On Sunday, September 29, 2013 5:26:42 PM UTC+3, Harri Smått wrote:

     

--
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+unsubscribe@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 unsubscribe from this group and stop receiving emails from it, send an email to android-developers+unsubscribe@googlegroups.com.
For more options, visit https://groups.google.com/groups/opt_out.

[android-developers] Digest for android-developers@googlegroups.com - 18 Messages in 10 Topics

Comments: (0)

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

    Alexander Osmanov <alex.osmanov.88@gmail.com> Sep 29 11:40AM -0700  

    Kj, I did a research today, published my app through alpha testing on
    Google Play and tried downloading it using several accounts. I can confirm
    that IAB is NOT limited to primary Google account. Whichever account I use
    for downloading the app from Google play is then used for IAB.
     
    On Saturday, September 28, 2013 5:41:45 PM UTC+4, kj wrote:

     

    kj <scweeden@gmail.com> Sep 29 12:26PM -0700  

    Weird, I didn't realize that the Google Play downloading account would be
    used, although this makes sense. Ultimately though the user making the
    purchase isn't configurable by your app since you'll be stuck with the
    downloading Google account anyway.
     
    On Sunday, September 29, 2013 2:40:11 PM UTC-4, Alexander Osmanov wrote:

     

    Alexander Osmanov <alex.osmanov.88@gmail.com> Sep 29 12:44PM -0700  

    Yes, that is my problem if I want to bind server side to Google account. I
    can't rely on first account being the one I should use and I don't think
    that something like showing an account picker and saying "choose the
    account you used for purchasing blah blah to create blah blah" is a good
    idea. Users still will be able to choose another account and don't have it
    on other device with all the consequences. That's why I'm so confused. If
    only there was a way to know for sure which account is used for IAB.
     
    On Sunday, September 29, 2013 11:26:29 PM UTC+4, kj wrote:

     

    kj <scweeden@gmail.com> Sep 29 03:56PM -0700  

    The Google IAB dialog has the Google account name that will be associated
    with the purchase. In-app purchases are generally understood to be tied to
    your Google account and apps you download/purchase are associated with the
    account used in Google play. You could force your users to create user
    accounts with your service if you want to avoid this kind of Google
    associated purchasing altogether, but you are going to have a bit more
    friction for new users. You can just auto generate accounts for your app
    and associate purchases with said auto generated account, that way
    purchases are unique to a device rather than something that a user can take
    with them to a new device. Other than that, those are the only real
    options. If you need more explicit guaruntees of user behavior, force them
    to make accounts. If you don't need that, it is OK to use the current
    Google account.
     
    On Sunday, September 29, 2013 3:44:34 PM UTC-4, Alexander Osmanov wrote:

     

    Nikolay Elenkov <nikolay.elenkov@gmail.com> Sep 30 10:48AM +0900  

    >...
    > ... If you need more explicit guaruntees of user behavior, force them to make
    > accounts.
     
    Your point being? Letting the developer know what account the user used to
    buy an IAB item, etc. is genuinely useful. It has been requested countless
    times, but the it's not part of the API. 'Force them to make accounts' is
    hardly user friendly and is really BS in a world where people are used to
    simply using their Google/FB, etc. account. Additionally Google is aggressively
    pushing OAuth and more specifically G+ accounts for *everything* now, so
    forcing people to create a bunch of throw-away accounts just to
    compensate for the limitations of the IAB API is not only bad advice, it also
    goes against even Google's policy. And BTW, what exactly is 'the current
    Google account'?

     

    kj <scweeden@gmail.com> Sep 29 07:26PM -0700  

    I'm not saying that getting the Google account name via the API wouldn't be
    useful, but unfortunately that doesn't exist right now. I agree that
    forcing accounts is not user friendly and probably isn't a good idea for
    the majority of apps, but it is an option that may be considered. Sticking
    with the default IAB model of purchases being tied to the Google account
    that downloaded the app works for most cases and users have a reasonable
    expectation of how that will work.
     
    What I meant by current Google account is what Alexander mentioned
    previously, that the Google account making the purchase is the one that
    downloaded the app from the Play store.
     
    On Sunday, September 29, 2013 9:48:18 PM UTC-4, Nikolay Elenkov wrote:

     

    Amit Mangal <forum.amit.mangal@gmail.com> Sep 30 01:49AM +0530  

    Hi Team,
     
    hope you all are doing good.
    i want to create a button with one image in background and one inside
    button and want to write small text on that.
     
    i have attached the sample picture any idea how to create that .
    i want to add text inside button image dynamically .
     
    thanks

     

    tarun sablok <tarun.sablok@gmail.com> Sep 29 12:36PM +0530  

    There should be one column in your database which should be named *_id* ,
    its common error !!!
     
     

     

    Piren <gpiren@gmail.com> Sep 29 01:26AM -0700  

    never came across such a report, but if it's isolated to that specific
    query maybe try replacing it with a rawQuery instead and see if it makes a
    difference.
     
    On Sunday, September 29, 2013 1:05:26 AM UTC+3, Kostya Vasilyev wrote:

     

    Kostya Vasilyev <kmansoft@gmail.com> Sep 29 11:14PM +0400  

    Yes, that's what just did in a dev build, will see it helps.
     
    Curiously enough, the framework's SQLiteQueryBuilder uses a StringBuilder
    that is initially 120 chars long, and the corruption happens at 112'th
    character.
     
    I've long anticipated an Android device with firmware that calculates 2+2
    as 5... this is not quite it, but comes pretty close.
     
    -- K
     
     
     
    2013/9/29 Piren <gpiren@gmail.com>
     

     

    Dev Droid <jitesh.dedhiya@gmail.com> Sep 29 11:45AM -0700  

    @Frank LoVecchio Can you share the code please how did you did uploaded to
    s3 using multipart please ?
     
    On Friday, March 18, 2011 9:34:52 PM UTC+5:30, Frank LoVecchio wrote:

     

    Robert Greenwalt <rgreenwalt@google.com> Sep 29 11:06AM -0700  

    We have contacts with many of the carriers and I had them ask Sprint about
    this.
     
     

     

    elio francesconi <elio.francesconi@gmail.com> Sep 29 07:06PM +0200  

    Hi all,
     
    I wrote an application it controls dynamically the AIRPLANE_MODE, this is
    the piece of code:
     
    *
    // toggle airplane mode
    android.provider.Settings.System.putInt(
    mContext.getContentResolver(),
    android.provider.Settings.System.AIRPLANE_MODE_ON, on ? 1 : 0);
    // Post an intent to reload
    Intent intent = new Intent(Intent.ACTION_AIRPLANE_MODE_CHANGED);
    intent.putExtra("state", on);
    mContext.sendBroadcast(intent);
    *
     
    I noticed a call stack exception on Nexus 4 only,
     
    Full Stack Trace:
     
    java.lang.SecurityException
    android.os.Parcel.readException(Parcel.java:1431)
    android.os.Parcel.readException(Parcel.java:1385)
    android.app.ActivityManagerProxy.broadcastIntent(ActivityManagerNative.java:2224)
    android.app.ContextImpl.sendBroadcast(ContextImpl.java:1046)
    android.content.ContextWrapper.sendBroadcast(ContextWrapper.java:344)
     
    Have you experience on such kind of exceptions?
     
    Thanks
     
    Elio

     

    "Harri Smått" <harism@gmail.com> Sep 29 06:25PM +0100  

    Hi,
     
    I would be more interested why other devices you've ran this code on (?)
    have not caused similar exception. According to docs
    Intent.ACTION_AIRPLANE_MODE_CHANGED should be protected for system usage
    only.
     
    --
    Harri
     
     
    On Sun, Sep 29, 2013 at 6:06 PM, elio francesconi <

     

    "Harri Smått" <harism@gmail.com> Sep 29 03:26PM +0100  

    Hello All,
     
    I'm in the midst of implementing somewhat dynamic background blur effect
    for Android (similar to what iOS7 has) and I'm keen to have this one
    optimisation in place.
     
    In my implementation I'm trying to achieve following:
     
    1. I extend default layout classes and call them blur layouts
     
    2. When view contents below blur layout in the view tree changes, I render
    what ever content there is into scaled offscreen bitmap (this is the part
    needing optimisation)
     
    3. Blur is applied on offscreen bitmap using RenderScript implementation of
    stack blur
     
    4. From then on the blur layout draws this blurred image as it's background
     
    Now.. Currently.. I'm using ViewTreeObserver to determine when current
    screen is about to update (OnPreDrawListener) but this doesn't give me any
    indication whether content below my layout has changed. It's triggered no
    matter what update happens on the screen and though I'm recreating the blur
    image way too often - also in cases content below hasn't changed.
     
    It would be great if someone with better knowledge on Android drawing
    internals could help me out on this one. Say, if my layout occupies
    Rect(100, 100, 200, 200) on the screen, I would like to observe in this
    layout when content below within it's area has changed. Or is this even
    possible?
     
    For interested ones current implementation can be found here:
    https://github.com/harism/android_anndblur
     
    And precompiled application should appear in Play Market at some point.
     
    --
    Harri

     

    Joan Pujol <joanpujol@gmail.com> Sep 29 02:41AM -0700  

    Hi,
     
    Has someone had problem with the migration from financial data from the
    last system to wallet?
    For me the bank data and tax data was corrupted and I had to enter it
    again. I was able to enter another time the bank data but I haven't been
    able to enter the tax data because the form doesn't work.
    I suppose that there is some corrupted data that makes the form crash an
    only a blank form appears and I'm not able to enter it.
     
    The problem with this is that I'm not able to receive the money and the
    google wallet support is a nightmare. We have interchanged more than 30
    mails and phone calls in the last two months and the response is always the
    same:
    Our engineers are looking into it...
     
    It's really a nightmare that a such important issue hadn't been solved in
    more than two months and as I didn't see any progress I have writen here to
    know if other people has the same problem.
     
    Some one had problems with data migration to wallet?
     
    Cheers,

     

    Piren <gpiren@gmail.com> Sep 29 01:25AM -0700  

    I've used both methods (webview and html textview) and found that both had
    their issues (especially with aligning images with text across screen
    sizes)... eventually nothing beats just doing it all using separate ui
    elements.
     
    On Saturday, September 28, 2013 3:02:54 AM UTC+3, Nathan wrote:

     

    Piren <gpiren@gmail.com> Sep 29 01:13AM -0700  

    check you didnt forget android:debuggable="true" in the manifest
     
    On Friday, September 27, 2013 3:00:22 PM UTC+3, Sadhna Upadhyay wrote:

     

--
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+unsubscribe@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 unsubscribe from this group and stop receiving emails from it, send an email to android-developers+unsubscribe@googlegroups.com.
For more options, visit https://groups.google.com/groups/opt_out.

[android-developers] Digest for android-developers@googlegroups.com - 11 Messages in 9 Topics

Comments: (0)

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

    bob <bob@coolfone.net> Sep 28 08:56PM -0700  

    Is there an easy way to have a widget take on the style of a theme other
    than the current one?
     
    For instance, maybe the current theme is Theme.Holo but you want a widget
    to look like Theme.Light.
     
    Thanks.

     

    Henrik Lindqvist <henrik.lindqvist@gmail.com> Sep 28 06:35PM -0700  

    In the Google I/O 2013 video presenting coming features for the Developer
    Console, Riccardo Govoni talks about Analytics for Google Play Store page
    view etc.:
     
    https://www.youtube.com/watch?feature=player_detailpage&v=SDaf7f9yl6E#t=1259
     
    When will this feature be launched?
     
    Do my app have to include the Google Analytics SDK?

     

    Kostya Vasilyev <kmansoft@gmail.com> Sep 29 02:05AM +0400  

    Hello,
     
    One of my users reports a crash like this:
     
    android.database.sqlite.SQLiteException: no such column: _id (code 1):
    , while compiling: SELECT _id, generation, flags, numeric_uid,
    body_main_size, body_main_fetched_size, body_alt_size, body_alt_fetc¤
    , search_token, op_flags, op_move_to_folder, op_hide, misc_flags
    FROM message WHERE folder_id = ? AND numeric_uid >= ? AND numeric_uid
    < ?
    at android.database.sqlite.SQLiteConnection.nativePrepareStatement(Native
    Method)
    at android.database.sqlite.SQLiteConnection.acquirePreparedStatement(SQLiteConnection.java:886)
    at android.database.sqlite.SQLiteConnection.executeForCursorWindow(SQLiteConnection.java:835)
    at android.database.sqlite.SQLiteSession.executeForCursorWindow(SQLiteSession.java:836)
    at android.database.sqlite.SQLiteQuery.fillWindow(SQLiteQuery.java:62)
    at android.database.sqlite.SQLiteCursor.fillWindow(SQLiteCursor.java:158)
    at android.database.sqlite.SQLiteCursor.getCount(SQLiteCursor.java:148)
    at android.database.AbstractCursor.moveToPosition(AbstractCursor.java:197)
    at android.database.AbstractCursor.moveToNext(AbstractCursor.java:245)
    at <my code here>
     
    Note the weird character in the middle of:
     
    "body_alt_fetc >>right here>>¤<<<<< , search_token".
     
    There are supposed to be a few more characters where this weird one is.
     
    My code here calls SQLiteDatabase.query with a String[] projection, a table
    name, a simple selection and its arguments, etc. All very basic stuff.
     
    The crash happens "once in a while", even though this query runs literally
    all the time. It's always this query, too, even though there are dozens
    more, for same table, and in same source file.
     
    It looks to me like a memory overwrite, presumably in native code ('cause
    it's pretty hard to overwrite something by accident on the Java side of
    things).
     
    Has anyone ran into this or a similar query corruption?
     
    The device is a Zopo 980, if that means anything.
     
    Thanks,
    -- K

     

    Sergio Panico <sergio.panico@gmail.com> Sep 28 01:08PM -0700  

    Hi all,
    I need your help to solve a question that hang my app's development.
     
    The problem is that I need to show in the status bar notification area an
    icon wider then the others. More in details, suppose my notification icon
    is 24x48, there is a way to avoid Android to makes the icon unreadable,
    stretching it to 12x24 (to fill the 24x24 standard icon placeholder)? In
    other words, there is a way to show a rectangular icon (wider than 24px)
    for an app's notification?
     
    Hope I succeed in explain myself and you can give me the right way.
     
    Thanks a lot
    Regards
    Sergio

     

    Simon Giddings <mr.s.giddings@gmail.com> Sep 28 11:45AM -0700  

    I am a bit confused here with this.
     
    With the examples that I have seen for using the Navigation Drawer, they
    all point to using one unique Activity, with Fragments giving the actual
    content.
    The advantage with this is that there is only one instance of the
    Navigation Drawer created.
     
    However, in my application, I have distinct Activities which have distinct
    tasks (and, yes, there are indeed more than three).
    Should I therefore be creating the same navigation drawer in each Activity ?
    It is obvious that I would like to be able to preserve my existing
    activities and not have to re-write them as fragments.
     
    My understanding is that fragments are not activities and activities are
    not fragments, are they ?
     
    Have I correctly understood this ?
    Can anyone give some advice here ?

     

    Simon Giddings <mr.s.giddings@gmail.com> Sep 28 09:51AM -0700  

    I would like to be able to use oversized icons within the Navigation Drawer
    listview items.
     
    However, I have seen that, even if I put larger icons in the resource
    directories, they are all scaled down.
    This is for working exclusively within a tablet application.
     
    Is there a way around this automatic re-scaling ?

     

    12169 <ashish.acet@gmail.com> Sep 28 07:27AM -0700  

    Hi,
     
    i use below code to make http connection.
     
    URL url = new URL(filePath);
    HttpURLConnection con = (HttpURLConnection) url.openConnection();
    con.setReadTimeout(10*1000);
    con.setConnectTimeout(10*1000);
     
    but when i use setReadTimeout and connectTimeout values then
    java.net.SocketTimeoutException: Transport endpoint is not connected

     

    Siva Kumar <j.sivakumar000@gmail.com> Sep 28 09:04PM +0530  

    1st u check there is network in it device.then type url in the device's web
    browser & check it
    > 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 unsubscribe from this group and stop receiving emails from it, send an
    email to android-developers+unsubscribe@googlegroups.com.

     

    kj <scweeden@gmail.com> Sep 28 06:41AM -0700  

    As others mentioned, IAB is limited to the primary Google account. Users
    that need truly separated user accounts will use the multi-user accounts
    options on Jelly Bean tablets, so their primary Google accounts will be
    different. This isn't confusing: when you make a purchase with a Google
    account, it is tied to that account. If your web app/service has its own
    user account system, tie that transaction to that user account at purchase
    time or later on when that Google user makes an account. Your app and
    webapp should provide a way to view the IAPs for accounts so the user knows
    what they have purchased.
     
    On Thursday, September 26, 2013 6:20:30 AM UTC-4, Alexander Osmanov wrote:

     

    Alexander Osmanov <alex.osmanov.88@gmail.com> Sep 28 07:08AM -0700  

    Thank you for your reply.
     
    Are you sure, IAB is really tied to the primary account? I was sure about
    that but this note in documentation confused me a lot:
     
    *Note*: To make test purchases, the license test account must be on the
    user's Android device. If the device has more than one account, the
    purchase will be made with the account that downloaded the app. If none of
    the accounts has downloaded the app, the purchase is made with the first
    account.Users can confirm the account that is making a purchase by
    expanding the purchase dialog.
     
    Here: http://developer.android.com/google/play/billing/billing_testing.html
     
    Thanks
     
    On Saturday, September 28, 2013 5:41:45 PM UTC+4, kj wrote:

     

    Gaurav Sharma <gauravsharma531@gmail.com> Sep 28 04:04PM +0530  

    @robert: How do you such information? have you faced this situation before
    or have they contacted you ?
     
     
     
    --
    Gaurav Sharma
    Bangalore

     

--
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+unsubscribe@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 unsubscribe from this group and stop receiving emails from it, send an email to android-developers+unsubscribe@googlegroups.com.
For more options, visit https://groups.google.com/groups/opt_out.

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

Comments: (0)

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

    Anirvan <anirvan.majumdar@gmail.com> Sep 27 06:42AM -0700  

    The question might appear a bit vague, so allow me to explain a bit.
     
    I'm part of a startup that is trying to build a way to set up an Android
    tutorial, whereby, users also get to build a proper, functioning app
    alongside. Unlike teaching web-based technologies, we can't emulate the
    experience of building an android app on the web.
     
    For this, we were hoping to create a stub project, which our users would
    download and then, we can devise ways to verify that users have correctly
    performed certain actions, by modifying the "Run Configuration". However,
    we haven't been able to find any useful hooks through which we can test for
    correctness.
     
    By *correctness*, I mean some basic tests, like whether the user properly
    created a list adapter, whether an edit box was created, whether the
    textview showed up, etc.
     
    At this point, I wanted to ask if there are any good approaches I can try?
    I thought of extending the ADT, or build a plugin for it. But that would be
    a significant effort, and I'd like to exhaust any other alternatives before
    diving into this.
     
    Thanks for reading!

     

    Kristopher Micinski <krismicinski@gmail.com> Sep 27 10:20AM -0400  

    So the obvious question that comes to mind is: why do you need to do
    this within Eclipse, rather than using an Android testing framework.
    Are you talking about whether or not the user *physically* created the
    code, rather than testing it actually worked?
     
    I would give a word of warning against trying to do things that
    require parsing with Eclipse: it would be a huge amount of work to do
    this, it's much larger than an extension to the ADT. (And, working
    with Eclipse's representation of java code is rather horrible.)
     
    Kris
     
     

     

    Anirvan <anirvan.majumdar@gmail.com> Sep 27 10:03AM -0700  

    Hello Kris,
     
    Appreciate your response.
     
    Even I have an inkling that trying to write some plugin might just end up
    being something *big*. However, what we need to establish is whether a
    particular user was able to follow our tutorial and do some basic
    application changes as part of our chapter exercises.
     
    So yes, we are trying to determine whether a user was able to correctly
    make *physical* code changes as part of a chapter's exercises.
     
    Consider it like, suppose you were preparing a tutorial on Javascript, and
    you wanted your tutorial to be interactive, you can have many ways to test
    whether the user is able to follow the instructions on her own. But that's
    not possible to do with Android through a web-based platform. At least not
    that I know of. So is their any way I could tell the user — go do this and
    this, and after that run your code. Now if it runs properly, we should be
    able to receive some signal through the build process, which indicates that
    the user did the right thing. And then, we let the user know whether she
    was successful with the last set of assignments.
     
    Any suggestions?
     
     
     
    On Friday, 27 September 2013 19:50:30 UTC+5:30, Kristopher Micinski wrote:

     

    Kristopher Micinski <krismicinski@gmail.com> Sep 27 01:59PM -0400  

    > able to receive some signal through the build process, which indicates that
    > the user did the right thing. And then, we let the user know whether she was
    > successful with the last set of assignments.
     
    What even is "the right thing?" Do they have to have the class named
    the correct thing, do they have to have some sort of functional
    behavior? Do they have to place the button on the screen in the right
    way?
     
    Ultimately, there are going to be an infinite number of ways to do the
    right thing, each valued slightly differently.
     
    Static analysis at the source level is extremely hard in Eclipse
    because it's a huge API that you have to tie yourself to pretty
    intimately. Whenever I parse Java source I actually use a compiler
    toolkit, because Eclipse's mechanisms are so hard to work with. In
    any case, I think you have bigger problems, since doing this for
    JavaScript seems equally complicated.
     
    The way to start is to look at changes to the AST of the code. This
    is pretty possible to do within Eclipse, supposing you're willing to
    put in a lot of work. However, nobody on this list can really help:
    this is more about designing Android programs. Instead, I'd point you
    at a list targeted towards Eclipse hackers.
     
    Kris

     

    Anirvan <anirvan.majumdar@gmail.com> Sep 27 10:16PM -0700  

    Thanks for the input Kris. What you're saying does make sense. And while
    I'm not going to get into static analysis, by "the right thing" what I was
    looking at is a bit more simpler like checking things inline with what a
    programmer would do using asserts. Anyways, I understand that the problem
    definition is getting a bit vague, so I'll possibly go dig around more and
    come back with something specific, if required.
     
    On Friday, 27 September 2013 19:12:04 UTC+5:30, Anirvan wrote:

     

    Nathan <nathan.d.mellor@gmail.com> Sep 27 02:59PM -0700  

    Html.from Html. can parse html into a Spanned.
     
    It mentions it has limitations.
    Is it documented anywhere what limitations those are?
     
    It could be useful for context help and a lot more lightweight than using a
    Webview
     
    I've been considering something like this.
     
    http://blahti.wordpress.com/2012/02/14/how-to-build-simple-help-in-android/
     
    I wouldn't have to handle arbitrary text from the internet, just strings
    from our own resource files.
     
    Nathan

     

    danaimset <danaimset@gmail.com> Sep 27 04:24PM -0700  

    Hi Dirk!
     
    MQTT is really good. I've never heard about it.
     
    Regarding 24/7
    We have two states:
    1. In charge (connected devices, push all required data (apks, general
    info, media content) to all tablets from the server;
    2. In use (updates not allowed, only critical information could be
    submitted by using XMPP pubsub);
     
    Yes, that's a really minus of MQTT cause it doesn't allow to send ping.
     
    But I was able to find the following
    solution: http://stackoverflow.com/questions/10065624/how-to-send-ping-using-ecipse-paho-mqtt-client
    https://github.com/chinesejie/paho-for-android
     
    Thank You!
    Dan.
     
    понедельник, 23 сентября 2013 г., 15:55:36 UTC+3 пользователь Dirk Jäckel
    написал:

     

    gjs <garyjamessilva@gmail.com> Sep 27 12:25AM -0700  

    Hi,
     
    Don't know.
     
    What happens if you comment out the marker, is the map still centered at
    the same location ?
     
    Also does this vary with device rotation & / or different zoom - eg 21, &
    on phone or tablet ?
     
    I think there's also an option to move / animate & zoom the camera at the
    same, something like - map.moveCamera(CameraUpdateFactory.newLatLngZoom(
    center, zoom)) - maybe try that as well.
     
    I notice that the map moves a bit when you press on a marker, to show the
    text.
     
    Regards
     
    On Friday, September 27, 2013 9:50:45 AM UTC+10, Gary Blakely wrote:

     

    lbendlin <lutz@bendlin.us> Sep 27 05:28AM -0700  

    What happens if you set the camera tilt to zero?
     
    On Thursday, September 26, 2013 7:50:45 PM UTC-4, Gary Blakely wrote:
     

     

    Gary Blakely <gdeanblakely@gmail.com> Sep 27 04:15PM -0700  

    After reading the docs at
    I found that the following code works well. However my original code
    should have worked so I guess there are still some bugs.
     
    CameraPosition cameraPosition = new CameraPosition.Builder()
    .target(new LatLng(Lat, Lon))
    .zoom(15)
    .bearing(0)
    .tilt(45)
    .build();
    map.animateCamera(CameraUpdateFactory.newCameraPosition(cameraPosition));
    map.addMarker(new MarkerOptions()
    .position(new LatLng(Lat, Lon))
    .title("Phone Location")
    );
     
     
    On Thursday, September 26, 2013 4:50:45 PM UTC-7, Gary Blakely wrote:

     

    Robert Greenwalt <rgreenwalt@google.com> Sep 27 04:01PM -0700  

    I understand Sprint is investigating and may contact you for more info.
     
     

     

    Nathan <nathan.d.mellor@gmail.com> Sep 27 02:33PM -0700  

    Here's a situation I have run across.
     
    We have a Contextual Action Bar on screen. So far so good. When the user
    dismisses this, they are also done with the Activity/Fragment so we go
    ahead and close it for them.
     
    While our contextual action bar is active, the user long presses an
    EditText field on the same screen.
     
    It then brings up another contextual action bar, the copy and paste action
    bar. onDestroyActionMode is then called. Thinking the user dismissed the
    form, we close the Activity/Fragment for them.
     
    From the user's perspective, using copy/paste kills the form.
     
    It seems like the proper behavior would be to com back to ContextActionBars
    in the order they were opened.
     
    Any advice on how we can detect and handle this situation.
     
    Nathan

     

    Alexander Osmanov <alex.osmanov.88@gmail.com> Sep 27 09:51AM -0700  

    There must be no broken in one of such important part of the API. That's
    why I'd really like to hear some official recommendations for handling
    this. I refuse to believe there are no apps with IAB and server side data
    with accounts.
     
    Someone? Anyone?
     
    On Thursday, September 26, 2013 6:20:33 PM UTC+4, b0b wrote:

     

    Nikolay Elenkov <nikolay.elenkov@gmail.com> Sep 28 03:19AM +0900  

    On Sep 28, 2013 1:58 AM, "Alexander Osmanov" <alex.osmanov.88@gmail.com>
    wrote:
     
    > There must be no broken in one of such important part of the API. That's
    why I'd really like to hear some official recommendations for handling
    this. I refuse to believe there are no apps with IAB and server side data
    with accounts.
     
    You are obviously an optimist :) Adding features to IAB takes years and the
    people designing it obviously don't sell apps on Google Play. And when a
    new guy takes over they re-write the whole thing from scratch...
     
    Move on.

     

    Alexander Osmanov <alex.osmanov.88@gmail.com> Sep 27 11:51AM -0700  

    It's hard to just move on when you kinda spent a year writing your app and
    when the only thing left to do is to integrate it with billing :)
     
    On Friday, September 27, 2013 10:19:05 PM UTC+4, Nikolay Elenkov wrote:

     

    Sadhna Upadhyay <sadhna.braahmam@gmail.com> Sep 27 05:30PM +0530  

    Hi guys,
    m trying to debug my codebut it is not hitting any line ,but in other
    project its working then why it is not working in one project please let me
    know if any one ave any idea

     

    Mukesh Srivastav <mukichamps@gmail.com> Sep 27 08:07PM +0530  

    Did you check the break point, was it placed in the correct line and also,
    check restart your adp and eclipse that helps.
     
     
    On Fri, Sep 27, 2013 at 5:30 PM, Sadhna Upadhyay
     
    --
    Warm Regards,
    *Mukesh Kumar*,
    Android Consultant/Freelancer,
    India,Hyderabad.

     

    hanni <hanni78@gmail.com> Sep 27 07:34AM -0700  

    I'm creating an application with large bitmaps in a scrolling list.
     
    I'm on a 1080p screen and the bitmaps are about 1080x1080 pixels each. All
    drawing is done directly to canvas in a custom View, and all of the bitmaps
    are loaded from resources into memory before doing any scrolling (well, at
    least in my test case). I noticed that each time a new bitmap enters the
    screen, a frame of drawing is dropped, leading to a small stutter. But when
    I scroll back to the bitmaps already shown before there is no frame drop,
    but smooth 60 fps.
     
    This leads me to believe that the HW acceleration in Android uploads a
    texture to GPU the first time a Bitmap is shown on screen. And if the
    Bitmap is large enough, it eats a frame of time (when small bitmaps are
    scrolled in, there's no stuttering).
     
    I'm trying to avoid this behavior by ensuring that all textures are loaded
    into GPU memory before scrolling starts. I'm thinking I could draw all
    bitmaps to canvas on the first onDraw() call, either with alpha 0 or scaled
    down to 0 x 0 or similar.
     
    Am I right in mu assumption that its the texture uploading that takes time?
    Should I be drawing the bitmap to Canvas to ensure that texture is uploaded
    or is there any other, better way?
    Will the texture be uploaded if I draw the bitmap with alpha 0 or scaled
    down to 0 x 0?
     
    Thanks

     

    Dan <dan.schmitt@gmail.com> Sep 27 05:14AM -0700  

    Look for proguard-project.txt in your android project directory (with the
    AndroidManifest.xml
    and various other .properites files.)
     
    Pick one of the keywords to avoid having classes/members mangled by
    proguard to
    protect whatever you are calling/want called back:
     
    http://proguard.sourceforge.net/index.html#manual/examples.html
     
    proguard will re-name everything it can, and will do (what it thinks is)
    dead code
    removal (which it can only guess at what outside code might want to run in
    your
    code, and often gets it wrong.) The -keep options in the configuration
    file will
    tell proguard not to obfuscate the name or remove the code (if it thinks
    it's unused.)
     
     
    Dan S.
     
     
    On Thursday, September 26, 2013 3:24:23 PM UTC-4, 12169 wrote:

     

    Alice Ni <alice.ni19@gmail.com> Sep 27 07:05AM -0500  

    So what if it is in the support library?..... it is as native as it could
    be!
     
     

     

    Simon Giddings <mr.s.giddings@gmail.com> Sep 27 05:14AM -0700  

    Well my, previous, understanding was that the support library was to
    provide functionality found in the most recent APIs, for earlier APIs.
    So, stuff in the v4.0 could be used in v2.3 via the support library.
     
    Perhaps you could clear something up for me.
    When I use just *one *item in the support library, will I get *only* that
    item included in my apps files, or will *all of the support library* be
    packaged all the same ?
     
    On Friday, September 27, 2013 2:05:31 PM UTC+2, alice wrote:

     

    Giuseppe Brando <giuseppe.brando.85@gmail.com> Sep 27 02:29AM -0700  

    Hi to everyone,
     
    someone can tell me if is possible to interact with the light sensor when
    the device is in standby?
     
    Thanks,

     

    gjs <garyjamessilva@gmail.com> Sep 27 12:29AM -0700  

    Hi,
     
    Is there an ASUS usb driver you need to install ?
     
    You can also debugging over Wifi instead of usb, maybe try that as well.
     
    Regards
     
    On Friday, September 27, 2013 12:13:32 AM UTC+10, eli wrote:

     

--
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+unsubscribe@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 unsubscribe from this group and stop receiving emails from it, send an email to android-developers+unsubscribe@googlegroups.com.
For more options, visit https://groups.google.com/groups/opt_out.

[android-developers] Digest for android-developers@googlegroups.com - 16 Messages in 8 Topics

Comments: (0)

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

    Gary Blakely <gdeanblakely@gmail.com> Sep 26 04:50PM -0700  

    In my android app I have the following code...
     
    CameraUpdate center= CameraUpdateFactory.newLatLng(new LatLng(Lat,Lon));
    DebugLog.debugLog("centered camera on " + Lat + " and " + Lon, false);
    CameraUpdate zoom=CameraUpdateFactory.zoomTo(15);
    map.moveCamera(center);
    map.animateCamera(zoom);
    map.addMarker(new MarkerOptions()
    .position(new LatLng(Lat, Lon))
    .title("Phone Location")
    );
     
    Lat is 31.7898
    Lon is -111.0354
     
    The marker is exactly at that location. However the camera is centered
    about 5 miles north of that location on the v2 map.
    Why?
    Thanks
    Gary

     

    Gaurav Sharma <gauravsharma531@gmail.com> Sep 26 02:01AM -0700  

    I am having a very strange issue in my android app. I receive xml file from
    server and perform operation based on xml content.
     
    It is working on almost every network for eg. AT&T, Verizon in USA, airtel,
    vodaphone and others in india.But it not working on sprint network USA.
     
    When i tried to find xml content i am getting some byte code or unicode not
    the plain xml file. I looked for more information i found other also has
    faced this issue on sprint evdeo. people says turn off byte mobile
    optimization here <http://t8387.codeinpro.us/q/50810aaa4f1eba38a4efcbd1>
     
    I am not able to turn off mobile byte optimization. If i switch to wifi
    network it receive file properly. Issue occur on sprint cellular network
    only.
     
    Any help or any pointer will be very much appreciated. Thanks in advance

     

    Nobu Games <dev.nobu.games@gmail.com> Sep 26 08:03AM -0700  

    Could you post an example of such a corrupted version of your XML files?
    Maybe as a hex dump?
     
    On Thursday, September 26, 2013 4:01:31 AM UTC-5, Gaurav Sharma wrote:

     

    Robert Greenwalt <rgreenwalt@google.com> Sep 26 08:47AM -0700  

    There have been cases in the past where a carrier has intercepted and
    alterned content flowing over their network - most notably graphics getting
    down-rezed or compressed. I'd not heard of this happening on xml, but the
    fact that changing networks fixes the problem suggests something like this
    may be happening.
     
    What protocol are you using to transfer the file?
     
     

     

    Gaurav Sharma <gauravsharma531@gmail.com> Sep 26 11:33PM +0530  

    Thank for response
     
    @Nobu : I tried to tump it but was not able to dump it and yes changing the
    network is working fine. If i switch to AT&T or some other network provider
    it is working like a charm.
    @Robert: I am using Http protocol to transfer file.
     
     
     
    --
    Gaurav Sharma
    Bangalore

     

    Michael Banzon <michael@banzon.dk> Sep 26 08:19PM +0200  

    On other platforms (desktop) I very often see XML payloads messed up
    over HTTP by proxies. Usually some request/response header to signal
    no use of proxy fixes the issue.
     
    (This might not be the case for you though)
     
    On Thu, Sep 26, 2013 at 8:03 PM, Gaurav Sharma
     
    --
    Michael Banzon
    http://michaelbanzon.com/

     

    Gaurav Sharma <gauravsharma531@gmail.com> Sep 27 12:20AM +0530  

    @Michael : thanks for your valuable suggestion but i am using cellular
    network.
     
     
     
    --
    Gaurav Sharma
    Bangalore

     

    Michael Banzon <michael@banzon.dk> Sep 26 09:35PM +0200  

    There still might be a proxy in between - wouldn't be the first time
    an ISP shoved that in there ;-)
     
    On Thu, Sep 26, 2013 at 8:50 PM, Gaurav Sharma
     
    --
    Michael Banzon
    http://michaelbanzon.com/

     

    12169 <ashish.acet@gmail.com> Sep 26 12:28PM -0700  

    Hi,
    i do not have understanding of native developement.
    can you read data directly from fram-buffer which actually hold the data
    while capturing the image.
     
    On Wednesday, September 18, 2013 5:03:19 PM UTC-7, Baodong Chen wrote:

     

    Andrew Mackenzie <andrew@mackenzie-serres.net> Sep 25 11:53PM -0700  

    Look at the classes youbarebusing tibdi that, then add instructions to your proguard config file (in project root) to have it NOT obfuscate or remove those classes or methods or the classes or methods they access by name.

     

    12169 <ashish.acet@gmail.com> Sep 26 12:24PM -0700  

    Hi , can you please explain...or provide demo wt to do?
     
    On Wednesday, September 25, 2013 11:53:14 PM UTC-7, Andrew Mackenzie wrote:

     

    Simon Giddings <mr.s.giddings@gmail.com> Sep 26 08:50AM -0700  

    I have seen the Navigation Drawer and am interested in it for my v4.1
    tablet application.
    However, I see that the documentation describes it as being within the
    support library.
     
    My understanding was that this library was mainly for apps in and before
    v2.3 of android.
     
    Is there not a "native" version of this feature available, or are we
    "condemned" to using the support library ?

     

    gauri <gauri.vale@gmail.com> Sep 26 07:32AM -0700  

    Thanks for your help.
    I downloaded and installed one paid Android app using Google Play Store in
    phone with Android OS 4.3.
    I wrote one test application which enumerates list of installed apps and
    prints apk download location them.
    When I tested this app, I found that, this paid app was downloaded at
    "/mnt/asec". In this location, the directory named by that app's package
    name was created and it was having following files:
    - res.zip (containing res directory, AndroidManifest.xml)
    - pkg.apk
    - libs directory
     
    On Tuesday, September 24, 2013 7:56:12 PM UTC+5:30, Nikolay Elenkov wrote:

     

    eli <elinaiman@sympatico.ca> Sep 26 07:13AM -0700  

    I am using Eclipse and am able to communicate with a XOOM tablet for USB
    debugging. However if I use an ASUS tablet Windows XP does not see it if I
    have the USB debugging option selected. Has anybody solved this problem.

     

    Alexander Osmanov <alex.osmanov.88@gmail.com> Sep 26 03:20AM -0700  

    Hello,
     
    I'm having a hard time with figuring out the right way to approach
    handling in app purchases for users with multiple accounts. I am using
    Appengine Endpoints to implement my server side API. This API returns some
    data to my users. As soon as user purchases a certain product API will
    return additional data. I want to make it more secure by enabling OAuth
    authentication to my endpoints. So as soon as user purchases something it
    is verified and remembered on a server. Thus my API endpoint will always
    know what data to return to a particular user.
     
    But what should I do if a user has more than one account? I couldn't find
    the way how to obtain account the app uses for IAP (according to
    documentation it's the account used to download the app). So I either have
    to blindly pick first account or let user pick an account. But what if they
    pick another account and all their purchases would go to a different
    account? This creates a lot of problems. For instance if user has only one
    account on another device it will either not have server side info
    available or will not have Google Play recognizing as a buyer. Basically we
    will end up with two sources of info - Google Play and my server possibly
    conflicting with each other because of accounts.
     
    What makes problem even harder is that I don't want to force users logging
    in using their account as this really doesn't add much value to app at the
    moment. But at the same I want to avoid just sending purchased flag to my
    API based on some my local data (which can be compromised).
     
    What is the appropriate strategy for handling this I would say quite common
    situation? If only there was a way to know for sure which account the app
    used for purchases, all my problems would be gone.
     
    Thanks,
    Alex.

     

    b0b <pujos.michael@gmail.com> Sep 26 07:20AM -0700  

    IAP with multiple accounts is in my opinion *broken*, even if I suspect
    current behaviour is how Google intended it.
     
    In my experience, in the presence of multiple accounts, the IAP code will
    always pickup the first listed account, in the device's Google account list
    in Settings, which may not be the account used for the IAP.

     

--
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+unsubscribe@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 unsubscribe from this group and stop receiving emails from it, send an email to android-developers+unsubscribe@googlegroups.com.
For more options, visit https://groups.google.com/groups/opt_out.