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

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

    Shubham Aggarwal <shubham.1992aggarwal@gmail.com> Aug 27 10:19AM -0700  

    Hi,
    I am creating an application which uses an example source code provided in
    Google Android Documentation licensed under apache license 2.0
    Is it legal to directly copy one or more of the files from that source code
    in my application (to be published on market)
     
    Thanks
    Shubham

     

    TreKing <trekingapp@gmail.com> Aug 27 07:29PM -0500  

    On Tue, Aug 27, 2013 at 12:19 PM, Shubham Aggarwal <
    > Google Android Documentation licensed under apache license 2.0
    > Is it legal to directly copy one or more of the files from that source
    > code in my application (to be published on market)
     
    Have you considered reading the terms of the Apache License?
     
    -------------------------------------------------------------------------------------------------
    TreKing <http://sites.google.com/site/rezmobileapps/treking> - Chicago
    transit tracking app for Android-powered devices

     

    brianl <lichtenw@gmail.com> Aug 27 04:51PM -0700  

    Also, tried...
     
    mView.announceForAccessibility("Hello World");
     
     
     
    On Tuesday, August 27, 2013 4:46:07 PM UTC-7, brianl wrote:

     

    brianl <lichtenw@gmail.com> Aug 27 04:46PM -0700  

    Instead of using TTS to voice an utterance I'm wondering if this will do
    the job...

    if (Build.VERSION.SDK_INT > Build.VERSION_CODES.ICE_CREAM_SANDWICH)
    {
    AccessibilityEvent event =
    AccessibilityEvent.obtain(AccessibilityEvent.TYPE_ANNOUNCEMENT);
    AccessibilityRecord record = AccessibilityRecord.obtain();
    record.setContentDescription("Hello World");
    event.appendRecord(record);
    mView.sendAccessibilityEventUnchecked(event);
    }
     
    Tried this on a Nexus 4.1.2 with Accessibility TalkBack enabled and 'Hello
    World' was NOT spoken.

     

    Lai Vung <haibison@gmail.com> Aug 27 02:45PM -0700  

    Thanks Jon.
     
    It works very well for me. You saved me a day. Thank you.
     
    Hai
     
    On Sunday, December 7, 2008 2:56:10 PM UTC+7, Jon Colverson wrote:

     

    Keith Wiley <kbwiley@gmail.com> Aug 27 09:13AM -0700  

    I admit I haven't logged into my developer console in a few days, but when
    I did this morning I saw a message that there are new guidelines to agree
    to and that existing apps not in compliance might be removed 30 days hence
    (less than 30 since I missed a few days). Part of the new agreement says
    the following [my emphasis in red]:
     
     
    - *In-app purchases:*
    -
    - *Developers offering virtual goods* or currencies* within a game
    downloaded from Google Play must use Google Play's in-app billing
    service <http://developer.android.com/google/play/billing/index.html>as the method of payment.
    *
    - Developers offering additional content, services or functionality
    within another category of app downloaded from Google Play must use Google
    Play's in-app billing service<http://developer.android.com/google/play/billing/index.html>as the method of payment, except:
    - where payment is primarily for physical goods or services (e.g.
    buying movie tickets, or buying a publication where the price also includes
    a hard copy subscription); or
    - where payment is for digital content or goods that may be
    consumed outside of the application itself (e.g. buying songs that can be
    played on other music players).

    One approach to interpreting this would be to try to nit-pick it apart (to
    debate the meaning of "*virtual good*" for instance, but another approach
    is to simply ask the larger question: Can we no longer use MobFox or any
    other non-Google in-app payment system (in a game, perhaps other apps, but
    not in a game for whatever reason)? I have a game on Google Play that
    uses in-app purchases to sell various "upgrades" or "additional
    capabilities" (sort of extra-life like things) within the game. Is Google
    going to remove my app three weeks from now if I don't complete gut all the
    MobFox payments from it or am I misunderstanding these new guidelines?
     
    ...or, alternatively, does "*virtual good*" refer to something very
    specific, not just app upgrades but actual "pretend items" of some nebulous
    definition (like magic swords or stuff like that, which my game doesn't
    have anything like anyway), such that the *mere presence of MobFox* in an
    app won't necessarily be grounds for summary removal by Google.
     
    I'm quite confused about this.
     
    Thanks.

     

    John Coryat <coryat@gmail.com> Aug 27 10:23AM -0700  

    Caution: IANAL
     
    I believe you were already in violation of Google's terms when you opted to
    use a payer system outside of Google Wallet. The new terms just clarify it.
    To me, it removes all doubt that you can get away with bypassing the Google
    Play terms.
     
    There shouldn't be any doubt as to what this says. You're fooling yourself
    if you think this is an idle threat from Google. They most likely have an
    automatic system in place that is going to purge any app that isn't in
    compliance after the deadline.
     
    -John Coryat

     

    Keith Wiley <kbwiley@gmail.com> Aug 27 10:41AM -0700  

    Fair enough. Thanks for the info. That leaves me rather confused though.
    What is the point of third party systems like MobFox? How do they work?
    Is their entire business model predicated on hoping confused developers
    such as myself will accidentally violate the Google TOS? That strikes me
    as somewhat unbelievable.

     

    Kristopher Micinski <krismicinski@gmail.com> Aug 27 01:51PM -0400  

    I think they're a vestigal holdover from when in app billing didn't exist
    and these things weren't really enforced, but you can feel free to email
    them if you'd like clarification.
     
    Kris
     
     

     

    Keith Wiley <kbwiley@gmail.com> Aug 27 10:52AM -0700  

    WAIT. Oh man am I confused. I'm sorry. I use MobFox for my in-app ads
    (as opposed to whatever ad system Google supports, AdMob I believe), but my
    in-app purchases are processed using Google. Yeesh!
     
    In fact, IIRC, I coded up both MobFox and AdMob ads and can switch to use
    either, both, or neither of those ad systems, but I don't think I ever
    turned the AdMob option on, only MobFox.
     
    Anyway, this whole discussion is something of a red herring now. Sorry.

     

    Keith Wiley <kbwiley@gmail.com> Aug 27 11:21AM -0700  

    Like I said in an earlier response, I was confusing in-app ads and in-app
    purchases. This entire thread (my original question) is essentially
    invalid. Please disregard. Sorry.

     

    Nuno Silva <little.coding.fox@gmail.com> Aug 27 09:13AM -0700  

    I'm using Google Play Services for cloud sync in a game, and have already
    spent several hours trying to figure out this bug, but I have absolutely no
    luck figuring it out.
     
    I googled everywhere, but this specific error doesn't appear to anyone
    else, and I tried all the other solutions to similar problems without
    success, so I'm hoping I'll get luck and someone will know how to solve
    this.
     
    What confuses me is, this worked at least once, originally even using a
    wrong app key! After I logged in for the first time, I am now unable to
    login any more, and get an "Unknown Error" message box.
     
    I've verified that I call the mHelper methods for onActivityResult since I
    overload it, and followed all the instructions I could find for setting up
    everything.
     
    Any help would be appreciated!
     
    Relevant Logcat:
     
    08-27 16:48:20.082 I/ejk ( 1690): I/O exception
    (javax.net.ssl.SSLException) caught when processing request: Write error:
    ssl=0x5fbf10: I/O error during system call, Broken pipe
     
    08-27 16:48:20.082 I/ejk ( 1690): Retrying request
     
    08-27 16:48:20.343 D/dalvikvm( 1690): GC_CONCURRENT freed 749K, 49% free
    4217K/8263K, external 1596K/2108K, paused 3ms+3ms
     
    08-27 16:48:20.757 E/Volley ( 1690): [24] je.a: Unexpected response code
    403 for https://www.googleapis.com/games/v1/players/me
     
    08-27 16:48:20.820 E/SignInIntentService( 1690): Access Not Configured
     
    08-27 16:48:20.820 E/SignInIntentService( 1690): avk
     
    08-27 16:48:20.820 E/SignInIntentService( 1690): at
    aqq.a(SourceFile:126)
     
    08-27 16:48:20.820 E/SignInIntentService( 1690): at
    ahd.a(SourceFile:228)
     
    08-27 16:48:20.820 E/SignInIntentService( 1690): at
    ahd.a(SourceFile:209)
     
    08-27 16:48:20.820 E/SignInIntentService( 1690): at
    agl.a(SourceFile:489)
     
    08-27 16:48:20.820 E/SignInIntentService( 1690): at
    axu.a(SourceFile:202)
     
    08-27 16:48:20.820 E/SignInIntentService( 1690): at
    com.google.android.gms.games.service.GamesSignInIntentService.onHandleIntent(SourceFile:324)
     
    08-27 16:48:20.820 E/SignInIntentService( 1690): at
    android.app.IntentService$ServiceHandler.handleMessage(IntentService.java:59)
     
    08-27 16:48:20.820 E/SignInIntentService( 1690): at
    android.os.Handler.dispatchMessage(Handler.java:99)
     
    08-27 16:48:20.820 E/SignInIntentService( 1690): at
    android.os.Looper.loop(Looper.java:130)
     
    08-27 16:48:20.820 E/SignInIntentService( 1690): at
    android.os.HandlerThread.run(HandlerThread.java:60)
     
    08-27 16:48:20.820 E/LoadSelfFragment( 3660): Unable to sign in -
    application does not have a registered client ID
     
    08-27 16:48:20.828 D/CcUtils Google Services GameHelper( 3627):
    onActivityResult, req 9001 response 10004
     
    08-27 16:48:20.828 D/CcUtils Google Services GameHelper( 3627):
    responseCode != RESULT_OK, so not reconnecting.
     
    08-27 16:48:20.828 D/CcUtils Google Services GameHelper( 3627): giveUp:
    giving up on connection. Status code: 4
     
    08-27 16:48:20.828 D/CcUtils Google Services GameHelper( 3627): Making
    error dialog for error: 4
     
    08-27 16:48:20.867 D/CcUtils Google Services GameHelper( 3627):
    onActivityResult, req 9001 response 10004
     
    08-27 16:48:20.871 D/CcUtils Google Services GameHelper( 3627):
    responseCode != RESULT_OK, so not reconnecting.
     
    08-27 16:48:20.871 D/CcUtils Google Services GameHelper( 3627): giveUp:
    giving up on connection. Status code: 4
     
    08-27 16:48:20.871 D/CcUtils Google Services GameHelper( 3627): Making
    error dialog for error: 4
     
    Relevant Android Manifest bits:
     
    <meta-data android:name="com.google.android.gms.games.APP_ID"

     

    akash khandare <akashsapana@gmail.com> Aug 27 09:24PM +0530  


    > In a testing program I'm playing with currently, I want to use
    setFormat() to adapt the pixel format of my surface to the chosen EGL
    config before I pass the surface holder to eglCreateWindowSurface().
     
    > Now, I call EGL from my render thread and I know
    SurfaceHolder.setFormat() is documented to have to be "called from the same
    thread running the SurfaceView's window", which I take to be the main
    thread. To comply, I wrap my setFormat() call in a Runnable which I pass
    to runOnUiThread() and wait() until it's actually executed.
     
    > This works perfectly on some devices, however it gives me intermittent
    failures on Optimus One (with Android 2.2) - on program start-up, three
    times out of four the screen is just black. Even if start-up goes right,
    the first configuration change makes the screen go black. The program
    still runs and no GL or EGL calls signal any errors.
     
    > Here's the weirdest part - if I omit the runOnUiThread() stuff and simply
    call setFormat() from my render thread, it fixes the problem and the
    program runs 100% solid on Optimus no matter much beating I give it -
    randomly pressing Home and Back while rotating the device wildly, putting
    it to sleep and waking it back up, the renderer always handles the native
    window changes correctly and renders just fine.
    > 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.

     

    RLScott <fixthatpiano@yahoo.com> Aug 27 06:10AM -0700  

    Is there anything wrong with this way of trigger an action in an Activity
    from a local Service? It seems too easy. But all the examples I have seen
    of accomplishing the same end use a more complicated Messenger method.
    Anyway, here is what I do:
     
    In my activity, I start and bind to a local Service (BTService) from
    onResume:
     
    Intent intent = new Intent(this, BTService.class);
    bindService(intent, mConnection, Context.BIND_AUTO_CREATE);
    startService(intent);
     
    The "mConnection" referenced above is defined by:
     
    /** Defines callbacks for service binding, passed to bindService() **/
    private ServiceConnection mConnection = new ServiceConnection() {
     
    @Override
    public void onServiceConnected(ComponentName className,
    IBinder service) {
    // We've bound to LocalService, cast the IBinder and get BTService
    instance
    MyBtServiceBinder binder = (MyBtServiceBinder) service;
    btserv = binder.getService(); //..Activity's reference to the
    Service
    btserv.main = Main.this; //..Service's reference to the
    binding Activity
    }
     
    @Override
    public void onServiceDisconnected(ComponentName arg0) {
    if(btserv != null)
    {
    btserv.main = null; //..Break the Service's reference to the
    Activity
    btserv = null; //..Break the Activity's reference to the
    Service
    }
    }
    };
     
    In my Activity's onPause I disconnect from the Service as follows:
     
    if (btserv!=null) {
    btserv.main = null; //..Break the Service's reference to the
    Activity
    btserv = null; //..Break the Activity's reference to the
    Service
    unbindService(mConnection);
    }
     
    So when the Service wants to trigger an event in the Activity, it does this:
     
    if(main != null)
    {
    main.handler.post(main.doHandleEvent);
    }
     
    Where "main" is the reference to my Activity that was set by the Activity
    in "onServiceConnected", and "handler" is a Handler in my Activity that
    handles posts to the Runnable, "doHandleEvent". Then in short order, the
    doHandleEvent in my Activity will run. And that is how I trigger an event
    in the Activity from my Service. Of course there are many assumptions in
    this approach. For example, only one client should connect to my Service,
    since it only holds a single reference to the client. And the triggering
    shown above is from the UI thread, not from a worker thread. That gets
    around the race condition where "main" is not null at the "if" statement,
    but becomes null by the time the thread gets into the referencing of
    handler and doHandleEvent. I have tested this method in a Bluetooth
    application and everything seems to be working fine. But I want to know if
    there is some "gotcha" that I have not seen.
     
    Robert Scott
    Hopkins, MN

     

    Amit Mangal <forum.amit.mangal@gmail.com> Aug 27 12:24PM +0530  

    any idea guys ?
     
     
    On Tue, Aug 27, 2013 at 10:50 AM, Amit Mangal

     

    Sumedh Jiwane <sumedh02@gmail.com> Aug 27 01:36PM +0530  

    Try refreshing the folders, clean and rebuild.
     
     
     
    On Tue, Aug 27, 2013 at 12:24 PM, Amit Mangal

     

    Harish <hkachoria@gmail.com> Aug 27 01:32AM -0700  


    > Ideally no setting is require, how you know dpi of your screen ? some time
    > even big screen are treated as mdpi based on the dpi setting on device
    > (which is not editable unless rooted).
     
     
    First you check dpi of device, try some helper app like
    https://play.google.com/store/apps/details?id=com.sturnus.screeninfo
     
    Normally for big screen( 7 and 10 inch) device I created separate
    folder drawable-sw600dp and drawable-sw720dp and it works for bigger screen
    with good dpi.

     

    Amit Mangal <forum.amit.mangal@gmail.com> Aug 27 03:44PM +0530  

    is there any way my app should support all screen sizes withouth stretching
    images ?
     
    i am having ldpi hdpi mdpi xhdpi xxhdpi
     
    images .
     
     

     

    Harish <hkachoria@gmail.com> Aug 27 04:24AM -0700  

    I face lot of issue on my app which is supported for Tablet as well as on
    phone device and I had entirely different screens and layout for tablets.
     
    It was nightmare working with china tablets which come with very different
    dpi even though all are 7inch tablets.
     
    and After testing on many tablets and phone I put images with following
    sizes and as of now it's working on most of devices without issue,
     
    - hdpi - 48*48
    - mdpi- 48*48
    - sw600dp - 72*72
    - sw720dp - 96*96
    - xhdpi- 72*72
    - xxhdpi - 96*96
    - ldpi- 24*24
     
    pls let me know if you find better solution.

     

--
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.

No comments:

Post a Comment