Commit 5b07ce50 authored by Jody Goldberg's avatar Jody Goldberg Committed by Jody Goldberg
Browse files

use cell_is_blank. (parse_database_criteria) : ditto.

2002-02-17  Jody Goldberg <jody@gnome.org>

	* fn-database.c (parse_criteria_range) : use cell_is_blank.
	(parse_database_criteria) : ditto.
	(find_cells_that_match) : ditto.
	(find_rows_that_match) : ditto.
	(gnumeric_getpivotdata) : ditto.

2002-02-17  Jody Goldberg <jody@gnome.org>

	* plugins/excel/ms-escher.c (ms_escher_read_OPT) : add support for
	  blip cropping.
parent fabe8de5
2002-02-17 Jody Goldberg <jody@gnome.org>
* plugins/excel/ms-escher.c (ms_escher_read_OPT) : add support for
blip cropping.
2002-02-16 Jody Goldberg <jody@gnome.org> 2002-02-16 Jody Goldberg <jody@gnome.org>
* src/sheet-object-image.c (soi_get_pixbuf) : move things here. * src/sheet-object-image.c (soi_get_pixbuf) : move things here.
......
2002-02-17 Jody Goldberg <jody@gnome.org>
* plugins/excel/ms-escher.c (ms_escher_read_OPT) : add support for
blip cropping.
2002-02-16 Jody Goldberg <jody@gnome.org> 2002-02-16 Jody Goldberg <jody@gnome.org>
* src/sheet-object-image.c (soi_get_pixbuf) : move things here. * src/sheet-object-image.c (soi_get_pixbuf) : move things here.
......
2002-02-17 Jody Goldberg <jody@gnome.org>
* plugins/excel/ms-escher.c (ms_escher_read_OPT) : add support for
blip cropping.
2002-02-16 Jody Goldberg <jody@gnome.org> 2002-02-16 Jody Goldberg <jody@gnome.org>
* src/sheet-object-image.c (soi_get_pixbuf) : move things here. * src/sheet-object-image.c (soi_get_pixbuf) : move things here.
......
...@@ -186,10 +186,6 @@ to features that already work. ...@@ -186,10 +186,6 @@ to features that already work.
+ Localise sheet/workbook Name import. + Localise sheet/workbook Name import.
+ Import names even if they arn't referenced. + Import names even if they arn't referenced.
* Excel Export
+ Detect large style ranges and correctly set the default row/col/sheet styles.
1.1 1.1
========== ==========
These section lists features that are for post 1.0 versions These section lists features that are for post 1.0 versions
...@@ -233,4 +229,6 @@ under "1.0" are more important. ...@@ -233,4 +229,6 @@ under "1.0" are more important.
* Autofilter * Autofilter
+ ? + Most of the major elements are there to support in place
filters. All we'd need is a new Dependent type to manage the
filter results.
...@@ -376,7 +376,7 @@ ms_escher_read_BSE (MSEscherState * state, MSEscherHeader * h) ...@@ -376,7 +376,7 @@ ms_escher_read_BSE (MSEscherState * state, MSEscherHeader * h)
static gboolean static gboolean
ms_escher_read_Blip (MSEscherState * state, MSEscherHeader * h) ms_escher_read_Blip (MSEscherState * state, MSEscherHeader * h)
{ {
int primary_uid_size = 0; int blip_header = -1, primary_uid_size = 0;
guint32 blip_instance = h->instance; guint32 blip_instance = h->instance;
gboolean res = FALSE; gboolean res = FALSE;
MSEscherBlip *blip = NULL; MSEscherBlip *blip = NULL;
...@@ -406,24 +406,33 @@ ms_escher_read_Blip (MSEscherState * state, MSEscherHeader * h) ...@@ -406,24 +406,33 @@ ms_escher_read_Blip (MSEscherState * state, MSEscherHeader * h)
/* Clients may set bit 0x800 */ /* Clients may set bit 0x800 */
blip_instance &= (~0x800); blip_instance &= (~0x800);
/*
* TODO : read /scratch/openoffice/svx/source/msfilter/msdffimp.cxx
*/
switch (blip_instance) { switch (blip_instance) {
case 0x216 : /* compressed WMF, with Metafile header */ case 0x216 : /* compressed WMF, with Metafile header */
type = "wmf"; type = "wmf.gz";
blip_header = 20 + 8 + 6;
break; break;
case 0x3d4 : /* compressed EMF, with Metafile header */ case 0x3d4 : /* compressed EMF, with Metafile header */
type = "emf"; type = "emf.gz";
blip_header = 20 + 8 + 6;
break; break;
case 0x542 : /* compressed PICT, with Metafile header */ case 0x542 : /* compressed PICT, with Metafile header */
type = "pict"; type = "pict.gz";
blip_header = 20 + 8 + 6;
break; break;
case 0x46a : /* JPEG data, with 1 byte header */ case 0x46a : /* JPEG data, with 1 byte header */
type = "jpeg"; type = "jpeg";
blip_header = 1;
break; break;
case 0x6e0 : /* PNG data, with 1 byte header */ case 0x6e0 : /* PNG data, with 1 byte header */
type = "png"; type = "png";
blip_header = 1;
break; break;
case 0x7a8 : /* DIB data, with 1 byte header */ case 0x7a8 : /* DIB data, with 1 byte header */
type = "dib"; type = "dib";
blip_header = 1;
break; break;
default: default:
...@@ -432,8 +441,8 @@ ms_escher_read_Blip (MSEscherState * state, MSEscherHeader * h) ...@@ -432,8 +441,8 @@ ms_escher_read_Blip (MSEscherState * state, MSEscherHeader * h)
h->instance); h->instance);
}; };
if (type != NULL) { if (blip_header >= 0) {
int const header = 17 + primary_uid_size + common_header_len; int const header = blip_header + 16 + primary_uid_size + common_header_len;
gboolean needs_free; gboolean needs_free;
guint8 const *data = ms_escher_get_data (state, h->offset, h->len, guint8 const *data = ms_escher_get_data (state, h->offset, h->len,
header, &needs_free); header, &needs_free);
...@@ -1221,10 +1230,18 @@ ms_escher_read_OPT (MSEscherState *state, MSEscherHeader *h) ...@@ -1221,10 +1230,18 @@ ms_escher_read_OPT (MSEscherState *state, MSEscherHeader *h)
/* Blip */ /* Blip */
/* 0 : 16.16 fraction times total image width or height, as appropriate. */ /* 0 : 16.16 fraction times total image width or height, as appropriate. */
case 256 : name = "fixed16_16 cropFromTop"; break; case 256 : name = "fixed16_16 cropFromTop";
case 257 : name = "fixed16_16 cropFromBottom"; break; id = MS_OBJ_ATTR_BLIP_CROP_TOP;
case 258 : name = "fixed16_16 cropFromLeft"; break; break;
case 259 : name = "fixed16_16 cropFromRight"; break; case 257 : name = "fixed16_16 cropFromBottom";
id = MS_OBJ_ATTR_BLIP_CROP_BOTTOM;
break;
case 258 : name = "fixed16_16 cropFromLeft";
id = MS_OBJ_ATTR_BLIP_CROP_LEFT;
break;
case 259 : name = "fixed16_16 cropFromRight";
id = MS_OBJ_ATTR_BLIP_CROP_RIGHT;
break;
/* NULL : Blip to display */ /* NULL : Blip to display */
case 260 : id = MS_OBJ_ATTR_BLIP_ID; case 260 : id = MS_OBJ_ATTR_BLIP_ID;
......
...@@ -36,6 +36,10 @@ typedef enum { ...@@ -36,6 +36,10 @@ typedef enum {
MS_OBJ_ATTR_SCROLLBAR_MAX, MS_OBJ_ATTR_SCROLLBAR_MAX,
MS_OBJ_ATTR_SCROLLBAR_INC, MS_OBJ_ATTR_SCROLLBAR_INC,
MS_OBJ_ATTR_SCROLLBAR_PAGE, MS_OBJ_ATTR_SCROLLBAR_PAGE,
MS_OBJ_ATTR_BLIP_CROP_TOP,
MS_OBJ_ATTR_BLIP_CROP_BOTTOM,
MS_OBJ_ATTR_BLIP_CROP_LEFT,
MS_OBJ_ATTR_BLIP_CROP_RIGHT,
/* Ptrs */ /* Ptrs */
MS_OBJ_ATTR_IS_PTR_MASK = 0x2000, MS_OBJ_ATTR_IS_PTR_MASK = 0x2000,
......
/* vim: set sw=8: */
/* /*
* fn-database.c: Built in database functions and functions registration * fn-database.c: Built in database functions and functions registration
* *
...@@ -235,7 +236,7 @@ parse_criteria_range(Sheet *sheet, int b_col, int b_row, int e_col, int e_row, ...@@ -235,7 +236,7 @@ parse_criteria_range(Sheet *sheet, int b_col, int b_row, int e_col, int e_row,
database_criteria_t *new_criteria; database_criteria_t *new_criteria;
GSList *criterias = NULL; GSList *criterias = NULL;
GSList *conditions; GSList *conditions;
Cell *cell; Cell const *cell;
func_criteria_t *cond; func_criteria_t *cond;
gchar *cell_str; gchar *cell_str;
...@@ -247,7 +248,7 @@ parse_criteria_range(Sheet *sheet, int b_col, int b_row, int e_col, int e_row, ...@@ -247,7 +248,7 @@ parse_criteria_range(Sheet *sheet, int b_col, int b_row, int e_col, int e_row,
for (j = b_col; j <= e_col; j++) { for (j = b_col; j <= e_col; j++) {
cell = sheet_cell_get (sheet, j, i); cell = sheet_cell_get (sheet, j, i);
if (cell == NULL || cell->value == NULL) if (cell_is_blank (cell))
continue; continue;
cond = g_new (func_criteria_t, 1); cond = g_new (func_criteria_t, 1);
...@@ -289,7 +290,7 @@ parse_database_criteria (const EvalPos *ep, Value *database, ...@@ -289,7 +290,7 @@ parse_database_criteria (const EvalPos *ep, Value *database,
{ {
Sheet *sheet; Sheet *sheet;
GSList *criterias; GSList *criterias;
Cell *cell; Cell const *cell;
int i; int i;
int b_col, b_row, e_col, e_row; int b_col, b_row, e_col, e_row;
...@@ -306,7 +307,7 @@ parse_database_criteria (const EvalPos *ep, Value *database, ...@@ -306,7 +307,7 @@ parse_database_criteria (const EvalPos *ep, Value *database,
/* Find the index numbers for the columns of criterias */ /* Find the index numbers for the columns of criterias */
for (i = b_col; i <= e_col; i++) { for (i = b_col; i <= e_col; i++) {
cell = sheet_cell_get (sheet, i, b_row); cell = sheet_cell_get (sheet, i, b_row);
if (cell == NULL || cell->value == NULL) if (cell_is_blank (cell))
continue; continue;
field_ind[i - b_col] = field_ind[i - b_col] =
find_column_of_field (ep, database, cell->value); find_column_of_field (ep, database, cell->value);
...@@ -335,6 +336,7 @@ find_cells_that_match (Sheet *sheet, Value *database, ...@@ -335,6 +336,7 @@ find_cells_that_match (Sheet *sheet, Value *database,
GSList *ptr, *condition, *cells; GSList *ptr, *condition, *cells;
int row, first_row, last_row; int row, first_row, last_row;
gboolean add_flag; gboolean add_flag;
Cell *cell;
cells = NULL; cells = NULL;
/* TODO : Why ignore the first row ? What if there is no header ? */ /* TODO : Why ignore the first row ? What if there is no header ? */
...@@ -342,8 +344,8 @@ find_cells_that_match (Sheet *sheet, Value *database, ...@@ -342,8 +344,8 @@ find_cells_that_match (Sheet *sheet, Value *database,
last_row = database->v_range.cell.b.row; last_row = database->v_range.cell.b.row;
for (row = first_row; row <= last_row; row++) { for (row = first_row; row <= last_row; row++) {
Cell *cell = sheet_cell_get (sheet, col, row); cell = sheet_cell_get (sheet, col, row);
if (cell == NULL || cell->value == NULL) if (cell_is_blank (cell))
continue; continue;
add_flag = TRUE; add_flag = TRUE;
...@@ -358,8 +360,7 @@ find_cells_that_match (Sheet *sheet, Value *database, ...@@ -358,8 +360,7 @@ find_cells_that_match (Sheet *sheet, Value *database,
Cell const *tmp = sheet_cell_get (sheet, Cell const *tmp = sheet_cell_get (sheet,
cond->column, row); cond->column, row);
if (tmp == NULL || if (cell_is_blank (tmp) ||
tmp->value == NULL ||
!cond->fun (tmp->value, cond->x)) { !cond->fun (tmp->value, cond->x)) {
add_flag = FALSE; add_flag = FALSE;
break; break;
...@@ -385,11 +386,11 @@ find_rows_that_match (Sheet *sheet, int first_col, int first_row, ...@@ -385,11 +386,11 @@ find_rows_that_match (Sheet *sheet, int first_col, int first_row,
GSList *criterias, gboolean unique_only) GSList *criterias, gboolean unique_only)
{ {
GSList *current, *conditions, *rows; GSList *current, *conditions, *rows;
Cell const *test_cell;
int row, add_flag; int row, add_flag;
rows = NULL; rows = NULL;
for (row = first_row; row <= last_row; row++) { for (row = first_row; row <= last_row; row++) {
Cell *test_cell;
current = criterias; current = criterias;
add_flag = 1; add_flag = 1;
...@@ -402,13 +403,11 @@ find_rows_that_match (Sheet *sheet, int first_col, int first_row, ...@@ -402,13 +403,11 @@ find_rows_that_match (Sheet *sheet, int first_col, int first_row,
conditions = current_criteria->conditions; conditions = current_criteria->conditions;
while (conditions != NULL) { while (conditions != NULL) {
func_criteria_t *cond = conditions->data; func_criteria_t const *cond = conditions->data;
test_cell = test_cell = sheet_cell_get (sheet,
sheet_cell_get (sheet,
first_col + cond->column, row); first_col + cond->column, row);
if (test_cell == NULL || if (cell_is_blank (test_cell))
test_cell->value == NULL)
continue; continue;
if (!cond->fun (test_cell->value, cond->x)) { if (!cond->fun (test_cell->value, cond->x)) {
...@@ -1348,7 +1347,7 @@ gnumeric_getpivotdata (FunctionEvalInfo *ei, Value **argv) ...@@ -1348,7 +1347,7 @@ gnumeric_getpivotdata (FunctionEvalInfo *ei, Value **argv)
/* FIXME: Lots of stuff missing */ /* FIXME: Lots of stuff missing */
if (cell == NULL || cell->value == NULL || if (cell_is_blank (cell) ||
!VALUE_IS_NUMBER (cell->value)) !VALUE_IS_NUMBER (cell->value))
return value_new_error (ei->pos, gnumeric_err_REF); return value_new_error (ei->pos, gnumeric_err_REF);
......
...@@ -27,6 +27,7 @@ ...@@ -27,6 +27,7 @@
<child> <child>
<widget class="GtkButton" id="okbutton"> <widget class="GtkButton" id="okbutton">
<property name="can_default">yes</property> <property name="can_default">yes</property>
<property name="has_default">yes</property>
<property name="can_focus">yes</property> <property name="can_focus">yes</property>
<property name="visible">yes</property> <property name="visible">yes</property>
<property name="label" translatable="yes">gtk-ok</property> <property name="label" translatable="yes">gtk-ok</property>
......
...@@ -27,6 +27,7 @@ ...@@ -27,6 +27,7 @@
<child> <child>
<widget class="GtkButton" id="ok_button"> <widget class="GtkButton" id="ok_button">
<property name="can_default">yes</property> <property name="can_default">yes</property>
<property name="has_default">yes</property>
<property name="can_focus">yes</property> <property name="can_focus">yes</property>
<property name="relief">GTK_RELIEF_NORMAL</property> <property name="relief">GTK_RELIEF_NORMAL</property>
<property name="visible">yes</property> <property name="visible">yes</property>
......
...@@ -29,7 +29,7 @@ ...@@ -29,7 +29,7 @@
<child> <child>
<widget class="GtkButton" id="format_ok"> <widget class="GtkButton" id="format_ok">
<property name="can_default">yes</property> <property name="can_default">yes</property>
<!-- <property name="has_default">yes</property> libglade problem --> <property name="has_default">yes</property>
<property name="can_focus">yes</property> <property name="can_focus">yes</property>
<property name="visible">yes</property> <property name="visible">yes</property>
<property name="label" translatable="yes">gtk-ok</property> <property name="label" translatable="yes">gtk-ok</property>
......
...@@ -26,6 +26,7 @@ ...@@ -26,6 +26,7 @@
<child> <child>
<widget class="GtkButton" id="button1"> <widget class="GtkButton" id="button1">
<property name="can_default">yes</property> <property name="can_default">yes</property>
<property name="has_default">yes</property>
<property name="can_focus">yes</property> <property name="can_focus">yes</property>
<property name="visible">yes</property> <property name="visible">yes</property>
<property name="label" translatable="yes">gtk-ok</property> <property name="label" translatable="yes">gtk-ok</property>
......
...@@ -42,6 +42,7 @@ ...@@ -42,6 +42,7 @@
<child> <child>
<widget class="GtkButton" id="okbutton"> <widget class="GtkButton" id="okbutton">
<property name="can_default">yes</property> <property name="can_default">yes</property>
<property name="has_default">yes</property>
<property name="can_focus">yes</property> <property name="can_focus">yes</property>
<property name="visible">yes</property> <property name="visible">yes</property>
<property name="label" translatable="yes">gtk-ok</property> <property name="label" translatable="yes">gtk-ok</property>
......
...@@ -26,6 +26,7 @@ ...@@ -26,6 +26,7 @@
<child> <child>
<widget class="GtkButton" id="ok_button"> <widget class="GtkButton" id="ok_button">
<property name="can_default">yes</property> <property name="can_default">yes</property>
<property name="has_default">yes</property>
<property name="can_focus">yes</property> <property name="can_focus">yes</property>
<property name="visible">yes</property> <property name="visible">yes</property>
<property name="label" translatable="yes">gtk-ok</property> <property name="label" translatable="yes">gtk-ok</property>
......
...@@ -27,6 +27,7 @@ ...@@ -27,6 +27,7 @@
<child> <child>
<widget class="GtkButton" id="btn_ok"> <widget class="GtkButton" id="btn_ok">
<property name="can_default">yes</property> <property name="can_default">yes</property>
<property name="has_default">yes</property>
<property name="can_focus">yes</property> <property name="can_focus">yes</property>
<property name="visible">yes</property> <property name="visible">yes</property>
<property name="label" translatable="yes">gtk-ok</property> <property name="label" translatable="yes">gtk-ok</property>
......
2002-02-17 Jody Goldberg <jody@gnome.org>
* fn-database.c (parse_criteria_range) : use cell_is_blank.
(parse_database_criteria) : ditto.
(find_cells_that_match) : ditto.
(find_rows_that_match) : ditto.
(gnumeric_getpivotdata) : ditto.
2002-02-07 Morten Welinder <terra@diku.dk> 2002-02-07 Morten Welinder <terra@diku.dk>
* fn-date.c (gnumeric_date2unix): Fix. * fn-date.c (gnumeric_date2unix): Fix.
......
/* vim: set sw=8: */
/* /*
* fn-database.c: Built in database functions and functions registration * fn-database.c: Built in database functions and functions registration
* *
...@@ -235,7 +236,7 @@ parse_criteria_range(Sheet *sheet, int b_col, int b_row, int e_col, int e_row, ...@@ -235,7 +236,7 @@ parse_criteria_range(Sheet *sheet, int b_col, int b_row, int e_col, int e_row,
database_criteria_t *new_criteria; database_criteria_t *new_criteria;
GSList *criterias = NULL; GSList *criterias = NULL;
GSList *conditions; GSList *conditions;
Cell *cell; Cell const *cell;
func_criteria_t *cond; func_criteria_t *cond;
gchar *cell_str; gchar *cell_str;
...@@ -247,7 +248,7 @@ parse_criteria_range(Sheet *sheet, int b_col, int b_row, int e_col, int e_row, ...@@ -247,7 +248,7 @@ parse_criteria_range(Sheet *sheet, int b_col, int b_row, int e_col, int e_row,
for (j = b_col; j <= e_col; j++) { for (j = b_col; j <= e_col; j++) {
cell = sheet_cell_get (sheet, j, i); cell = sheet_cell_get (sheet, j, i);
if (cell == NULL || cell->value == NULL) if (cell_is_blank (cell))
continue; continue;
cond = g_new (func_criteria_t, 1); cond = g_new (func_criteria_t, 1);
...@@ -289,7 +290,7 @@ parse_database_criteria (const EvalPos *ep, Value *database, ...@@ -289,7 +290,7 @@ parse_database_criteria (const EvalPos *ep, Value *database,
{ {
Sheet *sheet; Sheet *sheet;
GSList *criterias; GSList *criterias;
Cell *cell; Cell const *cell;
int i; int i;
int b_col, b_row, e_col, e_row; int b_col, b_row, e_col, e_row;
...@@ -306,7 +307,7 @@ parse_database_criteria (const EvalPos *ep, Value *database, ...@@ -306,7 +307,7 @@ parse_database_criteria (const EvalPos *ep, Value *database,
/* Find the index numbers for the columns of criterias */ /* Find the index numbers for the columns of criterias */
for (i = b_col; i <= e_col; i++) { for (i = b_col; i <= e_col; i++) {
cell = sheet_cell_get (sheet, i, b_row); cell = sheet_cell_get (sheet, i, b_row);
if (cell == NULL || cell->value == NULL) if (cell_is_blank (cell))
continue; continue;
field_ind[i - b_col] = field_ind[i - b_col] =
find_column_of_field (ep, database, cell->value); find_column_of_field (ep, database, cell->value);
...@@ -335,6 +336,7 @@ find_cells_that_match (Sheet *sheet, Value *database, ...@@ -335,6 +336,7 @@ find_cells_that_match (Sheet *sheet, Value *database,
GSList *ptr, *condition, *cells; GSList *ptr, *condition, *cells;
int row, first_row, last_row; int row, first_row, last_row;
gboolean add_flag; gboolean add_flag;
Cell *cell;
cells = NULL; cells = NULL;
/* TODO : Why ignore the first row ? What if there is no header ? */ /* TODO : Why ignore the first row ? What if there is no header ? */
...@@ -342,8 +344,8 @@ find_cells_that_match (Sheet *sheet, Value *database, ...@@ -342,8 +344,8 @@ find_cells_that_match (Sheet *sheet, Value *database,
last_row = database->v_range.cell.b.row; last_row = database->v_range.cell.b.row;
for (row = first_row; row <= last_row; row++) { for (row = first_row; row <= last_row; row++) {
Cell *cell = sheet_cell_get (sheet, col, row); cell = sheet_cell_get (sheet, col, row);
if (cell == NULL || cell->value == NULL) if (cell_is_blank (cell))
continue; continue;
add_flag = TRUE; add_flag = TRUE;
...@@ -358,8 +360,7 @@ find_cells_that_match (Sheet *sheet, Value *database, ...@@ -358,8 +360,7 @@ find_cells_that_match (Sheet *sheet, Value *database,
Cell const *tmp = sheet_cell_get (sheet, Cell const *tmp = sheet_cell_get (sheet,
cond->column, row); cond->column, row);
if (tmp == NULL || if (cell_is_blank (tmp) ||
tmp->value == NULL ||
!cond->fun (tmp->value, cond->x)) { !cond->fun (tmp->value, cond->x)) {
add_flag = FALSE; add_flag = FALSE;
break; break;
...@@ -385,11 +386,11 @@ find_rows_that_match (Sheet *sheet, int first_col, int first_row, ...@@ -385,11 +386,11 @@ find_rows_that_match (Sheet *sheet, int first_col, int first_row,
GSList *criterias, gboolean unique_only) GSList *criterias, gboolean unique_only)
{ {
GSList *current, *conditions, *rows; GSList *current, *conditions, *rows;
Cell const *test_cell;
int row, add_flag; int row, add_flag;
rows = NULL; rows = NULL;
for (row = first_row; row <= last_row; row++) { for (row = first_row; row <= last_row; row++) {
Cell *test_cell;
current = criterias; current = criterias;
add_flag = 1; add_flag = 1;
...@@ -402,13 +403,11 @@ find_rows_that_match (Sheet *sheet, int first_col, int first_row, ...@@ -402,13 +403,11 @@ find_rows_that_match (Sheet *sheet, int first_col, int first_row,
conditions = current_criteria->conditions; conditions = current_criteria->conditions;
while (conditions != NULL) { while (conditions != NULL) {
func_criteria_t *cond = conditions->data; func_criteria_t const *cond = conditions->data;
test_cell = test_cell = sheet_cell_get (sheet,
sheet_cell_get (sheet,
first_col + cond->column, row); first_col + cond->column, row);
if (test_cell == NULL || if (cell_is_blank (test_cell))
test_cell->value == NULL)
continue; continue;
if (!cond->fun (test_cell->value, cond->x)) { if (!cond->fun (test_cell->value, cond->x)) {
...@@ -1348,7 +1347,7 @@ gnumeric_getpivotdata (FunctionEvalInfo *ei, Value **argv) ...@@ -1348,7 +1347,7 @@ gnumeric_getpivotdata (FunctionEvalInfo *ei, Value **argv)
/* FIXME: Lots of stuff missing */ /* FIXME: Lots of stuff missing */