summaryrefslogtreecommitdiff
path: root/sdext/source/presenter/PresenterToolBar.cxx
diff options
context:
space:
mode:
Diffstat (limited to 'sdext/source/presenter/PresenterToolBar.cxx')
-rw-r--r--sdext/source/presenter/PresenterToolBar.cxx10
1 files changed, 9 insertions, 1 deletions
diff --git a/sdext/source/presenter/PresenterToolBar.cxx b/sdext/source/presenter/PresenterToolBar.cxx
index 3b102475398d..0b514b3e3850 100644
--- a/sdext/source/presenter/PresenterToolBar.cxx
+++ b/sdext/source/presenter/PresenterToolBar.cxx
@@ -310,7 +310,7 @@ namespace {
virtual void TimeHasChanged (const oslDateTime& rCurrentTime) SAL_OVERRIDE;
};
- class PresentationTimeLabel : public TimeLabel
+ class PresentationTimeLabel : public TimeLabel, public IPresentationTime
{
public:
static ::rtl::Reference<Element> Create (
@@ -320,6 +320,7 @@ namespace {
const SharedElementMode& rpMouseOverMode,
const SharedElementMode& rpSelectedMode,
const SharedElementMode& rpDisabledMode) SAL_OVERRIDE;
+ virtual void restart() SAL_OVERRIDE;
private:
TimeFormatter maTimeFormatter;
TimeValue maStartTimeValue;
@@ -1909,6 +1910,7 @@ void CurrentTimeLabel::SetModes (
PresentationTimeLabel::~PresentationTimeLabel()
{
+ mpToolBar->GetPresenterController()->SetPresentationTime(0);
}
PresentationTimeLabel::PresentationTimeLabel (
@@ -1917,6 +1919,12 @@ PresentationTimeLabel::PresentationTimeLabel (
maTimeFormatter(),
maStartTimeValue()
{
+ restart();
+ mpToolBar->GetPresenterController()->SetPresentationTime(this);
+}
+
+void PresentationTimeLabel::restart()
+{
maStartTimeValue.Seconds = 0;
maStartTimeValue.Nanosec = 0;
}