<p><a class="user-mention" data-hovercard-type="user" data-hovercard-url="/hovercards?user_id=1010248" data-octo-click="hovercard-link-click" data-octo-dimensions="link_type:self" href="https://github.com/frlan">@frlan</a> The change here allows a GeanyPy plugin to tell Geany it <em>did</em> handle a keybinding, preventing any other handler using the same binding to run.</p>
<p>The problem is kinda tricky in real situation because this feature is more or less broken in Geany, as there's no real way to tell which handler will be called first, so it only works if all handlers on the same binding are well-behaved.</p>
<p>Anyway, to test, for example make a GeanyPy plugin with 2 binding handlers that do something visible (log a message or something). Then, bind those both to the same key combo, and see they both run.  Now, try and follow Geany API to return <code>True</code> in the handlers, which should prevent the other ones from running.  Before this patch, both still run.  After, only the first one should (given it returns <code>True</code>).</p>

<p style="font-size:small;-webkit-text-size-adjust:none;color:#666;">—<br />You are receiving this because you are subscribed to this thread.<br />Reply to this email directly, <a href="https://github.com/geany/geany-plugins/pull/809#issuecomment-484844904">view it on GitHub</a>, or <a href="https://github.com/notifications/unsubscribe-auth/AAIOWJYBAXA777NKUQSI2WTPRGNPLANCNFSM4GNYXGTQ">mute the thread</a>.<img src="https://github.com/notifications/beacon/AAIOWJ6NKKPRR2D7XWDHG5TPRGNPLANCNFSM4GNYXGTQ.gif" height="1" width="1" alt="" /></p>
<script type="application/json" data-scope="inboxmarkup">{"api_version":"1.0","publisher":{"api_key":"05dde50f1d1a384dd78767c55493e4bb","name":"GitHub"},"entity":{"external_key":"github/geany/geany-plugins","title":"geany/geany-plugins","subtitle":"GitHub repository","main_image_url":"https://github.githubassets.com/images/email/message_cards/header.png","avatar_image_url":"https://github.githubassets.com/images/email/message_cards/avatar.png","action":{"name":"Open in GitHub","url":"https://github.com/geany/geany-plugins"}},"updates":{"snippets":[{"icon":"PERSON","message":"@b4n in #809: @frlan The change here allows a GeanyPy plugin to tell Geany it *did* handle a keybinding, preventing any other handler using the same binding to run.\r\n\r\nThe problem is kinda tricky in real situation because this feature is more or less broken in Geany, as there's no real way to tell which handler will be called first, so it only works if all handlers on the same binding are well-behaved.\r\n\r\nAnyway, to test, for example make a GeanyPy plugin with 2 binding handlers that do something visible (log a message or something). Then, bind those both to the same key combo, and see they both run.  Now, try and follow Geany API to return `True` in the handlers, which should prevent the other ones from running.  Before this patch, both still run.  After, only the first one should (given it returns `True`)."}],"action":{"name":"View Pull Request","url":"https://github.com/geany/geany-plugins/pull/809#issuecomment-484844904"}}}</script>
<script type="application/ld+json">[
{
"@context": "http://schema.org",
"@type": "EmailMessage",
"potentialAction": {
"@type": "ViewAction",
"target": "https://github.com/geany/geany-plugins/pull/809#issuecomment-484844904",
"url": "https://github.com/geany/geany-plugins/pull/809#issuecomment-484844904",
"name": "View Pull Request"
},
"description": "View this Pull Request on GitHub",
"publisher": {
"@type": "Organization",
"name": "GitHub",
"url": "https://github.com"
}
}
]</script>