From: joncruz Date: Fri, 26 Oct 2007 05:43:30 +0000 (+0000) Subject: Warning cleanup X-Git-Url: https://git.tokkee.org/?a=commitdiff_plain;h=d4d3b624d2d4a01877a37cbb3ec36279d6396e91;p=inkscape.git Warning cleanup --- diff --git a/src/desktop.cpp b/src/desktop.cpp index 9a6b937c5..a97e1f3fc 100644 --- a/src/desktop.cpp +++ b/src/desktop.cpp @@ -1212,7 +1212,7 @@ SPDesktop::onPositionSet (double x, double y) } void -SPDesktop::onResized (double x, double y) +SPDesktop::onResized (double /*x*/, double /*y*/) { // Nothing called here } @@ -1338,7 +1338,7 @@ SPDesktop::_onDeactivate (SPDesktop* dt) void SPDesktop::_onSelectionModified -(Inkscape::Selection *selection, guint flags, SPDesktop *dt) +(Inkscape::Selection */*selection*/, guint /*flags*/, SPDesktop *dt) { if (!dt->_widget) return; dt->_widget->updateScrollbars (expansion(dt->_d2w)); @@ -1368,7 +1368,7 @@ _onSelectionChanged * \todo fixme */ static gint -_arena_handler (SPCanvasArena *arena, NRArenaItem *ai, GdkEvent *event, SPDesktop *desktop) +_arena_handler (SPCanvasArena */*arena*/, NRArenaItem *ai, GdkEvent *event, SPDesktop *desktop) { if (ai) { SPItem *spi = (SPItem*)NR_ARENA_ITEM_GET_DATA (ai); @@ -1393,7 +1393,7 @@ _layer_deactivated(SPObject *layer, SPDesktop *desktop) { /// Callback static void -_layer_hierarchy_changed(SPObject *top, SPObject *bottom, +_layer_hierarchy_changed(SPObject */*top*/, SPObject *bottom, SPDesktop *desktop) { desktop->_layer_changed_signal.emit (bottom); diff --git a/src/display/canvas-arena.cpp b/src/display/canvas-arena.cpp index bb636a91a..bb710a021 100644 --- a/src/display/canvas-arena.cpp +++ b/src/display/canvas-arena.cpp @@ -450,13 +450,13 @@ sp_canvas_arena_send_event (SPCanvasArena *arena, GdkEvent *event) } static void -sp_canvas_arena_request_update (NRArena *arena, NRArenaItem *item, void *data) +sp_canvas_arena_request_update (NRArena */*arena*/, NRArenaItem */*item*/, void *data) { sp_canvas_item_request_update (SP_CANVAS_ITEM (data)); } static void -sp_canvas_arena_request_render (NRArena *arena, NRRectL *area, void *data) +sp_canvas_arena_request_render (NRArena */*arena*/, NRRectL *area, void *data) { sp_canvas_request_redraw (SP_CANVAS_ITEM (data)->canvas, area->x0, area->y0, area->x1, area->y1); } diff --git a/src/display/canvas-axonomgrid.cpp b/src/display/canvas-axonomgrid.cpp index beb5c088a..c00e2ea8f 100644 --- a/src/display/canvas-axonomgrid.cpp +++ b/src/display/canvas-axonomgrid.cpp @@ -396,7 +396,7 @@ CanvasAxonomGrid::readRepr() * Called when XML node attribute changed; updates dialog widgets if change was not done by widgets themselves. */ void -CanvasAxonomGrid::onReprAttrChanged(Inkscape::XML::Node *repr, gchar const *key, gchar const *oldval, gchar const *newval, bool is_interactive) +CanvasAxonomGrid::onReprAttrChanged(Inkscape::XML::Node */*repr*/, gchar const */*key*/, gchar const */*oldval*/, gchar const */*newval*/, bool /*is_interactive*/) { readRepr(); @@ -453,7 +453,7 @@ CanvasAxonomGrid::updateWidgets() void -CanvasAxonomGrid::Update (NR::Matrix const &affine, unsigned int flags) +CanvasAxonomGrid::Update (NR::Matrix const &affine, unsigned int /*flags*/) { ow = origin * affine; sw = NR::Point(fabs(affine[0]),fabs(affine[3])); diff --git a/src/display/canvas-grid.cpp b/src/display/canvas-grid.cpp index 846d3699a..e9eabad10 100644 --- a/src/display/canvas-grid.cpp +++ b/src/display/canvas-grid.cpp @@ -536,7 +536,6 @@ static void validateInt(gint oldVal, void CanvasXYGrid::readRepr() { - char buff[100]; gchar const *value; if ( (value = repr->attribute("originx")) ) { sp_nv_read_length(value, SP_UNIT_ABSOLUTE | SP_UNIT_DEVICE, &origin[NR::X], &gridunit); @@ -599,7 +598,7 @@ CanvasXYGrid::readRepr() * Called when XML node attribute changed; updates dialog widgets if change was not done by widgets themselves. */ void -CanvasXYGrid::onReprAttrChanged(Inkscape::XML::Node *repr, gchar const *key, gchar const *oldval, gchar const *newval, bool is_interactive) +CanvasXYGrid::onReprAttrChanged(Inkscape::XML::Node */*repr*/, gchar const */*key*/, gchar const */*oldval*/, gchar const */*newval*/, bool /*is_interactive*/) { readRepr(); @@ -655,7 +654,7 @@ CanvasXYGrid::updateWidgets() void -CanvasXYGrid::Update (NR::Matrix const &affine, unsigned int flags) +CanvasXYGrid::Update (NR::Matrix const &affine, unsigned int /*flags*/) { ow = origin * affine; sw = spacing * affine; diff --git a/src/display/canvas-grid.h b/src/display/canvas-grid.h index f3ffd7137..40e37c44f 100644 --- a/src/display/canvas-grid.h +++ b/src/display/canvas-grid.h @@ -69,43 +69,43 @@ class CanvasGrid { public: CanvasGrid(SPNamedView * nv, Inkscape::XML::Node * in_repr, SPDocument *in_doc); virtual ~CanvasGrid(); - + static const char * getName(GridType type); static const char * getSVGName(GridType type); static GridType getGridTypeFromSVGName(const char * typestr); static GridType getGridTypeFromName(const char * typestr); - + static CanvasGrid* NewGrid(SPNamedView * nv, Inkscape::XML::Node * repr, SPDocument *doc, GridType gridtype); static void writeNewGridToRepr(Inkscape::XML::Node * repr, SPDocument * doc, GridType gridtype); GridCanvasItem * createCanvasItem(SPDesktop * desktop); - + virtual void Update (NR::Matrix const &affine, unsigned int flags) = 0; virtual void Render (SPCanvasBuf *buf) = 0; - + virtual void readRepr() {}; - virtual void onReprAttrChanged (Inkscape::XML::Node * repr, const gchar *key, const gchar *oldval, const gchar *newval, bool is_interactive) {}; - + virtual void onReprAttrChanged (Inkscape::XML::Node * /*repr*/, const gchar */*key*/, const gchar */*oldval*/, const gchar */*newval*/, bool /*is_interactive*/) {}; + virtual Gtk::Widget & getWidget() = 0; Inkscape::XML::Node * repr; SPDocument *doc; - + Inkscape::Snapper* snapper; static void on_repr_attr_changed (Inkscape::XML::Node * repr, const gchar *key, const gchar *oldval, const gchar *newval, bool is_interactive, void * data); - + protected: GSList * canvasitems; // list of created canvasitems SPNamedView * namedview; - + Gtk::VBox vbox; private: CanvasGrid(const CanvasGrid&); CanvasGrid& operator=(const CanvasGrid&); - + }; @@ -116,10 +116,10 @@ public: void Update (NR::Matrix const &affine, unsigned int flags); void Render (SPCanvasBuf *buf); - + void readRepr(); void onReprAttrChanged (Inkscape::XML::Node * repr, const gchar *key, const gchar *oldval, const gchar *newval, bool is_interactive); - + Gtk::Widget & getWidget(); NR::Point origin; @@ -137,19 +137,19 @@ public: private: CanvasXYGrid(const CanvasXYGrid&); CanvasXYGrid& operator=(const CanvasXYGrid&); - + void updateWidgets(); Gtk::Table table; - + Inkscape::UI::Widget::RegisteredUnitMenu _rumg, _rums; Inkscape::UI::Widget::RegisteredScalarUnit _rsu_ox, _rsu_oy, _rsu_sx, _rsu_sy; Inkscape::UI::Widget::RegisteredColorPicker _rcp_gcol, _rcp_gmcol; Inkscape::UI::Widget::RegisteredSuffixedInteger _rsi; Inkscape::UI::Widget::RegisteredCheckButton _rcb_dotted; - - Inkscape::UI::Widget::Registry _wr; - + + Inkscape::UI::Widget::Registry _wr; + bool render_dotted; }; @@ -160,11 +160,11 @@ class CanvasXYGridSnapper : public LineSnapper public: CanvasXYGridSnapper(CanvasXYGrid *grid, SPNamedView const *nv, NR::Coord const d); -private: +private: LineList _getSnapLines(NR::Point const &p) const; - + CanvasXYGrid *grid; -}; +}; }; /* namespace Inkscape */ diff --git a/src/document.cpp b/src/document.cpp index cfbcf95fe..0207fe597 100644 --- a/src/document.cpp +++ b/src/document.cpp @@ -299,7 +299,7 @@ void SPDocument::collectOrphans() { } } -void SPDocument::reset_key (void *dummy) +void SPDocument::reset_key (void */*dummy*/) { actionkey = NULL; } @@ -1208,7 +1208,7 @@ sigc::connection sp_document_resources_changed_connect(SPDocument *document, /* Helpers */ gboolean -sp_document_resource_list_free(gpointer key, gpointer value, gpointer data) +sp_document_resource_list_free(gpointer /*key*/, gpointer value, gpointer /*data*/) { g_slist_free((GSList *) value); return TRUE; diff --git a/src/inkscape.cpp b/src/inkscape.cpp index 7e46efce6..8b84416aa 100644 --- a/src/inkscape.cpp +++ b/src/inkscape.cpp @@ -368,14 +368,14 @@ void inkscape_mapalt(guint maskvalue) } static void -inkscape_activate_desktop_private (Inkscape::Application *inkscape, SPDesktop *desktop) +inkscape_activate_desktop_private (Inkscape::Application */*inkscape*/, SPDesktop *desktop) { desktop->set_active (true); } static void -inkscape_deactivate_desktop_private (Inkscape::Application *inkscape, SPDesktop *desktop) +inkscape_deactivate_desktop_private (Inkscape::Application */*inkscape*/, SPDesktop *desktop) { desktop->set_active (false); } @@ -387,7 +387,7 @@ inkscape_deactivate_desktop_private (Inkscape::Application *inkscape, SPDesktop static void -inkscape_crash_handler (int signum) +inkscape_crash_handler (int /*signum*/) { using Inkscape::Debug::SimpleEvent; using Inkscape::Debug::EventTracker; @@ -1239,7 +1239,7 @@ inkscape_active_event_context (void) #####################*/ static bool -inkscape_init_config (Inkscape::XML::Document *doc, const gchar *config_name, const gchar *skeleton, +inkscape_init_config (Inkscape::XML::Document */*doc*/, const gchar *config_name, const gchar *skeleton, unsigned int skel_size, const gchar *e_mkdir, const gchar *e_notdir, @@ -1366,7 +1366,7 @@ inkscape_refresh_display (Inkscape::Application *inkscape) * saves the preferences if appropriate, and quits. */ void -inkscape_exit (Inkscape::Application *inkscape) +inkscape_exit (Inkscape::Application */*inkscape*/) { g_assert (INKSCAPE); diff --git a/src/knot.cpp b/src/knot.cpp index 87b5c2bb9..cbb923d41 100644 --- a/src/knot.cpp +++ b/src/knot.cpp @@ -282,7 +282,7 @@ void sp_knot_start_dragging(SPKnot *knot, NR::Point p, gint x, gint y, guint32 e /** * Called to handle events on knots. */ -static int sp_knot_handler(SPCanvasItem *item, GdkEvent *event, SPKnot *knot) +static int sp_knot_handler(SPCanvasItem */*item*/, GdkEvent *event, SPKnot *knot) { g_assert(knot != NULL); g_assert(SP_IS_KNOT(knot)); diff --git a/src/selection.cpp b/src/selection.cpp index af5db825c..e4c628d9e 100644 --- a/src/selection.cpp +++ b/src/selection.cpp @@ -58,7 +58,7 @@ Selection::~Selection() { /* Handler for selected objects "modified" signal */ -void Selection::_schedule_modified(SPObject *obj, guint flags) { +void Selection::_schedule_modified(SPObject */*obj*/, guint flags) { if (!this->_idle) { /* Request handling to be run in _idle loop */ this->_idle = g_idle_add_full(SP_SELECTION_UPDATE_PRIORITY, GSourceFunc(&Selection::_emit_modified), this, NULL); diff --git a/src/sp-object.cpp b/src/sp-object.cpp index f76e70a51..ff4769f64 100644 --- a/src/sp-object.cpp +++ b/src/sp-object.cpp @@ -304,7 +304,7 @@ sp_object_unref(SPObject *object, SPObject *owner) * \pre object points to real object */ SPObject * -sp_object_href(SPObject *object, gpointer owner) +sp_object_href(SPObject *object, gpointer /*owner*/) { g_return_val_if_fail(object != NULL, NULL); g_return_val_if_fail(SP_IS_OBJECT(object), NULL); @@ -325,7 +325,7 @@ sp_object_href(SPObject *object, gpointer owner) * \pre object points to real object and hrefcount>0 */ SPObject * -sp_object_hunref(SPObject *object, gpointer owner) +sp_object_hunref(SPObject *object, gpointer /*owner*/) { g_return_val_if_fail(object != NULL, NULL); g_return_val_if_fail(SP_IS_OBJECT(object), NULL); @@ -753,7 +753,7 @@ sp_object_remove_child(SPObject *object, Inkscape::XML::Node *child) * Invoked whenever the given mutation event happens in the XML tree. * \param old_ref Ignored */ -static void sp_object_order_changed(SPObject *object, Inkscape::XML::Node *child, Inkscape::XML::Node *old_ref, +static void sp_object_order_changed(SPObject *object, Inkscape::XML::Node *child, Inkscape::XML::Node */*old_ref*/, Inkscape::XML::Node *new_ref) { SPObject *ochild = sp_object_get_child_by_repr(object, child); @@ -900,7 +900,7 @@ void SPObject::releaseReferences() { * Callback for child_added node event. */ static void -sp_object_repr_child_added(Inkscape::XML::Node *repr, Inkscape::XML::Node *child, Inkscape::XML::Node *ref, gpointer data) +sp_object_repr_child_added(Inkscape::XML::Node */*repr*/, Inkscape::XML::Node *child, Inkscape::XML::Node *ref, gpointer data) { SPObject *object = SP_OBJECT(data); @@ -912,7 +912,7 @@ sp_object_repr_child_added(Inkscape::XML::Node *repr, Inkscape::XML::Node *child * Callback for remove_child node event. */ static void -sp_object_repr_child_removed(Inkscape::XML::Node *repr, Inkscape::XML::Node *child, Inkscape::XML::Node *ref, gpointer data) +sp_object_repr_child_removed(Inkscape::XML::Node */*repr*/, Inkscape::XML::Node *child, Inkscape::XML::Node */*ref*/, gpointer data) { SPObject *object = SP_OBJECT(data); @@ -927,7 +927,7 @@ sp_object_repr_child_removed(Inkscape::XML::Node *repr, Inkscape::XML::Node *chi * \todo fixme: */ static void -sp_object_repr_order_changed(Inkscape::XML::Node *repr, Inkscape::XML::Node *child, Inkscape::XML::Node *old, Inkscape::XML::Node *newer, gpointer data) +sp_object_repr_order_changed(Inkscape::XML::Node */*repr*/, Inkscape::XML::Node *child, Inkscape::XML::Node *old, Inkscape::XML::Node *newer, gpointer data) { SPObject *object = SP_OBJECT(data); @@ -1064,7 +1064,7 @@ sp_object_read_attr(SPObject *object, gchar const *key) * Callback for attr_changed node event. */ static void -sp_object_repr_attr_changed(Inkscape::XML::Node *repr, gchar const *key, gchar const *oldval, gchar const *newval, bool is_interactive, gpointer data) +sp_object_repr_attr_changed(Inkscape::XML::Node *repr, gchar const *key, gchar const */*oldval*/, gchar const */*newval*/, bool is_interactive, gpointer data) { SPObject *object = SP_OBJECT(data); @@ -1081,7 +1081,7 @@ sp_object_repr_attr_changed(Inkscape::XML::Node *repr, gchar const *key, gchar c * Callback for content_changed node event. */ static void -sp_object_repr_content_changed(Inkscape::XML::Node *repr, gchar const *oldcontent, gchar const *newcontent, gpointer data) +sp_object_repr_content_changed(Inkscape::XML::Node */*repr*/, gchar const */*oldcontent*/, gchar const */*newcontent*/, gpointer data) { SPObject *object = SP_OBJECT(data); @@ -1367,25 +1367,25 @@ SPObject::emitModified(unsigned int flags) */ gchar const * -sp_object_title_get(SPObject *object) +sp_object_title_get(SPObject */*object*/) { return NULL; } gchar const * -sp_object_description_get(SPObject *object) +sp_object_description_get(SPObject */*object*/) { return NULL; } unsigned int -sp_object_title_set(SPObject *object, gchar const *title) +sp_object_title_set(SPObject */*object*/, gchar const */*title*/) { return FALSE; } unsigned int -sp_object_description_set(SPObject *object, gchar const *desc) +sp_object_description_set(SPObject */*object*/, gchar const */*desc*/) { return FALSE; }