summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorPadraig O'Briain <padraigo@src.gnome.org>2001-06-12 12:57:12 +0000
committerPadraig O'Briain <padraigo@src.gnome.org>2001-06-12 12:57:12 +0000
commit51f3b4ae25be17ad62e0258d36c7825587ad21ab (patch)
tree62ade381ceedcf8e7eacc3191673ff2e65285c5c
parentb686b7f2f0e8cb753d5e51edcf084969aff6341c (diff)
downloadatk-51f3b4ae25be17ad62e0258d36c7825587ad21ab.tar.gz
Add signal model-changed.
* atk/atkmarshal.list, atk/atktable.h atk/atktable.c: Add signal model-changed. * atk/atkobject.c: Add properties accessible-role, accessible-table-caption, accessible-table-column-header, accessible-table-column_description. accessible-table-row-header, accessible-table-row_description. accessible-table-summary, accessible-model
-rw-r--r--ChangeLog11
-rw-r--r--atk/atkmarshal.list1
-rwxr-xr-xatk/atkobject.c82
-rwxr-xr-xatk/atktable.c41
-rwxr-xr-xatk/atktable.h9
5 files changed, 141 insertions, 3 deletions
diff --git a/ChangeLog b/ChangeLog
index 3f0fc94..db0458f 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,14 @@
+2001-06-12 Padraig O'Briain <padraig.obriain@sun.com>
+
+ * atk/atkmarshal.list, atk/atktable.h atk/atktable.c:
+ Add signal model-changed.
+
+ * atk/atkobject.c: Add properties
+ accessible-role, accessible-table-caption,
+ accessible-table-column-header, accessible-table-column_description.
+ accessible-table-row-header, accessible-table-row_description.
+ accessible-table-summary, accessible-model
+
2001-06-12 Brian Cameron <brian.cameron@sun.com>
* atk/atkeditabletext.[ch], atk/atktext.[ch], atk/atkobject.h
diff --git a/atk/atkmarshal.list b/atk/atkmarshal.list
index 2d9dd51..196945a 100644
--- a/atk/atkmarshal.list
+++ b/atk/atkmarshal.list
@@ -23,3 +23,4 @@
# BOOL deprecated alias for BOOLEAN
VOID:INT,INT
+VOID:INT,INT,INT,INT,INT
diff --git a/atk/atkobject.c b/atk/atkobject.c
index 5368f62..495be2f 100755
--- a/atk/atkobject.c
+++ b/atk/atkobject.c
@@ -38,6 +38,14 @@ enum
PROP_SELECTION,
PROP_VALUE,
PROP_VISIBLE_DATA,
+ PROP_ROLE,
+ PROP_TABLE_CAPTION,
+ PROP_TABLE_COLUMN_DESCRIPTION,
+ PROP_TABLE_COLUMN_HEADER,
+ PROP_TABLE_ROW_DESCRIPTION,
+ PROP_TABLE_ROW_HEADER,
+ PROP_TABLE_SUMMARY,
+ PROP_MODEL,
PROP_LAST /* gobject convention */
};
@@ -78,6 +86,14 @@ static const gchar* atk_object_name_property_caret = "accessible-caret";
static const gchar* atk_object_name_property_selection = "accessible-selection";
static const gchar* atk_object_name_property_value = "accessible-value";
static const gchar* atk_object_name_property_visible = "accessible-visible-data";
+static const gchar* atk_object_name_property_role = "accessible-role";
+static const gchar* atk_object_name_property_table_caption = "accessible-table-caption";
+static const gchar* atk_object_name_property_table_column_description = "accessible-table-column-description";
+static const gchar* atk_object_name_property_table_column_header = "accessible-table-column-header";
+static const gchar* atk_object_name_property_table_row_description = "accessible-table-row-description";
+static const gchar* atk_object_name_property_table_row_header = "accessible-table-row-header";
+static const gchar* atk_object_name_property_table_summary = "accessible-table-summary";
+static const gchar* atk_object_name_property_model = "accessible-model";
GType
atk_object_get_type (void)
@@ -156,8 +172,8 @@ atk_object_class_init (AtkObjectClass *klass)
"Is used to notify that a child has been added or removed ",
ATK_TYPE_OBJECT,
G_PARAM_READWRITE));
- g_object_class_install_property (gobject_class,
- PROP_PARENT,
+ g_object_class_install_property (gobject_class,
+ PROP_PARENT,
g_param_spec_object (atk_object_name_property_parent,
"Accessible Parent",
"Is used to notify that the parent has changed ",
@@ -202,6 +218,68 @@ atk_object_class_init (AtkObjectClass *klass)
"Is used to notify that the visual appearance of the object has changed ",
ATK_TYPE_OBJECT,
G_PARAM_READWRITE));
+ g_object_class_install_property (gobject_class,
+ PROP_ROLE,
+ g_param_spec_int (atk_object_name_property_role,
+ "Accessible Role",
+ "The accessible role this object ",
+ 0,
+ G_MAXINT,
+ 0,
+ G_PARAM_READWRITE));
+ g_object_class_install_property (gobject_class,
+ PROP_TABLE_CAPTION,
+ g_param_spec_object (atk_object_name_property_table_caption,
+ "Accessible Table Caption",
+ "Is used to notify that the table caption has changed ",
+ ATK_TYPE_OBJECT,
+ G_PARAM_READWRITE));
+ g_object_class_install_property (gobject_class,
+ PROP_TABLE_COLUMN_HEADER,
+ g_param_spec_object (atk_object_name_property_table_column_header,
+ "Accessible Table Column Header",
+ "Is used to notify that the table column header has changed ",
+ ATK_TYPE_OBJECT,
+ G_PARAM_READWRITE));
+ g_object_class_install_property (gobject_class,
+ PROP_TABLE_COLUMN_DESCRIPTION,
+ g_param_spec_int (atk_object_name_property_table_column_description,
+ "Accessible Table Columnn Description",
+ "Is used to notify that the table columnscription has changed ",
+ 0,
+ G_MAXINT,
+ 0,
+ G_PARAM_READWRITE));
+ g_object_class_install_property (gobject_class,
+ PROP_TABLE_ROW_HEADER,
+ g_param_spec_object (atk_object_name_property_table_row_header,
+ "Accessible Table Row Header",
+ "Is used to notify that the table row header has changed ",
+ ATK_TYPE_OBJECT,
+ G_PARAM_READWRITE));
+ g_object_class_install_property (gobject_class,
+ PROP_TABLE_ROW_DESCRIPTION,
+ g_param_spec_int (atk_object_name_property_table_row_description,
+ "Accessible Table Row Description",
+ "Is used to notify that the table row description has changed ",
+ 0,
+ G_MAXINT,
+ 0,
+ G_PARAM_READWRITE));
+ g_object_class_install_property (gobject_class,
+ PROP_TABLE_SUMMARY,
+ g_param_spec_object (atk_object_name_property_table_summary,
+ "Accessible Table Summary",
+ "Is used to notify that the table summary has changed ",
+ ATK_TYPE_OBJECT,
+ G_PARAM_READWRITE));
+ g_object_class_install_property (gobject_class,
+ PROP_MODEL,
+ g_param_spec_object (atk_object_name_property_model,
+ "Accessible Model",
+ "Is used to notify that the model for Table or Tree has changed ",
+ ATK_TYPE_OBJECT,
+ G_PARAM_READWRITE));
/*
* The signal "children_changed" supports two details:
* "add" and "remove"
diff --git a/atk/atktable.c b/atk/atktable.c
index 338fb56..0236a1b 100755
--- a/atk/atktable.c
+++ b/atk/atktable.c
@@ -18,6 +18,23 @@
*/
#include "atktable.h"
+#include "atkmarshal.h"
+
+enum {
+ MODEL_CHANGED,
+ LAST_SIGNAL
+};
+
+struct _AtkTableIfaceClass
+{
+ GObjectClass parent;
+};
+
+typedef struct _AtkTableIfaceClass AtkTableIfaceClass;
+
+static void atk_table_base_init (gpointer *g_class);
+
+static guint atk_table_signals[LAST_SIGNAL] = { 0 };
GType
atk_table_get_type ()
@@ -28,7 +45,7 @@ atk_table_get_type ()
GTypeInfo tinfo =
{
sizeof (AtkTableIface),
- (GBaseInitFunc) NULL,
+ (GBaseInitFunc) atk_table_base_init,
(GBaseFinalizeFunc) NULL,
};
@@ -39,6 +56,28 @@ atk_table_get_type ()
return type;
}
+
+static void
+atk_table_base_init (gpointer *g_class)
+{
+ static gboolean initialized = FALSE;
+
+ if (! initialized)
+ {
+ atk_table_signals[MODEL_CHANGED] =
+ g_signal_newc ("model_changed",
+ ATK_TYPE_TABLE,
+ G_SIGNAL_RUN_LAST,
+ G_STRUCT_OFFSET (AtkTableIface, model_changed),
+ (GSignalAccumulator) NULL, NULL,
+ atk_marshal_VOID__INT_INT_INT_INT_INT,
+ G_TYPE_NONE,
+ 5, G_TYPE_INT, G_TYPE_INT, G_TYPE_INT, G_TYPE_INT,
+ G_TYPE_INT);
+ initialized = TRUE;
+ }
+}
+
/**
* atk_table_ref_at:
* @table: a GObject instance that implements AtkTableIface
diff --git a/atk/atktable.h b/atk/atktable.h
index b4d86a5..87ab435 100755
--- a/atk/atktable.h
+++ b/atk/atktable.h
@@ -98,6 +98,15 @@ struct _AtkTableIface
AtkTable *header);
void (* set_summary) (AtkTable *table,
AtkObject *accessible);
+ /*
+ * signal handlers
+ */
+ void (* model_changed) (AtkTable *table,
+ gint type,
+ gint first_row,
+ gint last_row,
+ gint first_column,
+ gint last_column);
};
GType atk_table_get_type ();