LayoutManager plugin compatibility

Asked by Alexey on 2016-11-02

Hello. I am not very experienced in Python and I've found that in one of recent commits you've removed get_top_window def from utils module, and this breaks very handy layout manager plugin. Can you bring it back in future release? I've added this function locally in file and plugin looks to work okay now.
Thank you.

Question information

English Edit question
Terminator Edit question
No assignee Edit question
Solved by:
Stephen Boddy
Last query:
Last reply:

OK, the function was removed back in 2011... not exactly recent.

I'm assuming that the layout manager plugin you are talking about is the one here:
which does reference the get_top_window function. This as it says is old and has moved to:
which now recreates that function.

All the get_top_window function did was iterate up the widget tree till it found the window. This was replaced by the builtin gtk widget function get_toplevel which did exactly the same thing, but within the faster GTK C libraries.

In the layout manager plugin you just need to replace:
    window = get_top_window(terminal)
    window = terminal.get_toplevel()
and then the redundant get_top_window function could be removed from there too.

Perhaps you could raise the request against the plugin in GitHub.

Alexey (sneakyfildy) said : #2

Thank you very much! I will fork plugin and make correct version, thank you again!

Alexey (sneakyfildy) said : #3

Thanks Stephen Boddy, that solved my question.