Browse Source

Fix a whole bunch of compiler warnings.

upstream/xfce4-panel-4.10.1
Nick Schermer 13 years ago
parent
commit
eaaaa403d6
  1. 3
      libxfce4panel/Makefile.am
  2. 12
      libxfce4panel/libxfce4panel.h
  3. 2
      libxfce4panel/xfce-arrow-button.c
  4. 2
      libxfce4panel/xfce-hvbox.c
  5. 4
      libxfce4panel/xfce-panel-plugin-provider.c
  6. 2
      libxfce4panel/xfce-panel-plugin-provider.h
  7. 5
      libxfce4panel/xfce-panel-plugin.c
  8. 2
      libxfce4panel/xfce-scaled-image.c
  9. 3
      panel/Makefile.am
  10. 5
      panel/main.c
  11. 53
      panel/panel-application.c
  12. 45
      panel/panel-dbus-service.c
  13. 2
      panel/panel-dbus-service.h
  14. 7
      panel/panel-glue.h
  15. 10
      panel/panel-item-dialog.c
  16. 14
      panel/panel-itembar.c
  17. 10
      panel/panel-module-factory.c
  18. 2
      panel/panel-module.c
  19. 22
      panel/panel-plugin-external.c
  20. 3
      panel/panel-preferences-dialog.c
  21. 4
      panel/panel-window.c
  22. 26
      plugins/clock/clock-analog.c
  23. 2
      plugins/clock/clock-analog.h
  24. 49
      plugins/clock/clock-binary.c
  25. 2
      plugins/clock/clock-binary.h
  26. 38
      plugins/clock/clock-digital.c
  27. 2
      plugins/clock/clock-digital.h
  28. 35
      plugins/clock/clock-fuzzy.c
  29. 2
      plugins/clock/clock-fuzzy.h
  30. 62
      plugins/clock/clock-lcd.c
  31. 2
      plugins/clock/clock-lcd.h
  32. 8
      plugins/clock/clock.c
  33. 82
      plugins/launcher/launcher-dialog.glade
  34. 15
      plugins/launcher/launcher.c
  35. 13
      plugins/launcher/launcher.h
  36. 2
      plugins/pager/pager.c
  37. 11
      plugins/separator/separator.c
  38. 4
      plugins/showdesktop/showdesktop.c
  39. 28
      plugins/systray/Makefile.am
  40. 29
      plugins/systray/xfce-tray-manager.c
  41. 28
      plugins/systray/xfce-tray-widget.c
  42. 11
      plugins/tasklist/tasklist-widget.c
  43. 5
      plugins/tasklist/tasklist.c
  44. 3
      wrapper/Makefile.am
  45. 23
      wrapper/main.c
  46. 11
      wrapper/wrapper-plug.c
  47. 14
      wrapper/wrapper-plug.h

3
libxfce4panel/Makefile.am

@ -73,7 +73,8 @@ libxfce4panel-marshal.h: libxfce4panel-marshal.list Makefile
glib-genmarshal --prefix=_libxfce4panel_marshal --internal --header $< > $@
libxfce4panel-marshal.c: libxfce4panel-marshal.list Makefile
glib-genmarshal --prefix=_libxfce4panel_marshal --body $< > $@
echo "#include <libxfce4panel/libxfce4panel-marshal.h>" > $@ \
&& glib-genmarshal --prefix=_libxfce4panel_marshal --body $< >> $@
DISTCLEANFILES = \
$(libxfce4panel_built_sources)

12
libxfce4panel/libxfce4panel.h

@ -36,6 +36,12 @@ G_BEGIN_DECLS
#define XFCE_PANEL_PLUGIN_REGISTER_OBJECT(TYPE) \
PANEL_SYMBOL_EXPORT G_MODULE_EXPORT XfcePanelPlugin * \
__xpp_construct_obj (const gchar *name, \
gint unique_id, \
const gchar *display_name, \
gchar **arguments, \
GdkScreen *screen); \
PANEL_SYMBOL_EXPORT G_MODULE_EXPORT XfcePanelPlugin * \
__xpp_construct_obj (const gchar *name, \
gint unique_id, \
const gchar *display_name, \
@ -71,6 +77,12 @@ G_BEGIN_DECLS
} \
\
PANEL_SYMBOL_EXPORT G_MODULE_EXPORT XfcePanelPlugin * \
__xpp_construct (const gchar *name, \
gint unique_id, \
const gchar *display_name, \
gchar **arguments, \
GdkScreen *screen); \
PANEL_SYMBOL_EXPORT G_MODULE_EXPORT XfcePanelPlugin * \
__xpp_construct (const gchar *name, \
gint unique_id, \
const gchar *display_name, \

2
libxfce4panel/xfce-arrow-button.c

@ -47,8 +47,6 @@ enum
PROP_ARROW_TYPE
};
static void xfce_arrow_button_class_init (XfceArrowButtonClass *klass);
static void xfce_arrow_button_init (XfceArrowButton *button);
static void xfce_arrow_button_set_property (GObject *object,
guint prop_id,
const GValue *value,

2
libxfce4panel/xfce-hvbox.c

@ -31,8 +31,6 @@
static void xfce_hvbox_class_init (XfceHVBoxClass *klass);
static void xfce_hvbox_init (XfceHVBox *hvbox);
static gpointer xfce_hvbox_get_class (XfceHVBox *hvbox);
static void xfce_hvbox_size_request (GtkWidget *widget,
GtkRequisition *requisition);

4
libxfce4panel/xfce-panel-plugin-provider.c

@ -142,12 +142,12 @@ xfce_panel_plugin_provider_save (XfcePanelPluginProvider *provider)
PANEL_SYMBOL_EXPORT void
xfce_panel_plugin_provider_emit_signal (XfcePanelPluginProvider *provider,
XfcePanelPluginProviderSignal signal)
XfcePanelPluginProviderSignal provider_signal)
{
panel_return_if_fail (XFCE_IS_PANEL_PLUGIN_PROVIDER (provider));
/* emit the signal */
g_signal_emit (G_OBJECT (provider), provider_signals[PROVIDER_SIGNAL], 0, signal);
g_signal_emit (G_OBJECT (provider), provider_signals[PROVIDER_SIGNAL], 0, provider_signal);
}

2
libxfce4panel/xfce-panel-plugin-provider.h

@ -106,7 +106,7 @@ void xfce_panel_plugin_provider_set_screen_position (XfcePanelPluginProv
void xfce_panel_plugin_provider_save (XfcePanelPluginProvider *provider);
void xfce_panel_plugin_provider_emit_signal (XfcePanelPluginProvider *provider,
XfcePanelPluginProviderSignal signal);
XfcePanelPluginProviderSignal provider_signal);
gboolean xfce_panel_plugin_provider_get_show_configure (XfcePanelPluginProvider *provider);

