tag:blogger.com,1999:blog-5837865295676240265.post8075511052141201494..comments2023-10-15T18:50:22.212+11:00Comments on Preposterous! Egregious!: Releasing an App for Android - Part 1David Barrihttp://www.blogger.com/profile/05426582122438954031noreply@blogger.comBlogger7125tag:blogger.com,1999:blog-5837865295676240265.post-80410730313830824972013-08-30T10:01:24.700+10:002013-08-30T10:01:24.700+10:00Hey. Nah, not exactly but I did make some template...Hey. Nah, not exactly but I did make some template projects with Scala + Android that you can look at or prune down to what you need.<br /><br />https://github.com/japgolly/reference/tree/master/android-scala-maven-singleDavid Barrihttps://www.blogger.com/profile/05426582122438954031noreply@blogger.comtag:blogger.com,1999:blog-5837865295676240265.post-62445451268395047972013-08-24T00:07:35.447+10:002013-08-24T00:07:35.447+10:00David Barri,
Do you have a step by step tutorial ...David Barri,<br /><br />Do you have a step by step tutorial in how to confifure an Scala environment to develop Android application?<br /><br />ThanksBlueCarrothttps://www.blogger.com/profile/02811598965064487524noreply@blogger.comtag:blogger.com,1999:blog-5837865295676240265.post-7305855923056455002013-03-16T07:03:34.775+11:002013-03-16T07:03:34.775+11:00Thanks that cleared things up :) I'm developin...Thanks that cleared things up :) I'm developing an ad/no-ad app myself so I'll be using that trick as well!Frode Nilsenhttps://www.blogger.com/profile/11779675194677466654noreply@blogger.comtag:blogger.com,1999:blog-5837865295676240265.post-58699262366681382392013-03-09T14:07:02.529+11:002013-03-09T14:07:02.529+11:00Hi there Frode, thanks for the positive feedback :...Hi there Frode, thanks for the positive feedback :)<br /><br />Re: hardcoded measurements, I may have been unclear. I'm not referring to the measurement unit, the developer should choose between dp/sp/px etc as appropriate for their needs and the situation; rather I was referring to storing the numbers themselves in the layout XML. Say you have an attribute such as android:textSize="20sp" in your layout XML, if you're trying to save space on a small or low-density screen you're probably going to want to change the 20sp to a 18sp. If the 20sp is in the layout XML you'd have to copy & paste the entire layout to one with a different qualifier which is bad because it's more to maintain and will probably go out of sync. In nearly all cases your layout itself will be fine, it's just the numbers/meaurements you'll want to change, thus, it's best not to put the 20sp in the layout XML (which is what I meant by hardcoded), but rather put it in a dimensions XML, give it a name, reference it in the layout XML (ie. android:textSize="@dimen/size"). That way you can modify just that number in isolation, the layout remains shared.<br /><br />For the ads vs no-ads, I did this.<br />1. Create a library, free, paid projects. The free & paid projects will inherit the library one.<br />1. Create layout XMLs normally in the library project and use to use ads.<br />2. Create an empty ads layout XML in the library. It will include just a and the visibility will be "gone".<br />3. In the paid app, create an ads XML with the same name and use a proper AdView.<br />Have a look at template #3 on my other post.<br />http://japgolly.blogspot.com.au/2013/02/android-project-templates.html<br /><br />Hope that helps!David Barrihttps://www.blogger.com/profile/05426582122438954031noreply@blogger.comtag:blogger.com,1999:blog-5837865295676240265.post-55786196779652510482013-03-09T13:55:33.788+11:002013-03-09T13:55:33.788+11:00Oh really? Mate, thank you for that information! I...Oh really? Mate, thank you for that information! I wasn't aware of that. That explains the frustration I've seen in some app review comments. Hmm, I'll have to spend some time looking into and thinking about that.David Barrihttps://www.blogger.com/profile/05426582122438954031noreply@blogger.comtag:blogger.com,1999:blog-5837865295676240265.post-91809023917380371102013-03-05T18:52:06.590+11:002013-03-05T18:52:06.590+11:00GREAT article! I love the structure and your to-th...GREAT article! I love the structure and your to-the-point style of writing in this post. A lot of tips to pick up on for everybody here, including experienced developers.<br /><br />A have a couple of questions regarding 1.6 though. Tip #5 please explain why it's obvious not to have "hardcoded" measures in the XML. Do you include Density Pixels ("dp") in your definition of "hardcoded"? Since Android picks XML files based on screen size and resolution as you obviously are aware of, I don't see why it's a problem, and in fact the official documentation is scattered with examples of this.<br /><br />Second, how did you implement the ads vs no-ads layout files in practice? Did you have separate XML files for the no-ads version, and if so - how did you make the Android framework load them instead of the default files for the set resolution?Frode Nilsenhttps://www.blogger.com/profile/11779675194677466654noreply@blogger.comtag:blogger.com,1999:blog-5837865295676240265.post-41444503689362410932013-03-05T08:40:05.804+11:002013-03-05T08:40:05.804+11:00I'm one of those people vehement about creatin...I'm one of those people vehement about creating an app that works in landscape. Or, at the bare minimum, *not locking it to portrait*!<br /><br />Reason being that there are devices out there whose default orientation is landscape. There are a bunch of such phones, but I bought a Samsung Galaxy Y Pro specifically for testing this stuff.Anonymousnoreply@blogger.com