Tuesday, October 11, 2011

Pages From 99% I liked

This piece on the power of uncertain times was a good read:

This one about 25 insights on how to be a better writer was also worth a read:

And this about how a talented executive learned to lead:

And last but not least, 12 attributes of a really great place to work:

Thursday, October 06, 2011

Android Application Trouble with "android.hardware.screen.landscape"

The Problem:

When you upload your APK to the Android Market it is flagged with an awful and mysterious permisison called "android.hardware.screen.landscape" and this limits your devices to a very small number.


The Issue:

You have a landscape application that does not support portrait. However, your application will run on many devices that are rotated even if they do not specifically have the landscape hardware (ie, no portrait mode?)


The Solution:

Add the following line to your AndroidManifest.xml and everything will be fine.




Notes


At some point Google added this as a filter during upload. It came on and off for a while depending on what SDK you use. Various people have posted / Tweet'd that it can be fixed with an SDK upgrade. That may or may not be true on your platform or at the time you read this.

Monday, July 25, 2011

Trese Brother's Software: Cyber Knights RPG Reaches 50,000 Downloads

Trese Brother's Software: Cyber Knights RPG Reaches 50,000 Downloads: "Andrew and I wanted to write a quick blog post and say 'Thank You, thank you' to everyone who has downloaded, played and rated Cyber Knights..."

Saturday, July 23, 2011

Android Development on Windows

If you are doing any Android development on Windows 7 OS you should install these Codecs:


They will really help you get around inside the media that Android APK are packaging, like OGG files.

Follow me on Twitter @corytrese

Tuesday, June 28, 2011

Monday, June 27, 2011

Codedependent: Android Rendering Options

Codedependent: Android Rendering Options: "I've given some talks about Android graphics recently, and the same questions keep coming up: What is Renderscript appropriate for? Is it a ..."

Friday, June 03, 2011

Android ADT Eclipse: Unknown error: java.lang.NullPointerException

Do you have this error?

[2011-06-03 09:52:51 - AndroidSamNinteen] Unknown error: java.lang.NullPointerException

If you have this error, GIVE UP NOW.

This error cannot be fixed.

Eclipse is corrupted in a way that cannot be recovered.

the only solution I have ever found (sixth time) is the second you see this error, remove everything, delete all files and start over.

1. New install of Eclipse
2. New install of ADT
3. Recreate project by hand (import source files)
4. Now it will build

Thursday, June 02, 2011

Eclipse Android

#Eclipse ADT for #Android and Windows XP -- a match made in heaven. They both need to be restarted about 27 times a day.

Questions I should have Asked at Google IO

Questions I should have asked :

Why 9-patches, why not XML?
Why is /tools/ so bad?
Does Google use any of these tools?

Wednesday, June 01, 2011

Working From Home

I'm stuck working from my house a lot due to the fact that they re-assigned my desk at work to a contractor. (Seriously.)


There are some good tips from our friends over at GoPayment.

Wednesday, May 25, 2011

Class for Creating Bold Text in Android

This class has saved me TONS of time ...


public class StyleableSpannableStringBuilder extends SpannableStringBuilder {

public StyleableSpannableStringBuilder appendWithStyle(CharacterStyle c, CharSequence text) {
super.append(text);
final int startPos = length() - text.length();
setSpan(c, startPos, length(), 0);
return this;
}

public StyleableSpannableStringBuilder appendBold(CharSequence text) {
return appendWithStyle(new StyleSpan(Typeface.BOLD), text);
}

public StyleableSpannableStringBuilder appendItalic(CharSequence text) {
return appendWithStyle(new StyleSpan(Typeface.ITALIC), text);
}
}

Wednesday, May 18, 2011

Dealing with the "gen" folder in Android -- Clean, Error, Clean, Build, Etc

From StackOverflow:

http://stackoverflow.com/questions/3820517/clean-in-eclipse-temporarily-destroys-android-project-with-error-message-missing


So valuable I needed to repost it

We have finally tracked the last problem regarding this bug.

The "clean" action used to always delete the "gen" folder which was wrong. This was fixed in ADT 8 or 9, I can't remember.

However, if the "gen" folder is marked as derived it still gets deleted which leads to the error.

When the "New Project Wizard" is run, the gen folder is created normally, without the "derived" flag, so this is fine.

The following scenario however is broken:

  • delete manually gen, or
  • check in the source code in a repository (git/svn/...) and don't put the "gen" folder in there, then do a check out on another computer.

  • This leads to ADT recreating automatically the "gen" folder during build, this time enabling the "derived" flag, which will trigger the wrong behavior on "clean".

The temporary solution is to:

  • right click "gen"
  • choose "Properties"
  • uncheck "Derived"

as long as the "gen" folder doesn't get deleted you'll be able to clean your project without side effect.

I just checked in a fix to: - never mark the folder as "derived" - during clean, first remove the "derived" flag from "gen" so that it doesn't get deleted in the case of older projects. Patch is visible at:https://review.source.android.com/#change,22410

Friday, May 13, 2011

Bookmarks and Reading for 5/13

