diff --git a/sys/common/functions.php b/sys/common/functions.php index 96f0319..827a5a8 100644 --- a/sys/common/functions.php +++ b/sys/common/functions.php @@ -40,7 +40,7 @@ function array_to_object($array) // -------------------------------------------------------------------------- /** - * Create info dialog to retun an informational message + * Create info dialog to return an informational message * * @param string $message * @return void @@ -142,5 +142,4 @@ function about() $dlg->destroy(); } - // End of functions.php \ No newline at end of file diff --git a/sys/widgets/connection_sidebar.php b/sys/widgets/connection_sidebar.php index b93007c..51cbc56 100644 --- a/sys/widgets/connection_sidebar.php +++ b/sys/widgets/connection_sidebar.php @@ -19,26 +19,36 @@ class Connection_Sidebar extends GtkVBox { /** * Reference to Settings instance + * + * @var Settings */ protected $settings; /** * Reference to popup menu + * + * @var GtkMenu */ protected $menu; /** * Treeview for displaying connections + * + * @var GtkTreeView */ protected $treeview; /** * Singleton instance + * + * @var Connection_Sidebar */ private static $instance; /** * Name of current db connection + * + * @var string */ private $conn_name; diff --git a/sys/widgets/data_grid.php b/sys/widgets/data_grid.php index 621aeb9..5342a37 100644 --- a/sys/widgets/data_grid.php +++ b/sys/widgets/data_grid.php @@ -19,6 +19,8 @@ class Data_Grid extends GtkTreeView { /** * GtkTreeStore object + * + * @var GtkTreeStore */ protected $model; diff --git a/sys/widgets/db_info_widget.php b/sys/widgets/db_info_widget.php index 9a870a7..f6790ce 100644 --- a/sys/widgets/db_info_widget.php +++ b/sys/widgets/db_info_widget.php @@ -19,97 +19,127 @@ class DB_Info_Widget extends GtkTable { /** * Alias to Settings::get_instance + * * @var Settings */ private $settings; /** * Connection name + * + * @var GtkEntry */ protected $conn; /** * Connection database name + * + * @var GtkEntry */ protected $conn_db; /** * Connection database type + * + * @var GtkComboBox */ protected $dbtype; /** * Connection database host + * + * @var GtkEntry */ protected $host; /** * Connection user name + * + * @var GtkEntry */ protected $user; /** * Connection password + * + * @var GtkEntry */ protected $pass; /** * Connection database file + * + * @var GtkFileChooserButton */ protected $db_file; /** * Connection port + * + * @var GtkEntry */ protected $port; /** * Reference to last connection name + * + * @var string */ protected $old_conn; /** - * Labels + * Label for connection name + * + * @var GtkLabel */ protected $lblconn; /** - * Labels + * Label for connection database name + * + * @var Gtklabel */ protected $lblconn_db; /** - * Labels + * Label for database type + * + * @var Gtklabel */ protected $lbldbtype; /** - * Labels + * Label for database host + * + * @var Gtklabel */ protected $lblhost; /** - * Labels + * Label for database connection user + * + * @var GtkLabel */ protected $lbluser; /** - * Labels + * Label for database connection password + * + * @var GtkLabel */ protected $lblpass; /** - * Labels - */ - protected $lbldatabase; - - /** - * Labels + * Label for database file + * + * @var GtkLabel */ protected $lbldb_file; /** - * Labels + * Label for database connection port + * + * @var GtkLabel */ protected $lblport; @@ -121,6 +151,7 @@ class DB_Info_Widget extends GtkTable { * No params = add, params = edit * * @param object $db + * @return void */ public function __construct($db=null) { @@ -535,48 +566,32 @@ class DB_Info_Widget extends GtkTable { $y2 = 0; // Connection name - { - $this->_add_row("Connection name", 'conn', $y1, $y2); - } + $this->_add_row("Connection name", 'conn', $y1, $y2); // Database type - { - $dbtypelbl = new GtkLabel("Database Type"); - $typealign = new GtkAlignment(0, 0.5, 0, 0); - $typealign->add($dbtypelbl); - $this->attach($typealign, 0, 1, ++$y1, ++$y2); - $this->attach($this->dbtype, 1, 2, $y1, $y2); - } + $dbtypelbl = new GtkLabel("Database Type"); + $typealign = new GtkAlignment(0, 0.5, 0, 0); + $typealign->add($dbtypelbl); + $this->attach($typealign, 0, 1, ++$y1, ++$y2); + $this->attach($this->dbtype, 1, 2, $y1, $y2); // DB File - { - $this->_add_row("Database File", 'db_file', $y1, $y2); - } + $this->_add_row("Database File", 'db_file', $y1, $y2); // First Db - { - $this->_add_row("Database Name", 'conn_db', $y1, $y2); - } + $this->_add_row("Database Name", 'conn_db', $y1, $y2); // Host - { - $this->_add_row("Host", 'host', $y1, $y2); - } + $this->_add_row("Host", 'host', $y1, $y2); // Port - { - $this->_add_row("Port", 'port', $y1, $y2); - } + $this->_add_row("Port", 'port', $y1, $y2); // Username - { - $this->_add_row("User", 'user', $y1, $y2); - } + $this->_add_row("User", 'user', $y1, $y2); // Password - { - $this->_add_row("Password", 'pass', $y1, $y2); - } + $this->_add_row("Password", 'pass', $y1, $y2); // Add/Edit connection button { diff --git a/sys/widgets/db_tabs.php b/sys/widgets/db_tabs.php index cacd4b2..3780182 100644 --- a/sys/widgets/db_tabs.php +++ b/sys/widgets/db_tabs.php @@ -19,12 +19,15 @@ class DB_tabs extends GTKNotebook { /** * Current Tab Widget object + * * @var DB_Tabs */ private static $instance; /** * Db Data cache + * + * @var array */ private $data; diff --git a/sys/windows/db_table_data.php b/sys/windows/db_table_data.php index e46ff49..6179a62 100644 --- a/sys/windows/db_table_data.php +++ b/sys/windows/db_table_data.php @@ -19,6 +19,8 @@ class DB_Table_Data extends GTKWindow { /** * Reference to the scrolled window + * + * @var GtkScrolledWindow */ protected $win; diff --git a/sys/windows/main.php b/sys/windows/main.php index 8b4383a..99fb906 100644 --- a/sys/windows/main.php +++ b/sys/windows/main.php @@ -21,11 +21,15 @@ class Main extends GtkWindow { /** * Reference to settings instance + * + * @var Settings */ private $settings; /** * Reference to connection sidebar instance + * + * @var Connection_Sidebar */ private $connection_sidebar;