Commit 59daaff7 authored by Jody Goldberg's avatar Jody Goldberg

- Correct some statics

- Correct some const
- Add descriptors and copywrites to a few files.
parent faf31247
......@@ -42,6 +42,11 @@
* src/workbook-private.h: Move the menu_item fields to
workbook_private.
2000-01-01 Jody Goldberg <jgoldberg@home.com>
* src/cell.c (cell_cleanout) : Make static again.
* src/eval.c (workbook_next_generation) : Make static.
1999-12-31 Jody Goldberg <jgoldberg@home.com>
* src/file.c (workbook_import) : Support new plugin interface.
......
......@@ -42,6 +42,11 @@
* src/workbook-private.h: Move the menu_item fields to
workbook_private.
2000-01-01 Jody Goldberg <jgoldberg@home.com>
* src/cell.c (cell_cleanout) : Make static again.
* src/eval.c (workbook_next_generation) : Make static.
1999-12-31 Jody Goldberg <jgoldberg@home.com>
* src/file.c (workbook_import) : Support new plugin interface.
......
......@@ -109,7 +109,7 @@ application_clipboard_cut (Sheet *sheet, Range const *area)
app.clipboard_cut_range = *area;
/* No paste special for copies */
workbook_view_set_paste_state (sheet->workbook, WORKBOOK_VIEW_PASTE_SPECIAL_ITEM);
workbook_view_set_paste_state (sheet->workbook, WORKBOOK_VIEW_PASTE_ITEM);
sheet_selection_ant (sheet);
}
......
......@@ -4,7 +4,7 @@
* Author:
* Jody Goldberg (jgoldberg@home.org)
*
* (C) 1999 Jody Goldberg
* (C) 1999, 2000 Jody Goldberg
*/
#include <config.h>
#include "border.h"
......
......@@ -45,7 +45,7 @@ cell_modified (Cell *cell)
/* Empty a cell's value, entered_text, and parsed_node. */
void
static void
cell_cleanout (Cell *cell)
{
if (cell->parsed_node){
......
/*
* command-context.c : Error dispatch utilities.
*
* Author:
* Jody Goldberg <jgoldberg@home.com>
*
* (C) 1999, 2000 Jody Goldberg
*/
#include <config.h>
#include "gnumeric-type-util.h"
#include "command-context.h"
......
......@@ -22,7 +22,7 @@ cell_eval_content (Cell *cell)
#ifdef DEBUG_EVALUATION
{
EvalPosition fp;
char *exprtxt = expr_decode_tree
(cell->parsed_node, eval_pos_cell (&fp, cell));
printf ("Evaluating %s: %s ->\n",
......@@ -69,7 +69,7 @@ cell_eval (Cell *cell)
if (cell->generation == cell->sheet->workbook->generation)
return;
cell->generation = cell->sheet->workbook->generation;
if (cell->parsed_node) {
......@@ -77,10 +77,10 @@ cell_eval (Cell *cell)
cell_eval_content (cell);
deps = cell_get_dependencies (cell);
for (l = deps; l; l = l->next) {
Cell *one_cell;
one_cell = l->data;
if (one_cell->generation != cell->sheet->workbook->generation)
cell_queue_recalc (one_cell);
......@@ -90,7 +90,7 @@ cell_eval (Cell *cell)
}
/*
* Comparission function for the dependency hash table
* Comparison function for the dependency hash table
*/
static gint
dependency_equal (gconstpointer v, gconstpointer v2)
......@@ -264,7 +264,7 @@ add_tree_deps (Cell *cell, ExprTree *tree)
case OPER_CONSTANT:
add_value_deps (cell, tree->u.constant);
return;
/*
* FIXME: needs to be taught implicit intersection +
* more cunning handling of argument type matching.
......@@ -475,14 +475,14 @@ search_cell_deps (gpointer key, gpointer value, gpointer closure)
get_cell_dep_closure_t *c = closure;
GList *l;
/* int draw;*/
if (deprange->sheet != c->sheet)
return;
/* draw = FALSE;
if (c->col == 1 && c->row == 1)
draw = TRUE;*/
/* No intersection is the common case */
if (!range_contains (range, c->col, c->row))
return;
......@@ -509,7 +509,7 @@ cell_get_dependencies (Cell *cell)
{
get_cell_dep_closure_t closure;
GList *l, *sheets;
if (!cell->sheet->dependency_hash)
dependency_hash_init (cell->sheet);
......@@ -524,7 +524,7 @@ cell_get_dependencies (Cell *cell)
if (!sheet->dependency_hash)
continue;
g_hash_table_foreach (sheet->dependency_hash,
&search_cell_deps, &closure);
}
......@@ -632,7 +632,7 @@ pick_next_cell_from_queue (Workbook *wb)
* Increments the generation. Every time the generation is
* about to wrap around, we reset all of the cell counters to zero
*/
void
static void
workbook_next_generation (Workbook *wb)
{
if (wb->generation == 255) {
......
......@@ -22,7 +22,7 @@ cell_eval_content (Cell *cell)
#ifdef DEBUG_EVALUATION
{
EvalPosition fp;
char *exprtxt = expr_decode_tree
(cell->parsed_node, eval_pos_cell (&fp, cell));
printf ("Evaluating %s: %s ->\n",
......@@ -69,7 +69,7 @@ cell_eval (Cell *cell)
if (cell->generation == cell->sheet->workbook->generation)
return;
cell->generation = cell->sheet->workbook->generation;
if (cell->parsed_node) {
......@@ -77,10 +77,10 @@ cell_eval (Cell *cell)
cell_eval_content (cell);
deps = cell_get_dependencies (cell);
for (l = deps; l; l = l->next) {
Cell *one_cell;
one_cell = l->data;
if (one_cell->generation != cell->sheet->workbook->generation)
cell_queue_recalc (one_cell);
......@@ -90,7 +90,7 @@ cell_eval (Cell *cell)
}
/*
* Comparission function for the dependency hash table
* Comparison function for the dependency hash table
*/
static gint
dependency_equal (gconstpointer v, gconstpointer v2)
......@@ -264,7 +264,7 @@ add_tree_deps (Cell *cell, ExprTree *tree)
case OPER_CONSTANT:
add_value_deps (cell, tree->u.constant);
return;
/*
* FIXME: needs to be taught implicit intersection +
* more cunning handling of argument type matching.
......@@ -475,14 +475,14 @@ search_cell_deps (gpointer key, gpointer value, gpointer closure)
get_cell_dep_closure_t *c = closure;
GList *l;
/* int draw;*/
if (deprange->sheet != c->sheet)
return;
/* draw = FALSE;
if (c->col == 1 && c->row == 1)
draw = TRUE;*/
/* No intersection is the common case */
if (!range_contains (range, c->col, c->row))
return;
......@@ -509,7 +509,7 @@ cell_get_dependencies (Cell *cell)
{
get_cell_dep_closure_t closure;
GList *l, *sheets;
if (!cell->sheet->dependency_hash)
dependency_hash_init (cell->sheet);
......@@ -524,7 +524,7 @@ cell_get_dependencies (Cell *cell)
if (!sheet->dependency_hash)
continue;
g_hash_table_foreach (sheet->dependency_hash,
&search_cell_deps, &closure);
}
......@@ -632,7 +632,7 @@ pick_next_cell_from_queue (Workbook *wb)
* Increments the generation. Every time the generation is
* about to wrap around, we reset all of the cell counters to zero
*/
void
static void
workbook_next_generation (Workbook *wb)
{
if (wb->generation == 255) {
......
......@@ -1373,7 +1373,7 @@ enum CellRefRelocate {
};
static enum CellRefRelocate
cellref_relocate (const CellRef * ref,
cellref_relocate (CellRef * const ref,
const EvalPosition * const pos,
const struct expr_relocate_info * const rinfo)
{
......
/*
* item-edit.c : Edit facilities for worksheets.
*
* Author:
* Miguel de Icaza (miguel@gnu.org)
*
* (C) 1999, 2000 Miguel de Icaza
*/
#include <config.h>
#include <gnome.h>
......
/*
* pattern.c : Support and specifications for patterns.
*
* Author:
* Jody Goldberg <jgoldberg@home.com>
*
* (C) 1999, 2000 Jody Goldberg
*/
#include "config.h"
#include "pattern.h"
#include "color.h"
......
......@@ -5,6 +5,7 @@
* Miguel de Icaza (miguel@gnu.org)
* Jody Goldberg (jgoldberg@home.com)
*
* (C) 1999, 2000 Jody Goldberg
*/
#include <config.h>
#include "selection.h"
......
......@@ -4,7 +4,7 @@
* Author:
* Jody Goldberg (jgoldberg@home.org)
*
* (C) 1999 Jody Goldberg
* (C) 1999, 2000 Jody Goldberg
*/
#include <config.h>
#include "border.h"
......
/*
* gnumeric-dashed-canvas-line.c : A canvas line with support for dash styles.
*
* Author:
* Jody Goldberg (jgoldberg@home.org)
*
* (C) 1999, 2000 Jody Goldberg
*/
#include <config.h>
#include "gnumeric-dashed-canvas-line.h"
......
......@@ -142,7 +142,6 @@ void workbook_focus_sheet (Sheet *sheet);
Sheet *workbook_get_current_sheet (Workbook *wb);
char *workbook_sheet_get_free_name (Workbook *wb);
void workbook_auto_expr_label_set (Workbook *wb, const char *text);
void workbook_next_generation (Workbook *wb);
void workbook_set_region_status (Workbook *wb, const char *str);
int workbook_parse_and_jump (Workbook *wb, const char *text);
Sheet *workbook_sheet_lookup (Workbook *wb, const char *sheet_name);
......
......@@ -923,7 +923,7 @@ workbook_edit_comment (GtkWidget *widget, Workbook *wb)
cell = sheet_cell_get (sheet, sheet->cursor_col, sheet->cursor_row);
if (!cell){
if (!cell) {
cell = sheet_cell_new (sheet, sheet->cursor_col, sheet->cursor_row);
cell_set_value (cell, value_new_empty ());
}
......
......@@ -142,7 +142,6 @@ void workbook_focus_sheet (Sheet *sheet);
Sheet *workbook_get_current_sheet (Workbook *wb);
char *workbook_sheet_get_free_name (Workbook *wb);
void workbook_auto_expr_label_set (Workbook *wb, const char *text);
void workbook_next_generation (Workbook *wb);
void workbook_set_region_status (Workbook *wb, const char *str);
int workbook_parse_and_jump (Workbook *wb, const char *text);
Sheet *workbook_sheet_lookup (Workbook *wb, const char *sheet_name);
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment