2006-09-05 Michael Dominic Kostrzewa <michael.kostrzewa@nokia.com>
+ * hildon-widgets/hildon-note.c: Fixing the behaviour of
+ hildon_note_new_confirmation_with_icon_stock. Fixes #NB22825.
+
+2006-09-05 Michael Dominic Kostrzewa <michael.kostrzewa@nokia.com>
+
* hildon-widgets/hildon-font-selection-dialog.c: Adding a
"font-scaling" property that allows to customize the output of the
Preview dialog during font selection. By default font-scaling equals
PROP_HILDON_NOTE_TYPE,
PROP_HILDON_NOTE_DESCRIPTION,
PROP_HILDON_NOTE_ICON,
- PROP_HILDON_NOTE_PROGRESSBAR
+ PROP_HILDON_NOTE_PROGRESSBAR,
+ PROP_HILDON_NOTE_STOCK_ICON
};
static void
gtk_image_set_from_icon_name(GTK_IMAGE(priv->icon),
g_value_get_string(value), HILDON_ICON_SIZE_BIG_NOTE);
break;
+ case PROP_HILDON_NOTE_STOCK_ICON:
+ gtk_image_set_from_stock(GTK_IMAGE(priv->icon),
+ g_value_get_string(value), HILDON_ICON_SIZE_BIG_NOTE);
+ break;
case PROP_HILDON_NOTE_PROGRESSBAR:
widget = g_value_get_object(value);
if (widget != priv->progressbar)
case PROP_HILDON_NOTE_ICON:
g_object_get_property(G_OBJECT(priv->icon), "icon-name", value);
break;
+ case PROP_HILDON_NOTE_STOCK_ICON:
+ g_object_get_property(G_OBJECT(priv->icon), "stock", value);
+ break;
case PROP_HILDON_NOTE_PROGRESSBAR:
g_value_set_object(value, priv->progressbar);
break;
"",
G_PARAM_READWRITE));
+ /**
+ * HildonNote:stock-icon:
+ *
+ * Stock icon for note.
+ */
+ g_object_class_install_property(object_class,
+ PROP_HILDON_NOTE_STOCK_ICON,
+ g_param_spec_string("stock-icon",
+ "Stock note icon",
+ "The stock name of the icon that appears in the note dialog",
+ "",
+ G_PARAM_READWRITE));
+
/**
* HildonNote:progressbar:
*
const gchar *
stock_id)
{
- /* FIXME: This function is broken. We cannot detect if the "icon"
- means icon name or stock-id, since the type is the same
- as in the following function. Anyway, since we really
- do not support stock icons properly, this is a minor issue. */
GtkWidget *dialog = g_object_new(HILDON_TYPE_NOTE,
"note_type",
HILDON_NOTE_CONFIRMATION_TYPE,
- "description", description, "icon",
+ "description", description, "stock-icon",
stock_id, NULL);
if (parent != NULL)