~ubuntu-branches/ubuntu/quantal/gnumeric/quantal

« back to all changes in this revision

Viewing changes to src/dialogs/dialog-so-list.c

  • Committer: Bazaar Package Importer
  • Author(s): Gauvain Pocentek
  • Date: 2009-06-07 11:10:47 UTC
  • mfrom: (1.1.19 upstream) (2.1.2 squeeze)
  • Revision ID: james.westby@ubuntu.com-20090607111047-l3rtbzfjxvmi1kx0
Tags: 1.9.8-1ubuntu1
* Merge from debian unstable, remaining changes:
  - Promoted gnumeric-doc to Recommends in gnumeric package for help to be
    installed automatically
  - gnumeric-gtk is a transitional package
  - gnumeric conflicts with gnumeric-gtk << 1.8.3-3ubuntu1
  - call initltool-update in po*
  - remove psiconv support (psiconv is in universe):
    o debian/control: remove B-D on libpsiconv-dev
    o debian/rules: don't pass --with-psiconv to ./configure

Show diffs side-by-side

added added

removed removed

Lines of Context:
36
36
#include <parse-util.h>
37
37
#include <commands.h>
38
38
#include <widgets/gnumeric-expr-entry.h>
39
 
#include <gtk/gtktable.h>
 
39
#include <gtk/gtk.h>
40
40
#include <glib/gi18n.h>
41
41
 
42
42
#define DIALOG_SO_LIST_KEY "so-list"
72
72
                "scg", wbcg_cur_scg (state->wbcg),
73
73
                "with-icon", TRUE,
74
74
                NULL);
75
 
        gnm_expr_entry_set_flags (gee,
76
 
                GNM_EE_FORCE_ABS_REF | GNM_EE_SHEET_OPTIONAL | GNM_EE_SINGLE_RANGE,
77
 
                GNM_EE_MASK);
 
75
        gnm_expr_entry_set_flags (gee, GNM_EE_FORCE_ABS_REF | 
 
76
                                  GNM_EE_SHEET_OPTIONAL | 
 
77
                                  GNM_EE_SINGLE_RANGE, GNM_EE_MASK);
78
78
        gnm_expr_entry_load_from_dep (gee, dep);
79
79
        return gee;
80
80
}
85
85
        if (response_id == GTK_RESPONSE_HELP)
86
86
                return;
87
87
        if (response_id == GTK_RESPONSE_OK) {
 
88
                GnmParsePos pp;
 
89
                Sheet *sheet = sheet_object_get_sheet (state->so);
 
90
                GnmExprTop const *output;
 
91
                GnmExprTop const *content;
 
92
 
 
93
                parse_pos_init (&pp, sheet->workbook, sheet, 0, 0);
 
94
                output = gnm_expr_entry_parse (state->link_entry, 
 
95
                                               &pp, NULL, FALSE, GNM_EE_FORCE_ABS_REF);
 
96
                content = gnm_expr_entry_parse (state->content_entry, 
 
97
                                                &pp, NULL, FALSE, GNM_EE_FORCE_ABS_REF);
 
98
                cmd_so_set_links (WORKBOOK_CONTROL (state->wbcg), state->so, output, content);
88
99
        }
89
100
 
90
101
        gtk_object_destroy (GTK_OBJECT (dialog));
106
117
        table = GTK_TABLE (glade_xml_get_widget (state->gui, "table"));
107
118
 
108
119
        state->content_entry = init_entry (state, "content-entry",
109
 
                sheet_widget_list_base_get_content_dep (so));
 
120
                                           sheet_widget_list_base_get_content_dep (so));
110
121
        state->link_entry = init_entry (state, "link-entry",
111
 
                sheet_widget_list_base_get_result_dep (so));
 
122
                                        sheet_widget_list_base_get_result_dep (so));
112
123
 
113
124
        g_signal_connect (G_OBJECT (state->dialog), "response",
114
125
                G_CALLBACK (cb_so_list_response), state);