MPopupForm.js 24 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623624625626627628629630631632633634635636637638639640641642643644645646647648649
  1. var MPopupForm = new Class({
  2. Extends: MWF.widget.Common,
  3. Implements: [Options, Events],
  4. options: {
  5. "style": "default",
  6. "width": 500,
  7. "height": 450,
  8. "top": null,
  9. "left": null,
  10. "bottom" : null,
  11. "right" : null,
  12. "minWidth" : 300,
  13. "minHeight" : 220,
  14. "isLimitSize": true,
  15. "ifFade": true,
  16. "hasTop": false,
  17. "hasTopIcon" : false,
  18. "hasTopContent" : false,
  19. "hasIcon": true,
  20. "hasScroll" : true,
  21. "hasBottom": true,
  22. "hasMask" : true,
  23. "closeByClickMask" : false,
  24. "title": "",
  25. "draggable": false,
  26. "resizeable" : false,
  27. "maxAction" : false,
  28. "closeAction": true,
  29. "relativeToApp" : true,
  30. "sizeRelateTo" : "app", //desktop
  31. "resultSeparator" : ","
  32. },
  33. initialize: function (explorer, data, options, para) {
  34. debugger;
  35. this.setOptions(options);
  36. this.explorer = explorer;
  37. if( para ){
  38. if( this.options.relativeToApp ){
  39. this.app = para.app || this.explorer.app;
  40. this.container = para.container || this.app.content;
  41. this.lp = para.lp || this.explorer.lp || this.app.lp;
  42. this.css = para.css || this.explorer.css || this.app.css;
  43. this.actions = para.actions || this.explorer.actions || this.app.actions || this.app.restActions;
  44. }else{
  45. this.container = para.container;
  46. this.lp = para.lp || this.explorer.lp;
  47. this.css = para.css || this.explorer.css;
  48. this.actions = para.actions || this.explorer.actions;
  49. }
  50. }else{
  51. if( this.options.relativeToApp ){
  52. this.app = this.explorer.app;
  53. this.container = this.app.content;
  54. this.lp = this.explorer.lp || this.app.lp;
  55. this.css = this.explorer.css || this.app.css;
  56. this.actions = this.explorer.actions || this.app.actions || this.app.restActions;
  57. }else{
  58. this.container = window.document.body;
  59. this.lp = this.explorer.lp;
  60. this.css = this.explorer.css;
  61. this.actions = this.explorer.actions;
  62. }
  63. }
  64. this.data = data || {};
  65. this.cssPath = "/x_component_Template/$MPopupForm/"+this.options.style+"/css.wcss";
  66. this.load();
  67. },
  68. load: function () {
  69. this._loadCss();
  70. },
  71. _loadCss: function(){
  72. var css = {};
  73. var r = new Request.JSON({
  74. url: this.cssPath,
  75. secure: false,
  76. async: false,
  77. method: "get",
  78. noCache: false,
  79. onSuccess: function(responseJSON, responseText){
  80. css = responseJSON;
  81. MWF.widget.css[key] = responseJSON;
  82. }.bind(this),
  83. onError: function(text, error){
  84. alert(error + text);
  85. }
  86. });
  87. r.send();
  88. var isEmptyObject = true;
  89. for( var key in css ){
  90. if(key){
  91. isEmptyObject = false;
  92. break;
  93. }
  94. }
  95. if( !isEmptyObject ){
  96. this.css = Object.merge( css, this.css );
  97. }
  98. },
  99. reload : function( keepData ){
  100. if( keepData ){
  101. this.data = this.form.getResult(false, this.options.resultSeparator, false, false, true);
  102. }
  103. this.formTopNode = null;
  104. if(this.setFormNodeSizeFun && this.app ){
  105. this.app.removeEvent("resize",this.setFormNodeSizeFun);
  106. }
  107. if( this.formMaskNode )this.formMaskNode.destroy();
  108. this.formAreaNode.destroy();
  109. if( this.isNew ){
  110. this.create();
  111. }else if( this.isEdited ){
  112. this.edit();
  113. }else{
  114. this.open();
  115. }
  116. },
  117. open: function (e) {
  118. this.fireEvent("queryOpen");
  119. this.isNew = false;
  120. this.isEdited = false;
  121. this._open();
  122. this.fireEvent("postOpen");
  123. },
  124. create: function () {
  125. this.fireEvent("queryCreate");
  126. this.isNew = true;
  127. this._open();
  128. this.fireEvent("postCreate");
  129. },
  130. edit: function () {
  131. this.fireEvent("queryEdit");
  132. this.isEdited = true;
  133. this._open();
  134. this.fireEvent("postEdit");
  135. },
  136. _open: function () {
  137. if( this.options.hasMask ){
  138. this.formMaskNode = new Element("div.formMaskNode", {
  139. "styles": this.css.formMaskNode,
  140. "events": {
  141. "mouseover": function (e) {
  142. e.stopPropagation();
  143. },
  144. "mouseout": function (e) {
  145. e.stopPropagation();
  146. },
  147. "click": function (e) {
  148. e.stopPropagation();
  149. }
  150. }
  151. }).inject( this.container || this.app.content);
  152. }
  153. this.formAreaNode = new Element("div.formAreaNode", {
  154. "styles": this.css.formAreaNode
  155. });
  156. this.createFormNode();
  157. if( this.formMaskNode ){
  158. this.formAreaNode.inject(this.formMaskNode , "after");
  159. }else{
  160. this.formAreaNode.inject( this.container || this.app.content );
  161. }
  162. if (this.options.ifFade){
  163. this.formAreaNode.fade("in");
  164. }else{
  165. this.formAreaNode.setStyle("opacity", 1);
  166. }
  167. this.setFormNodeSize();
  168. this.setFormNodeSizeFun = this.setFormNodeSize.bind(this);
  169. if( this.app )this.app.addEvent("resize", this.setFormNodeSizeFun);
  170. if (this.options.draggable && this.formTopNode) {
  171. var size = (this.container || this.app.content).getSize();
  172. var nodeSize = this.formAreaNode.getSize();
  173. this.formAreaNode.makeDraggable({
  174. "handle": this.formTopNode,
  175. "limit": {
  176. "x": [0, size.x - nodeSize.x],
  177. "y": [0, size.y - nodeSize.y]
  178. },
  179. "onDrag": function(){
  180. this.fireEvent("drag");
  181. }.bind(this),
  182. "onComplete": function(){
  183. this.fireEvent("dragCompleted");
  184. }.bind(this)
  185. });
  186. }
  187. if( this.options.closeByClickMask && this.formMaskNode ){
  188. this.formMaskNode.addEvent("click", function(e){
  189. this.close(e)
  190. }.bind(this));
  191. }
  192. if (this.options.resizeable){
  193. this.resizeNode = new Element("div.resizeNode", {
  194. "styles": this.css.resizeNode
  195. }).inject(this.formNode);
  196. this.formAreaNode.makeResizable({
  197. "handle": this.resizeNode,
  198. "limit": {x:[ this.options.minWidth, null], y:[this.options.minHeight, null]},
  199. "onDrag": function(){
  200. var size = this.formAreaNode.getComputedSize();
  201. this.setNodesSize( size.width, size.height );
  202. this.fireEvent("resize");
  203. }.bind(this),
  204. "onComplete": function(){
  205. var size = this.formAreaNode.getComputedSize();
  206. this.options.width = size.width;
  207. this.options.height = size.height;
  208. if( this.oldCoordinate ){
  209. this.oldCoordinate.width = size.width;
  210. this.oldCoordinate.height = size.height;
  211. }
  212. this.fireEvent("resizeCompleted");
  213. }.bind(this)
  214. });
  215. }
  216. },
  217. createFormNode: function () {
  218. var _self = this;
  219. this.formNode = new Element("div.formNode", {
  220. "styles": this.css.formNode
  221. }).inject(this.formAreaNode);
  222. if (this.options.hasTop) {
  223. this.createTopNode();
  224. }
  225. if (this.options.hasIcon) {
  226. this.formIconNode = new Element("div.formIconNode", {
  227. "styles": this.isNew ? this.css.formNewNode : this.css.formIconNode
  228. }).inject(this.formNode);
  229. }
  230. this.createContent();
  231. //formContentNode.set("html", html);
  232. if (this.options.hasBottom) {
  233. this.createBottomNode();
  234. }
  235. this._setCustom();
  236. if( this.options.hasScroll ){
  237. //this.setScrollBar(this.formTableContainer)
  238. MWF.require("MWF.widget.ScrollBar", function () {
  239. new MWF.widget.ScrollBar(this.formTableContainer, {
  240. "indent": false,
  241. "style": "xApp_TaskList",
  242. "where": "before",
  243. "distance": 30,
  244. "friction": 4,
  245. "axis": {"x": false, "y": true},
  246. "onScroll": function (y) {
  247. //var scrollSize = _self.viewContainerNode.getScrollSize();
  248. //var clientSize = _self.viewContainerNode.getSize();
  249. //var scrollHeight = scrollSize.y - clientSize.y;
  250. //if (y + 200 > scrollHeight && _self.view && _self.view.loadElementList) {
  251. // if (!_self.view.isItemsLoaded) _self.view.loadElementList();
  252. //}
  253. }
  254. });
  255. }.bind(this));
  256. }
  257. },
  258. _setCustom : function(){
  259. },
  260. createTopNode: function () {
  261. this.fireEvent("queryCreateTop");
  262. if (!this.formTopNode) {
  263. this.formTopNode = new Element("div.formTopNode", {
  264. "styles": this.css.formTopNode
  265. }).inject(this.formNode);
  266. if(this.options.hasTopIcon){
  267. this.formTopIconNode = new Element("div", {
  268. "styles": this.css.formTopIconNode
  269. }).inject(this.formTopNode)
  270. }
  271. this.formTopTextNode = new Element("div", {
  272. "styles": this.css.formTopTextNode,
  273. "text": this.options.title
  274. }).inject(this.formTopNode);
  275. if (this.options.closeAction) {
  276. this.formTopCloseActionNode = new Element("div", {
  277. "styles": this.css.formTopCloseActionNode,
  278. "title" : "关闭"
  279. }).inject(this.formTopNode);
  280. this.formTopCloseActionNode.addEvent("click", function ( ev ) {
  281. this.close();
  282. ev.stopPropagation();
  283. }.bind(this))
  284. }
  285. if( this.options.maxAction ){
  286. this.formTopMaxActionNode = new Element("div", {
  287. "styles": this.css.formTopMaxActionNode,
  288. "title" : "最大化"
  289. }).inject(this.formTopNode);
  290. this.formTopMaxActionNode.addEvent("click", function () {
  291. this.maxSize()
  292. }.bind(this));
  293. this.formTopRestoreActionNode = new Element("div", {
  294. "styles": this.css.formTopRestoreActionNode,
  295. "title" : "还原"
  296. }).inject(this.formTopNode);
  297. this.formTopRestoreActionNode.addEvent("click", function () {
  298. this.restoreSize()
  299. }.bind(this));
  300. this.formTopNode.addEvent("dblclick", function(){
  301. this.switchMax();
  302. }.bind(this));
  303. }
  304. if(this.options.hasTopContent){
  305. this.formTopContentNode = new Element("div.formTopContentNode", {
  306. "styles": this.css.formTopContentNode
  307. }).inject(this.formTopNode);
  308. this._createTopContent();
  309. }
  310. }
  311. this.fireEvent("postCreateTop");
  312. //if (!this.formTopNode) {
  313. // this.formTopNode = new Element("div.formTopNode", {
  314. // "styles": this.css.formTopNode,
  315. // "text": this.options.title
  316. // }).inject(this.formNode);
  317. //
  318. // this._createTopContent();
  319. //
  320. // if (this.options.closeAction) {
  321. // this.formTopCloseActionNode = new Element("div.formTopCloseActionNode", {"styles": this.css.formTopCloseActionNode}).inject(this.formTopNode);
  322. // this.formTopCloseActionNode.addEvent("click", function () {
  323. // this.close()
  324. // }.bind(this))
  325. // }
  326. //}
  327. },
  328. _createTopContent: function () {
  329. },
  330. createContent: function () {
  331. this.formContentNode = new Element("div.formContentNode", {
  332. "styles": this.css.formContentNode
  333. }).inject(this.formNode);
  334. this.formTableContainer = new Element("div.formTableContainer", {
  335. "styles": this.css.formTableContainer
  336. }).inject(this.formContentNode);
  337. this.formTableArea = new Element("div.formTableArea", {
  338. "styles": this.css.formTableArea
  339. }).inject(this.formTableContainer);
  340. this._createTableContent();
  341. },
  342. _createTableContent: function () {
  343. var html = "<table width='100%' bordr='0' cellpadding='5' cellspacing='0' styles='formTable'>" +
  344. //"<tr><td colspan='2' styles='formTableHead'>申诉处理单</td></tr>" +
  345. "<tr><td styles='formTableTitle' lable='empName'></td>" +
  346. " <td styles='formTableValue' item='empName'></td></tr>" +
  347. "<tr><td styles='formTableTitle' lable='departmentName'></td>" +
  348. " <td styles='formTableValue' item='departmentName'></td></tr>" +
  349. "<tr><td styles='formTableTitle' lable='recordDateString'></td>" +
  350. " <td styles='formTableValue' item='recordDateString'></td></tr>" +
  351. "<tr><td styles='formTableTitle' lable='status'></td>" +
  352. " <td styles='formTableValue' item='status'></td></tr>" +
  353. "<tr><td styles='formTableTitle' lable='appealReason'></td>" +
  354. " <td styles='formTableValue' item='appealReason'></td></tr>" +
  355. "<tr><td styles='formTableTitle' lable='appealDescription'></td>" +
  356. " <td styles='formTableValue' item='appealDescription'></td></tr>" +
  357. "<tr><td styles='formTableTitle' lable='opinion1'></td>" +
  358. " <td styles='formTableValue' item='opinion1'></td></tr>" +
  359. "</table>";
  360. this.formTableArea.set("html", html);
  361. MWF.xDesktop.requireApp("Template", "MForm", function () {
  362. this.form = new MForm(this.formTableArea, {empName: "xadmin"}, {
  363. isEdited: this.isEdited || this.isNew,
  364. itemTemplate: {
  365. empName: {text: "姓名", type: "innertext"},
  366. departmentName: {text: "部门", tType: "department", notEmpty: true},
  367. recordDateString: {text: "日期", tType: "date"},
  368. status: {text: "状态", tType: "number"},
  369. appealReason: {
  370. text: "下拉框",
  371. type: "select",
  372. selectValue: ["测试1", "测试2"]
  373. },
  374. appealDescription: {text: "描述", type: "textarea"},
  375. opinion1: {text: "测试", type: "button", "value": "测试"}
  376. }
  377. }, this.app);
  378. this.form.load();
  379. }.bind(this), true);
  380. },
  381. createBottomNode: function () {
  382. this.fireEvent("queryCreateBottom");
  383. this.formBottomNode = new Element("div.formBottomNode", {
  384. "styles": this.css.formBottomNode
  385. }).inject(this.formNode);
  386. this._createBottomContent();
  387. this.fireEvent("postCreateBottom");
  388. },
  389. _createBottomContent: function () {
  390. this.cancelActionNode = new Element("div.formCancelActionNode", {
  391. "styles": this.css.formCancelActionNode,
  392. "text": this.lp.cancel
  393. }).inject(this.formBottomNode);
  394. this.cancelActionNode.addEvent("click", function (e) {
  395. this.cancel(e);
  396. }.bind(this));
  397. if (this.isNew || this.isEdited) {
  398. this.okActionNode = new Element("div.formOkActionNode", {
  399. "styles": this.css.formOkActionNode,
  400. "text": this.lp.ok
  401. }).inject(this.formBottomNode);
  402. this.okActionNode.addEvent("click", function (e) {
  403. this.ok(e);
  404. }.bind(this));
  405. }
  406. },
  407. cancel: function (e) {
  408. this.fireEvent("queryCancel");
  409. this.close();
  410. this.fireEvent("postCancel");
  411. },
  412. close: function (e) {
  413. this.fireEvent("queryClose");
  414. this._close();
  415. //if( this.form ){
  416. // this.form.destroy();
  417. //}
  418. if(this.setFormNodeSizeFun && this.app ){
  419. this.app.removeEvent("resize",this.setFormNodeSizeFun);
  420. }
  421. if( this.formMaskNode )this.formMaskNode.destroy();
  422. this.formAreaNode.destroy();
  423. this.fireEvent("postClose");
  424. delete this;
  425. },
  426. _close: function(){
  427. },
  428. ok: function (e) {
  429. this.fireEvent("queryOk");
  430. var data = this.form.getResult(true, this.options.resultSeparator, true, false, true);
  431. if (data) {
  432. this._ok(data, function (json) {
  433. if (json.type == "error") {
  434. if( this.app )this.app.notice(json.message, "error");
  435. } else {
  436. if( this.formMaskNode )this.formMaskNode.destroy();
  437. this.formAreaNode.destroy();
  438. if (this.explorer && this.explorer.view)this.explorer.view.reload();
  439. if( this.app )this.app.notice(this.isNew ? this.lp.createSuccess : this.lp.updateSuccess, "success");
  440. this.fireEvent("postOk");
  441. }
  442. }.bind(this))
  443. }
  444. },
  445. _ok: function (data, callback) {
  446. //this.app.restActions.saveDocument( this.data.id, data, function(json){
  447. // if( callback )callback(json);
  448. //}.bind(this), function( errorObj ){
  449. // var error = JSON.parse( errorObj.responseText );
  450. // this.app.notice( error.message, error );
  451. //}.bind(this));
  452. },
  453. switchMax : function(){
  454. if( !this.isMax ){
  455. this.maxSize();
  456. }else{
  457. this.restoreSize();
  458. }
  459. },
  460. maxSize: function(){
  461. if(!this.oldCoordinate)this.oldCoordinate = {
  462. width : this.options.width,
  463. height : this.options.height,
  464. top : this.options.top,
  465. left : this.options.left,
  466. bottom : this.options.bottom,
  467. right : this.options.right
  468. };
  469. this.options.width = "100%";
  470. this.options.height = "100%";
  471. this.options.top = null;
  472. this.options.left = null;
  473. this.options.bottom = null;
  474. this.options.right = null;
  475. this.setFormNodeSize();
  476. this.formTopMaxActionNode.setStyle("display","none");
  477. this.formTopRestoreActionNode.setStyle("display","");
  478. this.isMax = true;
  479. this.fireEvent("max");
  480. },
  481. restoreSize : function(){
  482. if( this.oldCoordinate){
  483. this.options.width = this.oldCoordinate.width;
  484. this.options.height = this.oldCoordinate.height;
  485. this.options.top = this.oldCoordinate.top;
  486. this.options.left = this.oldCoordinate.left;
  487. this.options.bottom = this.oldCoordinate.bottom;
  488. this.options.right = this.oldCoordinate.right;
  489. }
  490. this.setFormNodeSize();
  491. this.formTopMaxActionNode.setStyle("display","");
  492. this.formTopRestoreActionNode.setStyle("display","none");
  493. this.isMax = false;
  494. this.fireEvent("restore");
  495. },
  496. setFormNodeSize: function (width, height, top, left, bottom, right) {
  497. if (!width)width = this.options.width ? this.options.width : "50%";
  498. if (!height)height = this.options.height ? this.options.height : "50%";
  499. if (!top && top != 0 ) top = this.options.top; // ? this.options.top : 0;
  500. if (!left && left != 0) left = this.options.left; // ? this.options.left : 0;
  501. if (!bottom && bottom != 0) bottom = this.options.bottom; // ? this.options.bottom : 0;
  502. if (!right && right != 0) right = this.options.right; // ? this.options.right : 0;
  503. width = width.toString();
  504. height = height.toString();
  505. var allSize = ( this.container || this.app.content).getSize();
  506. var limitWidth = allSize.x; //window.screen.width
  507. var limitHeight = allSize.y; //window.screen.height
  508. if (this.options.isLimitSize){
  509. if( "%" != width.substr(width.length - 1, 1) ){
  510. if( allSize.x < parseInt(width) )width = allSize.x;
  511. }
  512. if( "%" != height.substr(height.length - 1, 1) ){
  513. if( allSize.y < parseInt(height) )height = allSize.y;
  514. }
  515. }
  516. "string" == typeof width && (1 < width.length && "%" == width.substr(width.length - 1, 1)) && (width = parseInt(limitWidth * parseInt(width, 10) / 100, 10));
  517. "string" == typeof height && (1 < height.length && "%" == height.substr(height.length - 1, 1)) && (height = parseInt(limitHeight * parseInt(height, 10) / 100, 10));
  518. this.options.minWidth > width && (width = this.options.minWidth);
  519. this.options.minHeight > height && (height = this.options.minHeight);
  520. var styles = {
  521. "width": "" + width + "px",
  522. "height": "" + height + "px"
  523. };
  524. if( top != null ){
  525. styles.top = "" + top + "px";
  526. styles.bottom = "auto";
  527. }else if( bottom != null ){
  528. styles.top = "auto";
  529. styles.bottom = "" + bottom + "px";
  530. }else{
  531. styles.top = "" + parseInt((limitHeight - height) / 2, 10) + "px";
  532. styles.bottom = "auto";
  533. }
  534. if( left != null ){
  535. styles.left = "" + left + "px";
  536. styles.right = "auto";
  537. }else if( right != null ){
  538. styles.left = "auto";
  539. styles.right = "" + right + "px";
  540. }else{
  541. styles.left = "" + parseInt((limitWidth - width) / 2, 10) + "px";
  542. styles.right = "auto";
  543. }
  544. //top = top || parseInt((limitHeight - height) / 2, 10);
  545. //left = left || parseInt((limitWidth - width) / 2, 10);
  546. this.formAreaNode.setStyles(styles);
  547. this._setFormNodeSize(styles);
  548. this.setNodesSize( width, height );
  549. },
  550. _setFormNodeSize: function( styles ){
  551. },
  552. setNodesSize: function(width, height){
  553. this.options.minWidth > width && (width = this.options.minWidth);
  554. this.options.minHeight > height && (height = this.options.minHeight);
  555. this.formNode.setStyles({
  556. "width": "" + width + "px",
  557. "height": "" + height + "px"
  558. });
  559. var iconSize = this.formIconNode ? this.formIconNode.getSize() : {x: 0, y: 0};
  560. var topSize = this.formTopNode ? this.formTopNode.getSize() : {x: 0, y: 0};
  561. var bottomSize = this.formBottomNode ? this.formBottomNode.getSize() : {x: 0, y: 0};
  562. var contentHeight = height - iconSize.y - topSize.y - bottomSize.y;
  563. var marginTop = parseFloat(this.formContentNode.getStyle( "margin-top" )) || 0;
  564. var marginBottom = parseFloat(this.formContentNode.getStyle( "margin-bottom" )) || 0;
  565. var formContentHeight = contentHeight - marginTop - marginBottom;
  566. this.formContentNode.setStyles({
  567. "height": "" + formContentHeight + "px"
  568. });
  569. var paddingTop = parseFloat( this.formContentNode.getStyle( "padding-top" )) || 0;
  570. var paddingBottom = parseFloat( this.formContentNode.getStyle( "padding-bottom" )) || 0;
  571. marginTop = parseFloat( this.formTableContainer.getStyle( "margin-top" )) || 0;
  572. marginBottom = parseFloat( this.formTableContainer.getStyle( "margin-bottom" )) || 0;
  573. var tablePaddingTop = parseFloat( this.formTableContainer.getStyle( "padding-top" )) || 0;
  574. var tablePaddingTBottom = parseFloat( this.formTableContainer.getStyle( "padding-bottom" )) || 0;
  575. var formTableHeight = contentHeight - marginTop - marginBottom - paddingTop - paddingBottom - tablePaddingTop - tablePaddingTBottom;
  576. this.formTableContainer.setStyles({
  577. "height": "" + formTableHeight + "px"
  578. });
  579. this._setNodesSize( width, height, formContentHeight, formTableHeight );
  580. this.fireEvent("resizeForm");
  581. },
  582. _setNodesSize : function(width, height, formContentHeight, formTableHeight ){
  583. }
  584. });