• Register
  • Log In
  • Home
  • Quick Start
    • Configurator
    • Download YUI 3
  • Documentation
    • User Guides
    • Examples
    • API Docs
    • Environments
    • Tutorials
  • Community
    • Gallery
    • Blog
    • Forums
    • YUI Theater
    • Calendar
  • Contribute
    • YUI on GitHub »
    • File a Ticket
    • View Tickets
    • Dashboard
  • Other Projects
    • Shifter »
    • Yogi »
    • YUI 2
    • YUI Doc »
    • YUI Test
    • YUI Website
    • YUI Compressor »
    • YUI Builder »
    • YUI PHP Loader
    • Grid Builder »
    • Skin Builder »
  • YUI
  • >
  • Community
  • >
  • Gallery

Gallery

Modules

  • Home
  • Featured
  • Popular
  • New
  • All

Documentation

  • Yogi Documentation
  • Shifter Documentation
  • Developer Guide
  • Module Setup

Tag Cloud

Context Navigation

    Build Tag: gallery-2009.12.15-22

    Return to History Lite

    YUI({
        //Last Gallery Build of this module
        gallery: 'gallery-2009.12.15-22'
    }).use('gallery-history-lite', 'console', function (Y) {
     
        // Create a logging console so we can watch the awesomeness happen.
        Y.one(document.body).addClass('yui-skin-sam');
        new Y.Console().render();
     
        // Listen for history changes.
        Y.on('history-lite:change', function (e) {
            // Properties on e.changed represent new or changed history parameters.
            Y.each(e.changed, function (value, name) {
                Y.log(name + ' changed to "' + value + '"', 'debug', 'history-lite');
            });
     
            // Properties on e.removed represent history parameters that have been
            // removed.
            Y.each(e.removed, function (value, name) {
                Y.log(name + ' was removed', 'debug', 'history-lite');
            });
     
            // The get() method returns the current value of the specified history
            // parameter. If you call get() without specifying a parameter name,
            // it'll return an object containing all current history parameters and
            // their values.
            Y.log('current value of foo is ' + Y.HistoryLite.get('foo'), 'debug', 'history-lite');
        });
     
        // Simulate some history change events (watch the browser's location bar and
        // the debug console to see what's happening).
        setTimeout(function () {
            // The add() method accepts an object containing key/value pairs of
            // history parameter names and values. Each call to add() creates a new
            // browser history entry.
            Y.HistoryLite.add({foo: 'bar', baz: 'quux'});
        }, 1000);
     
        setTimeout(function () {
            // The add() method will also accept a query string.
            Y.HistoryLite.add('foo=kittens');
        }, 2000);
     
        setTimeout(function () {
            // A null or undefined value causes that parameter to be removed from
            // the history state.
            Y.HistoryLite.add({foo: null, baz: 'monkeys'});
        }, 3000);
     
    });
     

    Build Output

    /home/y/libexec/ant/bin/ant all
    Buildfile: build.xml
         [echo] Starting Build For gallery-history-lite
         [echo] Ant Properties
         [echo]     Home : /home/y/libexec/ant
         [echo]     Ant Version : Apache Ant version 1.7.1 compiled on June 27 2008
         [echo]     Build File : /home/y/var/builds/workspace/gallery/build_tmp/src/yui3-gallery/src/gallery-history-lite/build.xml
         [echo] Local Build Properties
         [echo]     version : 3
         [echo]     srcdir : /home/y/var/builds/workspace/gallery/build_tmp/src/yui3-gallery
         [echo]     builddir : ../../../builder/componentbuild
         [echo]     component : gallery-history-lite
         [echo]     component.basefilename : gallery-history-lite
         [echo]     component.basedir : /home/y/var/builds/workspace/gallery/build_tmp/src/yui3-gallery/src/gallery-history-lite
         [echo]     component.builddir : /home/y/var/builds/workspace/gallery/build_tmp/src/yui3-gallery/src/gallery-history-lite/build_tmp
         [echo] Global Build Properties
         [echo]     global.build.base : /home/y/var/builds/workspace/gallery/build_tmp/src/yui3-gallery/build
         [echo]     global.build.component : /home/y/var/builds/workspace/gallery/build_tmp/src/yui3-gallery/build/gallery-history-lite
         [echo]     global.build.component.assets : /home/y/var/builds/workspace/gallery/build_tmp/src/yui3-gallery/build/gallery-history-lite/assets
    
    clean:
    
    init:
        [mkdir] Created dir: /home/y/var/builds/workspace/gallery/build_tmp/src/yui3-gallery/src/gallery-history-lite/build_tmp
    
    -concatdebug:
         [echo] Concatenating
         [echo]     Source Files : history-lite.js
         [echo]     In Source Dir : /home/y/var/builds/workspace/gallery/build_tmp/src/yui3-gallery/src/gallery-history-lite/js
         [echo]     To : /home/y/var/builds/workspace/gallery/build_tmp/src/yui3-gallery/src/gallery-history-lite/build_tmp/gallery-history-lite-debug.js
         [copy] Copying 1 file to /home/y/var/builds/workspace/gallery/build_tmp/src/yui3-gallery/src/gallery-history-lite/build_tmp/ant
       [delete] Deleting directory /home/y/var/builds/workspace/gallery/build_tmp/src/yui3-gallery/src/gallery-history-lite/build_tmp/ant
    
    -registerdebug:
         [echo] Wrapping /home/y/var/builds/workspace/gallery/build_tmp/src/yui3-gallery/src/gallery-history-lite/build_tmp/gallery-history-lite-debug.js in YUI.add module
         [copy] Copying 1 file to /home/y/var/builds/workspace/gallery/build_tmp/src/yui3-gallery/src/gallery-history-lite/build_tmp
    
    -prependdebug:
    
    -appenddebug:
    
    builddebug:
    
    -createcore:
         [copy] Copying 1 file to /home/y/var/builds/workspace/gallery/build_tmp/src/yui3-gallery/src/gallery-history-lite/build_tmp
    
    -loggerregex:
         [echo] Replacing Logger Statements in /home/y/var/builds/workspace/gallery/build_tmp/src/yui3-gallery/src/gallery-history-lite/build_tmp/gallery-history-lite.js
    
    buildcore:
    
    -rollupjs:
    
    -concatskins:
    
    -buildskins:
    
    -rollupcss:
    
    buildskins:
    
    build:
    
    minify:
         [echo] Running yuicompressor on /home/y/var/builds/workspace/gallery/build_tmp/src/yui3-gallery/src/gallery-history-lite/build_tmp/gallery-history-lite.js
         [java] 
         [java] [INFO] Using charset ANSI_X3.4-1968
         [java] 
         [java] [WARNING] Try to use a single 'var' statement per scope.
         [java] replace(/+/g," "));} ---> var  <--- getHash;if(Y.UA.gecko)
         [java] 
         [java] [WARNING] Found an undeclared symbol: YUI
         [java]  ---> YUI <--- .add("gallery-history-lite",function(Y){
    
    lint:
         [java] Running JSLint on : /home/y/var/builds/workspace/gallery/build_tmp/src/yui3-gallery/src/gallery-history-lite/build_tmp/gallery-history-lite-debug.js
         [java] - OK
         [java] Running JSLint on : /home/y/var/builds/workspace/gallery/build_tmp/src/yui3-gallery/src/gallery-history-lite/build_tmp/gallery-history-lite-min.js
         [java] - OK
         [java] Running JSLint on : /home/y/var/builds/workspace/gallery/build_tmp/src/yui3-gallery/src/gallery-history-lite/build_tmp/gallery-history-lite.js
         [java] - OK
    
    local:
    
    deploybuild:
         [copy] Copying 3 files to /home/y/var/builds/workspace/gallery/build_tmp/src/yui3-gallery/build/gallery-history-lite
    
    deployassets:
    
    deployskins:
    
    deploydocs:
    
    deploy:
    
    all:
    
    BUILD SUCCESSFUL
    Total time: 2 seconds

    © 2006-2013 Yahoo! Inc. All rights reserved.
    All code on this site is licensed under the BSD License unless stated otherwise.
    About This Site · Security Contact Info