Only show quickreply on threads

captchafix
Florens Douwes 11 years ago
parent d22ea3deff
commit 7cceca0245
  1. 16
      Clover/app/src/main/java/org/floens/chan/core/manager/ThreadManager.java
  2. 2
      Clover/app/src/main/res/values/strings.xml

@ -237,6 +237,10 @@ public class ThreadManager implements Loader.LoaderListener {
menu.add(Menu.NONE, 9, Menu.NONE, activity.getString(R.string.action_pin));
}
if (loader.getLoadable().isThreadMode()) {
menu.add(Menu.NONE, 5, Menu.NONE, activity.getString(R.string.post_quick_reply));
}
String[] baseOptions = activity.getResources().getStringArray(R.array.post_options);
for (int i = 0; i < baseOptions.length; i++) {
menu.add(Menu.NONE, i, Menu.NONE, baseOptions[i]);
@ -259,22 +263,22 @@ public class ThreadManager implements Loader.LoaderListener {
@Override
public boolean onMenuItemClick(final MenuItem item) {
switch (item.getItemId()) {
case 0: // Quick reply
case 5: // Quick reply
openReply(false);
// Pass through
case 1: // Quote
case 0: // Quote
ChanApplication.getReplyManager().quote(post.no);
break;
case 2: // Info
case 1: // Info
showPostInfo(post);
break;
case 3: // Show clickables
case 2: // Show clickables
showPostLinkables(post);
break;
case 4: // Copy text
case 3: // Copy text
copyToClipboard(post.comment.toString());
break;
case 5: // Report
case 4: // Report
Utils.openLink(activity, ChanUrls.getReportUrl(post.board, post.no));
break;
case 6: // Id

@ -98,13 +98,13 @@ along with this program. If not, see <http://www.gnu.org/licenses/>.
<string name="multiple_posts">posts</string>
<string name="post_info">Info</string>
<string-array name="post_options">
<item>Quick reply</item>
<item>Quote</item>
<item>Info</item>
<item>Show clickables</item>
<item>Copy text</item>
<item>Report</item>
</string-array>
<string name="post_quick_reply">Quick reply</string>
<string name="post_highlight_id">Highlight ID</string>
<string name="post_text_copied_to_clipboard">Text copied to clipboard</string>

Loading…
Cancel
Save