From 86c82ea8da949ff9e2474bf89986a9f4fbf18080 Mon Sep 17 00:00:00 2001 From: Mark Nelson Date: Wed, 10 Apr 2013 17:53:56 +0800 Subject: [PATCH] Renamed the function responsible for rendering the elements to something more suitable --- elements/date/lib.php | 5 ++--- elements/element.class.php | 4 ++-- elements/grade/lib.php | 5 ++--- elements/studentname/lib.php | 4 ++-- 4 files changed, 8 insertions(+), 10 deletions(-) diff --git a/elements/date/lib.php b/elements/date/lib.php index 3fd8948..5346a72 100644 --- a/elements/date/lib.php +++ b/elements/date/lib.php @@ -98,12 +98,11 @@ class customcert_element_date extends customcert_element_base { } /** - * Handles displaying the element on the pdf. + * Handles rendering the element on the pdf. * * @param $pdf the pdf object, see lib/pdflib.php - * @todo functionality missing, add when we start rendering the pdf */ - public function display($pdf) { + public function render($pdf) { global $USER; // TO DO. diff --git a/elements/element.class.php b/elements/element.class.php index 8c7a287..aefaae8 100644 --- a/elements/element.class.php +++ b/elements/element.class.php @@ -200,12 +200,12 @@ class customcert_element_base { } /** - * Handles displaying the element on the pdf. + * Handles rendering the element on the pdf. * Must be overriden. * * @param stdClass the pdf object, see lib/pdflib.php */ - public function display($pdf) { + public function render($pdf) { // Must be overriden. return false; } diff --git a/elements/grade/lib.php b/elements/grade/lib.php index 097b78f..be406ea 100644 --- a/elements/grade/lib.php +++ b/elements/grade/lib.php @@ -102,12 +102,11 @@ class customcert_element_grade extends customcert_element_base { } /** - * Handles displaying the element on the pdf. + * Handles rendering the element on the pdf. * * @param $pdf the pdf object, see lib/pdflib.php - * @todo functionality missing, add when we start rendering the pdf */ - public function display($pdf) { + public function render($pdf) { global $USER; // TO DO. diff --git a/elements/studentname/lib.php b/elements/studentname/lib.php index 21a107b..c87db3e 100644 --- a/elements/studentname/lib.php +++ b/elements/studentname/lib.php @@ -39,11 +39,11 @@ class customcert_element_studentname extends customcert_element_base { } /** - * Handles displaying the element on the pdf. + * Handles rendering the element on the pdf. * * @param $pdf the pdf object, see lib/pdflib.php */ - public function display($pdf) { + public function render($pdf) { global $USER; $pdf->setFont($this->element->font, '', $this->element->size);