Improved Feedmenu
This commit is contained in:
parent
5c308c7f1e
commit
3608ba18b6
Binary file not shown.
After Width: | Height: | Size: 1.7 KiB |
|
@ -1,6 +1,8 @@
|
||||||
<?xml version="1.0" encoding="utf-8"?>
|
<?xml version="1.0" encoding="utf-8"?>
|
||||||
<menu xmlns:android="http://schemas.android.com/apk/res/android" >
|
<menu xmlns:android="http://schemas.android.com/apk/res/android" >
|
||||||
<item android:id="@+id/remove_item" android:title="@string/remove_label" android:icon="@drawable/content_discard" android:visible="true"></item>
|
<item android:id="@+id/mark_all_read_item" android:title="@string/mark_all_read_label" android:showAsAction="ifRoom|withText"></item><item android:id="@+id/show_info_item" android:icon="@drawable/action_about" android:title="@string/show_info_label" android:showAsAction="always"></item><item android:id="@+id/remove_item" android:title="@string/remove_feed_label" android:icon="@drawable/content_discard" android:visible="true" android:showAsAction="collapseActionView"></item>
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
</menu>
|
</menu>
|
|
@ -55,4 +55,7 @@
|
||||||
<string name="stream_label">Stream</string>
|
<string name="stream_label">Stream</string>
|
||||||
<string name="player_seeking_msg">Seeking</string>
|
<string name="player_seeking_msg">Seeking</string>
|
||||||
<string name="player_playing_msg"></string>
|
<string name="player_playing_msg"></string>
|
||||||
|
<string name="mark_all_read_label">Mark all read</string>
|
||||||
|
<string name="show_info_label">Show information</string>
|
||||||
|
<string name="remove_feed_label">Remove Feed</string>
|
||||||
</resources>
|
</resources>
|
||||||
|
|
|
@ -111,6 +111,9 @@ public class FeedlistFragment extends SherlockListFragment {
|
||||||
public void onPause() {
|
public void onPause() {
|
||||||
super.onPause();
|
super.onPause();
|
||||||
pActivity.unregisterReceiver(contentUpdate);
|
pActivity.unregisterReceiver(contentUpdate);
|
||||||
|
if (mActionMode != null) {
|
||||||
|
mActionMode.finish();
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
private BroadcastReceiver contentUpdate = new BroadcastReceiver() {
|
private BroadcastReceiver contentUpdate = new BroadcastReceiver() {
|
||||||
|
@ -158,6 +161,12 @@ public class FeedlistFragment extends SherlockListFragment {
|
||||||
};
|
};
|
||||||
remover.execute(selectedFeed);
|
remover.execute(selectedFeed);
|
||||||
break;
|
break;
|
||||||
|
case R.id.mark_all_read_item:
|
||||||
|
for (FeedItem feeditem : selectedFeed.getItems()) {
|
||||||
|
manager.markItemRead(getSherlockActivity(), feeditem, true);
|
||||||
|
}
|
||||||
|
fla.notifyDataSetChanged();
|
||||||
|
break;
|
||||||
}
|
}
|
||||||
mode.finish();
|
mode.finish();
|
||||||
return true;
|
return true;
|
||||||
|
|
Loading…
Reference in New Issue