11/*!
22 * ====================================================
3- * kityminder - v1.4.37 - 2017-03-23
3+ * kityminder - v1.4.38 - 2017-04-10
44 * https://github.com/fex-team/kityminder-core
55 * GitHub: https://github.com/fex-team/kityminder-core.git
66 * Copyright (c) 2017 Baidu FEX; Licensed MIT
@@ -1969,7 +1969,7 @@ _p[19] = {
19691969 this . fire ( "finishInitHook" ) ;
19701970 }
19711971 } ) ;
1972- Minder . version = "1.4.37 " ;
1972+ Minder . version = "1.4.38 " ;
19731973 Minder . registerInitHook = function ( hook ) {
19741974 _initHooks . push ( hook ) ;
19751975 } ;
@@ -2311,7 +2311,7 @@ _p[21] = {
23112311 return this . rc ;
23122312 } ,
23132313 getCommonAncestor : function ( node ) {
2314- return MinderNode . getNodeCommonAncestor ( this , node ) ;
2314+ return MinderNode . getCommonAncestor ( this , node ) ;
23152315 } ,
23162316 contains : function ( node ) {
23172317 return this == node || this . isAncestorOf ( node ) ;
@@ -3041,6 +3041,8 @@ _p[27] = {
30413041 renderer . getRenderShape ( ) . setVisible ( false ) ;
30423042 lastBoxes [ j ] = null ;
30433043 }
3044+ // 更新 render 的 contentBox
3045+ renderer . contentBox = lastBoxes [ j ] ;
30443046 }
30453047 }
30463048 for ( j = 0 ; j < nodes . length ; j ++ ) {
@@ -6302,7 +6304,7 @@ _p[55] = {
63026304 var BACK_PATH = "M0,13c0,3.866,3.134,7,7,7h6c3.866,0,7-3.134,7-7V7H0V13z" ;
63036305 var MASK_PATH = "M20,10c0,3.866-3.134,7-7,7H7c-3.866,0-7-3.134-7-7V7c0-3.866,3.134-7,7-7h6c3.866,0,7,3.134,7,7V10z" ;
63046306 var PRIORITY_DATA = "priority" ;
6305- // 进度图标的图形
6307+ // 优先级图标的图形
63066308 var PriorityIcon = kity . createClass ( "PriorityIcon" , {
63076309 base : kity . Group ,
63086310 constructor : function ( ) {
@@ -8088,8 +8090,8 @@ _p[65] = {
80888090 url : imageUrl ,
80898091 width : imageSize . width ,
80908092 height : imageSize . height ,
8091- x : - renderContainer . getBoundaryBox ( ) . x + imageRenderBox . x + 20 ,
8092- y : - renderContainer . getBoundaryBox ( ) . y + imageRenderBox . y + 20
8093+ x : - renderContainer . getBoundaryBox ( ) . x + imageRenderBox . x ,
8094+ y : - renderContainer . getBoundaryBox ( ) . y + imageRenderBox . y
80938095 } ;
80948096 imagesInfo . push ( imageInfo ) ;
80958097 }
@@ -8132,9 +8134,9 @@ _p[65] = {
81328134 }
81338135 function drawImage ( ctx , image , x , y , width , height ) {
81348136 if ( width && height ) {
8135- ctx . drawImage ( image , x , y , width , height ) ;
8137+ ctx . drawImage ( image , x + padding , y + padding , width , height ) ;
81368138 } else {
8137- ctx . drawImage ( image , x , y ) ;
8139+ ctx . drawImage ( image , x + padding , y + padding ) ;
81388140 }
81398141 }
81408142 function generateDataUrl ( canvas ) {
@@ -8156,7 +8158,7 @@ _p[65] = {
81568158 return loadImages ( imagesInfo ) ;
81578159 } ) . then ( function ( $images ) {
81588160 for ( var i = 0 ; i < $images . length ; i ++ ) {
8159- drawImage ( ctx , $images [ i ] . element , $images [ i ] . x , $images [ i ] . y , $images [ i ] . width , $images [ i ] . height ) ;
8161+ drawImage ( ctx , $images [ i ] . element , $images [ i ] . x + offsetX , $images [ i ] . y + offsetY , $images [ i ] . width , $images [ i ] . height ) ;
81608162 }
81618163 DomURL . revokeObjectURL ( svgDataUrl ) ;
81628164 document . body . appendChild ( canvas ) ;
0 commit comments