From 803afcc6d2573a85a493d7bbab2c3a4498823869 Mon Sep 17 00:00:00 2001 From: Andrew Dolgov Date: Wed, 7 Dec 2011 15:30:06 +0300 Subject: [PATCH] fix orientation crashes in offlineactivity, bump version --- AndroidManifest.xml | 4 ++-- src/org/fox/ttrss/MainActivity.java | 4 ++-- src/org/fox/ttrss/OfflineActivity.java | 6 +++--- 3 files changed, 7 insertions(+), 7 deletions(-) diff --git a/AndroidManifest.xml b/AndroidManifest.xml index d10d02fb..896bb55c 100644 --- a/AndroidManifest.xml +++ b/AndroidManifest.xml @@ -1,8 +1,8 @@ + android:versionCode="38" + android:versionName="0.3.5" > diff --git a/src/org/fox/ttrss/MainActivity.java b/src/org/fox/ttrss/MainActivity.java index 3310dcd2..4daab3da 100644 --- a/src/org/fox/ttrss/MainActivity.java +++ b/src/org/fox/ttrss/MainActivity.java @@ -386,6 +386,8 @@ public class MainActivity extends FragmentActivity implements OnlineServices { @Override public void onCreate(Bundle savedInstanceState) { + initDatabase(); + m_prefs = PreferenceManager .getDefaultSharedPreferences(getApplicationContext()); @@ -433,8 +435,6 @@ public class MainActivity extends FragmentActivity implements OnlineServices { setContentView(R.layout.main); - initDatabase(); - IntentFilter filter = new IntentFilter(); filter.addAction(OfflineDownloadService.INTENT_ACTION_SUCCESS); filter.addAction(OfflineUploadService.INTENT_ACTION_SUCCESS); diff --git a/src/org/fox/ttrss/OfflineActivity.java b/src/org/fox/ttrss/OfflineActivity.java index 54b62fb4..51cdf911 100644 --- a/src/org/fox/ttrss/OfflineActivity.java +++ b/src/org/fox/ttrss/OfflineActivity.java @@ -54,6 +54,8 @@ public class OfflineActivity extends FragmentActivity implements @Override public void onCreate(Bundle savedInstanceState) { + initDatabase(); + m_prefs = PreferenceManager .getDefaultSharedPreferences(getApplicationContext()); @@ -97,8 +99,6 @@ public class OfflineActivity extends FragmentActivity implements setContentView(R.layout.main); - initDatabase(); - Log.d(TAG, "m_smallScreenMode=" + m_smallScreenMode); Log.d(TAG, "m_compatMode=" + m_compatMode); @@ -236,7 +236,7 @@ public class OfflineActivity extends FragmentActivity implements @Override public void onResume() { super.onResume(); - + boolean needRefresh = !m_prefs.getString("theme", "THEME_DARK").equals( m_themeName) || m_prefs.getBoolean("enable_cats", false) != m_enableCats;