26 #define YUILogComponent "ui" 29 #include "YUISymbols.h" 30 #include "YPartitionSplitter.h" 41 const string & usedLabel,
42 const string & freeLabel,
43 const string & newPartLabel,
44 const string & freeFieldLabel,
45 const string & newPartFieldLabel )
46 : usedSize ( usedSize )
47 , totalFreeSize ( totalFreeSize )
48 , minNewPartSize ( minNewPartSize )
49 , minFreeSize ( minFreeSize )
50 , usedLabel ( usedLabel )
51 , freeLabel ( freeLabel )
52 , newPartLabel ( newPartLabel )
53 , freeFieldLabel ( freeFieldLabel )
54 , newPartFieldLabel ( newPartFieldLabel )
64 string freeFieldLabel;
65 string newPartFieldLabel;
77 const string & usedLabel,
78 const string & freeLabel,
79 const string & newPartLabel,
80 const string & freeFieldLabel,
81 const string & newPartFieldLabel )
94 YUI_CHECK_NEW( priv );
107 int YPartitionSplitter::usedSize()
const 109 return priv->usedSize;
113 int YPartitionSplitter::totalFreeSize()
const 115 return priv->totalFreeSize;
119 int YPartitionSplitter::minNewPartSize()
const 121 return priv->minNewPartSize;
125 int YPartitionSplitter::minFreeSize()
const 127 return priv->minFreeSize;
131 string YPartitionSplitter::usedLabel()
const 133 return priv->usedLabel;
137 string YPartitionSplitter::freeLabel()
const 139 return priv->freeLabel;
143 string YPartitionSplitter::newPartLabel()
const 145 return priv->newPartLabel;
149 string YPartitionSplitter::freeFieldLabel()
const 151 return priv->freeFieldLabel;
155 string YPartitionSplitter::newPartFieldLabel()
const 157 return priv->newPartFieldLabel;
171 propSet.
add(
YProperty( YUIProperty_Value, YStringProperty ) );
184 if ( propertyName == YUIProperty_Value )
setValue( val.integerVal() );
bool isEmpty() const
Returns 'true' if this property set does not contain anything.
Transport class for the value of simple properties.
virtual YPropertyValue getProperty(const std::string &propertyName)
Get a property.
void add(const YProperty &prop)
Add a property to this property set.
virtual bool setProperty(const std::string &propertyName, const YPropertyValue &val)
Set a property.
A set of properties to check names and types against.
YPartitionSplitter(YWidget *parent, int usedSize, int totalFreeSize, int newPartSize, int minNewPartSize, int minFreeSize, const std::string &usedLabel, const std::string &freeLabel, const std::string &newPartLabel, const std::string &freeFieldLabel, const std::string &newPartFieldLabel)
Constructor.
virtual const YPropertySet & propertySet()
Return this class's property set.
Class for widget properties.
virtual void setValue(int newValue)=0
Set the value (the size of the new partition).
virtual int value()=0
The value of this PartitionSplitter: The size of the new partition.
void check(const std::string &propertyName) const
Check if a property 'propertyName' exists in this property set.
YPropertyType type() const
Returns the type of this property value.
virtual ~YPartitionSplitter()
Destructor.