summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--officecfg/registry/data/org/openoffice/Office/UI/CalcCommands.xcu4
-rw-r--r--sc/source/ui/view/tabvwsh3.cxx4
-rw-r--r--sc/source/ui/view/tabvwsha.cxx13
3 files changed, 7 insertions, 14 deletions
diff --git a/officecfg/registry/data/org/openoffice/Office/UI/CalcCommands.xcu b/officecfg/registry/data/org/openoffice/Office/UI/CalcCommands.xcu
index cdfd82674a53..249b0baa1c1f 100644
--- a/officecfg/registry/data/org/openoffice/Office/UI/CalcCommands.xcu
+++ b/officecfg/registry/data/org/openoffice/Office/UI/CalcCommands.xcu
@@ -550,10 +550,10 @@
</node>
<node oor:name=".uno:DeletePrintArea" oor:op="replace">
<prop oor:name="Label" oor:type="xs:string">
- <value xml:lang="en-US">~Remove Print Area</value>
+ <value xml:lang="en-US">~Clear Print Area</value>
</prop>
<prop oor:name="ContextLabel" oor:type="xs:string">
- <value xml:lang="en-US">~Remove</value>
+ <value xml:lang="en-US">~Clear</value>
</prop>
<prop oor:name="Properties" oor:type="xs:int">
<value>1</value>
diff --git a/sc/source/ui/view/tabvwsh3.cxx b/sc/source/ui/view/tabvwsh3.cxx
index c74de5aed9b2..d8d482738f3b 100644
--- a/sc/source/ui/view/tabvwsh3.cxx
+++ b/sc/source/ui/view/tabvwsh3.cxx
@@ -190,8 +190,10 @@ void ScTabViewShell::Execute( SfxRequest& rReq )
case SID_DELETE_PRINTAREA:
{
+ // Clear currently defined print range if any, and reset it to
+ // print entire sheet which is the default.
OUString aEmpty;
- SetPrintRanges( false, &aEmpty, NULL, NULL, false ); // Druckbereich loeschen
+ SetPrintRanges(true, &aEmpty, NULL, NULL, false);
rReq.Done();
}
break;
diff --git a/sc/source/ui/view/tabvwsha.cxx b/sc/source/ui/view/tabvwsha.cxx
index af5cd662785c..5e8ae2a28b97 100644
--- a/sc/source/ui/view/tabvwsha.cxx
+++ b/sc/source/ui/view/tabvwsha.cxx
@@ -191,21 +191,12 @@ void ScTabViewShell::GetState( SfxItemSet& rSet )
break;
case SID_DELETE_PRINTAREA:
- if ( nTabSelCount > 1 )
- {
- // #i22589# also take "Print Entire Sheet" into account here
- bool bHas = false;
- for (SCTAB i=0; !bHas && i<nTabCount; i++)
- bHas = rMark.GetTableSelect(i) && (pDoc->GetPrintRangeCount(i) || pDoc->IsPrintEntireSheet(i));
- if (!bHas)
- rSet.DisableItem( nWhich );
- }
- else if ( !pDoc->GetPrintRangeCount( nTab ) && !pDoc->IsPrintEntireSheet( nTab ) )
- rSet.DisableItem( nWhich );
if ( pDocShell && pDocShell->IsDocShared() )
{
rSet.DisableItem( nWhich );
}
+ else if (pDoc->IsPrintEntireSheet(nTab))
+ rSet.DisableItem(nWhich);
break;
case SID_STATUS_PAGESTYLE: