[Libreoffice-commits] core.git: vcl/unx
Takeshi Abe
tabe at fixedpoint.jp
Thu Aug 7 07:44:17 PDT 2014
vcl/unx/gtk/gdi/salnativewidgets-gtk.cxx | 12 ++++++++----
1 file changed, 8 insertions(+), 4 deletions(-)
New commits:
commit 38a3d53d8b9e6dd66c19f721be9b4b3e350eb249
Author: Takeshi Abe <tabe at fixedpoint.jp>
Date: Thu Aug 7 23:35:02 2014 +0900
fdo#75757: remove inheritance to std::vector
Change-Id: I04a5832c86823718146c78238ea648be21bf1f53
Reviewed-on: https://gerrit.libreoffice.org/10811
Reviewed-by: David Tardon <dtardon at redhat.com>
Tested-by: David Tardon <dtardon at redhat.com>
diff --git a/vcl/unx/gtk/gdi/salnativewidgets-gtk.cxx b/vcl/unx/gtk/gdi/salnativewidgets-gtk.cxx
index c563395..11aec87 100644
--- a/vcl/unx/gtk/gdi/salnativewidgets-gtk.cxx
+++ b/vcl/unx/gtk/gdi/salnativewidgets-gtk.cxx
@@ -155,12 +155,16 @@ struct NWFWidgetData
// easily and quickly reset each to a default state before using
// them
static boost::unordered_map<long, guint> gWidgetDefaultFlags;
-class WidgetDataVector : public std::vector<NWFWidgetData>
+class WidgetDataVector
{
+private:
+ std::vector<NWFWidgetData> mData;
+
public:
- WidgetDataVector(size_t nElems = 0) : std::vector<NWFWidgetData>( nElems ) {}
- NWFWidgetData &operator [](size_t i) { return at(i); }
- NWFWidgetData &operator [](const SalX11Screen &s) { return at(s.getXScreen()); }
+ WidgetDataVector(size_t nElems = 0) : mData( nElems ) {}
+ size_t size() const { return mData.size(); }
+ NWFWidgetData &operator [](size_t i) { return mData.at(i); }
+ NWFWidgetData &operator [](const SalX11Screen &s) { return mData.at(s.getXScreen()); }
};
static WidgetDataVector gWidgetData;
More information about the Libreoffice-commits
mailing list