Resolves #1229. You can view, comment on, or merge this pull request online at:
https://github.com/geany/geany-plugins/pull/1234
-- Commit Summary --
* GeanyLua: Fix geany.activate()
-- File Changes --
M geanylua/docs/geanylua-ref.html (2) M geanylua/glspi_doc.c (66)
-- Patch Links --
https://github.com/geany/geany-plugins/pull/1234.patch https://github.com/geany/geany-plugins/pull/1234.diff
LGBI and :+1: for fixing the doc.
Forgive my curiosity :) Why not ```c if (tab_idx >= 0) { if (tab_idx != gtk_notebook_get_current_page(NOTEBOOK)) { gtk_notebook_set_current_page(NOTEBOOK, tab_idx); } } ``` ?
I haven't looked at this in a while. Behavior originally intended is to "Actvate and focus" a document. The original inner conditional `if (idx != ...)` prevented both. Also, `gtk_notebook_set_current_page` most likely already performs necessary checks, so additional checks wastes processor cycles to produce incorrect behavior.
@xiota pushed 1 commit.
17fe2b18ed41b959a27b691091dc574f280b4027 GeanyLua: Fix geany.activate()
Confirmed original issue described in #1229 and this PR fixes it. Used `list-open-files.lua` to test.
Force pushed to rebase. Also corrected `> 0` to `>= 0`. I had misunderstood @Skif-off's previous comment.
@b4n Should be ready for review and merge.
Any news? In fact, the plugin is broken, because one of its functions is not working (maybe this is not the main function, but then what is the main function? :))).
the plugin is broken, because one of its functions is not working
Anything that needs changes to this PR?
Any news?
I'm waiting for someone to review and commit. Maybe @frlan or @elextr ?
@xiota I meant `geany.activate()`, this function is still broken in upstream.
I'm waiting for someone to review and commit.
Yes, I understand, I just thought that an extra reminder in notifications would remind contributors once again about the unresolved issue. And I hope I wasn't too annoying :))
@Skif-off No problem. Might help to have additional confirmation that this PR is working as expected. You've tested it after the rebase?
You've tested it after the rebase?
Hmm... I thought you tested it. Joke :)) I am not a contributor, so my voice has little weight, but just in case I compiled and tested it 20 minutes ago: works fime, I didn't find any problems.
my voice has little weight ... I didn't find any problems.
Thanks for testing. Helpful for you to have checked in case I miss something else.
@b4n, can you add this to the [2.1.0](https://github.com/geany/geany-plugins/milestone/17) milestone?
I do not know when the new version of Geany is scheduled to be released, there is no alternative solution and it will be sad if all forget about this PR... :)
@frlan Any chance you could take a look and merge? This fixes a bug that has been affecting at least a couple users. Thanks.
github-comments@lists.geany.org