cvs: pear /XML_XUL/XUL Document.php
| From: | Amir Mohammad Saied | Date: | Fri, 02 Feb 2007 15:05:29 +0000 |
| Subject: | cvs: pear /XML_XUL/XUL Document.php | ||
| Groups: | php.pear.cvs | ||
| Request: | Send a blank email to pear-cvs+get-44511@lists.php.net to get a copy of this message | ||
amir Fri Feb 2 15:05:29 2007 UTC
Modified files:
/pear/XML_XUL/XUL Document.php
Log:
Overlays suppord added
http://cvs.php.net/viewvc.cgi/pear/XML_XUL/XUL/Document.php?r1=1.6&r2=1.7&diff_format=u
Index: pear/XML_XUL/XUL/Document.php
diff -u pear/XML_XUL/XUL/Document.php:1.6 pear/XML_XUL/XUL/Document.php:1.7
--- pear/XML_XUL/XUL/Document.php:1.6 Tue Mar 15 22:41:14 2005
+++ pear/XML_XUL/XUL/Document.php Fri Feb 2 15:05:28 2007
@@ -83,6 +83,14 @@
var $_htmlNs;
/**
+ * overlays that should be included
+ *
+ * @access private
+ * @var array
+ */
+ var $_overlays = array();
+
+ /**
* stylesheets that should be included
*
* @access private
@@ -143,6 +151,17 @@
}
/**
+ * add an overlay
+ *
+ * @access public
+ * @params string uri of overlay
+ */
+ function addOverlay( $uri )
+ {
+ array_push($this->_overlays, $uri);
+ }
+
+ /**
* add a stylesheet
*
* @access public
@@ -264,6 +283,14 @@
}
$doc .= XML_Util::getDocTypeDeclaration( $root, $this->_dtd ) . "\n";
}
+
+ /**
+ * add overlays
+ */
+ $cnt = count($this->_overlays);
+ for ($i=0; $i<$cnt; $i++) {
+ $doc .= sprintf('<?xul-overlay href="%s"?>',
$this->_overlays[$i]). "\n";
+ }
/**
* add styles
@@ -413,4 +440,4 @@
echo $this->getDebug();
}
}
-?>
\ No newline at end of file
+?>