summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorCaolán McNamara <caolanm@redhat.com>2016-01-20 20:54:04 +0000
committerCaolán McNamara <caolanm@redhat.com>2016-01-21 11:47:18 +0000
commit57057732676135c1c671d3af717e147abbbb40d3 (patch)
tree16b96c2d23383bf6a9dcfae24537141beacef19a
parent68f519f5d3f90a9f7ae7c91dc1d6653440a9c6d6 (diff)
cppcheck: variableScope
Change-Id: Id7cf5887c1ef0e0c0aad72ea5ac49f4d3db5065e
-rw-r--r--vcl/source/outdev/transparent.cxx6
-rw-r--r--vcl/unx/generic/desktopdetect/desktopdetector.cxx2
-rw-r--r--xmloff/source/chart/SchXMLExport.cxx4
3 files changed, 6 insertions, 6 deletions
diff --git a/vcl/source/outdev/transparent.cxx b/vcl/source/outdev/transparent.cxx
index 86b0fe5b40e8..6d60524ece91 100644
--- a/vcl/source/outdev/transparent.cxx
+++ b/vcl/source/outdev/transparent.cxx
@@ -366,9 +366,6 @@ bool OutputDevice::DrawTransparentNatively ( const tools::PolyPolygon& rPolyPoly
void OutputDevice::EmulateDrawTransparent ( const tools::PolyPolygon& rPolyPoly,
sal_uInt16 nTransparencePercent )
{
- // debug helper:
- static const char* pDisableNative = getenv( "SAL_DISABLE_NATIVE_ALPHA" );
-
// #110958# Disable alpha VDev, we perform the necessary
VirtualDevice* pOldAlphaVDev = mpAlphaVDev;
@@ -392,6 +389,9 @@ void OutputDevice::EmulateDrawTransparent ( const tools::PolyPolygon& rPolyPoly,
{
bool bDrawn = false;
+ // debug helper:
+ static const char* pDisableNative = getenv( "SAL_DISABLE_NATIVE_ALPHA" );
+
// #i66849# Added fast path for exactly rectangular
// polygons
// #i83087# Naturally, system alpha blending cannot
diff --git a/vcl/unx/generic/desktopdetect/desktopdetector.cxx b/vcl/unx/generic/desktopdetect/desktopdetector.cxx
index 8135164c44aa..06fdc50df33a 100644
--- a/vcl/unx/generic/desktopdetect/desktopdetector.cxx
+++ b/vcl/unx/generic/desktopdetect/desktopdetector.cxx
@@ -234,9 +234,9 @@ static bool is_tde_desktop( Display* pDisplay )
static bool is_kde3_desktop( Display* pDisplay )
{
static const char * pFullVersion = getenv( "KDE_FULL_SESSION" );
- static const char * pSessionVersion = getenv( "KDE_SESSION_VERSION" );
if ( pFullVersion )
{
+ static const char * pSessionVersion = getenv( "KDE_SESSION_VERSION" );
if ( !pSessionVersion || pSessionVersion[0] == '0' )
{
return true; // does not exist => KDE3
diff --git a/xmloff/source/chart/SchXMLExport.cxx b/xmloff/source/chart/SchXMLExport.cxx
index 0c7ca7d4c636..44f59efe83eb 100644
--- a/xmloff/source/chart/SchXMLExport.cxx
+++ b/xmloff/source/chart/SchXMLExport.cxx
@@ -1832,8 +1832,6 @@ void SchXMLExportHelper_Impl::exportPlotArea(
Reference< beans::XPropertySet > xPropSet;
std::vector< XMLPropertyState > aPropertyStates;
- bool bIs3DChart = false;
-
msStringBuffer.setLength( 0 );
// plot-area element
@@ -1902,6 +1900,8 @@ void SchXMLExportHelper_Impl::exportPlotArea(
addSize( xShape );
}
+ bool bIs3DChart = false;
+
if( xPropSet.is())
{
Any aAny;