Fix broken (un)equip clicks

This commit is contained in:
2020-01-27 20:00:41 -05:00
parent df4ab21ff1
commit c2cdeb4990
2 changed files with 2 additions and 2 deletions

View File

@@ -1339,7 +1339,7 @@ bool handle_action(const sf::Event& event) {
item_hit = item_sbar->getPosition() + i;
switch(j) {
case ITEMBTN_NAME: // equip
case ITEMBTN_NAME: case ITEMBTN_ICON: // equip
handle_equip_item(item_hit, need_redraw);
break;
case ITEMBTN_USE:

View File

@@ -438,7 +438,7 @@ void place_buy_button(short position,short pc_num,short item_num) {
void place_item_graphic(short which_slot,short graphic) {
rectangle from_rect = {0,0,18,18},to_rect;
item_area_button_active[which_slot][ITEMBTN_ICON] = true;
item_area_button_active[which_slot][ITEMBTN_NAME] = item_area_button_active[which_slot][ITEMBTN_ICON] = true;
from_rect.offset((graphic % 10) * 18,(graphic / 10) * 18);
to_rect = item_buttons[which_slot][ITEMBTN_ICON];
std::shared_ptr<const sf::Texture> src_gw;