Commit 48f93015 authored by Oleg.Korshul's avatar Oleg.Korshul Committed by Alexander.Trofimov

Delete/ Select/ SelectAll/ Copy/ Paste/ Cut

git-svn-id: svn://192.168.3.15/activex/AVS/Sources/TeamlabOffice/trunk/OfficeWeb@58949 954022d7-b5bf-4e40-9824-e11837661b57
parent 341c9776
......@@ -541,6 +541,7 @@ function CDrawingDocument()
{
this.Native = window["native"];
this.Api = window.editor;
this.m_oApi = this.Api;
this.IsLockObjectsEnable = false;
this.LogicDocument = null;
......@@ -605,6 +606,8 @@ CDrawingDocument.prototype =
{
this.m_oWordControl = this;
this.Api = window.editor;
this.m_oApi = this.Api;
this.m_oApi.DocumentUrl = "";
this.LogicDocument = window.editor.WordControl.m_oLogicDocument;
this.LogicDocument.DrawingDocument = this;
},
......
......@@ -4939,12 +4939,12 @@ asc_docs_api.prototype["Native_Editor_Initialize_Settings"] = function(_params)
asc_docs_api.prototype.Call_Menu_Context_Copy = function()
{
var oCopyProcessor = new CopyProcessor(this, null, true);
var _binaty_data = oCopyProcessor.getSelectedBinary();
var _binary_data = oCopyProcessor.getSelectedBinary();
var _stream = global_memory_stream_menu;
_stream["ClearNoAttack"]();
if (!_binaty_data)
if (!_binary_data)
{
_stream["WriteByte"](255);
return _stream;
......@@ -4963,20 +4963,24 @@ asc_docs_api.prototype.Call_Menu_Context_Copy = function()
// owner format
_stream["WriteByte"](2);
_stream["WriteStringA"](_binaty_data.sBase64);
_stream["WriteStringA"](_binary_data.sBase64);
_stream["WriteByte"](255);
return _stream;
};
asc_docs_api.prototype.Call_Menu_Context_Cut = function()
{
var oCopyProcessor = new CopyProcessor(this, null);
var _binaty_data = oCopyProcessor.getSelectedBinary();
var oCopyProcessor = new CopyProcessor(this, null, true);
var _binary_data = oCopyProcessor.getSelectedBinary();
this.WordControl.m_oLogicDocument.Create_NewHistoryPoint();
this.WordControl.m_oLogicDocument.Remove(1, true, true);
this.WordControl.m_oLogicDocument.Document_UpdateSelectionState();
var _stream = global_memory_stream_menu;
_stream["ClearNoAttack"]();
if (!_binaty_data)
if (!_binary_data)
{
_stream["WriteByte"](255);
return _stream;
......@@ -4995,14 +4999,9 @@ asc_docs_api.prototype.Call_Menu_Context_Cut = function()
// owner format
_stream["WriteByte"](2);
_stream["WriteStringA"](_binaty_data.sBase64);
_stream["WriteStringA"](_binary_data.sBase64);
_stream["WriteByte"](255);
this.WordControl.m_oLogicDocument.Create_NewHistoryPoint();
this.WordControl.m_oLogicDocument.Remove(1, true, true);
this.WordControl.m_oLogicDocument.Document_UpdateSelectionState();
return _stream;
};
asc_docs_api.prototype.Call_Menu_Context_Paste = function(type, param)
......@@ -5039,4 +5038,18 @@ asc_docs_api.prototype.Call_Menu_Context_SelectAll = function()
{
this.WordControl.m_oLogicDocument.Select_All();
};
/************************************************************************/
\ No newline at end of file
asc_docs_api.prototype.pre_Paste = function(_fonts, _images, callback)
{
History.Create_NewPoint();
callback();
};
/************************************************************************/
window.NativeCorrectImageUrlOnPaste = function(url)
{
return url;
};
window.NativeCorrectImageUrlOnCopy = function(url)
{
return url;
};
\ No newline at end of file
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