/*!
 * SAP UI development toolkit for HTML5 (SAPUI5/OpenUI5)
 * (c) Copyright 2009-2015 SAP SE or an SAP affiliate company.
 * Licensed under the Apache License, Version 2.0 - see LICENSE.txt.
 */
sap.ui.define(['jquery.sap.global'],function(q){"use strict";var P={};P.render=function(r,p){var h=null,f=null,s=null,e=p.getEnableScrolling()?" sapMPageScrollEnabled":"";if(p.getShowHeader()){h=p._getAnyHeader();}if(p.getShowSubHeader()){s=p.getSubHeader();}if(p.getShowFooter()){f=p.getFooter();}r.write("<div");r.writeControlData(p);r.addClass("sapMPage");r.addClass("sapMPageBg"+p.getBackgroundDesign());if(h){r.addClass("sapMPageWithHeader");}if(s){r.addClass("sapMPageWithSubHeader");}if(f){r.addClass("sapMPageWithFooter");}r.writeClasses();var t=p.getTooltip_AsString();if(t){r.writeAttributeEscaped("title",t);}r.write(">");this.renderBarControl(r,h,{context:"header",styleClass:"sapMPageHeader"});this.renderBarControl(r,s,{context:"subheader",styleClass:"sapMPageSubHeader"});r.write('<section id="'+p.getId()+'-cont">');if(p._bUseScrollDiv){r.write('<div id="'+p.getId()+'-scroll" class="sapMPageScroll'+e+'">');}var c=p.getContent();var l=c.length;for(var i=0;i<l;i++){r.renderControl(c[i]);}if(p._bUseScrollDiv){r.write("</div>");}r.write("</section>");this.renderBarControl(r,f,{context:"footer",styleClass:"sapMPageFooter"});r.write("</div>");};P.renderBarControl=function(r,b,o){if(!b){return;}b.applyTagAndContextClassFor(o.context);b.addStyleClass(o.styleClass);r.renderControl(b);};return P;},true);
