[prev in list] [next in list] [prev in thread] [next in thread] 

List:       kde-core-devel
Subject:    parametrized entries in kcfg files are set to immutable...
From:       Reinhold Kainhofer <reinhold () kainhofer ! com>
Date:       2004-03-06 18:40:56
Message-ID: 200403061940.56434.reinhold () kainhofer ! com
[Download RAW message or body]

Hi, I'm having a problem with parametrized entries in KConfigXT: In KPilot's 
addressbook conduit we have four Custom fields, where the user can choose 
among possible values of an enum. The corresponding part in the .kcfg file 
(kdepim/kpilot/conduits/abbrowserconduit/abbrowserconduit.kcfg) is:

<entry name="Custom$(customIndex)" key="Custom $(customIndex)" type="Enum">
  <parameter name="customIndex" type="Int" max="3"/>
  <choices label="eCustomEnum">
    <choice name="eCustomField"/>
    <choice name="eCustomBirthdate"/>
    <choice name="eCustomURL"/>
    <choice name="eCustomIM"/>
  </choices>
  <label></label>
  <default>eCustomField</default>
</entry>


Accessing the config entries via custom(0) works fine. Now, whenever I do a 
setCustom(0, ...), nothing changes. I inserted a few debug statements into 
the generated abbrowserSettings.h (in the static void setCustom(int i, int v) 
function) and found that the "Custom" item is set to immutable:

static
void setCustom( int i, int v )
{
	if (!self()->isImmutable( "Custom" ))
		self()->mCustom[i] = v;
}

The isImmutable always returns true, and the item is not changed! Am I doing 
something wrong, or is this a bug somewhere in kconfigXT or kconfigSkeleton?

Thanks for any help,
Reinhold

[prev in list] [next in list] [prev in thread] [next in thread] 

Configure | About | News | Add a list | Sponsored by KoreLogic