Skip to content

Commit

Permalink
minor mods
Browse files Browse the repository at this point in the history
  • Loading branch information
0xeb committed Dec 27, 2021
1 parent dd82618 commit b4e23df
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions qscripts.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -726,11 +726,11 @@ struct qscripts_chooser_t: public plugmod_t, public chooser_t
return ctx->widget_title == ch->title;
}
public:
void setup(qscripts_chooser_t *ch, action_desc_t &action_desc)
bool setup(qscripts_chooser_t *ch, action_desc_t &action_desc)
{
this->ch = ch;
action_desc.handler = this;
register_action(action_desc);
return register_action(action_desc);
}
};

Expand Down Expand Up @@ -774,7 +774,7 @@ struct qscripts_chooser_t: public plugmod_t, public chooser_t
{
virtual action_state_t idaapi update(action_update_ctx_t *ctx) override
{
return AST_ENABLE;
return ch->has_selected_script() ? AST_ENABLE : AST_DISABLE;
}

virtual int idaapi activate(action_activation_ctx_t *ctx) override
Expand Down

0 comments on commit b4e23df

Please sign in to comment.