argil-svn Mailing List for Argil Framework (Page 3)
Status: Alpha
Brought to you by:
tswicegood
You can subscribe to this list here.
| 2007 |
Jan
|
Feb
(18) |
Mar
(8) |
Apr
(11) |
May
(23) |
Jun
(1) |
Jul
(6) |
Aug
|
Sep
|
Oct
|
Nov
|
Dec
|
|---|
|
From: <tsw...@us...> - 2007-02-22 15:32:16
|
Revision: 498
http://argil.svn.sourceforge.net/argil/?rev=498&view=rev
Author: tswicegood
Date: 2007-02-22 07:32:13 -0800 (Thu, 22 Feb 2007)
Log Message:
-----------
Remove Pipes references
Modified Paths:
--------------
trunk/docs/Roadmap
Modified: trunk/docs/Roadmap
===================================================================
--- trunk/docs/Roadmap 2007-02-21 17:50:29 UTC (rev 497)
+++ trunk/docs/Roadmap 2007-02-22 15:32:13 UTC (rev 498)
@@ -1,6 +1,6 @@
-Pipes - PHP In Pipes Express Scaffolding
-========================================
-Pipes is an OO MVC framework built in PHP 5 designed to quickly and easily build
+Argil Framework
+===============
+Argil is an OO MVC framework built in PHP 5 designed to quickly and easily build
a MVC application around database tables created using your favorite MySQL
client. This document outlines the intended features through version 1.0 with
a few additional features that are anticipated in post 1.0 releases.
@@ -12,16 +12,16 @@
code and return it in a compressed archive form.
* Add support for mixins in Controllers
* Move Controller authorization into a mixin
- * Add in Pipes_Dispatcher to take the place of Pipes_Controller::run()
+ * Add in Argil_Dispatcher to take the place of Argil_Controller::run()
* Make all Controller::action*() methods public and have them return View_Result
objects by default
- * Add Pipes_Controller::findExecutable($route, $credentials) for use by Dispatcher
+ * Add Argil_Controller::findExecutable($route, $credentials) for use by Dispatcher
Version 0.4
-----------
* Implement RSS/Atom PageTypes
- * Start Pipes_Services code
- * Implement Pipes_Http to wrap access to Zend, PEAR, Pecl, and Curl
+ * Start Argil_Services code
+ * Implement Argil_Http to wrap access to Zend, PEAR, Pecl, and Curl
* Implement ability to map URLs to 'name' field instead of 'id' field.
Version 0.5
@@ -30,7 +30,7 @@
release until Version 1.1
* Ability to create complex MVC code directly from the command line by setting
up a database with the tables and relationships that you need and calling
- 'pipes create all' from the command line.
+ 'argil create all' from the command line.
Version 0.6
-----------
@@ -39,7 +39,7 @@
Version 0.7
-----------
- * Documentation release - contains narrative documentation on how to use Pipes
+ * Documentation release - contains narrative documentation on how to use Argil
for various tasks. Will focus on use cases rather than API.
Version 0.9
@@ -65,7 +65,7 @@
### Version 0.1
* Ability to create basic CRUD (Create, Retrieve, Update, Delete) directly from
commandline
- * Implement executable script called "pipes" which takes two parameters
+ * Implement executable script called "argil" which takes two parameters
- 'create <table_name>': creates the Model, Controller, and
View for basic applications based on the table in a MySQL database.
* All new Models are stored with an ID based on universal sequences table
@@ -83,8 +83,8 @@
### Version 0.2
* Implement basic Authorization Decorator to allow multiple Authorization
types
- * Implement first AJAX interface via 'pipes' Javascript object that provides
- basic API for performing Pipes related commands (see [PipesAjaxApi](./PipesAjaxApi))
+ * Implement first AJAX interface via 'argil' Javascript object that provides
+ basic API for performing Argil related commands (see [ArgilAjaxApi](./ArgilAjaxApi))
* Include initial Javascript effects libraries as part of release
* Implement PageTypes based on file extension (i.e. bookmarks/browse.html)
which is used to load a PageType wrapper to wrap Controller generated content
This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.
|
|
From: <tsw...@us...> - 2007-02-21 17:50:30
|
Revision: 497
http://argil.svn.sourceforge.net/argil/?rev=497&view=rev
Author: tswicegood
Date: 2007-02-21 09:50:29 -0800 (Wed, 21 Feb 2007)
Log Message:
-----------
Remove debug code from JS and trailing slashes (for IE)
Modified Paths:
--------------
trunk/src/ArgilCore/Public/scripts/argil.moo.js
trunk/src/ArgilCore/Public/scripts/mootools.full.v1.00.js
Modified: trunk/src/ArgilCore/Public/scripts/argil.moo.js
===================================================================
--- trunk/src/ArgilCore/Public/scripts/argil.moo.js 2007-02-21 17:10:31 UTC (rev 496)
+++ trunk/src/ArgilCore/Public/scripts/argil.moo.js 2007-02-21 17:50:29 UTC (rev 497)
@@ -8,7 +8,6 @@
switch($(selector).getTag()) {
case 'a' :
- console.log(options['type']);
switch (options['type']) {
case 'RemoveModel' :
return new Argil.objects.Anchor.RemoveModel($(selector));
@@ -112,7 +111,7 @@
},
removeRow: function() {
new Argil.Fx.FadeOutAndRemove(this.row).toggle();
- },
+ }
});
Argil.objects.Anchor.AddForm = Argil.objects.Anchor.extend({
@@ -129,7 +128,7 @@
},
onComplete: function(result) {
new Argil.Fx.FadeInAndShow(new Moo.Element('div').setHTML(result), {where: this.anchor.parentNode}).toggle();
- },
+ }
});
Argil.objects.Anchor.EditForm = Argil.objects.Anchor.extend({
@@ -189,7 +188,7 @@
},
remove: function() {
this.container.removeChild(this.modal);
- },
+ }
});
Argil.objects.Form = new Moo.Class({
requireValidation: false,
@@ -227,7 +226,7 @@
this.loading();
this.form.send({onComplete: function(result){me.onComplete(result);}});
return false;
- },
+ }
});
@@ -276,7 +275,7 @@
this.slider = new Argil.Fx.SlideWithTab(this.element, this.options.slider);
- },
+ }
});
Argil.Fx = {};
@@ -301,7 +300,7 @@
toggle: function(mode){
if (this.wrapper.offsetHeight == this.tabSize || this.wrapper.offsetWidth == this.tabSize) return this.slideIn(mode);
else return this.slideOut(mode);
- },
+ }
});
Argil.Fx.FadeOutAndRemove = new Moo.Class({
Modified: trunk/src/ArgilCore/Public/scripts/mootools.full.v1.00.js
===================================================================
--- trunk/src/ArgilCore/Public/scripts/mootools.full.v1.00.js 2007-02-21 17:10:31 UTC (rev 496)
+++ trunk/src/ArgilCore/Public/scripts/mootools.full.v1.00.js 2007-02-21 17:50:29 UTC (rev 497)
@@ -3808,8 +3808,6 @@
*/
slideIn: function(mode){
- console.log(this[mode || this.options.mode]());
- console.log([0, this.offset]);
return this.start(this[mode || this.options.mode](), [0, this.offset]);
},
@@ -3819,8 +3817,6 @@
*/
slideOut: function(mode){
- console.log(this[mode || this.options.mode]());
- console.log([0, this.offset]);
return this.start(this[mode || this.options.mode](), [-this.offset, 0]);
},
This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.
|
|
From: <tsw...@us...> - 2007-02-21 17:10:47
|
Revision: 496
http://argil.svn.sourceforge.net/argil/?rev=496&view=rev
Author: tswicegood
Date: 2007-02-21 09:10:31 -0800 (Wed, 21 Feb 2007)
Log Message:
-----------
Change the PDO field to reflect what will be there
Modified Paths:
--------------
trunk/docs/HowTos/BookmarkApp
Modified: trunk/docs/HowTos/BookmarkApp
===================================================================
--- trunk/docs/HowTos/BookmarkApp 2007-02-21 15:47:08 UTC (rev 495)
+++ trunk/docs/HowTos/BookmarkApp 2007-02-21 17:10:31 UTC (rev 496)
@@ -50,7 +50,7 @@
your PDO connection is properly set up. Line 10 of the config file will look
like:
- $config['pdo'] = new PDO('mysql:host=localhost;dbname=argil_demo', 'root', '');
+ $config['pdo'] = new PDO('mysql:host=localhost;dbname=my_project', 'root', '');
The `argil_demo` database was assumed based on the project you created. This
also attempts to connect to the `localhost` using the `root` account with no
This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.
|
|
From: <tsw...@us...> - 2007-02-21 15:47:11
|
Revision: 495
http://argil.svn.sourceforge.net/argil/?rev=495&view=rev
Author: tswicegood
Date: 2007-02-21 07:47:08 -0800 (Wed, 21 Feb 2007)
Log Message:
-----------
Modify failing tests so they work with the latest PHPUnit.
These are tested against PHPUnit3 SVN r521. There was bugs in prior version of PU3 that
made expectations give false positives.
Modified Paths:
--------------
trunk/tests/Argil/Database/Reflection/TableTest.php
trunk/tests/Argil/Model/MapperTest.php
trunk/tests/Argil/Model/MetaTest.php
trunk/tests/Argil/Model/Relationship/MapperTest.php
trunk/tests/Argil/ModelListTest.php
trunk/tests/Argil/ModelTest.php
trunk/tests/ArgilCore/Models/Finders/AllTest.php
trunk/tests/ArgilCore/Models/Finders/OneTest.php
trunk/tests/ArgilSample/TestCase.php
Modified: trunk/tests/Argil/Database/Reflection/TableTest.php
===================================================================
--- trunk/tests/Argil/Database/Reflection/TableTest.php 2007-02-21 01:06:13 UTC (rev 494)
+++ trunk/tests/Argil/Database/Reflection/TableTest.php 2007-02-21 15:47:08 UTC (rev 495)
@@ -28,9 +28,6 @@
public function testContainsTableNameBasedOnConstruct() {
$database = $this->getMock('ArgilImpl_Database_Reflection');
- $database->expects($this->once())
- ->method('getName')
- ->will($this->returnValue('argiltest'));
$table = new Argil_Database_Reflection_Table($database, $this->_tableName);
$this->assertSame("{$this->_tableName}", $table->getName());
@@ -41,7 +38,7 @@
$database->expects($this->atLeastOnce())
->method('getPDO')
->will($this->returnValue($this->_pdo));
- $database->expects($this->atLeastOnce())
+ $database->expects($this->any())
->method('getName')
->will($this->returnValue('argiltest'));
@@ -61,7 +58,7 @@
$database->expects($this->once())
->method('getPDO')
->will($this->returnValue($this->_pdo));
- $database->expects($this->once())
+ $database->expects($this->any())
->method('getName')
->will($this->returnValue('argiltest'));
Modified: trunk/tests/Argil/Model/MapperTest.php
===================================================================
--- trunk/tests/Argil/Model/MapperTest.php 2007-02-21 01:06:13 UTC (rev 494)
+++ trunk/tests/Argil/Model/MapperTest.php 2007-02-21 15:47:08 UTC (rev 495)
@@ -141,7 +141,7 @@
public function testCallsRemoveOnProvidedStorageOnRemove() {
$values = array('widget_id' => rand(100, 999), 'title' => rand(1000, 1999));
$storage = $this->getMock('ArgilImpl_Storage');
- $storage->expects($this->once())
+ $storage->expects($this->any())
->method('getRecord')
->will($this->returnValue($values));
$storage->expects($this->once())
Modified: trunk/tests/Argil/Model/MetaTest.php
===================================================================
--- trunk/tests/Argil/Model/MetaTest.php 2007-02-21 01:06:13 UTC (rev 494)
+++ trunk/tests/Argil/Model/MetaTest.php 2007-02-21 15:47:08 UTC (rev 495)
@@ -50,7 +50,7 @@
$widgetColumn = $this->getMock('ArgilImpl_Database_Reflection_Column');
- $widgetColumn->expects($this->exactly(2))
+ $widgetColumn->expects($this->atLeastOnce())
->method('getName')
->will($this->returnValue('widget_id'));
$widgetColumn->expects($this->once())
@@ -70,7 +70,7 @@
->will($this->returnValue(0));
$titleColumn = $this->getMock('ArgilImpl_Database_Reflection_Column');
- $titleColumn->expects($this->exactly(2))
+ $titleColumn->expects($this->atLeastOnce())
->method('getName')
->will($this->returnValue('title'));
$titleColumn->expects($this->once())
@@ -87,7 +87,7 @@
->will($this->returnValue(false));
$randomColumn = $this->getMock('ArgilImpl_Database_Reflection_Column');
- $randomColumn->expects($this->exactly(2))
+ $randomColumn->expects($this->atLeastOnce())
->method('getName')
->will($this->returnValue($this->_randomColumn));
$randomColumn->expects($this->once())
@@ -107,7 +107,7 @@
->will($this->returnValue(false));
$textAreaColumn = $this->getMock('ArgilImpl_Database_Reflection_Column');
- $textAreaColumn->expects($this->exactly(2))
+ $textAreaColumn->expects($this->atLeastOnce())
->method('getName')
->will($this->returnValue('text_area'));
$textAreaColumn->expects($this->once())
Modified: trunk/tests/Argil/Model/Relationship/MapperTest.php
===================================================================
--- trunk/tests/Argil/Model/Relationship/MapperTest.php 2007-02-21 01:06:13 UTC (rev 494)
+++ trunk/tests/Argil/Model/Relationship/MapperTest.php 2007-02-21 15:47:08 UTC (rev 495)
@@ -71,7 +71,7 @@
$idColumn->name = 'widget_id';
$model = $this->getMock('ArgilImpl_Model');
- $model->expects($this->exactly(2))
+ $model->expects($this->atLeastOnce())
->method('getName')
->will($this->returnValue('widget'));
$model->expects($this->any())
Modified: trunk/tests/Argil/ModelListTest.php
===================================================================
--- trunk/tests/Argil/ModelListTest.php 2007-02-21 01:06:13 UTC (rev 494)
+++ trunk/tests/Argil/ModelListTest.php 2007-02-21 15:47:08 UTC (rev 495)
@@ -59,7 +59,7 @@
'title' => array()
);
$meta = $this->getMock('ArgilImpl_Model_Meta');
- $meta->expects($this->atLeastOnce())
+ $meta->expects($this->any())
->method('getColumns')
->will($this->returnValue($columns));
@@ -196,7 +196,7 @@
'title' => array()
);
$meta = $this->getMock('ArgilImpl_Model_Meta');
- $meta->expects($this->atLeastOnce())
+ $meta->expects($this->any())
->method('getColumns')
->will($this->returnValue($columns));
Modified: trunk/tests/Argil/ModelTest.php
===================================================================
--- trunk/tests/Argil/ModelTest.php 2007-02-21 01:06:13 UTC (rev 494)
+++ trunk/tests/Argil/ModelTest.php 2007-02-21 15:47:08 UTC (rev 495)
@@ -14,7 +14,7 @@
public function setUp() {
// mock "init" method so it doesn't try to check config values
$meta = $this->getMock('ArgilImpl_Model_Meta');
- $meta->expects($this->atLeastOnce())
+ $meta->expects($this->any())
->method('getColumns')
->will($this->returnValue(
array(
Modified: trunk/tests/ArgilCore/Models/Finders/AllTest.php
===================================================================
--- trunk/tests/ArgilCore/Models/Finders/AllTest.php 2007-02-21 01:06:13 UTC (rev 494)
+++ trunk/tests/ArgilCore/Models/Finders/AllTest.php 2007-02-21 15:47:08 UTC (rev 495)
@@ -44,11 +44,6 @@
$meta->expects($this->atLeastOnce())
->method('getModelName')
->will($this->returnValue('Widget_Models_Widget'));
- $widgetId = $this->getMock('ArgilImpl_Model_Meta_Column');
- $widgetId->name = 'widget_id';
- $meta->expects($this->once())
- ->method('idColumn')
- ->will($this->returnValue($widgetId));
$subMeta->expects($this->atLeastOnce())
->method('getName')
@@ -56,11 +51,6 @@
$subMeta->expects($this->atLeastOnce())
->method('getModelName')
->will($this->returnValue('Widget_Models_Sub'));
- $subId = $this->getMock('ArgilImpl_Model_Meta_Column');
- $subId->name = 'sub_id';
- $subMeta->expects($this->once())
- ->method('idColumn')
- ->will($this->returnValue($subId));
$finder = new ArgilCore_Models_Finders_All($config, $meta);
$list = $finder->find($this->_randomId);
@@ -91,11 +81,6 @@
$meta->expects($this->atLeastOnce())
->method('getModelName')
->will($this->returnValue('Widget_Models_Widget'));
- $widgetId = $this->getMock('ArgilImpl_Model_Meta_Column');
- $widgetId->name = 'widget_id';
- $meta->expects($this->once())
- ->method('idColumn')
- ->will($this->returnValue($widgetId));
$finder = new ArgilCore_Models_Finders_All($config, $meta);
$filter = new Argil_Filter();
Modified: trunk/tests/ArgilCore/Models/Finders/OneTest.php
===================================================================
--- trunk/tests/ArgilCore/Models/Finders/OneTest.php 2007-02-21 01:06:13 UTC (rev 494)
+++ trunk/tests/ArgilCore/Models/Finders/OneTest.php 2007-02-21 15:47:08 UTC (rev 495)
@@ -79,7 +79,7 @@
'projects' => array('ArgilCore', 'Widget'),
));
$meta = $this->getMock('ArgilImpl_Model_Meta');
- $meta->expects($this->any())
+ $meta->expects($this->once())
->method('getColumns')
->will($this->returnValue(array()));
$meta->expects($this->once())
@@ -88,11 +88,6 @@
$meta->expects($this->atLeastOnce())
->method('getModelName')
->will($this->returnValue('Widget_Models_Widget'));
- $widgetId = $this->getMock('ArgilImpl_Model_Meta_Column');
- $widgetId->name = 'widget_id';
- $meta->expects($this->once())
- ->method('idColumn')
- ->will($this->returnValue($widgetId));
$finder = new ArgilCore_Models_Finders_one($config, $meta);
$filter = new Argil_Filter();
Modified: trunk/tests/ArgilSample/TestCase.php
===================================================================
--- trunk/tests/ArgilSample/TestCase.php 2007-02-21 01:06:13 UTC (rev 494)
+++ trunk/tests/ArgilSample/TestCase.php 2007-02-21 15:47:08 UTC (rev 495)
@@ -8,16 +8,17 @@
class ArgilSample_TestCase extends PHPUnit_Framework_TestCase
{
protected $_pdo = null;
+ protected $_dbName = 'argil_sample_dev';
public function setup() {
$this->_pdo = new PDO('mysql:host=localhost;', 'root', '');
- $this->_pdo->exec('DROP DATABASE IF EXISTS argilsample_dev');
- $this->_pdo->exec('CREATE DATABASE argilsample_dev');
- $this->_pdo->exec('USE argilsample_dev');
+ $this->_pdo->exec("DROP DATABASE IF EXISTS {$this->_dbName}");
+ $this->_pdo->exec("CREATE DATABASE {$this->_dbName}");
+ $this->_pdo->exec("USE {$this->_dbName}");
}
public function teardown() {
- $this->_pdo->exec('DROP DATABASE IF EXISTS argilsample_dev');
+ $this->_pdo->exec("DROP DATABASE IF EXISTS {$this->_dbName}");
unset($this->_pdo);
}
}
This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.
|
|
From: <tsw...@us...> - 2007-02-21 01:06:13
|
Revision: 494
http://argil.svn.sourceforge.net/argil/?rev=494&view=rev
Author: tswicegood
Date: 2007-02-20 17:06:13 -0800 (Tue, 20 Feb 2007)
Log Message:
-----------
Update all of the docs to be reflect the name change
Modified Paths:
--------------
trunk/docs/CodingStandard
trunk/docs/HowTos/BookmarkApp
trunk/docs/HowTos/HelloWorld
trunk/docs/Manifesto
trunk/docs/OneMinuteTutorial
Added Paths:
-----------
trunk/docs/ArgilAjaxApi
trunk/docs/InstallingArgil
Removed Paths:
-------------
trunk/docs/InstallingPipes
trunk/docs/PipesAjaxApi
Copied: trunk/docs/ArgilAjaxApi (from rev 477, trunk/docs/PipesAjaxApi)
===================================================================
--- trunk/docs/ArgilAjaxApi (rev 0)
+++ trunk/docs/ArgilAjaxApi 2007-02-21 01:06:13 UTC (rev 494)
@@ -0,0 +1,5 @@
+Argil Javascript/AJAX API
+=========================
+As I move past version 0.1 and toward 0.2, this page will contain an outline
+of the Javascript API.
+
Modified: trunk/docs/CodingStandard
===================================================================
--- trunk/docs/CodingStandard 2007-02-20 23:57:43 UTC (rev 493)
+++ trunk/docs/CodingStandard 2007-02-21 01:06:13 UTC (rev 494)
@@ -1,13 +1,13 @@
-Pipes Coding Standard
+Argil Coding Standard
=====================
-Pipes does not adhere to the *Coding Standard* set forth by PEAR. That
-is actually a [formatting standard][1], which Pipes does have. Our coding
+Argil does not adhere to the *Coding Standard* set forth by PEAR. That
+is actually a [formatting standard][1], which Argil does have. Our coding
standard actually focuses on standard level of code:
Interface usage
: There should be no [concrete class dependencies][2]. Type hinting is
- strongly encouraged throughout, however it should hit to an interface,
+ strongly encouraged throughout, however it should hint to an interface,
not directly to a class.
Method length
Modified: trunk/docs/HowTos/BookmarkApp
===================================================================
--- trunk/docs/HowTos/BookmarkApp 2007-02-20 23:57:43 UTC (rev 493)
+++ trunk/docs/HowTos/BookmarkApp 2007-02-21 01:06:13 UTC (rev 494)
@@ -1,16 +1,16 @@
How to build a simple bookmark application
==========================================
-Pipes is a rapid application development framework that provides the tools
+Argil is a rapid application development framework that provides the tools
necessary to quickly, and efficiently create database powered applicaitons.
Getting Started
---------------
-Make sure you have [installed](../InstallingPipes) Pipes. If this is your
+Make sure you have [installed](../InstallingArgil) Argil. If this is your
first application, you will need to start off by creating a *project* for it
to reside in. To do that, you will need to run the following command:
- $ pipes start MyProject
+ $ argil start MyProject
### What is a project? ###
@@ -22,7 +22,7 @@
A look at what was created
--------------------------
-The `pipes` program just created a skeleton project directory and config
+The `argil` program just created a skeleton project directory and config
file. To view the files it just created, look in the new `./MyProject'
directory. You should see something like this:
@@ -45,14 +45,14 @@
Setting up the configuration
----------------------------
-Pipes has adopted *convention over configuration*, so you won't spend much time
+Argil has adopted *convention over configuration*, so you won't spend much time
editing `MyProject/config.php`, but to start with, you'll want to make sure
your PDO connection is properly set up. Line 10 of the config file will look
like:
- $config['pdo'] = new PDO('mysql:host=localhost;dbname=pipes_demo', 'root', '');
+ $config['pdo'] = new PDO('mysql:host=localhost;dbname=argil_demo', 'root', '');
-The `pipes_demo` database was assumed based on the project you created. This
+The `argil_demo` database was assumed based on the project you created. This
also attempts to connect to the `localhost` using the `root` account with no
password as that is the default setup for MySQL. It is not a secure means of
connecting to the database, so it is *strongly* suggested that you change this
@@ -76,11 +76,11 @@
There are three *conventions* to note here:
-1. The name of the table is a simple plural. Pipes assumes all databases will
+1. The name of the table is a simple plural. Argil assumes all databases will
be named in a simple plural form - just add *s* to the end of the name.
2. The primary ID field is the non-plural name of the table with a "_id"
suffix.
-3. Pipes does not use a built-in sequence, such as MySQL's `auto_increment`.
+3. Argil does not use a built-in sequence, such as MySQL's `auto_increment`.
Instead, it will create and use a universal `sequences` table to track
the universal unique ID.
@@ -88,10 +88,10 @@
Creating the MVC scaffolding
----------------------------
Once the data storage has been defined in the database, you need to run the
-`pipes` script again to create the MVC scaffolding. To do so, switch into
+`argil` script again to create the MVC scaffolding. To do so, switch into
the `MyProject` directory you created earlier and run
- $ pipes create Bookmark --with=Tag
+ $ argil create Bookmark --with=Tag
This will create the files necessary for a basic CRUD application. Here are
the files it created:
@@ -113,12 +113,12 @@
You can explore these files on your own. You'll notice that there is not
-much in any of them. Pipes uses *metaprogramming*, or more correctly, a subset
-termed *[CategoryReflection][note-1]*. This basically means that the Pipes is
+much in any of them. Argil uses *metaprogramming*, or more correctly, a subset
+termed *[CategoryReflection][note-1]*. This basically means that the Argil is
capable of looking at where the code exists, what its name is, and figuring out
what to do from there.
-> Future versions of Pipes will also be capable of [Code Generation][note-2] to
+> Future versions of Argil will also be capable of [Code Generation][note-2] to
> allow for greater flexibility. While meta-programming allows for quick
> prototyping, it does create a [tight coupling][note-3] which makes the
> code less portable.
@@ -128,7 +128,7 @@
-------------------------
Your application is now ready to load.
- http://localhost/pipes/index.php/Bookmark/
+ http://localhost/argil/index.php/Bookmark/
That will bring up a page that has 'title', 'url', and 'description', and a
link to add a new bookmark. Click the *Add New* link to be taken to a form to
@@ -140,7 +140,7 @@
Creating the interface for Tags
-------------------------------
-One thing your app can't do yet is handle Tags. Though Pipes realizes there is
+One thing your app can't do yet is handle Tags. Though Argil realizes there is
a connection there, it doesn't know immediately how to display those related
items. Since all of the required code is in place, all we have to do is edit
the view files to make it display properly.
@@ -165,7 +165,7 @@
To:
<?php $form = $this->form($this->model); ?>
- <div pipes:for="tags">
+ <div argil:for="tags">
<label for="form__bookmark__tags">Tags</label>
<input id="form__bookmark__tags" \
type="text"
@@ -182,12 +182,12 @@
<?php $form = $this->form($this->model); ?>
-The `form()` call above calls the PipesCore_Helpers_Form object to work
+The `form()` call above calls the ArgilCore_Helpers_Form object to work
as a Helper. Helpers can be in any project and are accessed in Views by
calling `$this->helperName()`. All this line does is start the generating
of a Form object.
- <div pipes:for="tags">
+ <div argil:for="tags">
This line uses an XML Namespace to signify that this should be used by the
Form object to be displayed whenever a `tags` element is encountered while
@@ -198,7 +198,7 @@
type="text"
name="bookmark[tags]" ...
-All form elements in Pipes contain IDs that are mapped out as
+All form elements in Argil contain IDs that are mapped out as
`form__<model_name>__<column_name>`. All form elements that are to be
submitted should also have a name in the format of `<model_name>[<column_name>]`
@@ -212,7 +212,7 @@
?>" />
The `value` of the `input` tag uses a new foreach(). By calling the `tags`
-attribute on the Model, we're asking Pipes to find any related objects. The
+attribute on the Model, we're asking Argil to find any related objects. The
text of a tag's name is in it's `name` attribute, so we're just creating a list
of space-separated tags as the value.
@@ -246,7 +246,7 @@
Of course, you can make those labels anything you would like. Another thing
you might have noticed is that the `url` input box is a `textarea`. This is
-because Pipes sees the `BLOB` data type and thinks it should display something
+because Argil sees the `BLOB` data type and thinks it should display something
to accomodate it. Since we want it to act like a normal string, just one with
a lot of storage, we can set another override in the Meta file and it will
automatically display as a text input. Change 'url' to look like:
@@ -263,7 +263,7 @@
------------------------------
Now that you can add Tags to Bookmark entries, you'll want to be able to see
them on the browse page. To do this, you'll need to edit the
-`MyProject/PipesDemo/Views/Bookmark/browse.php` file and tell it how to display
+`MyProject/ArgilDemo/Views/Bookmark/browse.php` file and tell it how to display
the Tags. In this case, change:
foreach ($this->modelList as $model) {
@@ -274,7 +274,7 @@
foreach ($this->modelList as $model) {
?>
- <td pipes:for="tags">
+ <td argil:for="tags">
<?php
foreach ($model->tags as $tag) {
echo $tag->name . ' ';
@@ -286,7 +286,7 @@
<?php
}
-Again, we're using `pipes:for` to specify that when we get to the `tags`
+Again, we're using `argil:for` to specify that when we get to the `tags`
element, we already have it determined how we want it to display. This uses
the same `foreach` that is used in the `edit.php` template to display the tag
name as a space-separated list. Save the file, and refresh your browse and now
@@ -296,10 +296,10 @@
Making URLs links
-----------------
One last change to make is to make the URL fields on the browse page links. As
-you might guess, it's just a matter of adding a new `pipes:for` field. In this
-case, before `<td pipes:for="tags">`, add in the following:
+you might guess, it's just a matter of adding a new `argil:for` field. In this
+case, before `<td argil:for="tags">`, add in the following:
- <td pipes:for="url">
+ <td argil:for="url">
<a href="<?php echo $model->url; ?>"><?php echo $model->url; ?></a>
</td>
@@ -310,13 +310,13 @@
Conclusion and Final Notes
--------------------------
-This tutorial covers basic use of Pipes. It shows you how to create a new
+This tutorial covers basic use of Argil. It shows you how to create a new
project, make sure it's configured, and how to edit the view files to create
some custom displays on the edit and browse pages.
There are a few things missing:
-1. First, the tags aren't clickable. As of this release, Pipes does not have
+1. First, the tags aren't clickable. As of this release, Argil does not have
a tag action in the Controller to handle displaying elements by tags. This
functionality will be in future releases.
2. There is now user authentication built-in. This is planned for version 0.2.
Modified: trunk/docs/HowTos/HelloWorld
===================================================================
--- trunk/docs/HowTos/HelloWorld 2007-02-20 23:57:43 UTC (rev 493)
+++ trunk/docs/HowTos/HelloWorld 2007-02-21 01:06:13 UTC (rev 494)
@@ -1,25 +1,25 @@
How to build a simple Hello World application
=============================================
-Although Pipes is designed to be used in a database driven environment with
+Although Argil is designed to be used in a database driven environment with
dynamic content, it works equally well to serve up static content. This
quick tutorial will walk you through the process of creating a controller
to return static contents and introduce you to the Controller and View in
-Pipes.
+Argil.
Hello World in Sixty Seconds
----------------------------
-*Step One* [Install](../InstallingPipes) Pipes
+*Step One* [Install](../InstallingArgil) Argil
-*Step Two* Create a project by running `pipes start MyProject`
+*Step Two* Create a project by running `argil start MyProject`
*Step Three* Create the `MyProject/Controllers/HelloWorldController.php` file
<?php
- require_once 'Pipes/Controller.php';
+ require_once 'Argil/Controller.php';
class MyProject_Controllers_HelloWorldController
- extends Pipes_Controller
+ extends Argil_Controller
{
}
@@ -33,19 +33,19 @@
*Step Six* Read on to understand what you just did...
-What is Pipes?
+What is Argil?
--------------
-In buzzwords, Pipes is a rapid application development framework utilizing
+In buzzwords, Argil is a rapid application development framework utilizing
the MVC design pattern. In laymen's terms, it's a quick way to get from
idea in your head to working idea in code.
First Step
----------
-The step is to create a project. To do this, you will execute the 'pipes'
+The step is to create a project. To do this, you will execute the 'argil'
program from the command line to start your project:
- $ /path/to/pipes start MyProject --disable-database
+ $ /path/to/argil start MyProject --disable-database
### What is a project? ###
@@ -56,9 +56,9 @@
### Configuration - not so much ###
-The `pipes start ...` command above created a directory called `./MyProject`.
+The `argil start ...` command above created a directory called `./MyProject`.
That directory contains the normal sub-directories and files required for
-Pipes to run. While Pipes uses convention over configuration for the majority
+Argil to run. While Argil uses convention over configuration for the majority
of the heavily lifting, it does need a few things defined so it can run. If
you opening the 'MyProject/config.php' file, you will see a file that looks
roughly like:
@@ -67,7 +67,7 @@
$config = array(
'projects' => array(
- 'PipesCore',
+ 'ArgilCore',
'MyProject'
)
);
@@ -77,12 +77,12 @@
The `$config` variable is what will be returned at the end of the config file.
The item of interest in it right now is the array `projects`. You'll note that
-it currently contains two values, `PipesCore` and `MyProject`. The latter
-you'll recognize as project name you gave `pipes` earlier. The `PipesCore`
-line is included to give you access to core pieces of Pipes, such as tagging,
+it currently contains two values, `ArgilCore` and `MyProject`. The latter
+you'll recognize as project name you gave `argil` earlier. The `ArgilCore`
+line is included to give you access to core pieces of Argil, such as tagging,
while allowing you to easily override them by providing your own.
-Several parts of Pipes, including all Model related objects, Views, and Helpers
+Several parts of Argil, including all Model related objects, Views, and Helpers
(Controllers are upcoming) are loaded via file loaders that use the `projects`
to determine the prefix of the class you are loaded. They are checked in
reverse order.
@@ -90,14 +90,14 @@
### MyProject/Public ###
The other file worth noting is `MyProject/Public`. This contains a sample
-bootstrap file to get Pipes running. Generally, you will want to make a
+bootstrap file to get Argil running. Generally, you will want to make a
symlink of this directory to some publicly accessible directory inside your
document root.
Creating the Controller
-----------------------
-An intregal, and required, part of Pipes is the Controller. Though the
+An intregal, and required, part of Argil is the Controller. Though the
Controller is required in order for any application to work, its use is
straight forward and simple. You need to create a new file in the
`MyProject/Controllers` directory called `HelloWorldController.php`. The
@@ -105,22 +105,22 @@
<?php
- require_once 'Pipes/Controller.php';
+ require_once 'Argil/Controller.php';
- class MyProject_Controllers_HelloWorldController
+ class MyProject_Controllers_HelloWorldController extends Argil_Controller
{
}
### PEAR Class Naming Convention ###
If you're familiar with PEAR, you'll notice that this file uses the PEAR
-class naming convention. This is true of all files in Pipes, every *_* is
+class naming convention. This is true of all files in Argil, every *_* is
equivalent to another directory level in the filesystem.
Creating the View
-----------------
-That's it for the Controller - really. In it's current form, Pipes favors
+That's it for the Controller - really. In it's current form, Argil favors
meta-programming, meaning that by extending an abstract super-class, it can
figure out what to do from there. Now, on to the view.
@@ -135,13 +135,13 @@
<h1>Hello World!</h1>
Assuming you have a copy or symlink of `MyProject/Public/index.php` accessible
-at `http://localhost/pipes/`, load the URL to see your handy work:
+at `http://localhost/argil/`, load the URL to see your handy work:
- http://localhost/pipes/index.php/HelloWorld
+ http://localhost/argil/index.php/HelloWorld
### No Actions?! ###
-Pipes does not require actions when all that is being done rendering static
+Argil does not require actions when all that is being done rendering static
content. This removes one extra step for static pages. In dynamic settings,
however, actions are extremely useful by allowing you to assign variables,
loading additional information, etc., that are to be used by the View. For
@@ -168,22 +168,22 @@
Conclusion
----------
This introduces you to the concept of projects, Controllers, and Views within
-Pipes. This just scratches the surface of what Pipes is and will be capable
+Argil. This just scratches the surface of what Argil is and will be capable
of by demonstrating how to create a simple HelloWorld application by hand.
-Using the other parameter in the `pipes` program, `create`, these files would
+Using the other parameter in the `argil` program, `create`, these files would
be created for you, but only if you are using a database.
Final Note on Development
-------------------------
-It should be noted that as of the writing of this how-to, Pipes is at its
+It should be noted that as of the writing of this how-to, Argil is at its
very early stages of development. While it does have a lot of features
included in this first release, it is probably not ready for a production
environment unless you are ready to keep up with a rapid pace of development.
While every reasonable effort has been made to make wise choices up front
-in regards to the internal API of Pipes, it is entirely possible that it will
+in regards to the internal API of Argil, it is entirely possible that it will
change slightly until a release is reached. The first intended stable release
and API freeze is planned for version 0.5 (see misc/Roadmap.txt).
-If you're interested in keeping up with Pipes development, be sure to join
-the [pipes-talk Google Group](http://groups-beta.google.com/group/pipes-talk/).
+If you're interested in keeping up with Argil development, be sure to join
+the [argil-talk mailing list](https://lists.sourceforge.net/lists/listinfo/argil-talk).
Copied: trunk/docs/InstallingArgil (from rev 477, trunk/docs/InstallingPipes)
===================================================================
--- trunk/docs/InstallingArgil (rev 0)
+++ trunk/docs/InstallingArgil 2007-02-21 01:06:13 UTC (rev 494)
@@ -0,0 +1,33 @@
+Installing Argil
+================
+Argil can currently be manually installed or installed via Subversion.
+
+
+Manually installing Argil
+-------------------------
+* Downloaded the latest release tarball (see http://phpinargil.org for latest)
+* Uncompress tarball into readable directory
+* Continue to *Steps for Manual and SVN installations*
+
+
+Installing Argil from Subversion
+--------------------------------
+* Checkout the latest tag from the SVN repo (i.e. http://phpinargil.googlecode.com/svn/tags/0.1)
+ (See notes on release numbers for more information about what release numbers mean)
+* Continue to *Steps for Manual and SVN installations*
+
+
+Steps for Manual and SVN installations
+--------------------------------------
+* Create sym-link of `scripts/argil` into an executable path (see *Copying
+ `argil`* if you plan on making a copy of the `argil` script)
+* Run `argil` from the command line to make sure everything is working
+
+
+Copying `argil`
+---------------
+If you plan on copying the `argil` executable, you will need to edit the
+`set_include_path()` call on line 4 to make sure it points to the `src/`
+directory in the Argil tree. Alternatively, you can copy `src/Argil/`,
+`src/ArgilCore`, and `src/ArgilImpl` into the PHP's `include_path` and
+comment out line 4 all together.
Deleted: trunk/docs/InstallingPipes
===================================================================
--- trunk/docs/InstallingPipes 2007-02-20 23:57:43 UTC (rev 493)
+++ trunk/docs/InstallingPipes 2007-02-21 01:06:13 UTC (rev 494)
@@ -1,33 +0,0 @@
-Installing Pipes
-================
-Pipes can currently be manually installed or installed via Subversion.
-
-
-Manually installing Pipes
--------------------------
-* Downloaded the latest release tarball (see http://phpinpipes.org for latest)
-* Uncompress tarball into readable directory
-* Continue to *Steps for Manual and SVN installations*
-
-
-Installing Pipes from Subversion
---------------------------------
-* Checkout the latest tag from the SVN repo (i.e. http://phpinpipes.googlecode.com/svn/tags/0.1)
- (See notes on release numbers for more information about what release numbers mean)
-* Continue to *Steps for Manual and SVN installations*
-
-
-Steps for Manual and SVN installations
---------------------------------------
-* Create sym-link of `scripts/pipes` into an executable path (see *Copying
- `pipes`* if you plan on making a copy of the `pipes` script)
-* Run `pipes` from the command line to make sure everything is working
-
-
-Copying `pipes`
----------------
-If you plan on copying the `pipes` executable, you will need to edit the
-`set_include_path()` call on line 4 to make sure it points to the `src/`
-directory in the Pipes tree. Alternatively, you can copy `src/Pipes/`,
-`src/PipesCore`, and `src/PipesImpl` into the PHP's `include_path` and
-comment out line 4 all together.
Modified: trunk/docs/Manifesto
===================================================================
--- trunk/docs/Manifesto 2007-02-20 23:57:43 UTC (rev 493)
+++ trunk/docs/Manifesto 2007-02-21 01:06:13 UTC (rev 494)
@@ -1,19 +1,19 @@
-PHP In Pipes Express Scaffolding Manifesto
-==========================================
+Argil Framework
+===============
There are no PHP 5 MVC frameworks that do the work for you. The best code is
-self generating - that's what Pipes is all about. By creating a simple MVC
-framework and command line tool to go along with it, Pipes automates the grunt
+self generating - that's what Argil is all about. By creating a simple MVC
+framework and command line tool to go along with it, Argil automates the grunt
work required to make your code function.
-*Note*: This document represents what Pipes will be. This isn't poured in
-concrete yet, but this is the Manifesto that outlines where Pipes is headed on
+*Note*: This document represents what Argil will be. This isn't poured in
+concrete yet, but this is the Manifesto that outlines where Argil is headed on
its way to v1.0.
Three Things Matter: Generate, Generate, Generate
-------------------------------------------------
The best code generates itself. Generated code is already tested, already
-proven, and doesn't have typos. Pipes provides the tool to take your database
+proven, and doesn't have typos. Argil provides the tool to take your database
and generate the objects needed to make a basic app work. Then you focus on the
custom logic needed to make everything tick.
@@ -22,7 +22,7 @@
----------------------------
You should only need to design once: when you outline your database structure.
There are numerous tools available to help you create a database, but not as
-many to help you create code. Pipes allows you to create the database tables
+many to help you create code. Argil allows you to create the database tables
you want then it figures out what to do with all that data.
@@ -39,7 +39,7 @@
----------------------------------------
OO code isn't for everyone, but good decoupling practices generally follow an
OO style. Most systems introduce "flexibility" by forcing you to adhere to
-their naming style while Pipes implements its flex-points by using native PHP
+their naming style while Argil implements its flex-points by using native PHP
callbacks.
@@ -47,7 +47,7 @@
-----------------------------------------------
The DOM (Document Object Model) lets you navigate a properly formed XML or
XHTML document - those same markup languages you want your templates to output.
-Using a defined "pipes" namespace inside those documents you can control how
+Using a defined "argil" namespace inside those documents you can control how
templates are loaded. No new markup languages to learn.
@@ -55,7 +55,7 @@
------------------------
Denormalized databases are the norm, but creating all of the tables and code to
handle that denormalization is time consuming. By supplying a command line
-argument to the `pipes` script, it can create the code to handle your
+argument to the `argil` script, it can create the code to handle your
relationships and the required database tables automatically.
@@ -63,14 +63,14 @@
-------------------------------
Tagging has become the defacto categorization of Web2.0 and you probably want
your new app to have it. Your new framework should support tagging your new
-tables without any fuss. 'pipes create bookmarks --with=tags' and your new
+tables without any fuss. 'argil create Bookmark --with=Tag' and your new
bookmark controller will have tagging automatically built-in.
Service First: Built-in web services
------------------------------------
Focusing on Web2.0 means focusing on mashups. Mashups need Web Services.
-Pipes wraps HTTP request object for handling those requests to web services and
+Argil wraps HTTP request object for handling those requests to web services and
has a growing catalog of Web Services that it supports out of the box, including
del.icio.us, Yahoo! Geocoding, Amazon ECS, Amazon SQS, and Amazon S3.
Modified: trunk/docs/OneMinuteTutorial
===================================================================
--- trunk/docs/OneMinuteTutorial 2007-02-20 23:57:43 UTC (rev 493)
+++ trunk/docs/OneMinuteTutorial 2007-02-21 01:06:13 UTC (rev 494)
@@ -1,22 +1,22 @@
One Minute Tutotrial
====================
-What is Pipes
+What is Argil
-------------
-Pipes is a rapid application development framework designed to assist
+Argil is a rapid application development framework designed to assist
developers in creating MVC applications quickly and effectiently.
-How to use Pipes
+How to use Argil
----------------
-* [Install](./InstallingPipes) Pipes
-* Create the database you want to use - `pipes_demo`
+* [Install](./InstallingArgil) Argil
+* Create the database you want to use - `argil_demo`
* Add a table called `messages` with the fields `message_id` and `message`
-* Run `pipes start PipesDemo`
-* Change directories to `./PipesDemo'
+* Run `argil start ArgilDemo`
+* Change directories to `./ArgilDemo'
* Edit config.php, adjusting the PDO object to match your configuration
-* In the `./PipesDemo` directory, run `pipes create Message`
-* Create a link, or copy the files from `./PipesDemo/Public/` into a web
+* In the `./ArgilDemo` directory, run `argil create Message`
+* Create a link, or copy the files from `./ArgilDemo/Public/` into a web
accessible directory.
-* Assuming the previous step copied into /pipes/ of localhost, access your
- new application at `http://localhost/pipes/index.php/Message`
+* Assuming the previous step copied into /argil/ of localhost, access your
+ new application at `http://localhost/argil/index.php/Message`
Deleted: trunk/docs/PipesAjaxApi
===================================================================
--- trunk/docs/PipesAjaxApi 2007-02-20 23:57:43 UTC (rev 493)
+++ trunk/docs/PipesAjaxApi 2007-02-21 01:06:13 UTC (rev 494)
@@ -1,5 +0,0 @@
-Pipes Javascript/AJAX API
-=========================
-As I move past version 0.1 and toward 0.2, this page will contain an outline
-of the Javascript API.
-
This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.
|
|
From: <tsw...@us...> - 2007-02-20 23:57:42
|
Revision: 493
http://argil.svn.sourceforge.net/argil/?rev=493&view=rev
Author: tswicegood
Date: 2007-02-20 15:57:43 -0800 (Tue, 20 Feb 2007)
Log Message:
-----------
Remove test file
Removed Paths:
-------------
trunk/test
Deleted: trunk/test
===================================================================
This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.
|
|
From: <tsw...@us...> - 2007-02-20 15:35:16
|
Revision: 492
http://argil.svn.sourceforge.net/argil/?rev=492&view=rev
Author: tswicegood
Date: 2007-02-20 07:35:11 -0800 (Tue, 20 Feb 2007)
Log Message:
-----------
No new to assign the drawer to a variable
Modified Paths:
--------------
trunk/src/ArgilCore/Views/Demo/drawer.php
Modified: trunk/src/ArgilCore/Views/Demo/drawer.php
===================================================================
--- trunk/src/ArgilCore/Views/Demo/drawer.php 2007-02-20 15:34:37 UTC (rev 491)
+++ trunk/src/ArgilCore/Views/Demo/drawer.php 2007-02-20 15:35:11 UTC (rev 492)
@@ -7,5 +7,5 @@
</div>
<script type="text/javascript">
- var d = new Argil.Drawer('.drawer');
+ new Argil.Drawer('.drawer');
</script>
This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.
|
|
From: <tsw...@us...> - 2007-02-20 15:34:40
|
Revision: 491
http://argil.svn.sourceforge.net/argil/?rev=491&view=rev
Author: tswicegood
Date: 2007-02-20 07:34:37 -0800 (Tue, 20 Feb 2007)
Log Message:
-----------
Rename pipes CLI tool to argil
Added Paths:
-----------
trunk/scripts/argil
Removed Paths:
-------------
trunk/scripts/pipes
Copied: trunk/scripts/argil (from rev 477, trunk/scripts/pipes)
===================================================================
--- trunk/scripts/argil (rev 0)
+++ trunk/scripts/argil 2007-02-20 15:34:37 UTC (rev 491)
@@ -0,0 +1,56 @@
+#!/usr/bin/php
+<?php
+
+set_include_path(dirname(__FILE__) . '/../src/');
+
+require_once 'Argil/CommandLine/ArgumentParser.php';
+require_once 'Argil/FileSystem/Directory.php';
+require_once 'Argil/Generator/Start.php';
+require_once 'Argil/Generator/Create.php';
+
+$action = $argv[1];
+$argument = $argv[2];
+$rootPath = new Argil_FileSystem_Directory(getcwd());
+switch ($action) {
+ case 'start' :
+ $schema = array(
+ '--disable-database' => array(
+ 'name' => 'disable_database',
+ 'type' => 'bool'
+ ),
+ );
+ $parser = new Argil_CommandLine_ArgumentParser($schema);
+
+ $starter = new Argil_Generator_Start($rootPath, $parser->parse($argv));
+ $starter->start($argument);
+ break;
+
+ case 'create' :
+ $schema = array(
+ '--with' => array(
+ 'name' => 'with',
+ 'pattern' => Argil_CommandLine_ArgumentParser::PATTERN_WITH,
+ 'type' => 'array',
+ )
+ );
+ $parser = new Argil_CommandLine_ArgumentParser($schema);
+
+ $config = new Argil_Config('./config.php');
+ $creator = new Argil_Generator_Create($config, $rootPath->toString());
+ $creator->create($argument, $parser->parse($argv));
+ break;
+
+ default:
+ echo <<< END
+Congratulations! Argil is successfully installed.
+
+To start a project, run:
+ \$ argil start <ProjectName>
+
+To create basic MVC scaffolding, switch to the <ProjectName> directory and run:
+ \$ argil create <ModelName>
+
+
+END;
+ break;
+}
Deleted: trunk/scripts/pipes
===================================================================
--- trunk/scripts/pipes 2007-02-20 14:48:26 UTC (rev 490)
+++ trunk/scripts/pipes 2007-02-20 15:34:37 UTC (rev 491)
@@ -1,56 +0,0 @@
-#!/usr/bin/php
-<?php
-
-set_include_path(dirname(__FILE__) . '/../src/');
-
-require_once 'Pipes/CommandLine/ArgumentParser.php';
-require_once 'Pipes/FileSystem/Directory.php';
-require_once 'Pipes/Generator/Start.php';
-require_once 'Pipes/Generator/Create.php';
-
-$action = $argv[1];
-$argument = $argv[2];
-$rootPath = new Pipes_FileSystem_Directory(getcwd());
-switch ($action) {
- case 'start' :
- $schema = array(
- '--disable-database' => array(
- 'name' => 'disable_database',
- 'type' => 'bool'
- ),
- );
- $parser = new Pipes_CommandLine_ArgumentParser($schema);
-
- $starter = new Pipes_Generator_Start($rootPath, $parser->parse($argv));
- $starter->start($argument);
- break;
-
- case 'create' :
- $schema = array(
- '--with' => array(
- 'name' => 'with',
- 'pattern' => Pipes_CommandLine_ArgumentParser::PATTERN_WITH,
- 'type' => 'array',
- )
- );
- $parser = new Pipes_CommandLine_ArgumentParser($schema);
-
- $config = new Pipes_Config('./config.php');
- $creator = new Pipes_Generator_Create($config, $rootPath->toString());
- $creator->create($argument, $parser->parse($argv));
- break;
-
- default:
- echo <<< END
-Congratulations! Pipes is successfully installed.
-
-To start a project, run:
- \$ pipes start <ProjectName>
-
-To create basic MVC scaffolding, switch to the <ProjectName> directory and run:
- \$ pipes create <ModelName>
-
-
-END;
- break;
-}
This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.
|
|
From: <tsw...@us...> - 2007-02-20 14:48:28
|
Revision: 490
http://argil.svn.sourceforge.net/argil/?rev=490&view=rev
Author: tswicegood
Date: 2007-02-20 06:48:26 -0800 (Tue, 20 Feb 2007)
Log Message:
-----------
Add in a SlideWithTab to handle the drawer widget
Modified Paths:
--------------
trunk/src/ArgilCore/Public/css/layout.css
trunk/src/ArgilCore/Public/scripts/argil.moo.js
Added Paths:
-----------
trunk/src/ArgilCore/Controllers/DemoController.php
trunk/src/ArgilCore/Public/css/drawer.css
trunk/src/ArgilCore/Views/Demo/
trunk/src/ArgilCore/Views/Demo/drawer.php
Added: trunk/src/ArgilCore/Controllers/DemoController.php
===================================================================
--- trunk/src/ArgilCore/Controllers/DemoController.php (rev 0)
+++ trunk/src/ArgilCore/Controllers/DemoController.php 2007-02-20 14:48:26 UTC (rev 490)
@@ -0,0 +1,10 @@
+<?php
+
+require_once 'Argil/Controller.php';
+
+class ArgilCore_Controllers_DemoController extends Argil_Controller
+{
+ public function actionDrawer() {
+ return $this->_viewFactory('drawer');
+ }
+}
Added: trunk/src/ArgilCore/Public/css/drawer.css
===================================================================
--- trunk/src/ArgilCore/Public/css/drawer.css (rev 0)
+++ trunk/src/ArgilCore/Public/css/drawer.css 2007-02-20 14:48:26 UTC (rev 490)
@@ -0,0 +1,11 @@
+.drawer {
+ border:1px solid red;
+ background-color:#f9f9f9;
+}
+
+.drawer-wrapper {
+ position:absolute;
+}
+.drawer-toggle {
+ position:relative;
+}
Modified: trunk/src/ArgilCore/Public/css/layout.css
===================================================================
--- trunk/src/ArgilCore/Public/css/layout.css 2007-02-20 14:47:20 UTC (rev 489)
+++ trunk/src/ArgilCore/Public/css/layout.css 2007-02-20 14:48:26 UTC (rev 490)
@@ -1,6 +1,9 @@
/* Form loading modal styling */
@import url("loading.css");
+/* Handle drawer CSS */
+@import url('drawer.css');
+
body {
font-family: sans-serif;
font-size: 12px;
Modified: trunk/src/ArgilCore/Public/scripts/argil.moo.js
===================================================================
--- trunk/src/ArgilCore/Public/scripts/argil.moo.js 2007-02-20 14:47:20 UTC (rev 489)
+++ trunk/src/ArgilCore/Public/scripts/argil.moo.js 2007-02-20 14:48:26 UTC (rev 490)
@@ -231,7 +231,79 @@
});
+Argil.Drawer = new Moo.Class({
+ getOptions: function() {
+ return {
+ slider: {
+ duration: 500,
+ mode:'vertical',
+ },
+ wrapper: {
+ class: 'drawer-wrapper',
+ },
+ toggle: {
+ textIn: 'Hide',
+ textOut: 'Show',
+ class: 'drawer-toggle',
+ },
+ };
+ },
+ initialize: function(selector, options) {
+ this.options = Moo.Object.extend(this.getOptions(), options);
+ this.element = Moo.$E(selector);
+ this.wrapper = new Element('div')
+ .injectAfter(this.element)
+ .adopt(this.element)
+ .addClass(this.options.wrapper.class);
+ this.wrapper.setStyles({
+ position: 'absolute',
+ });
+// this.wrapper.style.top = '-' + this.element.style.height +'px';
+ this.wrapper.style.width = this.element.style.width;
+
+ var me = this;
+ a = new Moo.Element('a')
+ .addEvent('click', function(event) {
+ me.slider.toggle();
+ me.options.closed = !me.options.closed;
+ this.setHTML(me.options.closed ? me.options.toggle.textOut : me.options.toggle.textIn);
+ new Moo.Event(event).stop();
+ })
+ .setHTML('Click Me!')
+ .addClass(this.options.toggle.class)
+ a.href = '#';
+ this.element.adopt(a);
+
+ this.slider = new Argil.Fx.SlideWithTab(this.element, this.options.slider);
+
+ },
+});
+
Argil.Fx = {};
+Argil.Fx.SlideWithTab = Moo.Fx.Slide.extend({
+ initialize: function(el, options) {
+ this.parent(el, options);
+ this.options.tabSelector = this.options.tabSelector || '.drawer-toggle';
+ this.closed = false;
+
+ this.tabSize = Moo.$E(this.options.tabSelector, this.wrapper).getStyle('height').toInt();
+ },
+
+ /*
+ Property: slideOut
+ slides the elements out of the view horizontally or vertically, depending on the mode parameter or options.mode.
+ */
+
+ slideOut: function(mode){
+ return this.start(this[mode || this.options.mode](), [-(this.offset - this.tabSize), this.tabSize]);
+ },
+
+ toggle: function(mode){
+ if (this.wrapper.offsetHeight == this.tabSize || this.wrapper.offsetWidth == this.tabSize) return this.slideIn(mode);
+ else return this.slideOut(mode);
+ },
+
+});
Argil.Fx.FadeOutAndRemove = new Moo.Class({
initialize: function(selector, options) {
this.element = $(selector);
Added: trunk/src/ArgilCore/Views/Demo/drawer.php
===================================================================
--- trunk/src/ArgilCore/Views/Demo/drawer.php (rev 0)
+++ trunk/src/ArgilCore/Views/Demo/drawer.php 2007-02-20 14:48:26 UTC (rev 490)
@@ -0,0 +1,11 @@
+<div class="drawer">
+ <ul>
+ <li>Item One</li>
+ <li>Item Two</li>
+ <li>Item Three</li>
+ </ul>
+</div>
+
+<script type="text/javascript">
+ var d = new Argil.Drawer('.drawer');
+</script>
This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.
|
|
From: <tsw...@us...> - 2007-02-20 14:47:51
|
Revision: 489
http://argil.svn.sourceforge.net/argil/?rev=489&view=rev
Author: tswicegood
Date: 2007-02-20 06:47:20 -0800 (Tue, 20 Feb 2007)
Log Message:
-----------
Make all of the other function calls utilize the Moo namespace
Modified Paths:
--------------
trunk/src/ArgilCore/Public/scripts/mootools.full.v1.00.js
Modified: trunk/src/ArgilCore/Public/scripts/mootools.full.v1.00.js
===================================================================
--- trunk/src/ArgilCore/Public/scripts/mootools.full.v1.00.js 2007-02-19 02:32:53 UTC (rev 488)
+++ trunk/src/ArgilCore/Public/scripts/mootools.full.v1.00.js 2007-02-20 14:47:20 UTC (rev 489)
@@ -270,7 +270,7 @@
*/
Moo.$pick = function(obj, picked){
- return ($type(obj)) ? obj : picked;
+ return (Moo.$type(obj)) ? obj : picked;
};
/*
@@ -1068,8 +1068,8 @@
*/
initialize: function(el){
- if ($type(el) == 'string') el = document.createElement(el);
- return $(el);
+ if (Moo.$type(el) == 'string') el = document.createElement(el);
+ return Moo.$(el);
}
});
@@ -1102,8 +1102,8 @@
Moo.$ = function(el){
if (!el) return false;
if (el._element_extended_ || [Moo.window, document].test(el)) return el;
- if ($type(el) == 'string') el = document.getElementById(el);
- if ($type(el) != 'element') return false;
+ if (Moo.$type(el) == 'string') el = document.getElementById(el);
+ if (Moo.$type(el) != 'element') return false;
if (['object', 'embed'].test(el.tagName.toLowerCase()) || el.extend) return el;
el._element_extended_ = true;
Moo.Garbage.collect(el);
@@ -1147,14 +1147,14 @@
if (arguments[0]._elements_extended_) return arguments[0];
}
var elements = [];
- $each(arguments, function(selector){
- switch ($type(selector)){
+ Moo.$each(arguments, function(selector){
+ switch (Moo.$type(selector)){
case 'element': elements.push($(selector)); break;
case 'string': selector = document.getElementsBySelector(selector);
default:
if (selector.length){
- $each(selector, function(el){
- if ($(el)) elements.push(el);
+ Moo.$each(selector, function(el){
+ if (Moo.$(el)) elements.push(el);
});
}
}
@@ -1168,12 +1168,12 @@
var args = arguments;
var items = [];
var elements = true;
- $each(this, function(el){
+ Moo.$each(this, function(el){
var returns = el[property].apply(el, args);
- if ($type(returns) != 'element') elements = false;
+ if (Moo.$type(returns) != 'element') elements = false;
items.push(returns);
});
- if (elements) items = $$(items);
+ if (elements) items = Moo.$$(items);
return items;
};
};
@@ -1194,12 +1194,12 @@
Moo.Element.extend({
inject: function(el, where){
- el = $(el) || new Moo.Element(el);
+ el = Moo.$(el) || new Moo.Element(el);
switch (where){
- case "before": $(el.parentNode).insertBefore(this, el); break;
+ case "before": Moo.$(el.parentNode).insertBefore(this, el); break;
case "after":
- if (!el.getNext()) $(el.parentNode).appendChild(this);
- else $(el.parentNode).insertBefore(this, el.getNext());
+ if (!el.getNext()) Moo.$(el.parentNode).appendChild(this);
+ else Moo.$(el.parentNode).insertBefore(this, el.getNext());
break;
case "inside": el.appendChild(this);
}
@@ -1258,7 +1258,7 @@
*/
adopt: function(el){
- this.appendChild($(el) || new Moo.Element(el));
+ this.appendChild(Moo.$(el) || new Moo.Element(el));
return this;
},
@@ -1289,7 +1289,7 @@
clone: function(contents){
var el = this.cloneNode(contents !== false);
- return $(el);
+ return Moo.$(el);
},
/*
@@ -1308,7 +1308,7 @@
*/
replaceWith: function(el){
- el = $(el) || new Moo.Element(el);
+ el = Moo.$(el) || new Moo.Element(el);
this.parentNode.replaceChild(el, this);
return el;
},
@@ -1440,7 +1440,7 @@
*/
setStyles: function(source){
- switch ($type(source)){
+ switch (Moo.$type(source)){
case 'object':
for (var property in source) this.setStyle(property, source[property]);
break;
@@ -1492,8 +1492,8 @@
getStyle: function(property){
property = property.camelCase();
var style = this.style[property] || false;
- if (!$chk(style)){
- if (property == 'opacity') return $chk(this.opacity) ? this.opacity : 1;
+ if (!Moo.$chk(style)){
+ if (property == 'opacity') return Moo.$chk(this.opacity) ? this.opacity : 1;
if (['margin', 'padding'].test(property)){
return [this.getStyle(property+'-top') || 0, this.getStyle(property+'-right') || 0,
this.getStyle(property+'-bottom') || 0, this.getStyle(property+'-left') || 0].join(' ');
@@ -1596,8 +1596,8 @@
getBrother: function(what){
var el = this[what+'Sibling'];
- while ($type(el) == 'whitespace') el = el[what+'Sibling'];
- return $(el);
+ while (Moo.$type(el) == 'whitespace') el = el[what+'Sibling'];
+ return Moo.$(el);
},
/*
@@ -1631,8 +1631,8 @@
getFirst: function(){
var el = this.firstChild;
- while ($type(el) == 'whitespace') el = el.nextSibling;
- return $(el);
+ while (Moo.$type(el) == 'whitespace') el = el.nextSibling;
+ return Moo.$(el);
},
/*
@@ -1642,8 +1642,8 @@
getLast: function(){
var el = this.lastChild;
- while ($type(el) == 'whitespace') el = el.previousSibling;
- return $(el);
+ while (Moo.$type(el) == 'whitespace') el = el.previousSibling;
+ return Moo.$(el);
},
/*
@@ -1652,7 +1652,7 @@
*/
getParent: function(){
- return $(this.parentNode);
+ return Moo.$(this.parentNode);
},
/*
@@ -1661,7 +1661,7 @@
*/
getChildren: function(){
- return $$(this.childNodes);
+ return Moo.$$(this.childNodes);
},
/*
@@ -1681,8 +1681,8 @@
case 'class': this.className = value; break;
case 'style': this.setStyles(value); break;
case 'name': if (Moo.window.ie6){
- var el = $(document.createElement('<'+this.getTag()+' name="'+value+'" />'));
- $each(this.attributes, function(attribute){
+ var el = Moo.$(document.createElement('<'+this.getTag()+' name="'+value+'" />'));
+ Moo.$each(this.attributes, function(attribute){
if (attribute.name != 'name') el.setProperty(attribute.name, attribute.value);
});
if (this.parentNode) this.replaceWith(el);
@@ -1727,7 +1727,7 @@
*/
setHTML: function(){
- this.innerHTML = $A(arguments).join('');
+ this.innerHTML = Moo.$A(arguments).join('');
return this;
},
@@ -2244,7 +2244,7 @@
this.options = Moo.Object.extend(defaults, options);
if (this.addEvent){
for (var option in this.options){
- if (($type(this.options[option]) == 'function') && option.test(/^on[A-Z]/)) this.addEvent(option, this.options[option]);
+ if ((Moo.$type(this.options[option]) == 'function') && option.test(/^on[A-Z]/)) this.addEvent(option, this.options[option]);
}
}
return this;
@@ -2260,7 +2260,7 @@
Moo.Group = new Moo.Class({
initialize: function(){
- this.instances = $A(arguments);
+ this.instances = Moo.$A(arguments);
this.events = {};
this.checker = {};
},
@@ -2322,7 +2322,7 @@
*/
Moo.$E = function(selector, filter){
- return ($(filter) || document).getElement(selector);
+ return (Moo.$(filter) || document).getElement(selector);
};
/*
@@ -2343,7 +2343,7 @@
*/
Moo.$ES = function(selector, filter){
- return ($(filter) || document).getElementsBySelector(selector);
+ return (Moo.$(filter) || document).getElementsBySelector(selector);
};
/*
@@ -2378,7 +2378,7 @@
if (!el || ((param[1] != '*') && (Element.prototype.getTag.call(el) != param[1]))) return;
elements = [el];
} else {
- elements = $A(this.getElementsByTagName(param[1]));
+ elements = Moo.$A(this.getElementsByTagName(param[1]));
}
} else {
elements = Moo.Elements.prototype.getElementsByTagName.call(elements, param[1], true);
@@ -2387,7 +2387,7 @@
if (param[3]) elements = elements.filter(Moo.Filters.className);
if (param[4]) elements = elements.filter(Moo.Filters.attribute);
}, this);
- return $$(elements);
+ return Moo.$$(elements);
},
/*
@@ -2427,7 +2427,7 @@
selector.split(',').each(function(sel){
els.extend(this.getElements(sel));
}, this);
- return $$(els);
+ return Moo.$$(els);
}
});
@@ -2743,8 +2743,8 @@
*/
mix: function(){
- var colors = $A(arguments);
- var alpha = ($type(colors[colors.length-1]) == 'number') ? colors.pop() : 50;
+ var colors = Moo.$A(arguments);
+ var alpha = (Moo.$type(colors[colors.length-1]) == 'number') ? colors.pop() : 50;
var rgb = this.copy();
colors.each(function(color){
color = new Moo.Color(color);
@@ -2929,7 +2929,7 @@
var domReady = function(){
if (this.loaded) return;
this.loaded = true;
- if (this.timer) this.timer = $clear(this.timer);
+ if (this.timer) this.timer = Moo.$clear(this.timer);
Element.prototype.fireEvent.call(this, 'domready');
this.events.domready = null;
}.bind(this);
@@ -2940,7 +2940,7 @@
}
else if (document.readyState && this.ie){ //ie
document.write("<script id=ie_ready defer src=javascript:void(0)><\/script>");
- $('ie_ready').onreadystatechange = function(){
+ Moo.$('ie_ready').onreadystatechange = function(){
if (this.readyState == 'complete') domReady();
};
} else { //others
@@ -3203,7 +3203,7 @@
stop: function(end){
if (!this.timer) return this;
- this.timer = $clear(this.timer);
+ this.timer = Moo.$clear(this.timer);
if (!end) this.fireEvent('onCancel', this.element);
return this;
},
@@ -3359,7 +3359,7 @@
Moo.Fx.Style = Moo.Fx.Base.extend({
initialize: function(el, property, options){
- this.element = $(el);
+ this.element = Moo.$(el);
this.property = property;
this.parent(options);
},
@@ -3469,7 +3469,7 @@
Moo.Fx.Styles = Moo.Fx.Base.extend({
initialize: function(el, options){
- this.element = $(el);
+ this.element = Moo.$(el);
this.parent(options);
},
@@ -3563,7 +3563,7 @@
Moo.Fx.Elements = Moo.Fx.Base.extend({
initialize: function(elements, options){
- this.elements = $$(elements);
+ this.elements = Moo.$$(elements);
this.parent(options);
},
@@ -3656,7 +3656,7 @@
initialize: function(element, options){
this.now = [];
- this.element = $(element);
+ this.element = Moo.$(element);
this.addEvent('onStart', function(){
this.element.addEvent('mousewheel', this.stop.bind(this, false));
}.bind(this));
@@ -3685,7 +3685,7 @@
var values = {'x': x, 'y': y};
for (var z in el.size){
var max = el.scrollSize[z] - el.size[z];
- if ($chk(values[z])) values[z] = ($type(values[z]) == 'number') ? Math.max(Math.min(values[z], max), 0) : max;
+ if (Moo.$chk(values[z])) values[z] = (Moo.$type(values[z]) == 'number') ? Math.max(Math.min(values[z], max), 0) : max;
else values[z] = el.scroll[z];
}
return this.start([el.scroll.x, el.scroll.y], [values.x, values.y]);
@@ -3736,7 +3736,7 @@
*/
toElement: function(el){
- return this.scrollTo($(el).getLeft(), $(el).getTop());
+ return this.scrollTo(Moo.$(el).getLeft(), Moo.$(el).getTop());
},
increase: function(){
@@ -3777,7 +3777,7 @@
Moo.Fx.Slide = Moo.Fx.Base.extend({
initialize: function(el, options){
- this.element = $(el).setStyle('margin', 0);
+ this.element = Moo.$(el).setStyle('margin', 0);
this.wrapper = new Moo.Element('div').injectAfter(this.element).setStyle('overflow', 'hidden').adopt(this.element);
this.setOptions({'mode': 'vertical'}, options);
this.now = [];
@@ -3808,6 +3808,8 @@
*/
slideIn: function(mode){
+ console.log(this[mode || this.options.mode]());
+ console.log([0, this.offset]);
return this.start(this[mode || this.options.mode](), [0, this.offset]);
},
@@ -3817,6 +3819,8 @@
*/
slideOut: function(mode){
+ console.log(this[mode || this.options.mode]());
+ console.log([0, this.offset]);
return this.start(this[mode || this.options.mode](), [-this.offset, 0]);
},
@@ -4121,8 +4125,8 @@
initialize: function(el, options){
this.setOptions(this.getOptions(), options);
- this.element = $(el);
- this.handle = $(this.options.handle) || this.element;
+ this.element = Moo.$(el);
+ this.handle = Moo.$(this.options.handle) || this.element;
this.mouse = {'now': {}, 'pos': {}};
this.value = {'start': {}, 'now': {}};
this.bound = {'start': this.start.bindWithEvent(this)};
@@ -4144,7 +4148,7 @@
this.mouse.pos[z] = event.page[z] - this.value.now[z];
if (limit && limit[z]){
for (var i = 0; i < 2; i++){
- if ($chk(limit[z][i])) this.limit[z][i] = limit[z][i].apply ? limit[z][i].call(this) : limit[z][i];
+ if (Moo.$chk(limit[z][i])) this.limit[z][i] = limit[z][i].apply ? limit[z][i].call(this) : limit[z][i];
}
}
}
@@ -4175,10 +4179,10 @@
for (var z in this.options.modifiers){
this.value.now[z] = this.mouse.now[z] - this.mouse.pos[z];
if (this.limit[z]){
- if ($chk(this.limit[z][1]) && (this.value.now[z] > this.limit[z][1])){
+ if (Moo.$chk(this.limit[z][1]) && (this.value.now[z] > this.limit[z][1])){
this.value.now[z] = this.limit[z][1];
this.out = true;
- } else if ($chk(this.limit[z][0]) && (this.value.now[z] < this.limit[z][0])){
+ } else if (Moo.$chk(this.limit[z][0]) && (this.value.now[z] < this.limit[z][0])){
this.value.now[z] = this.limit[z][0];
this.out = true;
}
@@ -4263,18 +4267,18 @@
initialize: function(el, options){
this.setOptions(this.getExtended(), options);
- this.element = $(el);
+ this.element = Moo.$(el);
this.position = this.element.getStyle('position');
- this.droppables = $$(this.options.droppables);
+ this.droppables = Moo.$$(this.options.droppables);
if (!['absolute', 'relative'].test(this.position)) this.position = 'absolute';
var top = this.element.getStyle('top').toInt();
var left = this.element.getStyle('left').toInt();
if (this.position == 'absolute'){
- top = $chk(top) ? top : this.element.getTop();
- left = $chk(left) ? left : this.element.getLeft();
+ top = Moo.$chk(top) ? top : this.element.getTop();
+ left = Moo.$chk(left) ? left : this.element.getLeft();
} else {
- top = $chk(top) ? top : 0;
- left = $chk(left) ? left : 0;
+ top = Moo.$chk(top) ? top : 0;
+ left = Moo.$chk(left) ? left : 0;
}
this.element.setStyles({
'top': top+'px',
@@ -4285,7 +4289,7 @@
},
start: function(event){
- this.container = $(this.options.container);
+ this.container = Moo.$(this.options.container);
if (this.container){
var cont = this.container.getCoordinates();
var el = this.element.getCoordinates();
@@ -4310,7 +4314,7 @@
this.parent(event);
if (this.out) return this;
this.droppables.each(function(drop){
- if (this.checkAgainst($(drop))){
+ if (this.checkAgainst(Moo.$(drop))){
if (!drop.overing) drop.fireEvent('over', [this.element, this]);
drop.overing = true;
} else {
@@ -4328,7 +4332,7 @@
stop: function(){
this.parent();
- this.timer = $clear(this.timer);
+ this.timer = Moo.$clear(this.timer);
if (this.out) return this;
var dropped = false;
this.droppables.each(function(drop){
@@ -4533,7 +4537,7 @@
},
onComplete: function(){
- if (this.options.update) $(this.options.update).setHTML(this.response.text);
+ if (this.options.update) Moo.$(this.options.update).setHTML(this.response.text);
if (this.options.evalResponse) eval(this.response.text);
if (this.options.evalScripts) this.evalScripts.delay(30, this);
this.fireEvent('onComplete', [this.response.text, this.response.xml], 20);
@@ -4554,8 +4558,8 @@
request: function(){
var data = null;
- switch ($type(this.options.postBody)){
- case 'element': data = $(this.options.postBody).toQueryString(); break;
+ switch (Moo.$type(this.options.postBody)){
+ case 'element': data = Moo.$(this.options.postBody).toQueryString(); break;
case 'object': data = Moo.Object.toQueryString(this.options.postBody); break;
case 'string': data = this.options.postBody;
}
@@ -4653,8 +4657,8 @@
toObject: function(){
var obj = {};
- $$(this.getElementsByTagName('input'), this.getElementsByTagName('select'), this.getElementsByTagName('textarea')).each(function(el){
- var name = $(el).name;
+ Moo.$$(this.getElementsByTagName('input'), this.getElementsByTagName('select'), this.getElementsByTagName('textarea')).each(function(el){
+ var name = Moo.$(el).name;
var value = el.getValue();
if ((value !== false) && name) obj[name] = value;
});
@@ -4795,7 +4799,7 @@
*/
toString: function(obj){
- switch ($type(obj)){
+ switch (Moo.$type(obj)){
case 'string':
return '"'+obj.replace(new RegExp('(["\\\\])', 'g'), '\\$1')+'"';
case 'array':
@@ -5012,7 +5016,7 @@
create: function(type, defaults, properties, inject){
Moo.Object.extend(defaults, properties || {});
var element = new Moo.Element(type).setProperties(defaults);
- if (inject) element.injectInside($$('head')[0]);
+ if (inject) element.injectInside(Moo.$$('head')[0]);
return element;
}
@@ -5073,7 +5077,7 @@
this.setOptions(this.getExtended(), options);
this.previous = -1;
if (this.options.alwaysHide) this.options.wait = true;
- if ($chk(this.options.show)){
+ if (Moo.$chk(this.options.show)){
this.options.display = false;
this.previous = this.options.show;
}
@@ -5081,8 +5085,8 @@
this.options.display = false;
this.options.show = false;
}
- this.togglers = $$(togglers);
- this.elements = $$(elements);
+ this.togglers = Moo.$$(togglers);
+ this.elements = Moo.$$(elements);
this.togglers.each(function(tog, i){
tog.addEvent('click', this.display.bind(this, i));
}, this);
@@ -5101,7 +5105,7 @@
else for (var fx in this.effects) el.setStyle(fx, 0);
}, this);
this.parent(this.elements, this.options);
- if ($chk(this.options.display)) this.display(this.options.display);
+ if (Moo.$chk(this.options.display)) this.display(this.options.display);
},
/*
@@ -5176,8 +5180,8 @@
initialize: function(element, options){
this.setOptions(this.getOptions(), options);
- this.element = $(element);
- this.mousemover = ([Moo.window, document].test(element)) ? $(document.body) : this.element;
+ this.element = Moo.$(element);
+ this.mousemover = ([Moo.window, document].test(element)) ? Moo.$(document.body) : this.element;
},
/*
@@ -5197,7 +5201,7 @@
stop: function(){
this.mousemover.removeEvent('mousemove', this.coord);
- this.timer = $clear(this.timer);
+ this.timer = Moo.$clear(this.timer);
},
getCoords: function(event){
@@ -5270,8 +5274,8 @@
},
initialize: function(el, knob, options){
- this.element = $(el);
- this.knob = $(knob);
+ this.element = Moo.$(el);
+ this.knob = Moo.$(knob);
this.setOptions(this.getOptions(), options);
this.previousChange = -1;
@@ -5412,10 +5416,10 @@
initialize: function(options){
this.addEvent('onCancel', this.clearChain);
var location = Moo.window.location.href.match(/^[^#]*/)[0] + '#';
- $each(document.links, function(lnk){
+ Moo.$each(document.links, function(lnk){
if (lnk.href.indexOf(location) != 0) return;
var anchor = lnk.href.substr(location.length);
- if (anchor && $(anchor)) this.useLink(lnk, anchor);
+ if (anchor && Moo.$(anchor)) this.useLink(lnk, anchor);
}, this);
this.parent(Moo.window, options);
},
@@ -5477,9 +5481,9 @@
initialize: function(list, options){
this.setOptions(this.getOptions(), options);
- this.list = $(list);
+ this.list = Moo.$(list);
this.elements = this.list.getChildren();
- this.handles = $$(this.options.handles) || this.elements;
+ this.handles = Moo.$$(this.options.handles) || this.elements;
this.drag = [];
this.bound = {'start': []};
this.elements.each(function(el, i){
@@ -5641,8 +5645,8 @@
'visibility': 'hidden'
}).injectInside(document.body);
this.wrapper = new Moo.Element('div').injectInside(this.toolTip);
- $each(elements, function(el){
- this.build($(el));
+ Moo.$each(elements, function(el){
+ this.build(Moo.$(el));
}, this);
if (this.options.initialize) this.options.initialize.call(this);
},
@@ -5682,12 +5686,12 @@
new Moo.Element('div').addClass(this.options.className+'-text').injectInside(this.wrapper)
).setHTML(el.myText);
}
- $clear(this.timer);
+ Moo.$clear(this.timer);
this.timer = this.show.delay(this.options.showDelay, this);
},
end: function(event){
- $clear(this.timer);
+ Moo.$clear(this.timer);
this.timer = this.hide.delay(this.options.hideDelay, this);
event.stop();
},
This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.
|
|
From: <tsw...@us...> - 2007-02-19 02:33:04
|
Revision: 488
http://argil.svn.sourceforge.net/argil/?rev=488&view=rev
Author: tswicegood
Date: 2007-02-18 18:32:53 -0800 (Sun, 18 Feb 2007)
Log Message:
-----------
Namespace an Event.keys reference and make sure $chk and $type were called within the namespace
Modified Paths:
--------------
trunk/src/ArgilCore/Public/scripts/mootools.full.v1.00.js
Modified: trunk/src/ArgilCore/Public/scripts/mootools.full.v1.00.js
===================================================================
--- trunk/src/ArgilCore/Public/scripts/mootools.full.v1.00.js 2007-02-19 02:29:36 UTC (rev 487)
+++ trunk/src/ArgilCore/Public/scripts/mootools.full.v1.00.js 2007-02-19 02:32:53 UTC (rev 488)
@@ -893,7 +893,7 @@
'periodical': false,
'attempt': false
}, options || {});
- if ($chk(options.arguments) && $type(options.arguments) != 'array') options.arguments = [options.arguments];
+ if (Moo.$chk(options.arguments) && Moo.$type(options.arguments) != 'array') options.arguments = [options.arguments];
return function(event){
var args;
if (options.event){
@@ -2054,7 +2054,7 @@
});
-Event.keys = {
+Moo.Event.keys = {
'enter': 13,
'up': 38,
'down': 40,
This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.
|
|
From: <tsw...@us...> - 2007-02-19 02:29:41
|
Revision: 487
http://argil.svn.sourceforge.net/argil/?rev=487&view=rev
Author: tswicegood
Date: 2007-02-18 18:29:36 -0800 (Sun, 18 Feb 2007)
Log Message:
-----------
Namespace all references to 'window'
Modified Paths:
--------------
trunk/src/ArgilCore/Public/scripts/mootools.full.v1.00.js
Modified: trunk/src/ArgilCore/Public/scripts/mootools.full.v1.00.js
===================================================================
--- trunk/src/ArgilCore/Public/scripts/mootools.full.v1.00.js 2007-02-19 02:22:43 UTC (rev 486)
+++ trunk/src/ArgilCore/Public/scripts/mootools.full.v1.00.js 2007-02-19 02:29:36 UTC (rev 487)
@@ -208,9 +208,12 @@
//window, document
-window.extend = document.extend = Moo.Object.extend;
-Moo.Window = window;
+Moo.document = document;
+Moo.window = window;
+Moo.window.extend = Moo.document.extend = Moo.Object.extend;
+Moo.Window = Moo.window;
+
/*
Function: $type
Returns the type of object that matches the element passed in.
@@ -322,13 +325,13 @@
window.gecko - will be set to true if the current browser is Mozilla/Gecko.
*/
-if (window.ActiveXObject) window.ie = window[window.XMLHttpRequest ? 'ie7' : 'ie6'] = true;
-else if (document.childNodes && !document.all && !navigator.taintEnabled) window.khtml = true;
-else if (document.getBoxObjectFor != null) window.gecko = true;
+if (Moo.window.ActiveXObject) Moo.window.ie = Moo.window[Moo.window.XMLHttpRequest ? 'ie7' : 'ie6'] = true;
+else if (Moo.document.childNodes && !Moo.document.all && !navigator.taintEnabled) Moo.window.khtml = true;
+else if (Moo.document.getBoxObjectFor != null) Moo.window.gecko = true;
//enables background image cache for internet explorer 6
-if (window.ie6) try {document.execCommand("BackgroundImageCache", false, true);} catch (e){};
+if (Moo.window.ie6) try {Moo.document.execCommand("BackgroundImageCache", false, true);} catch (e){};
/*
Script: Array.js
@@ -894,7 +897,7 @@
return function(event){
var args;
if (options.event){
- event = event || window.event;
+ event = event || Moo.window.event;
args = [(options.event === true) ? event : new options.event(event)];
if (options.arguments) args = args.concat(options.arguments);
}
@@ -1098,7 +1101,7 @@
Moo.$ = function(el){
if (!el) return false;
- if (el._element_extended_ || [window, document].test(el)) return el;
+ if (el._element_extended_ || [Moo.window, document].test(el)) return el;
if ($type(el) == 'string') el = document.getElementById(el);
if ($type(el) != 'element') return false;
if (['object', 'embed'].test(el.tagName.toLowerCase()) || el.extend) return el;
@@ -1323,7 +1326,7 @@
*/
appendText: function(text){
- if (window.ie){
+ if (Moo.window.ie){
switch(this.getTag()){
case 'style': this.styleSheet.cssText = text; return this;
case 'script': this.setProperty('text', text); return this;
@@ -1465,7 +1468,7 @@
if(this.style.visibility != "visible") this.style.visibility = "visible";
}
if (!this.currentStyle || !this.currentStyle.hasLayout) this.style.zoom = 1;
- if (window.ie) this.style.filter = "alpha(opacity=" + opacity*100 + ")";
+ if (Moo.window.ie) this.style.filter = "alpha(opacity=" + opacity*100 + ")";
this.style.opacity = this.opacity = opacity;
return this;
},
@@ -1520,7 +1523,7 @@
if (!this.events[type].keys.test(fn)){
this.events[type].keys.push(fn);
if (this.addEventListener){
- this.addEventListener((type == 'mousewheel' && window.gecko) ? 'DOMMouseScroll' : type, fn, false);
+ this.addEventListener((type == 'mousewheel' && Moo.window.gecko) ? 'DOMMouseScroll' : type, fn, false);
} else {
fn = fn.bind(this);
this.attachEvent('on'+type, fn);
@@ -1548,7 +1551,7 @@
if (pos == -1) return this;
var key = this.events[type].keys.splice(pos,1)[0];
if (this.removeEventListener){
- this.removeEventListener((type == 'mousewheel' && window.gecko) ? 'DOMMouseScroll' : type, key, false);
+ this.removeEventListener((type == 'mousewheel' && Moo.window.gecko) ? 'DOMMouseScroll' : type, key, false);
} else {
this.detachEvent('on'+type, this.events[type].values.splice(pos,1)[0]);
}
@@ -1677,7 +1680,7 @@
switch (property){
case 'class': this.className = value; break;
case 'style': this.setStyles(value); break;
- case 'name': if (window.ie6){
+ case 'name': if (Moo.window.ie6){
var el = $(document.createElement('<'+this.getTag()+' name="'+value+'" />'));
$each(this.attributes, function(attribute){
if (attribute.name != 'name') el.setProperty(attribute.name, attribute.value);
@@ -1905,9 +1908,9 @@
});
-window.addEvent = document.addEvent = Moo.Element.prototype.addEvent;
-window.removeEvent = document.removeEvent = Moo.Element.prototype.removeEvent;
-window.removeEvents = document.removeEvents = Moo.Element.prototype.removeEvents;
+Moo.window.addEvent = document.addEvent = Moo.Element.prototype.addEvent;
+Moo.window.removeEvent = document.removeEvent = Moo.Element.prototype.removeEvent;
+Moo.window.removeEvents = document.removeEvents = Moo.Element.prototype.removeEvents;
Moo.Garbage = {
@@ -1918,7 +1921,7 @@
},
trash: function(){
- Moo.Garbage.collect(window);
+ Moo.Garbage.collect(Moo.window);
Moo.Garbage.collect(document);
Moo.Garbage.elements.each(function(el){
el.removeEvents();
@@ -1929,7 +1932,7 @@
};
-window.addEvent('unload', Moo.Garbage.trash);
+Moo.window.addEvent('unload', Moo.Garbage.trash);
/*
Script: Event.js
@@ -1979,7 +1982,7 @@
Moo.Event = new Moo.Class({
initialize: function(event){
- this.event = event || window.event;
+ this.event = event || Moo.window.event;
this.type = this.event.type;
this.target = this.event.target || this.event.srcElement;
if (this.target.nodeType == 3) this.target = this.target.parentNode; // Safari
@@ -1988,7 +1991,7 @@
this.alt = this.event.altKey;
this.meta = this.event.metaKey;
if (['DOMMouseScroll', 'mousewheel'].test(this.type)){
- this.wheel = this.event.wheelDelta ? (this.event.wheelDelta / (window.opera ? -120 : 120)) : -(this.event.detail || 0) / 3;
+ this.wheel = this.event.wheelDelta ? (this.event.wheelDelta / (Moo.window.opera ? -120 : 120)) : -(this.event.detail || 0) / 3;
} else if (this.type.test(/key/)){
this.code = this.event.which || this.event.keyCode;
for (var name in Event.keys){
@@ -2005,8 +2008,8 @@
'y': this.event.pageY || this.event.clientY + document.documentElement.scrollTop
};
this.client = {
- 'x': this.event.pageX ? this.event.pageX - window.pageXOffset : this.event.clientX,
- 'y': this.event.pageY ? this.event.pageY - window.pageYOffset : this.event.clientY
+ 'x': this.event.pageX ? this.event.pageX - Moo.window.pageXOffset : this.event.clientX,
+ 'y': this.event.pageY ? this.event.pageY - Moo.window.pageYOffset : this.event.clientY
};
this.rightClick = (this.event.which == 3) || (this.event.button == 2);
switch (this.type){
@@ -2903,7 +2906,7 @@
Cross browser methods to get the window size, onDomReady method.
*/
-window.extend({
+Moo.window.extend({
/*
Property: window.addEvent
@@ -2986,7 +2989,7 @@
Warning: All these methods require that the browser operates in strict mode, not quirks mode.
*/
-window.extend({
+Moo.window.extend({
/*
Property: getWidth
@@ -4408,7 +4411,7 @@
},
initialize: function(options){
- this.transport = window.XMLHttpRequest ? new XMLHttpRequest() : (window.ie ? new ActiveXObject('Microsoft.XMLHTTP') : false);
+ this.transport = Moo.window.XMLHttpRequest ? new XMLHttpRequest() : (Moo.window.ie ? new ActiveXObject('Microsoft.XMLHTTP') : false);
this.setOptions(this.getOptions(), options);
if (!this.transport) return;
this.headers = {};
@@ -5174,7 +5177,7 @@
initialize: function(element, options){
this.setOptions(this.getOptions(), options);
this.element = $(element);
- this.mousemover = ([window, document].test(element)) ? $(document.body) : this.element;
+ this.mousemover = ([Moo.window, document].test(element)) ? $(document.body) : this.element;
},
/*
@@ -5198,7 +5201,7 @@
},
getCoords: function(event){
- this.page = (this.element == window) ? event.client : event.page;
+ this.page = (this.element == Moo.window) ? event.client : event.page;
if (!this.timer) this.timer = this.scroll.periodical(50, this);
},
@@ -5408,19 +5411,19 @@
initialize: function(options){
this.addEvent('onCancel', this.clearChain);
- var location = window.location.href.match(/^[^#]*/)[0] + '#';
+ var location = Moo.window.location.href.match(/^[^#]*/)[0] + '#';
$each(document.links, function(lnk){
if (lnk.href.indexOf(location) != 0) return;
var anchor = lnk.href.substr(location.length);
if (anchor && $(anchor)) this.useLink(lnk, anchor);
}, this);
- this.parent(window, options);
+ this.parent(Moo.window, options);
},
useLink: function(lnk, anchor){
lnk.addEvent('click', function(event){
- if(!window.khtml) this.chain(function(){
- window.location.href = '#'+anchor;
+ if(!Moo.window.khtml) this.chain(function(){
+ Moo.window.location.href = '#'+anchor;
});
this.toElement(anchor);
event.stop();
@@ -5690,8 +5693,8 @@
},
locate: function(event){
- var win = {'x': window.getWidth(), 'y': window.getHeight()};
- var scroll = {'x': window.getScrollLeft(), 'y': window.getScrollTop()};
+ var win = {'x': Moo.window.getWidth(), 'y': Moo.window.getHeight()};
+ var scroll = {'x': Moo.window.getScrollLeft(), 'y': Moo.window.getScrollTop()};
var tip = {'x': this.toolTip.offsetWidth, 'y': this.toolTip.offsetHeight};
var prop = {'x': 'left', 'y': 'top'};
for (var z in prop){
This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.
|
|
From: <tsw...@us...> - 2007-02-19 02:22:42
|
Revision: 486
http://argil.svn.sourceforge.net/argil/?rev=486&view=rev
Author: tswicegood
Date: 2007-02-18 18:22:43 -0800 (Sun, 18 Feb 2007)
Log Message:
-----------
Bring Object into the Moo namespace
Modified Paths:
--------------
trunk/src/ArgilCore/Public/scripts/mootools.full.v1.00.js
Modified: trunk/src/ArgilCore/Public/scripts/mootools.full.v1.00.js
===================================================================
--- trunk/src/ArgilCore/Public/scripts/mootools.full.v1.00.js 2007-02-18 17:38:21 UTC (rev 485)
+++ trunk/src/ArgilCore/Public/scripts/mootools.full.v1.00.js 2007-02-19 02:22:43 UTC (rev 486)
@@ -163,7 +163,8 @@
The first object, extended.
*/
-Object.extend = function(){
+Moo.Object = Object;
+Moo.Object.extend = function(){
var args = arguments;
args = (args[1]) ? [args[0], args[1]] : [this, args[0]];
for (var property in args[1]) args[0][property] = args[1][property];
@@ -179,11 +180,11 @@
*/
-Object.Native = function(){
+Moo.Object.Native = function(){
for (var i = 0; i < arguments.length; i++) arguments[i].extend = Moo.Class.prototype.implement;
};
-new Object.Native(Function, Array, String, Number, Moo.Class);
+new Moo.Object.Native(Function, Array, String, Number, Moo.Class);
/*
Script: Utility.js
@@ -207,7 +208,7 @@
//window, document
-window.extend = document.extend = Object.extend;
+window.extend = document.extend = Moo.Object.extend;
Moo.Window = window;
/*
@@ -881,7 +882,7 @@
create: function(options){
var fn = this;
- options = Object.extend({
+ options = Moo.Object.extend({
'bind': fn,
'event': false,
'arguments': null,
@@ -1103,7 +1104,7 @@
if (['object', 'embed'].test(el.tagName.toLowerCase()) || el.extend) return el;
el._element_extended_ = true;
Moo.Garbage.collect(el);
- el.extend = Object.extend;
+ el.extend = Moo.Object.extend;
if (!(el.htmlElement)) el.extend(Element.prototype);
return el;
};
@@ -1112,7 +1113,7 @@
Moo.Elements = new Moo.Class({});
-new Object.Native(Moo.Elements);
+new Moo.Object.Native(Moo.Elements);
document.getElementsBySelector = document.getElementsByTagName;
@@ -1156,7 +1157,7 @@
}
});
elements._elements_extended_ = true;
- return Object.extend(elements, new Moo.Elements);
+ return Moo.Object.extend(elements, new Moo.Elements);
};
Moo.Elements.Multi = function(property){
@@ -2237,7 +2238,7 @@
*/
setOptions: function(defaults, options){
- this.options = Object.extend(defaults, options);
+ this.options = Moo.Object.extend(defaults, options);
if (this.addEvent){
for (var option in this.options){
if (($type(this.options[option]) == 'function') && option.test(/^on[A-Z]/)) this.addEvent(option, this.options[option]);
@@ -2726,7 +2727,7 @@
hsb = rgb.rgbToHsb();
}
rgb.hsb = hsb;
- return Object.extend(rgb, Moo.Color.prototype);
+ return Moo.Object.extend(rgb, Moo.Color.prototype);
},
/*
@@ -4216,7 +4217,7 @@
*/
makeResizable: function(options){
- return new Moo.Drag.Base(this, Object.extend(options || {}, {modifiers: {x: 'width', y: 'height'}}));
+ return new Moo.Drag.Base(this, Moo.Object.extend(options || {}, {modifiers: {x: 'width', y: 'height'}}));
}
});
@@ -4451,7 +4452,7 @@
this.transport.open(this.options.method, url, this.options.async);
this.transport.onreadystatechange = this.onStateChange.bind(this);
if ((this.options.method == 'post') && this.transport.overrideMimeType) this.setHeader('Connection', 'close');
- Object.extend(this.headers, this.options.headers);
+ Moo.Object.extend(this.headers, this.options.headers);
for (var type in this.headers) this.transport.setRequestHeader(type, this.headers[type]);
this.transport.send(data);
return this;
@@ -4552,7 +4553,7 @@
var data = null;
switch ($type(this.options.postBody)){
case 'element': data = $(this.options.postBody).toQueryString(); break;
- case 'object': data = Object.toQueryString(this.options.postBody); break;
+ case 'object': data = Moo.Object.toQueryString(this.options.postBody); break;
case 'string': data = this.options.postBody;
}
if (this._method) data = (data) ? [this._method, data].join('&') : this._method;
@@ -4587,7 +4588,7 @@
>Object.toQueryString({apple: "red", lemon: "yellow"}); //returns "apple=red&lemon=yellow"
*/
-Object.toQueryString = function(source){
+Moo.Object.toQueryString = function(source){
var queryString = [];
for (var property in source) queryString.push(encodeURIComponent(property)+'='+encodeURIComponent(source[property]));
return queryString.join('&');
@@ -4623,7 +4624,7 @@
*/
send: function(options){
- options = Object.extend(options || {}, {postBody: this.toQueryString(), method: 'post'});
+ options = Moo.Object.extend(options || {}, {postBody: this.toQueryString(), method: 'post'});
return new Moo.Ajax(this.getProperty('action'), options).request();
},
@@ -4658,7 +4659,7 @@
},
toQueryString: function(){
- return Object.toQueryString(this.toObject());
+ return Moo.Object.toQueryString(this.toObject());
}
});
@@ -4703,7 +4704,7 @@
*/
set: function(key, value, options){
- options = Object.extend({
+ options = Moo.Object.extend({
domain: false,
path: false,
duration: 365
@@ -4940,7 +4941,7 @@
*/
image: function(source, properties){
- properties = Object.extend({
+ properties = Moo.Object.extend({
'src': source,
'onload': Moo.Class.empty,
'onabort': Moo.Class.empty,
@@ -4985,7 +4986,7 @@
*/
images: function(sources, options){
- options = Object.extend({
+ options = Moo.Object.extend({
onComplete: Moo.Class.empty,
onProgress: Moo.Class.empty
}, options || {});
@@ -5006,7 +5007,7 @@
},
create: function(type, defaults, properties, inject){
- Object.extend(defaults, properties || {});
+ Moo.Object.extend(defaults, properties || {});
var element = new Moo.Element(type).setProperties(defaults);
if (inject) element.injectInside($$('head')[0]);
return element;
This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.
|
|
From: <tsw...@us...> - 2007-02-18 17:38:26
|
Revision: 485
http://argil.svn.sourceforge.net/argil/?rev=485&view=rev
Author: tswicegood
Date: 2007-02-18 09:38:21 -0800 (Sun, 18 Feb 2007)
Log Message:
-----------
Streamline bringing code into the global scope based on feedback from the Mootools forum
Modified Paths:
--------------
trunk/src/ArgilCore/Public/scripts/mootools.full.v1.00.js
Modified: trunk/src/ArgilCore/Public/scripts/mootools.full.v1.00.js
===================================================================
--- trunk/src/ArgilCore/Public/scripts/mootools.full.v1.00.js 2007-02-16 15:33:41 UTC (rev 484)
+++ trunk/src/ArgilCore/Public/scripts/mootools.full.v1.00.js 2007-02-18 17:38:21 UTC (rev 485)
@@ -5714,13 +5714,10 @@
Moo.Tips.implement(new Moo.Events);
Moo.Tips.implement(new Moo.Options);
-Moo.MoveToGlobal = function() {
- for (var i in this) {
- if (i == 'MoveToGlobal') { continue; }
- eval(i + ' = Moo.' +i)
- }
-}
var CompatibilityMode = CompatibilityMode || false;
if (!CompatibilityMode) {
- Moo.MoveToGlobal();
+ for (var i in Moo) {
+ window[i] = Moo[i];
+ }
}
+
This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.
|
|
From: <tsw...@us...> - 2007-02-16 15:33:42
|
Revision: 484
http://argil.svn.sourceforge.net/argil/?rev=484&view=rev
Author: tswicegood
Date: 2007-02-16 07:33:41 -0800 (Fri, 16 Feb 2007)
Log Message:
-----------
Completely namespace Mootools as a proof of concept
Modified Paths:
--------------
trunk/src/ArgilCore/Public/scripts/argil.moo.js
trunk/src/ArgilCore/Public/scripts/mootools.full.v1.00.js
Modified: trunk/src/ArgilCore/Public/scripts/argil.moo.js
===================================================================
--- trunk/src/ArgilCore/Public/scripts/argil.moo.js 2007-02-16 00:31:14 UTC (rev 483)
+++ trunk/src/ArgilCore/Public/scripts/argil.moo.js 2007-02-16 15:33:41 UTC (rev 484)
@@ -62,7 +62,7 @@
Argil.objects = {};
Argil.objects.Div = {};
-Argil.objects.Div.AjaxifiedLinks = new Class({
+Argil.objects.Div.AjaxifiedLinks = new Moo.Class({
initialize: function(div) {
this.element = div;
},
@@ -81,13 +81,13 @@
break;
}
- new Event(event).stop();
+ new Moo.Event(event).stop();
});
});
}
});
-Argil.objects.Anchor = new Class({
+Argil.objects.Anchor = new Moo.Class({
initialize: function(anchor) {
this.anchor = anchor;
},
@@ -104,7 +104,7 @@
},
process: function() {
var me = this;
- new Ajax(
+ new Moo.Ajax(
this.anchor.href,
{method:'get', onComplete: function() { me.removeRow(); }}
).request();
@@ -121,14 +121,14 @@
},
process: function() {
var me = this;
- new Ajax(
+ new Moo.Ajax(
this.anchor.href + '?isAjax=true',
{method:'get', onComplete:function(result) { me.onComplete(result) }}
).request();
return false;
},
onComplete: function(result) {
- new Argil.Fx.FadeInAndShow(new Element('div').setHTML(result), {where: this.anchor.parentNode}).toggle();
+ new Argil.Fx.FadeInAndShow(new Moo.Element('div').setHTML(result), {where: this.anchor.parentNode}).toggle();
},
});
@@ -138,14 +138,14 @@
},
process: function() {
var me = this;
- new Ajax(
+ new Moo.Ajax(
this.anchor.href + '?isAjax=true',
{method:'get', onComplete:function(result) { me.onComplete(result) }}
).request();
return false;
},
onComplete: function(result) {
- new Argil.Fx.FadeInAndShow(new Element('div').setHTML(result), {where: 'dashboard_action'}).toggle();
+ new Argil.Fx.FadeInAndShow(new Moo.Element('div').setHTML(result), {where: 'dashboard_action'}).toggle();
}
});
@@ -157,7 +157,7 @@
var me = this;
this.modal = new Argil.objects.Modal($('dashboard_browse'));
this.modal.show();
- new Ajax(
+ new Moo.Ajax(
me.anchor.href + '?isAjax=true',
{method:'get', onComplete:function(result) { me.onComplete(result) }}
).request();
@@ -171,14 +171,14 @@
});
-Argil.objects.Modal = new Class({
+Argil.objects.Modal = new Moo.Class({
initialize: function(container) {
this.container = container;
this.container.setStyles({
'position':'relative',
'display':'block'
});
- this.modal = new Element('div');
+ this.modal = new Moo.Element('div');
this.modal.addClass('loading');
this.modal.setHTML('<div class="middle"><div class="inner"><p>Please wait...</p></div></div>');
this.modal.setStyle('height', this.container.clientHeight+'px');
@@ -191,12 +191,12 @@
this.container.removeChild(this.modal);
},
});
-Argil.objects.Form = new Class({
+Argil.objects.Form = new Moo.Class({
requireValidation: false,
onComplete: function(result) {
// update dashboard if available, otherwise replace
var dashboard = $('dashboard_browse');
- var div = new Element('div').setHTML(result);
+ var div = new Moo.Element('div').setHTML(result);
if (dashboard !== false) {
new Argil.Fx.FadeOutAndRemove(this.form.parentNode.parentNode).toggle();
div.id = 'dashboard_browse';
@@ -232,23 +232,23 @@
Argil.Fx = {};
-Argil.Fx.FadeOutAndRemove = new Class({
+Argil.Fx.FadeOutAndRemove = new Moo.Class({
initialize: function(selector, options) {
this.element = $(selector);
this.options = options || {};
this.options['duration'] = this.options['duration'] || 500;
},
toggle: function() {
- new Fx.Style(this.element, 'opacity').start(1,0);
+ new Moo.Fx.Style(this.element, 'opacity').start(1,0);
var me = this;
var removeNode = function() {
me.element.remove();
}.delay(this.options.duration);
}
});
-Argil.Fx.FadeOutAndRemove.implement(new Chain);
+Argil.Fx.FadeOutAndRemove.implement(new Moo.Chain);
-Argil.Fx.FadeInAndShow = new Class({
+Argil.Fx.FadeInAndShow = new Moo.Class({
initialize: function(selector, options) {
this.element = $(selector);
this.options = options || {};
@@ -257,7 +257,7 @@
toggle: function() {
$(this.options.where).adopt(this.element);
this.element.setOpacity(0);
- new Fx.Style(this.element, 'opacity').start(0,1);
+ new Moo.Fx.Style(this.element, 'opacity').start(0,1);
}
});
-Argil.Fx.FadeInAndShow.implement(new Chain);
+Argil.Fx.FadeInAndShow.implement(new Moo.Chain);
Modified: trunk/src/ArgilCore/Public/scripts/mootools.full.v1.00.js
===================================================================
--- trunk/src/ArgilCore/Public/scripts/mootools.full.v1.00.js 2007-02-16 00:31:14 UTC (rev 483)
+++ trunk/src/ArgilCore/Public/scripts/mootools.full.v1.00.js 2007-02-16 15:33:41 UTC (rev 484)
@@ -33,7 +33,9 @@
(end)
*/
-var Class = function(properties){
+var Moo = {};
+
+Moo.Class = function(properties){
var klass = function(){
if (this.initialize && arguments[0] != 'noinit') return this.initialize.apply(this, arguments);
else return this;
@@ -48,9 +50,9 @@
Returns an empty function
*/
-Class.empty = function(){};
+Moo.Class.empty = function(){};
-Class.prototype = {
+Moo.Class.prototype = {
/*
Property: extend
@@ -95,7 +97,7 @@
if (previous && previous != current) current = parentize(previous, current) || current;
pr0t0typ3[property] = current;
}
- return new Class(pr0t0typ3);
+ return new Moo.Class(pr0t0typ3);
},
/*
@@ -178,10 +180,10 @@
*/
Object.Native = function(){
- for (var i = 0; i < arguments.length; i++) arguments[i].extend = Class.prototype.implement;
+ for (var i = 0; i < arguments.length; i++) arguments[i].extend = Moo.Class.prototype.implement;
};
-new Object.Native(Function, Array, String, Number, Class);
+new Object.Native(Function, Array, String, Number, Moo.Class);
/*
Script: Utility.js
@@ -197,7 +199,7 @@
//htmlelement
if (typeof HTMLElement == 'undefined'){
- var HTMLElement = Class.empty;
+ var HTMLElement = Moo.Class.empty;
HTMLElement.prototype = {};
} else {
HTMLElement.prototype.htmlElement = true;
@@ -206,7 +208,7 @@
//window, document
window.extend = document.extend = Object.extend;
-var Window = window;
+Moo.Window = window;
/*
Function: $type
@@ -232,7 +234,7 @@
false - (boolean) if the object is not defined or none of the above.
*/
-function $type(obj){
+Moo.$type = function(obj){
if (obj === null || obj === undefined) return false;
var type = typeof obj;
if (type == 'object'){
@@ -254,7 +256,7 @@
Useful to accept zeroes.
*/
-function $chk(obj){
+Moo.$chk = function(obj){
return !!(obj || obj === 0);
};
@@ -263,7 +265,7 @@
Returns the first object if defined, otherwise returns the second.
*/
-function $pick(obj, picked){
+Moo.$pick = function(obj, picked){
return ($type(obj)) ? obj : picked;
};
@@ -279,7 +281,7 @@
a random integer between min and max.
*/
-function $random(min, max){
+Moo.$random = function(min, max){
return Math.floor(Math.random() * (max - min + 1) + min);
};
@@ -301,7 +303,7 @@
<Function.delay>, <Function.periodical>
*/
-function $clear(timer){
+Moo.$clear = function(timer){
clearTimeout(timer);
clearInterval(timer);
return null;
@@ -577,7 +579,7 @@
(end)
*/
-function $A(array, start, length){
+Moo.$A = function(array, start, length){
return Array.prototype.copy.call(array, start, length);
};
@@ -591,7 +593,7 @@
bind - optional, the 'this' of the function will refer to this object.
*/
-function $each(iterable, fn, bind){
+Moo.$each = function(iterable, fn, bind){
return Array.prototype.forEach.call(iterable, fn, bind);
};
@@ -1048,7 +1050,7 @@
Custom class to allow all of its methods to be used with any DOM element via the dollar function <$>.
*/
-var Element = new Class({
+Moo.Element = new Moo.Class({
/*
Property: initialize
@@ -1093,14 +1095,14 @@
But its no harm to call it multiple times, as it will detect if it has been already extended.
*/
-function $(el){
+Moo.$ = function(el){
if (!el) return false;
if (el._element_extended_ || [window, document].test(el)) return el;
if ($type(el) == 'string') el = document.getElementById(el);
if ($type(el) != 'element') return false;
if (['object', 'embed'].test(el.tagName.toLowerCase()) || el.extend) return el;
el._element_extended_ = true;
- Garbage.collect(el);
+ Moo.Garbage.collect(el);
el.extend = Object.extend;
if (!(el.htmlElement)) el.extend(Element.prototype);
return el;
@@ -1108,9 +1110,9 @@
//elements class
-var Elements = new Class({});
+Moo.Elements = new Moo.Class({});
-new Object.Native(Elements);
+new Object.Native(Moo.Elements);
document.getElementsBySelector = document.getElementsByTagName;
@@ -1134,7 +1136,7 @@
array - array of all the dom elements matched
*/
-function $$(){
+Moo.$$ = function(){
if (!arguments) return false;
if (arguments.length == 1){
if (!arguments[0]) return false;
@@ -1154,10 +1156,10 @@
}
});
elements._elements_extended_ = true;
- return Object.extend(elements, new Elements);
+ return Object.extend(elements, new Moo.Elements);
};
-Elements.Multi = function(property){
+Moo.Elements.Multi = function(property){
return function(){
var args = arguments;
var items = [];
@@ -1172,11 +1174,11 @@
};
};
-Element.extend = function(properties){
+Moo.Element.extend = function(properties){
for (var property in properties){
HTMLElement.prototype[property] = properties[property];
- Element.prototype[property] = properties[property];
- Elements.prototype[property] = Elements.Multi(property);
+ Moo.Element.prototype[property] = properties[property];
+ Moo.Elements.prototype[property] = Moo.Elements.Multi(property);
}
};
@@ -1185,10 +1187,10 @@
Custom class to allow all of its methods to be used with any DOM element via the dollar function <$>.
*/
-Element.extend({
+Moo.Element.extend({
inject: function(el, where){
- el = $(el) || new Element(el);
+ el = $(el) || new Moo.Element(el);
switch (where){
case "before": $(el.parentNode).insertBefore(this, el); break;
case "after":
@@ -1252,7 +1254,7 @@
*/
adopt: function(el){
- this.appendChild($(el) || new Element(el));
+ this.appendChild($(el) || new Moo.Element(el));
return this;
},
@@ -1302,7 +1304,7 @@
*/
replaceWith: function(el){
- el = $(el) || new Element(el);
+ el = $(el) || new Moo.Element(el);
this.parentNode.replaceChild(el, this);
return el;
},
@@ -1902,31 +1904,31 @@
});
-window.addEvent = document.addEvent = Element.prototype.addEvent;
-window.removeEvent = document.removeEvent = Element.prototype.removeEvent;
-window.removeEvents = document.removeEvents = Element.prototype.removeEvents;
+window.addEvent = document.addEvent = Moo.Element.prototype.addEvent;
+window.removeEvent = document.removeEvent = Moo.Element.prototype.removeEvent;
+window.removeEvents = document.removeEvents = Moo.Element.prototype.removeEvents;
-var Garbage = {
+Moo.Garbage = {
elements: [],
collect: function(element){
- Garbage.elements.push(element);
+ Moo.Garbage.elements.push(element);
},
trash: function(){
- Garbage.collect(window);
- Garbage.collect(document);
- Garbage.elements.each(function(el){
+ Moo.Garbage.collect(window);
+ Moo.Garbage.collect(document);
+ Moo.Garbage.elements.each(function(el){
el.removeEvents();
- for (var p in Element.prototype) el[p] = null;
+ for (var p in Moo.Element.prototype) el[p] = null;
el.extend = null;
});
}
};
-window.addEvent('unload', Garbage.trash);
+window.addEvent('unload', Moo.Garbage.trash);
/*
Script: Event.js
@@ -1973,7 +1975,7 @@
(end)
*/
-var Event = new Class({
+Moo.Event = new Moo.Class({
initialize: function(event){
this.event = event || window.event;
@@ -2118,7 +2120,7 @@
(end)
*/
-var Chain = new Class({
+Moo.Chain = new Moo.Class({
/*
Property: chain
@@ -2172,7 +2174,7 @@
(end)
*/
-var Events = new Class({
+Moo.Events = new Moo.Class({
/*
Property: addEvent
@@ -2180,7 +2182,7 @@
*/
addEvent: function(type, fn){
- if (fn != Class.empty){
+ if (fn != Moo.Class.empty){
this.events = this.events || {};
this.events[type] = this.events[type] || [];
if (!this.events[type].test(fn)) this.events[type].push(fn);
@@ -2220,7 +2222,7 @@
Used to automate the options settings, also adding Class <Events> when the option begins with on.
*/
-var Options = new Class({
+Moo.Options = new Moo.Class({
/*
Property: setOptions
@@ -2251,7 +2253,7 @@
An "Utility" Class.
*/
-var Group = new Class({
+Moo.Group = new Moo.Class({
initialize: function(){
this.instances = $A(arguments);
@@ -2315,7 +2317,7 @@
a DOM element - the first element that matches the selector
*/
-function $E(selector, filter){
+Moo.$E = function(selector, filter){
return ($(filter) || document).getElement(selector);
};
@@ -2336,7 +2338,7 @@
>$ES('a','myElement') //get all the anchor tags within $('myElement')
*/
-function $ES(selector, filter){
+Moo.$ES = function(selector, filter){
return ($(filter) || document).getElementsBySelector(selector);
};
@@ -2345,7 +2347,7 @@
Custom class to allow all of its methods to be used with any DOM element via the dollar function <$>.
*/
-Element.extend({
+Moo.Element.extend({
/*
Property: getElements
@@ -2364,7 +2366,7 @@
var param = sel.match(/^(\w*|\*)(?:#([\w-]+)|\.([\w-]+))?(?:\[(\w+)(?:([*^$]?=)["']?([^"'\]]*)["']?)?])?$/);
//PARAM ARRAY: 0 = full string: 1 = tag; 2 = id; 3 = class; 4 = attribute; 5 = operator; 6 = value;
if (!param) return;
- Filters.selector = param;
+ Moo.Filters.selector = param;
param[1] = param[1] || '*';
if (i == 0){
if (param[2]){
@@ -2375,11 +2377,11 @@
elements = $A(this.getElementsByTagName(param[1]));
}
} else {
- elements = Elements.prototype.getElementsByTagName.call(elements, param[1], true);
- if (param[2]) elements = elements.filter(Filters.id);
+ elements = Moo.Elements.prototype.getElementsByTagName.call(elements, param[1], true);
+ if (param[2]) elements = elements.filter(Moo.Filters.id);
}
- if (param[3]) elements = elements.filter(Filters.className);
- if (param[4]) elements = elements.filter(Filters.attribute);
+ if (param[3]) elements = elements.filter(Moo.Filters.className);
+ if (param[4]) elements = elements.filter(Moo.Filters.attribute);
}, this);
return $$(elements);
},
@@ -2403,7 +2405,7 @@
/*
Property: getElement
- Same as <Element.getElements>, but returns only the first. Alternate syntax for <$E>, where filter is the Element.
+ Same as <Element.getElements>, but returns only the first. Alternate syntax for <$E>, where filter is the Moo.Element.
*/
getElement: function(selector){
@@ -2438,32 +2440,32 @@
getElementsByClassName: function(className){
return document.getElements('.'+className);
},
- getElement: Element.prototype.getElement,
- getElements: Element.prototype.getElements,
- getElementsBySelector: Element.prototype.getElementsBySelector
+ getElement: Moo.Element.prototype.getElement,
+ getElements: Moo.Element.prototype.getElements,
+ getElementsBySelector: Moo.Element.prototype.getElementsBySelector
});
//dom filters, internal methods.
-var Filters = {
+Moo.Filters = {
selector: [],
id: function(el){
- return (el.id == Filters.selector[2]);
+ return (el.id == Moo.Filters.selector[2]);
},
className: function(el){
- return (Element.prototype.hasClass.call(el, Filters.selector[3]));
+ return (Element.prototype.hasClass.call(el, Moo.Filters.selector[3]));
},
attribute: function(el){
- var current = el.getAttribute(Filters.selector[4]);
+ var current = el.getAttribute(Moo.Filters.selector[4]);
if (!current) return false;
- var operator = Filters.selector[5];
+ var operator = Moo.Filters.selector[5];
if (!operator) return true;
- var value = Filters.selector[6];
+ var value = Moo.Filters.selector[6];
switch (operator){
case '*=': return (current.test(value));
case '=': return (current == value);
@@ -2480,7 +2482,7 @@
Methods for dom queries arrays, <$$>.
*/
-Elements.extend({
+Moo.Elements.extend({
getElementsByTagName: function(tagName){
var found = [];
@@ -2517,7 +2519,7 @@
(end)
*/
-var Hash = new Class({
+Moo.Hash = new Moo.Class({
length: 0,
@@ -2668,8 +2670,8 @@
Shortcut to create a Hash from an Object.
*/
-function $H(obj){
- return new Hash(obj);
+Moo.$H = function(obj){
+ return new Moo.Hash(obj);
};
/*
@@ -2703,7 +2705,7 @@
(end)
*/
-var Color = new Class({
+Moo.Color = new Moo.Class({
initialize: function(color, type){
if (color.isColor) return color;
@@ -2724,7 +2726,7 @@
hsb = rgb.rgbToHsb();
}
rgb.hsb = hsb;
- return Object.extend(rgb, Color.prototype);
+ return Object.extend(rgb, Moo.Color.prototype);
},
/*
@@ -2741,10 +2743,10 @@
var alpha = ($type(colors[colors.length-1]) == 'number') ? colors.pop() : 50;
var rgb = this.copy();
colors.each(function(color){
- color = new Color(color);
+ color = new Moo.Color(color);
for (var i = 0; i < 3; i++) rgb[i] = Math.round((rgb[i] / 100 * (100 - alpha)) + (color[i] / 100 * alpha));
});
- return new Color(rgb, 'rgb');
+ return new Moo.Color(rgb, 'rgb');
},
/*
@@ -2753,7 +2755,7 @@
*/
invert: function(){
- return new Color(this.map(function(value){
+ return new Moo.Color(this.map(function(value){
return 255 - value;
}));
},
@@ -2767,7 +2769,7 @@
*/
setHue: function(value){
- return new Color([value, this.hsb[1], this.hsb[2]], 'hsb');
+ return new Moo.Color([value, this.hsb[1], this.hsb[2]], 'hsb');
},
/*
@@ -2779,7 +2781,7 @@
*/
setSaturation: function(percent){
- return new Color([this.hsb[0], percent, this.hsb[2]], 'hsb');
+ return new Moo.Color([this.hsb[0], percent, this.hsb[2]], 'hsb');
},
/*
@@ -2791,7 +2793,7 @@
*/
setBrightness: function(percent){
- return new Color([this.hsb[0], this.hsb[1], percent], 'hsb');
+ return new Moo.Color([this.hsb[0], this.hsb[1], percent], 'hsb');
}
});
@@ -2801,8 +2803,8 @@
Shortcut to create a new color, based on red, green, blue values.
*/
-function $RGB(r, g, b){
- return new Color([r, g, b], 'rgb');
+Moo.$RGB = function(r, g, b){
+ return new Moo.Color([r, g, b], 'rgb');
};
/*
@@ -2810,8 +2812,8 @@
Shortcut to create a new color, based on hue, saturation, brightness values.
*/
-function $HSB(h, s, b){
- return new Color([h, s, b], 'hsb');
+Moo.$HSB = function(h, s, b){
+ return new Moo.Color([h, s, b], 'hsb');
};
/*
@@ -3090,7 +3092,7 @@
MIT-style license.
*/
-var Fx = {};
+Moo.Fx = {};
/*
Class: Fx.Base
@@ -3106,14 +3108,14 @@
fps - the frames per second for the transition; default is 30
*/
-Fx.Base = new Class({
+Moo.Fx.Base = new Moo.Class({
getOptions: function(){
return {
- onStart: Class.empty,
- onComplete: Class.empty,
- onCancel: Class.empty,
- transition: Fx.Transitions.sineInOut,
+ onStart: Moo.Class.empty,
+ onComplete: Moo.Class.empty,
+ onCancel: Moo.Class.empty,
+ transition: Moo.Fx.Transitions.sineInOut,
duration: 500,
unit: 'px',
wait: true,
@@ -3208,9 +3210,9 @@
});
-Fx.Base.implement(new Chain);
-Fx.Base.implement(new Events);
-Fx.Base.implement(new Options);
+Moo.Fx.Base.implement(new Moo.Chain);
+Moo.Fx.Base.implement(new Moo.Events);
+Moo.Fx.Base.implement(new Moo.Options);
/*
Class: Fx.Transitions
@@ -3223,7 +3225,7 @@
Easing Equations, (c) 2003 Robert Penner (http://www.robertpenner.com/easing/), Open Source BSD License.
*/
-Fx.Transitions = {
+Moo.Fx.Transitions = {
/* Property: linear */
linear: function(t, b, c, d){
@@ -3249,7 +3251,7 @@
MIT-style license.
*/
-Fx.CSS = {
+Moo.Fx.CSS = {
select: function(property, to){
if (property.test(/color/i)) return this.Color;
@@ -3270,7 +3272,7 @@
};
-Fx.CSS.Single = {
+Moo.Fx.CSS.Single = {
parse: function(value){
return parseFloat(value);
@@ -3286,7 +3288,7 @@
};
-Fx.CSS.Multi = {
+Moo.Fx.CSS.Multi = {
parse: function(value){
return value.push ? value : value.split(' ').map(function(v){
@@ -3306,7 +3308,7 @@
};
-Fx.CSS.Color = {
+Moo.Fx.CSS.Color = {
parse: function(value){
return value.push ? value : value.hexToRgb(true);
@@ -3350,7 +3352,7 @@
>marginChange.start(10, 100);
*/
-Fx.Style = Fx.Base.extend({
+Moo.Fx.Style = Moo.Fx.Base.extend({
initialize: function(el, property, options){
this.element = $(el);
@@ -3372,7 +3374,7 @@
},
set: function(to){
- this.css = Fx.CSS.select(this.property, to);
+ this.css = Moo.Fx.CSS.select(this.property, to);
return this.parent(this.css.parse(to));
},
@@ -3389,7 +3391,7 @@
start: function(from, to){
if (this.timer && this.options.wait) return this;
- var parsed = Fx.CSS.parse(this.element, this.property, [from, to]);
+ var parsed = Moo.Fx.CSS.parse(this.element, this.property, [from, to]);
this.css = parsed.css;
return this.parent(parsed.from, parsed.to);
},
@@ -3405,7 +3407,7 @@
Custom class to allow all of its methods to be used with any DOM element via the dollar function <$>.
*/
-Element.extend({
+Moo.Element.extend({
/*
Property: effect
@@ -3417,7 +3419,7 @@
*/
effect: function(property, options){
- return new Fx.Style(this, property, options);
+ return new Moo.Fx.Style(this, property, options);
}
});
@@ -3460,7 +3462,7 @@
(end)
*/
-Fx.Styles = Fx.Base.extend({
+Moo.Fx.Styles = Moo.Fx.Base.extend({
initialize: function(el, options){
this.element = $(el);
@@ -3475,7 +3477,7 @@
var parsed = {};
this.css = {};
for (var p in to){
- this.css[p] = Fx.CSS.select(p, to[p]);
+ this.css[p] = Moo.Fx.CSS.select(p, to[p]);
parsed[p] = this.css[p].parse(to[p]);
}
return this.parent(parsed);
@@ -3498,7 +3500,7 @@
this.css = {};
var from = {}, to = {};
for (var p in obj){
- var parsed = Fx.CSS.parse(this.element, p, obj[p]);
+ var parsed = Moo.Fx.CSS.parse(this.element, p, obj[p]);
from[p] = parsed.from;
to[p] = parsed.to;
this.css[p] = parsed.css;
@@ -3517,7 +3519,7 @@
Custom class to allow all of its methods to be used with any DOM element via the dollar function <$>.
*/
-Element.extend({
+Moo.Element.extend({
/*
Property: effects
@@ -3529,7 +3531,7 @@
*/
effects: function(options){
- return new Fx.Styles(this, options);
+ return new Moo.Fx.Styles(this, options);
}
});
@@ -3554,7 +3556,7 @@
options - same as <Fx.Base> options.
*/
-Fx.Elements = Fx.Base.extend({
+Moo.Fx.Elements = Moo.Fx.Base.extend({
initialize: function(elements, options){
this.elements = $$(elements);
@@ -3574,7 +3576,7 @@
for (var i in to){
var iTo = to[i], iCss = this.css[i] = {}, iParsed = parsed[i] = {};
for (var p in iTo){
- iCss[p] = Fx.CSS.select(p, iTo[p]);
+ iCss[p] = Moo.Fx.CSS.select(p, iTo[p]);
iParsed[p] = iCss[p].parse(iTo[p]);
}
}
@@ -3608,7 +3610,7 @@
for (var i in obj){
var iProps = obj[i], iFrom = from[i] = {}, iTo = to[i] = {}, iCss = this.css[i] = {};
for (var p in iProps){
- var parsed = Fx.CSS.parse(this.elements[i], p, iProps[p]);
+ var parsed = Moo.Fx.CSS.parse(this.elements[i], p, iProps[p]);
iFrom[p] = parsed.from;
iTo[p] = parsed.to;
iCss[p] = parsed.css;
@@ -3646,7 +3648,7 @@
options - same as <Fx.Base> options.
*/
-Fx.Scroll = Fx.Base.extend({
+Moo.Fx.Scroll = Moo.Fx.Base.extend({
initialize: function(element, options){
this.now = [];
@@ -3768,11 +3770,11 @@
(end)
*/
-Fx.Slide = Fx.Base.extend({
+Moo.Fx.Slide = Moo.Fx.Base.extend({
initialize: function(el, options){
this.element = $(el).setStyle('margin', 0);
- this.wrapper = new Element('div').injectAfter(this.element).setStyle('overflow', 'hidden').adopt(this.element);
+ this.wrapper = new Moo.Element('div').injectAfter(this.element).setStyle('overflow', 'hidden').adopt(this.element);
this.setOptions({'mode': 'vertical'}, options);
this.now = [];
this.parent(this.options);
@@ -3867,7 +3869,7 @@
A collection of tweaning transitions for use with the <Fx.Base> classes.
*/
-Fx.Transitions = {
+Moo.Fx.Transitions = {
/* Property: linear */
linear: function(t, b, c, d){
@@ -4033,7 +4035,7 @@
/* Property: bounceIn */
bounceIn: function(t, b, c, d){
- return c - Fx.Transitions.bounceOut (d-t, 0, c, d) + b;
+ return c - Moo.Fx.Transitions.bounceOut (d-t, 0, c, d) + b;
},
/* Property: bounceOut */
@@ -4051,8 +4053,8 @@
/* Property: bounceInOut */
bounceInOut: function(t, b, c, d){
- if (t < d/2) return Fx.Transitions.bounceIn(t*2, 0, c, d) * .5 + b;
- return Fx.Transitions.bounceOut(t*2-d, 0, c, d) * .5 + c*.5 + b;
+ if (t < d/2) return Moo.Fx.Transitions.bounceIn(t*2, 0, c, d) * .5 + b;
+ return Moo.Fx.Transitions.bounceOut(t*2-d, 0, c, d) * .5 + c*.5 + b;
}
};
@@ -4068,7 +4070,7 @@
MIT-style license.
*/
-var Drag = {};
+Moo.Drag = {};
/*
Class: Drag.Base
@@ -4096,17 +4098,17 @@
y - array with start and end limit relative to modifiers.y
*/
-Drag.Base = new Class({
+Moo.Drag.Base = new Moo.Class({
getOptions: function(){
return {
handle: false,
unit: 'px',
- onStart: Class.empty,
- onBeforeStart: Class.empty,
- onComplete: Class.empty,
- onSnap: Class.empty,
- onDrag: Class.empty,
+ onStart: Moo.Class.empty,
+ onBeforeStart: Moo.Class.empty,
+ onComplete: Moo.Class.empty,
+ onSnap: Moo.Class.empty,
+ onDrag: Moo.Class.empty,
limit: false,
modifiers: {x: 'left', y: 'top'},
snap: 6
@@ -4195,15 +4197,15 @@
});
-Drag.Base.implement(new Events);
-Drag.Base.implement(new Options);
+Moo.Drag.Base.implement(new Moo.Events);
+Moo.Drag.Base.implement(new Moo.Options);
/*
Class: Element
Custom class to allow all of its methods to be used with any DOM element via the dollar function <$>.
*/
-Element.extend({
+Moo.Element.extend({
/*
Property: makeResizable
@@ -4214,7 +4216,7 @@
*/
makeResizable: function(options){
- return new Drag.Base(this, Object.extend(options || {}, {modifiers: {x: 'width', y: 'height'}}));
+ return new Moo.Drag.Base(this, Object.extend(options || {}, {modifiers: {x: 'width', y: 'height'}}));
}
});
@@ -4245,7 +4247,7 @@
droppables - an array of elements you can drop your draggable to.
*/
-Drag.Move = Drag.Base.extend({
+Moo.Drag.Move = Moo.Drag.Base.extend({
getExtended: function(){
return {
@@ -4342,7 +4344,7 @@
Custom class to allow all of its methods to be used with any DOM element via the dollar function <$>.
*/
-Element.extend({
+Moo.Element.extend({
/*
Property: makeDraggable
@@ -4353,7 +4355,7 @@
*/
makeDraggable: function(options){
- return new Drag.Move(this, options);
+ return new Moo.Drag.Move(this, options);
}
});
@@ -4389,16 +4391,16 @@
>var myXHR = new XHR({method: 'get'}).send('http://site.com/requestHandler.php', 'name=john&lastname=doe');
*/
-var XHR = new Class({
+Moo.XHR = new Moo.Class({
getOptions: function(){
return {
method: 'post',
async: true,
- onRequest: Class.empty,
- onStateChange: Class.empty,
- onSuccess: Class.empty,
- onFailure: Class.empty,
+ onRequest: Moo.Class.empty,
+ onStateChange: Moo.Class.empty,
+ onSuccess: Moo.Class.empty,
+ onFailure: Moo.Class.empty,
headers: {},
isSuccess: this.isSuccess
}
@@ -4419,7 +4421,7 @@
try {status = this.transport.status} catch (e){}
if (this.options.isSuccess(status)) this.onSuccess();
else this.onFailure();
- this.transport.onreadystatechange = Class.empty;
+ this.transport.onreadystatechange = Moo.Class.empty;
},
isSuccess: function(status){
@@ -4457,9 +4459,9 @@
});
-XHR.implement(new Chain);
-XHR.implement(new Events);
-XHR.implement(new Options);
+Moo.XHR.implement(new Moo.Chain);
+Moo.XHR.implement(new Moo.Events);
+Moo.XHR.implement(new Moo.Options);
/*
Script: Ajax.js
@@ -4496,13 +4498,13 @@
>var myAjax = new Ajax(url, {method: 'get'}).request();
*/
-var Ajax = XHR.extend({
+Moo.Ajax = Moo.XHR.extend({
moreOptions: function(){
return {
postBody: null,
update: null,
- onComplete: Class.empty,
+ onComplete: Moo.Class.empty,
evalScripts: false,
evalResponse: false,
encoding: 'utf-8'
@@ -4596,7 +4598,7 @@
Custom class to allow all of its methods to be used with any DOM element via the dollar function <$>.
*/
-Element.extend({
+Moo.Element.extend({
/*
Property: send
@@ -4622,7 +4624,7 @@
send: function(options){
options = Object.extend(options || {}, {postBody: this.toQueryString(), method: 'post'});
- return new Ajax(this.getProperty('action'), options).request();
+ return new Moo.Ajax(this.getProperty('action'), options).request();
},
/*
@@ -4677,7 +4679,7 @@
Class for creating, getting, and removing cookies.
*/
-var Cookie = {
+Moo.Cookie = {
/*
Property: set
@@ -4770,7 +4772,7 @@
Simple Json parser and Stringyfier, See: <http://www.json.org/>
*/
-var Json = {
+Moo.Json = {
/*
Property: toString
@@ -4794,11 +4796,11 @@
return '"'+obj.replace(new RegExp('(["\\\\])', 'g'), '\\$1')+'"';
case 'array':
return '['+ obj.map(function(ar){
- return Json.toString(ar);
+ return Moo.Json.toString(ar);
}).join(',') +']';
case 'object':
var string = [];
- for (var property in obj) string.push('"'+property+'":'+Json.toString(obj[property]));
+ for (var property in obj) string.push('"'+property+'":'+Moo.Json.toString(obj[property]));
return '{'+string.join(',')+'}';
}
return String(obj);
@@ -4852,7 +4854,7 @@
(end)
*/
-Json.Remote = XHR.extend({
+Moo.Json.Remote = Moo.XHR.extend({
initialize: function(url, options){
this.url = url;
@@ -4862,11 +4864,11 @@
},
send: function(obj){
- return this.parent(this.url, 'json='+Json.toString(obj));
+ return this.parent(this.url, 'json='+Moo.Json.toString(obj));
},
onComplete: function(){
- this.fireEvent('onComplete', Json.evaluate(this.response.text));
+ this.fireEvent('onComplete', Moo.Json.evaluate(this.response.text));
}
});
@@ -4884,7 +4886,7 @@
MIT-style license.
*/
-var Asset = {
+Moo.Asset = {
/*
Property: javascript
@@ -4899,7 +4901,7 @@
*/
javascript: function(source, properties){
- return Asset.create('script', {
+ return Moo.Asset.create('script', {
'type': 'text/javascript', 'src': source
}, properties, true);
},
@@ -4917,7 +4919,7 @@
*/
css: function(source, properties){
- return Asset.create('link', {
+ return Moo.Asset.create('link', {
'rel': 'stylesheet', 'media': 'screen', 'type': 'text/css', 'href': source
}, properties, true);
},
@@ -4940,9 +4942,9 @@
image: function(source, properties){
properties = Object.extend({
'src': source,
- 'onload': Class.empty,
- 'onabort': Class.empty,
- 'onerror': Class.empty
+ 'onload': Moo.Class.empty,
+ 'onabort': Moo.Class.empty,
+ 'onerror': Moo.Class.empty
}, properties || {});
var image = new Image();
image.onload = function(){
@@ -4954,7 +4956,7 @@
image.onerror = properties.onerror;
image.onabort = properties.onabort;
image.src = properties.src;
- return Asset.create('img', properties);
+ return Moo.Asset.create('img', properties);
},
/*
@@ -4984,14 +4986,14 @@
images: function(sources, options){
options = Object.extend({
- onComplete: Class.empty,
- onProgress: Class.empty
+ onComplete: Moo.Class.empty,
+ onProgress: Moo.Class.empty
}, options || {});
if (!sources.push) sources = [sources];
var images = [];
counter = 0;
sources.each(function(source){
- var img = new Asset.image(source, {
+ var img = new Moo.Asset.image(source, {
'onload': function(){
counter++;
options.onProgress();
@@ -5005,7 +5007,7 @@
create: function(type, defaults, properties, inject){
Object.extend(defaults, properties || {});
- var element = new Element(type).setProperties(defaults);
+ var element = new Moo.Element(type).setProperties(defaults);
if (inject) element.injectInside($$('head')[0]);
return element;
}
@@ -5045,12 +5047,12 @@
alwaysHide - boolean, will allow to hide all elements if true, instead of always keeping one element shown. defaults to false.
*/
-var Accordion = Fx.Elements.extend({
+Moo.Accordion = Moo.Fx.Elements.extend({
getExtended: function(){
return {
- onActive: Class.empty,
- onBackground: Class.empty,
+ onActive: Moo.Class.empty,
+ onBackground: Moo.Class.empty,
display: 0,
show: false,
height: true,
@@ -5127,7 +5129,7 @@
});
-Fx.Accordion = Accordion;
+Moo.Fx.Accordion = Moo.Accordion;
/*
Script: Scroller.js
@@ -5156,7 +5158,7 @@
Automatically passes as parameters x and y values.
*/
-var Scroller = new Class({
+Moo.Scroller = new Moo.Class({
getOptions: function(){
return {
@@ -5215,8 +5217,8 @@
});
-Scroller.implement(new Events);
-Scroller.implement(new Options);
+Moo.Scroller.implement(new Moo.Events);
+Moo.Scroller.implement(new Moo.Options);
/*
Script: Slider.js
@@ -5248,12 +5250,12 @@
wheel - experimental! Also use the mouse wheel to control the slider. defaults to false.
*/
-var Slider = new Class({
+Moo.Slider = new Moo.Class({
getOptions: function(){
return {
- onChange: Class.empty,
- onComplete: Class.empty,
+ onChange: Moo.Class.empty,
+ onComplete: Moo.Class.empty,
onTick: function(pos){
this.knob.setStyle(this.p, pos+'px');
},
@@ -5295,7 +5297,7 @@
limSlide[this.z] = [0, this.max];
modSlide[this.z] = this.p;
- this.drag = new Drag.Base(this.knob, {
+ this.drag = new Moo.Drag.Base(this.knob, {
limit: limSlide,
snap: 0,
modifiers: modSlide,
@@ -5376,8 +5378,8 @@
});
-Slider.implement(new Events);
-Slider.implement(new Options);
+Moo.Slider.implement(new Moo.Events);
+Moo.Slider.implement(new Moo.Options);
/*
Script: SmoothScroll.js
@@ -5401,7 +5403,7 @@
>new SmoothScroll();
*/
-var SmoothScroll = Fx.Scroll.extend({
+Moo.SmoothScroll = Moo.Fx.Scroll.extend({
initialize: function(options){
this.addEvent('onCancel', this.clearChain);
@@ -5451,13 +5453,13 @@
onComplete - function executed when the item ends dragging
*/
-var Sortables = new Class({
+Moo.Sortables = new Moo.Class({
getOptions: function() {
return {
handles: false,
- onStart: Class.empty,
- onComplete: Class.empty,
+ onStart: Moo.Class.empty,
+ onComplete: Moo.Class.empty,
ghost: true,
snap: 3,
onDragStart: function(element, ghost){
@@ -5479,9 +5481,9 @@
this.elements.each(function(el, i){
this.bound.start[i] = this.start.bindWithEvent(this, el);
if (this.options.ghost){
- this.trash = new Element('div').injectInside(document.body);
+ this.trash = new Moo.Element('div').injectInside(document.body);
var limit = this.list.getCoordinates();
- this.drag[i] = new Drag.Base(el, {
+ this.drag[i] = new Moo.Drag.Base(el, {
handle: this.handles[i],
snap: this.options.snap,
modifiers: {y: 'top'},
@@ -5552,8 +5554,8 @@
});
-Sortables.implement(new Events);
-Sortables.implement(new Options);
+Moo.Sortables.implement(new Moo.Events);
+Moo.Sortables.implement(new Moo.Options);
/*
Script: Tips.js
@@ -5607,7 +5609,7 @@
(end)
*/
-var Tips = new Class({
+Moo.Tips = new Moo.Class({
getOptions: function(){
return {
@@ -5628,13 +5630,13 @@
initialize: function(elements, options){
this.setOptions(this.getOptions(), options);
- this.toolTip = new Element('div').addClass(this.options.className+'-tip').setStyles({
+ this.toolTip = new Moo.Element('div').addClass(this.options.className+'-tip').setStyles({
'position': 'absolute',
'top': '0',
'left': '0',
'visibility': 'hidden'
}).injectInside(document.body);
- this.wrapper = new Element('div').injectInside(this.toolTip);
+ this.wrapper = new Moo.Element('div').injectInside(this.toolTip);
$each(elements, function(el){
this.build($(el));
}, this);
@@ -5667,13 +5669,13 @@
start: function(el){
this.wrapper.setHTML('');
if (el.myTitle){
- new Element('span').injectInside(
- new Element('div').addClass(this.options.className+'-title').injectInside(this.wrapper)
+ new Moo.Element('span').injectInside(
+ new Moo.Element('div').addClass(this.options.className+'-title').injectInside(this.wrapper)
).setHTML(el.myTitle);
}
if (el.myText){
- new Element('span').injectInside(
- new Element('div').addClass(this.options.className+'-text').injectInside(this.wrapper)
+ new Moo.Element('span').injectInside(
+ new Moo.Element('div').addClass(this.options.className+'-text').injectInside(this.wrapper)
).setHTML(el.myText);
}
$clear(this.timer);
@@ -5709,5 +5711,16 @@
});
-Tips.implement(new Events);
-Tips.implement(new Options);
+Moo.Tips.implement(new Moo.Events);
+Moo.Tips.implement(new Moo.Options);
+
+Moo.MoveToGlobal = function() {
+ for (var i in this) {
+ if (i == 'MoveToGlobal') { continue; }
+ eval(i + ' = Moo.' +i)
+ }
+}
+var CompatibilityMode = CompatibilityMode || false;
+if (!CompatibilityMode) {
+ Moo.MoveToGlobal();
+}
This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.
|
|
From: <tsw...@us...> - 2007-02-16 00:31:14
|
Revision: 483
http://argil.svn.sourceforge.net/argil/?rev=483&view=rev
Author: tswicegood
Date: 2007-02-15 16:31:14 -0800 (Thu, 15 Feb 2007)
Log Message:
-----------
Final things to make Argil Pipes free
Modified Paths:
--------------
trunk/public/index.php
trunk/src/ArgilCore/Public/scripts/argil.moo.js
trunk/src/ArgilSample/sample.config.php
Modified: trunk/public/index.php
===================================================================
--- trunk/public/index.php 2007-02-14 03:31:04 UTC (rev 482)
+++ trunk/public/index.php 2007-02-16 00:31:14 UTC (rev 483)
@@ -3,12 +3,12 @@
$includePath = realpath(dirname(__FILE__) . '/../src');
set_include_path($includePath . ':' . $includePath . '/PEAR');
-require_once 'Pipes/Framework.php';
-require_once 'Pipes/Config.php';
-require_once 'Pipes/Route.php';
+require_once 'Argil/Framework.php';
+require_once 'Argil/Config.php';
+require_once 'Argil/Route.php';
session_start();
-$config = new Pipes_Config('PipesSample/sample.config.php');
-$pipes = new Pipes_Framework($config);
-echo $pipes->run(new Pipes_Route($config, $_SERVER['REQUEST_URI']));
+$config = new Argil_Config('ArgilSample/sample.config.php');
+$pipes = new Argil_Framework($config);
+echo $pipes->run(new Argil_Route($config, $_SERVER['REQUEST_URI']));
Modified: trunk/src/ArgilCore/Public/scripts/argil.moo.js
===================================================================
--- trunk/src/ArgilCore/Public/scripts/argil.moo.js 2007-02-14 03:31:04 UTC (rev 482)
+++ trunk/src/ArgilCore/Public/scripts/argil.moo.js 2007-02-16 00:31:14 UTC (rev 483)
@@ -1,8 +1,8 @@
-// Define the Pipes namespace object
-var Pipes = {};
+// Define the Argil namespace object
+var Argil = {};
-// standard factory for creating Pipes.objects.* objects
-Pipes.ajaxify = function(selector, options) {
+// standard factory for creating Argil.objects.* objects
+Argil.ajaxify = function(selector, options) {
// define options as an empty has if it's not set
options = options || {};
@@ -11,23 +11,23 @@
console.log(options['type']);
switch (options['type']) {
case 'RemoveModel' :
- return new Pipes.objects.Anchor.RemoveModel($(selector));
+ return new Argil.objects.Anchor.RemoveModel($(selector));
break;
case 'AddForm' :
- return new Pipes.objects.Anchor.AddForm($(selector));
+ return new Argil.objects.Anchor.AddForm($(selector));
break;
case 'EditForm' :
- return new Pipes.objects.Anchor.EditForm($(selector));
+ return new Argil.objects.Anchor.EditForm($(selector));
break;
case 'BrowseReplace' :
- return new Pipes.objects.Anchor.BrowseReplace($(selector));
+ return new Argil.objects.Anchor.BrowseReplace($(selector));
break;
}
- return new Pipes.objects.Anchor($(selector));
+ return new Argil.objects.Anchor($(selector));
break;
case 'form' :
@@ -35,23 +35,23 @@
// definte requireValidation based on whether it has the 'requireValidation'
// class if it's not explicitly set
options['requireValidation'] = options['requireValidation'] || $(selector).hasClass('requireValidation');
- return new Pipes.objects.Form(selector, options);
+ return new Argil.objects.Form(selector, options);
break;
-
+
case 'div' :
switch (options['type']) {
case 'AjaxifiedLinks' :
- return new Pipes.objects.Div.AjaxifiedLinks($(selector));
+ return new Argil.objects.Div.AjaxifiedLinks($(selector));
break;
}
default:
- Pipes.error('Unable to ajaxify [' + $(selector).getTag() + '] element');
+ Argil.error('Unable to ajaxify [' + $(selector).getTag() + '] element');
break;
}
};
-Pipes.error = function(msg) {
+Argil.error = function(msg) {
if (console != undefined) {
console.log(msg);
} else {
@@ -59,10 +59,10 @@
}
}
-Pipes.objects = {};
+Argil.objects = {};
-Pipes.objects.Div = {};
-Pipes.objects.Div.AjaxifiedLinks = new Class({
+Argil.objects.Div = {};
+Argil.objects.Div.AjaxifiedLinks = new Class({
initialize: function(div) {
this.element = div;
},
@@ -71,13 +71,13 @@
anchor.addEvent('click', function(event) {
switch (this.firstChild.nodeValue) {
case 'edit':
- Pipes.ajaxify(this, {type:'EditForm'}).process();
+ Argil.ajaxify(this, {type:'EditForm'}).process();
break;
case 'delete':
- Pipes.ajaxify(this, {type: 'RemoveModel'}).process();
+ Argil.ajaxify(this, {type: 'RemoveModel'}).process();
break;
default :
- Pipes.ajaxify(this, {type: 'BrowseReplace'}).process();
+ Argil.ajaxify(this, {type: 'BrowseReplace'}).process();
break;
}
@@ -87,7 +87,7 @@
}
});
-Pipes.objects.Anchor = new Class({
+Argil.objects.Anchor = new Class({
initialize: function(anchor) {
this.anchor = anchor;
},
@@ -97,7 +97,7 @@
}
});
-Pipes.objects.Anchor.RemoveModel = Pipes.objects.Anchor.extend({
+Argil.objects.Anchor.RemoveModel = Argil.objects.Anchor.extend({
initialize: function(anchor) {
this.parent(anchor);
this.row = $($($(this.anchor).parentNode).parentNode);
@@ -111,11 +111,11 @@
return false;
},
removeRow: function() {
- new Pipes.Fx.FadeOutAndRemove(this.row).toggle();
+ new Argil.Fx.FadeOutAndRemove(this.row).toggle();
},
});
-Pipes.objects.Anchor.AddForm = Pipes.objects.Anchor.extend({
+Argil.objects.Anchor.AddForm = Argil.objects.Anchor.extend({
initialize: function(anchor) {
this.parent(anchor);
},
@@ -128,11 +128,11 @@
return false;
},
onComplete: function(result) {
- new Pipes.Fx.FadeInAndShow(new Element('div').setHTML(result), {where: this.anchor.parentNode}).toggle();
+ new Argil.Fx.FadeInAndShow(new Element('div').setHTML(result), {where: this.anchor.parentNode}).toggle();
},
});
-Pipes.objects.Anchor.EditForm = Pipes.objects.Anchor.extend({
+Argil.objects.Anchor.EditForm = Argil.objects.Anchor.extend({
initialize: function(anchor) {
this.parent(anchor);
},
@@ -145,17 +145,17 @@
return false;
},
onComplete: function(result) {
- new Pipes.Fx.FadeInAndShow(new Element('div').setHTML(result), {where: 'dashboard_action'}).toggle();
+ new Argil.Fx.FadeInAndShow(new Element('div').setHTML(result), {where: 'dashboard_action'}).toggle();
}
});
-Pipes.objects.Anchor.BrowseReplace = Pipes.objects.Anchor.extend({
+Argil.objects.Anchor.BrowseReplace = Argil.objects.Anchor.extend({
initialize: function(anchor) {
this.parent(anchor);
},
process: function() {
var me = this;
- this.modal = new Pipes.objects.Modal($('dashboard_browse'));
+ this.modal = new Argil.objects.Modal($('dashboard_browse'));
this.modal.show();
new Ajax(
me.anchor.href + '?isAjax=true',
@@ -166,12 +166,12 @@
},
onComplete: function(result) {
$('dashboard_browse').setHTML(result);
- Pipes.ajaxify($('dashboard_browse'), {type:'AjaxifiedLinks'}).process();
+ Argil.ajaxify($('dashboard_browse'), {type:'AjaxifiedLinks'}).process();
}
});
-Pipes.objects.Modal = new Class({
+Argil.objects.Modal = new Class({
initialize: function(container) {
this.container = container;
this.container.setStyles({
@@ -191,14 +191,14 @@
this.container.removeChild(this.modal);
},
});
-Pipes.objects.Form = new Class({
+Argil.objects.Form = new Class({
requireValidation: false,
onComplete: function(result) {
// update dashboard if available, otherwise replace
var dashboard = $('dashboard_browse');
var div = new Element('div').setHTML(result);
if (dashboard !== false) {
- new Pipes.Fx.FadeOutAndRemove(this.form.parentNode.parentNode).toggle();
+ new Argil.Fx.FadeOutAndRemove(this.form.parentNode.parentNode).toggle();
div.id = 'dashboard_browse';
dashboard.replaceWith(div);
} else {
@@ -206,7 +206,7 @@
}
},
loading: function() {
- this.loadingModal = new Pipes.objects.Modal(this.form);
+ this.loadingModal = new Argil.objects.Modal(this.form);
this.loadingModal.show();
},
initialize: function(selector, options) {
@@ -231,8 +231,8 @@
});
-Pipes.Fx = {};
-Pipes.Fx.FadeOutAndRemove = new Class({
+Argil.Fx = {};
+Argil.Fx.FadeOutAndRemove = new Class({
initialize: function(selector, options) {
this.element = $(selector);
this.options = options || {};
@@ -246,9 +246,9 @@
}.delay(this.options.duration);
}
});
-Pipes.Fx.FadeOutAndRemove.implement(new Chain);
+Argil.Fx.FadeOutAndRemove.implement(new Chain);
-Pipes.Fx.FadeInAndShow = new Class({
+Argil.Fx.FadeInAndShow = new Class({
initialize: function(selector, options) {
this.element = $(selector);
this.options = options || {};
@@ -260,4 +260,4 @@
new Fx.Style(this.element, 'opacity').start(0,1);
}
});
-Pipes.Fx.FadeInAndShow.implement(new Chain);
+Argil.Fx.FadeInAndShow.implement(new Chain);
Modified: trunk/src/ArgilSample/sample.config.php
===================================================================
--- trunk/src/ArgilSample/sample.config.php 2007-02-14 03:31:04 UTC (rev 482)
+++ trunk/src/ArgilSample/sample.config.php 2007-02-16 00:31:14 UTC (rev 483)
@@ -11,8 +11,8 @@
);
if (defined('PIPES_TEST_MODE')) {
- $config['pdo'] = new PDO('mysql:host=localhost;dbname=argilsample_dev', 'root', '');
+ $config['pdo'] = new PDO('mysql:host=localhost;dbname=argil_sample_dev', 'root', '');
} else {
- $config['pdo'] = new PDO('mysql:host=localhost;dbname=argilsample', 'root', '');
+ $config['pdo'] = new PDO('mysql:host=localhost;dbname=argil_sample', 'root', '');
}
return $config;
This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.
|
|
From: <tsw...@us...> - 2007-02-14 03:31:11
|
Revision: 482
http://argil.svn.sourceforge.net/argil/?rev=482&view=rev
Author: tswicegood
Date: 2007-02-13 19:31:04 -0800 (Tue, 13 Feb 2007)
Log Message:
-----------
Make it so all you have to do is type 'phing' at the working copy to get an installable package
Modified Paths:
--------------
trunk/build.xml
Modified: trunk/build.xml
===================================================================
--- trunk/build.xml 2007-02-13 23:45:34 UTC (rev 481)
+++ trunk/build.xml 2007-02-14 03:31:04 UTC (rev 482)
@@ -4,7 +4,7 @@
currently checked out code.
-->
-<project name="Argil" basedir="." default="Argil.pear">
+<project name="Argil" basedir="." default="all">
<property file="${project.basedir}/misc/build.properties" />
<!--
This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.
|