[android-developers] Re: [RFC] What are your thoughts on cross-platform development for Android and iOS?

2015-03-21 Thread Guy Smith
My twopence worth... as a hobby app developer, my main concern is a 
platform that puts up as few obstacles as possible. 

I loathe "version hell": the code works under this version, but breaks 
under that version ; the display is fine on most screens but breaks on 
particular sizes ; yada yada. 

Any cross-platform SDK has to sit on top of all these versions, from each 
of Apple, Android, Microsoft, perhaps all the browser APIs if you're doing 
web-enabled stuff, and any other random companies (Ubuntu, Samsung?) that 
bring out a mobile platform. 

Somewhere, you are going to have to make a trade-off. On some aspect, 
you're going to be way behind the single platform SDKs. It might be 
performance, complexity, features, robustness, whatever, but it's going to 
be something. 

Who do you expect to use your platform? For example, governments would want 
to develop cross-platform apps as cheaply as possible and don't care about 
performance or robustness, game developers probably care about performance, 
retailers probably care about look&feel and robustness. 


On Saturday, March 21, 2015 at 11:39:26 AM UTC+10, Mario Zechner wrote:
>
> Hi, 
>
> i'm the guy behind libGDX (http://libgdx.badlogicgames.com) and am 
> currently also working on RoboVM (http://www.robovm.com) which allows you 
> to run Java/Scala/Kotlin/... on iOS. Just like with libGDX, my main concern 
> with RoboVM is to make cross-platform app development easier for people 
> coming from a Java/JVM/Android background. We want to get input from the 
> broader Android developer community to help us shape the future of RoboVM. 
> It would mean a lot to us, a team of 4 devs, if you find the time to 
> comment on the below blurb. 
>
> A lot of people here are working in app shops that probably create apps 
> for customers or themselves that need to work on both iOS and Android. Some 
> may only focus on Android but may wish to expand to iOS. 
>
> There are a few frameworks/platforms out there that can help with sharing 
> code between both Android and iOS (C#, Java, JS, Ruby, pick your poison). 
>
> Some of these frameworks/platforms allow you to share business logic and 
> use the native UI APIs on each platform. This means you'll have to write 
> the UI for each platform separately. The UX will most likely be better, but 
> at the expense of more development time. Let's call this the "native UI" 
> solution. 
>
> Some frameworks allow you to share both the business logic and the UI 
> code. A cross-platform UI API either wraps the native UI API (lowest common 
> denominator between the two platforms), or it uses something like a 
> webview, emulating the native UI. The UX will most likely be worse, but 
> development time can be reduced. Let's call this the "cross-platform UI" 
> solution. 
>
> I'd be super happy if you have any input on the following questions 
> 1. Do you think cross-platform development is viable at all? Why/Why not? 
> 2. Would you rather use the "native UI" solution or the "cross-platform 
> UI" solution? Why? 
>
> Our focus with RoboVM at the moment is on the "native UI" solution and 
> making the code-sharing of the business logic as easy as possible. Once 
> this is complete, we also want to offer a "crossplatform UI" solution. We 
> are currently evaluating different approaches: 
>
> 1. JavaFX. That's already alpha quality, there's a whole community around 
> it and we enable them to work on iOS. But it isn't the most natively 
> looking & feeling option. It also carries the Swing heritage with it. 
> 2. Webview. Quite flexible but shares all the same problems that Phonegap 
> et. al. have (performance, look & feel). 
> 3. Custom cross-platform UI. Gives us the most freedom. Maps a common API 
> on top of native UI APIs, so the look & feel is native. Might be a leaky 
> abstraction though. 
>
> I do have my preferences regarding the above 3 options, but i'd really 
> love to get input from you folks on that. 
> Thanks for your time, really appreciate it. 
>
> Ciao, 
> Mario

-- 
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
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+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


[android-developers] Re: Chromium WebView not as fast as Chrome

2015-03-03 Thread Guy Smith
Yes. I've had quite a lot of trouble with WebView, to the point where I've 
put a button in so the user can invoke an external browser if the webview 
is blank or otherwise unreadable. 

-- 
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
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+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


[android-developers] Re: Activty on orientation

2014-02-12 Thread Guy Smith


I’ve found creating Views – even view hierarchies – quite fast. But 
accessing data can be slower, especially over the internet. 

Do you need to keep your view hierarchy, or just a cache of your data, 
between invocations of onCreate()? 

On Saturday, February 8, 2014 10:38:40 PM UTC+10, rahul kaushik wrote:
>
> Hi,
>
> I created dynamic controls on view ,i call the this view creation at 
> OnCreate when i changed the orientation the activity call the OnCreate 
> again and it consume same amount of time which which was created at very 
> first time ,can i reduce this time on orientaion 
> Pls Suggest
>
> Thanks
> RK
>

-- 
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
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+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/groups/opt_out.


[android-developers] Re: Android Implementation of Emacs

2014-01-19 Thread Guy Smith
Vim - an extension of 
"vi". https://play.google.com/store/apps/details?id=net.momodalo.app.vimtouch

Ah... the good old days. I remember the vi vs emacs religious wars in our 
office. After we'd buried our dead, we came to the conclusion that they 
were about as good as each other. 

But, vi uses fewer meta- ctrl- shift- keystrokes, so might work better on a 
touchscreen keyboard. 

Disclaimer: I haven't tried the above app. 

On Monday, January 20, 2014 6:34:35 AM UTC+10, Umar wrote:
>
> I downloaded an implementation of Emacs from Google Play store. I am 
> trying to make it work on my Samsung Note 2. Does anyone know which key 
> maps to Ctrl and Esc (on the smartphone keyboard)? 
>
> Is there any other versatile editor similar to Emacs that works well for 
> Android developers? 
>
> Thanks for any pointers. 
>

-- 
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
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+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/groups/opt_out.


Re: [android-developers] HELP

2013-05-20 Thread Guy Smith
OTOH, beware the second-system syndrome: 
http://en.wikipedia.org/wiki/Second-system_effect

On Tuesday, May 21, 2013 12:52:46 AM UTC+10, John Coryat wrote:
>
> You might also find that the second time you code it up, it will be 
> better... Good lesson in backup though.
>
>
>

-- 
-- 
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
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+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/groups/opt_out.




[android-developers] Re: How to check if screen is held touched?

2013-02-24 Thread Guy Smith
Are you using GestureDetector and onGestureListener? Perhaps 
OnGestureListener's onSingleTapUp method is what you're after. 

On Sunday, February 24, 2013 3:37:14 PM UTC+10, Edvinas Kilbauskas wrote:
>
> Ok, so I'm having a little problem with OnTouchListener on android 2.3+ 
> devices.
> I'm making a game, when you touch your screen, the player jumps, and if 
> you hold your screen touched the player falls slower.
> Everything seem good on my android 2.2 device. Because I get 
> MotionEvent.ACTION_MOVE even if my finger isn't moving on the screen, but 
> on android 2.3+ devices I need to move my finger to get ANY event. How can 
> I make that when I hold the screen touched I get onTouch() some kind other 
> method called? Yes I tried, making a isTouched boolean variable, and set it 
> to true when I get MotionEvent.ACTION_DOWN, or ACTION_MOVE and to false 
> when I get ACTION_CANCEL or ACTION_UP. At first, it seemed to have done the 
> trick, but later on, it started bugging again. So is there ANY kind of way 
> to check if screen is touched using Android API? And could someone explain 
> me why this is happening? 
>
> By the way, sorry for reposing, I though I had problem solved but I 
> didn't, and I don't know how to delete my other post, I messed something up 
> there.
>

-- 
-- 
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
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+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/groups/opt_out.




Re: [android-developers] Debugging beta apps

2013-02-18 Thread Guy Smith
Actually, Guy is guilty of sloppy phrasing. I was thinking it seemed like 
the no-cost and low set-up backend was going. For me, not having to arrange 
storage was an attraction of ACRA. 

Apologies to those who have contributed to ACRA. 

On Tuesday, February 19, 2013 9:08:22 AM UTC+10, Indicator Veritatis wrote:
>
> It appears Guy misread the note. It has happened to lots of people on lots 
> of issues. The note really is not talking about discontinuing ACRA, but 
> about discontinuing storage of the ACRA report results as spreadsheets on 
> Google Drive. This leaves us free to continue to use ACRA, as long we find 
> our own storage.
>
> Or perhaps he thought this was a first step, and that ACRA deprecation was 
> soon to follow. But that seems rather unlikely.
>
> On Sunday, February 17, 2013 3:04:24 PM UTC-8, Mark Murphy (a Commons Guy) 
> wrote:
>>
>> On Sun, Feb 17, 2013 at 5:59 PM, Guy Smith  wrote: 
>> > ACRA is essentially being phased out (IMHO) - 
>> > see 
>> > 
>> https://github.com/ACRA/acra/wiki/Notice-on-Google-Form-Spreadsheet-usage. 
>>
>>
>> You are welcome to your opinion, but there are plenty of ACRA 
>> back-ends available, including ACRA's own Acralyzer, that do not 
>> require the use of Google Spreadsheets. 
>>
>> -- 
>> Mark Murphy (a Commons Guy) 
>> http://commonsware.com | http://github.com/commonsguy 
>> http://commonsware.com/blog | http://twitter.com/commonsguy 
>>
>> Localized Android Question-and-Answer Sites: http://www.andglobe.com 
>>
>

-- 
-- 
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
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+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/groups/opt_out.




[android-developers] Re: Debugging beta apps

2013-02-17 Thread Guy Smith
Briefly: I used HockeyApp for reporting back capability, and was happy. I 
used ElusiveStars, a forum and TheBetaFamily to find testers, and got best 
results from ElusiveStars. 

A more detailed post is 
at https://groups.google.com/d/topic/android-developers/PrW2hFpZzpk/discussion. 

On Saturday, February 16, 2013 4:40:01 AM UTC+10, dashman wrote:
>
> How do users debug their beta apps - once it's released 
> to users. I'd like to get a better feedback than 'app crashed.
>
> Can users send back log files etc.
>
> I was thinking about using ASSERT.
>
> Is the java assert feature recommended or the Assert class.
>
> I noticed that the latter does not display a message on the screen.
>
>
> Help appreciated.
>
>

-- 
-- 
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
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+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/groups/opt_out.




Re: [android-developers] Debugging beta apps

2013-02-17 Thread Guy Smith
There are two parts to this. One, you need to get stack dumps back from 
your app. Two, you need to find testers. 

I set up testing in December. ACRA is essentially being phased out (IMHO) - 
see 
https://github.com/ACRA/acra/wiki/Notice-on-Google-Form-Spreadsheet-usage. 
There are several tools out there for putting reporting-back capability 
into your app. Most of them cost money, perhaps with a trial period. I went 
with HockeyApp, and was happy. 

Finding testers is more difficult. I got best results from ElusiveStars, 
but see AndroidForums for my post 
http://androidforums.com/application-development/672692-testing-sites-services.html.
 
I also tried the Alpha&Beta Testing forums, and TheBetaFamily, with little 
success. 


On Saturday, February 16, 2013 6:20:11 PM UTC+10, TreKing wrote:
>
>
> On Fri, Feb 15, 2013 at 12:37 PM, njman >wrote:
>
>> How do people test their beta apps - i.e. released to a few
>> testers - getting back app crashed doesn't help.
>>
>> Can users send back a log file and/or stack trace.
>>
>
> Use something like ACRA get logs and traces of what your app is doing 
> along with a crash.
> Have your testers explain to you how they break your app.
>
>
> -
> 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
android-developers+unsubscr...@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+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/groups/opt_out.




[android-developers] Re: Debugging beta apps

2013-02-17 Thread Guy Smith
I've read somewhere not all errors get reported there. Sorry, can't 
remember where I read that. 

On Saturday, February 16, 2013 6:04:24 AM UTC+10, bob wrote:
>
> In the Google app Developer Control Panel, there's a link that says 
> "Errors" sometimes.  Then you can see how your app crashed for different 
> users.
>
>
>
> On Friday, February 15, 2013 12:40:01 PM UTC-6, dashman wrote:
>>
>> How do users debug their beta apps - once it's released 
>> to users. I'd like to get a better feedback than 'app crashed.
>>
>> Can users send back log files etc.
>>
>> I was thinking about using ASSERT.
>>
>> Is the java assert feature recommended or the Assert class.
>>
>> I noticed that the latter does not display a message on the screen.
>>
>>
>> Help appreciated.
>>
>>

-- 
-- 
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
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+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/groups/opt_out.




[android-developers] Re: sliding in a new layout

2013-01-19 Thread Guy Smith
I have similar functionality. 

I create a ViewGroup, large enough to hold the outgoing View below the 
incoming View. 

I replace the outgoing View with the ViewGroup in the tree, animate a 
translation, then replace the ViewGroup with the incoming View. 

It works well for me. 

Admittedly, I slide the whole screen, so I don't have visibility issues. 
But you should be able to restrict the sliding section using onLayout, I 
guess.

On Sunday, January 20, 2013 12:33:46 PM UTC+10, dashman wrote:
>
> i've got a nested layout that takes up the middle of a screen.
>
> on user input i'd like to slide a new layout over it - just the
> portion of the screen that the original layout spans.
>
> and then later slide it back up - and make it disappear.
>
> i was thinking about using relativelayout - initially making
> the sliding layout invsibile.
>
> but haven't figured out how to make it slide down.
>
> any pointer appreciated - i can look up the details.
>
>
>
>

-- 
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
For more options, visit this group at
http://groups.google.com/group/android-developers?hl=en

[android-developers] Bundle arrays - live or copies?

2012-02-28 Thread Guy Smith
I retrieve an array from a bundle, using getDoubleArray(). I then use
that instance of the array in my code, without copying it.

I'm guessing Bundle is a low-overhead class, and gives me its instance
of the array, rather than making a copy for every getDoubleArray()
call?

I'm using Bundle as an intermediary in my code (not just receiving it
on startup).
Will changes I make to the retrieved array be reflected in the array
that was passed into putDoubleArray() when I built the bundle?

The documentation doesn't specify what happens here. Do we have any
guarantees of behaviour over future versions?

-- 
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
For more options, visit this group at
http://groups.google.com/group/android-developers?hl=en


[android-developers] Re: Automatic "word wrap" for views?

2012-01-30 Thread Guy Smith
The WritingLayout class in  
https://groups.google.com/forum/#!topic/android-developers/ksS0cBFmxxE may 
be useful. 

-- 
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
For more options, visit this group at
http://groups.google.com/group/android-developers?hl=en

[android-developers] Re: Layout supporting "word wrap" for Views?

2012-01-30 Thread Guy Smith
I bit the bullet and wrote a class: WritingLayout is a ViewGroup which lays 
out children horizontally to a given width, then begins a new line. 

Warning: It's a proof-of-concept. You may wish to tighten it up, and 
perhaps add some bells and whistles. 

package com.downacross.util;

import java.util.ArrayList;

import android.content.Context;
import android.graphics.Rect;
import android.view.View;
import android.view.ViewGroup;

/**
 * Left-to-right, then top-to-bottom, layout. 
 * 
 * This layout positions its components similarly to writing text on a 
(Western) page. 
 * It goes left to right up to a given width, then wraps to the start of 
the next line down, and continues. 
 * The children get as much space as they ask for. 
 * 
 * This layout does not know about justification, and does not put space 
between children. 
 * 
 * WARNING: This is not a complete, robust class. For example, there's no 
concurrency protection. 
 * Also, more methods should be overridden, especially the other addView 
methods. 
 */
public class WritingLayout extends ViewGroup {
 /**
 * Holds all component views, in order. 
 */
private final ArrayList childViews = new ArrayList() ; 
 /**
 * Holds layout bounds for corresponding child views. This is set in {@link 
#onMeasure}, and used in {@link #onLayout}. 
 */
private final ArrayList childPositions = new ArrayList() ; 

public WritingLayout(Context context) {
super(context);
}
 /**
 * Adds a child view to the end of the list of children. Currently 31jan12, 
this is the only addView method that should be called. 
 */
@Override
public void addView(View child) {
super.addView(child); // Necessary for event propagation, perhaps other 
framework stuff. 
childViews.add(child); 
childPositions.add(new Rect()); 
}
 @Override
protected void onMeasure(int widthMeasureSpec, int heightMeasureSpec) {
//  Extract incoming constraints
int widthMode = MeasureSpec.getMode(widthMeasureSpec); 
int widthSpecSize = MeasureSpec.getSize(widthMeasureSpec); // This is our 
line-length limit. 
int heightMode = MeasureSpec.getMode(heightMeasureSpec); 
int heightSpecSize = MeasureSpec.getSize(heightMeasureSpec);
//  Measure child views
int childWidthMode = widthMode == MeasureSpec.EXACTLY ? MeasureSpec.AT_MOST 
: widthMode ; 
int childHeightMode = heightMode == MeasureSpec.EXACTLY ? 
MeasureSpec.AT_MOST : heightMode ; 
int childWidthMeasureSpec = MeasureSpec.makeMeasureSpec(childWidthMode, 
widthMode); 
int childHeightMeasureSpec = MeasureSpec.makeMeasureSpec(childHeightMode, 
heightMode); 
for (View childView : childViews) {
childView.measure(childWidthMeasureSpec, childHeightMeasureSpec); 
}
//  Position each child
int acrossPosition = 0 ; // Rightmost edge of last view on this line. 
int lineTop = 0 ; // Bottom edge of previous line. 
int lineHeight = 0 ; // Bottom edge of this line, so far. 
int childCount = childViews.size(); 
for (int i=0 ; i widthSpecSize) { 
// Have filled line, start a new one. 
acrossPosition = 0 ; 
lineTop += lineHeight ; 
lineHeight = 0 ; 
}
//  Place this child, and update progress variables. 
int right = acrossPosition + childWidth ; 
childPosition.set(acrossPosition, lineTop, right, lineTop+childHeight); 
acrossPosition = right ; 
if (childHeight>lineHeight) lineHeight = childHeight ; 
}
//  Set the WritingLayout's measurements. 
int pageHeight = lineTop + lineHeight ; 
this.setMeasuredDimension(widthSpecSize, pageHeight); 
}

@Override
protected void onLayout(boolean changed, int l, int t, int r, int b) {
// Don't know exactly what the 'changed' argument means. 
int childCount = childViews.size(); 
for (int i=0 ; ihttp://groups.google.com/group/android-developers?hl=en

[android-developers] Re: RelativeLayout created in Java not XML - is this possible?

2012-01-24 Thread Guy Smith
Ah! Thank you.

-- 
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
For more options, visit this group at
http://groups.google.com/group/android-developers?hl=en


[android-developers] RelativeLayout created in Java not XML - is this possible?

2012-01-24 Thread Guy Smith
I want to create a RelativeLayout in Java code, rather than using the
XML format.

It seems RelativeLayout.LayoutParams.addRule() would be the way to add
relative positioning constraints. However, this doesn't take a View
anchor argument, just an int anchor argument. Does this mean you can
only use XML-specified Views as the anchor in constraints?

All the examples & tutorials I've found for RelativeLayout assume you
are using XML-specifications. I'm constructing the layout
programmatically because the layout is very dynamic - each region of
the screen has structured content (eg, a crossword square) which
varies according to the size of the crossword chosen, and the degree
of zooming.

-- 
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
For more options, visit this group at
http://groups.google.com/group/android-developers?hl=en


[android-developers] Re: Difference between invalidate and requestLayout for Viewgroup

2012-01-23 Thread Guy Smith
Could the method Javadoc for invalidate() and requestLayout() have
{@see ...} to each other?

There's a lot to learn when you're a newbie to a framework. I've lost
hours on this. Yes, I now see the info at the top of the View class
Javadoc, but it would have been handy to have a pointer to it in the
place I went looking (the method Javadoc).

On Jan 13, 5:30 pm, Dianne Hackborn  wrote:
> Basically, yes.  Invalidate says something in your visuals has changed so
> you need to be redrawn; requestLayout() says something structural has
> changed so a new layout is needed (which also implies eventually redrawing).
>
>
>
>
>
>
>
>
>
> On Thu, Jan 12, 2012 at 6:53 PM, harvinder  wrote:
> > It is my understanding is that when invalidate() is  called on ViewGroup
> > derived class  onDraw gets called. However, when requestLayout is called
> > onMeasure and onLayout gets called.
>
> > Is my understanding correct?
>
> > Truly
> > harvinder
>
> > --
> > 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
> > For more options, visit this group at
> >http://groups.google.com/group/android-developers?hl=en
>
> --
> Dianne Hackborn
> Android framework engineer
> hack...@android.com
>
> 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.

-- 
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
For more options, visit this group at
http://groups.google.com/group/android-developers?hl=en