[Libreoffice-commits] core.git: Branch 'feature/vclptr' - accessibility/source desktop/source vcl/unx vcl/workben
Michael Meeks
michael.meeks at collabora.com
Fri Apr 10 06:39:12 PDT 2015
accessibility/source/standard/vclxaccessibletoolbox.cxx | 2 +-
desktop/source/splash/splash.cxx | 2 +-
vcl/unx/gtk3/gdi/cairo_gtk3_cairo.cxx | 4 ++--
vcl/workben/vcldemo.cxx | 15 +++++++++------
4 files changed, 13 insertions(+), 10 deletions(-)
New commits:
commit 746b518ceff830f8ac1f29c8871ad379793eb12e
Author: Michael Meeks <michael.meeks at collabora.com>
Date: Fri Apr 10 14:44:45 2015 +0100
More misc. cleanup.
Change-Id: I91d2c45a7082fd989f440fff9e1322e4571dc2b2
diff --git a/accessibility/source/standard/vclxaccessibletoolbox.cxx b/accessibility/source/standard/vclxaccessibletoolbox.cxx
index 8e502bf..bbb4e26 100644
--- a/accessibility/source/standard/vclxaccessibletoolbox.cxx
+++ b/accessibility/source/standard/vclxaccessibletoolbox.cxx
@@ -624,7 +624,7 @@ void VCLXAccessibleToolBox::ProcessWindowEvent( const VclWindowEvent& rVclWindow
VCLXAccessibleToolBox* pParent = static_cast< VCLXAccessibleToolBox* >(
pWin->GetParent()->GetAccessible()->getAccessibleContext().get() );
if ( pParent )
- pParent->ReleaseSubToolBox(static_cast<ToolBox *>(pWin));
+ pParent->ReleaseSubToolBox(static_cast<ToolBox *>(pWin.get()));
}
// dispose all items
diff --git a/desktop/source/splash/splash.cxx b/desktop/source/splash/splash.cxx
index cb1630a..ae80ddc 100644
--- a/desktop/source/splash/splash.cxx
+++ b/desktop/source/splash/splash.cxx
@@ -629,7 +629,7 @@ void SplashScreenWindow::Paint( const Rectangle&)
}
if( (DrawNativeControl( CTRL_INTROPROGRESS, PART_ENTIRE_CONTROL, aDrawRect,
- ControlState::ENABLED, aValue, _sProgressText )) )
+ ControlState::ENABLED, aValue, pSpl->_sProgressText )) )
{
return;
}
diff --git a/vcl/unx/gtk3/gdi/cairo_gtk3_cairo.cxx b/vcl/unx/gtk3/gdi/cairo_gtk3_cairo.cxx
index 6917596..b9a2751 100644
--- a/vcl/unx/gtk3/gdi/cairo_gtk3_cairo.cxx
+++ b/vcl/unx/gtk3/gdi/cairo_gtk3_cairo.cxx
@@ -107,9 +107,9 @@ namespace cairo
mpGraphics->WidgetQueueDraw();
}
- boost::shared_ptr<VirtualDevice> Gtk3Surface::createVirtualDevice() const
+ VclPtr<VirtualDevice> Gtk3Surface::createVirtualDevice() const
{
- return boost::shared_ptr<VirtualDevice>(new VirtualDevice(NULL, Size(1, 1), 0));
+ return VclPtrInstance<VirtualDevice>(nullptr, Size(1, 1), 0);
}
}
diff --git a/vcl/workben/vcldemo.cxx b/vcl/workben/vcldemo.cxx
index 4220b7f..4347801 100644
--- a/vcl/workben/vcldemo.cxx
+++ b/vcl/workben/vcldemo.cxx
@@ -1457,8 +1457,8 @@ public:
DemoWidgets() :
WorkWindow(NULL, WB_STDWORK),
mpBox(VclPtrInstance<VclVBox>(this, false, 3)),
- mpToolbox(VclPtrInstance<ToolBox>(mpBox)),
- mpButton(VclPtrInstance<PushButton>(mpBox))
+ mpToolbox(VclPtrInstance<ToolBox>(mpBox.get())),
+ mpButton(VclPtrInstance<PushButton>(mpBox.get()))
{
SetText("VCL widget demo");
@@ -1503,7 +1503,7 @@ public:
DrawWallpaper(aWholeSize, aWallpaper);
Pop();
- ScopedVclPtr< VirtualDevice > pDev(new VirtualDevice(*this));
+ ScopedVclPtrInstance< VirtualDevice > pDev(*this);
pDev->EnableRTL(IsRTLEnabled());
pDev->SetOutputSizePixel(aExclude.GetSize());
@@ -1617,19 +1617,22 @@ public:
}
ScopedVclPtrInstance<DemoWin> aMainWin(aRenderer, bThreads);
- VclPtr<DemoWidgets> aWidgets;
+ VclPtr<DemoWidgets> xWidgets;
VclPtr<DemoPopup> xPopup;
aMainWin->SetText("Interactive VCL demo #1");
if (bWidgets)
- xWidgets.reset(new DemoWidgets());
+ xWidgets = VclPtrInstance< DemoWidgets > ();
else if (bPopup)
- xPopup.reset(new DemoPopup());
+ xPopup = VclPtrInstance< DemoPopup> ();
else
aMainWin->Show();
Application::Execute();
+
+ xWidgets.disposeAndClear();
+ xPopup.disposeAndClear();
}
catch (const css::uno::Exception& e)
{
More information about the Libreoffice-commits
mailing list