[gimp] Use gtk_adjustment_get_value() instead of adjustment->value
- From: Michael Natterer <mitch src gnome org>
- To: svn-commits-list gnome org
- Cc:
- Subject: [gimp] Use gtk_adjustment_get_value() instead of adjustment->value
- Date: Fri, 9 Oct 2009 19:20:36 +0000 (UTC)
commit e61a74b938fbb4aa5666c27f1c45ac6d0d009fa0
Author: Michael Natterer <mitch gimp org>
Date: Fri Oct 9 11:55:11 2009 +0200
Use gtk_adjustment_get_value() instead of adjustment->value
modules/color-selector-cmyk-lcms.c | 11 +++++++----
1 files changed, 7 insertions(+), 4 deletions(-)
---
diff --git a/modules/color-selector-cmyk-lcms.c b/modules/color-selector-cmyk-lcms.c
index b1b65e2..d468908 100644
--- a/modules/color-selector-cmyk-lcms.c
+++ b/modules/color-selector-cmyk-lcms.c
@@ -308,24 +308,27 @@ colorsel_cmyk_adj_update (GtkAdjustment *adj,
{
GimpColorSelector *selector = GIMP_COLOR_SELECTOR (module);
gint i;
+ gdouble value;
for (i = 0; i < 4; i++)
if (module->adj[i] == adj)
break;
+ value = gtk_adjustment_get_value (adj) / 100.0;
+
switch (i)
{
case 0:
- module->cmyk.c = adj->value / 100.0;
+ module->cmyk.c = value;
break;
case 1:
- module->cmyk.m = adj->value / 100.0;
+ module->cmyk.m = value;
break;
case 2:
- module->cmyk.y = adj->value / 100.0;
+ module->cmyk.y = value;
break;
case 3:
- module->cmyk.k = adj->value / 100.0;
+ module->cmyk.k = value;
break;
default:
return;
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]