summaryrefslogtreecommitdiff
path: root/sd/source/ui/unoidl
diff options
context:
space:
mode:
authorDavid Tardon <dtardon@redhat.com>2010-10-19 09:41:43 +0200
committerDavid Tardon <dtardon@redhat.com>2010-10-19 09:41:43 +0200
commit9167a2bb957b398f35808d3585e9426f7383a885 (patch)
tree621169bfc60d0b09814441c2d50d2621e8e2013a /sd/source/ui/unoidl
parent2f20e05065b41975647c6399d3b2165bf812975d (diff)
remove do {...} while (false) spanning whole func.
Diffstat (limited to 'sd/source/ui/unoidl')
-rw-r--r--sd/source/ui/unoidl/SdUnoDrawView.cxx28
1 files changed, 12 insertions, 16 deletions
diff --git a/sd/source/ui/unoidl/SdUnoDrawView.cxx b/sd/source/ui/unoidl/SdUnoDrawView.cxx
index a4df6184cab7..d711b5a497aa 100644
--- a/sd/source/ui/unoidl/SdUnoDrawView.cxx
+++ b/sd/source/ui/unoidl/SdUnoDrawView.cxx
@@ -165,25 +165,21 @@ Reference<drawing::XLayer> SdUnoDrawView::getActiveLayer (void) throw ()
void SdUnoDrawView::setActiveLayer (const Reference<drawing::XLayer>& rxLayer) throw ()
{
- do
- {
- // Get the SdrLayer object corresponding to the given reference.
- if ( ! rxLayer.is())
- break;
+ // Get the SdrLayer object corresponding to the given reference.
+ if ( ! rxLayer.is())
+ return;
- SdLayer* pLayer = SdLayer::getImplementation (rxLayer);
- if (pLayer == NULL)
- break;
+ SdLayer* pLayer = SdLayer::getImplementation (rxLayer);
+ if (pLayer == NULL)
+ return;
- SdrLayer* pSdrLayer = pLayer->GetSdrLayer();
- if (pSdrLayer == NULL)
- break;
+ SdrLayer* pSdrLayer = pLayer->GetSdrLayer();
+ if (pSdrLayer == NULL)
+ return;
- // Set the new active layer and make the change visible.
- mrView.SetActiveLayer (pSdrLayer->GetName());
- mrDrawViewShell.ResetActualLayer ();
- }
- while (false);
+ // Set the new active layer and make the change visible.
+ mrView.SetActiveLayer (pSdrLayer->GetName());
+ mrDrawViewShell.ResetActualLayer ();
}