Sha256: 8a89762f4f33485825f42f019b7b6fee1ccb27c728c249ef970b09c3bc1c6916

Contents?: true

Size: 1.82 KB

Versions: 40

Compression:

Stored size: 1.82 KB

Contents

// ==========================================================================
// Project:   SproutCore - JavaScript Application Framework
// Copyright: ©2006-2011 Strobe Inc. and contributors.
//            Portions ©2008-2011 Apple Inc. All rights reserved.
// License:   Licensed under MIT license (see license.js)
// ==========================================================================

/*global module test equals context ok */

module("SC.View#themes");

// TODO: This isn't passing on master. Alex needs to take a look at it.

//var t1 = SC.Theme.addTheme("sc-test-1", SC.BaseTheme.extend({name: 'test-1' }));
//var t2 = SC.Theme.addTheme("sc-test-2", SC.BaseTheme.extend({name: 'test-2' }));

test("changing themes propagates to child view.");
//test("changing themes propagates to child view.", function() {
  //var view = SC.View.create({
    //"childViews": "child".w(),
    //theme: "sc-test-1",
    //child: SC.View.extend({
      
    //})
  //});
  
  //ok(t1 === view.get("theme"), "view's theme should be sc-test-1");
  //ok(t1 === view.child.get("theme"), "view's child's theme should be sc-test-1");
  //view.set('themeName', 'sc-test-2');
  //ok(t2 === view.get("theme"), "view's theme should be sc-test-2");
  //ok(t2 === view.child.get("theme"), "view's child's theme should be sc-test-2");
//});

test("adding child to parent propagates theme to child view.");
//test("adding child to parent propagates theme to child view.", function() {
  //var child = SC.View.create({});
  //var view = SC.View.create({
    //theme: "sc-test-1"
  //});
  
  //ok(t1 === view.get("theme"), "view's theme should be sc-test-1");
  //equals(child.get("theme"), SC.Theme.find('sc-base'), "view's child's theme should start at base theme");
  //view.appendChild(child);
  //equals(t1, child.get("theme"), "view's child's theme should be sc-test-1");
//});

Version data entries

40 entries across 40 versions & 1 rubygems

Version Path
sproutcore-1.11.0 lib/frameworks/sproutcore/frameworks/core_foundation/tests/views/view/theme.js
sproutcore-1.11.0.rc3 lib/frameworks/sproutcore/frameworks/core_foundation/tests/views/view/theme.js
sproutcore-1.11.0.rc2 lib/frameworks/sproutcore/frameworks/core_foundation/tests/views/view/theme.js
sproutcore-1.11.0.rc1 lib/frameworks/sproutcore/frameworks/core_foundation/tests/views/view/theme.js
sproutcore-1.10.3.1 lib/frameworks/sproutcore/frameworks/core_foundation/tests/views/view/theme.js
sproutcore-1.10.2 lib/frameworks/sproutcore/frameworks/core_foundation/tests/views/view/theme.js
sproutcore-1.10.1 lib/frameworks/sproutcore/frameworks/core_foundation/tests/views/view/theme.js
sproutcore-1.10.0 lib/frameworks/sproutcore/frameworks/core_foundation/tests/views/view/theme.js
sproutcore-1.10.0.rc.3 lib/frameworks/sproutcore/frameworks/core_foundation/tests/views/view/theme.js
sproutcore-1.10.0.rc.2 lib/frameworks/sproutcore/frameworks/core_foundation/tests/views/view/theme.js
sproutcore-1.10.0.rc.1 lib/frameworks/sproutcore/frameworks/core_foundation/tests/views/view/theme.js
sproutcore-1.9.2 lib/frameworks/sproutcore/frameworks/core_foundation/tests/views/view/theme.js
sproutcore-1.9.1 lib/frameworks/sproutcore/frameworks/core_foundation/tests/views/view/theme.js
sproutcore-1.9.0 lib/frameworks/sproutcore/frameworks/core_foundation/tests/views/view/theme.js
sproutcore-1.8.2.1 lib/frameworks/sproutcore/frameworks/core_foundation/tests/views/view/theme.js
sproutcore-1.8.1 lib/frameworks/sproutcore/frameworks/core_foundation/tests/views/view/theme.js
sproutcore-1.8.0 lib/frameworks/sproutcore/frameworks/core_foundation/tests/views/view/theme.js
sproutcore-1.7.1.beta-java lib/frameworks/sproutcore/frameworks/core_foundation/tests/views/view/theme.js
sproutcore-1.7.1.beta lib/frameworks/sproutcore/frameworks/core_foundation/tests/views/view/theme.js
sproutcore-1.6.0.1-java lib/frameworks/sproutcore/frameworks/core_foundation/tests/views/view/theme.js