Skip to content
Snippets Groups Projects
Commit be1f9868 authored by Morris Jette's avatar Morris Jette
Browse files

Fix bug in sview layout if node count less than configured grid_x_width.

parent f455c48a
No related branches found
No related tags found
No related merge requests found
...@@ -20,6 +20,7 @@ documents those changes that are of interest to users and admins. ...@@ -20,6 +20,7 @@ documents those changes that are of interest to users and admins.
Patch from Alejandro Lucero Palau, BSC. Patch from Alejandro Lucero Palau, BSC.
-- Improve logic to import a user's environment. Needed with --get-user-env -- Improve logic to import a user's environment. Needed with --get-user-env
option used with Moab. Patch from Mark Grondona, LLNL. option used with Moab. Patch from Mark Grondona, LLNL.
-- Fix bug in sview layout if node count less than configured grid_x_width.
* Changes in SLURM 2.3.2 * Changes in SLURM 2.3.2
======================== ========================
......
...@@ -848,7 +848,8 @@ static int _grid_table_by_switch(button_processor_t *button_processor, ...@@ -848,7 +848,8 @@ static int _grid_table_by_switch(button_processor_t *button_processor,
/* This is needed to get the correct width of the grid window. /* This is needed to get the correct width of the grid window.
* If it is not given then we get a really narrow window. */ * If it is not given then we get a really narrow window. */
gtk_table_set_row_spacing(button_processor->table, gtk_table_set_row_spacing(button_processor->table,
(*button_processor->coord_y)-1, 1); (*button_processor->coord_y)?
((*button_processor->coord_y)-1):0, 1);
return rc; return rc;
...@@ -878,11 +879,11 @@ static int _grid_table_by_list(button_processor_t *button_processor, ...@@ -878,11 +879,11 @@ static int _grid_table_by_list(button_processor_t *button_processor,
list_iterator_destroy(itr); list_iterator_destroy(itr);
rc = _add_button_to_list(NULL, button_processor); rc = _add_button_to_list(NULL, button_processor);
/* This is needed to get the correct width of the grid /* This is needed to get the correct width of the grid window.
window. If it is not given then we get a really narrow * If it is not given then we get a really narrow window. */
window. */
gtk_table_set_row_spacing(button_processor->table, gtk_table_set_row_spacing(button_processor->table,
(*button_processor->coord_y)-1, 1); (*button_processor->coord_y)?
((*button_processor->coord_y)-1):0, 1);
return rc; return rc;
...@@ -1502,7 +1503,7 @@ extern void put_buttons_in_table(GtkTable *table, List button_list) ...@@ -1502,7 +1503,7 @@ extern void put_buttons_in_table(GtkTable *table, List button_list)
if (cluster_dims == 0) { if (cluster_dims == 0) {
/* This is needed to get the correct width of the grid window. /* This is needed to get the correct width of the grid window.
* If it is not given then we get a really narrow window. */ * If it is not given then we get a really narrow window. */
gtk_table_set_row_spacing(table, coord_y-1, 1); gtk_table_set_row_spacing(table, coord_y?(coord_y-1):0, 1);
} }
gtk_widget_show_all(GTK_WIDGET(table)); gtk_widget_show_all(GTK_WIDGET(table));
} }
...@@ -1567,10 +1568,9 @@ extern int update_grid_table(GtkTable *table, List button_list, List node_list) ...@@ -1567,10 +1568,9 @@ extern int update_grid_table(GtkTable *table, List button_list, List node_list)
} }
rc = _add_button_to_list(NULL, &button_processor); rc = _add_button_to_list(NULL, &button_processor);
/* This is needed to get the correct width of the grid /* This is needed to get the correct width of the grid window.
window. If it is not given then we get a really narrow * If it is not given then we get a really narrow window. */
window. */ gtk_table_set_row_spacing(table, coord_y?(coord_y-1):0, 1);
gtk_table_set_row_spacing(table, coord_y-1, 1);
end_it: end_it:
list_iterator_destroy(itr); list_iterator_destroy(itr);
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment