use more concrete UNO in ScTabViewShell
Change-Id: Ibd9ce1d7a5cb5a7012c9c99235234ca16818f871 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/198370 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
This commit is contained in:
@@ -1867,14 +1867,14 @@ uno::Reference<css::sheet::XSpreadsheet> ScTabViewShell::GetRangeWithSheet(css::
|
||||
uno::Reference<frame::XController> xController(xModel->getCurrentController());
|
||||
|
||||
// spreadsheet's extension of com.sun.star.frame.Controller service
|
||||
uno::Reference<sheet::XSpreadsheetView> SpreadsheetDocument(xController, uno::UNO_QUERY);
|
||||
uno::Reference<sheet::XSpreadsheet> ActiveSheet = SpreadsheetDocument->getActiveSheet();
|
||||
ScTabViewObj* pSpreadsheetDocument = dynamic_cast<ScTabViewObj*>(xController.get());
|
||||
assert(pSpreadsheetDocument);
|
||||
uno::Reference<sheet::XSpreadsheet> ActiveSheet = pSpreadsheetDocument->getActiveSheet();
|
||||
|
||||
if (!bHasUnoArguments)
|
||||
{
|
||||
// get the selection supplier, extract selection in XSheetCellRange
|
||||
uno::Reference<view::XSelectionSupplier> xSelectionSupplier(SpreadsheetDocument, uno::UNO_QUERY);
|
||||
uno::Any Selection = xSelectionSupplier->getSelection();
|
||||
uno::Any Selection = pSpreadsheetDocument->getSelection();
|
||||
uno::Reference<sheet::XSheetCellRange> SelectedCellRange;
|
||||
Selection >>= SelectedCellRange;
|
||||
|
||||
|
||||
Reference in New Issue
Block a user