summaryrefslogtreecommitdiffstats
path: root/gtk/src/presets.c
diff options
context:
space:
mode:
authorjstebbins <[email protected]>2008-09-19 00:19:46 +0000
committerjstebbins <[email protected]>2008-09-19 00:19:46 +0000
commit15208b5875fbfc53480941750bc8afae7b5f90a7 (patch)
treebff253b6752c33a6d1f1f9e3b3c357b08bbea524 /gtk/src/presets.c
parent3609b74b98372c0c4960a0a681fd1f0a4dc24c9b (diff)
LinGui: tidy up how combobox values are handled internally and stored in plists
fix a problem with storing max picture dims to presets plist git-svn-id: svn://svn.handbrake.fr/HandBrake/trunk@1719 b64f7644-9d1e-0410-96f1-a4d463321fa5
Diffstat (limited to 'gtk/src/presets.c')
-rw-r--r--gtk/src/presets.c15
1 files changed, 9 insertions, 6 deletions
diff --git a/gtk/src/presets.c b/gtk/src/presets.c
index 8f8a0cd65..e3ec46591 100644
--- a/gtk/src/presets.c
+++ b/gtk/src/presets.c
@@ -745,19 +745,22 @@ ghb_settings_save(signal_user_data_t *ud, const gchar *name)
while (g_hash_table_iter_next(
&iter, (gpointer*)(void*)&key, (gpointer*)(void*)&value))
{
+ const GValue *gval;
+ gchar *key2;
+
+ key2 = key;
if (!autoscale)
{
- if (strcmp(key, "scale_width"))
+ if (strcmp(key, "max_width") == 0)
{
- key = "max_width";
+ key2 = "scale_width";
}
- if (strcmp(key, "scale_height"))
+ else if (strcmp(key, "max_height") == 0)
{
- key = "max_height";
+ key2 = "scale_height";
}
}
- const GValue *gval;
- gval = ghb_settings_get_value(ud->settings, key);
+ gval = ghb_settings_get_value(ud->settings, key2);
if (gval == NULL)
{
g_debug("Setting (%s) is not in defaults\n", (gchar*)key);