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

git-svn-id:...

git-svn-id: svn://192.168.3.15/activex/AVS/Sources/TeamlabOffice/trunk/OfficeWeb@55014 954022d7-b5bf-4e40-9824-e11837661b57
parent 40981881
......@@ -5729,14 +5729,8 @@ function CStylesPainter()
this.mergedStyles = null;
this.STYLE_THUMBNAIL_WIDTH = 80;
this.STYLE_THUMBNAIL_HEIGHT = 40;
if (window["flat_desine"] === true)
{
this.STYLE_THUMBNAIL_WIDTH = 109;
this.STYLE_THUMBNAIL_HEIGHT = 45;
}
this.STYLE_THUMBNAIL_WIDTH = GlobalSkin.STYLE_THUMBNAIL_WIDTH;
this.STYLE_THUMBNAIL_HEIGHT = GlobalSkin.STYLE_THUMBNAIL_HEIGHT;
this.CurrentTranslate = null;
this.IsRetinaEnabled = false;
......@@ -6028,18 +6022,19 @@ function CStylesPainter()
var y = index * dKoefToMM * this.STYLE_THUMBNAIL_HEIGHT;
var b = (index + 1) * dKoefToMM * this.STYLE_THUMBNAIL_HEIGHT;
var w = dKoefToMM * this.STYLE_THUMBNAIL_WIDTH;
var off = 10 * dKoefToMM;
graphics.transform(1,0,0,1,0,0);
graphics.save();
graphics._s();
graphics._m(0, y);
graphics._l(w, y);
graphics._l(w, b);
graphics._l(0, b);
graphics._m(off, y);
graphics._l(w - off, y);
graphics._l(w - off, b);
graphics._l(off, b);
graphics._z();
graphics.clip();
graphics.t(style.Name, 0.5, y + 0.75 * (b - y));
graphics.t(style.Name, off + 0.5, y + 0.75 * (b - y));
graphics.restore();
}
......
......@@ -44,7 +44,24 @@ if (AscBrowser.isIE || window.opera)
}
}
var global_style_color = "#B0B0B0";
var GlobalSkinTeamlab = {
BackgroundColor : "#B0B0B0",
RulerDark : "#B0B0B0",
RulerLight : "EDEDED",
BackgroundScroll : "#D3D3D3",
STYLE_THUMBNAIL_WIDTH : 80,
STYLE_THUMBNAIL_HEIGHT : 40
};
var GlobalSkinFlat = {
BackgroundColor : "#F4F4F4",
RulerDark : "#E5E5E5",
RulerLight : "#F4F4F4",
BackgroundScroll : "#E5E5E5",
STYLE_THUMBNAIL_WIDTH : 109,
STYLE_THUMBNAIL_HEIGHT : 45
};
var GlobalSkin = GlobalSkinTeamlab;
function CEditorPage(api)
{
......@@ -2455,7 +2472,7 @@ function CEditorPage(api)
var settings = {
showArrows: true,
animateScroll: false,
scrollBackgroundColor:"#D3D3D3",
scrollBackgroundColor: GlobalSkin.BackgroundScroll,
scrollerColor:"#EDEDED",
screenW: this.m_oEditor.HtmlElement.width,
screenH: this.m_oEditor.HtmlElement.height,
......@@ -3033,7 +3050,7 @@ function CEditorPage(api)
return;
var context = canvas.getContext("2d");
context.fillStyle = global_style_color;
context.fillStyle = GlobalSkin.BackgroundColor;
//this.m_oBoundsController.Clear(context);
// сначала посморим, изменились ли ректы страниц
......
......@@ -416,7 +416,7 @@ function CHorRuler()
else
context.setTransform(2, 0, 0, 2, 10, 0);
context.fillStyle = global_style_color;
context.fillStyle = GlobalSkin.BackgroundColor;
context.fillRect(0, 0, this.m_oCanvas.width, this.m_oCanvas.height);
// ���������� ����� ���������
......@@ -468,11 +468,21 @@ function CHorRuler()
}
}
context.fillStyle = "#EDEDED";
context.fillStyle = GlobalSkin.RulerLight;
context.fillRect(left_margin + 0.5, this.m_nTop + 0.5, right_margin - left_margin, this.m_nBottom - this.m_nTop);
var intW = width >> 0;
if (window["flat_desine"] === true)
{
context.beginPath();
context.fillStyle = GlobalSkin.RulerDark;
context.fillRect(0.5, this.m_nTop + 0.5, left_margin, this.m_nBottom - this.m_nTop);
context.fillRect(right_margin + 0.5, this.m_nTop + 0.5, Math.max(intW - right_margin, 1), this.m_nBottom - this.m_nTop);
context.beginPath();
}
// �����
//context.shadowBlur = 0;
//context.shadowColor = "#81878F";
......@@ -599,7 +609,7 @@ function CHorRuler()
var _count = markup.Cols.length;
if (0 != _count)
{
context.fillStyle = global_style_color;
context.fillStyle = GlobalSkin.RulerDark;
context.strokeStyle = "#929292";
var _offset = markup.X;
......@@ -1948,7 +1958,7 @@ function CVerRuler()
else
context.setTransform(2, 0, 0, 2, 0, 10);
context.fillStyle = global_style_color;
context.fillStyle = GlobalSkin.BackgroundColor;
context.fillRect(0, 0, this.m_oCanvas.width, this.m_oCanvas.height);
var top_margin = 0;
......@@ -1998,12 +2008,22 @@ function CVerRuler()
if (bottom_margin > top_margin)
{
context.fillStyle = "#EDEDED";
context.fillStyle = GlobalSkin.RulerLight;
context.fillRect(this.m_nLeft + 0.5, top_margin + 0.5, this.m_nRight - this.m_nLeft, bottom_margin - top_margin);
}
var intH = height >> 0;
if (window["flat_desine"] === true)
{
context.beginPath();
context.fillStyle = GlobalSkin.RulerDark;
context.fillRect(this.m_nLeft + 0.5, 0.5, this.m_nRight - this.m_nLeft, top_margin);
context.fillRect(this.m_nLeft + 0.5, bottom_margin + 0.5, this.m_nRight - this.m_nLeft, Math.max(intH - bottom_margin, 1));
context.beginPath();
}
// �����
context.strokeStyle = "#929292";
......
......@@ -1089,7 +1089,7 @@ asc_docs_api.prototype.CreateCSS = function()
{
if (window["flat_desine"] === true)
{
global_style_color = "#CBCBCB";
GlobalSkin = GlobalSkinFlat;
}
var _head = document.getElementsByTagName('head')[0];
......@@ -1120,7 +1120,7 @@ background-repeat: no-repeat;\
var style3 = document.createElement('style');
style3.type = 'text/css';
style3.innerHTML = ".buttonPrevPage {\
background-image: url(data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAABAAAABgCAYAAAAU0fKgAAAABGdBTUEAALGPC/xhBQAAAAlwSFlzAAAOxAAADsQBlSsOGwAAABh0RVh0U29mdHdhcmUAUGFpbnQuTkVUIHYzLjMxN4N3hgAAAUlJREFUWEftWEEKwjAQTMVX9Su9ivgDEaGUgojXnES89iv9QB+kNLIgcXa3sqIlxlOQnTGz2UwGi2EYbs7wWRiwAZo6Qd20aovYHhBYI4EEMUgiKaQ5GIFtU4syZi5BPYI/mMQpPSi89yY/CARVVU35sZearuuS94PVeqP2hr1MBNZIIEEMkkiWaI/Xyzl8PQJpzWn5vYQ8ic6Zr7P5dQ47KMtSnXlU0Pd98n5wOJ7U3rCnQGCNBBLEIIkE+sF+tw1bH4G0ftsPviYhT+IH/EDMieoc55AVWgSbiNI5F7rhdY6LpcTOGgqBtLifqoQpI0w15rcxAQJzwMgpzTn4uKJ0zoVuOEhxsZTY2UkkkBb3VQkkZ74SxNuo6U/knyzzdTZbWk5pjB+gdM6FbngKcbGU2NljJJAW96EfPEug9XwliKOs6c9+8EhJd/Clu/4I7OgqAAAAAElFTkSuQmCC);\
background-image: url(data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAABAAAABgCAYAAAAU0fKgAAAABGdBTUEAALGPC/xhBQAAAAlwSFlzAAAOwwAADsMBx2+oZAAAABp0RVh0U29mdHdhcmUAUGFpbnQuTkVUIHYzLjUuMTAw9HKhAAABU0lEQVRYR+XWQW6DQBBEUV8xinwxzsWOc3AGoorUUgv9qZ4Gr/DiZVFQxSwg8mvbtlsw7MCwA8MODDswDD+/74PyDENROdD1gGEuVyMYBlcMGMrM0wXDXK5GMOzAsAPDDgw7MOx4Lcty3PE/sO/7Jd8woFeY8mAH8ndA12U4kMtuxJ5ARsVgB6qny3Agl92IPcGMJw3c8ZmBdV0v+YYBvcKUBzuQvwO6LsOBXHYj9gQyKgY7UD1dhgO57EbsCWY8aeAO/NHQgWEHhh0YdmDYgSG9ynSfYCgzZcEwVGXBMD890H2CocyUBcNQlQXDDgw7MOzAsAPDjvv/UPSHfr7MePJA/g7C+R6xJ6jKYgfElWU4kJ8ezveIPUFVFjsgrizlQOVJA3d8ZoB+vsx48kD+DsL5HrEnqMpiB8SVZTiQnx7O94g9QVUWOyCuLOVA5UkD1y3HHxBw7VBakRjXAAAAAElFTkSuQmCC);\
background-position: 0px 0px;\
background-repeat: no-repeat;\
}";
......@@ -1129,7 +1129,7 @@ background-repeat: no-repeat;\
var style4 = document.createElement('style');
style4.type = 'text/css';
style4.innerHTML = ".buttonNextPage {\
background-image: url(data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAABAAAABgCAYAAAAU0fKgAAAABGdBTUEAALGPC/xhBQAAAAlwSFlzAAAOxAAADsQBlSsOGwAAABh0RVh0U29mdHdhcmUAUGFpbnQuTkVUIHYzLjMxN4N3hgAAAUlJREFUWEftWEEKwjAQTMVX9Su9ivgDEaGUgojXnES89iv9QB+kNLIgcXa3sqIlxlOQnTGz2UwGi2EYbs7wWRiwAZo6Qd20aovYHhBYI4EEMUgiKaQ5GIFtU4syZi5BPYI/mMQpPSi89yY/CARVVU35sZearuuS94PVeqP2hr1MBNZIIEEMkkiWaI/Xyzl8PQJpzWn5vYQ8ic6Zr7P5dQ47KMtSnXlU0Pd98n5wOJ7U3rCnQGCNBBLEIIkE+sF+tw1bH4G0ftsPviYhT+IH/EDMieoc55AVWgSbiNI5F7rhdY6LpcTOGgqBtLifqoQpI0w15rcxAQJzwMgpzTn4uKJ0zoVuOEhxsZTY2UkkkBb3VQkkZ74SxNuo6U/knyzzdTZbWk5pjB+gdM6FbngKcbGU2NljJJAW96EfPEug9XwliKOs6c9+8EhJd/Clu/4I7OgqAAAAAElFTkSuQmCC);\
background-image: url(data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAABAAAABgCAYAAAAU0fKgAAAABGdBTUEAALGPC/xhBQAAAAlwSFlzAAAOwwAADsMBx2+oZAAAABp0RVh0U29mdHdhcmUAUGFpbnQuTkVUIHYzLjUuMTAw9HKhAAABU0lEQVRYR+XWQW6DQBBEUV8xinwxzsWOc3AGoorUUgv9qZ4Gr/DiZVFQxSwg8mvbtlsw7MCwA8MODDswDD+/74PyDENROdD1gGEuVyMYBlcMGMrM0wXDXK5GMOzAsAPDDgw7MOx4Lcty3PE/sO/7Jd8woFeY8mAH8ndA12U4kMtuxJ5ARsVgB6qny3Agl92IPcGMJw3c8ZmBdV0v+YYBvcKUBzuQvwO6LsOBXHYj9gQyKgY7UD1dhgO57EbsCWY8aeAO/NHQgWEHhh0YdmDYgSG9ynSfYCgzZcEwVGXBMD890H2CocyUBcNQlQXDDgw7MOzAsAPDjvv/UPSHfr7MePJA/g7C+R6xJ6jKYgfElWU4kJ8ezveIPUFVFjsgrizlQOVJA3d8ZoB+vsx48kD+DsL5HrEnqMpiB8SVZTiQnx7O94g9QVUWOyCuLOVA5UkD1y3HHxBw7VBakRjXAAAAAElFTkSuQmCC);\
background-position: 0px -48px;\
background-repeat: no-repeat;\
}";
......@@ -1142,7 +1142,7 @@ asc_docs_api.prototype.CreateComponents = function()
var element = document.getElementById(this.HtmlElementName);
if (element != null)
element.innerHTML = "<div id=\"id_main\" class=\"block_elem\" style=\"-moz-user-select:none;-khtml-user-select:none;user-select:none;background-color:" + global_style_color + ";overflow:hidden;\" UNSELECTABLE=\"on\">\
element.innerHTML = "<div id=\"id_main\" class=\"block_elem\" style=\"-moz-user-select:none;-khtml-user-select:none;user-select:none;background-color:" + GlobalSkin.BackgroundColor + ";overflow:hidden;\" UNSELECTABLE=\"on\">\
<div id=\"id_panel_left\" class=\"block_elem\">\
<div id=\"id_buttonTabs\" class=\"block_elem buttonTabs\"></div>\
<canvas id=\"id_vert_ruler\" class=\"block_elem\"></canvas>\
......@@ -1151,12 +1151,12 @@ asc_docs_api.prototype.CreateComponents = function()
<canvas id=\"id_hor_ruler\" class=\"block_elem\"></canvas>\
</div>\
<div id=\"id_main_view\" class=\"block_elem\" style=\"overflow:hidden\">\
<canvas id=\"id_viewer\" class=\"block_elem\" style=\"background-color:" + global_style_color + ";z-index:1\"></canvas>\
<canvas id=\"id_viewer\" class=\"block_elem\" style=\"background-color:" + GlobalSkin.BackgroundColor + ";z-index:1\"></canvas>\
<canvas id=\"id_viewer_overlay\" class=\"block_elem\" style=\"z-index:2\"></canvas>\
<canvas id=\"id_target_cursor\" class=\"block_elem\" width=\"1\" height=\"1\" style=\"width:2px;height:13px;display:none;z-index:3;\"></canvas>\
</div>\
</div>\
<div id=\"id_panel_right\" class=\"block_elem\" style=\"margin-right:1px;background-color:" + global_style_color + ";\">\
<div id=\"id_panel_right\" class=\"block_elem\" style=\"margin-right:1px;background-color:" + GlobalSkin.BackgroundScroll + ";\">\
<div id=\"id_buttonRulers\" class=\"block_elem buttonRuler\"></div>\
<div id=\"id_vertical_scroll\" style=\"left:0;top:0;width:16px;overflow:hidden;position:absolute;\">\
<div id=\"panel_right_scroll\" class=\"block_elem\" style=\"left:0;top:0;width:16px;height:6000px;\"></div>\
......@@ -1164,7 +1164,7 @@ asc_docs_api.prototype.CreateComponents = function()
<div id=\"id_buttonPrevPage\" class=\"block_elem buttonPrevPage\"></div>\
<div id=\"id_buttonNextPage\" class=\"block_elem buttonNextPage\"></div>\
</div>\
<div id=\"id_horscrollpanel\" class=\"block_elem\" style=\"margin-bottom:1px;background-color:" + global_style_color + ";\">\
<div id=\"id_horscrollpanel\" class=\"block_elem\" style=\"margin-bottom:1px;background-color:" + GlobalSkin.BackgroundScroll + ";\">\
<div id=\"id_horizontal_scroll\" style=\"left:0;top:0;height:16px;overflow:hidden;position:absolute;width:100%;\">\
<div id=\"panel_hor_scroll\" class=\"block_elem\" style=\"left:0;top:0;width:6000px;height:16px;\"></div>\
</div>\
......
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