Artificial Intelligence
Anyone who is trying to build compelling single player games will be faced with the need to create a compelling second player -- the AI.



IDE vs. Command Line
For those of us who are building in Eclipse for our Android projects, there is another way if you are willing to work at it.



Thursday, May 12, 2011

Why the HTML5 vs. Flash Debate Is Already Over

This is a battle of one vs. many.

Adobe vs. Google/Apple/Microsoft/Opera

JavaScript and HTML5 cannot help but win because they have numbers.

Maybe not browser numbers yet -- but Adobe doesn't even make a browser.

Saturday, April 16, 2011

Trese Brother's Software: Star Traders RPG v3.6.9 Released

Trese Brother's Software: Star Traders RPG v3.6.9 Released: "The newest version of Star Traders RPG has been released to the Android Market! You can download the free to play edition also available f..."

Another release of my Star Traders RPG game, a from-scratch one-man development project using Java and Eclipse.

Thursday, April 14, 2011

Trese Brother's Software: Star Traders RPG v3.6.8 Released

Trese Brother's Software: Star Traders RPG v3.6.8 Released: "Full Screen Option Better Honeycomb Support Improved Game Skins Added First 4 Backgrounds for Game Screens Improved Map Movement Performance..."

Friday, April 08, 2011

Bad Idea

Geeking out reading old backstory of The Ur-Quan Masters on Wiki pages when I should be coding

Wednesday, April 06, 2011

Refactoring Tools: Eclipse v. Visual Studio 2010

After coding with both Visual Studio 2010 Professional and Eclipse Basic 3.6 I can honestly say, Visual Studio sucks at refactoring.

The basic "change method signature" tool in Eclipse -- which is free -- is honestly at least 5 times better than the Visual Studio version which cost me -- literally -- thousands of dollars.

It seems that the best way to get Visual Studio to refactor at roughly the same level as Eclipse is to purchase ANOTHER commercial product -- ReSharper to plug into Visual Studio and bring up the refactoring. Really?

Tuesday, April 05, 2011

Telerik RadControls

I would not trust anything they say about the capabilities of this application component outside of our own ability to verify and test it.
 
I have opened over 10 tickets with TELERIK regarding these controls and not a single one of them has been resolved with "the documentation was correct, here is the configuration parameter you need."
 
Resolutions are most often are "You do not understand ASP.net" or "none of our other clients use load balancers."
 
Short answer -- don't trust Telerik any farther than you can throw them.

Sunday, April 03, 2011

Android Market for Publishers has been up and down for days/weeks ... I press reload every 10 or 15 minutes and push updates the moment it shows me something that works. Sometimes the updates, work, sometimes they don't. Pretty random, but you always get something like this at the end:

Google Android Market User Interface

Android Market Stability Down to 50%?

We're into the second week of nasty Android Market problems right now

Problems range from:
1) Getting 404 on the page
2) Not loading any applications in the console
3) Being told your applications don't belong to you
4) Statistics off by an order of magnitude
5) Data not updating
6) Google Checkout skipping a day in payments
7) Updates Failing to Publish

Thursday, March 31, 2011

Amazon Android Developer App Market Is Terrible Right Now

Starting to regret the Amazon AppStore choice! I really feel cheated and I'm considering taking my applications down. @amznappstoredev

Tuesday, March 22, 2011

Uploadify and ASP.Net with jQuery for File Upload using HttpModule

If you are managing any type of content management system using ASP.Net you are probably using jQuery in some respects. One useful browser-side plugin for jQuery uses Flash to upload files. This plugin is called Uploadify and ships with a PHP server side component. There is a great post on ASP.Net snippets about replacing the File Upload Server Side component with a C#/.Net HttpModule for IIS.

http://www.aspsnippets.com/Articles/Multiple-File-Uploads-Gmail-Style-using-JQuery-and-ASP.Net.aspx

Thursday, March 03, 2011

Amazon Android Developer App Market Is Terrible Right Now

Today (March 2011) the Amazon.com Android App Market is a total mess.

They are using insecure and out of date technology like FTP, failing to provide basic documentation on DRM and pretty much ignoring all requests for information.

It took (not a joke) more than 2 weeks to get the "I have found a technical person to ask" level response from the sales contact at http://twitter.com/#!/amznappstoredev

I really hope that they work on getting it together soon, because right now it's a total joke.

Thursday, February 24, 2011

Hot Swap AHCI Bay Rocks Socks

OK guys this Super-Micro AHCI hot-swap SATA enclosure rocks socks. I am super happy.

Today is boxing day for my huge collection of external drives. I am no longer a slave to your crappy firewire interface, stupid power bricks or extreme heat generation and low quality fans!

Now I use a fully backed AHCI hotswap 8-bay and buy the SATA drives internal and on the cheap!

Tuesday, February 22, 2011

I'm backing Google on this one

Guess what? A loose alliance of hardware and software manufacturers are going to create an ecosystem that topples Apple tech-monotone

Thursday, February 17, 2011

Adding EULA or Introduction Screen to Android App

Have some important text that always needs to be displayed and approved by the user when it changes? Common use case includes compliance notifications, license text or tutorials.

