Created
June 10, 2011 18:24
-
-
Save tritchey/1019417 to your computer and use it in GitHub Desktop.
rendering buttons
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
ScaleUI.SystemSectionDetailView = SC.View.extend({ | |
layout: { top: 0, left: 0, right: 0}, | |
useStaticLayout: YES, | |
isVisibleBinding: '.parentView.parentView.isDetail', | |
childViews: 'showEditButton'.w(), | |
showEditButton: SC.ButtonView.extend({ | |
useStaticLayout: YES, | |
action: 'editClicked', | |
title: '_Edit'.loc(), | |
}), | |
renderChildViews: function() {}, | |
render: function(context, firstTime) { | |
sc_super(); | |
context = context.begin(this.getPath('showEditButton.tagName')); | |
this.get('showEditButton').renderToContext(context, YES); | |
context = context.end(); | |
this._didRenderChildViews = YES; | |
}, | |
}) |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment