diff options
author | Tor Lillqvist <tml@collabora.com> | 2014-10-08 17:02:09 +0300 |
---|---|---|
committer | Tor Lillqvist <tml@collabora.com> | 2014-10-08 22:52:51 +0300 |
commit | 62bf8e2fbe684e5c9de708234d8867098004076c (patch) | |
tree | 2f9fa0711a646f5adcd491230edc0cf6a81c25e2 | |
parent | 9df8d2a922b85d76011c8ab67a1ded8f367e7aec (diff) |
Store the image bitmaps in MyWorkWindow in the OpenGL case
Change-Id: I1acac06f076a4f8173929a0fe0c0d9eaf6b8d1ff
-rw-r--r-- | vcl/workben/icontest.cxx | 15 |
1 files changed, 3 insertions, 12 deletions
diff --git a/vcl/workben/icontest.cxx b/vcl/workben/icontest.cxx index 2df0f9c7ea83..4d06aa229e78 100644 --- a/vcl/workben/icontest.cxx +++ b/vcl/workben/icontest.cxx @@ -45,6 +45,8 @@ public: virtual void MouseButtonDown( const MouseEvent& rMEvt ) SAL_OVERRIDE; virtual void Paint( const Rectangle& rRect ) SAL_OVERRIDE; virtual void Resize() SAL_OVERRIDE; + + std::vector<Bitmap*>maBitmaps; }; MyWorkWindow::MyWorkWindow( const char *kind, vcl::Window* pParent, WinBits nWinStyle ) : @@ -251,8 +253,6 @@ void IconTestApp::DoItWithOpenGL(std::vector<OUString>& aImageFiles) pWindow->SetText(OUString("OpenGL Image Test")); - Point aPos(10, 10); - for (std::vector<OUString>::const_iterator i = aImageFiles.cbegin(); i != aImageFiles.end(); ++i) { SvFileStream aFileStream( *i, STREAM_READ ); @@ -261,16 +261,7 @@ void IconTestApp::DoItWithOpenGL(std::vector<OUString>& aImageFiles) if (aGraphicFilter.ImportGraphic(aGraphic, *i, aFileStream) != 0) continue; SAL_INFO("vcl.icontest", *i << ": size: " << aGraphic.GetSizeBytes() << "B, " << aGraphic.GetSizePixel()); - Size aSize( 100, 100 ); - // Bitmap *pBitmap = new Bitmap( aGraphic.GetBitmap( ) ); - - - aPos.Move( aSize.Width() + 10, 0); - if ( aPos.X() > 800 ) - { - aPos.setX( 10 ); - aPos.setY( aPos.Y() + aSize.Height() + 10 ); - } + pWindow->maBitmaps.push_back(new Bitmap( aGraphic.GetBitmap( ) ) ); } pWindow->Hide(); |