
var EditArea_mydbr= {
	execCommand: function(cmd, param){
		// Handle commands
		switch(cmd){
			case "new_document":
				parent.newTab();
				return false;
		}
		// Pass to next handler in chain
		return true;
	}
	
	,onkeydown: function(e){
		var str = String.fromCharCode(e.keyCode).toLowerCase();
		if ( e.ctrlKey && e.keyCode == 13) {
			parent.executeSQL();
			return false;
		}
		if ( e.ctrlKey && str == 's' ) {
			parent.getObject();
			return false;
		}
	}
};


// Adds the plugin class to the list of available EditArea plugins
editArea.add_plugin("mydbr", EditArea_mydbr);