mirror of
https://github.com/MidnightCommander/mc
synced 2025-01-18 09:19:24 +03:00
Merge branch '3061_layout_split_buttons_fix'
* 3061_layout_split_buttons_fix: Ticket #3061: fix [en|dis]abling of layout split adjust buttons.
This commit is contained in:
commit
1ff833e154
@ -377,19 +377,26 @@ layout_callback (Widget * w, Widget * sender, widget_msg_t msg, int parm, void *
|
|||||||
{
|
{
|
||||||
if (panels_layout.horizontal_split != radio_widget->sel)
|
if (panels_layout.horizontal_split != radio_widget->sel)
|
||||||
{
|
{
|
||||||
|
int eq;
|
||||||
|
|
||||||
panels_layout.horizontal_split = radio_widget->sel;
|
panels_layout.horizontal_split = radio_widget->sel;
|
||||||
|
|
||||||
if (panels_layout.horizontal_split)
|
if (panels_layout.horizontal_split)
|
||||||
{
|
{
|
||||||
if (panels_layout.horizontal_equal)
|
eq = panels_layout.horizontal_equal;
|
||||||
|
if (eq)
|
||||||
panels_layout.top_panel_size = height / 2;
|
panels_layout.top_panel_size = height / 2;
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
if (panels_layout.vertical_equal)
|
eq = panels_layout.vertical_equal;
|
||||||
|
if (eq)
|
||||||
panels_layout.left_panel_size = COLS / 2;
|
panels_layout.left_panel_size = COLS / 2;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
widget_disable (WIDGET (bleft_widget), eq);
|
||||||
|
widget_disable (WIDGET (bright_widget), eq);
|
||||||
|
|
||||||
update_split (h);
|
update_split (h);
|
||||||
layout_change ();
|
layout_change ();
|
||||||
do_refresh ();
|
do_refresh ();
|
||||||
|
Loading…
Reference in New Issue
Block a user