summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorDaniel Wehner2011-02-05 16:50:37 (GMT)
committer Daniel Wehner2011-02-05 16:50:37 (GMT)
commitdd83660c5417a6a53d5fee59bf7154069ffb5bcf (patch)
tree23cfe191620f49f073e9a466a11417f77d1d0af2
parent862bda284066e38fe7d39aa5513842509ec7a1e3 (diff)
#1012596 by dereine: More inline documentation of class variables.
-rw-r--r--CHANGELOG.txt2
-rw-r--r--includes/base.inc8
-rw-r--r--includes/handlers.inc14
-rw-r--r--includes/plugins.inc14
-rw-r--r--includes/view.inc28
-rw-r--r--plugins/views_plugin_display.inc7
-rw-r--r--plugins/views_plugin_query_default.inc7
7 files changed, 77 insertions, 3 deletions
diff --git a/CHANGELOG.txt b/CHANGELOG.txt
index 8400559..eb96a9f 100644
--- a/CHANGELOG.txt
+++ b/CHANGELOG.txt
@@ -35,6 +35,8 @@ Fix fieldsets in field handler.
#776830: Attachments and other displays lost "Items to display" controls.
#747782 by dereine: Improve jump menu grouping.
#1026014 by dereine and alex_b: Use more always should not ask for the count query to see if we need to show the more link.
+#1012596 by dereine: More inline documentation of class variables.
+#988680 by mikeytown2: Fix Views memory leak with attachments.
Views 3.x-7.x-alpha1 (05-Jan-2011)
==================================
diff --git a/includes/base.inc b/includes/base.inc
index 21deea7..bcad6ed 100644
--- a/includes/base.inc
+++ b/includes/base.inc
@@ -14,6 +14,14 @@ class views_object {
* Except for displays, options for the object will be held here.
*/
var $options = array();
+
+ /**
+ * The top object of a view.
+ *
+ * @var view
+ */
+ var $view = NULL;
+
/**
* Information about options for all kinds of purposes will be held here.
* @code
diff --git a/includes/handlers.inc b/includes/handlers.inc
index 457b241..c057df6 100644
--- a/includes/handlers.inc
+++ b/includes/handlers.inc
@@ -123,6 +123,20 @@ function views_get_table_join($table, $base_table) {
*/
class views_handler extends views_object {
/**
+ * The top object of a view.
+ *
+ * @var view
+ */
+ var $view = NULL;
+
+ /**
+ * Where the $query object will reside:
+ *
+ * @var views_plugin_query
+ */
+ var $query = NULL;
+
+ /**
* init the handler with necessary data.
* @param $view
* The $view object this handler is attached to.
diff --git a/includes/plugins.inc b/includes/plugins.inc
index 80ece46..e592af7 100644
--- a/includes/plugins.inc
+++ b/includes/plugins.inc
@@ -419,6 +419,20 @@ function views_discover_plugins() {
*/
class views_plugin extends views_object {
/**
+ * The top object of a view.
+ *
+ * @var view
+ */
+ var $view = NULL;
+
+ /**
+ * The current used display plugin.
+ *
+ * @var views_plugin_display
+ */
+ var $display = NULL;
+
+ /**
* Init will be called after construct, when the plugin is attached to a
* view and a display.
*/
diff --git a/includes/view.inc b/includes/view.inc
index 3aa8783..4b558c3 100644
--- a/includes/view.inc
+++ b/includes/view.inc
@@ -51,9 +51,27 @@ class view extends views_db_object {
// Used to store views that were previously running if we recurse.
var $old_view = array();
- // Where the $query object will reside:
+ /**
+ * Where the $query object will reside:
+ *
+ * @var views_plugin_query
+ */
var $query = NULL;
+ /**
+ * The current used display plugin.
+ *
+ * @var views_plugin_display
+ */
+ var $display_handler;
+
+ /**
+ * The current used style plugin.
+ *
+ * @var views_plugin_style
+ */
+ var $style_plugin;
+
/**
* Constructor
*/
@@ -1275,7 +1293,8 @@ class view extends views_db_object {
* The name of the view or its internal view id (vid)
* @param $reset
* If TRUE, reset this entry in the load cache.
- * @return A view object or NULL if it was not available.
+ * @return view
+ * A view object or NULL if it was not available.
*/
static function &load($arg, $reset = FALSE) {
static $cache = array();
@@ -1512,6 +1531,9 @@ class view extends views_db_object {
* view. This gets ugly fast.
*
* This will completely wipe a view clean so it can be considered fresh.
+ *
+ * @return view
+ * The cloned view.
*/
function clone_view() {
$clone = version_compare(phpversion(), '5.0') < 0 ? $this : clone($this);
@@ -1919,7 +1941,7 @@ class views_db_object {
* The title of the display; optional, may be filled in from default.
* @param $id
* The id to use.
- * @return
+ * @return views_plugin_display
* A reference to the new handler object.
*/
function &new_display($type = 'page', $title = NULL, $id = NULL) {
diff --git a/plugins/views_plugin_display.inc b/plugins/views_plugin_display.inc
index bad8220..1d445bc 100644
--- a/plugins/views_plugin_display.inc
+++ b/plugins/views_plugin_display.inc
@@ -25,6 +25,13 @@
* @ingroup views_display_plugins
*/
class views_plugin_display extends views_plugin {
+ /**
+ * The top object of a view.
+ *
+ * @var view
+ */
+ var $view = NULL;
+
var $handlers = array();
function init(&$view, &$display, $options = NULL) {
diff --git a/plugins/views_plugin_query_default.inc b/plugins/views_plugin_query_default.inc
index 7658944..d72b292 100644
--- a/plugins/views_plugin_query_default.inc
+++ b/plugins/views_plugin_query_default.inc
@@ -74,6 +74,13 @@ class views_plugin_query_default extends views_plugin_query {
var $get_count_optimized = NULL;
/**
+ * The current used pager plugin.
+ *
+ * @var views_plugin_pager
+ */
+ var $pager = NULL;
+
+ /**
* Constructor; Create the basic query object and fill with default values.
*/
function init($base_table = 'node', $base_field = 'nid', $options) {