Skip to content

Commit

Permalink
documentation improvements
Browse files Browse the repository at this point in the history
  • Loading branch information
setola committed Apr 10, 2013
1 parent d5486cf commit 66514c3
Show file tree
Hide file tree
Showing 36 changed files with 105 additions and 18 deletions.
4 changes: 2 additions & 2 deletions AjaxImageGenerator.class.php
Original file line number Diff line number Diff line change
Expand Up @@ -6,11 +6,11 @@

/**
* Hooks the ImageGenerator class to admin-ajax action
*
* @author etessore
* @version 1.0.0
* @package classes
*
* 1.0.0
* Initial release
*/
class AjaxImageGenerator{
/**
Expand Down
6 changes: 5 additions & 1 deletion ClassAutoloader.class.php
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,11 @@
* Autoload needed classes
* @author etessore
* @version 1.0.1
*
* @package classes
*/

/*
* Changelog:
* 1.0.1
* support multiple search path to allow children theme to extend classes
* 1.0.0
Expand Down
9 changes: 9 additions & 0 deletions DebugUtils.class.php
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,7 @@
/**
* Utils to debug the code while writing it.
* @author Emanuele 'Tex' Tessore
* @package classes
*/
final class DebugUtils {

Expand Down Expand Up @@ -141,6 +142,8 @@ public function set_title($title){
* Quick and dirty way to know a variable value
* vd stand for <b>v</b>ar_dump() and <b>d</b>ie()
* @param mixed $var the variable to be dumped
* @package debug
* @version 1.0.0
*/
function vd($var){
DebugUtils::get_instance()
Expand All @@ -155,6 +158,8 @@ function vd($var){
* Quick and dirty way to know a variable value
* Usefull in a loop cause it doesn't break the execution with die
* @param mixed $var the variable to be dumped
* @package debug
* @version 1.0.0
*/
function v($var){
DebugUtils::get_instance()
Expand All @@ -169,6 +174,8 @@ function v($var){
* Quick and dirty way to know a variable value in a production enviroment
* vc stand for <b>v</b>ar_dump() on a <b>c</b>omment
* @param mixed $var the variable to be dumped
* @package debug
* @version 1.0.0
*/
function vc($var){
DebugUtils::get_instance()
Expand All @@ -183,6 +190,8 @@ function vc($var){
* Quick and dirty way to know a variable value.
* It uses the last changed mode.
* @param mixed $var the variable to be dumped
* @package debug
* @version 1.0.0
*/
function debug($var){
DebugUtils::get_instance()
Expand Down
1 change: 1 addition & 0 deletions DefaultAssets.class.php
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,7 @@
* Register some useful assets in WordPress
* @author etessore
* @version 1.0.1
* @package classes
*/
class DefaultAssets{
/**
Expand Down
1 change: 1 addition & 0 deletions DefaultAssetsCDN.class.php
Original file line number Diff line number Diff line change
Expand Up @@ -11,6 +11,7 @@
*
* @author etessore
* @since 1.0
* @package classes
*
*/
class DefaultAssetsCDN extends DefaultAssets{
Expand Down
5 changes: 4 additions & 1 deletion EscapeRoute.class.php
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,10 @@
* Manages the navigation links on a 404 page
* @author etessore
* @version 1.0.1
*
* @package classes
*/

/*
* Changelog
* 1.0.1
* moved from ThemeHelpers to HtmlHelper class
Expand Down
8 changes: 6 additions & 2 deletions FeatureWithAssets.class.php
Original file line number Diff line number Diff line change
Expand Up @@ -11,8 +11,12 @@
* You have to take care of it by yourself (tipically in assets.php)
* @author etessore
* @version 1.0.1
*
* 1.0.1
* @package classes
*/

/*
* Changelog:
* 1.0.1
* Fixed Notice: wp_enqueue_script was called incorrectly
* 1.0.0
* Initial release
Expand Down
1 change: 1 addition & 0 deletions ForceDownload.class.php
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,7 @@
* Force an attachment to be downloaded
* @author etessore
* @version 1.0.0
* @package classes
*/
class ForceDownload{

Expand Down
1 change: 1 addition & 0 deletions GMapDataRetriever.class.php
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,7 @@
* Retrieves GMaps data for the gmap.js integration
* @author etessore
* @version 1.0
* @package classes
*/
class GMapDataRetriever {
/**
Expand Down
1 change: 1 addition & 0 deletions GalleryHelper.class.php
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,7 @@
* Extend this with your nice and candy classes!
* @author etessore
* @version 1.0.2
* @package classes
*/
abstract class GalleryHelper extends FeatureWithAssets{

Expand Down
1 change: 1 addition & 0 deletions GaussianMath.class.php
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,7 @@
/**
* The following object is used to compute numbers with a gaussian distribution
* @link http://us.php.net/manual/en/function.rand.php#53784
* @package classes
*/
class GaussianMath{

Expand Down
1 change: 1 addition & 0 deletions GeneratorDictionary.class.php
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,7 @@
* Maintans a set of words for a sentences generator
* @author etessore
* @version 1.0.0
* @package classes
* @todo maintain an ordinate array so that
* insertion and deletion will be more efficent
*/
Expand Down
1 change: 1 addition & 0 deletions HashAnchorWalkerNavMenu.class.php
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,7 @@
* Menu Walker to have the la tocke of the url as hash
* ex: http://www.fastbooking.net/clients/#africa
* @author etessore
* @package classes
*/
class HashAnchorWalkerNavMenu extends Walker_Nav_Menu{
/**
Expand Down
2 changes: 2 additions & 0 deletions HeadHelper.class.php
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,8 @@
/**
* Some helper for the code inside <head> tag
* @author etessore
* @version 1.0.0
* @package classes
*
*/
class HeadHelper{
Expand Down
1 change: 1 addition & 0 deletions HtmlHelper.class.php
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,7 @@
* Helper class useful to generate some html tags
* @author etessore
* @version 1.0.0
* @package classes
*/
class HtmlHelper extends HtmlBuilder{

Expand Down
9 changes: 6 additions & 3 deletions ImageGenerator.class.php
Original file line number Diff line number Diff line change
Expand Up @@ -6,11 +6,14 @@
* Generates paceholder images
* @author etessore
* @version 1.0.1
*
* @package classes
*/
/*
* Changelog:
* 1.0.1
* added hooks into wordpress
* added hooks into wordpress
* 1.0.0
* Initial release
* Initial release
*/
class ImageGenerator{
/**
Expand Down
1 change: 1 addition & 0 deletions ImagePreload.class.php
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,7 @@
* Takes care of image preloading with jQuery imagesloaded
* @author etessore
* @version 1.0.0
* @package classes
*/
class ImagePreload extends GalleryHelper{

Expand Down
2 changes: 2 additions & 0 deletions LevelWalkerNavMenu.class.php
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,8 @@
/**
* Adds the level for the current menu element
* @author etessore
* @version 1.0.0
* @package classes
*
*/
class LevelWalkerNavMenu extends Walker_Nav_Menu {
Expand Down
2 changes: 2 additions & 0 deletions LipsumGenerator.class.php
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,8 @@
/**
* Generates Lorem Ipsum text
* @author etessore
* @version 1.0.0
* @package classes
*/
class LipsumGenerator {

Expand Down
2 changes: 2 additions & 0 deletions LoremIpsumDictionary.class.php
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,8 @@
/**
* Stores the dictionary for generating 'Lorem ipsum...' text
* @author etessore
* @version 1.0.0
* @package classes
*/
class LoremIpsumDictionary extends GeneratorDictionary{

Expand Down
1 change: 1 addition & 0 deletions MinigalleryBigImageWithThumbs.class.php
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,7 @@
* with a big image and some small thumbs
* @author etessore
* @version 1.0.0
* @package classes
*/
class MinigalleryBigImageWithThumbs extends GalleryHelper{
/**
Expand Down
1 change: 1 addition & 0 deletions MinigalleryThumbsLinkToBig.class.php
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,7 @@
* By default loads FancyBox so to have an eye candy popup effect.
* @author etessore
* @version 1.0.0
* @package classes
*/
class MinigalleryThumbsLinkToBig extends GalleryHelper{
/**
Expand Down
26 changes: 21 additions & 5 deletions NewBlogInitializator.class.php
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,7 @@
*
* @author etessore
* @version 1.0.0
* @package classes
*
*/
class NewBlogInitializator{
Expand All @@ -31,6 +32,9 @@ class NewBlogInitializator{
*/
private $pages = array();

/**
* Hooks the initial data filling into WordPress
*/
public function hook(){
add_action('wpmu_new_blog', array(&$this, 'init'), 10, 1);
}
Expand Down Expand Up @@ -177,8 +181,8 @@ public function add_menu_entry($index, $menu_id){
/**
* Adds all automatically generated pages to the given menu
* @param int $menu_id the menu id
* @params int $start the first element index
* @params int $end the last element index
* @param int $start the first element index
* @param int $end the last element index
* @return NewBlogInitializator $this for chainability
*/
public function add_menu_entries($menu_id, $start=0, $end=null){
Expand Down Expand Up @@ -208,11 +212,23 @@ public function reset_page_list(){
* Then tries to create style.css in the newly
* theme folder and fill it with the default header comment
*
* An example of parameters:
* <code>
* $defaults = array(
* 'name' => 'Wordpress Theme Utils Child Theme',
* 'folder' => 'wtu-child-theme',
* 'child_of' => 'Wordpress-Theme-Utils',
* 'description' => 'This is a Child Theme of Wordpress Theme Utils',
* 'theme_uri' => 'http://www.emanueletessore.com/',
* 'author' => 'Emanuele Tessore',
* 'author_uri' => 'http://www.emanueletessore.com/',
* 'version' => '1.0.0'
* );
* </code>
*
* Uses {@link http://codex.wordpress.org/Function_Reference/wp_die wp_die()} if something goes wrong
*
* @param string $name the name of your new child theme. Spaces and tags will be stripped
* @param string $child_of the parent theme, default hotel-template
* @param string $description the description of the theme will be showed in WP backend
* @param array $parms parameters for the new theme
* @return NewBlogInitializator $this for chainability
*/
public function add_theme($parms=null){
Expand Down
1 change: 1 addition & 0 deletions OneImageForAll.class.php
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,7 @@
* Important: every image have the same sizes and jpeg quality.
* @author etessore
* @version 1.0.0
* @package classes
*/
class OneImageForAll extends GalleryHelper{
/**
Expand Down
2 changes: 2 additions & 0 deletions PhotogalleryThumbWithFancybox.class.php
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,8 @@
* Manages images and markup for a photogallery where
* clicking on a little thumb opens the big image in fancybox
* @author etessore
* @version 1.0.0
* @package classes
*/
class PhotogalleryThumbWithFancybox extends GalleryHelper{

Expand Down
1 change: 1 addition & 0 deletions RemoveSpacesWalkerNavMenu.class.php
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,7 @@
* text-align: center;</code>
* @author etessore
* @version 1.0.0
* @package classes
*/
class RemoveSpacesWalkerNavMenu extends Walker_Nav_Menu {
/**
Expand Down
5 changes: 4 additions & 1 deletion RuntimeInfos.class.php
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,10 @@
* Manages a set of info to be printed as a json generally at the endo of the page
* @author etessore
* @version 1.0.1
*
* @package classes
*/

/*
* Changelog
* 1.0.1
* solved notice of undefined post on 404 pages
Expand Down
5 changes: 5 additions & 0 deletions ShortcodeForTabs.class.php
Original file line number Diff line number Diff line change
Expand Up @@ -22,6 +22,7 @@
*
* @author etessore
* @version 1.0.0
* @package classes
* @since 1.0
*/
class ShortcodeForTabs{
Expand Down Expand Up @@ -73,6 +74,8 @@ public function __construct(){

/**
* Register the needed shortcodes with WordPress subsystem
* @param boolean $tab true if you want to enable the shortcode for the single tab
* @param boolean $list true if you want to enable the shortcode for the list of tabs
*/
private function add_shordcode($tab=true, $list=true){
if($tab) add_shortcode(self::$tab_shortcode, array(&$this, 'tab_hook'));
Expand All @@ -81,6 +84,8 @@ private function add_shordcode($tab=true, $list=true){

/**
* Deletes the shortcodes used in this feature
* @param boolean $tab true if you want to remove the shortcode for the single tab
* @param boolean $list true if you want to remove the shortcode for the list of tabs
*/
private function delete_shortcode($tab=true, $list=true){
if($tab) remove_shortcode(self::$tab_shortcode, array(&$this, 'tab_hook'));
Expand Down
1 change: 1 addition & 0 deletions ShowItemExcerptWalkerNavMenu.class.php
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,7 @@
* to the default menu entry.
* @author etessore
* @version 1.0.0
* @package classes
*/
class ShowItemExcerptWalkerNavMenu extends Walker_Nav_Menu {
/**
Expand Down
1 change: 1 addition & 0 deletions ShowTitleThumbExcerptWalkerNavMenu.class.php
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,7 @@
* and the excerpt for every menu entry.
* @author etessore
* @version 1.0.0
* @package classes
*/
class ShowTitleThumbExcerptWalkerNavMenu extends Walker_Nav_Menu {
/**
Expand Down
4 changes: 3 additions & 1 deletion SimpleFieldsQuickConfig.class.php
Original file line number Diff line number Diff line change
Expand Up @@ -5,11 +5,13 @@

/**
* Perform a quick configuration for Simple Fields plugin
* with the default values used by FastBooking
*
* It uses the default values used by FastBooking
* By default you only need to call in functions.php:
* <code>new SimpleFieldsQuickConfig();</code>
* @author etessore
* @version 1.0
* @package classes
*/
class SimpleFieldsQuickConfig{

Expand Down
Loading

0 comments on commit 66514c3

Please sign in to comment.