mirror of https://github.com/readrops/Readrops.git
Minor diverse changes
This commit is contained in:
parent
34e8c1b4c2
commit
d20d1e3ed1
|
@ -183,12 +183,7 @@ public class AddFeedActivity extends AppCompatActivity implements View.OnClickLi
|
|||
viewModel.parseUrl(finalUrl)
|
||||
.subscribeOn(Schedulers.io())
|
||||
.observeOn(AndroidSchedulers.mainThread())
|
||||
.subscribe(new SingleObserver<List<ParsingResult>>() {
|
||||
@Override
|
||||
public void onSubscribe(Disposable d) {
|
||||
|
||||
}
|
||||
|
||||
.subscribe(new DisposableSingleObserver<List<ParsingResult>>() {
|
||||
@Override
|
||||
public void onSuccess(List<ParsingResult> parsingResultList) {
|
||||
displayParseResults(parsingResultList);
|
||||
|
|
|
@ -138,7 +138,7 @@
|
|||
android:layout_height="16dp"
|
||||
android:layout_alignParentStart="true"
|
||||
android:layout_centerVertical="true"
|
||||
android:src="@drawable/ic_read_time" />
|
||||
android:src="@drawable/ic_read_time_grey" />
|
||||
|
||||
<TextView
|
||||
android:id="@+id/activity_item_readtime"
|
||||
|
|
|
@ -68,7 +68,7 @@
|
|||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_alignParentStart="true"
|
||||
android:layout_toLeftOf="@id/item_date">
|
||||
android:layout_toLeftOf="@id/item_date_layout">
|
||||
|
||||
<ImageView
|
||||
android:id="@+id/item_feed_icon"
|
||||
|
|
|
@ -44,16 +44,13 @@ public class RSSQuery {
|
|||
*/
|
||||
public RSSQueryResult queryUrl(String url, Map<String, String> headers) throws Exception {
|
||||
Response response = query(url, headers);
|
||||
RSSQueryResult queryResult;
|
||||
|
||||
if (response.isSuccessful()) {
|
||||
String header = response.header(LibUtils.CONTENT_TYPE_HEADER);
|
||||
RSSType type = getRSSType(header);
|
||||
|
||||
if (type == null) {
|
||||
queryResult = new RSSQueryResult(new UnknownFormatException("bad content type : " + header + "for " + url));
|
||||
return queryResult;
|
||||
}
|
||||
if (type == null)
|
||||
return new RSSQueryResult(new UnknownFormatException("bad content type : " + header + "for " + url));
|
||||
|
||||
return parseFeed(response.body().byteStream(), type, response);
|
||||
} else if (response.code() == 304)
|
||||
|
|
Loading…
Reference in New Issue