Sha256: 58e76d48cefc35e432e9c13915525f879f9901804a6131fd41d85749b50e6c9a

Contents?: true

Size: 833 Bytes

Versions: 24

Compression:

Stored size: 833 Bytes

Contents

// ==========================================================================
// Project:   TestRunner.OffsetCheckboxView
// Copyright: ©2009 Apple Inc.
// ==========================================================================
/*globals TestRunner */

/** @class

  This special view class will automatically adjusts its left offset based 
  on an "offset" value, which is will be bound to the width of the split view.
  
  This way when you resize the split view, the checkbox view will move also.

  @extends SC.CheckboxView
*/
TestRunner.OffsetCheckboxView = SC.CheckboxView.extend(
/** @scope TestRunner.OffsetCheckboxView.prototype */ {

  /** bind to thickness of splitview (though a controller) */
  offset: 0,
  
  offsetDidChange: function() {
    this.adjust('left', this.get('offset')+6);
  }.observes('offset')

});

Version data entries

24 entries across 24 versions & 2 rubygems

Version Path
sproutit-sproutcore-1.0.20090721145285 frameworks/sproutcore/apps/tests/views/offset_checkbox.js
sproutcore-1.4.0.rc.5 lib/frameworks/sproutcore/apps/tests/views/offset_checkbox.js
sproutcore-1.4.0.rc.4 lib/frameworks/sproutcore/apps/tests/views/offset_checkbox.js
sproutcore-1.4.0.rc.3 lib/frameworks/sproutcore/apps/tests/views/offset_checkbox.js
sproutcore-1.4.0.rc.2 lib/frameworks/sproutcore/apps/tests/views/offset_checkbox.js
sproutcore-1.4.0.rc lib/frameworks/sproutcore/apps/tests/views/offset_checkbox.js
sproutcore-1.0.1049.pre.2 lib/frameworks/sproutcore/apps/tests/views/offset_checkbox.js
sproutcore-1.0.1049.pre.1 frameworks/sproutcore/apps/tests/views/offset_checkbox.js
sproutcore-1.0.1046 frameworks/sproutcore/apps/tests/views/offset_checkbox.js
sproutcore-1.0.1043 frameworks/sproutcore/apps/tests/views/offset_checkbox.js
sproutcore-1.0.1042 frameworks/sproutcore/apps/tests/views/offset_checkbox.js
sproutcore-1.0.1037 frameworks/sproutcore/apps/tests/views/offset_checkbox.js
sproutcore-1.0.1035 frameworks/sproutcore/apps/tests/views/offset_checkbox.js
sproutcore-1.0.1031 frameworks/sproutcore/apps/tests/views/offset_checkbox.js
sproutcore-1.0.1030 frameworks/sproutcore/apps/tests/views/offset_checkbox.js
sproutcore-1.0.1029 frameworks/sproutcore/apps/tests/views/offset_checkbox.js
sproutcore-1.0.1027 frameworks/sproutcore/apps/tests/views/offset_checkbox.js
sproutcore-1.0.1028 frameworks/sproutcore/apps/tests/views/offset_checkbox.js
sproutcore-1.0.1026 frameworks/sproutcore/apps/tests/views/offset_checkbox.js
sproutcore-1.0.1025 frameworks/sproutcore/apps/tests/views/offset_checkbox.js