mirror of
https://gitlab.gnome.org/GNOME/glade.git
synced 2025-10-08 00:04:35 -04:00
More janitoring. Remove dead code.
This commit is contained in:
parent
6d7ae493b0
commit
46e859b6c9
@ -1,14 +1,15 @@
|
|||||||
2003-11-01 Paolo Borelli <pbprelli@katamail.com>
|
2003-11-01 Paolo Borelli <pborelli@katamail.com>
|
||||||
|
|
||||||
* glade-3.desktop.in: minor updates from glade-2.
|
* glade-3.desktop.in: minor updates from glade-2.
|
||||||
* Makefile.am: remove .dektop file on make clean.
|
* Makefile.am: remove .dektop file on make clean.
|
||||||
* src/glade-property.[ch]: ifdef out the ->child member since it's
|
* src/glade-property.[ch]: ifdef out the ->child member since it's
|
||||||
unused.
|
unused. Remove glade_property_get_* since they are not needed.
|
||||||
* src/glade-widget.[ch]: move here the get_property_by_id function and
|
* src/glade-widget.[ch]: move here the get_property_by_id function and
|
||||||
simplify the get_property_by_class. Use apply_property_from_node also
|
simplify the get_property_by_class. Use apply_property_from_node also
|
||||||
for packing properties.
|
for packing properties.
|
||||||
* src/glade-gtk.c: fixups for the above changes.
|
* src/glade-gtk.c: fixups for the above changes.
|
||||||
* src/glade-editor.c: ditto.
|
* src/glade-editor.c: ditto.
|
||||||
|
* src/glade-types.h: remove GladePaletteSelection.
|
||||||
|
|
||||||
2003-10-31 Paolo Borelli <pborelli@katamail.com>
|
2003-10-31 Paolo Borelli <pborelli@katamail.com>
|
||||||
|
|
||||||
|
@ -221,86 +221,6 @@ glade_property_refresh (GladeProperty *property)
|
|||||||
glade_property_set (property, property->value);
|
glade_property_set (property, property->value);
|
||||||
}
|
}
|
||||||
|
|
||||||
const gchar *
|
|
||||||
glade_property_get_string (GladeProperty *property)
|
|
||||||
{
|
|
||||||
g_return_val_if_fail (property != NULL, NULL);
|
|
||||||
g_return_val_if_fail (property->value != NULL, NULL);
|
|
||||||
|
|
||||||
return g_value_get_string (property->value);
|
|
||||||
}
|
|
||||||
|
|
||||||
gint
|
|
||||||
glade_property_get_integer (GladeProperty *property)
|
|
||||||
{
|
|
||||||
g_return_val_if_fail (property != NULL, 0);
|
|
||||||
g_return_val_if_fail (property->value != NULL, 0);
|
|
||||||
|
|
||||||
return g_value_get_int (property->value);
|
|
||||||
}
|
|
||||||
|
|
||||||
gfloat
|
|
||||||
glade_property_get_float (GladeProperty *property)
|
|
||||||
{
|
|
||||||
gfloat resp;
|
|
||||||
g_return_val_if_fail (property != NULL, 0.0);
|
|
||||||
g_return_val_if_fail (property->value != NULL, 0.0);
|
|
||||||
|
|
||||||
resp = g_value_get_float (property->value);
|
|
||||||
|
|
||||||
return resp;
|
|
||||||
}
|
|
||||||
|
|
||||||
gdouble
|
|
||||||
glade_property_get_double (GladeProperty *property)
|
|
||||||
{
|
|
||||||
g_return_val_if_fail (property != NULL, 0.0);
|
|
||||||
g_return_val_if_fail (property->value != NULL, 0.0);
|
|
||||||
|
|
||||||
return g_value_get_double (property->value);
|
|
||||||
}
|
|
||||||
|
|
||||||
gboolean
|
|
||||||
glade_property_get_boolean (GladeProperty *property)
|
|
||||||
{
|
|
||||||
g_return_val_if_fail (property != NULL, FALSE);
|
|
||||||
g_return_val_if_fail (property->value != NULL, FALSE);
|
|
||||||
|
|
||||||
return g_value_get_boolean (property->value);
|
|
||||||
}
|
|
||||||
|
|
||||||
gunichar
|
|
||||||
glade_property_get_unichar (GladeProperty *property)
|
|
||||||
{
|
|
||||||
g_return_val_if_fail (property != NULL, g_utf8_get_char (" "));
|
|
||||||
g_return_val_if_fail (property->value != NULL, g_utf8_get_char (" "));
|
|
||||||
|
|
||||||
return g_value_get_uint (property->value);
|
|
||||||
}
|
|
||||||
|
|
||||||
GladeChoice *
|
|
||||||
glade_property_get_enum (GladeProperty *property)
|
|
||||||
{
|
|
||||||
GladeChoice *choice = NULL;
|
|
||||||
GList *list;
|
|
||||||
gint value;
|
|
||||||
|
|
||||||
g_return_val_if_fail (property != NULL, NULL);
|
|
||||||
g_return_val_if_fail (property->value != NULL, NULL);
|
|
||||||
|
|
||||||
value = g_value_get_enum (property->value);
|
|
||||||
list = property->class->choices;
|
|
||||||
for (; list; list = list->next) {
|
|
||||||
choice = list->data;
|
|
||||||
if (choice->value == value)
|
|
||||||
break;
|
|
||||||
}
|
|
||||||
if (list == NULL)
|
|
||||||
g_warning ("Cant find the GladePropertyChoice selected\n");
|
|
||||||
|
|
||||||
return choice;
|
|
||||||
}
|
|
||||||
|
|
||||||
GladeXmlNode *
|
GladeXmlNode *
|
||||||
glade_property_write (GladeXmlContext *context, GladeProperty *property)
|
glade_property_write (GladeXmlContext *context, GladeProperty *property)
|
||||||
{
|
{
|
||||||
@ -366,7 +286,7 @@ void
|
|||||||
glade_property_get_from_widget (GladeProperty *property)
|
glade_property_get_from_widget (GladeProperty *property)
|
||||||
{
|
{
|
||||||
gboolean bool = FALSE;
|
gboolean bool = FALSE;
|
||||||
|
|
||||||
g_value_reset (property->value);
|
g_value_reset (property->value);
|
||||||
|
|
||||||
if (property->class->get_function)
|
if (property->class->get_function)
|
||||||
|
@ -60,14 +60,6 @@ void glade_property_free (GladeProperty *property);
|
|||||||
void glade_property_set (GladeProperty *property, const GValue *value);
|
void glade_property_set (GladeProperty *property, const GValue *value);
|
||||||
void glade_property_refresh (GladeProperty *property);
|
void glade_property_refresh (GladeProperty *property);
|
||||||
|
|
||||||
const gchar * glade_property_get_string (GladeProperty *property);
|
|
||||||
gint glade_property_get_integer (GladeProperty *property);
|
|
||||||
gfloat glade_property_get_float (GladeProperty *property);
|
|
||||||
gdouble glade_property_get_double (GladeProperty *property);
|
|
||||||
gboolean glade_property_get_boolean (GladeProperty *property);
|
|
||||||
gunichar glade_property_get_unichar (GladeProperty *property);
|
|
||||||
GladeChoice * glade_property_get_enum (GladeProperty *property);
|
|
||||||
|
|
||||||
void glade_property_get_from_widget (GladeProperty *property);
|
void glade_property_get_from_widget (GladeProperty *property);
|
||||||
|
|
||||||
/* XML i/o */
|
/* XML i/o */
|
||||||
|
@ -1,7 +1,6 @@
|
|||||||
#ifndef __GLADE_TYPES_H__
|
#ifndef __GLADE_TYPES_H__
|
||||||
#define __GLADE_TYPES_H__
|
#define __GLADE_TYPES_H__
|
||||||
|
|
||||||
typedef struct _GladePaletteSection GladePaletteSection;
|
|
||||||
|
|
||||||
typedef struct _GladePalette GladePalette;
|
typedef struct _GladePalette GladePalette;
|
||||||
typedef struct _GladeEditor GladeEditor;
|
typedef struct _GladeEditor GladeEditor;
|
||||||
|
Loading…
x
Reference in New Issue
Block a user