Commit 480025b3 authored by Dmitry.Vikulov's avatar Dmitry.Vikulov Committed by Alexander.Trofimov

GlobalLoaders.js берётся из Excel\model\DrawingObjects\

git-svn-id: svn://192.168.3.15/activex/AVS/Sources/TeamlabOffice/trunk/OfficeWeb@47874 954022d7-b5bf-4e40-9824-e11837661b57
parent 6842ff91
......@@ -32,7 +32,6 @@
"../Word/Drawing/Graphics.js",
"../Word/Drawing/Metafile.js",
"../Word/Drawing/AllFonts.js",
"../Word/Drawing/GlobalLoaders.js",
"../Common/FontsFreeType/FontExport.js",
"../Excel/offlinedocs/test-workbook9/Editor.js",
"../Excel/offlinedocs/empty-workbook.js",
......@@ -129,6 +128,7 @@
"../Excel/model/DrawingObjects/Graphics.js",
"../Excel/model/DrawingObjects/Overlay.js",
"../Excel/model/DrawingObjects/GlobalCounters.js",
"../Excel/model/DrawingObjects/GlobalLoaders.js",
"../Excel/model/DrawingObjects/DrawingDocument.js",
"../Word/apiCommon.js",
"../Excel/.build/Log/apiCommonExport.js",
......
......@@ -3256,52 +3256,52 @@ function DrawingObjects() {
if ( !_image.Image ) {
worksheet.model.workbook.handlers.trigger("asc_onError", c_oAscError.ID.UplImageUrl, c_oAscError.Level.NoCritical);
return;
}
var obj = _this.createDrawingObject();
obj.id = generateId();
obj.worksheet = worksheet;
obj.from.col = isOption ? options.cell.col : worksheet.getSelectedColumnIndex();
obj.from.row = isOption ? options.cell.row : worksheet.getSelectedRowIndex();
var headerTop = worksheet.getCellTop(0, 0);
var headerLeft = worksheet.getCellLeft(0, 0);
// Проверяем начальные координаты при вставке
while ( !worksheet.cols[obj.from.col] ) {
worksheet.expandColsOnScroll(true);
}
worksheet.expandColsOnScroll(true); // для colOff
while ( !worksheet.rows[obj.from.row] ) {
worksheet.expandRowsOnScroll(true);
else {
var obj = _this.createDrawingObject();
obj.id = generateId();
obj.worksheet = worksheet;
obj.from.col = isOption ? options.cell.col : worksheet.getSelectedColumnIndex();
obj.from.row = isOption ? options.cell.row : worksheet.getSelectedRowIndex();
var headerTop = worksheet.getCellTop(0, 0);
var headerLeft = worksheet.getCellLeft(0, 0);
// Проверяем начальные координаты при вставке
while ( !worksheet.cols[obj.from.col] ) {
worksheet.expandColsOnScroll(true);
}
worksheet.expandColsOnScroll(true); // для colOff
while ( !worksheet.rows[obj.from.row] ) {
worksheet.expandRowsOnScroll(true);
}
worksheet.expandRowsOnScroll(true); // для rowOff
calculateObjectMetrics(obj, isOption ? options.width : _image.Image.width, isOption ? options.height : _image.Image.height);
var x = pxToMm(obj.getVisibleLeftOffset() + headerLeft);
var y = pxToMm(obj.getVisibleTopOffset() + headerTop);
var w = pxToMm(obj.getWidthFromTo());
var h = pxToMm(obj.getHeightFromTo());
// CImage
obj.graphicObject = new CImage(obj, _this);
obj.graphicObject.initDefault( x, y, w, h, _image.Image.src );
obj.graphicObject.select(_this.controller);
aObjects.push(obj);
worksheet.autoFilters.drawAutoF(worksheet);
worksheet.cellCommentator.drawCommentCells(false);
_this.showDrawingObjects(false);
// History.Create_NewPoint();
// History.Add(g_oUndoRedoDrawingObject, historyitem_DrawingObject_Add, worksheet.model.getId(), null, obj);
_this.lockDrawingObject(obj.id, bPackage ? false : true, bPackage ? false : true);
}
worksheet.expandRowsOnScroll(true); // для rowOff
calculateObjectMetrics(obj, isOption ? options.width : _image.Image.width, isOption ? options.height : _image.Image.height);
var x = pxToMm(obj.getVisibleLeftOffset() + headerLeft);
var y = pxToMm(obj.getVisibleTopOffset() + headerTop);
var w = pxToMm(obj.getWidthFromTo());
var h = pxToMm(obj.getHeightFromTo());
// CImage
obj.graphicObject = new CImage(obj, _this);
obj.graphicObject.initDefault( x, y, w, h, _image.Image.src );
obj.graphicObject.select(_this.controller);
aObjects.push(obj);
worksheet.autoFilters.drawAutoF(worksheet);
worksheet.cellCommentator.drawCommentCells(false);
_this.showDrawingObjects(false);
// History.Create_NewPoint();
// var copyObject = _this.cloneDrawingObject(obj);
// History.Add(g_oUndoRedoDrawingObject, historyitem_DrawingObject_Add, worksheet.model.getId(), null, copyObject);
_this.lockDrawingObject(obj.id, bPackage ? false : true, bPackage ? false : true);
worksheet.model.workbook.handlers.trigger("asc_onEndAction", c_oAscAsyncActionType.BlockInteraction, c_oAscAsyncAction.LoadImage);
}
......
......@@ -120,7 +120,7 @@
<script type="text/javascript" src="../../../../OfficeWeb/Word/Drawing/Externals.js"></script>
<script type="text/javascript" src="../../../../OfficeWeb/Word/Drawing/Metafile.js"></script>
<script type="text/javascript" src="../../../../OfficeWeb/Word/Drawing/AllFonts.js"></script>
<script type="text/javascript" src="../../../../OfficeWeb/Word/Drawing/GlobalLoaders.js"></script>
<!--<script type="text/javascript" src="../../../../OfficeWeb/Word/Drawing/GlobalLoaders.js"></script>-->
<script type="text/javascript" src="../../../../OfficeWeb/Excel/utils/utils.js"></script>
<script type="text/javascript" src="../../../../OfficeWeb/Excel/model/ConditionalFormatting.js"></script>
......@@ -227,6 +227,7 @@
<script src="../../../../OfficeWeb/Excel/model/DrawingObjects/DrawingObjectsController.js"></script>
<script src="../../../../OfficeWeb/Excel/model/DrawingObjects/DrawingDocument.js"></script>
<script src="../../../../OfficeWeb/Excel/model/DrawingObjects/States.js"></script>
<script src="../../../../OfficeWeb/Excel/model/DrawingObjects/GlobalLoaders.js"></script>
<script src="../../../../OfficeWeb/Excel/model/DrawingObjects/Format/GroupShape.js"></script>
<script src="../../../../OfficeWeb/Excel/model/DrawingObjects/Format/Image.js"></script>
......
This diff is collapsed.
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