[gnumeric] some more G_VALUE_INIT uses
- From: Andreas J. Guelzow <guelzow src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [gnumeric] some more G_VALUE_INIT uses
- Date: Wed, 30 Nov 2011 22:13:53 +0000 (UTC)
commit ae8b2d98deab4e5fe44626bfd1d658449478ba95
Author: Andreas J Guelzow <aguelzow pyrshep ca>
Date: Wed Nov 30 15:13:06 2011 -0700
some more G_VALUE_INIT uses
2011-11-30 Andreas J. Guelzow <aguelzow pyrshep ca>
* xlsx-read-docprops.c (xlsx_read_core_keys): use G_VALUE_INIT
* xlsx-read.c: add dead-kittens.h
2011-11-30 Andreas J. Guelzow <aguelzow pyrshep ca>
* dialog-doc-metadata.c (gnm_docprop_vector_as_string): use G_VALUE_INIT;
(dialog_doc_metadata_update_keywords_changed): ditto
plugins/excel/ChangeLog | 5 +++
plugins/excel/xlsx-read-docprops.c | 2 +-
plugins/excel/xlsx-read.c | 1 +
src/dialogs/ChangeLog | 5 +++
src/dialogs/dialog-doc-metadata.c | 54 ++++++++++++++++++------------------
5 files changed, 39 insertions(+), 28 deletions(-)
---
diff --git a/plugins/excel/ChangeLog b/plugins/excel/ChangeLog
index 0608dce..286ef00 100644
--- a/plugins/excel/ChangeLog
+++ b/plugins/excel/ChangeLog
@@ -1,5 +1,10 @@
2011-11-30 Andreas J. Guelzow <aguelzow pyrshep ca>
+ * xlsx-read-docprops.c (xlsx_read_core_keys): use G_VALUE_INIT
+ * xlsx-read.c: add dead-kittens.h
+
+2011-11-30 Andreas J. Guelzow <aguelzow pyrshep ca>
+
* excel-xml-read.c (xl_xml_selection): adjust call to
sv_selection_add_full
* ms-excel-read.c (excel_read_SELECTION): adjust calls to
diff --git a/plugins/excel/xlsx-read-docprops.c b/plugins/excel/xlsx-read-docprops.c
index 4e4f180..64d355d 100644
--- a/plugins/excel/xlsx-read-docprops.c
+++ b/plugins/excel/xlsx-read-docprops.c
@@ -36,7 +36,7 @@ xlsx_read_core_keys (GsfXMLIn *xin, G_GNUC_UNUSED GsfXMLBlob *blob)
XLSXReadState *state = (XLSXReadState *)xin->user_state;
gchar **strs, **orig_strs;
GsfDocPropVector *keywords;
- GValue v = {0};
+ GValue v = G_VALUE_INIT;
int count = 0;
if (strlen (xin->content->str) == 0)
diff --git a/plugins/excel/xlsx-read.c b/plugins/excel/xlsx-read.c
index 4b81577..728a8d6 100644
--- a/plugins/excel/xlsx-read.c
+++ b/plugins/excel/xlsx-read.c
@@ -53,6 +53,7 @@
#include "gnm-so-filled.h"
#include "gnm-so-line.h"
#include "sheet-object-image.h"
+#include "dead-kittens.h"
#include <goffice/goffice.h>
diff --git a/src/dialogs/ChangeLog b/src/dialogs/ChangeLog
index bfce9c8..289d8eb 100644
--- a/src/dialogs/ChangeLog
+++ b/src/dialogs/ChangeLog
@@ -1,5 +1,10 @@
2011-11-30 Andreas J. Guelzow <aguelzow pyrshep ca>
+ * dialog-doc-metadata.c (gnm_docprop_vector_as_string): use G_VALUE_INIT;
+ (dialog_doc_metadata_update_keywords_changed): ditto
+
+2011-11-30 Andreas J. Guelzow <aguelzow pyrshep ca>
+
* dialog-doc-metadata.c: add dead-kittens.h
(dialog_doc_metadata_set_gsf_prop_val): use G_VALUE_INIT;
diff --git a/src/dialogs/dialog-doc-metadata.c b/src/dialogs/dialog-doc-metadata.c
index 1997c19..c4feb49 100644
--- a/src/dialogs/dialog-doc-metadata.c
+++ b/src/dialogs/dialog-doc-metadata.c
@@ -505,7 +505,7 @@ gnm_docprop_vector_as_string (GsfDocPropVector *vector)
guint i;
guint num_values;
GValueArray *gva;
- GValue vl = {0};
+ GValue vl = G_VALUE_INIT;
g_return_val_if_fail (vector != NULL, NULL);
@@ -811,7 +811,7 @@ dialog_doc_metadata_get_gsf_prop_val_type (DialogDocMetaData *state,
}
static void
-dialog_doc_metadata_set_gsf_prop_val (DialogDocMetaData *state,
+dialog_doc_metadata_set_gsf_prop_val (G_GNUC_UNUSED DialogDocMetaData *state,
GValue *prop_value,
const gchar *str_val)
{
@@ -1026,7 +1026,7 @@ dialog_doc_metadata_set_prop (DialogDocMetaData *state,
**/
static gboolean
cb_dialog_doc_metadata_title_changed (GtkEntry *entry,
- GdkEventFocus *event,
+ G_GNUC_UNUSED GdkEventFocus *event,
DialogDocMetaData *state)
{
dialog_doc_metadata_set_prop (state,
@@ -1038,7 +1038,7 @@ cb_dialog_doc_metadata_title_changed (GtkEntry *entry,
static gboolean
cb_dialog_doc_metadata_subject_changed (GtkEntry *entry,
- GdkEventFocus *event,
+ G_GNUC_UNUSED GdkEventFocus *event,
DialogDocMetaData *state)
{
dialog_doc_metadata_set_prop (state,
@@ -1050,7 +1050,7 @@ cb_dialog_doc_metadata_subject_changed (GtkEntry *entry,
static gboolean
cb_dialog_doc_metadata_author_changed (GtkEntry *entry,
- GdkEventFocus *event,
+ G_GNUC_UNUSED GdkEventFocus *event,
DialogDocMetaData *state)
{
dialog_doc_metadata_set_prop (state,
@@ -1062,7 +1062,7 @@ cb_dialog_doc_metadata_author_changed (GtkEntry *entry,
static gboolean
cb_dialog_doc_metadata_manager_changed (GtkEntry *entry,
- GdkEventFocus *event,
+ G_GNUC_UNUSED GdkEventFocus *event,
DialogDocMetaData *state)
{
dialog_doc_metadata_set_prop (state,
@@ -1074,7 +1074,7 @@ cb_dialog_doc_metadata_manager_changed (GtkEntry *entry,
static gboolean
cb_dialog_doc_metadata_company_changed (GtkEntry *entry,
- GdkEventFocus *event,
+ G_GNUC_UNUSED GdkEventFocus *event,
DialogDocMetaData *state)
{
dialog_doc_metadata_set_prop (state,
@@ -1086,7 +1086,7 @@ cb_dialog_doc_metadata_company_changed (GtkEntry *entry,
static gboolean
cb_dialog_doc_metadata_category_changed (GtkEntry *entry,
- GdkEventFocus *event,
+ G_GNUC_UNUSED GdkEventFocus *event,
DialogDocMetaData *state)
{
dialog_doc_metadata_set_prop (state,
@@ -1098,7 +1098,7 @@ cb_dialog_doc_metadata_category_changed (GtkEntry *entry,
static gboolean
cb_dialog_doc_metadata_comments_changed (GtkTextView *view,
- GdkEventFocus *event,
+ G_GNUC_UNUSED GdkEventFocus *event,
DialogDocMetaData *state)
{
GtkTextIter start_iter;
@@ -1177,7 +1177,7 @@ dialog_doc_metadata_init_description_page (DialogDocMetaData *state)
static void
dialog_doc_metadata_update_keywords_changed (DialogDocMetaData *state)
{
- GValue val = {0};
+ GValue val = G_VALUE_INIT;
GtkTreeIter iter;
GsfDocPropVector *vector = gsf_docprop_vector_new ();
@@ -1242,8 +1242,8 @@ dialog_doc_metadata_update_keyword_list (DialogDocMetaData *state, GsfDocProp *p
}
static void
-cb_dialog_doc_metadata_keywords_add_clicked (GtkWidget *w,
- DialogDocMetaData *state)
+cb_dialog_doc_metadata_keywords_add_clicked (G_GNUC_UNUSED GtkWidget *w,
+ DialogDocMetaData *state)
{
gtk_list_store_insert_with_values (state->key_store, NULL, G_MAXINT,
0, "<?>", -1);
@@ -1251,8 +1251,8 @@ cb_dialog_doc_metadata_keywords_add_clicked (GtkWidget *w,
}
static void
-cb_dialog_doc_metadata_keywords_remove_clicked (GtkWidget *w,
- DialogDocMetaData *state)
+cb_dialog_doc_metadata_keywords_remove_clicked (G_GNUC_UNUSED GtkWidget *w,
+ DialogDocMetaData *state)
{
GtkTreeIter iter;
GtkTreeSelection *sel = gtk_tree_view_get_selection (state->key_tree_view);
@@ -1264,10 +1264,10 @@ cb_dialog_doc_metadata_keywords_remove_clicked (GtkWidget *w,
}
static void
-cb_dialog_doc_metadata_keyword_edited (GtkCellRendererText *renderer,
- gchar *path,
- gchar *new_text,
- DialogDocMetaData *state)
+cb_dialog_doc_metadata_keyword_edited (G_GNUC_UNUSED GtkCellRendererText *renderer,
+ gchar *path,
+ gchar *new_text,
+ DialogDocMetaData *state)
{
GtkTreeIter iter;
if (gtk_tree_model_get_iter_from_string (GTK_TREE_MODEL (state->key_store), &iter, path)) {
@@ -1332,10 +1332,10 @@ dialog_doc_metadata_init_keywords_page (DialogDocMetaData *state)
******************************************************************************/
static void
-cb_dialog_doc_metadata_value_edited (GtkCellRendererText *renderer,
- gchar *path,
- gchar *new_text,
- DialogDocMetaData *state)
+cb_dialog_doc_metadata_value_edited (G_GNUC_UNUSED GtkCellRendererText *renderer,
+ gchar *path,
+ gchar *new_text,
+ DialogDocMetaData *state)
{
GtkTreeIter iter;
if (gtk_tree_model_get_iter_from_string
@@ -1366,8 +1366,8 @@ cb_dialog_doc_metadata_value_edited (GtkCellRendererText *renderer,
*
**/
static void
-cb_dialog_doc_metadata_add_clicked (GtkWidget *w,
- DialogDocMetaData *state)
+cb_dialog_doc_metadata_add_clicked (G_GNUC_UNUSED GtkWidget *w,
+ DialogDocMetaData *state)
{
const gchar *name = gtk_entry_get_text (state->ppt_name);
const gchar *value = gtk_entry_get_text (state->ppt_value);
@@ -1593,9 +1593,9 @@ cb_dialog_doc_metadata_tree_prop_selected (GtkTreeSelection *selection,
*
**/
static gchar *
-dialog_doc_metadata_get_prop_val (DialogDocMetaData *state,
- char const *prop_name,
- GValue *prop_value)
+dialog_doc_metadata_get_prop_val (G_GNUC_UNUSED DialogDocMetaData *state,
+ char const *prop_name,
+ GValue *prop_value)
{
GValue str_value = G_VALUE_INIT;
gboolean ret = FALSE;
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]