This useful Android development blog post outlines an excellent pattern for adding an EULA to your Android Java application:

Wednesday, February 16, 2011

Android Disappointment

Shouldn't Android / Java have a CORE SDK / Language feature like "File.IO.File.Copy()" because it really seems obvious to me.

I am totally shocked that I spent 30 minutes trying to determine the optimal way to copy a file and it is like 30 lines long and looks dangerous.

Why not make it simple? Write once, run anywhere. What happened to that?

Servers Direct

I have been having a wonderful time working with the system integration Servers Direct.

After more than five years of upgrading, extending and repairing a pair of workstations from earlier in the decade I decided to upgrade.

The two machines I was using were AMD x64 CPU systems and were built around gaming motherboards from DFI and NVidia. Never really intended as gaming boxes, I suffered a lot from expandability, heat and space issues using essentially consumer grade components for workstation grade work.

So this time I decided to make sure that it got done, and got done right. To that end I selected only workstation class components to build a machine that is certain to last comfortably for several long years of hard service.

For me, when I think about workstation class motherboards I think about Tyan and SuperMicro.

In the 1990s I was a die-hard Intel user and made the switch to AMD around the time of the Tyan Tiger and the Opteron (around 2003.) I ended up settling on Athlon64 processors in the end, but the Intel components were retired.

Now, in 2011 I have returned to my roots with the Xeon and Intel chipsets. Thank you Super Micro and Servers Direct.

More to come in future posts about the new computer experience ...

Windows 7 x64 Woes

I am having some small issues as I work towards adjusting to the new operating system.

One issue that hurts me is that I cannot seem to make PreviewExtractor.exe (x86) like the Windows 7 environment, even with XP SP2 compatibility turned on.

If you are not using Windows 7, I suggest you take a look at this:

Really useful if you need fast JPG of NEF or RAW files.

Tuesday, February 15, 2011

Chrome MailTo: Links in Windows 7 x64

Windows 7 seems to have a lot of configuration issues. It doesn't come with (at least my disk) mapping for the MailTo: URL type.

I installed this Google Chrome Extension to make it work in my browser.

Monday, February 14, 2011

Robotium Enables Black Box Unit Testing with Android Mobile Applications and Games

JUnit is the unit testing framework that really started it all and has a great number of mature features and add-on projects. One such project is Robotium which enabled wonderful black box testing of your Android application:

http://code.google.com/p/robotium/

You can even control it with the very friendly Selenium Remote-Control:


While I was searching Twitter for real-time updates to these subjects that I could include in this blog, I found a reference to RoboGuice which is an Android DI / IOC container. I did not know it existed, but I do like Guice:


Perhaps something to look at for an upcoming complex application ...

G-Mail Tasks Day #1

I am going to start a few day adventure based on using Google Tasks to keep track of my to do issue list.

Email To Tasks
I will make use of the "Add E-Mail to Tasks" feature found under the "More Actions" button.

Tasks To Email
I will make use of the "E-Mail Tasks to Me" to have a list on my phone or when I need a summary on a big screen.

Interesting Android UI Study

This interesting Android mobile UI study includes side-by-side comparisons of several popular social media applications running on Android.

Why I am not Publishing on Amazon.com Android App Store

Dear Amazon,

I am still trying to find someone to talk to about the DRM system! I've been poking around on Twitter and reading blogs but have had little success.

Most of the information I've been able to locate is regarding how to remove the DRM protection, which seems to be more detailed than Amazon's own docs.

Any feedback or explanation on the lack of details? Seems like a pretty big miss. Here is what I get from Google.

Documentation, Source Code and Reference Implementations:

I would really like to use your Amazon Application Store, but you are making it very hard to entrust my APK and hard work to your DRM system.

Tuesday, January 25, 2011

Blocking E-Freedom

EFreedom.com is an annoying StackOverflow clone.

You can block is by adding "-site:efreedom.com" to your Google searches.

Best way to do this using Chrome:

1> Options
2> Default Search Providers -> Click "Manage"
3> Add "-site:efreedom.com" to your Android search customs OR all Google searches

Or you could use use it ad-hoc

Monday, January 10, 2011

Make Google Chrome Search Twitter

Options > Default Search > Manage

Select "Add" in the Mange Search Providers dialog

Field1: Twitter
Field2: tw
Field3: http://twitter.com/#!/search/%s

now just type "tw Star Traders" into Google Chrome to search twitter for Star Traders

Make Google Chrome Search Checkout

Options > Default Search > Manage

Select "Add"

Field1: Checkout
Field2: Checkout
Field3: https://checkout.google.com/sell/searchResults?searchField=%s&searchSubmit=Search&ordersTable=1&backToSearch=false&backToInbox=1&showClosed=false

Make Chrome Search Android Documentation

Open: Options
In the "Default Search" section of "Basics" configuration, find the "Manage" button for Search Providers.

To add a Google Android search provider, in the Search dialog, press "Add"

Field 1: Android
Field 2: Droid
Field 3: http://developer.android.com/search.html#q=%s&t=0

Now you can type "Droid View" to search the Android documentation for the word 'View'

Try it out!