Commit 5f17bdbb authored by Oleg.Korshul's avatar Oleg.Korshul Committed by Alexander.Trofimov

удаление слайдов при демонстрации (другим пользователем)

git-svn-id: svn://192.168.3.15/activex/AVS/Sources/TeamlabOffice/trunk/OfficeWeb@68427 954022d7-b5bf-4e40-9824-e11837661b57
parent df821261
...@@ -2818,6 +2818,13 @@ function CDemonstrationManager(htmlpage) ...@@ -2818,6 +2818,13 @@ function CDemonstrationManager(htmlpage)
} }
} }
this.CorrectSlideNum = function()
{
this.SlidesCount = this.HtmlPage.m_oDrawingDocument.SlidesCount;
if (this.SlideNum > this.SlidesCount)
this.SlideNum = this.SlidesCount;
}
this.Start = function(main_div_id, start_slide_num, is_play_mode) this.Start = function(main_div_id, start_slide_num, is_play_mode)
{ {
this.SlidesCount = this.HtmlPage.m_oDrawingDocument.SlidesCount; this.SlidesCount = this.HtmlPage.m_oDrawingDocument.SlidesCount;
...@@ -3090,6 +3097,8 @@ function CDemonstrationManager(htmlpage) ...@@ -3090,6 +3097,8 @@ function CDemonstrationManager(htmlpage)
if (!this.Mode) if (!this.Mode)
return; return;
this.CorrectSlideNum();
var _is_transition = this.Transition.IsPlaying(); var _is_transition = this.Transition.IsPlaying();
if (!_is_transition) if (!_is_transition)
this.SlideNum++; this.SlideNum++;
...@@ -3110,6 +3119,8 @@ function CDemonstrationManager(htmlpage) ...@@ -3110,6 +3119,8 @@ function CDemonstrationManager(htmlpage)
if (0 != this.SlideNum) if (0 != this.SlideNum)
{ {
this.CorrectSlideNum();
// TODO: backward transition // TODO: backward transition
this.StartSlideBackward(); this.StartSlideBackward();
this.HtmlPage.m_oApi.sync_DemonstrationSlideChanged(this.SlideNum); this.HtmlPage.m_oApi.sync_DemonstrationSlideChanged(this.SlideNum);
...@@ -3121,6 +3132,8 @@ function CDemonstrationManager(htmlpage) ...@@ -3121,6 +3132,8 @@ function CDemonstrationManager(htmlpage)
if (!this.Mode) if (!this.Mode)
return; return;
this.CorrectSlideNum();
if ((slideNum == this.SlideNum) || (slideNum < 0) || (slideNum >= this.SlidesCount)) if ((slideNum == this.SlideNum) || (slideNum < 0) || (slideNum >= this.SlidesCount))
return; return;
...@@ -3201,6 +3214,8 @@ function CDemonstrationManager(htmlpage) ...@@ -3201,6 +3214,8 @@ function CDemonstrationManager(htmlpage)
this.onMouseUp = function(e) this.onMouseUp = function(e)
{ {
// next slide // next slide
oThis.CorrectSlideNum();
var _is_transition = oThis.Transition.IsPlaying(); var _is_transition = oThis.Transition.IsPlaying();
if (_is_transition) if (_is_transition)
{ {
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment