From 5054f41ed42d8659f0be85be2c71e9a9291a5ba1 Mon Sep 17 00:00:00 2001 From: Samuel Tardieu Date: Wed, 30 May 2012 15:32:54 +0200 Subject: Refactoring: cleanup application startup This cleanup: - do not pass the cgeoapplication singleton to cgData - do not pretend that CacheCache is a singleton, it only occurs to have one instance in cgData - start version updater thread in cgeoapplication.onCreate(), once the object has been created, to avoid risking accessing the sole instance before it is fully initialized, this could lead to a crash at initialization time - use an available context object to access version information, which is not accessed frequently --- main/src/cgeo/geocaching/AboutActivity.java | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'main/src/cgeo/geocaching/AboutActivity.java') diff --git a/main/src/cgeo/geocaching/AboutActivity.java b/main/src/cgeo/geocaching/AboutActivity.java index cef5830..b7a14ff 100644 --- a/main/src/cgeo/geocaching/AboutActivity.java +++ b/main/src/cgeo/geocaching/AboutActivity.java @@ -20,7 +20,7 @@ public class AboutActivity extends AbstractActivity { setContentView(R.layout.about); setTitle(res.getString(R.string.about)); - ((TextView) findViewById(R.id.about_version_string)).setText(Version.getVersionName()); + ((TextView) findViewById(R.id.about_version_string)).setText(Version.getVersionName(this)); ((TextView) findViewById(R.id.contributors)).setMovementMethod(LinkMovementMethod.getInstance()); ((TextView) findViewById(R.id.changelog)).setMovementMethod(LinkMovementMethod.getInstance()); } -- cgit v1.1