summaryrefslogtreecommitdiff
path: root/chart2
diff options
context:
space:
mode:
authorIngrid Halama <iha@openoffice.org>2010-05-17 18:05:05 +0200
committerIngrid Halama <iha@openoffice.org>2010-05-17 18:05:05 +0200
commit417c5223db83a7f5932ecbba12bed63e0f5c6f41 (patch)
tree3552708019ab6041eb1a5a670b8c4ed04fea3ebb /chart2
parent2a1490743fb5da2ddb579967fa93b723b5f851a6 (diff)
chart47: #i109770# #i110253# don't paint anything if no model is available
Diffstat (limited to 'chart2')
-rw-r--r--chart2/source/controller/main/ChartController_Window.cxx5
1 files changed, 5 insertions, 0 deletions
diff --git a/chart2/source/controller/main/ChartController_Window.cxx b/chart2/source/controller/main/ChartController_Window.cxx
index 7822c8c1cc21..284b3ff370cf 100644
--- a/chart2/source/controller/main/ChartController_Window.cxx
+++ b/chart2/source/controller/main/ChartController_Window.cxx
@@ -507,6 +507,11 @@ void ChartController::execute_Paint( const Rectangle& rRect )
{
try
{
+ uno::Reference< frame::XModel > xModel( m_aModel->getModel() );
+ DBG_ASSERT( xModel.is(), "ChartController::execute_Paint: have no model to paint");
+ if( !xModel.is() )
+ return;
+
//better performance for big data
uno::Reference< beans::XPropertySet > xProp( m_xChartView, uno::UNO_QUERY );
if( xProp.is() )