summaryrefslogtreecommitdiffstats
path: root/src/sp-fespotlight.cpp
diff options
context:
space:
mode:
authorJon A. Cruz <jon@joncruz.org>2007-11-04 07:22:23 +0000
committerjoncruz <joncruz@users.sourceforge.net>2007-11-04 07:22:23 +0000
commit220136e32a951dffe05ab4c3a117d67f4540680c (patch)
tree00738e1584136c324f4424957f264f10840fbd40 /src/sp-fespotlight.cpp
parentAdd virtual to a lot of the destructors. Note: perhaps it will have to be rev... (diff)
downloadinkscape-220136e32a951dffe05ab4c3a117d67f4540680c.tar.gz
inkscape-220136e32a951dffe05ab4c3a117d67f4540680c.zip
Warning cleanup
(bzr r4025)
Diffstat (limited to 'src/sp-fespotlight.cpp')
-rw-r--r--src/sp-fespotlight.cpp29
1 files changed, 15 insertions, 14 deletions
diff --git a/src/sp-fespotlight.cpp b/src/sp-fespotlight.cpp
index 2730b0d8f..e45b123ed 100644
--- a/src/sp-fespotlight.cpp
+++ b/src/sp-fespotlight.cpp
@@ -90,7 +90,7 @@ sp_fespotlight_init(SPFeSpotLight *fespotlight)
fespotlight->pointsAtZ = 0;
fespotlight->specularExponent = 1;
fespotlight->limitingConeAngle = 90;
-
+
fespotlight->x_set = FALSE;
fespotlight->y_set = FALSE;
fespotlight->z_set = FALSE;
@@ -151,7 +151,7 @@ sp_fespotlight_set(SPObject *object, unsigned int key, gchar const *value)
{
SPFeSpotLight *fespotlight = SP_FESPOTLIGHT(object);
gchar *end_ptr;
-
+
switch (key) {
case SP_ATTR_X:
end_ptr = NULL;
@@ -163,7 +163,7 @@ sp_fespotlight_set(SPObject *object, unsigned int key, gchar const *value)
if(!value || !end_ptr) {
fespotlight->x = 0;
fespotlight->x_set = FALSE;
- }
+ }
if (object->parent &&
(SP_IS_FEDIFFUSELIGHTING(object->parent) ||
SP_IS_FESPECULARLIGHTING(object->parent))) {
@@ -180,7 +180,7 @@ sp_fespotlight_set(SPObject *object, unsigned int key, gchar const *value)
if(!value || !end_ptr) {
fespotlight->y = 0;
fespotlight->y_set = FALSE;
- }
+ }
if (object->parent &&
(SP_IS_FEDIFFUSELIGHTING(object->parent) ||
SP_IS_FESPECULARLIGHTING(object->parent))) {
@@ -197,7 +197,7 @@ sp_fespotlight_set(SPObject *object, unsigned int key, gchar const *value)
if(!value || !end_ptr) {
fespotlight->z = 0;
fespotlight->z_set = FALSE;
- }
+ }
if (object->parent &&
(SP_IS_FEDIFFUSELIGHTING(object->parent) ||
SP_IS_FESPECULARLIGHTING(object->parent))) {
@@ -214,7 +214,7 @@ sp_fespotlight_set(SPObject *object, unsigned int key, gchar const *value)
if(!value || !end_ptr) {
fespotlight->pointsAtX = 0;
fespotlight->pointsAtX_set = FALSE;
- }
+ }
if (object->parent &&
(SP_IS_FEDIFFUSELIGHTING(object->parent) ||
SP_IS_FESPECULARLIGHTING(object->parent))) {
@@ -231,7 +231,7 @@ sp_fespotlight_set(SPObject *object, unsigned int key, gchar const *value)
if(!value || !end_ptr) {
fespotlight->pointsAtY = 0;
fespotlight->pointsAtY_set = FALSE;
- }
+ }
if (object->parent &&
(SP_IS_FEDIFFUSELIGHTING(object->parent) ||
SP_IS_FESPECULARLIGHTING(object->parent))) {
@@ -248,7 +248,7 @@ sp_fespotlight_set(SPObject *object, unsigned int key, gchar const *value)
if(!value || !end_ptr) {
fespotlight->pointsAtZ = 0;
fespotlight->pointsAtZ_set = FALSE;
- }
+ }
if (object->parent &&
(SP_IS_FEDIFFUSELIGHTING(object->parent) ||
SP_IS_FESPECULARLIGHTING(object->parent))) {
@@ -265,7 +265,7 @@ sp_fespotlight_set(SPObject *object, unsigned int key, gchar const *value)
if(!value || !end_ptr) {
fespotlight->specularExponent = 1;
fespotlight->specularExponent_set = FALSE;
- }
+ }
if (object->parent &&
(SP_IS_FEDIFFUSELIGHTING(object->parent) ||
SP_IS_FESPECULARLIGHTING(object->parent))) {
@@ -282,7 +282,7 @@ sp_fespotlight_set(SPObject *object, unsigned int key, gchar const *value)
if(!value || !end_ptr) {
fespotlight->limitingConeAngle = 90;
fespotlight->limitingConeAngle_set = FALSE;
- }
+ }
if (object->parent &&
(SP_IS_FEDIFFUSELIGHTING(object->parent) ||
SP_IS_FESPECULARLIGHTING(object->parent))) {
@@ -290,7 +290,7 @@ sp_fespotlight_set(SPObject *object, unsigned int key, gchar const *value)
}
break;
default:
- // See if any parents need this value.
+ // See if any parents need this value.
if (((SPObjectClass *) feSpotLight_parent_class)->set) {
((SPObjectClass *) feSpotLight_parent_class)->set(object, key, value);
}
@@ -305,6 +305,7 @@ static void
sp_fespotlight_update(SPObject *object, SPCtx *ctx, guint flags)
{
SPFeSpotLight *feSpotLight = SP_FESPOTLIGHT(object);
+ (void)feSpotLight;
if (flags & SP_OBJECT_MODIFIED_FLAG) {
/* do something to trigger redisplay, updates? */
@@ -317,7 +318,7 @@ sp_fespotlight_update(SPObject *object, SPCtx *ctx, guint flags)
sp_object_read_attr(object, "specularExponent");
sp_object_read_attr(object, "limitingConeAngle");
}
-
+
if (((SPObjectClass *) feSpotLight_parent_class)->update) {
((SPObjectClass *) feSpotLight_parent_class)->update(object, ctx, flags);
}
@@ -334,7 +335,7 @@ sp_fespotlight_write(SPObject *object, Inkscape::XML::Node *repr, guint flags)
if (!repr) {
repr = SP_OBJECT_REPR(object)->duplicate(NULL); // FIXME
}
-
+
if (fespotlight->x_set)
sp_repr_set_css_double(repr, "x", fespotlight->x);
if (fespotlight->y_set)
@@ -351,7 +352,7 @@ sp_fespotlight_write(SPObject *object, Inkscape::XML::Node *repr, guint flags)
sp_repr_set_css_double(repr, "specularExponent", fespotlight->specularExponent);
if (fespotlight->limitingConeAngle_set)
sp_repr_set_css_double(repr, "limitingConeAngle", fespotlight->limitingConeAngle);
-
+
if (((SPObjectClass *) feSpotLight_parent_class)->write) {
((SPObjectClass *) feSpotLight_parent_class)->write(object, repr, flags);
}