-
Notifications
You must be signed in to change notification settings - Fork 38
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
19 changed files
with
1,927 additions
and
78 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,47 @@ | ||
<?php | ||
/** | ||
* Babel | ||
* | ||
* Copyright 2010 by Jakob Class <jakob.class@class-zec.de> | ||
* | ||
* This file is part of Babel. | ||
* | ||
* Babel is free software; you can redistribute it and/or modify it under the | ||
* terms of the GNU General Public License as published by the Free Software | ||
* Foundation; either version 2 of the License, or (at your option) any later | ||
* version. | ||
* | ||
* Babel is distributed in the hope that it will be useful, but WITHOUT ANY | ||
* WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR | ||
* A PARTICULAR PURPOSE. See the GNU General Public License for more details. | ||
* | ||
* You should have received a copy of the GNU General Public License along with | ||
* Babel; if not, write to the Free Software Foundation, Inc., 59 Temple Place, | ||
* Suite 330, Boston, MA 02111-1307 USA | ||
* | ||
* @package babel | ||
*/ | ||
/** | ||
* Add menu to build | ||
* | ||
* @author Jakob Class <jakob.class@class-zec.de> | ||
* goldsky <goldsky@virtudraft.com> | ||
* @package babel | ||
* @subpackage build | ||
*/ | ||
|
||
$menu = $modx->newObject('modMenu'); | ||
$menu->fromArray(array( | ||
'text' => 'babel', | ||
'parent' => 'components', | ||
'action' => 'index', | ||
'description' => 'babel.desc', | ||
'icon' => 'images/icons/plugin.gif', | ||
'menuindex' => 0, | ||
'params' => '', | ||
'handler' => '', | ||
'pemission' => '', | ||
'namespace' => 'babel', | ||
), '', true, true); | ||
|
||
return $menu; |
Empty file.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,9 @@ | ||
var Babel = function (config) { | ||
config = config || {}; | ||
Babel.superclass.constructor.call(this, config); | ||
}; | ||
Ext.extend(Babel, Ext.Component, { | ||
page: {}, window: {}, grid: {}, tree: {}, panel: {}, combo: {}, config: {} | ||
}); | ||
Ext.reg('babel', Babel); | ||
Babel = new Babel(); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,15 @@ | ||
Ext.onReady(function () { | ||
MODx.load({xtype: 'babel-page-home'}); | ||
}); | ||
Babel.page.Home = function (config) { | ||
config = config || {}; | ||
Ext.applyIf(config, { | ||
components: [{ | ||
xtype: 'babel-panel-home' | ||
, renderTo: 'babel-panel-home-div' | ||
}] | ||
}); | ||
Babel.page.Home.superclass.constructor.call(this, config); | ||
}; | ||
Ext.extend(Babel.page.Home, MODx.Component); | ||
Ext.reg('babel-page-home', Babel.page.Home); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,25 @@ | ||
Babel.combo.Context = function (config) { | ||
config = config || {}; | ||
Ext.applyIf(config, { | ||
url: Babel.config.connectorUrl, | ||
baseParams: { | ||
action: 'mgr/context/getlist', | ||
combo: true, | ||
exclude: 'mgr' | ||
} | ||
}); | ||
Babel.combo.Context.superclass.constructor.call(this, config); | ||
|
||
this.on('select', function (comp, record, index){ | ||
if (comp.getValue() === "" || comp.getValue() === " ") { | ||
comp.setValue(null); | ||
} | ||
}); | ||
this.on('change', function (comp, newValue, oldValue){ | ||
if (newValue === "" || newValue === " ") { | ||
comp.setValue(null); | ||
} | ||
}); | ||
}; | ||
Ext.extend(Babel.combo.Context, MODx.combo.Context); | ||
Ext.reg('babel-combo-context', Babel.combo.Context); |
Oops, something went wrong.