lmi
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [lmi] Drill-down census editor observations


From: Václav Slavík
Subject: Re: [lmi] Drill-down census editor observations
Date: Thu, 7 Nov 2013 15:06:51 +0100

Hi,

On 1 Nov 2013, at 15:00, Václav Slavík <address@hidden> wrote:
>> A. While testing various controls (i.e., textbox, radiobutton, spin 
>>  control, etc.), I observed that the Product Name is text and not 
>>  a drop-down list (as on the Plan tab in the GUI). This may be 
>>  problematic to some users having to remember a products exact 
>>  spelling and naming convention.
> 
> This is strange. If the Product Name is declared as an mc_enum in the model 
> (which it seems to be to me), then it should be picked as such by CensusView. 
> I'll investigate.

Turns out that ce_product_name (why is this the only enum that doesn't start 
with "mce_", BTW?) was missing from reconstitutor<mc_enum_base, Input> and so 
the type wasn't recognized as  an enum, even though it derives from 
mc_enum_base. This patch fixes it:


diff --git a/input.hpp b/input.hpp
index 495f0c0..c3a748e 100644
--- a/input.hpp
+++ b/input.hpp
@@ -512,6 +512,7 @@ template<> struct reconstitutor<mc_enum_base, Input>
     static DesiredType* reconstitute(any_member<Input>& m)
         {
         DesiredType* z = 0;
+        z = exact_cast<ce_product_name         >(m); if(z) return z;
         z = exact_cast<mce_class               >(m); if(z) return z;
         z = exact_cast<mce_country             >(m); if(z) return z;
         z = exact_cast<mce_dbopt               >(m); if(z) return z;


Regards,
Vaclav


reply via email to

[Prev in Thread] Current Thread [Next in Thread]