diff options
author | Caolán McNamara <caolanm@redhat.com> | 2012-12-11 14:03:18 +0000 |
---|---|---|
committer | Caolán McNamara <caolanm@redhat.com> | 2012-12-11 14:04:51 +0000 |
commit | a930214c40389b82ee1060ed65669dc772ed36ea (patch) | |
tree | d1c6c3a68ae2e3b2a78cac29127c897adce96943 /vcl/inc | |
parent | 7ba2c823cac8998dfc0c2e19470f5edee70e63f0 (diff) |
support 'active' property in ListBox
Change-Id: Ib1219e8e7031febd4f9cc599cb19426f974eac9c
Diffstat (limited to 'vcl/inc')
-rw-r--r-- | vcl/inc/vcl/builder.hxx | 16 | ||||
-rw-r--r-- | vcl/inc/vcl/lstbox.hxx | 2 |
2 files changed, 16 insertions, 2 deletions
diff --git a/vcl/inc/vcl/builder.hxx b/vcl/inc/vcl/builder.hxx index 4ca873f2d35e..e34da3aefcc8 100644 --- a/vcl/inc/vcl/builder.hxx +++ b/vcl/inc/vcl/builder.hxx @@ -81,19 +81,31 @@ private: }; typedef StringPair RadioButtonGroupMap; - typedef StringPair ComboBoxModelMap; typedef StringPair ButtonImageWidgetMap; typedef StringPair TextBufferMap; typedef StringPair WidgetAdjustmentMap; typedef StringPair ButtonMenuMap; + struct ComboBoxModelMap + { + OString m_sID; + OString m_sValue; + sal_Int32 m_nActiveId; + ComboBoxModelMap(const OString &rId, const OString &rValue, sal_Int32 nActiveId) + : m_sID(rId) + , m_sValue(rValue) + , m_nActiveId(nActiveId) + { + } + }; + struct ListStore { typedef std::vector<OString> row; std::vector<row> m_aEntries; }; const ListStore* get_model_by_name(OString sID) const; - static void mungeModel(ListBox &rTarget, const ListStore &rStore); + static void mungeModel(ListBox &rTarget, const ListStore &rStore, sal_uInt16 nActiveId); typedef stringmap TextBuffer; const TextBuffer* get_buffer_by_name(OString sID) const; diff --git a/vcl/inc/vcl/lstbox.hxx b/vcl/inc/vcl/lstbox.hxx index f90a63e365a6..849da52a79a3 100644 --- a/vcl/inc/vcl/lstbox.hxx +++ b/vcl/inc/vcl/lstbox.hxx @@ -217,6 +217,8 @@ public: */ using Control::GetIndexForPoint; long GetIndexForPoint( const Point& rPoint, sal_uInt16& rPos ) const; + + virtual bool set_property(const rtl::OString &rKey, const rtl::OString &rValue); }; // ---------------- |