Tag: cws_src680_oj14 User: oj Date: 2007-05-30 16:24:49+0000 Modified: dba/reportdesign/source/ui/report/DesignView.cxx dba/reportdesign/source/ui/report/ReportController.cxx dba/reportdesign/source/ui/report/ReportWindow.cxx dba/reportdesign/source/ui/report/ScrollHelper.cxx dba/reportdesign/source/ui/report/ViewsWindow.cxx
Log: #i77284 tab+ctrl to move between sections File Changes: Directory: /dba/reportdesign/source/ui/report/ ============================================== File [changed]: DesignView.cxx Url: http://dba.openoffice.org/source/browse/dba/reportdesign/source/ui/report/DesignView.cxx?r1=1.1.2.7&r2=1.1.2.8 Delta lines: +8 -2 ------------------- --- DesignView.cxx 2007-05-29 13:12:23+0000 1.1.2.7 +++ DesignView.cxx 2007-05-30 16:24:46+0000 1.1.2.8 @@ -4,9 +4,9 @@ * * $RCSfile: DesignView.cxx,v $ * - * $Revision: 1.1.2.7 $ + * $Revision: 1.1.2.8 $ * - * last change: $Author: lla $ $Date: 2007/05/29 13:12:23 $ + * last change: $Author: oj $ $Date: 2007/05/30 16:24:46 $ * * The Contents of this file are made available subject to * the terms of GNU Lesser General Public License Version 2.1. @@ -599,6 +599,12 @@ { return m_pScrollWindow ? m_pScrollWindow->getMarkedSection(nsa) : ::boost::shared_ptr<OReportSection>(); } +// ------------------------------------------------------------------------- +void ODesignView::markSection(const sal_uInt16 _nPos) +{ + if ( m_pScrollWindow ) + m_pScrollWindow->markSection(_nPos); +} // ----------------------------------------------------------------------------- void ODesignView::fillCollapsedSections(::std::vector<sal_uInt16>& _rCollapsedPositions) const { File [changed]: ReportController.cxx Url: http://dba.openoffice.org/source/browse/dba/reportdesign/source/ui/report/ReportController.cxx?r1=1.1.2.19&r2=1.1.2.20 Delta lines: +38 -5 -------------------- --- ReportController.cxx 2007-05-30 13:50:17+0000 1.1.2.19 +++ ReportController.cxx 2007-05-30 16:24:46+0000 1.1.2.20 @@ -4,9 +4,9 @@ * * $RCSfile: ReportController.cxx,v $ * - * $Revision: 1.1.2.19 $ + * $Revision: 1.1.2.20 $ * - * last change: $Author: fs $ $Date: 2007/05/30 13:50:17 $ + * last change: $Author: oj $ $Date: 2007/05/30 16:24:46 $ * * The Contents of this file are made available subject to * the terms of GNU Lesser General Public License Version 2.1. @@ -465,7 +465,7 @@ aReturn.bEnabled = isEditable(); aReturn.bChecked = (m_xReportDefinition.is() && m_xReportDefinition->getMimeType() == MIMETYPE_OASIS_OPENDOCUMENT_TEXT); break; - case SID_RPT_SPREEDSHEET: + case SID_RPT_SPREADSHEET: aReturn.bEnabled = isEditable(); aReturn.bChecked = (m_xReportDefinition.is() && m_xReportDefinition->getMimeType() == MIMETYPE_OASIS_OPENDOCUMENT_SPREADSHEET); break; @@ -598,6 +598,10 @@ case SID_RPT_NEW_FUNCTION: aReturn.bEnabled = isEditable(); break; + case SID_NEXT_MARK: + case SID_PREV_MARK: + aReturn.bEnabled = isEditable(); + break; case SID_SELECT: case SID_SELECT_REPORT: aReturn.bEnabled = sal_True; @@ -1034,7 +1038,7 @@ if ( m_xReportDefinition.is() ) m_xReportDefinition->setMimeType( MIMETYPE_OASIS_OPENDOCUMENT_TEXT ); break; - case SID_RPT_SPREEDSHEET: + case SID_RPT_SPREADSHEET: if (m_xReportDefinition.is() ) m_xReportDefinition->setMimeType( MIMETYPE_OASIS_OPENDOCUMENT_SPREADSHEET ); break; @@ -1161,6 +1165,12 @@ case SID_RPT_NEW_FUNCTION: createNewFunction(aArgs[0].Value); break; + case SID_NEXT_MARK: + markSection(true); + break; + case SID_PREV_MARK: + markSection(false); + break; case SID_DELETE: if ( aArgs.getLength() == 1 ) { @@ -1800,7 +1810,7 @@ OSingleDocumentController::describeSupportedFeatures(); implDescribeSupportedFeature( ".uno:TextDocument", SID_RPT_TEXTDOCUMENT, CommandGroup::APPLICATION ); - implDescribeSupportedFeature( ".uno:Spreedsheet", SID_RPT_SPREEDSHEET, CommandGroup::APPLICATION ); + implDescribeSupportedFeature( ".uno:Spreadsheet", SID_RPT_SPREADSHEET, CommandGroup::APPLICATION ); implDescribeSupportedFeature( ".uno:Redo", SID_REDO, CommandGroup::EDIT ); implDescribeSupportedFeature( ".uno:Undo", SID_UNDO, CommandGroup::EDIT ); @@ -2046,6 +2056,8 @@ implDescribeSupportedFeature( ".uno:LastPropertyBrowserPage", SID_PROPERTYBROWSER_LAST_PAGE); implDescribeSupportedFeature( ".uno:Select", SID_SELECT); implDescribeSupportedFeature( ".uno:InsertFunction", SID_RPT_NEW_FUNCTION); + implDescribeSupportedFeature( ".uno:NextMark", SID_NEXT_MARK); + implDescribeSupportedFeature( ".uno:PrevMark", SID_PREV_MARK); } // ----------------------------------------------------------------------------- SfxUndoManager* OReportController::getUndoMgr() @@ -3721,4 +3733,25 @@ } } } +// ----------------------------------------------------------------------------- +void OReportController::markSection(const bool _bNext) +{ + ::boost::shared_ptr<OReportSection> pSection = m_pMyOwnView->getMarkedSection(); + if ( pSection ) + { + ::boost::shared_ptr<OReportSection> pPrevSection = m_pMyOwnView->getMarkedSection(_bNext ? POST : PREVIOUS); + if ( pPrevSection != pSection && pPrevSection ) + select(uno::makeAny(pPrevSection->getSection())); + else + select(uno::makeAny(m_xReportDefinition)); + } + else + { + m_pMyOwnView->markSection(_bNext ? 0 : m_pMyOwnView->getSectionCount() - 1); + pSection = m_pMyOwnView->getMarkedSection(); + if ( pSection ) + select(uno::makeAny(pSection->getSection())); + } +} + File [changed]: ReportWindow.cxx Url: http://dba.openoffice.org/source/browse/dba/reportdesign/source/ui/report/ReportWindow.cxx?r1=1.1.2.4&r2=1.1.2.5 Delta lines: +8 -2 ------------------- --- ReportWindow.cxx 2007-05-30 09:49:56+0000 1.1.2.4 +++ ReportWindow.cxx 2007-05-30 16:24:46+0000 1.1.2.5 @@ -4,9 +4,9 @@ * * $RCSfile: ReportWindow.cxx,v $ * - * $Revision: 1.1.2.4 $ + * $Revision: 1.1.2.5 $ * - * last change: $Author: oj $ $Date: 2007/05/30 09:49:56 $ + * last change: $Author: oj $ $Date: 2007/05/30 16:24:46 $ * * The Contents of this file are made available subject to * the terms of GNU Lesser General Public License Version 2.1. @@ -482,6 +482,12 @@ { return m_pViews ? m_pViews->getMarkedSection(nsa) : ::boost::shared_ptr<OReportSection>(); } +// ------------------------------------------------------------------------- +void OReportWindow::markSection(const sal_uInt16 _nPos) +{ + if ( m_pViews ) + m_pViews->markSection(_nPos); +} // ----------------------------------------------------------------------------- void OReportWindow::fillCollapsedSections(::std::vector<sal_uInt16>& _rCollapsedPositions) const { File [changed]: ScrollHelper.cxx Url: http://dba.openoffice.org/source/browse/dba/reportdesign/source/ui/report/ScrollHelper.cxx?r1=1.1.2.3&r2=1.1.2.4 Delta lines: +8 -2 ------------------- --- ScrollHelper.cxx 2007-05-30 12:28:35+0000 1.1.2.3 +++ ScrollHelper.cxx 2007-05-30 16:24:46+0000 1.1.2.4 @@ -4,9 +4,9 @@ * * $RCSfile: ScrollHelper.cxx,v $ * - * $Revision: 1.1.2.3 $ + * $Revision: 1.1.2.4 $ * - * last change: $Author: oj $ $Date: 2007/05/30 12:28:35 $ + * last change: $Author: oj $ $Date: 2007/05/30 16:24:46 $ * * The Contents of this file are made available subject to * the terms of GNU Lesser General Public License Version 2.1. @@ -496,6 +496,12 @@ { return m_pChild ? m_pChild->getMarkedSection(nsa) : ::boost::shared_ptr<OReportSection>(); } +// ------------------------------------------------------------------------- +void OScrollWindowHelper::markSection(const sal_uInt16 _nPos) +{ + if ( m_pChild ) + m_pChild->markSection(_nPos); +} // ----------------------------------------------------------------------------- void OScrollWindowHelper::fillCollapsedSections(::std::vector<sal_uInt16>& _rCollapsedPositions) const { File [changed]: ViewsWindow.cxx Url: http://dba.openoffice.org/source/browse/dba/reportdesign/source/ui/report/ViewsWindow.cxx?r1=1.1.2.6&r2=1.1.2.7 Delta lines: +8 -2 ------------------- --- ViewsWindow.cxx 2007-05-29 17:24:06+0000 1.1.2.6 +++ ViewsWindow.cxx 2007-05-30 16:24:46+0000 1.1.2.7 @@ -4,9 +4,9 @@ * * $RCSfile: ViewsWindow.cxx,v $ * - * $Revision: 1.1.2.6 $ + * $Revision: 1.1.2.7 $ * - * last change: $Author: oj $ $Date: 2007/05/29 17:24:06 $ + * last change: $Author: oj $ $Date: 2007/05/30 16:24:46 $ * * The Contents of this file are made available subject to * the terms of GNU Lesser General Public License Version 2.1. @@ -614,6 +614,12 @@ return pRet; } +// ------------------------------------------------------------------------- +void OViewsWindow::markSection(const sal_uInt16 _nPos) +{ + if ( _nPos < m_aSections.size() ) + m_pParent->setMarked(getIteratorAtPos(_nPos)->first.first->getSection(),sal_True); +} //---------------------------------------------------------------------------- BOOL OViewsWindow::IsPasteAllowed() { --------------------------------------------------------------------- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
