diff options
author | Andrew Dolgov <[email protected]> | 2016-04-12 08:57:51 +0300 |
---|---|---|
committer | Andrew Dolgov <[email protected]> | 2016-04-12 08:57:51 +0300 |
commit | e9723861e7f37e78129ef0d75a1b4d47eda4930b (patch) | |
tree | b58feff502b60140a4cb1d91701f88558e86c10e | |
parent | 17c70e6f9475d164eaebfd5f9a8de453820787af (diff) | |
parent | c234648de4a6869343875d4ea80e948d4af6a1e8 (diff) |
Merge branch 'master' of git.fakecake.org:tt-rss-android
-rwxr-xr-x | build.gradle | 2 | ||||
-rw-r--r-- | gradle/wrapper/gradle-wrapper.properties | 4 | ||||
-rwxr-xr-x | org.fox.ttrss/src/main/java/org/fox/ttrss/ArticlePager.java | 2 | ||||
-rw-r--r-- | org.fox.ttrss/src/main/java/org/fox/ttrss/DetailActivity.java | 1 | ||||
-rwxr-xr-x | org.fox.ttrss/src/main/java/org/fox/ttrss/HeadlinesFragment.java | 7 | ||||
-rw-r--r-- | tt-rss-android.iml | 2 |
6 files changed, 10 insertions, 8 deletions
diff --git a/build.gradle b/build.gradle index f0411ebb..fd48ba51 100755 --- a/build.gradle +++ b/build.gradle @@ -4,7 +4,7 @@ buildscript { jcenter() } dependencies { - classpath 'com.android.tools.build:gradle:1.3.0' + classpath 'com.android.tools.build:gradle:2.0.0' } } diff --git a/gradle/wrapper/gradle-wrapper.properties b/gradle/wrapper/gradle-wrapper.properties index 754c2b19..77340c2f 100644 --- a/gradle/wrapper/gradle-wrapper.properties +++ b/gradle/wrapper/gradle-wrapper.properties @@ -1,6 +1,6 @@ -#Tue Jan 27 11:47:07 AST 2015 +#Mon Apr 11 22:43:55 MSK 2016 distributionBase=GRADLE_USER_HOME distributionPath=wrapper/dists zipStoreBase=GRADLE_USER_HOME zipStorePath=wrapper/dists -distributionUrl=https\://services.gradle.org/distributions/gradle-2.2.1-all.zip +distributionUrl=https\://services.gradle.org/distributions/gradle-2.10-all.zip diff --git a/org.fox.ttrss/src/main/java/org/fox/ttrss/ArticlePager.java b/org.fox.ttrss/src/main/java/org/fox/ttrss/ArticlePager.java index 6c3f90da..f6ac6b30 100755 --- a/org.fox.ttrss/src/main/java/org/fox/ttrss/ArticlePager.java +++ b/org.fox.ttrss/src/main/java/org/fox/ttrss/ArticlePager.java @@ -175,7 +175,7 @@ public class ArticlePager extends Fragment { } if (m_article != null) { - if (m_article.id == 0 || m_articles.indexOf(m_article) == -1) { + if (m_article.id == 0 || !m_articles.containsId(m_article.id)) { if (m_articles.size() > 0) { m_article = m_articles.get(0); m_listener.onArticleSelected(m_article, false); diff --git a/org.fox.ttrss/src/main/java/org/fox/ttrss/DetailActivity.java b/org.fox.ttrss/src/main/java/org/fox/ttrss/DetailActivity.java index 379661c4..dafcbe66 100644 --- a/org.fox.ttrss/src/main/java/org/fox/ttrss/DetailActivity.java +++ b/org.fox.ttrss/src/main/java/org/fox/ttrss/DetailActivity.java @@ -279,6 +279,7 @@ public class DetailActivity extends OnlineActivity implements HeadlinesEventList Article article = hf.getActiveArticle(); if (article == null && hf.getAllArticles().size() > 0) { + article = hf.getAllArticles().get(0); hf.setActiveArticle(article); diff --git a/org.fox.ttrss/src/main/java/org/fox/ttrss/HeadlinesFragment.java b/org.fox.ttrss/src/main/java/org/fox/ttrss/HeadlinesFragment.java index b69fe3be..52b9de48 100755 --- a/org.fox.ttrss/src/main/java/org/fox/ttrss/HeadlinesFragment.java +++ b/org.fox.ttrss/src/main/java/org/fox/ttrss/HeadlinesFragment.java @@ -598,8 +598,9 @@ public class HeadlinesFragment extends Fragment implements OnItemClickListener, if (result != null) { m_refreshInProgress = false; - if (m_articles.indexOf(m_activeArticle) == -1) + if (m_activeArticle != null && !m_articles.containsId(m_activeArticle.id)) { m_activeArticle = null; + } if (m_firstIdChanged) { m_articles.add(new Article(ARTICLE_SPECIAL_TOP_CHANGED)); @@ -613,7 +614,9 @@ public class HeadlinesFragment extends Fragment implements OnItemClickListener, // not sure why but listview sometimes gets positioned while ignoring the header so // top headline content becomes partially obscured by the toolbar on phones // (not reproducible on avd) - if (!fappend) m_list.smoothScrollToPosition(0); + if (!fappend) { + m_list.smoothScrollToPosition(0); + } } else { if (m_lastError == ApiError.LOGIN_FAILED) { diff --git a/tt-rss-android.iml b/tt-rss-android.iml index 58a44a3e..e26286a6 100644 --- a/tt-rss-android.iml +++ b/tt-rss-android.iml @@ -9,8 +9,6 @@ </facet> </component> <component name="NewModuleRootManager" LANGUAGE_LEVEL="JDK_1_6" inherit-compiler-output="true"> - <output url="file://$MODULE_DIR$/build/classes/main" /> - <output-test url="file://$MODULE_DIR$/build/classes/test" /> <exclude-output /> <content url="file://$MODULE_DIR$"> <excludeFolder url="file://$MODULE_DIR$/.gradle" /> |