From 183f9cc1aca8a850ea4f749f8be53934016d8ac4 Mon Sep 17 00:00:00 2001 From: Krzysztof Kosciuszkiewicz Date: Thu, 13 Jan 2011 00:57:07 +0100 Subject: [PATCH] gattrib: remove references to LEAVE_VISIBILITY_ALONE None of the callers of s_visibility_set_cell passed LEAVE_INVISIBILITY_ALONE as the visibility parameter. Affects-bug: lp-701431 Reviewed-by: Peter Clifton --- gattrib/src/s_toplevel.c | 2 +- gattrib/src/s_visibility.c | 7 +++---- 2 files changed, 4 insertions(+), 5 deletions(-) diff --git a/gattrib/src/s_toplevel.c b/gattrib/src/s_toplevel.c index e561cec94..f05401710 100644 --- a/gattrib/src/s_toplevel.c +++ b/gattrib/src/s_toplevel.c @@ -1015,7 +1015,7 @@ s_toplevel_update_pin_attribs_in_toplevel (TOPLEVEL *toplevel, o_pin, new_attrib_name, new_attrib_value, - LEAVE_VISIBILITY_ALONE, + o_is_visible (toplevel, o_pin) ? VISIBLE : INVISIBLE, LEAVE_NAME_VALUE_ALONE); } diff --git a/gattrib/src/s_visibility.c b/gattrib/src/s_visibility.c index 539340aa9..666a62562 100644 --- a/gattrib/src/s_visibility.c +++ b/gattrib/src/s_visibility.c @@ -375,10 +375,9 @@ void s_visibility_set_cell(gint cur_page, gint row, gint col, } /* Question: how to sanity check (row, col) selection? */ - if (visibility != LEAVE_VISIBILITY_ALONE) { - local_table[row][col].visibility = visibility; - sheet_head->CHANGED = 1; /* cell has been updated. */ - } + local_table[row][col].visibility = visibility; + sheet_head->CHANGED = 1; /* cell has been updated. */ + if (show_name_value != LEAVE_NAME_VALUE_ALONE) { local_table[row][col].show_name_value = show_name_value; sheet_head->CHANGED = 1; /* cell has been updated. */ -- 2.11.4.GIT