5
libxfce4panel/xfce-panel-plugin.c

@ -33,12 +33,13 @@
#define XFCE_PANEL_PLUGIN_GET_PRIVATE(obj) (G_TYPE_INSTANCE_GET_PRIVATE ((obj), XFCE_TYPE_PANEL_PLUGIN, XfcePanelPluginPrivate))
typedef const gchar *(*ProviderToPluginChar) (XfcePanelPluginProvider *provider);
typedef gint (*ProviderToPluginInt) (XfcePanelPluginProvider *provider);
static void xfce_panel_plugin_class_init (XfcePanelPluginClass *klass);
static void xfce_panel_plugin_init (XfcePanelPlugin *plugin);
static void xfce_panel_plugin_provider_init (XfcePanelPluginProviderIface *iface);
static void xfce_panel_plugin_get_property (GObject *object,
guint prop_id,

2
libxfce4panel/xfce-scaled-image.c

@ -59,8 +59,6 @@ struct _XfceScaledImage
static void xfce_scaled_image_class_init (XfceScaledImageClass *klass);
static void xfce_scaled_image_init (XfceScaledImage *tasklist);
static void xfce_scaled_image_finalize (GObject *object);
static void xfce_scaled_image_size_request (GtkWidget *widget,
GtkRequisition *requisition);

3
panel/Makefile.am

@ -94,7 +94,8 @@ panel-marshal.h: $(srcdir)/panel-marshal.list Makefile
glib-genmarshal --header --prefix=panel_marshal $< > $@
panel-marshal.c: $(srcdir)/panel-marshal.list Makefile
glib-genmarshal --body --prefix=panel_marshal $< > $@
echo "#include <panel/panel-marshal.h>" > $@ \
&& glib-genmarshal --body --prefix=panel_marshal $< >> $@
DISTCLEANFILES = \
$(xfce4_panel_built_sources)

5
panel/main.c

@ -117,8 +117,6 @@ callback_handler (const gchar *name,
static void
signal_handler (gint signum)
{
extern gboolean dbus_quit_with_restart;
/* don't try to restart */
dbus_quit_with_restart = FALSE;
@ -134,7 +132,6 @@ main (gint argc, gchar **argv)
PanelApplication *application;
GError *error = NULL;
PanelDBusService *dbus_service;
extern gboolean dbus_quit_with_restart;
gboolean result;
guint i;
const gint signums[] = { SIGHUP, SIGINT, SIGQUIT, SIGTERM };
@ -147,7 +144,7 @@ main (gint argc, gchar **argv)
g_thread_init (NULL);
/* initialize gtk+ */
if (!gtk_init_with_args (&argc, &argv, _("[ARGUMENTS...]"), option_entries, GETTEXT_PACKAGE, &error))
if (!gtk_init_with_args (&argc, &argv, _("[ARGUMENTS...]"), option_entries, (gchar *) GETTEXT_PACKAGE, &error))
{
if (G_LIKELY (error))
{

53
panel/panel-application.c

@ -34,6 +34,7 @@
#include <libxfce4panel/libxfce4panel.h>
#include <libxfce4panel/xfce-panel-plugin-provider.h>
#include <panel/panel-dbus-service.h>
#include <panel/panel-window.h>
#include <panel/panel-application.h>
#include <panel/panel-itembar.h>
@ -48,8 +49,6 @@
static void panel_application_class_init (PanelApplicationClass *klass);
static void panel_application_init (PanelApplication *application);
static void panel_application_finalize (GObject *object);
static void panel_application_load (PanelApplication *application);
static void panel_application_plugin_move (GtkWidget *item,
@ -73,13 +72,13 @@ static void panel_application_drag_data_received (GtkWidget *i
gint y,
GtkSelectionData *selection_data,
guint info,
guint time,
guint drag_time,
PanelWindow *window);
static gboolean panel_application_drag_drop (GtkWidget *itembar,
GdkDragContext *context,
gint x,
gint y,
guint time,
guint drag_time,
PanelWindow *window);
@ -116,7 +115,7 @@ struct _PanelApplication
static const GtkTargetEntry drag_targets[] =
{
{ "application/x-xfce-panel-plugin-widget", 0, 0 }
{ (gchar *) "application/x-xfce-panel-plugin-widget", 0, 0 }
};
@ -199,7 +198,7 @@ panel_application_xfconf_window_bindings (PanelApplication *application,
XfconfChannel *channel = application->xfconf;
gchar buf[100];
guint i;
guint index = g_slist_index (application->windows, window);
guint panel_n = g_slist_index (application->windows, window);
GValue value = { 0, };
const gchar *bool_properties[] = { "locked", "autohide", "span-monitors", "horizontal" };
const gchar *uint_properties[] = { "size", "length", "x-offset", "y-offset",
@ -210,13 +209,13 @@ panel_application_xfconf_window_bindings (PanelApplication *application,
for (i = 0; i < G_N_ELEMENTS (bool_properties); i++)
{
/* create xfconf property name */
g_snprintf (buf, sizeof (buf), "/panels/panel-%u/%s", index, bool_properties[i]);
g_snprintf (buf, sizeof (buf), "/panels/panel-%u/%s", panel_n, bool_properties[i]);
/* store the window settings in the channel before we create the binding,
* so we don't loose the panel settings */
if (store_settings)
{
g_value_init(&value, G_TYPE_BOOLEAN);
g_value_init (&value, G_TYPE_BOOLEAN);
g_object_get_property (G_OBJECT (window), bool_properties[i], &value);
xfconf_channel_set_property (channel, buf, &value);
g_value_unset (&value);
@ -230,7 +229,7 @@ panel_application_xfconf_window_bindings (PanelApplication *application,
for (i = 0; i < G_N_ELEMENTS (uint_properties); i++)
{
/* create xfconf property name */
g_snprintf (buf, sizeof (buf), "/panels/panel-%u/%s", index, uint_properties[i]);
g_snprintf (buf, sizeof (buf), "/panels/panel-%u/%s", panel_n, uint_properties[i]);
/* store the window settings in the channel before we create the binding,
* so we don't loose the panel settings */
@ -354,14 +353,13 @@ panel_application_plugin_move (GtkWidget *item,
static void
panel_application_plugin_provider_signal (XfcePanelPluginProvider *provider,
XfcePanelPluginProviderSignal signal,
XfcePanelPluginProviderSignal provider_signal,
PanelApplication *application)
{
GtkWidget *itembar;
PanelWindow *window;
gchar *property;
gchar *path, *filename;
extern gboolean dbus_quit_with_restart;
GtkWidget *itembar;
PanelWindow *window;
gchar *property;
gchar *path, *filename;
panel_return_if_fail (PANEL_IS_APPLICATION (application));
panel_return_if_fail (XFCE_IS_PANEL_PLUGIN_PROVIDER (provider));
@ -370,7 +368,7 @@ panel_application_plugin_provider_signal (XfcePanelPluginProvider *provide
window = PANEL_WINDOW (gtk_widget_get_toplevel (GTK_WIDGET (provider)));
/* handle the signal emitted from the plugin provider */
switch (signal)
switch (provider_signal)
{
case PROVIDER_SIGNAL_MOVE_PLUGIN:
/* invoke the move function */
@ -383,7 +381,8 @@ panel_application_plugin_provider_signal (XfcePanelPluginProvider *provide
itembar = gtk_bin_get_child (GTK_BIN (window));
/* set new expand mode */
panel_itembar_set_child_expand (PANEL_ITEMBAR (itembar), GTK_WIDGET (provider), !!(signal == PROVIDER_SIGNAL_EXPAND_PLUGIN));
panel_itembar_set_child_expand (PANEL_ITEMBAR (itembar), GTK_WIDGET (provider),
!!(provider_signal == PROVIDER_SIGNAL_EXPAND_PLUGIN));
break;
case PROVIDER_SIGNAL_LOCK_PANEL:
@ -437,7 +436,7 @@ panel_application_plugin_provider_signal (XfcePanelPluginProvider *provide
case PROVIDER_SIGNAL_PANEL_QUIT:
case PROVIDER_SIGNAL_PANEL_RESTART:
/* set the restart boolean */
dbus_quit_with_restart = !!(signal == PROVIDER_SIGNAL_PANEL_RESTART);
dbus_quit_with_restart = !!(provider_signal == PROVIDER_SIGNAL_PANEL_RESTART);
/* quit the main loop */
gtk_main_quit ();
@ -606,7 +605,7 @@ panel_application_drag_data_received (GtkWidget *itembar,
gint y,
GtkSelectionData *selection_data,
guint info,
guint time,
guint drag_time,
PanelWindow *window)
{
guint position;
@ -694,7 +693,7 @@ panel_application_drag_data_received (GtkWidget *itembar,
g_object_unref (G_OBJECT (application));
/* tell the peer that we handled the drop */
gtk_drag_finish (context, succeed, FALSE, time);
gtk_drag_finish (context, succeed, FALSE, drag_time);
}
@ -704,7 +703,7 @@ panel_application_drag_drop (GtkWidget *itembar,
GdkDragContext *context,
gint x,
gint y,
guint time,
guint drag_time,
PanelWindow *window)
{
GdkAtom target;
@ -720,7 +719,7 @@ panel_application_drag_drop (GtkWidget *itembar,
return FALSE;
/* request the drag data */
gtk_drag_get_data (itembar, context, target, time);
gtk_drag_get_data (itembar, context, target, drag_time);
/* we call gtk_drag_finish later */
return TRUE;
@ -919,16 +918,6 @@ panel_application_new_window (PanelApplication *application,
GSList *
panel_application_get_windows (PanelApplication *application)
{
panel_return_val_if_fail (PANEL_IS_APPLICATION (application), NULL);
return application->windows;
}
guint
panel_application_get_n_windows (PanelApplication *application)
{

45
panel/panel-dbus-service.c

@ -41,9 +41,36 @@
static void panel_dbus_service_class_init (PanelDBusServiceClass *klass);
static void panel_dbus_service_init (PanelDBusService *service);
static void panel_dbus_service_finalize (GObject *object);
static void panel_dbus_service_finalize (GObject *object);
static gboolean panel_dbus_service_display_preferences_dialog (PanelDBusService *service,
guint active,
GError **error);
static gboolean panel_dbus_service_display_items_dialog (PanelDBusService *service,
guint active,
GError **error);
static gboolean panel_dbus_service_save (PanelDBusService *service,
GError **error);
static gboolean panel_dbus_service_add_new_item (PanelDBusService *service,
const gchar *plugin_name,
gchar **arguments,
GError **error);
static gboolean panel_dbus_service_terminate (PanelDBusService *service,
gboolean restart,
GError **error);
static gboolean panel_dbus_service_plugin_provider_signal (PanelDBusService *service,
gint plugin_id,
gint provider_signal,
GError *error);
static gboolean panel_dbus_service_plugin_panel_property (PanelDBusService *service,
gint plugin_id,
gint property,
GValue *value,
GError *error);
/* include the dbus glue generated by dbus-binding-tool */
#include <panel/panel-dbus-service-infos.h>
@ -84,8 +111,7 @@ G_DEFINE_TYPE (PanelDBusService, panel_dbus_service, G_TYPE_OBJECT);
static void
panel_dbus_service_class_init (PanelDBusServiceClass *klass)
{
extern const DBusGObjectInfo dbus_glib_panel_dbus_service_object_info;
GObjectClass *gobject_class;
GObjectClass *gobject_class;
gobject_class = G_OBJECT_CLASS (klass);
gobject_class->finalize = panel_dbus_service_finalize;
@ -268,7 +294,7 @@ panel_dbus_service_terminate (PanelDBusService *service,
static gboolean
panel_dbus_service_plugin_provider_signal (PanelDBusService *service,
gint plugin_id,
gint signal,
gint provider_signal,
GError *error)
{
PanelModuleFactory *factory;
@ -285,7 +311,7 @@ panel_dbus_service_plugin_provider_signal (PanelDBusService *service,
/* emit the signal for the local plugin provider */
if (G_LIKELY (provider))
xfce_panel_plugin_provider_emit_signal (XFCE_PANEL_PLUGIN_PROVIDER (provider), signal);
xfce_panel_plugin_provider_emit_signal (XFCE_PANEL_PLUGIN_PROVIDER (provider), provider_signal);
/* release the factory */
g_object_unref (G_OBJECT (factory));
@ -347,8 +373,3 @@ panel_dbus_service_plugin_property_changed (gint plugin_id,
/* release */
g_object_unref (G_OBJECT (service));
}
/* include the dbus glue generated by dbus-binding-tool */
#include <panel/panel-dbus-service-infos.h>

2
panel/panel-dbus-service.h

@ -33,6 +33,8 @@ typedef struct _PanelDBusService PanelDBusService;
#define PANEL_IS_DBUS_SERVICE_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE ((klass), PANEL_TYPE_DBUS_SERVICE))
#define PANEL_DBUS_SERVICE_GET_CLASS(obj) (G_TYPE_INSTANCE_GET_CLASS ((obj), PANEL_TYPE_DBUS_SERVICE, PanelDBusServiceClass))
extern gboolean dbus_quit_with_restart;
GType panel_dbus_service_get_type (void) G_GNUC_CONST;
PanelDBusService *panel_dbus_service_get (void);

7
panel/panel-glue.h

@ -26,8 +26,11 @@
#include <libxfce4panel/xfce-panel-plugin-provider.h>
G_BEGIN_DECLS
void panel_glue_set_provider_info (XfcePanelPluginProvider *provider,
PanelWindow *window);
XfceScreenPosition panel_glue_get_screen_position (PanelWindow *window);
void panel_glue_set_provider_info (XfcePanelPluginProvider *provider,
PanelWindow *window);
G_END_DECLS

10
panel/panel-item-dialog.c

@ -44,8 +44,6 @@
static void panel_item_dialog_class_init (PanelItemDialogClass *klass);
static void panel_item_dialog_init (PanelItemDialog *dialog);
static void panel_item_dialog_finalize (GObject *object);
static void panel_item_dialog_response (GtkDialog *dialog, gint response_id);
static void panel_item_dialog_unique_changed (PanelModuleFactory *factory, PanelModule *module, PanelItemDialog *dialog);
@ -53,7 +51,7 @@ static gboolean panel_item_dialog_unique_changed_foreach (GtkTreeModel *model, G
static gboolean panel_item_dialog_separator_func (GtkTreeModel *model, GtkTreeIter *iter, gpointer user_data);
static PanelModule *panel_item_dialog_get_selected_module (GtkTreeView *treeview);
static void panel_item_dialog_drag_begin (GtkWidget *treeview, GdkDragContext *context, PanelItemDialog *dialog);
static void panel_item_dialog_drag_data_get (GtkWidget *treeview, GdkDragContext *context, GtkSelectionData *selection_data, guint info, guint time, PanelItemDialog *dialog);
static void panel_item_dialog_drag_data_get (GtkWidget *treeview, GdkDragContext *context, GtkSelectionData *selection_data, guint info, guint drag_time, PanelItemDialog *dialog);
static void panel_item_dialog_populate_store (PanelItemDialog *dialog);
static gint panel_item_dialog_compare_func (GtkTreeModel *model, GtkTreeIter *a, GtkTreeIter *b, gpointer user_data);
static gboolean panel_item_dialog_visible_func (GtkTreeModel *model, GtkTreeIter *iter, gpointer user_data);
@ -90,7 +88,7 @@ enum
static const GtkTargetEntry drag_targets[] =
{
{ "application/x-xfce-panel-plugin-name", 0, 0 },
{ (gchar *) "application/x-xfce-panel-plugin-name", 0, 0 },
};
@ -456,8 +454,8 @@ static void
panel_item_dialog_drag_data_get (GtkWidget *treeview,
GdkDragContext *context,
GtkSelectionData *selection_data,
guint info,
guint time,
guint drag_info,
guint drag_time,
PanelItemDialog *dialog)
{
PanelModule *module;

14
panel/panel-itembar.c

@ -34,8 +34,6 @@
static void panel_itembar_class_init (PanelItembarClass *klass);
static void panel_itembar_init (PanelItembar *itembar);
static void panel_itembar_set_property (GObject *object,
guint prop_id,
const GValue *value,
@ -59,10 +57,10 @@ static gboolean panel_itembar_drag_motion (GtkWidget *widget,
GdkDragContext *drag_context,
gint drag_x,
gint drag_y,
guint time);
guint drag_time);
static void panel_itembar_drag_leave (GtkWidget *widget,
GdkDragContext *drag_context,
guint time);
guint drag_time);
static void panel_itembar_add (GtkContainer *container,
GtkWidget *child);
static void panel_itembar_remove (GtkContainer *container,
@ -122,8 +120,8 @@ G_DEFINE_TYPE (PanelItembar, panel_itembar, GTK_TYPE_CONTAINER);
/* drop targets */
static const GtkTargetEntry drop_targets[] =
{
{ "application/x-xfce-panel-plugin-name", 0, PANEL_ITEMBAR_TARGET_PLUGIN_NAME },
{ "application/x-xfce-panel-plugin-widget", 0, PANEL_ITEMBAR_TARGET_PLUGIN_WIDGET },
{ (gchar *) "application/x-xfce-panel-plugin-name", 0, PANEL_ITEMBAR_TARGET_PLUGIN_NAME },
{ (gchar *) "application/x-xfce-panel-plugin-widget", 0, PANEL_ITEMBAR_TARGET_PLUGIN_WIDGET },
};
@ -550,7 +548,7 @@ panel_itembar_drag_motion (GtkWidget *widget,
GdkDragContext *drag_context,
gint drag_x,
gint drag_y,
guint time)
guint drag_time)
{
PanelItembar *itembar = PANEL_ITEMBAR (widget);
GdkWindowAttr attributes;
@ -632,7 +630,7 @@ panel_itembar_drag_motion (GtkWidget *widget,
static void
panel_itembar_drag_leave (GtkWidget *widget,
GdkDragContext *drag_context,
guint time)
guint drag_time)
{
PanelItembar *itembar = PANEL_ITEMBAR (widget);

10
panel/panel-module-factory.c

@ -38,8 +38,6 @@
static void panel_module_factory_class_init (PanelModuleFactoryClass *klass);
static void panel_module_factory_init (PanelModuleFactory *plugin_factory);
static void panel_module_factory_finalize (GObject *object);
static void panel_module_factory_load_modules (PanelModuleFactory *factory);
static gboolean panel_module_factory_modules_cleanup (gpointer key,
@ -250,19 +248,19 @@ panel_module_factory_modules_cleanup (gpointer key,
{
PanelModuleFactory *factory = PANEL_MODULE_FACTORY (user_data);
PanelModule *module = PANEL_MODULE (value);
gboolean remove;
gboolean remove_from_table;
panel_return_val_if_fail (PANEL_IS_MODULE (module), TRUE);
panel_return_val_if_fail (PANEL_IS_MODULE_FACTORY (factory), TRUE);
/* get whether the module is valid */
remove = !panel_module_is_valid (module);
remove_from_table = !panel_module_is_valid (module);
/* if we're going to remove this item, check if it's the launcher */
if (remove == TRUE && exo_str_is_equal (LAUNCHER_PLUGIN_NAME, panel_module_get_internal_name (module)))
if (remove_from_table && exo_str_is_equal (LAUNCHER_PLUGIN_NAME, panel_module_get_internal_name (module)))
factory->has_launcher = FALSE;
return remove;
return remove_from_table;
}

2
panel/panel-module.c

@ -36,8 +36,6 @@
static void panel_module_class_init (PanelModuleClass *klass);
static void panel_module_init (PanelModule *plugin);
static void panel_module_dispose (GObject *object);
static void panel_module_finalize (GObject *object);
static gboolean panel_module_load (GTypeModule *type_module);

22
panel/panel-plugin-external.c

@ -46,8 +46,6 @@
static void panel_plugin_external_class_init (PanelPluginExternalClass *klass);
static void panel_plugin_external_init (PanelPluginExternal *external);
static void panel_plugin_external_provider_init (XfcePanelPluginProviderIface *iface);
static void panel_plugin_external_finalize (GObject *object);
static void panel_plugin_external_realize (GtkWidget *widget);
@ -234,17 +232,17 @@ panel_plugin_external_realize (GtkWidget *widget)
argv = g_new (gchar *, argc);
/* setup the basic argv */
argv[0] = LIBEXECDIR "/xfce4-panel-wrapper";
argv[1] = "-n";
argv[0] = (gchar *) LIBEXECDIR "/xfce4-panel-wrapper";
argv[1] = (gchar *) "-n";
argv[2] = (gchar *) panel_module_get_internal_name (external->module);
argv[3] = "-i";
argv[4] = unique_id;
argv[5] = "-d";
argv[3] = (gchar *) "-i";
argv[4] = (gchar *) unique_id;
argv[5] = (gchar *) "-d";
argv[6] = (gchar *) panel_module_get_name (external->module);
argv[7] = "-f";
argv[7] = (gchar *) "-f";
argv[8] = (gchar *) panel_module_get_library_filename (external->module);
argv[9] = "-s";
argv[10] = socket_id;
argv[9] = (gchar *) "-s";
argv[10] = (gchar *) socket_id;
/* append the arguments */
if (G_UNLIKELY (external->arguments != NULL))
@ -424,7 +422,7 @@ panel_plugin_external_plug_added (GtkSocket *socket)
static void
panel_plugin_external_provider_signal (XfcePanelPluginProvider *provider,
XfcePanelPluginProviderSignal signal)
XfcePanelPluginProviderSignal provider_signal)
{
PanelPluginExternal *external = PANEL_PLUGIN_EXTERNAL (provider);
@ -433,7 +431,7 @@ panel_plugin_external_provider_signal (XfcePanelPluginProvider *provider,
/* we handle some signals here, everything else is handled in
* panel-application */
switch (signal)
switch (provider_signal)
{
case PROVIDER_SIGNAL_REMOVE_PLUGIN:
/* we're forced removing the plugin, don't ask for a restart */

3
panel/panel-preferences-dialog.c

@ -36,13 +36,10 @@
#include <panel/panel-preferences-dialog.h>
#include <panel/panel-preferences-dialog-glade.h>
#define BORDER (6)
#define PREFERENCES_HELP_URL "http://www.xfce.org"
static void panel_preferences_dialog_class_init (PanelPreferencesDialogClass *klass);
static void panel_preferences_dialog_init (PanelPreferencesDialog *dialog);
static void panel_preferences_dialog_finalize (GObject *object);
static void panel_preferences_dialog_response (GtkWidget *window, gint response_id, PanelPreferencesDialog *dialog);

4
panel/panel-window.c

@ -48,8 +48,6 @@
static void panel_window_class_init (PanelWindowClass *klass);
static void panel_window_init (PanelWindow *window);
static void panel_window_get_property (GObject *object, guint prop_id, GValue *value, GParamSpec *pspec);
static void panel_window_set_property (GObject *object, guint prop_id, const GValue *value, GParamSpec *pspec);
static void panel_window_finalize (GObject *object);
@ -1992,8 +1990,6 @@ panel_window_set_autohide (PanelWindow *window,
static void
panel_window_menu_quit (gpointer boolean)
{
extern gboolean dbus_quit_with_restart;
/* restart or quit */
dbus_quit_with_restart = !!(GPOINTER_TO_UINT (boolean));

26
plugins/clock/clock-analog.c

@ -45,8 +45,6 @@
/* prototypes */
static void xfce_clock_analog_class_init (XfceClockAnalogClass *klass);
static void xfce_clock_analog_init (XfceClockAnalog *clock);
static void xfce_clock_analog_set_property (GObject *object,
guint prop_id,
const GValue *value,
@ -123,10 +121,10 @@ xfce_clock_analog_class_init (XfceClockAnalogClass *klass)
static void
xfce_clock_analog_init (XfceClockAnalog *clock)
xfce_clock_analog_init (XfceClockAnalog *analog)
{
/* init */
clock->show_seconds = FALSE;
analog->show_seconds = FALSE;
}
@ -137,12 +135,12 @@ xfce_clock_analog_set_property (GObject *object,
const GValue *value,
GParamSpec *pspec)
{
XfceClockAnalog *clock = XFCE_CLOCK_ANALOG (object);
XfceClockAnalog *analog = XFCE_CLOCK_ANALOG (object);
switch (prop_id)
{
case PROP_SHOW_SECONDS:
clock->show_seconds = g_value_get_boolean (value);
analog->show_seconds = g_value_get_boolean (value);
break;
default:
@ -159,12 +157,12 @@ xfce_clock_analog_get_property (GObject *object,
GValue *value,
GParamSpec *pspec)
{
XfceClockAnalog *clock = XFCE_CLOCK_ANALOG (object);
XfceClockAnalog *analog = XFCE_CLOCK_ANALOG (object);
switch (prop_id)
{
case PROP_SHOW_SECONDS:
g_value_set_boolean (value, clock->show_seconds);
g_value_set_boolean (value, analog->show_seconds);
break;
default:
@ -194,13 +192,13 @@ static gboolean
xfce_clock_analog_expose_event (GtkWidget *widget,
GdkEventExpose *event)
{
XfceClockAnalog *clock = XFCE_CLOCK_ANALOG (widget);
XfceClockAnalog *analog = XFCE_CLOCK_ANALOG (widget);
gdouble xc, yc;
gdouble angle, radius;
cairo_t *cr;
struct tm tm;
panel_return_val_if_fail (XFCE_CLOCK_IS_ANALOG (clock), FALSE);
panel_return_val_if_fail (XFCE_CLOCK_IS_ANALOG (analog), FALSE);
/* get center of the widget and the radius */
xc = (widget->allocation.width / 2.0);
@ -230,7 +228,7 @@ xfce_clock_analog_expose_event (GtkWidget *widget,
/* draw the ticks */
xfce_clock_analog_draw_ticks (cr, xc, yc, radius);
if (clock->show_seconds)
if (analog->show_seconds)
{
/* second pointer */
angle = TICKS_TO_RADIANS (tm.tm_sec);
@ -351,9 +349,9 @@ xfce_clock_analog_update (gpointer user_data)
guint
xfce_clock_analog_interval (XfceClockAnalog *clock)
xfce_clock_analog_interval (XfceClockAnalog *analog)
{
panel_return_val_if_fail (XFCE_CLOCK_IS_ANALOG (clock), CLOCK_INTERVAL_SECOND);
panel_return_val_if_fail (XFCE_CLOCK_IS_ANALOG (analog), CLOCK_INTERVAL_SECOND);
return clock->show_seconds ? CLOCK_INTERVAL_SECOND : CLOCK_INTERVAL_MINUTE;
return analog->show_seconds ? CLOCK_INTERVAL_SECOND : CLOCK_INTERVAL_MINUTE;
}

2
plugins/clock/clock-analog.h

@ -38,7 +38,7 @@ GtkWidget *xfce_clock_analog_new (void) G_GNUC_MALLOC;
gboolean xfce_clock_analog_update (gpointer user_data);
guint xfce_clock_analog_interval (XfceClockAnalog *clock);
guint xfce_clock_analog_interval (XfceClockAnalog *analog);
G_END_DECLS

49
plugins/clock/clock-binary.c

@ -40,9 +40,6 @@
/* class functions */
static void xfce_clock_binary_class_init (XfceClockBinaryClass *klass);
static void xfce_clock_binary_init (XfceClockBinary *clock);
static void xfce_clock_binary_set_property (GObject *object,
guint prop_id,
const GValue *value,
@ -118,11 +115,11 @@ xfce_clock_binary_class_init (XfceClockBinaryClass *klass)
static void
xfce_clock_binary_init (XfceClockBinary *clock)
xfce_clock_binary_init (XfceClockBinary *binary)
{
/* init */
clock->show_seconds = FALSE;
clock->true_binary = FALSE;
binary->show_seconds = FALSE;
binary->true_binary = FALSE;
}
@ -133,16 +130,16 @@ xfce_clock_binary_set_property (GObject *object,
const GValue *value,
GParamSpec *pspec)
{
XfceClockBinary *clock = XFCE_CLOCK_BINARY (object);
XfceClockBinary *binary = XFCE_CLOCK_BINARY (object);
switch (prop_id)
{
case PROP_SHOW_SECONDS:
clock->show_seconds = g_value_get_boolean (value);
binary->show_seconds = g_value_get_boolean (value);
break;
case PROP_TRUE_BINARY:
clock->true_binary = g_value_get_boolean (value);
binary->true_binary = g_value_get_boolean (value);
break;
default:
@ -159,16 +156,16 @@ xfce_clock_binary_get_property (GObject *object,
GValue *value,
GParamSpec *pspec)
{
XfceClockBinary *clock = XFCE_CLOCK_BINARY (object);
XfceClockBinary *binary = XFCE_CLOCK_BINARY (object);
switch (prop_id)
{
case PROP_SHOW_SECONDS:
g_value_set_boolean (value, clock->show_seconds);
g_value_set_boolean (value, binary->show_seconds);
break;
case PROP_TRUE_BINARY:
g_value_set_boolean (value, clock->true_binary);
g_value_set_boolean (value, binary->true_binary);
break;
default:
@ -181,20 +178,20 @@ xfce_clock_binary_get_property (GObject *object,
static void
xfce_clock_binary_size_request (GtkWidget *widget,
GtkRequisition *requisition)
GtkRequisition *requisition)
{
gint width, height;
gdouble ratio;
XfceClockBinary *clock = XFCE_CLOCK_BINARY (widget);
XfceClockBinary *binary = XFCE_CLOCK_BINARY (widget);
/* get the current widget size */
gtk_widget_get_size_request (widget, &width, &height);
/* ratio of the clock */
if (clock->true_binary)
ratio = clock->show_seconds ? 2.0 : 3.0;
if (binary->true_binary)
ratio = binary->show_seconds ? 2.0 : 3.0;
else
ratio = clock->show_seconds ? 1.5 : 1.0;
ratio = binary->show_seconds ? 1.5 : 1.0;
/* set requisition based on the plugin orientation */
if (width == -1)
@ -215,7 +212,7 @@ static gboolean
xfce_clock_binary_expose_event (GtkWidget *widget,
GdkEventExpose *event)
{
XfceClockBinary *clock = XFCE_CLOCK_BINARY (widget);
XfceClockBinary *binary = XFCE_CLOCK_BINARY (widget);
gdouble cw, ch, columns;
gint ticks, cells, decimal;
gdouble radius;
@ -227,14 +224,14 @@ xfce_clock_binary_expose_event (GtkWidget *widget,
GdkColor active, inactive;
struct tm tm;
panel_return_val_if_fail (XFCE_CLOCK_IS_BINARY (clock), FALSE);
panel_return_val_if_fail (XFCE_CLOCK_IS_BINARY (binary), FALSE);
/* number of columns and cells */
columns = clock->show_seconds ? 3.0 : 2.0;
cells = clock->true_binary ? 6 : 8;
columns = binary->show_seconds ? 3.0 : 2.0;
cells = binary->true_binary ? 6 : 8;
/* cell width and height */
if (clock->true_binary)
if (binary->true_binary)
{
cw = widget->allocation.width / 6.0;
ch = widget->allocation.height / columns;
@ -278,7 +275,7 @@ xfce_clock_binary_expose_event (GtkWidget *widget,
/* walk the binary columns */
for (j = 0; j < cells; j++)
{
if (clock->true_binary)
if (binary->true_binary)
{
/* skip the columns we don't draw */
if (i == 0 && j == 0)
@ -364,9 +361,9 @@ xfce_clock_binary_update (gpointer user_data)
guint
xfce_clock_binary_interval (XfceClockBinary *clock)
xfce_clock_binary_interval (XfceClockBinary *binary)
{
panel_return_val_if_fail (XFCE_CLOCK_IS_BINARY (clock), CLOCK_INTERVAL_SECOND);
panel_return_val_if_fail (XFCE_CLOCK_IS_BINARY (binary), CLOCK_INTERVAL_SECOND);
return clock->show_seconds ? CLOCK_INTERVAL_SECOND : CLOCK_INTERVAL_MINUTE;
return binary->show_seconds ? CLOCK_INTERVAL_SECOND : CLOCK_INTERVAL_MINUTE;
}

2
plugins/clock/clock-binary.h

@ -38,7 +38,7 @@ GtkWidget *xfce_clock_binary_new (void) G_GNUC_MALLOC;
gboolean xfce_clock_binary_update (gpointer user_data);
guint xfce_clock_binary_interval (XfceClockBinary *clock);
guint xfce_clock_binary_interval (XfceClockBinary *binary);
G_END_DECLS

38
plugins/clock/clock-digital.c

@ -32,8 +32,6 @@
static void xfce_clock_digital_class_init (XfceClockDigitalClass *klass);
static void xfce_clock_digital_init (XfceClockDigital *clock);
static void xfce_clock_digital_finalize (GObject *object);
static void xfce_clock_digital_set_property (GObject *object,
guint prop_id,
@ -92,13 +90,13 @@ xfce_clock_digital_class_init (XfceClockDigitalClass *klass)
static void
xfce_clock_digital_init (XfceClockDigital *clock)
xfce_clock_digital_init (XfceClockDigital *digital)
{
/* init */
clock->format = NULL;
digital->format = NULL;
/* center text */
gtk_label_set_justify (GTK_LABEL (clock), GTK_JUSTIFY_CENTER);
gtk_label_set_justify (GTK_LABEL (digital), GTK_JUSTIFY_CENTER);
}
@ -106,10 +104,10 @@ xfce_clock_digital_init (XfceClockDigital *clock)
static void
xfce_clock_digital_finalize (GObject *object)
{
XfceClockDigital *clock = XFCE_CLOCK_DIGITAL (object);
XfceClockDigital *digital = XFCE_CLOCK_DIGITAL (object);
/* cleanup */
g_free (clock->format);
g_free (digital->format);
(*G_OBJECT_CLASS (xfce_clock_digital_parent_class)->finalize) (object);
}
@ -122,19 +120,19 @@ xfce_clock_digital_set_property (GObject *object,
const GValue *value,
GParamSpec *pspec)
{
XfceClockDigital *clock = XFCE_CLOCK_DIGITAL (object);
XfceClockDigital *digital = XFCE_CLOCK_DIGITAL (object);
switch (prop_id)
{
case PROP_DIGITAL_FORMAT:
/* cleanup */
g_free (clock->format);
g_free (digital->format);
/* set new format */
clock->format = g_value_dup_string (value);
digital->format = g_value_dup_string (value);
/* update the widget */
xfce_clock_digital_update (clock);
xfce_clock_digital_update (digital);
break;
default:
@ -151,12 +149,12 @@ xfce_clock_digital_get_property (GObject *object,
GValue *value,
GParamSpec *pspec)
{
XfceClockDigital *clock = XFCE_CLOCK_DIGITAL (object);
XfceClockDigital *digital = XFCE_CLOCK_DIGITAL (object);
switch (prop_id)
{
case PROP_DIGITAL_FORMAT:
g_value_set_string (value, clock->format);
g_value_set_string (value, digital->format);
break;
default:
@ -178,21 +176,21 @@ xfce_clock_digital_new (void)
gboolean
xfce_clock_digital_update (gpointer user_data)
{
XfceClockDigital *clock = XFCE_CLOCK_DIGITAL (user_data);
XfceClockDigital *digital = XFCE_CLOCK_DIGITAL (user_data);
gchar *string;
struct tm tm;
panel_return_val_if_fail (XFCE_CLOCK_IS_DIGITAL (user_data), FALSE);
panel_return_val_if_fail (XFCE_CLOCK_IS_DIGITAL (digital), FALSE);
/* get the local time */
clock_plugin_get_localtime (&tm);
/* get the string */
string = clock_plugin_strdup_strftime (clock->format ? clock->format :
string = clock_plugin_strdup_strftime (digital->format ? digital->format :
DEFAULT_DIGITAL_FORMAT, &tm);
/* set the new label */
gtk_label_set_markup (GTK_LABEL (clock), string);
gtk_label_set_markup (GTK_LABEL (digital), string);
/* cleanup */
g_free (string);
@ -203,10 +201,10 @@ xfce_clock_digital_update (gpointer user_data)
guint
xfce_clock_digital_interval (XfceClockDigital *clock)
xfce_clock_digital_interval (XfceClockDigital *digital)
{
panel_return_val_if_fail (XFCE_CLOCK_IS_DIGITAL (clock), CLOCK_INTERVAL_SECOND);
panel_return_val_if_fail (XFCE_CLOCK_IS_DIGITAL (digital), CLOCK_INTERVAL_SECOND);
return clock_plugin_interval_from_format (clock->format ? clock->format :
return clock_plugin_interval_from_format (digital->format ? digital->format :
DEFAULT_DIGITAL_FORMAT);
}

2
plugins/clock/clock-digital.h

@ -38,7 +38,7 @@ GtkWidget *xfce_clock_digital_new (void) G_GNUC_MALLOC;
gboolean xfce_clock_digital_update (gpointer user_data);
guint xfce_clock_digital_interval (XfceClockDigital *clock);
guint xfce_clock_digital_interval (XfceClockDigital *digital);
G_END_DECLS

35
plugins/clock/clock-fuzzy.c

@ -32,8 +32,6 @@
static void xfce_clock_fuzzy_class_init (XfceClockFuzzyClass *klass);
static void xfce_clock_fuzzy_init (XfceClockFuzzy *clock);
static void xfce_clock_fuzzy_set_property (GObject *object,
guint prop_id,
const GValue *value,
@ -129,13 +127,13 @@ xfce_clock_fuzzy_class_init (XfceClockFuzzyClass *klass)
static void
xfce_clock_fuzzy_init (XfceClockFuzzy *clock)
xfce_clock_fuzzy_init (XfceClockFuzzy *fuzzy)
{
/* init */
clock->fuzziness = FUZZINESS_DEFAULT;
fuzzy->fuzziness = FUZZINESS_DEFAULT;
/* center text */
gtk_label_set_justify (GTK_LABEL (clock), GTK_JUSTIFY_CENTER);
gtk_label_set_justify (GTK_LABEL (fuzzy), GTK_JUSTIFY_CENTER);
}
@ -146,13 +144,12 @@ xfce_clock_fuzzy_set_property (GObject *object,
const GValue *value,
GParamSpec *pspec)
{
XfceClockFuzzy *clock = XFCE_CLOCK_FUZZY (object);
XfceClockFuzzy *fuzzy = XFCE_CLOCK_FUZZY (object);
switch (prop_id)
{
case PROP_FUZZINESS:
clock->fuzziness = CLAMP (g_value_get_uint (value),
FUZZINESS_MIN, FUZZINESS_MAX);
fuzzy->fuzziness = MIN (g_value_get_uint (value), FUZZINESS_MAX);
break;
default:
@ -169,12 +166,12 @@ xfce_clock_fuzzy_get_property (GObject *object,
GValue *value,
GParamSpec *pspec)
{
XfceClockFuzzy *clock = XFCE_CLOCK_FUZZY (object);
XfceClockFuzzy *fuzzy = XFCE_CLOCK_FUZZY (object);
switch (prop_id)
{
case PROP_FUZZINESS:
g_value_set_uint (value, clock->fuzziness);
g_value_set_uint (value, fuzzy->fuzziness);
break;
default:
@ -196,26 +193,26 @@ xfce_clock_fuzzy_new (void)
gboolean
xfce_clock_fuzzy_update (gpointer user_data)
{
XfceClockFuzzy *clock = XFCE_CLOCK_FUZZY (user_data);
XfceClockFuzzy *fuzzy = XFCE_CLOCK_FUZZY (user_data);
struct tm tm;
gint hour_sector;
gint minutes, hour;
gchar *string;
panel_return_val_if_fail (XFCE_CLOCK_IS_FUZZY (clock), FALSE);
panel_return_val_if_fail (XFCE_CLOCK_IS_FUZZY (fuzzy), FALSE);
/* get the local time */
clock_plugin_get_localtime (&tm);
if (clock->fuzziness == FUZZINESS_5_MINS
|| clock->fuzziness == FUZZINESS_15_MINS)
if (fuzzy->fuzziness == FUZZINESS_5_MINS
|| fuzzy->fuzziness == FUZZINESS_15_MINS)
{
/* set the time */
minutes = tm.tm_min;
hour = tm.tm_hour > 12 ? tm.tm_hour - 12 : tm.tm_hour;
/* get the hour sector */
if (clock->fuzziness == FUZZINESS_5_MINS)
if (fuzzy->fuzziness == FUZZINESS_5_MINS)
hour_sector = minutes >= 3 ? (minutes - 3) / 5 : 11;
else
hour_sector = minutes > 7 ? ((minutes - 7) / 15 + 1) * 3 - 1 : 11;
@ -226,12 +223,12 @@ xfce_clock_fuzzy_update (gpointer user_data)
/* set the time string */
string = g_strdup_printf (_(i18n_hour_sectors[hour_sector]), _(i18n_hour_names[hour]));
gtk_label_set_text (GTK_LABEL (clock), string);
gtk_label_set_text (GTK_LABEL (fuzzy), string);
g_free (string);
}
else /* FUZZINESS_DAY */
{
gtk_label_set_text (GTK_LABEL (clock), _(i18n_day_sectors[tm.tm_hour / 3]));
gtk_label_set_text (GTK_LABEL (fuzzy), _(i18n_day_sectors[tm.tm_hour / 3]));
}
return TRUE;
@ -240,9 +237,9 @@ xfce_clock_fuzzy_update (gpointer user_data)
guint
xfce_clock_fuzzy_interval (XfceClockFuzzy *clock)
xfce_clock_fuzzy_interval (XfceClockFuzzy *fuzzy)
{
panel_return_val_if_fail (XFCE_CLOCK_IS_FUZZY (clock), CLOCK_INTERVAL_MINUTE);
panel_return_val_if_fail (XFCE_CLOCK_IS_FUZZY (fuzzy), CLOCK_INTERVAL_MINUTE);
return CLOCK_INTERVAL_MINUTE;
}

2
plugins/clock/clock-fuzzy.h

@ -38,7 +38,7 @@ GtkWidget *xfce_clock_fuzzy_new (void) G_GNUC_MALLOC;
gboolean xfce_clock_fuzzy_update (gpointer user_data);
guint xfce_clock_fuzzy_interval (XfceClockFuzzy *clock);
guint xfce_clock_fuzzy_interval (XfceClockFuzzy *fuzzy);
G_END_DECLS

62
plugins/clock/clock-lcd.c

@ -37,8 +37,6 @@
/* prototypes */
static void xfce_clock_lcd_class_init (XfceClockLcdClass *klass);
static void xfce_clock_lcd_init (XfceClockLcd *clock);
static void xfce_clock_lcd_set_property (GObject *object,
guint prop_id,
const GValue *value,
@ -51,7 +49,7 @@ static void xfce_clock_lcd_size_request (GtkWidget *widget,
GtkRequisition *requisition);
static gboolean xfce_clock_lcd_expose_event (GtkWidget *widget,
GdkEventExpose *event);
static gdouble xfce_clock_lcd_get_ratio (XfceClockLcd *clock);
static gdouble xfce_clock_lcd_get_ratio (XfceClockLcd *lcd);
static gdouble xfce_clock_lcd_draw_dots (cairo_t *cr,
gdouble size,
gdouble offset_x,
@ -159,13 +157,13 @@ xfce_clock_lcd_class_init (XfceClockLcdClass *klass)
static void
xfce_clock_lcd_init (XfceClockLcd *clock)
xfce_clock_lcd_init (XfceClockLcd *lcd)
{
/* init */
clock->show_seconds = FALSE;
clock->show_meridiem = FALSE;
clock->show_military = TRUE;
clock->flash_separators = FALSE;
lcd->show_seconds = FALSE;
lcd->show_meridiem = FALSE;
lcd->show_military = TRUE;
lcd->flash_separators = FALSE;
}
@ -176,24 +174,24 @@ xfce_clock_lcd_set_property (GObject *object,
const GValue *value,
GParamSpec *pspec)
{
XfceClockLcd *clock = XFCE_CLOCK_LCD (object);
XfceClockLcd *lcd = XFCE_CLOCK_LCD (object);
switch (prop_id)
{
case PROP_SHOW_SECONDS:
clock->show_seconds = g_value_get_boolean (value);
lcd->show_seconds = g_value_get_boolean (value);
break;
case PROP_SHOW_MILITARY:
clock->show_military = g_value_get_boolean (value);
lcd->show_military = g_value_get_boolean (value);
break;
case PROP_SHOW_MERIDIEM:
clock->show_meridiem = g_value_get_boolean (value);
lcd->show_meridiem = g_value_get_boolean (value);
break;
case PROP_FLASH_SEPARATORS:
clock->flash_separators = g_value_get_boolean (value);
lcd->flash_separators = g_value_get_boolean (value);
break;
default:
@ -210,24 +208,24 @@ xfce_clock_lcd_get_property (GObject *object,
GValue *value,
GParamSpec *pspec)
{
XfceClockLcd *clock = XFCE_CLOCK_LCD (object);
XfceClockLcd *lcd = XFCE_CLOCK_LCD (object);
switch (prop_id)
{
case PROP_SHOW_SECONDS:
g_value_set_boolean (value, clock->show_seconds);
g_value_set_boolean (value, lcd->show_seconds);
break;
case PROP_SHOW_MILITARY:
g_value_set_boolean (value, clock->show_military);
g_value_set_boolean (value, lcd->show_military);
break;
case PROP_SHOW_MERIDIEM:
g_value_set_boolean (value, clock->show_meridiem);
g_value_set_boolean (value, lcd->show_meridiem);
break;
case PROP_FLASH_SEPARATORS:
g_value_set_boolean (value, clock->flash_separators);
g_value_set_boolean (value, lcd->flash_separators);
break;
default:
@ -273,7 +271,7 @@ static gboolean
xfce_clock_lcd_expose_event (GtkWidget *widget,
GdkEventExpose *event)
{
XfceClockLcd *clock = XFCE_CLOCK_LCD</