Skip to content
Projeler
Gruplar
Parçacıklar
Yardım
Yükleniyor...
Oturum aç / Kaydol
Gezinmeyi değiştir
C
core
Proje
Proje
Ayrıntılar
Etkinlik
Cycle Analytics
Depo (repository)
Depo (repository)
Dosyalar
Kayıtlar (commit)
Dallar (branch)
Etiketler
Katkıda bulunanlar
Grafik
Karşılaştır
Grafikler
Konular (issue)
0
Konular (issue)
0
Liste
Pano
Etiketler
Kilometre Taşları
Birleştirme (merge) Talepleri
0
Birleştirme (merge) Talepleri
0
CI / CD
CI / CD
İş akışları (pipeline)
İşler
Zamanlamalar
Grafikler
Paketler
Paketler
Wiki
Wiki
Parçacıklar
Parçacıklar
Üyeler
Üyeler
Collapse sidebar
Close sidebar
Etkinlik
Grafik
Grafikler
Yeni bir konu (issue) oluştur
İşler
Kayıtlar (commit)
Konu (issue) Panoları
Kenar çubuğunu aç
LibreOffice
core
Commits
7d42654a
Kaydet (Commit)
7d42654a
authored
Mar 11, 2012
tarafından
Rafael Dominguez
Kaydeden (comit)
Markus Mohrhard
Mar 23, 2012
Dosyalara gözat
Seçenekler
Dosyalara Gözat
İndir
Eposta Yamaları
Sade Fark
Merge InsertMenu_YErrorBar and InsertYErrorBar commands in chart controller.
üst
68e482e9
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
48 additions
and
55 deletions
+48
-55
ChartController.cxx
chart2/source/controller/main/ChartController.cxx
+1
-1
ChartController.hxx
chart2/source/controller/main/ChartController.hxx
+0
-1
ChartController_Insert.cxx
chart2/source/controller/main/ChartController_Insert.cxx
+47
-53
No files found.
chart2/source/controller/main/ChartController.cxx
Dosyayı görüntüle @
7d42654a
...
...
@@ -1112,7 +1112,7 @@ bool lcl_isFormatObjectCommand( const rtl::OString& aCommand )
else
if
(
aCommand
.
equals
(
"InsertMenuMeanValues"
))
this
->
executeDispatch_InsertMenu_MeanValues
();
else
if
(
aCommand
.
equals
(
"InsertMenuYErrorBars"
))
this
->
executeDispatch_Insert
Menu_
YErrorBars
();
this
->
executeDispatch_InsertYErrorBars
();
else
if
(
aCommand
.
equals
(
"InsertSymbol"
))
this
->
executeDispatch_InsertSpecialCharacter
();
else
if
(
aCommand
.
equals
(
"InsertTrendline"
))
...
...
chart2/source/controller/main/ChartController.hxx
Dosyayı görüntüle @
7d42654a
...
...
@@ -623,7 +623,6 @@ private:
void
executeDispatch_InsertGrid
();
void
executeDispatch_InsertMenu_DataLabels
();
void
executeDispatch_InsertMenu_YErrorBars
();
void
executeDispatch_InsertMenu_Trendlines
();
void
executeDispatch_InsertMenu_MeanValues
();
...
...
chart2/source/controller/main/ChartController_Insert.cxx
Dosyayı görüntüle @
7d42654a
...
...
@@ -338,58 +338,6 @@ void ChartController::executeDispatch_InsertMenu_DataLabels()
}
}
void
ChartController
::
executeDispatch_InsertMenu_YErrorBars
()
{
//if a series is selected insert error bars for that series only:
uno
::
Reference
<
chart2
::
XDataSeries
>
xSeries
(
ObjectIdentifier
::
getDataSeriesForCID
(
m_aSelection
.
getSelectedCID
(),
getModel
()
),
uno
::
UNO_QUERY
);
if
(
xSeries
.
is
())
{
executeDispatch_InsertYErrorBars
();
return
;
}
//if no series is selected insert error bars for all series
UndoGuard
aUndoGuard
(
ActionDescriptionProvider
::
createDescription
(
ActionDescriptionProvider
::
INSERT
,
ObjectNameProvider
::
getName_ObjectForAllSeries
(
OBJECTTYPE_DATA_ERRORS
)
),
m_xUndoManager
);
try
{
wrapper
::
AllSeriesStatisticsConverter
aItemConverter
(
getModel
(),
m_pDrawModelWrapper
->
GetItemPool
()
);
SfxItemSet
aItemSet
=
aItemConverter
.
CreateEmptyItemSet
();
aItemConverter
.
FillItemSet
(
aItemSet
);
//prepare and open dialog
SolarMutexGuard
aGuard
;
InsertErrorBarsDialog
aDlg
(
m_pChartWindow
,
aItemSet
,
uno
::
Reference
<
chart2
::
XChartDocument
>
(
getModel
(),
uno
::
UNO_QUERY
),
ErrorBarResources
::
ERROR_BAR_Y
);
aDlg
.
SetAxisMinorStepWidthForErrorBarDecimals
(
InsertErrorBarsDialog
::
getAxisMinorStepWidthForErrorBarDecimals
(
getModel
(),
m_xChartView
,
rtl
::
OUString
()
)
);
if
(
aDlg
.
Execute
()
==
RET_OK
)
{
SfxItemSet
aOutItemSet
=
aItemConverter
.
CreateEmptyItemSet
();
aDlg
.
FillItemSet
(
aOutItemSet
);
// lock controllers till end of block
ControllerLockGuard
aCLGuard
(
getModel
()
);
bool
bChanged
=
aItemConverter
.
ApplyItemSet
(
aOutItemSet
);
//model should be changed now
if
(
bChanged
)
aUndoGuard
.
commit
();
}
}
catch
(
const
uno
::
RuntimeException
&
e
)
{
ASSERT_EXCEPTION
(
e
);
}
}
void
ChartController
::
executeDispatch_InsertMeanValue
()
{
UndoGuard
aUndoGuard
(
...
...
@@ -526,8 +474,10 @@ void ChartController::executeDispatch_InsertTrendline()
void
ChartController
::
executeDispatch_InsertYErrorBars
()
{
//if a series is selected insert error bars for that series only:
uno
::
Reference
<
chart2
::
XDataSeries
>
xSeries
(
ObjectIdentifier
::
getDataSeriesForCID
(
m_aSelection
.
getSelectedCID
(),
getModel
()
),
uno
::
UNO_QUERY
);
if
(
xSeries
.
is
())
{
UndoLiveUpdateGuard
aUndoGuard
(
...
...
@@ -557,7 +507,8 @@ void ChartController::executeDispatch_InsertYErrorBars()
SchAttribTabDlg
aDlg
(
m_pChartWindow
,
&
aItemSet
,
&
aDialogParameter
,
&
aViewElementListProvider
,
uno
::
Reference
<
util
::
XNumberFormatsSupplier
>
(
getModel
(),
uno
::
UNO_QUERY
));
aDlg
.
SetAxisMinorStepWidthForErrorBarDecimals
(
InsertErrorBarsDialog
::
getAxisMinorStepWidthForErrorBarDecimals
(
getModel
(),
m_xChartView
,
m_aSelection
.
getSelectedCID
()));
InsertErrorBarsDialog
::
getAxisMinorStepWidthForErrorBarDecimals
(
getModel
(),
m_xChartView
,
m_aSelection
.
getSelectedCID
()));
// note: when a user pressed "OK" but didn't change any settings in the
// dialog, the SfxTabDialog returns "Cancel"
...
...
@@ -572,6 +523,49 @@ void ChartController::executeDispatch_InsertYErrorBars()
aUndoGuard
.
commit
();
}
}
else
{
//if no series is selected insert error bars for all series
UndoGuard
aUndoGuard
(
ActionDescriptionProvider
::
createDescription
(
ActionDescriptionProvider
::
INSERT
,
ObjectNameProvider
::
getName_ObjectForAllSeries
(
OBJECTTYPE_DATA_ERRORS
)
),
m_xUndoManager
);
try
{
wrapper
::
AllSeriesStatisticsConverter
aItemConverter
(
getModel
(),
m_pDrawModelWrapper
->
GetItemPool
()
);
SfxItemSet
aItemSet
=
aItemConverter
.
CreateEmptyItemSet
();
aItemConverter
.
FillItemSet
(
aItemSet
);
//prepare and open dialog
SolarMutexGuard
aGuard
;
InsertErrorBarsDialog
aDlg
(
m_pChartWindow
,
aItemSet
,
uno
::
Reference
<
chart2
::
XChartDocument
>
(
getModel
(),
uno
::
UNO_QUERY
),
ErrorBarResources
::
ERROR_BAR_Y
);
aDlg
.
SetAxisMinorStepWidthForErrorBarDecimals
(
InsertErrorBarsDialog
::
getAxisMinorStepWidthForErrorBarDecimals
(
getModel
(),
m_xChartView
,
rtl
::
OUString
()
)
);
if
(
aDlg
.
Execute
()
==
RET_OK
)
{
SfxItemSet
aOutItemSet
=
aItemConverter
.
CreateEmptyItemSet
();
aDlg
.
FillItemSet
(
aOutItemSet
);
// lock controllers till end of block
ControllerLockGuard
aCLGuard
(
getModel
()
);
bool
bChanged
=
aItemConverter
.
ApplyItemSet
(
aOutItemSet
);
//model should be changed now
if
(
bChanged
)
aUndoGuard
.
commit
();
}
}
catch
(
const
uno
::
RuntimeException
&
e
)
{
ASSERT_EXCEPTION
(
e
);
}
}
}
void
ChartController
::
executeDispatch_InsertTrendlineEquation
(
bool
bInsertR2
)
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment